Zero Hour rebuilt from EA's source: x64, Direct3D 11, VS2022/CMake, ~60 original bugs fixed, an AI that builds a base. Bring your own game.
C++ cmakecnccommand-and-conquercppdirectx11game-enginegame-preservationgeneralsrtssage-enginex64zero-hour
fix(gameclient): a power's shortcut icon is found in any promotion slot
Olcay Seyganed094c28f5f1
diff --git a/GeneralsMD/Code/GameEngine/Source/GameClient/GUI/ControlBar/ControlBar.cpp b/GeneralsMD/Code/GameEngine/Source/GameClient/GUI/ControlBar/ControlBar.cppindex 301fbfcac..806ff03be 100644--- a/GeneralsMD/Code/GameEngine/Source/GameClient/GUI/ControlBar/ControlBar.cpp+++ b/GeneralsMD/Code/GameEngine/Source/GameClient/GUI/ControlBar/ControlBar.cpp@@ -5635,7 +5635,7 @@ void ControlBar::populateSpecialPowerShortcut( Player *player)}Bool found = FALSE;- for( i = 0; !found && i < MAX_PURCHASE_SCIENCE_RANK_1; i++ )+ for( i = 0; !found && i < MAX_COMMANDS_PER_SET; i++ ){const CommandButton *command = commandSet1->getCommandButton( i );if( command && command->getCommandType() == GUI_COMMAND_PURCHASE_SCIENCE )@@ -5654,7 +5654,7 @@ void ControlBar::populateSpecialPowerShortcut( Player *player)}}}- for( i = 0; !found && i < MAX_PURCHASE_SCIENCE_RANK_3; i++ )+ for( i = 0; !found && i < MAX_COMMANDS_PER_SET; i++ ){const CommandButton *command = commandSet3->getCommandButton( i );if( command && command->getCommandType() == GUI_COMMAND_PURCHASE_SCIENCE )@@ -5673,7 +5673,7 @@ void ControlBar::populateSpecialPowerShortcut( Player *player)}}}- for( i = 0; !found && i < MAX_PURCHASE_SCIENCE_RANK_8; i++ )+ for( i = 0; !found && i < MAX_COMMANDS_PER_SET; i++ ){const CommandButton *command = commandSet8->getCommandButton( i );if( command && command->getCommandType() == GUI_COMMAND_PURCHASE_SCIENCE )diff --git a/GeneralsMD/Code/GameEngine/Source/GameClient/GUI/ControlBar/ControlBarCommand.cpp b/GeneralsMD/Code/GameEngine/Source/GameClient/GUI/ControlBar/ControlBarCommand.cppindex fc6f1e162..45137c835 100644--- a/GeneralsMD/Code/GameEngine/Source/GameClient/GUI/ControlBar/ControlBarCommand.cpp+++ b/GeneralsMD/Code/GameEngine/Source/GameClient/GUI/ControlBar/ControlBarCommand.cpp@@ -500,7 +500,7 @@ void ControlBar::populateCommand( Object *obj )}Bool found = FALSE;- for( i = 0; !found && i < MAX_PURCHASE_SCIENCE_RANK_1; i++ )+ for( i = 0; !found && i < MAX_COMMANDS_PER_SET; i++ ){const CommandButton *command = commandSet1->getCommandButton( i );if( command && command->getCommandType() == GUI_COMMAND_PURCHASE_SCIENCE )@@ -519,7 +519,7 @@ void ControlBar::populateCommand( Object *obj )}}}- for( i = 0; !found && i < MAX_PURCHASE_SCIENCE_RANK_3; i++ )+ for( i = 0; !found && i < MAX_COMMANDS_PER_SET; i++ ){const CommandButton *command = commandSet3->getCommandButton( i );if( command && command->getCommandType() == GUI_COMMAND_PURCHASE_SCIENCE )@@ -538,7 +538,7 @@ void ControlBar::populateCommand( Object *obj )}}}- for( i = 0; !found && i < MAX_PURCHASE_SCIENCE_RANK_8; i++ )+ for( i = 0; !found && i < MAX_COMMANDS_PER_SET; i++ ){const CommandButton *command = commandSet8->getCommandButton( i );if( command && command->getCommandType() == GUI_COMMAND_PURCHASE_SCIENCE )