Diff to HTML by rtfpessoa

Files changed (9) hide show
  1. common/scripted_effects/00_scripted_effects.txt +1693 -4822
  2. common/scripted_effects/01_scripted_effects_for_estates.txt +144 -32
  3. common/scripted_effects/01_scripted_effects_for_government_mechanics.txt +703 -0
  4. common/scripted_effects/01_scripted_effects_for_on_actions.txt +1228 -273
  5. common/scripted_effects/01_scripted_effects_for_rulers_heirs_consorts.txt +84 -0
  6. common/scripted_effects/01_scripted_effects_natives_and_colonization.txt +2768 -0
  7. common/scripted_effects/02_scripted_effects_preview_missions.txt +1782 -0
  8. common/scripted_effects/02_scripted_effects_unlocks.txt +797 -0
  9. common/scripted_effects/03_scripted_effects_for_mission_rewards.txt +2973 -0
common/scripted_effects/00_scripted_effects.txt CHANGED
@@ -274,8 +274,6 @@ add_vassalise_cb_effect = {
274
274
  target = ROOT
275
275
  }
276
276
  }
277
-
278
-
279
277
  remove_vassalise_cb_effect = {
280
278
  if = {
281
279
  limit = {
@@ -440,7 +438,6 @@ add_half_industrialization_effect = {
440
438
  }
441
439
  }
442
440
  }
443
-
444
441
  #province scope
445
442
  add_quarter_industrialization_effect = {
446
443
  if = {
@@ -463,7 +460,6 @@ choose_random_development_bonus_effect = {
463
460
  1 = { set_province_flag = add_base_manpower_flag }
464
461
  }
465
462
  }
466
-
467
463
  apply_random_development_bonus_bonus_effect = {
468
464
  trigger_switch = {
469
465
  on_trigger = has_province_flag
@@ -473,7 +469,6 @@ apply_random_development_bonus_bonus_effect = {
473
469
  }
474
470
  clear_random_development_bonus_flags_effect = yes
475
471
  }
476
-
477
472
  clear_random_development_bonus_flags_effect = {
478
473
  clr_province_flag = add_base_tax_flag
479
474
  clr_province_flag = add_base_production_flag
@@ -604,7 +599,6 @@ spawn_small_scaled_rebels = {
604
599
  ]
605
600
  }
606
601
  }
607
-
608
602
  spawn_large_scaled_rebels = {
609
603
  #always specify type
610
604
  #specify saved_name = <saved_name> if you want to use one of those
@@ -771,7 +765,6 @@ spawn_large_scaled_rebels = {
771
765
  }
772
766
  }
773
767
 
774
-
775
768
  #country scope. Currently just applies to the Hansa, if future ones are added, update the flags
776
769
  #Used in nation formation decisions
777
770
  restore_country_name_effect = {
@@ -785,7 +778,6 @@ restore_country_name_effect = {
785
778
  }
786
779
  }
787
780
  }
788
-
789
781
  #Used to clone the nation when forming a colonial tag.
790
782
  restore_old_nation_on_formation_effect = {
791
783
  if = {
@@ -1241,7 +1233,6 @@ change_government_to_republic = {
1241
1233
  change_government_reform_progress = -200
1242
1234
  }
1243
1235
  }
1244
-
1245
1236
  change_government_to_monarchy = {
1246
1237
  if = {
1247
1238
  limit = {
@@ -1260,7 +1251,6 @@ change_government_to_monarchy = {
1260
1251
  }
1261
1252
  }
1262
1253
  }
1263
-
1264
1254
  change_government_to_theocracy = {
1265
1255
  if = {
1266
1256
  limit = {
@@ -1279,7 +1269,6 @@ change_government_to_theocracy = {
1279
1269
  }
1280
1270
  }
1281
1271
  }
1282
-
1283
1272
  change_government_to_tribal = {
1284
1273
  if = {
1285
1274
  limit = {
@@ -1290,90 +1279,6 @@ change_government_to_tribal = {
1290
1279
  }
1291
1280
  }
1292
1281
 
1293
- add_ruler_personality_ancestor = {
1294
- # key = personality to test again
1295
- if = {
1296
- limit = {
1297
- has_dlc = "Leviathan"
1298
- religion = totemism
1299
- }
1300
- add_ruler_personality = ancestor_$key$_personality
1301
- }
1302
- else = {
1303
- add_ruler_personality = $key$_personality
1304
- }
1305
- }
1306
-
1307
- add_heir_personality_ancestor = {
1308
- # key = personality to test again
1309
- if = {
1310
- limit = {
1311
- has_dlc = "Leviathan"
1312
- religion = totemism
1313
- }
1314
- add_heir_personality = ancestor_$key$_personality
1315
- }
1316
- else = {
1317
- add_heir_personality = $key$_personality
1318
- }
1319
- }
1320
-
1321
- add_queen_personality_ancestor = {
1322
- # key = personality to test again
1323
- if = {
1324
- limit = {
1325
- has_dlc = "Leviathan"
1326
- religion = totemism
1327
- }
1328
- add_queen_personality = ancestor_$key$_personality
1329
- }
1330
- else = {
1331
- add_queen_personality = $key$_personality
1332
- }
1333
- }
1334
-
1335
- remove_ruler_personality_ancestor = {
1336
- # key = personality to test again
1337
- if = {
1338
- limit = {
1339
- has_dlc = "Leviathan"
1340
- religion = totemism
1341
- }
1342
- remove_ruler_personality = ancestor_$key$_personality
1343
- }
1344
- else = {
1345
- remove_ruler_personality = $key$_personality
1346
- }
1347
- }
1348
-
1349
- remove_heir_personality_ancestor = {
1350
- # key = personality to test again
1351
- if = {
1352
- limit = {
1353
- has_dlc = "Leviathan"
1354
- religion = totemism
1355
- }
1356
- remove_heir_personality = ancestor_$key$_personality
1357
- }
1358
- else = {
1359
- remove_heir_personality = $key$_personality
1360
- }
1361
- }
1362
-
1363
- remove_queen_personality_ancestor = {
1364
- # key = personality to test again
1365
- if = {
1366
- limit = {
1367
- has_dlc = "Leviathan"
1368
- religion = totemism
1369
- }
1370
- remove_queen_personality = ancestor_$key$_personality
1371
- }
1372
- else = {
1373
- remove_queen_personality = $key$_personality
1374
- }
1375
- }
1376
-
1377
1282
  #The three effects below are used for setting a great project to exact the tier
1378
1283
  #I tried to combine the three effects into one single scripted effect, but I couldn't figure a way out to do the effect without having to do a lot of custom tooltip
1379
1284
  #Sets monument tier 1 (has no effect if the monument is tier 1 or higher)
@@ -1409,7 +1314,6 @@ set_great_project_tier_1 = {
1409
1314
  add_base_manpower = 1
1410
1315
  }
1411
1316
  }
1412
-
1413
1317
  #Sets monument tier 2 (has no effect if the monument is tier 2 or higher)
1414
1318
  #Province scope
1415
1319
  set_great_project_tier_2 = {
@@ -1478,7 +1382,6 @@ set_great_project_tier_2 = {
1478
1382
  add_base_manpower = 1
1479
1383
  }
1480
1384
  }
1481
-
1482
1385
  #Sets monument tier 3 (has no effect if the monument is tier 3 or higher)
1483
1386
  #Province scope
1484
1387
  set_great_project_tier_3 = {
@@ -1610,7 +1513,6 @@ create_colony_mission_reward = {
1610
1513
  add_permanent_claim = $province$
1611
1514
  }
1612
1515
  }
1613
-
1614
1516
  #Country effect
1615
1517
  seize_empty_province_effect = {
1616
1518
  if = {
@@ -1636,7 +1538,6 @@ seize_empty_province_effect = {
1636
1538
  }
1637
1539
  }
1638
1540
  }
1639
-
1640
1541
  #Provine effect
1641
1542
  create_colony_mission_reward_province = {
1642
1543
  if = {
@@ -1895,291 +1796,6 @@ mal_determine_offer_acceptance = {
1895
1796
  }
1896
1797
  }
1897
1798
 
1898
- #Country effect
1899
- ##########################################################
1900
- # Supports following privileges
1901
- # estate_burghers_hydraulic_rights
1902
- # estate_nobles_cawa_peace_keepers
1903
- # estate_nobles_cawa_offensive_fighters
1904
- # estate_burghers_control_over_the_mint
1905
- # estate_dhimmi_guarantee_of_traditions
1906
- # estate_church_yakobs_churches
1907
- # estate_nobles_grant_power_to_the_bashorun
1908
- # estate_burghers_forest_expansion
1909
- # estate_burghers_mountain_expansion
1910
- # estate_nobles_leidang_conscription
1911
- # estate_burghers_orthodox_tolerance
1912
- # estate_church_anti_heresy_act
1913
- # estate_nobles_religious_conscription
1914
- # estate_dhimmi_millet_system
1915
- # estate_burghers_the_new_middle_class
1916
- # estate_janissary_ottoman_vanguards
1917
- # estate_nobles_english_copyhold_tenure
1918
- # estate_burghers_autonomous_trade_companies
1919
- # estate_nobles_defensive_policy
1920
- # estate_qizilbash_defensive_policy
1921
- # estate_ghulams_defensive_policy
1922
- # estate_nobles_tofangchi_regiment
1923
- # estate_qizilbash_tofangchi_regiment
1924
- # estate_ghulams_tofangchi_regiment
1925
- # estate_nobles_tupchi_artillery_corps
1926
- # estate_qizilbash_tupchi_artillery_corps
1927
- # estate_ghulams_tupchi_artillery_corps
1928
- ##########################################################
1929
- # When adding new privileges then make sure that a unlock_privilege_$estate_privilege$_tt is defined in the localization
1930
- # For checking if an estate privilege is unlocked already, use has_unlocked_estate_privilege = { estate_privilege = $estate_privilege$ }
1931
- # For localization write the following: "Enable the [Root.<Estate Name>] privilege '§Y<Privilege Name>§!'."
1932
- unlock_estate_privilege = {
1933
- custom_tooltip = unlock_privilege_$estate_privilege$_tt
1934
- hidden_effect = {
1935
- set_country_flag = unlocked_privilege_$estate_privilege$
1936
- }
1937
- [[modifier_tooltip]
1938
- custom_tooltip = unlock_estate_privilege_modifier_tooltip_tt
1939
- tooltip = {
1940
- add_country_modifier = {
1941
- name = $modifier_tooltip$
1942
- duration = -1
1943
- desc = UNTIL_PRIVILEGE_REVOKED
1944
- }
1945
- }
1946
- ]
1947
- [[effect_tooltip]
1948
- custom_tooltip = unlock_estate_privilege_effect_tooltip_tt
1949
- tooltip = {
1950
- $effect_tooltip$
1951
- }
1952
- ]
1953
- }
1954
-
1955
- #Country effect
1956
- ##########################################################
1957
- # Supports following merc companies
1958
- # merc_oyo_cavalry
1959
- # merc_hakkapeliita_cavalry
1960
- # merc_prussian_volunteer_army
1961
- # merc_large_hakkapeliita_cavalry
1962
- # merc_guerilla_hakkapeliita_cavalry
1963
- # merc_elite_hakkapeliita_cavalry
1964
- # merc_schwarze_garde
1965
- # merc_hessian_jaegerkorps
1966
- # merc_doppelsoeldner
1967
- # merc_frisian_free_company
1968
- # merc_flemish_company
1969
- # merc_reislaufer
1970
- # merc_tatar_vanguard
1971
- ##########################################################
1972
- # When adding a new merc company then make sure that a unlock_$merc_company$_tt is defined in the localization
1973
- # For checking if a merc company is unlocked already, use has_unlocked_merc_company = { merc_company = $merc_company$ }
1974
- # For localization write the following: "Unlock the mercenary company §Y<Merc Company>§! to recruit."
1975
- unlock_merc_company = {
1976
- custom_tooltip = unlock_$merc_company$_tt
1977
- hidden_effect = {
1978
- set_country_flag = unlocked_$merc_company$
1979
- }
1980
- [[free_merc]
1981
- custom_tooltip = costs_no_army_professionalism
1982
- ]
1983
- [[global]
1984
- custom_tooltip = global_merc_company
1985
- hidden_effect = {
1986
- set_global_flag = global_unlocked_$merc_company$
1987
- }
1988
- ]
1989
- }
1990
-
1991
- #Same as above, but this time it makes a company unavailable
1992
- #Does not support any merc company yet
1993
- #lock_merc_company = {
1994
- # custom_tooltip = lock_$merc_company$_tt
1995
- # hidden_effect = {
1996
- # clr_country_flag = unlocked_$merc_company$
1997
- # }
1998
- #}
1999
-
2000
- #Country effect
2001
- ##########################################################
2002
- # Supports following church aspects
2003
- # anglican_aspect
2004
- # spread_the_book_of_common_prayer
2005
- ##########################################################
2006
- # When adding a new unlockable Church Aspect then make sure that a unlock_church_aspect_$church_aspect$_tt is defined in the localization
2007
- # For checking if a Church Aspect is unlocked already, use has_unlocked_church_aspect = { church_aspect = $church_aspect$ }
2008
- # For localization write the following: "Unlock the Protestant church aspect '§Y<Church Aspect>§!'."
2009
- unlock_church_aspect = {
2010
- custom_tooltip = unlock_church_aspect_$church_aspect$_tt
2011
- hidden_effect = {
2012
- set_country_flag = unlocked_church_aspect_$church_aspect$
2013
- }
2014
- }
2015
-
2016
- #Country effect
2017
- ##########################################################
2018
- # Supports following government reforms
2019
- # prussian_monarchy_base
2020
- # prussian_republic_reform
2021
- # prussian_theocratic_reform
2022
- # holy_horde_reform
2023
- # crusading_kingdom_reform
2024
- # militarized_crusader_order_reform
2025
- # allotment_system
2026
- # expanded_devshirme_system_reform
2027
- # ottoman_siyasah_tax_reform
2028
- # fiqh_laws_reform
2029
- # sufism_decree_reform
2030
- # ottoman_conscription_reform
2031
- # reformed_ottoman_conscription_reform
2032
- # mansure_army_reform
2033
- # janissary_military_reform
2034
- # standardized_millets_reform
2035
- # modernized_ottoman_government
2036
- # reorganized_ottoman_government
2037
- # russian_empire_reform
2038
- # great_russian_republic_reform
2039
- # professional_navy_reform
2040
- # thalassocracy_reform
2041
- # governing_senate_reform
2042
- # enforced_autocracy_reform
2043
- # holy_synod_reform
2044
- # strengthened_the_patriarchy_reform
2045
- # head_of_the_patriarchy_reform
2046
- # tysyatsky_reform
2047
- # namestnik_reform
2048
- # oprichnina_reform
2049
- # anglican_state_church_reform
2050
- # english_conciliarism_reform
2051
- # direct_royal_administration_reform
2052
- # administration_of_the_parliament_reform
2053
- # royal_charters_reform
2054
- # commercial_trade_empire_reform
2055
- # peters_government_reform
2056
- # caliphate_reform
2057
- # caliphate_theocracy_reform
2058
- # legacy_of_timur_reform
2059
- # legacy_of_the_safavid_reform
2060
- # divided_aristocracy_reform
2061
- ##########################################################
2062
- # When adding a new government reform then make sure that a unlock_$government_reform$_tt is defined in the localization
2063
- # For checking if a government reform is unlocked already, use has_unlocked_government_reform = { government_reform = $government_reform$ }
2064
- # For localization write the following: "Unlock the government reform §Y<Government Reform>§!."
2065
- unlock_government_reform = {
2066
- custom_tooltip = unlock_$government_reform$_tt
2067
- hidden_effect = {
2068
- set_country_flag = unlocked_$government_reform$
2069
- }
2070
- [[tooltip]
2071
- custom_tooltip = unlock_government_reform_tooltip
2072
- tooltip = {
2073
- add_government_reform = $government_reform$
2074
- }
2075
- ]
2076
- }
2077
-
2078
- #Country effect
2079
- ##########################################################
2080
- # Has the localization for the following estates:
2081
- # estate_brahmins
2082
- # estate_church
2083
- # estate_maratha
2084
- # estate_nobles
2085
- # estate_burghers
2086
- # estate_vaisyas
2087
- # estate_cossacks
2088
- # estate_nomadic_tribes
2089
- # estate_dhimmi
2090
- # estate_jains
2091
- # estate_rajput
2092
- # estate_janissaries
2093
- # estate_eunuchs
2094
- # estate_qizilbash
2095
- # estate_ghulams
2096
- ##########################################################
2097
- # When adding a new estate then make sure that a unlock_$estate$_tt is defined in the localization
2098
- # For checking if an Estate is unlocked already, use has_unlocked_estate = { estate = $estate$ }
2099
- # For localization write the following: "Unlock the §Y<Estate>§! Estate."
2100
- # Important: this way of unlocking an estate does not give you permanent access to the estate - hence the show_conditions.
2101
- # For granting permanent access, use "enable_estate_effect"
2102
- unlock_estate = {
2103
- custom_tooltip = unlock_$estate$_tt
2104
- hidden_effect = {
2105
- set_country_flag = unlocked_$estate$_flag
2106
- }
2107
- [[show_conditions]
2108
- custom_tooltip = is_unavailable_$estate$
2109
- ]
2110
- }
2111
-
2112
- #Country effect
2113
- ##########################################################
2114
- # Has the localization for the following estates:
2115
- # estate_brahmins
2116
- # estate_church
2117
- # estate_maratha
2118
- # estate_nobles
2119
- # estate_burghers
2120
- # estate_vaisyas
2121
- # estate_cossacks
2122
- # estate_nomadic_tribes
2123
- # estate_dhimmi
2124
- # estate_jains
2125
- # estate_rajput
2126
- # estate_janissaries
2127
- # estate_eunuchs
2128
- # estate_qizilbash
2129
- # estate_ghulams
2130
- ##########################################################
2131
- # Unlocks the estate without any kind of condition
2132
- enable_estate_effect = {
2133
- custom_tooltip = mechanic_enables_$estate$_yes
2134
- hidden_effect = {
2135
- clr_country_flag = disables_$estate$_flag
2136
- set_country_flag = enables_$estate$_flag
2137
- }
2138
- }
2139
-
2140
- #Country effect
2141
- ##########################################################
2142
- # Has the localization for the following estates:
2143
- # estate_brahmins
2144
- # estate_church
2145
- # estate_maratha
2146
- # estate_nobles
2147
- # estate_burghers
2148
- # estate_vaisyas
2149
- # estate_cossacks
2150
- # estate_nomadic_tribes
2151
- # estate_dhimmi
2152
- # estate_jains
2153
- # estate_rajput
2154
- # estate_janissaries
2155
- # estate_eunuchs
2156
- # estate_qizilbash
2157
- # estate_ghulams
2158
- ##########################################################
2159
- # Locks the estate even if they would
2160
- disable_estate_effect = {
2161
- custom_tooltip = mechanic_disables_$estate$_yes
2162
- hidden_effect = {
2163
- set_country_flag = disables_$estate$_flag
2164
- clr_country_flag = enables_$estate$_flag
2165
- }
2166
- }
2167
-
2168
- enable_full_ducat_gain_from_selling_crownland = {
2169
- custom_tooltip = enable_full_ducat_gain_from_selling_crownland_tt
2170
- set_country_flag = enable_full_ducat_gain_from_selling_crownland_flag
2171
- }
2172
-
2173
- can_sell_crownland_to_estates_targeted = {
2174
- custom_tooltip = can_sell_crownland_to_estates_targeted_tt
2175
- set_country_flag = can_sell_crownland_to_estates_targeted_flag
2176
- }
2177
-
2178
- can_seize_crownland_to_estates_targeted = {
2179
- custom_tooltip = can_seize_crownland_to_estates_targeted_tt
2180
- set_country_flag = can_seize_crownland_to_estates_targeted_flag
2181
- }
2182
-
2183
1799
  #Country effect
2184
1800
  #add_increase_same_religion_opinion = {
2185
1801
  # custom_tooltip = increase_same_religion_opinion_tt
@@ -2326,21 +1942,10 @@ add_temporary_colonist = {
2326
1942
  }
2327
1943
  custom_tooltip = add_temporary_colonist_tt
2328
1944
  }
2329
-
2330
- #Country effect - Mission reward
2331
- allow_baseline_invite_scholar = {
2332
- custom_tooltip = allows_every_time_invite_of_$religious_school$
1945
+ remove_temporary_colonist = {
2333
1946
  hidden_effect = {
2334
- set_country_flag = can_always_invite_$religious_school$
1947
+ remove_country_modifier = temporary_colonist
2335
1948
  }
2336
- [[religious_school_modifier]
2337
- tooltip = {
2338
- add_country_modifier = {
2339
- name = $religious_school_modifier$
2340
- duration = -1
2341
- }
2342
- }
2343
- ]
2344
1949
  }
2345
1950
 
2346
1951
  #Country effect
@@ -2392,100 +1997,6 @@ transfer_treasury = {
2392
1997
  ]
2393
1998
  }
2394
1999
 
2395
- #Country effect
2396
- enable_propogate_religion_effect = {
2397
- custom_tooltip = enable_propogate_religion_effect_tt
2398
- hidden_effect = {
2399
- set_country_flag = can_use_propagate_religion
2400
- }
2401
- }
2402
-
2403
- #Country effect
2404
- disable_propogate_religion_effect = {
2405
- custom_tooltip = disable_propogate_religion_effect_tt
2406
- hidden_effect = {
2407
- clr_country_flag = can_use_propagate_religion
2408
- }
2409
- }
2410
-
2411
- #5, #10, #15, #20, #25, #30, #35, #40, #45
2412
- set_trade_power_requirement_of_propogate_religion = {
2413
- custom_tooltip = set_trade_power_requirement_of_propogate_religion_$value$_tt
2414
- hidden_effect = {
2415
- set_country_flag = $value$_trade_power_for_propogate_religion
2416
- }
2417
- }
2418
-
2419
- #Country effect
2420
- enable_propogate_religion_immunity = {
2421
- custom_tooltip = enable_propogate_religion_immunity_tt
2422
- hidden_effect = {
2423
- set_country_flag = immunity_against_propogate_religion
2424
- }
2425
- }
2426
-
2427
- #Country effect
2428
- disable_propogate_religion_immunity = {
2429
- custom_tooltip = disable_propogate_religion_immunity_tt
2430
- hidden_effect = {
2431
- clr_country_flag = immunity_against_propogate_religion
2432
- }
2433
- }
2434
-
2435
- #Country effect
2436
- enable_propagate_religion_in_abrahamic_provinces= {
2437
- custom_tooltip = enable_propogate_religion_in_abrahamic_provinces_tt
2438
- hidden_effect = {
2439
- set_country_flag = can_propagate_religion_in_abrahamic_provinces
2440
- }
2441
- }
2442
-
2443
- #Country effect
2444
- disable_propogate_religion_in_abrahamic_provinces = {
2445
- custom_tooltip = disable_propogate_religion_in_abrahamic_provinces_tt
2446
- hidden_effect = {
2447
- clr_country_flag = can_propagate_religion_in_abrahamic_provinces
2448
- }
2449
- }
2450
-
2451
- #Country effect
2452
- #Supports the following Trading Policies
2453
- # maximize_profit
2454
- # hostile_trading
2455
- # improve_inland_routes
2456
- # establish_communities
2457
- # propagate_religion
2458
- #Makes Trading Policy SELECTABLE
2459
- unlock_trading_policy = {
2460
- custom_tooltip = unlock_trading_policy_$policy$_tt
2461
- hidden_effect = {
2462
- clr_country_flag = locked_trading_policy_$policy$
2463
- }
2464
- }
2465
- #Makes Trading Policy UNSELECTABLE
2466
- lock_trading_policy = {
2467
- custom_tooltip = lock_trading_policy_$policy$_tt
2468
- hidden_effect = {
2469
- set_country_flag = locked_trading_policy_$policy$
2470
- }
2471
- }
2472
- #Makes Trading Policy VISIBLE
2473
- enable_trading_policy = {
2474
- custom_tooltip = enable_trading_policy_$policy$_tt
2475
- hidden_effect = {
2476
- set_country_flag = enabled_trading_policy_$policy$
2477
- clr_country_flag = disabled_trading_policy_$policy$
2478
- }
2479
- }
2480
- #Makes Trading Policy INVISIBLE
2481
- disable_trading_policy = {
2482
- custom_tooltip = disable_trading_policy_$policy$_tt
2483
- hidden_effect = {
2484
- set_country_flag = disabled_trading_policy_$policy$
2485
- clr_country_flag = enabled_trading_policy_$policy$
2486
- }
2487
- }
2488
-
2489
2000
  #Country effect
2490
2001
  set_prestige_to_zero = {
2491
2002
  custom_tooltip = set_prestige_to_zero_tt
@@ -2495,93 +2006,6 @@ set_prestige_to_zero = {
2495
2006
  }
2496
2007
  }
2497
2008
 
2498
- #Country effect
2499
- enable_cult_for_heirs = {
2500
- custom_tooltip = enable_cult_for_heirs_tt
2501
- hidden_effect = {
2502
- set_country_flag = enabled_cult_for_heirs
2503
- if = {
2504
- limit = {
2505
- has_heir = yes
2506
- }
2507
- country_event = {
2508
- id = fetishist_flavor.600
2509
- }
2510
- }
2511
- }
2512
- }
2513
-
2514
- #Country effect
2515
- enable_cult_for_heirs_mission = {
2516
- custom_tooltip = enable_cult_for_heirs_tt
2517
- hidden_effect = {
2518
- if = {
2519
- limit = { has_estate_privilege = estate_church_heir_shrine }
2520
- remove_estate_privilege = estate_church_heir_shrine
2521
- }
2522
- set_country_flag = enabled_cult_for_heirs
2523
- set_country_flag = heir_cult_through_missions
2524
- if = {
2525
- limit = {
2526
- has_heir = yes
2527
- }
2528
- country_event = {
2529
- id = fetishist_flavor.600
2530
- }
2531
- }
2532
- }
2533
- }
2534
-
2535
- #Country effect
2536
- remove_heir_cult = {
2537
- trigger_switch = {
2538
- on_trigger = has_country_modifier
2539
- junior_yemoja_cult = { remove_country_modifier = junior_yemoja_cult }
2540
- junior_roog_cult = { remove_country_modifier = junior_roog_cult }
2541
- junior_nyame_cult = { remove_country_modifier = junior_nyame_cult }
2542
- junior_cwezi_cult = { remove_country_modifier = junior_cwezi_cult }
2543
- junior_central_african_ancestor_cult = { remove_country_modifier = junior_central_african_ancestor_cult }
2544
- junior_mwari_cult = { remove_country_modifier = junior_mwari_cult }
2545
- junior_enkai_cult = { remove_country_modifier = junior_enkai_cult }
2546
- junior_waaq_cult = { remove_country_modifier = junior_waaq_cult }
2547
- junior_zanahary_cult = { remove_country_modifier = junior_zanahary_cult }
2548
- junior_christianity_cult = { remove_country_modifier = junior_christianity_cult }
2549
- junior_islam_cult = { remove_country_modifier = junior_islam_cult }
2550
- junior_buddhism_cult = { remove_country_modifier = junior_buddhism_cult }
2551
- junior_dharmic_cult = { remove_country_modifier = junior_dharmic_cult }
2552
- junior_south_central_american_cult = { remove_country_modifier = junior_south_central_american_cult }
2553
- junior_norse_cult = { remove_country_modifier = junior_norse_cult }
2554
- junior_jewish_cult = { remove_country_modifier = junior_jewish_cult }
2555
- junior_zoroastrian_cult = { remove_country_modifier = junior_zoroastrian_cult }
2556
- }
2557
- }
2558
-
2559
- disable_cult_for_heirs = {
2560
- custom_tooltip = disable_cult_for_heirs_tt
2561
- hidden_effect = {
2562
- remove_heir_cult = yes
2563
- clr_country_flag = enabled_cult_for_heirs
2564
- }
2565
- }
2566
-
2567
- #Country effect
2568
- unlock_cult_through_selection = {
2569
- custom_tooltip = unlock_cult_through_selection_tt
2570
- hidden_effect = {
2571
- country_event = {
2572
- id = fetishist_flavor.601
2573
- }
2574
- }
2575
- }
2576
-
2577
- #Country effect
2578
- half_estate_privilege_absolutism_loss = {
2579
- custom_tooltip = half_estate_privilege_absolutism_loss_tt
2580
- hidden_effect = {
2581
- set_country_flag = has_halved_absolutism_reduction
2582
- }
2583
- }
2584
-
2585
2009
  #Province effect
2586
2010
  spawn_country_religious_rebels = {
2587
2011
  owner = {
@@ -2655,49 +2079,10 @@ spawn_province_religious_rebels = {
2655
2079
  }
2656
2080
 
2657
2081
  #Country effect
2658
- disable_annexation_penalty = {
2659
- custom_tooltip = disable_annexation_penalty_tt
2660
- hidden_effect = {
2661
- set_country_flag = no_integrate_penalty
2662
- remove_country_modifier = annexers_legacy
2663
- }
2664
- }
2665
-
2666
- #Country effect
2667
- enable_annexation_penalty = {
2668
- custom_tooltip = enable_annexation_penalty_tt
2082
+ enable_development_on_buildings_built = {
2083
+ custom_tooltip = enable_development_on_buildings_built_tt
2669
2084
  hidden_effect = {
2670
- clr_country_flag = no_integrate_penalty
2671
- }
2672
- }
2673
-
2674
- #Country effect
2675
- enable_cult_switching = {
2676
- custom_tooltip = enable_cult_switching_tt
2677
- hidden_effect = {
2678
- set_country_flag = enabled_cult_switching
2679
- }
2680
- }
2681
- enable_cult_switching_mission = {
2682
- custom_tooltip = enable_cult_switching_tt
2683
- hidden_effect = {
2684
- set_country_flag = enabled_cult_switching_mission
2685
- }
2686
- }
2687
-
2688
- #Country effect
2689
- disable_cult_switching = {
2690
- custom_tooltip = disable_cult_switching_tt
2691
- hidden_effect = {
2692
- clr_country_flag = enabled_cult_switching
2693
- }
2694
- }
2695
-
2696
- #Country effect
2697
- enable_development_on_buildings_built = {
2698
- custom_tooltip = enable_development_on_buildings_built_tt
2699
- hidden_effect = {
2700
- set_country_flag = improve_development_on_buildings_built
2085
+ set_country_flag = improve_development_on_buildings_built
2701
2086
  }
2702
2087
  }
2703
2088
 
@@ -3245,125 +2630,6 @@ clear_primary_cult_bonus = {
3245
2630
  }
3246
2631
  }
3247
2632
 
3248
- #Country effect
3249
- enable_primary_cult = {
3250
- custom_tooltip = enable_primary_cult_tt
3251
- hidden_effect = {
3252
- set_country_flag = uses_primary_cult
3253
- country_event = {
3254
- id = fetishist_flavor.602
3255
- }
3256
- }
3257
- }
3258
-
3259
- #Country effect
3260
- disable_primary_cult = {
3261
- custom_tooltip = disable_primary_cult_tt
3262
- hidden_effect = {
3263
- clr_country_flag = uses_primary_cult
3264
- clr_country_flag = has_selected_a_primary_cult
3265
- clear_previous_primary_cults = yes
3266
- }
3267
- }
3268
-
3269
- #Country effect
3270
- disable_scholar_cost = {
3271
- custom_tooltip = disable_scholar_cost_tt
3272
- hidden_effect = {
3273
- set_country_flag = no_scholar_adm_cost
3274
- }
3275
- }
3276
-
3277
- #Country effect
3278
- enable_scholar_cost = {
3279
- custom_tooltip = enable_scholar_cost_tt
3280
- hidden_effect = {
3281
- clr_country_flag = no_scholar_adm_cost
3282
- }
3283
- }
3284
-
3285
- #Country effect - Estate
3286
- enable_baseline_invite_scholar = {
3287
- custom_tooltip = enable_baseline_invite_scholar_tt
3288
- hidden_effect = {
3289
- country_event = {
3290
- id = muslim_school_events.24
3291
- }
3292
- set_country_flag = enabled_baseline_invite_scholar
3293
- }
3294
- }
3295
-
3296
- enable_baseline_invite_scholar_no_privilege = {
3297
- custom_tooltip = enable_baseline_invite_scholar_tt
3298
- hidden_effect = {
3299
- country_event = {
3300
- id = muslim_school_events.24
3301
- }
3302
- set_country_flag = enabled_baseline_invite_scholar_no_priv
3303
- }
3304
- }
3305
-
3306
- allow_baseline_invite_scholar_privilege = {
3307
- custom_tooltip = allows_every_time_invite_of_$religious_school$
3308
- hidden_effect = {
3309
- set_country_flag = privilege_can_always_invite_$religious_school$
3310
- }
3311
- custom_tooltip = allow_baseline_invite_scholar_privilege_tt
3312
- custom_tooltip = $religious_school$_bonus_tt
3313
- }
3314
-
3315
- disallow_baseline_invite_scholar = {
3316
- hidden_effect = {
3317
- clr_country_flag = privilege_can_always_invite_hanafi_school
3318
- clr_country_flag = privilege_can_always_invite_hanbali_school
3319
- clr_country_flag = privilege_can_always_invite_maliki_school
3320
- clr_country_flag = privilege_can_always_invite_shafii_school
3321
- clr_country_flag = privilege_can_always_invite_ismaili_school
3322
- clr_country_flag = privilege_can_always_invite_jafari_school
3323
- clr_country_flag = privilege_can_always_invite_zaidi_school
3324
- }
3325
- }
3326
-
3327
- disable_baseline_invite_scholar = {
3328
- custom_tooltip = disable_baseline_invite_scholar_tt
3329
- hidden_effect = {
3330
- clr_country_flag = enabled_baseline_invite_scholar
3331
- if = {
3332
- limit = { NOT = { has_country_flag = enabled_baseline_invite_scholar_no_priv } }
3333
- clr_country_flag = privilege_can_always_invite_hanafi_school
3334
- clr_country_flag = privilege_can_always_invite_hanbali_school
3335
- clr_country_flag = privilege_can_always_invite_maliki_school
3336
- clr_country_flag = privilege_can_always_invite_shafii_school
3337
- clr_country_flag = privilege_can_always_invite_ismaili_school
3338
- clr_country_flag = privilege_can_always_invite_jafari_school
3339
- clr_country_flag = privilege_can_always_invite_zaidi_school
3340
- }
3341
- }
3342
- }
3343
-
3344
- #Country effect
3345
- enable_capital_slave_raid = {
3346
- custom_tooltip = enable_capital_slave_raid_tt
3347
- hidden_effect = {
3348
- set_country_flag = enabled_capital_slave_raid
3349
- }
3350
- if = {
3351
- limit = { has_dlc = "Leviathan" }
3352
- custom_tooltip = enable_slave_raid_pillage_tt
3353
- }
3354
- }
3355
-
3356
- disable_capital_slave_raid = {
3357
- custom_tooltip = disable_capital_slave_raid_tt
3358
- hidden_effect = {
3359
- clr_country_flag = enabled_capital_slave_raid
3360
- }
3361
- if = {
3362
- limit = { has_dlc = "Leviathan" }
3363
- custom_tooltip = disable_slave_raid_pillage_tt
3364
- }
3365
- }
3366
-
3367
2633
  #On action effect
3368
2634
  grant_manpower_from_besieging_fort = {
3369
2635
  if = {
@@ -3445,74 +2711,6 @@ slave_raid_pillage_capital_effect = {
3445
2711
  }
3446
2712
  }
3447
2713
 
3448
- #Country effect
3449
- enable_tributary_state_use = {
3450
- if = {
3451
- limit = {
3452
- OR = {
3453
- has_dlc = "Mandate of Heaven"
3454
- has_dlc = "Origins"
3455
- }
3456
- }
3457
- custom_tooltip = enable_tributary_state_use_tt
3458
- }
3459
- hidden_effect = {
3460
- set_country_flag = can_create_tributaries_flag
3461
- }
3462
- }
3463
-
3464
- disable_tributary_state_use = {
3465
- if = {
3466
- limit = {
3467
- OR = {
3468
- has_dlc = "Mandate of Heaven"
3469
- has_dlc = "Origins"
3470
- }
3471
- }
3472
- custom_tooltip = disable_tributary_state_use_tt
3473
- }
3474
- hidden_effect = {
3475
- clr_country_flag = can_create_tributaries_flag
3476
- }
3477
- }
3478
-
3479
- #Use for estate effects
3480
- enable_tributary_state_use_estate = {
3481
- if = {
3482
- limit = {
3483
- OR = {
3484
- has_dlc = "Mandate of Heaven"
3485
- has_dlc = "Origins"
3486
- }
3487
- }
3488
- custom_tooltip = enable_tributary_state_use_tt
3489
- }
3490
- hidden_effect = {
3491
- set_country_flag = can_create_tributaries_flag_estate
3492
- }
3493
- }
3494
-
3495
- disable_tributary_state_use_estate = {
3496
- if = {
3497
- limit = {
3498
- OR = {
3499
- has_dlc = "Mandate of Heaven"
3500
- has_dlc = "Origins"
3501
- }
3502
- }
3503
- custom_tooltip = disable_tributary_state_use_tt
3504
- }
3505
- hidden_effect = {
3506
- clr_country_flag = can_create_tributaries_flag_estate
3507
- }
3508
- every_subject_country = {
3509
- limit = {
3510
- is_subject_of_type = tributary_state
3511
- }
3512
- grant_independence = yes
3513
- }
3514
- }
3515
-
3516
2714
  #Country effect, event target
3517
2715
  select_biggest_country_of_region = {
3518
2716
  if = {
@@ -3766,121 +2964,6 @@ select_biggest_country_of_scope_type = {
3766
2964
  }
3767
2965
  }
3768
2966
 
3769
- #Country effect
3770
- mal_mansa_musa_visit_effect = {
3771
- trigger_switch = {
3772
- on_trigger = has_country_flag
3773
- mal_journey_to_maghreb = { every_country = { limit = { NOT = { tag = ROOT } NOT = { has_country_flag = mal_is_already_getting_visit } capital_scope = { region = maghreb_region } } add_country_modifier = { name = mal_the_gold_inflation duration = 1825 } } }
3774
- mal_journey_to_iberia = { every_country = { limit = { NOT = { tag = ROOT } NOT = { has_country_flag = mal_is_already_getting_visit } capital_scope = { region = iberia_region } } add_country_modifier = { name = mal_the_gold_inflation duration = 1825 } } }
3775
- mal_journey_to_france = { every_country = { limit = { NOT = { tag = ROOT } NOT = { has_country_flag = mal_is_already_getting_visit } capital_scope = { region = france_region } } add_country_modifier = { name = mal_the_gold_inflation duration = 1825 } } }
3776
- mal_journey_to_italy = { every_country = { limit = { NOT = { tag = ROOT } NOT = { has_country_flag = mal_is_already_getting_visit } capital_scope = { region = italy_region } } add_country_modifier = { name = mal_the_gold_inflation duration = 1825 } } }
3777
- mal_journey_to_south_germany = { every_country = { limit = { NOT = { tag = ROOT } NOT = { has_country_flag = mal_is_already_getting_visit } capital_scope = { region = south_german_region } } add_country_modifier = { name = mal_the_gold_inflation duration = 1825 } } }
3778
- mal_journey_to_balkans = { every_country = { limit = { NOT = { tag = ROOT } NOT = { has_country_flag = mal_is_already_getting_visit } capital_scope = { region = balkan_region } } add_country_modifier = { name = mal_the_gold_inflation duration = 1825 } } }
3779
- mal_journey_to_anatolia = { every_country = { limit = { NOT = { tag = ROOT } NOT = { has_country_flag = mal_is_already_getting_visit } capital_scope = { region = anatolia_region } } add_country_modifier = { name = mal_the_gold_inflation duration = 1825 } } }
3780
- mal_journey_to_mashriq = { every_country = { limit = { NOT = { tag = ROOT } NOT = { has_country_flag = mal_is_already_getting_visit } capital_scope = { region = mashriq_region } } add_country_modifier = { name = mal_the_gold_inflation duration = 1825 } } }
3781
- mal_journey_to_egypt = { every_country = { limit = { NOT = { tag = ROOT } NOT = { has_country_flag = mal_is_already_getting_visit } capital_scope = { region = egypt_region } } add_country_modifier = { name = mal_the_gold_inflation duration = 1825 } } }
3782
- mal_journey_to_arabia = { every_country = { limit = { NOT = { tag = ROOT } NOT = { has_country_flag = mal_is_already_getting_visit } capital_scope = { region = arabia_region } } add_country_modifier = { name = mal_the_gold_inflation duration = 1825 } } }
3783
- mal_journey_to_horn_of_africa = { every_country = { limit = { NOT = { tag = ROOT } NOT = { has_country_flag = mal_is_already_getting_visit } capital_scope = { region = horn_of_africa_region } } add_country_modifier = { name = mal_the_gold_inflation duration = 1825 } } }
3784
- }
3785
- }
3786
-
3787
- #Country effect
3788
- mal_invest_in_own_provinces_effect = {
3789
- trigger_switch = {
3790
- on_trigger = has_country_flag
3791
- mal_journey_to_maghreb = { custom_tooltip = mal_invest_in_region_tt hidden_effect = { every_owned_province = { limit = { region = maghreb_region } } add_province_modifier = { name = mal_investing_in_own_provinces duration = 1825 }} }
3792
- mal_journey_to_iberia = { custom_tooltip = mal_invest_in_region_tt hidden_effect = { every_owned_province = { limit = { region = iberia_region } } add_province_modifier = { name = mal_investing_in_own_provinces duration = 1825 }} }
3793
- mal_journey_to_france = { custom_tooltip = mal_invest_in_region_tt hidden_effect = { every_owned_province = { limit = { region = france_region } } add_province_modifier = { name = mal_investing_in_own_provinces duration = 1825 }} }
3794
- mal_journey_to_italy = { custom_tooltip = mal_invest_in_region_tt hidden_effect = { every_owned_province = { limit = { region = italy_region } } add_province_modifier = { name = mal_investing_in_own_provinces duration = 1825 }} }
3795
- mal_journey_to_south_germany = { custom_tooltip = mal_invest_in_region_tt hidden_effect = { every_owned_province = { limit = { region = south_german_region } } add_province_modifier = { name = mal_investing_in_own_provinces duration = 1825 }} }
3796
- mal_journey_to_balkans = { custom_tooltip = mal_invest_in_region_tt hidden_effect = { every_owned_province = { limit = { region = balkan_region } } add_province_modifier = { name = mal_investing_in_own_provinces duration = 1825 }} }
3797
- mal_journey_to_anatolia = { custom_tooltip = mal_invest_in_region_tt hidden_effect = { every_owned_province = { limit = { region = anatolia_region } } add_province_modifier = { name = mal_investing_in_own_provinces duration = 1825 }} }
3798
- mal_journey_to_mashriq = { custom_tooltip = mal_invest_in_region_tt hidden_effect = { every_owned_province = { limit = { region = mashriq_region } } add_province_modifier = { name = mal_investing_in_own_provinces duration = 1825 }} }
3799
- mal_journey_to_egypt = { custom_tooltip = mal_invest_in_region_tt hidden_effect = { every_owned_province = { limit = { region = egypt_region } } add_province_modifier = { name = mal_investing_in_own_provinces duration = 1825 }} }
3800
- mal_journey_to_arabia = { custom_tooltip = mal_invest_in_region_tt hidden_effect = { every_owned_province = { limit = { region = arabia_region } } add_province_modifier = { name = mal_investing_in_own_provinces duration = 1825 }} }
3801
- mal_journey_to_horn_of_africa = { custom_tooltip = mal_invest_in_region_tt hidden_effect = { every_owned_province = { limit = { region = horn_of_africa_region } } add_province_modifier = { name = mal_investing_in_own_provinces duration = 1825 }} }
3802
- }
3803
- }
3804
-
3805
- #Country effect
3806
- mal_travel_to_next_area = {
3807
- if = {
3808
- limit = { has_country_flag = mal_journey_to_maghreb }
3809
- clr_country_flag = mal_journey_to_maghreb
3810
- set_country_flag = mal_journey_to_iberia
3811
- }
3812
- else_if = {
3813
- limit = { has_country_flag = mal_journey_to_iberia }
3814
- clr_country_flag = mal_journey_to_iberia
3815
- set_country_flag = mal_journey_to_france
3816
- }
3817
- else_if = {
3818
- limit = { has_country_flag = mal_journey_to_france }
3819
- clr_country_flag = mal_journey_to_france
3820
- set_country_flag = mal_journey_to_italy
3821
- }
3822
- else_if = {
3823
- limit = { has_country_flag = mal_journey_to_italy }
3824
- clr_country_flag = mal_journey_to_italy
3825
- set_country_flag = mal_journey_to_south_germany
3826
- }
3827
- else_if = {
3828
- limit = { has_country_flag = mal_journey_to_south_germany }
3829
- clr_country_flag = mal_journey_to_south_germany
3830
- set_country_flag = mal_journey_to_balkans
3831
- }
3832
- else_if = {
3833
- limit = { has_country_flag = mal_journey_to_balkans }
3834
- clr_country_flag = mal_journey_to_balkans
3835
- set_country_flag = mal_journey_to_anatolia
3836
- }
3837
- else_if = {
3838
- limit = { has_country_flag = mal_journey_to_anatolia }
3839
- clr_country_flag = mal_journey_to_anatolia
3840
- set_country_flag = mal_journey_to_mashriq
3841
- }
3842
- else_if = {
3843
- limit = { has_country_flag = mal_journey_to_mashriq }
3844
- clr_country_flag = mal_journey_to_mashriq
3845
- set_country_flag = mal_journey_to_egypt
3846
- }
3847
- else_if = {
3848
- limit = { has_country_flag = mal_journey_to_egypt }
3849
- clr_country_flag = mal_journey_to_egypt
3850
- set_country_flag = mal_journey_to_arabia
3851
- }
3852
- else_if = {
3853
- limit = { has_country_flag = mal_journey_to_arabia }
3854
- clr_country_flag = mal_journey_to_arabia
3855
- set_country_flag = mal_journey_to_horn_of_africa
3856
- }
3857
- else_if = {
3858
- limit = { has_country_flag = mal_journey_to_horn_of_africa }
3859
- clr_country_flag = mal_journey_to_horn_of_africa
3860
- set_country_flag = mal_journey_to_home
3861
- }
3862
- clr_country_flag = mal_has_just_arrived
3863
- clr_country_flag = mal_visit_foreign_capital
3864
- }
3865
-
3866
- #Country effect
3867
- mal_select_country_for_region = {
3868
- trigger_switch = {
3869
- on_trigger = has_country_flag
3870
- mal_journey_to_maghreb = { maghreb_region = { discover_country = ROOT } select_biggest_country_of_region = { region = maghreb_region } }
3871
- mal_journey_to_iberia = { iberia_region = { discover_country = ROOT } select_biggest_country_of_region = { region = iberia_region } }
3872
- mal_journey_to_france = { france_region = { discover_country = ROOT } select_biggest_country_of_region = { region = france_region } }
3873
- mal_journey_to_italy = { italy_region = { discover_country = ROOT } select_biggest_country_of_region = { region = italy_region } }
3874
- mal_journey_to_south_germany = { south_german_region = { discover_country = ROOT } select_biggest_country_of_region = { region = south_german_region } }
3875
- mal_journey_to_balkans = { balkan_region = { discover_country = ROOT } select_biggest_country_of_region = { region = balkan_region } }
3876
- mal_journey_to_anatolia = { anatolia_region = { discover_country = ROOT } select_biggest_country_of_region = { region = anatolia_region } }
3877
- mal_journey_to_mashriq = { mashriq_region = { discover_country = ROOT } select_biggest_country_of_region = { region = mashriq_region } }
3878
- mal_journey_to_egypt = { egypt_region = { discover_country = ROOT } select_biggest_country_of_region = { region = egypt_region } }
3879
- mal_journey_to_arabia = { arabia_region = { discover_country = ROOT } select_biggest_country_of_region = { region = arabia_region } }
3880
- mal_journey_to_horn_of_africa = { horn_of_africa_region = { discover_country = ROOT } select_biggest_country_of_region = { region = horn_of_africa_region } }
3881
- }
3882
- }
3883
-
3884
2967
  clr_protestant_aspects_buffs = {
3885
2968
  if = {
3886
2969
  limit = { NOT = { has_church_aspect = organised_through_bishops_aspect } }
@@ -4075,18 +3158,18 @@ faction_in_power_effect = {
4075
3158
  }
4076
3159
 
4077
3160
  ## adds the culture as an accepted culture or 100 dip power
4078
- ### add_accepted_culture_or_dip_power = { culture = <culture> (optional) free = yes (optional) dip_reward = yes (optional, use when you have this effect twice in a row) new_line = yes }
3161
+ ### add_accepted_culture_or_dip_power_stated = { culture = <culture> (optional) free = yes (optional) dip_reward = yes (optional) value = x (optional, works like dip_reward giving X diplomatic power instead) }
4079
3162
  ### the custom effect is only able to check for up to 10 culture slots
4080
3163
  #Credits for that script goes to Stiopa
4081
3164
  # In case you want a culture to be a free slot then make sure that you have the following covered:
4082
3165
  # defined a free_slot_for_$culture$ = { num_accepted_culture = 1 }
4083
3166
  # Supports currently the following cultures:
4084
- # armenian
4085
- # georgian
4086
- # turkish
4087
- # al_iraqiya_arabic
4088
- # al_suryah_arabic
4089
- add_accepted_culture_or_dip_power = {
3167
+ # armenian
3168
+ # georgian
3169
+ # turkish
3170
+ # al_iraqiya_arabic
3171
+ # al_suryah_arabic
3172
+ add_accepted_culture_or_dip_power_stated = {
4090
3173
  tooltip = {
4091
3174
  add_accepted_culture = $culture$
4092
3175
  }
@@ -4345,13 +3428,6 @@ count_won_battles_and_reward_at_end = {
4345
3428
  }
4346
3429
  }
4347
3430
 
4348
- fifty_percent_merc_army_professionalism_cost = {
4349
- custom_tooltip = fifty_percent_merc_army_professionalism_cost_tt
4350
- hidden_effect = {
4351
- set_country_flag = fifty_percent_merc_army_professionalism_cost
4352
- }
4353
- }
4354
-
4355
3431
  #Province effect
4356
3432
  set_center_level_3_center_of_trade = {
4357
3433
  custom_tooltip = set_center_level_3_center_of_trade_tt
@@ -4376,8 +3452,6 @@ set_center_level_3_center_of_trade = {
4376
3452
  }
4377
3453
  }
4378
3454
  }
4379
-
4380
-
4381
3455
  set_center_level_2_center_of_trade = {
4382
3456
  custom_tooltip = set_center_level_2_center_of_trade_tt
4383
3457
  hidden_effect = {
@@ -4397,16 +3471,6 @@ set_center_level_2_center_of_trade = {
4397
3471
  }
4398
3472
  }
4399
3473
 
4400
- enable_admirals_army_professionalism = {
4401
- if = {
4402
- limit = { has_dlc = "Cradle of Civilization" }
4403
- custom_tooltip = admirals_give_army_professionalism_tt
4404
- }
4405
- hidden_effect = {
4406
- set_country_flag = admirals_give_army_professionalism
4407
- }
4408
- }
4409
-
4410
3474
  make_ruler_to_legendary_pirate = {
4411
3475
  if = {
4412
3476
  limit = {
@@ -4657,91 +3721,6 @@ add_influence_to_mil_faction = {
4657
3721
  }
4658
3722
  }
4659
3723
 
4660
- show_points_needed_for_livionian_government_of_category = {
4661
- [[adm]
4662
- if = {
4663
- limit = { NOT = { check_variable = { which = liv_adm value = 5 } } }
4664
- custom_tooltip = livonian_administrative_monarchy_points_needed_tt
4665
- }
4666
- if = {
4667
- limit = { NOT = { check_variable = { which = liv_adm value = 4 } } }
4668
- custom_tooltip = livonian_absolute_monarchy_points_needed_tt
4669
- }
4670
- if = {
4671
- limit = { NOT = { check_variable = { which = liv_adm value = 3 } } }
4672
- custom_tooltip = livonian_trade_monarchy_points_needed_tt
4673
- }
4674
- if = {
4675
- limit = { NOT = { check_variable = { which = liv_adm value = 3 } } }
4676
- custom_tooltip = livonian_constitutional_monarchy_points_needed_tt
4677
- }
4678
- if = {
4679
- limit = { NOT = { check_variable = { which = liv_adm value = 3 } } }
4680
- custom_tooltip = livonian_theocratic_monarchy_points_needed_tt
4681
- }
4682
- if = {
4683
- limit = { NOT = { check_variable = { which = liv_adm value = 2 } } }
4684
- custom_tooltip = livonian_enlightened_monarchy_points_needed_tt
4685
- }
4686
- ]
4687
- [[dip]
4688
- if = {
4689
- limit = { NOT = { check_variable = { which = liv_dip value = 5 } } }
4690
- custom_tooltip = livonian_naval_monarchy_points_needed_tt
4691
- }
4692
- if = {
4693
- limit = { NOT = { check_variable = { which = liv_dip value = 4 } } }
4694
- custom_tooltip = livonian_diplomatic_monarchy_points_needed_tt
4695
- }
4696
- if = {
4697
- limit = { NOT = { check_variable = { which = liv_dip value = 4 } } }
4698
- custom_tooltip = livonian_admiral_monarchy_points_needed_tt
4699
- }
4700
- if = {
4701
- limit = { NOT = { check_variable = { which = liv_dip value = 3 } } }
4702
- custom_tooltip = livonian_trade_monarchy_points_needed_tt
4703
- }
4704
- if = {
4705
- limit = { NOT = { check_variable = { which = liv_dip value = 3 } } }
4706
- custom_tooltip = livonian_elective_monarchy_points_needed_tt
4707
- }
4708
- if = {
4709
- limit = { NOT = { check_variable = { which = liv_dip value = 3 } } }
4710
- custom_tooltip = livonian_naval_controlled_monarchy_points_needed_tt
4711
- }
4712
- if = {
4713
- limit = { NOT = { check_variable = { which = liv_dip value = 2 } } }
4714
- custom_tooltip = livonian_enlightened_monarchy_points_needed_tt
4715
- }
4716
- ]
4717
- [[mil]
4718
- if = {
4719
- limit = { NOT = { check_variable = { which = liv_mil value = 5 } } }
4720
- custom_tooltip = livonian_military_monarchy_points_needed_tt
4721
- }
4722
- if = {
4723
- limit = { NOT = { check_variable = { which = liv_mil value = 4 } } }
4724
- custom_tooltip = livonian_general_controlled_monarchy_points_needed_tt
4725
- }
4726
- if = {
4727
- limit = { NOT = { check_variable = { which = liv_mil value = 3 } } }
4728
- custom_tooltip = livonian_theocratic_monarchy_points_needed_tt
4729
- }
4730
- if = {
4731
- limit = { NOT = { check_variable = { which = liv_mil value = 3 } } }
4732
- custom_tooltip = livonian_mercenary_monarchy_points_needed_tt
4733
- }
4734
- if = {
4735
- limit = { NOT = { check_variable = { which = liv_mil value = 3 } } }
4736
- custom_tooltip = livonian_naval_controlled_monarchy_points_needed_tt
4737
- }
4738
- if = {
4739
- limit = { NOT = { check_variable = { which = liv_mil value = 2 } } }
4740
- custom_tooltip = livonian_enlightened_monarchy_points_needed_tt
4741
- }
4742
- ]
4743
- }
4744
-
4745
3724
  add_revolutionary_zeal_or_absolutism = {
4746
3725
  if = {
4747
3726
  limit = {
@@ -5102,29 +4081,6 @@ increase_gold_discovery = {
5102
4081
  set_country_flag = por_bandeirantes_flag
5103
4082
  }
5104
4083
 
5105
- enable_improved_consecration = {
5106
- if = {
5107
- limit = {
5108
- has_dlc = "Third Rome"
5109
- religion = orthodox
5110
- }
5111
- custom_tooltip = enable_improved_consecration_tt
5112
- }
5113
- hidden_effect = {
5114
- set_country_flag = has_improved_consecration
5115
- every_owned_province = {
5116
- limit = {
5117
- has_state_patriach = yes
5118
- }
5119
- add_province_modifier = {
5120
- name = consecrated_ground
5121
- duration = -1
5122
- hidden = yes
5123
- }
5124
- }
5125
- }
5126
- }
5127
-
5128
4084
  remove_dev_from_building = {
5129
4085
  if = {
5130
4086
  limit = {
@@ -5216,33 +4172,119 @@ create_leader_scaling_with_tradition = {
5216
4172
  custom_tooltip = create_leader_scaling_with_tradition_tt
5217
4173
  }
5218
4174
 
5219
- #type = heavy_ship/light_ship/galley/transport
5220
- add_ship_construction_scaled_to_ports = {
5221
- random_owned_province = {
4175
+ #A Specific case of the above
4176
+ create_general_scaling_with_tradition_and_pips = {
4177
+ if = {
5222
4178
  limit = {
5223
- has_port = yes
4179
+ army_tradition = 80
5224
4180
  }
5225
- if = {
5226
- limit = {
5227
- owner = {
5228
- num_of_ports = 10
5229
- }
5230
- }
5231
- add_unit_construction = {
5232
- amount = 5
5233
- type = $type$
5234
- speed = 0.5
5235
- cost = 0
5236
- }
4181
+ create_general_with_pips = {
4182
+ tradition = 100
4183
+ [[add_fire] add_fire = $add_fire$ ]
4184
+ [[add_shock] add_shock = $add_shock$ ]
4185
+ [[add_manuever] add_manuever = $add_manuever$ ]
4186
+ [[add_siege] add_siege = $add_siege$ ]
5237
4187
  }
5238
- else_if = {
5239
- limit = {
5240
- owner = {
5241
- num_of_ports = 8
5242
- }
5243
- }
5244
- add_unit_construction = {
5245
- amount = 4
4188
+ }
4189
+ else_if = {
4190
+ limit = {
4191
+ army_tradition = 70
4192
+ }
4193
+ create_general_with_pips = {
4194
+ tradition = 90
4195
+ [[add_fire] add_fire = $add_fire$ ]
4196
+ [[add_shock] add_shock = $add_shock$ ]
4197
+ [[add_manuever] add_manuever = $add_manuever$ ]
4198
+ [[add_siege] add_siege = $add_siege$ ]
4199
+ }
4200
+ }
4201
+ else_if = {
4202
+ limit = {
4203
+ army_tradition = 60
4204
+ }
4205
+ create_general_with_pips = {
4206
+ tradition = 80
4207
+ [[add_fire] add_fire = $add_fire$ ]
4208
+ [[add_shock] add_shock = $add_shock$ ]
4209
+ [[add_manuever] add_manuever = $add_manuever$ ]
4210
+ [[add_siege] add_siege = $add_siege$ ]
4211
+ }
4212
+ }
4213
+ else_if = {
4214
+ limit = {
4215
+ army_tradition = 50
4216
+ }
4217
+ create_general_with_pips = {
4218
+ tradition = 70
4219
+ [[add_fire] add_fire = $add_fire$ ]
4220
+ [[add_shock] add_shock = $add_shock$ ]
4221
+ [[add_manuever] add_manuever = $add_manuever$ ]
4222
+ [[add_siege] add_siege = $add_siege$ ]
4223
+ }
4224
+ }
4225
+ else_if = {
4226
+ limit = {
4227
+ army_tradition = 40
4228
+ }
4229
+ create_general_with_pips = {
4230
+ tradition = 60
4231
+ [[add_fire] add_fire = $add_fire$ ]
4232
+ [[add_shock] add_shock = $add_shock$ ]
4233
+ [[add_manuever] add_manuever = $add_manuever$ ]
4234
+ [[add_siege] add_siege = $add_siege$ ]
4235
+ }
4236
+ }
4237
+ else_if = {
4238
+ limit = {
4239
+ army_tradition = 30
4240
+ }
4241
+ create_general_with_pips = {
4242
+ tradition = 50
4243
+ [[add_fire] add_fire = $add_fire$ ]
4244
+ [[add_shock] add_shock = $add_shock$ ]
4245
+ [[add_manuever] add_manuever = $add_manuever$ ]
4246
+ [[add_siege] add_siege = $add_siege$ ]
4247
+ }
4248
+ }
4249
+ else = {
4250
+ create_general_with_pips = {
4251
+ tradition = 40
4252
+ [[add_fire] add_fire = $add_fire$ ]
4253
+ [[add_shock] add_shock = $add_shock$ ]
4254
+ [[add_manuever] add_manuever = $add_manuever$ ]
4255
+ [[add_siege] add_siege = $add_siege$ ]
4256
+ }
4257
+ }
4258
+ custom_tooltip = create_leader_scaling_with_tradition_tt
4259
+ }
4260
+
4261
+ #type = heavy_ship/light_ship/galley/transport
4262
+ add_ship_construction_scaled_to_ports = {
4263
+ random_owned_province = {
4264
+ limit = {
4265
+ has_port = yes
4266
+ }
4267
+ if = {
4268
+ limit = {
4269
+ owner = {
4270
+ num_of_ports = 10
4271
+ }
4272
+ }
4273
+ add_unit_construction = {
4274
+ amount = 5
4275
+ type = $type$
4276
+ speed = 0.5
4277
+ cost = 0
4278
+ }
4279
+ }
4280
+ else_if = {
4281
+ limit = {
4282
+ owner = {
4283
+ num_of_ports = 8
4284
+ }
4285
+ }
4286
+ add_unit_construction = {
4287
+ amount = 4
5246
4288
  type = $type$
5247
4289
  speed = 0.5
5248
4290
  cost = 0
@@ -5274,9 +4316,143 @@ add_ship_construction_scaled_to_ports = {
5274
4316
  cost = 0
5275
4317
  }
5276
4318
  }
4319
+ else = {
4320
+ add_unit_construction = {
4321
+ amount = 1
4322
+ type = $type$
4323
+ speed = 0.5
4324
+ cost = 0
4325
+ }
4326
+ }
4327
+ }
4328
+ }
4329
+ add_ship_construction_scaled_to_ports_MAY = {
4330
+ random_owned_province = {
4331
+ limit = {
4332
+ has_port = yes
4333
+ }
4334
+ if = {
4335
+ limit = {
4336
+ owner = {
4337
+ num_of_ports = 10
4338
+ }
4339
+ }
4340
+ add_unit_construction = {
4341
+ amount = 10
4342
+ type = heavy_ship
4343
+ speed = 0.5
4344
+ cost = 0
4345
+ }
4346
+ }
4347
+ else_if = {
4348
+ limit = {
4349
+ owner = {
4350
+ num_of_ports = 8
4351
+ }
4352
+ }
4353
+ add_unit_construction = {
4354
+ amount = 8
4355
+ type = heavy_ship
4356
+ speed = 0.5
4357
+ cost = 0
4358
+ }
4359
+ }
4360
+ else_if = {
4361
+ limit = {
4362
+ owner = {
4363
+ num_of_ports = 6
4364
+ }
4365
+ }
4366
+ add_unit_construction = {
4367
+ amount = 6
4368
+ type = heavy_ship
4369
+ speed = 0.5
4370
+ cost = 0
4371
+ }
4372
+ }
4373
+ else_if = {
4374
+ limit = {
4375
+ owner = {
4376
+ num_of_ports = 4
4377
+ }
4378
+ }
4379
+ add_unit_construction = {
4380
+ amount = 4
4381
+ type = heavy_ship
4382
+ speed = 0.5
4383
+ cost = 0
4384
+ }
4385
+ }
4386
+ else = {
4387
+ add_unit_construction = {
4388
+ amount = 2
4389
+ type = heavy_ship
4390
+ speed = 0.5
4391
+ cost = 0
4392
+ }
4393
+ }
4394
+ }
4395
+ }
4396
+ add_ship_construction_scaled_to_ports_MAY = {
4397
+ random_owned_province = {
4398
+ limit = {
4399
+ has_port = yes
4400
+ }
4401
+ if = {
4402
+ limit = {
4403
+ owner = {
4404
+ num_of_ports = 10
4405
+ }
4406
+ }
4407
+ add_unit_construction = {
4408
+ amount = 10
4409
+ type = heavy_ship
4410
+ speed = 0.5
4411
+ cost = 0
4412
+ }
4413
+ }
4414
+ else_if = {
4415
+ limit = {
4416
+ owner = {
4417
+ num_of_ports = 8
4418
+ }
4419
+ }
4420
+ add_unit_construction = {
4421
+ amount = 8
4422
+ type = heavy_ship
4423
+ speed = 0.5
4424
+ cost = 0
4425
+ }
4426
+ }
4427
+ else_if = {
4428
+ limit = {
4429
+ owner = {
4430
+ num_of_ports = 6
4431
+ }
4432
+ }
4433
+ add_unit_construction = {
4434
+ amount = 6
4435
+ type = heavy_ship
4436
+ speed = 0.5
4437
+ cost = 0
4438
+ }
4439
+ }
4440
+ else_if = {
4441
+ limit = {
4442
+ owner = {
4443
+ num_of_ports = 4
4444
+ }
4445
+ }
4446
+ add_unit_construction = {
4447
+ amount = 4
4448
+ type = heavy_ship
4449
+ speed = 0.5
4450
+ cost = 0
4451
+ }
4452
+ }
5277
4453
  add_unit_construction = {
5278
- amount = 1
5279
- type = $type$
4454
+ amount = 2
4455
+ type = heavy_ship
5280
4456
  speed = 0.5
5281
4457
  cost = 0
5282
4458
  }
@@ -5757,2792 +4933,47 @@ create_new_culture_group = {
5757
4933
  set_global_flag = updated_$culture_group$_flag
5758
4934
  }
5759
4935
  }
5760
- #Supports the following trade goods Base prices
5761
- # grain 2.5
5762
- # wine 2.5
5763
- # wool 2.5
5764
- # cloth 3
5765
- # fish 2.5
5766
- # fur 2
5767
- # salt 3
5768
- # naval_supplies 2
5769
- # copper 3
5770
- # gold 10 #Technically 0, but let us calculate with 10
5771
- # iron 3
5772
- # slaves 2
5773
- # ivory 4
5774
- # tea 3
5775
- # chinaware 3
5776
- # spices 3
5777
- # coffee 3
5778
- # cotton 3
5779
- # sugar 3
5780
- # tobacco 3
5781
- # cocoa 4
5782
- # silk 4
5783
- # dyes 4
5784
- # tropical_wood 2
5785
- # livestock 2
5786
- # incense 2.5
5787
- # glass 3
5788
- # paper 3.5
5789
- # gems 4
5790
- # coal 10
5791
- # cloves 8
5792
- # unknown 0 #Special and should not count
5793
-
5794
- determine_value_of_trade_goods_grain = {
5795
- set_variable = {
5796
- which = base_value_grain
5797
- value = 2.5
5798
- }
5799
- if = {
5800
- limit = {
5801
- has_chance_scaling_cost = yes
4936
+
4937
+ change_japan_formable_color = {
4938
+ if = {
4939
+ limit = { was_tag = ASK }
4940
+ change_country_color = {
4941
+ color = { 162 32 65 }
5802
4942
  }
5803
- set_variable = {
5804
- which = chance_modifier_grain
5805
- value = 1
4943
+ set_country_flag = has_overriden_color_flag
4944
+ }
4945
+ if = {
4946
+ limit = { was_tag = UES }
4947
+ change_country_color = {
4948
+ color = { 200 200 200 }
5806
4949
  }
5807
- if = {
5808
- limit = {
5809
- ROOT = {
5810
- OR = {
5811
- has_terrain = mountain
5812
- has_terrain = coastal_desert
5813
- has_terrain = forest
5814
- has_terrain = woods
5815
- has_terrain = hills
5816
- has_terrain = jungle
5817
- }
5818
- }
5819
- }
5820
- multiply_variable = {
5821
- which = chance_modifier_grain
5822
- value = 0.15
5823
- }
4950
+ set_country_flag = has_overriden_color_flag
4951
+ }
4952
+ if = {
4953
+ limit = { was_tag = TKI }
4954
+ change_country_color = {
4955
+ color = { 86 84 162 }
5824
4956
  }
5825
- if = {
5826
- limit = {
5827
- ROOT = {
5828
- OR = {
5829
- has_terrain = highlands
5830
- has_terrain = marsh
5831
- }
5832
- }
5833
- }
5834
- multiply_variable = {
5835
- which = chance_modifier_grain
5836
- value = 0.25
5837
- }
4957
+ set_country_flag = has_overriden_color_flag
4958
+ }
4959
+ if = {
4960
+ limit = { was_tag = SMZ }
4961
+ change_country_color = {
4962
+ color = { 101 49 142 }
5838
4963
  }
5839
- if = {
5840
- limit = {
5841
- ROOT = {
5842
- OR = {
5843
- has_climate = arid
5844
- has_climate = tropical
5845
- }
5846
- }
5847
- }
5848
- multiply_variable = {
5849
- which = chance_modifier_grain
5850
- value = 0.25
5851
- }
4964
+ set_country_flag = has_overriden_color_flag
4965
+ }
4966
+ if = {
4967
+ limit = { was_tag = TKD }
4968
+ change_country_color = {
4969
+ color = { 234 85 6 }
5852
4970
  }
5853
- if = {
5854
- limit = {
5855
- ROOT = {
5856
- OR = {
5857
- has_terrain = drylands
5858
- has_terrain = savannah
5859
- has_terrain = steppe
5860
- }
5861
- }
5862
- }
5863
- multiply_variable = {
5864
- which = chance_modifier_grain
5865
- value = 0.6
5866
- }
5867
- }
5868
- if = {
5869
- limit = {
5870
- ROOT = {
5871
- has_winter = severe_winter
5872
- }
5873
- }
5874
- multiply_variable = {
5875
- which = chance_modifier_grain
5876
- value = 0.35
5877
- }
5878
- }
5879
- if = {
5880
- limit = {
5881
- ROOT = {
5882
- has_winter = normal_winter
5883
- }
5884
- }
5885
- multiply_variable = {
5886
- which = chance_modifier_grain
5887
- value = 0.5
5888
- }
5889
- }
5890
- if = {
5891
- limit = {
5892
- ROOT = {
5893
- has_terrain = farmlands
5894
- }
5895
- }
5896
- multiply_variable = {
5897
- which = chance_modifier_grain
5898
- value = 1.5
5899
- }
5900
- }
5901
- if = {
5902
- limit = {
5903
- ROOT = {
5904
- OR = {
5905
- region = poland_region
5906
- region = ruthenia_region
5907
- }
5908
- }
5909
- }
5910
- multiply_variable = {
5911
- which = chance_modifier_grain
5912
- value = 1.5
5913
- }
5914
- }
5915
- if = {
5916
- limit = {
5917
- OR = {
5918
- has_increased_trade_goods_discovery = { trade_goods = grain }
5919
- colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = grain } }
5920
- }
5921
- }
5922
- multiply_variable = {
5923
- which = chance_modifier_grain
5924
- value = 2
5925
- }
5926
- }
5927
- if = {
5928
- limit = {
5929
- NOT = {
5930
- is_variable_equal = {
5931
- which = chance_modifier_grain
5932
- value = 0
5933
- }
5934
- }
5935
- }
5936
- divide_variable = {
5937
- which = base_value_grain
5938
- which = chance_modifier_grain
5939
- }
5940
- }
5941
- }
5942
- }
5943
- determine_value_of_trade_goods_wine = {
5944
- set_variable = {
5945
- which = base_value_wine
5946
- value = 2.5
5947
- }
5948
- if = {
5949
- limit = {
5950
- has_chance_scaling_cost = yes
5951
- }
5952
- set_variable = {
5953
- which = chance_modifier_wine
5954
- value = 1
5955
- }
5956
- if = {
5957
- limit = {
5958
- ROOT = {
5959
- has_winter = normal_winter
5960
- }
5961
- }
5962
- multiply_variable = {
5963
- which = chance_modifier_wine
5964
- value = 0.25
5965
- }
5966
- }
5967
- if = {
5968
- limit = {
5969
- ROOT = {
5970
- has_terrain = farmlands
5971
- }
5972
- }
5973
- multiply_variable = {
5974
- which = chance_modifier_wine
5975
- value = 1.25
5976
- }
5977
- }
5978
- if = {
5979
- limit = {
5980
- ROOT = {
5981
- OR = {
5982
- has_terrain = hills
5983
- has_terrain = highlands
5984
- }
5985
- }
5986
- }
5987
- multiply_variable = {
5988
- which = chance_modifier_wine
5989
- value = 1.25
5990
- }
5991
- }
5992
- if = {
5993
- limit = {
5994
- ROOT = {
5995
- OR = {
5996
- area = cuyo_area
5997
- region = france_region
5998
- region = italy_region
5999
- }
6000
- }
6001
- }
6002
- multiply_variable = {
6003
- which = chance_modifier_wine
6004
- value = 1.5
6005
- }
6006
- }
6007
- if = {
6008
- limit = {
6009
- OR = {
6010
- culture_group = french
6011
- culture_group = iberian
6012
- culture_group = latin
6013
- }
6014
- }
6015
- multiply_variable = {
6016
- which = chance_modifier_wine
6017
- value = 1.1
6018
- }
6019
- }
6020
- if = {
6021
- limit = {
6022
- OR = {
6023
- has_increased_trade_goods_discovery = { trade_goods = wine }
6024
- colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = wine } }
6025
- }
6026
- }
6027
- multiply_variable = {
6028
- which = chance_modifier_wine
6029
- value = 2
6030
- }
6031
- }
6032
- if = {
6033
- limit = {
6034
- NOT = {
6035
- is_variable_equal = {
6036
- which = chance_modifier_wine
6037
- value = 0
6038
- }
6039
- }
6040
- }
6041
- divide_variable = {
6042
- which = base_value_wine
6043
- which = chance_modifier_wine
6044
- }
6045
- }
6046
- }
6047
- }
6048
- determine_value_of_trade_goods_wool = {
6049
- set_variable = {
6050
- which = base_value_wool
6051
- value = 2.5
6052
- }
6053
- if = {
6054
- limit = {
6055
- has_chance_scaling_cost = yes
6056
- }
6057
- set_variable = {
6058
- which = chance_modifier_wool
6059
- value = 1
6060
- }
6061
- if = {
6062
- limit = {
6063
- ROOT = {
6064
- OR = {
6065
- has_terrain = grasslands
6066
- has_terrain = hills
6067
- has_terrain = forest
6068
- has_terrain = woods
6069
- }
6070
- }
6071
- }
6072
- multiply_variable = {
6073
- which = chance_modifier_wool
6074
- value = 0.15
6075
- }
6076
- }
6077
- if = {
6078
- limit = {
6079
- ROOT = {
6080
- OR = {
6081
- has_terrain = desert
6082
- has_terrain = savannah
6083
- has_terrain = highlands
6084
- has_terrain = drylands
6085
- has_climate = arid
6086
- }
6087
- }
6088
- }
6089
- multiply_variable = {
6090
- which = chance_modifier_wool
6091
- value = 1.25
6092
- }
6093
- }
6094
- if = {
6095
- limit = {
6096
- ROOT = {
6097
- region = central_asia_region
6098
- }
6099
- }
6100
- multiply_variable = {
6101
- which = chance_modifier_wool
6102
- value = 1.5
6103
- }
6104
- }
6105
- if = {
6106
- limit = {
6107
- ROOT = {
6108
- region = tibet_region
6109
- }
6110
- }
6111
- multiply_variable = {
6112
- which = chance_modifier_wool
6113
- value = 1.5
6114
- }
6115
- }
6116
- if = {
6117
- limit = {
6118
- OR = {
6119
- has_increased_trade_goods_discovery = { trade_goods = wool }
6120
- colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = wool } }
6121
- }
6122
- }
6123
- multiply_variable = {
6124
- which = chance_modifier_wool
6125
- value = 2
6126
- }
6127
- }
6128
- if = {
6129
- limit = {
6130
- NOT = {
6131
- is_variable_equal = {
6132
- which = chance_modifier_wool
6133
- value = 0
6134
- }
6135
- }
6136
- }
6137
- divide_variable = {
6138
- which = base_value_wool
6139
- which = chance_modifier_wool
6140
- }
6141
- }
6142
- }
6143
- }
6144
- determine_value_of_trade_goods_cloth = {
6145
- set_variable = {
6146
- which = base_value_cloth
6147
- value = 3
6148
- }
6149
- if = {
6150
- limit = {
6151
- has_chance_scaling_cost = yes
6152
- }
6153
- set_variable = {
6154
- which = chance_modifier_cloth
6155
- value = 1
6156
- }
6157
- if = {
6158
- limit = {
6159
- ROOT = {
6160
- development_discounting_tribal = 12
6161
- }
6162
- }
6163
- multiply_variable = {
6164
- which = chance_modifier_cloth
6165
- value = 2
6166
- }
6167
- }
6168
- if = {
6169
- limit = {
6170
- OR = {
6171
- has_increased_trade_goods_discovery = { trade_goods = cloth }
6172
- colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = cloth } }
6173
- }
6174
- }
6175
- multiply_variable = {
6176
- which = chance_modifier_cloth
6177
- value = 2
6178
- }
6179
- }
6180
- if = {
6181
- limit = {
6182
- NOT = {
6183
- is_variable_equal = {
6184
- which = chance_modifier_cloth
6185
- value = 0
6186
- }
6187
- }
6188
- }
6189
- divide_variable = {
6190
- which = base_value_cloth
6191
- which = chance_modifier_cloth
6192
- }
6193
- }
6194
- }
6195
- }
6196
- determine_value_of_trade_goods_fish = {
6197
- set_variable = {
6198
- which = base_value_fish
6199
- value = 2.5
6200
- }
6201
- if = {
6202
- limit = {
6203
- has_chance_scaling_cost = yes
6204
- }
6205
- set_variable = {
6206
- which = chance_modifier_fish
6207
- value = 1
6208
- }
6209
- if = {
6210
- limit = {
6211
- ROOT = {
6212
- OR = {
6213
- region = carribeans_region
6214
- region = malaya_region
6215
- region = moluccas_region
6216
- region = indonesia_region
6217
- }
6218
- }
6219
- }
6220
- multiply_variable = {
6221
- which = chance_modifier_fish
6222
- value = 0.65
6223
- }
6224
- }
6225
- if = {
6226
- limit = {
6227
- ROOT = {
6228
- area = newfoundland_area
6229
- }
6230
- }
6231
- multiply_variable = {
6232
- which = chance_modifier_fish
6233
- value = 15
6234
- }
6235
- }
6236
- if = {
6237
- limit = {
6238
- ROOT = {
6239
- OR = {
6240
- has_terrain = coastline
6241
- has_terrain = coastal_desert
6242
- }
6243
- }
6244
- }
6245
- multiply_variable = {
6246
- which = chance_modifier_fish
6247
- value = 1.1
6248
- }
6249
- }
6250
- if = {
6251
- limit = {
6252
- ROOT = {
6253
- has_terrain = glacier
6254
- }
6255
- }
6256
- multiply_variable = {
6257
- which = chance_modifier_fish
6258
- value = 1.2
6259
- }
6260
- }
6261
- if = {
6262
- limit = {
6263
- OR = {
6264
- has_increased_trade_goods_discovery = { trade_goods = fish }
6265
- colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = fish } }
6266
- }
6267
- }
6268
- multiply_variable = {
6269
- which = chance_modifier_fish
6270
- value = 2
6271
- }
6272
- }
6273
- if = {
6274
- limit = {
6275
- NOT = {
6276
- is_variable_equal = {
6277
- which = chance_modifier_fish
6278
- value = 0
6279
- }
6280
- }
6281
- }
6282
- divide_variable = {
6283
- which = base_value_fish
6284
- which = chance_modifier_fish
6285
- }
6286
- }
6287
- }
6288
- }
6289
- determine_value_of_trade_goods_fur = {
6290
- set_variable = {
6291
- which = base_value_fur
6292
- value = 2
6293
- }
6294
- if = {
6295
- limit = {
6296
- has_chance_scaling_cost = yes
6297
- }
6298
- set_variable = {
6299
- which = chance_modifier_fur
6300
- value = 1
6301
- }
6302
- if = {
6303
- limit = {
6304
- ROOT = {
6305
- OR = {
6306
- has_terrain = savannah
6307
- has_terrain = grasslands
6308
- has_terrain = highlands
6309
- }
6310
- has_winter = mild_winter
6311
- }
6312
- }
6313
- multiply_variable = {
6314
- which = chance_modifier_fur
6315
- value = 0.75
6316
- }
6317
- }
6318
- if = {
6319
- limit = {
6320
- ROOT = {
6321
- NOT = { native_size = 1 }
6322
- }
6323
- }
6324
- multiply_variable = {
6325
- which = chance_modifier_fur
6326
- value = 0.5
6327
- }
6328
- }
6329
- if = {
6330
- limit = {
6331
- ROOT = {
6332
- native_size = 1
6333
- }
6334
- }
6335
- multiply_variable = {
6336
- which = chance_modifier_fur
6337
- value = 2
6338
- }
6339
- }
6340
- if = {
6341
- limit = {
6342
- ROOT = {
6343
- has_terrain = forest
6344
- }
6345
- }
6346
- multiply_variable = {
6347
- which = chance_modifier_fur
6348
- value = 1.5
6349
- }
6350
- }
6351
- if = {
6352
- limit = {
6353
- ROOT = {
6354
- has_winter = normal_winter
6355
- }
6356
- }
6357
- multiply_variable = {
6358
- which = chance_modifier_fur
6359
- value = 1.6
6360
- }
6361
- }
6362
- if = {
6363
- limit = {
6364
- ROOT = {
6365
- has_winter = severe_winter
6366
- NOT = { has_terrain = glacier }
6367
- }
6368
- }
6369
- multiply_variable = {
6370
- which = chance_modifier_fur
6371
- value = 2.5
6372
- }
6373
- }
6374
- if = {
6375
- limit = {
6376
- has_country_flag = encourage_cash_crops_flag
6377
- }
6378
- multiply_variable = {
6379
- which = chance_modifier_fur
6380
- value = 2
6381
- }
6382
- }
6383
- if = {
6384
- limit = {
6385
- OR = {
6386
- has_increased_trade_goods_discovery = { trade_goods = fur }
6387
- colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = fur } }
6388
- }
6389
- }
6390
- multiply_variable = {
6391
- which = chance_modifier_fur
6392
- value = 2
6393
- }
6394
- }
6395
- if = {
6396
- limit = {
6397
- NOT = {
6398
- is_variable_equal = {
6399
- which = chance_modifier_fur
6400
- value = 0
6401
- }
6402
- }
6403
- }
6404
- divide_variable = {
6405
- which = base_value_fur
6406
- which = chance_modifier_fur
6407
- }
6408
- }
6409
- }
6410
- }
6411
- determine_value_of_trade_goods_salt = {
6412
- set_variable = {
6413
- which = base_value_salt
6414
- value = 3
6415
- }
6416
- if = {
6417
- limit = {
6418
- has_chance_scaling_cost = yes
6419
- }
6420
- set_variable = {
6421
- which = chance_modifier_salt
6422
- value = 1
6423
- }
6424
- if = {
6425
- limit = {
6426
- ROOT = {
6427
- OR = {
6428
- has_terrain = desert
6429
- AND = {
6430
- has_terrain = marsh
6431
- NOT = { has_climate = arctic } #Hudson Bay
6432
- }
6433
- }
6434
- }
6435
- }
6436
- multiply_variable = {
6437
- which = chance_modifier_salt
6438
- value = 2
6439
- }
6440
- }
6441
- if = {
6442
- limit = {
6443
- ROOT = {
6444
- region = peru_region
6445
- }
6446
- }
6447
- multiply_variable = {
6448
- which = chance_modifier_salt
6449
- value = 2
6450
- }
6451
- }
6452
- if = {
6453
- limit = {
6454
- ROOT = {
6455
- area = western_sahara_area
6456
- }
6457
- }
6458
- multiply_variable = {
6459
- which = chance_modifier_salt
6460
- value = 2
6461
- }
6462
- }
6463
- if = {
6464
- limit = {
6465
- OR = {
6466
- has_increased_trade_goods_discovery = { trade_goods = salt }
6467
- colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = salt } }
6468
- }
6469
- }
6470
- multiply_variable = {
6471
- which = chance_modifier_salt
6472
- value = 2
6473
- }
6474
- }
6475
- if = {
6476
- limit = {
6477
- NOT = {
6478
- is_variable_equal = {
6479
- which = chance_modifier_salt
6480
- value = 0
6481
- }
6482
- }
6483
- }
6484
- divide_variable = {
6485
- which = base_value_salt
6486
- which = chance_modifier_salt
6487
- }
6488
- }
6489
- }
6490
- }
6491
- determine_value_of_trade_goods_naval_supplies = {
6492
- set_variable = {
6493
- which = base_value_naval_supplies
6494
- value = 2
6495
- }
6496
- if = {
6497
- limit = {
6498
- has_chance_scaling_cost = yes
6499
- }
6500
- set_variable = {
6501
- which = chance_modifier_naval_supplies
6502
- value = 1
6503
- }
6504
- if = {
6505
- limit = {
6506
- ROOT = {
6507
- region = carribeans_region
6508
- }
6509
- }
6510
- multiply_variable = {
6511
- which = chance_modifier_naval_supplies
6512
- value = 0.65
6513
- }
6514
- }
6515
- if = {
6516
- limit = {
6517
- ROOT = {
6518
- OR = {
6519
- has_terrain = mountain
6520
- has_terrain = grasslands
6521
- region = central_africa_region
6522
- }
6523
- }
6524
- }
6525
- multiply_variable = {
6526
- which = chance_modifier_naval_supplies
6527
- value = 0.5
6528
- }
6529
- }
6530
- if = {
6531
- limit = {
6532
- NOT = { num_of_ports = 1 }
6533
- }
6534
- multiply_variable = {
6535
- which = chance_modifier_naval_supplies
6536
- value = 0.5
6537
- }
6538
- }
6539
- if = {
6540
- limit = {
6541
- ROOT = {
6542
- OR = {
6543
- has_terrain = coastline
6544
- has_climate = tropical
6545
- }
6546
- }
6547
- }
6548
- multiply_variable = {
6549
- which = chance_modifier_naval_supplies
6550
- value = 0.75
6551
- }
6552
- }
6553
- if = {
6554
- limit = {
6555
- ROOT = {
6556
- OR = {
6557
- has_terrain = forest
6558
- has_terrain = woods
6559
- has_terrain = hills
6560
- has_terrain = jungle
6561
- }
6562
- }
6563
- }
6564
- multiply_variable = {
6565
- which = chance_modifier_naval_supplies
6566
- value = 1.5
6567
- }
6568
- }
6569
- if = {
6570
- limit = {
6571
- OR = {
6572
- has_increased_trade_goods_discovery = { trade_goods = naval_supplies }
6573
- colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = naval_supplies } }
6574
- }
6575
- }
6576
- multiply_variable = {
6577
- which = chance_modifier_naval_supplies
6578
- value = 2
6579
- }
6580
- }
6581
- if = {
6582
- limit = {
6583
- NOT = {
6584
- is_variable_equal = {
6585
- which = chance_modifier_naval_supplies
6586
- value = 0
6587
- }
6588
- }
6589
- }
6590
- divide_variable = {
6591
- which = base_value_naval_supplies
6592
- which = chance_modifier_naval_supplies
6593
- }
6594
- }
6595
- }
6596
- }
6597
- determine_value_of_trade_goods_copper = {
6598
- set_variable = {
6599
- which = base_value_copper
6600
- value = 3
6601
- }
6602
- if = {
6603
- limit = {
6604
- has_chance_scaling_cost = yes
6605
- }
6606
- set_variable = {
6607
- which = chance_modifier_copper
6608
- value = 1
6609
- }
6610
- if = {
6611
- limit = {
6612
- ROOT = {
6613
- region = central_africa_region
6614
- }
6615
- }
6616
- multiply_variable = {
6617
- which = chance_modifier_copper
6618
- value = 0.7
6619
- }
6620
- }
6621
- if = {
6622
- limit = {
6623
- ROOT = {
6624
- is_random_new_world = yes
6625
- OR = {
6626
- has_terrain = mountain
6627
- has_terrain = highlands
6628
- }
6629
- }
6630
- }
6631
- multiply_variable = {
6632
- which = chance_modifier_copper
6633
- value = 1.1
6634
- }
6635
- }
6636
- if = {
6637
- limit = {
6638
- ROOT = {
6639
- OR = {
6640
- area = minas_gerais_area
6641
- area = diamantina_area
6642
- area = mato_grosso_area
6643
- area = ofaie_area
6644
- area = great_valley_area
6645
- area = susquehanna_area
6646
- area = hudson_valley_area
6647
- area = lake_superior_area
6648
- area = south_iroquoisia_area
6649
- region = west_siberia_region
6650
- region = east_siberia_region
6651
- }
6652
- }
6653
- }
6654
- multiply_variable = {
6655
- which = chance_modifier_copper
6656
- value = 1.5
6657
- }
6658
- }
6659
- if = {
6660
- limit = {
6661
- OR = {
6662
- has_increased_trade_goods_discovery = { trade_goods = copper }
6663
- colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = copper } }
6664
- }
6665
- }
6666
- multiply_variable = {
6667
- which = chance_modifier_copper
6668
- value = 2
6669
- }
6670
- }
6671
- if = {
6672
- limit = {
6673
- NOT = {
6674
- is_variable_equal = {
6675
- which = chance_modifier_copper
6676
- value = 0
6677
- }
6678
- }
6679
- }
6680
- divide_variable = {
6681
- which = base_value_copper
6682
- which = chance_modifier_copper
6683
- }
6684
- }
6685
- }
6686
- }
6687
- determine_value_of_trade_goods_gold = {
6688
- set_variable = {
6689
- which = base_value_gold
6690
- value = 10
6691
- }
6692
- if = {
6693
- limit = {
6694
- #has_chance_scaling_cost = yes
6695
- always = no
6696
- }
6697
- set_variable = {
6698
- which = chance_modifier_gold
6699
- value = 1
6700
- }
6701
- if = {
6702
- limit = {
6703
- ROOT = {
6704
- is_random_new_world = yes
6705
- has_terrain = mountain
6706
- continent = new_world #Always in RNW
6707
- }
6708
- }
6709
- multiply_variable = {
6710
- which = chance_modifier_gold
6711
- value = 1.5
6712
- }
6713
- }
6714
- if = {
6715
- limit = {
6716
- ROOT = {
6717
- normal_or_historical_nations = no
6718
- }
6719
- }
6720
- multiply_variable = {
6721
- which = chance_modifier_gold
6722
- value = 1.5
6723
- }
6724
- }
6725
- if = {
6726
- limit = {
6727
- ROOT = {
6728
- region = peru_region
6729
- }
6730
- }
6731
- multiply_variable = {
6732
- which = chance_modifier_gold
6733
- value = 3.5
6734
- }
6735
- }
6736
- if = {
6737
- limit = {
6738
- ROOT = {
6739
- OR = {
6740
- province_id = 852 # Mexico
6741
- province_id = 853 # Huastec
6742
- province_id = 854 # Sayultecas
6743
- province_id = 2617 # Huichol
6744
- province_id = 856 # Zacatecas
6745
- province_id = 857 # Guichichil
6746
- province_id = 858 # Tamaulipas
6747
- province_id = 2615 # Guamares
6748
- province_id = 4781 # Transvaal (Johannesburg mines)
6749
- }
6750
- }
6751
- }
6752
- multiply_variable = {
6753
- which = chance_modifier_gold
6754
- value = 4
6755
- }
6756
- }
6757
- if = {
6758
- limit = {
6759
- ROOT = {
6760
- OR = {
6761
- area = minas_gerais_area
6762
- area = diamantina_area
6763
- area = mato_grosso_area
6764
- area = ofaie_area
6765
- area = goias_area
6766
- area = pontal_area
6767
- }
6768
- }
6769
- }
6770
- multiply_variable = {
6771
- which = chance_modifier_gold
6772
- value = 3.5
6773
- }
6774
- }
6775
- if = {
6776
- limit = {
6777
- OR = {
6778
- has_country_flag = por_bandeirantes_flag
6779
- colonial_parent = { has_country_flag = por_bandeirantes_flag }
6780
- }
6781
- }
6782
- multiply_variable = {
6783
- which = chance_modifier_gold
6784
- value = 2
6785
- }
6786
- }
6787
- if = {
6788
- limit = {
6789
- OR = {
6790
- has_increased_trade_goods_discovery = { trade_goods = gold }
6791
- colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = gold } }
6792
- }
6793
- }
6794
- multiply_variable = {
6795
- which = chance_modifier_gold
6796
- value = 2
6797
- }
6798
- }
6799
- if = {
6800
- limit = {
6801
- ROOT = {
6802
- province_id = 856
6803
- }
6804
- }
6805
- multiply_variable = {
6806
- which = chance_modifier_gold
6807
- value = 100
6808
- }
6809
- }
6810
- if = {
6811
- limit = {
6812
- NOT = {
6813
- is_variable_equal = {
6814
- which = chance_modifier_gold
6815
- value = 0
6816
- }
6817
- }
6818
- }
6819
- divide_variable = {
6820
- which = base_value_gold
6821
- which = chance_modifier_gold
6822
- }
6823
- }
6824
- }
6825
- }
6826
- determine_value_of_trade_goods_iron = {
6827
- set_variable = {
6828
- which = base_value_iron
6829
- value = 3
6830
- }
6831
- if = {
6832
- limit = {
6833
- has_chance_scaling_cost = yes
6834
- }
6835
- set_variable = {
6836
- which = chance_modifier_iron
6837
- value = 1
6838
- }
6839
- if = {
6840
- limit = {
6841
- ROOT = {
6842
- normal_or_historical_nations = no
6843
- OR = {
6844
- has_terrain = mountain
6845
- has_terrain = hills
6846
- has_terrain = highlands
6847
- province_id = 990
6848
- }
6849
- }
6850
- }
6851
- multiply_variable = {
6852
- which = chance_modifier_iron
6853
- value = 1.2
6854
- }
6855
- }
6856
- if = {
6857
- limit = {
6858
- ROOT = {
6859
- province_id = 990
6860
- }
6861
- }
6862
- multiply_variable = {
6863
- which = chance_modifier_iron
6864
- value = 20
6865
- }
6866
- }
6867
- if = {
6868
- limit = {
6869
- NOT = {
6870
- is_variable_equal = {
6871
- which = chance_modifier_iron
6872
- value = 0
6873
- }
6874
- }
6875
- }
6876
- divide_variable = {
6877
- which = base_value_iron
6878
- which = chance_modifier_iron
6879
- }
6880
- }
6881
- }
6882
- }
6883
- determine_value_of_trade_goods_slaves = {
6884
- set_variable = {
6885
- which = base_value_slaves
6886
- value = 2
6887
- }
6888
- if = {
6889
- limit = {
6890
- has_chance_scaling_cost = yes
6891
- }
6892
- set_variable = {
6893
- which = chance_modifier_slaves
6894
- value = 1
6895
- }
6896
- if = {
6897
- limit = {
6898
- ROOT = {
6899
- OR = {
6900
- region = horn_of_africa_region
6901
- region = kongo_region
6902
- area = west_africa_coast_area
6903
- area = gulf_of_guinea_area
6904
- area = benin_area
6905
- }
6906
- }
6907
- }
6908
- multiply_variable = {
6909
- which = chance_modifier_slaves
6910
- value = 2
6911
- }
6912
- }
6913
- if = {
6914
- limit = {
6915
- ROOT = {
6916
- region = south_africa_region
6917
- }
6918
- }
6919
- multiply_variable = {
6920
- which = chance_modifier_slaves
6921
- value = 0.5
6922
- }
6923
- }
6924
- if = {
6925
- limit = {
6926
- has_country_flag = encourage_cash_crops_flag
6927
- }
6928
- multiply_variable = {
6929
- which = chance_modifier_slaves
6930
- value = 2
6931
- }
6932
- }
6933
- if = {
6934
- limit = {
6935
- OR = {
6936
- has_increased_trade_goods_discovery = { trade_goods = slaves }
6937
- colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = slaves } }
6938
- }
6939
- }
6940
- multiply_variable = {
6941
- which = chance_modifier_slaves
6942
- value = 2
6943
- }
6944
- }
6945
- if = {
6946
- limit = {
6947
- NOT = {
6948
- is_variable_equal = {
6949
- which = chance_modifier_slaves
6950
- value = 0
6951
- }
6952
- }
6953
- }
6954
- divide_variable = {
6955
- which = base_value_slaves
6956
- which = chance_modifier_slaves
6957
- }
6958
- }
6959
- }
6960
- }
6961
- determine_value_of_trade_goods_ivory = {
6962
- set_variable = {
6963
- which = base_value_ivory
6964
- value = 4
6965
- }
6966
- if = {
6967
- limit = {
6968
- has_chance_scaling_cost = yes
6969
- }
6970
- set_variable = {
6971
- which = chance_modifier_ivory
6972
- value = 1
6973
- }
6974
- if = {
6975
- limit = {
6976
- ROOT = {
6977
- OR = {
6978
- region = malaya_region
6979
- region = moluccas_region
6980
- region = indonesia_region
6981
- }
6982
- }
6983
- }
6984
- multiply_variable = {
6985
- which = chance_modifier_ivory
6986
- value = 0.5
6987
- }
6988
- }
6989
- if = {
6990
- limit = {
6991
- ROOT = {
6992
- OR = {
6993
- has_terrain = jungle
6994
- has_terrain = savannah
6995
- }
6996
- }
6997
- }
6998
- multiply_variable = {
6999
- which = chance_modifier_ivory
7000
- value = 1.25
7001
- }
7002
- }
7003
- if = {
7004
- limit = {
7005
- has_country_flag = encourage_cash_crops_flag
7006
- }
7007
- multiply_variable = {
7008
- which = chance_modifier_ivory
7009
- value = 2
7010
- }
7011
- }
7012
- if = {
7013
- limit = {
7014
- OR = {
7015
- has_increased_trade_goods_discovery = { trade_goods = ivory }
7016
- colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = ivory } }
7017
- }
7018
- }
7019
- multiply_variable = {
7020
- which = chance_modifier_ivory
7021
- value = 2
7022
- }
7023
- }
7024
- if = {
7025
- limit = {
7026
- NOT = {
7027
- is_variable_equal = {
7028
- which = chance_modifier_ivory
7029
- value = 0
7030
- }
7031
- }
7032
- }
7033
- divide_variable = {
7034
- which = base_value_ivory
7035
- which = chance_modifier_ivory
7036
- }
7037
- }
7038
- }
7039
- }
7040
- determine_value_of_trade_goods_tea = {
7041
- set_variable = {
7042
- which = base_value_tea
7043
- value = 3
7044
- }
7045
- if = {
7046
- limit = {
7047
- has_chance_scaling_cost = yes
7048
- }
7049
- set_variable = {
7050
- which = chance_modifier_tea
7051
- value = 1
7052
- }
7053
- if = {
7054
- limit = {
7055
- ROOT = {
7056
- has_terrain = farmlands
7057
- }
7058
- }
7059
- multiply_variable = {
7060
- which = chance_modifier_tea
7061
- value = 1.2
7062
- }
7063
- }
7064
- if = {
7065
- limit = {
7066
- ROOT = {
7067
- OR = {
7068
- area = assam_area
7069
- AND = {
7070
- has_climate = tropical
7071
- is_random_new_world = yes
7072
- }
7073
- }
7074
- }
7075
- }
7076
- multiply_variable = {
7077
- which = chance_modifier_tea
7078
- value = 1.5
7079
- }
7080
- }
7081
- if = {
7082
- limit = {
7083
- ROOT = {
7084
- OR = {
7085
- area = banda_oriental_area #Yerba Mate
7086
- area = rio_grande_do_sol_area #Yerba Mate
7087
- area = buenos_aires_area #Yerba Mate
7088
- area = misiones_area #Yerba Mate
7089
- area = beni_area #Yerba Mate
7090
- area = moxos_area #Yerba Mate
7091
- area = paraguay_area #Yerba Mate
7092
- area = sao_paolo_area #Yerba Mate
7093
- area = west_sao_paolo_area #Yerba Mate
7094
- }
7095
- }
7096
- }
7097
- multiply_variable = {
7098
- which = chance_modifier_tea
7099
- value = 1.5
7100
- }
7101
- }
7102
- if = {
7103
- limit = {
7104
- OR = {
7105
- has_increased_trade_goods_discovery = { trade_goods = tea }
7106
- colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = tea } }
7107
- }
7108
- }
7109
- multiply_variable = {
7110
- which = chance_modifier_tea
7111
- value = 2
7112
- }
7113
- }
7114
- if = {
7115
- limit = {
7116
- has_country_flag = encourage_cash_crops_flag
7117
- }
7118
- multiply_variable = {
7119
- which = chance_modifier_tea
7120
- value = 2
7121
- }
7122
- }
7123
- if = {
7124
- limit = {
7125
- NOT = {
7126
- is_variable_equal = {
7127
- which = chance_modifier_tea
7128
- value = 0
7129
- }
7130
- }
7131
- }
7132
- divide_variable = {
7133
- which = base_value_tea
7134
- which = chance_modifier_tea
7135
- }
7136
- }
7137
- }
7138
- }
7139
- determine_value_of_trade_goods_chinaware = {
7140
- set_variable = {
7141
- which = base_value_chinaware
7142
- value = 3
7143
- }
7144
- if = {
7145
- limit = {
7146
- has_chance_scaling_cost = yes
7147
- }
7148
- set_variable = {
7149
- which = chance_modifier_chinaware
7150
- value = 1
7151
- }
7152
- if = {
7153
- limit = {
7154
- has_country_flag = encourage_cash_crops_flag
7155
- }
7156
- multiply_variable = {
7157
- which = chance_modifier_chinaware
7158
- value = 2
7159
- }
7160
- }
7161
- if = {
7162
- limit = {
7163
- OR = {
7164
- has_increased_trade_goods_discovery = { trade_goods = chinaware }
7165
- colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = chinaware } }
7166
- }
7167
- }
7168
- multiply_variable = {
7169
- which = chance_modifier_chinaware
7170
- value = 2
7171
- }
7172
- }
7173
- if = {
7174
- limit = {
7175
- NOT = {
7176
- is_variable_equal = {
7177
- which = chance_modifier_chinaware
7178
- value = 0
7179
- }
7180
- }
7181
- }
7182
- divide_variable = {
7183
- which = base_value_chinaware
7184
- which = chance_modifier_chinaware
7185
- }
7186
- }
7187
- }
7188
- }
7189
- determine_value_of_trade_goods_spices = {
7190
- set_variable = {
7191
- which = base_value_spices
7192
- value = 3
7193
- }
7194
- if = {
7195
- limit = {
7196
- has_chance_scaling_cost = yes
7197
- }
7198
- set_variable = {
7199
- which = chance_modifier_spices
7200
- value = 1
7201
- }
7202
- if = {
7203
- limit = {
7204
- ROOT = {
7205
- area = indian_ocean_islands_area
7206
- }
7207
- }
7208
- multiply_variable = {
7209
- which = chance_modifier_spices
7210
- value = 0.75
7211
- }
7212
- }
7213
- if = {
7214
- limit = {
7215
- ROOT = {
7216
- OR = {
7217
- continent = north_america
7218
- continent = south_america
7219
- }
7220
- }
7221
- }
7222
- multiply_variable = {
7223
- which = chance_modifier_spices
7224
- value = 0.5
7225
- }
7226
- }
7227
- if = {
7228
- limit = {
7229
- ROOT = {
7230
- OR = {
7231
- region = malaya_region
7232
- region = indonesia_region
7233
- region = moluccas_region
7234
- }
7235
- }
7236
- }
7237
- multiply_variable = {
7238
- which = chance_modifier_spices
7239
- value = 1.25
7240
- }
7241
- }
7242
- if = {
7243
- limit = {
7244
- has_country_flag = encourage_cash_crops_flag
7245
- }
7246
- multiply_variable = {
7247
- which = chance_modifier_spices
7248
- value = 2
7249
- }
7250
- }
7251
- if = {
7252
- limit = {
7253
- OR = {
7254
- has_increased_trade_goods_discovery = { trade_goods = spices }
7255
- colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = spices } }
7256
- }
7257
- }
7258
- multiply_variable = {
7259
- which = chance_modifier_spices
7260
- value = 2
7261
- }
7262
- }
7263
- if = {
7264
- limit = {
7265
- NOT = {
7266
- is_variable_equal = {
7267
- which = chance_modifier_spices
7268
- value = 0
7269
- }
7270
- }
7271
- }
7272
- divide_variable = {
7273
- which = base_value_spices
7274
- which = chance_modifier_spices
7275
- }
7276
- }
7277
- }
7278
- }
7279
- determine_value_of_trade_goods_coffee = {
7280
- set_variable = {
7281
- which = base_value_coffee
7282
- value = 3
7283
- }
7284
- if = {
7285
- limit = {
7286
- has_chance_scaling_cost = yes
7287
- }
7288
- set_variable = {
7289
- which = chance_modifier_coffee
7290
- value = 1
7291
- }
7292
- if = {
7293
- limit = {
7294
- ROOT = {
7295
- region = colombia_region
7296
- }
7297
- }
7298
- multiply_variable = {
7299
- which = chance_modifier_coffee
7300
- value = 1.5
7301
- }
7302
- }
7303
- if = {
7304
- limit = {
7305
- has_country_flag = encourage_cash_crops_flag
7306
- }
7307
- multiply_variable = {
7308
- which = chance_modifier_coffee
7309
- value = 2
7310
- }
7311
- }
7312
- if = {
7313
- limit = {
7314
- OR = {
7315
- has_increased_trade_goods_discovery = { trade_goods = coffee }
7316
- colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = coffee } }
7317
- }
7318
- }
7319
- multiply_variable = {
7320
- which = chance_modifier_coffee
7321
- value = 2
7322
- }
7323
- }
7324
- if = {
7325
- limit = {
7326
- NOT = {
7327
- is_variable_equal = {
7328
- which = chance_modifier_coffee
7329
- value = 0
7330
- }
7331
- }
7332
- }
7333
- divide_variable = {
7334
- which = base_value_coffee
7335
- which = chance_modifier_coffee
7336
- }
7337
- }
7338
- }
7339
- }
7340
- determine_value_of_trade_goods_cotton = {
7341
- set_variable = {
7342
- which = base_value_cotton
7343
- value = 3
7344
- }
7345
- if = {
7346
- limit = {
7347
- has_chance_scaling_cost = yes
7348
- }
7349
- set_variable = {
7350
- which = chance_modifier_cotton
7351
- value = 1
7352
- }
7353
- if = {
7354
- limit = {
7355
- ROOT = {
7356
- OR = {
7357
- has_terrain = farmlands
7358
- has_terrain = grasslands
7359
- region = southeast_america_region
7360
- }
7361
- }
7362
- }
7363
- multiply_variable = {
7364
- which = chance_modifier_cotton
7365
- value = 1.5
7366
- }
7367
- }
7368
- if = {
7369
- limit = {
7370
- has_country_flag = encourage_cash_crops_flag
7371
- }
7372
- multiply_variable = {
7373
- which = chance_modifier_cotton
7374
- value = 2
7375
- }
7376
- }
7377
- if = {
7378
- limit = {
7379
- OR = {
7380
- has_increased_trade_goods_discovery = { trade_goods = cotton }
7381
- colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = cotton } }
7382
- }
7383
- }
7384
- multiply_variable = {
7385
- which = chance_modifier_cotton
7386
- value = 2
7387
- }
7388
- }
7389
- if = {
7390
- limit = {
7391
- NOT = {
7392
- is_variable_equal = {
7393
- which = chance_modifier_cotton
7394
- value = 0
7395
- }
7396
- }
7397
- }
7398
- divide_variable = {
7399
- which = base_value_cotton
7400
- which = chance_modifier_cotton
7401
- }
7402
- }
7403
- }
7404
- }
7405
- determine_value_of_trade_goods_sugar = {
7406
- set_variable = {
7407
- which = base_value_sugar
7408
- value = 3
7409
- }
7410
- if = {
7411
- limit = {
7412
- has_chance_scaling_cost = yes
7413
- }
7414
- set_variable = {
7415
- which = chance_modifier_sugar
7416
- value = 1
7417
- }
7418
- if = {
7419
- limit = {
7420
- ROOT = {
7421
- is_random_new_world = no
7422
- NOT = { province_id = 481 }
7423
- OR = {
7424
- region = carribeans_region
7425
- area = ceara_area
7426
- area = pernambuco_area
7427
- area = bahia_area
7428
- area = guyana_area
7429
- area = suriname_area
7430
- }
7431
- }
7432
- }
7433
- multiply_variable = {
7434
- which = chance_modifier_sugar
7435
- value = 2.5
7436
- }
7437
- }
7438
- if = {
7439
- limit = {
7440
- has_country_flag = encourage_cash_crops_flag
7441
- }
7442
- multiply_variable = {
7443
- which = chance_modifier_sugar
7444
- value = 2
7445
- }
7446
- }
7447
- if = {
7448
- limit = {
7449
- OR = {
7450
- has_increased_trade_goods_discovery = { trade_goods = sugar }
7451
- colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = sugar } }
7452
- }
7453
- }
7454
- multiply_variable = {
7455
- which = chance_modifier_sugar
7456
- value = 2
7457
- }
7458
- }
7459
- if = {
7460
- limit = {
7461
- NOT = {
7462
- is_variable_equal = {
7463
- which = chance_modifier_sugar
7464
- value = 0
7465
- }
7466
- }
7467
- }
7468
- divide_variable = {
7469
- which = base_value_sugar
7470
- which = chance_modifier_sugar
7471
- }
7472
- }
7473
- }
7474
- }
7475
- determine_value_of_trade_goods_tobacco = {
7476
- set_variable = {
7477
- which = base_value_tobacco
7478
- value = 3
7479
- }
7480
- if = {
7481
- limit = {
7482
- has_chance_scaling_cost = yes
7483
- }
7484
- set_variable = {
7485
- which = chance_modifier_tobacco
7486
- value = 1
7487
- }
7488
- if = {
7489
- limit = {
7490
- ROOT = {
7491
- OR = {
7492
- region = northeast_america_region
7493
- region = southeast_america_region
7494
- }
7495
- }
7496
- }
7497
- multiply_variable = {
7498
- which = chance_modifier_tobacco
7499
- value = 2.5
7500
- }
7501
- }
7502
- if = {
7503
- limit = {
7504
- ROOT = {
7505
- region = australia_region
7506
- }
7507
- }
7508
- multiply_variable = {
7509
- which = chance_modifier_tobacco
7510
- value = 0.2
7511
- }
7512
- }
7513
- if = {
7514
- limit = {
7515
- has_country_flag = encourage_cash_crops_flag
7516
- }
7517
- multiply_variable = {
7518
- which = chance_modifier_tobacco
7519
- value = 2
7520
- }
7521
- }
7522
- if = {
7523
- limit = {
7524
- OR = {
7525
- has_increased_trade_goods_discovery = { trade_goods = tobacco }
7526
- colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = tobacco } }
7527
- }
7528
- }
7529
- multiply_variable = {
7530
- which = chance_modifier_tobacco
7531
- value = 2
7532
- }
7533
- }
7534
- if = {
7535
- limit = {
7536
- NOT = {
7537
- is_variable_equal = {
7538
- which = chance_modifier_tobacco
7539
- value = 0
7540
- }
7541
- }
7542
- }
7543
- divide_variable = {
7544
- which = base_value_tobacco
7545
- which = chance_modifier_tobacco
7546
- }
7547
- }
7548
- }
7549
- }
7550
- determine_value_of_trade_goods_cocoa = {
7551
- set_variable = {
7552
- which = base_value_cocoa
7553
- value = 4
7554
- }
7555
- if = {
7556
- limit = {
7557
- has_chance_scaling_cost = yes
7558
- }
7559
- set_variable = {
7560
- which = chance_modifier_cocoa
7561
- value = 1
7562
- }
7563
- if = {
7564
- limit = {
7565
- OR = {
7566
- has_increased_trade_goods_discovery = { trade_goods = cocoa }
7567
- colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = cocoa } }
7568
- }
7569
- }
7570
- multiply_variable = {
7571
- which = chance_modifier_cocoa
7572
- value = 2
7573
- }
7574
- }
7575
- if = {
7576
- limit = {
7577
- NOT = {
7578
- is_variable_equal = {
7579
- which = chance_modifier_cocoa
7580
- value = 0
7581
- }
7582
- }
7583
- }
7584
- divide_variable = {
7585
- which = base_value_cocoa
7586
- which = chance_modifier_cocoa
7587
- }
7588
- }
7589
- }
7590
- }
7591
- determine_value_of_trade_goods_silk = {
7592
- set_variable = {
7593
- which = base_value_silk
7594
- value = 4
7595
- }
7596
- if = {
7597
- limit = {
7598
- has_chance_scaling_cost = yes
7599
- }
7600
- set_variable = {
7601
- which = chance_modifier_silk
7602
- value = 1
7603
- }
7604
- if = {
7605
- limit = {
7606
- ROOT = {
7607
- normal_or_historical_nations = no
7608
- FROM = { NOT = { religion_group = dharmic } }
7609
- FROM = { NOT = { religion_group = eastern } }
7610
- }
7611
- }
7612
- multiply_variable = {
7613
- which = chance_modifier_silk
7614
- value = 0.5
7615
- }
7616
- }
7617
- if = {
7618
- limit = {
7619
- ROOT = {
7620
- normal_or_historical_nations = no
7621
- OR = {
7622
- region = south_china_region
7623
- region = xinan_region
7624
- region = north_china_region
7625
- region = hindusthan_region
7626
- region = bengal_region
7627
- region = deccan_region
7628
- region = coromandel_region
7629
- }
7630
- development_discounting_tribal = 20
7631
- }
7632
- }
7633
- multiply_variable = {
7634
- which = chance_modifier_silk
7635
- value = 1.5
7636
- }
7637
- }
7638
- if = {
7639
- limit = {
7640
- has_country_flag = encourage_cash_crops_flag
7641
- }
7642
- multiply_variable = {
7643
- which = chance_modifier_silk
7644
- value = 2
7645
- }
7646
- }
7647
- if = {
7648
- limit = {
7649
- OR = {
7650
- has_increased_trade_goods_discovery = { trade_goods = silk }
7651
- colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = silk } }
7652
- }
7653
- }
7654
- multiply_variable = {
7655
- which = chance_modifier_silk
7656
- value = 2
7657
- }
7658
- }
7659
- if = {
7660
- limit = {
7661
- NOT = {
7662
- is_variable_equal = {
7663
- which = chance_modifier_silk
7664
- value = 0
7665
- }
7666
- }
7667
- }
7668
- divide_variable = {
7669
- which = base_value_silk
7670
- which = chance_modifier_silk
7671
- }
7672
- }
7673
- }
7674
- }
7675
- determine_value_of_trade_goods_dyes = {
7676
- set_variable = {
7677
- which = base_value_dyes
7678
- value = 4
7679
- }
7680
- if = {
7681
- limit = {
7682
- has_chance_scaling_cost = yes
7683
- }
7684
- set_variable = {
7685
- which = chance_modifier_dyes
7686
- value = 1
7687
- }
7688
- if = {
7689
- limit = {
7690
- has_country_flag = encourage_cash_crops_flag
7691
- }
7692
- multiply_variable = {
7693
- which = chance_modifier_dyes
7694
- value = 2
7695
- }
7696
- }
7697
- if = {
7698
- limit = {
7699
- OR = {
7700
- has_increased_trade_goods_discovery = { trade_goods = dyes }
7701
- colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = dyes } }
7702
- }
7703
- }
7704
- multiply_variable = {
7705
- which = chance_modifier_dyes
7706
- value = 2
7707
- }
7708
- }
7709
- if = {
7710
- limit = {
7711
- NOT = {
7712
- is_variable_equal = {
7713
- which = chance_modifier_dyes
7714
- value = 0
7715
- }
7716
- }
7717
- }
7718
- divide_variable = {
7719
- which = base_value_dyes
7720
- which = chance_modifier_dyes
7721
- }
7722
- }
7723
- }
7724
- }
7725
- determine_value_of_trade_goods_tropical_wood = {
7726
- set_variable = {
7727
- which = base_value_tropical_wood
7728
- value = 2
7729
- }
7730
- if = {
7731
- limit = {
7732
- has_chance_scaling_cost = yes
7733
- }
7734
- set_variable = {
7735
- which = chance_modifier_tropical_wood
7736
- value = 1
7737
- }
7738
- if = {
7739
- limit = {
7740
- ROOT = {
7741
- area = amazon_area
7742
- }
7743
- }
7744
- multiply_variable = {
7745
- which = chance_modifier_tropical_wood
7746
- value = 2
7747
- }
7748
- }
7749
- if = {
7750
- limit = {
7751
- ROOT = {
7752
- OR = {
7753
- region = malaya_region
7754
- region = moluccas_region
7755
- region = indonesia_region
7756
- }
7757
- }
7758
- }
7759
- multiply_variable = {
7760
- which = chance_modifier_tropical_wood
7761
- value = 0.5
7762
- }
7763
- }
7764
- if = {
7765
- limit = {
7766
- has_country_flag = encourage_cash_crops_flag
7767
- }
7768
- multiply_variable = {
7769
- which = chance_modifier_tropical_wood
7770
- value = 2
7771
- }
7772
- }
7773
- if = {
7774
- limit = {
7775
- OR = {
7776
- has_increased_trade_goods_discovery = { trade_goods = tropical_wood }
7777
- colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = tropical_wood } }
7778
- }
7779
- }
7780
- multiply_variable = {
7781
- which = chance_modifier_tropical_wood
7782
- value = 2
7783
- }
7784
- }
7785
- if = {
7786
- limit = {
7787
- NOT = {
7788
- is_variable_equal = {
7789
- which = chance_modifier_tropical_wood
7790
- value = 0
7791
- }
7792
- }
7793
- }
7794
- divide_variable = {
7795
- which = base_value_tropical_wood
7796
- which = chance_modifier_tropical_wood
7797
- }
7798
- }
7799
- }
7800
- }
7801
- determine_value_of_trade_goods_livestock = {
7802
- set_variable = {
7803
- which = base_value_livestock
7804
- value = 2
7805
- }
7806
- if = {
7807
- limit = {
7808
- has_chance_scaling_cost = yes
7809
- }
7810
- set_variable = {
7811
- which = chance_modifier_livestock
7812
- value = 1
7813
- }
7814
- if = {
7815
- limit = {
7816
- ROOT = {
7817
- province_id = 2002
7818
- }
7819
- }
7820
- multiply_variable = {
7821
- which = chance_modifier_livestock
7822
- value = 0.05
7823
- }
7824
- }
7825
- if = {
7826
- limit = {
7827
- ROOT = {
7828
- has_winter = severe_winter
7829
- }
7830
- }
7831
- multiply_variable = {
7832
- which = chance_modifier_livestock
7833
- value = 0.75
7834
- }
7835
- }
7836
- if = {
7837
- limit = {
7838
- ROOT = {
7839
- OR = {
7840
- has_terrain = desert
7841
- has_terrain = savannah
7842
- has_terrain = highlands
7843
- has_terrain = drylands
7844
- has_climate = arid
7845
- }
7846
- }
7847
- }
7848
- multiply_variable = {
7849
- which = chance_modifier_livestock
7850
- value = 1.25
7851
- }
7852
- }
7853
- if = {
7854
- limit = {
7855
- ROOT = {
7856
- has_terrain = steppe
7857
- }
7858
- }
7859
- multiply_variable = {
7860
- which = chance_modifier_livestock
7861
- value = 1.5
7862
- }
7863
- }
7864
- if = {
7865
- limit = {
7866
- ROOT = {
7867
- region = central_asia_region
7868
- }
7869
- }
7870
- multiply_variable = {
7871
- which = chance_modifier_livestock
7872
- value = 1.5
7873
- }
7874
- }
7875
- if = {
7876
- limit = {
7877
- ROOT = {
7878
- region = mongolia_region
7879
- }
7880
- }
7881
- multiply_variable = {
7882
- which = chance_modifier_livestock
7883
- value = 1.5
7884
- }
7885
- }
7886
- if = {
7887
- limit = {
7888
- ROOT = {
7889
- region = tibet_region
7890
- }
7891
- }
7892
- multiply_variable = {
7893
- which = chance_modifier_livestock
7894
- value = 1.5
7895
- }
7896
- }
7897
- if = {
7898
- limit = {
7899
- ROOT = {
7900
- region = central_africa_region
7901
- }
7902
- }
7903
- multiply_variable = {
7904
- which = chance_modifier_livestock
7905
- value = 1.5
7906
- }
7907
- }
7908
- if = {
7909
- limit = {
7910
- OR = {
7911
- has_increased_trade_goods_discovery = { trade_goods = livestock }
7912
- colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = livestock } }
7913
- }
7914
- }
7915
- multiply_variable = {
7916
- which = chance_modifier_livestock
7917
- value = 2
7918
- }
7919
- }
7920
- if = {
7921
- limit = {
7922
- NOT = {
7923
- is_variable_equal = {
7924
- which = chance_modifier_livestock
7925
- value = 0
7926
- }
7927
- }
7928
- }
7929
- divide_variable = {
7930
- which = base_value_livestock
7931
- which = chance_modifier_livestock
7932
- }
7933
- }
7934
- }
7935
- }
7936
- determine_value_of_trade_goods_incense = {
7937
- set_variable = {
7938
- which = base_value_incense
7939
- value = 2.5
7940
- }
7941
- if = {
7942
- limit = {
7943
- has_chance_scaling_cost = yes
7944
- }
7945
- set_variable = {
7946
- which = chance_modifier_incense
7947
- value = 1
7948
- }
7949
- if = {
7950
- limit = {
7951
- ROOT = {
7952
- area = indian_ocean_islands_area
7953
- }
7954
- }
7955
- multiply_variable = {
7956
- which = chance_modifier_incense
7957
- value = 0.5
7958
- }
7959
- }
7960
- if = {
7961
- limit = {
7962
- ROOT = {
7963
- region = arabia_region
7964
- }
7965
- }
7966
- multiply_variable = {
7967
- which = chance_modifier_incense
7968
- value = 1.25
7969
- }
7970
- }
7971
- if = {
7972
- limit = {
7973
- has_country_flag = encourage_cash_crops_flag
7974
- }
7975
- multiply_variable = {
7976
- which = chance_modifier_incense
7977
- value = 2
7978
- }
7979
- }
7980
- if = {
7981
- limit = {
7982
- OR = {
7983
- has_increased_trade_goods_discovery = { trade_goods = incense }
7984
- colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = incense } }
7985
- }
7986
- }
7987
- multiply_variable = {
7988
- which = chance_modifier_incense
7989
- value = 2
7990
- }
7991
- }
7992
- if = {
7993
- limit = {
7994
- NOT = {
7995
- is_variable_equal = {
7996
- which = chance_modifier_incense
7997
- value = 0
7998
- }
7999
- }
8000
- }
8001
- divide_variable = {
8002
- which = base_value_incense
8003
- which = chance_modifier_incense
8004
- }
8005
- }
8006
- }
8007
- }
8008
- determine_value_of_trade_goods_glass = {
8009
- set_variable = {
8010
- which = base_value_glass
8011
- value = 3
8012
- }
8013
- if = {
8014
- limit = {
8015
- has_chance_scaling_cost = yes
8016
- }
8017
- set_variable = {
8018
- which = chance_modifier_glass
8019
- value = 1
8020
- }
8021
- if = {
8022
- limit = {
8023
- ROOT = {
8024
- development_discounting_tribal = 22
8025
- }
8026
- }
8027
- multiply_variable = {
8028
- which = chance_modifier_glass
8029
- value = 2
8030
- }
8031
- }
8032
- if = {
8033
- limit = {
8034
- OR = {
8035
- has_increased_trade_goods_discovery = { trade_goods = glass }
8036
- colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = glass } }
8037
- }
8038
- }
8039
- multiply_variable = {
8040
- which = chance_modifier_glass
8041
- value = 2
8042
- }
8043
- }
8044
- if = {
8045
- limit = {
8046
- NOT = {
8047
- is_variable_equal = {
8048
- which = chance_modifier_glass
8049
- value = 0
8050
- }
8051
- }
8052
- }
8053
- divide_variable = {
8054
- which = base_value_glass
8055
- which = chance_modifier_glass
8056
- }
8057
- }
8058
- }
8059
- }
8060
- determine_value_of_trade_goods_paper = {
8061
- set_variable = {
8062
- which = base_value_paper
8063
- value = 3.5
8064
- }
8065
- if = {
8066
- limit = {
8067
- has_chance_scaling_cost = yes
8068
- }
8069
- set_variable = {
8070
- which = chance_modifier_paper
8071
- value = 1
8072
- }
8073
- if = {
8074
- limit = {
8075
- ROOT = {
8076
- development_discounting_tribal = 22
8077
- }
8078
- }
8079
- multiply_variable = {
8080
- which = chance_modifier_paper
8081
- value = 2
8082
- }
8083
- }
8084
- if = {
8085
- limit = {
8086
- OR = {
8087
- has_increased_trade_goods_discovery = { trade_goods = paper }
8088
- colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = paper } }
8089
- }
8090
- }
8091
- multiply_variable = {
8092
- which = chance_modifier_paper
8093
- value = 2
8094
- }
8095
- }
8096
- if = {
8097
- limit = {
8098
- NOT = {
8099
- is_variable_equal = {
8100
- which = chance_modifier_paper
8101
- value = 0
8102
- }
8103
- }
8104
- }
8105
- divide_variable = {
8106
- which = base_value_paper
8107
- which = chance_modifier_paper
8108
- }
8109
- }
8110
- }
8111
- }
8112
- determine_value_of_trade_goods_gems = {
8113
- set_variable = {
8114
- which = base_value_gems
8115
- value = 4
8116
- }
8117
- if = {
8118
- limit = {
8119
- has_chance_scaling_cost = yes
8120
- }
8121
- set_variable = {
8122
- which = chance_modifier_gems
8123
- value = 1
8124
- }
8125
- if = {
8126
- limit = {
8127
- ROOT = {
8128
- region = moluccas_region
8129
- }
8130
- }
8131
- multiply_variable = {
8132
- which = chance_modifier_gems
8133
- value = 1.2
8134
- }
8135
- }
8136
- if = {
8137
- limit = {
8138
- ROOT = {
8139
- region = indonesia_region
8140
- }
8141
- }
8142
- multiply_variable = {
8143
- which = chance_modifier_gems
8144
- value = 0.75
8145
- }
8146
- }
8147
- if = {
8148
- limit = {
8149
- ROOT = {
8150
- continent = oceania
8151
- }
8152
- }
8153
- multiply_variable = {
8154
- which = chance_modifier_gems
8155
- value = 0.5
8156
- }
8157
- }
8158
- if = {
8159
- limit = {
8160
- ROOT = {
8161
- OR = {
8162
- continent = south_america
8163
- continent = north_america
8164
- }
8165
- }
8166
- }
8167
- multiply_variable = {
8168
- which = chance_modifier_gems
8169
- value = 1.5
8170
- }
8171
- }
8172
- if = {
8173
- limit = {
8174
- ROOT = {
8175
- OR = {
8176
- area = diamantina_area
8177
- area = bogota_area
8178
- area = murray_river_area #Opal
8179
- }
8180
- }
8181
- }
8182
- multiply_variable = {
8183
- which = chance_modifier_gems
8184
- value = 2
8185
- }
8186
- }
8187
- if = {
8188
- limit = {
8189
- ROOT = {
8190
- OR = {
8191
- province_id = 1093 #Opal
8192
- province_id = 2736 #Opal
8193
- province_id = 4862 #Opal
8194
- }
8195
- }
8196
- }
8197
- multiply_variable = {
8198
- which = chance_modifier_gems
8199
- value = 2
8200
- }
8201
- }
8202
- if = {
8203
- limit = {
8204
- ROOT = {
8205
- region = brazil_region
8206
- }
8207
- }
8208
- multiply_variable = {
8209
- which = chance_modifier_gems
8210
- value = 1.5
8211
- }
8212
- }
8213
- if = {
8214
- limit = {
8215
- ROOT = {
8216
- OR = {
8217
- has_terrain = mountain
8218
- has_terrain = jungle
8219
- has_terrain = hills
8220
- has_terrain = highlands
8221
- has_terrain = coastline #Pearls
8222
- }
8223
- }
8224
- }
8225
- multiply_variable = {
8226
- which = chance_modifier_gems
8227
- value = 1.5
8228
- }
8229
- }
8230
- if = {
8231
- limit = {
8232
- ROOT = {
8233
- is_random_new_world = yes
8234
- has_terrain = mountain
8235
- continent = new_world #Always in RNW
8236
- }
8237
- }
8238
- multiply_variable = {
8239
- which = chance_modifier_gems
8240
- value = 1.5
8241
- }
8242
- }
8243
- if = {
8244
- limit = {
8245
- ROOT = {
8246
- normal_or_historical_nations = no
8247
- }
8248
- }
8249
- multiply_variable = {
8250
- which = chance_modifier_gems
8251
- value = 1.5
8252
- }
8253
- }
8254
- if = {
8255
- limit = {
8256
- has_country_flag = encourage_cash_crops_flag
8257
- }
8258
- multiply_variable = {
8259
- which = chance_modifier_gems
8260
- value = 1.5
8261
- }
8262
- }
8263
- if = {
8264
- limit = {
8265
- OR = {
8266
- has_increased_trade_goods_discovery = { trade_goods = gems }
8267
- colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = gems } }
8268
- }
8269
- }
8270
- multiply_variable = {
8271
- which = chance_modifier_gems
8272
- value = 1.5
8273
- }
8274
- }
8275
- if = {
8276
- limit = {
8277
- NOT = {
8278
- is_variable_equal = {
8279
- which = chance_modifier_gems
8280
- value = 0
8281
- }
8282
- }
8283
- }
8284
- divide_variable = {
8285
- which = base_value_gems
8286
- which = chance_modifier_gems
8287
- }
8288
- }
8289
- }
8290
- }
8291
- determine_value_of_trade_goods_coal = {
8292
- set_variable = {
8293
- which = base_value_coal
8294
- value = 10
8295
- }
8296
- if = {
8297
- limit = {
8298
- #has_chance_scaling_cost = yes
8299
- always = no
8300
- }
8301
- set_variable = {
8302
- which = chance_modifier_coal
8303
- value = 1
8304
- }
8305
- if = {
8306
- limit = {
8307
- NOT = {
8308
- is_variable_equal = {
8309
- which = chance_modifier_coal
8310
- value = 0
8311
- }
8312
- }
8313
- }
8314
- divide_variable = {
8315
- which = base_value_coal
8316
- which = chance_modifier_coal
8317
- }
8318
- }
8319
- }
8320
- }
8321
- determine_value_of_trade_goods_cloves = {
8322
- set_variable = {
8323
- which = base_value_cloves
8324
- value = 8
8325
- }
8326
- if = {
8327
- limit = {
8328
- has_chance_scaling_cost = yes
8329
- }
8330
- set_variable = {
8331
- which = chance_modifier_cloves
8332
- value = 1
8333
- }
8334
- if = {
8335
- limit = {
8336
- has_country_flag = encourage_cash_crops_flag
8337
- }
8338
- multiply_variable = {
8339
- which = chance_modifier_cloves
8340
- value = 2
8341
- }
8342
- }
8343
- if = {
8344
- limit = {
8345
- OR = {
8346
- has_increased_trade_goods_discovery = { trade_goods = cloves }
8347
- colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = cloves } }
8348
- }
8349
- }
8350
- multiply_variable = {
8351
- which = chance_modifier_cloves
8352
- value = 2
8353
- }
8354
- }
8355
- if = {
8356
- limit = {
8357
- NOT = {
8358
- is_variable_equal = {
8359
- which = chance_modifier_cloves
8360
- value = 0
8361
- }
8362
- }
8363
- }
8364
- divide_variable = {
8365
- which = base_value_cloves
8366
- which = chance_modifier_cloves
8367
- }
8368
- }
8369
- }
8370
- }
8371
- determine_value_of_trade_goods_unknown = {
8372
- set_variable = {
8373
- which = base_value_unknown
8374
- value = 0
8375
- }
8376
- }
8377
-
8378
- # The design behind it is the following:
8379
- # 1. You colonize a province
8380
- # 2. A pop-up event appears which gives you the choice to select the trade good for the province
8381
- # 3. Every trade good has an own base price assigned to them. This base price should be their base value * 5 Ducats.
8382
- # 4. Trade goods above 3 value also cost ADM power.
8383
- # 5. Every time you select a certain trade good, the price increases
8384
- # 6. The new price is calculated with this formula: (1 + (times you upgraded it)) * 5 (base trade good price)
8385
- # 7. ADM costs are calculated as follows: (base trade good pirce - 2.5) * 25 * (times YOU upgraded it) as long (base trade good pirce - 2.5) => 0
8386
- # 7. Gold will be counted as having a trade value of 10 Ducats so not all of the whole new world becomes one huge gold cluster
8387
-
8388
- calculate_trade_goods_price = {
8389
- owner = {
8390
- determine_value_of_trade_goods_$trade_goods$ = yes
8391
- set_variable = {
8392
- which = final_ducat_price_$trade_goods$
8393
- value = 1
8394
- }
8395
- set_variable = {
8396
- which = final_adm_cost_$trade_goods$
8397
- which = base_value_$trade_goods$
8398
- }
8399
- subtract_variable = {
8400
- which = final_adm_cost_$trade_goods$
8401
- value = 2.5
8402
- }
8403
- multiply_variable = {
8404
- which = final_adm_cost_$trade_goods$
8405
- value = 5
8406
- }
8407
- #Determine price increase on your own
8408
- if = {
8409
- limit = { has_country_flag = ever_selected_$trade_goods$ }
8410
- change_variable = {
8411
- which = final_ducat_price_$trade_goods$
8412
- which = ducat_cost_$trade_goods$_own_counter
8413
- }
8414
- if = {
8415
- limit = {
8416
- check_variable = {
8417
- which = final_adm_cost_$trade_goods$
8418
- value = 1
8419
- }
8420
- }
8421
- multiply_variable = {
8422
- which = final_adm_cost_$trade_goods$
8423
- which = ducat_cost_$trade_goods$_own_counter
8424
- }
8425
- }
8426
- }
8427
- multiply_variable = {
8428
- which = final_ducat_price_$trade_goods$
8429
- value = 10
8430
- }
8431
- multiply_variable = {
8432
- which = final_ducat_price_$trade_goods$
8433
- which = base_value_$trade_goods$
8434
- }
8435
- }
8436
- }
8437
-
8438
- purchase_trade_goods = {
8439
- custom_tooltip = ducat_price_for_$trade_goods$_tt
8440
- if = {
8441
- limit = {
8442
- owner = {
8443
- check_variable = {
8444
- which = final_adm_cost_$trade_goods$
8445
- value = 1
8446
- }
8447
- }
8448
- }
8449
- custom_tooltip = adm_price_for_$trade_goods$_tt
8450
- }
8451
- hidden_effect = {
8452
- owner = {
8453
- if = {
8454
- limit = { NOT = { has_country_flag = ever_selected_$trade_goods$ } }
8455
- set_country_flag = ever_selected_$trade_goods$
8456
- set_variable = {
8457
- which = ducat_cost_$trade_goods$_own_counter
8458
- value = 1
8459
- }
8460
- }
8461
- else = {
8462
- change_variable = {
8463
- which = ducat_cost_$trade_goods$_own_counter
8464
- value = 1
8465
- }
8466
- }
8467
- while = {
8468
- limit = {
8469
- check_variable = {
8470
- which = final_ducat_price_$trade_goods$
8471
- value = 1
8472
- }
8473
- }
8474
- add_treasury = -1
8475
- subtract_variable = {
8476
- which = final_ducat_price_$trade_goods$
8477
- value = 1
8478
- }
8479
- }
8480
- if = {
8481
- limit = {
8482
- check_variable = {
8483
- which = final_adm_cost_$trade_goods$
8484
- value = 1
8485
- }
8486
- }
8487
- while = {
8488
- limit = {
8489
- check_variable = {
8490
- which = final_adm_cost_$trade_goods$
8491
- value = 1
8492
- }
8493
- }
8494
- add_adm_power = -1
8495
- subtract_variable = {
8496
- which = final_adm_cost_$trade_goods$
8497
- value = 1
8498
- }
8499
- }
8500
- }
8501
- }
8502
- }
8503
- change_trade_goods = $trade_goods$
8504
- }
8505
-
8506
- change_japan_formable_color = {
8507
- if = {
8508
- limit = { was_tag = ASK }
8509
- change_country_color = {
8510
- color = { 162 32 65 }
8511
- }
8512
- set_country_flag = has_overriden_color_flag
8513
- }
8514
- if = {
8515
- limit = { was_tag = UES }
8516
- change_country_color = {
8517
- color = { 200 200 200 }
8518
- }
8519
- set_country_flag = has_overriden_color_flag
8520
- }
8521
- if = {
8522
- limit = { was_tag = TKI }
8523
- change_country_color = {
8524
- color = { 86 84 162 }
8525
- }
8526
- set_country_flag = has_overriden_color_flag
8527
- }
8528
- if = {
8529
- limit = { was_tag = SMZ }
8530
- change_country_color = {
8531
- color = { 101 49 142 }
8532
- }
8533
- set_country_flag = has_overriden_color_flag
8534
- }
8535
- if = {
8536
- limit = { was_tag = TKD }
8537
- change_country_color = {
8538
- color = { 234 85 6 }
8539
- }
8540
- set_country_flag = has_overriden_color_flag
8541
- }
8542
- if = {
8543
- limit = { was_tag = SOO }
8544
- change_country_color = {
8545
- color = { 231 96 158 }
4971
+ set_country_flag = has_overriden_color_flag
4972
+ }
4973
+ if = {
4974
+ limit = { was_tag = SOO }
4975
+ change_country_color = {
4976
+ color = { 231 96 158 }
8546
4977
  }
8547
4978
  set_country_flag = has_overriden_color_flag
8548
4979
  }
@@ -8590,187 +5021,6 @@ change_japan_formable_color = {
8590
5021
  }
8591
5022
  }
8592
5023
 
8593
- #civic_republicanism_focus_government
8594
- #civic_republicanism_focus_expansion
8595
- #civic_republicanism_focus_technology
8596
- #civic_republicanism_focus_stability
8597
- #civic_republicanism_focus_religion
8598
-
8599
- #civic_republicanism_focus_diplomacy
8600
- #civic_republicanism_focus_court
8601
- #civic_republicanism_focus_trade
8602
- #civic_republicanism_focus_subjects
8603
- #civic_republicanism_focus_development
8604
-
8605
- #civic_republicanism_focus_defensive
8606
- #civic_republicanism_focus_sieges
8607
- #civic_republicanism_focus_leaders
8608
- #civic_republicanism_focus_quality
8609
- #civic_republicanism_focus_naval
8610
-
8611
- pre_select_possible_ruler_focus_adm = {
8612
- random_list = {
8613
- 1 = { set_country_flag = civic_republicanism_focus_government_flag }
8614
- 1 = { set_country_flag = civic_republicanism_focus_expansion_flag }
8615
- 1 = { set_country_flag = civic_republicanism_focus_technology_flag }
8616
- 1 = { set_country_flag = civic_republicanism_focus_stability_flag }
8617
- 1 = { set_country_flag = civic_republicanism_focus_religion_flag }
8618
- }
8619
- }
8620
- pre_select_possible_ruler_focus_dip = {
8621
- random_list = {
8622
- 1 = { set_country_flag = civic_republicanism_focus_diplomacy_flag }
8623
- 1 = { set_country_flag = civic_republicanism_focus_court_flag }
8624
- 1 = { set_country_flag = civic_republicanism_focus_trade_flag }
8625
- 1 = { set_country_flag = civic_republicanism_focus_subjects_flag }
8626
- 1 = { set_country_flag = civic_republicanism_focus_development_flag }
8627
- }
8628
- }
8629
- pre_select_possible_ruler_focus_mil = {
8630
- random_list = {
8631
- 1 = { set_country_flag = civic_republicanism_focus_defensive_flag }
8632
- 1 = { set_country_flag = civic_republicanism_focus_sieges_flag }
8633
- 1 = { set_country_flag = civic_republicanism_focus_leaders_flag }
8634
- 1 = { set_country_flag = civic_republicanism_focus_quality_flag }
8635
- 1 = { set_country_flag = civic_republicanism_focus_naval_flag }
8636
- }
8637
- }
8638
- pre_select_possible_ruler_focus_rng = {
8639
- random_list = {
8640
- 1 = { set_country_flag = RNG_civic_republicanism_focus_government }
8641
- 1 = { set_country_flag = RNG_civic_republicanism_focus_expansion }
8642
- 1 = { set_country_flag = RNG_civic_republicanism_focus_technology }
8643
- 1 = { set_country_flag = RNG_civic_republicanism_focus_stability }
8644
- 1 = { set_country_flag = RNG_civic_republicanism_focus_religion }
8645
- 1 = { set_country_flag = RNG_civic_republicanism_focus_diplomacy }
8646
- 1 = { set_country_flag = RNG_civic_republicanism_focus_court }
8647
- 1 = { set_country_flag = RNG_civic_republicanism_focus_trade }
8648
- 1 = { set_country_flag = RNG_civic_republicanism_focus_subjects }
8649
- 1 = { set_country_flag = RNG_civic_republicanism_focus_development }
8650
- 1 = { set_country_flag = RNG_civic_republicanism_focus_defensive }
8651
- 1 = { set_country_flag = RNG_civic_republicanism_focus_sieges }
8652
- 1 = { set_country_flag = RNG_civic_republicanism_focus_leaders }
8653
- 1 = { set_country_flag = RNG_civic_republicanism_focus_quality }
8654
- 1 = { set_country_flag = RNG_civic_republicanism_focus_naval }
8655
- }
8656
- }
8657
-
8658
- pre_select_possible_ruler_focus = {
8659
- pre_select_possible_ruler_focus_adm = yes
8660
- pre_select_possible_ruler_focus_dip = yes
8661
- pre_select_possible_ruler_focus_mil = yes
8662
- pre_select_possible_ruler_focus_rng = yes
8663
- }
8664
-
8665
- assign_ruler_focus_adm = {
8666
- trigger_switch = {
8667
- on_trigger = has_country_flag
8668
- civic_republicanism_focus_government_flag = { add_ruler_modifier = { name = civic_republicanism_focus_government duration = -1 } }
8669
- civic_republicanism_focus_expansion_flag = { add_ruler_modifier = { name = civic_republicanism_focus_expansion duration = -1 } }
8670
- civic_republicanism_focus_technology_flag = { add_ruler_modifier = { name = civic_republicanism_focus_technology duration = -1 } }
8671
- civic_republicanism_focus_stability_flag = { add_ruler_modifier = { name = civic_republicanism_focus_stability duration = -1 } }
8672
- civic_republicanism_focus_religion_flag = { add_ruler_modifier = { name = civic_republicanism_focus_religion duration = -1 } }
8673
- }
8674
- }
8675
- assign_ruler_focus_dip = {
8676
- trigger_switch = {
8677
- on_trigger = has_country_flag
8678
- civic_republicanism_focus_diplomacy_flag = { add_ruler_modifier = { name = civic_republicanism_focus_diplomacy duration = -1 } }
8679
- civic_republicanism_focus_court_flag = { add_ruler_modifier = { name = civic_republicanism_focus_court duration = -1 } }
8680
- civic_republicanism_focus_trade_flag = { add_ruler_modifier = { name = civic_republicanism_focus_trade duration = -1 } }
8681
- civic_republicanism_focus_subjects_flag = { add_ruler_modifier = { name = civic_republicanism_focus_subjects duration = -1 } }
8682
- civic_republicanism_focus_development_flag = { add_ruler_modifier = { name = civic_republicanism_focus_development duration = -1 } }
8683
- }
8684
- }
8685
- assign_ruler_focus_mil = {
8686
- trigger_switch = {
8687
- on_trigger = has_country_flag
8688
- civic_republicanism_focus_defensive_flag = { add_ruler_modifier = { name = civic_republicanism_focus_defensive duration = -1 } }
8689
- civic_republicanism_focus_sieges_flag = { add_ruler_modifier = { name = civic_republicanism_focus_sieges duration = -1 } }
8690
- civic_republicanism_focus_leaders_flag = { add_ruler_modifier = { name = civic_republicanism_focus_leaders duration = -1 } }
8691
- civic_republicanism_focus_quality_flag = { add_ruler_modifier = { name = civic_republicanism_focus_quality duration = -1 } }
8692
- civic_republicanism_focus_naval_flag = { add_ruler_modifier = { name = civic_republicanism_focus_naval duration = -1 } }
8693
- }
8694
- }
8695
- assign_ruler_focus_rng = {
8696
- trigger_switch = {
8697
- on_trigger = has_country_flag
8698
- RNG_civic_republicanism_focus_government = { add_ruler_modifier = { name = civic_republicanism_focus_government duration = -1 } }
8699
- RNG_civic_republicanism_focus_expansion = { add_ruler_modifier = { name = civic_republicanism_focus_expansion duration = -1 } }
8700
- RNG_civic_republicanism_focus_technology = { add_ruler_modifier = { name = civic_republicanism_focus_technology duration = -1 } }
8701
- RNG_civic_republicanism_focus_stability = { add_ruler_modifier = { name = civic_republicanism_focus_stability duration = -1 } }
8702
- RNG_civic_republicanism_focus_religion = { add_ruler_modifier = { name = civic_republicanism_focus_religion duration = -1 } }
8703
- RNG_civic_republicanism_focus_diplomacy = { add_ruler_modifier = { name = civic_republicanism_focus_diplomacy duration = -1 } }
8704
- RNG_civic_republicanism_focus_court = { add_ruler_modifier = { name = civic_republicanism_focus_court duration = -1 } }
8705
- RNG_civic_republicanism_focus_trade = { add_ruler_modifier = { name = civic_republicanism_focus_trade duration = -1 } }
8706
- RNG_civic_republicanism_focus_subjects = { add_ruler_modifier = { name = civic_republicanism_focus_subjects duration = -1 } }
8707
- RNG_civic_republicanism_focus_development = { add_ruler_modifier = { name = civic_republicanism_focus_development duration = -1 } }
8708
- RNG_civic_republicanism_focus_defensive = { add_ruler_modifier = { name = civic_republicanism_focus_defensive duration = -1 } }
8709
- RNG_civic_republicanism_focus_sieges = { add_ruler_modifier = { name = civic_republicanism_focus_sieges duration = -1 } }
8710
- RNG_civic_republicanism_focus_leaders = { add_ruler_modifier = { name = civic_republicanism_focus_leaders duration = -1 } }
8711
- RNG_civic_republicanism_focus_quality = { add_ruler_modifier = { name = civic_republicanism_focus_quality duration = -1 } }
8712
- RNG_civic_republicanism_focus_naval = { add_ruler_modifier = { name = civic_republicanism_focus_naval duration = -1 } }
8713
- }
8714
- }
8715
-
8716
- assign_ruler_focus = {
8717
- assign_ruler_focus_$type$ = yes
8718
- }
8719
-
8720
- post_ruler_focus_clearance = {
8721
- hidden_effect = {
8722
- clr_country_flag = civic_republicanism_focus_government_flag
8723
- clr_country_flag = civic_republicanism_focus_expansion_flag
8724
- clr_country_flag = civic_republicanism_focus_technology_flag
8725
- clr_country_flag = civic_republicanism_focus_stability_flag
8726
- clr_country_flag = civic_republicanism_focus_religion_flag
8727
- clr_country_flag = civic_republicanism_focus_diplomacy_flag
8728
- clr_country_flag = civic_republicanism_focus_court_flag
8729
- clr_country_flag = civic_republicanism_focus_trade_flag
8730
- clr_country_flag = civic_republicanism_focus_subjects_flag
8731
- clr_country_flag = civic_republicanism_focus_development_flag
8732
- clr_country_flag = civic_republicanism_focus_defensive_flag
8733
- clr_country_flag = civic_republicanism_focus_sieges_flag
8734
- clr_country_flag = civic_republicanism_focus_leaders_flag
8735
- clr_country_flag = civic_republicanism_focus_quality_flag
8736
- clr_country_flag = civic_republicanism_focus_naval_flag
8737
- clr_country_flag = RNG_civic_republicanism_focus_government
8738
- clr_country_flag = RNG_civic_republicanism_focus_expansion
8739
- clr_country_flag = RNG_civic_republicanism_focus_technology
8740
- clr_country_flag = RNG_civic_republicanism_focus_stability
8741
- clr_country_flag = RNG_civic_republicanism_focus_religion
8742
- clr_country_flag = RNG_civic_republicanism_focus_diplomacy
8743
- clr_country_flag = RNG_civic_republicanism_focus_court
8744
- clr_country_flag = RNG_civic_republicanism_focus_trade
8745
- clr_country_flag = RNG_civic_republicanism_focus_subjects
8746
- clr_country_flag = RNG_civic_republicanism_focus_development
8747
- clr_country_flag = RNG_civic_republicanism_focus_defensive
8748
- clr_country_flag = RNG_civic_republicanism_focus_sieges
8749
- clr_country_flag = RNG_civic_republicanism_focus_leaders
8750
- clr_country_flag = RNG_civic_republicanism_focus_quality
8751
- clr_country_flag = RNG_civic_republicanism_focus_naval
8752
- }
8753
- }
8754
-
8755
- clr_ruler_focus_modifiers = {
8756
- post_ruler_focus_clearance = yes
8757
- if = { limit = { has_country_modifier = civic_republicanism_focus_government } remove_country_modifier = civic_republicanism_focus_government }
8758
- if = { limit = { has_country_modifier = civic_republicanism_focus_expansion } remove_country_modifier = civic_republicanism_focus_expansion }
8759
- if = { limit = { has_country_modifier = civic_republicanism_focus_technology } remove_country_modifier = civic_republicanism_focus_technology }
8760
- if = { limit = { has_country_modifier = civic_republicanism_focus_stability } remove_country_modifier = civic_republicanism_focus_stability }
8761
- if = { limit = { has_country_modifier = civic_republicanism_focus_religion } remove_country_modifier = civic_republicanism_focus_religion }
8762
- if = { limit = { has_country_modifier = civic_republicanism_focus_diplomacy } remove_country_modifier = civic_republicanism_focus_diplomacy }
8763
- if = { limit = { has_country_modifier = civic_republicanism_focus_court } remove_country_modifier = civic_republicanism_focus_court }
8764
- if = { limit = { has_country_modifier = civic_republicanism_focus_trade } remove_country_modifier = civic_republicanism_focus_trade }
8765
- if = { limit = { has_country_modifier = civic_republicanism_focus_subjects } remove_country_modifier = civic_republicanism_focus_subjects }
8766
- if = { limit = { has_country_modifier = civic_republicanism_focus_development } remove_country_modifier = civic_republicanism_focus_development }
8767
- if = { limit = { has_country_modifier = civic_republicanism_focus_defensive } remove_country_modifier = civic_republicanism_focus_defensive }
8768
- if = { limit = { has_country_modifier = civic_republicanism_focus_sieges } remove_country_modifier = civic_republicanism_focus_sieges }
8769
- if = { limit = { has_country_modifier = civic_republicanism_focus_leaders } remove_country_modifier = civic_republicanism_focus_leaders }
8770
- if = { limit = { has_country_modifier = civic_republicanism_focus_quality } remove_country_modifier = civic_republicanism_focus_quality }
8771
- if = { limit = { has_country_modifier = civic_republicanism_focus_naval } remove_country_modifier = civic_republicanism_focus_naval }
8772
- }
8773
-
8774
5024
  for_every_level_of_advisor_do = {
8775
5025
  if = {
8776
5026
  limit = {
@@ -8803,964 +5053,1585 @@ for_every_level_of_advisor_do = {
8803
5053
  }
8804
5054
  }
8805
5055
  }
8806
-
8807
- complete_artwork_effect_architecture = {
8808
- if = {
8809
- limit = { any_owned_province = { has_building = temple } }
8810
- random_owned_province = { limit = { has_building = temple } upgrade_building = { tax = yes } }
8811
- }
8812
- else = {
8813
- random_owned_province = {
8814
- limit = { NOT = { has_building = cathedral } religion = root culture = root }
5056
+
5057
+
5058
+ # All is province scope here
5059
+ ## add/upgrade trade building in province
5060
+ ### add_or_upgrade_trade_building = yes # feel free to refactor to include the amount of upgrades
5061
+ add_or_upgrade_trade_building = {
5062
+ custom_tooltip = add_or_upgrade_trade_building_tt
5063
+ hidden_effect = {
5064
+ if = {
5065
+ limit = { has_building = marketplace }
5066
+ add_building = trade_depot
5067
+ }
5068
+ else_if = {
5069
+ limit = { has_building = trade_depot }
5070
+ add_building = stock_exchange
5071
+ }
5072
+ else_if = {
5073
+ limit = { has_building = stock_exchange }
5074
+ add_base_tax = 1
5075
+ add_base_production = 1
5076
+ }
5077
+ else = { add_building = marketplace }
5078
+ }
5079
+ }
5080
+ add_or_upgrade_tax_building = {
5081
+ custom_tooltip = add_or_upgrade_tax_building_tt
5082
+ hidden_effect = {
5083
+ if = {
5084
+ limit = { has_building = temple }
5085
+ add_building = cathedral
5086
+ }
5087
+ else_if = {
5088
+ limit = { has_building = cathedral }
5089
+ add_base_tax = 2
5090
+ }
5091
+ else = { add_building = temple }
5092
+ }
5093
+ }
5094
+ add_or_upgrade_production_building = {
5095
+ custom_tooltip = add_or_upgrade_production_building_tt
5096
+ hidden_effect = {
5097
+ if = {
5098
+ limit = { has_building = workshop }
5099
+ add_building = counting_house
5100
+ }
5101
+ else_if = {
5102
+ limit = { has_building = counting_house }
5103
+ add_base_production = 2
5104
+ }
5105
+ else = { add_building = workshop }
5106
+ }
5107
+ }
5108
+ add_or_upgrade_dock_building = {
5109
+ custom_tooltip = add_or_upgrade_dock_building_tt
5110
+ hidden_effect = {
5111
+ if = {
5112
+ limit = { has_building = dock }
5113
+ add_building = drydock
5114
+ }
5115
+ else_if = {
5116
+ limit = { has_building = drydock }
5117
+ ROOT = { add_sailors = 500 }
5118
+ }
5119
+ else = { add_building = dock }
5120
+ }
5121
+ }
5122
+ add_or_upgrade_shipyard_building = {
5123
+ custom_tooltip = add_or_upgrade_shipyard_building_tt
5124
+ hidden_effect = {
5125
+ if = {
5126
+ limit = { has_building = shipyard }
5127
+ add_building = grand_shipyard
5128
+ }
5129
+ else_if = {
5130
+ limit = { has_building = grand_shipyard }
5131
+ ROOT = { add_sailors = 500 }
5132
+ }
5133
+ else = { add_building = shipyard }
5134
+ }
5135
+ }
5136
+ add_or_upgrade_manpower_building = {
5137
+ custom_tooltip = add_or_upgrade_manpower_building_tt
5138
+ hidden_effect = {
5139
+ if = {
5140
+ limit = { has_building = barracks }
5141
+ add_building = training_fields
5142
+ }
5143
+ else_if = {
5144
+ limit = { has_building = training_fields }
5145
+ add_base_tax = 1
5146
+ add_base_manpower = 1
5147
+ }
5148
+ else = { add_building = barracks }
5149
+ }
5150
+ }
5151
+ add_or_upgrade_forcelimit_building = {
5152
+ custom_tooltip = add_or_upgrade_forcelimit_building_tt
5153
+ hidden_effect = {
5154
+ if = {
5155
+ limit = { has_building = regimental_camp }
5156
+ add_building = conscription_center
5157
+ }
5158
+ else_if = {
5159
+ limit = { has_building = conscription_center }
5160
+ add_base_manpower = 2
5161
+ }
5162
+ else = { add_building = regimental_camp }
5163
+ }
5164
+ }
5165
+ add_or_upgrade_university_building = {
5166
+ custom_tooltip = add_or_upgrade_university_building_tt
5167
+ hidden_effect = {
5168
+ if = {
5169
+ limit = { has_building = university }
5170
+ add_base_tax = 1
5171
+ add_base_production = 1
5172
+ add_base_manpower = 1
5173
+ }
5174
+ else = { add_building = university }
5175
+ }
5176
+ }
5177
+ add_or_upgrade_courthouse_building = {
5178
+ custom_tooltip = add_or_upgrade_courthouse_building_tt
5179
+ hidden_effect = {
5180
+ if = {
5181
+ limit = { has_building = courthouse }
5182
+ add_building = town_hall
5183
+ }
5184
+ else_if = {
5185
+ limit = { has_building = town_hall }
5186
+ add_base_tax = 1
5187
+ add_base_production = 1
5188
+ add_base_manpower = 1
5189
+ }
5190
+ else = { add_building = courthouse }
5191
+ }
5192
+ }
5193
+ add_or_upgrade_fort_building = {
5194
+ custom_tooltip = add_or_upgrade_fort_building_tt
5195
+ hidden_effect = {
5196
+ if = {
5197
+ limit = { has_building = fort_15th }
5198
+ add_building = fort_16th
5199
+ }
5200
+ else_if = {
5201
+ limit = { has_building = fort_16th }
5202
+ add_building = fort_17th
5203
+ }
5204
+ else_if = {
5205
+ limit = { has_building = fort_17th }
5206
+ add_building = fort_18th
5207
+ }
5208
+ else_if = {
5209
+ limit = { has_building = fort_18th }
5210
+ add_base_manpower = 3
5211
+ }
5212
+ else = { add_building = fort_15th }
5213
+ }
5214
+ }
5215
+ add_or_upgrade_naval_defense_building = {
5216
+ custom_tooltip = add_or_upgrade_naval_defense_building_tt
5217
+ hidden_effect = {
5218
+ if = {
5219
+ limit = { has_building = coastal_defence }
5220
+ add_building = naval_battery
5221
+ }
5222
+ else_if = {
5223
+ limit = { has_building = naval_battery }
5224
+ add_base_production = 2
5225
+ }
5226
+ else = { add_building = coastal_defence }
5227
+ }
5228
+ }
5229
+ upgrade_trade_building = {
5230
+ custom_tooltip = upgrade_trade_building_tt
5231
+ hidden_effect = {
5232
+ if = {
5233
+ limit = { has_building = marketplace }
5234
+ add_building = trade_depot
5235
+ }
5236
+ else_if = {
5237
+ limit = { has_building = trade_depot }
5238
+ add_building = stock_exchange
5239
+ }
5240
+ else_if = {
5241
+ limit = { has_building = stock_exchange }
5242
+ add_base_tax = 1
5243
+ add_base_production = 1
5244
+ }
5245
+ }
5246
+ }
5247
+ upgrade_tax_building = {
5248
+ custom_tooltip = upgrade_tax_building_tt
5249
+ hidden_effect = {
5250
+ if = {
5251
+ limit = { has_building = temple }
8815
5252
  add_building = cathedral
8816
5253
  }
8817
- }
8818
- custom_tooltip = DUE_TO_ART_QUALITY_FOLLOWING_EFFECT_HAPPENS_TT
8819
- if = {
8820
- limit = { check_variable = { which = art_quality value = 4 } }
8821
- add_government_power = {
8822
- mechanic_type = persian_influence_mechanic
8823
- power_type = persian_influence
8824
- value = 25
8825
- }
8826
- random_owned_province = {
8827
- limit = { religion = root culture = root }
8828
- add_base_tax = 3
8829
- }
8830
- }
8831
- else_if = {
8832
- limit = { check_variable = { which = art_quality value = 3 } }
8833
- add_government_power = {
8834
- mechanic_type = persian_influence_mechanic
8835
- power_type = persian_influence
8836
- value = 20
8837
- }
8838
- random_owned_province = {
8839
- limit = { religion = root culture = root }
5254
+ else_if = {
5255
+ limit = { has_building = cathedral }
8840
5256
  add_base_tax = 2
8841
5257
  }
8842
5258
  }
8843
- else_if = {
8844
- limit = { check_variable = { which = art_quality value = 2 } }
8845
- add_government_power = {
8846
- mechanic_type = persian_influence_mechanic
8847
- power_type = persian_influence
8848
- value = 15
8849
- }
8850
- random_owned_province = {
8851
- limit = { religion = root culture = root }
8852
- add_base_tax = 1
8853
- }
8854
- }
8855
- else_if = {
8856
- limit = { check_variable = { which = art_quality value = 1 } }
8857
- add_government_power = {
8858
- mechanic_type = persian_influence_mechanic
8859
- power_type = persian_influence
8860
- value = 10
5259
+ }
5260
+ upgrade_production_building = {
5261
+ custom_tooltip = upgrade_production_building_tt
5262
+ hidden_effect = {
5263
+ if = {
5264
+ limit = { has_building = workshop }
5265
+ add_building = counting_house
8861
5266
  }
8862
- }
8863
- else = {
8864
- add_prestige = -20
8865
- add_government_power = {
8866
- mechanic_type = persian_influence_mechanic
8867
- power_type = persian_influence
8868
- value = -10
8869
- scaled_with_gain_modifier = no
5267
+ else_if = {
5268
+ limit = { has_building = counting_house }
5269
+ add_base_production = 2
8870
5270
  }
8871
5271
  }
8872
5272
  }
8873
- complete_artwork_effect_textiles = {
8874
- custom_tooltip = DUE_TO_ART_QUALITY_FOLLOWING_EFFECT_HAPPENS_TT
8875
- if = {
8876
- limit = { check_variable = { which = art_quality value = 4 } }
8877
- add_government_power = {
8878
- mechanic_type = persian_influence_mechanic
8879
- power_type = persian_influence
8880
- value = 25
5273
+ upgrade_dock_building = {
5274
+ custom_tooltip = upgrade_dock_building_tt
5275
+ hidden_effect = {
5276
+ if = {
5277
+ limit = { has_building = dock }
5278
+ add_building = drydock
8881
5279
  }
8882
- add_mercantilism_or_monarch_power = {
8883
- amount = 3
5280
+ else_if = {
5281
+ limit = { has_building = drydock }
5282
+ ROOT = { add_sailors = 500 }
8884
5283
  }
8885
5284
  }
8886
- else_if = {
8887
- limit = { check_variable = { which = art_quality value = 3 } }
8888
- add_government_power = {
8889
- mechanic_type = persian_influence_mechanic
8890
- power_type = persian_influence
8891
- value = 20
5285
+ }
5286
+ upgrade_shipyard_building = {
5287
+ custom_tooltip = upgrade_shipyard_building_tt
5288
+ hidden_effect = {
5289
+ if = {
5290
+ limit = { has_building = shipyard }
5291
+ add_building = grand_shipyard
8892
5292
  }
8893
- add_mercantilism_or_monarch_power = {
8894
- amount = 2
5293
+ else_if = {
5294
+ limit = { has_building = grand_shipyard }
5295
+ ROOT = { add_sailors = 500 }
8895
5296
  }
8896
5297
  }
8897
- else_if = {
8898
- limit = { check_variable = { which = art_quality value = 2 } }
8899
- add_government_power = {
8900
- mechanic_type = persian_influence_mechanic
8901
- power_type = persian_influence
8902
- value = 15
5298
+ }
5299
+ upgrade_manpower_building = {
5300
+ custom_tooltip = upgrade_manpower_building_tt
5301
+ hidden_effect = {
5302
+ if = {
5303
+ limit = { has_building = barracks }
5304
+ add_building = training_fields
8903
5305
  }
8904
- add_mercantilism_or_monarch_power = {
8905
- amount = 1
5306
+ else_if = {
5307
+ limit = { has_building = training_fields }
5308
+ add_base_tax = 1
5309
+ add_base_manpower = 1
8906
5310
  }
8907
5311
  }
8908
- else_if = {
8909
- limit = { check_variable = { which = art_quality value = 1 } }
8910
- add_government_power = {
8911
- mechanic_type = persian_influence_mechanic
8912
- power_type = persian_influence
8913
- value = 10
5312
+ }
5313
+ upgrade_forcelimit_building = {
5314
+ custom_tooltip = upgrade_forcelimit_building_tt
5315
+ hidden_effect = {
5316
+ if = {
5317
+ limit = { has_building = regimental_camp }
5318
+ add_building = conscription_center
8914
5319
  }
8915
- }
8916
- else = {
8917
- add_prestige = -20
8918
- add_government_power = {
8919
- mechanic_type = persian_influence_mechanic
8920
- power_type = persian_influence
8921
- value = -10
8922
- scaled_with_gain_modifier = no
5320
+ else_if = {
5321
+ limit = { has_building = conscription_center }
5322
+ add_base_manpower = 2
8923
5323
  }
8924
5324
  }
8925
5325
  }
8926
- complete_artwork_effect_painting = {
8927
- custom_tooltip = DUE_TO_ART_QUALITY_FOLLOWING_EFFECT_HAPPENS_TT
8928
- if = {
8929
- limit = { check_variable = { which = art_quality value = 4 } }
8930
- add_government_power = {
8931
- mechanic_type = persian_influence_mechanic
8932
- power_type = persian_influence
8933
- value = 25
5326
+ upgrade_courthouse_building = {
5327
+ custom_tooltip = upgrade_courthouse_building_tt
5328
+ hidden_effect = {
5329
+ if = {
5330
+ limit = { has_building = courthouse }
5331
+ add_building = town_hall
8934
5332
  }
8935
- add_prestige_or_monarch_power = { amount = 30 }
8936
- }
8937
- else_if = {
8938
- limit = { check_variable = { which = art_quality value = 3 } }
8939
- add_government_power = {
8940
- mechanic_type = persian_influence_mechanic
8941
- power_type = persian_influence
8942
- value = 20
5333
+ else_if = {
5334
+ limit = { has_building = town_hall }
5335
+ add_base_tax = 1
5336
+ add_base_production = 1
5337
+ add_base_manpower = 1
8943
5338
  }
8944
- add_prestige_or_monarch_power = { amount = 20 }
8945
5339
  }
8946
- else_if = {
8947
- limit = { check_variable = { which = art_quality value = 2 } }
8948
- add_government_power = {
8949
- mechanic_type = persian_influence_mechanic
8950
- power_type = persian_influence
8951
- value = 15
5340
+ }
5341
+ upgrade_fort_building = {
5342
+ custom_tooltip = upgrade_fort_building_tt
5343
+ hidden_effect = {
5344
+ if = {
5345
+ limit = { has_building = fort_15th }
5346
+ add_building = fort_16th
8952
5347
  }
8953
- add_prestige_or_monarch_power = { amount = 10 }
8954
- }
8955
- else_if = {
8956
- limit = { check_variable = { which = art_quality value = 1 } }
8957
- add_government_power = {
8958
- mechanic_type = persian_influence_mechanic
8959
- power_type = persian_influence
8960
- value = 10
5348
+ else_if = {
5349
+ limit = { has_building = fort_16th }
5350
+ add_building = fort_17th
8961
5351
  }
8962
- }
8963
- else = {
8964
- add_prestige = -20
8965
- add_government_power = {
8966
- mechanic_type = persian_influence_mechanic
8967
- power_type = persian_influence
8968
- value = -10
8969
- scaled_with_gain_modifier = no
5352
+ else_if = {
5353
+ limit = { has_building = fort_17th }
5354
+ add_building = fort_18th
8970
5355
  }
8971
- }
8972
- }
8973
- complete_artwork_effect = {
8974
- remove_country_modifier = promoting_$type$
8975
- complete_artwork_effect_$type$ = yes
8976
- if = {
8977
- limit = { has_country_modifier = promoting_art }
8978
- country_event = {
8979
- id = promoting_art_events.1
5356
+ else_if = {
5357
+ limit = { has_building = fort_18th }
5358
+ add_base_manpower = 3
8980
5359
  }
8981
5360
  }
5361
+ }
5362
+ upgrade_naval_defense_building = {
5363
+ custom_tooltip = upgrade_naval_defense_building_tt
8982
5364
  hidden_effect = {
8983
- set_variable = {
8984
- which = art_progress
8985
- value = 0
5365
+ if = {
5366
+ limit = { has_building = coastal_defence }
5367
+ add_building = naval_battery
8986
5368
  }
8987
- set_variable = {
8988
- which = art_quality
8989
- value = 1
5369
+ else_if = {
5370
+ limit = { has_building = naval_battery }
5371
+ add_base_production = 2
8990
5372
  }
8991
5373
  }
8992
5374
  }
8993
- change_art_progress = {
8994
- change_variable = {
8995
- which = art_progress
8996
- value = $amount$
8997
- }
8998
- }
8999
- change_art_quality = {
9000
- change_variable = {
9001
- which = art_quality
9002
- value = $amount$
5375
+
5376
+
5377
+ #####################
5378
+ # USAGE
5379
+ # pick_best_tags = {
5380
+ # global_trigger = "your global triggers here" OPTIONAL
5381
+ # <example>
5382
+ # global_trigger = "
5383
+ # OR = {
5384
+ # continent = europe
5385
+ # allied_with = ROOT
5386
+ # }"
5387
+ # scale = your trigger type here REQUIRED
5388
+ # <example>
5389
+ # scale = army_size
5390
+ # <number of tags here> = yes (supported numbers: 1-3) REQUIRED
5391
+ # event_target_name = "your name for event target here> REQUIRED
5392
+ # scope = "your scope here> OPTIONAL
5393
+ # <example>
5394
+ # scope = "every_neighbor_country"
5395
+ # default is every_country
5396
+ # }
5397
+ #####################
5398
+
5399
+ pick_best_tags = {
5400
+ [[scope]
5401
+ pick_best_tags_2 = {
5402
+ scope = $scope$
5403
+ scale = $scale$
5404
+ event_target_name = $event_target_name$
5405
+ global_trigger = "$global_trigger$"
5406
+ 1 = "$1$"
5407
+ 2 = "$2$"
5408
+ 3 = "$3$"
5409
+ 4 = "$4$"
5410
+ 5 = "$5$"
5411
+ 10 = "$10$"
5412
+ }
5413
+ set_global_flag = PICK_BEST_TAG_FLAG
5414
+ ] #curses for not having an [ELSE ] or something.
5415
+ if = {
5416
+ limit = {
5417
+ NOT = { has_global_flag = PICK_BEST_TAG_FLAG } #This check is here to prevent the algorithm from being run again after the scoped version was executed
5418
+ }
5419
+ pick_best_tags_2 = {
5420
+ scope = every_country
5421
+ scale = $scale$
5422
+ event_target_name = $event_target_name$
5423
+ global_trigger = "$global_trigger$"
5424
+ 1 = "$1$"
5425
+ 2 = "$2$"
5426
+ 3 = "$3$"
5427
+ 4 = "$4$"
5428
+ 5 = "$5$"
5429
+ 10 = "$10$"
5430
+ }
9003
5431
  }
5432
+ else = { clr_global_flag = PICK_BEST_TAG_FLAG }
9004
5433
  }
9005
5434
 
9006
- used_persian_influence_mechanic = {
9007
- custom_tooltip = used_persian_influence_mechanic_tt
5435
+ pick_best_tags_2 = {
9008
5436
  hidden_effect = {
9009
- if = {
9010
- limit = { NOT = { has_country_flag = persian_influence_setup_flag } }
9011
- set_country_flag = persian_influence_setup_flag
9012
- }
9013
- remove_country_modifier = used_persian_influece_interaction_1
9014
- remove_country_modifier = used_persian_influece_interaction_2
9015
- remove_country_modifier = used_persian_influece_interaction_3
9016
- remove_country_modifier = used_persian_influece_interaction_4
9017
- remove_country_modifier = used_persian_influece_interaction_5
9018
- remove_country_modifier = used_persian_influece_interaction_6
9019
- remove_country_modifier = used_persian_influece_interaction_7
9020
- remove_country_modifier = used_persian_influece_interaction_8
9021
- remove_country_modifier = used_persian_influece_interaction_9
9022
- remove_country_modifier = used_persian_influece_interaction_10
9023
- remove_country_modifier = used_persian_influece_interaction_11
9024
- remove_country_modifier = used_persian_influece_interaction_12
9025
- remove_country_modifier = used_persian_influece_interaction_13
9026
- remove_country_modifier = used_persian_influece_interaction_14
9027
- remove_country_modifier = used_persian_influece_interaction_15
9028
- remove_country_modifier = used_persian_influece_interaction_16
9029
- remove_country_modifier = used_persian_influece_interaction_17
9030
- remove_country_modifier = used_persian_influece_interaction_18
9031
- remove_country_modifier = used_persian_influece_interaction_19
9032
- remove_country_modifier = used_persian_influece_interaction_20
9033
- change_variable = {
9034
- which = persian_influece_counter
9035
- value = 1
9036
- }
9037
- if = {
9038
- limit = { has_country_flag = improved_elevation_reduction }
5437
+ [[1]
9039
5438
  if = {
9040
- limit = { check_variable = { which = persian_influece_counter_tooltip value = -400 } }
9041
- change_variable = {
9042
- which = persian_influece_counter_tooltip
9043
- value = -20
5439
+ limit = { always = $1$ }
5440
+ pick_best_tag = {
5441
+ scale = "$scale$"
5442
+ scope = $scope$
5443
+ global_trigger = "$global_trigger$"
5444
+ event_target_name = "$event_target_name$"
5445
+ number = 1
9044
5446
  }
9045
5447
  }
9046
- }
9047
- else = {
5448
+ ]
5449
+ [[2]
9048
5450
  if = {
9049
- limit = { check_variable = { which = persian_influece_counter_tooltip value = -200 } }
9050
- change_variable = {
9051
- which = persian_influece_counter_tooltip
9052
- value = -20
5451
+ limit = { always = $2$ }
5452
+ pick_best_tag = {
5453
+ scale = "$scale$"
5454
+ scope = $scope$
5455
+ global_trigger = "$global_trigger$"
5456
+ event_target_name = "$event_target_name$"
5457
+ number = 1
5458
+ }
5459
+ pick_best_tag = {
5460
+ scale = "$scale$"
5461
+ scope = $scope$
5462
+ global_trigger = "$global_trigger$"
5463
+ event_target_name = "$event_target_name$"
5464
+ number = 2
9053
5465
  }
9054
5466
  }
9055
- }
9056
- change_variable = {
9057
- which = persian_influence_interaction_counter
9058
- value = 1
9059
- }
9060
- if = {
9061
- limit = { has_country_flag = improved_elevation_reduction }
5467
+ ]
5468
+ [[3]
9062
5469
  if = {
9063
- limit = { check_variable = { which = persian_influece_counter value = 10 } }
9064
- if = {
9065
- limit = { check_variable = { which = persian_influece_counter value = 15 } }
9066
- if = {
9067
- limit = { check_variable = { which = persian_influece_counter value = 17 } }
9068
- if = {
9069
- limit = { check_variable = { which = persian_influece_counter value = 19 } }
9070
- if = {
9071
- limit = { check_variable = { which = persian_influece_counter value = 20 } }
9072
- add_country_modifier = { name = used_persian_influece_interaction_20 duration = -1 hidden = yes }
9073
- }
9074
- else = {
9075
- add_country_modifier = { name = used_persian_influece_interaction_19 duration = -1 hidden = yes }
9076
- }
9077
- }
9078
- else = {
9079
- if = {
9080
- limit = { check_variable = { which = persian_influece_counter value = 18 } }
9081
- add_country_modifier = { name = used_persian_influece_interaction_18 duration = -1 hidden = yes }
9082
- }
9083
- else = {
9084
- add_country_modifier = { name = used_persian_influece_interaction_17 duration = -1 hidden = yes }
9085
- }
9086
- }
9087
- }
9088
- else = {
9089
- if = {
9090
- limit = { check_variable = { which = persian_influece_counter value = 16 } }
9091
- add_country_modifier = { name = used_persian_influece_interaction_16 duration = -1 hidden = yes }
9092
- }
9093
- else = {
9094
- add_country_modifier = { name = used_persian_influece_interaction_15 duration = -1 hidden = yes }
9095
- }
9096
- }
9097
- }
9098
- else = {
9099
- if = {
9100
- limit = { check_variable = { which = persian_influece_counter value = 13 } }
9101
- if = {
9102
- limit = { check_variable = { which = persian_influece_counter value = 14 } }
9103
- add_country_modifier = { name = used_persian_influece_interaction_14 duration = -1 hidden = yes }
9104
- }
9105
- else = {
9106
- add_country_modifier = { name = used_persian_influece_interaction_13 duration = -1 hidden = yes }
9107
- }
9108
- }
9109
- else = {
9110
- if = {
9111
- limit = { check_variable = { which = persian_influece_counter value = 11 } }
9112
- if = {
9113
- limit = { check_variable = { which = persian_influece_counter value = 12 } }
9114
- add_country_modifier = { name = used_persian_influece_interaction_12 duration = -1 hidden = yes }
9115
- }
9116
- else = {
9117
- add_country_modifier = { name = used_persian_influece_interaction_11 duration = -1 hidden = yes }
9118
- }
9119
- }
9120
- else = {
9121
- add_country_modifier = { name = used_persian_influece_interaction_10 duration = -1 hidden = yes }
9122
- }
9123
- }
5470
+ limit = { always = $3$ }
5471
+ pick_best_tag = {
5472
+ scale = "$scale$"
5473
+ scope = $scope$
5474
+ global_trigger = "$global_trigger$"
5475
+ event_target_name = "$event_target_name$"
5476
+ number = 1
5477
+ }
5478
+ pick_best_tag = {
5479
+ scale = "$scale$"
5480
+ scope = $scope$
5481
+ global_trigger = "$global_trigger$"
5482
+ event_target_name = "$event_target_name$"
5483
+ number = 2
5484
+ }
5485
+ pick_best_tag = {
5486
+ scale = "$scale$"
5487
+ scope = $scope$
5488
+ global_trigger = "$global_trigger$"
5489
+ event_target_name = "$event_target_name$"
5490
+ number = 3
9124
5491
  }
9125
5492
  }
9126
- else = {
9127
- if = {
9128
- limit = { check_variable = { which = persian_influece_counter value = 5 } }
9129
- if = {
9130
- limit = { check_variable = { which = persian_influece_counter value = 8 } }
9131
- if = {
9132
- limit = { check_variable = { which = persian_influece_counter value = 9 } }
9133
- add_country_modifier = { name = used_persian_influece_interaction_9 duration = -1 hidden = yes }
9134
- }
9135
- else = {
9136
- add_country_modifier = { name = used_persian_influece_interaction_8 duration = -1 hidden = yes }
9137
- }
9138
- }
9139
- else = {
9140
- if = {
9141
- limit = { check_variable = { which = persian_influece_counter value = 6 } }
9142
- if = {
9143
- limit = { check_variable = { which = persian_influece_counter value = 7 } }
9144
- add_country_modifier = { name = used_persian_influece_interaction_7 duration = -1 hidden = yes }
9145
- }
9146
- else = {
9147
- add_country_modifier = { name = used_persian_influece_interaction_6 duration = -1 hidden = yes }
9148
- }
9149
- }
9150
- else = {
9151
- add_country_modifier = { name = used_persian_influece_interaction_5 duration = -1 hidden = yes }
9152
- }
9153
- }
9154
- }
9155
- else = {
9156
- if = {
9157
- limit = { check_variable = { which = persian_influece_counter value = 3 } }
9158
- if = {
9159
- limit = { check_variable = { which = persian_influece_counter value = 4 } }
9160
- add_country_modifier = { name = used_persian_influece_interaction_4 duration = -1 hidden = yes }
9161
- }
9162
- add_country_modifier = { name = used_persian_influece_interaction_3 duration = -1 hidden = yes }
9163
- }
9164
- else = {
9165
- if = {
9166
- limit = { check_variable = { which = persian_influece_counter value = 2 } }
9167
- add_country_modifier = { name = used_persian_influece_interaction_2 duration = -1 hidden = yes }
9168
- }
9169
- else = {
9170
- add_country_modifier = { name = used_persian_influece_interaction_1 duration = -1 hidden = yes }
9171
- }
9172
- }
5493
+ ]
5494
+ [[4]
5495
+ if = {
5496
+ limit = { always = $4$ }
5497
+ pick_best_tag = {
5498
+ scale = "$scale$"
5499
+ scope = $scope$
5500
+ global_trigger = "$global_trigger$"
5501
+ event_target_name = "$event_target_name$"
5502
+ number = 1
5503
+ }
5504
+ pick_best_tag = {
5505
+ scale = "$scale$"
5506
+ scope = $scope$
5507
+ global_trigger = "$global_trigger$"
5508
+ event_target_name = "$event_target_name$"
5509
+ number = 2
5510
+ }
5511
+ pick_best_tag = {
5512
+ scale = "$scale$"
5513
+ scope = $scope$
5514
+ global_trigger = "$global_trigger$"
5515
+ event_target_name = "$event_target_name$"
5516
+ number = 3
5517
+ }
5518
+ pick_best_tag = {
5519
+ scale = "$scale$"
5520
+ scope = $scope$
5521
+ global_trigger = "$global_trigger$"
5522
+ event_target_name = "$event_target_name$"
5523
+ number = 4
9173
5524
  }
9174
5525
  }
9175
- }
9176
- else = {
5526
+ ]
5527
+ [[5]
9177
5528
  if = {
9178
- limit = { check_variable = { which = persian_influece_counter value = 5 } }
9179
- if = {
9180
- limit = { check_variable = { which = persian_influece_counter value = 7 } }
9181
- if = {
9182
- limit = { check_variable = { which = persian_influece_counter value = 9 } }
9183
- if = {
9184
- limit = { check_variable = { which = persian_influece_counter value = 10 } }
9185
- add_country_modifier = { name = used_persian_influece_interaction_10 duration = -1 hidden = yes }
9186
- }
9187
- else = {
9188
- add_country_modifier = { name = used_persian_influece_interaction_9 duration = -1 hidden = yes }
9189
- }
9190
- }
9191
- else = {
9192
- if = {
9193
- limit = { check_variable = { which = persian_influece_counter value = 8 } }
9194
- add_country_modifier = { name = used_persian_influece_interaction_8 duration = -1 hidden = yes }
9195
- }
9196
- else = {
9197
- add_country_modifier = { name = used_persian_influece_interaction_7 duration = -1 hidden = yes }
9198
- }
9199
- }
9200
- }
9201
- else = {
9202
- if = {
9203
- limit = { check_variable = { which = persian_influece_counter value = 6 } }
9204
- add_country_modifier = { name = used_persian_influece_interaction_6 duration = -1 hidden = yes }
9205
- }
9206
- else = {
9207
- add_country_modifier = { name = used_persian_influece_interaction_5 duration = -1 hidden = yes }
9208
- }
5529
+ limit = { always = $5$ }
5530
+ pick_best_tag = {
5531
+ scale = "$scale$"
5532
+ scope = $scope$
5533
+ global_trigger = "$global_trigger$"
5534
+ event_target_name = "$event_target_name$"
5535
+ number = 1
5536
+ }
5537
+ pick_best_tag = {
5538
+ scale = "$scale$"
5539
+ scope = $scope$
5540
+ global_trigger = "$global_trigger$"
5541
+ event_target_name = "$event_target_name$"
5542
+ number = 2
5543
+ }
5544
+ pick_best_tag = {
5545
+ scale = "$scale$"
5546
+ scope = $scope$
5547
+ global_trigger = "$global_trigger$"
5548
+ event_target_name = "$event_target_name$"
5549
+ number = 3
5550
+ }
5551
+ pick_best_tag = {
5552
+ scale = "$scale$"
5553
+ scope = $scope$
5554
+ global_trigger = "$global_trigger$"
5555
+ event_target_name = "$event_target_name$"
5556
+ number = 4
5557
+ }
5558
+ pick_best_tag = {
5559
+ scale = "$scale$"
5560
+ scope = $scope$
5561
+ global_trigger = "$global_trigger$"
5562
+ event_target_name = "$event_target_name$"
5563
+ number = 5
9209
5564
  }
9210
5565
  }
9211
- else = {
9212
- if = {
9213
- limit = { check_variable = { which = persian_influece_counter value = 3 } }
9214
- if = {
9215
- limit = { check_variable = { which = persian_influece_counter value = 4 } }
9216
- add_country_modifier = { name = used_persian_influece_interaction_4 duration = -1 hidden = yes }
9217
- }
9218
- add_country_modifier = { name = used_persian_influece_interaction_3 duration = -1 hidden = yes }
5566
+ ]
5567
+ [[10]
5568
+ if = {
5569
+ limit = { always = $10$ }
5570
+ pick_best_tag = {
5571
+ scale = "$scale$"
5572
+ scope = $scope$
5573
+ global_trigger = "$global_trigger$"
5574
+ event_target_name = "$event_target_name$"
5575
+ number = 1
5576
+ }
5577
+ pick_best_tag = {
5578
+ scale = "$scale$"
5579
+ scope = $scope$
5580
+ global_trigger = "$global_trigger$"
5581
+ event_target_name = "$event_target_name$"
5582
+ number = 2
5583
+ }
5584
+ pick_best_tag = {
5585
+ scale = "$scale$"
5586
+ scope = $scope$
5587
+ global_trigger = "$global_trigger$"
5588
+ event_target_name = "$event_target_name$"
5589
+ number = 3
5590
+ }
5591
+ pick_best_tag = {
5592
+ scale = "$scale$"
5593
+ scope = $scope$
5594
+ global_trigger = "$global_trigger$"
5595
+ event_target_name = "$event_target_name$"
5596
+ number = 4
5597
+ }
5598
+ pick_best_tag = {
5599
+ scale = "$scale$"
5600
+ scope = $scope$
5601
+ global_trigger = "$global_trigger$"
5602
+ event_target_name = "$event_target_name$"
5603
+ number = 5
5604
+ }
5605
+ pick_best_tag = {
5606
+ scale = "$scale$"
5607
+ scope = $scope$
5608
+ global_trigger = "$global_trigger$"
5609
+ event_target_name = "$event_target_name$"
5610
+ number = 6
5611
+ }
5612
+ pick_best_tag = {
5613
+ scale = "$scale$"
5614
+ scope = $scope$
5615
+ global_trigger = "$global_trigger$"
5616
+ event_target_name = "$event_target_name$"
5617
+ number = 7
5618
+ }
5619
+ pick_best_tag = {
5620
+ scale = "$scale$"
5621
+ scope = $scope$
5622
+ global_trigger = "$global_trigger$"
5623
+ event_target_name = "$event_target_name$"
5624
+ number = 8
5625
+ }
5626
+ pick_best_tag = {
5627
+ scale = "$scale$"
5628
+ scope = $scope$
5629
+ global_trigger = "$global_trigger$"
5630
+ event_target_name = "$event_target_name$"
5631
+ number = 9
5632
+ }
5633
+ pick_best_tag = {
5634
+ scale = "$scale$"
5635
+ scope = $scope$
5636
+ global_trigger = "$global_trigger$"
5637
+ event_target_name = "$event_target_name$"
5638
+ number = 10
9219
5639
  }
9220
- else = {
9221
- if = {
9222
- limit = { check_variable = { which = persian_influece_counter value = 2 } }
9223
- add_country_modifier = { name = used_persian_influece_interaction_2 duration = -1 hidden = yes }
9224
- }
9225
- else = {
9226
- add_country_modifier = { name = used_persian_influece_interaction_1 duration = -1 hidden = yes }
5640
+ }
5641
+ ]
5642
+ $scope$ = {
5643
+ limit = {
5644
+ has_country_flag = $event_target_name$_exclude
5645
+ }
5646
+ clr_country_flag = $event_target_name$_exclude
5647
+ }
5648
+ }
5649
+ }
5650
+
5651
+ pick_best_tag = {
5652
+ 1 = { save_event_target_as = $event_target_name$_$number$ }
5653
+ $scope$ = {
5654
+ limit = {
5655
+ [[global_trigger] $global_trigger$ ]
5656
+ $scale$ = event_target:$event_target_name$_$number$
5657
+ NOT = { has_country_flag = $event_target_name$_exclude }
5658
+ }
5659
+ save_event_target_as = $event_target_name$_$number$
5660
+ }
5661
+ event_target:$event_target_name$_$number$ = {
5662
+ set_country_flag = $event_target_name$_exclude
5663
+ }
5664
+ }
5665
+
5666
+ # distribute_development = {
5667
+ # type = x //The 3 development types. E.G. type = production
5668
+ # amount = x //How many development to add. E.G amount = 10
5669
+ # limit = " " OPTIONAL //takes actual triggers. E.G. limit = " NOT = { culture = ROOT } "
5670
+ #}
5671
+ distribute_development = {
5672
+ hidden_effect = {
5673
+ set_variable = {
5674
+ which = $type$_loop
5675
+ value = 0
5676
+ }
5677
+ while = {
5678
+ limit = {
5679
+ NOT = {
5680
+ check_variable = {
5681
+ which = $type$_loop
5682
+ value = $amount$
9227
5683
  }
9228
5684
  }
9229
5685
  }
5686
+ random_owned_province = {
5687
+ [[limit]
5688
+ limit = {
5689
+ $limit$
5690
+ }
5691
+ ]
5692
+ add_base_$type$ = 1
5693
+ }
5694
+ change_variable = {
5695
+ which = $type$_loop
5696
+ value = 1
5697
+ }
5698
+ }
5699
+ }
5700
+ custom_tooltip = $type$_$amount$
5701
+ custom_tooltip = " "
5702
+ [[tooltip]
5703
+ custom_tooltip = $tooltip$
5704
+ custom_tooltip = " "
5705
+ ]
5706
+ }
5707
+
5708
+ # This file contains all effects which are are needed for dynamic effects, but have more than 512 characters in total.
5709
+ # It also has the dynamic effect itself too.
5710
+ #Use insight_tooltip = INSIGHT_JUST_TOOLTIP if you don't want to have anything specific
5711
+ country_event_with_insight = {
5712
+ country_event = {
5713
+ id = $id$
5714
+ [[days] days = $days$]
5715
+ [[random] random = $random$]
5716
+ [[tooltip] tooltip = $tooltip$]
5717
+ }
5718
+ custom_tooltip = EVENT_INSIGHT_INTRO
5719
+ custom_tooltip = $insight_tooltip$
5720
+ [[effect_tooltip] tooltip = { $effect_tooltip$ }]
5721
+ }
5722
+
5723
+ # "Simple" as in "Do not put too many characters in the input argument or else it will not work"
5724
+ # This serves as both an useful effect for small dynamic mission rewards
5725
+ # And as a reminder how the template for the dynamic mission rewards should look like
5726
+
5727
+ # Use this if you want the rewards / triggers to be exclusive
5728
+ # This means if a AND b are fulfilled then the player gets only reward from a
5729
+ # IMPORTANT: They do NOT fire events for some reason.
5730
+ simple_dynamic_effect = {
5731
+ custom_tooltip = $first_custom_tooltip$
5732
+ if = {
5733
+ limit = {
5734
+ $first_limit$
5735
+ }
5736
+ custom_tooltip = BONUS_REWARD_YES
5737
+ }
5738
+ else = { custom_tooltip = BONUS_REWARD_NO }
5739
+ tooltip = {
5740
+ $first_effect$
5741
+ }
5742
+ custom_tooltip = mission_alternatively_tt
5743
+ [[second_custom_tooltip] custom_tooltip = $second_custom_tooltip$ ]
5744
+ if = {
5745
+ limit = {
5746
+ $second_limit$
9230
5747
  }
5748
+ custom_tooltip = BONUS_REWARD_YES
5749
+ }
5750
+ else = { custom_tooltip = BONUS_REWARD_NO }
5751
+ tooltip = {
5752
+ $second_effect$
9231
5753
  }
9232
- }
9233
-
9234
- improve_elevation_effect = {
9235
- custom_tooltip = improve_elevation_effect_tt
9236
5754
  hidden_effect = {
9237
- set_country_flag = improved_elevation_effect
5755
+ if = {
5756
+ limit = { $first_limit$ }
5757
+ $first_effect$
5758
+ }
5759
+ else = {
5760
+ $second_effect$
5761
+ }
9238
5762
  }
9239
5763
  }
9240
5764
 
9241
- improve_elevation_reduction = {
9242
- custom_tooltip = improve_elevation_reduction_tt
5765
+ # Use this if you want the rewards / triggers to be additive
5766
+ # This means if a AND b are fulfilled then the player gets both
5767
+ simple_dynamic_effect_without_alternative = {
5768
+ custom_tooltip = $first_custom_tooltip$
5769
+ if = {
5770
+ limit = {
5771
+ $first_limit$
5772
+ }
5773
+ custom_tooltip = BONUS_REWARD_YES
5774
+ }
5775
+ else = { custom_tooltip = BONUS_REWARD_NO }
5776
+ tooltip = {
5777
+ $first_effect$
5778
+ }
5779
+ [[second_custom_tooltip] custom_tooltip = $second_custom_tooltip$ ]
5780
+ if = {
5781
+ limit = {
5782
+ $second_limit$
5783
+ }
5784
+ custom_tooltip = BONUS_REWARD_YES
5785
+ }
5786
+ else = { custom_tooltip = BONUS_REWARD_NO }
5787
+ tooltip = {
5788
+ $second_effect$
5789
+ }
9243
5790
  hidden_effect = {
9244
- set_country_flag = improved_elevation_reduction
5791
+ if = {
5792
+ limit = { $first_limit$ }
5793
+ $first_effect$
5794
+ }
5795
+ if = {
5796
+ limit = { $second_limit$ }
5797
+ $second_effect$
5798
+ }
9245
5799
  }
9246
5800
  }
9247
5801
 
9248
- improve_persian_influence_abilities = {
9249
- custom_tooltip = improve_persian_influence_abilities_tt
9250
- hidden_effect = {
9251
- set_country_flag = improved_persian_influence_abilities
5802
+ # "Complex" as in "if you need this effect then you should rethink your mission reward"
5803
+ # Supports up to 10 dynamic effects
5804
+ # Will probably result in a grocery list when you hover over the effects though
5805
+ complex_dynamic_effect = {
5806
+ custom_tooltip = $first_custom_tooltip$
5807
+ if = {
5808
+ limit = {
5809
+ $first_limit$
5810
+ }
5811
+ custom_tooltip = BONUS_REWARD_YES
5812
+ }
5813
+ else = { custom_tooltip = BONUS_REWARD_NO }
5814
+ tooltip = {
5815
+ $first_effect$
9252
5816
  }
9253
- }
9254
5817
 
9255
- improve_fabricate_religious_conflict = {
9256
- custom_tooltip = improve_fabricate_religious_conflict_tt
9257
- hidden_effect = {
9258
- set_country_flag = reduced_spread_faith_cb_spy_cost
9259
- }
9260
- }
9261
-
9262
- consume_persian_influence_reduction = {
9263
- remove_country_modifier = used_persian_influece_interaction_1
9264
- remove_country_modifier = used_persian_influece_interaction_2
9265
- remove_country_modifier = used_persian_influece_interaction_3
9266
- remove_country_modifier = used_persian_influece_interaction_4
9267
- remove_country_modifier = used_persian_influece_interaction_5
9268
- remove_country_modifier = used_persian_influece_interaction_6
9269
- remove_country_modifier = used_persian_influece_interaction_7
9270
- remove_country_modifier = used_persian_influece_interaction_8
9271
- remove_country_modifier = used_persian_influece_interaction_9
9272
- remove_country_modifier = used_persian_influece_interaction_10
9273
- remove_country_modifier = used_persian_influece_interaction_11
9274
- remove_country_modifier = used_persian_influece_interaction_12
9275
- remove_country_modifier = used_persian_influece_interaction_13
9276
- remove_country_modifier = used_persian_influece_interaction_14
9277
- remove_country_modifier = used_persian_influece_interaction_15
9278
- remove_country_modifier = used_persian_influece_interaction_16
9279
- remove_country_modifier = used_persian_influece_interaction_17
9280
- remove_country_modifier = used_persian_influece_interaction_18
9281
- remove_country_modifier = used_persian_influece_interaction_19
9282
- remove_country_modifier = used_persian_influece_interaction_20
9283
- change_variable = {
9284
- which = persian_influece_counter
9285
- value = 0
9286
- }
9287
- change_variable = {
9288
- which = persian_influece_counter_tooltip
9289
- value = 0
9290
- }
9291
- }
9292
-
9293
- #Check with "has_unlocked_decision = { type = <decisions id> }"
9294
- #Supports the following decisions
9295
- #################################
9296
- # grand_vizier_selection
9297
- # horse_breeding_decision
9298
- unlock_decision = {
9299
- custom_tooltip = unlock_decision_$type$_tt
9300
- hidden_effect = { set_country_flag = unlocked_decision_$type$ }
9301
- [[effect_tooltip]
9302
- custom_tooltip = unlock_decision_effect_tt
9303
- $effect_tooltip$
5818
+ [[second_custom_tooltip]
5819
+ custom_tooltip = mission_alternatively_tt
5820
+ custom_tooltip = $second_custom_tooltip$
5821
+ if = {
5822
+ limit = {
5823
+ $second_limit$
5824
+ }
5825
+ custom_tooltip = BONUS_REWARD_YES
5826
+ }
5827
+ else = { custom_tooltip = BONUS_REWARD_NO }
5828
+ tooltip = {
5829
+ $second_effect$
5830
+ }
9304
5831
  ]
9305
- [[custom_tooltip]custom_tooltip = $custom_tooltip$]
9306
- }
9307
- lock_decision = {
9308
- custom_tooltip = lock_decision_$type$_tt
9309
- hidden_effect = { clr_country_flag = unlocked_decision_$type$ }
9310
- }
9311
5832
 
9312
- #Supports the following holy orders
9313
- ###################################
9314
- # savafid_order
9315
- # zahediyeh_order
9316
- unlock_holy_order = {
5833
+ [[third_custom_tooltip]
5834
+ custom_tooltip = mission_alternatively_tt
5835
+ custom_tooltip = $third_custom_tooltip$
9317
5836
  if = {
9318
- limit = { has_dlc = "Golden Century" }
9319
- custom_tooltip = unlock_holy_order_$type$_tt
5837
+ limit = {
5838
+ $third_limit$
5839
+ }
5840
+ custom_tooltip = BONUS_REWARD_YES
9320
5841
  }
9321
- hidden_effect = { set_country_flag = unlocked_holy_order_$type$ }
9322
- }
5842
+ else = { custom_tooltip = BONUS_REWARD_NO }
5843
+ tooltip = {
5844
+ $third_effect$
5845
+ }
5846
+ ]
9323
5847
 
9324
- #Supports the following arguments
9325
- #################################
9326
- # fabricate_spread_the_true_faith_cb
9327
- unlock_diplomatic_action = {
9328
- custom_tooltip = unlock_$type$_tt
9329
- hidden_effect = {
9330
- set_country_flag = unlocked_diplomatic_action_$type$
5848
+ [[fourth_custom_tooltip]
5849
+ custom_tooltip = mission_alternatively_tt
5850
+ custom_tooltip = $fourth_custom_tooltip$
5851
+ if = {
5852
+ limit = {
5853
+ $fourth_limit$
5854
+ }
5855
+ custom_tooltip = BONUS_REWARD_YES
9331
5856
  }
9332
- [[custom_tooltip]custom_tooltip = $custom_tooltip$]
9333
- }
5857
+ else = { custom_tooltip = BONUS_REWARD_NO }
5858
+ tooltip = {
5859
+ $fourth_effect$
5860
+ }
5861
+ ]
9334
5862
 
9335
- enable_great_holy_war_cb = {
9336
- custom_tooltip = enable_great_holy_war_cb_tt
9337
- hidden_effect = { set_country_flag = enabled_great_holy_war_cb }
9338
- }
5863
+ [[fifth_custom_tooltip]
5864
+ custom_tooltip = mission_alternatively_tt
5865
+ custom_tooltip = $fifth_custom_tooltip$
5866
+ if = {
5867
+ limit = {
5868
+ $fifth_limit$
5869
+ }
5870
+ custom_tooltip = BONUS_REWARD_YES
5871
+ }
5872
+ else = { custom_tooltip = BONUS_REWARD_NO }
5873
+ tooltip = {
5874
+ $fifth_effect$
5875
+ }
5876
+ ]
9339
5877
 
9340
- change_asha_vahishta = {
5878
+ [[sixth_custom_tooltip]
5879
+ custom_tooltip = mission_alternatively_tt
5880
+ custom_tooltip = $sixth_custom_tooltip$
9341
5881
  if = {
9342
- limit = { has_government_mechanic = the_three_royal_fires_mechanic }
9343
- [[custom_tooltip]custom_tooltip = $custom_tooltip$]
9344
- add_government_power = {
9345
- mechanic_type = the_three_royal_fires_mechanic
9346
- power_type = asha_vahishta
9347
- value = $value$
5882
+ limit = {
5883
+ $sixth_limit$
9348
5884
  }
5885
+ custom_tooltip = BONUS_REWARD_YES
9349
5886
  }
9350
- }
5887
+ else = { custom_tooltip = BONUS_REWARD_NO }
5888
+ tooltip = {
5889
+ $sixth_effect$
5890
+ }
5891
+ ]
9351
5892
 
9352
- remove_asha_vahishta_loss_from_missionaries = {
9353
- custom_tooltip = remove_asha_vahishta_loss_from_missionaries_tt
9354
- hidden_effect = {
9355
- set_country_flag = removed_asha_vahishta_loss_from_missionaries
5893
+ [[seventh_custom_tooltip]
5894
+ custom_tooltip = mission_alternatively_tt
5895
+ custom_tooltip = $seventh_custom_tooltip$
5896
+ if = {
5897
+ limit = {
5898
+ $seventh_limit$
5899
+ }
5900
+ custom_tooltip = BONUS_REWARD_YES
9356
5901
  }
9357
- }
5902
+ else = { custom_tooltip = BONUS_REWARD_NO }
5903
+ tooltip = {
5904
+ $seventh_effect$
5905
+ }
5906
+ ]
9358
5907
 
9359
- upgrade_the_three_fire = {
9360
- custom_tooltip = upgrade_the_three_fire_tt
9361
- hidden_effect = {
9362
- set_country_flag = upgraded_the_three_fire
5908
+ [[eighth_custom_tooltip]
5909
+ custom_tooltip = mission_alternatively_tt
5910
+ custom_tooltip = $eighth_custom_tooltip$
5911
+ if = {
5912
+ limit = {
5913
+ $eighth_limit$
5914
+ }
5915
+ custom_tooltip = BONUS_REWARD_YES
9363
5916
  }
9364
- }
5917
+ else = { custom_tooltip = BONUS_REWARD_NO }
5918
+ tooltip = {
5919
+ $eighth_effect$
5920
+ }
5921
+ ]
9365
5922
 
9366
- remove_asha_vahishta_loss_from_force_conversion = {
9367
- custom_tooltip = remove_asha_vahishta_loss_from_force_conversion_tt
9368
- hidden_effect = {
9369
- set_country_flag = removed_asha_vahishta_loss_from_force_conversion
5923
+ [[nineth_custom_tooltip]
5924
+ custom_tooltip = mission_alternatively_tt
5925
+ custom_tooltip = $nineth_custom_tooltip$
5926
+ if = {
5927
+ limit = {
5928
+ $nineth_limit$
5929
+ }
5930
+ custom_tooltip = BONUS_REWARD_YES
9370
5931
  }
9371
- }
5932
+ else = { custom_tooltip = BONUS_REWARD_NO }
5933
+ tooltip = {
5934
+ $nineth_effect$
5935
+ }
5936
+ ]
9372
5937
 
9373
- enable_three_royal_fires_mana_generation = {
9374
- custom_tooltip = enable_three_royal_fires_mana_generation_tt
9375
- hidden_effect = {
9376
- set_country_flag = enabled_three_royal_fires_mana_generation
5938
+ [[tenth_custom_tooltip]
5939
+ custom_tooltip = mission_alternatively_tt
5940
+ custom_tooltip = $tenth_custom_tooltip$
5941
+ if = {
5942
+ limit = {
5943
+ $tenth_limit$
5944
+ }
5945
+ custom_tooltip = BONUS_REWARD_YES
9377
5946
  }
9378
- }
5947
+ else = { custom_tooltip = BONUS_REWARD_NO }
5948
+ tooltip = {
5949
+ $tenth_effect$
5950
+ }
5951
+ ]
9379
5952
 
9380
- # All is province scope here
9381
- ## add/upgrade trade building in province
9382
- ### add_or_upgrade_trade_building = yes # feel free to refactor to include the amount of upgrades
9383
- add_or_upgrade_trade_building = {
9384
- custom_tooltip = add_or_upgrade_trade_building_tt
9385
5953
  hidden_effect = {
9386
5954
  if = {
9387
- limit = { has_building = marketplace }
9388
- add_building = trade_depot
5955
+ limit = { $first_limit$ }
5956
+ $first_effect$
9389
5957
  }
5958
+ [[second_custom_tooltip]
9390
5959
  else_if = {
9391
- limit = { has_building = trade_depot }
9392
- add_building = stock_exchange
5960
+ limit = { $second_limit$ }
5961
+ $second_effect$
9393
5962
  }
5963
+ ]
5964
+ [[third_custom_tooltip]
9394
5965
  else_if = {
9395
- limit = { has_building = stock_exchange }
9396
- add_base_tax = 1
9397
- add_base_production = 1
5966
+ limit = { $third_limit$ }
5967
+ $third_effect$
9398
5968
  }
9399
- else = { add_building = marketplace }
9400
- }
9401
- }
9402
-
9403
- add_or_upgrade_tax_building = {
9404
- custom_tooltip = add_or_upgrade_tax_building_tt
9405
- hidden_effect = {
9406
- if = {
9407
- limit = { has_building = temple }
9408
- add_building = cathedral
5969
+ ]
5970
+ [[fourth_custom_tooltip]
5971
+ else_if = {
5972
+ limit = { $fourth_limit$ }
5973
+ $fourth_effect$
9409
5974
  }
5975
+ ]
5976
+ [[fifth_custom_tooltip]
9410
5977
  else_if = {
9411
- limit = { has_building = cathedral }
9412
- add_base_tax = 2
5978
+ limit = { $fifth_limit$ }
5979
+ $fifth_effect$
9413
5980
  }
9414
- else = { add_building = temple }
9415
- }
9416
- }
9417
-
9418
- add_or_upgrade_production_building = {
9419
- custom_tooltip = add_or_upgrade_production_building_tt
9420
- hidden_effect = {
9421
- if = {
9422
- limit = { has_building = workshop }
9423
- add_building = counting_house
5981
+ ]
5982
+ [[sixth_custom_tooltip]
5983
+ else_if = {
5984
+ limit = { $sixth_limit$ }
5985
+ $sixth_effect$
9424
5986
  }
5987
+ ]
5988
+ [[seventh_custom_tooltip]
9425
5989
  else_if = {
9426
- limit = { has_building = counting_house }
9427
- add_base_production = 2
5990
+ limit = { $seventh_limit$ }
5991
+ $seventh_effect$
9428
5992
  }
9429
- else = { add_building = workshop }
9430
- }
9431
- }
9432
-
9433
- add_or_upgrade_dock_building = {
9434
- custom_tooltip = add_or_upgrade_dock_building_tt
9435
- hidden_effect = {
9436
- if = {
9437
- limit = { has_building = dock }
9438
- add_building = drydock
5993
+ ]
5994
+ [[eigth_custom_tooltip]
5995
+ else_if = {
5996
+ limit = { $eigth_limit$ }
5997
+ $eigth_effect$
9439
5998
  }
5999
+ ]
6000
+ [[nineth_custom_tooltip]
9440
6001
  else_if = {
9441
- limit = { has_building = drydock }
9442
- ROOT = { add_sailors = 0.5 }
6002
+ limit = { $nineth_limit$ }
6003
+ $nineth_effect$
9443
6004
  }
9444
- else = { add_building = dock }
6005
+ ]
6006
+ [[tenth_custom_tooltip]
6007
+ else_if = {
6008
+ limit = { $tenth_limit$ }
6009
+ $tenth_effect$
6010
+ }
6011
+ ]
9445
6012
  }
9446
6013
  }
9447
6014
 
9448
- add_or_upgrade_shipyard_building = {
9449
- custom_tooltip = add_or_upgrade_shipyard_building_tt
9450
- hidden_effect = {
9451
- if = {
9452
- limit = { has_building = shipyard }
9453
- add_building = grand_shipyard
6015
+ # Use this if you want the rewards / triggers to be additive
6016
+ # This means if a AND b are fulfilled then the player gets both
6017
+ complex_dynamic_effect_without_alternative = {
6018
+ custom_tooltip = $first_custom_tooltip$
6019
+ if = {
6020
+ limit = {
6021
+ $first_limit$
9454
6022
  }
9455
- else_if = {
9456
- limit = { has_building = grand_shipyard }
9457
- ROOT = { add_sailors = 0.5 }
6023
+ custom_tooltip = BONUS_REWARD_YES
6024
+ }
6025
+ else = { custom_tooltip = BONUS_REWARD_NO }
6026
+ tooltip = {
6027
+ $first_effect$
6028
+ }
6029
+
6030
+ [[second_custom_tooltip]
6031
+ custom_tooltip = $second_custom_tooltip$
6032
+ if = {
6033
+ limit = {
6034
+ $second_limit$
9458
6035
  }
9459
- else = { add_building = shipyard }
6036
+ custom_tooltip = BONUS_REWARD_YES
9460
6037
  }
9461
- }
6038
+ else = { custom_tooltip = BONUS_REWARD_NO }
6039
+ tooltip = {
6040
+ $second_effect$
6041
+ }
6042
+ ]
9462
6043
 
9463
- add_or_upgrade_manpower_building = {
9464
- custom_tooltip = add_or_upgrade_manpower_building_tt
9465
- hidden_effect = {
9466
- if = {
9467
- limit = { has_building = barracks }
9468
- add_building = training_fields
6044
+ [[third_custom_tooltip]
6045
+ custom_tooltip = $third_custom_tooltip$
6046
+ if = {
6047
+ limit = {
6048
+ $third_limit$
9469
6049
  }
9470
- else_if = {
9471
- limit = { has_building = training_fields }
9472
- add_base_tax = 1
9473
- add_base_manpower = 1
6050
+ custom_tooltip = BONUS_REWARD_YES
6051
+ }
6052
+ else = { custom_tooltip = BONUS_REWARD_NO }
6053
+ tooltip = {
6054
+ $third_effect$
6055
+ }
6056
+ ]
6057
+
6058
+ [[fourth_custom_tooltip]
6059
+ custom_tooltip = $fourth_custom_tooltip$
6060
+ if = {
6061
+ limit = {
6062
+ $fourth_limit$
9474
6063
  }
9475
- else = { add_building = barracks }
6064
+ custom_tooltip = BONUS_REWARD_YES
9476
6065
  }
9477
- }
6066
+ else = { custom_tooltip = BONUS_REWARD_NO }
6067
+ tooltip = {
6068
+ $fourth_effect$
6069
+ }
6070
+ ]
9478
6071
 
9479
- add_or_upgrade_forcelimit_building = {
9480
- custom_tooltip = add_or_upgrade_forcelimit_building_tt
9481
- hidden_effect = {
9482
- if = {
9483
- limit = { has_building = regimental_camp }
9484
- add_building = conscription_center
6072
+ [[fifth_custom_tooltip]
6073
+ custom_tooltip = $fifth_custom_tooltip$
6074
+ if = {
6075
+ limit = {
6076
+ $fifth_limit$
9485
6077
  }
9486
- else_if = {
9487
- limit = { has_building = conscription_center }
9488
- add_base_manpower = 2
6078
+ custom_tooltip = BONUS_REWARD_YES
6079
+ }
6080
+ else = { custom_tooltip = BONUS_REWARD_NO }
6081
+ tooltip = {
6082
+ $fifth_effect$
6083
+ }
6084
+ ]
6085
+
6086
+ [[sixth_custom_tooltip]
6087
+ custom_tooltip = $sixth_custom_tooltip$
6088
+ if = {
6089
+ limit = {
6090
+ $sixth_limit$
9489
6091
  }
9490
- else = { add_building = regimental_camp }
6092
+ custom_tooltip = BONUS_REWARD_YES
9491
6093
  }
9492
- }
6094
+ else = { custom_tooltip = BONUS_REWARD_NO }
6095
+ tooltip = {
6096
+ $sixth_effect$
6097
+ }
6098
+ ]
9493
6099
 
9494
- add_or_upgrade_university_building = {
9495
- custom_tooltip = add_or_upgrade_university_building_tt
9496
- hidden_effect = {
9497
- if = {
9498
- limit = { has_building = university }
9499
- add_base_tax = 1
9500
- add_base_production = 1
9501
- add_base_manpower = 1
6100
+ [[seventh_custom_tooltip]
6101
+ custom_tooltip = $seventh_custom_tooltip$
6102
+ if = {
6103
+ limit = {
6104
+ $seventh_limit$
9502
6105
  }
9503
- else = { add_building = university }
6106
+ custom_tooltip = BONUS_REWARD_YES
6107
+ }
6108
+ else = { custom_tooltip = BONUS_REWARD_NO }
6109
+ tooltip = {
6110
+ $seventh_effect$
6111
+ }
6112
+ ]
6113
+
6114
+ [[eighth_custom_tooltip]
6115
+ custom_tooltip = $eighth_custom_tooltip$
6116
+ if = {
6117
+ limit = {
6118
+ $eighth_limit$
6119
+ }
6120
+ custom_tooltip = BONUS_REWARD_YES
6121
+ }
6122
+ else = { custom_tooltip = BONUS_REWARD_NO }
6123
+ tooltip = {
6124
+ $eighth_effect$
9504
6125
  }
9505
- }
6126
+ ]
9506
6127
 
9507
- add_or_upgrade_courthouse_building = {
9508
- custom_tooltip = add_or_upgrade_courthouse_building_tt
9509
- hidden_effect = {
9510
- if = {
9511
- limit = { has_building = courthouse }
9512
- add_building = town_hall
6128
+ [[nineth_custom_tooltip]
6129
+ custom_tooltip = $nineth_custom_tooltip$
6130
+ if = {
6131
+ limit = {
6132
+ $nineth_limit$
9513
6133
  }
9514
- else_if = {
9515
- limit = { has_building = town_hall }
9516
- add_base_tax = 1
9517
- add_base_production = 1
9518
- add_base_manpower = 1
6134
+ custom_tooltip = BONUS_REWARD_YES
6135
+ }
6136
+ else = { custom_tooltip = BONUS_REWARD_NO }
6137
+ tooltip = {
6138
+ $nineth_effect$
6139
+ }
6140
+ ]
6141
+
6142
+ [[tenth_custom_tooltip]
6143
+ custom_tooltip = $tenth_custom_tooltip$
6144
+ if = {
6145
+ limit = {
6146
+ $tenth_limit$
9519
6147
  }
9520
- else = { add_building = courthouse }
6148
+ custom_tooltip = BONUS_REWARD_YES
9521
6149
  }
9522
- }
6150
+ else = { custom_tooltip = BONUS_REWARD_NO }
6151
+ tooltip = {
6152
+ $tenth_effect$
6153
+ }
6154
+ ]
6155
+
6156
+ [[combined_effect]
6157
+ if = {
6158
+ limit = {
6159
+ $first_limit$
6160
+ $second_limit$
6161
+ $third_limit$
6162
+ $fourth_limit$
6163
+ $fifth_limit$
6164
+ $sixth_limit$
6165
+ $seventh_limit$
6166
+ $eigth_limit$
6167
+ $nineth_limit$
6168
+ $tenth_limit$
6169
+ }
6170
+ custom_tooltip = COMBINED_BONUS_REWARD_YES
6171
+ }
6172
+ else = { custom_tooltip = COMBINED_BONUS_REWARD_NO }
6173
+ tooltip = {
6174
+ $combined_effect$
6175
+ }
6176
+ ]
9523
6177
 
9524
- add_or_upgrade_fort_building = {
9525
- custom_tooltip = add_or_upgrade_fort_building_tt
9526
6178
  hidden_effect = {
9527
6179
  if = {
9528
- limit = { has_building = fort_15th }
9529
- add_building = fort_16th
6180
+ limit = { $first_limit$ }
6181
+ $first_effect$
9530
6182
  }
9531
- else_if = {
9532
- limit = { has_building = fort_16th }
9533
- add_building = fort_17th
6183
+ [[second_custom_tooltip]
6184
+ if = {
6185
+ limit = { $second_limit$ }
6186
+ $second_effect$
9534
6187
  }
9535
- else_if = {
9536
- limit = { has_building = fort_17th }
9537
- add_building = fort_18th
6188
+ ]
6189
+ [[third_custom_tooltip]
6190
+ if = {
6191
+ limit = { $third_limit$ }
6192
+ $third_effect$
9538
6193
  }
9539
- else_if = {
9540
- limit = { has_building = fort_18th }
9541
- add_base_manpower = 3
6194
+ ]
6195
+ [[fourth_custom_tooltip]
6196
+ if = {
6197
+ limit = { $fourth_limit$ }
6198
+ $fourth_effect$
9542
6199
  }
9543
- else = { add_building = fort_15th }
9544
- }
9545
- }
9546
-
9547
- add_or_upgrade_naval_defense_building = {
9548
- custom_tooltip = add_or_upgrade_naval_defense_building_tt
9549
- hidden_effect = {
6200
+ ]
6201
+ [[fifth_custom_tooltip]
9550
6202
  if = {
9551
- limit = { has_building = coastal_defence }
9552
- add_building = naval_battery
6203
+ limit = { $fifth_limit$ }
6204
+ $fifth_effect$
9553
6205
  }
9554
- else_if = {
9555
- limit = { has_building = naval_battery }
9556
- add_base_production = 2
6206
+ ]
6207
+ [[sixth_custom_tooltip]
6208
+ if = {
6209
+ limit = { $sixth_limit$ }
6210
+ $sixth_effect$
9557
6211
  }
9558
- else = { add_building = coastal_defence }
9559
- }
9560
- }
9561
-
9562
- upgrade_trade_building = {
9563
- custom_tooltip = upgrade_trade_building_tt
9564
- hidden_effect = {
6212
+ ]
6213
+ [[seventh_custom_tooltip]
9565
6214
  if = {
9566
- limit = { has_building = marketplace }
9567
- add_building = trade_depot
6215
+ limit = { $seventh_limit$ }
6216
+ $seventh_effect$
9568
6217
  }
9569
- else_if = {
9570
- limit = { has_building = trade_depot }
9571
- add_building = stock_exchange
6218
+ ]
6219
+ [[eigth_custom_tooltip]
6220
+ if = {
6221
+ limit = { $eigth_limit$ }
6222
+ $eigth_effect$
9572
6223
  }
9573
- else_if = {
9574
- limit = { has_building = stock_exchange }
9575
- add_base_tax = 1
9576
- add_base_production = 1
6224
+ ]
6225
+ [[nineth_custom_tooltip]
6226
+ if = {
6227
+ limit = { $nineth_limit$ }
6228
+ $nineth_effect$
9577
6229
  }
9578
- }
9579
- }
9580
-
9581
- upgrade_tax_building = {
9582
- custom_tooltip = upgrade_tax_building_tt
9583
- hidden_effect = {
6230
+ ]
6231
+ [[tenth_custom_tooltip]
9584
6232
  if = {
9585
- limit = { has_building = temple }
9586
- add_building = cathedral
6233
+ limit = { $tenth_limit$ }
6234
+ $tenth_effect$
9587
6235
  }
9588
- else_if = {
9589
- limit = { has_building = cathedral }
9590
- add_base_tax = 2
6236
+ ]
6237
+ [[combined_effect]
6238
+ if = {
6239
+ limit = {
6240
+ $first_limit$
6241
+ $second_limit$
6242
+ $third_limit$
6243
+ $fourth_limit$
6244
+ $fifth_limit$
6245
+ $sixth_limit$
6246
+ $seventh_limit$
6247
+ $eigth_limit$
6248
+ $nineth_limit$
6249
+ $tenth_limit$
6250
+ }
6251
+ $combined_effect$
9591
6252
  }
6253
+ ]
9592
6254
  }
9593
6255
  }
9594
6256
 
9595
- upgrade_production_building = {
9596
- custom_tooltip = upgrade_production_building_tt
9597
- hidden_effect = {
9598
- if = {
9599
- limit = { has_building = workshop }
9600
- add_building = counting_house
6257
+ pick_best_provinces = {
6258
+ [[scope]
6259
+ pick_best_provinces_2 = {
6260
+ scope = "$scope$"
6261
+ scale = "$scale$"
6262
+ event_target_name = "$event_target_name$"
6263
+ global_trigger = "$global_trigger$"
6264
+ 1 = "$1$"
6265
+ 2 = "$2$"
6266
+ 3 = "$3$"
6267
+ 4 = "$4$"
6268
+ 5 = "$5$"
6269
+ 10 = "$10$"
9601
6270
  }
9602
- else_if = {
9603
- limit = { has_building = counting_house }
9604
- add_base_production = 2
6271
+ set_global_flag = PICK_BEST_PROVINCES_FLAG
6272
+ ] #curses for not having an [ELSE ] or something.
6273
+ if = {
6274
+ limit = {
6275
+ NOT = { has_global_flag = PICK_BEST_PROVINCES_FLAG } #This check is here to prevent the algorithm from being run again after the scoped version was executed
6276
+ }
6277
+ pick_best_provinces_2 = {
6278
+ scope = " every_province "
6279
+ scale = "$scale$"
6280
+ event_target_name = "$event_target_name$"
6281
+ global_trigger = "$global_trigger$"
6282
+ 1 = "$1$"
6283
+ 2 = "$2$"
6284
+ 3 = "$3$"
6285
+ 4 = "$4$"
6286
+ 5 = "$5$"
6287
+ 10 = "$10$"
9605
6288
  }
9606
6289
  }
6290
+ else = { clr_global_flag = PICK_BEST_PROVINCES_FLAG }
9607
6291
  }
9608
6292
 
9609
- upgrade_dock_building = {
9610
- custom_tooltip = upgrade_dock_building_tt
6293
+ pick_best_provinces_2 = {
9611
6294
  hidden_effect = {
9612
- if = {
9613
- limit = { has_building = dock }
9614
- add_building = drydock
9615
- }
9616
- else_if = {
9617
- limit = { has_building = drydock }
9618
- ROOT = { add_sailors = 0.5 }
6295
+ [[1]
6296
+ if = {
6297
+ limit = { always = $1$ }
6298
+ pick_best_province = {
6299
+ scale = "$scale$"
6300
+ scope = $scope$
6301
+ global_trigger = "$global_trigger$"
6302
+ event_target_name = "$event_target_name$"
6303
+ number = 1
6304
+ }
6305
+ }
6306
+ ]
6307
+ [[2]
6308
+ if = {
6309
+ limit = { always = $2$ }
6310
+ pick_best_province = {
6311
+ scale = "$scale$"
6312
+ scope = $scope$
6313
+ global_trigger = "$global_trigger$"
6314
+ event_target_name = "$event_target_name$"
6315
+ number = 1
6316
+ }
6317
+ pick_best_province = {
6318
+ scale = "$scale$"
6319
+ scope = $scope$
6320
+ global_trigger = "$global_trigger$"
6321
+ event_target_name = "$event_target_name$"
6322
+ number = 2
6323
+ }
6324
+ }
6325
+ ]
6326
+ [[3]
6327
+ if = {
6328
+ limit = { always = $3$ }
6329
+ pick_best_province = {
6330
+ scale = "$scale$"
6331
+ scope = $scope$
6332
+ global_trigger = "$global_trigger$"
6333
+ event_target_name = "$event_target_name$"
6334
+ number = 1
6335
+ }
6336
+ pick_best_province = {
6337
+ scale = "$scale$"
6338
+ scope = $scope$
6339
+ global_trigger = "$global_trigger$"
6340
+ event_target_name = "$event_target_name$"
6341
+ number = 2
6342
+ }
6343
+ pick_best_province = {
6344
+ scale = "$scale$"
6345
+ scope = $scope$
6346
+ global_trigger = "$global_trigger$"
6347
+ event_target_name = "$event_target_name$"
6348
+ number = 3
6349
+ }
6350
+ }
6351
+ ]
6352
+ [[4]
6353
+ if = {
6354
+ limit = { always = $4$ }
6355
+ pick_best_province = {
6356
+ scale = "$scale$"
6357
+ scope = $scope$
6358
+ global_trigger = "$global_trigger$"
6359
+ event_target_name = "$event_target_name$"
6360
+ number = 1
6361
+ }
6362
+ pick_best_province = {
6363
+ scale = "$scale$"
6364
+ scope = $scope$
6365
+ global_trigger = "$global_trigger$"
6366
+ event_target_name = "$event_target_name$"
6367
+ number = 2
6368
+ }
6369
+ pick_best_province = {
6370
+ scale = "$scale$"
6371
+ scope = $scope$
6372
+ global_trigger = "$global_trigger$"
6373
+ event_target_name = "$event_target_name$"
6374
+ number = 3
6375
+ }
6376
+ pick_best_province = {
6377
+ scale = "$scale$"
6378
+ scope = $scope$
6379
+ global_trigger = "$global_trigger$"
6380
+ event_target_name = "$event_target_name$"
6381
+ number = 4
6382
+ }
6383
+ }
6384
+ ]
6385
+ [[5]
6386
+ if = {
6387
+ limit = { always = $5$ }
6388
+ pick_best_province = {
6389
+ scale = "$scale$"
6390
+ scope = $scope$
6391
+ global_trigger = "$global_trigger$"
6392
+ event_target_name = "$event_target_name$"
6393
+ number = 1
6394
+ }
6395
+ pick_best_province = {
6396
+ scale = "$scale$"
6397
+ scope = $scope$
6398
+ global_trigger = "$global_trigger$"
6399
+ event_target_name = "$event_target_name$"
6400
+ number = 2
6401
+ }
6402
+ pick_best_province = {
6403
+ scale = "$scale$"
6404
+ scope = $scope$
6405
+ global_trigger = "$global_trigger$"
6406
+ event_target_name = "$event_target_name$"
6407
+ number = 3
6408
+ }
6409
+ pick_best_province = {
6410
+ scale = "$scale$"
6411
+ scope = $scope$
6412
+ global_trigger = "$global_trigger$"
6413
+ event_target_name = "$event_target_name$"
6414
+ number = 4
6415
+ }
6416
+ pick_best_province = {
6417
+ scale = "$scale$"
6418
+ scope = $scope$
6419
+ global_trigger = "$global_trigger$"
6420
+ event_target_name = "$event_target_name$"
6421
+ number = 5
6422
+ }
6423
+ }
6424
+ ]
6425
+ [[10]
6426
+ if = {
6427
+ limit = { always = $10$ }
6428
+ pick_best_province = {
6429
+ scale = "$scale$"
6430
+ scope = $scope$
6431
+ global_trigger = "$global_trigger$"
6432
+ event_target_name = "$event_target_name$"
6433
+ number = 1
6434
+ }
6435
+ pick_best_province = {
6436
+ scale = "$scale$"
6437
+ scope = $scope$
6438
+ global_trigger = "$global_trigger$"
6439
+ event_target_name = "$event_target_name$"
6440
+ number = 2
6441
+ }
6442
+ pick_best_province = {
6443
+ scale = "$scale$"
6444
+ scope = $scope$
6445
+ global_trigger = "$global_trigger$"
6446
+ event_target_name = "$event_target_name$"
6447
+ number = 3
6448
+ }
6449
+ pick_best_province = {
6450
+ scale = "$scale$"
6451
+ scope = $scope$
6452
+ global_trigger = "$global_trigger$"
6453
+ event_target_name = "$event_target_name$"
6454
+ number = 4
6455
+ }
6456
+ pick_best_province = {
6457
+ scale = "$scale$"
6458
+ scope = $scope$
6459
+ global_trigger = "$global_trigger$"
6460
+ event_target_name = "$event_target_name$"
6461
+ number = 5
6462
+ }
6463
+ pick_best_province = {
6464
+ scale = "$scale$"
6465
+ scope = $scope$
6466
+ global_trigger = "$global_trigger$"
6467
+ event_target_name = "$event_target_name$"
6468
+ number = 6
6469
+ }
6470
+ pick_best_province = {
6471
+ scale = "$scale$"
6472
+ scope = $scope$
6473
+ global_trigger = "$global_trigger$"
6474
+ event_target_name = "$event_target_name$"
6475
+ number = 7
6476
+ }
6477
+ pick_best_province = {
6478
+ scale = "$scale$"
6479
+ scope = $scope$
6480
+ global_trigger = "$global_trigger$"
6481
+ event_target_name = "$event_target_name$"
6482
+ number = 8
6483
+ }
6484
+ pick_best_province = {
6485
+ scale = "$scale$"
6486
+ scope = $scope$
6487
+ global_trigger = "$global_trigger$"
6488
+ event_target_name = "$event_target_name$"
6489
+ number = 9
6490
+ }
6491
+ pick_best_province = {
6492
+ scale = "$scale$"
6493
+ scope = $scope$
6494
+ global_trigger = "$global_trigger$"
6495
+ event_target_name = "$event_target_name$"
6496
+ number = 10
6497
+ }
6498
+ }
6499
+ ]
6500
+ $scope$ = {
6501
+ limit = {
6502
+ has_province_flag = $event_target_name$_exclude
6503
+ }
6504
+ clr_province_flag = $event_target_name$_exclude
9619
6505
  }
9620
6506
  }
9621
6507
  }
9622
6508
 
9623
- upgrade_shipyard_building = {
9624
- custom_tooltip = upgrade_shipyard_building_tt
9625
- hidden_effect = {
9626
- if = {
9627
- limit = { has_building = shipyard }
9628
- add_building = grand_shipyard
6509
+ pick_best_province = {
6510
+ $scope$ = {
6511
+ limit = {
6512
+ [[global_trigger] $global_trigger$ ]
6513
+ NOT = { has_province_flag = $event_target_name$_exclude }
9629
6514
  }
9630
- else_if = {
9631
- limit = { has_building = grand_shipyard }
9632
- ROOT = { add_sailors = 0.5 }
6515
+ save_event_target_as = $event_target_name$_$number$
6516
+ }
6517
+ $scope$ = {
6518
+ limit = {
6519
+ [[global_trigger] $global_trigger$ ]
6520
+ $scale$ = event_target:$event_target_name$_$number$
6521
+ NOT = { has_province_flag = $event_target_name$_exclude }
9633
6522
  }
6523
+ save_event_target_as = $event_target_name$_$number$
6524
+ }
6525
+ event_target:$event_target_name$_$number$ = {
6526
+ set_province_flag = $event_target_name$_exclude
9634
6527
  }
9635
6528
  }
9636
6529
 
9637
- upgrade_manpower_building = {
9638
- custom_tooltip = upgrade_manpower_building_tt
9639
- hidden_effect = {
9640
- if = {
9641
- limit = { has_building = barracks }
9642
- add_building = training_fields
9643
- }
9644
- else_if = {
9645
- limit = { has_building = training_fields }
9646
- add_base_tax = 1
9647
- add_base_manpower = 1
9648
- }
6530
+ create_general_with_pips = {
6531
+ create_general = {
6532
+ tradition = $tradition$
6533
+ [[add_fire] add_fire = $add_fire$ ]
6534
+ [[add_shock] add_shock = $add_shock$ ]
6535
+ [[add_manuever] add_manuever = $add_manuever$ ]
6536
+ [[add_siege] add_siege = $add_siege$ ]
6537
+ [[name] name = "$name$" ]
6538
+ [[culture] culture = $culture$ ]
9649
6539
  }
6540
+ custom_tooltip = ME_GENERAL_$add_fire$_$add_shock$_$add_manuever$_$add_siege$
9650
6541
  }
9651
6542
 
9652
- upgrade_forcelimit_building = {
9653
- custom_tooltip = upgrade_forcelimit_building_tt
9654
- hidden_effect = {
6543
+ give_province_claims = {
6544
+ $id$ = {
9655
6545
  if = {
9656
- limit = { has_building = regimental_camp }
9657
- add_building = conscription_center
9658
- }
9659
- else_if = {
9660
- limit = { has_building = conscription_center }
9661
- add_base_manpower = 2
6546
+ limit = {
6547
+ NOT = { is_core = $tag$ }
6548
+ NOT = { is_permanent_claim = $tag$ }
6549
+ }
6550
+ add_permanent_claim = $tag$
9662
6551
  }
9663
6552
  }
9664
6553
  }
9665
6554
 
9666
- upgrade_courthouse_building = {
9667
- custom_tooltip = upgrade_courthouse_building_tt
9668
- hidden_effect = {
9669
- if = {
9670
- limit = { has_building = courthouse }
9671
- add_building = town_hall
9672
- }
9673
- else_if = {
9674
- limit = { has_building = town_hall }
9675
- add_base_tax = 1
9676
- add_base_production = 1
9677
- add_base_manpower = 1
6555
+ give_area_claims = {
6556
+ $group$ = {
6557
+ limit = {
6558
+ NOT = { is_core = $tag$ }
6559
+ NOT = { is_permanent_claim = $tag$ }
9678
6560
  }
6561
+ add_permanent_claim = $tag$
9679
6562
  }
9680
6563
  }
9681
6564
 
9682
- upgrade_fort_building = {
9683
- custom_tooltip = upgrade_fort_building_tt
9684
- hidden_effect = {
9685
- if = {
9686
- limit = { has_building = fort_15th }
9687
- add_building = fort_16th
9688
- }
9689
- else_if = {
9690
- limit = { has_building = fort_16th }
9691
- add_building = fort_17th
9692
- }
9693
- else_if = {
9694
- limit = { has_building = fort_17th }
9695
- add_building = fort_18th
9696
- }
9697
- else_if = {
9698
- limit = { has_building = fort_18th }
9699
- add_base_manpower = 3
9700
- }
9701
- }
6565
+ give_claims = {
6566
+ [[province]
6567
+ give_province_claims = { id = $province$ tag = ROOT }
6568
+ ]
6569
+ [[id]
6570
+ give_province_claims = { id = $id$ tag = ROOT }
6571
+ ]
6572
+ [[area]
6573
+ give_area_claims = { group = $area$ tag = ROOT }
6574
+ ]
6575
+ [[region]
6576
+ give_area_claims = { group = $region$ tag = ROOT }
6577
+ ]
6578
+
9702
6579
  }
9703
6580
 
9704
- upgrade_naval_defense_building = {
9705
- custom_tooltip = upgrade_naval_defense_building_tt
9706
- hidden_effect = {
9707
- if = {
9708
- limit = { has_building = coastal_defence }
9709
- add_building = naval_battery
9710
- }
9711
- else_if = {
9712
- limit = { has_building = naval_battery }
9713
- add_base_production = 2
9714
- }
6581
+ add_power_projection_mission = {
6582
+ add_power_projection = {
6583
+ type = mission_rewards_power_projection
6584
+ amount = $amount$
9715
6585
  }
9716
6586
  }
9717
6587
 
9718
- remove_temporary_colonist = {
9719
- hidden_effect = {
9720
- remove_country_modifier = temporary_colonist
6588
+ country_event_with_effect_insight = {
6589
+ country_event = {
6590
+ id = $id$
6591
+ [[days] days = $days$]
6592
+ [[random] random = $random$]
6593
+ [[tooltip] tooltip = $tooltip$]
6594
+ }
6595
+ custom_tooltip = EVENT_INSIGHT_INTRO
6596
+ tooltip = {
6597
+ $effect$
9721
6598
  }
9722
6599
  }
9723
6600
 
9724
- restore_greek_names = {
9725
- custom_tooltip = reestablishing_themes_names_tooltip
9726
- hidden_effect = {
9727
- 149 = { change_province_name = Adrianople rename_capital = Adrianople }
9728
- 151 = { change_province_name = Constantinople rename_capital = Constantinople }
9729
- 316 = { change_province_name = Optimatoi rename_capital = Nikomedeia }
9730
- 317 = { change_province_name = Opsikion rename_capital = Prussa }
9731
- 318 = { change_province_name = Smyrna rename_capital = Smyrna }
9732
- 319 = { change_province_name = Mylasa rename_capital = Mougla }
9733
- 322 = { change_province_name = Kotyaion rename_capital = Kotyaion }
9734
- 323 = { change_province_name = Ikonion rename_capital = Iconion }
9735
- 324 = { change_province_name = Laranda rename_capital = Laranda }
9736
- 325 = { change_province_name = Paphlagonia rename_capital = Timonio }
9737
- 326 = { change_province_name = Galatia rename_capital = Ancyra }
9738
- 327 = { change_province_name = Cilicia rename_capital = Atana }
9739
- 328 = { change_province_name = Sinope rename_capital = Sinop }
9740
- 329 = { change_province_name = Sebasteia rename_capital = Sebastopolis }
9741
- 330 = { change_province_name = Trebizond rename_capital = Trapezous }
9742
- 331 = { change_province_name = Theodosiopolis rename_capital = Theodosiopolis }
9743
- 1764 = { change_province_name = Mesambria rename_capital = Mesambria }
9744
- 1846 = { change_province_name = Armeniakon rename_capital = Amasea }
9745
- 1848 = { change_province_name = Baris rename_capital = Baris }
9746
- 2296 = { change_province_name = Abydos rename_capital = Pigai }
9747
- 2297 = { change_province_name = Thrakesion rename_capital = Magnesia }
9748
- 2298 = { change_province_name = Attalia rename_capital = Attalia }
9749
- 2299 = { change_province_name = Boukellarion rename_capital = Klaudiopol}
9750
- 2300 = { change_province_name = Cappadocia rename_capital = Tavium }
9751
- 2301 = { change_province_name = Charsianon rename_capital = Ceasarea }
9752
- 2302 = { change_province_name = Seleucia rename_capital = Kermarage }
9753
- 2304 = { change_province_name = Chaldia rename_capital = Amissos}
9754
- 2305 = { change_province_name = Acilisene rename_capital = Acilisene }
9755
- 2750 = { change_province_name = Philippopolis rename_capital = Philippopolis}
9756
- 4307 = { change_province_name = Colonia rename_capital = Colonia }
9757
- 4308 = { change_province_name = Laodicea rename_capital = Laodicea }
9758
- 4309 = { change_province_name = Tralles rename_capital = Tralles }
9759
- 4310 = { change_province_name = Tephrike rename_capital = Tephrike }
9760
- 4311 = { change_province_name = Anatolikon rename_capital = Polydorion }
9761
- 4312 = { change_province_name = Dorylaeum rename_capital = Dorylaeum }
9762
- 4313 = { change_province_name = Gangra rename_capital = Gangra }
9763
- 4314 = { change_province_name = Justinianopolis rename_capital = Justinianopolis }
9764
- 4315 = { change_province_name = Evdoksia rename_capital = Evdoksia }
6601
+ country_event_with_option_insight = {
6602
+ country_event = {
6603
+ id = $id$
6604
+ [[days] days = $days$]
6605
+ [[random] random = $random$]
6606
+ [[tooltip] tooltip = $tooltip$]
6607
+ }
6608
+ custom_tooltip = EVENT_INSIGHT_INTRO
6609
+ custom_tooltip = EVENT_INSIGHT_OPT_1
6610
+ tooltip = {
6611
+ $option_1$
9765
6612
  }
6613
+ [[option_2]
6614
+ custom_tooltip = EVENT_INSIGHT_OPT_2
6615
+ tooltip = {
6616
+ $option_2$
6617
+ }
6618
+ ]
6619
+ [[option_3]
6620
+ custom_tooltip = EVENT_INSIGHT_OPT_3
6621
+ tooltip = {
6622
+ $option_3$
6623
+ }
6624
+ ]
6625
+ [[option_4]
6626
+ custom_tooltip = EVENT_INSIGHT_OPT_4
6627
+ tooltip = {
6628
+ $option_4$
6629
+ }
6630
+ ]
6631
+ [[option_5]
6632
+ custom_tooltip = EVENT_INSIGHT_OPT_5
6633
+ tooltip = {
6634
+ $option_5$
6635
+ }
6636
+ ]
9766
6637
  }
common/scripted_effects/01_scripted_effects_for_estates.txt CHANGED
@@ -972,6 +972,16 @@ on_province_religion_converted_estate_privileges_effect = {
972
972
  }
973
973
 
974
974
  on_province_culture_converted_estate_privilges_effect = {
975
+ if = {
976
+ limit = {
977
+ owner = {
978
+ has_estate_privilege = estate_nobles_reformatio_sigismundi
979
+ }
980
+ has_province_modifier = boh_cultural_integration
981
+ NOT = { culture_group = germanic }
982
+ }
983
+ remove_province_modifier = boh_cultural_integration
984
+ }
975
985
  if = {
976
986
  limit = {
977
987
  owner = {
@@ -1107,39 +1117,55 @@ on_province_owner_change_estate_privileges_effect = {
1107
1117
  if = {
1108
1118
  limit = { has_terrain = steppe }
1109
1119
  if = {
1110
- limit = {
1111
- owner = {
1112
- has_estate_privilege = estate_cossacks_prime_herding_rights
1113
- }
1114
- NOT = { has_province_modifier = estate_cossacks_prime_herding_rights_mod }
1115
- }
1120
+ limit = { owner = { has_estate_privilege = estate_cossacks_prime_herding_rights } }
1116
1121
  add_province_modifier = {
1117
1122
  name = estate_cossacks_prime_herding_rights_mod
1118
1123
  duration = -1
1119
1124
  }
1120
- }
1121
- if = {
1122
- limit = {
1123
- owner = {
1124
- has_estate_privilege = estate_cossacks_exploration_expedition
1125
+ if = {
1126
+ limit = { owner = { has_country_flag = feo_upgrade_prime_herding_rights_flag } }
1127
+ add_province_modifier = {
1128
+ name = feo_upgrade_prime_herding_rights_mod
1129
+ duration = -1
1125
1130
  }
1126
- NOT = { has_province_modifier = estate_cossacks_exploration_expedition_mod }
1127
1131
  }
1132
+ }
1133
+ else = {
1134
+ if = {
1135
+ limit = { has_province_modifier = estate_cossacks_prime_herding_rights_mod }
1136
+ remove_province_modifier = estate_cossacks_prime_herding_rights_mod
1137
+ }
1138
+ if = {
1139
+ limit = { has_province_modifier = feo_upgrade_prime_herding_rights_mod }
1140
+ remove_province_modifier = feo_upgrade_prime_herding_rights_mod
1141
+ }
1142
+ }
1143
+ if = {
1144
+ limit = { owner = { has_estate_privilege = estate_cossacks_exploration_expedition } }
1128
1145
  add_province_modifier = {
1129
1146
  name = estate_cossacks_exploration_expedition_mod
1130
1147
  duration = -1
1131
1148
  }
1132
1149
  }
1133
- }
1134
- else_if = {
1135
- limit = {
1136
- has_terrain = steppe
1137
- has_province_modifier = estate_cossacks_prime_herding_rights_mod
1138
- owner = {
1139
- NOT = { has_estate_privilege = estate_cossacks_prime_herding_rights }
1150
+ else = {
1151
+ if = {
1152
+ limit = { has_province_modifier = estate_cossacks_exploration_expedition_mod }
1153
+ remove_province_modifier = estate_cossacks_exploration_expedition_mod
1154
+ }
1155
+ }
1156
+ if = {
1157
+ limit = { owner = { has_estate_privilege = estate_cossacks_exempt_from_bureaucracy has_country_flag = feo_cossack_self_governance_buff_flag } }
1158
+ add_province_modifier = {
1159
+ name = feo_cossack_self_governance_buff_mod
1160
+ duration = -1
1161
+ }
1162
+ }
1163
+ else = {
1164
+ if = {
1165
+ limit = { has_province_modifier = feo_cossack_self_governance_buff_mod }
1166
+ remove_province_modifier = feo_cossack_self_governance_buff_mod
1140
1167
  }
1141
1168
  }
1142
- remove_province_modifier = estate_cossacks_prime_herding_rights_mod
1143
1169
  }
1144
1170
  if = {
1145
1171
  limit = {
@@ -1860,6 +1886,30 @@ on_province_owner_change_estate_privileges_effect = {
1860
1886
  }
1861
1887
  }
1862
1888
  }
1889
+ if = {
1890
+ limit = {
1891
+ owner = {
1892
+ has_estate_privilege = estate_burghers_MAY_tropical_adaptation
1893
+ }
1894
+ has_terrain = jungle
1895
+ }
1896
+ if = {
1897
+ limit = {
1898
+ owner = { has_country_flag = MAY_upgraded_privilege }
1899
+ }
1900
+ add_province_modifier = {
1901
+ name = MAY_jungle_reduction_upgrade
1902
+ duration = -1
1903
+ }
1904
+ }
1905
+ else = {
1906
+ add_province_modifier = {
1907
+ name = MAY_jungle_reduction
1908
+ duration = -1
1909
+ }
1910
+ }
1911
+ }
1912
+
1863
1913
  if = {
1864
1914
  limit = {
1865
1915
  owner = {
@@ -1974,12 +2024,23 @@ on_province_owner_change_estate_privileges_effect = {
1974
2024
  name = estate_cossacks_freedom_of_the_steppes_mod
1975
2025
  duration = -1
1976
2026
  }
2027
+ if = {
2028
+ limit = { owner = { has_country_flag = feo_buffed_freedom_of_steppes_flag } }
2029
+ add_province_modifier = {
2030
+ name = feo_buffed_freedom_of_steppes_mod
2031
+ duration = -1
2032
+ }
2033
+ }
1977
2034
  }
1978
2035
  else = {
1979
2036
  if = {
1980
2037
  limit = { has_province_modifier = estate_cossacks_freedom_of_the_steppes_mod }
1981
2038
  remove_province_modifier = estate_cossacks_freedom_of_the_steppes_mod
1982
2039
  }
2040
+ if = {
2041
+ limit = { has_province_modifier = feo_buffed_freedom_of_steppes_mod }
2042
+ remove_province_modifier = feo_buffed_freedom_of_steppes_mod
2043
+ }
1983
2044
  }
1984
2045
  }
1985
2046
  if = {
@@ -4558,7 +4619,25 @@ on_completed_agenda_effect_estate_brahmins = {
4558
4619
  change_statists_vs_orangists = -0.05
4559
4620
  }
4560
4621
  }
4561
- on_completed_agenda_effect_estate_burghers = {}
4622
+ on_completed_agenda_effect_estate_burghers = {
4623
+ if = {
4624
+ limit = {
4625
+ has_country_flag = ITA_upgrade_city_expansion_privileges_flag
4626
+ has_estate_privilege = estate_burghers_development_of_cities
4627
+ }
4628
+ custom_tooltip = ITA_3_random_dev_distribution
4629
+ hidden_effect = {
4630
+ for = {
4631
+ amount = 3
4632
+ effect = "
4633
+ random_owned_province = {
4634
+ add_random_development = 1
4635
+ }
4636
+ "
4637
+ }
4638
+ }
4639
+ }
4640
+ }
4562
4641
  on_completed_agenda_effect_estate_church = {
4563
4642
  if = {
4564
4643
  limit = { has_government_attribute = clergy_estate_agendas_gives_karma }
@@ -4938,8 +5017,16 @@ estate_action_COMISSION_MERCHANT_SHIPS_FOR_WAR_BURGHERS = {
4938
5017
  # estate = estate_burghers
4939
5018
  # loyalty = -15
4940
5019
  #}
4941
- add_ship_construction_scaled_to_ports = {
4942
- type = heavy_ship
5020
+ if = {
5021
+ limit = {
5022
+ has_country_flag = SUN_draft_ships_for_war_flag
5023
+ }
5024
+ add_ship_construction_scaled_to_ports_MAY = yes
5025
+ }
5026
+ else = {
5027
+ add_ship_construction_scaled_to_ports = {
5028
+ type = heavy_ship
5029
+ }
4943
5030
  }
4944
5031
  }
4945
5032
  estate_action_MAKE_GENEROUS_DONATION_CHURCH = {
@@ -5017,12 +5104,17 @@ estate_action_DEMAND_SUPPORT_CHURCH = {
5017
5104
  }
5018
5105
  }
5019
5106
  estate_action_SEEK_SUPPORT_OF_CLERGY_CHURCH = {
5020
- add_prestige = -5
5021
- add_legitimacy = -5
5022
- add_republican_tradition = -3
5023
- add_devotion = -5
5024
- add_horde_unity = -5
5025
- add_meritocracy = -2
5107
+ if = {
5108
+ limit = {
5109
+ NOT = { has_country_flag = MAY_upgrade_institutionalized_clergy_privilege_flag }
5110
+ }
5111
+ add_prestige = -5
5112
+ add_legitimacy = -5
5113
+ add_republican_tradition = -3
5114
+ add_devotion = -5
5115
+ add_horde_unity = -5
5116
+ add_meritocracy = -2
5117
+ }
5026
5118
  change_piety_effect = {
5027
5119
  amount = 0.05
5028
5120
  }
@@ -5656,9 +5748,20 @@ estate_action_CALL_DIET_NOBLES = {
5656
5748
  }
5657
5749
  }
5658
5750
  estate_action_GRANT_GENERALSHIP_NOBLES = {
5659
- create_leader_scaling_with_tradition = {
5660
- leader = general
5661
- type = army
5751
+ if = {
5752
+ limit = {
5753
+ has_country_flag = INC_upgrade_general_privilege_for_the_nobles_flag
5754
+ }
5755
+ create_general_scaling_with_tradition_and_pips = {
5756
+ add_shock = 1
5757
+ add_manuever = 1
5758
+ }
5759
+ }
5760
+ else = {
5761
+ create_leader_scaling_with_tradition = {
5762
+ leader = general
5763
+ type = army
5764
+ }
5662
5765
  }
5663
5766
  #add_estate_influence_modifier = {
5664
5767
  # estate = estate_nobles
@@ -5738,6 +5841,15 @@ estate_action_RECRUIT_MINISTER_NOBLES = {
5738
5841
  estate = estate_nobles
5739
5842
  type = diplomat
5740
5843
  }
5844
+ if = {
5845
+ limit = {
5846
+ has_country_flag = GER_upgrade_the_statesman_privilege_flag
5847
+ }
5848
+ generate_estate_advisor = {
5849
+ estate = estate_nobles
5850
+ type = statesman
5851
+ }
5852
+ }
5741
5853
  #add_estate_influence_modifier = {
5742
5854
  # estate = estate_nobles
5743
5855
  # desc = EST_VAL_NOBLES_MINISTER
common/scripted_effects/01_scripted_effects_for_government_mechanics.txt ADDED
@@ -0,0 +1,703 @@
1
+ #civic_republicanism_focus_government
2
+ #civic_republicanism_focus_expansion
3
+ #civic_republicanism_focus_technology
4
+ #civic_republicanism_focus_stability
5
+ #civic_republicanism_focus_religion
6
+
7
+ #civic_republicanism_focus_diplomacy
8
+ #civic_republicanism_focus_court
9
+ #civic_republicanism_focus_trade
10
+ #civic_republicanism_focus_subjects
11
+ #civic_republicanism_focus_development
12
+
13
+ #civic_republicanism_focus_defensive
14
+ #civic_republicanism_focus_sieges
15
+ #civic_republicanism_focus_leaders
16
+ #civic_republicanism_focus_quality
17
+ #civic_republicanism_focus_naval
18
+
19
+ pre_select_possible_ruler_focus_adm = {
20
+ random_list = {
21
+ 1 = { set_country_flag = civic_republicanism_focus_government_flag }
22
+ 1 = { set_country_flag = civic_republicanism_focus_expansion_flag }
23
+ 1 = { set_country_flag = civic_republicanism_focus_technology_flag }
24
+ 1 = { set_country_flag = civic_republicanism_focus_stability_flag }
25
+ 1 = { set_country_flag = civic_republicanism_focus_religion_flag }
26
+ }
27
+ }
28
+ pre_select_possible_ruler_focus_dip = {
29
+ random_list = {
30
+ 1 = { set_country_flag = civic_republicanism_focus_diplomacy_flag }
31
+ 1 = { set_country_flag = civic_republicanism_focus_court_flag }
32
+ 1 = { set_country_flag = civic_republicanism_focus_trade_flag }
33
+ 1 = { set_country_flag = civic_republicanism_focus_subjects_flag }
34
+ 1 = { set_country_flag = civic_republicanism_focus_development_flag }
35
+ }
36
+ }
37
+ pre_select_possible_ruler_focus_mil = {
38
+ random_list = {
39
+ 1 = { set_country_flag = civic_republicanism_focus_defensive_flag }
40
+ 1 = { set_country_flag = civic_republicanism_focus_sieges_flag }
41
+ 1 = { set_country_flag = civic_republicanism_focus_leaders_flag }
42
+ 1 = { set_country_flag = civic_republicanism_focus_quality_flag }
43
+ 1 = { set_country_flag = civic_republicanism_focus_naval_flag }
44
+ }
45
+ }
46
+ pre_select_possible_ruler_focus_rng = {
47
+ random_list = {
48
+ 1 = { set_country_flag = RNG_civic_republicanism_focus_government }
49
+ 1 = { set_country_flag = RNG_civic_republicanism_focus_expansion }
50
+ 1 = { set_country_flag = RNG_civic_republicanism_focus_technology }
51
+ 1 = { set_country_flag = RNG_civic_republicanism_focus_stability }
52
+ 1 = { set_country_flag = RNG_civic_republicanism_focus_religion }
53
+ 1 = { set_country_flag = RNG_civic_republicanism_focus_diplomacy }
54
+ 1 = { set_country_flag = RNG_civic_republicanism_focus_court }
55
+ 1 = { set_country_flag = RNG_civic_republicanism_focus_trade }
56
+ 1 = { set_country_flag = RNG_civic_republicanism_focus_subjects }
57
+ 1 = { set_country_flag = RNG_civic_republicanism_focus_development }
58
+ 1 = { set_country_flag = RNG_civic_republicanism_focus_defensive }
59
+ 1 = { set_country_flag = RNG_civic_republicanism_focus_sieges }
60
+ 1 = { set_country_flag = RNG_civic_republicanism_focus_leaders }
61
+ 1 = { set_country_flag = RNG_civic_republicanism_focus_quality }
62
+ 1 = { set_country_flag = RNG_civic_republicanism_focus_naval }
63
+ }
64
+ }
65
+ pre_select_possible_ruler_focus = {
66
+ pre_select_possible_ruler_focus_adm = yes
67
+ pre_select_possible_ruler_focus_dip = yes
68
+ pre_select_possible_ruler_focus_mil = yes
69
+ pre_select_possible_ruler_focus_rng = yes
70
+ }
71
+
72
+ assign_ruler_focus_adm = {
73
+ trigger_switch = {
74
+ on_trigger = has_country_flag
75
+ civic_republicanism_focus_government_flag = { add_ruler_modifier = { name = civic_republicanism_focus_government duration = -1 } }
76
+ civic_republicanism_focus_expansion_flag = { add_ruler_modifier = { name = civic_republicanism_focus_expansion duration = -1 } }
77
+ civic_republicanism_focus_technology_flag = { add_ruler_modifier = { name = civic_republicanism_focus_technology duration = -1 } }
78
+ civic_republicanism_focus_stability_flag = { add_ruler_modifier = { name = civic_republicanism_focus_stability duration = -1 } }
79
+ civic_republicanism_focus_religion_flag = { add_ruler_modifier = { name = civic_republicanism_focus_religion duration = -1 } }
80
+ }
81
+ }
82
+ assign_ruler_focus_dip = {
83
+ trigger_switch = {
84
+ on_trigger = has_country_flag
85
+ civic_republicanism_focus_diplomacy_flag = { add_ruler_modifier = { name = civic_republicanism_focus_diplomacy duration = -1 } }
86
+ civic_republicanism_focus_court_flag = { add_ruler_modifier = { name = civic_republicanism_focus_court duration = -1 } }
87
+ civic_republicanism_focus_trade_flag = { add_ruler_modifier = { name = civic_republicanism_focus_trade duration = -1 } }
88
+ civic_republicanism_focus_subjects_flag = { add_ruler_modifier = { name = civic_republicanism_focus_subjects duration = -1 } }
89
+ civic_republicanism_focus_development_flag = { add_ruler_modifier = { name = civic_republicanism_focus_development duration = -1 } }
90
+ }
91
+ }
92
+ assign_ruler_focus_mil = {
93
+ trigger_switch = {
94
+ on_trigger = has_country_flag
95
+ civic_republicanism_focus_defensive_flag = { add_ruler_modifier = { name = civic_republicanism_focus_defensive duration = -1 } }
96
+ civic_republicanism_focus_sieges_flag = { add_ruler_modifier = { name = civic_republicanism_focus_sieges duration = -1 } }
97
+ civic_republicanism_focus_leaders_flag = { add_ruler_modifier = { name = civic_republicanism_focus_leaders duration = -1 } }
98
+ civic_republicanism_focus_quality_flag = { add_ruler_modifier = { name = civic_republicanism_focus_quality duration = -1 } }
99
+ civic_republicanism_focus_naval_flag = { add_ruler_modifier = { name = civic_republicanism_focus_naval duration = -1 } }
100
+ }
101
+ }
102
+ assign_ruler_focus_rng = {
103
+ trigger_switch = {
104
+ on_trigger = has_country_flag
105
+ RNG_civic_republicanism_focus_government = { add_ruler_modifier = { name = civic_republicanism_focus_government duration = -1 } }
106
+ RNG_civic_republicanism_focus_expansion = { add_ruler_modifier = { name = civic_republicanism_focus_expansion duration = -1 } }
107
+ RNG_civic_republicanism_focus_technology = { add_ruler_modifier = { name = civic_republicanism_focus_technology duration = -1 } }
108
+ RNG_civic_republicanism_focus_stability = { add_ruler_modifier = { name = civic_republicanism_focus_stability duration = -1 } }
109
+ RNG_civic_republicanism_focus_religion = { add_ruler_modifier = { name = civic_republicanism_focus_religion duration = -1 } }
110
+ RNG_civic_republicanism_focus_diplomacy = { add_ruler_modifier = { name = civic_republicanism_focus_diplomacy duration = -1 } }
111
+ RNG_civic_republicanism_focus_court = { add_ruler_modifier = { name = civic_republicanism_focus_court duration = -1 } }
112
+ RNG_civic_republicanism_focus_trade = { add_ruler_modifier = { name = civic_republicanism_focus_trade duration = -1 } }
113
+ RNG_civic_republicanism_focus_subjects = { add_ruler_modifier = { name = civic_republicanism_focus_subjects duration = -1 } }
114
+ RNG_civic_republicanism_focus_development = { add_ruler_modifier = { name = civic_republicanism_focus_development duration = -1 } }
115
+ RNG_civic_republicanism_focus_defensive = { add_ruler_modifier = { name = civic_republicanism_focus_defensive duration = -1 } }
116
+ RNG_civic_republicanism_focus_sieges = { add_ruler_modifier = { name = civic_republicanism_focus_sieges duration = -1 } }
117
+ RNG_civic_republicanism_focus_leaders = { add_ruler_modifier = { name = civic_republicanism_focus_leaders duration = -1 } }
118
+ RNG_civic_republicanism_focus_quality = { add_ruler_modifier = { name = civic_republicanism_focus_quality duration = -1 } }
119
+ RNG_civic_republicanism_focus_naval = { add_ruler_modifier = { name = civic_republicanism_focus_naval duration = -1 } }
120
+ }
121
+ }
122
+
123
+ assign_ruler_focus = {
124
+ assign_ruler_focus_$type$ = yes
125
+ }
126
+ post_ruler_focus_clearance = {
127
+ hidden_effect = {
128
+ clr_country_flag = civic_republicanism_focus_government_flag
129
+ clr_country_flag = civic_republicanism_focus_expansion_flag
130
+ clr_country_flag = civic_republicanism_focus_technology_flag
131
+ clr_country_flag = civic_republicanism_focus_stability_flag
132
+ clr_country_flag = civic_republicanism_focus_religion_flag
133
+ clr_country_flag = civic_republicanism_focus_diplomacy_flag
134
+ clr_country_flag = civic_republicanism_focus_court_flag
135
+ clr_country_flag = civic_republicanism_focus_trade_flag
136
+ clr_country_flag = civic_republicanism_focus_subjects_flag
137
+ clr_country_flag = civic_republicanism_focus_development_flag
138
+ clr_country_flag = civic_republicanism_focus_defensive_flag
139
+ clr_country_flag = civic_republicanism_focus_sieges_flag
140
+ clr_country_flag = civic_republicanism_focus_leaders_flag
141
+ clr_country_flag = civic_republicanism_focus_quality_flag
142
+ clr_country_flag = civic_republicanism_focus_naval_flag
143
+ clr_country_flag = RNG_civic_republicanism_focus_government
144
+ clr_country_flag = RNG_civic_republicanism_focus_expansion
145
+ clr_country_flag = RNG_civic_republicanism_focus_technology
146
+ clr_country_flag = RNG_civic_republicanism_focus_stability
147
+ clr_country_flag = RNG_civic_republicanism_focus_religion
148
+ clr_country_flag = RNG_civic_republicanism_focus_diplomacy
149
+ clr_country_flag = RNG_civic_republicanism_focus_court
150
+ clr_country_flag = RNG_civic_republicanism_focus_trade
151
+ clr_country_flag = RNG_civic_republicanism_focus_subjects
152
+ clr_country_flag = RNG_civic_republicanism_focus_development
153
+ clr_country_flag = RNG_civic_republicanism_focus_defensive
154
+ clr_country_flag = RNG_civic_republicanism_focus_sieges
155
+ clr_country_flag = RNG_civic_republicanism_focus_leaders
156
+ clr_country_flag = RNG_civic_republicanism_focus_quality
157
+ clr_country_flag = RNG_civic_republicanism_focus_naval
158
+ }
159
+ }
160
+ clr_ruler_focus_modifiers = {
161
+ post_ruler_focus_clearance = yes
162
+ if = { limit = { has_country_modifier = civic_republicanism_focus_government } remove_country_modifier = civic_republicanism_focus_government }
163
+ if = { limit = { has_country_modifier = civic_republicanism_focus_expansion } remove_country_modifier = civic_republicanism_focus_expansion }
164
+ if = { limit = { has_country_modifier = civic_republicanism_focus_technology } remove_country_modifier = civic_republicanism_focus_technology }
165
+ if = { limit = { has_country_modifier = civic_republicanism_focus_stability } remove_country_modifier = civic_republicanism_focus_stability }
166
+ if = { limit = { has_country_modifier = civic_republicanism_focus_religion } remove_country_modifier = civic_republicanism_focus_religion }
167
+ if = { limit = { has_country_modifier = civic_republicanism_focus_diplomacy } remove_country_modifier = civic_republicanism_focus_diplomacy }
168
+ if = { limit = { has_country_modifier = civic_republicanism_focus_court } remove_country_modifier = civic_republicanism_focus_court }
169
+ if = { limit = { has_country_modifier = civic_republicanism_focus_trade } remove_country_modifier = civic_republicanism_focus_trade }
170
+ if = { limit = { has_country_modifier = civic_republicanism_focus_subjects } remove_country_modifier = civic_republicanism_focus_subjects }
171
+ if = { limit = { has_country_modifier = civic_republicanism_focus_development } remove_country_modifier = civic_republicanism_focus_development }
172
+ if = { limit = { has_country_modifier = civic_republicanism_focus_defensive } remove_country_modifier = civic_republicanism_focus_defensive }
173
+ if = { limit = { has_country_modifier = civic_republicanism_focus_sieges } remove_country_modifier = civic_republicanism_focus_sieges }
174
+ if = { limit = { has_country_modifier = civic_republicanism_focus_leaders } remove_country_modifier = civic_republicanism_focus_leaders }
175
+ if = { limit = { has_country_modifier = civic_republicanism_focus_quality } remove_country_modifier = civic_republicanism_focus_quality }
176
+ if = { limit = { has_country_modifier = civic_republicanism_focus_naval } remove_country_modifier = civic_republicanism_focus_naval }
177
+ }
178
+
179
+ complete_artwork_effect_architecture = {
180
+ if = {
181
+ limit = { any_owned_province = { has_building = temple } }
182
+ random_owned_province = { limit = { has_building = temple } upgrade_building = { tax = yes } }
183
+ }
184
+ else = {
185
+ random_owned_province = {
186
+ limit = { NOT = { has_building = cathedral } religion = root culture = root }
187
+ add_building = cathedral
188
+ }
189
+ }
190
+ custom_tooltip = DUE_TO_ART_QUALITY_FOLLOWING_EFFECT_HAPPENS_TT
191
+ if = {
192
+ limit = { check_variable = { which = art_quality value = 4 } }
193
+ add_government_power = {
194
+ mechanic_type = persian_influence_mechanic
195
+ power_type = persian_influence
196
+ value = 25
197
+ }
198
+ random_owned_province = {
199
+ limit = { religion = root culture = root }
200
+ add_base_tax = 3
201
+ }
202
+ }
203
+ else_if = {
204
+ limit = { check_variable = { which = art_quality value = 3 } }
205
+ add_government_power = {
206
+ mechanic_type = persian_influence_mechanic
207
+ power_type = persian_influence
208
+ value = 20
209
+ }
210
+ random_owned_province = {
211
+ limit = { religion = root culture = root }
212
+ add_base_tax = 2
213
+ }
214
+ }
215
+ else_if = {
216
+ limit = { check_variable = { which = art_quality value = 2 } }
217
+ add_government_power = {
218
+ mechanic_type = persian_influence_mechanic
219
+ power_type = persian_influence
220
+ value = 15
221
+ }
222
+ random_owned_province = {
223
+ limit = { religion = root culture = root }
224
+ add_base_tax = 1
225
+ }
226
+ }
227
+ else_if = {
228
+ limit = { check_variable = { which = art_quality value = 1 } }
229
+ add_government_power = {
230
+ mechanic_type = persian_influence_mechanic
231
+ power_type = persian_influence
232
+ value = 10
233
+ }
234
+ }
235
+ else = {
236
+ add_prestige = -20
237
+ add_government_power = {
238
+ mechanic_type = persian_influence_mechanic
239
+ power_type = persian_influence
240
+ value = -10
241
+ scaled_with_gain_modifier = no
242
+ }
243
+ }
244
+ }
245
+ complete_artwork_effect_textiles = {
246
+ custom_tooltip = DUE_TO_ART_QUALITY_FOLLOWING_EFFECT_HAPPENS_TT
247
+ if = {
248
+ limit = { check_variable = { which = art_quality value = 4 } }
249
+ add_government_power = {
250
+ mechanic_type = persian_influence_mechanic
251
+ power_type = persian_influence
252
+ value = 25
253
+ }
254
+ add_mercantilism_or_monarch_power = {
255
+ amount = 3
256
+ }
257
+ }
258
+ else_if = {
259
+ limit = { check_variable = { which = art_quality value = 3 } }
260
+ add_government_power = {
261
+ mechanic_type = persian_influence_mechanic
262
+ power_type = persian_influence
263
+ value = 20
264
+ }
265
+ add_mercantilism_or_monarch_power = {
266
+ amount = 2
267
+ }
268
+ }
269
+ else_if = {
270
+ limit = { check_variable = { which = art_quality value = 2 } }
271
+ add_government_power = {
272
+ mechanic_type = persian_influence_mechanic
273
+ power_type = persian_influence
274
+ value = 15
275
+ }
276
+ add_mercantilism_or_monarch_power = {
277
+ amount = 1
278
+ }
279
+ }
280
+ else_if = {
281
+ limit = { check_variable = { which = art_quality value = 1 } }
282
+ add_government_power = {
283
+ mechanic_type = persian_influence_mechanic
284
+ power_type = persian_influence
285
+ value = 10
286
+ }
287
+ }
288
+ else = {
289
+ add_prestige = -20
290
+ add_government_power = {
291
+ mechanic_type = persian_influence_mechanic
292
+ power_type = persian_influence
293
+ value = -10
294
+ scaled_with_gain_modifier = no
295
+ }
296
+ }
297
+ }
298
+ complete_artwork_effect_painting = {
299
+ custom_tooltip = DUE_TO_ART_QUALITY_FOLLOWING_EFFECT_HAPPENS_TT
300
+ if = {
301
+ limit = { check_variable = { which = art_quality value = 4 } }
302
+ add_government_power = {
303
+ mechanic_type = persian_influence_mechanic
304
+ power_type = persian_influence
305
+ value = 25
306
+ }
307
+ add_prestige_or_monarch_power = { amount = 30 }
308
+ }
309
+ else_if = {
310
+ limit = { check_variable = { which = art_quality value = 3 } }
311
+ add_government_power = {
312
+ mechanic_type = persian_influence_mechanic
313
+ power_type = persian_influence
314
+ value = 20
315
+ }
316
+ add_prestige_or_monarch_power = { amount = 20 }
317
+ }
318
+ else_if = {
319
+ limit = { check_variable = { which = art_quality value = 2 } }
320
+ add_government_power = {
321
+ mechanic_type = persian_influence_mechanic
322
+ power_type = persian_influence
323
+ value = 15
324
+ }
325
+ add_prestige_or_monarch_power = { amount = 10 }
326
+ }
327
+ else_if = {
328
+ limit = { check_variable = { which = art_quality value = 1 } }
329
+ add_government_power = {
330
+ mechanic_type = persian_influence_mechanic
331
+ power_type = persian_influence
332
+ value = 10
333
+ }
334
+ }
335
+ else = {
336
+ add_prestige = -20
337
+ add_government_power = {
338
+ mechanic_type = persian_influence_mechanic
339
+ power_type = persian_influence
340
+ value = -10
341
+ scaled_with_gain_modifier = no
342
+ }
343
+ }
344
+ }
345
+ complete_artwork_effect = {
346
+ remove_country_modifier = promoting_$type$
347
+ complete_artwork_effect_$type$ = yes
348
+ if = {
349
+ limit = { has_country_modifier = promoting_art }
350
+ country_event = {
351
+ id = promoting_art_events.1
352
+ }
353
+ }
354
+ hidden_effect = {
355
+ set_variable = {
356
+ which = art_progress
357
+ value = 0
358
+ }
359
+ set_variable = {
360
+ which = art_quality
361
+ value = 1
362
+ }
363
+ }
364
+ }
365
+ change_art_progress = {
366
+ change_variable = {
367
+ which = art_progress
368
+ value = $amount$
369
+ }
370
+ }
371
+ change_art_quality = {
372
+ change_variable = {
373
+ which = art_quality
374
+ value = $amount$
375
+ }
376
+ }
377
+
378
+ used_persian_influence_mechanic = {
379
+ custom_tooltip = used_persian_influence_mechanic_tt
380
+ hidden_effect = {
381
+ if = {
382
+ limit = { NOT = { has_country_flag = persian_influence_setup_flag } }
383
+ set_country_flag = persian_influence_setup_flag
384
+ }
385
+ remove_country_modifier = used_persian_influece_interaction_1
386
+ remove_country_modifier = used_persian_influece_interaction_2
387
+ remove_country_modifier = used_persian_influece_interaction_3
388
+ remove_country_modifier = used_persian_influece_interaction_4
389
+ remove_country_modifier = used_persian_influece_interaction_5
390
+ remove_country_modifier = used_persian_influece_interaction_6
391
+ remove_country_modifier = used_persian_influece_interaction_7
392
+ remove_country_modifier = used_persian_influece_interaction_8
393
+ remove_country_modifier = used_persian_influece_interaction_9
394
+ remove_country_modifier = used_persian_influece_interaction_10
395
+ remove_country_modifier = used_persian_influece_interaction_11
396
+ remove_country_modifier = used_persian_influece_interaction_12
397
+ remove_country_modifier = used_persian_influece_interaction_13
398
+ remove_country_modifier = used_persian_influece_interaction_14
399
+ remove_country_modifier = used_persian_influece_interaction_15
400
+ remove_country_modifier = used_persian_influece_interaction_16
401
+ remove_country_modifier = used_persian_influece_interaction_17
402
+ remove_country_modifier = used_persian_influece_interaction_18
403
+ remove_country_modifier = used_persian_influece_interaction_19
404
+ remove_country_modifier = used_persian_influece_interaction_20
405
+ change_variable = {
406
+ which = persian_influece_counter
407
+ value = 1
408
+ }
409
+ if = {
410
+ limit = { has_country_flag = improved_elevation_reduction }
411
+ if = {
412
+ limit = { check_variable = { which = persian_influece_counter_tooltip value = -400 } }
413
+ change_variable = {
414
+ which = persian_influece_counter_tooltip
415
+ value = -20
416
+ }
417
+ }
418
+ }
419
+ else = {
420
+ if = {
421
+ limit = { check_variable = { which = persian_influece_counter_tooltip value = -200 } }
422
+ change_variable = {
423
+ which = persian_influece_counter_tooltip
424
+ value = -20
425
+ }
426
+ }
427
+ }
428
+ change_variable = {
429
+ which = persian_influence_interaction_counter
430
+ value = 1
431
+ }
432
+ if = {
433
+ limit = { has_country_flag = improved_elevation_reduction }
434
+ if = {
435
+ limit = { check_variable = { which = persian_influece_counter value = 10 } }
436
+ if = {
437
+ limit = { check_variable = { which = persian_influece_counter value = 15 } }
438
+ if = {
439
+ limit = { check_variable = { which = persian_influece_counter value = 17 } }
440
+ if = {
441
+ limit = { check_variable = { which = persian_influece_counter value = 19 } }
442
+ if = {
443
+ limit = { check_variable = { which = persian_influece_counter value = 20 } }
444
+ add_country_modifier = { name = used_persian_influece_interaction_20 duration = -1 hidden = yes }
445
+ }
446
+ else = {
447
+ add_country_modifier = { name = used_persian_influece_interaction_19 duration = -1 hidden = yes }
448
+ }
449
+ }
450
+ else = {
451
+ if = {
452
+ limit = { check_variable = { which = persian_influece_counter value = 18 } }
453
+ add_country_modifier = { name = used_persian_influece_interaction_18 duration = -1 hidden = yes }
454
+ }
455
+ else = {
456
+ add_country_modifier = { name = used_persian_influece_interaction_17 duration = -1 hidden = yes }
457
+ }
458
+ }
459
+ }
460
+ else = {
461
+ if = {
462
+ limit = { check_variable = { which = persian_influece_counter value = 16 } }
463
+ add_country_modifier = { name = used_persian_influece_interaction_16 duration = -1 hidden = yes }
464
+ }
465
+ else = {
466
+ add_country_modifier = { name = used_persian_influece_interaction_15 duration = -1 hidden = yes }
467
+ }
468
+ }
469
+ }
470
+ else = {
471
+ if = {
472
+ limit = { check_variable = { which = persian_influece_counter value = 13 } }
473
+ if = {
474
+ limit = { check_variable = { which = persian_influece_counter value = 14 } }
475
+ add_country_modifier = { name = used_persian_influece_interaction_14 duration = -1 hidden = yes }
476
+ }
477
+ else = {
478
+ add_country_modifier = { name = used_persian_influece_interaction_13 duration = -1 hidden = yes }
479
+ }
480
+ }
481
+ else = {
482
+ if = {
483
+ limit = { check_variable = { which = persian_influece_counter value = 11 } }
484
+ if = {
485
+ limit = { check_variable = { which = persian_influece_counter value = 12 } }
486
+ add_country_modifier = { name = used_persian_influece_interaction_12 duration = -1 hidden = yes }
487
+ }
488
+ else = {
489
+ add_country_modifier = { name = used_persian_influece_interaction_11 duration = -1 hidden = yes }
490
+ }
491
+ }
492
+ else = {
493
+ add_country_modifier = { name = used_persian_influece_interaction_10 duration = -1 hidden = yes }
494
+ }
495
+ }
496
+ }
497
+ }
498
+ else = {
499
+ if = {
500
+ limit = { check_variable = { which = persian_influece_counter value = 5 } }
501
+ if = {
502
+ limit = { check_variable = { which = persian_influece_counter value = 8 } }
503
+ if = {
504
+ limit = { check_variable = { which = persian_influece_counter value = 9 } }
505
+ add_country_modifier = { name = used_persian_influece_interaction_9 duration = -1 hidden = yes }
506
+ }
507
+ else = {
508
+ add_country_modifier = { name = used_persian_influece_interaction_8 duration = -1 hidden = yes }
509
+ }
510
+ }
511
+ else = {
512
+ if = {
513
+ limit = { check_variable = { which = persian_influece_counter value = 6 } }
514
+ if = {
515
+ limit = { check_variable = { which = persian_influece_counter value = 7 } }
516
+ add_country_modifier = { name = used_persian_influece_interaction_7 duration = -1 hidden = yes }
517
+ }
518
+ else = {
519
+ add_country_modifier = { name = used_persian_influece_interaction_6 duration = -1 hidden = yes }
520
+ }
521
+ }
522
+ else = {
523
+ add_country_modifier = { name = used_persian_influece_interaction_5 duration = -1 hidden = yes }
524
+ }
525
+ }
526
+ }
527
+ else = {
528
+ if = {
529
+ limit = { check_variable = { which = persian_influece_counter value = 3 } }
530
+ if = {
531
+ limit = { check_variable = { which = persian_influece_counter value = 4 } }
532
+ add_country_modifier = { name = used_persian_influece_interaction_4 duration = -1 hidden = yes }
533
+ }
534
+ add_country_modifier = { name = used_persian_influece_interaction_3 duration = -1 hidden = yes }
535
+ }
536
+ else = {
537
+ if = {
538
+ limit = { check_variable = { which = persian_influece_counter value = 2 } }
539
+ add_country_modifier = { name = used_persian_influece_interaction_2 duration = -1 hidden = yes }
540
+ }
541
+ else = {
542
+ add_country_modifier = { name = used_persian_influece_interaction_1 duration = -1 hidden = yes }
543
+ }
544
+ }
545
+ }
546
+ }
547
+ }
548
+ else = {
549
+ if = {
550
+ limit = { check_variable = { which = persian_influece_counter value = 5 } }
551
+ if = {
552
+ limit = { check_variable = { which = persian_influece_counter value = 7 } }
553
+ if = {
554
+ limit = { check_variable = { which = persian_influece_counter value = 9 } }
555
+ if = {
556
+ limit = { check_variable = { which = persian_influece_counter value = 10 } }
557
+ add_country_modifier = { name = used_persian_influece_interaction_10 duration = -1 hidden = yes }
558
+ }
559
+ else = {
560
+ add_country_modifier = { name = used_persian_influece_interaction_9 duration = -1 hidden = yes }
561
+ }
562
+ }
563
+ else = {
564
+ if = {
565
+ limit = { check_variable = { which = persian_influece_counter value = 8 } }
566
+ add_country_modifier = { name = used_persian_influece_interaction_8 duration = -1 hidden = yes }
567
+ }
568
+ else = {
569
+ add_country_modifier = { name = used_persian_influece_interaction_7 duration = -1 hidden = yes }
570
+ }
571
+ }
572
+ }
573
+ else = {
574
+ if = {
575
+ limit = { check_variable = { which = persian_influece_counter value = 6 } }
576
+ add_country_modifier = { name = used_persian_influece_interaction_6 duration = -1 hidden = yes }
577
+ }
578
+ else = {
579
+ add_country_modifier = { name = used_persian_influece_interaction_5 duration = -1 hidden = yes }
580
+ }
581
+ }
582
+ }
583
+ else = {
584
+ if = {
585
+ limit = { check_variable = { which = persian_influece_counter value = 3 } }
586
+ if = {
587
+ limit = { check_variable = { which = persian_influece_counter value = 4 } }
588
+ add_country_modifier = { name = used_persian_influece_interaction_4 duration = -1 hidden = yes }
589
+ }
590
+ add_country_modifier = { name = used_persian_influece_interaction_3 duration = -1 hidden = yes }
591
+ }
592
+ else = {
593
+ if = {
594
+ limit = { check_variable = { which = persian_influece_counter value = 2 } }
595
+ add_country_modifier = { name = used_persian_influece_interaction_2 duration = -1 hidden = yes }
596
+ }
597
+ else = {
598
+ add_country_modifier = { name = used_persian_influece_interaction_1 duration = -1 hidden = yes }
599
+ }
600
+ }
601
+ }
602
+ }
603
+ }
604
+ }
605
+
606
+ improve_elevation_effect = {
607
+ custom_tooltip = improve_elevation_effect_tt
608
+ hidden_effect = {
609
+ set_country_flag = improved_elevation_effect
610
+ }
611
+ }
612
+
613
+ improve_elevation_reduction = {
614
+ custom_tooltip = improve_elevation_reduction_tt
615
+ hidden_effect = {
616
+ set_country_flag = improved_elevation_reduction
617
+ }
618
+ }
619
+
620
+ improve_persian_influence_abilities = {
621
+ custom_tooltip = improve_persian_influence_abilities_tt
622
+ hidden_effect = {
623
+ set_country_flag = improved_persian_influence_abilities
624
+ }
625
+ }
626
+
627
+ improve_fabricate_religious_conflict = {
628
+ custom_tooltip = improve_fabricate_religious_conflict_tt
629
+ hidden_effect = {
630
+ set_country_flag = reduced_spread_faith_cb_spy_cost
631
+ }
632
+ }
633
+
634
+ consume_persian_influence_reduction = {
635
+ remove_country_modifier = used_persian_influece_interaction_1
636
+ remove_country_modifier = used_persian_influece_interaction_2
637
+ remove_country_modifier = used_persian_influece_interaction_3
638
+ remove_country_modifier = used_persian_influece_interaction_4
639
+ remove_country_modifier = used_persian_influece_interaction_5
640
+ remove_country_modifier = used_persian_influece_interaction_6
641
+ remove_country_modifier = used_persian_influece_interaction_7
642
+ remove_country_modifier = used_persian_influece_interaction_8
643
+ remove_country_modifier = used_persian_influece_interaction_9
644
+ remove_country_modifier = used_persian_influece_interaction_10
645
+ remove_country_modifier = used_persian_influece_interaction_11
646
+ remove_country_modifier = used_persian_influece_interaction_12
647
+ remove_country_modifier = used_persian_influece_interaction_13
648
+ remove_country_modifier = used_persian_influece_interaction_14
649
+ remove_country_modifier = used_persian_influece_interaction_15
650
+ remove_country_modifier = used_persian_influece_interaction_16
651
+ remove_country_modifier = used_persian_influece_interaction_17
652
+ remove_country_modifier = used_persian_influece_interaction_18
653
+ remove_country_modifier = used_persian_influece_interaction_19
654
+ remove_country_modifier = used_persian_influece_interaction_20
655
+ change_variable = {
656
+ which = persian_influece_counter
657
+ value = 0
658
+ }
659
+ change_variable = {
660
+ which = persian_influece_counter_tooltip
661
+ value = 0
662
+ }
663
+ }
664
+
665
+ change_asha_vahishta = {
666
+ if = {
667
+ limit = { has_government_mechanic = the_three_royal_fires_mechanic }
668
+ [[custom_tooltip]custom_tooltip = $custom_tooltip$]
669
+ add_government_power = {
670
+ mechanic_type = the_three_royal_fires_mechanic
671
+ power_type = asha_vahishta
672
+ value = $value$
673
+ }
674
+ }
675
+ }
676
+
677
+ remove_asha_vahishta_loss_from_missionaries = {
678
+ custom_tooltip = remove_asha_vahishta_loss_from_missionaries_tt
679
+ hidden_effect = {
680
+ set_country_flag = removed_asha_vahishta_loss_from_missionaries
681
+ }
682
+ }
683
+
684
+ upgrade_the_three_fire = {
685
+ custom_tooltip = upgrade_the_three_fire_tt
686
+ hidden_effect = {
687
+ set_country_flag = upgraded_the_three_fire
688
+ }
689
+ }
690
+
691
+ remove_asha_vahishta_loss_from_force_conversion = {
692
+ custom_tooltip = remove_asha_vahishta_loss_from_force_conversion_tt
693
+ hidden_effect = {
694
+ set_country_flag = removed_asha_vahishta_loss_from_force_conversion
695
+ }
696
+ }
697
+
698
+ enable_three_royal_fires_mana_generation = {
699
+ custom_tooltip = enable_three_royal_fires_mana_generation_tt
700
+ hidden_effect = {
701
+ set_country_flag = enabled_three_royal_fires_mana_generation
702
+ }
703
+ }
common/scripted_effects/01_scripted_effects_for_on_actions.txt CHANGED
@@ -177,6 +177,15 @@ initialize_schools_effect = { #Used in on_startup on_action
177
177
  }
178
178
 
179
179
  on_new_monarch_effect = {
180
+ if = {
181
+ limit = {
182
+ has_government_attribute = orangist_cause
183
+ }
184
+ set_variable = {
185
+ which = NEDOrangistCauseVar
186
+ value = 0
187
+ }
188
+ }
180
189
  if = {
181
190
  limit = {
182
191
  has_consort_regency = no
@@ -1218,59 +1227,13 @@ burgundian_inheritance_start_effect = {
1218
1227
  tag = BUR
1219
1228
  has_country_modifier = burgundian_succession_crisis
1220
1229
  NOT = { has_country_flag = burgundian_succession_has_already_fired }
1221
- NOT = {
1222
- BUR = {
1223
- is_subject = yes
1224
- }
1225
- }
1230
+ is_subject = no
1231
+ is_lesser_in_union = no
1226
1232
  }
1227
- set_country_flag = burgundian_succession_has_already_fired
1228
- remove_country_modifier = burgundian_succession_crisis
1229
- set_country_flag = charles_died
1230
- if = {
1231
- limit = {
1232
- is_emperor = no
1233
- OR = {
1234
- AND = { #succession should not fire if Burgundy has a suitable male heir
1235
- has_regency = yes
1236
- OR = {
1237
- has_heir = no
1238
- NOT = {
1239
- heir_age = 15
1240
- }
1241
- NOT = { heir_claim = 51 }
1242
- }
1243
- }
1244
- NOT = { legitimacy = 40 } #medium to weak claimants should not be good enough
1245
- has_ruler_flag = mary_is_heir
1246
- has_heir_flag = mary_is_heir
1247
- }
1248
- }
1249
- if = { #if Mary was defined as heir proper, she gains some legitimacy
1250
- limit = {
1251
- OR = {
1252
- has_ruler_flag = mary_is_heir
1253
- has_heir_flag = mary_is_heir
1254
- }
1255
- }
1256
- add_legitimacy = 10
1257
- }
1258
- else = { #if she was not named heir, she becomes ruler here
1259
- define_ruler = {
1260
- name = "Marie"
1261
- dynasty = "de Bourgogne"
1262
- age = 21
1263
- adm = 4
1264
- dip = 5
1265
- mil = 3
1266
- claim = 50
1267
- female = yes
1268
- }
1269
- set_ruler_flag = mary_is_heir
1270
- }
1271
- country_event = {
1272
- id = incidents_bur_inheritance.1
1273
- }
1233
+ #Fire an event which checks on the current state of Burgundy to see if they are already in a normal PU or not
1234
+ country_event = {
1235
+ id = incidents_bur_inheritance.1000
1236
+ days = 1
1274
1237
  }
1275
1238
  }
1276
1239
  else_if = {
@@ -1288,6 +1251,14 @@ burgundian_inheritance_start_effect = {
1288
1251
  hidden = yes
1289
1252
  }
1290
1253
  }
1254
+ #Burgundian marriage cleaner
1255
+ if = {
1256
+ limit = { tag = BUR }
1257
+ country_event = {
1258
+ id = incidents_bur_inheritance.1001
1259
+ days = 3
1260
+ }
1261
+ }
1291
1262
  }
1292
1263
 
1293
1264
  joan_de_trastamara_king_died_effect = {
@@ -1367,6 +1338,34 @@ on_province_owner_change_government_effect = {
1367
1338
  }
1368
1339
  }
1369
1340
  }
1341
+ if = {
1342
+ limit = {
1343
+ trade_goods = paper
1344
+ owner = {
1345
+ has_government_attribute = GER_buff_paper_provinces
1346
+ }
1347
+ }
1348
+ add_province_modifier = {
1349
+ name = GER_paper_provinces_franconian
1350
+ duration = -1
1351
+ }
1352
+ }
1353
+ if = {
1354
+ limit = {
1355
+ OR = {
1356
+ trade_goods = iron
1357
+ trade_goods = copper
1358
+ trade_goods = gold
1359
+ }
1360
+ owner = {
1361
+ has_government_attribute = GER_buff_mining_provinces
1362
+ }
1363
+ }
1364
+ add_province_modifier = {
1365
+ name = GER_mining_provinces_saxon
1366
+ duration = -1
1367
+ }
1368
+ }
1370
1369
  if = {
1371
1370
  limit = {
1372
1371
  has_province_modifier = grain_vodka_bonus_prod
@@ -1535,6 +1534,13 @@ on_province_owner_change_government_effect = {
1535
1534
  duration = -1
1536
1535
  }
1537
1536
  }
1537
+ if = {
1538
+ limit = {
1539
+ has_owner_culture = yes
1540
+ owner = { has_government_attribute = can_recruit_banners_from_primary_culture_provinces }
1541
+ }
1542
+ add_province_modifier = { name = mongol_banners_location duration = -1 hidden = yes }
1543
+ }
1538
1544
  }
1539
1545
 
1540
1546
  on_province_religion_changed_effect = {
@@ -1726,6 +1732,48 @@ on_trade_good_changed_government_effect = {
1726
1732
  remove_province_modifier = wine_bonus_prod
1727
1733
  remove_province_modifier = grain_bonus_prod
1728
1734
  }
1735
+ if = {
1736
+ limit = {
1737
+ owner = {
1738
+ has_government_attribute = GER_buff_paper_provinces
1739
+ }
1740
+ }
1741
+ if = {
1742
+ limit = {
1743
+ trade_goods = paper
1744
+ }
1745
+ add_province_modifier = {
1746
+ name = GER_paper_provinces_franconian
1747
+ duration = -1
1748
+ }
1749
+ }
1750
+ else = {
1751
+ remove_province_modifier = GER_paper_provinces_franconian
1752
+ }
1753
+ }
1754
+ if = {
1755
+ limit = {
1756
+ owner = {
1757
+ has_government_attribute = GER_buff_mining_provinces
1758
+ }
1759
+ }
1760
+ if = {
1761
+ limit = {
1762
+ OR = {
1763
+ trade_goods = iron
1764
+ trade_goods = copper
1765
+ trade_goods = gold
1766
+ }
1767
+ }
1768
+ add_province_modifier = {
1769
+ name = GER_mining_provinces_saxon
1770
+ duration = -1
1771
+ }
1772
+ }
1773
+ else = {
1774
+ remove_province_modifier = GER_mining_provinces_saxon
1775
+ }
1776
+ }
1729
1777
  if = {
1730
1778
  limit = { owner = { has_government_attribute = extra_trade_goods_from_grain } }
1731
1779
  if = {
@@ -1788,6 +1836,61 @@ on_trade_good_changed_government_effect = {
1788
1836
  }
1789
1837
 
1790
1838
  on_battle_won_unit_effect = {
1839
+ if = {
1840
+ limit = {
1841
+ unit_owner = {
1842
+ has_government_mechanic = divine_authority_mechanic
1843
+ }
1844
+ is_ruler_commanding_unit = yes
1845
+ }
1846
+ unit_owner = {
1847
+ set_variable = {
1848
+ which = monarch_kill
1849
+ which = land_units_killed
1850
+ }
1851
+ while = {
1852
+ limit = {
1853
+ check_variable = {
1854
+ which = monarch_kill
1855
+ value = 100
1856
+ }
1857
+ }
1858
+ change_variable = {
1859
+ which = monarch_kill
1860
+ value = -100
1861
+ }
1862
+ add_government_power = {
1863
+ mechanic_type = divine_authority_mechanic
1864
+ power_type = divine_authority
1865
+ value = 0.01
1866
+ }
1867
+ }
1868
+ }
1869
+ }
1870
+ if = {
1871
+ limit = {
1872
+ unit_owner = {
1873
+ has_government_attribute = orangist_cause
1874
+ is_orangists_in_power = yes
1875
+ }
1876
+ is_ruler_commanding_unit = yes
1877
+ }
1878
+ unit_owner = {
1879
+ change_variable = {
1880
+ which = NEDOrangistCauseVar
1881
+ value = 1
1882
+ }
1883
+ if = {
1884
+ limit = {
1885
+ check_variable = {
1886
+ which = NEDOrangistCauseVar
1887
+ value = 25
1888
+ }
1889
+ }
1890
+ add_ruler_personality = orangist_stadholder_personality
1891
+ }
1892
+ }
1893
+ }
1791
1894
  if = {
1792
1895
  limit = {
1793
1896
  unit_owner = {
@@ -1867,6 +1970,46 @@ on_battle_won_unit_effect = {
1867
1970
  }
1868
1971
 
1869
1972
  on_battle_lost_unit_effect = {
1973
+ if = {
1974
+ limit = {
1975
+ unit_owner = {
1976
+ has_government_mechanic = divine_authority_mechanic
1977
+ }
1978
+ is_ruler_commanding_unit = yes
1979
+ }
1980
+ unit_owner = {
1981
+ set_variable = {
1982
+ which = monarch_kill
1983
+ which = land_units_killed
1984
+ }
1985
+ while = {
1986
+ limit = {
1987
+ check_variable = {
1988
+ which = monarch_kill
1989
+ value = 100
1990
+ }
1991
+ }
1992
+ change_variable = {
1993
+ which = monarch_kill
1994
+ value = -100
1995
+ }
1996
+ add_government_power = {
1997
+ mechanic_type = divine_authority_mechanic
1998
+ power_type = divine_authority
1999
+ value = 0.01
2000
+ }
2001
+ }
2002
+ }
2003
+ }
2004
+ if = {
2005
+ limit = {
2006
+ unit_owner = {
2007
+ has_government_attribute = orangist_cause
2008
+ is_orangists_in_power = yes
2009
+ }
2010
+ is_ruler_commanding_unit = yes
2011
+ }
2012
+ }
1870
2013
  if = {
1871
2014
  limit = {
1872
2015
  unit_owner = {
@@ -1946,6 +2089,52 @@ on_battle_lost_unit_effect = {
1946
2089
  }
1947
2090
 
1948
2091
  on_battle_won_country_effect = {
2092
+ if = {
2093
+ limit = {
2094
+ has_dlc = "Winds of Change"
2095
+ OR = {
2096
+ tag = BOH
2097
+ was_tag = BOH
2098
+ }
2099
+ has_mission = boh_bozi_bojovnici
2100
+ NOT = {
2101
+ mission_completed = boh_bozi_bojovnici
2102
+ }
2103
+ }
2104
+ change_variable = { which = bohemia_num_of_won_battles value = 1 }
2105
+ }
2106
+ if = {
2107
+ limit = {
2108
+ has_dlc = "Winds of Change"
2109
+ OR = {
2110
+ tag = BOH
2111
+ was_tag = BOH
2112
+ }
2113
+ has_mission = boh_shield_of_the_true_faith
2114
+ NOT = {
2115
+ mission_completed = boh_shield_of_the_true_faith
2116
+ }
2117
+ FROM = {
2118
+ NOT = {
2119
+ religion = ROOT
2120
+ }
2121
+ }
2122
+ }
2123
+ change_variable = { which = bohemia_num_of_won_battles_against_heretic_heathen value = 1 }
2124
+ }
2125
+ change_variable = {
2126
+ which = num_of_battles_won_var
2127
+ value = 1
2128
+ }
2129
+ if = {
2130
+ limit = {
2131
+ tag = NED
2132
+ }
2133
+ change_variable = {
2134
+ which = NEDBattlesWon
2135
+ value = 1
2136
+ }
2137
+ }
1949
2138
  if = {
1950
2139
  limit = {
1951
2140
  ROOT = {
@@ -2002,6 +2191,55 @@ on_battle_won_country_effect = {
2002
2191
  }
2003
2192
  }
2004
2193
  }
2194
+ if = {
2195
+ limit = {
2196
+ ROOT = {
2197
+ tag = ALB
2198
+ NOT = { has_country_flag = albanian_victory }
2199
+ }
2200
+ FROM = {
2201
+ tag = TUR
2202
+ }
2203
+ }
2204
+ ROOT = { set_country_flag = albanian_victory }
2205
+ }
2206
+ count_won_battles_and_reward_at_end = {
2207
+ counting_flag = teu_crusader_battle_counter
2208
+ max_value = 20
2209
+ effect = "
2210
+ country_event = {
2211
+ id = flavor_teu.12
2212
+ }
2213
+ "
2214
+ }
2215
+ count_won_battles_and_reward_at_end = {
2216
+ counting_flag = has_rus_kill_counter
2217
+ max_value = 40
2218
+ effect = "set_country_flag = rus_finished_kill_mission"
2219
+ }
2220
+ if = {
2221
+ limit = {
2222
+ has_country_modifier = geo_bane_khagan
2223
+ FROM = {
2224
+ has_reform = steppe_horde
2225
+ }
2226
+ }
2227
+ add_army_tradition = 0.5
2228
+ }
2229
+ if = {
2230
+ limit = {
2231
+ ROOT = {
2232
+ has_country_modifier = turkoman_triumphant_conquest
2233
+ }
2234
+ FROM = {
2235
+ tag = TIM
2236
+ }
2237
+ }
2238
+ random_list = {
2239
+ 20 = { ROOT = { add_manpower = 2 } }
2240
+ 80 = { }
2241
+ }
2242
+ }
2005
2243
  }
2006
2244
 
2007
2245
  on_battle_ended_effect = {
@@ -2261,84 +2499,91 @@ judaism_on_religion_change_effect = {
2261
2499
  }
2262
2500
  }
2263
2501
 
2264
- on_culture_demoted_effect_free_slot_removal = {
2265
- if = {
2266
- limit = {
2267
- has_country_modifier = free_slot_for_$culture$
2268
- NOT = { accepted_culture = $culture$ }
2269
- NOT = { primary_culture = $culture$ }
2270
- }
2271
- remove_country_modifier = free_slot_for_$culture$
2272
- }
2273
- }
2274
-
2275
- on_culture_demoted_effect_remove_all_free_slots = {
2276
- on_culture_demoted_effect_free_slot_removal = { culture = armenian }
2277
- on_culture_demoted_effect_free_slot_removal = { culture = georgian }
2278
- on_culture_demoted_effect_free_slot_removal = { culture = turkish }
2279
- on_culture_demoted_effect_free_slot_removal = { culture = al_iraqiya_arabic }
2280
- on_culture_demoted_effect_free_slot_removal = { culture = al_suryah_arabic }
2281
- }
2502
+ #on_culture_demoted_effect_free_slot_removal = {
2503
+ # if = {
2504
+ # limit = {
2505
+ # has_country_modifier = free_slot_for_$culture$
2506
+ # NOT = { accepted_culture = $culture$ }
2507
+ # NOT = { primary_culture = $culture$ }
2508
+ # }
2509
+ # remove_country_modifier = free_slot_for_$culture$
2510
+ # }
2511
+ #}
2512
+ #
2513
+ #on_culture_demoted_effect_remove_all_free_slots = {
2514
+ # on_culture_demoted_effect_free_slot_removal = { culture = armenian }
2515
+ # on_culture_demoted_effect_free_slot_removal = { culture = georgian }
2516
+ # on_culture_demoted_effect_free_slot_removal = { culture = turkish }
2517
+ # on_culture_demoted_effect_free_slot_removal = { culture = al_iraqiya_arabic }
2518
+ # on_culture_demoted_effect_free_slot_removal = { culture = al_suryah_arabic }
2519
+ # on_culture_demoted_effect_free_slot_removal = { culture = occitain }
2520
+ #}
2282
2521
 
2283
2522
  #Country effect
2284
2523
  on_culture_demoted_effect = {
2524
+ #if = {
2525
+ # limit = {
2526
+ # has_country_flag = boh_czechoslovak_brotherhood_flag
2527
+ # NOT = {
2528
+ # accepted_culture = slovak
2529
+ # }
2530
+ # has_country_modifier = boh_czechoslovak_brotherhood
2531
+ # }
2532
+ # remove_country_modifier = boh_czechoslovak_brotherhood
2533
+ #}
2534
+ #if = {
2535
+ # limit = {
2536
+ # has_country_flag = hun_polish_culture_bonus
2537
+ # NOT = {
2538
+ # accepted_culture = polish
2539
+ # }
2540
+ # has_country_modifier = hun_polish_brotherhood
2541
+ # }
2542
+ # remove_country_modifier = hun_polish_brotherhood
2543
+ #}
2544
+ #if = {
2545
+ # limit = {
2546
+ # has_country_modifier = plc_polish_lithuanian_union
2547
+ # OR = {
2548
+ # AND = {
2549
+ # primary_culture = polish
2550
+ # NOT = { accepted_culture = lithuanian }
2551
+ # }
2552
+ # AND = {
2553
+ # primary_culture = lithuanian
2554
+ # NOT = { accepted_culture = polish }
2555
+ # }
2556
+ # AND = {
2557
+ # OR = {
2558
+ # NOT = { accepted_culture = lithuanian }
2559
+ # NOT = { accepted_culture = polish }
2560
+ # }
2561
+ # NOT = { primary_culture = polish }
2562
+ # NOT = { primary_culture = lithuanian }
2563
+ # }
2564
+ # }
2565
+ # }
2566
+ # remove_country_modifier = plc_polish_lithuanian_union
2567
+ #}
2568
+ #if = {
2569
+ # limit = {
2570
+ # has_country_modifier = teu_pru_integration_of_the_poles
2571
+ # NOT = { accepted_culture = polish }
2572
+ # NOT = { primary_culture = polish }
2573
+ # }
2574
+ # remove_country_modifier = teu_pru_integration_of_the_poles
2575
+ #}
2576
+ #if = {
2577
+ # limit = {
2578
+ # has_country_modifier = teu_pru_integration_of_the_ruthenians
2579
+ # NOT = { accepted_culture = polish }
2580
+ # NOT = { primary_culture = polish }
2581
+ # }
2582
+ # remove_country_modifier = teu_pru_integration_of_the_ruthenians
2583
+ #}
2285
2584
  if = {
2286
2585
  limit = {
2287
- has_country_modifier = plc_polish_lithuanian_union
2288
- OR = {
2289
- AND = {
2290
- primary_culture = polish
2291
- NOT = { accepted_culture = lithuanian }
2292
- }
2293
- AND = {
2294
- primary_culture = lithuanian
2295
- NOT = { accepted_culture = polish }
2296
- }
2297
- AND = {
2298
- OR = {
2299
- NOT = { accepted_culture = lithuanian }
2300
- NOT = { accepted_culture = polish }
2301
- }
2302
- NOT = { primary_culture = polish }
2303
- NOT = { primary_culture = lithuanian }
2304
- }
2305
- }
2306
- }
2307
- remove_country_modifier = plc_polish_lithuanian_union
2308
- }
2309
- if = {
2310
- limit = {
2311
- has_country_modifier = teu_pru_integration_of_the_poles
2312
- NOT = { accepted_culture = polish }
2313
- NOT = { primary_culture = polish }
2314
- }
2315
- remove_country_modifier = teu_pru_integration_of_the_poles
2316
- }
2317
- if = {
2318
- limit = {
2319
- has_country_modifier = teu_pru_integration_of_the_ruthenians
2320
- NOT = { accepted_culture = polish }
2321
- NOT = { primary_culture = polish }
2322
- }
2323
- remove_country_modifier = teu_pru_integration_of_the_ruthenians
2324
- }
2325
- if = {
2326
- limit = {
2327
- has_country_modifier = dan_estonian_culture_accepted
2328
- NOT = { accepted_culture = estonian }
2329
- NOT = { primary_culture = estonian }
2330
- }
2331
- remove_country_modifier = dan_estonian_culture_accepted
2332
- every_owned_province = {
2333
- limit = {
2334
- has_province_modifier = dan_estonian_support
2335
- }
2336
- remove_province_modifier = dan_estonian_support
2337
- }
2338
- }
2339
- if = {
2340
- limit = {
2341
- has_country_modifier = tur_legitimate_roman_empire_modifier
2586
+ has_country_modifier = tur_legitimate_roman_empire_modifier
2342
2587
  OR = {
2343
2588
  NOT = { accepted_culture = lombard }
2344
2589
  NOT = { accepted_culture = tuscan }
@@ -2462,6 +2707,35 @@ on_culture_demoted_effect = {
2462
2707
  }
2463
2708
  remove_country_modifier = turkmen_turkic_union
2464
2709
  }
2710
+ if = {
2711
+ limit = {
2712
+ has_country_modifier = feo_russian_tolerance
2713
+ NOT = {
2714
+ accepted_culture = russian
2715
+ accepted_culture = novgorodian
2716
+ accepted_culture = ryazanian
2717
+ accepted_culture = byelorussian
2718
+ accepted_culture = ruthenian
2719
+ }
2720
+ }
2721
+ remove_country_modifier = feo_russian_tolerance
2722
+ }
2723
+ if = {
2724
+ limit = {
2725
+ has_government_attribute = negate_unaccepted_levantine_culture
2726
+ }
2727
+ every_owned_province = {
2728
+ limit = {
2729
+ culture_group = turko_semitic
2730
+ has_owner_accepted_culture = no
2731
+ NOT = { has_province_modifier = hsn_ayyubid_tolerance }
2732
+ }
2733
+ add_province_modifier = {
2734
+ name = hsn_ayyubid_tolerance
2735
+ duration = -1
2736
+ }
2737
+ }
2738
+ }
2465
2739
  }
2466
2740
 
2467
2741
  #Country effect
@@ -2504,6 +2778,19 @@ judaism_on_culture_country_effect = {
2504
2778
  }
2505
2779
  }
2506
2780
  }
2781
+ if = {
2782
+ limit = {
2783
+ has_government_attribute = negate_unaccepted_levantine_culture
2784
+ }
2785
+ every_owned_province = {
2786
+ limit = {
2787
+ culture_group = turko_semitic
2788
+ has_owner_accepted_culture = yes
2789
+ has_province_modifier = hsn_ayyubid_tolerance
2790
+ }
2791
+ remove_province_modifier = hsn_ayyubid_tolerance
2792
+ }
2793
+ }
2507
2794
  }
2508
2795
 
2509
2796
  #Province effect
@@ -2796,6 +3083,34 @@ remove_all_age_of_discovery_modifiers = {
2796
3083
  limit = { has_country_modifier = YEM_rise_of_yemen }
2797
3084
  remove_country_modifier = YEM_rise_of_yemen
2798
3085
  }
3086
+ if = {
3087
+ limit = { has_country_modifier = INC_bowmen_from_the_jungle }
3088
+ remove_country_modifier = INC_bowmen_from_the_jungle
3089
+ }
3090
+ if = {
3091
+ limit = { has_country_modifier = MAY_religion_reformed }
3092
+ remove_country_modifier = MAY_religion_reformed
3093
+ }
3094
+ if = {
3095
+ limit = { has_country_modifier = MAY_mayan_canoes }
3096
+ remove_country_modifier = MAY_mayan_canoes
3097
+ }
3098
+ if = {
3099
+ limit = { has_country_modifier = MUG_gunpowder_pioneers }
3100
+ remove_country_modifier = MUG_gunpowder_pioneers
3101
+ }
3102
+ if = {
3103
+ limit = { has_country_modifier = MUG_heir_of_timur }
3104
+ remove_country_modifier = MUG_heir_of_timur
3105
+ }
3106
+ if = {
3107
+ limit = { has_country_modifier = TIM_timurid_empire_modifier }
3108
+ remove_country_modifier = TIM_timurid_empire_modifier
3109
+ }
3110
+ if = {
3111
+ limit = { has_country_modifier = hab_onwards_for_glory }
3112
+ remove_country_modifier = hab_onwards_for_glory
3113
+ }
2799
3114
  }
2800
3115
  }
2801
3116
  remove_all_age_of_reformation_modifiers = {
@@ -2839,15 +3154,71 @@ remove_all_age_of_reformation_modifiers = {
2839
3154
  limit = { has_country_modifier = BYZ_roman_vigour }
2840
3155
  remove_country_modifier = BYZ_roman_vigour
2841
3156
  }
3157
+ if = {
3158
+ limit = { has_country_modifier = ITA_latin_tiara }
3159
+ remove_country_modifier = ITA_latin_tiara
3160
+ }
3161
+ if = {
3162
+ limit = { has_country_modifier = ITA_triumph_for_hispaniae }
3163
+ remove_country_modifier = ITA_triumph_for_hispaniae
3164
+ }
3165
+ if = {
3166
+ limit = { has_country_modifier = ITA_new_renaissance }
3167
+ remove_country_modifier = ITA_new_renaissance
3168
+ }
3169
+ if = {
3170
+ limit = { has_country_modifier = ITA_diplomatic_revolution }
3171
+ remove_country_modifier = ITA_diplomatic_revolution
3172
+ add_country_modifier = {
3173
+ name = ITA_diplomatic_revolution_weaker
3174
+ duration = -1
3175
+ }
3176
+ }
3177
+ if = {
3178
+ limit = { has_country_modifier = MUG_industrial_powerhouse }
3179
+ remove_country_modifier = MUG_industrial_powerhouse
3180
+ }
3181
+ if = {
3182
+ limit = { has_country_modifier = MUG_gunpowder_mastery }
3183
+ remove_country_modifier = MUG_gunpowder_mastery
3184
+ }
3185
+ if = {
3186
+ limit = { has_country_modifier = TIM_golden_horde }
3187
+ remove_country_modifier = TIM_golden_horde
3188
+ }
3189
+ if = {
3190
+ limit = { has_country_modifier = TIM_persian_economic_hegemon }
3191
+ remove_country_modifier = TIM_persian_economic_hegemon
3192
+ }
3193
+ if = {
3194
+ limit = { has_country_modifier = hordes_fall_of_china }
3195
+ remove_country_modifier = hordes_fall_of_china
3196
+ }
3197
+ if = {
3198
+ limit = { has_country_modifier = ITA_new_renaissance_non_dlc }
3199
+ remove_country_modifier = ITA_new_renaissance_non_dlc
3200
+ }
2842
3201
  }
2843
3202
  }
2844
3203
  remove_all_age_of_absolutism_modifiers = {
2845
- #if = {
2846
- # limit = {
2847
- # NOT = { current_age = age_of_absolutism }
2848
- # }
2849
- #}
2850
- #Empty as there are no modifiers specific for this age
3204
+ if = {
3205
+ limit = {
3206
+ NOT = { current_age = age_of_absolutism }
3207
+ }
3208
+ if = {
3209
+ limit = { has_country_modifier = ITA_conquest_of_britain }
3210
+ remove_country_modifier = ITA_conquest_of_britain
3211
+ }
3212
+ }
3213
+ if = {
3214
+ limit = {
3215
+ NOT = { current_age = age_of_absolutism }
3216
+ }
3217
+ if = {
3218
+ limit = { has_country_modifier = GER_economic_influence }
3219
+ remove_country_modifier = GER_economic_influence
3220
+ }
3221
+ }
2851
3222
  }
2852
3223
  remove_all_age_of_revolution_modifiers = {
2853
3224
  #if = {
@@ -2957,6 +3328,25 @@ on_harmonized_effect = {
2957
3328
  }
2958
3329
  }
2959
3330
 
3331
+ on_primary_culture_changed_effect = {
3332
+ if = {
3333
+ limit = { has_government_attribute = can_recruit_banners_from_primary_culture_provinces }
3334
+ every_owned_province = {
3335
+ if = {
3336
+ limit = {
3337
+ has_province_modifier = mongol_banners_location
3338
+ has_owner_culture = no
3339
+ }
3340
+ remove_province_modifier = mongol_banners_location
3341
+ }
3342
+ if = {
3343
+ limit = { has_owner_culture = yes }
3344
+ add_province_modifier = { name = mongol_banners_location duration = -1 hidden = yes }
3345
+ }
3346
+ }
3347
+ }
3348
+ }
3349
+
2960
3350
  on_province_culture_change_effect = {
2961
3351
  if = {
2962
3352
  limit = { has_province_modifier = tur_competent_pashas }
@@ -2988,6 +3378,58 @@ on_province_culture_change_effect = {
2988
3378
  add_province_modifier = { name = the_provincial_system duration = -1 hidden = yes }
2989
3379
  }
2990
3380
  }
3381
+ if = {
3382
+ limit = {
3383
+ owner = {
3384
+ has_government_attribute = negate_unaccepted_levantine_culture
3385
+ }
3386
+ }
3387
+ if = {
3388
+ limit = {
3389
+ culture_group = turko_semitic
3390
+ NOT = { has_owner_accepted_culture = yes }
3391
+ NOT = { has_province_modifier = hsn_ayyubid_tolerance }
3392
+ }
3393
+ add_province_modifier = {
3394
+ name = hsn_ayyubid_tolerance
3395
+ duration = -1
3396
+ }
3397
+ }
3398
+ if = {
3399
+ limit = {
3400
+ OR = {
3401
+ NOT = { culture_group = turko_semitic }
3402
+ has_owner_accepted_culture = yes
3403
+ }
3404
+ has_province_modifier = hsn_ayyubid_tolerance
3405
+ }
3406
+ remove_province_modifier = hsn_ayyubid_tolerance
3407
+ }
3408
+ }
3409
+ if = {
3410
+ limit = {
3411
+ owner = {
3412
+ has_government_attribute = increase_nobles_loyalty_per_culture_conversion
3413
+ }
3414
+ }
3415
+ owner = {
3416
+ add_estate_loyalty = {
3417
+ estate = all
3418
+ loyalty = 1
3419
+ }
3420
+ }
3421
+ }
3422
+ if = {
3423
+ limit = {
3424
+ has_owner_culture = yes
3425
+ owner = { has_government_attribute = can_recruit_banners_from_primary_culture_provinces }
3426
+ }
3427
+ add_province_modifier = { name = mongol_banners_location duration = -1 hidden = yes }
3428
+ }
3429
+ else_if = {
3430
+ limit = { has_province_modifier = mongol_banners_location }
3431
+ remove_province_modifier = mongol_banners_location
3432
+ }
2991
3433
  }
2992
3434
 
2993
3435
  on_province_culture_converted_effect = {
@@ -3197,20 +3639,64 @@ on_alliance_broken_effect = {
3197
3639
  remove_country_modifier = mam_ven_cooperation_modifier
3198
3640
  }
3199
3641
  }
3642
+ if = {
3643
+ limit = {
3644
+ has_country_modifier = hsn_a_sublime_alliance
3645
+ NOT = { alliance_with = event_target:hsn_anatolian_ally }
3646
+ }
3647
+ remove_country_modifier = hsn_a_sublime_alliance
3648
+ }
3649
+ FROM = {
3650
+ if = {
3651
+ limit = {
3652
+ has_country_modifier = hsn_a_sublime_alliance
3653
+ NOT = { alliance_with = event_target:hsn_anatolian_ally }
3654
+ }
3655
+ remove_country_modifier = hsn_a_sublime_alliance
3656
+ }
3657
+ }
3658
+ if = {
3659
+ limit = {
3660
+ has_saved_global_event_target = hsn_anatolian_ally
3661
+ }
3662
+ if = {
3663
+ limit = {
3664
+ has_country_modifier = hsn_a_sublime_alliance
3665
+ NOT = { alliance_with = event_target:hsn_anatolian_ally }
3666
+ }
3667
+ remove_country_modifier = hsn_a_sublime_alliance
3668
+ }
3669
+ FROM = {
3670
+ if = {
3671
+ limit = {
3672
+ has_country_modifier = hsn_a_sublime_alliance
3673
+ NOT = { alliance_with = event_target:hsn_anatolian_ally }
3674
+ }
3675
+ remove_country_modifier = hsn_a_sublime_alliance
3676
+ }
3677
+ }
3678
+ }
3200
3679
  }
3201
3680
 
3202
3681
  on_adm_development_effect = {
3682
+ if = {
3683
+ limit = { owner = { has_country_modifier = tre_revitalization } }
3684
+ add_local_autonomy = -5
3685
+ }
3686
+ if = {
3687
+ limit = { owner = { has_government_attribute = developing_manufactories_extra_dev_chance } has_manufactory_trigger = yes }
3688
+ random_list = { 10 = { add_base_tax = 1 } 90 = { } }
3689
+ }
3690
+ if = {
3691
+ limit = { owner = { has_country_flag = hun_bonus_dev_budapest } province_id = 153 }
3692
+ random_list = { 20 = { add_base_tax = 1 } 80 = { } }
3693
+ }
3203
3694
  if = {
3204
3695
  limit = { owner = { has_country_flag = enable_supplemental_development_flag } }
3205
- random_list = {
3206
- 20 = { add_base_tax = 1 }
3207
- 80 = { }
3208
- }
3696
+ random_list = { 20 = { add_base_tax = 1 } 80 = { } }
3209
3697
  }
3210
3698
  if = {
3211
- limit = {
3212
- owner = { has_country_modifier = lit_increased_dev_modifier }
3213
- }
3699
+ limit = { owner = { has_country_modifier = lit_increased_dev_modifier } }
3214
3700
  add_base_tax = 1
3215
3701
  }
3216
3702
  if = {
@@ -3224,47 +3710,45 @@ on_adm_development_effect = {
3224
3710
  }
3225
3711
  if = {
3226
3712
  limit = { owner = { has_country_modifier = JAP_cadastral_surveys has_dlc = "Domination" } }
3227
- change_estate_land_share = {
3228
- estate = all
3229
- share = -0.2
3230
- }
3231
- }
3232
-
3713
+ owner = { change_estate_land_share = { estate = all share = -0.2 } }
3714
+ }
3233
3715
  if = {
3234
3716
  limit = { owner = { has_country_modifier = jap_20_years_devving_tax_yields_twice_bonus_1_burgher_loyalt_modifier } }
3235
3717
  add_base_tax = 1
3236
- add_estate_loyalty = {
3237
- estate = estate_burghers
3238
- loyalty = 1
3239
- }
3718
+ owner = { add_estate_loyalty = { estate = estate_burghers loyalty = 1 } }
3719
+ }
3720
+ if = {
3721
+ limit = { religion = ROOT owner = { has_country_flag = geo_orthodox_dev } }
3722
+ random_list = { 10 = { add_base_tax = 1 } 90 = { } }
3723
+ }
3724
+ if = {
3725
+ limit = { OR = { trade_goods = cloth trade_goods = silk } owner = { has_country_modifier = turkoman_expanding_industry } }
3726
+ random_list = { 20 = { add_base_tax = 1 } 80 = { } }
3240
3727
  }
3241
-
3242
- #if = {
3243
- # limit = {
3244
- # OR = {
3245
- # region = british_isles_region
3246
- # region = france_region
3247
- # }
3248
- # owner = { has_country_modifier = eng_empire_of_the_island }
3249
- # }
3250
- # random_list = {
3251
- # 4 = { add_base_tax = 1 }
3252
- # 6 = {}
3253
- # }
3254
- #}
3255
3728
  }
3256
3729
  on_dip_development_effect = {
3730
+ if = {
3731
+ limit = { owner = { has_country_modifier = tre_revitalization } }
3732
+ add_local_autonomy = -5
3733
+ }
3734
+ if = {
3735
+ limit = { owner = { has_country_modifier = boh_early_industrialization } has_production_building_trigger = yes }
3736
+ random_list = { 20 = { add_base_production = 1 } 80 = { } }
3737
+ }
3738
+ if = {
3739
+ limit = { owner = { has_government_attribute = developing_manufactories_extra_dev_chance } has_manufactory_trigger = yes }
3740
+ random_list = { 10 = { add_base_production = 1 } 90 = { } }
3741
+ }
3742
+ if = {
3743
+ limit = { owner = { has_country_flag = hun_bonus_dev_budapest } province_id = 153 }
3744
+ random_list = { 20 = { add_base_production = 1 } 80 = { } }
3745
+ }
3257
3746
  if = {
3258
3747
  limit = { owner = { has_country_flag = enable_supplemental_development_flag } }
3259
- random_list = {
3260
- 20 = { add_base_production = 1 }
3261
- 80 = { }
3262
- }
3748
+ random_list = { 20 = { add_base_production = 1 } 80 = { } }
3263
3749
  }
3264
3750
  if = {
3265
- limit = {
3266
- owner = { has_country_modifier = lit_increased_dev_modifier }
3267
- }
3751
+ limit = { owner = { has_country_modifier = lit_increased_dev_modifier } }
3268
3752
  add_base_production = 1
3269
3753
  }
3270
3754
  if = {
@@ -3276,33 +3760,34 @@ on_dip_development_effect = {
3276
3760
  70 = { }
3277
3761
  }
3278
3762
  }
3279
-
3280
- #if = {
3281
- # limit = {
3282
- # OR = {
3283
- # region = british_isles_region
3284
- # region = france_region
3285
- # }
3286
- # owner = { has_country_modifier = eng_empire_of_the_island }
3287
- # }
3288
- # random_list = {
3289
- # 4 = { add_base_production = 1 }
3290
- # 6 = {}
3291
- # }
3292
- #}
3763
+ if = {
3764
+ limit = { religion = ROOT owner = { has_country_flag = geo_orthodox_dev } }
3765
+ random_list = { 10 = { add_base_production = 1 } 90 = { } }
3766
+ }
3767
+ if = {
3768
+ limit = { OR = { trade_goods = cloth trade_goods = silk } owner = { has_country_modifier = turkoman_expanding_industry } }
3769
+ random_list = { 20 = { add_base_production = 1 } 80 = { } }
3770
+ }
3293
3771
  }
3294
3772
  on_mil_development_effect = {
3773
+ if = {
3774
+ limit = { owner = { has_country_modifier = tre_revitalization } }
3775
+ add_local_autonomy = -5
3776
+ }
3777
+ if = {
3778
+ limit = { owner = { has_government_attribute = developing_manufactories_extra_dev_chance } has_manufactory_trigger = yes }
3779
+ random_list = { 10 = { add_base_manpower = 1 } 90 = { } }
3780
+ }
3781
+ if = {
3782
+ limit = { owner = { has_country_flag = hun_bonus_dev_budapest } province_id = 153 }
3783
+ random_list = { 20 = { add_base_manpower = 1 } 80 = { } }
3784
+ }
3295
3785
  if = {
3296
3786
  limit = { owner = { has_country_flag = enable_supplemental_development_flag } }
3297
- random_list = {
3298
- 20 = { add_base_manpower = 1 }
3299
- 80 = { }
3300
- }
3787
+ random_list = { 20 = { add_base_manpower = 1 } 80 = { } }
3301
3788
  }
3302
3789
  if = {
3303
- limit = {
3304
- owner = { has_country_modifier = lit_increased_dev_modifier }
3305
- }
3790
+ limit = { owner = { has_country_modifier = lit_increased_dev_modifier } }
3306
3791
  add_base_manpower = 1
3307
3792
  }
3308
3793
  if = {
@@ -3314,47 +3799,75 @@ on_mil_development_effect = {
3314
3799
  70 = { }
3315
3800
  }
3316
3801
  }
3317
-
3318
- #if = {
3319
- # limit = {
3320
- # OR = {
3321
- # region = british_isles_region
3322
- # region = france_region
3323
- # }
3324
- # owner = { has_country_modifier = eng_empire_of_the_island }
3325
- # }
3326
- # random_list = {
3327
- # 4 = { add_base_manpower = 1 }
3328
- # 6 = {}
3329
- # }
3330
- #}
3802
+ if = {
3803
+ limit = { religion = ROOT owner = { has_country_flag = geo_orthodox_dev } }
3804
+ random_list = { 10 = { add_base_manpower = 1 } 90 = { } }
3805
+ }
3806
+ if = {
3807
+ limit = { OR = { trade_goods = cloth trade_goods = silk } owner = { has_country_modifier = turkoman_expanding_industry } }
3808
+ random_list = { 20 = { add_base_manpower = 1 } 80 = { } }
3809
+ }
3331
3810
  }
3332
3811
  on_development_effect = {
3333
- owner = {
3334
- change_variable = {
3335
- which = num_of_times_developed
3336
- value = 1
3337
- }
3812
+ owner = { change_variable = { which = num_of_times_developed value = 1 } }
3813
+ if = {
3814
+ limit = { owner = { has_mission = ARB_the_harsh_desert } has_climate = arid }
3815
+ owner = { change_variable = { which = num_of_times_developed_arid value = 1 } }
3816
+ }
3817
+ if = {
3818
+ limit = { owner = { is_andean_society_trigger = yes } OR = { has_terrain = mountain has_terrain = highlands has_terrain = hills } }
3819
+ owner = { change_variable = { which = num_of_times_developed_mountains value = 1 } }
3820
+ }
3821
+ if = {
3822
+ limit = { has_terrain = jungle }
3823
+ owner = { change_variable = { which = num_of_times_developed_jungles value = 1 } }
3824
+ }
3825
+ if = {
3826
+ limit = { owner = { has_reform = german_cultural_disunity_reform } GER_has_matching_culture = yes }
3827
+ owner = { add_government_power = { mechanic_type = cultural_unity_mechanic power_type = cultural_unity value = 1.5 } }
3338
3828
  }
3339
-
3829
+ FROM = { change_variable = { which = num_of_times_developed_var value = 1 } }
3340
3830
  if = {
3341
- limit = {
3342
- owner = {
3343
- has_mission = ARB_the_harsh_desert
3344
- }
3345
- has_climate = arid
3346
- }
3347
- owner = {
3348
- change_variable = {
3349
- which = num_of_times_developed_arid
3350
- value = 1
3351
- }
3352
- }
3831
+ limit = { owner = { has_country_flag = ned_unlock_dutch_urbanization_flag } region = low_countries_region development = 25 }
3832
+ add_province_modifier = { name = ned_dutch_urbanization duration = -1 }
3833
+ }
3834
+ if = {
3835
+ limit = { owner = { has_country_flag = ned_unlock_flemish_urbanization_flag } region = low_countries_region development = 25 }
3836
+ add_province_modifier = { name = ned_flemish_urbanization duration = -1 }
3353
3837
  }
3838
+ if = {
3839
+ limit = {
3840
+ owner = { has_estate_privilege = estate_burghers_hungarian_royal_cities }
3841
+ NOT = { has_province_modifier = estate_burghers_hungarian_royal_city_modifier }
3842
+ development = 20
3843
+ region = carpathia_region
3844
+ province_has_center_of_trade_of_level = 1
3845
+ }
3846
+ add_province_modifier = { name = estate_burghers_hungarian_royal_city_modifier duration = -1 }
3847
+ }
3848
+ if = {
3849
+ limit = { owner = { has_country_modifier = pru_victory_lower_saxony_modifier } OR = { culture = saxon culture = lower_saxon } }
3850
+ add_nationalism = -3
3851
+ add_local_autonomy = -5
3852
+ add_prosperity = 1
3853
+ }
3854
+ on_$type$_development_effect = yes
3354
3855
  }
3355
3856
 
3356
3857
  # THIS = Province, FROM = Country, ROOT = Merc Unit
3357
3858
  on_mercenary_recruited_effect = {
3859
+ if = {
3860
+ limit = {
3861
+ FROM = {
3862
+ has_country_flag = hun_no_prof_black_army
3863
+ }
3864
+ OR = {
3865
+ ROOT = { mercenary_company = merc_black_army }
3866
+ ROOT = { mercenary_company = merc_black_army_2 }
3867
+ }
3868
+ }
3869
+ FROM = { add_army_professionalism = 0.01 }
3870
+ }
3358
3871
  if = {
3359
3872
  limit = {
3360
3873
  FROM = { has_not_free_mercs_trait = yes }
@@ -3362,6 +3875,7 @@ on_mercenary_recruited_effect = {
3362
3875
  OR = {
3363
3876
  FROM = { NOT = { has_country_flag = oyo_cavalry_do_not_consume_ap } }
3364
3877
  ROOT = { NOT = { mercenary_company = merc_oyo_cavalry } }
3878
+ FROM = { NOT = { has_country_modifier = hsn_turkoman_mercenaries } }
3365
3879
  }
3366
3880
  }
3367
3881
  if = {
@@ -3492,6 +4006,13 @@ on_parliament_debate_succeeded_effect = {
3492
4006
  }
3493
4007
 
3494
4008
  on_main_war_won_effect = {
4009
+ if = {
4010
+ limit = {
4011
+ has_country_modifier = hun_avenge_varna
4012
+ FROM = { tag = TUR }
4013
+ }
4014
+ remove_country_modifier = hun_avenge_varna
4015
+ }
3495
4016
  if = {
3496
4017
  limit = {
3497
4018
  has_government_attribute = winning_wars_gives_rt
@@ -3608,6 +4129,38 @@ on_main_war_won_effect = {
3608
4129
  value = 1
3609
4130
  }
3610
4131
  }
4132
+ if = {
4133
+ limit = {
4134
+ ROOT = {
4135
+ has_government_attribute = pp_on_heathen_wars
4136
+ }
4137
+ FROM = {
4138
+ NOT = {
4139
+ religion_group = ROOT
4140
+ }
4141
+ }
4142
+ }
4143
+ add_power_projection = {
4144
+ type = mission_rewards_power_projection
4145
+ amount = 10
4146
+ }
4147
+ }
4148
+ if = {
4149
+ limit = {
4150
+ ROOT = {
4151
+ has_country_flag = hun_pp_on_heathen_wars
4152
+ }
4153
+ FROM = {
4154
+ NOT = {
4155
+ religion_group = ROOT
4156
+ }
4157
+ }
4158
+ }
4159
+ add_power_projection = {
4160
+ type = mission_rewards_power_projection
4161
+ amount = 10
4162
+ }
4163
+ }
3611
4164
  }
3612
4165
 
3613
4166
  on_change_tag_effect = {
@@ -3624,6 +4177,24 @@ on_change_tag_effect = {
3624
4177
  if = { limit = { has_country_modifier = naval_reassignment_act_modifier } remove_country_modifier = naval_reassignment_act_modifier }
3625
4178
  if = { limit = { has_country_modifier = diplomatic_act_modifier } remove_country_modifier = diplomatic_act_modifier }
3626
4179
  if = { limit = { has_country_modifier = internal_focus_act_modifier } remove_country_modifier = internal_focus_act_modifier }
4180
+ if = {
4181
+ limit = {
4182
+ has_country_modifier = TIM_india_conquest
4183
+ }
4184
+ remove_country_modifier = TIM_india_conquest
4185
+ }
4186
+ if = {
4187
+ limit = {
4188
+ has_country_flag = feo_russian_ally
4189
+ }
4190
+ save_global_event_target_as = russian_ally
4191
+ }
4192
+ if = {
4193
+ limit = {
4194
+ has_country_flag = feo_russian_pu
4195
+ }
4196
+ save_global_event_target_as = feo_russian_pu
4197
+ }
3627
4198
  }
3628
4199
  }
3629
4200
 
@@ -3791,6 +4362,18 @@ on_general_recruited_effect = {
3791
4362
  limit = { has_country_modifier = fra_french_papal_military_cooperation_modifier }
3792
4363
  add_army_professionalism = 0.015
3793
4364
  }
4365
+ if = {
4366
+ limit = {
4367
+ has_reform = ayyubid_high_command
4368
+ }
4369
+ add_army_tradition = 0.5
4370
+ }
4371
+ if = {
4372
+ limit = {
4373
+ has_country_flag = ven_quality_reward_flag
4374
+ }
4375
+ add_army_tradition = 1
4376
+ }
3794
4377
  }
3795
4378
 
3796
4379
  on_sale_of_titles_effect = {
@@ -3800,6 +4383,20 @@ on_sale_of_titles_effect = {
3800
4383
  value = 1
3801
4384
  }
3802
4385
  }
4386
+ if = {
4387
+ limit = {
4388
+ has_country_flag = ITA_selling_crownland_will_give_25_administrative_power_flag
4389
+ }
4390
+ add_adm_power = 25
4391
+ }
4392
+ if = {
4393
+ limit = { has_government_mechanic = council_of_ten }
4394
+ add_government_power = {
4395
+ mechanic_type = council_of_ten
4396
+ power_type = authority_power
4397
+ value = 5
4398
+ }
4399
+ }
3803
4400
  }
3804
4401
  on_summon_the_diet_effect = {
3805
4402
  hidden_effect = {
@@ -3825,6 +4422,21 @@ on_seize_land_effect = {
3825
4422
  }
3826
4423
  }
3827
4424
  }
4425
+ if = {
4426
+ limit = {
4427
+ has_country_flag = MUG_seize_land_gives_absolutism
4428
+ is_absolutism_active = yes
4429
+ }
4430
+ add_absolutism = 2
4431
+ }
4432
+ if = {
4433
+ limit = { has_government_mechanic = council_of_ten }
4434
+ add_government_power = {
4435
+ mechanic_type = council_of_ten
4436
+ power_type = authority_power
4437
+ value = -5
4438
+ }
4439
+ }
3828
4440
  }
3829
4441
  on_heir_disinherited_or_death_effect = {
3830
4442
  if = {
@@ -3973,14 +4585,75 @@ on_built_tax_building_effect = {
3973
4585
  }
3974
4586
 
3975
4587
  on_capital_moved_effect = {
4588
+ owner = {
4589
+ if = {
4590
+ limit = {
4591
+ has_estate_privilege = estate_burghers_hungarian_royal_cities
4592
+ }
4593
+ carpathia_region = {
4594
+ limit = {
4595
+ owned_by = ROOT
4596
+ development = 20
4597
+ NOT = { has_province_modifier = estate_burghers_hungarian_royal_city_modifier }
4598
+ province_has_center_of_trade_of_level = 1
4599
+ }
4600
+ add_province_modifier = {
4601
+ name = estate_burghers_hungarian_royal_city_modifier
4602
+ duration = -1
4603
+ }
4604
+ }
4605
+ capital_scope = {
4606
+ remove_province_modifier = estate_burghers_hungarian_royal_city_modifier
4607
+ }
4608
+ }
4609
+ if = {
4610
+ limit = {
4611
+ check_variable = {
4612
+ which = inca_amount_of_mummies
4613
+ value = 1
4614
+ }
4615
+ }
4616
+ subtract_variable = {
4617
+ which = inca_amount_of_mummies
4618
+ value = 1
4619
+ }
4620
+ }
4621
+ }
4622
+ if = {
4623
+ limit = {
4624
+ owner = { has_reform = great_mongol_state_reform }
4625
+ }
4626
+ FROM = { remove_province_modifier = allow_banners_capital_modifier }
4627
+ ROOT = {
4628
+ add_province_modifier = {
4629
+ name = allow_banners_capital_modifier
4630
+ duration = -1
4631
+ hidden = yes
4632
+ }
4633
+ }
4634
+ }
3976
4635
  }
3977
4636
 
3978
4637
  on_government_change_effect = {
4638
+ if = {
4639
+ limit = {
4640
+ has_country_modifier = ven_ten_restrained
4641
+ }
4642
+ remove_country_modifier = ven_ten_restrained
4643
+ }
4644
+ if = {
4645
+ limit = {
4646
+ any_owned_province = { has_province_modifier = hsn_ayyubid_tolerance }
4647
+ }
4648
+ every_owned_province = {
4649
+ limit = { has_province_modifier = hsn_ayyubid_tolerance }
4650
+ remove_province_modifier = hsn_ayyubid_tolerance
4651
+ }
4652
+ }
3979
4653
  clr_country_flag = pirate_mutineer_council
3980
4654
  clr_country_flag = caretaker_revolutionary_government
3981
4655
  if = {
3982
4656
  limit = {
3983
- NOT = { government = monarchy }
3984
4657
  any_owned_province = { has_province_modifier = domain_of_spouses_family }
3985
4658
  }
3986
4659
  random_owned_province = {
@@ -3990,7 +4663,6 @@ on_government_change_effect = {
3990
4663
  }
3991
4664
  if = {
3992
4665
  limit = {
3993
- NOT = { government = monarchy }
3994
4666
  any_owned_province = { has_province_modifier = home_of_consort }
3995
4667
  }
3996
4668
  random_owned_province = {
@@ -4037,6 +4709,46 @@ on_government_change_effect = {
4037
4709
  }
4038
4710
  country_event = { id = persian_influence_events.3000 }
4039
4711
  }
4712
+ if = {
4713
+ limit = {
4714
+ has_country_flag = GER_unlocked_saxon_reform
4715
+ }
4716
+ every_owned_province = {
4717
+ limit = {
4718
+ has_province_modifier = GER_mining_provinces_saxon
4719
+ }
4720
+ remove_province_modifier = GER_mining_provinces_saxon
4721
+ }
4722
+ }
4723
+ if = {
4724
+ limit = {
4725
+ has_country_flag = GER_unlocked_franconian_reform
4726
+ }
4727
+ every_owned_province = {
4728
+ limit = {
4729
+ has_province_modifier = GER_paper_provinces_franconian
4730
+ }
4731
+ remove_province_modifier = GER_paper_provinces_franconian
4732
+ }
4733
+ }
4734
+ }
4735
+
4736
+ on_native_government_change_effect = {
4737
+ hidden_effect = {
4738
+ every_owned_province = {
4739
+ if = { limit = { has_building = native_palisade } set_province_flag = native_palisade_flag }
4740
+ if = { limit = { has_building = native_fortified_house } set_province_flag = native_fortified_house_flag }
4741
+ if = { limit = { has_building = native_ceremonial_fire_pit } set_province_flag = native_ceremonial_fire_pit_flag }
4742
+ if = { limit = { has_building = native_storehouse } set_province_flag = native_storehouse_flag }
4743
+ if = { limit = { has_building = native_longhouse } set_province_flag = native_longhouse_flag }
4744
+ if = { limit = { has_building = native_sweat_lodge } set_province_flag = native_sweat_lodge_flag }
4745
+ if = { limit = { has_building = native_great_trail } set_province_flag = native_great_trail_flag }
4746
+ }
4747
+ country_event = {
4748
+ id = native_americans.999
4749
+ days = 35
4750
+ }
4751
+ }
4040
4752
  }
4041
4753
 
4042
4754
  on_non_estate_disaster_end = {
@@ -4119,6 +4831,52 @@ on_startup_effect = {
4119
4831
  desc = until_end_of_age_desc
4120
4832
  }
4121
4833
  }
4834
+ if = {
4835
+ limit = {
4836
+ tag = BOH
4837
+ NOT = {
4838
+ has_country_flag = boh_hussite_aftermath_flag
4839
+ }
4840
+ }
4841
+ set_country_flag = boh_hussite_aftermath_flag
4842
+ country_event = { id = flavor_boh.15 }
4843
+ }
4844
+ if = {
4845
+ limit = {
4846
+ ai = no
4847
+ tag = BOH
4848
+ has_dlc = "Winds of Change"
4849
+ not_in_mission_preview_mode = { key = BOH_RELIGION }
4850
+ NOT = { mission_completed = boh_hussite_regency }
4851
+ }
4852
+ enable_branching_mission_review_without_ai = {
4853
+ key = BOH_RELIGION
4854
+ }
4855
+ }
4856
+ if = {
4857
+ limit = {
4858
+ ai = no
4859
+ tag = HSN
4860
+ has_dlc = "Winds of Change"
4861
+ not_in_mission_preview_mode = { key = HSN }
4862
+ NOT = { mission_completed = hsn_fate_of_anatolia }
4863
+ }
4864
+ enable_branching_mission_review_without_ai = {
4865
+ key = HSN
4866
+ }
4867
+ }
4868
+ if = {
4869
+ limit = {
4870
+ ai = no
4871
+ tag = HSN
4872
+ has_dlc = "Winds of Change"
4873
+ not_in_mission_preview_mode = { key = HSN2 }
4874
+ NOT = { mission_completed = hsn_sultan_shah }
4875
+ }
4876
+ enable_branching_mission_review_without_ai = {
4877
+ key = HSN2
4878
+ }
4879
+ }
4122
4880
  }
4123
4881
 
4124
4882
  on_startup_dlc_cleanup_effect = {
@@ -4129,6 +4887,46 @@ on_startup_dlc_cleanup_effect = {
4129
4887
  }
4130
4888
  remove_country_modifier = tur_janissary
4131
4889
  }
4890
+ if = {
4891
+ limit = {
4892
+ tag = BOH
4893
+ has_dlc = "Winds of Change"
4894
+ not_in_mission_preview_mode = { key = BOH_RELIGION }
4895
+ NOT = {
4896
+ mission_completed = boh_hussite_regency
4897
+ }
4898
+ }
4899
+ enable_branching_mission_review = {
4900
+ key = BOH_RELIGION
4901
+ ai_event_id = flavor_boh.14
4902
+ }
4903
+ }
4904
+ if = {
4905
+ limit = {
4906
+ tag = HSN
4907
+ has_dlc = "Winds of Change"
4908
+ not_in_mission_preview_mode = { key = HSN }
4909
+ NOT = {
4910
+ mission_completed = hsn_fate_of_anatolia
4911
+ }
4912
+ }
4913
+ enable_branching_mission_review_without_ai = {
4914
+ key = HSN
4915
+ }
4916
+ }
4917
+ if = {
4918
+ limit = {
4919
+ tag = HSN
4920
+ has_dlc = "Winds of Change"
4921
+ not_in_mission_preview_mode = { key = HSN2 }
4922
+ NOT = {
4923
+ mission_completed = hsn_sultan_shah
4924
+ }
4925
+ }
4926
+ enable_branching_mission_review_without_ai = {
4927
+ key = HSN2
4928
+ }
4929
+ }
4132
4930
  }
4133
4931
 
4134
4932
  on_dependency_gained_effect = {
@@ -4246,8 +5044,7 @@ on_monarch_death_effect = {
4246
5044
  if = {
4247
5045
  limit = { has_government_attribute = no_stability_loss_on_monarch_death }
4248
5046
  add_stability = 1
4249
- }
4250
-
5047
+ }
4251
5048
  if = {
4252
5049
  limit = {
4253
5050
  is_subject_of_type = pronoia_subject_type
@@ -4281,7 +5078,21 @@ on_monarch_death_effect = {
4281
5078
  }
4282
5079
  country_event = { id = 611 }
4283
5080
  }
4284
-
5081
+ if = {
5082
+ limit = {
5083
+ tag = HAB
5084
+ NOT = { exists = HUN }
5085
+ NOT = { has_country_flag = hab_hungarian_crown_event_flag }
5086
+ num_of_owned_provinces_with = {
5087
+ value = 1
5088
+ OR = {
5089
+ culture = hungarian
5090
+ is_core = HUN
5091
+ }
5092
+ }
5093
+ }
5094
+ country_event = { id = hungarian_revolt_events.4 }
5095
+ }
4285
5096
  }
4286
5097
 
4287
5098
  on_conquest_effect = {
@@ -4331,99 +5142,243 @@ on_conquest_effect = {
4331
5142
  }
4332
5143
  if = {
4333
5144
  limit = {
5145
+ has_fort_building_trigger = yes
4334
5146
  owner = {
4335
- mission_completed = feo_gothic_invasion
4336
- }
4337
- OR = {
4338
- region = north_german_region
4339
- region = south_german_region
5147
+ has_country_flag = orm_forts_trade_power_buff_flag
4340
5148
  }
4341
5149
  }
4342
5150
  add_province_modifier = {
4343
- name = feo_return_to_gothic_ways
5151
+ name = orm_forts_buff
4344
5152
  duration = -1
5153
+ hidden = yes
4345
5154
  }
4346
5155
  }
4347
5156
  if = {
4348
5157
  limit = {
5158
+ province_id = 134
4349
5159
  owner = {
4350
- mission_completed = feo_subdue_the_hordes
5160
+ OR = {
5161
+ has_country_flag = enable_gothic_invasion_cb_flag
5162
+ overlord = { has_country_flag = enable_gothic_invasion_cb_flag }
5163
+ }
4351
5164
  }
4352
- OR = {
4353
- region = ural_region
4354
- region = central_asia_region
5165
+ }
5166
+ if = {
5167
+ limit = {
5168
+ owner = { has_country_flag = enable_gothic_invasion_cb_flag }
5169
+ }
5170
+ owner = {
5171
+ add_country_modifier = {
5172
+ name = feo_vienna
5173
+ duration = -1
5174
+ }
4355
5175
  }
4356
5176
  }
4357
- add_province_modifier = {
4358
- name = feo_steppe_construction_efforts
4359
- duration = -1
5177
+ else = {
5178
+ owner = {
5179
+ overlord = {
5180
+ add_country_modifier = {
5181
+ name = feo_vienna
5182
+ duration = -1
5183
+ }
5184
+ }
5185
+ }
4360
5186
  }
4361
5187
  }
4362
5188
  if = {
4363
5189
  limit = {
5190
+ province_id = 266
4364
5191
  owner = {
4365
- mission_completed = feo_gothic_invasion
5192
+ OR = {
5193
+ has_country_flag = enable_gothic_invasion_cb_flag
5194
+ overlord = { has_country_flag = enable_gothic_invasion_cb_flag }
5195
+ }
4366
5196
  }
4367
5197
  }
4368
5198
  if = {
4369
5199
  limit = {
4370
- 134 = {
4371
- country_or_non_sovereign_subject_holds = ROOT
5200
+ owner = { has_country_flag = enable_gothic_invasion_cb_flag }
5201
+ }
5202
+ owner = {
5203
+ add_country_modifier = {
5204
+ name = feo_prague
5205
+ duration = -1
4372
5206
  }
4373
5207
  }
4374
- add_country_modifier = {
4375
- name = feo_vienna
4376
- duration = -1
4377
- hidden = yes
5208
+ }
5209
+ else = {
5210
+ owner = {
5211
+ overlord = {
5212
+ add_country_modifier = {
5213
+ name = feo_prague
5214
+ duration = -1
5215
+ }
5216
+ }
5217
+ }
5218
+ }
5219
+ }
5220
+ if = {
5221
+ limit = {
5222
+ province_id = 45
5223
+ owner = {
5224
+ OR = {
5225
+ has_country_flag = enable_gothic_invasion_cb_flag
5226
+ overlord = { has_country_flag = enable_gothic_invasion_cb_flag }
5227
+ }
4378
5228
  }
4379
5229
  }
4380
5230
  if = {
4381
5231
  limit = {
4382
- 266 = {
4383
- country_or_non_sovereign_subject_holds = ROOT
5232
+ owner = { has_country_flag = enable_gothic_invasion_cb_flag }
5233
+ }
5234
+ owner = {
5235
+ add_country_modifier = {
5236
+ name = feo_lubeck
5237
+ duration = -1
4384
5238
  }
4385
5239
  }
4386
- add_country_modifier = {
4387
- name = feo_prague
4388
- duration = -1
4389
- hidden = yes
5240
+ }
5241
+ else = {
5242
+ owner = {
5243
+ overlord = {
5244
+ add_country_modifier = {
5245
+ name = feo_lubeck
5246
+ duration = -1
5247
+ }
5248
+ }
5249
+ }
5250
+ }
5251
+ }
5252
+ if = {
5253
+ limit = {
5254
+ province_id = 1878
5255
+ owner = {
5256
+ OR = {
5257
+ has_country_flag = enable_gothic_invasion_cb_flag
5258
+ overlord = { has_country_flag = enable_gothic_invasion_cb_flag }
5259
+ }
4390
5260
  }
4391
5261
  }
4392
5262
  if = {
4393
5263
  limit = {
4394
- 45 = {
4395
- country_or_non_sovereign_subject_holds = ROOT
5264
+ owner = { has_country_flag = enable_gothic_invasion_cb_flag }
5265
+ }
5266
+ owner = {
5267
+ add_country_modifier = {
5268
+ name = feo_aachen
5269
+ duration = -1
4396
5270
  }
4397
5271
  }
4398
- add_country_modifier = {
4399
- name = feo_lubeck
4400
- duration = -1
4401
- hidden = yes
5272
+ }
5273
+ else = {
5274
+ owner = {
5275
+ overlord = {
5276
+ add_country_modifier = {
5277
+ name = feo_aachen
5278
+ duration = -1
5279
+ }
5280
+ }
5281
+ }
5282
+ }
5283
+ }
5284
+ if = {
5285
+ limit = {
5286
+ province_id = 85
5287
+ owner = {
5288
+ OR = {
5289
+ has_country_flag = enable_gothic_invasion_cb_flag
5290
+ overlord = { has_country_flag = enable_gothic_invasion_cb_flag }
5291
+ }
4402
5292
  }
4403
5293
  }
4404
5294
  if = {
4405
5295
  limit = {
4406
- 1878 = {
4407
- country_or_non_sovereign_subject_holds = ROOT
5296
+ owner = { has_country_flag = enable_gothic_invasion_cb_flag }
5297
+ }
5298
+ owner = {
5299
+ add_country_modifier = {
5300
+ name = feo_cologne
5301
+ duration = -1
4408
5302
  }
4409
5303
  }
4410
- add_country_modifier = {
4411
- name = feo_aachen
4412
- duration = -1
4413
- hidden = yes
5304
+ }
5305
+ else = {
5306
+ owner = {
5307
+ overlord = {
5308
+ add_country_modifier = {
5309
+ name = feo_cologne
5310
+ duration = -1
5311
+ }
5312
+ }
4414
5313
  }
4415
5314
  }
4416
- if = {
4417
- limit = {
4418
- 85 = {
4419
- country_or_non_sovereign_subject_holds = ROOT
5315
+ }
5316
+ }
5317
+
5318
+ on_convert_by_trade_policy_effect = {
5319
+ FROM = { change_variable = { which = propogation_counter value = 1 } }
5320
+ if = {
5321
+ limit = {
5322
+ trade_company_region = trade_company_moluccas
5323
+ FROM = { is_defender_of_faith = yes }
5324
+ }
5325
+ FROM = {
5326
+ if = {
5327
+ limit = {
5328
+ ai = no
5329
+ NOT = { check_variable = { which = religion_propagated_in_moluccas value = 1 } }
5330
+ }
5331
+ set_variable = {
5332
+ which = religion_propagated_in_moluccas value = 1
4420
5333
  }
4421
5334
  }
4422
- add_country_modifier = {
4423
- name = feo_cologne
4424
- duration = -1
4425
- hidden = yes
5335
+ else_if = {
5336
+ limit = {
5337
+ ai = no
5338
+ check_variable = { which = religion_propagated_in_moluccas value = 1 }
5339
+ NOT = { check_variable = { which = religion_propagated_in_moluccas value = 6 } }
5340
+ }
5341
+ change_variable = {
5342
+ which = religion_propagated_in_moluccas value = 1
5343
+ }
5344
+ }
5345
+ }
5346
+ }
5347
+ if = {
5348
+ limit = { FROM = { has_country_flag = YEM_propagation_gives_navy_tradition } }
5349
+ FROM = { add_navy_tradition = 1 }
5350
+ }
5351
+ if = {
5352
+ limit = {
5353
+ FROM = { has_country_flag = orm_better_sea_religious_propagation }
5354
+ OR = {
5355
+ region = indonesia_region
5356
+ region = moluccas_region
5357
+ region = malaya_region
4426
5358
  }
4427
5359
  }
5360
+ FROM = { add_piety = 0.005 }
5361
+ }
5362
+ if = {
5363
+ limit = { FROM = { has_country_flag = hormuz_religious_propagations_buffs_flag } }
5364
+ add_province_modifier = {
5365
+ name = orm_hormuz_merchants_influence
5366
+ duration = 7300
5367
+ }
5368
+ }
5369
+ }
5370
+
5371
+ on_age_ability_taken_age_of_discovery = { } #for future use (and modders!) :)
5372
+ on_age_ability_taken_age_of_reformation = { }
5373
+ on_age_ability_taken_age_of_absolutism = { }
5374
+ on_age_ability_taken_age_of_revolutions = { }
5375
+ on_age_ability_taken = {
5376
+ on_age_ability_taken_$age$ = yes
5377
+
5378
+ if = {
5379
+ limit = {
5380
+ has_government_attribute = GER_taking_age_rewards_gives_stability
5381
+ }
5382
+ add_stability_or_adm_power = yes
4428
5383
  }
4429
5384
  }
common/scripted_effects/01_scripted_effects_for_rulers_heirs_consorts.txt CHANGED
@@ -275,4 +275,88 @@ change_heir_stat = {
275
275
  }
276
276
  }
277
277
  }
278
+ }
279
+
280
+ add_ruler_personality_ancestor = {
281
+ # key = personality to test again
282
+ if = {
283
+ limit = {
284
+ has_dlc = "Leviathan"
285
+ religion = totemism
286
+ }
287
+ add_ruler_personality = ancestor_$key$_personality
288
+ }
289
+ else = {
290
+ add_ruler_personality = $key$_personality
291
+ }
292
+ }
293
+
294
+ add_heir_personality_ancestor = {
295
+ # key = personality to test again
296
+ if = {
297
+ limit = {
298
+ has_dlc = "Leviathan"
299
+ religion = totemism
300
+ }
301
+ add_heir_personality = ancestor_$key$_personality
302
+ }
303
+ else = {
304
+ add_heir_personality = $key$_personality
305
+ }
306
+ }
307
+
308
+ add_queen_personality_ancestor = {
309
+ # key = personality to test again
310
+ if = {
311
+ limit = {
312
+ has_dlc = "Leviathan"
313
+ religion = totemism
314
+ }
315
+ add_queen_personality = ancestor_$key$_personality
316
+ }
317
+ else = {
318
+ add_queen_personality = $key$_personality
319
+ }
320
+ }
321
+
322
+ remove_ruler_personality_ancestor = {
323
+ # key = personality to test again
324
+ if = {
325
+ limit = {
326
+ has_dlc = "Leviathan"
327
+ religion = totemism
328
+ }
329
+ remove_ruler_personality = ancestor_$key$_personality
330
+ }
331
+ else = {
332
+ remove_ruler_personality = $key$_personality
333
+ }
334
+ }
335
+
336
+ remove_heir_personality_ancestor = {
337
+ # key = personality to test again
338
+ if = {
339
+ limit = {
340
+ has_dlc = "Leviathan"
341
+ religion = totemism
342
+ }
343
+ remove_heir_personality = ancestor_$key$_personality
344
+ }
345
+ else = {
346
+ remove_heir_personality = $key$_personality
347
+ }
348
+ }
349
+
350
+ remove_queen_personality_ancestor = {
351
+ # key = personality to test again
352
+ if = {
353
+ limit = {
354
+ has_dlc = "Leviathan"
355
+ religion = totemism
356
+ }
357
+ remove_queen_personality = ancestor_$key$_personality
358
+ }
359
+ else = {
360
+ remove_queen_personality = $key$_personality
361
+ }
278
362
  }
common/scripted_effects/01_scripted_effects_natives_and_colonization.txt ADDED
@@ -0,0 +1,2768 @@
1
+ # Scripted effects for Native Americans
2
+
3
+
4
+ add_permanent_claims_for_federation_nation = {
5
+ # ORIGINAL = Original Tag
6
+ # TAG = New Tag
7
+ capital_scope = {
8
+ region = {
9
+ limit = {
10
+ NOT = { owned_by = $ORIGINAL$ }
11
+ }
12
+ add_permanent_claim = $TAG$
13
+ }
14
+ }
15
+ }
16
+
17
+ swap_federation_idea_group = {
18
+ if = {
19
+ limit = { has_custom_ideas = no }
20
+ country_event = { id = ideagroups.1 } #Swap Ideas
21
+ }
22
+ }
23
+
24
+ #Supports the following trade goods Base prices
25
+ # grain 2.5
26
+ # wine 2.5
27
+ # wool 2.5
28
+ # cloth 3
29
+ # fish 2.5
30
+ # fur 2
31
+ # salt 3
32
+ # naval_supplies 2
33
+ # copper 3
34
+ # gold 10 #Technically 0, but let us calculate with 10
35
+ # iron 3
36
+ # slaves 2
37
+ # ivory 4
38
+ # tea 3
39
+ # chinaware 3
40
+ # spices 3
41
+ # coffee 3
42
+ # cotton 3
43
+ # sugar 3
44
+ # tobacco 3
45
+ # cocoa 4
46
+ # silk 4
47
+ # dyes 4
48
+ # tropical_wood 2
49
+ # livestock 2
50
+ # incense 2.5
51
+ # glass 3
52
+ # paper 3.5
53
+ # gems 4
54
+ # coal 10
55
+ # cloves 8
56
+ # unknown 0 #Special and should not count
57
+
58
+ determine_value_of_trade_goods_grain = {
59
+ set_variable = {
60
+ which = base_value_grain
61
+ value = 2.5
62
+ }
63
+ if = {
64
+ limit = {
65
+ has_chance_scaling_cost = yes
66
+ }
67
+ set_variable = {
68
+ which = chance_modifier_grain
69
+ value = 1
70
+ }
71
+ if = {
72
+ limit = {
73
+ ROOT = {
74
+ OR = {
75
+ has_terrain = mountain
76
+ has_terrain = coastal_desert
77
+ has_terrain = forest
78
+ has_terrain = woods
79
+ has_terrain = hills
80
+ has_terrain = jungle
81
+ }
82
+ }
83
+ }
84
+ multiply_variable = {
85
+ which = chance_modifier_grain
86
+ value = 0.15
87
+ }
88
+ }
89
+ if = {
90
+ limit = {
91
+ ROOT = {
92
+ OR = {
93
+ has_terrain = highlands
94
+ has_terrain = marsh
95
+ }
96
+ }
97
+ }
98
+ multiply_variable = {
99
+ which = chance_modifier_grain
100
+ value = 0.25
101
+ }
102
+ }
103
+ if = {
104
+ limit = {
105
+ ROOT = {
106
+ OR = {
107
+ has_climate = arid
108
+ has_climate = tropical
109
+ }
110
+ }
111
+ }
112
+ multiply_variable = {
113
+ which = chance_modifier_grain
114
+ value = 0.25
115
+ }
116
+ }
117
+ if = {
118
+ limit = {
119
+ ROOT = {
120
+ OR = {
121
+ has_terrain = drylands
122
+ has_terrain = savannah
123
+ has_terrain = steppe
124
+ }
125
+ }
126
+ }
127
+ multiply_variable = {
128
+ which = chance_modifier_grain
129
+ value = 0.6
130
+ }
131
+ }
132
+ if = {
133
+ limit = {
134
+ ROOT = {
135
+ has_winter = severe_winter
136
+ }
137
+ }
138
+ multiply_variable = {
139
+ which = chance_modifier_grain
140
+ value = 0.35
141
+ }
142
+ }
143
+ if = {
144
+ limit = {
145
+ ROOT = {
146
+ has_winter = normal_winter
147
+ }
148
+ }
149
+ multiply_variable = {
150
+ which = chance_modifier_grain
151
+ value = 0.5
152
+ }
153
+ }
154
+ if = {
155
+ limit = {
156
+ ROOT = {
157
+ has_terrain = farmlands
158
+ }
159
+ }
160
+ multiply_variable = {
161
+ which = chance_modifier_grain
162
+ value = 1.5
163
+ }
164
+ }
165
+ if = {
166
+ limit = {
167
+ ROOT = {
168
+ OR = {
169
+ region = poland_region
170
+ region = ruthenia_region
171
+ }
172
+ }
173
+ }
174
+ multiply_variable = {
175
+ which = chance_modifier_grain
176
+ value = 1.5
177
+ }
178
+ }
179
+ if = {
180
+ limit = {
181
+ OR = {
182
+ has_increased_trade_goods_discovery = { trade_goods = grain }
183
+ colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = grain } }
184
+ }
185
+ }
186
+ multiply_variable = {
187
+ which = chance_modifier_grain
188
+ value = 2
189
+ }
190
+ }
191
+ if = {
192
+ limit = {
193
+ NOT = {
194
+ is_variable_equal = {
195
+ which = chance_modifier_grain
196
+ value = 0
197
+ }
198
+ }
199
+ }
200
+ divide_variable = {
201
+ which = base_value_grain
202
+ which = chance_modifier_grain
203
+ }
204
+ }
205
+ }
206
+ }
207
+ determine_value_of_trade_goods_wine = {
208
+ set_variable = {
209
+ which = base_value_wine
210
+ value = 2.5
211
+ }
212
+ if = {
213
+ limit = {
214
+ has_chance_scaling_cost = yes
215
+ }
216
+ set_variable = {
217
+ which = chance_modifier_wine
218
+ value = 1
219
+ }
220
+ if = {
221
+ limit = {
222
+ ROOT = {
223
+ has_winter = normal_winter
224
+ }
225
+ }
226
+ multiply_variable = {
227
+ which = chance_modifier_wine
228
+ value = 0.25
229
+ }
230
+ }
231
+ if = {
232
+ limit = {
233
+ ROOT = {
234
+ has_terrain = farmlands
235
+ }
236
+ }
237
+ multiply_variable = {
238
+ which = chance_modifier_wine
239
+ value = 1.25
240
+ }
241
+ }
242
+ if = {
243
+ limit = {
244
+ ROOT = {
245
+ OR = {
246
+ has_terrain = hills
247
+ has_terrain = highlands
248
+ }
249
+ }
250
+ }
251
+ multiply_variable = {
252
+ which = chance_modifier_wine
253
+ value = 1.25
254
+ }
255
+ }
256
+ if = {
257
+ limit = {
258
+ ROOT = {
259
+ OR = {
260
+ area = cuyo_area
261
+ region = france_region
262
+ region = italy_region
263
+ }
264
+ }
265
+ }
266
+ multiply_variable = {
267
+ which = chance_modifier_wine
268
+ value = 1.5
269
+ }
270
+ }
271
+ if = {
272
+ limit = {
273
+ OR = {
274
+ culture_group = french
275
+ culture_group = iberian
276
+ culture_group = latin
277
+ }
278
+ }
279
+ multiply_variable = {
280
+ which = chance_modifier_wine
281
+ value = 1.1
282
+ }
283
+ }
284
+ if = {
285
+ limit = {
286
+ OR = {
287
+ has_increased_trade_goods_discovery = { trade_goods = wine }
288
+ colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = wine } }
289
+ }
290
+ }
291
+ multiply_variable = {
292
+ which = chance_modifier_wine
293
+ value = 2
294
+ }
295
+ }
296
+ if = {
297
+ limit = {
298
+ NOT = {
299
+ is_variable_equal = {
300
+ which = chance_modifier_wine
301
+ value = 0
302
+ }
303
+ }
304
+ }
305
+ divide_variable = {
306
+ which = base_value_wine
307
+ which = chance_modifier_wine
308
+ }
309
+ }
310
+ }
311
+ }
312
+ determine_value_of_trade_goods_wool = {
313
+ set_variable = {
314
+ which = base_value_wool
315
+ value = 2.5
316
+ }
317
+ if = {
318
+ limit = {
319
+ has_chance_scaling_cost = yes
320
+ }
321
+ set_variable = {
322
+ which = chance_modifier_wool
323
+ value = 1
324
+ }
325
+ if = {
326
+ limit = {
327
+ ROOT = {
328
+ OR = {
329
+ has_terrain = grasslands
330
+ has_terrain = hills
331
+ has_terrain = forest
332
+ has_terrain = woods
333
+ }
334
+ }
335
+ }
336
+ multiply_variable = {
337
+ which = chance_modifier_wool
338
+ value = 0.15
339
+ }
340
+ }
341
+ if = {
342
+ limit = {
343
+ ROOT = {
344
+ OR = {
345
+ has_terrain = desert
346
+ has_terrain = savannah
347
+ has_terrain = highlands
348
+ has_terrain = drylands
349
+ has_climate = arid
350
+ }
351
+ }
352
+ }
353
+ multiply_variable = {
354
+ which = chance_modifier_wool
355
+ value = 1.25
356
+ }
357
+ }
358
+ if = {
359
+ limit = {
360
+ ROOT = {
361
+ region = central_asia_region
362
+ }
363
+ }
364
+ multiply_variable = {
365
+ which = chance_modifier_wool
366
+ value = 1.5
367
+ }
368
+ }
369
+ if = {
370
+ limit = {
371
+ ROOT = {
372
+ region = tibet_region
373
+ }
374
+ }
375
+ multiply_variable = {
376
+ which = chance_modifier_wool
377
+ value = 1.5
378
+ }
379
+ }
380
+ if = {
381
+ limit = {
382
+ OR = {
383
+ has_increased_trade_goods_discovery = { trade_goods = wool }
384
+ colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = wool } }
385
+ }
386
+ }
387
+ multiply_variable = {
388
+ which = chance_modifier_wool
389
+ value = 2
390
+ }
391
+ }
392
+ if = {
393
+ limit = {
394
+ NOT = {
395
+ is_variable_equal = {
396
+ which = chance_modifier_wool
397
+ value = 0
398
+ }
399
+ }
400
+ }
401
+ divide_variable = {
402
+ which = base_value_wool
403
+ which = chance_modifier_wool
404
+ }
405
+ }
406
+ }
407
+ }
408
+ determine_value_of_trade_goods_cloth = {
409
+ set_variable = {
410
+ which = base_value_cloth
411
+ value = 3
412
+ }
413
+ if = {
414
+ limit = {
415
+ has_chance_scaling_cost = yes
416
+ }
417
+ set_variable = {
418
+ which = chance_modifier_cloth
419
+ value = 1
420
+ }
421
+ if = {
422
+ limit = {
423
+ ROOT = {
424
+ development_discounting_tribal = 12
425
+ }
426
+ }
427
+ multiply_variable = {
428
+ which = chance_modifier_cloth
429
+ value = 2
430
+ }
431
+ }
432
+ if = {
433
+ limit = {
434
+ OR = {
435
+ has_increased_trade_goods_discovery = { trade_goods = cloth }
436
+ colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = cloth } }
437
+ }
438
+ }
439
+ multiply_variable = {
440
+ which = chance_modifier_cloth
441
+ value = 2
442
+ }
443
+ }
444
+ if = {
445
+ limit = {
446
+ NOT = {
447
+ is_variable_equal = {
448
+ which = chance_modifier_cloth
449
+ value = 0
450
+ }
451
+ }
452
+ }
453
+ divide_variable = {
454
+ which = base_value_cloth
455
+ which = chance_modifier_cloth
456
+ }
457
+ }
458
+ }
459
+ }
460
+ determine_value_of_trade_goods_fish = {
461
+ set_variable = {
462
+ which = base_value_fish
463
+ value = 2.5
464
+ }
465
+ if = {
466
+ limit = {
467
+ has_chance_scaling_cost = yes
468
+ }
469
+ set_variable = {
470
+ which = chance_modifier_fish
471
+ value = 1
472
+ }
473
+ if = {
474
+ limit = {
475
+ ROOT = {
476
+ OR = {
477
+ region = carribeans_region
478
+ region = malaya_region
479
+ region = moluccas_region
480
+ region = indonesia_region
481
+ }
482
+ }
483
+ }
484
+ multiply_variable = {
485
+ which = chance_modifier_fish
486
+ value = 0.65
487
+ }
488
+ }
489
+ if = {
490
+ limit = {
491
+ ROOT = {
492
+ area = newfoundland_area
493
+ }
494
+ }
495
+ multiply_variable = {
496
+ which = chance_modifier_fish
497
+ value = 15
498
+ }
499
+ }
500
+ if = {
501
+ limit = {
502
+ ROOT = {
503
+ OR = {
504
+ has_terrain = coastline
505
+ has_terrain = coastal_desert
506
+ }
507
+ }
508
+ }
509
+ multiply_variable = {
510
+ which = chance_modifier_fish
511
+ value = 1.1
512
+ }
513
+ }
514
+ if = {
515
+ limit = {
516
+ ROOT = {
517
+ has_terrain = glacier
518
+ }
519
+ }
520
+ multiply_variable = {
521
+ which = chance_modifier_fish
522
+ value = 1.2
523
+ }
524
+ }
525
+ if = {
526
+ limit = {
527
+ OR = {
528
+ has_increased_trade_goods_discovery = { trade_goods = fish }
529
+ colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = fish } }
530
+ }
531
+ }
532
+ multiply_variable = {
533
+ which = chance_modifier_fish
534
+ value = 2
535
+ }
536
+ }
537
+ if = {
538
+ limit = {
539
+ NOT = {
540
+ is_variable_equal = {
541
+ which = chance_modifier_fish
542
+ value = 0
543
+ }
544
+ }
545
+ }
546
+ divide_variable = {
547
+ which = base_value_fish
548
+ which = chance_modifier_fish
549
+ }
550
+ }
551
+ }
552
+ }
553
+ determine_value_of_trade_goods_fur = {
554
+ set_variable = {
555
+ which = base_value_fur
556
+ value = 2
557
+ }
558
+ if = {
559
+ limit = {
560
+ has_chance_scaling_cost = yes
561
+ }
562
+ set_variable = {
563
+ which = chance_modifier_fur
564
+ value = 1
565
+ }
566
+ if = {
567
+ limit = {
568
+ ROOT = {
569
+ OR = {
570
+ has_terrain = savannah
571
+ has_terrain = grasslands
572
+ has_terrain = highlands
573
+ }
574
+ has_winter = mild_winter
575
+ }
576
+ }
577
+ multiply_variable = {
578
+ which = chance_modifier_fur
579
+ value = 0.75
580
+ }
581
+ }
582
+ if = {
583
+ limit = {
584
+ ROOT = {
585
+ NOT = { native_size = 1 }
586
+ }
587
+ }
588
+ multiply_variable = {
589
+ which = chance_modifier_fur
590
+ value = 0.5
591
+ }
592
+ }
593
+ if = {
594
+ limit = {
595
+ ROOT = {
596
+ native_size = 1
597
+ }
598
+ }
599
+ multiply_variable = {
600
+ which = chance_modifier_fur
601
+ value = 2
602
+ }
603
+ }
604
+ if = {
605
+ limit = {
606
+ ROOT = {
607
+ has_terrain = forest
608
+ }
609
+ }
610
+ multiply_variable = {
611
+ which = chance_modifier_fur
612
+ value = 1.5
613
+ }
614
+ }
615
+ if = {
616
+ limit = {
617
+ ROOT = {
618
+ has_winter = normal_winter
619
+ }
620
+ }
621
+ multiply_variable = {
622
+ which = chance_modifier_fur
623
+ value = 1.6
624
+ }
625
+ }
626
+ if = {
627
+ limit = {
628
+ ROOT = {
629
+ has_winter = severe_winter
630
+ NOT = { has_terrain = glacier }
631
+ }
632
+ }
633
+ multiply_variable = {
634
+ which = chance_modifier_fur
635
+ value = 2.5
636
+ }
637
+ }
638
+ if = {
639
+ limit = {
640
+ has_country_flag = encourage_cash_crops_flag
641
+ }
642
+ multiply_variable = {
643
+ which = chance_modifier_fur
644
+ value = 2
645
+ }
646
+ }
647
+ if = {
648
+ limit = {
649
+ OR = {
650
+ has_increased_trade_goods_discovery = { trade_goods = fur }
651
+ colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = fur } }
652
+ }
653
+ }
654
+ multiply_variable = {
655
+ which = chance_modifier_fur
656
+ value = 2
657
+ }
658
+ }
659
+ if = {
660
+ limit = {
661
+ NOT = {
662
+ is_variable_equal = {
663
+ which = chance_modifier_fur
664
+ value = 0
665
+ }
666
+ }
667
+ }
668
+ divide_variable = {
669
+ which = base_value_fur
670
+ which = chance_modifier_fur
671
+ }
672
+ }
673
+ }
674
+ }
675
+ determine_value_of_trade_goods_salt = {
676
+ set_variable = {
677
+ which = base_value_salt
678
+ value = 3
679
+ }
680
+ if = {
681
+ limit = {
682
+ has_chance_scaling_cost = yes
683
+ }
684
+ set_variable = {
685
+ which = chance_modifier_salt
686
+ value = 1
687
+ }
688
+ if = {
689
+ limit = {
690
+ ROOT = {
691
+ OR = {
692
+ has_terrain = desert
693
+ AND = {
694
+ has_terrain = marsh
695
+ NOT = { has_climate = arctic } #Hudson Bay
696
+ }
697
+ }
698
+ }
699
+ }
700
+ multiply_variable = {
701
+ which = chance_modifier_salt
702
+ value = 2
703
+ }
704
+ }
705
+ if = {
706
+ limit = {
707
+ ROOT = {
708
+ region = peru_region
709
+ }
710
+ }
711
+ multiply_variable = {
712
+ which = chance_modifier_salt
713
+ value = 2
714
+ }
715
+ }
716
+ if = {
717
+ limit = {
718
+ ROOT = {
719
+ area = western_sahara_area
720
+ }
721
+ }
722
+ multiply_variable = {
723
+ which = chance_modifier_salt
724
+ value = 2
725
+ }
726
+ }
727
+ if = {
728
+ limit = {
729
+ OR = {
730
+ has_increased_trade_goods_discovery = { trade_goods = salt }
731
+ colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = salt } }
732
+ }
733
+ }
734
+ multiply_variable = {
735
+ which = chance_modifier_salt
736
+ value = 2
737
+ }
738
+ }
739
+ if = {
740
+ limit = {
741
+ NOT = {
742
+ is_variable_equal = {
743
+ which = chance_modifier_salt
744
+ value = 0
745
+ }
746
+ }
747
+ }
748
+ divide_variable = {
749
+ which = base_value_salt
750
+ which = chance_modifier_salt
751
+ }
752
+ }
753
+ }
754
+ }
755
+ determine_value_of_trade_goods_naval_supplies = {
756
+ set_variable = {
757
+ which = base_value_naval_supplies
758
+ value = 2
759
+ }
760
+ if = {
761
+ limit = {
762
+ has_chance_scaling_cost = yes
763
+ }
764
+ set_variable = {
765
+ which = chance_modifier_naval_supplies
766
+ value = 1
767
+ }
768
+ if = {
769
+ limit = {
770
+ ROOT = {
771
+ region = carribeans_region
772
+ }
773
+ }
774
+ multiply_variable = {
775
+ which = chance_modifier_naval_supplies
776
+ value = 0.65
777
+ }
778
+ }
779
+ if = {
780
+ limit = {
781
+ ROOT = {
782
+ OR = {
783
+ has_terrain = mountain
784
+ has_terrain = grasslands
785
+ region = central_africa_region
786
+ }
787
+ }
788
+ }
789
+ multiply_variable = {
790
+ which = chance_modifier_naval_supplies
791
+ value = 0.5
792
+ }
793
+ }
794
+ if = {
795
+ limit = {
796
+ NOT = { num_of_ports = 1 }
797
+ }
798
+ multiply_variable = {
799
+ which = chance_modifier_naval_supplies
800
+ value = 0.5
801
+ }
802
+ }
803
+ if = {
804
+ limit = {
805
+ ROOT = {
806
+ OR = {
807
+ has_terrain = coastline
808
+ has_climate = tropical
809
+ }
810
+ }
811
+ }
812
+ multiply_variable = {
813
+ which = chance_modifier_naval_supplies
814
+ value = 0.75
815
+ }
816
+ }
817
+ if = {
818
+ limit = {
819
+ ROOT = {
820
+ OR = {
821
+ has_terrain = forest
822
+ has_terrain = woods
823
+ has_terrain = hills
824
+ has_terrain = jungle
825
+ }
826
+ }
827
+ }
828
+ multiply_variable = {
829
+ which = chance_modifier_naval_supplies
830
+ value = 1.5
831
+ }
832
+ }
833
+ if = {
834
+ limit = {
835
+ OR = {
836
+ has_increased_trade_goods_discovery = { trade_goods = naval_supplies }
837
+ colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = naval_supplies } }
838
+ }
839
+ }
840
+ multiply_variable = {
841
+ which = chance_modifier_naval_supplies
842
+ value = 2
843
+ }
844
+ }
845
+ if = {
846
+ limit = {
847
+ NOT = {
848
+ is_variable_equal = {
849
+ which = chance_modifier_naval_supplies
850
+ value = 0
851
+ }
852
+ }
853
+ }
854
+ divide_variable = {
855
+ which = base_value_naval_supplies
856
+ which = chance_modifier_naval_supplies
857
+ }
858
+ }
859
+ }
860
+ }
861
+ determine_value_of_trade_goods_copper = {
862
+ set_variable = {
863
+ which = base_value_copper
864
+ value = 3
865
+ }
866
+ if = {
867
+ limit = {
868
+ has_chance_scaling_cost = yes
869
+ }
870
+ set_variable = {
871
+ which = chance_modifier_copper
872
+ value = 1
873
+ }
874
+ if = {
875
+ limit = {
876
+ ROOT = {
877
+ region = central_africa_region
878
+ }
879
+ }
880
+ multiply_variable = {
881
+ which = chance_modifier_copper
882
+ value = 0.7
883
+ }
884
+ }
885
+ if = {
886
+ limit = {
887
+ ROOT = {
888
+ is_random_new_world = yes
889
+ OR = {
890
+ has_terrain = mountain
891
+ has_terrain = highlands
892
+ }
893
+ }
894
+ }
895
+ multiply_variable = {
896
+ which = chance_modifier_copper
897
+ value = 1.1
898
+ }
899
+ }
900
+ if = {
901
+ limit = {
902
+ ROOT = {
903
+ OR = {
904
+ area = minas_gerais_area
905
+ area = diamantina_area
906
+ area = mato_grosso_area
907
+ area = ofaie_area
908
+ area = great_valley_area
909
+ area = susquehanna_area
910
+ area = hudson_valley_area
911
+ area = lake_superior_area
912
+ area = south_iroquoisia_area
913
+ region = west_siberia_region
914
+ region = east_siberia_region
915
+ }
916
+ }
917
+ }
918
+ multiply_variable = {
919
+ which = chance_modifier_copper
920
+ value = 1.5
921
+ }
922
+ }
923
+ if = {
924
+ limit = {
925
+ OR = {
926
+ has_increased_trade_goods_discovery = { trade_goods = copper }
927
+ colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = copper } }
928
+ }
929
+ }
930
+ multiply_variable = {
931
+ which = chance_modifier_copper
932
+ value = 2
933
+ }
934
+ }
935
+ if = {
936
+ limit = {
937
+ NOT = {
938
+ is_variable_equal = {
939
+ which = chance_modifier_copper
940
+ value = 0
941
+ }
942
+ }
943
+ }
944
+ divide_variable = {
945
+ which = base_value_copper
946
+ which = chance_modifier_copper
947
+ }
948
+ }
949
+ }
950
+ }
951
+ determine_value_of_trade_goods_gold = {
952
+ set_variable = {
953
+ which = base_value_gold
954
+ value = 10
955
+ }
956
+ if = {
957
+ limit = {
958
+ #has_chance_scaling_cost = yes
959
+ always = no
960
+ }
961
+ set_variable = {
962
+ which = chance_modifier_gold
963
+ value = 1
964
+ }
965
+ if = {
966
+ limit = {
967
+ ROOT = {
968
+ is_random_new_world = yes
969
+ has_terrain = mountain
970
+ continent = new_world #Always in RNW
971
+ }
972
+ }
973
+ multiply_variable = {
974
+ which = chance_modifier_gold
975
+ value = 1.5
976
+ }
977
+ }
978
+ if = {
979
+ limit = {
980
+ ROOT = {
981
+ normal_or_historical_nations = no
982
+ }
983
+ }
984
+ multiply_variable = {
985
+ which = chance_modifier_gold
986
+ value = 1.5
987
+ }
988
+ }
989
+ if = {
990
+ limit = {
991
+ ROOT = {
992
+ region = peru_region
993
+ }
994
+ }
995
+ multiply_variable = {
996
+ which = chance_modifier_gold
997
+ value = 3.5
998
+ }
999
+ }
1000
+ if = {
1001
+ limit = {
1002
+ ROOT = {
1003
+ OR = {
1004
+ province_id = 852 # Mexico
1005
+ province_id = 853 # Huastec
1006
+ province_id = 854 # Sayultecas
1007
+ province_id = 2617 # Huichol
1008
+ province_id = 856 # Zacatecas
1009
+ province_id = 857 # Guichichil
1010
+ province_id = 858 # Tamaulipas
1011
+ province_id = 2615 # Guamares
1012
+ province_id = 4781 # Transvaal (Johannesburg mines)
1013
+ }
1014
+ }
1015
+ }
1016
+ multiply_variable = {
1017
+ which = chance_modifier_gold
1018
+ value = 4
1019
+ }
1020
+ }
1021
+ if = {
1022
+ limit = {
1023
+ ROOT = {
1024
+ OR = {
1025
+ area = minas_gerais_area
1026
+ area = diamantina_area
1027
+ area = mato_grosso_area
1028
+ area = ofaie_area
1029
+ area = goias_area
1030
+ area = pontal_area
1031
+ }
1032
+ }
1033
+ }
1034
+ multiply_variable = {
1035
+ which = chance_modifier_gold
1036
+ value = 3.5
1037
+ }
1038
+ }
1039
+ if = {
1040
+ limit = {
1041
+ OR = {
1042
+ has_country_flag = por_bandeirantes_flag
1043
+ colonial_parent = { has_country_flag = por_bandeirantes_flag }
1044
+ }
1045
+ }
1046
+ multiply_variable = {
1047
+ which = chance_modifier_gold
1048
+ value = 2
1049
+ }
1050
+ }
1051
+ if = {
1052
+ limit = {
1053
+ OR = {
1054
+ has_increased_trade_goods_discovery = { trade_goods = gold }
1055
+ colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = gold } }
1056
+ }
1057
+ }
1058
+ multiply_variable = {
1059
+ which = chance_modifier_gold
1060
+ value = 2
1061
+ }
1062
+ }
1063
+ if = {
1064
+ limit = {
1065
+ ROOT = {
1066
+ province_id = 856
1067
+ }
1068
+ }
1069
+ multiply_variable = {
1070
+ which = chance_modifier_gold
1071
+ value = 100
1072
+ }
1073
+ }
1074
+ if = {
1075
+ limit = {
1076
+ NOT = {
1077
+ is_variable_equal = {
1078
+ which = chance_modifier_gold
1079
+ value = 0
1080
+ }
1081
+ }
1082
+ }
1083
+ divide_variable = {
1084
+ which = base_value_gold
1085
+ which = chance_modifier_gold
1086
+ }
1087
+ }
1088
+ }
1089
+ }
1090
+ determine_value_of_trade_goods_iron = {
1091
+ set_variable = {
1092
+ which = base_value_iron
1093
+ value = 3
1094
+ }
1095
+ if = {
1096
+ limit = {
1097
+ has_chance_scaling_cost = yes
1098
+ }
1099
+ set_variable = {
1100
+ which = chance_modifier_iron
1101
+ value = 1
1102
+ }
1103
+ if = {
1104
+ limit = {
1105
+ ROOT = {
1106
+ normal_or_historical_nations = no
1107
+ OR = {
1108
+ has_terrain = mountain
1109
+ has_terrain = hills
1110
+ has_terrain = highlands
1111
+ province_id = 990
1112
+ }
1113
+ }
1114
+ }
1115
+ multiply_variable = {
1116
+ which = chance_modifier_iron
1117
+ value = 1.2
1118
+ }
1119
+ }
1120
+ if = {
1121
+ limit = {
1122
+ ROOT = {
1123
+ province_id = 990
1124
+ }
1125
+ }
1126
+ multiply_variable = {
1127
+ which = chance_modifier_iron
1128
+ value = 20
1129
+ }
1130
+ }
1131
+ if = {
1132
+ limit = {
1133
+ NOT = {
1134
+ is_variable_equal = {
1135
+ which = chance_modifier_iron
1136
+ value = 0
1137
+ }
1138
+ }
1139
+ }
1140
+ divide_variable = {
1141
+ which = base_value_iron
1142
+ which = chance_modifier_iron
1143
+ }
1144
+ }
1145
+ }
1146
+ }
1147
+ determine_value_of_trade_goods_slaves = {
1148
+ set_variable = {
1149
+ which = base_value_slaves
1150
+ value = 2
1151
+ }
1152
+ if = {
1153
+ limit = {
1154
+ has_chance_scaling_cost = yes
1155
+ }
1156
+ set_variable = {
1157
+ which = chance_modifier_slaves
1158
+ value = 1
1159
+ }
1160
+ if = {
1161
+ limit = {
1162
+ ROOT = {
1163
+ OR = {
1164
+ region = horn_of_africa_region
1165
+ region = kongo_region
1166
+ area = west_africa_coast_area
1167
+ area = gulf_of_guinea_area
1168
+ area = benin_area
1169
+ }
1170
+ }
1171
+ }
1172
+ multiply_variable = {
1173
+ which = chance_modifier_slaves
1174
+ value = 2
1175
+ }
1176
+ }
1177
+ if = {
1178
+ limit = {
1179
+ ROOT = {
1180
+ region = south_africa_region
1181
+ }
1182
+ }
1183
+ multiply_variable = {
1184
+ which = chance_modifier_slaves
1185
+ value = 0.5
1186
+ }
1187
+ }
1188
+ if = {
1189
+ limit = {
1190
+ has_country_flag = encourage_cash_crops_flag
1191
+ }
1192
+ multiply_variable = {
1193
+ which = chance_modifier_slaves
1194
+ value = 2
1195
+ }
1196
+ }
1197
+ if = {
1198
+ limit = {
1199
+ OR = {
1200
+ has_increased_trade_goods_discovery = { trade_goods = slaves }
1201
+ colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = slaves } }
1202
+ }
1203
+ }
1204
+ multiply_variable = {
1205
+ which = chance_modifier_slaves
1206
+ value = 2
1207
+ }
1208
+ }
1209
+ if = {
1210
+ limit = {
1211
+ NOT = {
1212
+ is_variable_equal = {
1213
+ which = chance_modifier_slaves
1214
+ value = 0
1215
+ }
1216
+ }
1217
+ }
1218
+ divide_variable = {
1219
+ which = base_value_slaves
1220
+ which = chance_modifier_slaves
1221
+ }
1222
+ }
1223
+ }
1224
+ }
1225
+ determine_value_of_trade_goods_ivory = {
1226
+ set_variable = {
1227
+ which = base_value_ivory
1228
+ value = 4
1229
+ }
1230
+ if = {
1231
+ limit = {
1232
+ has_chance_scaling_cost = yes
1233
+ }
1234
+ set_variable = {
1235
+ which = chance_modifier_ivory
1236
+ value = 1
1237
+ }
1238
+ if = {
1239
+ limit = {
1240
+ ROOT = {
1241
+ OR = {
1242
+ region = malaya_region
1243
+ region = moluccas_region
1244
+ region = indonesia_region
1245
+ }
1246
+ }
1247
+ }
1248
+ multiply_variable = {
1249
+ which = chance_modifier_ivory
1250
+ value = 0.5
1251
+ }
1252
+ }
1253
+ if = {
1254
+ limit = {
1255
+ ROOT = {
1256
+ OR = {
1257
+ has_terrain = jungle
1258
+ has_terrain = savannah
1259
+ }
1260
+ }
1261
+ }
1262
+ multiply_variable = {
1263
+ which = chance_modifier_ivory
1264
+ value = 1.25
1265
+ }
1266
+ }
1267
+ if = {
1268
+ limit = {
1269
+ has_country_flag = encourage_cash_crops_flag
1270
+ }
1271
+ multiply_variable = {
1272
+ which = chance_modifier_ivory
1273
+ value = 2
1274
+ }
1275
+ }
1276
+ if = {
1277
+ limit = {
1278
+ OR = {
1279
+ has_increased_trade_goods_discovery = { trade_goods = ivory }
1280
+ colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = ivory } }
1281
+ }
1282
+ }
1283
+ multiply_variable = {
1284
+ which = chance_modifier_ivory
1285
+ value = 2
1286
+ }
1287
+ }
1288
+ if = {
1289
+ limit = {
1290
+ NOT = {
1291
+ is_variable_equal = {
1292
+ which = chance_modifier_ivory
1293
+ value = 0
1294
+ }
1295
+ }
1296
+ }
1297
+ divide_variable = {
1298
+ which = base_value_ivory
1299
+ which = chance_modifier_ivory
1300
+ }
1301
+ }
1302
+ }
1303
+ }
1304
+ determine_value_of_trade_goods_tea = {
1305
+ set_variable = {
1306
+ which = base_value_tea
1307
+ value = 3
1308
+ }
1309
+ if = {
1310
+ limit = {
1311
+ has_chance_scaling_cost = yes
1312
+ }
1313
+ set_variable = {
1314
+ which = chance_modifier_tea
1315
+ value = 1
1316
+ }
1317
+ if = {
1318
+ limit = {
1319
+ ROOT = {
1320
+ has_terrain = farmlands
1321
+ }
1322
+ }
1323
+ multiply_variable = {
1324
+ which = chance_modifier_tea
1325
+ value = 1.2
1326
+ }
1327
+ }
1328
+ if = {
1329
+ limit = {
1330
+ ROOT = {
1331
+ OR = {
1332
+ area = assam_area
1333
+ AND = {
1334
+ has_climate = tropical
1335
+ is_random_new_world = yes
1336
+ }
1337
+ }
1338
+ }
1339
+ }
1340
+ multiply_variable = {
1341
+ which = chance_modifier_tea
1342
+ value = 1.5
1343
+ }
1344
+ }
1345
+ if = {
1346
+ limit = {
1347
+ ROOT = {
1348
+ OR = {
1349
+ area = banda_oriental_area #Yerba Mate
1350
+ area = rio_grande_do_sol_area #Yerba Mate
1351
+ area = buenos_aires_area #Yerba Mate
1352
+ area = misiones_area #Yerba Mate
1353
+ area = beni_area #Yerba Mate
1354
+ area = moxos_area #Yerba Mate
1355
+ area = paraguay_area #Yerba Mate
1356
+ area = sao_paolo_area #Yerba Mate
1357
+ area = west_sao_paolo_area #Yerba Mate
1358
+ }
1359
+ }
1360
+ }
1361
+ multiply_variable = {
1362
+ which = chance_modifier_tea
1363
+ value = 1.5
1364
+ }
1365
+ }
1366
+ if = {
1367
+ limit = {
1368
+ OR = {
1369
+ has_increased_trade_goods_discovery = { trade_goods = tea }
1370
+ colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = tea } }
1371
+ }
1372
+ }
1373
+ multiply_variable = {
1374
+ which = chance_modifier_tea
1375
+ value = 2
1376
+ }
1377
+ }
1378
+ if = {
1379
+ limit = {
1380
+ has_country_flag = encourage_cash_crops_flag
1381
+ }
1382
+ multiply_variable = {
1383
+ which = chance_modifier_tea
1384
+ value = 2
1385
+ }
1386
+ }
1387
+ if = {
1388
+ limit = {
1389
+ NOT = {
1390
+ is_variable_equal = {
1391
+ which = chance_modifier_tea
1392
+ value = 0
1393
+ }
1394
+ }
1395
+ }
1396
+ divide_variable = {
1397
+ which = base_value_tea
1398
+ which = chance_modifier_tea
1399
+ }
1400
+ }
1401
+ }
1402
+ }
1403
+ determine_value_of_trade_goods_chinaware = {
1404
+ set_variable = {
1405
+ which = base_value_chinaware
1406
+ value = 3
1407
+ }
1408
+ if = {
1409
+ limit = {
1410
+ has_chance_scaling_cost = yes
1411
+ }
1412
+ set_variable = {
1413
+ which = chance_modifier_chinaware
1414
+ value = 1
1415
+ }
1416
+ if = {
1417
+ limit = {
1418
+ has_country_flag = encourage_cash_crops_flag
1419
+ }
1420
+ multiply_variable = {
1421
+ which = chance_modifier_chinaware
1422
+ value = 2
1423
+ }
1424
+ }
1425
+ if = {
1426
+ limit = {
1427
+ OR = {
1428
+ has_increased_trade_goods_discovery = { trade_goods = chinaware }
1429
+ colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = chinaware } }
1430
+ }
1431
+ }
1432
+ multiply_variable = {
1433
+ which = chance_modifier_chinaware
1434
+ value = 2
1435
+ }
1436
+ }
1437
+ if = {
1438
+ limit = {
1439
+ NOT = {
1440
+ is_variable_equal = {
1441
+ which = chance_modifier_chinaware
1442
+ value = 0
1443
+ }
1444
+ }
1445
+ }
1446
+ divide_variable = {
1447
+ which = base_value_chinaware
1448
+ which = chance_modifier_chinaware
1449
+ }
1450
+ }
1451
+ }
1452
+ }
1453
+ determine_value_of_trade_goods_spices = {
1454
+ set_variable = {
1455
+ which = base_value_spices
1456
+ value = 3
1457
+ }
1458
+ if = {
1459
+ limit = {
1460
+ has_chance_scaling_cost = yes
1461
+ }
1462
+ set_variable = {
1463
+ which = chance_modifier_spices
1464
+ value = 1
1465
+ }
1466
+ if = {
1467
+ limit = {
1468
+ ROOT = {
1469
+ area = indian_ocean_islands_area
1470
+ }
1471
+ }
1472
+ multiply_variable = {
1473
+ which = chance_modifier_spices
1474
+ value = 0.75
1475
+ }
1476
+ }
1477
+ if = {
1478
+ limit = {
1479
+ ROOT = {
1480
+ OR = {
1481
+ continent = north_america
1482
+ continent = south_america
1483
+ }
1484
+ }
1485
+ }
1486
+ multiply_variable = {
1487
+ which = chance_modifier_spices
1488
+ value = 0.5
1489
+ }
1490
+ }
1491
+ if = {
1492
+ limit = {
1493
+ ROOT = {
1494
+ OR = {
1495
+ region = malaya_region
1496
+ region = indonesia_region
1497
+ region = moluccas_region
1498
+ }
1499
+ }
1500
+ }
1501
+ multiply_variable = {
1502
+ which = chance_modifier_spices
1503
+ value = 1.25
1504
+ }
1505
+ }
1506
+ if = {
1507
+ limit = {
1508
+ has_country_flag = encourage_cash_crops_flag
1509
+ }
1510
+ multiply_variable = {
1511
+ which = chance_modifier_spices
1512
+ value = 2
1513
+ }
1514
+ }
1515
+ if = {
1516
+ limit = {
1517
+ OR = {
1518
+ has_increased_trade_goods_discovery = { trade_goods = spices }
1519
+ colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = spices } }
1520
+ }
1521
+ }
1522
+ multiply_variable = {
1523
+ which = chance_modifier_spices
1524
+ value = 2
1525
+ }
1526
+ }
1527
+ if = {
1528
+ limit = {
1529
+ NOT = {
1530
+ is_variable_equal = {
1531
+ which = chance_modifier_spices
1532
+ value = 0
1533
+ }
1534
+ }
1535
+ }
1536
+ divide_variable = {
1537
+ which = base_value_spices
1538
+ which = chance_modifier_spices
1539
+ }
1540
+ }
1541
+ }
1542
+ }
1543
+ determine_value_of_trade_goods_coffee = {
1544
+ set_variable = {
1545
+ which = base_value_coffee
1546
+ value = 3
1547
+ }
1548
+ if = {
1549
+ limit = {
1550
+ has_chance_scaling_cost = yes
1551
+ }
1552
+ set_variable = {
1553
+ which = chance_modifier_coffee
1554
+ value = 1
1555
+ }
1556
+ if = {
1557
+ limit = {
1558
+ ROOT = {
1559
+ region = colombia_region
1560
+ }
1561
+ }
1562
+ multiply_variable = {
1563
+ which = chance_modifier_coffee
1564
+ value = 1.5
1565
+ }
1566
+ }
1567
+ if = {
1568
+ limit = {
1569
+ has_country_flag = encourage_cash_crops_flag
1570
+ }
1571
+ multiply_variable = {
1572
+ which = chance_modifier_coffee
1573
+ value = 2
1574
+ }
1575
+ }
1576
+ if = {
1577
+ limit = {
1578
+ OR = {
1579
+ has_increased_trade_goods_discovery = { trade_goods = coffee }
1580
+ colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = coffee } }
1581
+ }
1582
+ }
1583
+ multiply_variable = {
1584
+ which = chance_modifier_coffee
1585
+ value = 2
1586
+ }
1587
+ }
1588
+ if = {
1589
+ limit = {
1590
+ NOT = {
1591
+ is_variable_equal = {
1592
+ which = chance_modifier_coffee
1593
+ value = 0
1594
+ }
1595
+ }
1596
+ }
1597
+ divide_variable = {
1598
+ which = base_value_coffee
1599
+ which = chance_modifier_coffee
1600
+ }
1601
+ }
1602
+ }
1603
+ }
1604
+ determine_value_of_trade_goods_cotton = {
1605
+ set_variable = {
1606
+ which = base_value_cotton
1607
+ value = 3
1608
+ }
1609
+ if = {
1610
+ limit = {
1611
+ has_chance_scaling_cost = yes
1612
+ }
1613
+ set_variable = {
1614
+ which = chance_modifier_cotton
1615
+ value = 1
1616
+ }
1617
+ if = {
1618
+ limit = {
1619
+ ROOT = {
1620
+ OR = {
1621
+ has_terrain = farmlands
1622
+ has_terrain = grasslands
1623
+ region = southeast_america_region
1624
+ }
1625
+ }
1626
+ }
1627
+ multiply_variable = {
1628
+ which = chance_modifier_cotton
1629
+ value = 1.5
1630
+ }
1631
+ }
1632
+ if = {
1633
+ limit = {
1634
+ has_country_flag = encourage_cash_crops_flag
1635
+ }
1636
+ multiply_variable = {
1637
+ which = chance_modifier_cotton
1638
+ value = 2
1639
+ }
1640
+ }
1641
+ if = {
1642
+ limit = {
1643
+ OR = {
1644
+ has_increased_trade_goods_discovery = { trade_goods = cotton }
1645
+ colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = cotton } }
1646
+ }
1647
+ }
1648
+ multiply_variable = {
1649
+ which = chance_modifier_cotton
1650
+ value = 2
1651
+ }
1652
+ }
1653
+ if = {
1654
+ limit = {
1655
+ NOT = {
1656
+ is_variable_equal = {
1657
+ which = chance_modifier_cotton
1658
+ value = 0
1659
+ }
1660
+ }
1661
+ }
1662
+ divide_variable = {
1663
+ which = base_value_cotton
1664
+ which = chance_modifier_cotton
1665
+ }
1666
+ }
1667
+ }
1668
+ }
1669
+ determine_value_of_trade_goods_sugar = {
1670
+ set_variable = {
1671
+ which = base_value_sugar
1672
+ value = 3
1673
+ }
1674
+ if = {
1675
+ limit = {
1676
+ has_chance_scaling_cost = yes
1677
+ }
1678
+ set_variable = {
1679
+ which = chance_modifier_sugar
1680
+ value = 1
1681
+ }
1682
+ if = {
1683
+ limit = {
1684
+ ROOT = {
1685
+ is_random_new_world = no
1686
+ NOT = { province_id = 481 }
1687
+ OR = {
1688
+ region = carribeans_region
1689
+ area = ceara_area
1690
+ area = pernambuco_area
1691
+ area = bahia_area
1692
+ area = guyana_area
1693
+ area = suriname_area
1694
+ }
1695
+ }
1696
+ }
1697
+ multiply_variable = {
1698
+ which = chance_modifier_sugar
1699
+ value = 2.5
1700
+ }
1701
+ }
1702
+ if = {
1703
+ limit = {
1704
+ has_country_flag = encourage_cash_crops_flag
1705
+ }
1706
+ multiply_variable = {
1707
+ which = chance_modifier_sugar
1708
+ value = 2
1709
+ }
1710
+ }
1711
+ if = {
1712
+ limit = {
1713
+ OR = {
1714
+ has_increased_trade_goods_discovery = { trade_goods = sugar }
1715
+ colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = sugar } }
1716
+ }
1717
+ }
1718
+ multiply_variable = {
1719
+ which = chance_modifier_sugar
1720
+ value = 2
1721
+ }
1722
+ }
1723
+ if = {
1724
+ limit = {
1725
+ NOT = {
1726
+ is_variable_equal = {
1727
+ which = chance_modifier_sugar
1728
+ value = 0
1729
+ }
1730
+ }
1731
+ }
1732
+ divide_variable = {
1733
+ which = base_value_sugar
1734
+ which = chance_modifier_sugar
1735
+ }
1736
+ }
1737
+ }
1738
+ }
1739
+ determine_value_of_trade_goods_tobacco = {
1740
+ set_variable = {
1741
+ which = base_value_tobacco
1742
+ value = 3
1743
+ }
1744
+ if = {
1745
+ limit = {
1746
+ has_chance_scaling_cost = yes
1747
+ }
1748
+ set_variable = {
1749
+ which = chance_modifier_tobacco
1750
+ value = 1
1751
+ }
1752
+ if = {
1753
+ limit = {
1754
+ ROOT = {
1755
+ OR = {
1756
+ region = northeast_america_region
1757
+ region = southeast_america_region
1758
+ }
1759
+ }
1760
+ }
1761
+ multiply_variable = {
1762
+ which = chance_modifier_tobacco
1763
+ value = 2.5
1764
+ }
1765
+ }
1766
+ if = {
1767
+ limit = {
1768
+ ROOT = {
1769
+ region = australia_region
1770
+ }
1771
+ }
1772
+ multiply_variable = {
1773
+ which = chance_modifier_tobacco
1774
+ value = 0.2
1775
+ }
1776
+ }
1777
+ if = {
1778
+ limit = {
1779
+ has_country_flag = encourage_cash_crops_flag
1780
+ }
1781
+ multiply_variable = {
1782
+ which = chance_modifier_tobacco
1783
+ value = 2
1784
+ }
1785
+ }
1786
+ if = {
1787
+ limit = {
1788
+ OR = {
1789
+ has_increased_trade_goods_discovery = { trade_goods = tobacco }
1790
+ colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = tobacco } }
1791
+ }
1792
+ }
1793
+ multiply_variable = {
1794
+ which = chance_modifier_tobacco
1795
+ value = 2
1796
+ }
1797
+ }
1798
+ if = {
1799
+ limit = {
1800
+ NOT = {
1801
+ is_variable_equal = {
1802
+ which = chance_modifier_tobacco
1803
+ value = 0
1804
+ }
1805
+ }
1806
+ }
1807
+ divide_variable = {
1808
+ which = base_value_tobacco
1809
+ which = chance_modifier_tobacco
1810
+ }
1811
+ }
1812
+ }
1813
+ }
1814
+ determine_value_of_trade_goods_cocoa = {
1815
+ set_variable = {
1816
+ which = base_value_cocoa
1817
+ value = 4
1818
+ }
1819
+ if = {
1820
+ limit = {
1821
+ has_chance_scaling_cost = yes
1822
+ }
1823
+ set_variable = {
1824
+ which = chance_modifier_cocoa
1825
+ value = 1
1826
+ }
1827
+ if = {
1828
+ limit = {
1829
+ OR = {
1830
+ has_increased_trade_goods_discovery = { trade_goods = cocoa }
1831
+ colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = cocoa } }
1832
+ }
1833
+ }
1834
+ multiply_variable = {
1835
+ which = chance_modifier_cocoa
1836
+ value = 2
1837
+ }
1838
+ }
1839
+ if = {
1840
+ limit = {
1841
+ NOT = {
1842
+ is_variable_equal = {
1843
+ which = chance_modifier_cocoa
1844
+ value = 0
1845
+ }
1846
+ }
1847
+ }
1848
+ divide_variable = {
1849
+ which = base_value_cocoa
1850
+ which = chance_modifier_cocoa
1851
+ }
1852
+ }
1853
+ }
1854
+ }
1855
+ determine_value_of_trade_goods_silk = {
1856
+ set_variable = {
1857
+ which = base_value_silk
1858
+ value = 4
1859
+ }
1860
+ if = {
1861
+ limit = {
1862
+ has_chance_scaling_cost = yes
1863
+ }
1864
+ set_variable = {
1865
+ which = chance_modifier_silk
1866
+ value = 1
1867
+ }
1868
+ if = {
1869
+ limit = {
1870
+ ROOT = {
1871
+ normal_or_historical_nations = no
1872
+ FROM = { NOT = { religion_group = dharmic } }
1873
+ FROM = { NOT = { religion_group = eastern } }
1874
+ }
1875
+ }
1876
+ multiply_variable = {
1877
+ which = chance_modifier_silk
1878
+ value = 0.5
1879
+ }
1880
+ }
1881
+ if = {
1882
+ limit = {
1883
+ ROOT = {
1884
+ normal_or_historical_nations = no
1885
+ OR = {
1886
+ region = south_china_region
1887
+ region = xinan_region
1888
+ region = north_china_region
1889
+ region = hindusthan_region
1890
+ region = bengal_region
1891
+ region = deccan_region
1892
+ region = coromandel_region
1893
+ }
1894
+ development_discounting_tribal = 20
1895
+ }
1896
+ }
1897
+ multiply_variable = {
1898
+ which = chance_modifier_silk
1899
+ value = 1.5
1900
+ }
1901
+ }
1902
+ if = {
1903
+ limit = {
1904
+ has_country_flag = encourage_cash_crops_flag
1905
+ }
1906
+ multiply_variable = {
1907
+ which = chance_modifier_silk
1908
+ value = 2
1909
+ }
1910
+ }
1911
+ if = {
1912
+ limit = {
1913
+ OR = {
1914
+ has_increased_trade_goods_discovery = { trade_goods = silk }
1915
+ colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = silk } }
1916
+ }
1917
+ }
1918
+ multiply_variable = {
1919
+ which = chance_modifier_silk
1920
+ value = 2
1921
+ }
1922
+ }
1923
+ if = {
1924
+ limit = {
1925
+ NOT = {
1926
+ is_variable_equal = {
1927
+ which = chance_modifier_silk
1928
+ value = 0
1929
+ }
1930
+ }
1931
+ }
1932
+ divide_variable = {
1933
+ which = base_value_silk
1934
+ which = chance_modifier_silk
1935
+ }
1936
+ }
1937
+ }
1938
+ }
1939
+ determine_value_of_trade_goods_dyes = {
1940
+ set_variable = {
1941
+ which = base_value_dyes
1942
+ value = 4
1943
+ }
1944
+ if = {
1945
+ limit = {
1946
+ has_chance_scaling_cost = yes
1947
+ }
1948
+ set_variable = {
1949
+ which = chance_modifier_dyes
1950
+ value = 1
1951
+ }
1952
+ if = {
1953
+ limit = {
1954
+ has_country_flag = encourage_cash_crops_flag
1955
+ }
1956
+ multiply_variable = {
1957
+ which = chance_modifier_dyes
1958
+ value = 2
1959
+ }
1960
+ }
1961
+ if = {
1962
+ limit = {
1963
+ OR = {
1964
+ has_increased_trade_goods_discovery = { trade_goods = dyes }
1965
+ colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = dyes } }
1966
+ }
1967
+ }
1968
+ multiply_variable = {
1969
+ which = chance_modifier_dyes
1970
+ value = 2
1971
+ }
1972
+ }
1973
+ if = {
1974
+ limit = {
1975
+ NOT = {
1976
+ is_variable_equal = {
1977
+ which = chance_modifier_dyes
1978
+ value = 0
1979
+ }
1980
+ }
1981
+ }
1982
+ divide_variable = {
1983
+ which = base_value_dyes
1984
+ which = chance_modifier_dyes
1985
+ }
1986
+ }
1987
+ }
1988
+ }
1989
+ determine_value_of_trade_goods_tropical_wood = {
1990
+ set_variable = {
1991
+ which = base_value_tropical_wood
1992
+ value = 2
1993
+ }
1994
+ if = {
1995
+ limit = {
1996
+ has_chance_scaling_cost = yes
1997
+ }
1998
+ set_variable = {
1999
+ which = chance_modifier_tropical_wood
2000
+ value = 1
2001
+ }
2002
+ if = {
2003
+ limit = {
2004
+ ROOT = {
2005
+ area = amazon_area
2006
+ }
2007
+ }
2008
+ multiply_variable = {
2009
+ which = chance_modifier_tropical_wood
2010
+ value = 2
2011
+ }
2012
+ }
2013
+ if = {
2014
+ limit = {
2015
+ ROOT = {
2016
+ OR = {
2017
+ region = malaya_region
2018
+ region = moluccas_region
2019
+ region = indonesia_region
2020
+ }
2021
+ }
2022
+ }
2023
+ multiply_variable = {
2024
+ which = chance_modifier_tropical_wood
2025
+ value = 0.5
2026
+ }
2027
+ }
2028
+ if = {
2029
+ limit = {
2030
+ has_country_flag = encourage_cash_crops_flag
2031
+ }
2032
+ multiply_variable = {
2033
+ which = chance_modifier_tropical_wood
2034
+ value = 2
2035
+ }
2036
+ }
2037
+ if = {
2038
+ limit = {
2039
+ OR = {
2040
+ has_increased_trade_goods_discovery = { trade_goods = tropical_wood }
2041
+ colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = tropical_wood } }
2042
+ }
2043
+ }
2044
+ multiply_variable = {
2045
+ which = chance_modifier_tropical_wood
2046
+ value = 2
2047
+ }
2048
+ }
2049
+ if = {
2050
+ limit = {
2051
+ NOT = {
2052
+ is_variable_equal = {
2053
+ which = chance_modifier_tropical_wood
2054
+ value = 0
2055
+ }
2056
+ }
2057
+ }
2058
+ divide_variable = {
2059
+ which = base_value_tropical_wood
2060
+ which = chance_modifier_tropical_wood
2061
+ }
2062
+ }
2063
+ }
2064
+ }
2065
+ determine_value_of_trade_goods_livestock = {
2066
+ set_variable = {
2067
+ which = base_value_livestock
2068
+ value = 2
2069
+ }
2070
+ if = {
2071
+ limit = {
2072
+ has_chance_scaling_cost = yes
2073
+ }
2074
+ set_variable = {
2075
+ which = chance_modifier_livestock
2076
+ value = 1
2077
+ }
2078
+ if = {
2079
+ limit = {
2080
+ ROOT = {
2081
+ province_id = 2002
2082
+ }
2083
+ }
2084
+ multiply_variable = {
2085
+ which = chance_modifier_livestock
2086
+ value = 0.05
2087
+ }
2088
+ }
2089
+ if = {
2090
+ limit = {
2091
+ ROOT = {
2092
+ has_winter = severe_winter
2093
+ }
2094
+ }
2095
+ multiply_variable = {
2096
+ which = chance_modifier_livestock
2097
+ value = 0.75
2098
+ }
2099
+ }
2100
+ if = {
2101
+ limit = {
2102
+ ROOT = {
2103
+ OR = {
2104
+ has_terrain = desert
2105
+ has_terrain = savannah
2106
+ has_terrain = highlands
2107
+ has_terrain = drylands
2108
+ has_climate = arid
2109
+ }
2110
+ }
2111
+ }
2112
+ multiply_variable = {
2113
+ which = chance_modifier_livestock
2114
+ value = 1.25
2115
+ }
2116
+ }
2117
+ if = {
2118
+ limit = {
2119
+ ROOT = {
2120
+ has_terrain = steppe
2121
+ }
2122
+ }
2123
+ multiply_variable = {
2124
+ which = chance_modifier_livestock
2125
+ value = 1.5
2126
+ }
2127
+ }
2128
+ if = {
2129
+ limit = {
2130
+ ROOT = {
2131
+ region = central_asia_region
2132
+ }
2133
+ }
2134
+ multiply_variable = {
2135
+ which = chance_modifier_livestock
2136
+ value = 1.5
2137
+ }
2138
+ }
2139
+ if = {
2140
+ limit = {
2141
+ ROOT = {
2142
+ region = mongolia_region
2143
+ }
2144
+ }
2145
+ multiply_variable = {
2146
+ which = chance_modifier_livestock
2147
+ value = 1.5
2148
+ }
2149
+ }
2150
+ if = {
2151
+ limit = {
2152
+ ROOT = {
2153
+ region = tibet_region
2154
+ }
2155
+ }
2156
+ multiply_variable = {
2157
+ which = chance_modifier_livestock
2158
+ value = 1.5
2159
+ }
2160
+ }
2161
+ if = {
2162
+ limit = {
2163
+ ROOT = {
2164
+ region = central_africa_region
2165
+ }
2166
+ }
2167
+ multiply_variable = {
2168
+ which = chance_modifier_livestock
2169
+ value = 1.5
2170
+ }
2171
+ }
2172
+ if = {
2173
+ limit = {
2174
+ OR = {
2175
+ has_increased_trade_goods_discovery = { trade_goods = livestock }
2176
+ colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = livestock } }
2177
+ }
2178
+ }
2179
+ multiply_variable = {
2180
+ which = chance_modifier_livestock
2181
+ value = 2
2182
+ }
2183
+ }
2184
+ if = {
2185
+ limit = {
2186
+ NOT = {
2187
+ is_variable_equal = {
2188
+ which = chance_modifier_livestock
2189
+ value = 0
2190
+ }
2191
+ }
2192
+ }
2193
+ divide_variable = {
2194
+ which = base_value_livestock
2195
+ which = chance_modifier_livestock
2196
+ }
2197
+ }
2198
+ }
2199
+ }
2200
+ determine_value_of_trade_goods_incense = {
2201
+ set_variable = {
2202
+ which = base_value_incense
2203
+ value = 2.5
2204
+ }
2205
+ if = {
2206
+ limit = {
2207
+ has_chance_scaling_cost = yes
2208
+ }
2209
+ set_variable = {
2210
+ which = chance_modifier_incense
2211
+ value = 1
2212
+ }
2213
+ if = {
2214
+ limit = {
2215
+ ROOT = {
2216
+ area = indian_ocean_islands_area
2217
+ }
2218
+ }
2219
+ multiply_variable = {
2220
+ which = chance_modifier_incense
2221
+ value = 0.5
2222
+ }
2223
+ }
2224
+ if = {
2225
+ limit = {
2226
+ ROOT = {
2227
+ region = arabia_region
2228
+ }
2229
+ }
2230
+ multiply_variable = {
2231
+ which = chance_modifier_incense
2232
+ value = 1.25
2233
+ }
2234
+ }
2235
+ if = {
2236
+ limit = {
2237
+ has_country_flag = encourage_cash_crops_flag
2238
+ }
2239
+ multiply_variable = {
2240
+ which = chance_modifier_incense
2241
+ value = 2
2242
+ }
2243
+ }
2244
+ if = {
2245
+ limit = {
2246
+ OR = {
2247
+ has_increased_trade_goods_discovery = { trade_goods = incense }
2248
+ colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = incense } }
2249
+ }
2250
+ }
2251
+ multiply_variable = {
2252
+ which = chance_modifier_incense
2253
+ value = 2
2254
+ }
2255
+ }
2256
+ if = {
2257
+ limit = {
2258
+ NOT = {
2259
+ is_variable_equal = {
2260
+ which = chance_modifier_incense
2261
+ value = 0
2262
+ }
2263
+ }
2264
+ }
2265
+ divide_variable = {
2266
+ which = base_value_incense
2267
+ which = chance_modifier_incense
2268
+ }
2269
+ }
2270
+ }
2271
+ }
2272
+ determine_value_of_trade_goods_glass = {
2273
+ set_variable = {
2274
+ which = base_value_glass
2275
+ value = 3
2276
+ }
2277
+ if = {
2278
+ limit = {
2279
+ has_chance_scaling_cost = yes
2280
+ }
2281
+ set_variable = {
2282
+ which = chance_modifier_glass
2283
+ value = 1
2284
+ }
2285
+ if = {
2286
+ limit = {
2287
+ ROOT = {
2288
+ development_discounting_tribal = 22
2289
+ }
2290
+ }
2291
+ multiply_variable = {
2292
+ which = chance_modifier_glass
2293
+ value = 2
2294
+ }
2295
+ }
2296
+ if = {
2297
+ limit = {
2298
+ OR = {
2299
+ has_increased_trade_goods_discovery = { trade_goods = glass }
2300
+ colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = glass } }
2301
+ }
2302
+ }
2303
+ multiply_variable = {
2304
+ which = chance_modifier_glass
2305
+ value = 2
2306
+ }
2307
+ }
2308
+ if = {
2309
+ limit = {
2310
+ NOT = {
2311
+ is_variable_equal = {
2312
+ which = chance_modifier_glass
2313
+ value = 0
2314
+ }
2315
+ }
2316
+ }
2317
+ divide_variable = {
2318
+ which = base_value_glass
2319
+ which = chance_modifier_glass
2320
+ }
2321
+ }
2322
+ }
2323
+ }
2324
+ determine_value_of_trade_goods_paper = {
2325
+ set_variable = {
2326
+ which = base_value_paper
2327
+ value = 3.5
2328
+ }
2329
+ if = {
2330
+ limit = {
2331
+ has_chance_scaling_cost = yes
2332
+ }
2333
+ set_variable = {
2334
+ which = chance_modifier_paper
2335
+ value = 1
2336
+ }
2337
+ if = {
2338
+ limit = {
2339
+ ROOT = {
2340
+ development_discounting_tribal = 22
2341
+ }
2342
+ }
2343
+ multiply_variable = {
2344
+ which = chance_modifier_paper
2345
+ value = 2
2346
+ }
2347
+ }
2348
+ if = {
2349
+ limit = {
2350
+ OR = {
2351
+ has_increased_trade_goods_discovery = { trade_goods = paper }
2352
+ colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = paper } }
2353
+ }
2354
+ }
2355
+ multiply_variable = {
2356
+ which = chance_modifier_paper
2357
+ value = 2
2358
+ }
2359
+ }
2360
+ if = {
2361
+ limit = {
2362
+ NOT = {
2363
+ is_variable_equal = {
2364
+ which = chance_modifier_paper
2365
+ value = 0
2366
+ }
2367
+ }
2368
+ }
2369
+ divide_variable = {
2370
+ which = base_value_paper
2371
+ which = chance_modifier_paper
2372
+ }
2373
+ }
2374
+ }
2375
+ }
2376
+ determine_value_of_trade_goods_gems = {
2377
+ set_variable = {
2378
+ which = base_value_gems
2379
+ value = 4
2380
+ }
2381
+ if = {
2382
+ limit = {
2383
+ has_chance_scaling_cost = yes
2384
+ }
2385
+ set_variable = {
2386
+ which = chance_modifier_gems
2387
+ value = 1
2388
+ }
2389
+ if = {
2390
+ limit = {
2391
+ ROOT = {
2392
+ region = moluccas_region
2393
+ }
2394
+ }
2395
+ multiply_variable = {
2396
+ which = chance_modifier_gems
2397
+ value = 1.2
2398
+ }
2399
+ }
2400
+ if = {
2401
+ limit = {
2402
+ ROOT = {
2403
+ region = indonesia_region
2404
+ }
2405
+ }
2406
+ multiply_variable = {
2407
+ which = chance_modifier_gems
2408
+ value = 0.75
2409
+ }
2410
+ }
2411
+ if = {
2412
+ limit = {
2413
+ ROOT = {
2414
+ continent = oceania
2415
+ }
2416
+ }
2417
+ multiply_variable = {
2418
+ which = chance_modifier_gems
2419
+ value = 0.5
2420
+ }
2421
+ }
2422
+ if = {
2423
+ limit = {
2424
+ ROOT = {
2425
+ OR = {
2426
+ continent = south_america
2427
+ continent = north_america
2428
+ }
2429
+ }
2430
+ }
2431
+ multiply_variable = {
2432
+ which = chance_modifier_gems
2433
+ value = 1.5
2434
+ }
2435
+ }
2436
+ if = {
2437
+ limit = {
2438
+ ROOT = {
2439
+ OR = {
2440
+ area = diamantina_area
2441
+ area = bogota_area
2442
+ area = murray_river_area #Opal
2443
+ }
2444
+ }
2445
+ }
2446
+ multiply_variable = {
2447
+ which = chance_modifier_gems
2448
+ value = 2
2449
+ }
2450
+ }
2451
+ if = {
2452
+ limit = {
2453
+ ROOT = {
2454
+ OR = {
2455
+ province_id = 1093 #Opal
2456
+ province_id = 2736 #Opal
2457
+ province_id = 4862 #Opal
2458
+ }
2459
+ }
2460
+ }
2461
+ multiply_variable = {
2462
+ which = chance_modifier_gems
2463
+ value = 2
2464
+ }
2465
+ }
2466
+ if = {
2467
+ limit = {
2468
+ ROOT = {
2469
+ region = brazil_region
2470
+ }
2471
+ }
2472
+ multiply_variable = {
2473
+ which = chance_modifier_gems
2474
+ value = 1.5
2475
+ }
2476
+ }
2477
+ if = {
2478
+ limit = {
2479
+ ROOT = {
2480
+ OR = {
2481
+ has_terrain = mountain
2482
+ has_terrain = jungle
2483
+ has_terrain = hills
2484
+ has_terrain = highlands
2485
+ has_terrain = coastline #Pearls
2486
+ }
2487
+ }
2488
+ }
2489
+ multiply_variable = {
2490
+ which = chance_modifier_gems
2491
+ value = 1.5
2492
+ }
2493
+ }
2494
+ if = {
2495
+ limit = {
2496
+ ROOT = {
2497
+ is_random_new_world = yes
2498
+ has_terrain = mountain
2499
+ continent = new_world #Always in RNW
2500
+ }
2501
+ }
2502
+ multiply_variable = {
2503
+ which = chance_modifier_gems
2504
+ value = 1.5
2505
+ }
2506
+ }
2507
+ if = {
2508
+ limit = {
2509
+ ROOT = {
2510
+ normal_or_historical_nations = no
2511
+ }
2512
+ }
2513
+ multiply_variable = {
2514
+ which = chance_modifier_gems
2515
+ value = 1.5
2516
+ }
2517
+ }
2518
+ if = {
2519
+ limit = {
2520
+ has_country_flag = encourage_cash_crops_flag
2521
+ }
2522
+ multiply_variable = {
2523
+ which = chance_modifier_gems
2524
+ value = 1.5
2525
+ }
2526
+ }
2527
+ if = {
2528
+ limit = {
2529
+ OR = {
2530
+ has_increased_trade_goods_discovery = { trade_goods = gems }
2531
+ colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = gems } }
2532
+ }
2533
+ }
2534
+ multiply_variable = {
2535
+ which = chance_modifier_gems
2536
+ value = 1.5
2537
+ }
2538
+ }
2539
+ if = {
2540
+ limit = {
2541
+ NOT = {
2542
+ is_variable_equal = {
2543
+ which = chance_modifier_gems
2544
+ value = 0
2545
+ }
2546
+ }
2547
+ }
2548
+ divide_variable = {
2549
+ which = base_value_gems
2550
+ which = chance_modifier_gems
2551
+ }
2552
+ }
2553
+ }
2554
+ }
2555
+ determine_value_of_trade_goods_coal = {
2556
+ set_variable = {
2557
+ which = base_value_coal
2558
+ value = 10
2559
+ }
2560
+ if = {
2561
+ limit = {
2562
+ #has_chance_scaling_cost = yes
2563
+ always = no
2564
+ }
2565
+ set_variable = {
2566
+ which = chance_modifier_coal
2567
+ value = 1
2568
+ }
2569
+ if = {
2570
+ limit = {
2571
+ NOT = {
2572
+ is_variable_equal = {
2573
+ which = chance_modifier_coal
2574
+ value = 0
2575
+ }
2576
+ }
2577
+ }
2578
+ divide_variable = {
2579
+ which = base_value_coal
2580
+ which = chance_modifier_coal
2581
+ }
2582
+ }
2583
+ }
2584
+ }
2585
+ determine_value_of_trade_goods_cloves = {
2586
+ set_variable = {
2587
+ which = base_value_cloves
2588
+ value = 8
2589
+ }
2590
+ if = {
2591
+ limit = {
2592
+ has_chance_scaling_cost = yes
2593
+ }
2594
+ set_variable = {
2595
+ which = chance_modifier_cloves
2596
+ value = 1
2597
+ }
2598
+ if = {
2599
+ limit = {
2600
+ has_country_flag = encourage_cash_crops_flag
2601
+ }
2602
+ multiply_variable = {
2603
+ which = chance_modifier_cloves
2604
+ value = 2
2605
+ }
2606
+ }
2607
+ if = {
2608
+ limit = {
2609
+ OR = {
2610
+ has_increased_trade_goods_discovery = { trade_goods = cloves }
2611
+ colonial_parent = { has_increased_trade_goods_discovery = { trade_goods = cloves } }
2612
+ }
2613
+ }
2614
+ multiply_variable = {
2615
+ which = chance_modifier_cloves
2616
+ value = 2
2617
+ }
2618
+ }
2619
+ if = {
2620
+ limit = {
2621
+ NOT = {
2622
+ is_variable_equal = {
2623
+ which = chance_modifier_cloves
2624
+ value = 0
2625
+ }
2626
+ }
2627
+ }
2628
+ divide_variable = {
2629
+ which = base_value_cloves
2630
+ which = chance_modifier_cloves
2631
+ }
2632
+ }
2633
+ }
2634
+ }
2635
+ determine_value_of_trade_goods_unknown = {
2636
+ set_variable = {
2637
+ which = base_value_unknown
2638
+ value = 0
2639
+ }
2640
+ }
2641
+
2642
+ # The design behind it is the following:
2643
+ # 1. You colonize a province
2644
+ # 2. A pop-up event appears which gives you the choice to select the trade good for the province
2645
+ # 3. Every trade good has an own base price assigned to them. This base price should be their base value * 5 Ducats.
2646
+ # 4. Trade goods above 3 value also cost ADM power.
2647
+ # 5. Every time you select a certain trade good, the price increases
2648
+ # 6. The new price is calculated with this formula: (1 + (times you upgraded it)) * 5 (base trade good price)
2649
+ # 7. ADM costs are calculated as follows: (base trade good pirce - 2.5) * 25 * (times YOU upgraded it) as long (base trade good pirce - 2.5) => 0
2650
+ # 7. Gold will be counted as having a trade value of 10 Ducats so not all of the whole new world becomes one huge gold cluster
2651
+
2652
+ calculate_trade_goods_price = {
2653
+ owner = {
2654
+ determine_value_of_trade_goods_$trade_goods$ = yes
2655
+ set_variable = {
2656
+ which = final_ducat_price_$trade_goods$
2657
+ value = 1
2658
+ }
2659
+ set_variable = {
2660
+ which = final_adm_cost_$trade_goods$
2661
+ which = base_value_$trade_goods$
2662
+ }
2663
+ subtract_variable = {
2664
+ which = final_adm_cost_$trade_goods$
2665
+ value = 2.5
2666
+ }
2667
+ multiply_variable = {
2668
+ which = final_adm_cost_$trade_goods$
2669
+ value = 5
2670
+ }
2671
+ #Determine price increase on your own
2672
+ if = {
2673
+ limit = { has_country_flag = ever_selected_$trade_goods$ }
2674
+ change_variable = {
2675
+ which = final_ducat_price_$trade_goods$
2676
+ which = ducat_cost_$trade_goods$_own_counter
2677
+ }
2678
+ if = {
2679
+ limit = {
2680
+ check_variable = {
2681
+ which = final_adm_cost_$trade_goods$
2682
+ value = 1
2683
+ }
2684
+ }
2685
+ multiply_variable = {
2686
+ which = final_adm_cost_$trade_goods$
2687
+ which = ducat_cost_$trade_goods$_own_counter
2688
+ }
2689
+ }
2690
+ }
2691
+ multiply_variable = {
2692
+ which = final_ducat_price_$trade_goods$
2693
+ value = 10
2694
+ }
2695
+ multiply_variable = {
2696
+ which = final_ducat_price_$trade_goods$
2697
+ which = base_value_$trade_goods$
2698
+ }
2699
+ }
2700
+ }
2701
+
2702
+ purchase_trade_goods = {
2703
+ custom_tooltip = ducat_price_for_$trade_goods$_tt
2704
+ if = {
2705
+ limit = {
2706
+ owner = {
2707
+ check_variable = {
2708
+ which = final_adm_cost_$trade_goods$
2709
+ value = 1
2710
+ }
2711
+ }
2712
+ }
2713
+ custom_tooltip = adm_price_for_$trade_goods$_tt
2714
+ }
2715
+ hidden_effect = {
2716
+ owner = {
2717
+ if = {
2718
+ limit = { NOT = { has_country_flag = ever_selected_$trade_goods$ } }
2719
+ set_country_flag = ever_selected_$trade_goods$
2720
+ set_variable = {
2721
+ which = ducat_cost_$trade_goods$_own_counter
2722
+ value = 1
2723
+ }
2724
+ }
2725
+ else = {
2726
+ change_variable = {
2727
+ which = ducat_cost_$trade_goods$_own_counter
2728
+ value = 1
2729
+ }
2730
+ }
2731
+ while = {
2732
+ limit = {
2733
+ check_variable = {
2734
+ which = final_ducat_price_$trade_goods$
2735
+ value = 1
2736
+ }
2737
+ }
2738
+ add_treasury = -1
2739
+ subtract_variable = {
2740
+ which = final_ducat_price_$trade_goods$
2741
+ value = 1
2742
+ }
2743
+ }
2744
+ if = {
2745
+ limit = {
2746
+ check_variable = {
2747
+ which = final_adm_cost_$trade_goods$
2748
+ value = 1
2749
+ }
2750
+ }
2751
+ while = {
2752
+ limit = {
2753
+ check_variable = {
2754
+ which = final_adm_cost_$trade_goods$
2755
+ value = 1
2756
+ }
2757
+ }
2758
+ add_adm_power = -1
2759
+ subtract_variable = {
2760
+ which = final_adm_cost_$trade_goods$
2761
+ value = 1
2762
+ }
2763
+ }
2764
+ }
2765
+ }
2766
+ }
2767
+ change_trade_goods = $trade_goods$
2768
+ }
common/scripted_effects/02_scripted_effects_preview_missions.txt ADDED
@@ -0,0 +1,1782 @@
1
+ ######################################
2
+ # Branching Missions Preview Effects #
3
+ ######################################
4
+ enable_branching_mission_review_of_batch = {
5
+ if = {
6
+ limit = { not = { has_country_flag = has_batch_1_active } }
7
+ set_country_flag = has_batch_1_active
8
+ set_country_flag = can_choose_$key$_1_branching_missions
9
+ }
10
+ else_if = {
11
+ limit = { not = { has_country_flag = has_batch_2_active } }
12
+ set_country_flag = has_batch_2_active
13
+ set_country_flag = can_choose_$key$_2_branching_missions
14
+ }
15
+ else_if = {
16
+ limit = { not = { has_country_flag = has_batch_3_active } }
17
+ set_country_flag = has_batch_3_active
18
+ set_country_flag = can_choose_$key$_3_branching_missions
19
+ }
20
+ else = {
21
+ log = "Too many mission batches active at the same time. Make sure that any given moment only 3 batches are active to preview"
22
+ }
23
+ }
24
+ enable_branching_mission_review = {
25
+ if = {
26
+ limit = { ai = yes }
27
+ country_event = { id = $ai_event_id$ }
28
+ }
29
+ else = {
30
+ custom_tooltip = BYZ_unlock_branches_decision
31
+ hidden_effect = {
32
+ enable_branching_mission_review_of_batch = { key = $key$ }
33
+ change_variable = {
34
+ which = can_preview_missions_var
35
+ value = 1
36
+ }
37
+ }
38
+ }
39
+ }
40
+ enable_branching_mission_review_without_ai = {
41
+ custom_tooltip = BYZ_unlock_branches_decision
42
+ hidden_effect = {
43
+ enable_branching_mission_review_of_batch = { key = $key$ }
44
+ change_variable = {
45
+ which = can_preview_missions_var
46
+ value = 1
47
+ }
48
+ }
49
+ }
50
+
51
+ select_current_missions_MAL = {} #Empty on purpose, preview system only implemented for the sake of completion
52
+ select_current_missions_SON = {
53
+ if = {
54
+ limit = { has_country_flag = son_islamic_focus }
55
+ hidden_effect = { clr_country_flag = son_tolerance_focus }
56
+ add_estate_loyalty = {
57
+ estate = estate_church
58
+ loyalty = 10
59
+ }
60
+ add_estate_loyalty = {
61
+ estate = estate_nobles
62
+ loyalty = -10
63
+ }
64
+ add_estate_loyalty = {
65
+ estate = estate_dhimmi
66
+ loyalty = -10
67
+ }
68
+ }
69
+ if = {
70
+ limit = { has_country_flag = son_tolerance_focus }
71
+ hidden_effect = { clr_country_flag = son_islamic_focus }
72
+ add_estate_loyalty = {
73
+ estate = estate_church
74
+ loyalty = -10
75
+ }
76
+ add_estate_loyalty = {
77
+ estate = estate_nobles
78
+ loyalty = 10
79
+ }
80
+ add_estate_loyalty = {
81
+ estate = estate_dhimmi
82
+ loyalty = 10
83
+ }
84
+ }
85
+ }
86
+ select_current_missions_KON = {} #Empty on purpose, preview system only implemented for the sake of completion
87
+ select_scandinavian_religion_mission_effect = {
88
+ if = {
89
+ limit = { has_country_flag = sca_unlock_catholic_missions }
90
+ if = {
91
+ limit = { NOT = { religion = catholic } }
92
+ add_stability = -2
93
+ custom_tooltip = flavor_sca.1.a.tt
94
+ if = {
95
+ limit = {
96
+ NOT = { religion = coptic }
97
+ NOT = { religion = orthodox }
98
+ }
99
+ hidden_effect = {
100
+ every_known_country = {
101
+ limit = {
102
+ religion = ROOT
103
+ }
104
+ add_opinion = {
105
+ who = ROOT
106
+ modifier = swe_abandoned_the_reformation
107
+ }
108
+ }
109
+ }
110
+ }
111
+ else = {
112
+ hidden_effect = {
113
+ every_known_country = {
114
+ limit = {
115
+ religion = ROOT
116
+ }
117
+ add_opinion = {
118
+ who = ROOT
119
+ modifier = swe_betrayed_our_faith
120
+ }
121
+ }
122
+ }
123
+ }
124
+ change_religion = catholic
125
+ capital_scope = {
126
+ change_religion = catholic
127
+ }
128
+ random_owned_province = {
129
+ limit = {
130
+ region = scandinavia_region
131
+ NOT = { religion = catholic }
132
+ }
133
+ change_religion = catholic
134
+ }
135
+ }
136
+ }
137
+ if = {
138
+ limit = { has_country_flag = sca_unlock_protestant_missions }
139
+ if = {
140
+ limit = { religion = catholic }
141
+ add_stability = -2
142
+ custom_tooltip = flavor_sca.1.a.tt
143
+ hidden_effect = {
144
+ every_known_country = {
145
+ limit = {
146
+ religion = ROOT
147
+ }
148
+ add_opinion = {
149
+ who = ROOT
150
+ modifier = swe_betrayed_the_holy_see
151
+ }
152
+ }
153
+ }
154
+ change_religion = protestant
155
+ capital_scope = {
156
+ change_religion = protestant
157
+ }
158
+ random_owned_province = {
159
+ limit = {
160
+ region = scandinavia_region
161
+ religion = catholic
162
+ }
163
+ change_religion = protestant
164
+ }
165
+ }
166
+ else = {
167
+ capital_scope = {
168
+ change_religion = ROOT
169
+ }
170
+ random_owned_province = {
171
+ limit = {
172
+ region = scandinavia_region
173
+ NOT = { religion = ROOT }
174
+ }
175
+ change_religion = ROOT
176
+ }
177
+ }
178
+ }
179
+ if = {
180
+ limit = { has_country_flag = sca_unlock_humanist_missions }
181
+ custom_tooltip = flavor_sca.1.d.tt
182
+ hidden_effect = {
183
+ every_known_country = {
184
+ limit = {
185
+ religion_group = christian
186
+ NOT = { religion = orthodox }
187
+ NOT = { religion = coptic }
188
+ }
189
+ add_opinion = {
190
+ who = ROOT
191
+ modifier = swe_is_not_for_us
192
+ }
193
+ }
194
+ }
195
+ }
196
+ if = {
197
+ limit = { has_country_flag = sca_unlock_norse_missions }
198
+ add_army_tradition = 5
199
+ }
200
+ }
201
+ select_current_missions_SWE = {
202
+ select_scandinavian_religion_mission_effect = yes
203
+ }
204
+ select_current_missions_DAN = {
205
+ select_scandinavian_religion_mission_effect = yes
206
+ }
207
+ select_current_missions_NOR = {
208
+ select_scandinavian_religion_mission_effect = yes
209
+ }
210
+ select_current_missions_TEU = {
211
+ if = {
212
+ limit = { has_country_flag = teu_prussian_path }
213
+ hidden_effect = {
214
+ clr_country_flag = teu_crusader_path
215
+ if = {
216
+ limit = {
217
+ has_country_flag = formed_prussia_flag
218
+ NOT = { tag = PRU }
219
+ NOT = { was_tag = PRU }
220
+ }
221
+ clr_country_flag = formed_prussia_flag
222
+ }
223
+ }
224
+ }
225
+ if = {
226
+ limit = { has_country_flag = teu_crusader_path }
227
+ hidden_effect = {
228
+ clr_country_flag = teu_prussian_path
229
+ clr_country_flag = teu_diplomacy_hre_path
230
+ clr_country_flag = teu_conquest_hre_path
231
+ set_country_flag = formed_prussia_flag
232
+ }
233
+ if = {
234
+ limit = { has_mission = teu_defeat_the_poles }
235
+ hidden_effect = {
236
+ if = {
237
+ limit = {
238
+ has_mission = teu_crusader_mil_reform_1
239
+ NOT = { mission_completed = teu_crusader_mil_reform_1 }
240
+ }
241
+ set_country_flag = teu_crusader_battle_counter
242
+ }
243
+ else = {
244
+ clr_country_flag = teu_crusader_battle_counter
245
+ }
246
+ }
247
+ }
248
+ custom_tooltip = flavor_teu.10.b.ct
249
+ if = {
250
+ limit = { is_part_of_hre = yes }
251
+ set_in_empire = no
252
+ }
253
+ samogitia_area = {
254
+ limit = {
255
+ NOT = { is_core = ROOT }
256
+ NOT = { is_permanent_claim = ROOT }
257
+ }
258
+ add_permanent_claim = ROOT
259
+ }
260
+ lithuania_area = {
261
+ limit = {
262
+ NOT = { is_core = ROOT }
263
+ NOT = { is_permanent_claim = ROOT }
264
+ }
265
+ add_permanent_claim = ROOT
266
+ }
267
+ mazovia_area = {
268
+ limit = {
269
+ NOT = { is_core = ROOT }
270
+ NOT = { is_permanent_claim = ROOT }
271
+ }
272
+ add_permanent_claim = ROOT
273
+ }
274
+ malopolska_area = {
275
+ limit = {
276
+ NOT = { is_core = ROOT }
277
+ NOT = { is_permanent_claim = ROOT }
278
+ }
279
+ add_permanent_claim = ROOT
280
+ }
281
+ central_poland_area = {
282
+ limit = {
283
+ NOT = { is_core = ROOT }
284
+ NOT = { is_permanent_claim = ROOT }
285
+ }
286
+ add_permanent_claim = ROOT
287
+ }
288
+ }
289
+ }
290
+ select_current_missions_TEU_PRU = {
291
+ if = {
292
+ limit = { has_country_flag = teu_diplomacy_hre_path }
293
+ hidden_effect = {
294
+ clr_country_flag = teu_conquest_hre_path
295
+ clr_country_flag = teu_kingdom_prussia_path
296
+ clr_country_flag = teu_joined_the_hre
297
+ }
298
+ if = {
299
+ limit = {
300
+ is_part_of_hre = no
301
+ hre_size = 1
302
+ }
303
+ set_in_empire = yes
304
+ emperor = { add_imperial_influence = 10 }
305
+ }
306
+ if = {
307
+ limit = { tag = TEU }
308
+ country_event = { id = flavor_teu.34 }
309
+ }
310
+ if = {
311
+ limit = { exists = BRA }
312
+ add_casus_belli = {
313
+ type = cb_vassalize_mission
314
+ target = BRA
315
+ months = 240
316
+ }
317
+ }
318
+ mittelmark_area = {
319
+ limit = {
320
+ NOT = { is_core = ROOT }
321
+ NOT = { is_permanent_claim = ROOT }
322
+ }
323
+ add_permanent_claim = ROOT
324
+ }
325
+ neumark_area = {
326
+ limit = {
327
+ NOT = { is_core = ROOT }
328
+ NOT = { is_permanent_claim = ROOT }
329
+ }
330
+ add_permanent_claim = ROOT
331
+ }
332
+ }
333
+ if = {
334
+ limit = { has_country_flag = teu_conquest_hre_path }
335
+ if = {
336
+ limit = {
337
+ is_part_of_hre = no
338
+ hre_size = 1
339
+ }
340
+ set_in_empire = yes
341
+ emperor = { add_imperial_influence = 10 }
342
+ }
343
+ hidden_effect = {
344
+ set_country_flag = teu_conquest_hre_path
345
+ clr_country_flag = teu_diplomacy_hre_path
346
+ clr_country_flag = teu_kingdom_prussia_path
347
+ clr_country_flag = teu_joined_the_hre
348
+ }
349
+ if = {
350
+ limit = { tag = TEU }
351
+ country_event = { id = flavor_teu.34 }
352
+ }
353
+ mittelmark_area = {
354
+ limit = {
355
+ NOT = { is_core = ROOT }
356
+ NOT = { is_permanent_claim = ROOT }
357
+ }
358
+ add_permanent_claim = ROOT
359
+ }
360
+ neumark_area = {
361
+ limit = {
362
+ NOT = { is_core = ROOT }
363
+ NOT = { is_permanent_claim = ROOT }
364
+ }
365
+ add_permanent_claim = ROOT
366
+ }
367
+ vorpommern_area = {
368
+ limit = {
369
+ NOT = { is_core = ROOT }
370
+ NOT = { is_permanent_claim = ROOT }
371
+ }
372
+ add_permanent_claim = ROOT
373
+ }
374
+ hinter_pommern_area = {
375
+ limit = {
376
+ NOT = { is_core = ROOT }
377
+ NOT = { is_permanent_claim = ROOT }
378
+ }
379
+ add_permanent_claim = ROOT
380
+ }
381
+ mecklenburg_area = {
382
+ limit = {
383
+ NOT = { is_core = ROOT }
384
+ NOT = { is_permanent_claim = ROOT }
385
+ }
386
+ add_permanent_claim = ROOT
387
+ }
388
+ add_country_modifier = {
389
+ name = teu_pru_prussian_unification_wars
390
+ duration = 9125
391
+ }
392
+ }
393
+ if = {
394
+ limit = { has_country_flag = teu_kingdom_prussia_path }
395
+ if = {
396
+ limit = { is_part_of_hre = yes }
397
+ set_in_empire = no
398
+ }
399
+ add_prestige = 50
400
+ if = {
401
+ limit = { has_country_flag = teu_is_allowed_to_stay_in_the_hre }
402
+ reverse_add_opinion = {
403
+ who = emperor
404
+ modifier = hre_country_left
405
+ }
406
+ }
407
+ hidden_effect = {
408
+ clr_country_flag = teu_diplomacy_hre_path
409
+ clr_country_flag = teu_conquest_hre_path
410
+ clr_country_flag = teu_joined_the_hre
411
+ }
412
+ samogitia_area = {
413
+ limit = {
414
+ NOT = { is_core = ROOT }
415
+ NOT = { is_permanent_claim = ROOT }
416
+ }
417
+ add_permanent_claim = ROOT
418
+ }
419
+ lithuania_area = {
420
+ limit = {
421
+ NOT = { is_core = ROOT }
422
+ NOT = { is_permanent_claim = ROOT }
423
+ }
424
+ add_permanent_claim = ROOT
425
+ }
426
+ mazovia_area = {
427
+ limit = {
428
+ NOT = { is_core = ROOT }
429
+ NOT = { is_permanent_claim = ROOT }
430
+ }
431
+ add_permanent_claim = ROOT
432
+ }
433
+ malopolska_area = {
434
+ limit = {
435
+ NOT = { is_core = ROOT }
436
+ NOT = { is_permanent_claim = ROOT }
437
+ }
438
+ add_permanent_claim = ROOT
439
+ }
440
+ central_poland_area = {
441
+ limit = {
442
+ NOT = { is_core = ROOT }
443
+ NOT = { is_permanent_claim = ROOT }
444
+ }
445
+ add_permanent_claim = ROOT
446
+ }
447
+ }
448
+ }
449
+ select_current_missions_LIV = {
450
+ if = {
451
+ limit = {
452
+ has_country_flag = liv_crusader_path
453
+ }
454
+ hidden_effect = {
455
+ set_country_flag = formed_livonia_flag
456
+ set_country_flag = formed_courland_flag
457
+ }
458
+ custom_tooltip = flavor_liv.1.b.ct
459
+ lithuania_area = {
460
+ limit = {
461
+ NOT = { is_core = ROOT }
462
+ NOT = { is_permanent_claim = ROOT }
463
+ }
464
+ add_permanent_claim = ROOT
465
+ }
466
+ samogitia_area = {
467
+ limit = {
468
+ NOT = { is_core = ROOT }
469
+ NOT = { is_permanent_claim = ROOT }
470
+ }
471
+ add_permanent_claim = ROOT
472
+ }
473
+ karelia_area = {
474
+ limit = {
475
+ NOT = { is_core = ROOT }
476
+ NOT = { is_permanent_claim = ROOT }
477
+ }
478
+ add_permanent_claim = ROOT
479
+ }
480
+ novgorod_area = {
481
+ limit = {
482
+ NOT = { is_core = ROOT }
483
+ NOT = { is_permanent_claim = ROOT }
484
+ }
485
+ add_permanent_claim = ROOT
486
+ }
487
+ pskov_area = {
488
+ limit = {
489
+ NOT = { is_core = ROOT }
490
+ NOT = { is_permanent_claim = ROOT }
491
+ }
492
+ add_permanent_claim = ROOT
493
+ }
494
+ }
495
+ }
496
+ select_current_missions_POL = {} #Empty on purpose, preview system only implemented for the sake of completion
497
+ select_current_missions_TUR = {
498
+ if = {
499
+ limit = { has_country_flag = tur_chose_legalism }
500
+ hidden_effect = {
501
+ clr_country_flag = tur_chose_mysticism
502
+ clr_country_flag = tur_non_muslim_path_flag
503
+ }
504
+ add_country_modifier = {
505
+ name = tur_embraced_legalism_modifier
506
+ duration = 18250
507
+ }
508
+ }
509
+ if = {
510
+ limit = { has_country_flag = tur_chose_mysticism }
511
+ hidden_effect = {
512
+ clr_country_flag = tur_chose_legalism
513
+ clr_country_flag = tur_non_muslim_path_flag
514
+ }
515
+ add_country_modifier = {
516
+ name = tur_embraced_mysticism_modifier
517
+ duration = 18250
518
+ }
519
+ }
520
+ if = {
521
+ limit = { has_country_flag = tur_non_muslim_path_flag }
522
+ hidden_effect = {
523
+ clr_country_flag = tur_chose_legalism
524
+ clr_country_flag = tur_chose_mysticism
525
+ }
526
+ add_country_modifier = {
527
+ name = tur_end_of_the_caliphate_modifier
528
+ duration = 18250
529
+ }
530
+ }
531
+ }
532
+ select_current_missions_MNG = {
533
+ if = {
534
+ limit = { has_country_flag = mng_dynamic_1 }
535
+ clr_country_flag = mng_dynamic_2
536
+ add_country_modifier = {
537
+ name = haijin_policy_modifier
538
+ duration = -1
539
+ desc = until_we_complete_the_appropriate_missions_desc
540
+ }
541
+ }
542
+ if = {
543
+ limit = { has_country_flag = mng_dynamic_2 }
544
+ clr_country_flag = mng_dynamic_1
545
+ add_country_modifier = {
546
+ name = haijin_policy_modifier
547
+ duration = -1
548
+ desc = until_we_complete_the_appropriate_missions_desc
549
+ }
550
+ }
551
+ }
552
+ select_current_missions_QNG = {
553
+ if = {
554
+ limit = { has_country_flag = qng_open_ports_flag }
555
+ clr_country_flag = qng_close_ports_flag
556
+ if = {
557
+ limit = { has_reform = mercantilistic_approach_reform }
558
+ add_government_reform = free_trade_reform
559
+ }
560
+ add_country_modifier = {
561
+ name = qng_free_trade_modifier
562
+ duration = 9125
563
+ }
564
+ }
565
+ if = {
566
+ limit = { has_country_flag = qng_close_ports_flag }
567
+ clr_country_flag = qng_open_ports_flag
568
+ if = {
569
+ limit = { has_reform = free_trade_reform }
570
+ add_government_reform = mercantilistic_approach_reform
571
+ }
572
+ add_country_modifier = {
573
+ name = qng_mercantilism_modifier
574
+ duration = -1
575
+ }
576
+ }
577
+ }
578
+ select_current_missions_GBR = {
579
+ if = {
580
+ limit = { has_country_flag = eng_took_gbr_branch }
581
+ clr_country_flag = eng_took_ave_branch
582
+ add_country_modifier = {
583
+ name = gbr_isolation_policy
584
+ duration = 9125
585
+ }
586
+ }
587
+ if = {
588
+ limit = { has_country_flag = eng_took_ave_branch }
589
+ clr_country_flag = eng_took_gbr_branch
590
+ if = {
591
+ limit = {
592
+ FRA = {
593
+ is_subject = no
594
+ }
595
+ }
596
+ add_casus_belli = {
597
+ target = FRA
598
+ type = cb_hundred_years_union
599
+ months = 360
600
+ }
601
+ }
602
+ ile_de_france_area = {
603
+ limit = {
604
+ NOT = { is_core = ROOT }
605
+ NOT = { is_permanent_claim = ROOT }
606
+ }
607
+ add_permanent_claim = ROOT
608
+ }
609
+ champagne_area = {
610
+ limit = {
611
+ NOT = { is_core = ROOT }
612
+ NOT = { is_permanent_claim = ROOT }
613
+ }
614
+ add_permanent_claim = ROOT
615
+ }
616
+ }
617
+ }
618
+ select_current_missions_FRA = {
619
+ if = {
620
+ limit = { has_country_flag = fra_chose_to_piss_off_pope_flag }
621
+ add_country_modifier = {
622
+ name = fra_italian_wars_modifier
623
+ duration = 7300
624
+ }
625
+ piedmont_area = {
626
+ limit = {
627
+ NOT = { owned_by = ROOT }
628
+ NOT = { is_core = ROOT }
629
+ }
630
+ add_permanent_claim = ROOT
631
+ }
632
+ liguria_area = {
633
+ limit = {
634
+ NOT = { owned_by = ROOT }
635
+ NOT = { is_core = ROOT }
636
+ }
637
+ add_permanent_claim = ROOT
638
+ }
639
+ lombardy_area = {
640
+ limit = {
641
+ NOT = { owned_by = ROOT }
642
+ NOT = { is_core = ROOT }
643
+ }
644
+ add_permanent_claim = ROOT
645
+ }
646
+ if = {
647
+ limit = {
648
+ NAP = { is_subject = no exists = yes }
649
+ }
650
+ add_casus_belli = {
651
+ target = NAP
652
+ type = cb_vassalize_mission
653
+ months = 180
654
+ }
655
+ }
656
+ else = {
657
+ naples_area = {
658
+ limit = {
659
+ NOT = { owned_by = ROOT }
660
+ NOT = { is_core = ROOT }
661
+ is_empty = no
662
+ }
663
+ add_permanent_claim = ROOT
664
+ }
665
+ calabria_area = {
666
+ limit = {
667
+ NOT = { owned_by = ROOT }
668
+ NOT = { is_core = ROOT }
669
+ is_empty = no
670
+ }
671
+ add_permanent_claim = ROOT
672
+ }
673
+ apulia_area = {
674
+ limit = {
675
+ NOT = { owned_by = ROOT }
676
+ NOT = { is_core = ROOT }
677
+ is_empty = no
678
+ }
679
+ add_permanent_claim = ROOT
680
+ }
681
+ }
682
+ }
683
+ if = {
684
+ limit = { has_country_flag = fra_papal_lap_dop_flag }
685
+ add_country_modifier = {
686
+ name = fra_resurgence_of_crusader_fervor_modifier
687
+ duration = 9125
688
+ }
689
+ palestine_area = {
690
+ limit = {
691
+ NOT = { owned_by = ROOT }
692
+ NOT = { is_core = ROOT }
693
+ }
694
+ add_permanent_claim = ROOT
695
+ }
696
+ }
697
+ }
698
+ select_current_missions_FRA_HRE = {
699
+ if = { #Special case when the HRE is already dissolved
700
+ limit = {
701
+ not = { hre_size = 1 }
702
+ }
703
+ add_country_modifier = {
704
+ name = fra_triumph_over_austria_modifier
705
+ duration = -1
706
+ }
707
+ add_dip_power = 200
708
+ clr_country_flag = fra_shed_the_blood_of_the_saxon_man_flag
709
+ set_country_flag = fra_fufujoni_flag
710
+ swap_non_generic_missions = yes
711
+ }
712
+ else = {
713
+ if = {
714
+ limit = { has_country_flag = fra_fufujoni_flag }
715
+ clr_country_flag = fra_shed_the_blood_of_the_saxon_man_flag
716
+ add_country_modifier = {
717
+ name = fra_war_east_modifier
718
+ duration = 5475
719
+ }
720
+ if = {
721
+ limit = { hre_size = 1 }
722
+ custom_tooltip = fra_enable_war_on_the_empire_cb_tt
723
+ hidden_effect = { set_country_flag = fra_enable_war_on_the_empire_cb_flag }
724
+ }
725
+ }
726
+ if = {
727
+ limit = {
728
+ or = {
729
+ has_country_flag = fra_shed_the_blood_of_the_saxon_man_flag
730
+ is_emperor = yes
731
+ }
732
+ }
733
+ clr_country_flag = fra_fufujoni_flag
734
+ add_country_modifier = {
735
+ name = fra_charlemagne_legacy_modifier
736
+ duration = 7300
737
+ }
738
+ every_elector = {
739
+ limit = {
740
+ has_opinion = {
741
+ who = ROOT
742
+ value = 0
743
+ }
744
+ }
745
+ add_opinion = {
746
+ who = ROOT
747
+ modifier = fra_charlemagne_legacy_opinion_modifier
748
+ }
749
+ }
750
+ add_power_projection = {
751
+ type = mission_rewards_power_projection
752
+ amount = 25
753
+ }
754
+ if = {
755
+ limit = {
756
+ not = { has_country_flag = fra_shed_the_blood_of_the_saxon_man_flag }
757
+ is_emperor = yes
758
+ }
759
+ set_country_flag = fra_shed_the_blood_of_the_saxon_man_flag
760
+ custom_tooltip = fra_charlemagne_legacy_tt
761
+ swap_non_generic_missions = yes #Another special for the moment France becomes Emperor before selecing any of the branching missions
762
+ }
763
+ }
764
+ }
765
+ }
766
+ select_current_missions_JAP = {
767
+ if = {
768
+ limit = { has_country_flag = jap_mushashi_5_books_flag }
769
+ clr_country_flag = jap_domineering_naval_focus_flag
770
+ add_army_tradition = 10
771
+ add_country_modifier = {
772
+ name = jap_mushashi_5_books_modifier
773
+ duration = -1
774
+ }
775
+ }
776
+ if = {
777
+ limit = { has_country_flag = jap_domineering_naval_focus_flag }
778
+ clr_country_flag = jap_mushashi_5_books_flag
779
+ add_navy_tradition = 20
780
+ add_country_modifier = {
781
+ name = jap_domineering_naval_focus_modifier
782
+ duration = -1
783
+ }
784
+ }
785
+ }
786
+ select_current_missions_JAP_RELI = {
787
+ if = {
788
+ limit = { has_country_flag = christianity_defeated_flag }
789
+ clr_country_flag = a_kirishitan_realm
790
+ if = {
791
+ limit = { has_country_flag = significant_christian_presence_flag }
792
+ set_estate_privilege = estate_church_japanese_christian_communities_privilege
793
+ }
794
+ else = {
795
+ add_country_modifier = {
796
+ name = jap_shinto_warriors_modifier
797
+ duration = -1
798
+ }
799
+ }
800
+ }
801
+ if = {
802
+ limit = { has_country_flag = a_kirishitan_realm }
803
+ clr_country_flag = christianity_defeated_flag
804
+ override_country_name = KRJ
805
+ set_country_flag = is_KRJ_flag
806
+ set_country_flag = has_overriden_name_flag
807
+ add_country_modifier = {
808
+ name = jap_protectors_east_catholicism
809
+ duration = 10950
810
+ }
811
+ }
812
+ }
813
+ select_current_missions_BYZ = {} #Empty, nothing should happen
814
+ select_current_missions_PER = {
815
+ if = {
816
+ limit = {
817
+ OR = {
818
+ has_country_flag = per_shia_missions
819
+ has_country_flag = per_sunni_missions
820
+ }
821
+ }
822
+ country_event = { id = flavor_per.34 }
823
+ }
824
+ if = {
825
+ limit = { has_country_flag = per_zoroastrian_missions }
826
+ if = {
827
+ limit = { NOT = { religion_group = zoroastrian_group } }
828
+ country_event = { id = flavor_per.35 }
829
+ }
830
+ else = {
831
+ change_estate_land_share = { estate = estate_church share = -5 }
832
+ }
833
+ }
834
+ }
835
+ select_current_missions_HAB = {
836
+ if = {
837
+ limit = {
838
+ has_country_flag = hab_germany_branch
839
+ }
840
+ give_claims = { area = upper_bavaria_area }
841
+ give_claims = { area = lower_bavaria_area }
842
+ give_claims = { area = east_bavaria_area }
843
+ give_claims = { area = mittelmark_area }
844
+ give_claims = { area = neumark_area }
845
+ }
846
+ }
847
+ select_current_missions_BOH_RELIGION = {} #Empty
848
+ select_current_missions_HSN = {} #Empty
849
+ select_current_missions_HSN2 = {} #Empty
850
+ select_current_missions_ITA_TRADE = {
851
+ if = {
852
+ limit = {
853
+ has_country_flag = ITA_venice_missions
854
+ }
855
+ custom_tooltip = ITA_priv_upgrade_venice
856
+ }
857
+ if = {
858
+ limit = {
859
+ has_country_flag = ITA_genoa_missions
860
+ }
861
+ custom_tooltip = ITA_priv_upgrade_genoa
862
+ }
863
+ }
864
+ select_current_missions_FEO = {} #Empty
865
+ select_current_missions_TIM = {
866
+ hidden_effect = {
867
+ if = {
868
+ limit = {
869
+ has_country_flag = TIM_nomad_missions
870
+ }
871
+ if = {
872
+ limit = {
873
+ mission_completed = TIM_qoyunlu
874
+ }
875
+ give_claims = { region = egypt_region }
876
+ give_claims = { area = palestine_area }
877
+ give_claims = { area = trans_jordan_area }
878
+ give_claims = { area = syria_area }
879
+ give_claims = { area = syrian_desert_area }
880
+ give_claims = { area = aleppo_area }
881
+ give_claims = { region = anatolia_region }
882
+ give_claims = { region = balkan_region }
883
+ }
884
+ if = {
885
+ limit = {
886
+ mission_completed = TIM_delhi
887
+ }
888
+ give_claims = { region = hindusthan_region }
889
+ }
890
+ if = {
891
+ limit = {
892
+ mission_completed = TIM_caucasia
893
+ }
894
+ give_claims = { region = crimea_region }
895
+ }
896
+ if = {
897
+ limit = {
898
+ mission_completed = TIM_recover_north
899
+ }
900
+ give_claims = { area = tambov_area }
901
+ give_claims = { area = lower_yik_area }
902
+ give_claims = { area = nogai_area }
903
+ give_claims = { area = saratov_area }
904
+ give_claims = { area = samara_area }
905
+ give_claims = { area = bashkiria_area }
906
+ give_claims = { area = volga_area }
907
+ give_claims = { area = kazan_area }
908
+ give_claims = { area = kama_area }
909
+ }
910
+ if = {
911
+ limit = {
912
+ mission_completed = TIM_delhi
913
+ }
914
+ give_claims = { area = marwar_area }
915
+ give_claims = { area = jangladesh_area }
916
+ give_claims = { area = multan_area }
917
+ }
918
+ if = {
919
+ limit = {
920
+ mission_completed = TIM_moghulistan
921
+ }
922
+ give_claims = { region = mongolia_region }
923
+ }
924
+ }
925
+ }
926
+ }
927
+ select_current_missions_VEN = {} #Empty
928
+ select_current_missions_HORDES = {
929
+ hidden_effect = {
930
+ if = {
931
+ limit = {
932
+ has_country_flag = hordes_confucian_branch_flag
933
+ }
934
+ change_religion = confucianism
935
+ }
936
+ }
937
+ }
938
+
939
+ clr_preview_loc_branch = {
940
+ clr_country_flag = $key$_loc_preview_$batch$_for_1
941
+ clr_country_flag = $key$_loc_preview_$batch$_for_2
942
+ clr_country_flag = $key$_loc_preview_$batch$_for_3
943
+ clr_country_flag = $key$_loc_preview_$batch$_for_4
944
+ clr_country_flag = $key$_loc_preview_$batch$_for_5
945
+ }
946
+
947
+ select_current_missions = {
948
+ hidden_effect = {
949
+ if = {
950
+ limit = { can_preview_mission_of_key_and_batch = { key = $key$ batch = 1 } }
951
+ clr_country_flag = can_choose_$key$_1_branching_missions
952
+ clr_country_flag = has_batch_1_active
953
+ clr_preview_loc_branch = { key = $key$ batch = 1 }
954
+ }
955
+ if = {
956
+ limit = { can_preview_mission_of_key_and_batch = { key = $key$ batch = 2 } }
957
+ clr_country_flag = can_choose_$key$_2_branching_missions
958
+ clr_country_flag = has_batch_2_active
959
+ clr_preview_loc_branch = { key = $key$ batch = 2 }
960
+ }
961
+ if = {
962
+ limit = { can_preview_mission_of_key_and_batch = { key = $key$ batch = 3 } }
963
+ clr_country_flag = can_choose_$key$_3_branching_missions
964
+ clr_country_flag = has_batch_3_active
965
+ clr_preview_loc_branch = { key = $key$ batch = 3 }
966
+ }
967
+ change_variable = {
968
+ which = can_preview_missions_var
969
+ value = -1
970
+ }
971
+ }
972
+ select_current_missions_$key$ = yes
973
+ }
974
+ select_current_branch = {
975
+ custom_tooltip = BYZ_end_preview
976
+ hidden_effect = { clr_country_flag = has_batch_$batch$_active }
977
+ #Origins
978
+ if = { limit = { can_preview_mission_of_key_and_batch = { key = MAL batch = $batch$ } } select_current_missions = { key = MAL } }
979
+ if = { limit = { can_preview_mission_of_key_and_batch = { key = SON batch = $batch$ } } select_current_missions = { key = SON } }
980
+ if = { limit = { can_preview_mission_of_key_and_batch = { key = KON batch = $batch$ } } select_current_missions = { key = KON } }
981
+ #Lions of the North
982
+ if = { limit = { can_preview_mission_of_key_and_batch = { key = SWE batch = $batch$ } } select_current_missions = { key = SWE } }
983
+ if = { limit = { can_preview_mission_of_key_and_batch = { key = DAN batch = $batch$ } } select_current_missions = { key = DAN } }
984
+ if = { limit = { can_preview_mission_of_key_and_batch = { key = NOR batch = $batch$ } } select_current_missions = { key = NOR } }
985
+ if = { limit = { can_preview_mission_of_key_and_batch = { key = TEU batch = $batch$ } } select_current_missions = { key = TEU } }
986
+ if = { limit = { can_preview_mission_of_key_and_batch = { key = TEU_PRU batch = $batch$ } } select_current_missions = { key = TEU_PRU } }
987
+ if = { limit = { can_preview_mission_of_key_and_batch = { key = LIV batch = $batch$ } } select_current_missions = { key = LIV } }
988
+ if = { limit = { can_preview_mission_of_key_and_batch = { key = POL batch = $batch$ } } select_current_missions = { key = POL } }
989
+ #Domination
990
+ if = { limit = { can_preview_mission_of_key_and_batch = { key = TUR batch = $batch$ } } select_current_missions = { key = TUR } }
991
+ if = { limit = { can_preview_mission_of_key_and_batch = { key = MNG batch = $batch$ } } select_current_missions = { key = MNG } }
992
+ if = { limit = { can_preview_mission_of_key_and_batch = { key = QNG batch = $batch$ } } select_current_missions = { key = QNG } }
993
+ if = { limit = { can_preview_mission_of_key_and_batch = { key = JAP batch = $batch$ } } select_current_missions = { key = JAP } }
994
+ if = { limit = { can_preview_mission_of_key_and_batch = { key = JAP_RELI batch = $batch$ } } select_current_missions = { key = JAP_RELI } }
995
+ if = { limit = { can_preview_mission_of_key_and_batch = { key = FRA batch = $batch$ } } select_current_missions = { key = FRA } }
996
+ if = { limit = { can_preview_mission_of_key_and_batch = { key = FRA_HRE batch = $batch$ } } select_current_missions = { key = FRA_HRE } }
997
+ if = { limit = { can_preview_mission_of_key_and_batch = { key = GBR batch = $batch$ } } select_current_missions = { key = GBR } }
998
+ #King of Kings
999
+ if = { limit = { can_preview_mission_of_key_and_batch = { key = BYZ batch = $batch$ } } select_current_missions = { key = BYZ } }
1000
+ if = { limit = { can_preview_mission_of_key_and_batch = { key = PER batch = $batch$ } } select_current_missions = { key = PER } }
1001
+ #Winds of Change
1002
+ if = { limit = { can_preview_mission_of_key_and_batch = { key = HAB batch = $batch$ } } select_current_missions = { key = HAB } }
1003
+ if = { limit = { can_preview_mission_of_key_and_batch = { key = BOH_RELIGION batch = $batch$ } } select_current_missions = { key = BOH_RELIGION } }
1004
+ if = { limit = { can_preview_mission_of_key_and_batch = { key = HSN batch = $batch$ } } select_current_missions = { key = HSN } }
1005
+ if = { limit = { can_preview_mission_of_key_and_batch = { key = HSN2 batch = $batch$ } } select_current_missions = { key = HSN2 } }
1006
+ if = { limit = { can_preview_mission_of_key_and_batch = { key = ITA_TRADE batch = $batch$ } } select_current_missions = { key = ITA_TRADE } }
1007
+ if = { limit = { can_preview_mission_of_key_and_batch = { key = FEO batch = $batch$ } } select_current_missions = { key = FEO } }
1008
+ if = { limit = { can_preview_mission_of_key_and_batch = { key = TIM batch = $batch$ } } select_current_missions = { key = TIM } }
1009
+ if = { limit = { can_preview_mission_of_key_and_batch = { key = VEN batch = $batch$ } } select_current_missions = { key = VEN } }
1010
+ if = { limit = { can_preview_mission_of_key_and_batch = { key = HORDES batch = $batch$ } } select_current_missions = { key = HORDES } }
1011
+ }
1012
+
1013
+ clear_all_branching_flags = {
1014
+ #Origins
1015
+ #MAL
1016
+ if = {
1017
+ limit = { can_preview_mission_of_key_and_batch = { key = MAL batch = $batch$ } }
1018
+ clr_preview_loc_branch = { key = MAL batch = $batch$ }
1019
+ clr_country_flag = mal_decide_for_conversion
1020
+ clr_country_flag = mal_decide_for_tolerance
1021
+ }
1022
+ #SON
1023
+ if = {
1024
+ limit = { can_preview_mission_of_key_and_batch = { key = SON batch = $batch$ } }
1025
+ clr_preview_loc_branch = { key = SON batch = $batch$ }
1026
+ clr_country_flag = son_islamic_focus
1027
+ clr_country_flag = son_tolerance_focus
1028
+ }
1029
+ #KON
1030
+ if = {
1031
+ limit = { can_preview_mission_of_key_and_batch = { key = KON batch = $batch$ } }
1032
+ clr_preview_loc_branch = { key = KON batch = $batch$ }
1033
+ clr_country_flag = kon_picked_fetishism
1034
+ clr_country_flag = kon_picked_side_with_europeans
1035
+ }
1036
+ #Lions of the North
1037
+ #SWE
1038
+ if = {
1039
+ limit = { can_preview_mission_of_key_and_batch = { key = SWE batch = $batch$ } }
1040
+ clr_preview_loc_branch = { key = SWE batch = $batch$ }
1041
+ clr_country_flag = sca_unlock_catholic_missions
1042
+ clr_country_flag = sca_unlock_protestant_missions
1043
+ clr_country_flag = sca_unlock_norse_missions
1044
+ clr_country_flag = sca_unlock_humanist_missions
1045
+ }
1046
+ #DAN
1047
+ if = {
1048
+ limit = { can_preview_mission_of_key_and_batch = { key = DAN batch = $batch$ } }
1049
+ clr_preview_loc_branch = { key = DAN batch = $batch$ }
1050
+ clr_country_flag = sca_unlock_catholic_missions
1051
+ clr_country_flag = sca_unlock_protestant_missions
1052
+ clr_country_flag = sca_unlock_norse_missions
1053
+ clr_country_flag = sca_unlock_humanist_missions
1054
+ }
1055
+ #NOR
1056
+ if = {
1057
+ limit = { can_preview_mission_of_key_and_batch = { key = NOR batch = $batch$ } }
1058
+ clr_preview_loc_branch = { key = NOR batch = $batch$ }
1059
+ clr_country_flag = sca_unlock_catholic_missions
1060
+ clr_country_flag = sca_unlock_protestant_missions
1061
+ clr_country_flag = sca_unlock_norse_missions
1062
+ clr_country_flag = sca_unlock_humanist_missions
1063
+ }
1064
+ #TEU
1065
+ if = {
1066
+ limit = { can_preview_mission_of_key_and_batch = { key = TEU batch = $batch$ } }
1067
+ clr_preview_loc_branch = { key = TEU batch = $batch$ }
1068
+ clr_country_flag = teu_prussian_path
1069
+ clr_country_flag = teu_crusader_path
1070
+ }
1071
+ #TEU-PRU
1072
+ if = {
1073
+ limit = { can_preview_mission_of_key_and_batch = { key = TEU_PRU batch = $batch$ } }
1074
+ clr_preview_loc_branch = { key = TEU_PRU batch = $batch$ }
1075
+ clr_country_flag = teu_conquest_hre_path
1076
+ clr_country_flag = teu_diplomacy_hre_path
1077
+ clr_country_flag = teu_kingdom_prussia_path
1078
+ }
1079
+ #LIV
1080
+ if = {
1081
+ limit = { can_preview_mission_of_key_and_batch = { key = LIV batch = $batch$ } }
1082
+ clr_preview_loc_branch = { key = LIV batch = $batch$ }
1083
+ clr_country_flag = liv_livonian_path
1084
+ clr_country_flag = liv_crusader_path
1085
+ }
1086
+ #POL
1087
+ if = {
1088
+ limit = { can_preview_mission_of_key_and_batch = { key = POL batch = $batch$ } }
1089
+ clr_preview_loc_branch = { key = POL batch = $batch$ }
1090
+ clr_country_flag = pol_chose_pu_flag
1091
+ clr_country_flag = pol_denied_pu_flag
1092
+ }
1093
+ #Domination
1094
+ #TUR
1095
+ if = {
1096
+ limit = { can_preview_mission_of_key_and_batch = { key = TUR batch = $batch$ } }
1097
+ clr_preview_loc_branch = { key = TUR batch = $batch$ }
1098
+ clr_country_flag = tur_chose_legalism
1099
+ clr_country_flag = tur_chose_mysticism
1100
+ clr_country_flag = tur_non_muslim_path_flag
1101
+ }
1102
+ #MNG
1103
+ if = {
1104
+ limit = { can_preview_mission_of_key_and_batch = { key = MNG batch = $batch$ } }
1105
+ clr_preview_loc_branch = { key = MNG batch = $batch$ }
1106
+ clr_country_flag = mng_dynamic_1
1107
+ clr_country_flag = mng_dynamic_2
1108
+ }
1109
+ #QNG
1110
+ if = {
1111
+ limit = { can_preview_mission_of_key_and_batch = { key = QNG batch = $batch$ } }
1112
+ clr_preview_loc_branch = { key = QNG batch = $batch$ }
1113
+ clr_country_flag = qng_open_ports_flag
1114
+ clr_country_flag = qng_close_ports_flag
1115
+ }
1116
+ #JAP
1117
+ if = {
1118
+ limit = { can_preview_mission_of_key_and_batch = { key = JAP batch = $batch$ } }
1119
+ clr_preview_loc_branch = { key = JAP batch = $batch$ }
1120
+ clr_country_flag = jap_mushashi_5_books_flag
1121
+ clr_country_flag = jap_domineering_naval_focus_flag
1122
+ }
1123
+ #JAP_RELI
1124
+ if = {
1125
+ limit = { can_preview_mission_of_key_and_batch = { key = JAP_RELI batch = $batch$ } }
1126
+ clr_preview_loc_branch = { key = JAP_RELI batch = $batch$ }
1127
+ clr_country_flag = christianity_defeated_flag
1128
+ clr_country_flag = a_kirishitan_realm
1129
+ }
1130
+ #FRA
1131
+ if = {
1132
+ limit = { can_preview_mission_of_key_and_batch = { key = FRA batch = $batch$ } }
1133
+ clr_preview_loc_branch = { key = FRA batch = $batch$ }
1134
+ clr_country_flag = fra_chose_to_piss_off_pope_flag
1135
+ clr_country_flag = fra_papal_lap_dop_flag
1136
+ }
1137
+ #FRA_HRE
1138
+ if = {
1139
+ limit = { can_preview_mission_of_key_and_batch = { key = FRA_HRE batch = $batch$ } }
1140
+ clr_preview_loc_branch = { key = FRA_HRE batch = $batch$ }
1141
+ clr_country_flag = fra_shed_the_blood_of_the_saxon_man_flag
1142
+ clr_country_flag = fra_fufujoni_flag
1143
+ }
1144
+ #GBR
1145
+ if = {
1146
+ limit = { can_preview_mission_of_key_and_batch = { key = GBR batch = $batch$ } }
1147
+ clr_preview_loc_branch = { key = GBR batch = $batch$ }
1148
+ clr_country_flag = eng_took_gbr_branch
1149
+ clr_country_flag = eng_took_ave_branch
1150
+ }
1151
+ #King of Kings
1152
+ #BYZ
1153
+ if = {
1154
+ limit = { can_preview_mission_of_key_and_batch = { key = BYZ batch = $batch$ } }
1155
+ clr_preview_loc_branch = { key = BYZ batch = $batch$ }
1156
+ clr_country_flag = BYZ_centralized
1157
+ clr_country_flag = BYZ_decentralized
1158
+ }
1159
+ #PER
1160
+ if = {
1161
+ limit = { can_preview_mission_of_key_and_batch = { key = PER batch = $batch$ } }
1162
+ clr_preview_loc_branch = { key = PER batch = $batch$ }
1163
+ clr_country_flag = per_shia_missions
1164
+ clr_country_flag = per_sunni_missions
1165
+ clr_country_flag = per_zoroastrian_missions
1166
+ }
1167
+ #Winds of Change
1168
+ #HAB
1169
+ if = {
1170
+ limit = { can_preview_mission_of_key_and_batch = { key = HAB batch = $batch$ } }
1171
+ clr_preview_loc_branch = { key = HAB batch = $batch$ }
1172
+ clr_country_flag = hab_hre_branch
1173
+ clr_country_flag = hab_germany_branch
1174
+ }
1175
+ #BOH_RELIGION
1176
+ if = {
1177
+ limit = { can_preview_mission_of_key_and_batch = { key = BOH_RELIGION batch = $batch$ } }
1178
+ clr_preview_loc_branch = { key = BOH_RELIGION batch = $batch$ }
1179
+ clr_country_flag = boh_hussite_missions
1180
+ clr_country_flag = boh_catholic_missions
1181
+ }
1182
+ #HSN
1183
+ if = {
1184
+ limit = { can_preview_mission_of_key_and_batch = { key = HSN batch = $batch$ } }
1185
+ clr_preview_loc_branch = { key = HSN batch = $batch$ }
1186
+ clr_country_flag = hsn_unlock_anatolian_alliance
1187
+ clr_country_flag = hsn_unlock_anatolian_conquest
1188
+ }
1189
+ #HSN2
1190
+ if = {
1191
+ limit = { can_preview_mission_of_key_and_batch = { key = HSN2 batch = $batch$ } }
1192
+ clr_preview_loc_branch = { key = HSN2 batch = $batch$ }
1193
+ clr_country_flag = hsn_unlock_persian_alliance
1194
+ clr_country_flag = hsn_unlock_persian_conquest
1195
+ }
1196
+ #ITA_TRADE
1197
+ if = {
1198
+ limit = { can_preview_mission_of_key_and_batch = { key = ITA_TRADE batch = $batch$ } }
1199
+ clr_preview_loc_branch = { key = ITA_TRADE batch = $batch$ }
1200
+ clr_country_flag = ITA_venice_missions
1201
+ clr_country_flag = ITA_genoa_missions
1202
+ }
1203
+ #FEO
1204
+ if = {
1205
+ limit = { can_preview_mission_of_key_and_batch = { key = FEO batch = $batch$ } }
1206
+ clr_preview_loc_branch = { key = FEO batch = $batch$ }
1207
+ clr_country_flag = feo_russian_conquest_branch
1208
+ clr_country_flag = feo_russian_alliance_branch
1209
+ }
1210
+ #TIM
1211
+ if = {
1212
+ limit = { can_preview_mission_of_key_and_batch = { key = TIM batch = $batch$ } }
1213
+ clr_preview_loc_branch = { key = TIM batch = $batch$ }
1214
+ clr_country_flag = TIM_nomad_missions
1215
+ clr_country_flag = TIM_persian_missions
1216
+ }
1217
+ #VEN
1218
+ if = {
1219
+ limit = { can_preview_mission_of_key_and_batch = { key = VEN batch = $batch$ } }
1220
+ clr_preview_loc_branch = { key = VEN batch = $batch$ }
1221
+ clr_country_flag = ven_standing_army_missions_flag
1222
+ clr_country_flag = ven_mercenary_army_missions_flag
1223
+ clr_country_flag = ven_navy_missions_flag
1224
+ }
1225
+ #HORDES
1226
+ if = {
1227
+ limit = { can_preview_mission_of_key_and_batch = { key = HORDES batch = $batch$ } }
1228
+ clr_preview_loc_branch = { key = HORDES batch = $batch$ }
1229
+ clr_country_flag = hordes_tolerance_branch_flag
1230
+ clr_country_flag = hordes_devout_branch_flag
1231
+ clr_country_flag = hordes_confucian_branch_flag
1232
+ }
1233
+ }
1234
+
1235
+ set_preview_loc_branch = {
1236
+ set_country_flag = $key$_loc_preview_$batch$_for_$branch$
1237
+ }
1238
+
1239
+ preview_mission_branch_1 = {
1240
+ #Origins
1241
+ #MAL
1242
+ if = {
1243
+ limit = { can_preview_mission_of_key_and_batch = { key = MAL batch = $batch$ } }
1244
+ set_preview_loc_branch = { key = MAL batch = $batch$ branch = 1 }
1245
+ set_country_flag = mal_decide_for_conversion
1246
+ custom_tooltip = MAL_preview_conversion
1247
+ }
1248
+ #SON
1249
+ if = {
1250
+ limit = { can_preview_mission_of_key_and_batch = { key = SON batch = $batch$ } }
1251
+ set_preview_loc_branch = { key = SON batch = $batch$ branch = 1 }
1252
+ set_country_flag = son_islamic_focus
1253
+ custom_tooltip = SON_preview_islamic
1254
+ }
1255
+ #KON
1256
+ if = {
1257
+ limit = { can_preview_mission_of_key_and_batch = { key = KON batch = $batch$ } }
1258
+ set_preview_loc_branch = { key = KON batch = $batch$ branch = 1 }
1259
+ set_country_flag = kon_picked_fetishism
1260
+ custom_tooltip = KON_preview_fetishism
1261
+ }
1262
+ #Lions of the North
1263
+ #SWE
1264
+ if = {
1265
+ limit = { can_preview_mission_of_key_and_batch = { key = SWE batch = $batch$ } }
1266
+ set_preview_loc_branch = { key = SWE batch = $batch$ branch = 1 }
1267
+ set_country_flag = sca_unlock_catholic_missions
1268
+ custom_tooltip = SCA_preview_catholic
1269
+ }
1270
+ #DAN
1271
+ if = {
1272
+ limit = { can_preview_mission_of_key_and_batch = { key = DAN batch = $batch$ } }
1273
+ set_preview_loc_branch = { key = DAN batch = $batch$ branch = 1 }
1274
+ set_country_flag = sca_unlock_catholic_missions
1275
+ custom_tooltip = SCA_preview_catholic
1276
+ }
1277
+ #NOR
1278
+ if = {
1279
+ limit = { can_preview_mission_of_key_and_batch = { key = NOR batch = $batch$ } }
1280
+ set_preview_loc_branch = { key = NOR batch = $batch$ branch = 1 }
1281
+ set_country_flag = sca_unlock_catholic_missions
1282
+ custom_tooltip = SCA_preview_catholic
1283
+ }
1284
+ #TEU
1285
+ if = {
1286
+ limit = { can_preview_mission_of_key_and_batch = { key = TEU batch = $batch$ } }
1287
+ set_preview_loc_branch = { key = TEU batch = $batch$ branch = 1 }
1288
+ set_country_flag = teu_prussian_path
1289
+ custom_tooltip = TEU_preview_prussian
1290
+ }
1291
+ #TEU_PRU
1292
+ if = {
1293
+ limit = { can_preview_mission_of_key_and_batch = { key = TEU_PRU batch = $batch$ } }
1294
+ set_preview_loc_branch = { key = TEU_PRU batch = $batch$ branch = 1 }
1295
+ set_country_flag = teu_conquest_hre_path
1296
+ custom_tooltip = TEU_PRU_preview_hre_conquest
1297
+ }
1298
+ #LIV
1299
+ if = {
1300
+ limit = { can_preview_mission_of_key_and_batch = { key = LIV batch = $batch$ } }
1301
+ set_preview_loc_branch = { key = LIV batch = $batch$ branch = 1 }
1302
+ set_country_flag = liv_livonian_path
1303
+ custom_tooltip = LIV_preview_livonian
1304
+ }
1305
+ #POL
1306
+ if = {
1307
+ limit = { can_preview_mission_of_key_and_batch = { key = POL batch = $batch$ } }
1308
+ set_preview_loc_branch = { key = POL batch = $batch$ branch = 1 }
1309
+ set_country_flag = pol_chose_pu_flag
1310
+ custom_tooltip = POL_preview_lith
1311
+ }
1312
+ #Domination
1313
+ #TUR
1314
+ if = {
1315
+ limit = { can_preview_mission_of_key_and_batch = { key = TUR batch = $batch$ } }
1316
+ set_preview_loc_branch = { key = TUR batch = $batch$ branch = 1 }
1317
+ set_country_flag = tur_chose_legalism
1318
+ custom_tooltip = TUR_preview_legalism
1319
+ }
1320
+ #MNG
1321
+ if = {
1322
+ limit = { can_preview_mission_of_key_and_batch = { key = MNG batch = $batch$ } }
1323
+ set_preview_loc_branch = { key = MNG batch = $batch$ branch = 1 }
1324
+ set_country_flag = mng_dynamic_1
1325
+ custom_tooltip = MNG_preview_improve_haijin
1326
+ }
1327
+ #QNG
1328
+ if = {
1329
+ limit = { can_preview_mission_of_key_and_batch = { key = QNG batch = $batch$ } }
1330
+ set_preview_loc_branch = { key = QNG batch = $batch$ branch = 1 }
1331
+ set_country_flag = qng_open_ports_flag
1332
+ custom_tooltip = QNG_preview_open_ports
1333
+ }
1334
+ #GBR
1335
+ if = {
1336
+ limit = { can_preview_mission_of_key_and_batch = { key = GBR batch = $batch$ } }
1337
+ set_preview_loc_branch = { key = GBR batch = $batch$ branch = 1 }
1338
+ set_country_flag = eng_took_gbr_branch
1339
+ custom_tooltip = ENG_preview_gbr_branch
1340
+ }
1341
+ #FRA
1342
+ if = {
1343
+ limit = { can_preview_mission_of_key_and_batch = { key = FRA batch = $batch$ } }
1344
+ set_preview_loc_branch = { key = FRA batch = $batch$ branch = 1 }
1345
+ set_country_flag = fra_chose_to_piss_off_pope_flag
1346
+ custom_tooltip = FRA_preview_italian_wars
1347
+ }
1348
+ #FRA_HRE
1349
+ if = {
1350
+ limit = { can_preview_mission_of_key_and_batch = { key = FRA_HRE batch = $batch$ } }
1351
+ set_preview_loc_branch = { key = FRA_HRE batch = $batch$ branch = 1 }
1352
+ set_country_flag = fra_shed_the_blood_of_the_saxon_man_flag
1353
+ custom_tooltip = FRA_preview_charlemagnes_legacy
1354
+ }
1355
+ #JAP
1356
+ if = {
1357
+ limit = { can_preview_mission_of_key_and_batch = { key = JAP batch = $batch$ } }
1358
+ set_preview_loc_branch = { key = JAP batch = $batch$ branch = 1 }
1359
+ set_country_flag = jap_mushashi_5_books_flag
1360
+ custom_tooltip = JAP_preview_mushashi_5_books
1361
+ }
1362
+ #JAP_RELI
1363
+ if = {
1364
+ limit = { can_preview_mission_of_key_and_batch = { key = JAP_RELI batch = $batch$ } }
1365
+ set_preview_loc_branch = { key = JAP_RELI batch = $batch$ branch = 1 }
1366
+ set_country_flag = christianity_defeated_flag
1367
+ custom_tooltip = JAP_preview_christianity_defeated
1368
+ }
1369
+ #King of Kings
1370
+ #BYZ
1371
+ if = {
1372
+ limit = { can_preview_mission_of_key_and_batch = { key = BYZ batch = $batch$ } }
1373
+ set_preview_loc_branch = { key = BYZ batch = $batch$ branch = 1 }
1374
+ set_country_flag = BYZ_centralized
1375
+ custom_tooltip = BYZ_preview_centralized
1376
+ }
1377
+ #PER
1378
+ if = {
1379
+ limit = { can_preview_mission_of_key_and_batch = { key = PER batch = $batch$ } }
1380
+ set_preview_loc_branch = { key = PER batch = $batch$ branch = 1 }
1381
+ set_country_flag = per_shia_missions
1382
+ custom_tooltip = per_preview_shia_missions
1383
+ }
1384
+ #Winds of Change
1385
+ #HSN
1386
+ if = {
1387
+ limit = { can_preview_mission_of_key_and_batch = { key = HSN batch = $batch$ } }
1388
+ set_preview_loc_branch = { key = HSN batch = $batch$ branch = 1 }
1389
+ set_country_flag = hsn_unlock_anatolian_conquest
1390
+ custom_tooltip = hsn_unlock_anatolian_conquest
1391
+ }
1392
+ #HSN2
1393
+ if = {
1394
+ limit = { can_preview_mission_of_key_and_batch = { key = HSN2 batch = $batch$ } }
1395
+ set_preview_loc_branch = { key = HSN2 batch = $batch$ branch = 1 }
1396
+ set_country_flag = hsn_unlock_persian_alliance
1397
+ custom_tooltip = hsn_unlock_persian_alliance
1398
+ }
1399
+ #ITA_TRADE
1400
+ if = {
1401
+ limit = { can_preview_mission_of_key_and_batch = { key = ITA_TRADE batch = $batch$ } }
1402
+ set_preview_loc_branch = { key = ITA_TRADE batch = $batch$ branch = 1 }
1403
+ set_country_flag = ITA_venice_missions
1404
+ custom_tooltip = ITA_preview_venice
1405
+ }
1406
+ #FEO
1407
+ if = {
1408
+ limit = { can_preview_mission_of_key_and_batch = { key = FEO batch = $batch$ } }
1409
+ set_preview_loc_branch = { key = FEO batch = $batch$ branch = 1 }
1410
+ set_country_flag = feo_russian_conquest_branch
1411
+ custom_tooltip = feo_preview_russian_conquest_missions
1412
+ }
1413
+ #VEN
1414
+ if = {
1415
+ limit = { can_preview_mission_of_key_and_batch = { key = VEN batch = $batch$ } }
1416
+ set_preview_loc_branch = { key = VEN batch = $batch$ branch = 1 }
1417
+ set_country_flag = ven_standing_army_missions_flag
1418
+ custom_tooltip = ven_unlock_standing_army_missions_tt
1419
+ }
1420
+ #Hordes
1421
+ if = {
1422
+ limit = { can_preview_mission_of_key_and_batch = { key = HORDES batch = $batch$ } }
1423
+ set_preview_loc_branch = { key = HORDES batch = $batch$ branch = 1 }
1424
+ set_country_flag = hordes_tolerance_branch_flag
1425
+ custom_tooltip = hordes_preview_tolerant
1426
+ }
1427
+ #BOH_RELIGION
1428
+ if = {
1429
+ limit = { can_preview_mission_of_key_and_batch = { key = BOH_RELIGION batch = $batch$ } }
1430
+ set_preview_loc_branch = { key = BOH_RELIGION batch = $batch$ branch = 1 }
1431
+ set_country_flag = boh_catholic_missions
1432
+ custom_tooltip = boh_preview_catholic_branching
1433
+ }
1434
+ #TIM
1435
+ if = {
1436
+ limit = { can_preview_mission_of_key_and_batch = { key = TIM batch = $batch$ } }
1437
+ set_preview_loc_branch = { key = TIM batch = $batch$ branch = 1 }
1438
+ set_country_flag = TIM_nomad_missions
1439
+ custom_tooltip = TIM_preview_nomads
1440
+ }
1441
+ #HAB
1442
+ if = {
1443
+ limit = { can_preview_mission_of_key_and_batch = { key = HAB batch = $batch$ } }
1444
+ set_preview_loc_branch = { key = HAB batch = $batch$ branch = 1 }
1445
+ set_country_flag = hab_hre_branch
1446
+ custom_tooltip = hab_preview_hre_branch
1447
+ }
1448
+ }
1449
+ preview_mission_branch_2 = {
1450
+ #Origins
1451
+ #MAL
1452
+ if = {
1453
+ limit = { can_preview_mission_of_key_and_batch = { key = MAL batch = $batch$ } }
1454
+ set_preview_loc_branch = { key = MAL batch = $batch$ branch = 2 }
1455
+ set_country_flag = mal_decide_for_tolerance
1456
+ custom_tooltip = MAL_preview_tolerance
1457
+ }
1458
+ #SON
1459
+ if = {
1460
+ limit = { can_preview_mission_of_key_and_batch = { key = SON batch = $batch$ } }
1461
+ set_preview_loc_branch = { key = SON batch = $batch$ branch = 2 }
1462
+ set_country_flag = son_tolerance_focus
1463
+ custom_tooltip = SON_preview_tolerance
1464
+ }
1465
+ #KON
1466
+ if = {
1467
+ limit = { can_preview_mission_of_key_and_batch = { key = KON batch = $batch$ } }
1468
+ set_preview_loc_branch = { key = KON batch = $batch$ branch = 2 }
1469
+ set_country_flag = kon_picked_side_with_europeans
1470
+ custom_tooltip = KON_preview_christian
1471
+ }
1472
+ #Lions of the North
1473
+ #SWE
1474
+ if = {
1475
+ limit = { can_preview_mission_of_key_and_batch = { key = SWE batch = $batch$ } }
1476
+ set_preview_loc_branch = { key = SWE batch = $batch$ branch = 2 }
1477
+ set_country_flag = sca_unlock_protestant_missions
1478
+ custom_tooltip = SCA_preview_protestant
1479
+ }
1480
+ #DAN
1481
+ if = {
1482
+ limit = { can_preview_mission_of_key_and_batch = { key = DAN batch = $batch$ } }
1483
+ set_preview_loc_branch = { key = DAN batch = $batch$ branch = 2 }
1484
+ set_country_flag = sca_unlock_protestant_missions
1485
+ custom_tooltip = SCA_preview_protestant
1486
+ }
1487
+ #NOR
1488
+ if = {
1489
+ limit = { can_preview_mission_of_key_and_batch = { key = NOR batch = $batch$ } }
1490
+ set_preview_loc_branch = { key = NOR batch = $batch$ branch = 2 }
1491
+ set_country_flag = sca_unlock_protestant_missions
1492
+ custom_tooltip = SCA_preview_protestant
1493
+ }
1494
+ #TEU
1495
+ if = {
1496
+ limit = { can_preview_mission_of_key_and_batch = { key = TEU batch = $batch$ } }
1497
+ set_preview_loc_branch = { key = TEU batch = $batch$ branch = 2 }
1498
+ set_country_flag = teu_crusader_path
1499
+ custom_tooltip = TEU_preview_crusader
1500
+ }
1501
+ #TEU_PRU
1502
+ if = {
1503
+ limit = { can_preview_mission_of_key_and_batch = { key = TEU_PRU batch = $batch$ } }
1504
+ set_preview_loc_branch = { key = TEU_PRU batch = $batch$ branch = 2 }
1505
+ if = {
1506
+ limit = { hre_size = 1 }
1507
+ set_country_flag = teu_diplomacy_hre_path
1508
+ custom_tooltip = TEU_PRU_preview_hre_diplomacy
1509
+ }
1510
+ else = {
1511
+ set_country_flag = teu_kingdom_prussia_path
1512
+ custom_tooltip = TEU_PRU_preview_prussian_kingdom
1513
+ }
1514
+ }
1515
+ #LIV
1516
+ if = {
1517
+ limit = { can_preview_mission_of_key_and_batch = { key = LIV batch = $batch$ } }
1518
+ set_preview_loc_branch = { key = LIV batch = $batch$ branch = 2 }
1519
+ set_country_flag = liv_crusader_path
1520
+ custom_tooltip = LIV_preview_crusader
1521
+ }
1522
+ #POL
1523
+ if = {
1524
+ limit = { can_preview_mission_of_key_and_batch = { key = POL batch = $batch$ } }
1525
+ set_preview_loc_branch = { key = POL batch = $batch$ branch = 2 }
1526
+ set_country_flag = pol_denied_pu_flag
1527
+ custom_tooltip = POL_preview_hre
1528
+ }
1529
+ #Domination
1530
+ #TUR
1531
+ if = {
1532
+ limit = { can_preview_mission_of_key_and_batch = { key = TUR batch = $batch$ } }
1533
+ set_preview_loc_branch = { key = TUR batch = $batch$ branch = 2 }
1534
+ set_country_flag = tur_chose_mysticism
1535
+ custom_tooltip = TUR_preview_mysticism
1536
+ }
1537
+ #MNG
1538
+ if = {
1539
+ limit = { can_preview_mission_of_key_and_batch = { key = MNG batch = $batch$ } }
1540
+ set_preview_loc_branch = { key = MNG batch = $batch$ branch = 2 }
1541
+ set_country_flag = mng_dynamic_2
1542
+ custom_tooltip = MNG_preview_repeal_haijin
1543
+ }
1544
+ #QNG
1545
+ if = {
1546
+ limit = { can_preview_mission_of_key_and_batch = { key = QNG batch = $batch$ } }
1547
+ set_preview_loc_branch = { key = QNG batch = $batch$ branch = 2 }
1548
+ set_country_flag = qng_close_ports_flag
1549
+ custom_tooltip = QNG_preview_close_ports
1550
+ }
1551
+ #GBR
1552
+ if = {
1553
+ limit = { can_preview_mission_of_key_and_batch = { key = GBR batch = $batch$ } }
1554
+ set_preview_loc_branch = { key = GBR batch = $batch$ branch = 2 }
1555
+ set_country_flag = eng_took_ave_branch
1556
+ custom_tooltip = ENG_preview_ave_branch
1557
+ }
1558
+ #FRA
1559
+ if = {
1560
+ limit = { can_preview_mission_of_key_and_batch = { key = FRA batch = $batch$ } }
1561
+ set_preview_loc_branch = { key = FRA batch = $batch$ branch = 2 }
1562
+ set_country_flag = fra_papal_lap_dop_flag
1563
+ custom_tooltip = FRA_preview_crusader_kings
1564
+ }
1565
+ #FRA_HRE
1566
+ if = {
1567
+ limit = { can_preview_mission_of_key_and_batch = { key = FRA_HRE batch = $batch$ } }
1568
+ set_preview_loc_branch = { key = FRA_HRE batch = $batch$ branch = 2 }
1569
+ set_country_flag = fra_fufujoni_flag
1570
+ custom_tooltip = FRA_preview_kill_hre
1571
+ }
1572
+ #JAP
1573
+ if = {
1574
+ limit = { can_preview_mission_of_key_and_batch = { key = JAP batch = $batch$ } }
1575
+ set_preview_loc_branch = { key = JAP batch = $batch$ branch = 2 }
1576
+ set_country_flag = jap_domineering_naval_focus_flag
1577
+ custom_tooltip = JAP_preview_domineering_naval_focus
1578
+ }
1579
+ #JAP_RELI
1580
+ if = {
1581
+ limit = { can_preview_mission_of_key_and_batch = { key = JAP_RELI batch = $batch$ } }
1582
+ set_preview_loc_branch = { key = JAP_RELI batch = $batch$ branch = 2 }
1583
+ set_country_flag = a_kirishitan_realm
1584
+ custom_tooltip = JAP_preview_a_kirishitan_realm
1585
+ }
1586
+ #King of Kings
1587
+ #BYZ
1588
+ if = {
1589
+ limit = { can_preview_mission_of_key_and_batch = { key = BYZ batch = $batch$ } }
1590
+ set_preview_loc_branch = { key = BYZ batch = $batch$ branch = 2 }
1591
+ set_country_flag = BYZ_decentralized
1592
+ custom_tooltip = BYZ_preview_decentralized
1593
+ }
1594
+ #PER
1595
+ if = {
1596
+ limit = { can_preview_mission_of_key_and_batch = { key = PER batch = $batch$ } }
1597
+ set_preview_loc_branch = { key = PER batch = $batch$ branch = 2 }
1598
+ set_country_flag = per_sunni_missions
1599
+ custom_tooltip = per_preview_sunni_missions
1600
+ }
1601
+ #Winds of Change
1602
+ #HAB
1603
+ if = {
1604
+ limit = { can_preview_mission_of_key_and_batch = { key = HAB batch = $batch$ } }
1605
+ set_preview_loc_branch = { key = HAB batch = $batch$ branch = 2 }
1606
+ set_country_flag = hab_germany_branch
1607
+ custom_tooltip = hab_preview_germany_branch
1608
+ }
1609
+ #BOH_RELIGION
1610
+ if = {
1611
+ limit = { can_preview_mission_of_key_and_batch = { key = BOH_RELIGION batch = $batch$ } }
1612
+ set_preview_loc_branch = { key = BOH_RELIGION batch = $batch$ branch = 2 }
1613
+ set_country_flag = boh_hussite_missions
1614
+ custom_tooltip = boh_preview_hussite_branching
1615
+ }
1616
+ #HSN
1617
+ if = {
1618
+ limit = { can_preview_mission_of_key_and_batch = { key = HSN batch = $batch$ } }
1619
+ set_preview_loc_branch = { key = HSN batch = $batch$ branch = 2 }
1620
+ set_country_flag = hsn_unlock_anatolian_alliance
1621
+ custom_tooltip = hsn_unlock_anatolian_alliance
1622
+ }
1623
+ #HSN2
1624
+ if = {
1625
+ limit = { can_preview_mission_of_key_and_batch = { key = HSN2 batch = $batch$ } }
1626
+ set_preview_loc_branch = { key = HSN2 batch = $batch$ branch = 2 }
1627
+ set_country_flag = hsn_unlock_persian_conquest
1628
+ custom_tooltip = hsn_unlock_persian_conquest
1629
+ }
1630
+ #ITA_TRADE
1631
+ if = {
1632
+ limit = { can_preview_mission_of_key_and_batch = { key = ITA_TRADE batch = $batch$ } }
1633
+ set_preview_loc_branch = { key = ITA_TRADE batch = $batch$ branch = 2 }
1634
+ set_country_flag = ITA_genoa_missions
1635
+ custom_tooltip = ITA_preview_genoa
1636
+ }
1637
+ #FEO
1638
+ if = {
1639
+ limit = { can_preview_mission_of_key_and_batch = { key = FEO batch = $batch$ } }
1640
+ set_preview_loc_branch = { key = FEO batch = $batch$ branch = 2 }
1641
+ set_country_flag = feo_russian_alliance_branch
1642
+ custom_tooltip = feo_preview_russian_alliance_missions
1643
+ }
1644
+ #TIM
1645
+ if = {
1646
+ limit = { can_preview_mission_of_key_and_batch = { key = TIM batch = $batch$ } }
1647
+ set_preview_loc_branch = { key = TIM batch = $batch$ branch = 2 }
1648
+ set_country_flag = TIM_persian_missions
1649
+ custom_tooltip = TIM_preview_persians
1650
+ }
1651
+ #VEN
1652
+ if = {
1653
+ limit = { can_preview_mission_of_key_and_batch = { key = VEN batch = $batch$ } }
1654
+ set_preview_loc_branch = { key = VEN batch = $batch$ branch = 2 }
1655
+ set_country_flag = ven_mercenary_army_missions_flag
1656
+ custom_tooltip = ven_unlock_mercenary_army_missions_tt
1657
+ }
1658
+ #Hordes
1659
+ if = {
1660
+ limit = { can_preview_mission_of_key_and_batch = { key = HORDES batch = $batch$ } }
1661
+ set_preview_loc_branch = { key = HORDES batch = $batch$ branch = 2 }
1662
+ set_country_flag = hordes_devout_branch_flag
1663
+ custom_tooltip = hordes_preview_devout
1664
+ }
1665
+ }
1666
+ preview_mission_branch_3 = {
1667
+ #Origins
1668
+ # none
1669
+ #Lions of the North
1670
+ #SWE
1671
+ if = {
1672
+ limit = { can_preview_mission_of_key_and_batch = { key = SWE batch = $batch$ } }
1673
+ set_preview_loc_branch = { key = SWE batch = $batch$ branch = 3 }
1674
+ set_country_flag = sca_unlock_humanist_missions
1675
+ custom_tooltip = SCA_preview_humanist
1676
+ }
1677
+ #DAN
1678
+ if = {
1679
+ limit = { can_preview_mission_of_key_and_batch = { key = DAN batch = $batch$ } }
1680
+ set_preview_loc_branch = { key = DAN batch = $batch$ branch = 3 }
1681
+ set_country_flag = sca_unlock_humanist_missions
1682
+ custom_tooltip = SCA_preview_humanist
1683
+ }
1684
+ #NOR
1685
+ if = {
1686
+ limit = { can_preview_mission_of_key_and_batch = { key = NOR batch = $batch$ } }
1687
+ set_preview_loc_branch = { key = NOR batch = $batch$ branch = 3 }
1688
+ set_country_flag = sca_unlock_humanist_missions
1689
+ custom_tooltip = SCA_preview_humanist
1690
+ }
1691
+ #TEU_PRU
1692
+ if = {
1693
+ limit = { can_preview_mission_of_key_and_batch = { key = TEU_PRU batch = $batch$ } }
1694
+ set_preview_loc_branch = { key = TEU_PRU batch = $batch$ branch = 3 }
1695
+ set_country_flag = teu_kingdom_prussia_path
1696
+ custom_tooltip = TEU_PRU_preview_prussian_kingdom
1697
+ }
1698
+ #Domination
1699
+ #TUR
1700
+ if = {
1701
+ limit = { can_preview_mission_of_key_and_batch = { key = TUR batch = $batch$ } }
1702
+ set_preview_loc_branch = { key = TUR batch = $batch$ branch = 3 }
1703
+ set_country_flag = tur_non_muslim_path_flag
1704
+ custom_tooltip = TUR_preview_non_muslim_path
1705
+ }
1706
+ #King of Kings
1707
+ #PER
1708
+ if = {
1709
+ limit = { can_preview_mission_of_key_and_batch = { key = PER batch = $batch$ } }
1710
+ set_preview_loc_branch = { key = PER batch = $batch$ branch = 3 }
1711
+ set_country_flag = per_zoroastrian_missions
1712
+ custom_tooltip = per_preview_zoroastrian_missions
1713
+ }
1714
+ #Winds of Change
1715
+ #VEN
1716
+ if = {
1717
+ limit = { can_preview_mission_of_key_and_batch = { key = VEN batch = $batch$ } }
1718
+ set_preview_loc_branch = { key = VEN batch = $batch$ branch = 3 }
1719
+ set_country_flag = ven_navy_missions_flag
1720
+ custom_tooltip = ven_unlock_navy_missions_tt
1721
+ }
1722
+ #Hordes
1723
+ if = {
1724
+ limit = { can_preview_mission_of_key_and_batch = { key = HORDES batch = $batch$ } }
1725
+ set_preview_loc_branch = { key = HORDES batch = $batch$ branch = 3 }
1726
+ set_country_flag = hordes_confucian_branch_flag
1727
+ custom_tooltip = hordes_preview_confucian
1728
+ }
1729
+ }
1730
+ preview_mission_branch_4 = {
1731
+ #Origins
1732
+ # none
1733
+ #Lions of the North
1734
+ #SWE
1735
+ if = {
1736
+ limit = { can_preview_mission_of_key_and_batch = { key = SWE batch = $batch$ } }
1737
+ set_preview_loc_branch = { key = SWE batch = $batch$ branch = 4 }
1738
+ set_country_flag = sca_unlock_norse_missions
1739
+ custom_tooltip = SCA_preview_norse
1740
+ }
1741
+ #DAN
1742
+ if = {
1743
+ limit = { can_preview_mission_of_key_and_batch = { key = DAN batch = $batch$ } }
1744
+ set_preview_loc_branch = { key = DAN batch = $batch$ branch = 4 }
1745
+ set_country_flag = sca_unlock_norse_missions
1746
+ custom_tooltip = SCA_preview_norse
1747
+ }
1748
+ #NOR
1749
+ if = {
1750
+ limit = { can_preview_mission_of_key_and_batch = { key = NOR batch = $batch$ } }
1751
+ set_preview_loc_branch = { key = NOR batch = $batch$ branch = 4 }
1752
+ set_country_flag = sca_unlock_norse_missions
1753
+ custom_tooltip = SCA_preview_norse
1754
+ }
1755
+ #Domination
1756
+ # none
1757
+ #King of Kings
1758
+ # none
1759
+ #Winds of Change
1760
+ # none
1761
+ }
1762
+ preview_mission_branch_5 = {
1763
+ #Origins
1764
+ # none
1765
+ #Lions of the North
1766
+ # none
1767
+ #Domination
1768
+ # none
1769
+ #King of Kings
1770
+ # none
1771
+ #Winds of Change
1772
+ # none
1773
+ if = {
1774
+ limit = { can_preview_mission_of_key_and_batch = { key = DUMMY batch = $batch$ } }
1775
+ custom_tooltip = COOL_EFFECT
1776
+ }
1777
+ }
1778
+ preview_mission_branch = {
1779
+ clear_all_branching_flags = { batch = $batch$ }
1780
+ preview_mission_branch_$branch$ = { batch = $batch$ }
1781
+ hidden_effect = { swap_non_generic_missions = yes }
1782
+ }
common/scripted_effects/02_scripted_effects_unlocks.txt ADDED
@@ -0,0 +1,797 @@
1
+ #Country effect
2
+ ##########################################################
3
+ # Supports following privileges
4
+ # estate_burghers_hydraulic_rights
5
+ # estate_nobles_cawa_peace_keepers
6
+ # estate_nobles_cawa_offensive_fighters
7
+ # estate_burghers_control_over_the_mint
8
+ # estate_dhimmi_guarantee_of_traditions
9
+ # estate_church_yakobs_churches
10
+ # estate_nobles_grant_power_to_the_bashorun
11
+ # estate_burghers_forest_expansion
12
+ # estate_burghers_mountain_expansion
13
+ # estate_nobles_leidang_conscription
14
+ # estate_burghers_orthodox_tolerance
15
+ # estate_church_anti_heresy_act
16
+ # estate_nobles_religious_conscription
17
+ # estate_dhimmi_millet_system
18
+ # estate_burghers_the_new_middle_class
19
+ # estate_janissary_ottoman_vanguards
20
+ # estate_nobles_english_copyhold_tenure
21
+ # estate_burghers_autonomous_trade_companies
22
+ # estate_nobles_defensive_policy
23
+ # estate_qizilbash_defensive_policy
24
+ # estate_ghulams_defensive_policy
25
+ # estate_nobles_tofangchi_regiment
26
+ # estate_qizilbash_tofangchi_regiment
27
+ # estate_ghulams_tofangchi_regiment
28
+ # estate_nobles_tupchi_artillery_corps
29
+ # estate_qizilbash_tupchi_artillery_corps
30
+ # estate_ghulams_tupchi_artillery_corps
31
+ ##########################################################
32
+ # When adding new privileges then make sure that a unlock_privilege_$estate_privilege$_tt is defined in the localization
33
+ # For checking if an estate privilege is unlocked already, use has_unlocked_estate_privilege = { estate_privilege = $estate_privilege$ }
34
+ # For localization write the following: "Enable the [Root.<Estate Name>] privilege '§Y<Privilege Name>§!'."
35
+ unlock_estate_privilege = {
36
+ custom_tooltip = unlock_privilege_$estate_privilege$_tt
37
+ hidden_effect = {
38
+ set_country_flag = unlocked_privilege_$estate_privilege$
39
+ }
40
+ [[modifier_tooltip]
41
+ custom_tooltip = unlock_estate_privilege_modifier_tooltip_tt
42
+ tooltip = {
43
+ add_country_modifier = {
44
+ name = $modifier_tooltip$
45
+ duration = -1
46
+ desc = UNTIL_PRIVILEGE_REVOKED
47
+ }
48
+ }
49
+ ]
50
+ [[effect_tooltip]
51
+ custom_tooltip = unlock_estate_privilege_effect_tooltip_tt
52
+ tooltip = {
53
+ $effect_tooltip$
54
+ }
55
+ ]
56
+ }
57
+
58
+ #Country effect
59
+ ##########################################################
60
+ # Supports following merc companies
61
+ # merc_oyo_cavalry
62
+ # merc_hakkapeliita_cavalry
63
+ # merc_prussian_volunteer_army
64
+ # merc_large_hakkapeliita_cavalry
65
+ # merc_guerilla_hakkapeliita_cavalry
66
+ # merc_elite_hakkapeliita_cavalry
67
+ # merc_schwarze_garde
68
+ # merc_hessian_jaegerkorps
69
+ # merc_doppelsoeldner
70
+ # merc_frisian_free_company
71
+ # merc_flemish_company
72
+ # merc_reislaufer
73
+ # merc_tatar_vanguard
74
+ ##########################################################
75
+ # When adding a new merc company then make sure that a unlock_$merc_company$_tt is defined in the localization
76
+ # For checking if a merc company is unlocked already, use has_unlocked_merc_company = { merc_company = $merc_company$ }
77
+ # For localization write the following: "Unlock the mercenary company §Y<Merc Company>§! to recruit."
78
+ unlock_merc_company = {
79
+ custom_tooltip = unlock_$merc_company$_tt
80
+ hidden_effect = {
81
+ set_country_flag = unlocked_$merc_company$
82
+ }
83
+ [[free_merc]
84
+ if = {
85
+ limit = { has_dlc = "Cradle of Civilization" }
86
+ custom_tooltip = costs_no_army_professionalism
87
+ }
88
+ ]
89
+ [[global]
90
+ custom_tooltip = global_merc_company
91
+ hidden_effect = {
92
+ set_global_flag = global_unlocked_$merc_company$
93
+ }
94
+ ]
95
+ }
96
+
97
+ #Same as above, but this time it makes a company unavailable
98
+ #Does not support any merc company yet
99
+ #lock_merc_company = {
100
+ # custom_tooltip = lock_$merc_company$_tt
101
+ # hidden_effect = {
102
+ # clr_country_flag = unlocked_$merc_company$
103
+ # }
104
+ #}
105
+
106
+ #Country effect
107
+ ##########################################################
108
+ # Supports following church aspects
109
+ # anglican_aspect
110
+ # spread_the_book_of_common_prayer
111
+ ##########################################################
112
+ # When adding a new unlockable Church Aspect then make sure that a unlock_church_aspect_$church_aspect$_tt is defined in the localization
113
+ # For checking if a Church Aspect is unlocked already, use has_unlocked_church_aspect = { church_aspect = $church_aspect$ }
114
+ # For localization write the following: "Unlock the Protestant church aspect '§Y<Church Aspect>§!'."
115
+ unlock_church_aspect = {
116
+ custom_tooltip = unlock_church_aspect_$church_aspect$_tt
117
+ hidden_effect = {
118
+ set_country_flag = unlocked_church_aspect_$church_aspect$
119
+ }
120
+ }
121
+
122
+ #Country effect
123
+ ##########################################################
124
+ # Supports following government reforms
125
+ # prussian_monarchy_base
126
+ # prussian_republic_reform
127
+ # prussian_theocratic_reform
128
+ # holy_horde_reform
129
+ # crusading_kingdom_reform
130
+ # militarized_crusader_order_reform
131
+ # allotment_system
132
+ # expanded_devshirme_system_reform
133
+ # ottoman_siyasah_tax_reform
134
+ # fiqh_laws_reform
135
+ # sufism_decree_reform
136
+ # ottoman_conscription_reform
137
+ # reformed_ottoman_conscription_reform
138
+ # mansure_army_reform
139
+ # janissary_military_reform
140
+ # standardized_millets_reform
141
+ # modernized_ottoman_government
142
+ # reorganized_ottoman_government
143
+ # russian_empire_reform
144
+ # great_russian_republic_reform
145
+ # professional_navy_reform
146
+ # thalassocracy_reform
147
+ # governing_senate_reform
148
+ # enforced_autocracy_reform
149
+ # holy_synod_reform
150
+ # strengthened_the_patriarchy_reform
151
+ # head_of_the_patriarchy_reform
152
+ # tysyatsky_reform
153
+ # namestnik_reform
154
+ # oprichnina_reform
155
+ # anglican_state_church_reform
156
+ # english_conciliarism_reform
157
+ # direct_royal_administration_reform
158
+ # administration_of_the_parliament_reform
159
+ # royal_charters_reform
160
+ # commercial_trade_empire_reform
161
+ # peters_government_reform
162
+ # caliphate_reform
163
+ # caliphate_theocracy_reform
164
+ # legacy_of_timur_reform
165
+ # legacy_of_the_safavid_reform
166
+ # divided_aristocracy_reform
167
+ ##########################################################
168
+ # When adding a new government reform then make sure that a unlock_$government_reform$_tt is defined in the localization
169
+ # For checking if a government reform is unlocked already, use has_unlocked_government_reform = { government_reform = $government_reform$ }
170
+ # For localization write the following: "Unlock the government reform §Y<Government Reform>§!."
171
+ unlock_government_reform = {
172
+ custom_tooltip = unlock_$government_reform$_tt
173
+ hidden_effect = {
174
+ set_country_flag = unlocked_$government_reform$
175
+ }
176
+ [[tooltip]
177
+ custom_tooltip = unlock_government_reform_tooltip
178
+ tooltip = {
179
+ add_government_reform = $government_reform$
180
+ }
181
+ ]
182
+ }
183
+
184
+ #Country effect
185
+ ##########################################################
186
+ # Has the localization for the following estates:
187
+ # estate_brahmins
188
+ # estate_church
189
+ # estate_maratha
190
+ # estate_nobles
191
+ # estate_burghers
192
+ # estate_vaisyas
193
+ # estate_cossacks
194
+ # estate_nomadic_tribes
195
+ # estate_dhimmi
196
+ # estate_jains
197
+ # estate_rajput
198
+ # estate_janissaries
199
+ # estate_eunuchs
200
+ # estate_qizilbash
201
+ # estate_ghulams
202
+ ##########################################################
203
+ # When adding a new estate then make sure that a unlock_$estate$_tt is defined in the localization
204
+ # For checking if an Estate is unlocked already, use has_unlocked_estate = { estate = $estate$ }
205
+ # For localization write the following: "Unlock the §Y<Estate>§! Estate."
206
+ # Important: this way of unlocking an estate does not give you permanent access to the estate - hence the show_conditions.
207
+ # For granting permanent access, use "enable_estate_effect"
208
+ unlock_estate = {
209
+ custom_tooltip = unlock_$estate$_tt
210
+ hidden_effect = {
211
+ set_country_flag = unlocked_$estate$_flag
212
+ }
213
+ [[show_conditions]
214
+ custom_tooltip = is_unavailable_$estate$
215
+ ]
216
+ }
217
+
218
+ #Country effect
219
+ ##########################################################
220
+ # Has the localization for the following estates:
221
+ # estate_brahmins
222
+ # estate_church
223
+ # estate_maratha
224
+ # estate_nobles
225
+ # estate_burghers
226
+ # estate_vaisyas
227
+ # estate_cossacks
228
+ # estate_nomadic_tribes
229
+ # estate_dhimmi
230
+ # estate_jains
231
+ # estate_rajput
232
+ # estate_janissaries
233
+ # estate_eunuchs
234
+ # estate_qizilbash
235
+ # estate_ghulams
236
+ ##########################################################
237
+ # Unlocks the estate without any kind of condition
238
+ enable_estate_effect = {
239
+ custom_tooltip = mechanic_enables_$estate$_yes
240
+ hidden_effect = {
241
+ clr_country_flag = disables_$estate$_flag
242
+ set_country_flag = enables_$estate$_flag
243
+ }
244
+ }
245
+
246
+ #Country effect
247
+ ##########################################################
248
+ # Has the localization for the following estates:
249
+ # estate_brahmins
250
+ # estate_church
251
+ # estate_maratha
252
+ # estate_nobles
253
+ # estate_burghers
254
+ # estate_vaisyas
255
+ # estate_cossacks
256
+ # estate_nomadic_tribes
257
+ # estate_dhimmi
258
+ # estate_jains
259
+ # estate_rajput
260
+ # estate_janissaries
261
+ # estate_eunuchs
262
+ # estate_qizilbash
263
+ # estate_ghulams
264
+ ##########################################################
265
+ # Locks the estate even if they would
266
+ disable_estate_effect = {
267
+ custom_tooltip = mechanic_disables_$estate$_yes
268
+ hidden_effect = {
269
+ set_country_flag = disables_$estate$_flag
270
+ clr_country_flag = enables_$estate$_flag
271
+ }
272
+ }
273
+
274
+ enable_full_ducat_gain_from_selling_crownland = {
275
+ custom_tooltip = enable_full_ducat_gain_from_selling_crownland_tt
276
+ set_country_flag = enable_full_ducat_gain_from_selling_crownland_flag
277
+ }
278
+
279
+ can_sell_crownland_to_estates_targeted = {
280
+ custom_tooltip = can_sell_crownland_to_estates_targeted_tt
281
+ set_country_flag = can_sell_crownland_to_estates_targeted_flag
282
+ }
283
+
284
+ can_seize_crownland_to_estates_targeted = {
285
+ custom_tooltip = can_seize_crownland_to_estates_targeted_tt
286
+ set_country_flag = can_seize_crownland_to_estates_targeted_flag
287
+ }
288
+
289
+ #Country effect - Mission reward
290
+ allow_baseline_invite_scholar = {
291
+ custom_tooltip = allows_every_time_invite_of_$religious_school$
292
+ hidden_effect = {
293
+ set_country_flag = can_always_invite_$religious_school$
294
+ }
295
+ [[religious_school_modifier]
296
+ tooltip = {
297
+ add_country_modifier = {
298
+ name = $religious_school_modifier$
299
+ duration = -1
300
+ }
301
+ }
302
+ ]
303
+ }
304
+
305
+ #Country effect
306
+ enable_propogate_religion_effect = {
307
+ custom_tooltip = enable_propogate_religion_effect_tt
308
+ hidden_effect = {
309
+ set_country_flag = can_use_propagate_religion
310
+ }
311
+ }
312
+
313
+ #Country effect
314
+ disable_propogate_religion_effect = {
315
+ custom_tooltip = disable_propogate_religion_effect_tt
316
+ hidden_effect = {
317
+ clr_country_flag = can_use_propagate_religion
318
+ }
319
+ }
320
+
321
+ #5, #10, #15, #20, #25, #30, #35, #40, #45
322
+ set_trade_power_requirement_of_propogate_religion = {
323
+ custom_tooltip = set_trade_power_requirement_of_propogate_religion_$value$_tt
324
+ hidden_effect = {
325
+ set_country_flag = $value$_trade_power_for_propogate_religion
326
+ }
327
+ }
328
+
329
+ #Country effect
330
+ enable_propogate_religion_immunity = {
331
+ custom_tooltip = enable_propogate_religion_immunity_tt
332
+ hidden_effect = {
333
+ set_country_flag = immunity_against_propogate_religion
334
+ }
335
+ }
336
+
337
+ #Country effect
338
+ disable_propogate_religion_immunity = {
339
+ custom_tooltip = disable_propogate_religion_immunity_tt
340
+ hidden_effect = {
341
+ clr_country_flag = immunity_against_propogate_religion
342
+ }
343
+ }
344
+
345
+ #Country effect
346
+ enable_propagate_religion_in_abrahamic_provinces= {
347
+ custom_tooltip = enable_propogate_religion_in_abrahamic_provinces_tt
348
+ hidden_effect = {
349
+ set_country_flag = can_propagate_religion_in_abrahamic_provinces
350
+ }
351
+ }
352
+
353
+ #Country effect
354
+ disable_propogate_religion_in_abrahamic_provinces = {
355
+ custom_tooltip = disable_propogate_religion_in_abrahamic_provinces_tt
356
+ hidden_effect = {
357
+ clr_country_flag = can_propagate_religion_in_abrahamic_provinces
358
+ }
359
+ }
360
+
361
+ #Country effect
362
+ #Supports the following Trading Policies
363
+ # maximize_profit
364
+ # hostile_trading
365
+ # improve_inland_routes
366
+ # establish_communities
367
+ # propagate_religion
368
+ #Makes Trading Policy SELECTABLE
369
+ unlock_trading_policy = {
370
+ custom_tooltip = unlock_trading_policy_$policy$_tt
371
+ hidden_effect = {
372
+ clr_country_flag = locked_trading_policy_$policy$
373
+ }
374
+ }
375
+ #Makes Trading Policy UNSELECTABLE
376
+ lock_trading_policy = {
377
+ custom_tooltip = lock_trading_policy_$policy$_tt
378
+ hidden_effect = {
379
+ set_country_flag = locked_trading_policy_$policy$
380
+ }
381
+ }
382
+ #Makes Trading Policy VISIBLE
383
+ enable_trading_policy = {
384
+ custom_tooltip = enable_trading_policy_$policy$_tt
385
+ hidden_effect = {
386
+ set_country_flag = enabled_trading_policy_$policy$
387
+ clr_country_flag = disabled_trading_policy_$policy$
388
+ }
389
+ }
390
+ #Makes Trading Policy INVISIBLE
391
+ disable_trading_policy = {
392
+ custom_tooltip = disable_trading_policy_$policy$_tt
393
+ hidden_effect = {
394
+ set_country_flag = disabled_trading_policy_$policy$
395
+ clr_country_flag = enabled_trading_policy_$policy$
396
+ }
397
+ }
398
+
399
+ #Country effect
400
+ enable_cult_for_heirs = {
401
+ custom_tooltip = enable_cult_for_heirs_tt
402
+ hidden_effect = {
403
+ set_country_flag = enabled_cult_for_heirs
404
+ if = {
405
+ limit = {
406
+ has_heir = yes
407
+ }
408
+ country_event = {
409
+ id = fetishist_flavor.600
410
+ }
411
+ }
412
+ }
413
+ }
414
+
415
+ #Country effect
416
+ enable_cult_for_heirs_mission = {
417
+ custom_tooltip = enable_cult_for_heirs_tt
418
+ hidden_effect = {
419
+ if = {
420
+ limit = { has_estate_privilege = estate_church_heir_shrine }
421
+ remove_estate_privilege = estate_church_heir_shrine
422
+ }
423
+ set_country_flag = enabled_cult_for_heirs
424
+ set_country_flag = heir_cult_through_missions
425
+ if = {
426
+ limit = {
427
+ has_heir = yes
428
+ }
429
+ country_event = {
430
+ id = fetishist_flavor.600
431
+ }
432
+ }
433
+ }
434
+ }
435
+
436
+ #Country effect
437
+ remove_heir_cult = {
438
+ trigger_switch = {
439
+ on_trigger = has_country_modifier
440
+ junior_yemoja_cult = { remove_country_modifier = junior_yemoja_cult }
441
+ junior_roog_cult = { remove_country_modifier = junior_roog_cult }
442
+ junior_nyame_cult = { remove_country_modifier = junior_nyame_cult }
443
+ junior_cwezi_cult = { remove_country_modifier = junior_cwezi_cult }
444
+ junior_central_african_ancestor_cult = { remove_country_modifier = junior_central_african_ancestor_cult }
445
+ junior_mwari_cult = { remove_country_modifier = junior_mwari_cult }
446
+ junior_enkai_cult = { remove_country_modifier = junior_enkai_cult }
447
+ junior_waaq_cult = { remove_country_modifier = junior_waaq_cult }
448
+ junior_zanahary_cult = { remove_country_modifier = junior_zanahary_cult }
449
+ junior_christianity_cult = { remove_country_modifier = junior_christianity_cult }
450
+ junior_islam_cult = { remove_country_modifier = junior_islam_cult }
451
+ junior_buddhism_cult = { remove_country_modifier = junior_buddhism_cult }
452
+ junior_dharmic_cult = { remove_country_modifier = junior_dharmic_cult }
453
+ junior_south_central_american_cult = { remove_country_modifier = junior_south_central_american_cult }
454
+ junior_norse_cult = { remove_country_modifier = junior_norse_cult }
455
+ junior_jewish_cult = { remove_country_modifier = junior_jewish_cult }
456
+ junior_zoroastrian_cult = { remove_country_modifier = junior_zoroastrian_cult }
457
+ }
458
+ }
459
+
460
+ disable_cult_for_heirs = {
461
+ custom_tooltip = disable_cult_for_heirs_tt
462
+ hidden_effect = {
463
+ remove_heir_cult = yes
464
+ clr_country_flag = enabled_cult_for_heirs
465
+ }
466
+ }
467
+
468
+ #Country effect
469
+ unlock_cult_through_selection = {
470
+ custom_tooltip = unlock_cult_through_selection_tt
471
+ hidden_effect = {
472
+ country_event = {
473
+ id = fetishist_flavor.601
474
+ }
475
+ }
476
+ }
477
+
478
+ #Country effect
479
+ half_estate_privilege_absolutism_loss = {
480
+ custom_tooltip = half_estate_privilege_absolutism_loss_tt
481
+ hidden_effect = {
482
+ set_country_flag = has_halved_absolutism_reduction
483
+ }
484
+ }
485
+
486
+ #Country effect
487
+ disable_annexation_penalty = {
488
+ custom_tooltip = disable_annexation_penalty_tt
489
+ hidden_effect = {
490
+ set_country_flag = no_integrate_penalty
491
+ remove_country_modifier = annexers_legacy
492
+ }
493
+ }
494
+
495
+ #Country effect
496
+ enable_annexation_penalty = {
497
+ custom_tooltip = enable_annexation_penalty_tt
498
+ hidden_effect = {
499
+ clr_country_flag = no_integrate_penalty
500
+ }
501
+ }
502
+
503
+ #Country effect
504
+ enable_cult_switching = {
505
+ custom_tooltip = enable_cult_switching_tt
506
+ hidden_effect = {
507
+ set_country_flag = enabled_cult_switching
508
+ }
509
+ }
510
+ enable_cult_switching_mission = {
511
+ custom_tooltip = enable_cult_switching_tt
512
+ hidden_effect = {
513
+ set_country_flag = enabled_cult_switching_mission
514
+ }
515
+ }
516
+
517
+ #Country effect
518
+ disable_cult_switching = {
519
+ custom_tooltip = disable_cult_switching_tt
520
+ hidden_effect = {
521
+ clr_country_flag = enabled_cult_switching
522
+ }
523
+ }
524
+
525
+ #Country effect
526
+ enable_primary_cult = {
527
+ custom_tooltip = enable_primary_cult_tt
528
+ hidden_effect = {
529
+ set_country_flag = uses_primary_cult
530
+ country_event = {
531
+ id = fetishist_flavor.602
532
+ }
533
+ }
534
+ }
535
+
536
+ #Country effect
537
+ disable_primary_cult = {
538
+ custom_tooltip = disable_primary_cult_tt
539
+ hidden_effect = {
540
+ clr_country_flag = uses_primary_cult
541
+ clr_country_flag = has_selected_a_primary_cult
542
+ clear_previous_primary_cults = yes
543
+ }
544
+ }
545
+
546
+ #Country effect
547
+ disable_scholar_cost = {
548
+ custom_tooltip = disable_scholar_cost_tt
549
+ hidden_effect = {
550
+ set_country_flag = no_scholar_adm_cost
551
+ }
552
+ }
553
+
554
+ #Country effect
555
+ enable_scholar_cost = {
556
+ custom_tooltip = enable_scholar_cost_tt
557
+ hidden_effect = {
558
+ clr_country_flag = no_scholar_adm_cost
559
+ }
560
+ }
561
+
562
+ #Country effect - Estate
563
+ enable_baseline_invite_scholar = {
564
+ custom_tooltip = enable_baseline_invite_scholar_tt
565
+ hidden_effect = {
566
+ country_event = {
567
+ id = muslim_school_events.24
568
+ }
569
+ set_country_flag = enabled_baseline_invite_scholar
570
+ }
571
+ }
572
+
573
+ enable_baseline_invite_scholar_no_privilege = {
574
+ custom_tooltip = enable_baseline_invite_scholar_tt
575
+ hidden_effect = {
576
+ country_event = {
577
+ id = muslim_school_events.24
578
+ }
579
+ set_country_flag = enabled_baseline_invite_scholar_no_priv
580
+ }
581
+ }
582
+
583
+ allow_baseline_invite_scholar_privilege = {
584
+ custom_tooltip = allows_every_time_invite_of_$religious_school$
585
+ hidden_effect = {
586
+ set_country_flag = privilege_can_always_invite_$religious_school$
587
+ }
588
+ custom_tooltip = allow_baseline_invite_scholar_privilege_tt
589
+ custom_tooltip = $religious_school$_bonus_tt
590
+ }
591
+
592
+ disallow_baseline_invite_scholar = {
593
+ hidden_effect = {
594
+ clr_country_flag = privilege_can_always_invite_hanafi_school
595
+ clr_country_flag = privilege_can_always_invite_hanbali_school
596
+ clr_country_flag = privilege_can_always_invite_maliki_school
597
+ clr_country_flag = privilege_can_always_invite_shafii_school
598
+ clr_country_flag = privilege_can_always_invite_ismaili_school
599
+ clr_country_flag = privilege_can_always_invite_jafari_school
600
+ clr_country_flag = privilege_can_always_invite_zaidi_school
601
+ }
602
+ }
603
+
604
+ disable_baseline_invite_scholar = {
605
+ custom_tooltip = disable_baseline_invite_scholar_tt
606
+ hidden_effect = {
607
+ clr_country_flag = enabled_baseline_invite_scholar
608
+ if = {
609
+ limit = { NOT = { has_country_flag = enabled_baseline_invite_scholar_no_priv } }
610
+ clr_country_flag = privilege_can_always_invite_hanafi_school
611
+ clr_country_flag = privilege_can_always_invite_hanbali_school
612
+ clr_country_flag = privilege_can_always_invite_maliki_school
613
+ clr_country_flag = privilege_can_always_invite_shafii_school
614
+ clr_country_flag = privilege_can_always_invite_ismaili_school
615
+ clr_country_flag = privilege_can_always_invite_jafari_school
616
+ clr_country_flag = privilege_can_always_invite_zaidi_school
617
+ }
618
+ }
619
+ }
620
+
621
+ #Country effect
622
+ enable_capital_slave_raid = {
623
+ custom_tooltip = enable_capital_slave_raid_tt
624
+ hidden_effect = {
625
+ set_country_flag = enabled_capital_slave_raid
626
+ }
627
+ if = {
628
+ limit = { has_dlc = "Leviathan" }
629
+ custom_tooltip = enable_slave_raid_pillage_tt
630
+ }
631
+ }
632
+
633
+ disable_capital_slave_raid = {
634
+ custom_tooltip = disable_capital_slave_raid_tt
635
+ hidden_effect = {
636
+ clr_country_flag = enabled_capital_slave_raid
637
+ }
638
+ if = {
639
+ limit = { has_dlc = "Leviathan" }
640
+ custom_tooltip = disable_slave_raid_pillage_tt
641
+ }
642
+ }
643
+
644
+ #Country effect
645
+ enable_tributary_state_use = {
646
+ if = {
647
+ limit = {
648
+ OR = {
649
+ has_dlc = "Mandate of Heaven"
650
+ has_dlc = "Origins"
651
+ }
652
+ }
653
+ custom_tooltip = enable_tributary_state_use_tt
654
+ }
655
+ hidden_effect = {
656
+ set_country_flag = can_create_tributaries_flag
657
+ }
658
+ }
659
+
660
+ disable_tributary_state_use = {
661
+ if = {
662
+ limit = {
663
+ OR = {
664
+ has_dlc = "Mandate of Heaven"
665
+ has_dlc = "Origins"
666
+ }
667
+ }
668
+ custom_tooltip = disable_tributary_state_use_tt
669
+ }
670
+ hidden_effect = {
671
+ clr_country_flag = can_create_tributaries_flag
672
+ }
673
+ }
674
+
675
+ #Use for estate effects
676
+ enable_tributary_state_use_estate = {
677
+ if = {
678
+ limit = {
679
+ OR = {
680
+ has_dlc = "Mandate of Heaven"
681
+ has_dlc = "Origins"
682
+ }
683
+ }
684
+ custom_tooltip = enable_tributary_state_use_tt
685
+ }
686
+ hidden_effect = {
687
+ set_country_flag = can_create_tributaries_flag_estate
688
+ }
689
+ }
690
+
691
+ disable_tributary_state_use_estate = {
692
+ if = {
693
+ limit = {
694
+ OR = {
695
+ has_dlc = "Mandate of Heaven"
696
+ has_dlc = "Origins"
697
+ }
698
+ }
699
+ custom_tooltip = disable_tributary_state_use_tt
700
+ }
701
+ hidden_effect = {
702
+ clr_country_flag = can_create_tributaries_flag_estate
703
+ }
704
+ every_subject_country = {
705
+ limit = {
706
+ is_subject_of_type = tributary_state
707
+ }
708
+ grant_independence = yes
709
+ }
710
+ }
711
+
712
+ fifty_percent_merc_army_professionalism_cost = {
713
+ custom_tooltip = fifty_percent_merc_army_professionalism_cost_tt
714
+ hidden_effect = {
715
+ set_country_flag = fifty_percent_merc_army_professionalism_cost
716
+ }
717
+ }
718
+
719
+ enable_admirals_army_professionalism = {
720
+ if = {
721
+ limit = { has_dlc = "Cradle of Civilization" }
722
+ custom_tooltip = admirals_give_army_professionalism_tt
723
+ }
724
+ hidden_effect = {
725
+ set_country_flag = admirals_give_army_professionalism
726
+ }
727
+ }
728
+
729
+ enable_improved_consecration = {
730
+ if = {
731
+ limit = {
732
+ has_dlc = "Third Rome"
733
+ religion = orthodox
734
+ }
735
+ custom_tooltip = enable_improved_consecration_tt
736
+ }
737
+ hidden_effect = {
738
+ set_country_flag = has_improved_consecration
739
+ every_owned_province = {
740
+ limit = {
741
+ has_state_patriach = yes
742
+ }
743
+ add_province_modifier = {
744
+ name = consecrated_ground
745
+ duration = -1
746
+ hidden = yes
747
+ }
748
+ }
749
+ }
750
+ }
751
+
752
+ #Check with "has_unlocked_decision = { type = <decisions id> }"
753
+ #Supports the following decisions
754
+ #################################
755
+ # grand_vizier_selection
756
+ # horse_breeding_decision
757
+ unlock_decision = {
758
+ custom_tooltip = unlock_decision_$type$_tt
759
+ hidden_effect = { set_country_flag = unlocked_decision_$type$ }
760
+ [[effect_tooltip]
761
+ custom_tooltip = unlock_decision_effect_tt
762
+ $effect_tooltip$
763
+ ]
764
+ [[custom_tooltip]custom_tooltip = $custom_tooltip$]
765
+ }
766
+ lock_decision = {
767
+ custom_tooltip = lock_decision_$type$_tt
768
+ hidden_effect = { clr_country_flag = unlocked_decision_$type$ }
769
+ }
770
+
771
+ #Supports the following holy orders
772
+ ###################################
773
+ # savafid_order
774
+ # zahediyeh_order
775
+ unlock_holy_order = {
776
+ if = {
777
+ limit = { has_dlc = "Golden Century" }
778
+ custom_tooltip = unlock_holy_order_$type$_tt
779
+ }
780
+ hidden_effect = { set_country_flag = unlocked_holy_order_$type$ }
781
+ }
782
+
783
+ #Supports the following arguments
784
+ #################################
785
+ # fabricate_spread_the_true_faith_cb
786
+ unlock_diplomatic_action = {
787
+ custom_tooltip = unlock_$type$_tt
788
+ hidden_effect = {
789
+ set_country_flag = unlocked_diplomatic_action_$type$
790
+ }
791
+ [[custom_tooltip]custom_tooltip = $custom_tooltip$]
792
+ }
793
+
794
+ enable_great_holy_war_cb = {
795
+ custom_tooltip = enable_great_holy_war_cb_tt
796
+ hidden_effect = { set_country_flag = enabled_great_holy_war_cb }
797
+ }
common/scripted_effects/03_scripted_effects_for_mission_rewards.txt ADDED
@@ -0,0 +1,2973 @@
1
+ #Tag specific reward for the dynamic effects
2
+ restore_greek_names = {
3
+ custom_tooltip = reestablishing_themes_names_tooltip
4
+ hidden_effect = {
5
+ 149 = { change_province_name = Adrianople rename_capital = Adrianople }
6
+ 151 = { change_province_name = Constantinople rename_capital = Constantinople }
7
+ 316 = { change_province_name = Optimatoi rename_capital = Nikomedeia }
8
+ 317 = { change_province_name = Opsikion rename_capital = Prussa }
9
+ 318 = { change_province_name = Smyrna rename_capital = Smyrna }
10
+ 319 = { change_province_name = Mylasa rename_capital = Mougla }
11
+ 322 = { change_province_name = Kotyaion rename_capital = Kotyaion }
12
+ 323 = { change_province_name = Ikonion rename_capital = Iconion }
13
+ 324 = { change_province_name = Laranda rename_capital = Laranda }
14
+ 325 = { change_province_name = Paphlagonia rename_capital = Timonio }
15
+ 326 = { change_province_name = Galatia rename_capital = Ancyra }
16
+ 327 = { change_province_name = Cilicia rename_capital = Atana }
17
+ 328 = { change_province_name = Sinope rename_capital = Sinop }
18
+ 329 = { change_province_name = Sebasteia rename_capital = Sebastopolis }
19
+ 330 = { change_province_name = Trebizond rename_capital = Trapezous }
20
+ 331 = { change_province_name = Theodosiopolis rename_capital = Theodosiopolis }
21
+ 1764 = { change_province_name = Mesambria rename_capital = Mesambria }
22
+ 1846 = { change_province_name = Armeniakon rename_capital = Amasea }
23
+ 1848 = { change_province_name = Baris rename_capital = Baris }
24
+ 2296 = { change_province_name = Abydos rename_capital = Pigai }
25
+ 2297 = { change_province_name = Thrakesion rename_capital = Magnesia }
26
+ 2298 = { change_province_name = Attalia rename_capital = Attalia }
27
+ 2299 = { change_province_name = Boukellarion rename_capital = Klaudiopol}
28
+ 2300 = { change_province_name = Cappadocia rename_capital = Tavium }
29
+ 2301 = { change_province_name = Charsianon rename_capital = Ceasarea }
30
+ 2302 = { change_province_name = Seleucia rename_capital = Kermarage }
31
+ 2304 = { change_province_name = Chaldia rename_capital = Amissos}
32
+ 2305 = { change_province_name = Acilisene rename_capital = Acilisene }
33
+ 2750 = { change_province_name = Philippopolis rename_capital = Philippopolis}
34
+ 4307 = { change_province_name = Colonia rename_capital = Colonia }
35
+ 4308 = { change_province_name = Laodicea rename_capital = Laodicea }
36
+ 4309 = { change_province_name = Tralles rename_capital = Tralles }
37
+ 4310 = { change_province_name = Tephrike rename_capital = Tephrike }
38
+ 4311 = { change_province_name = Anatolikon rename_capital = Polydorion }
39
+ 4312 = { change_province_name = Dorylaeum rename_capital = Dorylaeum }
40
+ 4313 = { change_province_name = Gangra rename_capital = Gangra }
41
+ 4314 = { change_province_name = Justinianopolis rename_capital = Justinianopolis }
42
+ 4315 = { change_province_name = Evdoksia rename_capital = Evdoksia }
43
+ }
44
+ }
45
+ #Country effect
46
+ mal_mansa_musa_visit_effect = {
47
+ trigger_switch = {
48
+ on_trigger = has_country_flag
49
+ mal_journey_to_maghreb = { every_country = { limit = { NOT = { tag = ROOT } NOT = { has_country_flag = mal_is_already_getting_visit } capital_scope = { region = maghreb_region } } add_country_modifier = { name = mal_the_gold_inflation duration = 1825 } } }
50
+ mal_journey_to_iberia = { every_country = { limit = { NOT = { tag = ROOT } NOT = { has_country_flag = mal_is_already_getting_visit } capital_scope = { region = iberia_region } } add_country_modifier = { name = mal_the_gold_inflation duration = 1825 } } }
51
+ mal_journey_to_france = { every_country = { limit = { NOT = { tag = ROOT } NOT = { has_country_flag = mal_is_already_getting_visit } capital_scope = { region = france_region } } add_country_modifier = { name = mal_the_gold_inflation duration = 1825 } } }
52
+ mal_journey_to_italy = { every_country = { limit = { NOT = { tag = ROOT } NOT = { has_country_flag = mal_is_already_getting_visit } capital_scope = { region = italy_region } } add_country_modifier = { name = mal_the_gold_inflation duration = 1825 } } }
53
+ mal_journey_to_south_germany = { every_country = { limit = { NOT = { tag = ROOT } NOT = { has_country_flag = mal_is_already_getting_visit } capital_scope = { region = south_german_region } } add_country_modifier = { name = mal_the_gold_inflation duration = 1825 } } }
54
+ mal_journey_to_balkans = { every_country = { limit = { NOT = { tag = ROOT } NOT = { has_country_flag = mal_is_already_getting_visit } capital_scope = { region = balkan_region } } add_country_modifier = { name = mal_the_gold_inflation duration = 1825 } } }
55
+ mal_journey_to_anatolia = { every_country = { limit = { NOT = { tag = ROOT } NOT = { has_country_flag = mal_is_already_getting_visit } capital_scope = { region = anatolia_region } } add_country_modifier = { name = mal_the_gold_inflation duration = 1825 } } }
56
+ mal_journey_to_mashriq = { every_country = { limit = { NOT = { tag = ROOT } NOT = { has_country_flag = mal_is_already_getting_visit } capital_scope = { region = mashriq_region } } add_country_modifier = { name = mal_the_gold_inflation duration = 1825 } } }
57
+ mal_journey_to_egypt = { every_country = { limit = { NOT = { tag = ROOT } NOT = { has_country_flag = mal_is_already_getting_visit } capital_scope = { region = egypt_region } } add_country_modifier = { name = mal_the_gold_inflation duration = 1825 } } }
58
+ mal_journey_to_arabia = { every_country = { limit = { NOT = { tag = ROOT } NOT = { has_country_flag = mal_is_already_getting_visit } capital_scope = { region = arabia_region } } add_country_modifier = { name = mal_the_gold_inflation duration = 1825 } } }
59
+ mal_journey_to_horn_of_africa = { every_country = { limit = { NOT = { tag = ROOT } NOT = { has_country_flag = mal_is_already_getting_visit } capital_scope = { region = horn_of_africa_region } } add_country_modifier = { name = mal_the_gold_inflation duration = 1825 } } }
60
+ }
61
+ }
62
+
63
+ #Country effect
64
+ mal_invest_in_own_provinces_effect = {
65
+ trigger_switch = {
66
+ on_trigger = has_country_flag
67
+ mal_journey_to_maghreb = { custom_tooltip = mal_invest_in_region_tt hidden_effect = { every_owned_province = { limit = { region = maghreb_region } } add_province_modifier = { name = mal_investing_in_own_provinces duration = 1825 }} }
68
+ mal_journey_to_iberia = { custom_tooltip = mal_invest_in_region_tt hidden_effect = { every_owned_province = { limit = { region = iberia_region } } add_province_modifier = { name = mal_investing_in_own_provinces duration = 1825 }} }
69
+ mal_journey_to_france = { custom_tooltip = mal_invest_in_region_tt hidden_effect = { every_owned_province = { limit = { region = france_region } } add_province_modifier = { name = mal_investing_in_own_provinces duration = 1825 }} }
70
+ mal_journey_to_italy = { custom_tooltip = mal_invest_in_region_tt hidden_effect = { every_owned_province = { limit = { region = italy_region } } add_province_modifier = { name = mal_investing_in_own_provinces duration = 1825 }} }
71
+ mal_journey_to_south_germany = { custom_tooltip = mal_invest_in_region_tt hidden_effect = { every_owned_province = { limit = { region = south_german_region } } add_province_modifier = { name = mal_investing_in_own_provinces duration = 1825 }} }
72
+ mal_journey_to_balkans = { custom_tooltip = mal_invest_in_region_tt hidden_effect = { every_owned_province = { limit = { region = balkan_region } } add_province_modifier = { name = mal_investing_in_own_provinces duration = 1825 }} }
73
+ mal_journey_to_anatolia = { custom_tooltip = mal_invest_in_region_tt hidden_effect = { every_owned_province = { limit = { region = anatolia_region } } add_province_modifier = { name = mal_investing_in_own_provinces duration = 1825 }} }
74
+ mal_journey_to_mashriq = { custom_tooltip = mal_invest_in_region_tt hidden_effect = { every_owned_province = { limit = { region = mashriq_region } } add_province_modifier = { name = mal_investing_in_own_provinces duration = 1825 }} }
75
+ mal_journey_to_egypt = { custom_tooltip = mal_invest_in_region_tt hidden_effect = { every_owned_province = { limit = { region = egypt_region } } add_province_modifier = { name = mal_investing_in_own_provinces duration = 1825 }} }
76
+ mal_journey_to_arabia = { custom_tooltip = mal_invest_in_region_tt hidden_effect = { every_owned_province = { limit = { region = arabia_region } } add_province_modifier = { name = mal_investing_in_own_provinces duration = 1825 }} }
77
+ mal_journey_to_horn_of_africa = { custom_tooltip = mal_invest_in_region_tt hidden_effect = { every_owned_province = { limit = { region = horn_of_africa_region } } add_province_modifier = { name = mal_investing_in_own_provinces duration = 1825 }} }
78
+ }
79
+ }
80
+
81
+ #Country effect
82
+ mal_travel_to_next_area = {
83
+ if = {
84
+ limit = { has_country_flag = mal_journey_to_maghreb }
85
+ clr_country_flag = mal_journey_to_maghreb
86
+ set_country_flag = mal_journey_to_iberia
87
+ }
88
+ else_if = {
89
+ limit = { has_country_flag = mal_journey_to_iberia }
90
+ clr_country_flag = mal_journey_to_iberia
91
+ set_country_flag = mal_journey_to_france
92
+ }
93
+ else_if = {
94
+ limit = { has_country_flag = mal_journey_to_france }
95
+ clr_country_flag = mal_journey_to_france
96
+ set_country_flag = mal_journey_to_italy
97
+ }
98
+ else_if = {
99
+ limit = { has_country_flag = mal_journey_to_italy }
100
+ clr_country_flag = mal_journey_to_italy
101
+ set_country_flag = mal_journey_to_south_germany
102
+ }
103
+ else_if = {
104
+ limit = { has_country_flag = mal_journey_to_south_germany }
105
+ clr_country_flag = mal_journey_to_south_germany
106
+ set_country_flag = mal_journey_to_balkans
107
+ }
108
+ else_if = {
109
+ limit = { has_country_flag = mal_journey_to_balkans }
110
+ clr_country_flag = mal_journey_to_balkans
111
+ set_country_flag = mal_journey_to_anatolia
112
+ }
113
+ else_if = {
114
+ limit = { has_country_flag = mal_journey_to_anatolia }
115
+ clr_country_flag = mal_journey_to_anatolia
116
+ set_country_flag = mal_journey_to_mashriq
117
+ }
118
+ else_if = {
119
+ limit = { has_country_flag = mal_journey_to_mashriq }
120
+ clr_country_flag = mal_journey_to_mashriq
121
+ set_country_flag = mal_journey_to_egypt
122
+ }
123
+ else_if = {
124
+ limit = { has_country_flag = mal_journey_to_egypt }
125
+ clr_country_flag = mal_journey_to_egypt
126
+ set_country_flag = mal_journey_to_arabia
127
+ }
128
+ else_if = {
129
+ limit = { has_country_flag = mal_journey_to_arabia }
130
+ clr_country_flag = mal_journey_to_arabia
131
+ set_country_flag = mal_journey_to_horn_of_africa
132
+ }
133
+ else_if = {
134
+ limit = { has_country_flag = mal_journey_to_horn_of_africa }
135
+ clr_country_flag = mal_journey_to_horn_of_africa
136
+ set_country_flag = mal_journey_to_home
137
+ }
138
+ clr_country_flag = mal_has_just_arrived
139
+ clr_country_flag = mal_visit_foreign_capital
140
+ }
141
+
142
+ #Country effect
143
+ mal_select_country_for_region = {
144
+ trigger_switch = {
145
+ on_trigger = has_country_flag
146
+ mal_journey_to_maghreb = { maghreb_region = { discover_country = ROOT } select_biggest_country_of_region = { region = maghreb_region } }
147
+ mal_journey_to_iberia = { iberia_region = { discover_country = ROOT } select_biggest_country_of_region = { region = iberia_region } }
148
+ mal_journey_to_france = { france_region = { discover_country = ROOT } select_biggest_country_of_region = { region = france_region } }
149
+ mal_journey_to_italy = { italy_region = { discover_country = ROOT } select_biggest_country_of_region = { region = italy_region } }
150
+ mal_journey_to_south_germany = { south_german_region = { discover_country = ROOT } select_biggest_country_of_region = { region = south_german_region } }
151
+ mal_journey_to_balkans = { balkan_region = { discover_country = ROOT } select_biggest_country_of_region = { region = balkan_region } }
152
+ mal_journey_to_anatolia = { anatolia_region = { discover_country = ROOT } select_biggest_country_of_region = { region = anatolia_region } }
153
+ mal_journey_to_mashriq = { mashriq_region = { discover_country = ROOT } select_biggest_country_of_region = { region = mashriq_region } }
154
+ mal_journey_to_egypt = { egypt_region = { discover_country = ROOT } select_biggest_country_of_region = { region = egypt_region } }
155
+ mal_journey_to_arabia = { arabia_region = { discover_country = ROOT } select_biggest_country_of_region = { region = arabia_region } }
156
+ mal_journey_to_horn_of_africa = { horn_of_africa_region = { discover_country = ROOT } select_biggest_country_of_region = { region = horn_of_africa_region } }
157
+ }
158
+ }
159
+
160
+ show_points_needed_for_livionian_government_of_category = {
161
+ [[adm]
162
+ if = {
163
+ limit = { NOT = { check_variable = { which = liv_adm value = 5 } } }
164
+ custom_tooltip = livonian_administrative_monarchy_points_needed_tt
165
+ }
166
+ if = {
167
+ limit = { NOT = { check_variable = { which = liv_adm value = 4 } } }
168
+ custom_tooltip = livonian_absolute_monarchy_points_needed_tt
169
+ }
170
+ if = {
171
+ limit = { NOT = { check_variable = { which = liv_adm value = 3 } } }
172
+ custom_tooltip = livonian_trade_monarchy_points_needed_tt
173
+ }
174
+ if = {
175
+ limit = { NOT = { check_variable = { which = liv_adm value = 3 } } }
176
+ custom_tooltip = livonian_constitutional_monarchy_points_needed_tt
177
+ }
178
+ if = {
179
+ limit = { NOT = { check_variable = { which = liv_adm value = 3 } } }
180
+ custom_tooltip = livonian_theocratic_monarchy_points_needed_tt
181
+ }
182
+ if = {
183
+ limit = { NOT = { check_variable = { which = liv_adm value = 2 } } }
184
+ custom_tooltip = livonian_enlightened_monarchy_points_needed_tt
185
+ }
186
+ ]
187
+ [[dip]
188
+ if = {
189
+ limit = { NOT = { check_variable = { which = liv_dip value = 5 } } }
190
+ custom_tooltip = livonian_naval_monarchy_points_needed_tt
191
+ }
192
+ if = {
193
+ limit = { NOT = { check_variable = { which = liv_dip value = 4 } } }
194
+ custom_tooltip = livonian_diplomatic_monarchy_points_needed_tt
195
+ }
196
+ if = {
197
+ limit = { NOT = { check_variable = { which = liv_dip value = 4 } } }
198
+ custom_tooltip = livonian_admiral_monarchy_points_needed_tt
199
+ }
200
+ if = {
201
+ limit = { NOT = { check_variable = { which = liv_dip value = 3 } } }
202
+ custom_tooltip = livonian_trade_monarchy_points_needed_tt
203
+ }
204
+ if = {
205
+ limit = { NOT = { check_variable = { which = liv_dip value = 3 } } }
206
+ custom_tooltip = livonian_elective_monarchy_points_needed_tt
207
+ }
208
+ if = {
209
+ limit = { NOT = { check_variable = { which = liv_dip value = 3 } } }
210
+ custom_tooltip = livonian_naval_controlled_monarchy_points_needed_tt
211
+ }
212
+ if = {
213
+ limit = { NOT = { check_variable = { which = liv_dip value = 2 } } }
214
+ custom_tooltip = livonian_enlightened_monarchy_points_needed_tt
215
+ }
216
+ ]
217
+ [[mil]
218
+ if = {
219
+ limit = { NOT = { check_variable = { which = liv_mil value = 5 } } }
220
+ custom_tooltip = livonian_military_monarchy_points_needed_tt
221
+ }
222
+ if = {
223
+ limit = { NOT = { check_variable = { which = liv_mil value = 4 } } }
224
+ custom_tooltip = livonian_general_controlled_monarchy_points_needed_tt
225
+ }
226
+ if = {
227
+ limit = { NOT = { check_variable = { which = liv_mil value = 3 } } }
228
+ custom_tooltip = livonian_theocratic_monarchy_points_needed_tt
229
+ }
230
+ if = {
231
+ limit = { NOT = { check_variable = { which = liv_mil value = 3 } } }
232
+ custom_tooltip = livonian_mercenary_monarchy_points_needed_tt
233
+ }
234
+ if = {
235
+ limit = { NOT = { check_variable = { which = liv_mil value = 3 } } }
236
+ custom_tooltip = livonian_naval_controlled_monarchy_points_needed_tt
237
+ }
238
+ if = {
239
+ limit = { NOT = { check_variable = { which = liv_mil value = 2 } } }
240
+ custom_tooltip = livonian_enlightened_monarchy_points_needed_tt
241
+ }
242
+ ]
243
+ }
244
+
245
+ #Ottoman Mission Rewards
246
+ tur_crimean_khaganate_effect_a = {
247
+ CRI = {
248
+ add_historical_friend = ROOT
249
+ if = {
250
+ limit = {
251
+ is_subject_of_type = tributary_state
252
+ }
253
+ tooltip = {
254
+ ROOT = {
255
+ create_subject = {
256
+ subject_type = march
257
+ who = PREV
258
+ }
259
+ }
260
+ }
261
+ }
262
+ hidden_effect = {
263
+ if = {
264
+ limit = { is_subject_of_type = tributary_state }
265
+ grant_independence = yes
266
+ ROOT = {
267
+ create_subject = {
268
+ subject_type = march
269
+ who = PREV
270
+ }
271
+ }
272
+ }
273
+ }
274
+ }
275
+ add_historical_friend = CRI
276
+ add_country_modifier = {
277
+ name = tur_tatar_vanguard_modifier
278
+ duration = -1
279
+ desc = as_long_as_they_are_subject_desc
280
+ }
281
+ }
282
+
283
+ tur_address_firman_effect_a = {
284
+ hidden_effect = {
285
+ if = {
286
+ limit = {
287
+ GRA = {
288
+ OR = {
289
+ is_subject_of = ROOT
290
+ alliance_with = ROOT
291
+ }
292
+ }
293
+ }
294
+ GRA = { save_event_target_as = tur_andalusian_ally }
295
+ }
296
+ else_if = {
297
+ limit = {
298
+ ADU = {
299
+ OR = {
300
+ is_subject_of = ROOT
301
+ alliance_with = ROOT
302
+ }
303
+ }
304
+ }
305
+ ADU = { save_event_target_as = tur_andalusian_ally }
306
+ }
307
+ if = {
308
+ limit = { has_saved_event_target = tur_andalusian_ally }
309
+ add_historical_friend = event_target:tur_andalusian_ally
310
+ event_target:tur_andalusian_ally = {
311
+ add_historical_friend = ROOT
312
+ add_country_modifier = {
313
+ name = tur_turkish_andalusian_relations_gra
314
+ duration = -1
315
+ hidden = yes
316
+ }
317
+ add_accepted_culture = turkish
318
+ if = {
319
+ limit = { NOT = { tag = ADU } }
320
+ ADU = { add_historical_friend = ROOT }
321
+ ROOT = { add_historical_friend = ADU }
322
+ }
323
+ random_province = {
324
+ limit = { owned_by = event_target:tur_andalusian_ally is_capital = no has_port = yes culture = event_target:tur_andalusian }
325
+ add_base_tax = 2
326
+ add_base_production = 2
327
+ add_base_manpower = 2
328
+ change_religion = ROOT
329
+ change_culture = turkish
330
+ }
331
+ for = {
332
+ amount = 3
333
+ effect = "random_owned_province = { add_base_tax = 1 }"
334
+ }
335
+ for = {
336
+ amount = 3
337
+ effect = "random_owned_province = { add_base_production = 1 }"
338
+ }
339
+ for = {
340
+ amount = 3
341
+ effect = "random_owned_province = { add_base_manpower = 1 }"
342
+ }
343
+ }
344
+ add_country_modifier = {
345
+ name = tur_turkish_andalusian_relations_tur
346
+ duration = -1
347
+ hidden = yes
348
+ }
349
+ add_accepted_culture = andalucian
350
+ random_province = {
351
+ limit = { owned_by = ROOT is_capital = no culture = event_target:tur_andalusian_ally has_port = yes }
352
+ add_base_tax = 2
353
+ add_base_production = 2
354
+ add_base_manpower = 2
355
+ change_religion = event_target:tur_andalusian_ally
356
+ change_culture = andalucian
357
+ }
358
+ #for = {
359
+ # amount = 4
360
+ # effect = "random_owned_province = { random_list = { 1 = { add_base_tax = 2 } 1 = { add_base_production = 2 } 1 = { add_base_manpower = 2 } } }"
361
+ #}
362
+ random_owned_province = { random_list = { 1 = { add_base_tax = 2 } 1 = { add_base_production = 2 } 1 = { add_base_manpower = 2 } } }
363
+ random_owned_province = { random_list = { 1 = { add_base_tax = 2 } 1 = { add_base_production = 2 } 1 = { add_base_manpower = 2 } } }
364
+ random_owned_province = { random_list = { 1 = { add_base_tax = 2 } 1 = { add_base_production = 2 } 1 = { add_base_manpower = 2 } } }
365
+ random_owned_province = { random_list = { 1 = { add_base_tax = 2 } 1 = { add_base_production = 2 } 1 = { add_base_manpower = 2 } } }
366
+ random_owned_province = { random_list = { 1 = { add_base_tax = 2 } 1 = { add_base_production = 2 } 1 = { add_base_manpower = 2 } } }
367
+ }
368
+ }
369
+ }
370
+
371
+ tur_address_firman_effect_b = {
372
+ country_event_with_insight = {
373
+ id = flavor_tur.219
374
+ insight_tooltip = INSIGHT_JUST_TOOLTIP
375
+ effect_tooltip = "
376
+ thrace_area = {
377
+ limit = {
378
+ country_or_non_sovereign_subject_holds = ROOT
379
+ }
380
+ add_province_modifier = {
381
+ name = tur_morisco_refugees_modifier
382
+ duration = 7300
383
+ }
384
+ }
385
+ define_advisor = {
386
+ type = artist
387
+ cost_multiplier = 0.5
388
+ culture = andalucian
389
+ religion = sunni
390
+ }
391
+ "
392
+ }
393
+ }
394
+
395
+ tur_al_andalus_eyalet_effect_a = {
396
+ add_country_modifier = {
397
+ name = tur_re_reconquista
398
+ duration = -1
399
+ }
400
+ custom_tooltip = tur_al_andalus_eyalet_bt
401
+ hidden_effect = {
402
+ if = {
403
+ limit = {
404
+ any_subject_country = {
405
+ religion = ROOT
406
+ owns = 225
407
+ owns = 223
408
+ owns = 226
409
+ owns = 224
410
+ num_of_owned_provinces_with = {
411
+ region = iberia_region
412
+ value = 10
413
+ }
414
+ capital_scope = {
415
+ region = iberia_region
416
+ }
417
+ }
418
+ }
419
+ random_subject_country = {
420
+ limit = {
421
+ religion = ROOT
422
+ owns = 225
423
+ owns = 223
424
+ owns = 226
425
+ owns = 224
426
+ num_of_owned_provinces_with = {
427
+ region = iberia_region
428
+ value = 10
429
+ }
430
+ capital_scope = {
431
+ region = iberia_region
432
+ }
433
+ }
434
+ add_country_modifier = {
435
+ name = tur_re_reconquista
436
+ duration = -1
437
+ }
438
+ }
439
+ }
440
+ if = {
441
+ limit = {
442
+ any_ally = {
443
+ religion = ROOT
444
+ owns = 225
445
+ owns = 223
446
+ owns = 226
447
+ owns = 224
448
+ num_of_owned_provinces_with = {
449
+ region = iberia_region
450
+ value = 10
451
+ }
452
+ capital_scope = {
453
+ region = iberia_region
454
+ }
455
+ }
456
+ }
457
+ random_ally = {
458
+ limit = {
459
+ religion = ROOT
460
+ owns = 225
461
+ owns = 223
462
+ owns = 226
463
+ owns = 224
464
+ num_of_owned_provinces_with = {
465
+ region = iberia_region
466
+ value = 10
467
+ }
468
+ capital_scope = {
469
+ region = iberia_region
470
+ }
471
+ }
472
+ add_country_modifier = {
473
+ name = tur_re_reconquista
474
+ duration = -1
475
+ }
476
+ }
477
+ }
478
+ }
479
+ }
480
+
481
+ #British Mission Rewards
482
+ gbr_take_over_the_lowlands_effect_a = {
483
+ add_country_modifier = {
484
+ name = gbr_english_dutch_trade_partners
485
+ duration = -1
486
+ desc = UNTIL_ALLIANCE_BREAK
487
+ }
488
+ hidden_effect = {
489
+ random_ally = {
490
+ limit = {
491
+ capital_scope = {
492
+ region = low_countries_region
493
+ }
494
+ OR = {
495
+ primary_culture = dutch
496
+ primary_culture = flemish
497
+ primary_culture = frisian
498
+ primary_culture = wallonian
499
+ }
500
+ num_of_owned_provinces_with = {
501
+ region = low_countries_region
502
+ value = 15
503
+ }
504
+ }
505
+ add_historical_friend = ROOT
506
+ ROOT = { add_historical_friend = ROOT }
507
+ add_country_modifier = {
508
+ name = gbr_english_dutch_trade_partners
509
+ duration = -1
510
+ }
511
+ }
512
+ }
513
+ }
514
+
515
+ #Persian missions
516
+ per_claim_constantinople_effect = {
517
+ 151 = {
518
+ if = {
519
+ limit = { root = { has_country_flag = per_zoroastrian_missions } }
520
+ change_province_name = "Kustantiniya"
521
+ rename_capital = "Kustantiniya"
522
+ }
523
+ else = {
524
+ change_province_name = "Konstantiniyyeh"
525
+ rename_capital = "Konstantiniyyeh"
526
+ }
527
+ add_base_tax = 2
528
+ add_base_production = 2
529
+ add_base_manpower = 1
530
+ add_province_modifier = {
531
+ name = per_the_second_capital
532
+ duration = -1
533
+ }
534
+ }
535
+ }
536
+ per_invade_india_effect = {
537
+ add_adm_power = 75
538
+ add_permanent_claim_multi_provinces = { target = northern_sindh_area }
539
+ add_permanent_claim_multi_provinces = { target = sindh_area }
540
+ add_permanent_claim_multi_provinces = { target = jangladesh_area }
541
+ add_permanent_claim_multi_provinces = { target = marwar_area }
542
+ add_permanent_claim_multi_provinces = { target = patan_area }
543
+ add_permanent_claim_multi_provinces = { target = saurashtra_area }
544
+ add_permanent_claim_multi_provinces = { target = jaipur_area }
545
+ }
546
+
547
+
548
+ BYZ_convert_to_greek_culture = { #It's here in case I want to add anatolian-themed cultures.
549
+ if = {
550
+ limit = {
551
+ OR = {
552
+ area = erzurum_area
553
+ area = kastamonu_area
554
+ }
555
+ }
556
+ change_culture = pontic_greek
557
+ }
558
+ else_if = {
559
+ limit = {
560
+ area = karaman_area
561
+ }
562
+ change_culture = cappadocian_greek
563
+ }
564
+ else = {
565
+ change_culture = greek
566
+ }
567
+ }
568
+
569
+ BYZ_upgrade_hexamilion_if_possible = {
570
+ clr_country_flag = BYZ_upgrading_hexamilion
571
+
572
+ 4701 = {
573
+ if = {
574
+ limit = {
575
+ owned_by = ROOT
576
+ }
577
+ if = {
578
+ limit = {
579
+ has_province_modifier = BYZ_hexamilion_wall_2
580
+ }
581
+ #nothing should happen. should not be achievable
582
+ }
583
+ else_if = {
584
+ limit = {
585
+ has_province_modifier = BYZ_hexamilion_wall_1
586
+ }
587
+ remove_province_modifier = BYZ_hexamilion_wall_1
588
+ add_province_modifier = {
589
+ name = BYZ_hexamilion_wall_2
590
+ duration = -1
591
+ }
592
+ }
593
+ else = {
594
+ add_province_modifier = {
595
+ name = BYZ_hexamilion_wall_1
596
+ duration = -1
597
+ }
598
+ }
599
+ }
600
+ }
601
+ }
602
+
603
+ BYZ_upgrade_theodosian_if_possible = {
604
+ clr_country_flag = BYZ_upgrading_theodosian
605
+
606
+ 151 = {
607
+ if = {
608
+ limit = {
609
+ owned_by = ROOT
610
+ }
611
+ if = {
612
+ limit = {
613
+ has_province_modifier = BYZ_theodosian_wall_3
614
+ }
615
+ #nothing should happen. should not be achievable
616
+ }
617
+ else_if = {
618
+ limit = {
619
+ has_province_modifier = BYZ_theodosian_wall_2
620
+ }
621
+ remove_province_modifier = BYZ_theodosian_wall_2
622
+ add_province_modifier = {
623
+ name = BYZ_theodosian_wall_3
624
+ duration = -1
625
+ }
626
+ }
627
+ else_if = {
628
+ limit = {
629
+ has_province_modifier = BYZ_theodosian_wall_1
630
+ }
631
+ remove_province_modifier = BYZ_theodosian_wall_1
632
+ add_province_modifier = {
633
+ name = BYZ_theodosian_wall_2
634
+ duration = -1
635
+ }
636
+ }
637
+ else = {
638
+ add_province_modifier = {
639
+ name = BYZ_theodosian_wall_1
640
+ duration = -1
641
+ }
642
+ }
643
+ }
644
+ }
645
+ }
646
+
647
+ BYZ_branch_effect = {
648
+ custom_tooltip = BYZ_this_is_a_branching_mission
649
+ }
650
+
651
+ BYZ_if_saved_export_variable = {
652
+ if = {
653
+ limit = {
654
+ has_saved_event_target = $name$
655
+ }
656
+ event_target:$name$ = {
657
+ export_to_variable = {
658
+ variable_name = byz_yearly_income
659
+ value = years_of_income
660
+ }
661
+ }
662
+ }
663
+ }
664
+
665
+ BYZ_offer_mosaicists = {
666
+ custom_tooltip = BYZ_we_will_offer_to_this_for
667
+
668
+ tooltip = {
669
+ if = {
670
+ limit = {
671
+ has_dlc = "Leviathan"
672
+ }
673
+ add_country_modifier = {
674
+ name = BYZ_mosaicists_Leviathan
675
+ duration = 3650
676
+ }
677
+ }
678
+ else = {
679
+ add_country_modifier = {
680
+ name = BYZ_mosaicists
681
+ duration = 3650
682
+ }
683
+ }
684
+ }
685
+
686
+ custom_tooltip = BYZ_if_they_deny_we_will_still_get_modifier
687
+
688
+ hidden_effect = {
689
+ country_event = { id = MEE_Byzantine_Events.25 }
690
+ }
691
+ }
692
+
693
+ ARB_flavor_event_6_effect = {
694
+
695
+ add_permanent_power_projection = {
696
+ type = arb_permanent_power_projection
697
+ amount = 10
698
+ }
699
+
700
+ custom_tooltip = " "
701
+
702
+ if = {
703
+ limit = {
704
+ has_dlc = "Mandate of Heaven"
705
+ }
706
+ custom_tooltip = ARB_golden_age_renewal_tt
707
+ hidden_effect = {
708
+ if = {
709
+ limit = { has_had_golden_age = yes }
710
+ reset_golden_age = yes
711
+ }
712
+ else_if = {
713
+ limit = { in_golden_age = yes }
714
+ extend_golden_age = 600
715
+ }
716
+ }
717
+ custom_tooltip = " "
718
+ }
719
+ else = {
720
+ add_country_modifier = {
721
+ name = ARB_second_islamic_golden_age_modifier
722
+ duration = 18250
723
+ }
724
+ }
725
+
726
+ custom_tooltip = ARB_permanent_claims_on_all_muslim_provinces
727
+
728
+ custom_tooltip = " "
729
+
730
+ if = {
731
+ limit = {
732
+ has_country_modifier = unified_islam
733
+ }
734
+ add_country_modifier = {
735
+ name = ARB_united_islam_upgraded
736
+ duration = -1
737
+ }
738
+ }
739
+ else = {
740
+ set_country_flag = ARB_upgraded_uniting_islam
741
+ custom_tooltip = ARB_uniting_islam_will_now_give_10_warscore_cost_vs_other_religions
742
+ }
743
+ }
744
+
745
+ add_persian_and_zoroastrian_influence = {
746
+ if = {
747
+ limit = { has_government_mechanic = persian_influence_mechanic }
748
+ add_government_power = {
749
+ mechanic_type = persian_influence_mechanic
750
+ power_type = persian_influence
751
+ value = $value$
752
+ }
753
+ }
754
+ if = {
755
+ limit = { has_government_mechanic = the_three_royal_fires_mechanic }
756
+ add_government_power = {
757
+ mechanic_type = the_three_royal_fires_mechanic
758
+ power_type = asha_vahishta
759
+ value = $value$
760
+ }
761
+ }
762
+ }
763
+
764
+ feo_create_general_diplomatic_action_effect = {
765
+ if = {
766
+ limit = {
767
+ check_variable = {
768
+ which = ArmyTradtionOfFROM
769
+ value = 0
770
+ }
771
+ NOT = {
772
+ check_variable = {
773
+ which = ArmyTradtionOfFROM
774
+ value = 20
775
+ }
776
+ }
777
+ }
778
+ create_general = { tradition = 10 }
779
+ }
780
+ if = {
781
+ limit = {
782
+ check_variable = {
783
+ which = ArmyTradtionOfFROM
784
+ value = 20
785
+ }
786
+ NOT = {
787
+ check_variable = {
788
+ which = ArmyTradtionOfFROM
789
+ value = 30
790
+ }
791
+ }
792
+ }
793
+ create_general = { tradition = 20 }
794
+ }
795
+ if = {
796
+ limit = {
797
+ check_variable = {
798
+ which = ArmyTradtionOfFROM
799
+ value = 30
800
+ }
801
+ NOT = {
802
+ check_variable = {
803
+ which = ArmyTradtionOfFROM
804
+ value = 40
805
+ }
806
+ }
807
+ }
808
+ create_general = { tradition = 30 }
809
+ }
810
+ if = {
811
+ limit = {
812
+ check_variable = {
813
+ which = ArmyTradtionOfFROM
814
+ value = 40
815
+ }
816
+ NOT = {
817
+ check_variable = {
818
+ which = ArmyTradtionOfFROM
819
+ value = 50
820
+ }
821
+ }
822
+ }
823
+ create_general = { tradition = 40 }
824
+ }
825
+ if = {
826
+ limit = {
827
+ check_variable = {
828
+ which = ArmyTradtionOfFROM
829
+ value = 50
830
+ }
831
+ NOT = {
832
+ check_variable = {
833
+ which = ArmyTradtionOfFROM
834
+ value = 60
835
+ }
836
+ }
837
+ }
838
+ create_general = { tradition = 50 }
839
+ }
840
+ if = {
841
+ limit = {
842
+ check_variable = {
843
+ which = ArmyTradtionOfFROM
844
+ value = 60
845
+ }
846
+ NOT = {
847
+ check_variable = {
848
+ which = ArmyTradtionOfFROM
849
+ value = 70
850
+ }
851
+ }
852
+ }
853
+ create_general = { tradition = 60 }
854
+ }
855
+ if = {
856
+ limit = {
857
+ check_variable = {
858
+ which = ArmyTradtionOfFROM
859
+ value = 70
860
+ }
861
+ NOT = {
862
+ check_variable = {
863
+ which = ArmyTradtionOfFROM
864
+ value = 80
865
+ }
866
+ }
867
+ }
868
+ create_general = { tradition = 70 }
869
+ }
870
+ if = {
871
+ limit = {
872
+ check_variable = {
873
+ which = ArmyTradtionOfFROM
874
+ value = 80
875
+ }
876
+ NOT = {
877
+ check_variable = {
878
+ which = ArmyTradtionOfFROM
879
+ value = 90
880
+ }
881
+ }
882
+ }
883
+ create_general = { tradition = 80 }
884
+ }
885
+ if = {
886
+ limit = {
887
+ check_variable = {
888
+ which = ArmyTradtionOfFROM
889
+ value = 90
890
+ }
891
+ NOT = {
892
+ check_variable = {
893
+ which = ArmyTradtionOfFROM
894
+ value = 100
895
+ }
896
+ }
897
+ }
898
+ create_general = { tradition = 90 }
899
+ }
900
+ if = {
901
+ limit = {
902
+ check_variable = {
903
+ which = ArmyTradtionOfFROM
904
+ value = 100
905
+ }
906
+ NOT = {
907
+ check_variable = {
908
+ which = ArmyTradtionOfFROM
909
+ value = 110
910
+ }
911
+ }
912
+ }
913
+ create_general = { tradition = 100 }
914
+ }
915
+ }
916
+
917
+ feo_aegean_supremacy_aegean_islands_reward = {
918
+ 4700 = {
919
+ add_province_modifier = {
920
+ name = feo_aegean_trading_outpost
921
+ duration = -1
922
+ }
923
+ }
924
+ 2348 = {
925
+ add_province_modifier = {
926
+ name = feo_aegean_trading_outpost
927
+ duration = -1
928
+ }
929
+ }
930
+ 164 = {
931
+ add_province_modifier = {
932
+ name = feo_aegean_trading_outpost
933
+ duration = -1
934
+ }
935
+ }
936
+ 3003 = {
937
+ add_province_modifier = {
938
+ name = feo_aegean_trading_outpost
939
+ duration = -1
940
+ }
941
+ }
942
+ 320 = {
943
+ add_province_modifier = {
944
+ name = feo_aegean_trading_outpost
945
+ duration = -1
946
+ }
947
+ }
948
+ 163 = {
949
+ add_province_modifier = {
950
+ name = feo_aegean_trading_outpost
951
+ duration = -1
952
+ }
953
+ }
954
+ }
955
+
956
+ feo_aegean_supremacy_coastal_fortifications_reward = {
957
+ every_owned_province = {
958
+ limit = {
959
+ OR = {
960
+ province_id = 4705
961
+ province_id = 148
962
+ province_id = 147
963
+ province_id = 146
964
+ province_id = 3003
965
+ province_id = 4701
966
+ province_id = 145
967
+ province_id = 164
968
+ }
969
+ development = 15
970
+ has_coast_defense_building_trigger = yes
971
+ }
972
+ add_or_upgrade_naval_defense_building = yes
973
+ }
974
+ every_owned_province = {
975
+ limit = {
976
+ OR = {
977
+ province_id = 4705
978
+ province_id = 148
979
+ province_id = 147
980
+ province_id = 146
981
+ province_id = 3003
982
+ province_id = 4701
983
+ province_id = 145
984
+ province_id = 164
985
+ }
986
+ }
987
+ add_province_modifier = {
988
+ name = feo_aegean_slave_raid_block
989
+ duration = -1
990
+ hidden = yes
991
+ }
992
+ }
993
+ }
994
+
995
+
996
+ feo_conflicts_in_lithuania_event_opt_1 = {
997
+ random_owned_province = {
998
+ limit = {
999
+ region = ruthenia_region
1000
+ }
1001
+ change_culture = crimean
1002
+ }
1003
+ random_owned_province = {
1004
+ limit = {
1005
+ region = ruthenia_region
1006
+ }
1007
+ change_culture = crimean
1008
+ }
1009
+ random_owned_province = {
1010
+ limit = {
1011
+ region = ruthenia_region
1012
+ }
1013
+ change_culture = crimean
1014
+ }
1015
+ random_owned_province = {
1016
+ limit = {
1017
+ region = ruthenia_region
1018
+ }
1019
+ change_culture = crimean
1020
+ }
1021
+ if = {
1022
+ limit = {
1023
+ has_dlc = "The Cossacks"
1024
+ }
1025
+ add_estate_loyalty_modifier = {
1026
+ estate = estate_cossacks
1027
+ desc = EST_COSSACK_GRANTED_RUTHENIAN_LAND
1028
+ loyalty = 10
1029
+ duration = -1
1030
+ }
1031
+ custom_tooltip = FEO_MODIFY_COSSACK_SELF_GOVERNANCE_IN_RUTHENIA
1032
+ set_country_flag = feo_cossack_self_governance_ruthenia_buff
1033
+ hidden_effect = {
1034
+ if = {
1035
+ limit = {
1036
+ has_estate_privilege = estate_cossacks_cossack_self_governance
1037
+ }
1038
+ every_owned_province = {
1039
+ limit = {
1040
+ region = ruthenia_region
1041
+ }
1042
+ add_province_modifier = {
1043
+ name = feo_cossack_self_governance_ruthenia
1044
+ duration = -1
1045
+ }
1046
+ }
1047
+ }
1048
+ }
1049
+ }
1050
+ else = {
1051
+ custom_tooltip = FEO_ALL_RUTHENIAN_PROVINCES_GAIN_PERMANENT_MODIFIER
1052
+ custom_tooltip = " "
1053
+ add_country_modifier = {
1054
+ name = feo_plains_of_ruthenia
1055
+ duration = 7300
1056
+ }
1057
+ hidden_effect = {
1058
+ every_owned_province = {
1059
+ limit = {
1060
+ region = ruthenia_region
1061
+ culture_group = tartar
1062
+ }
1063
+ add_province_modifier = {
1064
+ name = feo_tatar_population
1065
+ duration = -1
1066
+ }
1067
+ }
1068
+ }
1069
+ }
1070
+ }
1071
+
1072
+ feo_conflicts_in_lithuania_event_opt_2 = {
1073
+
1074
+ custom_tooltip = FEO_DISTRIBUTED_ONLY_IN_RUTHENIA
1075
+ hidden_effect = {
1076
+ random_owned_province = {
1077
+ limit = { region = ruthenia_region }
1078
+ add_base_manpower = 1
1079
+ }
1080
+ random_owned_province = {
1081
+ limit = { region = ruthenia_region }
1082
+ add_base_manpower = 1
1083
+ }
1084
+ random_owned_province = {
1085
+ limit = { region = ruthenia_region }
1086
+ add_base_manpower = 1
1087
+ }
1088
+ random_owned_province = {
1089
+ limit = { region = ruthenia_region }
1090
+ add_base_manpower = 1
1091
+ }
1092
+ random_owned_province = {
1093
+ limit = { region = ruthenia_region }
1094
+ add_base_manpower = 1
1095
+ }
1096
+ random_owned_province = {
1097
+ limit = { region = ruthenia_region }
1098
+ add_base_manpower = 1
1099
+ }
1100
+ random_owned_province = {
1101
+ limit = { region = ruthenia_region }
1102
+ add_base_manpower = 1
1103
+ }
1104
+ random_owned_province = {
1105
+ limit = { region = ruthenia_region }
1106
+ add_base_manpower = 1
1107
+ }
1108
+ random_owned_province = {
1109
+ limit = { region = ruthenia_region }
1110
+ add_base_manpower = 1
1111
+ }
1112
+ random_owned_province = {
1113
+ limit = { region = ruthenia_region }
1114
+ add_base_manpower = 1
1115
+ }
1116
+ }
1117
+ custom_tooltip = FEO_4_RANDOM_RUTHENIAN_PROVINCES_GAIN_MANU
1118
+ hidden_effect = {
1119
+ random_owned_province = {
1120
+ limit = {
1121
+ region = ruthenia_region
1122
+ NOT = {
1123
+ has_manufactory_trigger = yes
1124
+ }
1125
+ }
1126
+ add_manufactory = yes
1127
+ }
1128
+ random_owned_province = {
1129
+ limit = {
1130
+ region = ruthenia_region
1131
+ NOT = {
1132
+ has_manufactory_trigger = yes
1133
+ }
1134
+ }
1135
+ add_manufactory = yes
1136
+ }
1137
+ random_owned_province = {
1138
+ limit = {
1139
+ region = ruthenia_region
1140
+ NOT = {
1141
+ has_manufactory_trigger = yes
1142
+ }
1143
+ }
1144
+ add_manufactory = yes
1145
+ }
1146
+ random_owned_province = {
1147
+ limit = {
1148
+ region = ruthenia_region
1149
+ NOT = {
1150
+ has_manufactory_trigger = yes
1151
+ }
1152
+ }
1153
+ add_manufactory = yes
1154
+ }
1155
+ }
1156
+ }
1157
+
1158
+ feo_integrate_cossacks_event_opt_1 = {
1159
+ if = {
1160
+ limit = {
1161
+ has_dlc = "The Cossacks"
1162
+ }
1163
+ set_country_flag = feo_expand_cossack_regiments_buff_flag
1164
+ custom_tooltip = FEO_GRANT_COSSACK_FL_FOR_EXPAND_COSSACK_REGIMENTS
1165
+ custom_tooltip = " "
1166
+ add_country_modifier = {
1167
+ name = feo_elite_tatar_vanguard
1168
+ duration = -1
1169
+ }
1170
+ }
1171
+ else = {
1172
+ unlock_merc_company = {
1173
+ merc_company = merc_tatar_vanguard
1174
+ free_merc = yes
1175
+ }
1176
+ }
1177
+ }
1178
+
1179
+ feo_integrate_cossacks_event_opt_2 = {
1180
+ if = {
1181
+ limit = {
1182
+ has_dlc = "The Cossacks"
1183
+ }
1184
+ custom_tooltip = FEO_GRANT_COSSACK_SELF_GOVERNANCE_BUFF
1185
+ set_country_flag = feo_cossack_self_governance_buff_flag
1186
+
1187
+ hidden_effect = {
1188
+ if = {
1189
+ limit = {
1190
+ has_estate_privilege = estate_cossacks_cossack_self_governance
1191
+ }
1192
+ every_owned_province = {
1193
+ limit = {
1194
+ has_terrain = steppe
1195
+ }
1196
+ add_province_modifier = {
1197
+ name = feo_cossack_self_governance_religious_buff
1198
+ duration = -1
1199
+ }
1200
+ }
1201
+ }
1202
+ }
1203
+ }
1204
+ else = {
1205
+ add_country_modifier = {
1206
+ name = feo_cosssack_autonomy_modifier
1207
+ duration = -1
1208
+ }
1209
+ }
1210
+ }
1211
+
1212
+ feo_russian_aristocracy_army_size_effect = {
1213
+ if = {
1214
+ limit = {
1215
+ any_country = {
1216
+ NOT = { tag = ROOT }
1217
+ capital_scope = {
1218
+ region = russia_region
1219
+ }
1220
+ }
1221
+ }
1222
+ pick_best_tags = {
1223
+ global_trigger = "
1224
+ NOT = { tag = ROOT }
1225
+ capital_scope = {
1226
+ region = russia_region
1227
+ }
1228
+ government = monarchy
1229
+ "
1230
+ scale = total_development
1231
+ 1 = yes
1232
+ event_target_name = russian_pu_tag
1233
+ }
1234
+ hidden_effect = {
1235
+ event_target:russian_pu_tag_1 = {
1236
+ save_global_event_target_as = feo_russian_pu
1237
+ set_country_flag = feo_russian_pu
1238
+ }
1239
+ country_event = { id = flavor_feo.8 }
1240
+ }
1241
+ }
1242
+ else = {
1243
+ give_claims = { region = russia_region }
1244
+ }
1245
+ }
1246
+
1247
+ feo_russian_claims_reward_effect = {
1248
+ custom_tooltip = FEO_LOWER_RUSSIAN_PROVINCES_AUTONOMY_AND_ACCEPT_RUSSIAN_CULTURE
1249
+ hidden_effect = {
1250
+ every_owned_province = {
1251
+ limit = {
1252
+ region = russia_region
1253
+ }
1254
+ add_local_autonomy = -20
1255
+ add_nationalism = -20
1256
+ }
1257
+ set_country_flag = feo_russian_accepted_cultures_flag
1258
+ add_country_modifier = {
1259
+ name = feo_russian_tolerance
1260
+ duration = -1
1261
+ hidden = yes
1262
+ }
1263
+ add_accepted_culture = russian
1264
+ add_accepted_culture = novgorodian
1265
+ add_accepted_culture = ryazanian
1266
+ add_accepted_culture = byelorussian
1267
+ add_accepted_culture = ruthenian
1268
+ }
1269
+ }
1270
+
1271
+ orm_fars_event_opt_1 = {
1272
+ 430 = {
1273
+ add_base_production = 1
1274
+ add_or_upgrade_shipyard_building = yes
1275
+ }
1276
+ 4332 = {
1277
+ add_or_upgrade_shipyard_building = yes
1278
+ }
1279
+ }
1280
+
1281
+ ITA_branch_effect = {
1282
+ custom_tooltip = ITA_this_is_a_branching_mission
1283
+ }
1284
+
1285
+ GER_cultural_unity_integrated = {
1286
+ GER_execute_effect_for_every_culture = {
1287
+ effect = GER_cultural_unity_integrated_specific
1288
+ }
1289
+
1290
+ hidden_effect = {
1291
+ GER_clear_integration_flag = yes
1292
+ regenerate_government_mechanics = yes
1293
+
1294
+ set_government_power = {
1295
+ mechanic_type = cultural_unity_mechanic
1296
+ power_type = cultural_unity
1297
+ value = 0
1298
+ }
1299
+ }
1300
+ }
1301
+
1302
+ GER_cultural_unity_integrated_specific = {
1303
+ if = {
1304
+ limit = {
1305
+ has_country_flag = GER_integrating_$culture$
1306
+ }
1307
+ set_country_flag = GER_integrated_$culture$
1308
+ GER_integrated_culture = { culture = $culture$ }
1309
+ }
1310
+ }
1311
+
1312
+ GER_integrated_culture = {
1313
+ if = {
1314
+ limit = {
1315
+ accepted_culture = $culture$
1316
+ }
1317
+ add_country_modifier = {
1318
+ name = GER_$culture$_modifier
1319
+ duration = -1
1320
+ desc = GER_until_demotion
1321
+ }
1322
+ }
1323
+ else = {
1324
+ add_country_modifier = {
1325
+ name = GER_$culture$_modifier
1326
+ duration = -1
1327
+ desc = GER_until_demotion
1328
+ }
1329
+ add_accepted_culture = $culture$
1330
+ }
1331
+ }
1332
+
1333
+ GER_on_culture_promoted = {
1334
+ GER_execute_effect_for_every_culture = {
1335
+ effect = GER_on_specific_culture_promoted
1336
+ }
1337
+ }
1338
+
1339
+ GER_on_specific_culture_promoted = {
1340
+ if = {
1341
+ limit = {
1342
+ accepted_culture = $culture$
1343
+ has_country_flag = GER_integrated_$culture$
1344
+ NOT = { has_country_modifier = GER_$culture$_modifier }
1345
+ }
1346
+ add_country_modifier = {
1347
+ name = GER_$culture$_modifier
1348
+ duration = -1
1349
+ desc = GER_until_demotion
1350
+ }
1351
+ }
1352
+ }
1353
+
1354
+ GER_on_culture_demoted = {
1355
+ GER_execute_effect_for_every_culture = {
1356
+ effect = GER_on_specific_culture_demoted
1357
+ }
1358
+ }
1359
+
1360
+ GER_on_specific_culture_demoted = {
1361
+ if = {
1362
+ limit = {
1363
+ OR = {
1364
+ NOT = { has_country_flag = GER_integrated_$culture$ }
1365
+ NOT = { accepted_culture = $culture$ }
1366
+ }
1367
+ has_country_modifier = GER_$culture$_modifier
1368
+ }
1369
+ remove_country_modifier = GER_$culture$_modifier
1370
+ }
1371
+ }
1372
+
1373
+ GER_clear_integration_flag = {
1374
+ GER_execute_effect_for_every_culture = {
1375
+ effect = GER_clear_flag
1376
+ }
1377
+ }
1378
+
1379
+ GER_execute_effect_for_every_culture = {
1380
+ $effect$ = { culture = pommeranian }
1381
+ $effect$ = { culture = austrian }
1382
+ $effect$ = { culture = bavarian }
1383
+ $effect$ = { culture = swiss }
1384
+ $effect$ = { culture = swabian }
1385
+ $effect$ = { culture = franconian }
1386
+ $effect$ = { culture = saxon }
1387
+ $effect$ = { culture = hessian }
1388
+ $effect$ = { culture = hannoverian }
1389
+ $effect$ = { culture = lower_saxon }
1390
+ $effect$ = { culture = prussian }
1391
+ }
1392
+
1393
+ GER_start_integrating = {
1394
+ hidden_effect = {
1395
+ GER_clear_integration_flag = yes
1396
+ }
1397
+
1398
+ custom_tooltip = GER_begin_integrating
1399
+
1400
+ set_country_flag = GER_integrating_$culture$
1401
+
1402
+ hidden_effect = {
1403
+ regenerate_government_mechanics = yes
1404
+ unfreeze_government_power = {
1405
+ mechanic_type = cultural_unity_mechanic
1406
+ power_type = cultural_unity
1407
+ }
1408
+ }
1409
+ }
1410
+
1411
+ GER_clear_flag = {
1412
+ clr_country_flag = GER_integrating_$culture$
1413
+ }
1414
+
1415
+ GER_unlock_reform_based_on_culture = {
1416
+ if = {
1417
+ limit = {
1418
+ OR = {
1419
+ primary_culture = lower_saxon
1420
+ primary_culture = baltic_german
1421
+ primary_culture = pommeranian
1422
+ }
1423
+ }
1424
+ GER_unlock_reform_based_on_certain_culture = { culture = lower_saxon [[reform] reform = $reform$ ] }
1425
+ }
1426
+ else_if = {
1427
+ limit = {
1428
+ primary_culture = prussian
1429
+ }
1430
+ GER_unlock_reform_based_on_certain_culture = { culture = prussian [[reform] reform = $reform$ ] }
1431
+ }
1432
+ else_if = {
1433
+ limit = {
1434
+ primary_culture = hannoverian
1435
+ }
1436
+ GER_unlock_reform_based_on_certain_culture = { culture = westphalian [[reform] reform = $reform$ ] }
1437
+ }
1438
+ else_if = {
1439
+ limit = {
1440
+ primary_culture = hessian
1441
+ }
1442
+ GER_unlock_reform_based_on_certain_culture = { culture = rhenish [[reform] reform = $reform$ ] }
1443
+ }
1444
+ else_if = {
1445
+ limit = {
1446
+ primary_culture = saxon
1447
+ }
1448
+ GER_unlock_reform_based_on_certain_culture = { culture = saxon [[reform] reform = $reform$ ] }
1449
+ }
1450
+ else_if = {
1451
+ limit = {
1452
+ primary_culture = franconian
1453
+ }
1454
+ GER_unlock_reform_based_on_certain_culture = { culture = franconian [[reform] reform = $reform$ ] }
1455
+ }
1456
+ else_if = {
1457
+ limit = {
1458
+ primary_culture = swabian
1459
+ }
1460
+ GER_unlock_reform_based_on_certain_culture = { culture = swabian [[reform] reform = $reform$ ] }
1461
+ }
1462
+ else_if = {
1463
+ limit = {
1464
+ primary_culture = swiss
1465
+ }
1466
+ GER_unlock_reform_based_on_certain_culture = { culture = swiss [[reform] reform = $reform$ ] }
1467
+ }
1468
+ else_if = {
1469
+ limit = {
1470
+ primary_culture = bavarian
1471
+ }
1472
+ GER_unlock_reform_based_on_certain_culture = { culture = bavarian [[reform] reform = $reform$ ] }
1473
+ }
1474
+ else_if = {
1475
+ limit = {
1476
+ primary_culture = austrian
1477
+ }
1478
+ GER_unlock_reform_based_on_certain_culture = { culture = austrian [[reform] reform = $reform$ ] }
1479
+ }
1480
+ else = {
1481
+ GER_unlock_reform_based_on_certain_culture = { culture = other [[reform] reform = $reform$ ] }
1482
+ }
1483
+ }
1484
+
1485
+ GER_unlock_reform_based_on_certain_culture = {
1486
+ set_country_flag = GER_unlocked_$culture$_reform
1487
+ [[reform]
1488
+ add_government_reform = german_$culture$_reform
1489
+ ]
1490
+ }
1491
+
1492
+ GER_remove_cultural_disunity_modifier_for_culture = {
1493
+ if = {
1494
+ limit = {
1495
+ has_country_modifier = GER_$culture$_modifier
1496
+ }
1497
+ remove_country_modifier = GER_$culture$_modifier
1498
+ }
1499
+ }
1500
+
1501
+ GER_remove_cultural_disunity_modifiers = {
1502
+ GER_execute_effect_for_every_culture = {
1503
+ effect = GER_remove_cultural_disunity_modifier_for_culture
1504
+ }
1505
+ }
1506
+
1507
+
1508
+ ned_glorious_revolution_effect_opt_1 = {
1509
+ country_event_with_option_insight = {
1510
+ id = dutch_mission_events.3
1511
+ option_1 = "
1512
+ custom_tooltip = NED_UNLOCK_MAN_O_WARS_TOOLTIP
1513
+ define_advisor = {
1514
+ type = naval_reformer
1515
+ skill = 3
1516
+ cost_multiplier = 0.25
1517
+ culture = english
1518
+ }
1519
+ "
1520
+ option_2 = "
1521
+ custom_tooltip = NED_ENGLAND_PU_IS_25_CHEAPER_TO_INTEGRATE
1522
+ "
1523
+ }
1524
+ }
1525
+
1526
+ INC_upgrade_pachakuti = {
1527
+ if = {
1528
+ limit = {
1529
+ OR = {
1530
+ has_ruler_flag = CSU_pachakuti_upgrades_flag
1531
+ AND = {
1532
+ NOT = { mission_completed = CSU_ground_shaker }
1533
+ has_mission = CSU_ground_shaker
1534
+ }
1535
+ }
1536
+ }
1537
+ change_$type$ = 1
1538
+ custom_tooltip = CSU_only_for_this_ruler
1539
+ custom_tooltip = " "
1540
+ }
1541
+ }
1542
+
1543
+ INC_upgrade_mountain_development_privilege = {
1544
+ custom_tooltip = INC_upgrade_mountain_development_privilege
1545
+ hidden_effect = {
1546
+ set_country_flag = INC_upgrade_mountain_development_privilege_flag
1547
+ if = {
1548
+ limit = {
1549
+ has_estate_privilege = estate_burghers_INC_mountain_development
1550
+ }
1551
+ every_owned_province = {
1552
+ limit = {
1553
+ has_terrain = mountain
1554
+ }
1555
+ remove_province_modifier = estate_burghers_mountain_expansion_mountains
1556
+ add_province_modifier = {
1557
+ name = estate_burghers_mountain_expansion_upgrade_mountains
1558
+ duration = -1
1559
+ }
1560
+ }
1561
+ every_owned_province = {
1562
+ limit = {
1563
+ has_terrain = hills
1564
+ }
1565
+ remove_province_modifier = estate_burghers_mountain_expansion_hills
1566
+ add_province_modifier = {
1567
+ name = estate_burghers_mountain_expansion_upgrade_hills
1568
+ duration = -1
1569
+ }
1570
+ }
1571
+ every_owned_province = {
1572
+ limit = {
1573
+ has_terrain = highlands
1574
+ }
1575
+ remove_province_modifier = estate_burghers_mountain_expansion_highlands
1576
+ add_province_modifier = {
1577
+ name = estate_burghers_mountain_expansion_upgrade_highlands
1578
+ duration = -1
1579
+ }
1580
+ }
1581
+ }
1582
+ }
1583
+ }
1584
+
1585
+ INC_seize_crownland_modified_by_mummies = {
1586
+ if = {
1587
+ limit = {
1588
+ check_variable = {
1589
+ which = inca_amount_of_mummies
1590
+ value = 5
1591
+ }
1592
+ }
1593
+ change_estate_land_share = {
1594
+ estate = all
1595
+ share = -1.25
1596
+ }
1597
+ }
1598
+ else_if = {
1599
+ limit = {
1600
+ check_variable = {
1601
+ which = inca_amount_of_mummies
1602
+ value = 4
1603
+ }
1604
+ }
1605
+ change_estate_land_share = {
1606
+ estate = all
1607
+ share = -2.5
1608
+ }
1609
+ }
1610
+ else_if = {
1611
+ limit = {
1612
+ check_variable = {
1613
+ which = inca_amount_of_mummies
1614
+ value = 3
1615
+ }
1616
+ }
1617
+ change_estate_land_share = {
1618
+ estate = all
1619
+ share = -3.5
1620
+ }
1621
+ }
1622
+ else_if = {
1623
+ limit = {
1624
+ check_variable = {
1625
+ which = inca_amount_of_mummies
1626
+ value = 2
1627
+ }
1628
+ }
1629
+ change_estate_land_share = {
1630
+ estate = all
1631
+ share = -4.25
1632
+ }
1633
+ }
1634
+ else = {
1635
+ change_estate_land_share = {
1636
+ estate = all
1637
+ share = -4.75
1638
+ }
1639
+ }
1640
+ }
1641
+
1642
+ INC_sell_crownland_modified_by_mummies = {
1643
+ if = {
1644
+ limit = {
1645
+ check_variable = {
1646
+ which = inca_amount_of_mummies
1647
+ value = 5
1648
+ }
1649
+ }
1650
+ if = {
1651
+ limit = { current_age = age_of_discovery }
1652
+ add_years_of_estate_land_income = 0.625
1653
+ }
1654
+ else_if = {
1655
+ limit = { current_age = age_of_reformation }
1656
+ add_years_of_estate_land_income = 0.5
1657
+ }
1658
+ else_if = {
1659
+ limit = { current_age = age_of_absolutism }
1660
+ add_years_of_estate_land_income = 0.375
1661
+ }
1662
+ else_if = {
1663
+ limit = { current_age = age_of_revolutions }
1664
+ add_years_of_estate_land_income = 0.25
1665
+ }
1666
+ else = {
1667
+ add_years_of_estate_land_income = 0.625
1668
+ }
1669
+ }
1670
+ else_if = {
1671
+ limit = {
1672
+ check_variable = {
1673
+ which = inca_amount_of_mummies
1674
+ value = 4
1675
+ }
1676
+ }
1677
+ if = {
1678
+ limit = { current_age = age_of_discovery }
1679
+ add_years_of_estate_land_income = 1.25
1680
+ }
1681
+ else_if = {
1682
+ limit = { current_age = age_of_reformation }
1683
+ add_years_of_estate_land_income = 1
1684
+ }
1685
+ else_if = {
1686
+ limit = { current_age = age_of_absolutism }
1687
+ add_years_of_estate_land_income = 0.75
1688
+ }
1689
+ else_if = {
1690
+ limit = { current_age = age_of_revolutions }
1691
+ add_years_of_estate_land_income = 0.5
1692
+ }
1693
+ else = {
1694
+ add_years_of_estate_land_income = 1.25
1695
+ }
1696
+ }
1697
+ else_if = {
1698
+ limit = {
1699
+ check_variable = {
1700
+ which = inca_amount_of_mummies
1701
+ value = 3
1702
+ }
1703
+ }
1704
+ if = {
1705
+ limit = { current_age = age_of_discovery }
1706
+ add_years_of_estate_land_income = 1.75
1707
+ }
1708
+ else_if = {
1709
+ limit = { current_age = age_of_reformation }
1710
+ add_years_of_estate_land_income = 1.4
1711
+ }
1712
+ else_if = {
1713
+ limit = { current_age = age_of_absolutism }
1714
+ add_years_of_estate_land_income = 1.05
1715
+ }
1716
+ else_if = {
1717
+ limit = { current_age = age_of_revolutions }
1718
+ add_years_of_estate_land_income = 0.7
1719
+ }
1720
+ else = {
1721
+ add_years_of_estate_land_income = 1.75
1722
+ }
1723
+ }
1724
+ else_if = {
1725
+ limit = {
1726
+ check_variable = {
1727
+ which = inca_amount_of_mummies
1728
+ value = 2
1729
+ }
1730
+ }
1731
+ if = {
1732
+ limit = { current_age = age_of_discovery }
1733
+ add_years_of_estate_land_income = 2.125
1734
+ }
1735
+ else_if = {
1736
+ limit = { current_age = age_of_reformation }
1737
+ add_years_of_estate_land_income = 1.7
1738
+ }
1739
+ else_if = {
1740
+ limit = { current_age = age_of_absolutism }
1741
+ add_years_of_estate_land_income = 1.275
1742
+ }
1743
+ else_if = {
1744
+ limit = { current_age = age_of_revolutions }
1745
+ add_years_of_estate_land_income = 0.85
1746
+ }
1747
+ else = {
1748
+ add_years_of_estate_land_income = 2.125
1749
+ }
1750
+ }
1751
+ else = {
1752
+ if = {
1753
+ limit = { current_age = age_of_discovery }
1754
+ add_years_of_estate_land_income = 2.375
1755
+ }
1756
+ else_if = {
1757
+ limit = { current_age = age_of_reformation }
1758
+ add_years_of_estate_land_income = 1.9
1759
+ }
1760
+ else_if = {
1761
+ limit = { current_age = age_of_absolutism }
1762
+ add_years_of_estate_land_income = 1.425
1763
+ }
1764
+ else_if = {
1765
+ limit = { current_age = age_of_revolutions }
1766
+ add_years_of_estate_land_income = 0.95
1767
+ }
1768
+ else = {
1769
+ add_years_of_estate_land_income = 2.125
1770
+ }
1771
+ }
1772
+ }
1773
+
1774
+ MAY_venus_effect = {
1775
+ add_stability_or_adm_power = yes
1776
+
1777
+ custom_tooltip = " "
1778
+
1779
+ add_army_tradition_or_mil_power = { amount = 15 }
1780
+ }
1781
+
1782
+ MAY_pass_reform_1_effect = {
1783
+ add_country_modifier = {
1784
+ name = MAY_reform_evolving_modifier_1
1785
+ duration = -1
1786
+ }
1787
+ }
1788
+
1789
+ MAY_pass_reform_2_effect = {
1790
+ custom_tooltip = MAY_reform_evolving_modifier_evolution
1791
+ hidden_effect = {
1792
+ remove_country_modifier = MAY_reform_evolving_modifier_1
1793
+ add_country_modifier = {
1794
+ name = MAY_reform_evolving_modifier_2
1795
+ duration = -1
1796
+ }
1797
+ }
1798
+ }
1799
+
1800
+ MAY_pass_reform_3_effect = {
1801
+ custom_tooltip = MAY_reform_evolving_modifier_evolution
1802
+ hidden_effect = {
1803
+ remove_country_modifier = MAY_reform_evolving_modifier_2
1804
+ add_country_modifier = {
1805
+ name = MAY_reform_evolving_modifier_3
1806
+ duration = -1
1807
+ }
1808
+ }
1809
+ }
1810
+
1811
+ MAY_pass_reform_4_effect = {
1812
+ custom_tooltip = MAY_reform_evolving_modifier_evolution
1813
+ hidden_effect = {
1814
+ remove_country_modifier = MAY_reform_evolving_modifier_3
1815
+ add_country_modifier = {
1816
+ name = MAY_reform_evolving_modifier_4
1817
+ duration = -1
1818
+ }
1819
+ }
1820
+ }
1821
+
1822
+ MAY_pass_reform_5_effect = {
1823
+ custom_tooltip = MAY_reform_evolving_modifier_evolution
1824
+ hidden_effect = {
1825
+ remove_country_modifier = MAY_reform_evolving_modifier_4
1826
+ add_country_modifier = {
1827
+ name = MAY_reform_evolving_modifier_5
1828
+ duration = -1
1829
+ }
1830
+ }
1831
+ }
1832
+
1833
+ MAY_pass_reform_effect = {
1834
+ hidden_effect = {
1835
+ set_variable = {
1836
+ which = land_units_killed_since_last_reform
1837
+ value = 0
1838
+ }
1839
+ }
1840
+ MAY_pass_reform_$amount$_effect = yes
1841
+
1842
+ if = {
1843
+ limit = {
1844
+ NOT = {
1845
+ num_of_maya_religious_reforms = { amount = 5 }
1846
+ }
1847
+ }
1848
+ custom_tooltip = MAY_turn_off_missions
1849
+ hidden_effect = { swap_non_generic_missions = yes }
1850
+ }
1851
+ }
1852
+
1853
+
1854
+ MAY_realm_size_effect = {
1855
+ add_yearly_manpower = 1
1856
+
1857
+ custom_tooltip = " "
1858
+
1859
+ add_power_projection = {
1860
+ type = MAY_reform_passed
1861
+ amount = 10
1862
+ }
1863
+ custom_tooltip = MAY_decays_1_yearly
1864
+ }
1865
+
1866
+ flavor_ger_4_option_1_effect = {
1867
+
1868
+ custom_tooltip = GER_one_province_gets_converted
1869
+
1870
+ custom_tooltip = " "
1871
+
1872
+ if = {
1873
+ limit = {
1874
+ NOT = { religion = catholic }
1875
+ }
1876
+ add_country_modifier = {
1877
+ name = GER_fight_against_the_catholic_church
1878
+ duration = -1
1879
+ }
1880
+ }
1881
+ else = {
1882
+ add_country_modifier = {
1883
+ name = GER_stopping_polish_independence_drive
1884
+ duration = -1
1885
+ }
1886
+ }
1887
+
1888
+ custom_tooltip = GER_every_polish_province_loses_20_autonomy
1889
+ }
1890
+
1891
+ hordes_unite_mongolia_event_opt1 = {
1892
+ if = {
1893
+ limit = {
1894
+ NOT = {
1895
+ primary_culture = mongol
1896
+ }
1897
+ }
1898
+ change_primary_culture = mongol
1899
+ set_ruler_culture = mongol
1900
+ if = {
1901
+ limit = {
1902
+ has_heir = yes
1903
+ }
1904
+ set_heir_culture = mongol
1905
+ }
1906
+ }
1907
+ custom_tooltip = unite_mongol_culture_tt
1908
+ hidden_effect = {
1909
+ every_owned_province = {
1910
+ limit = {
1911
+ OR = {
1912
+ culture = chahar
1913
+ culture = khalkha
1914
+ culture = oirats
1915
+ }
1916
+ }
1917
+ change_culture = mongol
1918
+ }
1919
+ }
1920
+ }
1921
+
1922
+ hordes_unite_mongolia_event_opt2 = {
1923
+ if = {
1924
+ limit = {
1925
+ NOT = { accepted_culture = mongol }
1926
+ NOT = { primary_culture = mongol }
1927
+ }
1928
+ add_accepted_culture = mongol
1929
+ }
1930
+ if = {
1931
+ limit = {
1932
+ NOT = { accepted_culture = chahar }
1933
+ NOT = { primary_culture = chahar }
1934
+ }
1935
+ add_accepted_culture = chahar
1936
+ }
1937
+ if = {
1938
+ limit = {
1939
+ NOT = { accepted_culture = khalkha }
1940
+ NOT = { primary_culture = khalkha }
1941
+ }
1942
+ add_accepted_culture = khalkha
1943
+ }
1944
+ if = {
1945
+ limit = {
1946
+ NOT = { accepted_culture = oirats }
1947
+ NOT = { primary_culture = oirats }
1948
+ }
1949
+ add_accepted_culture = oirats
1950
+ }
1951
+ add_country_modifier = {
1952
+ name = "reorganized_mongols"
1953
+ duration = -1
1954
+ }
1955
+ }
1956
+
1957
+ austria_iberian_hegemony_reward = {
1958
+ custom_tooltip = HAB_CREATE_INTEGRATED_PU_IN_IBERIA
1959
+ hidden_effect = {
1960
+ if = {
1961
+ limit = {
1962
+ senior_union_with = CAS
1963
+ }
1964
+ create_subject = {
1965
+ subject_type = integrated_personal_union
1966
+ subject = CAS
1967
+ }
1968
+ }
1969
+ if = {
1970
+ limit = {
1971
+ senior_union_with = SPA
1972
+ }
1973
+ create_subject = {
1974
+ subject_type = integrated_personal_union
1975
+ subject = SPA
1976
+ }
1977
+ }
1978
+ }
1979
+ }
1980
+
1981
+ austria_surpass_poland_effect = {
1982
+ custom_tooltip = HAB_GIVE_RESTORATION_OF_UNION
1983
+ hidden_effect = {
1984
+ if = {
1985
+ limit = {
1986
+ exists = PLC
1987
+ PLC = { valid_for_personal_unions_trigger = yes }
1988
+ valid_for_personal_unions_trigger = yes
1989
+ PLC = { NOT = { total_own_and_non_tributary_subject_development = 300 } }
1990
+ }
1991
+ add_casus_belli = {
1992
+ type = cb_restore_personal_union
1993
+ target = PLC
1994
+ }
1995
+ }
1996
+ if = {
1997
+ limit = {
1998
+ exists = POL
1999
+ POL = { valid_for_personal_unions_trigger = yes }
2000
+ valid_for_personal_unions_trigger = yes
2001
+ POL = { NOT = { total_own_and_non_tributary_subject_development = 300 } }
2002
+ }
2003
+ add_casus_belli = {
2004
+ type = cb_restore_personal_union
2005
+ target = POL
2006
+ }
2007
+ }
2008
+ }
2009
+ }
2010
+
2011
+ austria_king_of_poland_effect_2 = {
2012
+ add_accepted_culture_or_dip_power = { culture = polish dip_reward = yes }
2013
+
2014
+ custom_tooltip = SEPERATOR_TOOLTIP
2015
+ tooltip = {
2016
+ country_event_with_option_insight = {
2017
+ id = flavor_hab.31
2018
+ option_1 = "
2019
+ 262 = {
2020
+ add_base_production = 3
2021
+ add_province_modifier = {
2022
+ name = hab_expansion_of_krakow
2023
+ duration = -1
2024
+ }
2025
+ }
2026
+ "
2027
+ option_2 = "
2028
+ 257 = {
2029
+ add_base_manpower = 2
2030
+ add_province_modifier = {
2031
+ name = hab_conscription_in_warsaw
2032
+ duration = -1
2033
+ }
2034
+ }
2035
+ "
2036
+ }
2037
+ }
2038
+ }
2039
+
2040
+ hab_liberate_balkans_effect = {
2041
+ custom_tooltip = HAB_CREATE_ROMANIA
2042
+ hidden_effect = {
2043
+ if = {
2044
+ limit = {
2045
+ WAL = {
2046
+ was_player = yes
2047
+ }
2048
+ }
2049
+ WAL = {
2050
+ inherit = MOL
2051
+ change_tag = RMN
2052
+ }
2053
+ }
2054
+ else = {
2055
+ MOL = {
2056
+ inherit = WAL
2057
+ change_tag = RMN
2058
+ }
2059
+ }
2060
+ }
2061
+ }
2062
+
2063
+ italian_ambitions_effect_1 = {
2064
+ country_event_with_option_insight = {
2065
+ id = flavor_hab.32
2066
+ option_1 = "
2067
+ custom_tooltip = HAB_GAIN_50_OPINION_WITH_ITALY
2068
+ "
2069
+ option_2 = "
2070
+ custom_tooltip = HAB_GAIN_SUBJECT_CB_ON_ITALY
2071
+ "
2072
+ }
2073
+ }
2074
+
2075
+ boh_integrate_silesian_subjects = {
2076
+ if = {
2077
+ limit = {
2078
+ GLG = {
2079
+ ai = yes
2080
+ is_subject_of = BOH
2081
+ NOT = {
2082
+ num_of_cities = 10
2083
+ }
2084
+ }
2085
+ }
2086
+ BOH = {
2087
+ inherit = GLG
2088
+ }
2089
+ }
2090
+ if = {
2091
+ limit = {
2092
+ OPL = {
2093
+ ai = yes
2094
+ is_subject_of = BOH
2095
+ NOT = {
2096
+ num_of_cities = 10
2097
+ }
2098
+ }
2099
+ }
2100
+ BOH = {
2101
+ inherit = OPL
2102
+ }
2103
+ }
2104
+ if = {
2105
+ limit = {
2106
+ SIL = {
2107
+ ai = yes
2108
+ is_subject_of = BOH
2109
+ NOT = {
2110
+ num_of_cities = 10
2111
+ }
2112
+ }
2113
+ }
2114
+ BOH = {
2115
+ inherit = SIL
2116
+ }
2117
+ }
2118
+ }
2119
+
2120
+ set_startup_values = {
2121
+ if = {
2122
+ limit = {
2123
+ capital_scope = {
2124
+ religion_group = christian
2125
+ }
2126
+ }
2127
+ change_religion = capital
2128
+ }
2129
+ capital_scope = {
2130
+ build_to_forcelimit = {
2131
+ infantry = 0.6
2132
+ cavalry = 0.3
2133
+ artillery = 0.1
2134
+ }
2135
+ }
2136
+ add_manpower = 20
2137
+ adopt_reform_progress = ROOT
2138
+ if = {
2139
+ limit = {
2140
+ NOT = { prestige = -50 }
2141
+ }
2142
+ add_prestige = 100
2143
+ }
2144
+ add_adm_power = 500
2145
+ add_dip_power = 500
2146
+ add_mil_power = 500
2147
+ add_legitimacy = 100
2148
+ add_stability = 1
2149
+ add_treasury = 500
2150
+ change_estate_land_share = {
2151
+ estate = all
2152
+ share = 65
2153
+ }
2154
+ }
2155
+
2156
+ hab_divide_france = {
2157
+ every_owned_province = {
2158
+ limit = {
2159
+ region = france_region
2160
+ }
2161
+ set_in_empire = yes
2162
+ }
2163
+
2164
+ if = {
2165
+ limit = {
2166
+ NOT = {
2167
+ exists = DAU
2168
+ }
2169
+ }
2170
+ every_owned_province = {
2171
+ if = {
2172
+ limit = { is_core = DAU }
2173
+ remove_core = DAU
2174
+ }
2175
+ }
2176
+ savoy_dauphine_area = {
2177
+ if = {
2178
+ limit = {
2179
+ owned_by = ROOT
2180
+ }
2181
+ add_core = DAU
2182
+ set_in_empire = yes
2183
+ remove_core = ROOT
2184
+ }
2185
+ }
2186
+
2187
+ ROOT = {
2188
+ release = DAU
2189
+ }
2190
+
2191
+ DAU = {
2192
+ set_startup_values = yes
2193
+ add_historical_friend = ROOT
2194
+ ROOT = { add_historical_friend = BUR }
2195
+ }
2196
+ }
2197
+
2198
+ if = {
2199
+ limit = {
2200
+ NOT = {
2201
+ exists = BOU
2202
+ }
2203
+ }
2204
+ every_owned_province = {
2205
+ if = {
2206
+ limit = { is_core = BOU }
2207
+ remove_core = BOU
2208
+ }
2209
+ }
2210
+ massif_central_area = {
2211
+ if = {
2212
+ limit = {
2213
+ owned_by = ROOT
2214
+ }
2215
+ add_core = BOU
2216
+ set_in_empire = yes
2217
+ remove_core = ROOT
2218
+ }
2219
+ }
2220
+
2221
+ ROOT = {
2222
+ release = BOU
2223
+ }
2224
+
2225
+ BOU = {
2226
+ set_startup_values = yes
2227
+ add_historical_friend = ROOT
2228
+ ROOT = { add_historical_friend = BUR }
2229
+ }
2230
+ }
2231
+
2232
+ if = {
2233
+ limit = {
2234
+ NOT = {
2235
+ exists = LOR
2236
+ }
2237
+ }
2238
+ every_owned_province = {
2239
+ if = {
2240
+ limit = { is_core = LOR }
2241
+ remove_core = LOR
2242
+ }
2243
+ }
2244
+ lorraine_area = {
2245
+ if = {
2246
+ limit = {
2247
+ owned_by = ROOT
2248
+ }
2249
+ add_core = LOR
2250
+ set_in_empire = yes
2251
+ remove_core = ROOT
2252
+ }
2253
+ }
2254
+ ROOT = {
2255
+ release = LOR
2256
+ }
2257
+
2258
+ LOR = {
2259
+ set_startup_values = yes
2260
+ add_historical_friend = ROOT
2261
+ ROOT = { add_historical_friend = BUR }
2262
+ }
2263
+ }
2264
+
2265
+ if = {
2266
+ limit = {
2267
+ NOT = {
2268
+ exists = PIC
2269
+ }
2270
+ }
2271
+ every_owned_province = {
2272
+ if = {
2273
+ limit = { is_core = PIC }
2274
+ remove_core = PIC
2275
+ }
2276
+ }
2277
+
2278
+ picardy_area = {
2279
+ if = {
2280
+ limit = {
2281
+ owned_by = ROOT
2282
+ }
2283
+ add_core = PIC
2284
+ set_in_empire = yes
2285
+ remove_core = ROOT
2286
+ }
2287
+ }
2288
+
2289
+ 182 = {
2290
+ if = {
2291
+ limit = {
2292
+ owned_by = ROOT
2293
+ }
2294
+ add_core = PIC
2295
+ set_in_empire = yes
2296
+ remove_core = ROOT
2297
+ }
2298
+ }
2299
+
2300
+ ROOT = {
2301
+ release = PIC
2302
+ }
2303
+
2304
+ PIC = {
2305
+ set_startup_values = yes
2306
+ add_historical_friend = ROOT
2307
+ ROOT = { add_historical_friend = BUR }
2308
+ }
2309
+ }
2310
+
2311
+ if = {
2312
+ limit = {
2313
+ NOT = {
2314
+ exists = CHP
2315
+ }
2316
+ }
2317
+ every_owned_province = {
2318
+ if = {
2319
+ limit = { is_core = CHP }
2320
+ remove_core = CHP
2321
+ }
2322
+ }
2323
+ champagne_area = {
2324
+ if = {
2325
+ limit = {
2326
+ owned_by = ROOT
2327
+ }
2328
+ add_core = CHP
2329
+ set_in_empire = yes
2330
+ remove_core = ROOT
2331
+ }
2332
+ }
2333
+
2334
+ 185 = {
2335
+ if = {
2336
+ limit = {
2337
+ owned_by = ROOT
2338
+ }
2339
+ add_core = CHP
2340
+ set_in_empire = yes
2341
+ remove_core = ROOT
2342
+ }
2343
+ }
2344
+
2345
+ 183 = {
2346
+ if = {
2347
+ limit = {
2348
+ owned_by = ROOT
2349
+ }
2350
+ add_core = CHP
2351
+ set_in_empire = yes
2352
+ remove_core = ROOT
2353
+ }
2354
+ }
2355
+
2356
+ ROOT = {
2357
+ release = CHP
2358
+ }
2359
+
2360
+ CHP = {
2361
+ set_startup_values = yes
2362
+ add_historical_friend = ROOT
2363
+ ROOT = { add_historical_friend = BUR }
2364
+ }
2365
+ }
2366
+
2367
+ if = {
2368
+ limit = {
2369
+ NOT = {
2370
+ exists = NRM
2371
+ }
2372
+ }
2373
+ every_owned_province = {
2374
+ if = {
2375
+ limit = { is_core = NRM }
2376
+ remove_core = NRM
2377
+ }
2378
+ }
2379
+ normandy_area = {
2380
+ if = {
2381
+ limit = {
2382
+ owned_by = ROOT
2383
+ }
2384
+ add_core = NRM
2385
+ set_in_empire = yes
2386
+ remove_core = ROOT
2387
+ }
2388
+ }
2389
+
2390
+ 4388 = {
2391
+ if = {
2392
+ limit = {
2393
+ owned_by = ROOT
2394
+ }
2395
+ add_core = NRM
2396
+ set_in_empire = yes
2397
+ remove_core = ROOT
2398
+ }
2399
+ }
2400
+
2401
+ ROOT = {
2402
+ release = NRM
2403
+ }
2404
+
2405
+ NRM = {
2406
+ set_startup_values = yes
2407
+ add_historical_friend = ROOT
2408
+ ROOT = { add_historical_friend = BUR }
2409
+ }
2410
+ }
2411
+
2412
+ if = {
2413
+ limit = {
2414
+ NOT = {
2415
+ exists = BRI
2416
+ }
2417
+ }
2418
+ every_owned_province = {
2419
+ if = {
2420
+ limit = { is_core = BRI }
2421
+ remove_core = BRI
2422
+ }
2423
+ }
2424
+ brittany_area = {
2425
+ if = {
2426
+ limit = {
2427
+ owned_by = ROOT
2428
+ }
2429
+ add_core = BRI
2430
+ set_in_empire = yes
2431
+ remove_core = ROOT
2432
+ }
2433
+ }
2434
+
2435
+ ROOT = {
2436
+ release = BRI
2437
+ }
2438
+
2439
+ BRI = {
2440
+ set_startup_values = yes
2441
+ add_historical_friend = ROOT
2442
+ ROOT = { add_historical_friend = BUR }
2443
+ }
2444
+ }
2445
+
2446
+ if = {
2447
+ limit = {
2448
+ NOT = {
2449
+ exists = ORL
2450
+ }
2451
+ }
2452
+ every_owned_province = {
2453
+ if = {
2454
+ limit = { is_core = ORL }
2455
+ remove_core = ORL
2456
+ }
2457
+ }
2458
+ orleans_area = {
2459
+ if = {
2460
+ limit = {
2461
+ owned_by = ROOT
2462
+ }
2463
+ add_core = ORL
2464
+ set_in_empire = yes
2465
+ remove_core = ROOT
2466
+ }
2467
+ }
2468
+
2469
+ loire_area = {
2470
+ if = {
2471
+ limit = {
2472
+ owned_by = ROOT
2473
+ }
2474
+ add_core = ORL
2475
+ set_in_empire = yes
2476
+ remove_core = ROOT
2477
+ }
2478
+ }
2479
+
2480
+ ROOT = {
2481
+ release = ORL
2482
+ }
2483
+
2484
+ ORL = {
2485
+ set_startup_values = yes
2486
+ add_historical_friend = ROOT
2487
+ ROOT = { add_historical_friend = BUR }
2488
+ }
2489
+ }
2490
+
2491
+ if = {
2492
+ limit = {
2493
+ NOT = {
2494
+ exists = PRO
2495
+ }
2496
+ }
2497
+ every_owned_province = {
2498
+ if = {
2499
+ limit = { is_core = PRO }
2500
+ remove_core = PRO
2501
+ }
2502
+ }
2503
+ provence_area = {
2504
+ if = {
2505
+ limit = {
2506
+ owned_by = ROOT
2507
+ }
2508
+ add_core = PRO
2509
+ set_in_empire = yes
2510
+ remove_core = ROOT
2511
+ }
2512
+ }
2513
+
2514
+ ROOT = {
2515
+ release = PRO
2516
+ }
2517
+
2518
+ PRO = {
2519
+ set_startup_values = yes
2520
+ add_historical_friend = ROOT
2521
+ ROOT = { add_historical_friend = BUR }
2522
+ }
2523
+ }
2524
+
2525
+ if = {
2526
+ limit = {
2527
+ NOT = {
2528
+ exists = TOU
2529
+ }
2530
+ }
2531
+ every_owned_province = {
2532
+ if = {
2533
+ limit = { is_core = TOU }
2534
+ remove_core = TOU
2535
+ }
2536
+ }
2537
+ languedoc_area = {
2538
+ if = {
2539
+ limit = {
2540
+ owned_by = ROOT
2541
+ }
2542
+ add_core = TOU
2543
+ set_in_empire = yes
2544
+ remove_core = ROOT
2545
+ }
2546
+ }
2547
+
2548
+ 198 = {
2549
+ if = {
2550
+ limit = {
2551
+ owned_by = ROOT
2552
+ }
2553
+ add_core = TOU
2554
+ set_in_empire = yes
2555
+ remove_core = ROOT
2556
+ }
2557
+ }
2558
+
2559
+ ROOT = {
2560
+ release = TOU
2561
+ }
2562
+
2563
+ TOU = {
2564
+ set_startup_values = yes
2565
+ add_historical_friend = ROOT
2566
+ ROOT = { add_historical_friend = BUR }
2567
+ }
2568
+ }
2569
+
2570
+ if = {
2571
+ limit = {
2572
+ NOT = {
2573
+ exists = GUY
2574
+ }
2575
+ }
2576
+ every_owned_province = {
2577
+ if = {
2578
+ limit = { is_core = GUY }
2579
+ remove_core = GUY
2580
+ }
2581
+ }
2582
+ guyenne_area = {
2583
+ if = {
2584
+ limit = {
2585
+ owned_by = ROOT
2586
+ }
2587
+ add_core = GUY
2588
+ set_in_empire = yes
2589
+ remove_core = ROOT
2590
+ }
2591
+ }
2592
+
2593
+ poitou_area = {
2594
+ if = {
2595
+ limit = {
2596
+ owned_by = ROOT
2597
+ }
2598
+ add_core = GUY
2599
+ set_in_empire = yes
2600
+ remove_core = ROOT
2601
+ }
2602
+ }
2603
+
2604
+ pyrenees_area = {
2605
+ if = {
2606
+ limit = {
2607
+ owned_by = ROOT
2608
+ }
2609
+ add_core = GUY
2610
+ set_in_empire = yes
2611
+ remove_core = ROOT
2612
+ }
2613
+ }
2614
+
2615
+ ROOT = {
2616
+ release = GUY
2617
+ }
2618
+
2619
+ GUY = {
2620
+ set_startup_values = yes
2621
+ add_historical_friend = ROOT
2622
+ ROOT = { add_historical_friend = BUR }
2623
+ }
2624
+ }
2625
+
2626
+ if = {
2627
+ limit = {
2628
+ NOT = {
2629
+ exists = BUR
2630
+ }
2631
+ }
2632
+ every_owned_province = {
2633
+ if = {
2634
+ limit = { is_core = BUR }
2635
+ remove_core = BUR
2636
+ }
2637
+ }
2638
+ west_burgundy_area = {
2639
+ if = {
2640
+ limit = {
2641
+ owned_by = ROOT
2642
+ }
2643
+ add_core = BUR
2644
+
2645
+ remove_core = ROOT
2646
+ }
2647
+ }
2648
+ bourgogne_area = {
2649
+ if = {
2650
+ limit = {
2651
+ owned_by = ROOT
2652
+ }
2653
+ add_core = BUR
2654
+
2655
+ remove_core = ROOT
2656
+ }
2657
+ }
2658
+
2659
+ ROOT = {
2660
+ release = BUR
2661
+ }
2662
+
2663
+ BUR = {
2664
+ set_startup_values = yes
2665
+ add_historical_friend = ROOT
2666
+ ROOT = { add_historical_friend = BUR }
2667
+ }
2668
+ }
2669
+ }
2670
+
2671
+ grant_estate_10_crown_land = {
2672
+ change_estate_land_share = {
2673
+ estate = all
2674
+ share = -20
2675
+ }
2676
+ change_estate_land_share = {
2677
+ estate = estate_$estate$
2678
+ share = 10
2679
+ }
2680
+ }
2681
+
2682
+ reform_civil_registration_effect = {
2683
+ custom_tooltip = YUA_EVERY_POPULATION_CENSUS_DECREE_GRANTS_MODIFIER
2684
+ if = {
2685
+ limit = {
2686
+ has_dlc = "Rights of Man"
2687
+ has_dlc = "Mandate of Heaven"
2688
+ NOT = { num_of_ruler_traits = { amount = 3 } }
2689
+ }
2690
+ change_government_reform_progress = -150
2691
+ add_ruler_personality = reformist_personality
2692
+ set_country_flag = mng_empowered_pop_census_flag
2693
+ }
2694
+ else = {
2695
+ change_adm = 1
2696
+ change_government_reform_progress = -100
2697
+ set_country_flag = mng_empowered_pop_census_flag
2698
+ }
2699
+ }
2700
+
2701
+ yua_examination_system_effect = {
2702
+ country_event_with_effect_insight = {
2703
+ id = flavor_mng.30
2704
+ effect = "
2705
+ 700 = { add_province_triggered_modifier = mng_hanlin_academy_modifier }
2706
+ if = {
2707
+ limit = { has_dlc = \"Mandate of Heaven\" }
2708
+ add_splendor = 100
2709
+ }
2710
+ else = { add_prestige_or_monarch_power = { amount = 25 } }
2711
+ "
2712
+ }
2713
+ }
2714
+
2715
+ yua_mutual_trade_effect_1 = {
2716
+ if = {
2717
+ limit = {
2718
+ has_dlc = "Mandate of Heaven"
2719
+ is_emperor_of_china = yes
2720
+ }
2721
+ custom_tooltip = mng_5_mandate_per_ally_tt
2722
+ }
2723
+ else = { custom_tooltip = mng_25_mp_per_ally_tt }
2724
+ custom_tooltip = SEPERATOR_TOOLTIP
2725
+ add_country_modifier = {
2726
+ name = mng_foreign_merchant_influx_modifier
2727
+ duration = 7300
2728
+ }
2729
+ custom_tooltip = YUA_ALL_ALLIES_THAT_MEET_REQUIREMENTS_GAIN_THE_FOLLOWING
2730
+ tooltip = {
2731
+ add_country_modifier = {
2732
+ name = mng_trade_access_in_china_modifier
2733
+ duration = -1
2734
+ desc = as_long_as_we_stay_allies_desc
2735
+ }
2736
+ }
2737
+ hidden_effect = {
2738
+ if = {
2739
+ limit = {
2740
+ calc_true_if = {
2741
+ all_ally = {
2742
+ has_opinion = {
2743
+ who = ROOT
2744
+ value = 150
2745
+ }
2746
+ if = {
2747
+ limit = { has_dlc = "Leviathan" }
2748
+ trust = {
2749
+ who = ROOT
2750
+ value = 70
2751
+ }
2752
+ }
2753
+ }
2754
+ amount = 4
2755
+ }
2756
+ }
2757
+ every_ally = {
2758
+ limit = {
2759
+ has_opinion = {
2760
+ who = ROOT
2761
+ value = 150
2762
+ }
2763
+ if = {
2764
+ limit = { has_dlc = "Leviathan" }
2765
+ trust = {
2766
+ who = ROOT
2767
+ value = 70
2768
+ }
2769
+ }
2770
+ }
2771
+ add_country_modifier = {
2772
+ name = mng_trade_access_in_china_modifier
2773
+ duration = -1
2774
+ desc = as_long_as_we_stay_allies_desc
2775
+ }
2776
+ }
2777
+ add_country_modifier = {
2778
+ name = mng_foreign_merchant_influx_modifier
2779
+ duration = 7300
2780
+ }
2781
+ if = {
2782
+ limit = { has_dlc = "Mandate of Heaven" }
2783
+ every_ally = {
2784
+ limit = {
2785
+ has_opinion = {
2786
+ who = ROOT
2787
+ value = 150
2788
+ }
2789
+ if = {
2790
+ limit = { has_dlc = "Leviathan" }
2791
+ trust = {
2792
+ who = ROOT
2793
+ value = 70
2794
+ }
2795
+ }
2796
+ }
2797
+ ROOT = { add_mandate = 5 }
2798
+ }
2799
+ }
2800
+ else = {
2801
+ every_ally = {
2802
+ limit = {
2803
+ has_opinion = {
2804
+ who = ROOT
2805
+ value = 150
2806
+ }
2807
+ if = {
2808
+ limit = { has_dlc = "Leviathan" }
2809
+ trust = {
2810
+ who = ROOT
2811
+ value = 70
2812
+ }
2813
+ }
2814
+ }
2815
+ ROOT = {
2816
+ add_adm_power = 25
2817
+ add_dip_power = 25
2818
+ add_mil_power = 25
2819
+ }
2820
+ }
2821
+ }
2822
+ }
2823
+ }
2824
+ }
2825
+
2826
+ yua_single_whip_law_effect = {
2827
+ 2139 = {
2828
+ change_trade_goods = gold
2829
+ }
2830
+
2831
+ every_owned_province = {
2832
+ limit = { trade_goods = gold }
2833
+ add_province_modifier = {
2834
+ name = mng_silver_house_of_china_modifier
2835
+ duration = -1
2836
+ }
2837
+ }
2838
+
2839
+ define_advisor = {
2840
+ name = "Zhang Juzheng"
2841
+ type = treasurer
2842
+ skill = 2
2843
+ cost_multiplier = 0.2
2844
+ }
2845
+
2846
+ if = {
2847
+ limit = {
2848
+ any_ally = {
2849
+ capital_scope = { continent = europe }
2850
+ OR = {
2851
+ any_owned_province = {
2852
+ NOT = { continent = europe }
2853
+ trade_goods = gold
2854
+ }
2855
+ any_subject_country = {
2856
+ any_owned_province = {
2857
+ NOT = { continent = europe }
2858
+ trade_goods = gold
2859
+ }
2860
+ }
2861
+ }
2862
+ }
2863
+ }
2864
+ random_ally = {
2865
+ limit = {
2866
+ capital_scope = { continent = europe }
2867
+ OR = {
2868
+ any_owned_province = {
2869
+ NOT = { continent = europe }
2870
+ trade_goods = gold
2871
+ }
2872
+ any_subject_country = {
2873
+ any_owned_province = {
2874
+ NOT = { continent = europe }
2875
+ trade_goods = gold
2876
+ }
2877
+ }
2878
+ }
2879
+ }
2880
+ add_country_modifier = {
2881
+ name = mng_silver_trade_china_modifier
2882
+ duration = 7300
2883
+ }
2884
+ }
2885
+ }
2886
+
2887
+ if = {
2888
+ limit = { has_dlc = "Leviathan" }
2889
+ custom_tooltip = mng_inform_about_potosi_tt
2890
+ }
2891
+
2892
+ custom_tooltip = mng_may_enact_single_whip_reform
2893
+ custom_tooltip = empty_line_tt
2894
+ if = {
2895
+ limit = {
2896
+ NOT = { has_estate_privilege = estate_eunuchs_single_whip_law_privilege }
2897
+ }
2898
+ set_estate_privilege = estate_eunuchs_single_whip_law_privilege
2899
+ }
2900
+ }
2901
+
2902
+ every_trunk_road_province_effect = {
2903
+ custom_tooltip = MUG_every_highlighted_province
2904
+ tooltip = {
2905
+ $effect$
2906
+ }
2907
+ hidden_effect = {
2908
+ 4449 = { $effect$ }
2909
+ 2076 = { $effect$ }
2910
+ 507 = { $effect$ }
2911
+ 2075 = { $effect$ }
2912
+ 510 = { $effect$ }
2913
+ 2062 = { $effect$ }
2914
+ 522 = { $effect$ }
2915
+ 524 = { $effect$ }
2916
+ 2063 = { $effect$ }
2917
+ 523 = { $effect$ }
2918
+ 555 = { $effect$ }
2919
+ 4490 = { $effect$ }
2920
+ 4487 = { $effect$ }
2921
+ 4489 = { $effect$ }
2922
+ 2044 = { $effect$ }
2923
+ 563 = { $effect$ }
2924
+ 4479 = { $effect$ }
2925
+ 4476 = { $effect$ }
2926
+ 561 = { $effect$ }
2927
+ 4475 = { $effect$ }
2928
+ }
2929
+ }
2930
+
2931
+ extra_claims_for_nomadic_path = {
2932
+ if = {
2933
+ limit = {
2934
+ TIM_nomad_tree_trigger = yes
2935
+ }
2936
+ if = {
2937
+ limit = {
2938
+ not_in_mission_preview_mode = { key = TIM }
2939
+ }
2940
+ $effect$
2941
+ }
2942
+ else = {
2943
+ custom_tooltip = TIM_if_we_choose_to_go_for_nomadic_tree
2944
+ tooltip = {
2945
+ $effect$
2946
+ }
2947
+ }
2948
+ custom_tooltip = " "
2949
+ }
2950
+ }
2951
+
2952
+ update_fervor_effects = {
2953
+ if = {
2954
+ limit = { has_active_fervor = fervor_trade }
2955
+ remove_active_fervor = fervor_trade
2956
+ add_active_fervor = fervor_trade_buffed
2957
+ }
2958
+ if = {
2959
+ limit = { has_active_fervor = fervor_war }
2960
+ remove_active_fervor = fervor_war
2961
+ add_active_fervor = fervor_war_buffed
2962
+ }
2963
+ if = {
2964
+ limit = { has_active_fervor = fervor_stability }
2965
+ remove_active_fervor = fervor_stability
2966
+ add_active_fervor = fervor_stability_buffed
2967
+ }
2968
+ if = {
2969
+ limit = { has_active_fervor = fervor_diplomacy }
2970
+ remove_active_fervor = fervor_diplomacy
2971
+ add_active_fervor = fervor_diplomacy_buffed
2972
+ }
2973
+ }