Diff to HTML by rtfpessoa

Files changed (7) hide show
  1. common/government_mechanics/00_cossacks.txt +19 -17
  2. common/government_mechanics/01_feudal_theocracy.txt +175 -19
  3. common/government_mechanics/03_mamluk.txt +23 -4
  4. common/government_mechanics/05_tribal_federation.txt +44 -7
  5. common/government_mechanics/20_egyptian_westernization.txt +626 -0
  6. common/government_mechanics/20_persian_influence.txt +139 -0
  7. common/government_mechanics/21_the_three_royal_fires.txt +274 -0
common/government_mechanics/00_cossacks.txt CHANGED
@@ -32,25 +32,27 @@ cossacks_mechanic = {
32
32
  has_neighbor = yes
33
33
  }
34
34
  effect = {
35
- random_rival_country = {
36
- limit = {
37
- is_neighbor_of = root
38
- }
39
- save_event_target_as = source_country
40
- }
41
- if = {
42
- limit = {
43
- #use NOT here because changing the scopt to a non-existent country will fail anyway, giving us the check we want
44
- NOT = {
45
- event_target:source_country = {
46
- exists = yes
47
- }
35
+ hidden_effect = {
36
+ random_rival_country = {
37
+ limit = {
38
+ is_neighbor_of = root
48
39
  }
49
- }
50
- random_neighbor_country = {
51
40
  save_event_target_as = source_country
52
41
  }
53
- }
42
+ if = {
43
+ limit = {
44
+ #use NOT here because changing the scopt to a non-existent country will fail anyway, giving us the check we want
45
+ NOT = {
46
+ event_target:source_country = {
47
+ exists = yes
48
+ }
49
+ }
50
+ }
51
+ random_neighbor_country = {
52
+ save_event_target_as = source_country
53
+ }
54
+ }
55
+ }
54
56
  custom_tooltip = fleeing_serfs_tt
55
57
  hidden_effect = {
56
58
  random_owned_province = {
@@ -128,7 +130,7 @@ cossacks_mechanic = {
128
130
  create_unit_forcelimit_percentage = {
129
131
  type = cavalry
130
132
  special_unit_category = cossacks
131
- force_limit_percentage = 0.5
133
+ force_limit_percentage = 0.05
132
134
  }
133
135
  add_war_exhaustion = -2
134
136
  }
common/government_mechanics/01_feudal_theocracy.txt CHANGED
@@ -2,7 +2,10 @@ feudal_theocracy_mechanic = {
2
2
  alert_icon_gfx = GFX_alerticons_government_mechanics
3
3
  alert_icon_index = 4
4
4
  available = {
5
- has_dlc = "Cradle of Civilization"
5
+ OR = {
6
+ has_dlc = "Cradle of Civilization"
7
+ has_dlc = "King of Kings"
8
+ }
6
9
  }
7
10
 
8
11
  interactions = {
@@ -17,6 +20,46 @@ feudal_theocracy_mechanic = {
17
20
  name = seize_clerical_holdings_modifier
18
21
  duration = 1825
19
22
  }
23
+
24
+ if = {
25
+ limit = {
26
+ OR = {
27
+ has_country_flag = YEM_seize_clerical_holdings_clergy_crownland_flag
28
+ has_government_attribute = upgrade_feudal_theocracy
29
+ }
30
+ }
31
+ change_estate_land_share = {
32
+ estate = estate_church
33
+ share = -5
34
+ }
35
+ }
36
+ if = {
37
+ limit = {
38
+ has_country_flag = YEM_seize_clerical_holdings_every_temple_provinces_flag
39
+ }
40
+ add_country_modifier = {
41
+ name = YEM_global_tax_modifier_upgrade
42
+ duration = 1825
43
+ }
44
+ custom_tooltip = YEM_every_province_with_tax
45
+ tooltip = {
46
+ add_province_modifier = {
47
+ name = YEM_extra_buff_to_churches
48
+ duration = 1825
49
+ }
50
+ }
51
+ hidden_effect = {
52
+ every_owned_province = {
53
+ limit = {
54
+ has_tax_building_trigger = yes
55
+ }
56
+ add_province_modifier = {
57
+ name = YEM_extra_buff_to_churches
58
+ duration = 1825
59
+ }
60
+ }
61
+ }
62
+ }
20
63
  }
21
64
  cooldown_years = 5
22
65
  ai_chance = {
@@ -108,6 +151,49 @@ feudal_theocracy_mechanic = {
108
151
  add_random_development = 1
109
152
  }
110
153
  }
154
+
155
+ if = {
156
+ limit = {
157
+ OR = {
158
+ has_country_flag = ARB_upgrade_invite_minorities_flag
159
+ has_country_flag = YEM_invite_minorities_distribute_5_dev_flag
160
+ has_government_attribute = upgrade_feudal_theocracy
161
+ }
162
+ }
163
+ custom_tooltip = ABR_distribute_5_development_randomly
164
+ hidden_effect = {
165
+ for = {
166
+ amount = 5
167
+ effect = "
168
+ random_owned_province = {
169
+ add_random_development = 1
170
+ }
171
+ "
172
+ }
173
+ }
174
+ }
175
+
176
+ custom_tooltip = " "
177
+
178
+ if = {
179
+ limit = {
180
+ has_country_flag = YEM_invite_minorities_theologian_flag
181
+ }
182
+ random_province = {
183
+ limit = {
184
+ religion = ROOT
185
+ }
186
+ ROOT = {
187
+ define_advisor = {
188
+ type = theologian
189
+ skill = 3
190
+ cost_multiplier = 0.25
191
+ culture = PREV
192
+ religion = PREV
193
+ }
194
+ }
195
+ }
196
+ }
111
197
  }
112
198
  cooldown_years = 5
113
199
  ai_chance = {
@@ -128,34 +214,104 @@ feudal_theocracy_mechanic = {
128
214
  icon = GFX_sanction_holy_war_button
129
215
  trigger = {
130
216
  mil_power_cost = 50
131
- any_neighbor_province = {
132
- owner = {
133
- exists = yes
134
- not = { defensive_pact_with = ROOT }
135
- not = { religion = ROOT }
136
- }
137
- not = { is_claim = ROOT }
138
- not = { is_core = ROOT }
139
- has_discovered = ROOT
140
- }
141
- }
142
- effect = {
143
- mil_power_cost = 50
144
- every_neighbor_province = {
145
- limit = {
217
+ if = {
218
+ limit = { NOT = { has_government_attribute = upgrade_feudal_theocracy } }
219
+ any_neighbor_province = {
146
220
  owner = {
147
221
  exists = yes
148
222
  not = { defensive_pact_with = ROOT }
149
223
  not = { religion = ROOT }
150
224
  }
151
- not = { is_claim = ROOT }
225
+ not = { is_permanent_claim = ROOT }
152
226
  not = { is_core = ROOT }
153
227
  has_discovered = ROOT
154
228
  }
155
- add_claim = ROOT
156
229
  }
157
230
  }
158
- cooldown_years = 0
231
+ effect = {
232
+ mil_power_cost = 50
233
+ if = {
234
+ limit = {
235
+ has_government_attribute = upgrade_feudal_theocracy
236
+ }
237
+ hidden_effect = { capital_scope = { area = { limit = { owned_by = root } set_province_flag = manpower_source_flag } } }
238
+ custom_tooltip = sanction_holy_war_tt
239
+ hidden_effect = {
240
+ add_years_of_owned_provinces_manpower = {
241
+ custom_tooltip = sanction_holy_war_tt
242
+ years = 4
243
+ trigger = {
244
+ has_province_flag = manpower_source_flag
245
+ }
246
+ }
247
+ }
248
+ hidden_effect = { every_owned_province = { limit = { has_province_flag = manpower_source_flag } clr_province_flag = manpower_source_flag } }
249
+ }
250
+ if = {
251
+ limit = {
252
+ has_country_flag = YEM_sanction_holy_war_claims_permanent_flag
253
+ }
254
+ every_neighbor_province = {
255
+ limit = {
256
+ owner = {
257
+ exists = yes
258
+ not = { defensive_pact_with = ROOT }
259
+ not = { religion = ROOT }
260
+ }
261
+ not = { is_claim = ROOT }
262
+ not = { is_core = ROOT }
263
+ has_discovered = ROOT
264
+ }
265
+ add_permanent_claim = ROOT
266
+ }
267
+ }
268
+ else_if = {
269
+ limit = {
270
+ has_country_flag = YEM_sanction_holy_war_claims_areas_flag
271
+ }
272
+ every_neighbor_province = {
273
+ limit = {
274
+ owner = {
275
+ exists = yes
276
+ not = { defensive_pact_with = ROOT }
277
+ not = { religion = ROOT }
278
+ }
279
+ not = { is_claim = ROOT }
280
+ not = { is_core = ROOT }
281
+ has_discovered = ROOT
282
+ }
283
+ area = {
284
+ limit = {
285
+ owner = {
286
+ exists = yes
287
+ not = { defensive_pact_with = ROOT }
288
+ not = { religion = ROOT }
289
+ }
290
+ not = { is_claim = ROOT }
291
+ not = { is_core = ROOT }
292
+ has_discovered = ROOT
293
+ }
294
+ add_claim = ROOT
295
+ }
296
+ }
297
+ }
298
+ else = {
299
+ every_neighbor_province = {
300
+ limit = {
301
+ owner = {
302
+ exists = yes
303
+ not = { defensive_pact_with = ROOT }
304
+ not = { religion = ROOT }
305
+ }
306
+ not = { is_claim = ROOT }
307
+ not = { is_core = ROOT }
308
+ has_discovered = ROOT
309
+ }
310
+ add_claim = ROOT
311
+ }
312
+ }
313
+ }
314
+ cooldown_years = 5
159
315
  ai_chance = {
160
316
  factor = 10
161
317
  modifier = {
common/government_mechanics/03_mamluk.txt CHANGED
@@ -2,7 +2,10 @@ mamluk_mechanic = {
2
2
  alert_icon_gfx = GFX_alerticons_government_mechanics
3
3
  alert_icon_index = 3
4
4
  available = {
5
- has_dlc = "Cradle of Civilization"
5
+ OR = {
6
+ has_dlc = "King of Kings"
7
+ has_dlc = "Cradle of Civilization"
8
+ }
6
9
  }
7
10
 
8
11
  powers = {
@@ -34,9 +37,18 @@ mamluk_mechanic = {
34
37
  trigger = {
35
38
  }
36
39
  effect = {
37
- add_country_modifier = {
38
- name = promote_culture_in_government_modifier
39
- duration = 365
40
+ if = {
41
+ limit = { has_country_flag = promote_culture_government_duration_doubled_flag }
42
+ add_country_modifier = {
43
+ name = promote_culture_in_government_modifier
44
+ duration = 730
45
+ }
46
+ }
47
+ else = {
48
+ add_country_modifier = {
49
+ name = promote_culture_in_government_modifier
50
+ duration = 365
51
+ }
40
52
  }
41
53
  }
42
54
  cooldown_years = 1
@@ -116,6 +128,13 @@ mamluk_mechanic = {
116
128
  multiplier = 0.05
117
129
  age_multiplier = 1
118
130
  }
131
+ if = {
132
+ limit = {
133
+ has_country_flag = mam_boost_recruit_from_culture_lands_flag
134
+ has_dlc = "Cradle of Civilization"
135
+ }
136
+ add_army_professionalism = 0.02
137
+ }
119
138
  }
120
139
  cooldown_years = 1
121
140
  ai_chance = {
common/government_mechanics/05_tribal_federation.txt CHANGED
@@ -2,7 +2,10 @@ tribal_federation_mechanic = {
2
2
  alert_icon_gfx = GFX_alerticons_government_mechanics
3
3
  alert_icon_index = 5
4
4
  available = {
5
- has_dlc = "Cradle of Civilization"
5
+ OR = {
6
+ has_dlc = "Cradle of Civilization"
7
+ has_dlc = "King of Kings"
8
+ }
6
9
  }
7
10
 
8
11
  powers = {
@@ -30,8 +33,18 @@ tribal_federation_mechanic = {
30
33
  trigger = {
31
34
  }
32
35
  effect = {
33
- create_general = {
34
- tradition = 40
36
+ if = {
37
+ limit = {
38
+ has_country_flag = ARB_upgrade_enlist_general_flag
39
+ }
40
+ create_general = {
41
+ tradition = 60
42
+ }
43
+ }
44
+ else = {
45
+ create_general = {
46
+ tradition = 40
47
+ }
35
48
  }
36
49
  }
37
50
  cooldown_years = 0
@@ -96,14 +109,27 @@ tribal_federation_mechanic = {
96
109
  cost_type = tribal_allegiance
97
110
  cost = 30
98
111
  trigger = {
112
+ NOT = { has_country_modifier = ABR_train_horsemanship_modifier_upgraded }
113
+ NOT = { has_country_modifier = train_horsemanship_modifier }
99
114
  }
100
115
  effect = {
101
- add_country_modifier = {
102
- name = train_horsemanship_modifier
103
- duration = 3650
116
+ if = {
117
+ limit = {
118
+ has_country_flag = ARB_upgrade_train_horsemanship_flag
119
+ }
120
+ add_country_modifier = {
121
+ name = ABR_train_horsemanship_modifier_upgraded
122
+ duration = 5475
123
+ }
124
+ }
125
+ else = {
126
+ add_country_modifier = {
127
+ name = train_horsemanship_modifier
128
+ duration = 3650
129
+ }
104
130
  }
105
131
  }
106
- cooldown_years = 10
132
+ cooldown_years = 0
107
133
  ai_chance = {
108
134
  factor = 1
109
135
  modifier = {
@@ -155,6 +181,17 @@ tribal_federation_mechanic = {
155
181
  cost = 0
156
182
  }
157
183
  }
184
+ if = {
185
+ limit = {
186
+ OR = {
187
+ has_country_flag = turkoman_safavids_conscripted
188
+ has_country_flag = ARB_upgrade_conscript_from_the_tribes_flag
189
+ }
190
+ }
191
+ custom_tooltip = " "
192
+
193
+ add_yearly_manpower = 1
194
+ }
158
195
  }
159
196
  cooldown_years = 0
160
197
  ai_chance = {
common/government_mechanics/20_egyptian_westernization.txt ADDED
@@ -0,0 +1,626 @@
1
+ egyptian_westernization = {
2
+ available = {
3
+ has_dlc = "King of Kings"
4
+ }
5
+ powers = {
6
+ egyptian_westernization = {
7
+ gui = egyptian_westernization_gov_mech
8
+ show_before_interactions = yes
9
+ max = 100
10
+ reset_on_new_ruler = no
11
+ base_monthly_growth = -0.05
12
+ development_scaled_monthly_growth = 0
13
+ scaled_modifier = {
14
+ modifier = {
15
+ technology_cost = -0.1
16
+ idea_cost = -0.05
17
+ yearly_innovativeness = 0.25
18
+ }
19
+ }
20
+ reverse_scaled_modifier = {
21
+ modifier = {
22
+ all_estate_loyalty_equilibrium = 0.1
23
+ stability_cost_modifier = -0.25
24
+ tolerance_own = 1
25
+ }
26
+ start_value = 0
27
+ end_value = 50
28
+ }
29
+ scaled_modifier = {
30
+ modifier = {
31
+ all_estate_loyalty_equilibrium = -0.1
32
+ stability_cost_modifier = 0.25
33
+ tolerance_own = -1
34
+ }
35
+ start_value = 50
36
+ end_value = 100
37
+ }
38
+ is_good = yes
39
+ }
40
+ }
41
+ interactions = {
42
+ study_western_administration = {
43
+ icon = GFX_study_western_administration
44
+ gui = "egyptian_westernization_interaction_button"
45
+ cost_type = egyptian_westernization
46
+ cost = 30
47
+ trigger = {
48
+ custom_trigger_tooltip = {
49
+ tooltip = egyptian_westernization_trigger_tt
50
+ NOT = {
51
+ check_variable = {
52
+ which = egyptian_adm_westernization_var
53
+ value = 5
54
+ }
55
+ }
56
+ }
57
+ if = {
58
+ limit = { has_dlc = "Rule Britannia" }
59
+ innovativeness = 3
60
+ }
61
+ adm_power = 100
62
+ }
63
+ effect = {
64
+ if = {
65
+ limit = { has_dlc = "Rule Britannia" }
66
+ change_innovativeness = -3
67
+ }
68
+ add_adm_power = -100
69
+ if = {
70
+ limit = {
71
+ NOT = {
72
+ check_variable = {
73
+ which = egyptian_adm_westernization_var
74
+ value = 1
75
+ }
76
+ }
77
+ }
78
+ custom_tooltip = egyptian_adm_counter_1_tt
79
+
80
+ hidden_effect = {
81
+ remove_country_modifier = egyptian_adm_westernization_4_modifier
82
+ remove_country_modifier = egyptian_adm_westernization_3_modifier
83
+ remove_country_modifier = egyptian_adm_westernization_5_modifier
84
+ remove_country_modifier = egyptian_adm_westernization_2_modifier
85
+ change_government_reform_progress = 100
86
+ set_variable = {
87
+ which = egyptian_adm_westernization_var
88
+ value = 1
89
+ }
90
+ }
91
+ }
92
+ else_if = {
93
+ limit = {
94
+ check_variable = {
95
+ which = egyptian_adm_westernization_var
96
+ value = 1
97
+ }
98
+ NOT = {
99
+ check_variable = {
100
+ which = egyptian_adm_westernization_var
101
+ value = 2
102
+ }
103
+ }
104
+ }
105
+ custom_tooltip = egyptian_adm_counter_2_tt
106
+
107
+ hidden_effect = {
108
+ remove_country_modifier = egyptian_adm_westernization_4_modifier
109
+ remove_country_modifier = egyptian_adm_westernization_3_modifier
110
+ remove_country_modifier = egyptian_adm_westernization_5_modifier
111
+ set_variable = {
112
+ which = egyptian_adm_westernization_var
113
+ value = 2
114
+ }
115
+ }
116
+
117
+ add_country_modifier = {
118
+ name = egyptian_adm_westernization_2_modifier
119
+ duration = -1
120
+ hidden = yes
121
+ }
122
+ }
123
+ else_if = {
124
+ limit = {
125
+ check_variable = {
126
+ which = egyptian_adm_westernization_var
127
+ value = 2
128
+ }
129
+ NOT = {
130
+ check_variable = {
131
+ which = egyptian_adm_westernization_var
132
+ value = 3
133
+ }
134
+ }
135
+ }
136
+ custom_tooltip = egyptian_adm_counter_3_tt
137
+
138
+ hidden_effect = {
139
+ remove_country_modifier = egyptian_adm_westernization_2_modifier
140
+ remove_country_modifier = egyptian_adm_westernization_4_modifier
141
+ remove_country_modifier = egyptian_adm_westernization_5_modifier
142
+ set_variable = {
143
+ which = egyptian_adm_westernization_var
144
+ value = 3
145
+ }
146
+ }
147
+ add_country_modifier = {
148
+ name = egyptian_adm_westernization_3_modifier
149
+ duration = -1
150
+ hidden = yes
151
+ }
152
+ }
153
+ else_if = {
154
+ limit = {
155
+ check_variable = {
156
+ which = egyptian_adm_westernization_var
157
+ value = 3
158
+ }
159
+ NOT = {
160
+ check_variable = {
161
+ which = egyptian_adm_westernization_var
162
+ value = 4
163
+ }
164
+ }
165
+ }
166
+ custom_tooltip = egyptian_adm_counter_4_tt
167
+
168
+ hidden_effect = {
169
+ remove_country_modifier = egyptian_adm_westernization_2_modifier
170
+ remove_country_modifier = egyptian_adm_westernization_3_modifier
171
+ remove_country_modifier = egyptian_adm_westernization_5_modifier
172
+ set_variable = {
173
+ which = egyptian_adm_westernization_var
174
+ value = 4
175
+ }
176
+ }
177
+ add_country_modifier = {
178
+ name = egyptian_adm_westernization_4_modifier
179
+ duration = -1
180
+ hidden = yes
181
+ }
182
+ }
183
+ else_if = {
184
+ limit = {
185
+ check_variable = {
186
+ which = egyptian_adm_westernization_var
187
+ value = 4
188
+ }
189
+ NOT = {
190
+ check_variable = {
191
+ which = egyptian_adm_westernization_var
192
+ value = 5
193
+ }
194
+ }
195
+ }
196
+ custom_tooltip = egyptian_adm_counter_5_tt
197
+
198
+ hidden_effect = {
199
+ remove_country_modifier = egyptian_adm_westernization_2_modifier
200
+ remove_country_modifier = egyptian_adm_westernization_3_modifier
201
+ remove_country_modifier = egyptian_adm_westernization_4_modifier
202
+ set_variable = {
203
+ which = egyptian_adm_westernization_var
204
+ value = 5
205
+ }
206
+ }
207
+
208
+ add_country_modifier = {
209
+ name = egyptian_adm_westernization_5_modifier
210
+ duration = -1
211
+ hidden = yes
212
+ }
213
+ }
214
+ else_if = {
215
+ limit = {
216
+ check_variable = {
217
+ which = egyptian_adm_westernization_var
218
+ value = 5
219
+ }
220
+ }
221
+ custom_tooltip = egyptian_adm_counter_6_tt
222
+ }
223
+ if = {
224
+ limit = { has_country_flag = egyptian_westernization_costs_less_flag }
225
+ add_government_power = {
226
+ mechanic_type = egyptian_westernization
227
+ power_type = egyptian_westernization
228
+ value = 5
229
+ }
230
+ }
231
+ }
232
+ ai_chance = {
233
+
234
+ }
235
+ }
236
+ study_western_manufacturing = {
237
+ icon = GFX_study_western_manufacturing
238
+ gui = "egyptian_westernization_interaction_button"
239
+ cost_type = egyptian_westernization
240
+ cost = 30
241
+ trigger = {
242
+ custom_trigger_tooltip = {
243
+ tooltip = egyptian_westernization_trigger_2_tt
244
+ NOT = {
245
+ check_variable = {
246
+ which = egyptian_dip_westernization_var
247
+ value = 5
248
+ }
249
+ }
250
+ }
251
+ if = {
252
+ limit = { has_dlc = "Rule Britannia" }
253
+ innovativeness = 3
254
+ }
255
+ dip_power = 100
256
+ }
257
+ effect = {
258
+ if = {
259
+ limit = { has_dlc = "Rule Britannia" }
260
+ change_innovativeness = -3
261
+ }
262
+ add_dip_power = -100
263
+ if = {
264
+ limit = {
265
+ NOT = {
266
+ check_variable = {
267
+ which = egyptian_dip_westernization_var
268
+ value = 1
269
+ }
270
+ }
271
+ }
272
+ custom_tooltip = egyptian_dip_counter_1_tt
273
+
274
+ hidden_effect = {
275
+ set_variable = {
276
+ which = egyptian_dip_westernization_var
277
+ value = 1
278
+ }
279
+ remove_country_modifier = egyptian_dip_westernization_4_modifier
280
+ remove_country_modifier = egyptian_dip_westernization_3_modifier
281
+ remove_country_modifier = egyptian_dip_westernization_5_modifier
282
+ remove_country_modifier = egyptian_dip_westernization_2_modifier
283
+ change_government_reform_progress = 100
284
+ set_variable = {
285
+ which = egyptian_dip_westernization_var
286
+ value = 1
287
+ }
288
+ }
289
+ }
290
+ else_if = {
291
+ limit = {
292
+ check_variable = {
293
+ which = egyptian_dip_westernization_var
294
+ value = 1
295
+ }
296
+ NOT = {
297
+ check_variable = {
298
+ which = egyptian_dip_westernization_var
299
+ value = 2
300
+ }
301
+ }
302
+ }
303
+ custom_tooltip = egyptian_dip_counter_2_tt
304
+
305
+ hidden_effect = {
306
+ remove_country_modifier = egyptian_dip_westernization_4_modifier
307
+ remove_country_modifier = egyptian_dip_westernization_3_modifier
308
+ remove_country_modifier = egyptian_dip_westernization_5_modifier
309
+ set_variable = {
310
+ which = egyptian_dip_westernization_var
311
+ value = 2
312
+ }
313
+ add_country_modifier = {
314
+ name = egyptian_dip_westernization_2_modifier
315
+ duration = -1
316
+ hidden = yes
317
+ }
318
+ }
319
+ }
320
+ else_if = {
321
+ limit = {
322
+ check_variable = {
323
+ which = egyptian_dip_westernization_var
324
+ value = 2
325
+ }
326
+ NOT = {
327
+ check_variable = {
328
+ which = egyptian_dip_westernization_var
329
+ value = 3
330
+ }
331
+ }
332
+ }
333
+ custom_tooltip = egyptian_dip_counter_3_tt
334
+
335
+ hidden_effect = {
336
+ remove_country_modifier = egyptian_dip_westernization_2_modifier
337
+ remove_country_modifier = egyptian_dip_westernization_4_modifier
338
+ remove_country_modifier = egyptian_dip_westernization_5_modifier
339
+ set_variable = {
340
+ which = egyptian_dip_westernization_var
341
+ value = 3
342
+ }
343
+ add_country_modifier = {
344
+ name = egyptian_dip_westernization_3_modifier
345
+ duration = -1
346
+ hidden = yes
347
+ }
348
+ }
349
+
350
+ }
351
+ else_if = {
352
+ limit = {
353
+ check_variable = {
354
+ which = egyptian_dip_westernization_var
355
+ value = 3
356
+ }
357
+ NOT = {
358
+ check_variable = {
359
+ which = egyptian_dip_westernization_var
360
+ value = 4
361
+ }
362
+ }
363
+ }
364
+ custom_tooltip = egyptian_dip_counter_4_tt
365
+
366
+ hidden_effect = {
367
+ remove_country_modifier = egyptian_dip_westernization_2_modifier
368
+ remove_country_modifier = egyptian_dip_westernization_3_modifier
369
+ remove_country_modifier = egyptian_dip_westernization_5_modifier
370
+ set_variable = {
371
+ which = egyptian_dip_westernization_var
372
+ value = 4
373
+ }
374
+ add_country_modifier = {
375
+ name = egyptian_dip_westernization_4_modifier
376
+ duration = -1
377
+ hidden = yes
378
+ }
379
+ }
380
+
381
+ }
382
+ else_if = {
383
+ limit = {
384
+ check_variable = {
385
+ which = egyptian_dip_westernization_var
386
+ value = 4
387
+ }
388
+ NOT = {
389
+ check_variable = {
390
+ which = egyptian_dip_westernization_var
391
+ value = 5
392
+ }
393
+ }
394
+ }
395
+ custom_tooltip = egyptian_dip_counter_5_tt
396
+
397
+ hidden_effect = {
398
+ remove_country_modifier = egyptian_dip_westernization_2_modifier
399
+ remove_country_modifier = egyptian_dip_westernization_3_modifier
400
+ remove_country_modifier = egyptian_dip_westernization_4_modifier
401
+ set_variable = {
402
+ which = egyptian_dip_westernization_var
403
+ value = 5
404
+ }
405
+ add_country_modifier = {
406
+ name = egyptian_dip_westernization_5_modifier
407
+ duration = -1
408
+ hidden = yes
409
+ }
410
+ }
411
+ }
412
+ else_if = {
413
+ limit = {
414
+ check_variable = {
415
+ which = egyptian_dip_westernization_var
416
+ value = 5
417
+ }
418
+ }
419
+ custom_tooltip = egyptian_dip_counter_6_tt
420
+ }
421
+ if = {
422
+ limit = { has_country_flag = egyptian_westernization_costs_less_flag }
423
+ add_government_power = {
424
+ mechanic_type = egyptian_westernization
425
+ power_type = egyptian_westernization
426
+ value = 5
427
+ }
428
+ }
429
+ }
430
+ ai_chance = {
431
+
432
+ }
433
+ }
434
+ study_western_miltary = {
435
+ icon = GFX_study_western_military
436
+ gui = "egyptian_westernization_interaction_button"
437
+ cost_type = egyptian_westernization
438
+ cost = 30
439
+ trigger = {
440
+ custom_trigger_tooltip = {
441
+ tooltip = egyptian_westernization_trigger_3_tt
442
+ NOT = {
443
+ check_variable = {
444
+ which = egyptian_mil_westernization_var
445
+ value = 5
446
+ }
447
+ }
448
+ }
449
+ if = {
450
+ limit = { has_dlc = "Rule Britannia" }
451
+ innovativeness = 3
452
+ }
453
+ mil_power = 100
454
+ }
455
+ effect = {
456
+ if = {
457
+ limit = { has_dlc = "Rule Britannia" }
458
+ change_innovativeness = -3
459
+ }
460
+ add_mil_power = -100
461
+ if = {
462
+ limit = {
463
+ NOT = {
464
+ check_variable = {
465
+ which = egyptian_mil_westernization_var
466
+ value = 1
467
+ }
468
+ }
469
+ }
470
+ custom_tooltip = egyptian_mil_counter_1_tt
471
+
472
+ hidden_effect = {
473
+ set_variable = {
474
+ which = egyptian_mil_westernization_var
475
+ value = 1
476
+ }
477
+ remove_country_modifier = egyptian_mil_westernization_4_modifier
478
+ remove_country_modifier = egyptian_mil_westernization_3_modifier
479
+
480
+ remove_country_modifier = egyptian_mil_westernization_2_modifier
481
+ add_army_tradition = 10
482
+ set_variable = {
483
+ which = egyptian_mil_westernization_var
484
+ value = 1
485
+ }
486
+ }
487
+ }
488
+ else_if = {
489
+ limit = {
490
+ check_variable = {
491
+ which = egyptian_mil_westernization_var
492
+ value = 1
493
+ }
494
+ NOT = {
495
+ check_variable = {
496
+ which = egyptian_mil_westernization_var
497
+ value = 2
498
+ }
499
+ }
500
+ }
501
+ custom_tooltip = egyptian_mil_counter_2_tt
502
+
503
+ hidden_effect = {
504
+ remove_country_modifier = egyptian_mil_westernization_4_modifier
505
+ remove_country_modifier = egyptian_mil_westernization_3_modifier
506
+
507
+ set_variable = {
508
+ which = egyptian_mil_westernization_var
509
+ value = 2
510
+ }
511
+ add_country_modifier = {
512
+ name = egyptian_mil_westernization_2_modifier
513
+ duration = -1
514
+ hidden = yes
515
+ }
516
+ }
517
+ }
518
+ else_if = {
519
+ limit = {
520
+ check_variable = {
521
+ which = egyptian_mil_westernization_var
522
+ value = 2
523
+ }
524
+ NOT = {
525
+ check_variable = {
526
+ which = egyptian_mil_westernization_var
527
+ value = 3
528
+ }
529
+ }
530
+ }
531
+ custom_tooltip = egyptian_mil_counter_3_tt
532
+
533
+ hidden_effect = {
534
+ remove_country_modifier = egyptian_mil_westernization_2_modifier
535
+ remove_country_modifier = egyptian_mil_westernization_4_modifier
536
+
537
+ set_variable = {
538
+ which = egyptian_mil_westernization_var
539
+ value = 3
540
+ }
541
+ add_country_modifier = {
542
+ name = egyptian_mil_westernization_3_modifier
543
+ duration = -1
544
+ hidden = yes
545
+ }
546
+ }
547
+ }
548
+ else_if = {
549
+ limit = {
550
+ check_variable = {
551
+ which = egyptian_mil_westernization_var
552
+ value = 3
553
+ }
554
+ NOT = {
555
+ check_variable = {
556
+ which = egyptian_mil_westernization_var
557
+ value = 4
558
+ }
559
+ }
560
+ }
561
+ custom_tooltip = egyptian_mil_counter_4_tt
562
+
563
+ hidden_effect = {
564
+ remove_country_modifier = egyptian_mil_westernization_2_modifier
565
+ remove_country_modifier = egyptian_mil_westernization_3_modifier
566
+
567
+ set_variable = {
568
+ which = egyptian_mil_westernization_var
569
+ value = 4
570
+ }
571
+ add_country_modifier = {
572
+ name = egyptian_mil_westernization_4_modifier
573
+ duration = -1
574
+ hidden = yes
575
+ }
576
+ }
577
+ }
578
+ else_if = {
579
+ limit = {
580
+ check_variable = {
581
+ which = egyptian_mil_westernization_var
582
+ value = 4
583
+ }
584
+ NOT = {
585
+ check_variable = {
586
+ which = egyptian_mil_westernization_var
587
+ value = 5
588
+ }
589
+ }
590
+ }
591
+ custom_tooltip = egyptian_mil_counter_5_tt
592
+
593
+ hidden_effect = {
594
+
595
+ set_variable = {
596
+ which = egyptian_mil_westernization_var
597
+ value = 5
598
+ }
599
+ change_technology_group = western
600
+ change_unit_type = western
601
+ }
602
+ }
603
+ else_if = {
604
+ limit = {
605
+ check_variable = {
606
+ which = egyptian_mil_westernization_var
607
+ value = 5
608
+ }
609
+ }
610
+ custom_tooltip = egyptian_mil_counter_6_tt
611
+ }
612
+ if = {
613
+ limit = { has_country_flag = egyptian_westernization_costs_less_flag }
614
+ add_government_power = {
615
+ mechanic_type = egyptian_westernization
616
+ power_type = egyptian_westernization
617
+ value = 5
618
+ }
619
+ }
620
+ }
621
+ ai_chance = {
622
+
623
+ }
624
+ }
625
+ }
626
+ }
common/government_mechanics/20_persian_influence.txt ADDED
@@ -0,0 +1,139 @@
1
+ persian_influence_mechanic = {
2
+ alert_icon_gfx = GFX_alerticons_government_mechanics
3
+ alert_icon_index = 5 #TODO
4
+ available = {
5
+ has_dlc = "King of Kings"
6
+ }
7
+
8
+ powers = {
9
+ persian_influence = {
10
+ show_before_interactions = yes
11
+ max = 100
12
+ base_monthly_growth = 0
13
+ }
14
+ }
15
+
16
+ interactions = {
17
+ collect_tax_on_art = {
18
+ icon = GFX_collect_tax_on_art
19
+ cost_type = persian_influence
20
+ cost = 100
21
+ trigger = {
22
+ num_of_subjects = 1
23
+ }
24
+ effect = {
25
+ used_persian_influence_mechanic = yes
26
+ if = {
27
+ limit = { has_country_flag = improved_persian_influence_abilities }
28
+ add_subjects_development_ducats = {
29
+ multiplier = 5
30
+ }
31
+ }
32
+ else = {
33
+ add_subjects_development_ducats = {
34
+ multiplier = 2.5
35
+ }
36
+ }
37
+ }
38
+ cooldown_years = 0
39
+ ai_chance = {
40
+ factor = 1
41
+ }
42
+ }
43
+ promote_good_reputation = {
44
+ icon = GFX_promote_good_reputation
45
+ cost_type = persian_influence
46
+ cost = 100
47
+ trigger = {
48
+ num_of_subjects = 1
49
+ }
50
+ effect = {
51
+ used_persian_influence_mechanic = yes
52
+ if = {
53
+ limit = { has_country_flag = improved_persian_influence_abilities }
54
+ custom_tooltip = promote_good_reputation_at
55
+ hidden_effect = {
56
+ every_subject_country = {
57
+ add_mutual_opinion_modifier_effect = {
58
+ target = root
59
+ modifier = promote_good_reputation_opinion
60
+ }
61
+ add_trust = {
62
+ who = root
63
+ value = 2
64
+ mutual = yes
65
+ }
66
+ }
67
+ }
68
+ }
69
+ else = {
70
+ custom_tooltip = promote_good_reputation_bt
71
+ hidden_effect = {
72
+ every_subject_country = {
73
+ add_mutual_opinion_modifier_effect = {
74
+ target = root
75
+ modifier = promote_good_reputation_upgraded_opinion
76
+ }
77
+ add_trust = {
78
+ who = root
79
+ value = 4
80
+ mutual = yes
81
+ }
82
+ }
83
+ }
84
+ }
85
+ }
86
+ cooldown_years = 0
87
+ ai_chance = {
88
+ factor = 1
89
+ }
90
+ }
91
+ conscript_enthusiasts = {
92
+ icon = GFX_conscript_enthusiasts
93
+ cost_type = persian_influence
94
+ cost = 100
95
+ trigger = {
96
+ num_of_subjects = 1
97
+ }
98
+ effect = {
99
+ used_persian_influence_mechanic = yes
100
+ if = {
101
+ limit = { has_country_flag = improved_persian_influence_abilities }
102
+ add_subjects_development_manpower = {
103
+ multiplier = 0.2
104
+ }
105
+ }
106
+ else = {
107
+ add_subjects_development_manpower = {
108
+ multiplier = 0.1
109
+ }
110
+ }
111
+ }
112
+ cooldown_years = 0
113
+ ai_chance = {
114
+ factor = 10
115
+ modifier = {
116
+ factor = 0
117
+ not = { cavalry_fraction = 0.1 }
118
+ }
119
+ modifier = {
120
+ factor = 0
121
+ is_at_war = no
122
+ }
123
+ modifier = {
124
+ factor = 0
125
+ NOT = { manpower_percentage = 0.8 }
126
+ }
127
+ modifier = {
128
+ factor = 10
129
+ is_in_important_war = yes
130
+ has_government_power = {
131
+ mechanic_type = persian_influence_mechanic
132
+ power_type = persian_influence
133
+ value = 95
134
+ }
135
+ }
136
+ }
137
+ }
138
+ }
139
+ }
common/government_mechanics/21_the_three_royal_fires.txt ADDED
@@ -0,0 +1,274 @@
1
+ the_three_royal_fires_mechanic = {
2
+ alert_icon_gfx = GFX_alerticons_government_mechanics #TODO
3
+ alert_icon_index = 12 #TODO
4
+ available = {
5
+ has_dlc = "King of Kings"
6
+ }
7
+
8
+ powers = {
9
+ asha_vahishta = {
10
+ gui = three_flames_gov_mech
11
+ show_before_interactions = yes
12
+ max = 100
13
+ min = -100
14
+ base_monthly_growth = 0.2
15
+ scaled_modifier = {
16
+ modifier = {
17
+ global_unrest = -2
18
+ }
19
+ }
20
+ scaled_modifier = {
21
+ trigger = {
22
+ has_government_power = {
23
+ mechanic_type = the_three_royal_fires_mechanic
24
+ power_type = asha_vahishta
25
+ value = 0
26
+ }
27
+ }
28
+ modifier = {
29
+ manpower_in_true_faith_provinces = 0.25
30
+ monthly_adur_burzhen_mihr = 1
31
+ monthly_adur_farnbag = 1
32
+ monthly_adur_gushnasp = 1
33
+ }
34
+ start_value = 0
35
+ end_value = 100
36
+ }
37
+ reverse_scaled_modifier = {
38
+ trigger = {
39
+ NOT = {
40
+ has_government_power = {
41
+ mechanic_type = the_three_royal_fires_mechanic
42
+ power_type = asha_vahishta
43
+ value = 0
44
+ }
45
+ }
46
+ }
47
+ modifier = {
48
+ monthly_asha_vahishta = 1
49
+ }
50
+ start_value = -100
51
+ end_value = 0
52
+ }
53
+ }
54
+ adur_burzhen_mihr = {
55
+ max = 100
56
+ base_monthly_growth = 0.25
57
+ monarch_power = ADM
58
+ reset_on_new_ruler = no
59
+ }
60
+ adur_farnbag = {
61
+ max = 100
62
+ base_monthly_growth = 0.25
63
+ monarch_power = DIP
64
+ reset_on_new_ruler = no
65
+ }
66
+ adur_gushnasp = {
67
+ max = 100
68
+ base_monthly_growth = 0.25
69
+ monarch_power = MIL
70
+ reset_on_new_ruler = no
71
+ }
72
+ }
73
+ interactions = {
74
+ adur_farnbag_interaction = {
75
+ gui = three_flames_interaction_button
76
+ icon = GFX_adur_farnbag_interaction
77
+ cost_type = adur_farnbag
78
+ cost = 100
79
+ trigger = {
80
+ #if = {
81
+ # limit = { has_country_flag = can_place_center_of_reformation }
82
+ # custom_trigger_tooltip = {
83
+ # tooltip = adur_farnbag_interaction_ct
84
+ # NOT = { has_country_flag = can_place_center_of_reformation }
85
+ # }
86
+ #}
87
+ has_government_power = {
88
+ mechanic_type = the_three_royal_fires_mechanic
89
+ power_type = asha_vahishta
90
+ value = -50
91
+ }
92
+ }
93
+ effect = {
94
+ #if = {
95
+ # limit = {
96
+ # has_country_modifier = embraced_passive_conversion_methods
97
+ # }
98
+ # if = {
99
+ # limit = {
100
+ # NOT = {
101
+ # 1 = {
102
+ # check_variable = {
103
+ # which = zoroastrian_reform_center_counter
104
+ # value = 3
105
+ # }
106
+ # }
107
+ # }
108
+ # }
109
+ # hidden_effect = {
110
+ # set_country_flag = can_place_center_of_reformation
111
+ # }
112
+ # custom_tooltip = adur_farnbag_interaction_at
113
+ # }
114
+ # else = {
115
+ # custom_tooltip = adur_farnbag_interaction_bt
116
+ # }
117
+ #}
118
+ if = {
119
+ limit = { has_country_flag = upgraded_the_three_fire }
120
+ add_estate_loyalty = {
121
+ estate = all
122
+ loyalty = 5
123
+ short = yes
124
+ }
125
+ }
126
+ if = {
127
+ limit = { has_country_flag = enabled_three_royal_fires_mana_generation }
128
+ add_adm_power = 50
129
+ }
130
+ add_country_modifier = {
131
+ name = adur_farnbag_mod
132
+ duration = 3650
133
+ }
134
+ custom_tooltip = ENERGIES_OF_AHURA_MAZDA_FOR_SELFISH_PURPOSES_TT
135
+ add_government_power = {
136
+ mechanic_type = the_three_royal_fires_mechanic
137
+ power_type = asha_vahishta
138
+ value = -50
139
+ }
140
+ hidden_effect = {
141
+ change_variable = { which = the_three_royal_fires_counter value = 1 }
142
+ change_variable = { which = adur_farnbag_interaction_counter value = 1 }
143
+ }
144
+ }
145
+ ai_chance = {
146
+ factor = 0
147
+ }
148
+ }
149
+ adur_burzhen_mihr_interaction = {
150
+ gui = three_flames_interaction_button
151
+ icon = GFX_adur_burzhen_mihr_interaction
152
+ cost_type = adur_burzhen_mihr
153
+ cost = 100
154
+ trigger = {
155
+ has_government_power = {
156
+ mechanic_type = the_three_royal_fires_mechanic
157
+ power_type = asha_vahishta
158
+ value = -50
159
+ }
160
+ }
161
+ effect = {
162
+ custom_tooltip = adur_burzhen_mihr_interaction_at
163
+ hidden_effect = {
164
+ change_variable = {
165
+ which = zoroastrian_invitation_charges
166
+ value = 1
167
+ }
168
+ if = {
169
+ limit = { NOT = { has_country_flag = gained_first_invitation_charge } }
170
+ set_country_flag = gained_first_invitation_charge
171
+ }
172
+ }
173
+ if = {
174
+ limit = { has_country_flag = upgraded_the_three_fire }
175
+ capital_scope = {
176
+ random_area_province = {
177
+ limit = {
178
+ owner = {
179
+ tag = ROOT
180
+ }
181
+ }
182
+ add_random_development = 1
183
+ }
184
+ }
185
+ }
186
+ if = {
187
+ limit = { has_country_flag = enabled_three_royal_fires_mana_generation }
188
+ add_dip_power = 50
189
+ }
190
+ add_country_modifier = {
191
+ name = adur_burzhen_mihr_mod
192
+ duration = 3650
193
+ }
194
+ custom_tooltip = ENERGIES_OF_AHURA_MAZDA_FOR_SELFISH_PURPOSES_TT
195
+ add_government_power = {
196
+ mechanic_type = the_three_royal_fires_mechanic
197
+ power_type = asha_vahishta
198
+ value = -50
199
+ }
200
+ hidden_effect = {
201
+ change_variable = { which = the_three_royal_fires_counter value = 1 }
202
+ change_variable = { which = adur_burzhen_mihr_interaction_counter value = 1 }
203
+ }
204
+ }
205
+ ai_chance = {
206
+ factor = 0
207
+ }
208
+ }
209
+ adur_gushnasp_interaction = {
210
+ gui = three_flames_interaction_button
211
+ icon = GFX_adur_gushnasp_interaction
212
+ cost_type = adur_gushnasp
213
+ cost = 100
214
+ trigger = {
215
+ has_government_power = {
216
+ mechanic_type = the_three_royal_fires_mechanic
217
+ power_type = asha_vahishta
218
+ value = -50
219
+ }
220
+ }
221
+ effect = {
222
+ if = {
223
+ limit = { has_country_flag = upgraded_the_three_fire }
224
+ every_neighbor_province = {
225
+ limit = {
226
+ owner = {
227
+ exists = yes
228
+ not = { defensive_pact_with = ROOT }
229
+ not = { religion = ROOT }
230
+ }
231
+ not = { is_claim = ROOT }
232
+ not = { is_core = ROOT }
233
+ has_discovered = ROOT
234
+ }
235
+ add_claim = ROOT
236
+ }
237
+ }
238
+ if = {
239
+ limit = { has_country_flag = enabled_three_royal_fires_mana_generation }
240
+ add_mil_power = 50
241
+ }
242
+ add_country_modifier = {
243
+ name = adur_gushnasp_mod
244
+ duration = 3650
245
+ }
246
+ if = {
247
+ limit = { has_country_flag = upgraded_the_three_fire }
248
+ add_army_tradition = 5
249
+ }
250
+ custom_tooltip = ENERGIES_OF_AHURA_MAZDA_FOR_SELFISH_PURPOSES_TT
251
+ add_government_power = {
252
+ mechanic_type = the_three_royal_fires_mechanic
253
+ power_type = asha_vahishta
254
+ value = -50
255
+ }
256
+ hidden_effect = {
257
+ change_variable = { which = the_three_royal_fires_counter value = 1 }
258
+ change_variable = { which = adur_gushnasp_interaction_counter value = 1 }
259
+ }
260
+ }
261
+ ai_chance = {
262
+ factor = 10
263
+ modifier = {
264
+ factor = 100
265
+ is_at_war = yes
266
+ }
267
+ modifier = {
268
+ factor = 0
269
+ is_at_war = no
270
+ }
271
+ }
272
+ }
273
+ }
274
+ }