aboutsummaryrefslogtreecommitdiff
path: root/advtrains/occupation.lua
diff options
context:
space:
mode:
Diffstat (limited to 'advtrains/occupation.lua')
-rw-r--r--advtrains/occupation.lua4
1 files changed, 2 insertions, 2 deletions
diff --git a/advtrains/occupation.lua b/advtrains/occupation.lua
index 7af4a3d..e72d668 100644
--- a/advtrains/occupation.lua
+++ b/advtrains/occupation.lua
@@ -227,14 +227,14 @@ function handle_chg(t, pos, train_id, old, new)
if #blocking > 0 then
-- the aware trains should brake
for _, ix in ipairs(aware) do
- atc.train_set_command(t[ix], "B2")
+ advtrains.atc.train_set_command(t[ix], "B2")
end
if #blocking > 1 then
-- not good, 2 trains interfered with their blocking zones
-- make them brake too
local txt = {}
for _, ix in ipairs(blocking) do
- atc.train_set_command(t[ix], "B2")
+ advtrains.atc.train_set_command(t[ix], "B2")
txt[#txt+1] = t[ix]
end
atwarn("Trains",table.concat(txt, ","), "interfered with their blocking zones, braking...")