aboutsummaryrefslogtreecommitdiff
path: root/advtrains_interlocking/train_related.lua
diff options
context:
space:
mode:
authororwell96 <orwell@bleipb.de>2018-08-12 13:23:36 +0200
committerorwell96 <orwell@bleipb.de>2018-08-12 13:23:36 +0200
commit6cdb47edd231da08b32b8258eaa507ff312134cd (patch)
tree27811fa34404a022b4ab8d8b9105be1a0b810868 /advtrains_interlocking/train_related.lua
parent0d130bb262f25f089d2633479afa0ecee24256e6 (diff)
downloadadvtrains-6cdb47edd231da08b32b8258eaa507ff312134cd.tar.gz
advtrains-6cdb47edd231da08b32b8258eaa507ff312134cd.tar.bz2
advtrains-6cdb47edd231da08b32b8258eaa507ff312134cd.zip
Add routesetting callbacks.
Now, only the signal aspect setting is still missing
Diffstat (limited to 'advtrains_interlocking/train_related.lua')
-rw-r--r--advtrains_interlocking/train_related.lua3
1 files changed, 3 insertions, 0 deletions
diff --git a/advtrains_interlocking/train_related.lua b/advtrains_interlocking/train_related.lua
index 2dfbd5c..c2eeae6 100644
--- a/advtrains_interlocking/train_related.lua
+++ b/advtrains_interlocking/train_related.lua
@@ -106,6 +106,9 @@ local function freesection(tid, train, ts_id, ts)
end
ts.route_post = nil
end
+ -- This must be delayed, because this code is executed in-between a train step
+ -- TODO use luaautomation timers?
+ minetest.after(0, advtrains.interlocking.route.update_waiting, "ts", ts_id)
end