mirror of
https://git.minetest.land/Mineclonia/Mineclonia.git
synced 2024-11-24 18:55:09 +00:00
Fix item frames sometimes destroying placed items
This commit is contained in:
parent
91d04bb2c0
commit
b8b9857957
1 changed files with 2 additions and 3 deletions
|
@ -112,12 +112,11 @@ minetest.register_node("itemframes:frame",{
|
||||||
local meta = minetest.get_meta(pos)
|
local meta = minetest.get_meta(pos)
|
||||||
if clicker:get_player_name() == meta:get_string("owner") then
|
if clicker:get_player_name() == meta:get_string("owner") then
|
||||||
drop_item(pos,node)
|
drop_item(pos,node)
|
||||||
local s = itemstack
|
meta:set_string("item",itemstack:to_string())
|
||||||
|
update_item(pos,node)
|
||||||
if not minetest.setting_getbool("creative_mode") then
|
if not minetest.setting_getbool("creative_mode") then
|
||||||
itemstack:take_item()
|
itemstack:take_item()
|
||||||
end
|
end
|
||||||
meta:set_string("item",s:to_string())
|
|
||||||
update_item(pos,node)
|
|
||||||
end
|
end
|
||||||
return itemstack
|
return itemstack
|
||||||
end,
|
end,
|
||||||
|
|
Loading…
Reference in a new issue