From 0448593744d19223167dcc9488d21b309787d9ee Mon Sep 17 00:00:00 2001 From: Okladnoj Date: Fri, 9 Oct 2026 16:14:51 +0300 Subject: [PATCH] refactor(ai): Correct the temporary state comment in AIStateMachine --- Generals/Code/GameEngine/Include/GameLogic/AIStateMachine.h | 3 ++- GeneralsMD/Code/GameEngine/Include/GameLogic/AIStateMachine.h | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/Generals/Code/GameEngine/Include/GameLogic/AIStateMachine.h b/Generals/Code/GameEngine/Include/GameLogic/AIStateMachine.h index 90a5997fade..373f85dfa08 100644 --- a/Generals/Code/GameEngine/Include/GameLogic/AIStateMachine.h +++ b/Generals/Code/GameEngine/Include/GameLogic/AIStateMachine.h @@ -175,7 +175,8 @@ class AIStateMachine : public StateMachine Squad * m_goalSquad; /** A temporary state to run for a while (usually AI_MOVE_OUT_OF_THE_WAY). - Doesn't clear or reset the state machine, so it goes back to doing what it was doing. jba. */ + Setting it doesn't clear or reset the state machine, so it goes back to doing what it was doing. jba. + Its own update can still clear the state machine; without RETAIL_COMPATIBLE_CRC that also resets the temporary state. */ State *m_temporaryState; UnsignedInt m_temporaryStateFramEnd; ///< Last frame to run m_temporaryState. }; diff --git a/GeneralsMD/Code/GameEngine/Include/GameLogic/AIStateMachine.h b/GeneralsMD/Code/GameEngine/Include/GameLogic/AIStateMachine.h index 43e6c99c4c9..bb238b64e04 100644 --- a/GeneralsMD/Code/GameEngine/Include/GameLogic/AIStateMachine.h +++ b/GeneralsMD/Code/GameEngine/Include/GameLogic/AIStateMachine.h @@ -178,7 +178,8 @@ class AIStateMachine : public StateMachine Squad * m_goalSquad; /** A temporary state to run for a while (usually AI_MOVE_OUT_OF_THE_WAY). - Doesn't clear or reset the state machine, so it goes back to doing what it was doing. jba. */ + Setting it doesn't clear or reset the state machine, so it goes back to doing what it was doing. jba. + Its own update can still clear the state machine; without RETAIL_COMPATIBLE_CRC that also resets the temporary state. */ State *m_temporaryState; UnsignedInt m_temporaryStateFramEnd; ///< Last frame to run m_temporaryState. };