Polak

Léonard devint ch'ti
3 Badges
Sep 24, 2001
2.865
11
  • For The Glory
  • March of the Eagles
  • 500k Club
Hi !

For many events, i use the setflag and clr flag command to help me for triggering some events. By this mean, i'm avoiding some script lines

For exemple, i create this event :
#Support for the Avignon Papacy
event = {
id = 101001
trigger = {
event = 100
}
random = no
country = FRA
name = "Le schisme d'occident"
desc = " "

date = { day = 15 month = november year = 1378 }
offset = 15
deathdate = { day = 1 month = january year = 1417 }

action = {
name = "Soutien à Clément VII"
ai_chance = 80
command = { type = religion which = avignon_catholic }
command = { type = setflag which = [schism] }
command = { type = relation which = PAP value = -150 }
}
action = {
name = "Urbain VI est le vrai pape"
ai_chance = 20
command = { type = relation which = PAP value = 50 }
}
}
with this event, Charles V of France support the papacy of Avignon. after that, i wanted that every french minors follow its suzerain, like this...

event = {
id = 101002
trigger = {
flag = [schism]
}
random = no
country = BUR
name = "Le schisme d'occident"
desc = "Suite au choix de Charles V, les ducs français durent suivre l'opinion de leur souverain."

date = { day = 1 month = december year = 1378 }
offset = 15
deathdate = { day = 1 month = january year = 1417 }

action = {
name = "Soutien à Clément VII"
ai_chance = 80
command = { type = religion which = avignon_catholic }
command = { type = relation which = PAP value = -50 }
}
action = {
name = "Urbain VI est le vrai pape"
ai_chance = 20
command = { type = relation which = PAP value = 50 }
command = { type = relation which = FRA value = -50 }
}
}

But this event never happens. I was thinking that a flag trigger could be use for every countries, but i seems that it can serve only for the country which had the setflag command. Am I wrong ?

Is it possible to improve FTG to use a flag trigger for all countries ?
 

Ober

Sir Anjin
20 Badges
Sep 15, 2009
650
381
  • Darkest Hour
  • Europa Universalis IV: Res Publica
  • Heir to the Throne
  • For The Glory
  • Europa Universalis IV: Wealth of Nations
  • Europa Universalis IV: Conquest of Paradise
  • Europa Universalis IV: Art of War
  • Europa Universalis IV
  • Divine Wind
  • Europa Universalis III Complete
  • Deus Vult
  • Crusader Kings II
  • Europa Universalis III Complete
  • Europa Universalis III Complete
  • Victoria 2
  • War of the Roses
  • 500k Club
  • Europa Universalis IV: El Dorado
  • Europa Universalis IV: Common Sense
  • Cities: Skylines
I had the same problem recently with A4K events. And it seems that no, flags being set by setflag (not major flags - 1, 2, etc.) are not working for all states. Only for countries who get the event.

I went to Havard Bible to check it and unfortunately this seems to settle debate:

Code:
command = { type = setflag   which = [flag name] }

Sets the specified user country flag (flag is set to 'yes'). The flag can be triggered upon with the flag trigger.

In this case above you could simply make second option (about supporting Pope I assume) sleep second event by adding sleepevent.
 

Polak

Léonard devint ch'ti
3 Badges
Sep 24, 2001
2.865
11
  • For The Glory
  • March of the Eagles
  • 500k Club
I feared the answer, but that confirms my doubts

It would be good to have this globalflag command... otherwise, it's 17 sleepevent i have to add in my event:eek:


MichelM.. if you read us :)
 

MichaelM

For the Glory lead
10 Badges
Jun 30, 2004
3.798
99
crystalempiregames.com
  • Europa Universalis III Complete
  • Divine Wind
  • Europa Universalis IV
  • For The Glory
  • Heir to the Throne
  • Europa Universalis III Complete
  • Europa Universalis III Complete
  • Victoria 2
  • 500k Club
No reason to have a global flag when you can use
Code:
FRA = { flag = schism }
This is actually the reason we did not implement global flags.

And if you're worried about France not existing, then use MUS or one of the dummy countries (REB, MER, PIR, NAT). They're guaranteed to always exist.
 

Polak

Léonard devint ch'ti
3 Badges
Sep 24, 2001
2.865
11
  • For The Glory
  • March of the Eagles
  • 500k Club
:eek: Simply cleaver, and i never noticed that.

I tested, and now, all work's fine.
Many thanks