From f472ace93de69c1b0b1a75e82d2a784499238edb Mon Sep 17 00:00:00 2001 From: Wuzzy Date: Thu, 1 Jun 2017 00:52:14 +0200 Subject: [PATCH] Fix pos typo --- init.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/init.lua b/init.lua index 22b70b9..9275bbe 100644 --- a/init.lua +++ b/init.lua @@ -47,8 +47,8 @@ returnmirror.set_position_inactive = function(itemstack, user, pointed_thing) end end + local pos = user:getpos() if returnmirror.mana_check(user, returnmirror.cost_set) then - local pos = user:getpos() local newitem = ItemStack("returnmirror:mirror_active") newitem:set_metadata(minetest.pos_to_string(pos)) minetest.sound_play( {name="returnmirror_set", gain=1}, {pos=pos, max_hear_distance=12}) @@ -69,8 +69,8 @@ returnmirror.set_position_active = function(itemstack, user, pointed_thing) end end + local pos = user:getpos() if returnmirror.mana_check(user, returnmirror.cost_set) then - local pos = user:getpos() itemstack:set_metadata(minetest.pos_to_string(pos)) minetest.sound_play( {name="returnmirror_set", gain=1}, {pos=pos, max_hear_distance=12}) return itemstack -- 2.11.4.GIT