Merge pull request #3 from theFox6/patch-1

check if an item is leaves by groups
This commit is contained in:
Joachim Stolberg 2018-06-30 01:35:07 +02:00 committed by GitHub
commit b6325f9078
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -42,7 +42,8 @@ end
local function is_leaves(name)
return tubelib_addons1.FarmingNodes[name] ~= nil and
tubelib_addons1.FarmingNodes[name].leaves == true
(tubelib_addons1.FarmingNodes[name].leaves == true or
minetest.get_node_group(name, "leaves") > 0)
end
local function allow_metadata_inventory_put(pos, listname, index, stack, player)