# Effect: modify_social_conservatism_government # Purpose: Modifies the social conservatism of thegovernment modify_social_conservatism_government = { add_to_variable = { social_conservatism_government = temp_modify_social_con_government } clamp_variable = { var = social_conservatism_government min = 0 max = 100 } custom_effect_tooltip = conservatism_government_change_tt } # Effect: modify_gcc_unity # Purpose: Modifies the GCC Unity mechanic for the GCC modify_gcc_unity = { add_to_variable = { global.gcc_unity = temp_modify_gcc_unity } clamp_variable = { var = global.gcc_unity min = 0 max = 100 } custom_effect_tooltip = GCC_unity_change_tt } increase_pop_gulf = { if = { limit = { OR = { original_tag = BHR original_tag = QAT } } if = { limit = { NOT = { has_completed_focus = GCC_open_pathways_to_citizenship } } capital_scope = { add_manpower = 20000 } } else = { capital_scope = { add_manpower = 30000 } } } else_if = { limit = { original_tag = KUW } if = { limit = { NOT = { has_completed_focus = GCC_open_pathways_to_citizenship } } capital_scope = { add_manpower = 40000 } } else = { capital_scope = { add_manpower = 60000 } } } else_if = { limit = { original_tag = OMA } if = { limit = { NOT = { has_completed_focus = GCC_open_pathways_to_citizenship } } 182 = { add_manpower = 35000 } 183 = { add_manpower = 10000 } 182 = { add_manpower = 5000 } } else = { 182 = { add_manpower = 40000 } 183 = { add_manpower = 15000 } 182 = { add_manpower = 10000 } } } else_if = { limit = { original_tag = UAE } if = { limit = { NOT = { has_completed_focus = GCC_open_pathways_to_citizenship } } 180 = { add_manpower = 40000 } 179 = { add_manpower = 45000 } } else = { 180 = { add_manpower = 45000 } 179 = { add_manpower = 55000 } } } else_if = { limit = { original_tag = SAU } if = { limit = { NOT = { has_completed_focus = GCC_open_pathways_to_citizenship } } 174 = { add_manpower = 35000 } 176 = { add_manpower = 175000 } 177 = { add_manpower = 50000 } 178 = { add_manpower = 15000 } } else = { 174 = { add_manpower = 35000 } 176 = { add_manpower = 190000 } 177 = { add_manpower = 50000 } 178 = { add_manpower = 25000 } } } } decrease_pop_gulf = { if = { limit = { original_tag = KUW } capital_scope = { add_manpower = -40000 } } else_if = { limit = { original_tag = OMA } 182 = { add_manpower = -35000 } 183 = { add_manpower = -10000 } 182 = { add_manpower = -5000 } } else_if = { limit = { original_tag = UAE } 180 = { add_manpower = -40000 } 179 = { add_manpower = -45000 } } else_if = { limit = { original_tag = SAU } 174 = { add_manpower = -35000 } 176 = { add_manpower = -175000 } 177 = { add_manpower = -50000 } 178 = { add_manpower = -15000 } } } IRQ_MNF_setup = { hidden_effect = { create_dynamic_country = { original_tag = IRQ copy_tag = IRQ set_country_flag = IRQ_MNF set_cosmetic_tag = IRQ_MNF set_politics = { ruling_party = democratic elections_allowed = no } set_political_party = { ideology = democratic popularity = 100 } set_variable = { party_pop_array^0 = 1 } start_politics_input = yes set_variable = { ruling_party = 0 } startup_politics = yes ingame_startup_nations_effect = yes add_ideas = { non_state_actor sunni corruption_level_05 intervention_neo_imperialism defence_09 edu_01 health_01 social_01 police_05 bureau_01 partial_draft_army no_women_in_military officer_basic_training } } IRQ = { every_owned_state = { limit = { is_fully_controlled_by = USA } transfer_state_to = MNF } 171 = { transfer_state_to = MNF } } USA = { puppet = MNF add_to_faction = MNF } every_country = { limit = { has_country_flag = wot_pledged_mnf_volunteers } country_event = { id = iraqi_MNF.3 days = 1 } } if = { limit = { country_exists = MNF } MNF = { create_country_leader = { name = "David D. McKiernan" picture = "USA_David_McKiernan.dds" ideology = Western_Autocracy traits = { western_Western_Autocracy military_career pro_american } } set_country_flag = is_iraq_mnf if = { limit = { NOT = { has_war_with = IRQ } } declare_war_on = { target = IRQ type = civil_war } } add_civil_war_target = IRQ become_exiled_in = { target = USA legitimacy = 25 } 171 = { set_state_controller_to = IRQ } leave_faction = yes } } } } # Arab Spring Content AS_spawn_isis_into_game = { hidden_effect = { 192 = { add_core_of = ISI } release = ISI 192 = { add_core_of = SYR } ISI = { ingame_startup_nations_effect = yes every_state = { limit = { OR = { is_core_of = SYR is_core_of = ROJ is_core_of = IRQ } } add_core_of = ISI } if = { limit = { has_dlc = "No Step Back" } load_oob = ISI_2017_nsb } else = { load_oob = ISI_2017_nonnsb } add_timed_idea = { idea = ISI_islamic_state_early_offensive_idea days = 180 } IRQ = { add_timed_idea = { idea = ISI_islamic_state_failure_idea days = 90 } } SYR = { add_timed_idea = { idea = ISI_islamic_state_failure_idea days = 180 } } capital_scope = { create_unit = { division = "name = \"Liwa Milisha\" division_template = \"Liwa Milisha\" start_experience_factor = 0.9" prioritize_location = 6312 owner = ISI count = 2 } if = { limit = { SYR = { is_ai = no } difficulty > 2 } create_unit = { division = "name = \"Liwa Milisha\" division_template = \"Liwa Milisha\" start_experience_factor = 0.9" prioritize_location = 631 owner = ISI count = 3 } } if = { limit = { SYR = { is_ai = no } difficulty > 3 } create_unit = { division = "name = \"Liwa Milisha\" division_template = \"Liwa Milisha\" start_experience_factor = 0.9" prioritize_location = 631 owner = ISI count = 3 } } } if = { limit = { country_exists = FSA NOT = { has_war_with = FSA } } declare_war_on = { target = FSA type = annex_everything } } if = { limit = { country_exists = NUS NOT = { has_war_with = NUS } } declare_war_on = { target = NUS type = annex_everything } } if = { limit = { country_exists = ROJ NOT = { has_war_with = ROJ } } declare_war_on = { target = ROJ type = annex_everything } } if = { limit = { country_exists = SYR NOT = { has_war_with = SYR } } declare_war_on = { target = SYR type = annex_everything } } if = { limit = { country_exists = IRQ NOT = { has_war_with = IRQ } } declare_war_on = { target = IRQ type = annex_everything } } if = { limit = { country_exists = KUR NOT = { has_war_with = KUR } } declare_war_on = { target = KUR type = annex_everything } } if = { limit = { country_exists = PUK NOT = { has_war_with = PUK } } declare_war_on = { target = PUK type = annex_everything } } add_named_threat = { threat = 5 name = ISIS.threat } apply_terrorism_opinion_to_world = yes } } } censored_nation_level_up = { if = { limit = { has_idea = new_censored_nation_01 } swap_ideas = { remove_idea = new_censored_nation_01 add_idea = new_censored_nation_02 } } else_if = { limit = { has_idea = new_censored_nation_02 } swap_ideas = { remove_idea = new_censored_nation_02 add_idea = new_censored_nation_03 } } else_if = { limit = { has_idea = new_censored_nation_03 } swap_ideas = { remove_idea = new_censored_nation_03 add_idea = new_censored_nation_04 } } else_if = { limit = { has_idea = new_censored_nation_04 } swap_ideas = { remove_idea = new_censored_nation_04 add_idea = new_censored_nation_05 } } else_if = { limit = { has_idea = new_censored_nation_05 } swap_ideas = { remove_idea = new_censored_nation_05 add_idea = new_censored_nation_06 } } else_if = { limit = { has_idea = new_censored_nation_06 } swap_ideas = { remove_idea = new_censored_nation_06 add_idea = new_closed_nation } } } open_nation_level_up = { if = { limit = { has_idea = new_censored_nation_01 } swap_ideas = { remove_idea = new_censored_nation_01 add_idea = new_open_nation_01 } } else_if = { limit = { has_idea = new_open_nation_01 } swap_ideas = { remove_idea = new_open_nation_01 add_idea = new_open_nation_02 } } else_if = { limit = { has_idea = new_open_nation_02 } swap_ideas = { remove_idea = new_open_nation_02 add_idea = new_open_nation_03 } } else_if = { limit = { has_idea = new_open_nation_03 } swap_ideas = { remove_idea = new_open_nation_03 add_idea = new_open_nation_04 } } else_if = { limit = { has_idea = new_open_nation_04 } swap_ideas = { remove_idea = new_open_nation_04 add_idea = new_open_nation_05 } } else_if = { limit = { has_idea = new_open_nation_05 } swap_ideas = { remove_idea = new_open_nation_05 add_idea = new_open_nation_06 } } else_if = { limit = { has_idea = new_open_nation_06 } swap_ideas = { remove_idea = new_open_nation_06 add_idea = new_open_nation_07 } } else_if = { limit = { has_idea = GCC_censored_nation_01 } swap_ideas = { remove_idea = GCC_censored_nation_01 add_idea = new_open_nation_01 } } else_if = { limit = { has_idea = GCC_censored_nation_01 } swap_ideas = { remove_idea = GCC_censored_nation_01 add_idea = GCC_open_nation_02 } } else_if = { limit = { has_idea = GCC_open_nation_02 } swap_ideas = { remove_idea = GCC_open_nation_02 add_idea = GCC_open_nation_03 } } else_if = { limit = { has_idea = GCC_open_nation_03 } swap_ideas = { remove_idea = GCC_open_nation_03 add_idea = GCC_open_nation_04 } } else_if = { limit = { has_idea = GCC_open_nation_04 } swap_ideas = { remove_idea = GCC_open_nation_04 add_idea = GCC_open_nation_05 } } else_if = { limit = { has_idea = GCC_open_nation_05 } swap_ideas = { remove_idea = GCC_open_nation_05 add_idea = GCC_open_nation_06 } } else_if = { limit = { has_idea = GCC_open_nation_06 } swap_ideas = { remove_idea = GCC_open_nation_06 add_idea = GCC_open_nation_07 } } } GCC_censored_nation_level_up = { if = { limit = { has_idea = GCC_censored_nation_01 } swap_ideas = { remove_idea = GCC_censored_nation_01 add_idea = GCC_censored_nation_02 } } else_if = { limit = { has_idea = GCC_censored_nation_02 } swap_ideas = { remove_idea = GCC_censored_nation_02 add_idea = GCC_censored_nation_03 } } else_if = { limit = { has_idea = GCC_censored_nation_03 } swap_ideas = { remove_idea = GCC_censored_nation_03 add_idea = GCC_censored_nation_04 } } else_if = { limit = { has_idea = GCC_censored_nation_04 } swap_ideas = { remove_idea = GCC_censored_nation_04 add_idea = GCC_censored_nation_05 } } else_if = { limit = { has_idea = GCC_censored_nation_05 } swap_ideas = { remove_idea = GCC_censored_nation_05 add_idea = GCC_censored_nation_06 } } else_if = { limit = { has_idea = new_censored_nation_01 } swap_ideas = { remove_idea = new_censored_nation_01 add_idea = GCC_censored_nation_02 } } else_if = { limit = { has_idea = new_censored_nation_02 } swap_ideas = { remove_idea = new_censored_nation_02 add_idea = GCC_censored_nation_03 } } else_if = { limit = { has_idea = new_censored_nation_03 } swap_ideas = { remove_idea = new_censored_nation_03 add_idea = GCC_censored_nation_04 } } else_if = { limit = { has_idea = new_censored_nation_04 } swap_ideas = { remove_idea = new_censored_nation_04 add_idea = GCC_censored_nation_05 } } else_if = { limit = { has_idea = new_censored_nation_05 } swap_ideas = { remove_idea = new_censored_nation_05 add_idea = GCC_censored_nation_06 } } } GCC_open_nation_level_up = { if = { limit = { has_idea = GCC_censored_nation_01 } swap_ideas = { remove_idea = GCC_censored_nation_01 add_idea = GCC_open_nation_01 } } else_if = { limit = { has_idea = GCC_open_nation_01 } swap_ideas = { remove_idea = GCC_open_nation_01 add_idea = GCC_open_nation_02 } } else_if = { limit = { has_idea = GCC_open_nation_02 } swap_ideas = { remove_idea = GCC_open_nation_02 add_idea = GCC_open_nation_03 } } else_if = { limit = { has_idea = GCC_open_nation_03 } swap_ideas = { remove_idea = GCC_open_nation_03 add_idea = GCC_open_nation_04 } } else_if = { limit = { has_idea = GCC_open_nation_04 } swap_ideas = { remove_idea = GCC_open_nation_04 add_idea = GCC_open_nation_05 } } else_if = { limit = { has_idea = GCC_open_nation_05 } swap_ideas = { remove_idea = GCC_open_nation_05 add_idea = GCC_open_nation_06 } } else_if = { limit = { has_idea = GCC_open_nation_06 } swap_ideas = { remove_idea = GCC_open_nation_06 add_idea = GCC_open_nation_07 } } } BHR_open_nation_level_up = { if = { limit = { has_idea = GCC_censored_nation_01 } swap_ideas = { remove_idea = GCC_censored_nation_01 add_idea = BHR_open_nation_01 } } else_if = { limit = { has_idea = BHR_open_nation_01 } swap_ideas = { remove_idea = BHR_open_nation_01 add_idea = BHR_open_nation_02 } } else_if = { limit = { has_idea = BHR_open_nation_02 } swap_ideas = { remove_idea = BHR_open_nation_02 add_idea = BHR_open_nation_03 } } else_if = { limit = { has_idea = BHR_open_nation_03 } swap_ideas = { remove_idea = BHR_open_nation_03 add_idea = BHR_open_nation_04 } } else_if = { limit = { has_idea = BHR_open_nation_04 } swap_ideas = { remove_idea = BHR_open_nation_04 add_idea = BHR_open_nation_05 } } else_if = { limit = { has_idea = BHR_open_nation_05 } swap_ideas = { remove_idea = BHR_open_nation_05 add_idea = BHR_open_nation_06 } } else_if = { limit = { has_idea = BHR_open_nation_06 } swap_ideas = { remove_idea = BHR_open_nation_06 add_idea = BHR_open_nation_07 } } } shia_resistance_level_up = { if = { limit = { NOT = { OR = { has_idea = shia_resistance_01 has_idea = shia_resistance_02 has_idea = shia_resistance_03 has_idea = shia_resistance_04 has_idea = shia_resistance_05 has_idea = shia_resistance_06 has_idea = shia_resistance_07 has_idea = shia_resistance_08 has_idea = shia_resistance_09 has_idea = shia_resistance_10 } } } add_ideas = shia_resistance_01 } if = { limit = { has_idea = shia_resistance_01 } swap_ideas = { remove_idea = shia_resistance_01 add_idea = shia_resistance_02 } } else_if = { limit = { has_idea = shia_resistance_02 } swap_ideas = { remove_idea = shia_resistance_02 add_idea = shia_resistance_03 } } else_if = { limit = { has_idea = shia_resistance_03 } swap_ideas = { remove_idea = shia_resistance_03 add_idea = shia_resistance_04 } } else_if = { limit = { has_idea = shia_resistance_04 } swap_ideas = { remove_idea = shia_resistance_04 add_idea = shia_resistance_05 } } else_if = { limit = { has_idea = shia_resistance_05 } swap_ideas = { remove_idea = shia_resistance_05 add_idea = shia_resistance_06 } } else_if = { limit = { has_idea = shia_resistance_06 } swap_ideas = { remove_idea = shia_resistance_06 add_idea = shia_resistance_07 } } else_if = { limit = { has_idea = shia_resistance_07 } swap_ideas = { remove_idea = shia_resistance_07 add_idea = shia_resistance_08 } } else_if = { limit = { has_idea = shia_resistance_08 } swap_ideas = { remove_idea = shia_resistance_08 add_idea = shia_resistance_09 } } else_if = { limit = { has_idea = shia_resistance_09 } swap_ideas = { remove_idea = shia_resistance_09 add_idea = shia_resistance_10 } } else = { add_political_power = -50 } } shia_resistance_level_down = { if = { limit = { has_idea = shia_resistance_10 } swap_ideas = { remove_idea = shia_resistance_10 add_idea = shia_resistance_09 } } else_if = { limit = { has_idea = shia_resistance_09 } swap_ideas = { remove_idea = shia_resistance_09 add_idea = shia_resistance_08 } } else_if = { limit = { has_idea = shia_resistance_08 } swap_ideas = { remove_idea = shia_resistance_08 add_idea = shia_resistance_07 } } else_if = { limit = { has_idea = shia_resistance_07 } swap_ideas = { remove_idea = shia_resistance_07 add_idea = shia_resistance_06 } } else_if = { limit = { has_idea = shia_resistance_06 } swap_ideas = { remove_idea = shia_resistance_06 add_idea = shia_resistance_05 } } else_if = { limit = { has_idea = shia_resistance_05 } swap_ideas = { remove_idea = shia_resistance_05 add_idea = shia_resistance_04 } } else_if = { limit = { has_idea = shia_resistance_07 } swap_ideas = { remove_idea = shia_resistance_07 add_idea = shia_resistance_08 } } else_if = { limit = { has_idea = shia_resistance_04 } swap_ideas = { remove_idea = shia_resistance_04 add_idea = shia_resistance_03 } } else_if = { limit = { has_idea = shia_resistance_03 } swap_ideas = { remove_idea = shia_resistance_03 add_idea = shia_resistance_02 } } else_if = { limit = { has_idea = shia_resistance_02 } swap_ideas = { remove_idea = shia_resistance_02 add_idea = shia_resistance_01 } } else = { add_political_power = 50 } } remove_shia_resistance = { if = { limit = { has_idea = shia_resistance_01 } remove_ideas = shia_resistance_01 } if = { limit = { has_idea = shia_resistance_02 } remove_ideas = shia_resistance_02 } if = { limit = { has_idea = shia_resistance_03 } remove_ideas = shia_resistance_03 } if = { limit = { has_idea = shia_resistance_04 } remove_ideas = shia_resistance_04 } if = { limit = { has_idea = shia_resistance_05 } remove_ideas = shia_resistance_05 } if = { limit = { has_idea = shia_resistance_06 } remove_ideas = shia_resistance_06 } if = { limit = { has_idea = shia_resistance_07 } remove_ideas = shia_resistance_07 } if = { limit = { has_idea = shia_resistance_08 } remove_ideas = shia_resistance_08 } if = { limit = { has_idea = shia_resistance_09 } remove_ideas = shia_resistance_09 } if = { limit = { has_idea = shia_resistance_10 } remove_ideas = shia_resistance_10 } } clamp_shia = { clamp_variable = { var = shia_population min = 0 max = 100 } if = { limit = { NOT = { OR = { has_idea = tiny_shia_population has_idea = small_shia_population has_idea = substantial_shia_population has_idea = large_shia_population } } check_variable = { shia_population > 0 } } add_ideas = { tiny_shia_population } } if = { limit = { has_idea = tiny_shia_population check_variable = { shia_population = 0 } } remove_ideas = { tiny_shia_population } } if = { limit = { has_idea = tiny_shia_population check_variable = { shia_population > 10 } } swap_ideas = { remove_idea = tiny_shia_population add_idea = small_shia_population } } if = { limit = { has_idea = small_shia_population check_variable = { shia_population < 11 } } swap_ideas = { remove_idea = small_shia_population add_idea = tiny_shia_population } } if = { limit = { has_idea = small_shia_population check_variable = { shia_population > 19 } } swap_ideas = { remove_idea = small_shia_population add_idea = substantial_shia_population } } if = { limit = { has_idea = substantial_shia_population check_variable = { shia_population < 20 } } swap_ideas = { remove_idea = substantial_shia_population add_idea = small_shia_population } } if = { limit = { has_idea = substantial_shia_population check_variable = { shia_population > 49 } } swap_ideas = { remove_idea = substantial_shia_population add_idea = large_shia_population } } if = { limit = { has_idea = large_shia_population check_variable = { shia_population < 50 } } swap_ideas = { remove_idea = large_shia_population add_idea = substantial_shia_population } } } # Arab Spring Section # Effect: change_arab_spring_strength # Purpose: Change the strength of the Arab Spring protests # Parameters: # - temp_strength - The change in protest strength change_arab_spring_strength = { custom_effect_tooltip = change_arab_spring_strength_tt add_to_variable = { arab_spring = temp_strength } } # Effect: calculate_monthly_arab_spring_change # Purpose: Calculate the change in protest strength for the month calculate_monthly_arab_spring_change = { set_variable = { arab_spring_change = 0 } # Police Brutality Increases Arab Spring Likelihood if = { limit = { has_idea = police_05 } add_to_variable = { arab_spring_change = 3 } } else_if = { limit = { has_idea = police_04 } add_to_variable = { arab_spring_change = 2 } } else_if = { limit = { has_idea = police_03 } add_to_variable = { arab_spring_change = 1 } } # Economic Situation Increases Arab Spring Likelihood if = { limit = { check_variable = { gdp_per_capita < 15 } } if = { limit = { has_idea = depression } add_to_variable = { arab_spring_change = 6 } } else_if = { limit = { has_idea = recession } add_to_variable = { arab_spring_change = 4 } } else_if = { limit = { has_idea = stagnation } add_to_variable = { arab_spring_change = 2 } } } # Social Unrest Increases Arab Spring Likelihood if = { limit = { has_idea = social_01 } add_to_variable = { arab_spring_change = 3 } } else_if = { limit = { has_idea = social_02 } add_to_variable = { arab_spring_change = 2 } } else_if = { limit = { has_idea = social_03 } add_to_variable = { arab_spring_change = 1 } } else_if = { limit = { has_idea = social_04 } add_to_variable = { arab_spring_change = -1 } } else_if = { limit = { has_idea = social_05 } add_to_variable = { arab_spring_change = -2 } } else_if = { limit = { has_idea = social_06 } add_to_variable = { arab_spring_change = -3 } } # Healthcare Spending if = { limit = { has_idea = health_04 } add_to_variable = { arab_spring_change = -1 } } else_if = { limit = { has_idea = health_05 } add_to_variable = { arab_spring_change = -2 } } else_if = { limit = { has_idea = health_06 } add_to_variable = { arab_spring_change = -3 } } # Corruption Increases Arab Spring Likelihood if = { limit = { has_idea = corruption_level_10 } add_to_variable = { arab_spring_change = 6 } } else_if = { limit = { has_idea = corruption_level_09 } add_to_variable = { arab_spring_change = 5 } } else_if = { limit = { has_idea = corruption_level_08 } add_to_variable = { arab_spring_change = 4 } } else_if = { limit = { has_idea = corruption_level_07 } add_to_variable = { arab_spring_change = 3 } } else_if = { limit = { has_idea = corruption_level_06 } add_to_variable = { arab_spring_change = 2 } } else_if = { limit = { has_idea = corruption_level_05 } add_to_variable = { arab_spring_change = 1 } } else_if = { limit = { has_idea = corruption_level_03 } add_to_variable = { arab_spring_change = -1 } } else_if = { limit = { has_idea = corruption_level_02 } add_to_variable = { arab_spring_change = -2 } } else_if = { limit = { has_idea = corruption_level_01 } add_to_variable = { arab_spring_change = -3 } } # Historical Section if = { limit = { is_historical_focus_on = yes } if = { limit = { original_tag = TUN western_autocrats_are_in_power = yes } add_to_variable = { arab_spring_change = 9 } } else_if = { limit = { original_tag = SYR check_variable = { ruling_party = 7 } } add_to_variable = { arab_spring_change = 2 } } else_if = { limit = { original_tag = EGY western_autocrats_are_in_power = yes } add_to_variable = { arab_spring_change = 5 } } else_if = { limit = { original_tag = LBA check_variable = { ruling_party = 7 } NOT = { has_country_flag = AS_disabled_arab_spring } } add_to_variable = { arab_spring_change = 5 } } } # Shia Resistance Increases Arab Spring Likelihood if = { limit = { OR = { has_idea = shia_resistance_05 has_idea = shia_resistance_06 has_idea = shia_resistance_07 has_idea = shia_resistance_08 has_idea = shia_resistance_09 has_idea = shia_resistance_10 } } add_to_variable = { arab_spring_change = 2 } } if = { limit = { OR = { AND = { has_elections = yes OR = { has_government = democratic has_government = neutrality } NOT = { OR = { has_idea = hybrid_regime_emerging has_idea = hybrid_regime_western } } } has_idea = elected_legislature } } subtract_from_variable = { arab_spring_change = 4 } } if = { limit = { NOT = { has_tech = internet1 } } subtract_from_variable = { arab_spring_change = 4 } } if = { limit = { check_variable = { government_coalition_strength < 0.500 } } add_to_variable = { arab_spring_change = 2 } } else_if = { limit = { check_variable = { government_coalition_strength > 0.499 } check_variable = { government_coalition_strength < 0.599 } } add_to_variable = { arab_spring_change = -1 } } else_if = { limit = { check_variable = { government_coalition_strength > 0.599 } check_variable = { government_coalition_strength < 0.699 } } add_to_variable = { arab_spring_change = -2 } } else_if = { limit = { check_variable = { government_coalition_strength > 0.699 } check_variable = { government_coalition_strength < 0.799 } } add_to_variable = { arab_spring_change = -3 } } else_if = { limit = { check_variable = { government_coalition_strength > 0.799 } check_variable = { government_coalition_strength < 0.899 } } add_to_variable = { arab_spring_change = -4 } } else_if = { limit = { check_variable = { government_coalition_strength > 0.899 } } add_to_variable = { arab_spring_change = -5 } } } # Effect: increment_arab_spring_strength # Purpose: Increment the strength of the Arab Spring protests increment_arab_spring_strength = { calculate_monthly_arab_spring_change = yes set_temp_variable = { temp_strength = arab_spring_change } change_arab_spring_strength = yes } # Effect: Update social conservatism idea # Purpose: Updates the social conservatism idea for Arab nations update_social_conservatism_idea = { if = { limit = { check_variable = { social_conservatism_society > 90 } } if = { limit = { has_idea = conservative_society } swap_ideas = { remove_idea = conservative_society add_idea = extremely_conservative_society } } else_if = { limit = { has_idea = shia_conservative_society } swap_ideas = { remove_idea = shia_conservative_society add_idea = shia_extremely_conservative_society } } } else_if = { limit = { check_variable = { social_conservatism_society > 64 } } if = { limit = { has_idea = extremely_conservative_society } swap_ideas = { remove_idea = extremely_conservative_society add_idea = conservative_society } } else_if = { limit = { has_idea = shia_extremely_conservative_society } swap_ideas = { remove_idea = shia_extremely_conservative_society add_idea = shia_conservative_society } } } else_if = { limit = { check_variable = { social_conservatism_society > 49 } } if = { limit = { has_idea = conservative_society } swap_ideas = { remove_idea = conservative_society add_idea = moderately_conservative_society } } else_if = { limit = { has_idea = shia_conservative_society } swap_ideas = { remove_idea = shia_conservative_society add_idea = shia_moderately_conservative_society } } } else_if = { limit = { check_variable = { social_conservatism_society > 29 } } if = { limit = { has_idea = moderately_conservative_society } swap_ideas = { remove_idea = moderately_conservative_society add_idea = moderately_liberal_society } } else_if = { limit = { has_idea = shia_moderately_conservative_society } swap_ideas = { remove_idea = shia_moderately_conservative_society add_idea = shia_moderately_liberal_society } } } else_if = { limit = { check_variable = { social_conservatism_society > 9 } } if = { limit = { has_idea = moderately_liberal_society } swap_ideas = { remove_idea = moderately_liberal_society add_idea = liberal_society } } else_if = { limit = { has_idea = shia_moderately_liberal_society } swap_ideas = { remove_idea = shia_moderately_liberal_society add_idea = shia_liberal_society } } } else = { if = { limit = { has_idea = liberal_society } swap_ideas = { remove_idea = liberal_society add_idea = extremely_liberal_society } } else_if = { limit = { has_idea = shia_liberal_society } swap_ideas = { remove_idea = shia_liberal_society add_idea = shia_extremely_liberal_society } } } } # On Actions on_weekly_gcc_dominant_member_check = { # AI GCC members auto-endorse candidates they have positive relations with (so the invite can appear) if = { limit = { has_idea = idea_gcc_member_state is_ai = yes } if = { limit = { country_exists = EGY NOT = { has_country_flag = gcc_endorsed_EGY } EGY = { NOT = { has_idea = idea_gcc_member_state } } has_opinion = { target = EGY value > 0 } } set_country_flag = gcc_endorsed_EGY } if = { limit = { country_exists = JOR NOT = { has_country_flag = gcc_endorsed_JOR } JOR = { NOT = { has_idea = idea_gcc_member_state } } has_opinion = { target = JOR value > 0 } } set_country_flag = gcc_endorsed_JOR } if = { limit = { country_exists = MOR NOT = { has_country_flag = gcc_endorsed_MOR } MOR = { NOT = { has_idea = idea_gcc_member_state } } has_opinion = { target = MOR value > 0 } } set_country_flag = gcc_endorsed_MOR } if = { limit = { country_exists = IRQ NOT = { has_country_flag = gcc_endorsed_IRQ } IRQ = { NOT = { has_idea = idea_gcc_member_state } } has_opinion = { target = IRQ value > 0 } } set_country_flag = gcc_endorsed_IRQ } if = { limit = { country_exists = YEM NOT = { has_country_flag = gcc_endorsed_YEM } YEM = { NOT = { has_idea = idea_gcc_member_state } } has_opinion = { target = YEM value > 0 } } set_country_flag = gcc_endorsed_YEM } } if = { limit = { has_country_flag = gcc_dominant_member } # Gulf Cooperation Council Unity Additions if = { limit = { threat > 0.75 } add_to_variable = { global.gcc_unity = 0.75 } } else_if = { limit = { threat > 0.50 } add_to_variable = { global.gcc_unity = 0.50 } } else_if = { limit = { threat > 0.25 } add_to_variable = { global.gcc_unity = 0.25 } } clamp_variable = { var = global.gcc_unity min = 0 max = 100 } if = { limit = { has_idea = idea_gcc_member_state has_completed_focus = GCC_limited_unified_command NOT = { has_completed_focus = GCC_a_robust_alliance } is_in_faction = no has_defensive_war = yes all_enemy_country = { NOT = { has_idea = idea_gcc_member_state } } } create_faction_from_template = faction_template_gcc # Add to Faction for_each_scope_loop = { array = global.gcc_member_state PREV = { add_to_faction = PREV } } set_country_flag = gcc_formed } else_if = { limit = { NOT = { any_of_scopes = { array = global.gcc_member_state OR = { has_war = yes has_completed_focus = GCC_a_robust_alliance } } } any_of_scopes = { array = global.gcc_member_state has_war = no has_country_flag = gcc_formed } } if = { limit = { is_faction_leader = yes } dismantle_faction = yes } # Add to Faction for_each_scope_loop = { array = global.gcc_member_state if = { limit = { has_completed_focus = GCC_joint_defense_agreement } for_each_scope_loop = { array = global.gcc_member_state if = { limit = { NOT = { tag = ROOT } } give_guarantee = PREV } } } } } } } # Idempotent: always clears, then re-adds when both the refreshed country and the peer are MB. # Operates on the entry scope (saved as mb_origin) rather than ROOT, so it stays correct when # called from scope-changing loops (startup for_each_scope_loop, civil-war random_other_country). mb_refresh_relations_effect = { if = { limit = { is_in_array = { global.possible_muslim_brotherhood_nation = THIS.id } } save_event_target_as = mb_origin # Became MB — strip stale anti-MB state from when it was a suppressor if = { limit = { is_muslim_brotherhood = yes has_country_flag = mb_designated_terrorist } clr_country_flag = mb_designated_terrorist for_each_loop = { array = global.possible_muslim_brotherhood_nation value = v var:v = { if = { limit = { NOT = { tag = event_target:mb_origin } } remove_opinion_modifier = { target = event_target:mb_origin modifier = MB_branded_terrorist } remove_opinion_modifier = { target = event_target:mb_origin modifier = MB_counter_bloc } event_target:mb_origin = { remove_opinion_modifier = { target = PREV modifier = MB_counter_bloc } } } } } } if = { limit = { is_muslim_brotherhood = yes } for_each_loop = { array = global.possible_muslim_brotherhood_nation value = v var:v = { if = { limit = { NOT = { tag = event_target:mb_origin } } # It is now MB, so it can no longer be a crackdown patron or its target remove_opinion_modifier = { target = event_target:mb_origin modifier = MB_crackdown_patron } event_target:mb_origin = { remove_opinion_modifier = { target = PREV modifier = MB_crackdown_patron } } # Repression-funding modifiers v held against it-as-patron are stale remove_opinion_modifier = { target = event_target:mb_origin modifier = MB_funding_repression } } } } } # Lost MB status — strip the hub idea and bloc-side modifiers it acquired while MB if = { limit = { NOT = { is_muslim_brotherhood = yes } has_idea = muslim_brotherhood_faction_member } remove_ideas = muslim_brotherhood_faction_member } if = { limit = { NOT = { is_muslim_brotherhood = yes } } for_each_loop = { array = global.possible_muslim_brotherhood_nation value = v var:v = { if = { limit = { NOT = { tag = event_target:mb_origin } } # Bloc-solidarity and sponsor-of-network modifiers are stale once it is no longer MB remove_opinion_modifier = { target = event_target:mb_origin modifier = MB_solidarity } event_target:mb_origin = { remove_opinion_modifier = { target = PREV modifier = MB_solidarity } } remove_opinion_modifier = { target = event_target:mb_origin modifier = MB_sponsored_network } event_target:mb_origin = { remove_opinion_modifier = { target = PREV modifier = MB_sponsored_network } } # Subversion-funding modifiers v held against it-as-sponsor are stale remove_opinion_modifier = { target = event_target:mb_origin modifier = MB_funding_subversion } } } } } for_each_loop = { array = global.possible_muslim_brotherhood_nation value = v var:v = { if = { limit = { NOT = { tag = event_target:mb_origin } } remove_opinion_modifier = { target = event_target:mb_origin modifier = muslim_brotherhood_relations } event_target:mb_origin = { remove_opinion_modifier = { target = PREV modifier = muslim_brotherhood_relations } } if = { limit = { is_muslim_brotherhood = yes event_target:mb_origin = { is_muslim_brotherhood = yes } } add_opinion_modifier = { target = event_target:mb_origin modifier = muslim_brotherhood_relations } reverse_add_opinion_modifier = { target = event_target:mb_origin modifier = muslim_brotherhood_relations } } } } } } } # Entry scope (saved as mb_origin) = country adding the crackdown idea mb_apply_crackdown_opinions_effect = { save_event_target_as = mb_origin set_temp_variable = { temp_opinion = -8 } change_the_ulema_opinion = yes set_temp_variable = { temp_opinion = 5 } change_the_wahabi_ulema_opinion = yes for_each_loop = { array = global.possible_muslim_brotherhood_nation value = v var:v = { if = { limit = { NOT = { tag = event_target:mb_origin } is_muslim_brotherhood = yes } event_target:mb_origin = { add_opinion_modifier = { target = PREV modifier = is_cracking_down_on_muslim_brotherhood } } add_opinion_modifier = { target = event_target:mb_origin modifier = is_muslim_brotherhood_negative } } } } for_each_loop = { array = global.crackdown_countries value = v var:v = { if = { limit = { NOT = { tag = event_target:mb_origin } } add_opinion_modifier = { target = event_target:mb_origin modifier = is_cracking_down_on_muslim_brotherhood_positive } event_target:mb_origin = { add_opinion_modifier = { target = PREV modifier = is_cracking_down_on_muslim_brotherhood_positive } } } } } event_target:mb_origin = { add_to_array = { global.crackdown_countries = THIS.id } } } # Entry scope (saved as mb_origin) = country removing the crackdown idea mb_remove_crackdown_opinions_effect = { save_event_target_as = mb_origin event_target:mb_origin = { remove_from_array = { global.crackdown_countries = THIS.id } } set_temp_variable = { temp_opinion = 8 } change_the_ulema_opinion = yes set_temp_variable = { temp_opinion = -5 } change_the_wahabi_ulema_opinion = yes for_each_loop = { array = global.possible_muslim_brotherhood_nation value = v var:v = { if = { limit = { NOT = { tag = event_target:mb_origin } } event_target:mb_origin = { remove_opinion_modifier = { target = PREV modifier = is_cracking_down_on_muslim_brotherhood } } remove_opinion_modifier = { target = event_target:mb_origin modifier = is_muslim_brotherhood_negative } } } } for_each_loop = { array = global.crackdown_countries value = v var:v = { remove_opinion_modifier = { target = event_target:mb_origin modifier = is_cracking_down_on_muslim_brotherhood_positive } event_target:mb_origin = { remove_opinion_modifier = { target = PREV modifier = is_cracking_down_on_muslim_brotherhood_positive } } } } } # United Arabic Republic update_arabic_country_gdp_total_effect = { set_variable = { global.total_arabic_gdp = { value = 0 every_collection = { named_collection = arabic_nations_collection add = THIS.gdp_total } } } set_variable = { total_uar_gdp = { value = 0 every_collection = { named_collection = country_and_all_subjects_collection add = THIS.gdp_total } } } set_variable = { gdp_share = { value = total_uar_gdp divide = { value = global.total_arabic_gdp max = 1 } } } }