summaryrefslogtreecommitdiff
path: root/durt/nodes/(-2077,3,788).lua
blob: 669248afc2e114cc00514a7232de33d4d64c2e6c (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
25
local dir_indicator = POS(-2079,7,803)
local this_dir = false

__approach_callback_mode = 2
if event.approach and not event.has_entered then
	atc_set_lzb_tsr(2)
	atc_set_ars_disable(true)
	return
end

if event.train then
	if not atc_arrow then
		if F.dir(dir_indicator) == this_dir then
			atc_send("B1")
		end -- no else, should never happen
	else
		if F.has_rc("ARC_LOAD_load") and (F.dir(dir_indicator) == not this_dir) then
			F.remove_rc({"ARC_LOAD_load"})
			F.add_rc("ARC_LOAD_rejoin")
			atc_send("B0WRD1S2")
		else
			atc_send("A1S2")
		end
	end
end