Skip to content

Instantly share code, notes, and snippets.

@Zarkonnen
Last active March 19, 2023 23:09
Show Gist options
  • Save Zarkonnen/2309fc2ea637b7efa7521bcc3ed99d70 to your computer and use it in GitHub Desktop.
Save Zarkonnen/2309fc2ea637b7efa7521bcc3ed99d70 to your computer and use it in GitHub Desktop.

EMPIRE STATS EXPLANATION

These are per-empire values that are modified by an empire's bonuses. You can give an empire bonuses through heraldic charges, technology, city upgrades, special eras, monster nest rewards and expedition rewards.

This document is best read together with Airships Install Folder/data/EmpireStat/stats.json so you can see the concrete values used.

Calculations and Notes

Time

Time: 1 day = 400 milliseconds Milliseconds is abbreviated to "ms".

Espionage

Spy action success: Base Success Chance x (100 + ESPIONAGE_SUCCESS_PERCENTAGE_BONUS(yours) - ESPIONAGE_DEFENCE_PERCENTAGE_BONUS(enemy)) / 100

Research

Total research cost: BASE_RESEARCH_COST x RESEARCH_COST_MULTIPLIER x RESEARCH_COST_EXPONENT ^ Tier

Research points are added every two weeks. So for example, a tier 0 tech costs 400 x 1 x 1.4 ^ 0 = 400 points. Researched by an empire in the starting era, and with normal tech speed, where research output is 15, it takes 400 / 15 = 26.7 two-week cycles, so about 373 days.

Unrest

Unrest from empire size per city: CITY_UNREST / (Number of empires the map started out with + UNREST_MAP_SIZE_OFFSET).

Unrest from empire size per town: TOWN_UNREST / (Number of empires the map started out with + UNREST_MAP_SIZE_OFFSET).

For example, if you are on a very small map that started with only 4 empires, and you are in the early game, each city in your empire generates 180 / (4 + 9) = 13 points of unrest. In comparison, with a huge map, it's only 180 / (24 + 9) = 5 points.

Claims

If multiple empires cooperate in a fight to conquer a town or city, the strength of each empire's claim to the place is calculated, and the strongest claimant gains it. The calculation for claim strength works as follows:

  • min(MAX_FLEET_STRENGTH_CLAIM_STRENGTH, Total value of fleet after the fight / FLEET_STRENGTH_CLAIM_DIVIDER)
  • max(0, DISTANCE_TO_NEAREST_TOWN_CLAIM_BASE - DISTANCE_TO_NEAREST_TOWN_CLAIM_MULTIPLIER x Distance to nearest territory)
  • ORIGINAL_OWNER_CLAIM_STRENGTH(if it belonged to this empire originally)
  • PREVIOUSLY_AWARDED_CLAIM_STRENGTH(if this empire was most recently awarded territory).

So for example, if an empire has $3000 worth of fleet left after the battle, has another territory 12 tiles away, and originally owned the city, the claim strength would be min(20, 3000 / 1000) + max(0, 8 - 0.25 * 12) + 12 + 0 = 3 + 5 + 12 + 0 = 20.

Whereas an empire with $10000 worth of fleet left, a territory 100 tiles away, and who was most recently awarded a claim would have min(20, 10000 / 1000) + max(0, 8 - 0.25 * 100) + 0 - 5 = 10 + 0 + 0 - 5 = 5.

