From 227a4aaeacff3f1b5c1d42ab6ab729874f652d0b Mon Sep 17 00:00:00 2001 From: orwell96 Date: Mon, 18 May 2020 11:47:22 +0200 Subject: Try to track down why ATC is broken --- advtrains/atc.lua | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'advtrains') diff --git a/advtrains/atc.lua b/advtrains/atc.lua index 0cb6019..a1be084 100644 --- a/advtrains/atc.lua +++ b/advtrains/atc.lua @@ -30,7 +30,7 @@ function atc.train_set_command(train, command, arrow) train.atc_command = command end -function atc.send_command(pos, par_tid) +function atc.send_command(pos, par_tid, train_id_temp_debug) local pts=minetest.pos_to_string(pos) if atc.controllers[pts] then --atprint("Called send_command at "..pts) @@ -72,6 +72,8 @@ function atc.send_command(pos, par_tid) end else atwarn("ATC rail at", pos, ": Sending command failed: There's no train at this position. This seems to be a bug.") + -- huch + advtrains.path_print(advtrains.trains[train_id_temp_debug], atdebug) end else atwarn("ATC rail at", pos, ": Sending command failed: Entry for controller not found.") @@ -154,7 +156,7 @@ advtrains.atc_function = function(def, preset, suffix, rotation) end, advtrains = { on_train_enter = function(pos, train_id) - atc.send_command(pos) + atc.send_command(pos, nil, train_id) end, }, } -- cgit v1.2.3