summaryrefslogtreecommitdiff
path: root/durt/nodes/(-4120,13,-5762).lua
blob: 17b5acb25d3aadaeb158c7865df8949fe76c985d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
--[[Arrivals North End]]--
local arrivals_indicator = POS(-4107, 20, -5793)

if not event.train then return end
if atc_arrow then
	if not F.has_rc("DLG_SHUNTER") then return end
	local pre_split_length = train_length()
	local split_fc = split_at_fc("A0B0S0", 7)
	local post_split_length = train_length()


	local add_rc = {
		"DLG_HS_N",
		"DLG_HS_N_AC",
		split_fc ~= "" and "DLG_CLASS_"..split_fc or ""}

	if pre_split_length == post_split_length then --last collection, haven't had to split anything off
		F.indicator(arrivals_indicator, false)
		table.insert(add_rc, "DLG_FINAL_ARRIVAL")
	end
	F.add_rc(add_rc)
	return
end
F.remove_rc_match("DLG_DIR_%S+_N")