Skip to content
Snippets Groups Projects
Commit 9ff80126 authored by PilzAdam's avatar PilzAdam
Browse files

Return an ItemStack in minetest.item_place() if nodes' on rightclick doesnt return it

parent 8d4b7682
No related branches found
No related tags found
No related merge requests found
......@@ -244,7 +244,7 @@ function minetest.item_place(itemstack, placer, pointed_thing)
local n = minetest.env:get_node(pointed_thing.under)
local nn = n.name
if minetest.registered_nodes[nn] and minetest.registered_nodes[nn].on_rightclick then
return minetest.registered_nodes[nn].on_rightclick(pointed_thing.under, n, placer, itemstack)
return minetest.registered_nodes[nn].on_rightclick(pointed_thing.under, n, placer, itemstack) or itemstack
end
end
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment