Combat

Combat in Endless Space 2 is split into two parts: ship combat, taking place between fleets in orbit around systems, and ground combat, taking place between soldiers on a planet's surface. Both forms of combat are largely automated, but choices can be made at the start of combat that can have significant effects on the outcome.

**Space**
Ground

## Ship Combat

Ship combat takes place in orbit around systems. It occurs when an attacker's fleet chooses to attack another hostile fleet in the same system (only possible in neutral or attacker territory if in cold war with the defender unless the attacker has "Righteous Fury" law) by taking the Attack action, which causes them to automatically engage the strongest hostile fleet. (If there are multiple hostile factions in the system, the attacker can choose which to engage.) From this position, the attacked fleet has 2 options, fight or retreat.

### Fight

* A fight occurs. Each fleet chooses a battle tactic, and distributes their ships across up to three flotillas, aided by some basic information provided about the enemy fleet's composition and effectiveness. When the battle begins, the flotillas fire weapons at each other across three distinct combat phases, gradually moving to optimal ranges as determined by each fleet's tactics. The battle ends after the third phase, or if either side loses all their ships.

### Retreat

* The defender attempts to leave the system before being destroyed by the opposing fleet. If there is a starlane connecting to a friendly or neutral system, the retreating fleet will take 60% health damage (possibly destroying already-damaged ships) and begin moving toward it. If not, the retreating fleet will be entirely destroyed (after a confirmation dialog warning about this).
* If the attacker's fleet contains a ship with the *Tractor Beam* module (only equippable on Behemoths and Carrier-class hulls), the defender is not allowed to Retreat.

## Heroes

You can assign Heroes to your fleets, and they will participate in space combat. Every hero has a Hero Ship specific to their class; these take a diverse set of modules (including some unique to Hero ships) and do not add any CP to the fleet.

If a Hero's ship is destroyed in combat, but at least one other ship from their fleet survives, they'll revive at end of combat with minimal health. If the rest of the Hero's fleet is destroyed but the Hero survives, they'll continue commanding the (now empty besides their ship) fleet. If the entire fleet is destroyed, the Hero will return to the Academy for several turns to recover from their injury, during which you can't assign them.

Heroes have a number of skills in each quadrant that increase the health, damage, movement, or other stats of both their ship and the fleet as a whole; high-level Heroes can dramatically boost the combat power of a fleet when they're in command.

## Phases

A space battle will last for three phases, each of which is 40 seconds long. If one fleet is completely destroyed before this time is up, the battle will immediately end.

At the end of each phase, flotillas in each lane get closer to each other, if necessary according to their chosen Tactics. Some modules also have special effects at the end of each phase, such as restoring a portion of shields.

## Flotillas and Lanes

At the start of combat, you arrange the ships in your fleet into flotillas occupying the three lanes: Top, Center, and Bottom. The Center lane is always open, while the Top lane requires at least 5 and 2 ships in the fleet and the Bottom lane requires at least 10 and 3 ships in the fleet. The Center lane must always have at least 1 worth of ships in its flotilla, but the Top and Bottom can be left empty if desired.

A ship's lane determines what range it will fight at, according to the tactics cards used by each opponent.

Ships will usually fire at the opposing flotilla in the same lane if possible (an especially inviting target in an adjacent lane *can* pull their fire). If there are no enemy ships in their lane, they'll fire cross-lane into an *adjacent* lane (the Top and Bottom lanes cannot fire on each other); cross-lane fire is always at Long range.

If one combatant has more active flotillas in combat than the other (whether they started that way, or gained the advantage due to destroying enemy ships mid-battle), all of their ships gain a morale advantage, increasing their combat stats. Having one more flotilla than the enemy grants the fleet +10% damage and +5% accuracy and scales linearly with every amount of flotilla more than the enemy up to 3 more flotillas. (though only 2 more flotillas is the maximum amount, since when it goes to 3 the battle will have already ended)

### Automatic Distribution

While you can manually distribute your ships by dragging them to the desired lane, they can also be automatically distributed according to three default strategies chosen in the Advanced Battle Setup screen:

* *Optimal Range*: The first option places each ship in the optimal lane based on your chosen tactic's desired range for the lane and the ship's weapons. For example, ships with Kinetic weapons will be placed in Short lanes if possible. If multiple lanes are equally optimal, the ships are evenly distributed between them. While this option optimizes each ship's effectiveness, it runs the risk of having weaker flotillas destroyed early in battle, giving the enemy a morale bonus and forcing your other flotillas to attack cross-lane.
* *Balanced*: The second (default) option, which balances optimal-range considerations with even distribution. Ships are mostly placed in their optimal lane, but might be put in a less-optimal lane to ensure that no flotilla is too small.
* *Even Distribution*: The third option evenly distributes your ships between the lanes to ensure each flotilla has the same amount of . To the extent that it can without unbalancing the flotilla sizes, ships are placed in the lane with the most optimal range for their weapons. While this option balances your offense in each lane and increases your chance of gaining a morale bonus over your opponent, it might not use each individual ship to their fullest advantage.

## Ranges

The opposing flotillas in each lane can be at Short, Medium, or Long range with each other during a combat phase.

At the start of combat, each lane's flotillas are at the farthest range dictated by each combatant's tactics card. If one tactics card would place their flotilla at a closer range than this, the flotillas move closer by one range increment each phase of combat until they reach the desired closer range.

For example, if the attacker chooses the *Turtle* tactic and the defender chooses the *Power To Shields* tactic, at the start of combat the center lane will have the opposing flotillas at Long range, because *Power To Shields* puts its center lane at Long range. They will then close with each other, reaching Medium range in the second phase and Short range in the third phase, because *Turtle* puts its center lane at Short range. On the other hand, the top lane will start at Medium and reach Short in the second phase, while the bottom lane will start at Long, reach Medium in the second phase, and stay there.

Range determines the accuracy of weapons; each weapon type has varying base accuracy depending on the range it's fired at. For example, Kinetic weapons are most effective at Short range, with an 85% base accuracy; this decreases to 50% accuracy at Medium range, and a mere 10% accuracy at Long range.

## Tactics Cards

Your Battle Tactics affect 2 things: the range your ships will attempt to move to and the bonuses you get for that combat.

* First is the ranges for each flotilla, these show how close your ships will try get to your opponents. The blue bar represents the range your attempting to get to; left is long, middle is medium, and right is short.
* The middle shows what kind of buff the card gives, shield is defensive, a lighting bolt is attack, and >| is for after battle benefits.
* The bottom text tells you what specific benefits the card gives.

For example, in the case of Turtle (seen to the right), the Top and Middle flotillas will attempt to get to short range and the Bottom flotilla will attempt to go for medium range. You will also get a buff to the amount of damage absorbed by hull plating, but not shields.

Fleets at their respective lanes will start at the longest range chosen by either side, and then if one side isn't as close to the target range as their tactic cards dictate, that said side will move closer to the range by 1 unit every phase. The mechanics work like this (the dashes stand for the range in phase 1/2/3, respectively):

 M
 S

Cross-Lane (always adjacent) firing is always counted as Long distance.

It is of crucial importance to keep in mind of the range between firing fleets, as every weapon (other than Beams) have their accuracy significantly impacted by the distance between the two sides.

## Encounter

### Combat View

* While combat is executed completely automatically according to the chosen tactics and natural inclinations of each ship, you can choose to watch the combat by toggling the "Watch" option at the bottom of the combat setup screen.
* Like in other parts of the game, you can switch to a higher-information Scan View of battle by hitting Spacebar.

#### Accuracy Correction

* The game has an "accuracy correction" system to ensure that weapons generally hit as often as their listed accuracy. The exact formula for accuracy is listed below:

* `Accuracy = Weapon Accuracy + (Weapon Accuracy - (Hit Shots in Current Range / Total Shots in Current Range))`

#### Morale

* +10% Damage and +5% Accuracy per lane advantage, +20% Damage and +10% Accuracy at maximum\*
	+ Lane Advantage means having one lane more than the enemy that has at least one friendly ship present and no enemy ships there.
	+ (\*Technically the maximum amount to be gained is +30% Damage and +15% Accuracy, although it's pointless to state given that the battle would always be over by that point)

#### Manpower

* The manpower of a ship provides some innate damage bonus, up to 20%. For this reason, Umbral Choir has a distinct military disadvantage. The formula for the damage calculation is listed below

* `Damage Bonus = (Current Ship Manpower / Maximum Ship Manpower) * 0.2`

## Attack Modules

There are 7 weapon types available in Endless Space 2, loosely grouped into Projectile Weapons and Energy Weapons, corresponding to the two defense types. In addition to the basic weapons, strike craft and high-yield explosive weapons can be fielded. Most modules are unlocked through research, though they can also be rewarded for exploring curiosities or finishing quests.

### Kinetic/Slugs

Rapid-fire, high-velocity kinetic projectiles; space bullets, in other words.

Kinetics are most effective at short range: 85% Short accuracy, 50% Medium accuracy, and 10% Long accuracy. They are most effective against shields: 20% Hull Plating Penetration, and 50% Shield Penetration.

All Kinetics also add Flak to the ship, dealing damage to missiles, boarding pods, and squadrons to destroy them before they can impact the ship.

\* United Empire Only

### Railguns

Sacrificing firing rate for heavier projectiles, Railguns are capable of smashing through any defenses.

Railguns are most effective at short range: 100% Short accuracy, 50% Medium accuracy, and 10% Long accuracy. They completely ignore absorption, effectively having 100% Hull Plating and Shield Penetration.

Railguns are only available from the ES2 Community Challenge Add-On

\* Chitinous Alloys for Cravers

### Missiles

Guided, rocket-propelled projectiles with explosive payloads.

Missiles are most effective at long range: 25% Short accuracy, 50% Medium accuracy, and 100% Long accuracy. They are most effective against shields: 10% Hull Plating Penetration, and 60% Shield Penetration. Missiles can be destroyed by Flak, generated by Kinetic weapons, before reaching their target.

### Swarm Missiles

Firing many small missiles in quick succession, swarm missiles are designed to overwhelm enemy flak.

They have the same accuracy and penetration stats as regular missiles, and can also be destroyed by Flak, though since each "shot" fires 10 missiles, at least a few are likely to reach their target.

Swarm Missiles are only available from the ES2 Community Challenge Add-On

###  Boarding Pods (Vaulters DLC)

Disposable armored craft that slam into the enemy hull to deliver their deadly cargo: a trained boarding party.

Boarding pods are effective at any range: 100% accuracy, regardless of range. They ignore absorption entirely, as they deal no damage to shields or health at all. Like missiles, they can be destroyed by Flak before reaching their target.

After hitting the enemy ship, they will reduce its  each second for 10 seconds; if the enemy ship's  reaches 0, it will be disabled immediately and you gain control of it after the battle. Your empire's troop distribution (Infantry/Tank/Air) has no effect on this damage, but the Infantry upgrades of each empire do.

\* Vaulters Only

### Lasers

More properly particle beams, these are blasts of magnetically-contained high-energy plasmas.

Lasers are most effective at medium range: 50% Short accuracy, 100% Medium accuracy, and 50% Long accuracy. They are most effective against health: 80% Hull Plating Penetration, and 10% Shield Penetration.

\* Vodyani Only

### Beams

Powerful beams of light that can accurately track ships at any range.

Beams are effective at any range: 100% accuracy, regardless of range. They are most effective against health: 90% Hull Plating Penetration, and 10% Shield Penetration.

\* Riftborn Only

## Defense Modules

Your ships have six relevant defensive stats: Health, Shields, Flak, Evasion, Hull Plating Absorption, and Shield Absorption. The latter two are derived stats; modules will instead grant Projectile Defense or Energy Defense, which are inputs to the Absorption stats.

### Health

When your ship's Health  runs out, it is destroyed. The colored bar on the right side of the ships's image in the fleet listing shows its current health percentage. Health generally only recovers if the ship is orbiting in friendly systems (slowly each turn for free, or immediately for a  cost), though there are modules and battle tactics that can provide some healing during or after battles. Most of your ship's Health is granted by the hull itself; Plating  modules grant relatively large amounts of additional health, while Shields  and some other modules will grant smaller amounts. Health damage is resisted by Hull Plating Absorption; energy weapons are more effective at piercing this defense than projectile weapons.

### Shields

Shields are damaged first in battle, before Health, and they fully recover after battle. Some modules and abilities allow you to recover Shields during battle, as well. Shield damage is resisted by Shield Absorption; projectile weapons are more effective at piercing this defense than energy weapons.

### Flak

Flak is a secondary defensive benefit granted by kinetic weapons (slugs). Your flak cannons deal damage to missiles, fighters and bombers, and boarding pods, hopefully destroying them before they can touch your ship. It pays to have at least one slug weapon on larger ships just to grant some Flak defense.

### Evasion

Evasion mitigates damage by making your ships harder to hit. Any shot taken by the enemy subtracts your ships Evasion value from their accuracy, to a minimum of 5% accuracy. Evasion can be gained from Battle Tactics, Engines, Antimatter Shields, and some Support modules. Unfortunately, your ship's total Evasion is not displayed anywhere in-game.

Note: In some tooltips this is referred to as Dodge Chance.

### Defense and Absorption

**Projectile Defense** and **Energy Defense** are granted by Plating  and Shield  modules, respectively. Each ship also has a **Hull Weakness** stat, based on its size. (Small ships are 100, Medium are 250, Large are 600, Behemoths are 600.) By combining each Defense with the Hull Weakness, a **Hull Plating Absorption** and **Energy Absorption** stat is calculated:

Absorption = Defense / (Defense + Hull Weakness)

So a ship with 400 Projectile Defense and 100 Hull Weakness would have a Hull Plating Absorption of 400/500, or 80%, and would thus negate 80% of all incoming Projectile Damage. A well-defended ship can thus be *extremely* difficult to damage by the wrong type of weapon, and even well-matched weapons (Projectile vs Shields, for example) can have their damage significantly reduced.

A ship's Absorption stats are reduced by the Penetration stats of the weapons firing at them. It's a percentage reduction, not a direct subtraction; for example, if a ship has 80% Shield Absorption, and is being fired on by a slug weapon (which has 50% Shield Penetration), the ship's effective Absorption would be 40% (half of 80%) not 30%. This means even small amounts of Absorption are still valuable; if the ship had only 20% Shield Absorption and was again being fired on by a slug weapon, its effective Absorption would still be 10%.

* Damage Absorbed % = Hull Plating Absorption \* (1 - Hull Plating Penetration)

* Damage Absorbed % = Shield Absorption \* (1 - Shield Penetration)

* Damage done = Weapon damage x (1 - Damage Absorbed Shield) x (1 - Damage Absorbed Hull)

* Once Shields go down:
	+ Damage done = Weapon damage x (1 - Damage Absorbed Hull %)

Since Defense stats of modules are so large compared to Hull Weakness, even a single Plating or Shield module can give *significant* damage reduction, so ships should almost always be built with at least one of each.

Modules/Defense

## Squadron Modules

Coordinator, Carrier, and Behemoth hulls can equip Squadron  modules, which release autonomous Fighters  and Bombers  ships during combat to harass the enemy's ships in the same lane. Squadrons have 100% accuracy at all ranges, and can only be destroyed by enemy Flak or Fighters.

If a squadron's target ship is destroyed, they'll move on to another ship in the enemy flotilla automatically. If their launch ship is destroyed, the squadrons are *not* affected - they'll continue fighting until the end of combat, at which point they disappear.

Energy Fighters and Bombers are only available from the ES2 Community Challenge Add-On

###  Bombers

Bombers are designed to kill large ships. They have reasonably high DPS, which is halved against Small-hull ships, but is increased by ×1.5 against Large/Behemoth-hull ships, making their damage equivalent to the most advanced Kinetic weapons (but without requiring your ship to reach Close range). They do no damage to other Squadron ships.

Even a single Bomber module can do significant damage to fleets with Large ships if they don't have adequate defenses (Kinetic weapons and Fighter modules), so it's often worth equipping one on your Coordinator-hull escorts.

###  Fighters

Fighters are defense against Bombers. They will do a small amount of damage to enemy Ships (DPS reduced to 40% against Small, 25% against Medium, and 10% against Large/Behemoth), but are fully effective against other Squadron ships.

As unopposed Bombers can be devastating to a fleet with Large ships, if your fleets don't have Flak from Kinetic weapons, it can be worthwhile to equip even a single Fighter module for defense purposes.

### Squadron-Focused Tactics

Your choice of tactics card has a minor effect on how your squadrons perform, determining what fraction of your Fighters are devoted to offense (attacking the enemy Ships and defending your Bombers from enemy Fighters) and to defense (defending your ships from enemy squadrons). Attack-focused tactics cards (with the lightning-bolt icon) set them to 70% offense / 30% defense; defense-focused cards (with the shield icon) set them to 30% offense / 70% defense; and neutral tactics cards (with the arrow icon) set them to 50% offense / 50% defense.

The Military 4 tech Deniable Operations grants three squadron-focused tactics cards:

* *Repair Protocol* heals the launch ship post-battle according to how many of their squadrons survived the battle.
* *Strafing Run* sets your Fighters to 100% offense / 0% defense.
* *Fleet Escort* sets your Fighters to 0% offense / 100% defense.