Age modding

From Europa Universalis 4 Wiki
Jump to navigation Jump to search

Ages are dynamic periods ingame that activate special rules such as Absolutism and permit the spending of Splendor, gained through objectives, on age-specific modifiers.

Ages[edit | edit source]

The Ages for the game are defined in /Europa Universalis IV/common/ages/*.txt. You can have as a little as one age, or as many as you can create. There is an age usher-in time delay set in defines that delays when the next age happens, 120 months in vanilla.

Ages follow this format:

<age> = {
    # The year after which the age will be active in history
    start = <year>
    # The conditions for the age to happen (starts the usher-in-time countdown)
    can_start = {
    # Added to enable the Religious Conflict features, i.e. Crusades.
    religious_conflicts = yes
    # Added to enable the Absolutism feature.
    absolutism = {
        # Each entry defines the absolutism gain or loss from the action.
    # Objectives ...
    objectives = {
        <objective> = {
            # When to show the objective
            allow = {
            # When the objective is met
    # Abilities ...
    abilities = {
        <ability> = {
            # When to show the ability
            allow = {
            # Effect to execute when ability is taken
            effect = {
            # Modifier to grant when ability is taken
            modifier = {
            # Rule ability to grant when ability is taken
            rule = {
            # How likely the AI is to take this ability
            ai_will_do = {
                factor = <int>

Absolutism entries[edit | edit source]

The absolutism scope takes specific commands, with the value representing the amount of Absolutism lost or gained when the action is taken.

stability = <float>
decrease_autonomy_command = <float>
strengthen_government = <float>
increase_autonomy_command = <float>
debase_currency = <float>
execute_rebel_acceptance_command = <float>
seat_in_parliament = <float>
war_exhaustion = <float>

Abilities[edit | edit source]

The following modifiers are unique to Ages, they are used in the rule = { } scope within an ability.

can_transfer_vassal_wargoal = yes
can_chain_claim = yes
can_colony_boost_development = yes
attack_bonus_in_capital_terrain = yes
force_march_free = yes
ignore_coring_distance = yes

Interface[edit | edit source]

New ages must be added to ages_view.gui as a new WindowType within the ages_view window.

For example:

WindowType = {
    name = "<age name>"
	# ...

Abilites and Objectives[edit | edit source]

The icons for abilities and objectives must be defined in a .gfx file. For example:

spriteType = {
    name = "GFX_obj_discover_america"
    texturefile = "gfx/interface/ages/"

spriteType = {
    name = "GFX_ab_allow_feudal_de_jure_law"
    texturefile = "gfx/interface/ages/"

Topbar[edit | edit source]

It is important to note that Ages will edit the top-bar background when entering a Golden Age. Without the following spriteTypes, the game will crash when entering a golden age:

Documentation EffectsTriggersModifiersScopesVariablesLocalisationCustomizable localizationRun files
Scripting Scripted functionAdvisorsAgesBookmarksBuildingsCasus belliColonial regionsCountriesCultureDecisionsDefinesDiplomatic actionsDisastersEmpire of ChinaEstatesEventsFactionsGovernmentGreat projectsHistoryHoly Roman EmpireIdea groupsInstitutionsMercenariesMissionsModifiersNation designerOn ActionsParliamentPeace treatiesPoliciesRebel typesReligionSubject typesTechnologyTrade companiesTrade goodsUnits
Map MapNation designerRandom New WorldTrade nodes
Graphics 3D ModelsInterfaceGraphical AssetsFontsParticlesShadersUnit models
Audio MusicSound
Other Console commandsChecksumJoroDox mod making toolMod structureTroubleshootingThe ValidatorRun files
Guides Adding a provinceSave-game editing