From d85f95ad10ac89792d940ba6e8dc1c341ff2757a Mon Sep 17 00:00:00 2001 From: orwell96 Date: Mon, 22 May 2017 15:01:38 +0200 Subject: Fix issue #40 Was caused by arrowconn not being set. Instructs user to revisit. --- advtrains/advtrains_luaautomation/atc_rail.lua | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'advtrains') diff --git a/advtrains/advtrains_luaautomation/atc_rail.lua b/advtrains/advtrains_luaautomation/atc_rail.lua index ab84986..3ec82c8 100644 --- a/advtrains/advtrains_luaautomation/atc_rail.lua +++ b/advtrains/advtrains_luaautomation/atc_rail.lua @@ -17,6 +17,10 @@ function r.fire_event(pos, evtdata) local arrowconn = railtbl.arrowconn + if not arrowconn then + atwarn("LuaAutomation ATC interface rail at",ph,": Incomplete Data! Please visit position and click 'Save'!") + return + end --prepare ingame API for ATC. Regenerate each time since pos needs to be known --If no train, then return false. -- cgit v1.2.3