aboutsummaryrefslogtreecommitdiff
path: root/advtrains_interlocking/train_related.lua
diff options
context:
space:
mode:
authororwell96 <orwell@bleipb.de>2018-08-12 14:25:38 +0200
committerorwell96 <orwell@bleipb.de>2018-08-12 14:25:38 +0200
commitcb56b8b49aa872642e53fc1a82cbdb546d5bfbcb (patch)
treecd11da5a2c3c1bac4c1361458ca754672abbcd30 /advtrains_interlocking/train_related.lua
parent6cdb47edd231da08b32b8258eaa507ff312134cd (diff)
downloadadvtrains-cb56b8b49aa872642e53fc1a82cbdb546d5bfbcb.tar.gz
advtrains-cb56b8b49aa872642e53fc1a82cbdb546d5bfbcb.tar.bz2
advtrains-cb56b8b49aa872642e53fc1a82cbdb546d5bfbcb.zip
Signal aspect handling, make default signals compatible, fix signal digging
Diffstat (limited to 'advtrains_interlocking/train_related.lua')
-rw-r--r--advtrains_interlocking/train_related.lua4
1 files changed, 3 insertions, 1 deletions
diff --git a/advtrains_interlocking/train_related.lua b/advtrains_interlocking/train_related.lua
index c2eeae6..ebeda9f 100644
--- a/advtrains_interlocking/train_related.lua
+++ b/advtrains_interlocking/train_related.lua
@@ -76,11 +76,13 @@ local function setsection(tid, train, ts_id, ts, origin)
-- route setting - clear route state
if ts.route then
if ts.route.first then
+ -- 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
- --TODO callbacks
tcbs.routeset = nil
tcbs.route_committed = nil
+ tcbs.aspect = nil
+ advtrains.interlocking.update_signal_aspect(tcbs)
end
end
ts.route = nil