Skip to content

Commit

Permalink
Tweak AA production and research.
Browse files Browse the repository at this point in the history
  • Loading branch information
KJeff01 committed Nov 8, 2019
1 parent 01becdf commit e7fe1cd
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 9 deletions.
2 changes: 1 addition & 1 deletion multiplay/skirmish/cobra_includes/production.js
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,7 @@ function choosePersonalityWeapon(type)
}

// Choose an anti-air weapon instead... checks target player and then total player vtols.
if (((playerVtolRatio(getMostHarmfulPlayer()) >= 0.20) || (countEnemyVTOL() > 40)) && random(100) < 20)
if (((playerVtolRatio(getMostHarmfulPlayer()) >= 0.15) || (countEnemyVTOL() > 30)) && random(100) < 20)
{
weaponList = [];

Expand Down
12 changes: 4 additions & 8 deletions multiplay/skirmish/cobra_includes/research.js
Original file line number Diff line number Diff line change
Expand Up @@ -148,8 +148,7 @@ function research()
if (!found && random(100) < 33)
found = evalResearch(lab, extraTech);

//Use default AA until stormbringer.
if (random(100) < 40 && countEnemyVTOL() && !isStructureAvailable("P0-AASite-Laser"))
if (random(100) < 40 && countEnemyVTOL())
{
if (!found)
found = evalResearch(lab, antiAirTech);
Expand Down Expand Up @@ -220,8 +219,7 @@ function research()
}
else if (subPersonalities[personality].resPath === "defensive")
{
//Use default AA until stormbringer.
if (random(100) < 40 && countEnemyVTOL() && !isStructureAvailable("P0-AASite-Laser"))
if (random(100) < 40 && countEnemyVTOL())
{
if (!found)
found = evalResearch(lab, antiAirTech);
Expand Down Expand Up @@ -321,8 +319,7 @@ function research()
if (!found)
found = evalResearch(lab, SYSTEM_UPGRADES);

//Use default AA until stormbringer.
if (random(100) < 40 && countEnemyVTOL() && !isStructureAvailable("P0-AASite-Laser"))
if (random(100) < 40 && countEnemyVTOL())
{
if (!found)
found = evalResearch(lab, antiAirTech);
Expand Down Expand Up @@ -382,8 +379,7 @@ function research()
if (!found && useArti && random(100) < antiCyborgChance)
found = evalResearch(lab, artilleryTech);

//Use default AA until stormbringer.
if (random(100) < 40 && countEnemyVTOL() && !isStructureAvailable("P0-AASite-Laser"))
if (random(100) < 40 && countEnemyVTOL())
{
if (!found)
found = evalResearch(lab, antiAirTech);
Expand Down

0 comments on commit e7fe1cd

Please sign in to comment.