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

Polak

Léonard devint ch'ti
3 Badges
Sep 24, 2001
2.869
14
  • 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 ?
 
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.
 
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 :)
 
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.
 
:eek: Simply cleaver, and i never noticed that.

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