summaryrefslogtreecommitdiff
path: root/durt/nodes
diff options
context:
space:
mode:
authorautocommitter <autocommitter@linux-forks.de>2024-04-22 14:57:43 +0200
committerautocommitter <autocommitter@linux-forks.de>2024-04-22 14:57:43 +0200
commitac853fa04d0d8a6489320dfe7dbd60c9371d756b (patch)
treec21c64e8363b38cb46c0bc2f86d8b564b86c95ca /durt/nodes
parent81cc5416a111260d21e63b1029864914ee3709f7 (diff)
downloadluaatc_envs-ac853fa04d0d8a6489320dfe7dbd60c9371d756b.tar.gz
luaatc_envs-ac853fa04d0d8a6489320dfe7dbd60c9371d756b.tar.bz2
luaatc_envs-ac853fa04d0d8a6489320dfe7dbd60c9371d756b.zip
State at 2022-06-19
Diffstat (limited to 'durt/nodes')
-rw-r--r--durt/nodes/(-1512,8,-2613).lua18
-rw-r--r--durt/nodes/(-1515,7,-2625).lua18
2 files changed, 35 insertions, 1 deletions
diff --git a/durt/nodes/(-1512,8,-2613).lua b/durt/nodes/(-1512,8,-2613).lua
new file mode 100644
index 0000000..ecf8060
--- /dev/null
+++ b/durt/nodes/(-1512,8,-2613).lua
@@ -0,0 +1,18 @@
+local ind = POS(-1513,8,-2613)
+local loco_track = POS(-1515,7,-2625)
+
+if event.ext_int then
+ local m = event.message
+ if m.command == "NOTIFY" and m.msg == "S27" then
+ if F.indicator(ind) then return end
+ interrupt_pos(loco_track,"SEND")
+ F.indicator(ind,"on")
+ return
+ end
+end
+
+if event.punch then
+ F.indicator(ind,"on")
+ interrupt_pos(loco_track,"SEND")
+ return
+end \ No newline at end of file
diff --git a/durt/nodes/(-1515,7,-2625).lua b/durt/nodes/(-1515,7,-2625).lua
index 7489acc..d29e92c 100644
--- a/durt/nodes/(-1515,7,-2625).lua
+++ b/durt/nodes/(-1515,7,-2625).lua
@@ -1 +1,17 @@
--- \ No newline at end of file
+local ind = POS(-1513,8,-2613)
+local function send_train()
+ set_rc("FREIGHT S23 TanhX_NBS23toE3 BYARD BY_COLLECT_S27 MGGRatHYARD S27 S27_UNLOAD S27_Overburden BY_RTS S27_EXIT")
+ atc_send("S0WRD2A1S4")
+ set_route(POS(-1504,8,-2622),"Through to Lead")
+ F.indicator(ind,"off")
+end
+if event.ext_int and atc_id then
+ send_train()
+end
+
+if event.train then
+ if F.indicator(ind) then
+ send_train()
+ end
+ return
+end \ No newline at end of file