mirror of
https://github.com/mt-mods/moretrees.git
synced 2024-11-15 15:00:21 +01:00
Player placed fruits have param2 set to 1 (#24)
Player placed fruits have their param2 set to 1 for any mods that need to know if it was grown by sapling or placed by player.
This commit is contained in:
parent
21bdcc360b
commit
393840ba49
|
@ -542,6 +542,11 @@ for i in ipairs(moretrees.treelist) do
|
|||
},
|
||||
groups = {fleshy=3,dig_immediate=3,flammable=2, attached_node=1, leafdecay = 1, leafdecay_drop = 1},
|
||||
sounds = default.node_sound_defaults(),
|
||||
after_place_node = function(pos, placer)
|
||||
if placer:is_player() then
|
||||
minetest.set_node(pos, {name = "moretrees:"..fruit, param2 = 1})
|
||||
end
|
||||
end
|
||||
})
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user