summaryrefslogtreecommitdiff
path: root/mesecons_button/init.lua
diff options
context:
space:
mode:
Diffstat (limited to 'mesecons_button/init.lua')
-rw-r--r--mesecons_button/init.lua2
1 files changed, 1 insertions, 1 deletions
diff --git a/mesecons_button/init.lua b/mesecons_button/init.lua
index beca63e..f4a9198 100644
--- a/mesecons_button/init.lua
+++ b/mesecons_button/init.lua
@@ -3,7 +3,7 @@
-- and then turns off again
mesecon.button_turnoff = function (pos)
- local node = minetest.env:get_node(pos)
+ local node = minetest.get_node(pos)
if node.name=="mesecons_button:button_on" then --has not been dug
minetest.swap_node(pos, {name = "mesecons_button:button_off", param2=node.param2})
minetest.sound_play("mesecons_button_pop", {pos=pos})