Hands-On Usage
In civil war-related mods, use this effect when you want to manually terminate a country's status as a civil war belligerent through events or decisions—for example, designing a "peace agreement" decision that removes a split-off civil war faction from both sides' target lists, preventing the civil war logic from continuing to trigger.
# Example civil war peace agreement decision effect block
option = {
name = civil_war_peace.opt_a
# Remove REBelion from both sides' civil war targets
remove_civil_war_target = REB
add_political_power = -50
}
Synergy
[add_civil_war_target](/wiki/effect/add_civil_war_target): These two are inverse operations of each other. Typically use add_civil_war_target to register targets when civil war begins and remove_civil_war_target to unregister when it ends or is resolved. Using them as paired operations allows precise control over the civil war belligerent roster.
[civilwar_target](/wiki/trigger/civilwar_target): Before executing the removal, use this trigger to check whether a specific TAG is actually a current civil war target. This prevents erroneous logic branches from attempting to remove non-existent targets.
[has_civil_war](/wiki/trigger/has_civil_war): Use as a prerequisite condition to execute the removal only when the country is actually in a state of civil war, avoiding idle execution in non-civil war scenarios.
[annex_country](/wiki/effect/annex_country): In peace agreement or suppression scenarios, it is common to follow removal of civil war targets with annexation or integration of the rebellious faction. The two are frequently used together in the same option block.
Common Pitfalls
- Incorrect scope targeting: This effect must be executed under a legal COUNTRY scope. Many newcomers call it directly in event options at state scope, which causes the command to be ineffective or even produce errors. You should first confirm the current scope is national using
ROOT / THIS or similar.
- TAG input works for both sides but only affects "registered" targets: If the TAG was never registered as a civil war target through
add_civil_war_target, executing this command will not error but will have no effect. This easily leads to the mistaken belief that the civil war status has been cleared while leaving downstream logic bugs unresolved.