diff --git a/common/casus_belli_types/00_civil_war.txt b/common/casus_belli_types/00_civil_war.txt index 4175534cd0..00f05d8885 100644 --- a/common/casus_belli_types/00_civil_war.txt +++ b/common/casus_belli_types/00_civil_war.txt @@ -241,7 +241,7 @@ independence_faction_war = { value = medium_prestige_value multiply = -1 } - + # Warcraft decrease_any_authority_effect = yes } @@ -286,9 +286,9 @@ independence_faction_war = { scope:attacker = { show_pow_release_message_effect = yes stress_impact = { - ambitious = medium_stress_impact_gain - arrogant = medium_stress_impact_gain - } + ambitious = medium_stress_impact_gain + arrogant = medium_stress_impact_gain + } } hidden_effect = { scope:attacker = { @@ -303,8 +303,8 @@ independence_faction_war = { scope:defender = { stress_impact = { - arrogant = medium_stress_impact_gain - } + arrogant = medium_stress_impact_gain + } add_character_flag = { flag = recent_independence_faction_war @@ -391,7 +391,7 @@ independence_faction_war = { max_attacker_score_from_battles = 100 max_defender_score_from_battles = 50 - + max_defender_score_from_occupation = 150 max_attacker_score_from_occupation = 150 @@ -441,15 +441,15 @@ liberty_faction_war = { #EP2 Accolade glory gain from winning against higher ranked enemy scope:attacker = { accolade_attacker_war_end_glory_gain_med_effect = yes } - + # LEGITIMACY FROM LOSING FACTION WAR faction_war_end_defeat_legitimacy_effect = yes - + scope:defender = { # Warcraft decrease_any_authority_effect = yes - + add_prestige = -500 every_character_war = { @@ -540,9 +540,9 @@ liberty_faction_war = { scope:attacker = { show_pow_release_message_effect = yes stress_impact = { - ambitious = medium_stress_impact_gain - arrogant = medium_stress_impact_gain - } + ambitious = medium_stress_impact_gain + arrogant = medium_stress_impact_gain + } } hidden_effect = { scope:attacker = { @@ -556,8 +556,8 @@ liberty_faction_war = { } scope:defender = { stress_impact = { - arrogant = medium_stress_impact_gain - } + arrogant = medium_stress_impact_gain + } add_character_flag = { flag = recent_liberty_faction_war years = faction_war_white_peace_cooldown @@ -624,7 +624,7 @@ liberty_faction_war = { max_attacker_score_from_battles = 100 max_defender_score_from_battles = 50 - + max_defender_score_from_occupation = 150 max_attacker_score_from_occupation = 150 @@ -682,7 +682,7 @@ populist_war = { on_victory_desc = { desc = populist_war_victory_desc - + } on_victory = { @@ -753,16 +753,16 @@ populist_war = { on_white_peace_desc = { desc = populist_war_white_peace_desc - + } on_white_peace = { scope:attacker = { show_pow_release_message_effect = yes stress_impact = { - ambitious = medium_stress_impact_gain - arrogant = medium_stress_impact_gain - } + ambitious = medium_stress_impact_gain + arrogant = medium_stress_impact_gain + } } on_white_peace_faction_revolt_war = yes hidden_effect = { @@ -802,7 +802,7 @@ populist_war = { on_defeat_desc = { desc = populist_war_defeat_desc - + } on_defeat = { @@ -878,7 +878,7 @@ populist_war = { max_attacker_score_from_battles = 100 max_defender_score_from_battles = 50 - + max_defender_score_from_occupation = 150 max_attacker_score_from_occupation = 150 @@ -974,15 +974,15 @@ claimant_faction_war = { scope:attacker = { show_pow_release_message_effect = yes stress_impact = { - ambitious = medium_stress_impact_gain - arrogant = medium_stress_impact_gain - } + ambitious = medium_stress_impact_gain + arrogant = medium_stress_impact_gain + } } scope:defender = { stress_impact = { - arrogant = medium_stress_impact_gain - } + arrogant = medium_stress_impact_gain + } } on_white_peace_faction_revolt_war = yes @@ -1042,7 +1042,7 @@ claimant_faction_war = { max_attacker_score_from_battles = 50 max_defender_score_from_battles = 100 - + max_defender_score_from_occupation = 150 max_attacker_score_from_occupation = 150 @@ -1178,14 +1178,14 @@ depose_war = { scope:attacker = { show_pow_release_message_effect = yes stress_impact = { - ambitious = medium_stress_impact_gain - arrogant = medium_stress_impact_gain - } + ambitious = medium_stress_impact_gain + arrogant = medium_stress_impact_gain + } } scope:defender = { stress_impact = { - arrogant = medium_stress_impact_gain - } + arrogant = medium_stress_impact_gain + } } on_white_peace_faction_revolt_war = yes } @@ -1236,7 +1236,7 @@ depose_war = { defender_score_from_occupation_scale = 50 max_attacker_score_from_battles = 100 max_defender_score_from_battles = 100 - + max_defender_score_from_occupation = 150 max_attacker_score_from_occupation = 150 @@ -1395,15 +1395,15 @@ refused_liege_demand_war = { scope:attacker = { show_pow_release_message_effect = yes stress_impact = { - ambitious = medium_stress_impact_gain - arrogant = medium_stress_impact_gain - } + ambitious = medium_stress_impact_gain + arrogant = medium_stress_impact_gain + } } scope:defender = { stress_impact = { - arrogant = medium_stress_impact_gain - } + arrogant = medium_stress_impact_gain + } } hidden_effect = { scope:attacker = { @@ -1459,7 +1459,7 @@ refused_liege_demand_war = { } } } - + on_lost_request_revolt_war = yes } @@ -1485,7 +1485,7 @@ refused_liege_demand_war = { max_attacker_score_from_battles = 100 max_defender_score_from_battles = 50 - + max_defender_score_from_occupation = 150 max_attacker_score_from_occupation = 150 @@ -1644,9 +1644,9 @@ independence_war = { scope:attacker = { show_pow_release_message_effect = yes stress_impact = { - ambitious = medium_stress_impact_gain - arrogant = medium_stress_impact_gain - } + ambitious = medium_stress_impact_gain + arrogant = medium_stress_impact_gain + } } hidden_effect = { scope:attacker = { @@ -1662,8 +1662,8 @@ independence_war = { scope:defender = { add_prestige = minor_prestige_value stress_impact = { - arrogant = medium_stress_impact_gain - } + arrogant = medium_stress_impact_gain + } } } @@ -1733,7 +1733,7 @@ independence_war = { max_attacker_score_from_battles = 100 max_defender_score_from_battles = 50 - + max_defender_score_from_occupation = 150 max_attacker_score_from_occupation = 150 @@ -1794,7 +1794,7 @@ nation_fracturing_faction_war = { #EP2 Accolade glory gain from winning against higher ranked enemy scope:attacker = { accolade_attacker_war_end_glory_gain_med_effect = yes } - + create_title_and_vassal_change = { type = independency save_scope_as = change @@ -1863,9 +1863,9 @@ nation_fracturing_faction_war = { limit = { is_ai = no } send_interface_toast = { type = event_generic_neutral - title = liege_primary_title_dissolution - desc = liege_primary_title_dissolution_desc - left_icon = scope:defender + title = liege_primary_title_dissolution + desc = liege_primary_title_dissolution_desc + left_icon = scope:defender } } } @@ -1914,9 +1914,9 @@ nation_fracturing_faction_war = { scope:attacker = { show_pow_release_message_effect = yes stress_impact = { - ambitious = medium_stress_impact_gain - arrogant = medium_stress_impact_gain - } + ambitious = medium_stress_impact_gain + arrogant = medium_stress_impact_gain + } } hidden_effect = { scope:attacker = { @@ -1931,8 +1931,8 @@ nation_fracturing_faction_war = { scope:defender = { stress_impact = { - arrogant = medium_stress_impact_gain - } + arrogant = medium_stress_impact_gain + } add_character_flag = { flag = recent_nation_fracturing_faction_war @@ -2004,7 +2004,7 @@ nation_fracturing_faction_war = { max_attacker_score_from_battles = 100 max_defender_score_from_battles = 50 - + max_defender_score_from_occupation = 150 max_attacker_score_from_occupation = 150 diff --git a/common/casus_belli_types/wc_genocide_wars.txt b/common/casus_belli_types/wc_genocide_wars.txt new file mode 100644 index 0000000000..b709b6c4c1 --- /dev/null +++ b/common/casus_belli_types/wc_genocide_wars.txt @@ -0,0 +1,211 @@ +committed_genocide_war = { + group = invasion + ai = yes + + combine_into_one = yes + + allowed_for_character = { always = yes } + + allowed_against_character = { + OR = { + genocide_cb_can_avenge_culture = yes + genocide_cb_can_avenge_faith = yes + } + } + + target_titles = none + target_de_jure_regions_above = yes + + valid_to_start = { always = yes } + + ai_score_mult = { + value = 1 + + if = { + limit = { + genocide_cb_can_avenge_faith = yes + scope:attacker = { + has_trait = zealous + } + } + + add = 1 + } + } + + should_invalidate = { + NOT = { + OR = { + genocide_cb_can_avenge_culture = yes + genocide_cb_can_avenge_faith = yes + } + } + } + + on_invalidated_desc = msg_committed_genocide_invalid_message + + on_invalidated = { + + } + + cost = { + prestige = { + value = 0 + add = { + value = genocide_cb_prestige_cost + desc = CB_BASE_COST + } + } + piety = { + value = 0 + add = { + value = genocide_cb_piety_cost + desc = CB_BASE_COST + } + } + } + + on_declaration = { + on_declared_war = yes + + if = { # Vassals of the same culture approve of defending your culture + limit = { + genocide_cb_can_avenge_culture = yes + } + + scope:attacker = { + every_vassal_or_below = { + limit = { + culture = scope:attacker.culture + } + + add_opinion = { + target = scope:attacker + modifier = vassal_approves_of_defending_genocide_opinion + } + } + } + } + + if = { # Vassals of the same faith approve of defending your faith + limit = { + genocide_cb_can_avenge_faith = yes + } + + scope:attacker = { + every_vassal_or_below = { + limit = { + faith = scope:attacker.faith + } + + add_opinion = { + target = scope:attacker + modifier = vassal_approves_of_defending_genocide_opinion + } + } + } + } + } + + on_victory = { + scope:attacker = { + show_pow_release_message_effect = yes + accolade_attacker_war_end_glory_gain_med_effect = yes + } + + create_title_and_vassal_change = { + type = conquest + save_scope_as = change + add_claim_on_loss = yes + } + + add_genocide_cb_rewards = { OUTCOME = flag:win PRESTIGE_BASE_VALUE = medium_prestige_value PIETY_BASE_VALUE = medium_piety_value } + + resolve_title_and_vassal_change = scope:change + + # Legitimacy + add_legitimacy_attacker_victory_effect = yes + + # Truce + add_truce_attacker_victory_effect = yes + + # FP1: note the victory for future memorialisation via stele (if applicable). + scope:attacker = { fp1_remember_recent_conquest_victory_effect = yes } + } + + on_victory_desc = { + first_valid = { + triggered_desc = { + trigger = { scope:attacker = { is_local_player = yes } } + desc = committed_genocide_cb_victory_desc_attacker + } + desc = committed_genocide_cb_victory_desc + } + } + + on_white_peace = { + scope:attacker = { show_pow_release_message_effect = yes } + + add_genocide_cb_rewards = { OUTCOME = flag:white_peace PRESTIGE_BASE_VALUE = medium_prestige_value PIETY_BASE_VALUE = medium_piety_value } + + add_truce_white_peace_effect = yes + } + + on_white_peace_desc = { + first_valid = { + triggered_desc = { + trigger = { scope:defender = { is_local_player = yes } } + desc = committed_genocide_cb_white_peace_desc_defender + } + desc = committed_genocide_cb_white_peace_desc + } + } + + on_defeat = { + scope:attacker = { show_pow_release_message_effect = yes } + + # Legitimacy + add_legitimacy_attacker_defeat_effect = yes + + scope:defender = { + #EP2 accolade glory gain for winning against higher ranked enemy + accolade_defender_war_end_glory_gain_med_effect = yes + } + + add_genocide_cb_rewards = { OUTCOME = flag:loss PRESTIGE_BASE_VALUE = medium_prestige_value PIETY_BASE_VALUE = medium_piety_value } + + add_truce_attacker_defeat_effect = yes + + scope:attacker = { + save_temporary_scope_as = loser + } + on_lost_aggression_war_discontent_loss = yes + } + + on_defeat_desc = { + first_valid = { + triggered_desc = { + trigger = { scope:defender = { is_local_player = yes } } + desc = committed_genocide_cb_defeat_desc_defender + } + desc = committed_genocide_cb_defeat_desc + } + } + + on_primary_attacker_death = inherit + on_primary_defender_death = inherit + transfer_behavior = transfer + + check_attacker_inheritance_validity = yes + check_defender_inheritance_validity = yes + + attacker_allies_inherit = yes + defender_allies_inherit = yes + + war_name = "GENOCIDE_WAR_NAME" + cb_name = "GENOCIDE_WAR_CB_NAME" + interface_priority = 98 #Below take all and regular dejure. + + max_ai_diplo_distance_to_title = 500 + +} \ No newline at end of file diff --git a/common/council_tasks/wc_genocide_councilor_tasks.txt b/common/council_tasks/wc_genocide_councilor_tasks.txt new file mode 100644 index 0000000000..465a7b195e --- /dev/null +++ b/common/council_tasks/wc_genocide_councilor_tasks.txt @@ -0,0 +1,662 @@ +task_purge_population = { + position = councillor_marshal + + task_type = task_type_county + county_target = realm + ai_county_target = realm + task_progress = task_progress_value + task_current_value = scope:councillor_liege.marshal_purge_population_current_progress + task_max_value = marshal_purge_population_threshold + highlight_own_realm = yes + restart_on_finish = no + + effect_desc = { + desc = task_purge_population_effect_desc + triggered_desc = { + trigger = { + scope:councillor_liege = { can_corrupt_trigger = yes } + } + desc = task_purge_population_effect_corrupt_desc + } + triggered_desc = { + trigger = { scope:councillor_liege = { government_has_flag = government_dark_frenzy_from_conversions } } + desc = task_dark_frenzy_gain + } + triggered_desc = { + trigger = { + scope:councillor_liege = { + any_vassal = { + has_vassal_stance = minority + } + } + } + desc = minority_disapproves_genocide_tooltip + } + + desc = { + desc = council_task_possible_side_effects + # Corrupt + triggered_desc = { + trigger = { + scope:councillor_liege ?= { + can_corrupt_trigger = yes + } + scope:councillor ?= { + martial < high_skill_rating + } + } + desc = council_task_cursed_lands + } + triggered_desc = { + trigger = { + scope:councillor_liege ?= { + can_corrupt_trigger = yes + } + scope:councillor ?= { + martial < high_skill_rating + } + } + desc = council_task_marauders + } + triggered_desc = { + trigger = { + scope:councillor_liege ?= { + can_corrupt_trigger = yes + + cp:councillor_court_chaplain ?= { + learning > mediocre_skill_rating + } + } + scope:councillor ?= { + martial >= high_skill_rating + } + } + desc = council_task_devotion_demonstration + } + triggered_desc = { + trigger = { + scope:councillor_liege ?= { + can_corrupt_trigger = yes + } + scope:councillor ?= { + martial >= high_skill_rating + } + } + desc = council_task_harness_energy + } + + # Cleanse + triggered_desc = { + trigger = { + scope:councillor_liege ?= { + can_corrupt_trigger = no + } + scope:councillor ?= { + martial < high_skill_rating + } + scope:county ?= { + has_county_modifier = ongoing_cleansing_modifier + } + } + desc = council_task_champion_challenge + } + triggered_desc = { + trigger = { + scope:councillor_liege ?= { + can_corrupt_trigger = no + } + scope:councillor ?= { + martial < high_skill_rating + } + scope:county ?= { + has_county_modifier = ongoing_cleansing_modifier + } + } + desc = council_task_wild_energy + } + triggered_desc = { + trigger = { + scope:councillor_liege ?= { + can_corrupt_trigger = no + } + scope:councillor ?= { + martial >= high_skill_rating + } + scope:county ?= { + has_county_modifier = ongoing_cleansing_modifier + } + } + desc = council_task_army_spawn + } + triggered_desc = { + trigger = { + scope:councillor_liege ?= { + can_corrupt_trigger = no + } + scope:councillor ?= { + martial >= high_skill_rating + } + scope:county ?= { + has_county_modifier = ongoing_cleansing_modifier + } + } + desc = council_task_large_raid + } + + # Purge + triggered_desc = { + trigger = { + scope:councillor_liege ?= { + can_corrupt_trigger = no + } + scope:councillor ?= { + martial < high_skill_rating + } + OR = { + NOT = { + exists = scope:county + } + scope:county ?= { + NOT = { + has_county_modifier = ongoing_cleansing_modifier + } + } + } + } + desc = council_task_neighboring_unrest + } + triggered_desc = { + trigger = { + scope:councillor_liege ?= { + can_corrupt_trigger = no + } + scope:councillor ?= { + martial < high_skill_rating + } + OR = { + NOT = { + exists = scope:county + } + scope:county ?= { + NOT = { + has_county_modifier = ongoing_cleansing_modifier + } + } + } + } + desc = council_task_emigration + } + triggered_desc = { + trigger = { + scope:councillor_liege ?= { + can_corrupt_trigger = no + } + scope:councillor ?= { + martial >= high_skill_rating + } + OR = { + NOT = { + exists = scope:county + } + scope:county ?= { + NOT = { + has_county_modifier = ongoing_cleansing_modifier + } + } + } + } + desc = council_task_friendly_champion + } + triggered_desc = { + trigger = { + scope:councillor_liege ?= { + can_corrupt_trigger = no + } + scope:councillor ?= { + martial >= high_skill_rating + } + OR = { + NOT = { + exists = scope:county + } + scope:county ?= { + NOT = { + has_county_modifier = ongoing_cleansing_modifier + } + } + } + } + desc = council_task_found_supplies + } + } + } + + progress = { + value = 0 + add = { + value = marshal_purge_population_base_total + desc = INCREASE_CONTROL_BASE + } + + add = { + value = marshal_purge_population_skill_bonus + desc = SCALED_COUNCILLOR_MARTIAL_VALUE + } + + # Relation Bonuses/Penalties + if = { # Friend + limit = { + scope:councillor_liege = { + has_relation_friend = scope:councillor + NOT = { has_relation_best_friend = scope:councillor } + } + } + add = { + value = scope:councillor.marshal_purge_population_monthly_increase_friend_bonus + desc = COUNCILLOR_IS_YOUR_FRIEND + } + } + if = { # Best Friend + limit = { + scope:councillor_liege = { + has_relation_best_friend = scope:councillor + } + } + add = { + value = scope:councillor.marshal_purge_population_monthly_increase_best_friend_bonus + desc = COUNCILLOR_IS_YOUR_BEST_FRIEND + } + } + if = { # Rival + limit = { + scope:councillor_liege = { + has_relation_rival = scope:councillor + NOT = { has_relation_nemesis = scope:councillor } + } + } + add = { + value = scope:councillor.marshal_purge_population_monthly_increase_rival_bonus + desc = COUNCILLOR_IS_YOUR_RIVAL + } + } + if = { # Nemesis + limit = { + scope:councillor_liege = { + has_relation_nemesis = scope:councillor + } + } + add = { + value = scope:councillor.marshal_purge_population_monthly_increase_nemesis_bonus + desc = COUNCILLOR_IS_YOUR_NEMESIS + } + } + + #Partially completed bonuses + if = { # Same culture + limit = { + scope:county = { + culture = scope:councillor_liege.culture + } + } + add = { + value = scope:councillor.marshal_purge_population_monthly_increase_same_culture_bonus + desc = COUNTY_IS_YOUR_CULTURE + } + } + if = { # Same faith + limit = { + scope:county = { + faith = scope:councillor_liege.faith + + NOT = { + has_variable = false_convert + } + } + } + add = { + value = scope:councillor.marshal_purge_population_monthly_increase_same_faith_bonus + desc = COUNTY_IS_YOUR_FAITH + } + } + if = { # Has corruption modifier + limit = { + scope:councillor_liege = { + can_corrupt_trigger = yes + } + scope:county = { + has_beneficial_corruption_this_province_trigger = yes + } + } + add = { + value = scope:councillor.marshal_purge_population_monthly_increase_already_corrupted_bonus + DESC = COUNTY_ALREADY_CORRUPTED + } + } + + # bonus for army strength when armies are unraised + if = { + limit = { + scope:councillor_liege = { has_raised_armies = no } + } + + add = { + value = scope:councillor.marshal_purge_population_monthly_increase_unraised_army_bonus + desc = GENOCIDE_ARMY_STRENGTH_BONUS + } + } + + # Sacrificed cleanse speed bonus + if = { + limit = { + scope:councillor_liege = { + has_character_modifier = sacrificed_cleansing_targets_modifier + } + } + + add = { + value = scope:councillor.marshal_purge_population_monthly_increase_sacrifice_bonus + desc = GENOCIDE_SACRIFICE_BONUS + } + } + + # Local champion purge speed bonus + if = { + limit = { + scope:councillor_liege = { + has_character_modifier = genocide_local_champion_modifier + } + } + + add = { + value = scope:councillor.marshal_purge_population_monthly_increase_champion_bonus + desc = GENOCIDE_CHAMPION_BONUS + } + } + + # Fervor bonus + if = { + limit = { + scope:county = { + allow_genocide_this_province_religion_trigger = { CHARACTER = scope:councillor_liege } + } + } + add = { + value = scope:councillor.marshal_purge_population_monthly_increase_fervor_penalty + DESC = MARSHAL_GENOCIDE_FERVOR_IMPACT + } + } + + # Development reduces the speed. Should be the last non-multiply modifier applied to avoid negative values + if = { + limit = { + exists = scope:county + scope:county = { + development_level > 0 + } + } + add = { + value = scope:county.marshal_purge_population_monthly_increase_development_penalty + desc = STEWARD_PROMOTE_CULTURE_DEVELOPMENT_PENALTY + } + } + + if = { + limit = { + exists = scope:county + scope:county = { + OR = { + allow_genocide_this_province_culture_trigger = { CHARACTER = scope:councillor_liege } + allow_genocide_this_province_religion_trigger = { CHARACTER = scope:councillor_liege } + } + NOT = { + marshal_purge_population_game_rule_mult = 1 + } + } + } + multiply = { + value = marshal_purge_population_game_rule_mult + desc = FROM_CONVERSION_SPEED_GAME_RULE + } + } + } + + potential_county = { + scope:county = { + trigger_if = { + limit = { + NOT = { + county_controller = holder + } + } + + county_controller = { + OR = { + is_liege_or_above_of = scope:county.holder + is_vassal_or_below_of = scope:county.holder + } + } + } + trigger_if = { + limit = { + scope:councillor_liege = { + can_corrupt_trigger = yes + } + } + + allow_corrupt_this_province_trigger = yes + } + trigger_else_if = { + limit = { + allow_cleanse_this_province_trigger = yes + } + always = yes + } + trigger_else = { + OR = { + allow_genocide_this_province_trigger = yes + } + } + } + } + + on_start_task_county = { + scope:county = { + if = { + limit = { + allow_corrupt_this_province_trigger = yes + } + + add_county_modifier = ongoing_corruption_modifier + } + else_if = { + limit = { + allow_cleanse_this_province_trigger = yes + } + + add_county_modifier = ongoing_cleansing_modifier + } + else = { + add_county_modifier = ongoing_genocide_modifier + } + } + } + + on_cancel_task_county = { + scope:county = { + remove_genocide_modifiers = yes + } + } + + on_finish_task_county = { + scope:county = { + set_variable = { + name = finished_genocide + } + if = { + limit = { + has_county_modifier = ongoing_corruption_modifier + } + + scope:councillor_liege = { + trigger_event = genocide_task.2001 + } + } + else_if = { + limit = { + has_county_modifier = ongoing_cleansing_modifier + } + + scope:councillor_liege = { + trigger_event = genocide_task.2101 + } + } + else = { + scope:councillor_liege = { + trigger_event = genocide_task.2201 + } + } + } + + scope:councillor = { + start_default_task = yes + } + } + + on_monthly_county = { + if = { + limit = { + NOT = { + scope:county ?= { + has_variable = purge_population_current_progress + } + } + } + + scope:county = { + set_variable = { + name = purge_population_current_progress + value = 0 + } + } + } + + scope:county = { + change_variable = { + name = purge_population_current_progress + add = marshal_purge_population_total + } + } + + + scope:councillor_liege = { # monthly_on_action doesn't work + trigger_event = { + on_action = task_purge_population_side_effects + } + } + } + + ai_target_score = { + value = 20 + + if = { + limit = { + scope:councillor_liege = { + can_corrupt_trigger = yes + } + scope:county = { + has_beneficial_corruption_this_province_trigger = no + } + } + + add = 100 + } + + if = { + limit = { # Only factor in opinion if genocide, not cleanse or corrupt + scope:councillor_liege = { + can_corrupt_trigger = no + } + scope:county = { + allow_cleanse_this_province_trigger = no + } + } + scope:councillor_liege = { # Only genocide if bad opinion of holder + add = { + value = "opinion(scope:county.holder)" + multiply = -1 + } + } + } + + if = { + limit = { # AI shouldn't genocide parent/child culture + scope:county = { + allow_genocide_this_province_parent_culture_trigger = no + } + } + + multiply = 0 + } + } + + ai_will_do = { + value = 0 + + if = { + limit = { + scope:councillor = { + is_performing_council_task = task_purge_population + } + } + add = 10000 # Always keep going if this is already chosen + } + else_if = { + limit = { + scope:councillor_liege = { + can_corrupt_trigger = yes + } + } + add = 1000 + } + else_if = { + limit = { + scope:councillor_liege = { + any_sub_realm_county = { + allow_cleanse_this_province_trigger = yes + } + } + } + add = 1000 + } + else = { + add = { + value = ai_zeal + } + add = { + value = ai_greed + } + add = { + value = ai_compassion + multiply = -1 + } + add = { + value = ai_honor + multiply = -1 + } + } + + if = { + # Don't do this too often + limit = { + scope:councillor_liege = { + has_character_flag = no_ai_genocide + } + } + multiply = 0 + } + } + +} +# task_relocate_population = { +# +# } \ No newline at end of file diff --git a/common/customizable_localization/wc_genocide_custom_loc.txt b/common/customizable_localization/wc_genocide_custom_loc.txt new file mode 100644 index 0000000000..e6e00fbc11 --- /dev/null +++ b/common/customizable_localization/wc_genocide_custom_loc.txt @@ -0,0 +1,298 @@ +TaskPurgePopulationTitle = { + type = character + text = { + localization_key = TaskPurgePopulationTitle_Corrupt + trigger = { + can_corrupt_trigger = yes + } + } + text = { + localization_key = TaskPurgePopulationTitle_Purge + fallback = yes + } +} + +GenocideEventRelevantMagic = { + type = character + text = { + localization_key = GenocideEventRelevantMagic_Light + trigger = { + can_corrupt_specific_trigger = { BEING = being_light MAGIC = light } + } + fallback = yes + } + text = { + localization_key = GenocideEventRelevantMagic_Void + trigger = { + can_corrupt_specific_trigger = { BEING = being_void MAGIC = shadow } + } + } + text = { + localization_key = GenocideEventRelevantMagic_Arcane + trigger = { + can_corrupt_specific_trigger = { BEING = being_order MAGIC = order } + } + } + text = { + localization_key = GenocideEventRelevantMagic_Fel + trigger = { + can_corrupt_specific_trigger = { BEING = being_demon MAGIC = disorder } + } + } + text = { + localization_key = GenocideEventRelevantMagic_Life + trigger = { + can_corrupt_specific_trigger = { BEING = being_life MAGIC = life } + } + } + text = { + localization_key = GenocideEventRelevantMagic_Death + trigger = { + can_corrupt_specific_trigger = { BEING = being_undead MAGIC = death } + } + } +} + +GenocideEventRelevantCountyMagic = { + type = landed_title + text = { + localization_key = GenocideEventRelevantMagic_Light + trigger = { + has_county_modifier = county_corruption_light_modifier + } + fallback = yes + } + text = { + localization_key = GenocideEventRelevantMagic_Void + trigger = { + has_county_modifier = county_corruption_void_modifier + } + } + text = { + localization_key = GenocideEventRelevantMagic_Arcane + trigger = { + has_county_modifier = county_corruption_arcane_modifier + } + } + text = { + localization_key = GenocideEventRelevantMagic_Fel + trigger = { + has_county_modifier = county_corruption_fel_modifier + } + } + text = { + localization_key = GenocideEventRelevantMagic_Life + trigger = { + has_county_modifier = county_corruption_life_modifier + } + } + text = { + localization_key = GenocideEventRelevantMagic_Death + trigger = { + has_county_modifier = county_corruption_death_modifier + } + } +} + +GenocideEventRelevantGod = { + type = character + text = { + localization_key = GenocideEventRelevantGod_FaithGod + trigger = { + evil_public_religion_trigger = yes + faith = { + OR = { + has_doctrine = doctrine_light_magic_approved + has_doctrine = doctrine_shadow_magic_approved + has_doctrine = doctrine_order_magic_approved + has_doctrine = doctrine_disorder_magic_approved + has_doctrine = doctrine_life_magic_approved + has_doctrine = doctrine_death_magic_approved + } + } + } + fallback = yes + } + text = { + localization_key = GenocideEventRelevantGod_Light + trigger = { + has_trait = being_light + } + } + text = { + localization_key = GenocideEventRelevantGod_Void + trigger = { + has_trait = being_void + } + } + text = { + localization_key = GenocideEventRelevantGod_Arcane + trigger = { + has_trait = being_order + } + } + text = { + localization_key = GenocideEventRelevantGod_Fel + trigger = { + has_trait = being_demon + } + } + text = { + localization_key = GenocideEventRelevantGod_Life + trigger = { + has_trait = being_life + } + } + text = { + localization_key = GenocideEventRelevantGod_Death + trigger = { + has_trait = being_undead + } + } +} + +GenocideEventRelevantPower = { + type = character + text = { + localization_key = GenocideEventRelevantPower_Holy + trigger = { + OR = { + can_corrupt_specific_trigger = { BEING = being_light MAGIC = light } + can_corrupt_specific_trigger = { BEING = being_life MAGIC = life } + } + } + fallback = yes + } + text = { + localization_key = GenocideEventRelevantPower_Dark + trigger = { + OR = { + can_corrupt_specific_trigger = { BEING = being_void MAGIC = shadow } + can_corrupt_specific_trigger = { BEING = being_demon MAGIC = disorder } + can_corrupt_specific_trigger = { BEING = being_undead MAGIC = death } + } + } + } + text = { + localization_key = GenocideEventRelevantPower_Arcane + trigger = { + can_corrupt_specific_trigger = { BEING = being_order MAGIC = order } + } + } +} + +GenocideEventRelevantName = { + type = character + text = { + localization_key = GenocideEventRelevantName_Hallowed + trigger = { + OR = { + can_corrupt_specific_trigger = { BEING = being_light MAGIC = light } + can_corrupt_specific_trigger = { BEING = being_life MAGIC = life } + can_corrupt_specific_trigger = { BEING = being_order MAGIC = order } + } + } + fallback = yes + } + text = { + localization_key = GenocideEventRelevantName_Unholy + trigger = { + OR = { + can_corrupt_specific_trigger = { BEING = being_void MAGIC = shadow } + can_corrupt_specific_trigger = { BEING = being_demon MAGIC = disorder } + can_corrupt_specific_trigger = { BEING = being_undead MAGIC = death } + } + } + } +} + +GenocideEventRelevantNameCounty = { + type = landed_title + text = { + localization_key = GenocideEventRelevantName_Hallowed + trigger = { + OR = { + has_county_modifier = county_corruption_light_modifier + has_county_modifier = county_corruption_arcane_modifier + has_county_modifier = county_corruption_life_modifier + } + } + fallback = yes + } + text = { + localization_key = GenocideEventRelevantName_Unholy + trigger = { + OR = { + has_county_modifier = county_corruption_void_modifier + has_county_modifier = county_corruption_fel_modifier + has_county_modifier = county_corruption_death_modifier + } + } + } +} + +GenocideEventGenocidedPopulationsOr = { + type = character + + text = { + localization_key = GenocideEventGenocidedPopulationsOr_Both + trigger = { + scope:second = { + allow_genocide_this_province_culture_trigger = { CHARACTER = root } + allow_genocide_this_province_religion_trigger = { CHARACTER = root } + } + } + fallback = yes + } + + text = { + localization_key = GenocideEventGenocidedPopulations_Culture + trigger = { + scope:second = { + allow_genocide_this_province_culture_trigger = { CHARACTER = root } + } + } + } + + text = { + localization_key = GenocideEventGenocidedPopulations_Faith + trigger = { + scope:second = { + allow_genocide_this_province_religion_trigger = { CHARACTER = root } + } + } + } +} + +GenocideEventGenocidedPopulationsAnd = { + type = character + + text = { + localization_key = GenocideEventGenocidedPopulationsAnd_Both + trigger = { + scope:second = { + allow_genocide_this_province_culture_trigger = { CHARACTER = root } + allow_genocide_this_province_religion_trigger = { CHARACTER = root } + } + } + fallback = yes + } + + text = { + localization_key = GenocideEventGenocidedPopulations_Culture + trigger = { + scope:second = { + allow_genocide_this_province_culture_trigger = { CHARACTER = root } + } + } + } + + text = { + localization_key = GenocideEventGenocidedPopulations_Faith + trigger = { + scope:second = { + allow_genocide_this_province_religion_trigger = { CHARACTER = root } + } + } + } +} \ No newline at end of file diff --git a/common/game_concepts/wc_council_tasks_game_concepts.txt b/common/game_concepts/wc_council_tasks_game_concepts.txt new file mode 100644 index 0000000000..9b5317f844 --- /dev/null +++ b/common/game_concepts/wc_council_tasks_game_concepts.txt @@ -0,0 +1,7 @@ + + +purge_population = { + alias = { genocide } + parent = councillor_task + texture = "gfx/interface/icons/council_task_types/task_purge_population.dds" +} \ No newline at end of file diff --git a/common/modifiers/wc_genocide_modifiers.txt b/common/modifiers/wc_genocide_modifiers.txt new file mode 100644 index 0000000000..830bc0b752 --- /dev/null +++ b/common/modifiers/wc_genocide_modifiers.txt @@ -0,0 +1,259 @@ +ongoing_corruption_modifier = { + icon = martial_negative + + levy_size = -10 + garrison_size = -10 + tax_mult = -10 + levy_reinforcement_rate = -10 + development_growth_factor = -10 +} + +ongoing_cleansing_modifier = { + icon = martial_negative + + levy_size = -10 + garrison_size = -10 + tax_mult = -10 + levy_reinforcement_rate = -10 + development_growth_factor = -10 +} + +ongoing_genocide_modifier = { + icon = martial_negative + + levy_size = -10 + garrison_size = -10 + tax_mult = -10 + levy_reinforcement_rate = -10 + development_growth_factor = -10 +} + +county_corruption_light_modifier = { + icon = magic_mixed + + county_opinion_add = 10 + supply_limit_mult = 0.1 + + scale = { + value = corruption_modifier_scale_value + } +} + +county_corruption_void_modifier = { + icon = magic_mixed + + monthly_county_control_growth_add = 0.1 + build_speed = 0.1 + + scale = { + value = corruption_modifier_scale_value + } +} + +county_corruption_arcane_modifier = { + icon = magic_mixed + + county_opinion_add = 10 + development_growth_factor = 0.1 + + scale = { + value = corruption_modifier_scale_value + } +} + +county_corruption_fel_modifier = { + icon = magic_mixed + + monthly_county_control_growth_add = 0.1 + tax_mult = 0.1 + + scale = { + value = corruption_modifier_scale_value + } +} + +county_corruption_life_modifier = { + icon = magic_mixed + + county_opinion_add = 10 + levy_reinforcement_rate = 0.1 + + scale = { + value = corruption_modifier_scale_value + } +} + +county_corruption_death_modifier = { + icon = magic_mixed + + monthly_county_control_growth_add = 0.1 + levy_size = 0.1 + + scale = { + value = corruption_modifier_scale_value + } +} + +county_purged_modifier_1 = { + icon = flame_negative + + county_opinion_add = -20 + levy_size = -0.2 + garrison_size = -0.2 + tax_mult = -0.2 + levy_reinforcement_rate = -0.2 + supply_limit_mult = -0.2 + epidemic_resistance = 5 + development_growth_factor = -0.2 +} + +county_purged_modifier_2 = { + icon = flame_negative + + county_opinion_add = -40 + levy_size = -0.4 + garrison_size = -0.4 + tax_mult = -0.4 + levy_reinforcement_rate = -0.4 + supply_limit_mult = -0.4 + epidemic_resistance = 15 + development_growth_factor = -0.4 +} + +county_purged_modifier_3 = { + icon = flame_negative + + county_opinion_add = -60 + levy_size = -0.6 + garrison_size = -0.6 + tax_mult = -0.6 + levy_reinforcement_rate = -0.6 + supply_limit_mult = -0.6 + epidemic_resistance = 25 + development_growth_factor = -0.6 +} + +harmonize_with_force_modifier = { + icon = prowess_positive + + prowess = 2 +} + +corruption_disease_modifier = { + icon = martial_negative + + development_growth_factor = -0.5 + build_speed = 0.25 + tax_mult = -0.25 +} + +genocidal_unrest_modifier = { + icon = martial_negative + + development_growth_factor = -0.5 + build_speed = 0.25 + tax_mult = -0.25 +} + +genocide_emigration_modifier = { + icon = stewardship_negative + + development_growth_factor = -0.10 + build_speed = 0.05 + tax_mult = -0.05 + levy_size = -0.05 + county_opinion_add = -5 +} + +genocide_immigration_modifier = { + icon = stewardship_mixed + + development_growth_factor = 0.25 + build_speed = -0.1 + tax_mult = 0.1 + levy_size = 0.1 + county_opinion_add = -10 +} + +genocide_channelled_energy_modifier = { + icon = magic_positive + + development_growth_factor = 0.50 + build_speed = -0.25 + tax_mult = 0.25 + levy_size = 0.25 +} + +genocide_dispersed_energy_modifier = { + icon = magic_positive + + development_growth_factor = 0.25 + build_speed = -0.1 + tax_mult = 0.1 + levy_size = 0.1 +} + +sacrificed_cleansing_targets_modifier = { + icon = martial_positive + + dread_gain_mult = 0.2 + # Speeds up genocide +} + +genocide_focused_resources_modifier = { + icon = stewardship_positive + + development_growth_factor = 0.50 + build_speed = -0.25 + tax_mult = 0.25 + levy_size = 0.25 +} + +genocide_dispersed_resources_modifier = { + icon = stewardship_positive + + development_growth_factor = 0.25 + build_speed = -0.1 + tax_mult = 0.1 + levy_size = 0.1 +} + +genocide_wild_energy_modifier = { + icon = magic_negative + + development_growth_factor = -0.125 + build_speed = 0.05 + tax_mult = -0.05 + levy_size = -0.05 +} + +genocide_controlled_energy_modifier = { + icon = magic_negative + + development_growth_factor = -0.25 + build_speed = 0.1 + tax_mult = -0.1 + levy_size = -0.1 +} + +genocide_marauding_forces_modifier = { + icon = martial_negative + + county_opinion_add = -5 + travel_danger = 5 +} + +genocide_purged_marauders_modifier = { + icon = martial_negative + + county_opinion_add = -10 + development_growth = -0.5 +} + +genocide_local_champion_modifier = { + icon = martial_positive + + same_culture_opinion = 10 + same_faith_opinion = 10 + # Speeds up genocide +} \ No newline at end of file diff --git a/common/on_action/culture_on_actions.txt b/common/on_action/culture_on_actions.txt index b2f3e185f8..6afbfde375 100644 --- a/common/on_action/culture_on_actions.txt +++ b/common/on_action/culture_on_actions.txt @@ -75,6 +75,9 @@ on_character_culture_change = { trigger_event = bp2_yearly.8050 } } + + # Warcraft + refresh_corruption_modifiers_all_counties = yes } } diff --git a/common/on_action/game_start.txt b/common/on_action/game_start.txt index 4004b62ed3..b91779042b 100644 --- a/common/on_action/game_start.txt +++ b/common/on_action/game_start.txt @@ -320,6 +320,16 @@ on_game_start = { } } } + + # Warcraft + every_county = { + save_scope_as = county + holder = { + save_scope_as = councillor_liege + } + + corrupt_county_effect = { ON_START = yes } + } } # Warcraft - FP3 Struggle stuff removed } diff --git a/common/on_action/religion_on_actions.txt b/common/on_action/religion_on_actions.txt index 242be6e105..b893ff0323 100644 --- a/common/on_action/religion_on_actions.txt +++ b/common/on_action/religion_on_actions.txt @@ -196,6 +196,9 @@ on_character_faith_change = { trigger_event = bp2_yearly.8050 } } + + # Warcraft + refresh_corruption_modifiers_all_counties = yes } events = { # Warcraft diff --git a/common/on_action/title_on_actions.txt b/common/on_action/title_on_actions.txt index c842bcccc5..58aa09a8ec 100644 --- a/common/on_action/title_on_actions.txt +++ b/common/on_action/title_on_actions.txt @@ -283,6 +283,23 @@ on_title_gain = { } } # Warcraft + scope:title = { + if = { + limit = { + scope:title.tier = tier_county + scope:title.holder = { + NOR = { + is_liege_or_above_of = scope:previous_holder + is_vassal_or_below_of = scope:previous_holder + } + } + } + + remove_genocide_modifiers = yes + remove_genocide_variables = { REMOVE = no } + refresh_corruption_modifiers = yes + } + } } events = { # Warcraft diff --git a/common/on_action/wc_genocide_on_actions.txt b/common/on_action/wc_genocide_on_actions.txt new file mode 100644 index 0000000000..ac1491f153 --- /dev/null +++ b/common/on_action/wc_genocide_on_actions.txt @@ -0,0 +1,83 @@ +on_reduce_purge_modifier_on_action = { + effect = { + scope:county = { + if = { + limit = { + has_county_modifier = county_purged_modifier_1 + } + + remove_county_modifier = county_purged_modifier_1 + remove_genocide_variables = { REMOVE = yes } + } + else_if = { + limit = { + has_county_modifier = county_purged_modifier_2 + } + + remove_county_modifier = county_purged_modifier_2 + add_county_modifier = { + modifier = county_purged_modifier_1 + days = 1201 + } + + trigger_event = { + on_action = on_reduce_purge_modifier_on_action + days = 1200 + } + } + else_if = { + limit = { + has_county_modifier = county_purged_modifier_3 + } + + remove_county_modifier = county_purged_modifier_3 + add_county_modifier = { + modifier = county_purged_modifier_2 + days = 1201 + } + + trigger_event = { + on_action = on_reduce_purge_modifier_on_action + days = 1200 + } + } + } + } +} + +task_purge_population_side_effects = { + trigger = { + NOT = { has_variable = had_genocide_task_side_effect } + exists = cp:councillor_marshal + } + + random_events = { + chance_to_happen = 25 + 250 = 0 + # Bad side effects + ## Corrupt + 100 = genocide_task.0001 # Gives neighboring counties genocidal_unrest_modifier + 100 = genocide_task.0002 # Gain dread and lose dev or lose dread + + ## Cleanse + 100 = genocide_task.0101 # Champion challenges you to fight + 100 = genocide_task.0102 # Gives maluses, opposite of genocide_task.0302 + + ## Purge + 100 = genocide_task.0201 # Copy of genocide_task.0001 + 100 = genocide_task.0202 # Gives counties of same culture/faith genocide_emigration_modifier and a random neighboring realm county genocide_immigration_modifier + + # Good side effects + ## Corrupt + 100 = genocide_task.0301 # Gives dread, piety, or bonus to prowess + 100 = genocide_task.0302 # Give already corrupted counties small boost + + ## Cleanse + 100 = genocide_task.0401 # Spawn army or speed up cleansing + 100 = genocide_task.0402 # Gives dread, prestige, or bonus to cleanse speed + + ## Purge + 100 = genocide_task.0501 # Spawn a friendly champion or speed up purge + 100 = genocide_task.0502 # Gives counties of your culture/faith modifier + } +} \ No newline at end of file diff --git a/common/opinion_modifiers/wc_genocide_opinions.txt b/common/opinion_modifiers/wc_genocide_opinions.txt new file mode 100644 index 0000000000..a86d9e5e64 --- /dev/null +++ b/common/opinion_modifiers/wc_genocide_opinions.txt @@ -0,0 +1,34 @@ +minority_disapproves_of_genocide_population_opinion = { + opinion = -50 + years = 10 + decaying = yes + stacking = yes +} + +genocided_my_culture_opinion = { + opinion = -25 + years = 10 + decaying = yes + stacking = yes +} + +genocided_my_faith_opinion = { + opinion = -50 + years = 10 + decaying = yes + stacking = yes +} + +ruler_disapproves_of_genocide_population_opinion = { + opinion = -100 + years = 50 + decaying = yes + stacking = yes +} + +vassal_approves_of_defending_genocide_opinion = { + opinion = 25 + years = 10 + decaying = yes + stacking = yes +} \ No newline at end of file diff --git a/common/script_values/wc_genocide_values.txt b/common/script_values/wc_genocide_values.txt new file mode 100644 index 0000000000..73624262a1 --- /dev/null +++ b/common/script_values/wc_genocide_values.txt @@ -0,0 +1,484 @@ +marshal_purge_population_threshold = 18 +council_same_culture_impact_percentage = 50 +council_same_faith_impact_percentage = 50 +council_already_corrupted_impact_percentage = 50 +council_sacrifice_impact_percentage = 20 +council_champion_impact_percentage = 20 + +genocide_task_side_effect_cooldown = 91 + +marshal_purge_population_current_progress = { + value = 0 + if = { + limit = { + scope:county ?= { + has_variable = purge_population_current_progress + } + } + add = scope:county.var:purge_population_current_progress + } +} + +marshal_purge_population_base = { + value = 1 +} + +marshal_purge_population_base_total = { + value = marshal_purge_population_base + + if = { + limit = { + OR = { + scope:councillor_liege = { + can_corrupt_trigger = yes + } + scope:county = { + allow_cleanse_this_province_trigger = yes + } + } + } + add = 1 + } +} + +marshal_purge_population_skill_bonus = { + value = scope:councillor.martial + subtract = 10 + divide = 10 +} + +marshal_purge_population_monthly_increase_friend_bonus = { + if = { + limit = { + scope:councillor_liege = { + has_relation_friend = scope:councillor + NOT = { has_relation_best_friend = scope:councillor } + } + } + add = { + value = marshal_purge_population_base + multiply = { + value = council_friend_impact_percentage + divide = 100 + } + } + } +} +marshal_purge_population_monthly_increase_best_friend_bonus = { + if = { + limit = { + scope:councillor_liege = { + has_relation_best_friend = scope:councillor + } + } + add = { + value = marshal_purge_population_base + multiply = { + value = council_best_friend_impact_percentage + divide = 100 + } + } + } +} +marshal_purge_population_monthly_increase_rival_bonus = { + if = { + limit = { + scope:councillor_liege = { + has_relation_rival = scope:councillor + NOT = { has_relation_nemesis = scope:councillor } + } + } + add = { + value = marshal_purge_population_base + multiply = { + value = council_rival_impact_percentage + divide = 100 + } + } + } +} +marshal_purge_population_monthly_increase_nemesis_bonus = { + if = { + limit = { + scope:councillor_liege = { + has_relation_nemesis = scope:councillor + } + } + add = { + value = marshal_purge_population_base + multiply = { + value = council_nemesis_impact_percentage + divide = 100 + } + } + } +} +marshal_purge_population_monthly_increase_same_culture_bonus = { + if = { + limit = { + scope:county = { + culture = scope:councillor_liege.culture + } + } + add = { + value = marshal_purge_population_base + multiply = { + value = council_same_culture_impact_percentage + divide = 100 + } + } + } +} +marshal_purge_population_monthly_increase_same_faith_bonus = { + if = { + limit = { + scope:county = { + faith = scope:councillor_liege.faith + + NOT = { + has_variable = false_convert + } + } + } + add = { + value = marshal_purge_population_base + multiply = { + value = council_same_faith_impact_percentage + divide = 100 + } + } + } +} +marshal_purge_population_monthly_increase_already_corrupted_bonus = { + if = { + limit = { + scope:councillor_liege = { + can_corrupt_trigger = yes + } + scope:county = { + has_beneficial_corruption_this_province_trigger = yes + } + } + add = { + value = marshal_purge_population_base + multiply = { + value = council_already_corrupted_impact_percentage + divide = 100 + } + } + } +} + +marshal_purge_population_monthly_increase_unraised_army_bonus = { + # bonus for army strength when armies are unraised + if = { + limit = { + scope:councillor_liege = { has_raised_armies = no } + } + + add = { + value = marshal_purge_population_base + multiply = { + value = scope:councillor_liege.current_military_strength + divide = 10000 + } + max = 2 + } + } +} + +marshal_purge_population_monthly_increase_sacrifice_bonus = { + if = { + limit = { + scope:councillor_liege = { + has_character_modifier = sacrificed_cleansing_targets_modifier + } + } + + add = { + value = marshal_purge_population_base + multiply = { + value = council_sacrifice_impact_percentage + divide = 100 + } + } + } +} + +marshal_purge_population_monthly_increase_champion_bonus = { + if = { + limit = { + scope:councillor_liege = { + has_character_modifier = genocide_local_champion_modifier + } + } + + add = { + value = marshal_purge_population_base + multiply = { + value = council_champion_impact_percentage + divide = 100 + } + } + } +} + +marshal_purge_population_monthly_increase_fervor_penalty = { + if = { + limit = { + scope:county = { + allow_genocide_this_province_religion_trigger = { CHARACTER = scope:councillor_liege } + } + } + add = { + value = marshal_purge_population_base + multiply = { + add = { + add = scope:councillor_liege.faith.fervor + } + subtract = { + add = scope:county.faith.fervor + } + divide = 100 + } + } + } +} + +# Development penalty +marshal_purge_population_monthly_increase_development_penalty = { + value = 0 + if = { + limit = { exists = scope:county } + add = { + value = scope:councillor.marshal_purge_population_base + multiply = { + subtract = scope:county.development_level + divide = 50 + } + } + } +} + +marshal_purge_population_faith_game_rule_mult = { + value = 1 + # Conversion speed game rules + if = { + limit = { + has_game_rule = slower_faith_conversion_speed + } + multiply = slower_game_rule_value + } + if = { + limit = { + has_game_rule = significantly_slower_faith_conversion_speed + } + multiply = significantly_slower_game_rule_value + } + if = { + limit = { + has_game_rule = faster_faith_conversion_speed + } + multiply = faster_game_rule_value + } + if = { + limit = { + has_game_rule = significantly_faster_faith_conversion_speed + } + multiply = significantly_faster_game_rule_value + } +} + +marshal_purge_population_culture_game_rule_mult = { + value = 1 + # Conversion speed game rules + if = { + limit = { + has_game_rule = slower_culture_conversion_speed + } + multiply = slower_game_rule_value + } + if = { + limit = { + has_game_rule = significantly_slower_culture_conversion_speed + } + multiply = significantly_slower_game_rule_value + } + if = { + limit = { + has_game_rule = faster_culture_conversion_speed + } + multiply = faster_game_rule_value + } + if = { + limit = { + has_game_rule = significantly_faster_culture_conversion_speed + } + multiply = significantly_faster_game_rule_value + } +} + +marshal_purge_population_game_rule_mult = { + value = 0 + if = { + limit = { + limit = { exists = scope:county } + scope:county = { + allow_genocide_this_province_culture_trigger = { CHARACTER = scope:councillor_liege } + } + } + add = marshal_purge_population_culture_game_rule_mult + } + if = { + limit = { + scope:county ?= { + allow_genocide_this_province_religion_trigger = { CHARACTER = scope:councillor_liege } + } + } + add = marshal_purge_population_faith_game_rule_mult + } + + if = { + limit = { + scope:county ?= { + allow_genocide_this_province_religion_trigger = { CHARACTER = scope:councillor_liege } + allow_genocide_this_province_culture_trigger = { CHARACTER = scope:councillor_liege } + } + } + divide = 2 + } + + if = { + limit = { + scope:county ?= { + NOR = { + allow_genocide_this_province_religion_trigger = { CHARACTER = scope:councillor_liege } + allow_genocide_this_province_culture_trigger = { CHARACTER = scope:councillor_liege } + } + } + } + add = 1 + } +} + +marshal_purge_population_total = { + value = marshal_purge_population_base_total + add = marshal_purge_population_skill_bonus + add = marshal_purge_population_monthly_increase_friend_bonus + add = marshal_purge_population_monthly_increase_best_friend_bonus + add = marshal_purge_population_monthly_increase_rival_bonus + add = marshal_purge_population_monthly_increase_nemesis_bonus + add = marshal_purge_population_monthly_increase_same_culture_bonus + add = marshal_purge_population_monthly_increase_same_faith_bonus + add = marshal_purge_population_monthly_increase_already_corrupted_bonus + add = marshal_purge_population_monthly_increase_unraised_army_bonus + add = marshal_purge_population_monthly_increase_sacrifice_bonus + add = marshal_purge_population_monthly_increase_champion_bonus + add = marshal_purge_population_monthly_increase_fervor_penalty + add = marshal_purge_population_monthly_increase_development_penalty + multiply = marshal_purge_population_game_rule_mult +} + +genocide_cb_prestige_cost = { + value = 0 + scope:defender = { + every_realm_county = { + limit = { + OR = { + AND = { + has_variable = culture_genocided + var:culture_genocided = scope:attacker.culture + } + } + } + + add = 100 + } + } +} + +genocide_cb_piety_cost = { + value = 0 + scope:defender = { + every_realm_county = { + limit = { + OR = { + AND = { + has_variable = faith_genocided + var:faith_genocided = scope:attacker.faith + } + } + } + + add = 100 + } + } +} + +genocide_cb_participation_prestige = { + value = 0 + add = scope:base_prestige + multiply = 0.5 + multiply = { + value = 0 + if = { + limit = { + scope:attacker_culture_reward_mult > scope:defender_culture_reward_mult + } + add = scope:attacker_culture_reward_mult + } + else = { + add = scope:defender_culture_reward_mult + } + } +} + +genocide_cb_participation_piety = { + value = 0 + add = scope:base_piety + multiply = 0.5 + multiply = { + value = 0 + if = { + limit = { + scope:attacker_faith_reward_mult > scope:defender_faith_reward_mult + } + add = scope:attacker_faith_reward_mult + } + else = { + add = scope:defender_faith_reward_mult + } + } +} + +corruption_modifier_scale_value = { + value = 0 + if = { + limit = { + corruption_scale_extreme_pos_trigger = yes + } + + add = 2 + } + else_if = { + limit = { + corruption_scale_mild_pos_trigger = yes + } + + add = 1 + } + else_if = { + limit = { + corruption_scale_mild_neg_trigger = yes + } + + add = -1 + } + else_if = { + limit = { + corruption_scale_extreme_neg_trigger = yes + } + + add = -2 + } +} \ No newline at end of file diff --git a/common/scripted_effects/wc_being_effects.txt b/common/scripted_effects/wc_being_effects.txt index 3009d11273..fe43a914b3 100644 --- a/common/scripted_effects/wc_being_effects.txt +++ b/common/scripted_effects/wc_being_effects.txt @@ -13,6 +13,8 @@ become_undead_no_notification_effect = { check_pregnancy_effect = yes check_available_government_event_effect = yes # Memory leak 4 GB of OM + + refresh_corruption_modifiers_all_counties = yes } become_undead_no_notification_event_effect = { trigger_event = WCBEI.2 @@ -126,6 +128,8 @@ become_demon_effect = { } check_pregnancy_effect = yes check_available_government_event_effect = yes # May be memory leak + + refresh_corruption_modifiers_all_counties = yes } become_being_void_effect = { add_trait = being_void @@ -136,6 +140,8 @@ become_being_void_effect = { } check_pregnancy_effect = yes check_available_government_event_effect = yes # May be memory leak + + refresh_corruption_modifiers_all_counties = yes } become_being_life_effect = { add_trait = being_life @@ -145,6 +151,8 @@ become_being_life_effect = { recover_from_all_diseases_event_effect = yes } check_pregnancy_effect = yes + + refresh_corruption_modifiers_all_counties = yes } become_being_order_effect = { add_trait = being_order @@ -154,6 +162,8 @@ become_being_order_effect = { recover_from_all_diseases_event_effect = yes } check_pregnancy_effect = yes + + refresh_corruption_modifiers_all_counties = yes } become_being_light_effect = { add_trait = being_light @@ -163,6 +173,8 @@ become_being_light_effect = { recover_from_all_diseases_event_effect = yes } check_pregnancy_effect = yes + + refresh_corruption_modifiers_all_counties = yes } send_being_notifications_effect = { diff --git a/common/scripted_effects/wc_genocide_effects.txt b/common/scripted_effects/wc_genocide_effects.txt new file mode 100644 index 0000000000..44a066298e --- /dev/null +++ b/common/scripted_effects/wc_genocide_effects.txt @@ -0,0 +1,847 @@ +# TODO: Give nickname + +reset_genocide_progress_effect = { + if = { + limit = { + has_variable = purge_population_current_progress + } + set_variable = { name = purge_population_current_progress value = 0 } + } +} + +# Remove ongoing modifiers when title changes hands: on_title_gain, on_county_occupied +remove_genocide_modifiers = { + reset_genocide_progress_effect = yes + if = { + limit = { + has_county_modifier = ongoing_corruption_modifier + } + + remove_county_modifier = ongoing_corruption_modifier + } + if = { + limit = { + has_county_modifier = ongoing_cleansing_modifier + } + + remove_county_modifier = ongoing_cleansing_modifier + } + if = { + limit = { + has_county_modifier = ongoing_genocide_modifier + } + + remove_county_modifier = ongoing_genocide_modifier + } +} + +add_corruption_modifier = { + remove_corruption_modifiers = yes + set_variable = { + name = corruption_type + value = flag:$MOD$ + } + add_county_modifier = $MOD$ + remove_variable = corruption_type +} + +remove_corruption_modifiers = { + if = { + limit = { + has_county_modifier = county_corruption_light_modifier + } + + remove_county_modifier = county_corruption_light_modifier + } + if = { + limit = { + has_county_modifier = county_corruption_void_modifier + } + + remove_county_modifier = county_corruption_void_modifier + } + if = { + limit = { + has_county_modifier = county_corruption_arcane_modifier + } + + remove_county_modifier = county_corruption_arcane_modifier + } + if = { + limit = { + has_county_modifier = county_corruption_fel_modifier + } + + remove_county_modifier = county_corruption_fel_modifier + } + if = { + limit = { + has_county_modifier = county_corruption_life_modifier + } + + remove_county_modifier = county_corruption_life_modifier + } + if = { + limit = { + has_county_modifier = county_corruption_death_modifier + } + + remove_county_modifier = county_corruption_death_modifier + } +} + +refresh_corruption_modifiers = { # Modifier scale only works when modifier is added, so we use this to remove modifier and re-add it + if = { + limit = { + has_county_modifier = county_corruption_light_modifier + } + + add_corruption_modifier = { MOD = county_corruption_light_modifier } + } + if = { + limit = { + has_county_modifier = county_corruption_void_modifier + } + + add_corruption_modifier = { MOD = county_corruption_void_modifier } + } + if = { + limit = { + has_county_modifier = county_corruption_arcane_modifier + } + + add_corruption_modifier = { MOD = county_corruption_arcane_modifier } + } + if = { + limit = { + has_county_modifier = county_corruption_fel_modifier + } + + add_corruption_modifier = { MOD = county_corruption_fel_modifier } + } + if = { + limit = { + has_county_modifier = county_corruption_life_modifier + } + + add_corruption_modifier = { MOD = county_corruption_life_modifier } + } + if = { + limit = { + has_county_modifier = county_corruption_death_modifier + } + + add_corruption_modifier = { MOD = county_corruption_death_modifier } + } +} + +refresh_corruption_modifiers_all_counties = { + every_held_title = { + limit = { + tier = tier_county + } + + refresh_corruption_modifiers = yes + } +} + +remove_genocide_variables = { + if = { + limit = { + has_variable = culture_genocided + OR = { + NOT = { + culture = holder.culture + } + always = $REMOVE$ + } + } + + remove_variable = culture_genocided + } + + if = { + limit = { + has_variable = faith_genocided + OR = { + NOT = { + faith = holder.faith + } + always = $REMOVE$ + } + } + + remove_variable = faith_genocided + } +} + +corrupt_county_effect = { + scope:county ?= { + if = { + limit = { + OR = { + $ON_START$ = yes + AND = { + has_variable = purge_population_current_progress + var:purge_population_current_progress >= marshal_purge_population_threshold + } + has_variable = finished_genocide + } + } + + remove_genocide_modifiers = yes + + save_temporary_scope_value_as = { + name = take_county + value = yes + } + + if = { + limit = { + $ON_START$ = yes + } + + save_temporary_scope_value_as = { + name = take_county + value = no + } + } + + if = { + limit = { + trigger_if = { + limit = { + $ON_START$ = yes + } + scope:county = { + can_corrupt_at_game_start_specific_trigger = { BEING = being_light MAGIC = light } + } + } + trigger_else = { + scope:councillor_liege = { + can_corrupt_specific_trigger = { BEING = being_light MAGIC = light } + } + can_corrupt_this_province_valid_trigger = { MOD = county_corruption_light_modifier } + can_corrupt_this_province_liege_trigger = { BEING = being_light MAGIC = light } + } + } + + add_corruption_modifier = { MOD = county_corruption_light_modifier } + } + else_if = { + limit = { + trigger_if = { + limit = { + $ON_START$ = yes + } + scope:county = { + can_corrupt_at_game_start_specific_trigger = { BEING = being_void MAGIC = shadow } + } + } + trigger_else = { + scope:councillor_liege = { + can_corrupt_specific_trigger = { BEING = being_void MAGIC = shadow } + } + can_corrupt_this_province_valid_trigger = { MOD = county_corruption_void_modifier } + can_corrupt_this_province_liege_trigger = { BEING = being_void MAGIC = shadow } + } + } + + add_corruption_modifier = { MOD = county_corruption_void_modifier } + } + else_if = { + limit = { + trigger_if = { + limit = { + $ON_START$ = yes + } + scope:county = { + can_corrupt_at_game_start_specific_trigger = { BEING = being_order MAGIC = order } + } + } + trigger_else = { + scope:councillor_liege = { + can_corrupt_specific_trigger = { BEING = being_order MAGIC = order } + } + can_corrupt_this_province_valid_trigger = { MOD = county_corruption_arcane_modifier } + can_corrupt_this_province_liege_trigger = { BEING = being_order MAGIC = order } + } + } + + add_corruption_modifier = { MOD = county_corruption_arcane_modifier } + } + else_if = { + limit = { + trigger_if = { + limit = { + $ON_START$ = yes + } + scope:county = { + can_corrupt_at_game_start_specific_trigger = { BEING = being_demon MAGIC = disorder } + } + } + trigger_else = { + scope:councillor_liege = { + can_corrupt_specific_trigger = { BEING = being_demon MAGIC = disorder } + } + can_corrupt_this_province_valid_trigger = { MOD = county_corruption_fel_modifier } + can_corrupt_this_province_liege_trigger = { BEING = being_demon MAGIC = disorder } + } + } + + add_corruption_modifier = { MOD = county_corruption_fel_modifier } + } + else_if = { + limit = { + trigger_if = { + limit = { + $ON_START$ = yes + } + scope:county = { + can_corrupt_at_game_start_specific_trigger = { BEING = being_life MAGIC = life } + } + } + trigger_else = { + scope:councillor_liege = { + can_corrupt_specific_trigger = { BEING = being_life MAGIC = life } + } + can_corrupt_this_province_valid_trigger = { MOD = county_corruption_life_modifier } + can_corrupt_this_province_liege_trigger = { BEING = being_life MAGIC = life } + } + } + + add_corruption_modifier = { MOD = county_corruption_life_modifier } + } + else_if = { + limit = { + trigger_if = { + limit = { + $ON_START$ = yes + } + scope:county = { + can_corrupt_at_game_start_specific_trigger = { BEING = being_undead MAGIC = death } + } + } + trigger_else = { + scope:councillor_liege = { + can_corrupt_specific_trigger = { BEING = being_undead MAGIC = death } + } + can_corrupt_this_province_valid_trigger = { MOD = county_corruption_death_modifier } + can_corrupt_this_province_liege_trigger = { BEING = being_undead MAGIC = death } + } + } + + add_corruption_modifier = { MOD = county_corruption_death_modifier } + + save_temporary_scope_value_as = { + name = take_county + value = no + } + + if = { + limit = { + $ON_START$ = no + NOT = { + holder = scope:councillor_liege + } + } + holder = { + raise_undead_by_basic_effect = { MASTER = scope:councillor_liege FROSTMOURNE = no } + } + } + } + + if = { + limit = { + $ON_START$ = no + } + + genocide_common_effect = { + OPINION = yes + MULT = 3 + MOD = minority_disapproves_of_genocide_population_opinion + TAKE_TITLE = scope:take_county + } + + set_county_culture = scope:councillor_liege.culture + set_county_faith = scope:councillor_liege.faith + } + + if = { + limit = { + has_variable = finished_genocide + } + remove_variable = finished_genocide + } + + scope:councillor_liege = { + add_character_flag = { + flag = no_ai_genocide + years = 1 + } + } + } + } +} + +cleanse_county_effect = { + scope:county ?= { + if = { + limit = { + OR = { + AND = { + has_variable = purge_population_current_progress + var:purge_population_current_progress >= marshal_purge_population_threshold + } + has_variable = finished_genocide + } + } + + remove_genocide_modifiers = yes + + genocide_culture_effect = { MULT = 2 MOD = genocided_my_culture_opinion } + genocide_faith_effect = { MULT = 2 MOD = genocided_my_faith_opinion } + genocide_common_effect = { + OPINION = no + MULT = 3 + MOD = minority_disapproves_of_genocide_population_opinion + TAKE_TITLE = yes + } + remove_corruption_modifiers = yes + + add_county_modifier = { + modifier = county_purged_modifier_3 + days = 1201 + } + + trigger_event = { + on_action = on_reduce_purge_modifier_on_action + days = 1200 + } + + # TODO: Should destroy random building, not sure if possible in CK3 + + if = { + limit = { + has_variable = finished_genocide + } + remove_variable = finished_genocide + } + + scope:councillor_liege = { + add_character_flag = { + flag = no_ai_genocide + years = 1 + } + } + } + } +} + +purge_population_effect = { + scope:county ?= { + if = { + limit = { + OR = { + AND = { + has_variable = purge_population_current_progress + var:purge_population_current_progress >= marshal_purge_population_threshold + } + has_variable = finished_genocide + } + } + + remove_genocide_modifiers = yes + + genocide_culture_effect = { MULT = 2 MOD = genocided_my_culture_opinion } + genocide_faith_effect = { MULT = 2 MOD = genocided_my_faith_opinion } + genocide_common_effect = { + OPINION = yes + MULT = 2 + MOD = minority_disapproves_of_genocide_population_opinion + TAKE_TITLE = no + } + + add_county_modifier = { + modifier = county_purged_modifier_3 + days = 1201 + } + + trigger_event = { + on_action = on_reduce_purge_modifier_on_action + days = 1200 + } + + # TODO: Should destroy random building, not sure if possible in CK3 + + if = { + limit = { + has_variable = finished_genocide + } + remove_variable = finished_genocide + } + + scope:councillor_liege = { + add_character_flag = { + flag = no_ai_genocide + years = 20 + } + } + } + } +} + +genocide_culture_effect = { + if = { + limit = { + allow_genocide_this_province_culture_trigger = { CHARACTER = scope:councillor_liege } + } + + culture = { + save_scope_as = old_culture + change_cultural_acceptance = { + target = scope:councillor_liege.culture + value = { + value = -30 + multiply = $MULT$ + } + desc = cultural_acceptance_loss_purge_pupulation + } + custom_tooltip = { + text = $MOD$_desc + every_ruler = { + limit = { + NOT = { + target_is_liege_or_above = scope:councillor_liege + } + culture = scope:old_culture + NOT = { + this = scope:county.holder + } + } + add_opinion = { + target = scope:councillor_liege + modifier = $MOD$ + } + } + } + } + + set_variable = { + name = culture_genocided + value = scope:old_culture + } + + + set_county_culture = scope:councillor_liege.culture + } +} + +genocide_faith_effect = { + if = { + limit = { + allow_genocide_this_province_religion_trigger = { CHARACTER = scope:councillor_liege } + } + + faith = { + save_scope_as = old_faith + + change_fervor = { + value = { + value = 5 + multiply = $MULT$ + } + desc = genoided_faith_fervor + } + + custom_tooltip = { + text = $MOD$_desc + every_faith_ruler = { + limit = { + NOT = { + target_is_liege_or_above = scope:councillor_liege + } + NOT = { + this = scope:county.holder + } + } + add_opinion = { + target = scope:councillor_liege + modifier = $MOD$ + } + } + } + } + + set_variable = { + name = faith_genocided + value = scope:old_faith + } + + if = { # Remove false conversion + limit = { + has_county_modifier = false_convert_modifier + } + + remove_county_modifier = false_convert_modifier + } + + if = { # Remove false conversion + limit = { + has_variable = false_convert + } + + remove_variable = false_convert + } + + set_county_faith = scope:councillor_liege.faith + } +} + +genocide_common_effect = { + scope:councillor_liege = { + if = { + limit = { + $OPINION$ = yes + any_vassal = { + has_vassal_stance = minority + } + } + custom_tooltip = $MOD$_desc + hidden_effect = { + every_vassal = { + limit = { + has_vassal_stance = minority + NOT = { + this = scope:county.holder + } + } + add_opinion = { + target = scope:councillor_liege + modifier = $MOD$ + } + } + } + } + + if = { + limit = { government_has_flag = government_dark_frenzy_from_conversions } + change_dark_frenzy_effect = { VALUE = dark_frenzy_from_convert_county } + } + } + + change_county_control = { + value = -30 + multiply = $MULT$ + } + change_development_level = { + value = -10 + multiply = $MULT$ + } + + holder = { + save_temporary_scope_as = old_holder + + if = { + limit = { + NOT = { + this = scope:councillor_liege + } + } + + add_opinion = { + target = scope:councillor_liege + modifier = ruler_disapproves_of_genocide_population_opinion + } + } + } + + if = { # Take the title you just genocided + limit = { + $TAKE_TITLE$ = yes + NOT = { + holder = scope:councillor_liege + } + NAND = { + holder.culture = scope:councillor_liege.culture + holder.faith = scope:councillor_liege.faith + } + } + + create_title_and_vassal_change = { + type = usurped + add_claim_on_loss = yes + save_scope_as = change + } + + change_title_holder = { + holder = scope:councillor_liege + change = scope:change + take_baronies = yes + } + + resolve_title_and_vassal_change = scope:change + + scope:old_holder = { # If this was their only title they're included in the genocide + if = { + limit = { + is_ruler = no + } + + override_death_killer_effect = { + death_reason = death_execution + killer = scope:councillor_liege + } + } + } + } +} + +genocide_spawn_champion_effect = { + create_character = { + location = scope:county.title_province + culture = $CULTURE$ + faith = $FAITH$ + dynasty = none + random_traits = no + random_traits_list = { + count = 1 + education_martial_prowess_2 = {} + education_martial_prowess_3 = {} + education_martial_prowess_4 = {} + } + gender_female_chance = { + if = { + limit = { $FAITH$ = { has_doctrine = doctrine_gender_male_dominated } } + add = 0 + } + else_if = { + limit = { $FAITH$ = { has_doctrine = doctrine_gender_female_dominated } } + add = 100 + } + else = { + add = 50 + } + } + martial = { 8 12 } + prowess = { + min_template_high_skill + max_template_high_skill + } + save_scope_as = champion + after_creation = { + if = { + limit = { + $GOOD$ = yes + } + random_list = { + 1 = { + add_trait = brave + } + 1 = { + add_trait = just + } + 1 = { + add_trait = gallant + } + } + random_list = { + 1 = { + add_trait = lustful + } + 1 = { + add_trait = chaste + } + 1 = { + add_trait = wrathful + } + 1 = { + add_trait = arrogant + } + 1 = { + add_trait = impatient + } + 1 = { + add_trait = deceitful + } + 1 = { + add_trait = ambitious + } + 1 = { + add_trait = stubborn + } + 1 = { + add_trait = fickle + } + 1 = { + add_trait = beauty_good_1 + } + } + } + else = { + + random_list = { + 1 = { + add_trait = wrathful + } + 1 = { + add_trait = arbitrary + } + 1 = { + add_trait = arrogant + } + } + random_list = { + 1 = { + add_trait = lustful + } + 1 = { + add_trait = impatient + } + 1 = { + add_trait = paranoid + } + 1 = { + add_trait = arrogant + } + 1 = { + add_trait = impatient + } + 1 = { + add_trait = deceitful + } + 1 = { + add_trait = sadistic + } + 1 = { + add_trait = stubborn + } + 1 = { + add_trait = fickle + } + 1 = { + add_trait = beauty_bad_1 + } + } + } + # Warcraft + trigger_race_giving_no_gene_effect = yes + } + } +} + +genocide_add_champion_being_trait_effect = { + save_temporary_scope_as = champion + scope:county = { + switch = { + trigger = has_county_modifier + } + + county_corruption_light_modifier = { scope:champion = { add_trait = being_light } } + county_corruption_void_modifier = { scope:champion = { add_trait = being_void } } + county_corruption_arcane_modifier = { scope:champion = { add_trait = being_order } } + county_corruption_fel_modifier = { scope:champion = { add_trait = being_demon } } + county_corruption_life_modifier = { scope:champion = { add_trait = being_life } } + county_corruption_death_modifier = { scope:champion = { add_trait = being_undead } } + } +} \ No newline at end of file diff --git a/common/scripted_effects/wc_war_effects.txt b/common/scripted_effects/wc_war_effects.txt index ec26f33d1d..3aa15e33d7 100644 --- a/common/scripted_effects/wc_war_effects.txt +++ b/common/scripted_effects/wc_war_effects.txt @@ -623,4 +623,320 @@ join_every_war_effect = { } } } +} + +add_genocide_cb_rewards = { + save_scope_value_as = { name = attacker_culture_reward_mult value = 0 } + save_scope_value_as = { name = attacker_faith_reward_mult value = 0 } + save_scope_value_as = { name = defender_culture_reward_mult value = 0 } + save_scope_value_as = { name = defender_faith_reward_mult value = 0 } + save_scope_value_as = { name = base_prestige value = $PRESTIGE_BASE_VALUE$ } + save_scope_value_as = { name = base_piety value = $PIETY_BASE_VALUE$ } + scope:defender = { + every_realm_county = { + limit = { + OR = { + AND = { + has_variable = culture_genocided + var:culture_genocided = scope:attacker.culture + } + + AND = { + has_variable = faith_genocided + var:faith_genocided = scope:attacker.faith + } + } + } + + if = { + limit = { + has_variable = culture_genocided + } + + save_scope_value_as = { + name = attacker_culture_reward_mult + value = { + value = scope:attacker_culture_reward_mult + if = { + limit = { + $OUTCOME$ = flag:win + } + add = 1 + } + if = { + limit = { + $OUTCOME$ = flag:white_peace + } + add = 0.5 + } + if = { + limit = { + $OUTCOME$ = flag:loss + } + add = -1 + } + } + } + save_scope_value_as = { + name = defender_culture_reward_mult + value = { + value = scope:defender_culture_reward_mult + if = { + limit = { + $OUTCOME$ = flag:win + } + add = -1 + } + if = { + limit = { + $OUTCOME$ = flag:loss + } + add = 1 + } + } + } + } + if = { + limit = { + has_variable = faith_genocided + } + + save_scope_value_as = { + name = attacker_faith_reward_mult + value = { + value = scope:attacker_faith_reward_mult + if = { + limit = { + $OUTCOME$ = flag:win + } + add = 1 + } + if = { + limit = { + $OUTCOME$ = flag:white_peace + } + add = 0.5 + } + if = { + limit = { + $OUTCOME$ = flag:loss + } + add = -1 + } + } + } + save_scope_value_as = { + name = defender_faith_reward_mult + value = { + value = scope:defender_faith_reward_mult + if = { + limit = { + $OUTCOME$ = flag:win + } + add = -1 + } + if = { + limit = { + $OUTCOME$ = flag:loss + } + add = 1 + } + } + } + } + + if = { + limit = { + $OUTCOME$ = flag:win + } + + change_title_holder = { + holder = scope:attacker + change = scope:change + take_baronies = yes + } + } + } + } + + scope:attacker = { + add_prestige = { + value = scope:base_prestige + multiply = scope:attacker_culture_reward_mult + } + + add_piety = { + value = scope:base_piety + multiply = scope:attacker_faith_reward_mult + } + } + + scope:defender = { + if = { + limit = { + NOT = { + scope:defender_culture_reward_mult = 0 + } + } + add_prestige = { + value = scope:base_prestige + multiply = scope:defender_culture_reward_mult + } + } + + if = { + limit = { + NOT = { + scope:defender_faith_reward_mult = 0 + } + } + add_piety = { + value = scope:base_piety + multiply = scope:defender_faith_reward_mult + } + } + } + + if = { + limit = { + $OUTCOME$ = flag:loss + } + + # Allies on both sides get full prestige value for helping in the war, based on their war participation. + modify_allies_of_participants_fame_values_genocide = { + WINNER = scope:defender + FAME_BASE = genocide_cb_participation_prestige + PIETY_BASE = genocide_cb_participation_piety + GIVE_FAITH_REWARDS = genocide_cb_can_avenge_faith + GIVE_CULTURE_REWARDS = genocide_cb_can_avenge_culture + WINNER_ALLY_FAME_SCALE = 1 + LOSER_ALLY_FAME_SCALE = 1 + } + } + else = { + # Allies on both sides get full prestige value for helping in the war, based on their war participation. + modify_allies_of_participants_fame_values_genocide = { + WINNER = scope:attacker + FAME_BASE = genocide_cb_participation_prestige + PIETY_BASE = genocide_cb_participation_piety + GIVE_FAITH_REWARDS = genocide_cb_can_avenge_faith + GIVE_CULTURE_REWARDS = genocide_cb_can_avenge_culture + WINNER_ALLY_FAME_SCALE = 1 + LOSER_ALLY_FAME_SCALE = 1 + } + } +} + +modify_allies_of_participants_fame_values_genocide = { + # Give the allies of both primary participants the appropriate type & amount of 'fame'. + + if = { + # Religious wars award Piety to participants. + limit = { + OR = { + $GIVE_FAITH_REWARDS$ = yes + #always = yes + } + } + if = { + # Award Piety to the victorious attacker's allies. + limit = { + $WINNER$ = scope:attacker + } + add_from_contribution_attackers = { + piety = { + value = $PIETY_BASE$ + multiply = $WINNER_ALLY_FAME_SCALE$ + } + opinion = { + modifier = contributed_in_war + } + } + # Award Piety to the defeated defender's allies. + add_from_contribution_defenders = { + piety = { + value = $PIETY_BASE$ + multiply = $LOSER_ALLY_FAME_SCALE$ + } + opinion = { + modifier = contributed_in_war + } + } + } + else = { + # Award Piety to the victorious defender's allies. + add_from_contribution_defenders = { + piety = { + value = $PIETY_BASE$ + multiply = $WINNER_ALLY_FAME_SCALE$ + } + opinion = { + modifier = contributed_in_war + } + } + # Award Piety to the defeated attacker's allies. + add_from_contribution_attackers = { + piety = { + value = $PIETY_BASE$ + multiply = $LOSER_ALLY_FAME_SCALE$ + } + opinion = { + modifier = contributed_in_war + } + } + } + } + if = { + limit = { + $GIVE_CULTURE_REWARDS$ = yes + } + # All other war types award Prestige to participants. + if = { + # Award Prestige to the victorious attacker's allies. + limit = { + $WINNER$ = scope:attacker + } + add_from_contribution_attackers = { + prestige = { + value = $FAME_BASE$ + multiply = $WINNER_ALLY_FAME_SCALE$ + } + opinion = { + modifier = contributed_in_war + } + } + # Award Prestige to the defeated defender's allies. + add_from_contribution_defenders = { + prestige = { + value = $FAME_BASE$ + multiply = $LOSER_ALLY_FAME_SCALE$ + } + opinion = { + modifier = contributed_in_war + } + } + } + else = { + # Award Prestige to the victorious defender's allies. + add_from_contribution_defenders = { + prestige = { + value = $FAME_BASE$ + multiply = $WINNER_ALLY_FAME_SCALE$ + } + opinion = { + modifier = contributed_in_war + } + } + # Award Prestige to the defeated attacker's allies. + add_from_contribution_attackers = { + prestige = { + value = $FAME_BASE$ + multiply = $LOSER_ALLY_FAME_SCALE$ + } + opinion = { + modifier = contributed_in_war + } + } + } + } } \ No newline at end of file diff --git a/common/scripted_triggers/wc_being_triggers.txt b/common/scripted_triggers/wc_being_triggers.txt index ebe1367687..3493553369 100644 --- a/common/scripted_triggers/wc_being_triggers.txt +++ b/common/scripted_triggers/wc_being_triggers.txt @@ -8,6 +8,18 @@ has_trait = being_light } } +has_culture_being_trait_gfx_trigger = { + culture = { + OR = { + has_clothing_gfx = being_light_gfx + has_clothing_gfx = being_void_gfx + has_clothing_gfx = being_order_gfx + has_clothing_gfx = being_demon_gfx + has_clothing_gfx = being_life_gfx + has_clothing_gfx = being_undead_gfx + } + } +} valid_being_notification_target_trigger = { NOR = { this = scope:lost_character diff --git a/common/scripted_triggers/wc_casus_belli_triggers.txt b/common/scripted_triggers/wc_casus_belli_triggers.txt new file mode 100644 index 0000000000..5317722ff9 --- /dev/null +++ b/common/scripted_triggers/wc_casus_belli_triggers.txt @@ -0,0 +1,30 @@ +genocide_cb_can_avenge_culture = { + scope:defender = { + any_realm_county = { + trigger_if = { + limit = { + has_variable = culture_genocided + } + var:culture_genocided = scope:attacker.culture + } + trigger_else = { + always = no + } + } + } +} +genocide_cb_can_avenge_faith = { + scope:defender = { + any_realm_county = { + trigger_if = { + limit = { + has_variable = faith_genocided + } + var:faith_genocided = scope:attacker.faith + } + trigger_else = { + always = no + } + } + } +} \ No newline at end of file diff --git a/common/scripted_triggers/wc_genocide_triggers.txt b/common/scripted_triggers/wc_genocide_triggers.txt new file mode 100644 index 0000000000..ad60f89c23 --- /dev/null +++ b/common/scripted_triggers/wc_genocide_triggers.txt @@ -0,0 +1,602 @@ +# TODO: Infusion 2024, replace a lot of the corruption checks with infusion checks + +################################# +# Corruption # +################################# + +####################### +# Is corrupted # +####################### + +has_corruption_modifier_trigger = { + OR = { + has_county_modifier = county_corruption_light_modifier + has_county_modifier = county_corruption_void_modifier + has_county_modifier = county_corruption_arcane_modifier + has_county_modifier = county_corruption_fel_modifier + has_county_modifier = county_corruption_life_modifier + has_county_modifier = county_corruption_death_modifier + } +} + +# Check if province is corrupted with the modifier beneficial to the liege, with specific magic type +has_beneficial_corruption_this_province_specific_trigger = { + has_county_modifier = $MOD$ + + scope:councillor_liege = { + OR = { + can_corrupt_specific_trigger = { BEING = $BEING$ MAGIC = $MAGIC$ } + faith = { + OR = { + has_doctrine = doctrine_$MAGIC$_magic_approved + has_doctrine = doctrine_$MAGIC$_magic_accepted + } + } + } + NOT = { + has_trait = $BEING_OPPOSITE$ + } + } + trigger_if = { + limit = { scope:councillor_liege = { is_independent_ruler = no } } + scope:councillor_liege.top_liege = { + OR = { + can_corrupt_specific_trigger = { BEING = $BEING$ MAGIC = $MAGIC$ } + faith = { + OR = { + has_doctrine = doctrine_$MAGIC$_magic_approved + has_doctrine = doctrine_$MAGIC$_magic_accepted + } + } + } + NOT = { + has_trait = $BEING_OPPOSITE$ + } + } + } +} + +# Check if province is corrupted with the modifier beneficial to the liege, with any magic type +has_beneficial_corruption_this_province_trigger = { + OR = { + has_beneficial_corruption_this_province_specific_trigger = { BEING = being_light BEING_OPPOSITE = being_void MAGIC = light MOD = county_corruption_light_modifier } + has_beneficial_corruption_this_province_specific_trigger = { BEING = being_void BEING_OPPOSITE = being_light MAGIC = shadow MOD = county_corruption_void_modifier } + has_beneficial_corruption_this_province_specific_trigger = { BEING = being_order BEING_OPPOSITE = being_demon MAGIC = order MOD = county_corruption_arcane_modifier } + has_beneficial_corruption_this_province_specific_trigger = { BEING = being_demon BEING_OPPOSITE = being_order MAGIC = disorder MOD = county_corruption_fel_modifier } + has_beneficial_corruption_this_province_specific_trigger = { BEING = being_life BEING_OPPOSITE = being_undead MAGIC = life MOD = county_corruption_life_modifier } + has_beneficial_corruption_this_province_specific_trigger = { BEING = being_undead BEING_OPPOSITE = being_life MAGIC = death MOD = county_corruption_death_modifier } + } +} + +has_same_corruption_trigger = { + trigger_if = { + limit = { + $COUNTY_1$ = { + has_county_modifier = county_corruption_light_modifier + } + } + $COUNTY_2$ = { + has_county_modifier = county_corruption_light_modifier + } + } + trigger_else_if = { + limit = { + $COUNTY_1$ = { + has_county_modifier = county_corruption_void_modifier + } + } + $COUNTY_2$ = { + has_county_modifier = county_corruption_void_modifier + } + } + trigger_else_if = { + limit = { + $COUNTY_1$ = { + has_county_modifier = county_corruption_arcane_modifier + } + } + $COUNTY_2$ = { + has_county_modifier = county_corruption_arcane_modifier + } + } + trigger_else_if = { + limit = { + $COUNTY_1$ = { + has_county_modifier = county_corruption_fel_modifier + } + } + $COUNTY_2$ = { + has_county_modifier = county_corruption_fel_modifier + } + } + trigger_else_if = { + limit = { + $COUNTY_1$ = { + has_county_modifier = county_corruption_life_modifier + } + } + $COUNTY_2$ = { + has_county_modifier = county_corruption_life_modifier + } + } + trigger_else_if = { + limit = { + $COUNTY_1$ = { + has_county_modifier = county_corruption_death_modifier + } + } + $COUNTY_2$ = { + has_county_modifier = county_corruption_death_modifier + } + } + trigger_else = { + always = no + } +} + +####################### +# Can be corrupted # +####################### + +# Check if the character is allowed the Corrupt action instead of Purge +can_corrupt_trigger = { + OR = { + has_being_trait_trigger = yes + has_culture_being_trait_gfx_trigger = yes + AND = { + evil_public_religion_trigger = yes + faith = { + OR = { + has_doctrine = doctrine_light_magic_approved + has_doctrine = doctrine_shadow_magic_approved + has_doctrine = doctrine_order_magic_approved + has_doctrine = doctrine_disorder_magic_approved + has_doctrine = doctrine_life_magic_approved + has_doctrine = doctrine_death_magic_approved + } + } + } + } +} + +# Check if character can corrupt a specific magic type +can_corrupt_specific_trigger = { + OR = { + has_trait = $BEING$ + culture = { + has_clothing_gfx = $BEING$_gfx + } + AND = { + evil_public_religion_trigger = yes + faith = { + has_doctrine = doctrine_$MAGIC$_magic_approved + } + } + } +} + +can_corrupt_at_game_start_specific_trigger = { + OR = { + culture = { + has_clothing_gfx = $BEING$_gfx + } + AND = { + evil_public_religion_trigger = yes + faith = { + has_doctrine = doctrine_$MAGIC$_magic_approved + } + } + } +} + +# This is very clunky, but also the only way to get the tooltip to work properly +can_corrupt_this_province_valid_trigger = { + trigger_if = { + limit = { + OR = { + NOT = { has_county_modifier = $MOD$ } + NOT = { culture = scope:councillor_liege.culture } + NOT = { faith = scope:councillor_liege.faith } + } + } + always = yes + } + trigger_else = { + custom_tooltip = { + text = COUNTY_IS_YOUR_CULTURE + always = no + } + custom_tooltip = { + text = COUNTY_IS_YOUR_FAITH + always = no + } + custom_tooltip = { + text = COUNTY_ALREADY_CORRUPTED + always = no + } + } +} + +# Check if the liege will approve corruption, with a specific magic type +can_corrupt_this_province_liege_trigger = { + trigger_if = { + limit = { scope:councillor_liege = { is_independent_ruler = no } } + custom_tooltip = { + text = genocide_liege_disapproves + scope:councillor_liege.top_liege = { + can_corrupt_specific_trigger = { BEING = $BEING$ MAGIC = $MAGIC$ } + } + } + } +} + +# Check if the Corrupt task can be used on a county, with a any magic type +allow_corrupt_this_province_trigger = { + trigger_if = { + limit = { + scope:councillor_liege = { + can_corrupt_specific_trigger = { BEING = being_light MAGIC = light } + } + } + can_corrupt_this_province_valid_trigger = { MOD = county_corruption_light_modifier } + can_corrupt_this_province_liege_trigger = { BEING = being_light MAGIC = light } + } + trigger_else_if = { + limit = { + scope:councillor_liege = { + can_corrupt_specific_trigger = { BEING = being_void MAGIC = shadow } + } + } + can_corrupt_this_province_valid_trigger = { MOD = county_corruption_void_modifier } + can_corrupt_this_province_liege_trigger = { BEING = being_void MAGIC = shadow } + } + trigger_else_if = { + limit = { + scope:councillor_liege = { + can_corrupt_specific_trigger = { BEING = being_order MAGIC = order } + } + } + can_corrupt_this_province_valid_trigger = { MOD = county_corruption_arcane_modifier } + can_corrupt_this_province_liege_trigger = { BEING = being_order MAGIC = order } + } + trigger_else_if = { + limit = { + scope:councillor_liege = { + can_corrupt_specific_trigger = { BEING = being_demon MAGIC = disorder } + } + } + can_corrupt_this_province_valid_trigger = { MOD = county_corruption_fel_modifier } + can_corrupt_this_province_liege_trigger = { BEING = being_demon MAGIC = disorder } + } + trigger_else_if = { + limit = { + scope:councillor_liege = { + can_corrupt_specific_trigger = { BEING = being_life MAGIC = life } + } + } + can_corrupt_this_province_valid_trigger = { MOD = county_corruption_life_modifier } + can_corrupt_this_province_liege_trigger = { BEING = being_life MAGIC = life } + } + trigger_else_if = { + limit = { + scope:councillor_liege = { + can_corrupt_specific_trigger = { BEING = being_undead MAGIC = death } + } + } + can_corrupt_this_province_valid_trigger = { MOD = county_corruption_death_modifier } + can_corrupt_this_province_liege_trigger = { BEING = being_undead MAGIC = death } + } + trigger_else = { + always = no + } +} + +################################# +# Corruption modifier scale # +################################# + +corruption_scale_specific_trigger = { + var:corruption_type ?= flag:$MOD$ + holder = { + trigger_if = { + limit = { + $IS_EXTREME$ = yes + } + NOT = { + has_trait = $BEING_OPPOSITE$ + } + } + OR = { + trigger_if = { + limit = { + $IS_EXTREME$ = yes + } + OR = { + has_trait = $BEING$ + culture = { + has_clothing_gfx = $BEING$_gfx + } + } + } + faith = { + has_doctrine = doctrine_$MAGIC$_magic_$MAGIC_LEVEL$ + } + } + } +} + +corruption_scale_extreme_pos_trigger = { + OR = { + corruption_scale_specific_trigger = { IS_EXTREME = yes BEING = being_light BEING_OPPOSITE = being_void MAGIC = light MAGIC_LEVEL = approved MOD = county_corruption_light_modifier } + corruption_scale_specific_trigger = { IS_EXTREME = yes BEING = being_void BEING_OPPOSITE = being_light MAGIC = shadow MAGIC_LEVEL = approved MOD = county_corruption_void_modifier } + corruption_scale_specific_trigger = { IS_EXTREME = yes BEING = being_order BEING_OPPOSITE = being_demon MAGIC = order MAGIC_LEVEL = approved MOD = county_corruption_arcane_modifier } + corruption_scale_specific_trigger = { IS_EXTREME = yes BEING = being_demon BEING_OPPOSITE = being_order MAGIC = disorder MAGIC_LEVEL = approved MOD = county_corruption_fel_modifier } + corruption_scale_specific_trigger = { IS_EXTREME = yes BEING = being_life BEING_OPPOSITE = being_undead MAGIC = life MAGIC_LEVEL = approved MOD = county_corruption_life_modifier } + corruption_scale_specific_trigger = { IS_EXTREME = yes BEING = being_undead BEING_OPPOSITE = being_life MAGIC = death MAGIC_LEVEL = approved MOD = county_corruption_death_modifier } + } +} + +corruption_scale_mild_pos_trigger = { + OR = { + corruption_scale_specific_trigger = { IS_EXTREME = no BEING = being_light BEING_OPPOSITE = being_void MAGIC = light MAGIC_LEVEL = accepted MOD = county_corruption_light_modifier } + corruption_scale_specific_trigger = { IS_EXTREME = no BEING = being_void BEING_OPPOSITE = being_light MAGIC = shadow MAGIC_LEVEL = accepted MOD = county_corruption_void_modifier } + corruption_scale_specific_trigger = { IS_EXTREME = no BEING = being_order BEING_OPPOSITE = being_demon MAGIC = order MAGIC_LEVEL = accepted MOD = county_corruption_arcane_modifier } + corruption_scale_specific_trigger = { IS_EXTREME = no BEING = being_demon BEING_OPPOSITE = being_order MAGIC = disorder MAGIC_LEVEL = accepted MOD = county_corruption_fel_modifier } + corruption_scale_specific_trigger = { IS_EXTREME = no BEING = being_life BEING_OPPOSITE = being_undead MAGIC = life MAGIC_LEVEL = accepted MOD = county_corruption_life_modifier } + corruption_scale_specific_trigger = { IS_EXTREME = no BEING = being_undead BEING_OPPOSITE = being_life MAGIC = death MAGIC_LEVEL = accepted MOD = county_corruption_death_modifier } + } +} + +corruption_scale_extreme_neg_trigger = { + OR = { + corruption_scale_specific_trigger = { IS_EXTREME = yes BEING = being_void BEING_OPPOSITE = being_light MAGIC = light MAGIC_LEVEL = crime MOD = county_corruption_light_modifier } + corruption_scale_specific_trigger = { IS_EXTREME = yes BEING = being_light BEING_OPPOSITE = being_void MAGIC = shadow MAGIC_LEVEL = crime MOD = county_corruption_void_modifier } + corruption_scale_specific_trigger = { IS_EXTREME = yes BEING = being_demon BEING_OPPOSITE = being_order MAGIC = order MAGIC_LEVEL = crime MOD = county_corruption_arcane_modifier } + corruption_scale_specific_trigger = { IS_EXTREME = yes BEING = being_order BEING_OPPOSITE = being_demon MAGIC = disorder MAGIC_LEVEL = crime MOD = county_corruption_fel_modifier } + corruption_scale_specific_trigger = { IS_EXTREME = yes BEING = being_undead BEING_OPPOSITE = being_life MAGIC = life MAGIC_LEVEL = crime MOD = county_corruption_life_modifier } + corruption_scale_specific_trigger = { IS_EXTREME = yes BEING = being_life BEING_OPPOSITE = being_undead MAGIC = death MAGIC_LEVEL = crime MOD = county_corruption_death_modifier } + } +} + +corruption_scale_mild_neg_trigger = { + OR = { + corruption_scale_specific_trigger = { IS_EXTREME = no BEING = being_void BEING_OPPOSITE = being_light MAGIC = light MAGIC_LEVEL = shunned MOD = county_corruption_light_modifier } + corruption_scale_specific_trigger = { IS_EXTREME = no BEING = being_light BEING_OPPOSITE = being_void MAGIC = shadow MAGIC_LEVEL = shunned MOD = county_corruption_void_modifier } + corruption_scale_specific_trigger = { IS_EXTREME = no BEING = being_demon BEING_OPPOSITE = being_order MAGIC = order MAGIC_LEVEL = shunned MOD = county_corruption_arcane_modifier } + corruption_scale_specific_trigger = { IS_EXTREME = no BEING = being_order BEING_OPPOSITE = being_demon MAGIC = disorder MAGIC_LEVEL = shunned MOD = county_corruption_fel_modifier } + corruption_scale_specific_trigger = { IS_EXTREME = no BEING = being_undead BEING_OPPOSITE = being_life MAGIC = life MAGIC_LEVEL = shunned MOD = county_corruption_life_modifier } + corruption_scale_specific_trigger = { IS_EXTREME = no BEING = being_life BEING_OPPOSITE = being_undead MAGIC = death MAGIC_LEVEL = shunned MOD = county_corruption_death_modifier } + } +} + +################################# +# Cleanse # +################################# + +allow_cleanse_this_province_trigger = { + has_corruption_modifier_trigger = yes + NOT = { + has_beneficial_corruption_this_province_trigger = yes + } +} + +################################# +# Purge # +################################# + +# Monster cultures can genocide own heritage +monster_culture_trigger = { + OR = { + culture = culture:scourge + culture = culture:naga + culture = culture:satyr + culture = culture:faldorei + } +} + +# Can this character genocide their own heritage +can_genocide_own_culture_group_trigger = { + OR = { + monster_culture_trigger = yes + culture = { + has_cultural_pillar = heritage_mogu + } + $LIEGE$ = { + OR = { + monster_culture_trigger = yes + culture = { + has_cultural_pillar = heritage_mogu + } + } + } + } +} + +# Can this character genocide their own religion +can_genocide_own_religion_trigger = { + always = no + OR = { + $LIEGE$ = { + + } + } +} + +# Check if genocide should be allowed because they are evil +can_genocide_evil_trigger = { + OR = { + is_aggressive_trigger = yes + $LIEGE$ = { is_aggressive_trigger = yes } + evil_public_religion_trigger = yes + $LIEGE$ = { evil_public_religion_trigger = yes } + } +} + +has_faith_hostility_trigger = { + faith = { + faith_hostility_level = { + target = $LIEGE$.faith + value >= faith_$LEVEL$_level + } + } +} + +allow_character_genocide_this_province_culture_trigger = { + # These cultures can be genocided by their own group + OR = { + trigger_if = { + limit = { + can_genocide_own_culture_group_trigger = { LIEGE = $CHARACTER$ } + } + NOT = { culture = $CHARACTER$.culture } + } + trigger_else = { + NOT = { culture = { has_same_culture_heritage = $CHARACTER$.culture } } + } + + AND = { + NOT = { culture = $CHARACTER$.culture } + can_genocide_evil_trigger = { LIEGE = $CHARACTER$ } + } + } +} + +allow_genocide_this_province_parent_culture_trigger = { + trigger_if = { # AI shouldn't genocide parent/child cultures + limit = { + scope:councillor_liege = { + is_ai = yes + } + OR = { + scope:councillor_liege.culture = { + OR = { + is_hybrid_culture = yes + is_divergent_culture = yes + } + } + culture = { + OR = { + is_hybrid_culture = yes + is_divergent_culture = yes + } + } + } + } + culture = { + save_temporary_scope_as = culture_check + NOR = { + scope:councillor_liege.culture = { + any_parent_culture = { + this = scope:culture_check + } + } + any_parent_culture = { + this = scope:councillor_liege.culture + } + } + } + } +} + +allow_genocide_this_province_culture_trigger = { + allow_character_genocide_this_province_culture_trigger = { CHARACTER = $CHARACTER$ } + trigger_if = { # If the character is not independent, make sure their liege would approve + limit = { scope:councillor_liege = { is_independent_ruler = no } } + allow_character_genocide_this_province_culture_trigger = { CHARACTER = $CHARACTER$.top_liege } + } +} + +allow_character_genocide_this_province_religion_trigger = { + OR = { + # These religions can be genocided by their own group + trigger_if = { + limit = { + can_genocide_own_religion_trigger = { LIEGE = $CHARACTER$ } + } + NOT = { faith = $CHARACTER$.faith } + has_faith_hostility_trigger = { LIEGE = $CHARACTER$ LEVEL = astray } + } + trigger_else = { + NOT = { religion = $CHARACTER$.religion } + has_faith_hostility_trigger = { LIEGE = $CHARACTER$ LEVEL = hostile } + } + + AND = { + NOT = { faith = $CHARACTER$.faith } + can_genocide_evil_trigger = { LIEGE = $CHARACTER$ } + } + } +} + +allow_genocide_this_province_religion_trigger = { + allow_character_genocide_this_province_religion_trigger = { CHARACTER = $CHARACTER$ } + trigger_if = { # If the character is not independent, make sure their liege would approve + limit = { scope:councillor_liege = { is_independent_ruler = no } } + allow_character_genocide_this_province_religion_trigger = { CHARACTER = $CHARACTER$.top_liege } + } +} + +# This is the dumbest shit I've ever created +# Can't use OR = {} because the tooltip will only display triggers one level deep, so I came up with this shit instead +# Don't crucify me please +allow_genocide_this_province_trigger = { + trigger_if = { + limit = { + scope:councillor_liege = { + is_ai = yes + } + } + + NOT = { + scope:councillor_liege = { # AI should never genocide if they can cleanse first + any_sub_realm_county = { + allow_cleanse_this_province_trigger = yes + } + } + } + } + trigger_if = { + limit = { + OR = { + AND = { + allow_character_genocide_this_province_culture_trigger = { CHARACTER = scope:councillor_liege } + NOT = { + allow_genocide_this_province_religion_trigger = { CHARACTER = scope:councillor_liege } + } + NOT = { + allow_character_genocide_this_province_culture_trigger = { CHARACTER = scope:councillor_liege.top_liege } + } + } + AND = { + NOT = { + allow_genocide_this_province_culture_trigger = { CHARACTER = scope:councillor_liege } + } + allow_character_genocide_this_province_religion_trigger = { CHARACTER = scope:councillor_liege } + NOT = { + allow_character_genocide_this_province_religion_trigger = { CHARACTER = scope:councillor_liege.top_liege } + } + } + } + } + + custom_tooltip = { + text = genocide_liege_disapproves + always = no + } + } + trigger_else_if = { + limit = { + NAND = { + allow_genocide_this_province_culture_trigger = { CHARACTER = scope:councillor_liege } + allow_genocide_this_province_religion_trigger = { CHARACTER = scope:councillor_liege } + } + } + custom_tooltip = { + text = genocide_invalid_culture_faith + always = no + } + } + trigger_else = { + always = yes + } +} \ No newline at end of file diff --git a/common/scripted_triggers/wc_religious_triggers.txt b/common/scripted_triggers/wc_religious_triggers.txt index 81ebbfef40..8dcbdce58c 100644 --- a/common/scripted_triggers/wc_religious_triggers.txt +++ b/common/scripted_triggers/wc_religious_triggers.txt @@ -392,7 +392,9 @@ evil_public_religion_trigger = { } scope:faith = { - has_doctrine = doctrine_pluralism_dark + OR = { + has_doctrine = doctrine_pluralism_dark + } } } diff --git a/events/councillor_task_events/wc_genocide_task_events.txt b/events/councillor_task_events/wc_genocide_task_events.txt new file mode 100644 index 0000000000..7a2d369cbf --- /dev/null +++ b/events/councillor_task_events/wc_genocide_task_events.txt @@ -0,0 +1,1909 @@ +namespace = genocide_task + +genocide_task.0001 = { + type = character_event + title = genocide_task.0001.t + desc = genocide_task.0001.desc + theme = death + left_portrait = { + character = scope:councillor_liege + animation = personality_callous + } + + trigger = { + scope:county = { + has_county_modifier = ongoing_corruption_modifier + } + exists = cp:councillor_marshal + scope:councillor = cp:councillor_marshal + scope:councillor ?= { + martial < high_skill_rating + } + scope:county = { + any_neighboring_county = { + holder.top_liege = scope:county.holder.top_liege + } + } + } + + weight_multiplier = { + base = 1 + compare_modifier = { + target = scope:councillor + value = martial + multiplier = -0.2 + offset = inverted_high_skill_rating + } + } + + immediate = { + set_variable = { + name = had_genocide_task_side_effect + value = yes + days = genocide_task_side_effect_cooldown + } + + scope:county = { + every_neighboring_county = { + limit = { + this.holder.top_liege = scope:county.holder.top_liege + } + + add_county_modifier = { + modifier = corruption_disease_modifier + days = 100 + } + } + } + } + + option = { + name = genocide_task.0001.a + + stress_impact = { + zealous = major_dread_loss + sadistic = major_dread_loss + arbitrary = major_dread_loss + callous = major_dread_loss + + forgiving = major_stress_impact_gain + just = major_stress_impact_gain + generous = major_stress_impact_gain + compassionate = major_stress_impact_gain + } + + ai_chance = { + base = 50 + } + } +} + +genocide_task.0002 = { + type = character_event + title = genocide_task.0002.t + desc = genocide_task.0002.desc + theme = martial + override_background = { reference = burning_building } + left_portrait = { + character = scope:councillor + animation = worry + } + + right_portrait = { + character = scope:councillor_liege + animation = personality_rational + } + + trigger = { + scope:county = { + has_county_modifier = ongoing_corruption_modifier + } + exists = cp:councillor_marshal + scope:councillor = cp:councillor_marshal + scope:councillor ?= { + martial <= high_skill_rating + } + } + + weight_multiplier = { + base = 1 + compare_modifier = { + target = scope:councillor + value = martial + multiplier = -0.2 + offset = inverted_high_skill_rating + } + } + + immediate = { + set_variable = { + name = had_genocide_task_side_effect + value = yes + days = genocide_task_side_effect_cooldown + } + + stress_impact = { + paranoid = minor_stress_impact_gain + } + + scope:county = { + add_county_modifier = { + modifier = genocide_marauding_forces_modifier + days = 100 + } + + every_neighboring_county = { + add_county_modifier = { + modifier = genocide_marauding_forces_modifier + days = 100 + } + } + + culture = { + change_cultural_acceptance = { + target = scope:councillor_liege.culture + value = -5 + desc = genocide_task.0002.accpetance + } + } + } + } + + option = { + name = genocide_task.0002.a + + add_dread = 25 + add_gold = 25 + + stress_impact = { + forgiving = 25 + just = 25 + generous = 25 + compassionate = 25 + sadistic = -25 + arbitrary = -25 + callous = -25 + wrathful = -25 + vengeful = -25 + } + + scope:county = { + + remove_county_modifier = genocide_marauding_forces_modifier + add_county_modifier = { + modifier = genocide_purged_marauders_modifier + days = 100 + } + + every_neighboring_county = { + remove_county_modifier = genocide_marauding_forces_modifier + add_county_modifier = { + modifier = genocide_purged_marauders_modifier + days = 100 + } + } + } + + ai_chance = { + base = 50 + + ai_value_modifier = { + ai_compassion = -1.0 + } + } + } + + option = { + name = genocide_task.0002.b + + add_dread = -25 + + stress_impact = { + paranoid = minor_stress_impact_gain + ambitious = minor_stress_impact_gain + wrathful = minor_stress_impact_gain + vengeful = minor_stress_impact_gain + } + + ai_chance = { + base = 25 + + ai_value_modifier = { + ai_compassion = 1.0 + } + } + } +} + +genocide_task.0101 = { + type = character_event + title = genocide_task.0101.t + desc = genocide_task.0101.desc + theme = martial + left_portrait = { + character = scope:councillor_liege + animation = anger + } + + lower_left_portrait = { + character = scope:councillor + } + + right_portrait = { + character = scope:champion + animation = aggressive_spear + } + + trigger = { + scope:county = { + has_county_modifier = ongoing_cleansing_modifier + } + exists = cp:councillor_marshal + scope:councillor = cp:councillor_marshal + scope:councillor ?= { + martial < high_skill_rating + } + } + + weight_multiplier = { + base = 1 + compare_modifier = { + target = scope:councillor + value = martial + multiplier = -0.2 + offset = inverted_high_skill_rating + } + } + + immediate = { + set_variable = { + name = had_genocide_task_side_effect + value = yes + days = genocide_task_side_effect_cooldown + } + + if = { + limit = { + scope:county = { + OR = { + has_county_modifier = county_corruption_light_modifier + has_county_modifier = county_corruption_arcane_modifier + has_county_modifier = county_corruption_life_modifier + } + } + } + genocide_spawn_champion_effect = { CULTURE = scope:county.culture FAITH = scope:county.faith GOOD = yes } + } + else = { + genocide_spawn_champion_effect = { CULTURE = scope:county.culture FAITH = scope:county.faith GOOD = no } + } + + scope:champion = { + if = { + limit = { + has_being_trait_trigger = no + } + + genocide_add_champion_being_trait_effect = yes + } + } + } + + option = { + name = genocide_task.0101.a + duel = { + skill = prowess + target = scope:champion + 50 = { + compare_modifier = { + value = scope:duel_value + multiplier = 3.5 + min = -49 + } + send_interface_toast = { + add_prestige = minor_prestige_gain + scope:champion = { + override_death_killer_effect = { death_reason = death_duel killer = scope:councillor_liege } + } + title = travel_events.2200.b.success + left_icon = scope:champion + } + } + 50 = { + compare_modifier = { + value = scope:duel_value + multiplier = -3.5 + min = -49 + } + add_prestige = medium_prestige_loss + random_list = { + 80 = { + root= { + send_interface_toast = { + current_travel_plan = { + every_entourage_character = { + custom = every_entourage_tt + add_opinion = { + target = root + modifier = respect_opinion + opinion = -20 + } + } + } + + + title = travel_events.2200.b.failure + left_icon = scope:champion + } + } + } + 20 = { + root = { + send_interface_toast = { + title = travel_events.2200.b.failure + left_icon = scope:champion + increase_wounds_no_death_effect = { REASON = fight } + } + } + } + } + } + } + + stress_impact = { + brave = minor_stress_impact_loss + wrathful = medium_stress_impact_loss + craven = medium_stress_impact_gain + } + + ai_chance = { + base = 50 + + ai_value_modifier = { + ai_boldness = 1.0 + } + } + } + + option = { + name = genocide_task.0101.b + scope:councillor = { + duel = { + skill = prowess + target = scope:champion + 50 = { + compare_modifier = { + value = scope:duel_value + multiplier = 3.5 + min = -49 + } + send_interface_toast = { + add_prestige = minor_prestige_gain + scope:champion = { + override_death_killer_effect = { death_reason = death_duel killer = scope:councillor } + } + title = travel_events.2200.b.success + left_icon = scope:champion + } + } + 50 = { + compare_modifier = { + value = scope:duel_value + multiplier = -3.5 + min = -49 + } + add_prestige = medium_prestige_loss + random_list = { + 80 = { + root= { + send_interface_toast = { + current_travel_plan = { + every_entourage_character = { + custom = every_entourage_tt + add_opinion = { + target = root + modifier = respect_opinion + opinion = -20 + } + } + } + + + title = travel_events.2200.b.failure + left_icon = scope:champion + } + } + } + 20 = { + root = { + send_interface_toast = { + title = travel_events.2200.b.failure + left_icon = scope:champion + increase_wounds_no_death_effect = { REASON = fight } + } + } + } + } + } + } + } + + stress_impact = { + brave = minor_stress_impact_gain + wrathful = medium_stress_impact_gain + craven = medium_stress_impact_loss + } + + ai_chance = { + base = 20 + + ai_value_modifier = { + ai_boldness = -1.0 + } + } + } +} + +genocide_task.0102 = { + type = character_event + title = genocide_task.0102.t + desc = genocide_task.0102.desc + theme = martial + left_portrait = { + character = scope:councillor_liege + animation = personality_zealous + } + + trigger = { + scope:county = { + has_county_modifier = ongoing_cleansing_modifier + } + exists = cp:councillor_marshal + scope:councillor = cp:councillor_marshal + scope:councillor ?= { + martial < high_skill_rating + } + OR = { + AND = { + OR = { + OR = { + has_trait = magic_good + has_trait = magic_good_noninheritable + } + scope:councillor = { + OR = { + has_trait = magic_good + has_trait = magic_good_noninheritable + } + } + } + scope:county = { + any_neighboring_county = { + has_corruption_modifier_trigger = yes + has_beneficial_corruption_this_province_trigger = no + } + } + } + scope:county = { + any_neighboring_county = { + any_neighboring_county = { + has_corruption_modifier_trigger = yes + has_beneficial_corruption_this_province_trigger = no + } + } + } + } + } + + weight_multiplier = { + base = 1 + compare_modifier = { + target = scope:councillor + value = martial + multiplier = -0.2 + offset = inverted_high_skill_rating + } + } + + immediate = { + set_variable = { + name = had_genocide_task_side_effect + value = yes + days = genocide_task_side_effect_cooldown + } + } + + option = { + name = genocide_task.0302.a + + trigger = { + exists = capital_county + OR = { + OR = { + has_trait = magic_good + has_trait = magic_good_noninheritable + } + scope:councillor = { + OR = { + has_trait = magic_good + has_trait = magic_good_noninheritable + } + } + } + scope:county = { + any_neighboring_county = { + has_corruption_modifier_trigger = yes + has_beneficial_corruption_this_province_trigger = no + } + } + } + + add_piety = -100 + + scope:county = { + add_county_modifier = genocide_controlled_energy_modifier + every_neighboring_county = { + limit = { + has_corruption_modifier_trigger = yes + has_beneficial_corruption_this_province_trigger = no + } + + add_county_modifier = genocide_controlled_energy_modifier + } + } + + ai_chance = { + base = 99 + } + + stress_impact = { + compassionate = minor_stress_impact_loss + arrogant = minor_stress_impact_gain + sadistic = medium_stress_impact_gain + } + } + + option = { + name = genocide_task.0302.b + + trigger = { + scope:county = { + any_neighboring_county = { + any_neighboring_county = { + has_corruption_modifier_trigger = yes + has_beneficial_corruption_this_province_trigger = no + } + } + } + } + + add_prestige = -100 + + scope:county = { + every_neighboring_county = { + save_temporary_scope_as = temp_county + if = { + limit = { + has_corruption_modifier_trigger = yes + has_beneficial_corruption_this_province_trigger = no + } + + add_to_list = counties + } + every_neighboring_county = { + limit = { + NOT = { + this = scope:county + } + has_corruption_modifier_trigger = yes + has_beneficial_corruption_this_province_trigger = no + } + + add_to_list = counties + } + } + } + + every_in_list = { + list = counties + + add_county_modifier = { + modifier = genocide_wild_energy_modifier + days = 100 + } + } + + stress_impact = { + compassionate = minor_stress_impact_gain + arrogant = minor_stress_impact_loss + sadistic = medium_stress_impact_loss + } + + ai_chance = { + base = 1 + } + } +} + +genocide_task.0201 = { # Re-flavored version of genocide_task.0001 for purge instead of corrupt + type = character_event + title = genocide_task.0201.t + desc = genocide_task.0201.desc + theme = death + left_portrait = { + character = scope:councillor_liege + animation = personality_callous + } + + trigger = { + scope:county = { + has_county_modifier = ongoing_genocide_modifier + } + exists = cp:councillor_marshal + scope:councillor = cp:councillor_marshal + scope:councillor ?= { + martial < high_skill_rating + } + scope:county = { + any_neighboring_county = { + holder.top_liege = scope:county.holder.top_liege + } + } + } + + weight_multiplier = { + base = 1 + compare_modifier = { + target = scope:councillor + value = martial + multiplier = -0.2 + offset = inverted_high_skill_rating + } + } + + immediate = { + set_variable = { + name = had_genocide_task_side_effect + value = yes + days = genocide_task_side_effect_cooldown + } + + scope:county = { + every_neighboring_county = { + limit = { + this.holder.top_liege = scope:county.holder.top_liege + } + + add_county_modifier = { + modifier = genocidal_unrest_modifier + days = 100 + } + } + } + } + + option = { + name = genocide_task.0201.a + + stress_impact = { + zealous = major_stress_impact_loss + sadistic = major_stress_impact_loss + arbitrary = major_stress_impact_loss + callous = major_stress_impact_loss + + forgiving = major_stress_impact_gain + just = major_stress_impact_gain + generous = major_stress_impact_gain + compassionate = major_stress_impact_gain + } + + ai_chance = { + base = 50 + } + } +} + +genocide_task.0202 = { + type = character_event + title = genocide_task.0202.t + desc = genocide_task.0202.desc + theme = death + left_portrait = { + character = scope:councillor_liege + animation = anger + } + + right_portrait = { + character = scope:councillor + animation = shame + } + + lower_left_portrait = scope:target_ruler + + trigger = { + scope:county = { + has_county_modifier = ongoing_genocide_modifier + } + exists = cp:councillor_marshal + scope:councillor = cp:councillor_marshal + scope:councillor ?= { + martial < high_skill_rating + } + any_neighboring_and_across_water_top_liege_realm_owner = { + any_realm_border_county = { + any_neighboring_county = { + holder.top_liege = scope:county.holder.top_liege + } + title_province = { + squared_distance = { + target = scope:county + value < squared_distance_medium + } + } + } + } + } + + weight_multiplier = { + base = 1 + compare_modifier = { + target = scope:councillor + value = martial + multiplier = -0.2 + offset = inverted_high_skill_rating + } + } + + immediate = { + set_variable = { + name = had_genocide_task_side_effect + value = yes + days = genocide_task_side_effect_cooldown + } + + random_neighboring_and_across_water_top_liege_realm_owner = { + limit = { + any_realm_border_county = { + any_neighboring_county = { + holder.top_liege = scope:county.holder.top_liege + } + title_province = { + squared_distance = { + target = scope:county + value < squared_distance_medium + } + } + } + } + random_realm_border_county = { + limit = { + any_neighboring_county = { + holder.top_liege = scope:county.holder.top_liege + } + title_province = { + squared_distance = { + target = scope:county + value < squared_distance_medium + } + } + } + + save_scope_as = target_county + } + } + + every_realm_county = { + limit = { + trigger_if = { + limit = { + allow_genocide_this_province_culture_trigger = { CHARACTER = scope:councillor_liege } + } + + culture = scope:county.culture + } + + trigger_if = { + limit = { + allow_genocide_this_province_religion_trigger = { CHARACTER = scope:councillor_liege } + } + + faith = scope:county.faith + } + } + + add_county_modifier = { + modifier = genocide_emigration_modifier + days = 100 + } + } + + scope:target_county = { + add_county_modifier = { + modifier = genocide_immigration_modifier + days = 100 + } + + holder.top_liege = { + save_scope_as = target_ruler + } + } + + add_unpressed_claim = scope:target_county + + if = { + limit = { + can_set_relation_potential_rival_trigger = { + CHARACTER = scope:target_ruler + } + } + set_relation_potential_rival = scope:target_ruler + } + + stress_impact = { + paranoid = major_stress_impact_gain + arrogant = minor_stress_impact_gain + trusting = minor_stress_impact_loss + humble = minor_stress_impact_loss + } + } + + option = { + name = genocide_task.0202.a + + ai_chance = { + base = 50 + } + } +} + +genocide_task.0301 = { + type = character_event + title = genocide_task.0301.t + desc = genocide_task.0301.desc + theme = martial + override_background = { reference = burning_building } + left_portrait = { + character = cp:councillor_court_chaplain + animation = personality_zealous + } + + right_portrait = { + character = scope:councillor_liege + animation = throne_room_kneel_1 + } + + lower_center_portrait = { + character = scope:councillor + } + + trigger = { + scope:county = { + has_county_modifier = ongoing_corruption_modifier + } + exists = cp:councillor_marshal + scope:councillor = cp:councillor_marshal + scope:councillor ?= { + martial >= high_skill_rating + } + cp:councillor_court_chaplain ?= { + learning > mediocre_skill_rating + } + } + + weight_multiplier = { + base = 1 + compare_modifier = { + target = scope:councillor + value = martial + multiplier = 0.15 + offset = inverted_high_skill_rating + } + compare_modifier = { + target = cp:councillor_court_chaplain + value = learning + multiplier = 0.05 + offset = inverted_mediocre_skill_rating + } + } + + immediate = { + cp:councillor_court_chaplain = { + save_scope_as = cp_court_chaplain + } + set_variable = { + name = had_genocide_task_side_effect + value = yes + days = genocide_task_side_effect_cooldown + } + } + + option = { + name = genocide_task.0301.a + + add_dread = major_dread_gain + + stress_impact = { + forgiving = major_stress_impact_gain + just = major_stress_impact_gain + generous = major_stress_impact_gain + compassionate = major_stress_impact_gain + } + + ai_chance = { + base = 50 + + ai_value_modifier = { + ai_compassion = -1.0 + } + } + } + + option = { + name = genocide_task.0301.b + + add_piety = 100 + + stress_impact = { + zealous = minor_stress_impact_gain + sadistic = minor_stress_impact_gain + callous = minor_stress_impact_gain + } + + ai_chance = { + base = 50 + + ai_value_modifier = { + ai_zeal = 1.0 + } + } + } + + option = { + name = genocide_task.0301.c + + trigger = { + OR = { + has_trait = magic_good + has_trait = magic_good_noninheritable + } + } + + add_dread = medium_dread_gain + add_piety = minor_piety_value + add_character_modifier = { + modifier = harmonize_with_force_modifier + days = 100 + } # TODO: Infusion 2024, add infusion + + ai_chance = { + base = 250 + } + } +} + +genocide_task.0302 = { + type = character_event + title = genocide_task.0302.t + desc = genocide_task.0302.desc + theme = martial + left_portrait = { + character = scope:councillor_liege + animation = personality_zealous + } + + trigger = { + scope:county = { + has_county_modifier = ongoing_corruption_modifier + } + exists = cp:councillor_marshal + scope:councillor = cp:councillor_marshal + scope:councillor ?= { + martial >= high_skill_rating + } + OR = { + OR = { + OR = { + has_trait = magic_good + has_trait = magic_good_noninheritable + } + scope:councillor = { + OR = { + has_trait = magic_good + has_trait = magic_good_noninheritable + } + } + } + scope:county = { + any_neighboring_county = { + any_neighboring_county = { + has_beneficial_corruption_this_province_trigger = yes + } + } + } + } + } + + weight_multiplier = { + base = 1 + compare_modifier = { + target = scope:councillor + value = martial + multiplier = 0.2 + offset = inverted_high_skill_rating + } + } + + immediate = { + set_variable = { + name = had_genocide_task_side_effect + value = yes + days = genocide_task_side_effect_cooldown + } + } + + option = { + name = genocide_task.0302.a + + trigger = { + exists = capital_county + OR = { + OR = { + has_trait = magic_good + has_trait = magic_good_noninheritable + } + scope:councillor = { + OR = { + has_trait = magic_good + has_trait = magic_good_noninheritable + } + } + } + } + + add_piety = 100 + + capital_county = { + add_county_modifier = genocide_channelled_energy_modifier + } + + ai_chance = { + base = 50 + + ai_value_modifier = { + ai_greed = 1.0 + } + } + } + + option = { + name = genocide_task.0302.b + + trigger = { + scope:county = { + any_neighboring_county = { + any_neighboring_county = { + has_beneficial_corruption_this_province_trigger = yes + } + } + } + } + + add_prestige = 100 + + scope:county = { + every_neighboring_county = { + save_temporary_scope_as = temp_county + if = { + limit = { + has_beneficial_corruption_this_province_trigger = yes + } + + add_to_list = counties + } + every_neighboring_county = { + limit = { + NOT = { + this = scope:county + } + has_beneficial_corruption_this_province_trigger = yes + } + + add_to_list = counties + } + } + } + + every_in_list = { + list = counties + + add_county_modifier = { + modifier = genocide_dispersed_energy_modifier + days = 100 + } + } + + ai_chance = { + base = 50 + } + } +} + +genocide_task.0402 = { + type = character_event + title = genocide_task.0402.t + desc = genocide_task.0402.desc + theme = martial + override_background = { reference = burning_building } + + left_portrait = { + character = scope:councillor_liege + animation = happiness + } + + right_portrait = { + character = scope:councillor + animation = marshal + } + + trigger = { + scope:county = { + has_county_modifier = ongoing_cleansing_modifier + } + exists = cp:councillor_marshal + scope:councillor = cp:councillor_marshal + scope:councillor ?= { + martial >= high_skill_rating + } + } + + weight_multiplier = { + base = 1 + compare_modifier = { + target = scope:councillor + value = martial + multiplier = 0.2 + offset = inverted_high_skill_rating + } + } + + immediate = { + set_variable = { + name = had_genocide_task_side_effect + value = yes + days = genocide_task_side_effect_cooldown + } + } + + option = { + name = genocide_task.0402.a + + add_dread = major_dread_gain + + stress_impact = { + forgiving = major_stress_impact_gain + just = major_stress_impact_gain + generous = major_stress_impact_gain + compassionate = major_stress_impact_gain + } + + ai_chance = { + base = 50 + + ai_value_modifier = { + ai_compassion = -1.0 + } + } + } + + option = { + name = genocide_task.0402.b + + add_prestige = 100 + + stress_impact = { + zealous = minor_stress_impact_gain + sadistic = minor_stress_impact_gain + callous = minor_stress_impact_gain + just = minor_stress_impact_loss + generous = minor_stress_impact_loss + } + + ai_chance = { + base = 50 + + ai_value_modifier = { + ai_compassion = 1.0 + } + } + } + + option = { + name = genocide_task.0402.c + skill = learning + + trigger = { + learning >= 20 + } + + stress_impact = { + zealous = minor_stress_impact_loss + sadistic = minor_stress_impact_loss + forgiving = medium_stress_impact_gain + just = minor_stress_impact_gain + generous = medium_stress_impact_gain + compassionate = major_stress_impact_gain + } + + add_dread = medium_dread_gain + add_piety = minor_prestige_value + add_character_modifier = { + modifier = sacrificed_cleansing_targets_modifier + days = 100 + } + + ai_chance = { + base = 250 + } + } +} + +genocide_task.0401 = { + type = character_event + title = genocide_task.0401.t + desc = genocide_task.0401.desc + theme = martial + override_background = { reference = burning_building } + left_portrait = { + character = scope:councillor_liege + animation = ecstasy + } + + right_portrait = { + character = scope:councillor + animation = marshal + } + + trigger = { + scope:county = { + has_county_modifier = ongoing_cleansing_modifier + } + exists = cp:councillor_marshal + scope:councillor = cp:councillor_marshal + scope:councillor ?= { + martial >= high_skill_rating + } + } + + weight_multiplier = { + base = 1 + compare_modifier = { + target = scope:councillor + value = martial + multiplier = 0.2 + offset = inverted_high_skill_rating + } + } + + immediate = { + set_variable = { + name = had_genocide_task_side_effect + value = yes + days = genocide_task_side_effect_cooldown + } + } + + option = { + name = genocide_task.0401.a + + scope:county = { + custom_tooltip = genocide_task.0401.a.progress + change_variable = { + name = purge_population_current_progress + add = 4 + } + } + + ai_chance = { + base = 50 + + ai_value_modifier = { + ai_zeal = 1.0 + } + } + } + + option = { + name = genocide_task.0401.b + + spawn_army = { + name = genocide_task.0401.army_name + levies = { + scope:county = { + add = { + value = total_county_levies + divide = 10 + } + } + if = { + limit = { + highest_held_title_tier = tier_county + } + add = 50 + } + else_if = { + limit = { + highest_held_title_tier = tier_duchy + } + + add = 100 + } + else_if = { + limit = { + highest_held_title_tier = tier_kingdom + } + + add = 250 + } + else_if = { + limit = { + highest_held_title_tier = tier_empire + } + + add = 500 + } + } + location = scope:county.title_province + inheritable = no + uses_supply = yes + } + + ai_chance = { + base = 50 + + ai_value_modifier = { + ai_greed = 1.0 + } + } + } +} + +genocide_task.0501 = { + type = character_event + title = genocide_task.0501.t + desc = genocide_task.0501.desc + theme = martial + left_portrait = { + character = scope:councillor_liege + animation = happiness + } + + lower_left_portrait = { + character = scope:councillor + } + + right_portrait = { + character = scope:champion + animation = admiration + } + + trigger = { + scope:county = { + has_county_modifier = ongoing_genocide_modifier + } + exists = cp:councillor_marshal + scope:councillor = cp:councillor_marshal + scope:councillor ?= { + martial >= high_skill_rating + } + } + + weight_multiplier = { + base = 1 + compare_modifier = { + target = scope:councillor + value = martial + multiplier = 0.2 + offset = inverted_high_skill_rating + } + } + + immediate = { + set_variable = { + name = had_genocide_task_side_effect + value = yes + days = genocide_task_side_effect_cooldown + } + + genocide_spawn_champion_effect = { CULTURE = scope:councillor_liege.culture FAITH = scope:councillor_liege.faith GOOD = yes } + } + + option = { + name = genocide_task.0501.a + + add_prestige = 100 + add_courtier = scope:champion + + ai_chance = { + base = 50 + + ai_value_modifier = { + ai_greed = 1.0 + } + } + } + + option = { + name = genocide_task.0501.b + + add_piety = 50 + add_character_modifier = { + modifier = genocide_local_champion_modifier + days = 100 + } + scope:champion = { + silent_disappearance_effect = yes + } + + ai_chance = { + base = 50 + + ai_value_modifier = { + ai_zeal = 1.0 + } + } + } +} + +genocide_task.0502 = { + type = character_event + title = genocide_task.0502.t + desc = genocide_task.0502.desc + theme = martial + left_portrait = { + character = scope:councillor_liege + animation = personality_zealous + } + + trigger = { + scope:county = { + has_county_modifier = ongoing_genocide_modifier + } + exists = cp:councillor_marshal + scope:councillor = cp:councillor_marshal + scope:councillor ?= { + martial >= high_skill_rating + } + OR = { + OR = { + has_trait = administrator + scope:councillor = { + has_trait = administrator + } + } + scope:county = { + any_neighboring_county = { + any_neighboring_county = { + OR = { + culture = scope:councillor_liege.culture + faith = scope:councillor_liege.faith + } + } + } + } + } + } + + weight_multiplier = { + base = 1 + compare_modifier = { + target = scope:councillor + value = martial + multiplier = 0.2 + offset = inverted_high_skill_rating + } + } + + immediate = { + set_variable = { + name = had_genocide_task_side_effect + value = yes + days = genocide_task_side_effect_cooldown + } + } + + option = { + name = genocide_task.0502.a + + trigger = { + exists = capital_county + OR = { + has_trait = administrator + scope:councillor = { + has_trait = administrator + } + } + } + + add_gold = 50 + + capital_county = { + add_county_modifier = genocide_focused_resources_modifier + } + + ai_chance = { + base = 50 + + ai_value_modifier = { + ai_greed = 1.0 + } + } + } + + option = { + name = genocide_task.0502.b + + trigger = { + scope:county = { + any_neighboring_county = { + any_neighboring_county = { + OR = { + culture = scope:councillor_liege.culture + faith = scope:councillor_liege.faith + } + } + } + } + } + + add_prestige = 100 + + scope:county = { + every_neighboring_county = { + save_temporary_scope_as = temp_county + if = { + limit = { + OR = { + culture = scope:councillor_liege.culture + faith = scope:councillor_liege.faith + } + } + + add_to_list = counties + } + every_neighboring_county = { + limit = { + NOT = { + this = scope:county + } + OR = { + culture = scope:councillor_liege.culture + faith = scope:councillor_liege.faith + } + } + + add_to_list = counties + } + } + } + + every_in_list = { + list = counties + + add_county_modifier = { + modifier = genocide_dispersed_resources_modifier + days = 100 + } + } + + ai_chance = { + base = 50 + + ai_value_modifier = { + ai_compassion = 1.0 + } + } + } +} + +genocide_task.2001 = { + type = character_event + title = genocide_task.2001.t + desc = { + first_valid = { + triggered_desc = { + trigger = { + OR = { + can_corrupt_specific_trigger = { BEING = being_void MAGIC = shadow } + can_corrupt_specific_trigger = { BEING = being_demon MAGIC = disorder } + can_corrupt_specific_trigger = { BEING = being_undead MAGIC = death } + } + } + desc = genocide_task.2001.desc.dark + } + triggered_desc = { + trigger = { + can_corrupt_specific_trigger = { BEING = being_light MAGIC = light } + } + desc = genocide_task.2001.desc.light + } + triggered_desc = { + trigger = { + can_corrupt_specific_trigger = { BEING = being_life MAGIC = life } + } + desc = genocide_task.2001.desc.nature + } + triggered_desc = { + trigger = { + can_corrupt_specific_trigger = { BEING = being_order MAGIC = order } + } + desc = genocide_task.2001.desc.arcane + } + } + } + theme = martial + left_portrait = { + character = scope:councillor_liege + animation = happiness + } + right_portrait = { + character = scope:holder + trigger = { + exists = scope:holder + } + animation = grief + } + + immediate = { + if = { + limit = { + scope:county = { + NOT = { + holder = scope:councillor_liege + } + } + } + + scope:county.holder = { + save_scope_as = holder + } + } + + scope:county = { + corrupt_county_effect = { ON_START = no } + } + } + + option = { + name = genocide_task.2001.a + } +} + +genocide_task.2101 = { + type = character_event + title = genocide_task.2101.t + desc = { + first_valid = { + triggered_desc = { + trigger = { + scope:county = { + OR = { + has_county_modifier = county_corruption_void_modifier + has_county_modifier = county_corruption_fel_modifier + has_county_modifier = county_corruption_death_modifier + } + } + } + desc = genocide_task.2101.desc.dark + } + triggered_desc = { + trigger = { + has_county_modifier = county_corruption_light_modifier + } + desc = genocide_task.2101.desc.light + } + triggered_desc = { + trigger = { + has_county_modifier = county_corruption_life_modifier + } + desc = genocide_task.2101.desc.nature + } + triggered_desc = { + trigger = { + has_county_modifier = county_corruption_arcane_modifier + } + desc = genocide_task.2101.desc.arcane + } + } + } + theme = martial + left_portrait = { + character = scope:councillor_liege + animation = happiness + } + right_portrait = { + character = scope:holder + trigger = { + exists = scope:holder + } + animation = grief + } + + immediate = { + if = { + limit = { + scope:county = { + NOT = { + holder = scope:councillor_liege + } + } + } + + scope:county.holder = { + save_scope_as = holder + } + } + + scope:county = { + cleanse_county_effect = yes + } + } + + option = { + name = genocide_task.2101.a + } +} + +genocide_task.2201 = { + type = character_event + title = genocide_task.2201.t + desc = { + desc = genocide_task.2201.desc + triggered_desc = { + trigger = { + scope:holder = { + NOT = { + this = scope:councillor_liege + } + NAND = { + culture = scope:councillor_liege.culture + faith = scope:councillor_liege.faith + } + } + } + desc = genocide_task.2201.desc.holder + } + } + theme = martial + left_portrait = { + character = scope:councillor_liege + animation = happiness + } + right_portrait = { + character = scope:holder + trigger = { + exists = scope:holder + } + animation = grief + } + + immediate = { + if = { + limit = { + scope:county = { + NOT = { + holder = scope:councillor_liege + } + } + } + + scope:county.holder = { + save_scope_as = holder + } + } + + scope:county = { + purge_population_effect = yes + } + } + + option = { + name = genocide_task.2201.a + + trigger = { + NOT = { + exists = scope:holder + } + } + } + + option = { + name = genocide_task.2201.a.holder + + trigger = { + scope:holder ?= { + NOT = { + this = scope:councillor_liege + } + NAND = { + culture = scope:councillor_liege.culture + faith = scope:councillor_liege.faith + } + } + } + } + + option = { + name = genocide_task.2201.b + + trigger = { + scope:holder ?= { + NOT = { + this = scope:councillor_liege + } + NAND = { + culture = scope:councillor_liege.culture + faith = scope:councillor_liege.faith + } + } + } + + scope:county = { + create_title_and_vassal_change = { + type = usurped + add_claim_on_loss = yes + save_scope_as = change + } + + change_title_holder = { + holder = scope:councillor_liege + change = scope:change + take_baronies = yes + } + + resolve_title_and_vassal_change = scope:change + } + } + + option = { + name = genocide_task.2201.c + + trigger = { + scope:holder ?= { + NOT = { + this = scope:councillor_liege + } + NAND = { + culture = scope:councillor_liege.culture + faith = scope:councillor_liege.faith + } + any_held_title = { + tier = tier_county + count = 1 + } + } + } + + scope:county = { + create_title_and_vassal_change = { + type = usurped + add_claim_on_loss = yes + save_scope_as = change + } + + change_title_holder = { + holder = scope:councillor_liege + change = scope:change + take_baronies = yes + } + + resolve_title_and_vassal_change = scope:change + } + + scope:holder = { + override_death_killer_effect = { + death_reason = death_execution + killer = scope:councillor_liege + } + } + } +} \ No newline at end of file diff --git a/gfx/interface/icons/council_task_types/task_purge_population.dds b/gfx/interface/icons/council_task_types/task_purge_population.dds new file mode 100644 index 0000000000..869bac63b1 Binary files /dev/null and b/gfx/interface/icons/council_task_types/task_purge_population.dds differ diff --git a/gfx/interface/icons/council_task_types/task_relocate_population.dds b/gfx/interface/icons/council_task_types/task_relocate_population.dds new file mode 100644 index 0000000000..36a49466c6 Binary files /dev/null and b/gfx/interface/icons/council_task_types/task_relocate_population.dds differ diff --git a/localization/english/event_localization/wc_genocide_task_events_l_english.yml b/localization/english/event_localization/wc_genocide_task_events_l_english.yml new file mode 100644 index 0000000000..dc2fad5527 --- /dev/null +++ b/localization/english/event_localization/wc_genocide_task_events_l_english.yml @@ -0,0 +1,111 @@ +l_english: + + GenocideEventRelevantMagic_Light:0 "$LIGHT_NAME$" + GenocideEventRelevantMagic_Void:0 "$SHADOW_NAME$" + GenocideEventRelevantMagic_Arcane:0 "Arcane" + GenocideEventRelevantMagic_Fel:0 "Demonic" + GenocideEventRelevantMagic_Life:0 "Nature" + GenocideEventRelevantMagic_Death:0 "Necrotic" + + GenocideEventRelevantGod_FaithGod:0 "[ROOT.Char.GetFaith.HighGodName]" + GenocideEventRelevantGod_Light:0 "$LIGHT_NAME$" + GenocideEventRelevantGod_Void:0 "$VOID_NAME$" + GenocideEventRelevantGod_Arcane:0 "$MAGIC_NAME$" + GenocideEventRelevantGod_Fel:0 "$SARGERAS_NAME$" + GenocideEventRelevantGod_Life:0 "$LIFE_NAME$" + GenocideEventRelevantGod_Death:0 "$DEATH_NAME$" + + GenocideEventRelevantPower_Holy:0 "Holy" + GenocideEventRelevantPower_Dark:0 "Dark" + GenocideEventRelevantPower_Arcane:0 "Arcane" + + GenocideEventRelevantName_Hallowed:0 "Hallowed" + GenocideEventRelevantName_Unholy:0 "Unholy" + + GenocideEventGenocidedPopulationsOr_Both:0 "$GenocideEventGenocidedPopulations_Culture$ or $GenocideEventGenocidedPopulations_Faith$" + + GenocideEventGenocidedPopulationsAnd_Both:0 "$GenocideEventGenocidedPopulations_Culture$ and $GenocideEventGenocidedPopulations_Faith$" + GenocideEventGenocidedPopulations_Culture:0 "[second.GetProvince.GetCounty.GetCulture.GetCollectiveNoun]" + GenocideEventGenocidedPopulations_Faith:0 "[second.GetProvince.GetCounty.GetFaith.GetAdjective]" + + genocide_task.0001.t:0 "Cursed Lands Spreading" + genocide_task.0001.desc:0 "The surfeit of evil deeds in [county.GetName] has resulted in the spread of magical corruption and plagues of all kinds.\n\nThose who do are not cowering in their homes death or stricken with illness instead languish in an inexplicable apathy. Our forces range back and forth across the land; killing anything that moves, stealing anything of value, and burning anything that can be put to the flame.\n\nWhile this wanton violence surely pleases [councillor_liege.Custom('GenocideEventRelevantGod')], this land is dying and its productivity suffers." + genocide_task.0001.a:0 "We shall reap the powers of [councillor_liege.GetFaith.PantheonTerm]!" + + genocide_task.0002.t:0 "Marauding Forces Cause Unrest" + genocide_task.0002.desc:0 "The efforts of our forces have done much to please [councillor_liege.Custom('GenocideEventRelevantGod')], but the mortals of this land are boundless in their impudence. Reports have begun to filter in from our collaborators, scouts, and spies in [county.GetName] that resistance is growing amongst the populace.\n\nOur forces must act quickly to destroy this growing threat or we shall risk looking weak in front of those among us who wish to usurp power." + genocide_task.0002.a:0 "Kill anything that moves! Make an example of them!" + genocide_task.0002.b:0 "Do not bother me with these trifling rumors!" + + genocide_task.0101.t:0 "A Champion's Challenge" + genocide_task.0101.desc:0 "Our purification of the lands of [county.GetName] continues to move forward unhindered. The [champion.Custom('GenocideEventRelevantPower')] magic that taints this land continues to resist and struggle against our might, sending incursions and challenges to hinder the progress of our warriors.\n\nThis time, the abominable magic has risen up a befouled champion that has challenged us to single combat. I could fight them myself and benefit from the gains of glory that I will bring to our cause but it does pose some significant risks..." + genocide_task.0101.a:0 "I will cleanse this champion myself." + genocide_task.0101.b:0 "Perhaps my marshal is up to the challenge." + + genocide_task.0102.t:0 "Uncontrolled Magic" + genocide_task.0102.desc:0 "Our purification of the lands of [county.GetName] has run into some unforeseen consequences. The magic that corrupts this land resists and struggles against our will and as a consequence it is now out of our control. If we don't make a decision immediately, this corruption will uncontrollably spread through the surrounding region." + genocide_task.0102.a:0 "Contain this outbreak." + genocide_task.0102.b:0 "Perhaps we should leave this land to its fate.." + + genocide_task.0201.t:0 "Deep Unrest Spreading" + genocide_task.0201.desc:0 "The surfeit of... regrettable deeds in [county.GetName] has resulted in the spread of unrest of all kinds.\n\nThose who are not struck down by our soldiers are cowering in their homes in fear or starving. Our forces range back and forth across the land; killing any [councillor_liege.Custom2_Title('GenocideEventGenocidedPopulationsOr', SCOPE.sTitle('county'))] that move, stealing anything of value, and burning anything that can be put to the flame.\n\nWhile this wanton violence will surely accomplish our goals, our people are suffering, and their productivity with them." + genocide_task.0201.a:0 "Let us hope we are soon finished." + + genocide_task.0202.t:0 "[councillor_liege.Custom2_Title('GenocideEventGenocidedPopulationsAnd', SCOPE.sTitle('county'))] Emigration" + genocide_task.0202.desc:0 "The recent actions in [county.GetName] has caused a large emigration from our realm, the [councillor_liege.Custom2_Title('GenocideEventGenocidedPopulationsAnd', SCOPE.sTitle('county'))] fleeing in droves.\n\nThe [target_ruler.Custom('InsultAdjective')] [target_ruler.GetName] has \"generously\" decided to take them in, luring them with promises of safety and security, settling them in [target_county.GetName].\n\nWhile our soldiers have attempted to stop the migration, they have not been very successful so far." + genocide_task.0202.a:0 "Damn that villain!" + + genocide_task.0301.t:0 "Brutal Demonstration of Devotion" + genocide_task.0301.desc:0 "Pillars of smoke rise into the night sky. Blotting out the moon, they are lit only by the fires of burning buildings, fields, and bodies. The screams and chaos of the massacre inflicted on this village in [county.GetName] have left an eerie calm and silence in their wake, broken only by the crackling inferno and the occasional crash of a falling timber. Silhouetted against the flame, your [court_chaplain|E] [cp_court_chaplain.GetShortUINameNoTooltip] stands in exultant prayer. Just a few paces behind, you kneels in supplication. The ritual, begun just after the slaughter itself, finally nears its completion.\n\n'Oh [councillor_liege.Custom('GenocideEventRelevantGod')]!" He implores, "Accept the Souls of these wretches that they may demonstrate our supplication to your infinite power. Accept the Blood upon our blades as proof of our fealty to you and your servant [councillor_liege.GetNameNoTooltip|V]. Accept the Fires that surround us as a solemn proof of your will enforced in [councillor_liege.GetPrimaryTitle.GetName]. Let this destruction and suffering please You; may these Souls, Blood, and Fire provide payment for another infinitesimal fraction of your [councillor_liege.Custom('GenocideEventRelevantPower')] Power! In thy [councillor_liege.Custom('GenocideEventRelevantName')] name we pray...'\n\nYou remains silent and motionless even as the first shivers and tingles of [councillor_liege.Custom('GenocideEventRelevantMagic')] Energy begin to course through your veins. With all the clarity your mind can muster, you wish..." + genocide_task.0301.a:0 "...to be feared by your subjects." + genocide_task.0301.b:0 "...only to have your dedication known." + genocide_task.0301.c:0 "...to harmonize your power with [councillor_liege.GetFaith.PantheonTerm]." + + genocide_task.0302.t:0 "Fuel for [councillor_liege.GetFaith.PantheonTerm]" + genocide_task.0302.desc:0 "I feel a twisted pleasure coil within me with every death that follows our forces. Their weak souls clinging to life like insects - buzzing and writhing in their futile struggle. Their energy - their souls, are nothing more than fodder for the power I command.\n\nTheir power flows through me as a torrent of life which has been twisted into the [councillor_liege.Custom('GenocideEventRelevantPower')] power that I now command. I can guide it, shape it, force it into whatever I will. All that remains is the decision of where to invest this magic..." + genocide_task.0302.a:0 "This power belongs to [councillor_liege.GetCapitalLocation.GetName]." + genocide_task.0302.b:0 "Disperse it to the local region." + + genocide_task.0401.t:0 "Fervor of Purification" + genocide_task.0401.desc:0 "The fervor of our fight against the [county.GetProvince.GetCounty.GetCulture.GetCollectiveNoun] is spreading throughout the surrounding areas, kindling a desire for purification among the inhabitants. Inspired by our determination, locals have risen up, ready to take up arms to restore the power of $GenocideEventRelevantGod_FaithGod$ within our lands.\n\nTheir fervor is admirable, but without proper direction, their zeal could become misdirected and destructive. Already, rumors are circulating about isolated acts of violence against individuals perceived as [county.Custom('GenocideEventRelevantNameCounty')]. What should we do with this newfound force?" + genocide_task.0401.a:0 "Let them make themselves useful!" + genocide_task.0401.a.progress:0 "The progress of the Cleansing in [county.GetName] is increased" + genocide_task.0401.b:0 "They will fight by our side." + + genocide_task.0402.t:0 "Fortress of the [county.GetProvince.GetCounty.GetCulture.GetCollectiveNounNoTooltip]" + genocide_task.0402.desc:0 "The fortress of the [county.GetProvince.GetCounty.GetCulture.GetCollectiveNoun] in [county.GetName] is falling beneath a brutal assault led by our forces. Flames consume the walls and smoke blackens the sky, our troops begin to loot the fortress and gather the exhausted and broken defenders under tight guard.\n\nThe chaos of battle has started to subside, the air still thick with the scent of blood, when [councillor.GetFirstName] approaches me, hand on the hilt of [councillor.GetHerHis] weapon.\n\n"[ROOT.Char.GetTitleAsNameNoTooltip|U], we have taken prisoners during the attack. They are at your mercy. We await your orders."" + genocide_task.0402.a:0 "They shall pray for mercy before we are done with them." + genocide_task.0402.b:0 "Put them out of their misery." + genocide_task.0402.c:0 "They shall make a worthy sacrifice for [councillor_liege.GetFaith.PantheonTerm]!" + + genocide_task.0501.t:0 "A Purging Hand" + genocide_task.0501.desc:0 "Our purge of these lands is progressing well.\n\nOne day, an unknown individual has approached my court. They appear to be a champion of [councillor_liege.Custom('GenocideEventRelevantGod')] who has resided in [county.GetName] and believe in our righteous cause. They wish to pledge fealty to me, and in exchange, I allow them to help in the purge of these lands. Naturally, it is up to me to best decide where they should fit." + genocide_task.0501.a:0 "They would better serve in my court." + genocide_task.0501.b:0 "Purging it is." + + genocide_task.0502.t:0 "Supplies Of The Weak" + genocide_task.0502.desc:0 "Death follows our forces as we march uninhibited through these lands; cleansing and purifying them in our image. The inhabitants scatter like insects who scamper and flee on our approach. During the purge of their lands it has become evident that several caches of their supplies have been abandoned. All that remains is the decision of where to invest these resources..." + genocide_task.0502.a:0 "Send these to [councillor_liege.GetCapitalLocation.GetName]." + genocide_task.0502.b:0 "Disperse it to the local region." + + genocide_task.2001.t:0 "The Corruption of [county.GetName]" + genocide_task.2001.desc.dark:0 "Dark energies ripple through the land as your ritual reaches its peak, twisting the very essence of the county.\n\nOnce vibrant and thriving, it now pulses with malevolent power, its inhabitants succumbing to the creeping corruption. The air grows heavy, the skies darken, and the once-fertile fields wither beneath your influence. You feel the dark magic coursing through the earth, binding the county to your will, transforming it into a bastion of your newfound power.\n\nThe deed is done; the land is yours, reshaped in your image, but at what cost?" + genocide_task.2001.desc.light:0 "Radiant energies surge through the land as your ritual reaches its zenith, infusing the county with divine might.\n\nOnce ordinary and unremarkable, it now glows with celestial brilliance, its inhabitants uplifted by the overwhelming holiness. The air sparkles with sanctity, the skies clear with divine light, and the once-barren fields flourish under your touch. You sense the sacred power coursing through the earth, binding the county to your will, transforming it into a shining testament to your grace.\n\nThe deed is done; the land is yours, reshaped in your image, but at what cost?" + genocide_task.2001.desc.nature:0 "Nature’s energies flow through the land as your ritual reaches its zenith, breathing new life into the county.\n\nOnce barren and neglected, it now teems with verdant vitality, its inhabitants rejuvenated by the wild magic. The air hums with the vibrant pulse of nature, the skies clear with a lush glow, and the once-dry fields bloom under your influence. You feel the natural magic weaving through the earth, binding the county to your will, transforming it into a lush sanctuary of your creation.\n\nThe deed is done; the land is yours, flourishing under your command, but at what cost?" + genocide_task.2001.desc.arcane:0 "Arcane energies ripple through the land as your ritual reaches its climax, infusing the county with otherworldly brilliance.\n\nOnce ordinary and mundane, it now shimmers with mystical power, its inhabitants entranced by the swirling magic. The air crackles with arcane sparks, the skies swirl with ethereal hues, and the once-drained fields now glisten with magical vitality. You feel the arcane force weaving through the earth, binding the county to your will, transforming it into a beacon of your arcane mastery.\n\nThe deed is done; the land is yours, redefined by your touch, but at what cost?" + genocide_task.2001.a:0 "The deed is done." + + genocide_task.2101.t:0 "The Cleansing of [county.GetName]" + genocide_task.2101.desc.dark:0 "The dark energies dissipate from the land as your ritual reaches its peak, restoring the very essence of the county.\n\nOnce tainted and withering, it now flourishes with renewed vitality, its inhabitants freed from the clutches of corruption. The air grows lighter, the skies clear, and the once-barren fields begin to bloom again under your influence. You feel the pure magic coursing through the earth, releasing the county from its blight, returning it to its former glory.\n\nThe deed is done; the land is healed, restored to its natural state, and peace reigns once more." + genocide_task.2101.desc.light:0 "The holy energies dissipate from the land as your ritual reaches its peak, restoring the very essence of the county.\n\nOnce overwhelmed by celestial brilliance, it now returns to its natural state, its inhabitants freed from the grip of divine influence. The air grows calmer, the skies lose their blinding light, and the once-flourishing fields return to their humble form under your touch. You feel the pure magic coursing through the earth, releasing the county from its sacred bindings, returning it to its former, unremarkable glory.\n\nThe deed is done; the land is cleansed, restored to its natural state, and balance reigns once more." + genocide_task.2101.desc.nature:0 "The natural energies dissipate from the land as your ritual reaches its peak, restoring the very essence of the county. Once teeming with vibrant life, it now returns to its original state, its inhabitants freed from the overwhelming presence of nature’s magic. The air grows still, the skies lose their lush hues, and the once-flourishing fields settle back into their modest form under your touch. You feel the pure magic withdrawing from the earth, releasing the county from its natural bindings, returning it to its former, unremarkable state.\n\nThe deed is done; the land is cleansed, restored to its natural condition, and balance reigns once more." + genocide_task.2101.desc.arcane:0 "The arcane energies dissipate from the land as your ritual reaches its peak, restoring the very essence of the county. Once infused with vibrant magic, it now returns to its original state, its inhabitants freed from the overwhelming presence of arcane power. The air grows still, the skies lose their shimmering aura, and the once-enchanted fields settle back into their modest form under your touch. You feel the pure magic withdrawing from the earth, releasing the county from its arcane bindings, returning it to its former, unremarkable state.\n\nThe deed is done; the land is cleansed, restored to its natural condition, and balance reigns once more." + genocide_task.2101.a:0 "The foul corruption has been defeated." + + genocide_task.2201.t:0 "The Purge of [county.GetName]" + genocide_task.2201.desc:0 "An oppressive silence settles over [county.GetNameNoTooltip] as your purge reaches its zenith. The undesirable elements are driven out, their presence vanishing like shadows at dawn. The land breathes freely again, its once-chaotic energy now subdued. You stand amidst the calm, knowing your work has restored order and peace." + genocide_task.2201.desc.holder:0 "\n\nThe question remains of what to do with [holder.GetShortUIName]." + genocide_task.2201.a:0 "A job well done." + genocide_task.2201.a.holder:0 "Leave them be." + genocide_task.2201.b:0 "This land does not belong to them!" + genocide_task.2201.c:0 "They shall go the way of their subjects!" \ No newline at end of file diff --git a/localization/english/modifiers/wc_modifiers_l_english.yml b/localization/english/modifiers/wc_modifiers_l_english.yml index 4ed0f106ba..428e6efce0 100644 --- a/localization/english/modifiers/wc_modifiers_l_english.yml +++ b/localization/english/modifiers/wc_modifiers_l_english.yml @@ -285,4 +285,43 @@ wc_troll_mogu_pact_thunder_king_modifier_desc:0 "The [thunder_king|E] has been resurrected a Zandalari [ruler|E].\n\nThey may call them into a defensive [war|E] once for each remaining stack of this [modifier|E] via a [character_interaction|E]." union_block_modifier:0 "Union Block" - union_block_modifier_desc:0 "This character has recently left their union and is left with the consequences of standing alone." \ No newline at end of file + union_block_modifier_desc:0 "This character has recently left their union and is left with the consequences of standing alone." + + ongoing_corruption_modifier:0 "Ongoing Corruption" + ongoing_cleansing_modifier:0 "Ongoing Cleansing" + ongoing_genocide_modifier:0 "Ongoing Purge" + + county_corruption_light_modifier:0 "Light Corruption" + county_corruption_light_modifier_desc:0 "This county has been corrupted by Light.\n\nEffects scale based on Light Magic [doctrines|E] and [traits|E]." + county_corruption_void_modifier:0 "Shadow Corruption" + county_corruption_void_modifier_desc:0 "This county has been corrupted by Shadow.\n\nEffects scale based on Shadow Magic [doctrines|E] and [traits|E]." + county_corruption_arcane_modifier:0 "Arcane Corruption" + county_corruption_arcane_modifier_desc:0 "This county has been corrupted by the Arcane.\n\nEffects scale based on Arcane Magic [doctrines|E] and [traits|E]." + county_corruption_fel_modifier:0 "Fel Corruption" + county_corruption_fel_modifier_desc:0 "This county has been corrupted by Fel.\n\nEffects scale based on Fel Magic [doctrines|E] and [traits|E]." + county_corruption_life_modifier:0 "Nature Corruption" + county_corruption_life_modifier_desc:0 "This county has been corrupted by Nature.\n\nEffects scale based on Nature Magic [doctrines|E] and [traits|E]." + county_corruption_death_modifier:0 "Death Corruption" + county_corruption_death_modifier_desc:0 "This county has been corrupted by Death.\n\nEffects scale based on Death Magic [doctrines|E] and [traits|E]." + + county_purged_modifier_1:0 "Small Depopulation" + county_purged_modifier_2:0 "Large Depopulation" + county_purged_modifier_3:0 "Severe Depopulation" + + harmonize_with_force_modifier:0 "Harmonized With Power" + corruption_disease_modifier:0 "Corrupted Plague" + corruption_disease_modifier_desc:0 "The corruption of a neighboring county has caused a great outbreak of disease." + genocidal_unrest_modifier:0 "Genocidal Unrest" + genocidal_unrest_modifier_desc:0 "The purge of a neighboring county has caused a great deal of unrest here." + genocide_emigration_modifier:0 "Recent Emigration" + genocide_immigration_modifier:0 "Recent Immigration" + genocide_channelled_energy_modifier:0 "Harnessed Energy" + genocide_dispersed_energy_modifier:0 "Dispersed Energy" + sacrificed_cleansing_targets_modifier:0 "Cleansed Sacrifice" + genocide_focused_resources_modifier:0 "Focused Resources" + genocide_dispersed_resources_modifier:0 "Dispersed Resources" + genocide_wild_energy_modifier:0 "Rampaging Energy" + genocide_controlled_energy_modifier:0 "Corralled Energy" + genocide_marauding_forces_modifier:0 "Rampaging Marauders" + genocide_purged_marauders_modifier:0 "Purged Marauders" + genocide_local_champion_modifier:0 "Local Champion" \ No newline at end of file diff --git a/localization/english/opinions/wc_genocide_opinions_l_english.yml b/localization/english/opinions/wc_genocide_opinions_l_english.yml new file mode 100644 index 0000000000..2c39f698f8 --- /dev/null +++ b/localization/english/opinions/wc_genocide_opinions_l_english.yml @@ -0,0 +1,7 @@ +l_english: + disapproves_of_genocide:0 "Disapproves of Purge" + minority_disapproves_of_genocide_population_opinion:0 "[GetVassalStance( 'minority' ).GetTextIcon][GetVassalStance( 'minority' ).GetName] $disapproves_of_genocide$" + genocided_my_culture_opinion:0 "Purged My Culture" + genocided_my_faith_opinion:0 "Purged My Faith" + ruler_disapproves_of_genocide_population_opinion:0 "Purged My People" + vassal_approves_of_defending_genocide_opinion:0 "Avenged Purge" diff --git a/localization/english/wc_council_tasks_l_english.yml b/localization/english/wc_council_tasks_l_english.yml index ba790384c5..56833643ab 100644 --- a/localization/english/wc_council_tasks_l_english.yml +++ b/localization/english/wc_council_tasks_l_english.yml @@ -5,4 +5,40 @@ COURT_CHAPLAIN_FABRICATE_CLAIM_INNOVATION_BONUS_EXPANSIONISM:1 "[councillor_liege.GetCulture.GetName] — $innovation_expansionism$" - task_dark_frenzy_gain:0 "\n$TAB$Grants [dark_frenzy|E]" \ No newline at end of file + task_dark_frenzy_gain:0 "\n$TAB$Grants [dark_frenzy|E]" + + task_purge_population:0 "[GetPlayer.Custom('TaskPurgePopulationTitle')]" + TaskPurgePopulationTitle_Corrupt:0 "Corrupt County" + TaskPurgePopulationTitle_Purge:0 "Purge Population" + task_purge_population_VALUE_NAME:0 "" + task_purge_population_effect_desc:0 "#S At #V 100%#!#!:\n$TAB$The [county|E] will change [faith|E] to [councillor_liege.GetFaith.GetName]\n$TAB$The [county|E] will change culture to [councillor_liege.GetCulture.GetName]" + task_purge_population_effect_corrupt_desc:0 "\n$TAB$The [county|E] will become corrupted" + minority_disapproves_genocide_tooltip:0 "\n$TAB$Every $minority_vassal$ ([councillor_liege.MakeScope.ScriptValue('number_of_minority_vassals')|V0]) loses #N 25#! or #N 50#! [opinion|E] of [councillor_liege.GetShortUIName] for #V 10 years#! #weak (Disapproves Purge)#!" + COUNTY_IS_YOUR_CULTURE:0 "[county.GetName] is already [councillor_liege.GetCulture.GetName]" + COUNTY_IS_YOUR_FAITH:0 "[county.GetName] is already [councillor_liege.GetFaith.GetName]" + COUNTY_ALREADY_CORRUPTED:0 "[county.GetName] is already corrupted" + GENOCIDE_ARMY_STRENGTH_BONUS:0 "From unraised armies" + MARSHAL_GENOCIDE_FERVOR_IMPACT:0 "From [fervor|E]" + FROM_CONVERSION_SPEED_GAME_RULE:0 "From [culture|E] and [faith|E] conversion speed game rules" + genocide_liege_disapproves:0 "Liege does not approve of this purge" + genocide_invalid_culture_faith:0 "[county.GetProvince.GetCounty.GetCulture.GetName] and [county.GetProvince.GetCounty.GetFaith.GetName] are not valid targets" + cultural_acceptance_loss_purge_pupulation:0 "[old_culture.GetName] purged in [county.GetName]" + + genocided_my_culture_opinion_desc:0 "Every [old_culture.GetName] ruler lost #N 25#! [opinion|E] of #V you#! for #V 10 years#! #weak ($genocided_my_culture_opinion$)#!" + genocided_my_faith_opinion_desc:0 "Every [old_faith.GetName] ruler lost #N 50#! [opinion|E] of #V you#! for #V 10 years#! #weak ($genocided_my_faith_opinion$)#!" + minority_disapproves_of_genocide_population_opinion_desc:0 "Every $minority_vassal$ ([councillor_liege.MakeScope.ScriptValue('number_of_minority_vassals')|V0]) lost #N 25#! [opinion|E] of [councillor_liege.GetShortUIName] for #V 10 years#! #weak ($disapproves_of_genocide$)#!" + + council_task_cursed_lands:0 "\n$EFFECT_LIST_BULLET$#N Cursed Lands Spreading#!" + council_task_marauders:0 "\n$EFFECT_LIST_BULLET$#N Marauders Run Wild#!" + council_task_devotion_demonstration:0 "\n$EFFECT_LIST_BULLET$#P A Ritual To [councillor_liege.Custom('GenocideEventRelevantGod')]#!" + council_task_harness_energy:0 "\n$EFFECT_LIST_BULLET$#P Harness [councillor_liege.Custom('GenocideEventRelevantMagic')] Energy#!" + + council_task_champion_challenge:0 "\n$EFFECT_LIST_BULLET$#N An Unexpected Challenge#!" + council_task_wild_energy:0 "\n$EFFECT_LIST_BULLET$#N [county.Custom('GenocideEventRelevantCountyMagic')] Energy Runs Wild#!" + council_task_army_spawn:0 "\n$EFFECT_LIST_BULLET$#P Unexpected Aid Arrives#!" + council_task_large_raid:0 "\n$EFFECT_LIST_BULLET$#P A Large Raid#!" + + council_task_neighboring_unrest:0 "\n$EFFECT_LIST_BULLET$#N Neighboring Unrest#!" + council_task_emigration:0 "\n$EFFECT_LIST_BULLET$#N Large Emigration#!" + council_task_friendly_champion:0 "\n$EFFECT_LIST_BULLET$#P An Offer Of Assistance#!" + council_task_found_supplies:0 "\n$EFFECT_LIST_BULLET$#P A Windfall Of Supplies#!" \ No newline at end of file diff --git a/localization/english/wc_game_concepts_l_english.yml b/localization/english/wc_game_concepts_l_english.yml index aef1f69728..4c2190fc0b 100644 --- a/localization/english/wc_game_concepts_l_english.yml +++ b/localization/english/wc_game_concepts_l_english.yml @@ -120,4 +120,8 @@ game_concept_lei_shen:0 "Lei Shen" game_concept_thunder_king:0 "Thunder King" game_concept_the_thunder_king:0 "The Thunder King" - game_concept_the_thunder_king_desc:0 "One of the lesser [crises|E] on Azeroth. The [GetTrait('thunder_king').GetName( GetNullCharacter )] Lei Shen was the first Emperor of the Mogu Empire. He absorbed the powers of the titan watcher Ra-den to become one of the most powerful beings on Azeroth and conquered all of Pandaria, founding a tyrannical regime that would last for thousands of years. He was eventually killed alongside his Zandalari allies while attempting to claim the Forge of Origination in Uldum.\n\nThe Zandalari trolls are rumored to possess the secret ritual of his resurrection. If the legends are true, the resurrected Thunder King would waste no time rallying the [GetTrait('creature_mogu').GetName( GetNullCharacter )] Clans to reestablish his ancient [empire|E]'s dominion over Pandaria.\n\nAs an [ongoing_crisis|E], the Thunder King will have access to the [great_invasion|E] [casus_belli|E], but will generally not expand beyond Pandaria." \ No newline at end of file + game_concept_the_thunder_king_desc:0 "One of the lesser [crises|E] on Azeroth. The [GetTrait('thunder_king').GetName( GetNullCharacter )] Lei Shen was the first Emperor of the Mogu Empire. He absorbed the powers of the titan watcher Ra-den to become one of the most powerful beings on Azeroth and conquered all of Pandaria, founding a tyrannical regime that would last for thousands of years. He was eventually killed alongside his Zandalari allies while attempting to claim the Forge of Origination in Uldum.\n\nThe Zandalari trolls are rumored to possess the secret ritual of his resurrection. If the legends are true, the resurrected Thunder King would waste no time rallying the [GetTrait('creature_mogu').GetName( GetNullCharacter )] Clans to reestablish his ancient [empire|E]'s dominion over Pandaria.\n\nAs an [ongoing_crisis|E], the Thunder King will have access to the [great_invasion|E] [casus_belli|E], but will generally not expand beyond Pandaria." + + game_concept_purge_population:0 "Purge Population" + game_concept_genocide:0 "$game_concept_purge_population$" + game_concept_purge_population_desc:0 "A [councillor_task|E] performed by the [marshal|E] which targets a [county|E] of a different [culture|E] or [faith|E] than the [liege|E]\nProgress increases each month, and at 100%, the Target County has changed from their previous Culture and Faith to the Liege's.\n\nConversion speed is affected by many factors, including the [councillor|E]'s [martial_skill|E], the strength of the Liege's unraised [army|E], the County's [development|E], and the [fervor|E] of the two Faiths." \ No newline at end of file diff --git a/localization/english/wc_wars_l_english.yml b/localization/english/wc_wars_l_english.yml index 33d1bbb018..7a762c331d 100644 --- a/localization/english/wc_wars_l_english.yml +++ b/localization/english/wc_wars_l_english.yml @@ -27,4 +27,14 @@ MIGRATION_WAR_DUCHY_NAME:0 "[holy_war|E] for [duchy|E]" migration_theramore_war:0 "Migration War" - scourge_quelthalas_cb.undead_conversion:0 "All those you [Concept('vassal', 'Vassalize')|E] and their vassals become [GetTrait('being_undead').GetName( GetNullCharacter )]" \ No newline at end of file + scourge_quelthalas_cb.undead_conversion:0 "All those you [Concept('vassal', 'Vassalize')|E] and their vassals become [GetTrait('being_undead').GetName( GetNullCharacter )]" + + GENOCIDE_WAR_NAME:0 "#E Avenge Purge#! in [DEFENDER.GetPrimaryTitle.GetName]" + GENOCIDE_WAR_CB_NAME: "Avenge Purge" + msg_committed_genocide_invalid_message:0 "The [war.GetName] has ended: [attacker.GetTitledFirstName] can no longer avenge the purge" + committed_genocide_cb_victory_desc_attacker:0 "You gain all purged counties of your [culture|E] or [faith|E]" + committed_genocide_cb_victory_desc:0 "[attacker.GetShortUIName|U] gains all purged counties of their [culture|E] or [faith|E]" + committed_genocide_cb_white_peace_desc_defender:0 "You keep the purged counties" + committed_genocide_cb_white_peace_desc:0 "[defender.GetShortUIName|U] keeps the purged counties" + committed_genocide_cb_defeat_desc_defender:0 "$committed_genocide_cb_white_peace_desc_defender$" + committed_genocide_cb_defeat_desc:0 "$committed_genocide_cb_white_peace_desc$" \ No newline at end of file diff --git a/localization/replace/english/wc_game_rules_l_english.yml b/localization/replace/english/wc_game_rules_l_english.yml index b7f7ca5a54..6221088074 100644 --- a/localization/replace/english/wc_game_rules_l_english.yml +++ b/localization/replace/english/wc_game_rules_l_english.yml @@ -20,3 +20,10 @@ setting_random_ruler_placement_on_desc:0 "#warning (This game rule should already be set on a bookmark page to work)#! Rulers are randomly placed on the map. Each county gets a new faith and culture from it's new holder." setting_random_ruler_placement_on_conversion:1 "#high On (Conversion)#!" setting_random_ruler_placement_on_conversion_desc:1 "Rulers are randomly placed on the map. They convert to the historical holder's Faith." + + conversion_desc_genocide:0 "#clickable #Bold Warcraft#!#!: Also applies to Purges" + setting_default_culture_conversion_speed_desc:0 "Conversion speed is unchanged.\n$conversion_desc_genocide$" + setting_faster_culture_conversion_speed_desc:0 "The speed is increased, making conversion take roughly half of the time.\n$conversion_desc_genocide$" + setting_significantly_faster_culture_conversion_speed_desc:0 "The speed is significantly increased, making conversion take roughly a quarter of the time.\n$conversion_desc_genocide$" + setting_significantly_slower_culture_conversion_speed_desc:0 "The speed is significantly reduced, making conversion take roughly four times longer.\n$conversion_desc_genocide$" + setting_slower_culture_conversion_speed_desc:0 "The speed is reduced, making conversion take roughly twice the time.\n$conversion_desc_genocide$"