Always return the leftover ItemStack for on_place and on_rightclick

This commit is contained in:
Tim
2016-07-01 22:43:02 +02:00
committed by paramat
parent e38099225c
commit 71c7e21669
6 changed files with 20 additions and 15 deletions

View File

@ -224,10 +224,10 @@ minetest.register_craftitem("boats:boat", {
on_place = function(itemstack, placer, pointed_thing)
if pointed_thing.type ~= "node" then
return
return itemstack
end
if not is_water(pointed_thing.under) then
return
return itemstack
end
pointed_thing.under.y = pointed_thing.under.y + 0.5
minetest.add_entity(pointed_thing.under, "boats:boat")