trigger · is_theorist
Definition
- Supported scope:
CHARACTER - Supported target:
none
Description
is_theorist = yes/no - Checks if the character in scope is hired as a theorist
is_theoristCHARACTERnoneis_theorist = yes/no - Checks if the character in scope is hired as a theorist
实战内容由 AI 生成,并已对照 vanilla 命令词表校验 —— 请当作起点而非权威依据。上方的定义节才是游戏自带文档原文。
is_theorist 常用于需要区分顾问角色类型的 mod 场景,例如在某个决策或事件中,仅对当前担任理论家职位的角色触发特殊效果(如额外特质或升级)。在动态顾问系统中,也可用于防止重复逻辑触发。
# 事件选项:若该角色正担任理论家,则为其增加技能
character_event = {
id = my_mod.42
title = "理论突破"
option = {
name = "继续研究"
trigger = {
FROM = {
is_theorist = yes
}
}
FROM = {
add_skill_level = 1
}
}
}
[is_hired_as_advisor](/wiki/trigger/is_hired_as_advisor):与 is_theorist 配合可以区分"是否被雇用为顾问"与"是否具体担任理论家角色",双重校验避免逻辑漏洞。[has_advisor_role](/wiki/trigger/has_advisor_role):用于进一步确认角色拥有的顾问角色类型,与 is_theorist 组合可构建更精确的角色筛选条件。[add_trait](/wiki/effect/add_trait):确认角色为理论家后,为其赋予专属特质,是最常见的后续 effect 搭配。[remove_advisor_role](/wiki/effect/remove_advisor_role):在满足特定条件时移除理论家职位,通常以 is_theorist = yes 作为前置 limit 保护,确保不会对非理论家误操作。is_theorist 必须在 CHARACTER scope 下使用,新手容易直接写在国家 scope 的 trigger 块中,导致脚本报错或静默失效,需用 country_leader = { is_theorist = yes } 等方式先切换 scope。is_advisor 混用:is_advisor 只检查角色是否被雇用为顾问,而 is_theorist 专指理论家职位;两者并不等价,仅用 is_advisor = yes 无法保证该角色担任的是理论家职位。