Fix invalid path invalidation in ARS code

This commit is contained in:
orwell96 2019-01-22 12:43:11 +01:00
parent fab6cc11a8
commit 6c1ca46d6e
1 changed files with 3 additions and 1 deletions

View File

@ -58,6 +58,8 @@ function advtrains.interlocking.ars_check(sigd, train)
local rteid = find_rtematch(tcbs.routes, train)
if rteid then
il.route.update_route(sigd, tcbs, rteid, nil)
--delay routesetting, it should not occur inside train step
-- using after here is OK because that gets called on every path recalculation
minetest.after(0, il.route.update_route, sigd, tcbs, rteid, nil)
end
end