mirror of
https://github.com/1dot13/source.git
synced 2026-07-22 13:40:22 +02:00
Fix: Having lower (and invalid) team size values in Ja2_Options.ini than in the savegame could lead to crashes. I put back the check and warning message for this case. Having higher numbers in the ini is ok.
git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@7590 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
+8
-8
@@ -7498,17 +7498,17 @@ BOOLEAN LoadTacticalStatusFromSavedGame( HWFILE hFile )
|
||||
// gGameExternalOptions.ubGameMaximumNumberOfPlayerMercs + gGameExternalOptions.ubGameMaximumNumberOfPlayerVehicles (defined in OUR_TEAM_SIZE_NO_VEHICLE).
|
||||
// As a result, this check isn't needed anymore, as the number stays fixed (it always stayed fixed, as one couldn't continue the game if one altered it,
|
||||
// which raises the question of why we even checked that...)
|
||||
/*if ((cntFromFile[ idx ] > cntFromIni[ idx ]) || ((cntFromFile[ idx ] < cntFromIni[ idx ]) && (idx == OUR_TEAM)))
|
||||
{
|
||||
CHAR16 errorMessage[512];
|
||||
swprintf(errorMessage, Additional113Text[1], errMsgTxt [ idx ], cntFromFile[ idx ], cntFromIni[ idx ]);
|
||||
DoScreenIndependantMessageBox(errorMessage, MSG_BOX_FLAG_OK, FailedLoadingGameCallBack );
|
||||
return FALSE;
|
||||
}
|
||||
else*/ if (idx != OUR_TEAM && cntFromFile[ idx ] < cntFromIni[ idx ])
|
||||
if (idx != OUR_TEAM && cntFromFile[ idx ] < cntFromIni[ idx ])
|
||||
{
|
||||
needToRejigger = true;
|
||||
}
|
||||
else if (cntFromFile[ idx ] > cntFromIni[ idx ])
|
||||
{
|
||||
CHAR16 errorMessage[512];
|
||||
swprintf(errorMessage, Additional113Text[ADDTEXT_WRONG_TEAM_SIZE], errMsgTxt [ idx ], cntFromFile[ idx ], cntFromIni[ idx ]);
|
||||
DoScreenIndependantMessageBox(errorMessage, MSG_BOX_FLAG_OK, FailedLoadingGameCallBack );
|
||||
return FALSE;
|
||||
}
|
||||
}
|
||||
|
||||
if (needToRejigger) {
|
||||
|
||||
@@ -2529,6 +2529,7 @@ enum
|
||||
{
|
||||
ADDTEXT_16BPP_REQUIRED,
|
||||
ADDTEXT_LOWERRES_REQUIRED,
|
||||
ADDTEXT_WRONG_TEAM_SIZE,
|
||||
ERROR_MAX_MERCSVEHICLES,
|
||||
ERROR_MAX_ENEMIES,
|
||||
ERROR_MAX_CREATURES,
|
||||
|
||||
@@ -7301,7 +7301,7 @@ STR16 Additional113Text[]=
|
||||
{
|
||||
L"Jagged Alliance 2 v1.13 窗口模式需要一个16bpp或更少的颜色深度。",
|
||||
L"Jagged Alliance 2 v1.13 全屏模式选择的分辨率不能高于系统桌面分辨率 (%d x %d)。", //
|
||||
|
||||
L"存盘文件内部读取错误:存盘文件的“%s”数量跟 Ja2_Options.ini 设置的($d)不一致。", //L"Internal error in reading %s slots from Savegame: Number of slots in Savegame (%d) differs from defined slots in ja2_options.ini settings (%d)",
|
||||
// WANNE: Savegame slots validation against INI file
|
||||
L"佣兵 (MAX_NUMBER_PLAYER_MERCS) / 交通工具 (MAX_NUMBER_PLAYER_VEHICLES)",
|
||||
L"敌人 (MAX_NUMBER_ENEMIES_IN_TACTICAL)",
|
||||
|
||||
@@ -7310,7 +7310,7 @@ STR16 Additional113Text[]=
|
||||
{
|
||||
L"Jagged Alliance 2 v1.13 windowed modus vereist een kleurdiepte van 16 bits per pixel.",
|
||||
L"Jagged Alliance 2 v1.13 fullscreen mode requires to run at your desktop resolution (%d x %d) or less.", // TODO.Translate
|
||||
|
||||
L"Internal error in reading %s slots from Savegame: Number of slots in Savegame (%d) differs from defined slots in ja2_options.ini settings (%d)",
|
||||
// TODO.Translate
|
||||
// WANNE: Savegame slots validation against INI file
|
||||
L"Mercenary (MAX_NUMBER_PLAYER_MERCS) / Vehicle (MAX_NUMBER_PLAYER_VEHICLES)",
|
||||
|
||||
@@ -7301,7 +7301,7 @@ STR16 Additional113Text[]=
|
||||
{
|
||||
L"Jagged Alliance 2 v1.13 windowed mode requires a color depth of 16bpp or less.",
|
||||
L"Jagged Alliance 2 v1.13 fullscreen mode requires to run at your desktop resolution (%d x %d) or less.",
|
||||
|
||||
L"Internal error in reading %s slots from Savegame: Number of slots in Savegame (%d) differs from defined slots in ja2_options.ini settings (%d)",
|
||||
// WANNE: Savegame slots validation against INI file
|
||||
L"Mercenary (MAX_NUMBER_PLAYER_MERCS) / Vehicle (MAX_NUMBER_PLAYER_VEHICLES)",
|
||||
L"Enemy (MAX_NUMBER_ENEMIES_IN_TACTICAL)",
|
||||
|
||||
@@ -7305,7 +7305,7 @@ STR16 Additional113Text[]=
|
||||
{
|
||||
L"Jagged Alliance 2 v1.13 mode fenêtré exige une profondeur de couleur de 16 bit ou moins.",
|
||||
L"Jagged Alliance 2 v1.13 mode plein écran nécessite pour fonctionner la résolution du bureau de votre ordinateur (%d x %d) ou moins.",
|
||||
|
||||
L"Erreur interne en lisant %s emplacements depuis la sauvegarde : Le nombre d'emplacements dans la sauvegarde (%d) diffère des emplacements définis dans les paramètres de ja2_options.ini (%d)",
|
||||
// WANNE: Savegame slots validation against INI file
|
||||
L"Mercenaires (MAX_NUMBER_PLAYER_MERCS) / Véhicule (MAX_NUMBER_PLAYER_VEHICLES)",
|
||||
L"Ennemis (MAX_NUMBER_ENEMIES_IN_TACTICAL)",
|
||||
|
||||
@@ -7133,8 +7133,8 @@ STR16 gzFacilityAssignmentStrings[]=
|
||||
STR16 Additional113Text[]=
|
||||
{
|
||||
L"Für die korrekte Arbeit im Fenster-Modus benötigt Jagged Alliance 2 v1.13 16-bit Farbmodus.", //Jagged Alliance 2 v1.13 windowed mode requires a color depth of 16bpp or less.
|
||||
L"Jagged Alliance 2 v1.13 fullscreen mode requires to run at your desktop resolution (%d x %d) or less.", // TODO.Translate
|
||||
|
||||
L"Jagged Alliance 2 v1.13 Vollbildmodus kann nur in Desktop Auflösung (%d x %d) oder niedriger laufen.",
|
||||
L"Interner Fehler beim Auslesen der %s Slots des zu ladenden Spielstandes: Die Anzahl der Slots im Spielstand (%d) unterscheidet sich mit den definierten Slots in der Datei ja2_options.ini (%d)",
|
||||
// WANNE: Savegame slots validation against INI file
|
||||
L"Söldner (MAX_NUMBER_PLAYER_MERCS) / Fahrzeuge (MAX_NUMBER_PLAYER_VEHICLES)",
|
||||
L"Gegner (MAX_NUMBER_ENEMIES_IN_TACTICAL)",
|
||||
|
||||
@@ -7305,7 +7305,7 @@ STR16 Additional113Text[]=
|
||||
{
|
||||
L"Jagged Alliance 2 v1.13 modalità finestra richiede una profondità di colore di 16bpp o meno.",
|
||||
L"Jagged Alliance 2 v1.13 fullscreen mode requires to run at your desktop resolution (%d x %d) or less.", // TODO.Translate
|
||||
|
||||
L"Internal error in reading %s slots from Savegame: Number of slots in Savegame (%d) differs from defined slots in ja2_options.ini settings (%d)",
|
||||
// TODO.Translate
|
||||
// WANNE: Savegame slots validation against INI file
|
||||
L"Mercenary (MAX_NUMBER_PLAYER_MERCS) / Vehicle (MAX_NUMBER_PLAYER_VEHICLES)",
|
||||
|
||||
@@ -7320,7 +7320,7 @@ STR16 Additional113Text[]=
|
||||
{
|
||||
L"Jagged Alliance 2 v1.13 trybie okienkowym wymaga głębi koloru 16-bitowego lub mniej.",
|
||||
L"Jagged Alliance 2 v1.13 fullscreen mode requires to run at your desktop resolution (%d x %d) or less.", // TODO.Translate
|
||||
|
||||
L"Internal error in reading %s slots from Savegame: Number of slots in Savegame (%d) differs from defined slots in ja2_options.ini settings (%d)", // TODO.Translate
|
||||
// TODO.Translate
|
||||
// WANNE: Savegame slots validation against INI file
|
||||
L"Mercenary (MAX_NUMBER_PLAYER_MERCS) / Vehicle (MAX_NUMBER_PLAYER_VEHICLES)",
|
||||
|
||||
@@ -7298,7 +7298,7 @@ STR16 Additional113Text[]=
|
||||
{
|
||||
L"Для запуска Jagged Alliance 2 v1.13 в оконном режиме требуется установить 16-битное качество цветопередачи экрана",
|
||||
L"Jagged Alliance 2 v1.13 полноэкранный режим требует запуска с разрешением как на десктопе (%d x %d) или меньше.",
|
||||
|
||||
L"Internal error in reading %s slots from Savegame: Number of slots in Savegame (%d) differs from defined slots in ja2_options.ini settings (%d)", // TODO.Translate
|
||||
// WANNE: Savegame slots validation against INI file
|
||||
L"Наемники (MAX_NUMBER_PLAYER_MERCS) / Машины (MAX_NUMBER_PLAYER_VEHICLES)",
|
||||
L"Противник (MAX_NUMBER_ENEMIES_IN_TACTICAL)",
|
||||
|
||||
Reference in New Issue
Block a user