Skip to content

Commit 03b9ae8

Browse files
authored
bugfix(aiupdate): Repairing Chinooks and Helixes no longer take off after evacuating all passengers (#1762)
1 parent 1f2c1a3 commit 03b9ae8

File tree

2 files changed

+12
-0
lines changed

2 files changed

+12
-0
lines changed

Generals/Code/GameEngine/Source/GameLogic/Object/Update/AIUpdate/ChinookAIUpdate.cpp

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1123,8 +1123,14 @@ void ChinookAIUpdate::privateCombatDrop( Object* target, const Coord3D& pos, Com
11231123
//-------------------------------------------------------------------------------------------------
11241124
void ChinookAIUpdate::aiDoCommand(const AICommandParms* parms)
11251125
{
1126+
#if RETAIL_COMPATIBLE_CRC
11261127
// this gets reset every time a command is issued.
11271128
setAirfieldForHealing(INVALID_ID);
1129+
#else
1130+
// TheSuperHackers @bugfix Stubbjax 31/10/2025 Don't leave healing state for evacuation commands.
1131+
if (parms->m_cmd != AICMD_EVACUATE && parms->m_cmd != AICMD_EXIT)
1132+
setAirfieldForHealing(INVALID_ID);
1133+
#endif
11281134

11291135
if (!isAllowedToRespondToAiCommands(parms))
11301136
return;

GeneralsMD/Code/GameEngine/Source/GameLogic/Object/Update/AIUpdate/ChinookAIUpdate.cpp

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1258,8 +1258,14 @@ void ChinookAIUpdate::privateCombatDrop( Object* target, const Coord3D& pos, Com
12581258
//-------------------------------------------------------------------------------------------------
12591259
void ChinookAIUpdate::aiDoCommand(const AICommandParms* parms)
12601260
{
1261+
#if RETAIL_COMPATIBLE_CRC
12611262
// this gets reset every time a command is issued.
12621263
setAirfieldForHealing(INVALID_ID);
1264+
#else
1265+
// TheSuperHackers @bugfix Stubbjax 31/10/2025 Don't leave healing state for evacuation commands.
1266+
if (parms->m_cmd != AICMD_EVACUATE && parms->m_cmd != AICMD_EXIT)
1267+
setAirfieldForHealing(INVALID_ID);
1268+
#endif
12631269

12641270
if (!isAllowedToRespondToAiCommands(parms))
12651271
return;

0 commit comments

Comments
 (0)