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): load the 1.04 Patch.str string overlay
Olcay Seyganbec50d6c4a7d
diff --git a/GeneralsMD/Code/GameEngine/Source/GameClient/GameText.cpp b/GeneralsMD/Code/GameEngine/Source/GameClient/GameText.cppindex 8d086b87d..a4a09b4a1 100644--- a/GeneralsMD/Code/GameEngine/Source/GameClient/GameText.cpp+++ b/GeneralsMD/Code/GameEngine/Source/GameClient/GameText.cpp@@ -327,9 +327,20 @@ void GameTextManager::init( void )return;}+ // The 1.04 patch ships its two new menu strings as a text overlay - Data\Patch.str+ // inside PatchData.big - instead of an updated CSF. The retail 1.04 exe reads it;+ // this source drop predates that, so without it the patched MainMenu.wnd shows+ // MISSING: 'GUI:CustomMission'. Parse it into the tail of the string table.+ Int patchCount = 0;+ Int mainCount = m_textCount;+ if ( !getStringCount( "Data\\Patch.str", patchCount ) )+ {+ patchCount = 0;+ }+//Allocate StringInfo Array- m_stringInfo = NEW StringInfo[m_textCount];+ m_stringInfo = NEW StringInfo[m_textCount + patchCount];if( m_stringInfo == NULL ){@@ -354,6 +365,20 @@ void GameTextManager::init( void )}}+ if ( patchCount > 0 )+ {+ // parseStringFile fills m_stringInfo from index 0, so point it at the tail+ // for the overlay and restore afterwards.+ StringInfo *wholeTable = m_stringInfo;+ m_stringInfo += mainCount;+ Bool patchOk = parseStringFile( "Data\\Patch.str" );+ m_stringInfo = wholeTable;+ if ( patchOk )+ {+ m_textCount = mainCount + patchCount;+ }+ }+m_stringLUT = NEW StringLookUp[m_textCount];StringLookUp *lut = m_stringLUT;