Wiki

trigger · tag

Definition

  • Supported scope:COUNTRY, CHARACTER, COMBATANT
  • Supported target:THIS, ROOT, PREV, FROM, OWNER, CONTROLLER, OCCUPIED, CAPITAL

Description

country tag trigger

Hands-On Notes

Hands-on notes are AI-generated and checked against the vanilla command vocabulary — treat them as a starting point, not authoritative reference. The definition above is the game's own documentation.

Hands-On Usage

tag is the most fundamental trigger for country identity verification, commonly used to restrict a focus, decision, or event option to specific nations—for example, allowing only Germany to trigger a particular special decision, or excluding the player's own nation in any/all loops. Combined with other conditions in event trigger or limit blocks, it enables precise branching of historical paths tailored to different countries.

# Decision available only to Germany
available = {
    tag = GER
    has_war_support > 0.5
}

# Exclude self within any_neighbor_country loop
any_neighbor_country = {
    NOT = { tag = ROOT }
    is_in_faction_with = ROOT
}

Synergy

  • [exists](/wiki/trigger/exists): Typically use exists first to confirm the target nation exists in the current game, then use tag to verify its specific identity, avoiding logic triggers on annexed nations.
  • [has_completed_focus](/wiki/trigger/has_completed_focus): Combined with tag, restricts the condition to "a specific nation has completed a particular focus tree branch," useful for constructing diplomatic story nodes between nations.
  • [any_allied_country](/wiki/trigger/any_allied_country): Within any_allied_country loop scope, use tag to filter whether a specific ally exists—the standard pattern for multi-nation coordinated events.
  • [country_event](/wiki/effect/country_event): In effect blocks, first lock the trigger target with tag conditions, then send the targeted event, ensuring the event reaches only the intended nation.

Common Pitfalls

  1. Scope Confusion: When writing tag = GER directly inside scopes like any_owned_state or any_neighbor_country, the scope has already shifted to STATE or another nation—tag evaluates the current scope's nation, not the original context. Use ROOT/PREV to trace back to the correct nation scope, otherwise the condition will never function as intended.
  2. Case and Spelling Errors: Country tags must exactly match the three-letter uppercase codes in-game (e.g., SOV not sov or USSR). Misspelled tags cause silent condition failures with no error messages, making them easy to miss during debugging.