Name Info
CITY_INCOME_PERCENTAGE_BONUS Extra income from towns and cities, in percent.
BASE_RESEARCH_COST Base number of research points required to research a tier 0 tech.
RESEARCH_COST_MULTIPLIER Extra multiplier on for research cost.
RESEARCH_COST_EXPONENT Not actually an exponent. Research cost for a tier is multiplied by RESEARCH_COST_EXPONENT to the power of the tier.
STARTING_REPUTATION Starting reputation for empire. Empires start with STARTING_REPUTATION +- 5.
FIRE_QUENCH_AMOUNT When a single crewman puts out a fire, how many points of fire are subtracted.
REPAIR_AMOUNT How many HP are repaired in a module by a single crewman repairing it.
ESPIONAGE_SUCCESS_PERCENTAGE_BONUS Bonus to success of spy actions.
ESPIONAGE_DEFENCE_PERCENTAGE_BONUS Malus to success of enemy spy actions.
PRODUCTION_PERCENTAGE_BONUS Bonus to speed at which ships and buildings are built.
REVOLTING_CITIES_JOIN_EMPIRE Whether a foreign town or city that revolts joins this empire instead of becoming an independent empire.
INACCURACY_MULT Multiplier to weapon inaccuracy for ship-based weapons.
RELOAD_MULT Multiplier to weapon reload time for ship-based weapons.
BIO_MONSTER_RESEARCH_MULT Multiplier to research gained from defeating monster nests that have "biological" set to true.
BIO_MONSTER_MONEY_MULT Multiplier to money gained from defeating monster nests that have "biological" set to true.
BIO_MONSTER_EXTRA_MONEY Flat amount of additional money always gained by defeating monster nests that have "biological" set to true.
DAYS_PER_MONTH Days per month in the calendar displayed in-game.
STARTING_DAY Total number of days from the beginning of the calendar at the start of the game.
CALENDAR_NAME Translation key for the name of the calendar.
MONTHS Names of the months in the calendar. The length of this list also defines the number of months per year. Note that these names are used directly and not as translation keys.
SUPPLY_PER_DIST Number of supply points required by distance on the map.
AIRSHIP_MAP_SPEED_MULT Multiplier for airship speed for map movement.
LANDSHIP_MAP_SPEED_MULT Multiplier for landship speed for map movement.
FRIENDLY_TO_FRIENDLY_CITY_SUPPLY_MULT Multiplier for supply cost for moving a fleet from a friendly location to another friendly location.
MIN_SHIP_SUPPLY_COST Minimum supply required value for a ship.
NON_ADJACENT_MOVE_SUPPLY_MULT Multiplier for supply cost for moving a fleet to a territory that's not adjacent to a friendly territory.
CHANGE_COURSE_SUPPLY_PENALTY Additional supply cost for changing course midflight. Cost is multiplied by 1 + CHANGE_COURSE_SUPPLY_PENALTY.
LANDSHIP_MOVE_SUPPLY_MULT Multiplier for supply cost for landships.
SHIP_SUPPLY_MULT Supply required x SHIP_SUPPLY_MULT = Supply storage
RESUPPLY_TOWN Amount of supply filled up by a fleet in a town every two weeks.
RESUPPLY_NEST Amount of supply filled up by a fleet in a monster nest every two weeks.
RESUPPLY_CITY Amount of supply filled up by a fleet in a city every two weeks.
MAINTENANCE_COST_PER_SUPPLY Maintenance cost for modules per supply point.
MAX_SPIES Maximum number of spies available to an empire.
SPY_NETWORK_INCREASE_LEVEL_TIME Baseline time taken for a spy to increase spy network level, in milliseconds.
SPY_NETWORK_INCREASE_LEVEL_TIME_PER_LEVEL Additional time taken to increase spy network level per pre-existing network level, in milliseconds.
MAX_SPY_NETWORK_LEVEL Max spy network level you can reach.
CAPTURED_SPY_NETWORK_BONUS Number of network levels gained by your spies in towns and cities owned by an empire whose spy you caught.
RESEARCH Base amount of research produced by an empire.
CITY_PRODUCTION Amount of production towards ships and buildings in a city, per millisecond.
TOWN_PRODUCTION Amount of production towards ships and buildings in a town, per millisecond.
CITY_UPGRADE_COST Baseline cost for a city upgrade. Modified by UPGRADE_COST_EXPONENT and CityUpgradeType.extraCost.
TOWN_UPGRADE_COST Baseline cost for a town upgrade. Modified by UPGRADE_COST_EXPONENT and CityUpgradeType.extraCost.
UPGRADE_COST_EXPONENT Not-actually-exponent for making successive upgrades more expensive. Calculation is UPGRADE_COST x UPGRADE_COST_EXPONENT ^ Number of existing upgrades + Extra cost for this upgrade.
UPGRADE_SPEED_PERCENTAGE_BONUS Percentage bonus for time taken to build a city upgrade. Upgrade speed is not based on production!
MONSTER_NEST_MIN_TIME_EMPTY Minimum amount of time a monster nest stays empty before a new monster spawns, in milliseconds.
MONSTER_NEST_RESPAWN_CHANCE_MULT Multiplier for chance that a new monster spawns in a nest.
TOWN_BASE_UNREST Baseline unrest value in towns.
CITY_BASE_UNREST Baseline unrest value in cities.
CITY_REP_UNREST Unrest value for towns and cities based on your reputation.
UNREST_MAP_SIZE_OFFSET Offset value to prevent small maps from having high unrest. (See calculation.)
CITY_UNREST Unrest from empire size from each city. (See calculation.)
TOWN_UNREST Unrest from empire size from each town. (See calculation.)
POST_RAID_UNREST Additional unrest in a town or city if it's been recently raided.
STRIKE_UNREST Additional unrest caused by the city striking.
POST_RAID_UNREST_TIME Amount of time the POST_RAID_UNREST persists after a raid, in ms.
DISCONNECTED_FROM_CAPITAL_UNREST Additional unrest from a town or city not being connected to the empire's capital.
UNREST_REDUCTION_PER_DEFENCES_MAINTENANCE Unrest reduced for each $1 in maintenance cost for buildings in the town or city.
UNREST_REDUCTION_PER_GARRISON_MAINTENANCE Unrest reduced for each $1 in maintenance cost for ships and landships stationed in the town or city.
FOMENTING_UNREST_UNREST Unrest generated by the "foment unrest" spy action.
FOMENTING_UNREST_TIME Time in ms that the FOMENTING_UNREST_UNREST persists.
NO_TAKEOVER_SELECTED_UNREST Unrest generated in towns and cities that have been conquered but don't have a takeover method selected yet.
ECON_DAMAGE_RECOVERY_TIME Time in ms for one point of economic devastation to go away again.
EXPEDITION_MS Time in ms an expedition takes.
CAN_SEE_EVERYTHING Whether an empire has full spy vision in all towns, cities, and fleets.
SPY_CAN_SEE_LOCAL_INSIDES Infiltration level required for a spy to see the insides of ships and buildings in the town or city they're in.
SPY_CAN_INSPECT_FLEETS If you have a spy in any city with at least this infiltration level, you can click on and view fleets of that empire.
SPY_CAN_VIEW_ALL_CITIES If you have a spy in any city with at least this infiltration level, you can view all towns and cities of that empire as if you had a spy stationed there.
SPY_CAN_SEE_ALL_INSIDES If you have a spy in any city with at least this infiltration level, you can view the insides of ships and buildings in all towns and cities of that empire as if you had a spy with an infiltration level of SPY_CAN_SEE_LOCAL_INSIDES stationed there.
CORONATION_REPUTATION Reputation level required to start coronation.
CORONATION_TIME Time taken for coronation, in ms.
CORONATION_COST_PER_CITY Maintenance cost for coronation per city under your control.
RITUAL_COST_PER_SITE Maintenance cost for final ritual per ritual site.
TIME_PER_REP_DECAY Time in ms for your reputation to shift 1 point towards baseline 50. Reputation will never shift if it would put you into a different reputation bracket, though.
RECENT_LEVEL_CHANGE_TIMEOUT Time in ms for a treaty to no longer be considered "recent". Recent treaties have double reputation costs for breaking them.
TRUCE_TIME Time in ms for a truce to develop into a peace.
RESEARCH_TREATY_BREAK_COST Rep cost for breaking a research treaty.
TRADE_TREATY_BREAK_COST Rep cost for breaking a trade treaty.
TRIBUTE_BREAK_COST Rep cost for breaking a tribute treaty.
WAR_BREAK_COST Reputation cost for breaking a, uh, war. Not used.
TRUCE_BREAK_COST Reputation cost for breaking a truce.
PEACE_BREAK_COST Reputation cost for breaking a peace. Zero by default, but if you wanted any declaration of war to cost rep, you could change it.
NON_AGGRESSION_PACT_BREAK_COST Reputation cost for breaking a non-aggression pact.
DEFENSIVE_PACT_BREAK_COST Reputation cost for breaking a defensive pact.
ALLIANCE_BREAK_COST Reputation cost for breaking an alliance.
CANCELLED_ULTIMATUM_COST Reputation cost for backing down from an ultimatum.
FAILED_FALSE_ULTIMATUM_COST Reputation cost for not going through with your threat when an ultimatum is defied.
MIN_ULTIMATUM_REPUTATION Minimum reputation required to be able to make ultimatums.
ORIGINAL_OWNER_CLAIM_STRENGTH Claim strength if the town or city originally belonged to an empire.
DISTANCE_TO_NEAREST_TOWN_CLAIM_BASE Baseline claim strength for distance to nearest territory.
DISTANCE_TO_NEAREST_TOWN_CLAIM_MULTIPLIER Reduction in claim strength the further away the nearest territory is.
FLEET_STRENGTH_CLAIM_DIVIDER Strength of the fleet present after the battle is divided by this value to produce claim points.
MAX_FLEET_STRENGTH_CLAIM_STRENGTH Maximum claim strength from fleet strength.
PREVIOUSLY_AWARDED_CLAIM_STRENGTH Claim strength from having most recently been awarded a town or city.
BESIEGED_CITY_INCOME_REDUCTION_PERCENTAGE Not used.
TRIBUTE_INCOME_PAID_PERCENTAGE Percentage of gross income paid as tribute.
TRADE_TREATY_INCOME_GAINED_PERCENTAGE Percentage of gross income of a trade treaty partner gained as income.
RESEARCH_TREATY_RESEARCH_GAINED_PERCENTAGE Percentage of research points of a research treaty partner gained as research.
RESEARCH_COST_DECREASE_PERCENT_FOR_TREATY Percentage decrease in cost of a technology if a research treaty partner already has it.
AIRSHIP_CONSTRUCTION_SPEED_PERCENTAGE_BONUS Percentage bonus to airship construction speed.
LANDSHIP_CONSTRUCTION_SPEED_PERCENTAGE_BONUS Percentage bonus to landship construction speed.
BUILDING_CONSTRUCTION_SPEED_PERCENTAGE_BONUS Percentage bonus to building construction speed.
AIRSHIP_COST_MULTIPLIER Multiplier for airship cost.
LANDSHIP_COST_MULTIPLIER Multiplier for landship cost.
BUILDING_COST_MULTIPLIER Multiplier for building cost.
AIRSHIP_MAINTENANCE_MULTIPLIER Multiplier for airship maintenance.
LANDSHIP_MAINTENANCE_MULTIPLIER Multiplier for landship maintenance.
BUILDING_MAINTENANCE_MULTIPLIER Multiplier for building maintenance.
CAN_SEE_RITUAL_SITES Whether your empire has discovered where the ritual sites are.
CAN_DO_FINAL_RITUAL Whether your empire has the ability to do the final ritual if they have all the ritual sites under their control.
CAN_EVENTUALLY_DO_FINAL_RITUAL Whether your empire will eventually be able to do the final ritual and should be shown information about it.
CAN_CORONATE Whether your empire can do coronation if it controls enough cities and has high enough reputation.
FINAL_RITUAL_TIME Time taken for final ritual, in ms.
DELEGATION_SNUB_GRIEVANCES Grievances caused by rejecting a delegation.
DELEGATION_SNUB_REP_LOSS Reputation lost by having a delegation rejected.
UNANSWERED_INSULT_GRIEVANCES Grievances caused by not answering an insult.
UNANSWERED_INSULT_REP_LOSS Reputation lost by not answering an insult.
NO_GRIEVANCES_DELEGATION_SENDER_REP_GAIN Reputation gained by the sender of an accepted delegation if there are no grievances.
NO_GRIEVANCES_DELEGATION_RECEIVER_REP_GAIN Reputation gained by the receiver of an accepted delegation if there are no grievances.
SENDER_GRIEVANCES_DELEGATION_SENDER_REP_GAIN Reputation gained by the sender of an accepted delegation if the sender has grievances.
SENDER_GRIEVANCES_DELEGATION_SENDER_GRIEVANCES_LOSS Grievances lost by the sender of an accepted delegation if the sender has grievances.
RECEIVER_GRIEVANCES_DELEGATION_SENDER_REP_GAIN Reputation gained by the sender of an accepted delegation if the receiver has grievances.
RECEIVER_GRIEVANCES_DELEGATION_RECEIVER_REP_GAIN Reputation gained by the receiver of an accepted delegation if the receiver has grievances.
RECEIVER_GRIEVANCES_DELEGATION_RECEIVER_GRIEVANCES_LOSS Grievances lost by the receiver of an accepted delegation if the receiver has grievances.
ANSWERED_INSULT_GRIEVANCES Grievances caused by answering an insult.
ANSWERED_INSULT_REP_LOSS Reputation lost by answering an insult.
SEND_CHALLENGE_INTERVAL Cooldown between sending an insult or delegation, in ms.
INSULT_1_PREFIX Prefix for translation keys of the first part of insults.
INSULT_1_NUM Number of variations of the first part of insults. So the translation key for the first part could be INSULT_1_7 = "Coward!".
INSULT_2_PREFIX Prefix for translation keys of the second part of insults.
INSULT_2_NUM Number of variations of the second part of insults. So the translation key for the first part could be INSULT_2_12 = "Your corporals lack the spit to even shine their own shoes.".
DELEGATION_PREFIX Prefix for translation keys for gifts brought by a delegation.
DELEGATION_NUM Number of variations of gifts brought by delegation. So the translation key could be DELEGATION_4 = "floatmead".
DELEGATION_ACCEPTED_PREFIX Prefix for translation keys for accepted delegation messages.
DELEGATION_ACCEPTED_NUM Number of variations for accepted delegation messages. So the translation key could be DELEGATION_ACCEPTED_3 = "The delegation was praised for their manners.".
DELEGATION_REJECTED_PREFIX Prefix for translation keys for rejected delegation messages.
DELEGATION_REJECTED_NUM Number of variations for rejected delegation messages. So the translation key could be DELEGATION_REJECTED_14 = "The delegation was sent to the Crab Pole.".
SUBMISSION_REP_LOSS Reputation lost by submitting to another empire.
SUBMISSION_REP_GAIN Reputation gained by another empire submitting to yours.
CONQUER_HATED_CITY_REP_GAIN Reputation gained by conquering a town or city of a hated empire if you are not also hated.
CONQUER_LOVED_CITY_REP_LOSS Reputation lost by conquering a town or city of a loved empire if you are not also loved.
TOWN_DEFENCE_BUDGET Local defence budget in towns. The total maintenance cost for local buildings is reduced by this.
CITY_DEFENCE_BUDGET Local defence budget in cities. The total maintenance cost for local buildings is reduced by this.
EMPIRE_BASE_INCOME Base income for empire independent of any towns/cities.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment