Make bone meal increase size of tall grass + fern

This commit is contained in:
Wuzzy 2017-03-14 19:35:37 +01:00
parent b2a1d23dd3
commit 05e37defcb
1 changed files with 20 additions and 2 deletions

View File

@ -214,9 +214,27 @@ mcl_dye.apply_bone_meal = function(pointed_thing)
end end
end end
return true return true
else elseif n.name == "mcl_core:tallgrass" then
return false -- Grow tall grass into double tallgrass
local toppos = { x=pos.x, y=pos.y+1, z=pos.z }
local topnode = minetest.get_node(toppos)
if minetest.registered_nodes[topnode.name].buildable_to then
minetest.set_node(pos, { name = "mcl_flowers:double_grass" })
minetest.set_node(toppos, { name = "mcl_flowers:double_grass_top" })
return true
end
elseif n.name == "mcl_flowers:fern" then
-- Grow fern into large fern
local toppos = { x=pos.x, y=pos.y+1, z=pos.z }
local topnode = minetest.get_node(toppos)
if minetest.registered_nodes[topnode.name].buildable_to then
minetest.set_node(pos, { name = "mcl_flowers:double_fern" })
minetest.set_node(toppos, { name = "mcl_flowers:double_fern_top" })
return true
end
end end
return false
end end
minetest.register_craftitem("mcl_dye:white", { minetest.register_craftitem("mcl_dye:white", {