[edit]somehow the indentation did not show... , sorry if it is hard to read the event code[/edit]
I apologize for asking so many noob questions
o
but since I failed first year computer science because of the logics... oh well
Anyway, I am trying to write 2 separate events, the first one forces JAP into an alliance with CHI:
The second event is an event that portraits an ambitious industrialization project launched by Kuomingtang AFTER CHINA IS UNITED
So is this how I would write it ? :
)
I hope I didn't forget any other countries that CHI has claims of territory for...
and besides, is there a limit on how many "commands" an event can have?
And one last question about the
Say, Event B would only fire, given that Event A (with command = { type = trigger which = event_B_ID }defined) had fired, AND that it must also match the trigger = { whatever situation that triggers event B } for B, so that event B does not accidently fire by itself just because the situation matches the trigger of B.
Sorry for a rather chaotic post, but I really could not find other ways to organize them
o
I apologize for asking so many noob questions
but since I failed first year computer science because of the logics... oh well
Anyway, I am trying to write 2 separate events, the first one forces JAP into an alliance with CHI:
The event seemed to fire fine, but the problem being that as I move the cursor to the button for action A, only peace showed up in the blue pop-up box. And indeed, as I pressed it, only peace was concluded, not an alliance.###########################################
####Sino-Japanese Alliance###########
###########################################
event = {
id = 9505
random = no
country = CHI
trigger = {
war = { country = CHI country = JAP }
control = { province = 1190 data = CHI } #Fukuoka?
control = { province = 1184 data = CHI } #Hiroshima?
control = { province = 1185 data = CHI } #Osaka?
control = { province = 1186 data = CHI } #Nagoya
control = { province = 1187 data = CHI } #Kana... something
control = { province = 1188 data = CHI } #Tokyo
random = 80
}
name = "Sino-Japanese Alliance?"
desc = "CHI offers JAP alliance (I will modify later)"
picture = "I_have_not_decided_yet"
style = 0
date = { day = 9 month = january year = 1936 }
offset = 5
deathdate = { day = 29 month = december year = 1953 }
action_a = {
name = "Form an alliance!"
command = { type = peace which = JAP value =
1 }
command = { type = alliance which = JAP }
}
}
The second event is an event that portraits an ambitious industrialization project launched by Kuomingtang AFTER CHINA IS UNITED
So is this how I would write it ? :
(The above cheating value inputs are for tests only###########################################
###Kuomingtang's ambitious project###########
###########################################
event = {
id = 9504
random = no
country = CHI
trigger = {
NOT = {
war = { country = JAP country = CHI }
exists = CGX
exists = CSX
exists = CHC
exists = CXB
exists = CYN
exists = SIK
exists = TIB
exists = MAN
exists = MEN
}
random = 50
}
name = "Ambitious Project"
desc = "What else needs to be said?"
picture = "transfer"
style = 0
date = { day = 0 month = may year = 1939 }
offset = 10
deathdate = { day = 29 month = december year = 1953 }
action_a = {
name = "China is finally on par with the West."
command = { type = add_prov_resource which =
1360 value = 200 where = metal }
command = { type = add_prov_resource which =
1360 value = 800 where = energy }
command = { type = add_prov_resource which =
1360 value = 400 where = rare_materials }
command = { type = add_prov_resource which =
1360 value = 105 where = oil }
command = { type = construct which = ic where
= 1360 value = 80 }
command = { type = add_prov_resource which =
}
}
I hope I didn't forget any other countries that CHI has claims of territory for...
and besides, is there a limit on how many "commands" an event can have?
And one last question about the
command. Can this be used as part of a trigger of an other event? (I don't mean like sticking it into the trigger = {} )command = { type = trigger which = XXXX }
Say, Event B would only fire, given that Event A (with command = { type = trigger which = event_B_ID }defined) had fired, AND that it must also match the trigger = { whatever situation that triggers event B } for B, so that event B does not accidently fire by itself just because the situation matches the trigger of B.
Sorry for a rather chaotic post, but I really could not find other ways to organize them
Last edited: