• 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.

Test123456

Recruit
8 Badges
Oct 30, 2014
7
0
  • Crusader Kings II
  • Europa Universalis IV
  • Pillars of Eternity
  • Stellaris
  • Shadowrun Returns
  • Shadowrun: Dragonfall
  • Shadowrun: Hong Kong
  • Crusader Kings III
Is it possible apply damage or army modifier to an army form an event?

For example can I attach event in on_army_killed_in_combat and inside it use every_ground_combat_defender/every_ground_combat_attacker to iterate through and damage/add modifier to armies based on whose army got destroyed?

There is modify_army effect but i only saw it being able to change army types. I guess one could mod in additional unbuildable army types debuffed_<army_type> and switch armies to its corresponding debuffed variant and then in an event after invasion ended revert them back but that would be very tedious.

There is a set_army_flag/remove_army_flag but i'm not sure if and how that could be used to add modifier. Can there be always present modifier whose effects depend on presence of a flag?

Bonus points if there is a way to check if army is in frontline, reserves or disengaged.