Wiki

effect · activate_shine_on_focus

Definition

  • Supported scope:COUNTRY
  • Supported target:any

Description

Activates the shine effect on the focus with the given id. Focuses that are completed cannot have an activated shine effect.

Note that tooltips are only shown in debug mode.

### Example:

activate_shine_on_focus = GER_prioritize_economic_growth

实战 · 配合 · 坑

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

实战用法

activate_shine_on_focus 常用于需要动态引导玩家注意特定国策的 mod 场景,例如在完成某个前置任务后,用光效高亮下一步推荐的国策节点,提升玩家体验与叙事节奏。注意该效果仅在 debug 模式下显示提示,正式发布的 mod 中多作为视觉辅助使用。

country_event = {
    id = my_mod.1
    option = {
        name = my_mod.1.a
        # 完成事件后,高亮推荐玩家选择的下一个国策
        activate_shine_on_focus = GER_prioritize_economic_growth
    }
}

配合关系

  • [has_completed_focus](/wiki/trigger/has_completed_focus):在判断某个前置国策已完成后再激活光效,确保高亮的国策节点在流程上合理解锁,不会对已完成节点无效触发。
  • [deactivate_shine_on_focus](/wiki/effect/deactivate_shine_on_focus):与激活配合使用,在玩家选择了目标国策或条件变化后及时关闭光效,避免 UI 上残留不必要的高亮。
  • [complete_national_focus](/wiki/effect/complete_national_focus):当通过脚本强制完成国策时,应在此之前移除该国策上的 shine 效果,因为已完成的国策无法保持激活状态的光效。
  • [focus_progress](/wiki/trigger/focus_progress):可结合国策进度判断,在国策研究到特定阶段时触发光效,引导玩家关注即将完成的重要节点。

常见坑

  1. 对已完成国策使用:若目标国策已经被完成,activate_shine_on_focus 不会产生任何效果,新手常常忘记在调用前用 [has_completed_focus](/wiki/trigger/has_completed_focus) 进行判断保护,导致逻辑静默失败且难以排查。
  2. 忘记清理光效:激活 shine 后如果不在适当时机调用 [deactivate_shine_on_focus](/wiki/effect/deactivate_shine_on_focus) 关闭,光效会持续存在于国策树上,在玩家已经处理完相关流程后仍显示高亮,造成视觉混乱或误导。

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

activate_shine_on_focus is commonly used in mod scenarios where dynamic guidance is needed to direct player attention to specific focus nodes. For example, after completing a prerequisite task, you can use the shine effect to highlight the next recommended focus node, enhancing player experience and narrative pacing. Note that this effect only displays hints in debug mode; in officially released mods, it primarily serves as a visual aid.

country_event = {
    id = my_mod.1
    option = {
        name = my_mod.1.a
        # After event completion, highlight the next recommended focus for the player
        activate_shine_on_focus = GER_prioritize_economic_growth
    }
}

Synergy

  • [has_completed_focus](/wiki/trigger/has_completed_focus): After verifying that a prerequisite focus has been completed, activate the shine effect to ensure the highlighted focus node unlocks logically within the progression flow and won't trigger ineffectively on already-completed nodes.
  • [deactivate_shine_on_focus](/wiki/effect/deactivate_shine_on_focus): Use in conjunction with activation to promptly disable the shine effect after the player selects the target focus or when conditions change, preventing unnecessary highlight remnants on the UI.
  • [complete_national_focus](/wiki/effect/complete_national_focus): When forcibly completing a focus through script, the shine effect should be removed from that focus beforehand, as completed focuses cannot maintain an active shine state.
  • [focus_progress](/wiki/trigger/focus_progress): Can be combined with focus progress checks to trigger the shine effect when a focus reaches a specific research stage, guiding player attention to important nodes nearing completion.

Common Pitfalls

  1. Using on already-completed focuses: If the target focus has already been completed, activate_shine_on_focus will have no effect. Beginners often forget to guard the call with [has_completed_focus](/wiki/trigger/has_completed_focus) verification beforehand, resulting in silent logic failures that are difficult to debug.
  2. Forgetting to clean up the shine effect: If you fail to call [deactivate_shine_on_focus](/wiki/effect/deactivate_shine_on_focus) to disable the shine effect at an appropriate time after activation, it will persist on the focus tree. The highlight will continue displaying even after the player has finished the related progression, causing visual confusion or misleading guidance.