Hands-On Usage
This trigger is most commonly used within the on_nuke_drop on-action to determine how many nuclear warheads remain before the current nation finishes its nuclear strike round, thereby triggering additional event chains or penalty logic (for example, deducting stability when performing "rapid multi-nuke strikes"). It can also be employed in the available block of custom decisions to dynamically disable certain diplomatic options during an ongoing nuclear strike.
on_nuke_drop = {
trigger = {
num_nukes_left_to_drop > 0
}
effect = {
add_stability = -0.05
country_event = { id = my_mod.nuke_chain.1 }
}
}
Synergy
[has_country_flag](/wiki/trigger/has_country_flag): Set a flag during multi-nuke strikes, then use this trigger to check remaining quantities, enabling multi-stage event chains with step-by-step progression and preventing duplicate triggers.
[add_nuclear_bombs](/wiki/effect/add_nuclear_bombs): Dynamically supplement or deduct nuclear warhead stockpiles based on trigger results during on-actions, creating a "nuclear quantity linkage" design pattern.
[has_country_leader_with_trait](/wiki/trigger/has_country_leader_with_trait): Combine with leader traits to differentiate remaining strike rounds between different leaders, implementing varied penalty or reward logic during nuclear strikes.
[add_war_support](/wiki/effect/add_war_support): Adjust war support proportionally with the remaining nuclear warhead count during multi-nuke strikes, simulating the impact of sustained nuclear bombardment on domestic morale.
Common Pitfalls
- Limited value outside on-actions: This trigger only holds valid values during the nuclear strike sequence within the same game tick. If placed in a regular decision or focus's
available block (not driven by a nuke event), it almost always returns 0, causing conditions to never be satisfied. Newcomers often mistakenly assume this is a syntax error.
- Comparison operator direction confusion:
num_nukes_left_to_drop > 1 and num_nukes_left_to_drop < 1 have completely opposite meanings. If the script intends to detect "this is the final warhead," use < 2 (or = 1); writing > 1 instead means "multiple warheads remain," reversing the logic entirely. The game will not report an error, making this extremely difficult to debug.