trigger · casualties
Definition
- Supported scope:
COUNTRY - Supported target:
none
Description
Check the amount of casualties a country has suffered in all of it's wars
casualtiesCOUNTRYnoneCheck the amount of casualties a country has suffered in all of it's wars
实战内容由 AI 生成,并已对照 vanilla 命令词表校验 —— 请当作起点而非权威依据。上方的定义节才是游戏自带文档原文。
casualties 常用于战争主题的成就/决议解锁条件,例如判断某国是否经历了足够惨烈的战争消耗,或在事件中触发"战争疲劳"相关剧情分支。也可用于 AI 策略权重调整,让伤亡惨重的国家自动倾向于求和或外交路线。
# 当某国伤亡超过阈值时才允许触发停战决议
available = {
casualties > 500000
}
[has_casualties_war_support](/wiki/trigger/has_casualties_war_support):两者常同时出现在同一 trigger 块中,前者量化累计伤亡总数,后者检查伤亡是否已影响战争支持度,共同描绘"战争疲惫"状态。[has_war_support](/wiki/trigger/has_war_support)(此处应为)[has_bombing_war_support](/wiki/trigger/has_bombing_war_support):轰炸与伤亡都会侵蚀民心,搭配使用可构建多维度的厌战条件判断。[add_war_support](/wiki/effect/add_war_support):在伤亡达到阈值后通过 effect 扣减战争支持度,形成"高伤亡 → 触发 → 降低 war support"的完整逻辑链。[casualties_k](/wiki/trigger/casualties_k):同为伤亡类 trigger,casualties_k 以千为单位书写数值,与 casualties 混用时需注意单位不同,可按数量级选择更合适的一个。casualties 的数值是人头数(如 500000),而白名单中同时存在 casualties_k(以千为单位写 500),两者功能相近但数值写法完全不同,混用会导致条件永远不触发或永远为真。any_owned_state 的子块里),脚本不会报错但判断结果将不可预期,需确保外层 scope 指向的是国家标签。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.
casualties is commonly used in war-themed achievements and decision unlock conditions, such as determining whether a country has experienced sufficiently devastating war attrition, or triggering "war fatigue" narrative branches in events. It can also be used for AI strategy weight adjustments, allowing heavily damaged nations to automatically lean towards peace or diplomatic routes.
# Allow ceasefire decision only when casualties exceed threshold
available = {
casualties > 500000
}
[has_casualties_war_support](/wiki/trigger/has_casualties_war_support): Frequently appears alongside this trigger in the same trigger block. The former quantifies cumulative casualties, while the latter checks whether casualties have impacted war support, together depicting a "war fatigue" state.[has_bombing_war_support](/wiki/trigger/has_bombing_war_support): Both bombing and casualties erode public morale. Using them together constructs multi-dimensional war weariness condition checks.[add_war_support](/wiki/effect/add_war_support): After casualties reach the threshold, use effects to reduce war support, forming a complete logical chain: "high casualties → trigger → reduce war support".[casualties_k](/wiki/trigger/casualties_k): Also a casualties-type trigger. casualties_k uses thousands as the unit, and when mixed with casualties, be aware of the different units. Choose the more appropriate one based on the magnitude of numbers.casualties is in headcount (e.g., 500000), while the whitelist simultaneously contains casualties_k (written in thousands as 500). Though functionally similar, the value formats are completely different. Mixing them causes conditions to never trigger or always evaluate true.any_owned_state sub-block), the script won't error but the judgment will be unpredictable. Ensure the outer scope points to a country tag.