aboutsummaryrefslogtreecommitdiff
path: root/advtrains_interlocking/train_related.lua
diff options
context:
space:
mode:
Diffstat (limited to 'advtrains_interlocking/train_related.lua')
-rw-r--r--advtrains_interlocking/train_related.lua6
1 files changed, 5 insertions, 1 deletions
diff --git a/advtrains_interlocking/train_related.lua b/advtrains_interlocking/train_related.lua
index ebeda9f..a92e18f 100644
--- a/advtrains_interlocking/train_related.lua
+++ b/advtrains_interlocking/train_related.lua
@@ -79,10 +79,14 @@ local function setsection(tid, train, ts_id, ts, origin)
-- this is the first route section. clear route status from origin sigd
local tcbs = advtrains.interlocking.db.get_tcbs(ts.route.origin)
if tcbs then
- tcbs.routeset = nil
tcbs.route_committed = nil
tcbs.aspect = nil
advtrains.interlocking.update_signal_aspect(tcbs)
+ if tcbs.route_auto then
+ advtrains.interlocking.route.update_route(ts.route.origin, tcbs)
+ else
+ tcbs.routeset = nil
+ end
end
end
ts.route = nil