mirror of
https://github.com/1dot13/source.git
synced 2026-08-19 14:20:30 +02:00
Fix: merc records get erased when restarting the exe.
git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@6233 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
@@ -5950,6 +5950,8 @@ BOOLEAN SaveMercProfiles( HWFILE hFile )
|
|||||||
|
|
||||||
BOOLEAN LoadSavedMercProfiles( HWFILE hFile )
|
BOOLEAN LoadSavedMercProfiles( HWFILE hFile )
|
||||||
{
|
{
|
||||||
|
// Flugente 2013-07-16: This code erases merc records on loading. I am thus commenting it out until someone fixes it.
|
||||||
|
#if 0
|
||||||
UINT16 cnt;
|
UINT16 cnt;
|
||||||
MERCPROFILESTRUCT tempMercProfile;
|
MERCPROFILESTRUCT tempMercProfile;
|
||||||
//Loop through all the profiles to Load
|
//Loop through all the profiles to Load
|
||||||
@@ -5973,6 +5975,22 @@ BOOLEAN LoadSavedMercProfiles( HWFILE hFile )
|
|||||||
return(FALSE);
|
return(FALSE);
|
||||||
}*/
|
}*/
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
UINT16 cnt;
|
||||||
|
//Loop through all the profiles to Load
|
||||||
|
for( cnt=0; cnt< NUM_PROFILES; cnt++)
|
||||||
|
{
|
||||||
|
// At some point after STOMP12_SAVEGAME_DATATYPE_CHANGE, NUM_PROFILES was changed from NUM_PROFILES_v111
|
||||||
|
if(guiCurrentSaveGameVersion < STOMP12_SAVEGAME_DATATYPE_CHANGE && cnt >= NUM_PROFILES_v111)
|
||||||
|
break;
|
||||||
|
// Changed by ADB, rev 1513
|
||||||
|
//if ( !gMercProfiles[cnt].Load(hFile, false) )
|
||||||
|
if ( !gMercProfiles[cnt].Load(hFile, false, false, true) )
|
||||||
|
{
|
||||||
|
return(FALSE);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
return( TRUE );
|
return( TRUE );
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user