forked from mtcontrib/bakedclay
Compare commits
7 Commits
nalc-1.0
...
nalc-1.2.0
Author | SHA1 | Date | |
---|---|---|---|
e8e1a446b7 | |||
dd7749131c | |||
b7b3b98003 | |||
1ba54476b1 | |||
3af99b27c9 | |||
9ec581dbf2 | |||
d6a2fbaaee |
@ -7,6 +7,8 @@ https://forum.minetest.net/viewtopic.php?id=8890
|
||||
|
||||
Changelog:
|
||||
|
||||
- 0.9 - Baked clay now works in the technic cnc machine
|
||||
- 0.8 - Cooking clay block in furnace gives natural baked clay which you can dye
|
||||
- 0.7 - Added support for stairsplus so that stairs are registered properly
|
||||
- 0.6 - Added 3 new flowers and a new grass that are used for missing dyes
|
||||
- 0.5 - Now using minecraft recipe to colour baked clay (8x baked clay, 1x dye in centre)
|
||||
@ -15,4 +17,7 @@ Changelog:
|
||||
- 0.2 - Any colour of baked clay can be re-dyed into another colour
|
||||
- 0.1 - Initial Release
|
||||
|
||||
Lucky Blocks: 8
|
||||
Lucky Blocks: 9
|
||||
|
||||
|
||||
Note: Under settings you will find 'colored_clay_compatibility' switch that when enabled will register aliases for the older colored clay mod and it's stairplus stairs.
|
||||
|
@ -2,3 +2,4 @@ default
|
||||
stairs
|
||||
moreblocks?
|
||||
lucky_block?
|
||||
technic_cnc?
|
||||
|
83
init.lua
83
init.lua
@ -2,6 +2,7 @@
|
||||
-- Baked Clay by TenPlus1
|
||||
|
||||
local clay = {
|
||||
{"natural", "Natural"},
|
||||
{"white", "White"},
|
||||
{"grey", "Grey"},
|
||||
{"black", "Black"},
|
||||
@ -19,6 +20,7 @@ local clay = {
|
||||
{"dark_green", "Dark Green"},
|
||||
}
|
||||
|
||||
local techcnc_mod = minetest.get_modpath("technic_cnc")
|
||||
local stairs_mod = minetest.get_modpath("stairs")
|
||||
local stairsplus_mod = minetest.get_modpath("moreblocks")
|
||||
and minetest.global_exists("stairsplus")
|
||||
@ -35,7 +37,7 @@ for _, clay in pairs(clay) do
|
||||
})
|
||||
|
||||
-- craft from dye and any baked clay
|
||||
|
||||
if clay[1] ~= "natural" then
|
||||
minetest.register_craft({
|
||||
output = "bakedclay:" .. clay[1] .. " 8",
|
||||
recipe = {
|
||||
@ -44,6 +46,7 @@ for _, clay in pairs(clay) do
|
||||
{"group:bakedclay", "group:bakedclay", "group:bakedclay"}
|
||||
},
|
||||
})
|
||||
end
|
||||
|
||||
-- register stairsplus stairs if found
|
||||
if stairsplus_mod then
|
||||
@ -78,13 +81,22 @@ for _, clay in pairs(clay) do
|
||||
clay[2] .. " Baked Clay Slab",
|
||||
default.node_sound_stone_defaults())
|
||||
end
|
||||
|
||||
-- register bakedclay for use in technic_cnc mod
|
||||
if techcnc_mod then
|
||||
|
||||
technic_cnc.register_all("bakedclay:" .. clay[1],
|
||||
{cracky = 3, not_in_creative_inventory = 1},
|
||||
{"baked_clay_" .. clay[1] .. ".png"},
|
||||
clay[2] .. " Baked Clay")
|
||||
end
|
||||
end
|
||||
|
||||
-- cook clay block into white baked clay
|
||||
|
||||
minetest.register_craft({
|
||||
type = "cooking",
|
||||
output = "bakedclay:white",
|
||||
output = "bakedclay:natural",
|
||||
recipe = "default:clay",
|
||||
})
|
||||
|
||||
@ -221,18 +233,73 @@ lucky_block:add_blocks({
|
||||
{"dro", {"bakedclay:"}, 10, true},
|
||||
{"fal", {p.."black", p.."blue", p.."brown", p.."cyan", p.."dark_green",
|
||||
p.."dark_grey", p.."green", p.."grey", p.."magenta", p.."orange",
|
||||
p.."pink", p.."red", p.."violet", p.."white", p.."yellow"}, 0},
|
||||
p.."pink", p.."red", p.."violet", p.."white", p.."yellow", p.."natural"}, 0},
|
||||
{"fal", {p.."black", p.."blue", p.."brown", p.."cyan", p.."dark_green",
|
||||
p.."dark_grey", p.."green", p.."grey", p.."magenta", p.."orange",
|
||||
p.."pink", p.."red", p.."violet", p.."white", p.."yellow"}, 0, true},
|
||||
p.."pink", p.."red", p.."violet", p.."white", p.."yellow", p.."natural"}, 0, true},
|
||||
{"dro", {p.."delphinium"}, 5},
|
||||
{"dro", {p.."lazarus"}, 5},
|
||||
{"dro", {p.."mannagrass"}, 5},
|
||||
{"dro", {p.."thistle"}, 6},
|
||||
{"flo", 5, {p.."black", p.."blue", p.."brown", p.."cyan", p.."dark_green",
|
||||
p.."dark_grey", p.."green", p.."grey", p.."magenta", p.."orange",
|
||||
p.."pink", p.."red", p.."violet", p.."white", p.."yellow"}, 2},
|
||||
{"flo", 5, {p.."natural", p.."black", p.."blue", p.."brown", p.."cyan",
|
||||
p.."dark_green", p.."dark_grey", p.."green", p.."grey", p.."magenta",
|
||||
p.."orange", p.."pink", p.."red", p.."violet", p.."white", p.."yellow"}, 2},
|
||||
{"nod", "default:chest", 0, {
|
||||
{name = p.."natural", max = 30},
|
||||
{name = p.."black", max = 30},
|
||||
{name = p.."blue", max = 30},
|
||||
{name = p.."brown", max = 30},
|
||||
{name = p.."cyan", max = 30},
|
||||
{name = p.."dark_green", max = 30},
|
||||
{name = p.."dark_grey", max = 30},
|
||||
{name = p.."green", max = 30},
|
||||
{name = p.."grey", max = 30},
|
||||
{name = p.."magenta", max = 30},
|
||||
{name = p.."orange", max = 30},
|
||||
{name = p.."pink", max = 30},
|
||||
{name = p.."red", max = 30},
|
||||
{name = p.."violet", max = 30},
|
||||
{name = p.."white", max = 30},
|
||||
{name = p.."yellow", max = 30},
|
||||
}},
|
||||
})
|
||||
end
|
||||
|
||||
minetest.log("action", "[bakedclay] loaded.")
|
||||
-- colored clay compatibility
|
||||
if minetest.settings:get_bool("colored_clay_compatibility") == true then
|
||||
|
||||
local cc = {
|
||||
{"black", "black"},
|
||||
{"blue", "blue"},
|
||||
{"bright", "natural"},
|
||||
{"brown", "brown"},
|
||||
{"cyan", "cyan"},
|
||||
{"dark_green", "dark_green"},
|
||||
{"dark_grey", "dark_grey"},
|
||||
{"green", "green"},
|
||||
{"grey", "grey"},
|
||||
{"hardened", "natural"},
|
||||
{"magenta", "magenta"},
|
||||
{"orange", "orange"},
|
||||
{"pink", "pink"},
|
||||
{"red", "red"},
|
||||
{"violet", "violet"},
|
||||
{"white", "white"},
|
||||
{"yellow", "yellow"}
|
||||
}
|
||||
|
||||
for n = 1, #cc do
|
||||
|
||||
local nod1 = "colored_clay:" .. cc[n][1]
|
||||
local nod2 = "bakedclay:" .. cc[n][2]
|
||||
|
||||
minetest.register_alias(nod1, nod2)
|
||||
|
||||
if stairsplus_mod then
|
||||
stairsplus:register_alias_all("colored_clay", cc[n][1], "bakedclay", cc[n][2])
|
||||
end
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
minetest.log("action", "[MOD] Baked Clay loaded.")
|
||||
|
2
settingtypes.txt
Normal file
2
settingtypes.txt
Normal file
@ -0,0 +1,2 @@
|
||||
# Registers compatibility aliases with the older colored_clay mod
|
||||
colored_clay_compatibility (Colored Clay Compatibility) bool false
|
BIN
textures/baked_clay_natural.png
Normal file
BIN
textures/baked_clay_natural.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 296 B |
Reference in New Issue
Block a user