From 3cdaac6387e417df0897e17a0eadea9cda21f64f Mon Sep 17 00:00:00 2001 From: firleju Date: Wed, 9 Mar 2016 21:56:20 +0100 Subject: [PATCH] Repair crash when changing cabs by AI when player is in cab (debugmode). --- Train.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/Train.cpp b/Train.cpp index 2112e865..d44357da 100644 --- a/Train.cpp +++ b/Train.cpp @@ -4391,8 +4391,9 @@ bool TTrain::Update() */ //----------------- - if ((!FreeFlyModeFlag) && (!DynamicObject->Mechanik->AIControllFlag)) - { + if ((!FreeFlyModeFlag) && + (!(DynamicObject->Mechanik ? DynamicObject->Mechanik->AIControllFlag : false))) + { if (Console::Pressed(Global::Keys[k_Releaser])) // yB: odluzniacz caly // czas trzymany, warunki // powinny byc takie same,