- option menu descriptions changed

- bug fix: CTD in SendReinforcementsForGarrison. Happens in strategic map when a (maybe too large?) group of enemies wants to retake a city sector.

git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@325 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
lalien
2006-07-02 22:44:43 +00:00
parent 645598f3d5
commit d091bb09f1
6 changed files with 12 additions and 12 deletions
+1 -1
View File
@@ -23,7 +23,7 @@ INT16 zVersionLabel[256] = { L"Beta v. 0.98" };
#else #else
//RELEASE BUILD VERSION //RELEASE BUILD VERSION
INT16 zVersionLabel[256] = { L"Release v1.13.321" }; INT16 zVersionLabel[256] = { L"Release v1.13.325" };
#endif #endif
+2 -2
View File
@@ -43,7 +43,7 @@
<Tool <Tool
Name="VCLinkerTool" Name="VCLinkerTool"
AdditionalDependencies="libexpatMT.lib mss32.lib winmm.lib smackw32.lib fmodvc.lib" AdditionalDependencies="libexpatMT.lib mss32.lib winmm.lib smackw32.lib fmodvc.lib"
OutputFile="C:\games\Jagged Alliance 2 DE\ja2_debug_v1.13.321_2006_07_02.exe" OutputFile="C:\games\Jagged Alliance 2 DE\ja2_debug_v1.13.325_2006_07_02.exe"
LinkIncremental="2" LinkIncremental="2"
SuppressStartupBanner="TRUE" SuppressStartupBanner="TRUE"
AdditionalLibraryDirectories=".\..\..\Standard Gaming Platform\" AdditionalLibraryDirectories=".\..\..\Standard Gaming Platform\"
@@ -546,7 +546,7 @@
<Tool <Tool
Name="VCLinkerTool" Name="VCLinkerTool"
AdditionalDependencies="libexpatMT.lib winmm.lib smackw32.lib mss32.lib fmodvc.lib" AdditionalDependencies="libexpatMT.lib winmm.lib smackw32.lib mss32.lib fmodvc.lib"
OutputFile="C:\Games\Jagged Alliance 2 v1.13\ja2_release_v1.13.321_2006_07_02.exe" OutputFile="C:\Games\Jagged Alliance 2 v1.13\ja2_release_v1.13.325_2006_07_02.exe"
LinkIncremental="1" LinkIncremental="1"
SuppressStartupBanner="TRUE" SuppressStartupBanner="TRUE"
AdditionalLibraryDirectories=".\..\..\Standard Gaming Platform\" AdditionalLibraryDirectories=".\..\..\Standard Gaming Platform\"
+6 -6
View File
@@ -2701,12 +2701,12 @@ void SendReinforcementsForGarrison( INT32 iDstGarrisonID, UINT16 usDefencePoints
//The force is strong enough to be able to take the sector. //The force is strong enough to be able to take the sector.
gubGarrisonReinforcementsDenied[ iDstGarrisonID ] = 0; gubGarrisonReinforcementsDenied[ iDstGarrisonID ] = 0;
} }
//The chance she will send them is related with the strength difference between the //The chance she will send them is related with the strength difference between the
//player's force and the queen's. //player's force and the queen's.
if( ubNumExtraReinforcements && fLimitMaxTroopsAllowable && iReinforcementsApproved == iMaxReinforcementsAllowed ) if( ubNumExtraReinforcements && fLimitMaxTroopsAllowable && iReinforcementsApproved == iMaxReinforcementsAllowed )
{ {
iChance = (iReinforcementsApproved + ubNumExtraReinforcements) * 100 / usDefencePoints; iChance = (iReinforcementsApproved + ubNumExtraReinforcements) * 100 / max(usDefencePoints, 1); // lal bugfix: max 1 added to prevent division by 0
if( !Chance( iChance ) ) if( !Chance( iChance ) )
{ {
ValidateWeights( 13 ); ValidateWeights( 13 );
@@ -2789,8 +2789,8 @@ void SendReinforcementsForGarrison( INT32 iDstGarrisonID, UINT16 usDefencePoints
//The chance she will send them is related with the strength difference between the //The chance she will send them is related with the strength difference between the
//player's force and the queen's. //player's force and the queen's.
if( iReinforcementsApproved + ubNumExtraReinforcements == iMaxReinforcementsAllowed && usDefencePoints ) if( iReinforcementsApproved + ubNumExtraReinforcements == iMaxReinforcementsAllowed && usDefencePoints )
{ {
iChance = (iReinforcementsApproved + ubNumExtraReinforcements) * 100 / usDefencePoints; iChance = (iReinforcementsApproved + ubNumExtraReinforcements) * 100 / max(usDefencePoints, 1); // lal bugfix: max 1 added to prevent division by 0
if( !Chance( iChance ) ) if( !Chance( iChance ) )
{ {
ValidateWeights( 18 ); ValidateWeights( 18 );
@@ -3946,9 +3946,9 @@ void ExecuteStrategicAIAction( UINT16 usActionCode, INT16 sSectorX, INT16 sSecto
GROUP *pGroup, *pGroup0, *pGroup1, *pGroup2, *pGroup3, *pPendingGroup = NULL; GROUP *pGroup, *pGroup0, *pGroup1, *pGroup2, *pGroup3, *pPendingGroup = NULL;
SECTORINFO *pSector; SECTORINFO *pSector;
UINT8 ubSectorID; UINT8 ubSectorID;
UINT8 ubNumSoldiers;
UINT8 ubSourceSectorID; UINT8 ubSourceSectorID;
UINT8 ubTargetSectorID; UINT8 ubTargetSectorID;
UINT8 ubNumSoldiers;
switch( usActionCode ) switch( usActionCode )
{ {
+1 -1
View File
@@ -3417,7 +3417,7 @@ STR16 zOptionsToggleText[] =
L"Enemies Drop all Items", L"Enemies Drop all Items",
L"High angle Grenade launching", L"High angle Grenade launching",
L"Restrict extra Aim Levels", L"Restrict extra Aim Levels",
L"Select next Squad", L"Space selects next Squad",
L"Show Item Shadow", L"Show Item Shadow",
L"Show Weapon Ranges in Tiles", L"Show Weapon Ranges in Tiles",
}; };
+1 -1
View File
@@ -3224,7 +3224,7 @@ STR16 zOptionsToggleText[] =
L"Granatwerferflugbahn erhöhen", L"Granatwerferflugbahn erhöhen",
L"Extra Zielgenauigkeit", L"Extra Zielgenauigkeit",
L"Nächste Gruppe selektieren", L"Nächste Gruppe selektieren",
L"Gegenständen mit Schatten", L"Gegenstände mit Schatten",
L"Waffenreichweite in Felder", L"Waffenreichweite in Felder",
}; };
+1 -1
View File
@@ -3406,7 +3406,7 @@ STR16 zOptionsToggleText[] =
L"Enemies Drop all Items", L"Enemies Drop all Items",
L"High angle Grenade launching", L"High angle Grenade launching",
L"Restrict extra Aim Levels", L"Restrict extra Aim Levels",
L"Select next Squad", L"Space selects next Squad",
L"Show Item Shadow", L"Show Item Shadow",
L"Show Weapon Ranges in Tiles", L"Show Weapon Ranges in Tiles",
}; };