Wiki

effect · hold_election

Definition

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

Description

Immediately holds an election in the target country

实战 · 配合 · 坑

实战内容由 AI 生成,并已对照 vanilla 命令词表校验 —— 请当作起点而非权威依据。上方的定义节才是游戏自带文档原文。

实战用法

hold_election 常用于民主国家的政治事件中,模拟周期性大选或提前选举场景,例如玩家完成某个国策后立即触发选举改变执政党。也适合用在内战结束、傀儡独立等剧本节点,通过强制选举让新政权合法化。

# 某国国策完成后立即举行大选
focus = {
    id = GER_hold_snap_election
    ...
    completion_reward = {
        hold_election = ROOT
    }
}

配合关系

  • [has_elections](/wiki/trigger/has_elections) — 先用此触发器判断目标国是否启用了选举机制,避免在非民主体制下调用 hold_election 导致逻辑错误。
  • [add_popularity](/wiki/effect/add_popularity) — 选举前调整各意识形态支持度,让选举结果符合剧本预期,而非完全随机。
  • [add_political_power](/wiki/effect/add_political_power) — 选举往往伴随政治资本的消耗或奖励,搭配使用可模拟选举的政治成本。
  • [country_event](/wiki/effect/country_event) — 在选举后触发后续事件,处理"谁赢得大选"的分支结果,构成完整的选举事件链。

常见坑

  1. 在非民主体制国家上调用hold_election 仅对拥有选举系统的国家有实际效果,若目标国当前政体没有启用选举,指令会静默失效且不给出任何报错,新手往往误以为脚本正常运行。建议始终用 [has_elections](/wiki/trigger/has_elections) 做前置检查。
  2. 误用 scope 层级:此 effect 作用于 COUNTRY scope,若在 STATE 或 CHARACTER scope 下直接书写而未切换回国家 scope,游戏会忽略该指令或报脚本错误,需确认当前执行块的 scope 是否为目标国家。

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

hold_election is commonly used in political events for democratic nations to simulate periodic elections or snap election scenarios—for example, triggering an immediate election to change the ruling party after a player completes a focus. It is also suitable for scripted moments such as civil war conclusion or puppet independence, allowing forced elections to legitimize the new regime.

# Immediately hold an election after a nation completes a focus
focus = {
    id = GER_hold_snap_election
    ...
    completion_reward = {
        hold_election = ROOT
    }
}

Synergy

  • [has_elections](/wiki/trigger/has_elections) — Use this trigger first to check whether the target nation has elections enabled, preventing logic errors from calling hold_election in non-democratic systems.
  • [add_popularity](/wiki/effect/add_popularity) — Adjust ideology support levels before the election so that results align with the intended narrative rather than being entirely random.
  • [add_political_power](/wiki/effect/add_political_power) — Elections often involve expenditure or gain of political capital; using these together simulates the political cost of elections.
  • [country_event](/wiki/effect/country_event) — Trigger follow-up events after an election to handle the branching outcomes of "who wins the election," forming a complete election event chain.

Common Pitfalls

  1. Calling on non-democratic regime nations: hold_election only has actual effect on nations with election systems enabled. If the target nation's current government form has elections disabled, the command will silently fail without error messages, leading newcomers to mistakenly believe the script is working correctly. Always use [has_elections](/wiki/trigger/has_elections) as a prerequisite check.
  2. Misusing scope levels: This effect operates on COUNTRY scope; if written directly under STATE or CHARACTER scope without switching back to country scope, the game will ignore the command or report a script error. Always verify that the current execution block's scope is the target nation.