From 297e5a18d10e816af6442b43bd85a21824de67bd Mon Sep 17 00:00:00 2001 From: Stubbjax Date: Tue, 18 Nov 2025 01:28:07 +1100 Subject: [PATCH] bugfix: Allow immediate resumed construction of buildings if the existing builder dies --- Generals/Code/GameEngine/Source/Common/RTS/ActionManager.cpp | 4 ++++ .../Code/GameEngine/Source/Common/RTS/ActionManager.cpp | 4 ++++ 2 files changed, 8 insertions(+) diff --git a/Generals/Code/GameEngine/Source/Common/RTS/ActionManager.cpp b/Generals/Code/GameEngine/Source/Common/RTS/ActionManager.cpp index d588bc3cf8..bff402a3ac 100644 --- a/Generals/Code/GameEngine/Source/Common/RTS/ActionManager.cpp +++ b/Generals/Code/GameEngine/Source/Common/RTS/ActionManager.cpp @@ -476,7 +476,11 @@ Bool ActionManager::canResumeConstructionOf( const Object *obj, // in the future) // Object *builder = TheGameLogic->findObjectByID( objectBeingConstructed->getBuilderID() ); +#if RETAIL_COMPATIBLE_CRC if( builder ) +#else + if (builder && !builder->isEffectivelyDead()) +#endif { AIUpdateInterface *ai = builder->getAI(); DEBUG_ASSERTCRASH( ai, ("Builder object does not have an AI interface!") ); diff --git a/GeneralsMD/Code/GameEngine/Source/Common/RTS/ActionManager.cpp b/GeneralsMD/Code/GameEngine/Source/Common/RTS/ActionManager.cpp index ee93d3a076..04f2d4818f 100644 --- a/GeneralsMD/Code/GameEngine/Source/Common/RTS/ActionManager.cpp +++ b/GeneralsMD/Code/GameEngine/Source/Common/RTS/ActionManager.cpp @@ -480,7 +480,11 @@ Bool ActionManager::canResumeConstructionOf( const Object *obj, // in the future) // Object *builder = TheGameLogic->findObjectByID( objectBeingConstructed->getBuilderID() ); +#if RETAIL_COMPATIBLE_CRC if( builder ) +#else + if (builder && !builder->isEffectivelyDead()) +#endif { AIUpdateInterface *ai = builder->getAI(); DEBUG_ASSERTCRASH( ai, ("Builder object does not have an AI interface!") );