forked from Mirrorlandia_minetest/mesecons
Fix movestones sometimes not starting to move again when they are at the
end of the wire
This commit is contained in:
parent
1df6e5a03b
commit
1ee3b2107d
@ -63,7 +63,10 @@ function mesecon.register_movestone(name, def, is_sticky)
|
|||||||
end
|
end
|
||||||
|
|
||||||
local direction = mesecon.get_movestone_direction(pos)
|
local direction = mesecon.get_movestone_direction(pos)
|
||||||
if not direction then return end
|
if not direction then
|
||||||
|
minetest.set_node(pos, {name = name})
|
||||||
|
return
|
||||||
|
end
|
||||||
local frontpos = vector.add(pos, direction)
|
local frontpos = vector.add(pos, direction)
|
||||||
local backpos = vector.subtract(pos, direction)
|
local backpos = vector.subtract(pos, direction)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user