From db6727b2d7d0ae80ade2719acd440c83df84bb19 Mon Sep 17 00:00:00 2001 From: Shadooow Date: Sat, 26 Jun 2021 00:59:14 +0000 Subject: [PATCH] crash fix: changed maximum number of enemies in raid to be dependant on maximum enemies of that type defined beforehand git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@9107 3b4a5df2-a311-0410-b5c6-a8a6f20db521 --- GameSettings.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/GameSettings.cpp b/GameSettings.cpp index aa65f0d6..9bfd4b84 100644 --- a/GameSettings.cpp +++ b/GameSettings.cpp @@ -2077,9 +2077,9 @@ void LoadGameExternalOptions() gGameExternalOptions.gRaidReplenish_BaseValue = iniReader.ReadInteger( "Raid Settings", "RAID_REPLENISH_BASEVALUE", 3, 1, 100 ); - gGameExternalOptions.gRaidMaxSize_Bloodcats = iniReader.ReadInteger( "Raid Settings", "RAID_MAXSIZE_BLOODCATS", 8, 1, 254 ); - gGameExternalOptions.gRaidMaxSize_Zombies = iniReader.ReadInteger( "Raid Settings", "RAID_MAXSIZE_ZOMBIES", 15, 1, 254 ); - gGameExternalOptions.gRaidMaxSize_Bandits = iniReader.ReadInteger( "Raid Settings", "RAID_MAXSIZE_BANDITS", 6, 1, 254 ); + gGameExternalOptions.gRaidMaxSize_Bloodcats = iniReader.ReadInteger( "Raid Settings", "RAID_MAXSIZE_BLOODCATS", 8, 1, gGameExternalOptions.ubGameMaximumNumberOfCreatures); + gGameExternalOptions.gRaidMaxSize_Zombies = iniReader.ReadInteger( "Raid Settings", "RAID_MAXSIZE_ZOMBIES", 15, 1, gGameExternalOptions.ubGameMaximumNumberOfEnemies); + gGameExternalOptions.gRaidMaxSize_Bandits = iniReader.ReadInteger( "Raid Settings", "RAID_MAXSIZE_BANDITS", 6, 1, gGameExternalOptions.ubGameMaximumNumberOfEnemies); gGameExternalOptions.gRaid_MaxAttackPerNight_Bloodcats = iniReader.ReadInteger( "Raid Settings", "RAID_MAXATTACKSPERNIGHT_BLOODCATS", 3, 0, 100 ); gGameExternalOptions.gRaid_MaxAttackPerNight_Zombies = iniReader.ReadInteger( "Raid Settings", "RAID_MAXATTACKSPERNIGHT_ZOMBIES", 3, 0, 100 );