trigger · is_historical_focus_on
Definition
- Supported scope:
any - Supported target:
none
Description
check if the historical focus is active
is_historical_focus_onanynonecheck if the historical focus is active
实战内容由 AI 生成,并已对照 vanilla 命令词表校验 —— 请当作起点而非权威依据。上方的定义节才是游戏自带文档原文。
is_historical_focus_on 常用于区分"历史模式"与"自由模式",让 mod 在玩家选择了历史国策路线时提供不同的事件触发条件或限制分支。例如,在非历史模式下才允许某个"架空历史"国策或事件出现,避免与历史路线冲突。
# 仅在非历史模式时允许某个架空事件触发
available = {
NOT = { is_historical_focus_on = yes }
}
[has_game_rule](/wiki/trigger/has_game_rule):游戏规则与历史模式常同时影响分支逻辑,组合使用可精确控制特定规则+历史模式下的条件。[or](/wiki/trigger/or):当需要"历史模式开启 或 满足其他条件"时,包裹在 or 块中避免过于严格的限制。[not](/wiki/trigger/not):最高频的搭档,绝大多数架空/非历史分支都需要 NOT = { is_historical_focus_on = yes } 来反向判断。[has_dlc](/wiki/trigger/has_dlc):部分 DLC 内容只在特定游戏模式下有意义,与历史模式判断并列使用可做双重门控。NOT = { is_historical_focus_on = yes },逻辑反了。务必想清楚"历史开启"对应 = yes,"历史关闭"才需要套 NOT。is_historical_focus_on 仅是只读判断,无法通过任何 effect 在游戏中途强制开关历史模式,试图这样做的设计思路需要改用 set_global_flag 之类的变量来模拟替代标记。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.
is_historical_focus_on is commonly used to distinguish between "Historical Mode" and "Free Mode," allowing mods to provide different event triggers or branching restrictions when players select historical focus paths. For example, certain "alternate history" focuses or events can be allowed only in non-historical mode, preventing conflicts with historical routes.
# Allow an alternate history event to trigger only in non-historical mode
available = {
NOT = { is_historical_focus_on = yes }
}
[has_game_rule](/wiki/trigger/has_game_rule): Game rules and historical mode often influence branching logic simultaneously. Combined use allows precise control over conditions under specific rule + historical mode combinations.[or](/wiki/trigger/or): When you need "historical mode enabled or other conditions met," wrap within an or block to avoid overly restrictive constraints.[not](/wiki/trigger/not): The most frequent partner. The vast majority of alternate/non-historical branches require NOT = { is_historical_focus_on = yes } for inverse logic.[has_dlc](/wiki/trigger/has_dlc): Some DLC content is meaningful only in specific game modes. Using it alongside historical mode checks enables dual-gating control.NOT = { is_historical_focus_on = yes }, inverting the logic. Always clarify that "historical enabled" corresponds to = yes, and "historical disabled" requires wrapping in NOT.is_historical_focus_on is read-only and cannot be forcibly switched during gameplay through any effect. Design approaches attempting this should instead use alternatives like set_global_flag to simulate replacement flags.