summaryrefslogtreecommitdiff
path: root/durt
diff options
context:
space:
mode:
authorautocommitter <autocommitter@linux-forks.de>2024-11-03 00:00:02 +0100
committerautocommitter <autocommitter@linux-forks.de>2024-11-03 00:00:02 +0100
commit34fe0d5ffd14919fdb9495e45cfca294b248eefb (patch)
treeb2bf1918d24e8b8adf4a5188d22bb5d12d9b297c /durt
parent91cc36ecd4e2c68040642dbaf0b0dc46106df61c (diff)
downloadluaatc_envs-34fe0d5ffd14919fdb9495e45cfca294b248eefb.tar.gz
luaatc_envs-34fe0d5ffd14919fdb9495e45cfca294b248eefb.tar.bz2
luaatc_envs-34fe0d5ffd14919fdb9495e45cfca294b248eefb.zip
State at 2024-11-03
Diffstat (limited to 'durt')
-rw-r--r--durt/nodes/(-4125,13,-5731).lua9
-rw-r--r--durt/nodes/(-4181,13,-5787).lua16
-rw-r--r--durt/nodes/(-4197,13,-5781).lua7
-rw-r--r--durt/nodes/(-4197,13,-5784).lua7
-rw-r--r--durt/nodes/(-4197,13,-5787).lua7
-rw-r--r--durt/nodes/(-4197,13,-5790).lua7
-rw-r--r--durt/nodes/(-743,18,2424).lua1
7 files changed, 50 insertions, 4 deletions
diff --git a/durt/nodes/(-4125,13,-5731).lua b/durt/nodes/(-4125,13,-5731).lua
index c3fcc71..3a8d669 100644
--- a/durt/nodes/(-4125,13,-5731).lua
+++ b/durt/nodes/(-4125,13,-5731).lua
@@ -1,4 +1,5 @@
-- Automatic bouncer for headshunts, assuming longer headshunt than train length. Arrow points into headshunt
+-- Modified to bounce all trains. RC Removal still works though
local rev_rc = "DLG_HS_N"
local rm_rc = true
local autocouple = "DLG_HS_N_AC"
@@ -26,10 +27,10 @@ if event.train then
return
end
- if not F.has_rc(rev_rc) then --not our train. disregard
- atc_set_ars_disable(false)
- return
- end
+-- if not F.has_rc(rev_rc) then --not our train. disregard
+-- atc_set_ars_disable(false)
+-- return
+-- end
if rm_rc then F.remove_rc({rev_rc}) end
schedule_in(";01",atc_id)
return
diff --git a/durt/nodes/(-4181,13,-5787).lua b/durt/nodes/(-4181,13,-5787).lua
new file mode 100644
index 0000000..15a77da
--- /dev/null
+++ b/durt/nodes/(-4181,13,-5787).lua
@@ -0,0 +1,16 @@
+if not atc_arrow then return end
+if F.has_rc("COLLECT") then atc_send("B2CplS2") return end
+local options = {
+ {route = "SHUNT Centre", section = "250710"},
+ {route = "SHUNT Right", section = "403524"},
+ {route = "SHUNT Left", section = "779419"},
+ {route = "SHUNT Far Right", section = "810627"},
+}
+for _,v in ipairs(options) do
+ if not section_occupancy(v.section)[1] then
+ set_route(POS(-4183,13,-5788),v.route)
+ atc_set_ars_disable(true)
+ return
+ end
+end
+print("No automatic routes available. Check manually") \ No newline at end of file
diff --git a/durt/nodes/(-4197,13,-5781).lua b/durt/nodes/(-4197,13,-5781).lua
new file mode 100644
index 0000000..4f3ca65
--- /dev/null
+++ b/durt/nodes/(-4197,13,-5781).lua
@@ -0,0 +1,7 @@
+if atc_arrow then
+ if not F.has_rc("COLLECT") then
+ split_off_locomotive("A0B0")
+ end
+ atc_set_ars_disable(false)
+ return
+end \ No newline at end of file
diff --git a/durt/nodes/(-4197,13,-5784).lua b/durt/nodes/(-4197,13,-5784).lua
new file mode 100644
index 0000000..4f3ca65
--- /dev/null
+++ b/durt/nodes/(-4197,13,-5784).lua
@@ -0,0 +1,7 @@
+if atc_arrow then
+ if not F.has_rc("COLLECT") then
+ split_off_locomotive("A0B0")
+ end
+ atc_set_ars_disable(false)
+ return
+end \ No newline at end of file
diff --git a/durt/nodes/(-4197,13,-5787).lua b/durt/nodes/(-4197,13,-5787).lua
new file mode 100644
index 0000000..4f3ca65
--- /dev/null
+++ b/durt/nodes/(-4197,13,-5787).lua
@@ -0,0 +1,7 @@
+if atc_arrow then
+ if not F.has_rc("COLLECT") then
+ split_off_locomotive("A0B0")
+ end
+ atc_set_ars_disable(false)
+ return
+end \ No newline at end of file
diff --git a/durt/nodes/(-4197,13,-5790).lua b/durt/nodes/(-4197,13,-5790).lua
new file mode 100644
index 0000000..4f3ca65
--- /dev/null
+++ b/durt/nodes/(-4197,13,-5790).lua
@@ -0,0 +1,7 @@
+if atc_arrow then
+ if not F.has_rc("COLLECT") then
+ split_off_locomotive("A0B0")
+ end
+ atc_set_ars_disable(false)
+ return
+end \ No newline at end of file
diff --git a/durt/nodes/(-743,18,2424).lua b/durt/nodes/(-743,18,2424).lua
index d922a42..3c5008c 100644
--- a/durt/nodes/(-743,18,2424).lua
+++ b/durt/nodes/(-743,18,2424).lua
@@ -27,6 +27,7 @@ if event.train then
return
end
if rm_rc then F.remove_rc({rev_rc}) end
+ atc_send("S3")
schedule_in(";01",atc_id)
return
end