Use minetest.swap_node instead of hacky_swap_node

This commit is contained in:
Novatux
2013-12-08 18:12:44 +01:00
parent ba4c80644e
commit 47a49eccf4
3 changed files with 8 additions and 21 deletions

View File

@ -113,12 +113,8 @@ function screwdriver_handler (itemstack,user,pointed_thing)
end
end
--print (dump(axisdir..", "..rotation))
local meta = minetest.get_meta(pos)
local meta0 = meta:to_table()
node.param2 = n
minetest.set_node(pos,node)
meta = minetest.get_meta(pos)
meta:from_table(meta0)
minetest.swap_node(pos,node)
local item=itemstack:to_table()
local item_wear=tonumber((item["wear"]))
item_wear=item_wear+327