diff options
Diffstat (limited to 'firealarm_pullstation')
-rw-r--r-- | firealarm_pullstation/init.lua | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/firealarm_pullstation/init.lua b/firealarm_pullstation/init.lua index b212ec8..daca96a 100644 --- a/firealarm_pullstation/init.lua +++ b/firealarm_pullstation/init.lua @@ -69,10 +69,9 @@ minetest.register_node(":firealarm:pullstation_on",{ local name = player:get_player_name() minetest.chat_send_player(name,string.format("Position: %d,%d,%d",pos.x,pos.y,pos.z)) end, - on_rightclick = function(pos,node,name) - --local name = minetest.get_player_name(clicker) - if minetest.is_protected(pos,name) and not minetest.check_player_privs(name,"protection_bypass") then - minetest.record_protection_violation(pos,name) + on_rightclick = function(pos,node,clicker) + if minetest.is_protected(pos,clicker) and not minetest.check_player_privs(clicker,"protection_bypass") then + minetest.record_protection_violation(pos,minetest.get_player_name(clicker)) minetest.chat_send_player(name,"You are not authorized to reset this pull station") return end |