only reset the scroll index when starting the timer

(not when stopping it)
This commit is contained in:
Vanessa Dannenberg 2018-08-17 10:48:33 -04:00
parent 3df1e6454b
commit 3d5380ef25

@ -59,10 +59,10 @@ end
led_marquee.set_timer = function(pos, timeout)
local timer = minetest.get_node_timer(pos)
local meta = minetest.get_meta(pos)
meta:set_int("index", 1)
timer:stop()
if timeout > 0 then
local meta = minetest.get_meta(pos)
meta:set_int("index", 1)
timer:start(timeout)
end
end