summaryrefslogtreecommitdiff
path: root/durt/nodes/(-1515,7,-2625).lua
diff options
context:
space:
mode:
authorautocommitter <autocommitter@linux-forks.de>2024-04-22 14:58:03 +0200
committerautocommitter <autocommitter@linux-forks.de>2024-04-22 14:58:03 +0200
commit7b3ac07f3f9b9d92582aceb74050215a36646bc5 (patch)
tree3eda9d8e0a85b9d0daa53dd2887d154d9e0ef172 /durt/nodes/(-1515,7,-2625).lua
parentefa99edcbd392873d8ed78eae7760f8c0b23dc45 (diff)
downloadluaatc_envs-7b3ac07f3f9b9d92582aceb74050215a36646bc5.tar.gz
luaatc_envs-7b3ac07f3f9b9d92582aceb74050215a36646bc5.tar.bz2
luaatc_envs-7b3ac07f3f9b9d92582aceb74050215a36646bc5.zip
State at 2023-03-26
Diffstat (limited to 'durt/nodes/(-1515,7,-2625).lua')
-rw-r--r--durt/nodes/(-1515,7,-2625).lua22
1 files changed, 17 insertions, 5 deletions
diff --git a/durt/nodes/(-1515,7,-2625).lua b/durt/nodes/(-1515,7,-2625).lua
index c12db21..2fd2155 100644
--- a/durt/nodes/(-1515,7,-2625).lua
+++ b/durt/nodes/(-1515,7,-2625).lua
@@ -1,17 +1,29 @@
+local notification_id = "S27"
local ind = POS(-1513,8,-2613)
+local print_notification = true
local function send_train()
- set_rc("FREIGHT S23 TanhX_NBS23toE3 BYARD BY_COLLECT_S27 MGGRatHYARD S27 S27_UNLOAD S27_Overburden BY_RTS S27_EXIT")
+ set_rc("FREIGHT S23 ARCAUTO ARC_RTS ARC_COLLECT_S27 ARC_AUTO_S23S TanhX_SBS23toE3 MGGRatHYARD S27 S27_UNLOAD S27_Overburden S27_EXIT")
atc_send("S0WRD2A1S4")
- set_route(POS(-1504,8,-2622),"Through to Lead")
F.indicator(ind,false)
end
-if event.ext_int and atc_id then
- send_train()
+if event.ext_int then
+ if event.message == "notify" then
+ if print_notification then print(rwt.to_string(rwt.now()) .. " "..notification_id.." RX Notification") end
+ if F.indicator(ind) then return end
+ if atc_id then
+ send_train()
+ return
+ else
+ F.indicator(ind,true)
+ return
+ end
+ end
end
-
if event.train then
if F.indicator(ind) then
send_train()
+ return
end
+ atc_send("B0")
return
end \ No newline at end of file