trigger · energy_ratio
Definition
- Supported scope:
COUNTRY - Supported target:
none
Description
energy_ratio > 0.8 - Compare current energy fulfilment to the factories, with 1 being 100% and 0 being 0%
energy_ratioCOUNTRYnoneenergy_ratio > 0.8 - Compare current energy fulfilment to the factories, with 1 being 100% and 0 being 0%
实战内容由 AI 生成,并已对照 vanilla 命令词表校验 —— 请当作起点而非权威依据。上方的定义节才是游戏自带文档原文。
energy_ratio 常用于判断某国电力/能源供应是否充足,适合在工业决策、国策完成条件或 AI 战略 mod 中作为解锁条件——例如只有当能源满足率达到一定水平时才允许扩大军工生产或触发特定事件。也可用于动态难度 mod 中,当能源严重不足时强制触发惩罚事件。
# 仅当能源供应充足时才允许触发该决策
available = {
energy_ratio > 0.8
num_of_factories > 20
}
# 在国家事件中,能源不足时施加惩罚想法
trigger = {
energy_ratio < 0.5
has_war = yes
}
energy_ratio 低于阈值时配合该 effect 添加"能源短缺"惩罚 idea,形成完整的条件→后果逻辑链。energy_ratio > 0.8 表示能源充足,而 energy_ratio < 0.8 表示能源不足,新手有时因语义混淆将判断方向搞反,导致条件在完全相反的情况下触发。energy_ratio 衡量的是电力/能源对工厂的满足比例,与燃料系统(fuel)无关;若想判断燃料充足度,应使用 fuel_ratio 而非本 trigger。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.
energy_ratio is commonly used to check whether a country's power/energy supply is sufficient. It works well as an unlock condition in industrial decisions, national focus completion requirements, or AI strategy mods — for example, allowing expanded military-industrial production or triggering specific events only when the energy satisfaction rate reaches a certain level. It can also be used in dynamic difficulty mods to force penalty events when energy is critically low.
# Only allow this decision to fire when energy supply is sufficient
available = {
energy_ratio > 0.8
num_of_factories > 20
}
# In a country event, apply a penalty idea when energy is insufficient
trigger = {
energy_ratio < 0.5
has_war = yes
}
energy_ratio falls below a threshold, pair this with the effect to add an "energy shortage" penalty idea, forming a complete condition → consequence logic chain.energy_ratio > 0.8 means energy is sufficient, while energy_ratio < 0.8 means energy is insufficient. Beginners sometimes mix up the semantics and flip the comparison direction, causing the condition to fire under exactly the opposite circumstances.energy_ratio measures the ratio of power/energy supply satisfying factory demand — it has nothing to do with the fuel system. If you want to check fuel sufficiency, use fuel_ratio instead of this trigger.