trigger · has_border_war_with
Definition
- Supported scope:
STATE,COUNTRY - Supported target:
any
Description
Checks if a there is a border against a state/country
has_border_war_withSTATE, COUNTRYanyChecks if a there is a border against a state/country
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.
has_border_war_with is commonly used as a trigger condition in events or decisions related to border wars, such as determining whether a country is engaged in a border conflict with a specific neighbor, thereby activating decision chains for diplomatic mediation, reinforcement, or ending the border war. In the following example, a decision is only allowed to trigger when a country has an active border war with Germany:
available = {
has_border_war_with = GER
}
It can also be used within STATE scope to check whether a state is currently in a border war, useful for restricting the triggering of construction or recruitment effects.
[has_border_war](/wiki/trigger/has_border_war): Used to first check whether any border war currently exists (without specifying a target), then use has_border_war_with to precisely identify the specific belligerent. These two are often paired together to form layered filtering.[divisions_in_border_state](/wiki/trigger/divisions_in_border_state): Border wars typically involve military deployments. Using them together allows you to check the number of divisions in border states and assess the intensity of the conflict.[any_neighbor_country](/wiki/trigger/any_neighbor_country): When you need to iterate through all neighboring countries and check each one for active border wars, has_border_war_with is commonly nested within this scope.[declare_war_on](/wiki/effect/declare_war_on): After a border war ends, a full declaration of war logic often follows. Use has_border_war_with as a limit condition to ensure the effect upgrades to formal war only when a border war exists.has_border_war_with only applies to the Border War mechanism and does not work for formal wars initiated through declare_war_on. If you need to detect formal wars, use other triggers instead.