trigger · is_operative_captured
Definition
- Supported scope:
CHARACTER - Supported target:
none
Description
Checks whether the operative has the matching captured status
is_operative_capturedCHARACTERnoneChecks whether the operative has the matching captured status
实战内容由 AI 生成,并已对照 vanilla 命令词表校验 —— 请当作起点而非权威依据。上方的定义节才是游戏自带文档原文。
is_operative_captured 常用于特工相关事件或决策中,判断某个特工角色当前是否处于被俘状态,从而触发营救任务、外交谈判或惩罚逻辑。例如在一个特工营救事件中,只有当该特工确实被俘时才允许玩家选择营救选项:
# 在某个事件的选项 available 块中
option = {
name = my_event.option_rescue
available = {
scope:target_operative = {
is_operative_captured = yes
}
}
# 后续 effect...
}
[free_operative](/wiki/effect/free_operative):确认特工处于被俘状态后,营救成功时调用此 effect 将其释放,两者形成"判断→处理"的完整流程。[kill_operative](/wiki/effect/kill_operative):当被俘特工有叛变风险时,可在确认被俘后选择将其处决,避免情报泄露。[operative_leader_mission](/wiki/trigger/operative_leader_mission):可与其联用,进一步区分特工是在执行何种任务时被捕,从而实现更细粒度的分支逻辑。[has_character_flag](/wiki/trigger/has_character_flag):配合角色标记使用,防止同一被俘事件反复触发,或追踪该特工是否已经历过某段剧情。CHARACTER scope 下使用,若直接写在国家 scope 的 trigger 块中而未通过 scope: 或 any_character 等方式切入角色 scope,会导致脚本报错或静默失败,新手常忘记切换 scope。is_operative_captured = no 表示特工未被俘,部分新手误以为该写法无效或与 NOT = { is_operative_captured = yes } 行为不同,实际两者等价,但在嵌套逻辑中混用容易造成条件判断方向错误。