Campaign rule for unpredictable wave AI

This commit is contained in:
Anuken
2024-09-13 18:50:46 -04:00
parent 1529c40400
commit 6e5561a36e
6 changed files with 38 additions and 15 deletions

View File

@@ -5,12 +5,13 @@ public class CampaignRules{
public boolean fog;
public boolean showSpawns;
public boolean sectorInvasion;
public boolean randomWaveAI;
public void apply(Rules rules){
rules.staticFog = rules.fog = fog;
rules.showSpawns = showSpawns;
rules.randomWaveAI = randomWaveAI;
rules.teams.get(rules.waveTeam).blockHealthMultiplier = difficulty.enemyHealthMultiplier;
rules.teams.get(rules.waveTeam).unitHealthMultiplier = difficulty.enemyHealthMultiplier;
rules.randomAirTargeting = difficulty.ordinal() >= Difficulty.hard.ordinal();
}
}

View File

@@ -61,8 +61,8 @@ public class Rules{
public boolean fire = true;
/** Whether units use and require ammo. */
public boolean unitAmmo = false;
/** EXPERIMENTAL! If true, air units target random things each wave instead of only generators. */
public boolean randomAirTargeting = false;
/** EXPERIMENTAL! If true, air and ground units target random things each wave instead of only the core/generators. */
public boolean randomWaveAI = false;
/** EXPERIMENTAL! If true, blocks will update in units and share power. */
public boolean unitPayloadUpdate = false;
/** If true, units' payloads are destroy()ed when the unit is destroyed. */