diff options
-rw-r--r-- | Crossroads/nodes/(1769,10,652).lua | 1 | ||||
-rw-r--r-- | Crossroads/nodes/(1772,10,649).lua | 1 | ||||
-rw-r--r-- | Crossroads/nodes/(1843,10,652).lua | 1 | ||||
-rw-r--r-- | Crossroads/nodes/(1844,20,652).lua | 1 | ||||
-rw-r--r-- | Crossroads/nodes/(1846,10,649).lua | 1 | ||||
-rw-r--r-- | auto_yards/nodes/(771,14,-16).lua | 55 | ||||
-rw-r--r-- | auto_yards/nodes/(775,13,-20).lua | 1 | ||||
-rw-r--r-- | auto_yards/nodes/(783,10,-57).lua | 2 | ||||
-rw-r--r-- | auto_yards/nodes/(785,10,40).lua | 2 | ||||
-rw-r--r-- | auto_yards/nodes/(789,10,-31).lua | 1 | ||||
-rw-r--r-- | auto_yards/nodes/(789,10,13).lua | 1 | ||||
-rw-r--r-- | auto_yards/nodes/(792,10,-31).lua | 1 | ||||
-rw-r--r-- | auto_yards/nodes/(792,10,11).lua | 1 | ||||
-rw-r--r-- | auto_yards/nodes/(794,10,31).lua | 46 | ||||
-rw-r--r-- | auto_yards/nodes/(796,10,-39).lua | 1 | ||||
-rw-r--r-- | auto_yards/nodes/(796,10,-54).lua | 46 | ||||
-rw-r--r-- | auto_yards/nodes/(796,10,3).lua | 1 | ||||
-rw-r--r-- | auto_yards/nodes/(799,10,-37).lua | 1 | ||||
-rw-r--r-- | auto_yards/nodes/(799,10,3).lua | 1 |
19 files changed, 160 insertions, 5 deletions
diff --git a/Crossroads/nodes/(1769,10,652).lua b/Crossroads/nodes/(1769,10,652).lua deleted file mode 100644 index 4f300b4..0000000 --- a/Crossroads/nodes/(1769,10,652).lua +++ /dev/null @@ -1 +0,0 @@ -F.stn2gen("crs_7_1","W","R")
\ No newline at end of file diff --git a/Crossroads/nodes/(1772,10,649).lua b/Crossroads/nodes/(1772,10,649).lua deleted file mode 100644 index 9582a24..0000000 --- a/Crossroads/nodes/(1772,10,649).lua +++ /dev/null @@ -1 +0,0 @@ -F.stn2gen("crs_7_1","E","R")
\ No newline at end of file diff --git a/Crossroads/nodes/(1843,10,652).lua b/Crossroads/nodes/(1843,10,652).lua deleted file mode 100644 index 6804b79..0000000 --- a/Crossroads/nodes/(1843,10,652).lua +++ /dev/null @@ -1 +0,0 @@ -F.stn2gen("crs_7_3","W","R")
\ No newline at end of file diff --git a/Crossroads/nodes/(1844,20,652).lua b/Crossroads/nodes/(1844,20,652).lua deleted file mode 100644 index 1b25106..0000000 --- a/Crossroads/nodes/(1844,20,652).lua +++ /dev/null @@ -1 +0,0 @@ -F.stn2gen("crs_7_3", "N", "R")
\ No newline at end of file diff --git a/Crossroads/nodes/(1846,10,649).lua b/Crossroads/nodes/(1846,10,649).lua deleted file mode 100644 index af71d24..0000000 --- a/Crossroads/nodes/(1846,10,649).lua +++ /dev/null @@ -1 +0,0 @@ -F.stn2gen("crs_7_3","E","R")
\ No newline at end of file diff --git a/auto_yards/nodes/(771,14,-16).lua b/auto_yards/nodes/(771,14,-16).lua new file mode 100644 index 0000000..447dce1 --- /dev/null +++ b/auto_yards/nodes/(771,14,-16).lua @@ -0,0 +1,55 @@ +--leekston collection controller +local up_dir = "North" +local down_dir = "South" +local up_dir_indicator = POS(771,13,-14) +local down_dir_indicator = POS(771,13,-15) +local exit_indicator_pos = POS(771,13,-18) + +local userlist = { + "Maverick2797", + "mary4" +} + +if event.ext_int then --to be pinged by the departing LHF train only + local dir + if F.indicator(exit_indicator_pos) then + F.indicator(up_dir_indicator, false) + dir = up_dir + else + F.indicator(down_dir_indicator, false) + dir = down_dir + end + digiline_send("lcd",string.format("%s | Train collected and departed %sbound",rwt.to_string(rwt.now()), dir)) + return +end + +--confirm user is actually allowed to use this system +local permitted_user = false +for _,name in pairs(userlist) do + if name == event.name then + permitted_user = name + break + end +end +if not permitted_user then + digiline_send("lcd","User is not permitted to use this. Contact a moderator") + return +end + +local dir = "" +--cycle through the departure options +if F.indicator(up_dir_indicator) then + F.indicator(up_dir_indicator, false) + F.indicator(down_dir_indicator, true) + dir = down_dir.."bound" +elseif F.indicator(down_dir_indicator) then + F.indicator(up_dir_indicator, false) + F.indicator(down_dir_indicator, false) + dir = "Disabled" +else + F.indicator(up_dir_indicator, true) + F.indicator(down_dir_indicator, false) + dir = up_dir.."bound" +end + +digiline_send("lcd",string.format("%s\nCollection %s.\nUser %s", rwt.to_string(rwt.now()), dir, event.name))
\ No newline at end of file diff --git a/auto_yards/nodes/(775,13,-20).lua b/auto_yards/nodes/(775,13,-20).lua new file mode 100644 index 0000000..8cd2bb9 --- /dev/null +++ b/auto_yards/nodes/(775,13,-20).lua @@ -0,0 +1 @@ +interrupt_pos(POS(771,14,-16))
\ No newline at end of file diff --git a/auto_yards/nodes/(783,10,-57).lua b/auto_yards/nodes/(783,10,-57).lua new file mode 100644 index 0000000..e56cc30 --- /dev/null +++ b/auto_yards/nodes/(783,10,-57).lua @@ -0,0 +1,2 @@ +if not F.has_rc("LEEK_EXIT") then return end +-- remove any extra yard RCs here
\ No newline at end of file diff --git a/auto_yards/nodes/(785,10,40).lua b/auto_yards/nodes/(785,10,40).lua new file mode 100644 index 0000000..e56cc30 --- /dev/null +++ b/auto_yards/nodes/(785,10,40).lua @@ -0,0 +1,2 @@ +if not F.has_rc("LEEK_EXIT") then return end +-- remove any extra yard RCs here
\ No newline at end of file diff --git a/auto_yards/nodes/(789,10,-31).lua b/auto_yards/nodes/(789,10,-31).lua new file mode 100644 index 0000000..e877483 --- /dev/null +++ b/auto_yards/nodes/(789,10,-31).lua @@ -0,0 +1 @@ +-- arrival, dir = false
\ No newline at end of file diff --git a/auto_yards/nodes/(789,10,13).lua b/auto_yards/nodes/(789,10,13).lua new file mode 100644 index 0000000..4d16159 --- /dev/null +++ b/auto_yards/nodes/(789,10,13).lua @@ -0,0 +1 @@ +-- arrival, dir = true
\ No newline at end of file diff --git a/auto_yards/nodes/(792,10,-31).lua b/auto_yards/nodes/(792,10,-31).lua new file mode 100644 index 0000000..fa98cc9 --- /dev/null +++ b/auto_yards/nodes/(792,10,-31).lua @@ -0,0 +1 @@ +-- continue onwards
\ No newline at end of file diff --git a/auto_yards/nodes/(792,10,11).lua b/auto_yards/nodes/(792,10,11).lua new file mode 100644 index 0000000..ece3c16 --- /dev/null +++ b/auto_yards/nodes/(792,10,11).lua @@ -0,0 +1 @@ +-- continue northwards
\ No newline at end of file diff --git a/auto_yards/nodes/(794,10,31).lua b/auto_yards/nodes/(794,10,31).lua new file mode 100644 index 0000000..f7e80a9 --- /dev/null +++ b/auto_yards/nodes/(794,10,31).lua @@ -0,0 +1,46 @@ +-- Automatic bouncer for headshunts, assuming longer headshunt than train length. Arrow points into headshunt +local rev_rc = "LEEK_HS_north" +local rm_rc = true +local autocouple = nil +local rm_cpl_rc = true + +__approach_callback_mode = 1 + +if event.approach and not event.has_entered then + if not F.has_rc(rev_rc) then return end + atc_set_lzb_tsr(3) + atc_set_ars_disable(true) + return +end + +if event.train then + if not atc_arrow then --train has bounced + if F.has_rc(autocouple) then + atc_send("CplS0WD2S1") + if rm_cpl_rc then F.remove_rc({autocouple}) end + end + return + end + + if not F.has_rc(rev_rc) then --not our train. disregard + atc_set_ars_disable(false) + return + end + atc_send("S3") + if rm_rc then F.remove_rc({rev_rc}) end + schedule_in(";01",atc_id) + return +end + +if event.schedule then + if not atc_id then --bounce the train that just passed + atc_send_to_train(event.msg,"B0WRD1A1S3") + else + if atc_id == event.msg then --train hasn't fully passed yet, wait a bit longer + schedule_in(";01",atc_id) + else -- somehow another train crossed the controller before the first one returned. Unlikely but possible + atc_send_to_train(event.msg,"BBOL") + atc_send("BBOL") + end + end +end
\ No newline at end of file diff --git a/auto_yards/nodes/(796,10,-39).lua b/auto_yards/nodes/(796,10,-39).lua new file mode 100644 index 0000000..265c211 --- /dev/null +++ b/auto_yards/nodes/(796,10,-39).lua @@ -0,0 +1 @@ +-- collection track (controlled by tower UI)
\ No newline at end of file diff --git a/auto_yards/nodes/(796,10,-54).lua b/auto_yards/nodes/(796,10,-54).lua new file mode 100644 index 0000000..a3f3e42 --- /dev/null +++ b/auto_yards/nodes/(796,10,-54).lua @@ -0,0 +1,46 @@ +-- Automatic bouncer for headshunts, assuming longer headshunt than train length. Arrow points into headshunt +local rev_rc = "LEEK_HS_south" +local rm_rc = true +local autocouple = nil +local rm_cpl_rc = true + +__approach_callback_mode = 1 + +if event.approach and not event.has_entered then + if not F.has_rc(rev_rc) then return end + atc_set_lzb_tsr(3) + atc_set_ars_disable(true) + return +end + +if event.train then + if not atc_arrow then --train has bounced + if F.has_rc(autocouple) then + atc_send("CplS0WD2S1") + if rm_cpl_rc then F.remove_rc({autocouple}) end + end + return + end + + if not F.has_rc(rev_rc) then --not our train. disregard + atc_set_ars_disable(false) + return + end + atc_send("S3") + if rm_rc then F.remove_rc({rev_rc}) end + schedule_in(";01",atc_id) + return +end + +if event.schedule then + if not atc_id then --bounce the train that just passed + atc_send_to_train(event.msg,"B0WRD1A1S3") + else + if atc_id == event.msg then --train hasn't fully passed yet, wait a bit longer + schedule_in(";01",atc_id) + else -- somehow another train crossed the controller before the first one returned. Unlikely but possible + atc_send_to_train(event.msg,"BBOL") + atc_send("BBOL") + end + end +end
\ No newline at end of file diff --git a/auto_yards/nodes/(796,10,3).lua b/auto_yards/nodes/(796,10,3).lua new file mode 100644 index 0000000..265c211 --- /dev/null +++ b/auto_yards/nodes/(796,10,3).lua @@ -0,0 +1 @@ +-- collection track (controlled by tower UI)
\ No newline at end of file diff --git a/auto_yards/nodes/(799,10,-37).lua b/auto_yards/nodes/(799,10,-37).lua new file mode 100644 index 0000000..1db4581 --- /dev/null +++ b/auto_yards/nodes/(799,10,-37).lua @@ -0,0 +1 @@ +-- drop off here from LFH
\ No newline at end of file diff --git a/auto_yards/nodes/(799,10,3).lua b/auto_yards/nodes/(799,10,3).lua new file mode 100644 index 0000000..1db4581 --- /dev/null +++ b/auto_yards/nodes/(799,10,3).lua @@ -0,0 +1 @@ +-- drop off here from LFH
\ No newline at end of file |