Reproduction:
Code: Select all
/c
local surface = game.player.surface
local a = surface.create_entity{name = "wooden-chest", position = {0, 0}}
local b = surface.create_entity{name = "wooden-chest", position = {2, 0}}
local render = rendering.draw_line{color = {1, 1, 1}, width = 4, from = a, to = b, surface = surface, gap_length = 1, dash_length = 7}
script.on_event(defines.events.on_tick, function(event)
render.dash_offset = (event.tick % 120) / 120 * 8
end)
