summaryrefslogtreecommitdiff
path: root/mesecons_pistons/init.lua
diff options
context:
space:
mode:
authorCarter Kolwey <cheapiephp@gmail.com>2016-12-29 02:34:41 -0600
committerJeija <norrepli@gmail.com>2017-03-04 09:39:40 +0100
commitc7136b72cb9d041d7a49d905c03841373a93b45c (patch)
treebadf9052d5b65279f0e8996583488112f2b5b378 /mesecons_pistons/init.lua
parent774aac6e9059c713f8f9222a7e81bebf2ea49e93 (diff)
Fix crash when pushing a turned-on piston
Diffstat (limited to 'mesecons_pistons/init.lua')
-rw-r--r--mesecons_pistons/init.lua4
1 files changed, 2 insertions, 2 deletions
diff --git a/mesecons_pistons/init.lua b/mesecons_pistons/init.lua
index c8830ac..4ea2dce 100644
--- a/mesecons_pistons/init.lua
+++ b/mesecons_pistons/init.lua
@@ -305,8 +305,8 @@ local piston_up_down_get_stopper = function (node, dir, stack, stackid)
end
local piston_get_stopper = function (node, dir, stack, stackid)
- pistonspec = minetest.registered_nodes[node.name].mesecons_piston
- dir = piston_get_direction(pistonspec.dir, node)
+ local pistonspec = minetest.registered_nodes[node.name].mesecons_piston
+ local dir = pistonspec.dir(node)
local pusherpos = vector.add(stack[stackid].pos, dir)
local pushernode = minetest.get_node(pusherpos)