-
Notifications
You must be signed in to change notification settings - Fork 0
Collapse file tree
Files
Search this repository
/
Copy pathtriggers.txt
More file actions
More file actions
1231 lines (1047 loc) · 33.4 KB
/
triggers.txt
File metadata and controls
1231 lines (1047 loc) · 33.4 KB
You must be signed in to make or propose changes
More edit options
Edit and raw actions
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
1199
1200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210
1211
1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
1222
1223
1224
1225
1226
1227
1228
1229
1230
1231
#--------------------------------------------------------------------------------
# Dual-scope Triggers
#--------------------------------------------------------------------------------
always = yes / no
log = "[Root.GetName] text here"
ironman = yes / no
has_dlc = <dlc> # Only for gameplay DLCs
is_random_new_world = yes / no
is_month = <month>
is_year = <year>
real_day_of_year = <day>
real_month_of_year = <month>
start_date = <date> # Returns true only on exact date
started_in = <date>
has_game_started = yes
has_global_flag = <flag>
had_global_flag = {
flag = <flag>
days = <days>
}
normal_or_historical_nations = yes / no # Checks if the normal country setup is being used
normal_province_values = yes / no # Checks if the normal province setup is being used
num_of_custom_nations = <int>
check_variable = {
which = <var>
value = <float>
which = <var> # Used to compare
}
is_variable_equal = {
which = <var>
value = <float>
which = <var> # Used to compare
}
# Highlights provinces for decisions and missions
# Acts as all_province scope
provinces_to_highlight = {
<trigger>
}
#--------------------------------------------------------------------------------
# Country-scope Triggers
#--------------------------------------------------------------------------------
# ----- General -----
tag = <scope>
was_tag = <scope>
exists = yes / <scope>
ai = yes
luck = yes / no
was_player = yes / no
has_switched_nation = yes / no
has_saved_event_target = <event target>
has_country_flag = <flag>
has_country_modifier = <flag>
had_country_flag = {
flag = <flag>
days = <days>
}
has_global_modifier_value = {
which = <modifier>
value = <float>
extra_shortcut = yes # Display tooltip as if the modifier is 100% + value
}
active_major_mission = <mission>
last_mission = <mission>
mission_completed = <mission>
has_custom_ideas = yes / no
is_playing_custom_nation = yes / no
nation_designer_points = <int>
is_dynamic_tag = yes
has_mission = <mission>
# ----- Cores, Claims and Territories -----
capital = <scope> / <id>
controls = <scope> / <id>
is_claim = <scope> / <id>
is_core = <scope> / <id>
is_state_core = <scope> / <id>
is_territorial_core = <scope> / <id>
owns = <scope> / <id>
owns_core_province = <scope> / <id>
owns_or_vassal_of = <scope> / <id>
owns_or_subject_of = <scope> / <id>
owns_or_non_sovereign_subject_of = <scope> / <id>
same_continent = <scope> / <id>
num_of_provinces_in_states = <int> / <scope>
num_of_provinces_in_territories = <int> / <scope>
num_of_states = <int> / <scope>
num_of_territories = <int> / <scope>
num_of_continents = <int>
num_of_cities = <int> / <scope>
core_percentage = <float>
# Checks if an amount of owned provinces meet the specified triggers
num_of_owned_provinces_with = {
value = <amount>
<triggers>
}
# ----- Economy -----
adm_power = <int> / <scope>
dip_power = <int> / <scope>
mil_power = <int> / <scope>
national_focus = <type>
total_base_tax = <int> / <scope>
total_development = <int>
treasury = <int> / <scope>
years_of_income = <float> / <scope>
monthly_income = <int> / <scope>
tax_income_percentage = <float>
gold_income_percentage = <float>
production_income_percentage = <float>
trade_income_percentage = <float>
inflation = <float> / <scope>
is_bankrupt = yes / no
is_in_deficit = yes / no
num_of_loans = <int> / <scope>
is_in_large_debt = yes
production_efficiency = <float> / <scope>
trade_efficiency = <float> / <scope>
production_leader = {
trade_goods = <trade good>
}
# Checks if the owned provinces of the current scope have the specified amount (or more) of the specified building
<building> = <int>
# Used in missions
share_of_starting_income = <float>
grown_by_development = <int>
grown_by_states = <int>
# ----- Trade -----
<tradegood> = <int>
mercantilism = <int> / <scope>
num_of_merchants = <int>
num_of_strong_trade_companies = <int>
num_of_trade_companies = <int>
num_of_trading_bonuses = <int>
num_of_trade_embargos = <int>
is_in_trade_league_with = <scope>
trade_embargoing = <scope>
trade_embargo_by = <scope>
trade_league_embargoed_by = <scope>
is_in_trade_league = yes
is_trade_league_leader = yes
num_of_centers_of_trade = <int>
has_center_of_trade_of_level = <int>
trading_bonus = {
trade_goods = <good>
value = yes / no
}
trading_part = {
trade_goods = <good>
value = <float>
}
# ----- Government -----
prestige = <int> / <scope>
absolutism = <int> / <scope>
corruption = <float>
yearly_corruption_increase = <float> / <scope>
government = <type> # Checks: monarchy, republic, tribal, dictatorship
government_rank = <int>
legitimacy = <int> / <scope>
republican_tradition = <int> / <scope>
horde_unity = <int> / <scope>
legitimacy_or_horde_unity = <int> / <scope>
devotion = <int> / <scope>
meritocracy = <int>
legitimacy_equivalent = <int> / <scope>
is_nomad = yes / no
is_tribal = yes / no
is_monarchists_in_power = yes
is_statists_in_power = yes
has_parliament = yes / no
has_active_debate = yes / no
current_debate = <string>
current_size_of_parliament = <int>
percentage_backing_issue = <float>
uses_devotion = yes
militarised_society = <int>
tribal_allegiance = <int> / <scope>
statists_vs_orangists = <float> # 0 to 1
# Types: russian_mechanic, feudal_theocracy_mechanic, tribal_federation_mechanic, mamluk_mechanic, iqta_mechanic
has_government_mechanic = <type>
# Type: ADM, DIP, MIL
has_government_power = {
type = <type>
value = <amount>
}
# Attributes:
# Legitimacy - monarchy, republic, religion, tribal, dictatorship, nomad, papacy, has_meritocracy, has_devotion
# Abilities - militarised_society, has_parliament, allow_migration, claim_states, native_mechanic
# Ruler - heir, queen, has_term_election, election_on_death, is_elective
# Other - republican_name, valid_for_nation_designer, allow_normal_conversion
has_government_attribute = <attribute>
has_states_general_mechanic = <bool>
has_reform = <reform>
is_reform_available = <reform>
have_had_reform = <reform>
government_reform_progress = <int>
has_reform_level = <int>
# ----- Court -----
has_advisor = yes
<advisortype> = <skill>
advisor = <advisor>
advisor_exists = <advisor id> # Historical advisors only
is_advisor_employed = <advisor id> # Historical advisors only
# Checks if the current scope has an advisor hired with the specified attributes.
employed_advisor = {
type = <advisortype>
category = <type> # ADM / DIP / MIL
religion = <scope> / <religion> / true_faith / heretic / heathen
culture = <scope> / <culture>
is_male = yes
is_female = yes
}
# ----- Culture -----
primary_culture = <culture> / <scope>
accepted_culture = <culture> / <scope>
culture_group = <culture group> / <scope>
dominant_culture = <culture> / <capital>
has_unified_culture_group = yes
num_accepted_cultures = <int>
# ----- Religion -----
religion = <religion> / <scope> / secondary
religion_group = <religion group> / <scope>
dominant_religion = <religion group> / <scope> / capital / secondary
secondary_religion = <religion> / <scope>
papacy_active = yes / no
total_number_of_cardinals = <int>
papal_influence = <int> / <scope>
authority = <int> / <scope> # (0 to max)
doom = <int> / <scope> # (0 to max)
church_power = <int> / <scope> # (0 to max)
calc_true_if = {
#triggers
amount = 3
}
#It can be used with multiple triggers, and it returns true if at least X amount of the triggers return true
calc_true_if = {
ADM = 4
religion = catholic
full_idea_group = religious_ideas
religious_unity = 1.0
is_papal_controller = yes
amount = 3
}
#So this will return true if at least 3 of these 5 triggers are true
#This trigger funtions differently if using one of the all_ triggers
#Country Scope Example
calc_true_if = {
all_country = {
religion = protestant
}
amount = 5
}
#This will return true if there are at least 5 Protestant countries in the world
#Province Scope Example
calc_true_if = {
all_owned_province = {
has_terrain = marsh
}
amount = 2
}
#This will return true if the scope has at least two provinces that have the marsh terrain
#Scripted Triggers (defined in common\scripted_triggers)
scripted_triggers_name = yes #no doesn't work, must use NOT = { scripted_triggers_name = yes }
#--------------------------------------------------------------------------------
# Removed
#--------------------------------------------------------------------------------
has_sphere = #EU IV doesn't use spheres in the way that EU III did.
in_sphere_of = # EU IV doesn't use spheres in the way that EU III did.
leads_coalition = yes #never found in code, coalitions no longer have leaders
num_of_free_ideas = #never found in code, tested and wasn't working properly
num_of_total_ideas = #never found in code, tested and wasn't working properly
num_of_placed_merchants = #never found in code. Not really needed since merchants are no longer a currency, they'll always be placed so can just count number of merchants.
num_of_trade_rights = #not found in code. I don't think there are trade rights in EU IV
pure_revolt_risk = 3 #Removed as of patch 1.8
revolt_risk = 1 #Removed as of patch 1.8
trade_leader = #Removed by Gars in 1.6 and didn't work before that
war_with_nomads = yes
is_colonial = yes / no
has_discovered_region = {
region = <region>
years = <int>
}
has_discovered_capital_region_of = {
who = <scope>
years = <int>
}
#This trigger is not localized
has_any_country_in_region_discovered_capital_region_of = {
region = <region>
who = <scope>
years = <int>
}
has_hre_emperor_modifier = test
has_hre_member_modifier = test
months_since_last_owner_change = 60 #never found in code and reported that it doesn't work
is_protectorate = yes