• We have updated our Community Code of Conduct. Please read through the new rules for the forum that are an integral part of Paradox Interactive’s User Agreement.

MoralMonster

Second Lieutenant
9 Badges
Apr 2, 2011
173
340
  • Europa Universalis IV: Art of War
  • Europa Universalis IV: Conquest of Paradise
  • Europa Universalis IV: Wealth of Nations
  • Europa Universalis IV: Res Publica
  • Europa Universalis IV
  • Victoria 2
  • 500k Club
  • Europa Universalis IV: El Dorado
  • Europa Universalis IV: Common Sense
Hi everyone. I want to make a small mod for myself which will add some special battle conditions that will trigger for attacker/defender army if it has activated certain mobilization options. I know that previously it was possible and some modmakers did things like thas. But after Paradox reworked warfare and introduced military formations, I don't know how to implement it. Would be grateful for any help.
 
Looking at a few different files, there is a scoping option commander_military_formation which comes from the commander/character scope and that can then use the mobilization trigger.

So something like
Code:
scope:character = {
    commander_military_formation = {
        has_mobilization_option = mobilization_option:mobilization_option_flamethrowers
    }
}
 
  • 1Like
Reactions:
There are several examples through the files, if you search for "unit_type" you'll find some

For example, in the vanilla battle conditions file there is formation_navy_unit_type_fraction and there is a similar one with "army" instead of "navy".

There is another scope trigger any_combat_unit that might work.

P.S. If you use Notepad++ or Visual Studio Code (or a similar program), you can search through the entire game folder for terms, which makes it somewhat easier to find examples of script that might do what you want. I use both programs and that's how I found these terms.
 
  • 1Like
Reactions: