Wiki

effect · add_days_mission_timeout

Definition

  • Supported scope:COUNTRY
  • Supported target:none

Description

add days to 'mission_timeout' value of a mission
Example:
add_days_mission_timeout  = {
    mission = <some_mission>
    days = 30
}

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

When players need to extend the execution window for an ongoing mission after completing a focus or event, this effect can be used to dynamically prolong the mission's countdown. For example, in a "Wartime Emergency Act" event, you might allow players to spend political power in exchange for additional time:

option = {
    name = war_emergency.1.a
    add_political_power = -50
    add_days_mission_timeout = {
        mission = my_critical_war_mission
        days = 30
    }
}

Synergy

  • [has_active_mission](/wiki/trigger/has_active_mission): Check whether the target mission is still active before extending it, preventing errors or logic conflicts when operating on already-completed missions.
  • [activate_mission](/wiki/effect/activate_mission): Typically used in pairs—activate the mission first, then dynamically adjust its remaining duration through events or decisions to implement flexible mission deadlines.
  • [add_days_remove](/wiki/effect/add_days_remove): Similar logic, but extends the removal countdown for timed ideas; combining both in the same event option allows synchronized lifecycle management of missions and ideas.
  • [country_event](/wiki/effect/country_event): Often triggered when a mission is about to expire, offering event options like "spend resources to extend deadline"; combined with this effect, it creates a complete mission pressure system.

Common Pitfalls

  1. The mission field requires the mission's script token (the id used in activate_mission), not the mission's localization key; confusing the two causes silent failure where the mission countdown doesn't change and no error is logged, making it extremely difficult to debug.
  2. Calling this effect on an already-expired or non-activated mission has no effect; it is strongly recommended to guard the call with [has_active_mission](/wiki/trigger/has_active_mission) beforehand, otherwise the entire logic chain will break silently with no warning.