Improve AI garrisons, player recovery and mission administration
This commit is contained in:
@@ -23,7 +23,7 @@ for year in (1900, 1989, 2000, 2024, 2050):
|
||||
run('#include <cassert>\n#include <string>\n#include <cmath>\n' + rules + r"""
|
||||
int main() {
|
||||
int lo=-1,hi=-1;
|
||||
for (std::string key:{"reportIntervalSeconds","supportSquadLimit","responseRadiusMetres","aiIntelChancePercent","intelRevealChancePercent","radioDefenceSeconds","startTimeMinutes","timeMultiplier","startDateCode","weatherProfile","convoyCount","heliTimerMinutes"}) {
|
||||
for (std::string key:{"reportIntervalSeconds","supportSquadLimit","responseRadiusMetres","aiIntelChancePercent","intelRevealChancePercent","radioDefenceSeconds","startTimeMinutes","timeMultiplier","startDateCode","weatherProfile","convoyCount","heliTimerMinutes","antiAirChancePercent","antiPersonnelMineChancePercent"}) {
|
||||
assert(ValidSelection(key,-1)); assert(!Valid(key,-1));
|
||||
assert(ValidSelection(key,-2)==(key=="startTimeMinutes")); assert(!ValidSelection(key,-3));
|
||||
if(key=="startDateCode")continue;
|
||||
@@ -31,7 +31,7 @@ int main() {
|
||||
assert(lo<=hi);
|
||||
for(int value=lo;value<=hi;value++) assert(Valid(key,value));
|
||||
}
|
||||
for(std::string key:{"unknown","","stingerChanceOneIn","automaticConvoyEnabled"}) assert(!ValidSelection(key,-1));
|
||||
for(std::string key:{"unknown","","automaticConvoyEnabled"}) assert(!ValidSelection(key,-1));
|
||||
assert(RandomBounds("convoyCount",lo,hi)&&lo==0&&hi==20);
|
||||
assert(RandomBounds("weatherProfile",lo,hi)&&lo==1&&hi==3);
|
||||
assert(RandomBounds("startTimeMinutes",lo,hi)&&lo==0&&hi==1439);
|
||||
|
||||
Reference in New Issue
Block a user