From dbaa9aa676167f10dc2dc00d17f54c0440555f2f Mon Sep 17 00:00:00 2001 From: JulesFlammenkueche Date: Fri, 19 Dec 2025 19:29:16 +0100 Subject: [PATCH 1/3] Bavaria flags & some dev --- N3OW/gfx/coat_of_arms/colored_emblems/NEOW_ce_boot.dds | 3 +++ N3OW/gfx/coat_of_arms/colored_emblems/NEOW_ce_iron_hat.dds | 3 +++ N3OW/gfx/coat_of_arms/colored_emblems/NEOW_ce_millwheel.dds | 3 +++ N3OW/gfx/coat_of_arms/colored_emblems/NEOW_ce_monk.dds | 3 +++ N3OW/gfx/coat_of_arms/colored_emblems/NEOW_ce_plough.dds | 3 +++ N3OW/gfx/coat_of_arms/colored_emblems/NEOW_ce_plowshare.dds | 3 +++ 6 files changed, 18 insertions(+) create mode 100644 N3OW/gfx/coat_of_arms/colored_emblems/NEOW_ce_boot.dds create mode 100644 N3OW/gfx/coat_of_arms/colored_emblems/NEOW_ce_iron_hat.dds create mode 100644 N3OW/gfx/coat_of_arms/colored_emblems/NEOW_ce_millwheel.dds create mode 100644 N3OW/gfx/coat_of_arms/colored_emblems/NEOW_ce_monk.dds create mode 100644 N3OW/gfx/coat_of_arms/colored_emblems/NEOW_ce_plough.dds create mode 100644 N3OW/gfx/coat_of_arms/colored_emblems/NEOW_ce_plowshare.dds diff --git a/N3OW/gfx/coat_of_arms/colored_emblems/NEOW_ce_boot.dds b/N3OW/gfx/coat_of_arms/colored_emblems/NEOW_ce_boot.dds new file mode 100644 index 00000000..dc0be378 --- /dev/null +++ b/N3OW/gfx/coat_of_arms/colored_emblems/NEOW_ce_boot.dds @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:34eccaa848c5f125a6dc09fcaa98f8fef6676c67fca7434739d61c22248abf31 +size 22000 diff --git a/N3OW/gfx/coat_of_arms/colored_emblems/NEOW_ce_iron_hat.dds b/N3OW/gfx/coat_of_arms/colored_emblems/NEOW_ce_iron_hat.dds new file mode 100644 index 00000000..87f46d4c --- /dev/null +++ b/N3OW/gfx/coat_of_arms/colored_emblems/NEOW_ce_iron_hat.dds @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e5ecbf01f6367b49d58754fa718c49d6fe1385ae030bb98d4da76cb8c9b3c627 +size 87536 diff --git a/N3OW/gfx/coat_of_arms/colored_emblems/NEOW_ce_millwheel.dds b/N3OW/gfx/coat_of_arms/colored_emblems/NEOW_ce_millwheel.dds new file mode 100644 index 00000000..ee51d9e1 --- /dev/null +++ b/N3OW/gfx/coat_of_arms/colored_emblems/NEOW_ce_millwheel.dds @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2baa87605e986c73f2183a1f23bf063f6d50ac545659d537ae4eb27ae7fc15e7 +size 87536 diff --git a/N3OW/gfx/coat_of_arms/colored_emblems/NEOW_ce_monk.dds b/N3OW/gfx/coat_of_arms/colored_emblems/NEOW_ce_monk.dds new file mode 100644 index 00000000..df86c808 --- /dev/null +++ b/N3OW/gfx/coat_of_arms/colored_emblems/NEOW_ce_monk.dds @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:24b674a1344283e0e8ca420e19f962db6b3a6f9aa7ef4f820c44e5d17d9f1f7d +size 87536 diff --git a/N3OW/gfx/coat_of_arms/colored_emblems/NEOW_ce_plough.dds b/N3OW/gfx/coat_of_arms/colored_emblems/NEOW_ce_plough.dds new file mode 100644 index 00000000..9ac62159 --- /dev/null +++ b/N3OW/gfx/coat_of_arms/colored_emblems/NEOW_ce_plough.dds @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:047a0dc4bce16c0951b75cadf40a35626336949caa11c70a0fd312e06a4c7060 +size 87536 diff --git a/N3OW/gfx/coat_of_arms/colored_emblems/NEOW_ce_plowshare.dds b/N3OW/gfx/coat_of_arms/colored_emblems/NEOW_ce_plowshare.dds new file mode 100644 index 00000000..2a27707d --- /dev/null +++ b/N3OW/gfx/coat_of_arms/colored_emblems/NEOW_ce_plowshare.dds @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9ef6507c3f41ee6b53482565e836efe4616fb5e32b0d0627150b954f18cfc445 +size 22000 From 42a2a620236cc5e15d853151c56cb4112be00a86 Mon Sep 17 00:00:00 2001 From: Fishedotjpg Date: Sat, 20 Dec 2025 15:08:57 +0000 Subject: [PATCH 2/3] inappropriate decisions vapourised --- .../80_major_decisions_british_isles.txt | 2 + .../dlc_decisions/03_fp2_decisions.txt | 1563 +++++++++++++++++ 2 files changed, 1565 insertions(+) create mode 100644 N3OW/common/decisions/80_major_decisions_british_isles.txt create mode 100644 N3OW/common/decisions/dlc_decisions/03_fp2_decisions.txt diff --git a/N3OW/common/decisions/80_major_decisions_british_isles.txt b/N3OW/common/decisions/80_major_decisions_british_isles.txt new file mode 100644 index 00000000..a2128aef --- /dev/null +++ b/N3OW/common/decisions/80_major_decisions_british_isles.txt @@ -0,0 +1,2 @@ +#The culture of the people both high and low is veering towards Celtic - embrace it? +### Reclaim Britannia ### \ No newline at end of file diff --git a/N3OW/common/decisions/dlc_decisions/03_fp2_decisions.txt b/N3OW/common/decisions/dlc_decisions/03_fp2_decisions.txt new file mode 100644 index 00000000..66df983e --- /dev/null +++ b/N3OW/common/decisions/dlc_decisions/03_fp2_decisions.txt @@ -0,0 +1,1563 @@ +# No lists or indexes, only chaos. Keep scrolling down and thou shalt find them. + +############################################# +# Hostility Ending # +# by Joe Parkin # +############################################# + +struggle_iberia_ending_hostility_decision = { + decision_group_type = major + title = struggle_iberia_ending_hostility_decision + picture = { + reference = "gfx/interface/illustrations/decisions/fp2_decision_struggle_hostility.dds" + } + extra_picture = "gfx/interface/illustrations/struggle_decision_buttons/fp2_decision_hostility.dds" + desc = struggle_iberia_ending_hostility_decision_desc + selection_tooltip = struggle_iberia_ending_hostility_decision_tooltip + confirm_click_sound = "event:/DLC/FP2/SFX/UI/fp2_struggle_ending_decision_confirm" + is_invisible = yes + sort_order = 80 + + is_shown = { + is_landless_adventurer = no + has_fp2_dlc_trigger = yes + } + + is_valid = { + top_liege = this + + OR = { + custom_tooltip = { + text = struggle_iberia_ending_hostility_decision_correct_phase_tt + any_character_struggle = { + involvement = involved + is_struggle_type = iberian_struggle + is_struggle_phase = struggle_iberia_phase_hostility + } + } + ## Completely control Hispania for 5 years + AND = { + completely_controls_region = world_europe_west_iberia + primary_title = { + tier >= tier_kingdom + title_held_years >= 5 + } + } + } + + + custom_tooltip = { + text = struggle_ending_decision_correct_involvement_spain_tt + any_character_struggle = { + involvement = involved + is_struggle_type = iberian_struggle + } + } + + # Hold and completely control two de jure kingdoms of Hispania + OR = { + custom_tooltip = { # + text = struggle_iberia_ending_hostility_decision_kingdom_tt + any_held_title = { # 1st kingdom + title_tier = kingdom + de_jure_liege = title:e_spain + root = { completely_controls = prev } + save_temporary_scope_as = spanish_kingdom + } + any_held_title = { # 2nd kingdom + title_tier = kingdom + de_jure_liege = title:e_spain + trigger_if = { + limit = { exists = scope:spanish_kingdom } + this != scope:spanish_kingdom + } + root = { completely_controls = prev } + save_temporary_scope_as = spanish_kingdom_2 + } + } + custom_tooltip = { + text = struggle_iberia_ending_hostility_decision_united_spanish_throne_tt + AND = { + exists = global_var:unite_the_spanish_thrones_decision_title + primary_title = global_var:unite_the_spanish_thrones_decision_title + } + } + } + + + # All your capital kingdom's de jure counties are of your culture and faith + trigger_if = { + limit = { + exists = global_var:unite_the_spanish_thrones_decision_title + primary_title = global_var:unite_the_spanish_thrones_decision_title + } + custom_tooltip = { + text = struggle_iberia_ending_hostility_decision_county_light_tt + capital_county.de_jure_liege.de_jure_liege = { + any_de_jure_county = { + percent >= 0.75 + culture = root.culture + faith = root.faith + } + } + } + } + trigger_else = { + custom_tooltip = { + text = struggle_iberia_ending_hostility_decision_county_tt + capital_county.de_jure_liege.de_jure_liege = { + any_de_jure_county = { + count = all + culture = root.culture + faith = root.faith + } + } + } + } + + # No other realm controls more than 20% of the Iberia region + custom_tooltip = { + text = struggle_iberia_ending_hostility_decision_region_tt + NOT = { + struggle:iberian_struggle = { + any_involved_ruler = { + this != root + top_liege = this + primary_title ?= { is_mercenary_company = no } + save_temporary_scope_as = iberian_realm + any_county_in_region = { + region = world_europe_west_iberia + percent > fp2_struggle_hostility_region_percent_decimal_value + holder.top_liege = scope:iberian_realm + } + } + } + } + } + + # Completely control at least 2 of the important Iberian duchies + calc_true_if = { + amount >= 2 + completely_controls = title:d_galicia + completely_controls = title:d_toledo + completely_controls = title:d_cordoba + completely_controls = title:d_valencia + completely_controls = title:d_barcelona + } + } + + effect = { + if = { + limit = { has_dlc_feature = legends } + legend_seed_struggle_ending_effect = { + ENDER = root + STRUGGLE = iberian_struggle + } + } + if = { + limit = { has_ach_dlc_trigger = yes } + add_character_flag = ach_ended_struggle + } + + ##### Major Effects ##### + show_as_tooltip = { + dynasty = { add_dynasty_prestige = 10000 } + fp2_struggle_hostility_ender_effect = yes + } + # Hispania is available! + custom_tooltip = fp2_struggle_can_create_empire_of_hispania_tt + custom_description_no_bullet = { text = fp2_struggle_house_tt } + # Keep the Struggle Clash for your House + custom_tooltip = fp2_struggle_can_keep_using_struggle_clash_tt + # Boost to culture and faith conversion + custom_tooltip = fp2_struggle_hostility_conversion_tt + # Damage opinion with other culture/faiths + custom_tooltip = fp2_struggle_hostility_opinion_tt + custom_tooltip = fp2_struggle_hostility_opinion_negative_tt + # Choose Holy War boost, Culture War boost, or both + custom_description_no_bullet = { text = fp2_struggle_hostility_list_tt } + #custom_tooltip = fp2_struggle_hostility_holy_cb_joint_tt + #custom_tooltip = fp2_struggle_hostility_culture_cb_tt + + + + show_as_tooltip = { + stress_impact = { + humble = medium_stress_impact_gain + cynical = medium_stress_impact_gain + } + } + + + # Achievements + add_achievement_global_variable_effect = { + VARIABLE = fp2_iberian_hostilities_achievement_unlocked + VALUE = yes + } + fp2_holiday_in_iberia_check = yes + + # Trigger a player facing event as a coda + trigger_event = fp2_struggle.0900 + } + + cost = {} + + ai_check_interval_by_tier = { + barony = 0 + county = 0 + duchy = 0 + kingdom = 120 + empire = 120 + hegemony = 120 + } + + ai_potential = { always = yes } + + ai_will_do = { base = 100 } +} + +############################################# +# Compromise Ending # +# by Joe Parkin # +############################################# + +struggle_iberia_ending_compromise_decision = { + decision_group_type = major + title = struggle_iberia_ending_compromise_decision + picture = { + reference = "gfx/interface/illustrations/decisions/fp2_decision_struggle_compromise.dds" + } + extra_picture = "gfx/interface/illustrations/struggle_decision_buttons/fp2_decision_compromise.dds" + desc = struggle_iberia_ending_compromise_decision_desc + selection_tooltip = struggle_iberia_ending_compromise_decision_tooltip + confirm_click_sound = "event:/DLC/FP2/SFX/UI/fp2_struggle_ending_decision_confirm" + is_invisible = yes + + sort_order = 80 + + is_shown = { + is_landless_adventurer = no + has_fp2_dlc_trigger = yes + } + + is_valid = { + top_liege = this + + custom_tooltip = { + text = struggle_iberia_ending_compromise_decision_correct_phase_tt + any_character_struggle = { + is_struggle_type = iberian_struggle + is_struggle_phase = struggle_iberia_phase_compromise + } + } + + custom_tooltip = { + text = struggle_ending_decision_correct_involvement_spain_tt + any_character_struggle = { + involvement = involved + is_struggle_type = iberian_struggle + } + } + + OR = { + # Exalted among Men or higher + prestige_level >= very_high_prestige_level + # Hold and completely control a de jure kingdom of Hispania + custom_tooltip = { + text = struggle_iberia_ending_compromise_decision_kingdom_tt + fp2_struggle_ending_hold_de_jure_kingdom_trigger = yes + } + } + + # Control less than 50% of Iberia + custom_tooltip = { + text = struggle_iberia_ending_compromise_decision_region_tt + fp2_struggle_ending_percent_iberia_trigger = yes + } + + # No one else controls more than 50% of Iberia + custom_tooltip = { + text = struggle_iberia_ending_compromise_decision_other_region_tt + fp2_struggle_ending_other_percent_iberia_trigger = yes + } + + # No Independent Involved rulers are at war with each other + custom_tooltip = { + text = struggle_iberia_ending_compromise_truce_tt + NOT = { + struggle:iberian_struggle = { + any_involved_ruler = { + top_liege = this + is_landless_adventurer = no + primary_title = { is_mercenary_company = no } + any_primary_war_enemy = { + top_liege = this + is_landless_adventurer = no + any_character_struggle = { + involvement = involved + is_struggle_type = iberian_struggle + } + primary_title = { is_mercenary_company = no } + } + } + } + } + } + + OR = { + # Every other involved independent ruler in Iberia has at least 60 opinion of you or is strong hooked + custom_tooltip = { + text = struggle_iberia_ending_compromise_decision_opinion_tt + struggle:iberian_struggle = { + NOT = { + any_involved_ruler = { + this != root + top_liege = this + primary_title = { is_holy_order = no } + primary_title = { is_mercenary_company = no } + is_landless_adventurer = no + save_temporary_scope_as = this_character + NOR = { + root = { has_strong_hook = scope:this_character } + opinion = { + target = root + value >= struggle_iberia_ending_compromise_decision_opinion_value + } + } + } + } + } + } + # No other independent ruler in Iberia is a king or above + custom_tooltip = { + text = struggle_iberia_ending_compromise_decision_independent_tt + struggle:iberian_struggle = { + NOT = { + any_involved_ruler = { + this != root + top_liege = this + primary_title = { is_mercenary_company = no } + is_landless_adventurer = no + primary_title.tier >= tier_kingdom + } + } + } + } + # More than 25% of Iberia is controlled by Interloper or Uninvolved rulers + custom_tooltip = { + text = struggle_iberia_ending_compromise_decision_interloper_tt + any_county_in_region = { + region = world_europe_west_iberia + percent > fp2_struggle_compromise_uninvolved_percent_decimal_value + holder.top_liege = { fp2_character_interloper_in_struggle_trigger = yes } + } + } + } + + # Completely control any of the important Iberian duchies + calc_true_if = { + amount >= 1 + completely_controls = title:d_galicia + completely_controls = title:d_toledo + completely_controls = title:d_cordoba + completely_controls = title:d_valencia + completely_controls = title:d_barcelona + } + } + + effect = { + if = { + limit = { has_dlc_feature = legends } + legend_seed_struggle_ending_effect = { + ENDER = root + STRUGGLE = iberian_struggle + } + } + if = { + limit = { has_ach_dlc_trigger = yes } + add_character_flag = ach_ended_struggle + } + ##### Major Effects ##### + # Personal effects for ruler + show_as_tooltip = { fp2_struggle_compromise_ender_effect = yes } + # Independent/Split De Jure Duchies will become De Jure Kingdoms + if = { + limit = { + title:e_spain = { + any_in_de_jure_hierarchy = { fp2_struggle_ending_compromise_independent_duchy_trigger = yes } + } + } + custom_tooltip = fp2_struggle_compromise_create_new_kingdoms_tt + } + # Other Tooltips! + fp2_struggle_compromise_tooltip_effect = yes + + ##### Minor Effects ##### + # Self-sufficiency/defensive modifiers for each independent realm + show_as_tooltip = { fp2_struggle_compromise_modifier_rewards_effect = yes } + + show_as_tooltip = { + stress_impact = { + arrogant = medium_stress_impact_gain + } + } + + # Achievements + add_achievement_global_variable_effect = { + VARIABLE = fp2_iberian_compromise_achievement_unlocked + VALUE = yes + } + fp2_holiday_in_iberia_check = yes + + # Trigger a player facing event as a coda + trigger_event = fp2_struggle.0901 + } + + cost = {} + + ai_check_interval_by_tier = { + barony = 0 + county = 0 + duchy = 0 + kingdom = 120 + empire = 120 + hegemony = 120 + } + + ai_potential = { always = yes } + + ai_will_do = { base = 100 } +} + +############################################# +# Conciliation Ending # +# by Joe Parkin # +############################################# + +struggle_iberia_ending_conciliation_decision = { + decision_group_type = major + title = struggle_iberia_ending_conciliation_decision + picture = { + reference = "gfx/interface/illustrations/decisions/fp2_decision_struggle_conciliation.dds" + } + extra_picture = "gfx/interface/illustrations/struggle_decision_buttons/fp2_decision_conciliation.dds" + desc = struggle_iberia_ending_conciliation_decision_desc + selection_tooltip = struggle_iberia_ending_conciliation_decision_tooltip + confirm_click_sound = "event:/DLC/FP2/SFX/UI/fp2_struggle_ending_decision_confirm" + is_invisible = yes + + sort_order = 80 + + is_shown = { + is_landless_adventurer = no + has_fp2_dlc_trigger = yes + } + + is_valid = { + top_liege = this + + custom_tooltip = { + text = struggle_iberia_ending_conciliation_decision_correct_phase_tt + any_character_struggle = { + is_struggle_type = iberian_struggle + is_struggle_phase = struggle_iberia_phase_conciliation + } + } + + custom_tooltip = { + text = struggle_ending_decision_correct_involvement_spain_tt + any_character_struggle = { + involvement = involved + is_struggle_type = iberian_struggle + } + } + + prestige_level >= very_high_prestige_level # Exalted among Men or higher + + # Hold and completely control a de jure kingdom of Hispania + custom_tooltip = { + text = struggle_iberia_ending_compromise_decision_kingdom_tt + fp2_struggle_ending_hold_de_jure_kingdom_trigger = yes + } + + # Every other independent involved ruler in Iberia is allied to you + custom_tooltip = { + text = struggle_iberia_ending_conciliation_decision_alliance_tt + struggle:iberian_struggle = { + NOT = { + any_involved_ruler = { + top_liege = this + is_landless_adventurer = no + primary_title = { is_mercenary_company = no } + primary_title = { is_holy_order = no } + NOR = { + this = root + is_allied_to = root + } + } + } + } + } + + # Control less than 50% of Iberia + custom_tooltip = { + text = struggle_iberia_ending_compromise_decision_region_tt + fp2_struggle_ending_percent_iberia_trigger = yes + } + } + + effect = { + if = { + limit = { has_dlc_feature = legends } + legend_seed_struggle_ending_effect = { + ENDER = root + STRUGGLE = iberian_struggle + } + } + if = { + limit = { has_ach_dlc_trigger = yes } + add_character_flag = ach_ended_struggle + } + ##### Major Effects ##### + show_as_tooltip = { + fp2_struggle_conciliation_ender_effect = yes + fp2_struggle_conciliation_tooltip_effect = yes + fp2_struggle_conciliation_modifier_rewards_effect = yes + } + + show_as_tooltip = { + stress_impact = { + arrogant = medium_stress_impact_gain + zealous = medium_stress_impact_gain + } + } + + # Achievements + add_achievement_global_variable_effect = { + VARIABLE = fp2_iberian_conciliation_achievement_unlocked + VALUE = yes + } + fp2_holiday_in_iberia_check = yes + + + # Trigger a player facing event as a coda + trigger_event = fp2_struggle.0902 + } + + cost = {} + + ai_check_interval_by_tier = { + barony = 0 + county = 0 + duchy = 0 + kingdom = 120 + empire = 120 + hegemony = 120 + } + + ai_potential = { always = yes } + + ai_will_do = { base = 100 } +} + +############################################# +# Eat a Cheese +# by Daniel "yes I know what exciting content is stop bullying me" Moore +########################################################################### +eat_cheese_decision = { + picture = { + reference = "gfx/interface/illustrations/decisions/decision_personal_religious.dds" + } + desc = eat_cheese_decision_desc + + is_shown = { + any_character_artifact = { + has_variable = has_cheese_artifact + } + } + + effect = { + + custom_tooltip = eat_cheese_effect_tt + + trigger_event = fp2_yearly.1008 + + } + + ai_check_interval = 0 + + ai_potential = { + + } + + ai_will_do = { + base = 100 + } +} + +################################### +# Sponsor Jewish Sciences +# By Hugo Cortell +################################### +golden_age_jewish_science_in_iberia_decision = { + picture = { + reference = "gfx/interface/illustrations/decisions/decision_golden_age.dds" + } + desc = golden_age_jewish_science_in_iberia_decision_desc + decision_group_type = struggle + + is_shown = { + has_fp2_dlc_trigger = yes + top_liege = root + top_liege = this # (Redundancy check) + is_landed_or_landless_administrative = yes + AND = { + exists = struggle:iberian_struggle + any_character_struggle = { + involvement = involved + has_struggle_phase_parameter = unlocks_golden_age_jewish_science_decision + } + } + } + + is_valid = { + OR = { # Either the var does not exist (no current golden age) or you are not the sponsor of the current golden age + NOT = { exists = global_var:fp2_current_jewish_science_sponsor } + trigger_if = { + limit = { exists = global_var:fp2_current_jewish_science_sponsor } + custom_tooltip = { + text = golden_age_jewish_science_in_iberia_decision_hardcoded_trigger_text.b + NOT = { root = global_var:fp2_current_jewish_science_sponsor } + is_ai = no # Prevents the AI from stealing the golden age, players can steal each other's golden age + } + } + } + trigger_if = { # If you are not your culture's head, you must earn their approval + limit = { + exists = culture.culture_head # Redundancy check! + culture.culture_head != root + } + custom_tooltip = { + text = golden_age_jewish_science_in_iberia_decision_hardcoded_trigger_text.a + culture.culture_head = { + save_temporary_opinion_value_as = { + name = target_opinion + target = root + } + scope:target_opinion > 0 + } + } + } + } + + effect = { + hidden_effect = { # Prevent any case in which modifiers could be stacked + struggle:iberian_struggle = { + every_involved_ruler = { + remove_character_modifier = fp2_sponsored_golden_age_modifier + remove_character_modifier = fp2_part_of_golden_age_modifier + } + } + } + + send_interface_toast = { + type = event_toast_effect_good + title = golden_age_jewish_science_in_iberia_decision.player_notif.t + right_icon = root + play_music_cue = mx_cue_meadandwine + + add_character_modifier = { + modifier = fp2_sponsored_golden_age_modifier + years = 120 + } + capital_county = { + add_county_modifier = { + modifier = fp2_epicenter_of_golden_age_modifier + years = 60 + } + } + } + culture = { add_to_list = already_involved_cultures } # Ensures that only one top ruler for each involved culture is picked + struggle:iberian_struggle = { + every_involved_ruler = { + custom = fp2_one_independent_ruler_of_each_culture_notifier + limit = { + culture = { save_temporary_scope_as = current_culture } + NOT = { # Checks that it is not in the list of "I am already benefiting from this" + this = root # (Also must not be root) + any_in_list = { + list = already_involved_cultures + this = scope:current_culture + } + } + top_liege = this # Redundancy checks, vital to ensuring this has a 110% success rate + top_liege = this # Redundancy check + } + if = { + limit = { NOT = { has_character_modifier = fp2_part_of_golden_age_modifier } } + culture = { add_to_list = already_involved_cultures } + send_interface_toast = { + type = event_toast_effect_good + title = golden_age_jewish_science_in_iberia_decision.player_notif.t + right_icon = root # Showing root is WAD, lets other players know who started it + + add_character_modifier = { + modifier = fp2_part_of_golden_age_modifier + years = 120 + } + } + } + } + } + + hidden_effect = { + random_list = { + 100 = { + trigger_event = { # Translator/book retailer event + id = iberia_north_africa.2001 + days = { 4 32 } + } + } + 110 = { + trigger_event = { # Cataract Surgery event + id = iberia_north_africa.2002 + days = { 4 32 } + } + } + 90 = { + trigger_event = { # Bickering scholars event + id = iberia_north_africa.2003 + days = { 4 32 } + } + } + } + } + + set_global_variable = { + name = fp2_current_jewish_science_sponsor + value = root + years = 120 + } + } + + cost = { + gold = { + value = 0 + if = { + limit = { + has_treasury = no + } + add = major_gold_value + multiply = 2.25 + round = yes + } + } + treasury = { + value = 0 + if = { + limit = { + has_treasury = yes + } + add = major_gold_value + multiply = 2.25 + round = yes + } + } + } + + ai_check_interval_by_tier = { + barony = 0 + county = 0 + duchy = 0 + kingdom = 730 + empire = 730 + hegemony = 730 + } + + ai_potential = {} + + ai_will_do = { + base = 0 + modifier = { + add = { + value = learning + multiply = 5 + round = yes + } + always = yes + } + } +} + +############################################# +# Convene Council of Toledo # +# by Joe Parkin and Ola Jentzsch # +############################################# +council_of_toledo_decision = { + title = council_of_toledo_decision_title + picture = { + reference = "gfx/interface/illustrations/decisions/decision_major_religion.dds" + } + desc = { + first_valid = { + triggered_desc = { + trigger = { exists = global_var:council_of_toledo_counter } + desc = council_of_toledo_decision_desc_count + } + desc = council_of_toledo_decision_desc + } + } + selection_tooltip = council_of_toledo_decision_tooltip + cooldown = { years = council_of_toledo_decision_decision_cooldown_value } + decision_group_type = major + + sort_order = 80 + + is_shown = { + # DLC check + has_fp2_dlc_trigger = yes + # Is Mozarabic (or reformed Mozarabic) + faith = { + portrait_religious_faith_or_foundational_trigger = { FAITH = faith:mozarabic_church } + } + any_vassal = { } + } + + is_valid = { + # Owns Toledo + custom_tooltip = { + text = council_of_toledo_decision_toledo_holder_trigger + is_toledo_ownership_valid_trigger = yes + } + any_vassal = { + count >= 3 + is_powerful_vassal = yes + custom_tooltip = { + text = council_of_toledo_decision_toledo_faith_trigger + faith = root.faith + } + } + + realm_size >= council_of_toledo_realm_size_value + # update fp2_struggle_council_toledo_decision_trigger if changing this + } + + is_valid_showing_failures_only = { + is_landed = yes + # Not at war + is_at_war = no + } + + effect = { + custom_tooltip = council_of_toledo_decision_tt + faith:mozarabic_church = { + change_fervor = { + value = 10 + desc = fervor_gain_ascetic_example + } + } + # Council counter + if = { + limit = { exists = global_var:council_of_toledo_counter } + change_global_variable = { + name = council_of_toledo_counter + add = 1 + } + } + else = { + set_global_variable = { + name = council_of_toledo_counter + value = 19 + } + } + if = { + limit = { + any_character_struggle = { is_struggle_type = iberian_struggle } + } + custom_tooltip = council_of_toledo_decision_catalyst_tt + } + trigger_event = { + on_action = fp2_struggle_council_toledo_organize + days = 1 + } + } + + cost = { + gold = { + value = 0 + if = { + limit = { + has_treasury = no + } + add = council_of_toledo_gold_cost_value + } + } + treasury = { + value = 0 + if = { + limit = { + has_treasury = yes + } + add = council_of_toledo_gold_cost_value + } + } + piety = council_of_toledo_piety_cost_value + } + + ai_check_interval_by_tier = { + barony = 0 + county = 0 + duchy = 0 + kingdom = 60 + empire = 60 + hegemony = 60 + } + + ai_potential = { + is_ruler = yes + short_term_gold >= council_of_toledo_gold_cost_value + } + + ai_will_do = { + base = 100 + } +} + +############################################# +# Secure Iberian Foothold +# by Joe Parkin and Ola Jentzsch +############################################# +secure_iberian_foothold_decision = { + title = secure_iberian_foothold_decision_title + picture = { + reference = "gfx/interface/illustrations/decisions/decision_destiny_goal.dds" + } + desc = secure_iberian_foothold_decision_desc + selection_tooltip = secure_iberian_foothold_decision_tooltip + sort_order = 80 + decision_group_type = struggle + + is_shown = { + is_landless_adventurer = no + # DLC check + has_fp2_dlc_trigger = yes + # Struggle is active + exists = struggle:iberian_struggle + # Not Involved and capital lies outside Iberia + custom_tooltip = { + text = fp2_struggle_uninvolved_or_external_tt + NOR = { + any_character_struggle = { + is_struggle_type = iberian_struggle + involvement = involved + } + } + } + # Hold land near Iberia + any_sub_realm_county = { + title_province = { + OR = { + geographical_region = world_europe_west_iberia # Iberia + geographical_region = ghw_region_southern_france # Aquitaine + geographical_region = world_africa_north_west # Maghreb + } + } + } + NOT = { has_title = title:e_spain } + } + + is_valid = { + ##### General triggers ##### + # Struggle phase must be right + custom_tooltip = { + text = fp2_struggle_uninvolved_or_external_tt + NOT = { + capital_province = { geographical_region = world_europe_west_iberia } + } + } + custom_tooltip = { + text = fp2_struggle_secure_iberian_foothold_empire_tt + any_held_title = { + title_tier >= empire + NOT = { this = title:e_spain } + } + } + # If my religion is involved, I need to own the better portion of those counties + trigger_if = { + limit = { + religion = { + any_faith = { + struggle:iberian_struggle = { is_faith_involved_in_struggle = prev } + } + } + } + custom_tooltip = { + text = fp2_struggle_secure_iberian_foothold_religion_tt + fp2_struggle_secure_iberian_foothold_religion_percent_value >= fp2_struggle_secure_iberian_foothold_religion_target_percent_value + } + } + # Otherwise, I need to own a big chunk of the peninsula + trigger_else = { + custom_tooltip = { + text = fp2_struggle_secure_iberian_foothold_outsider_tt + any_county_in_region = { + region = world_europe_west_iberia + percent >= fp2_struggle_secure_iberian_foothold_outsider_target_percent_decimal_value + holder.top_liege = root + } + } + } + + ##### Iberian kingdom triggers ##### + + # Any de jure kingdom of Iberia is completely controlled + custom_tooltip = { + text = fp2_struggle_secure_iberian_foothold_kingdom_iberian_tt + any_held_title = { fp2_struggle_secure_iberian_foothold_iberian_kingdom_trigger = yes } + } + # Real tooltips + trigger_if = { + limit = { exists = scope:iberian_kingdom_temp } + # That kingdom is mostly my faith + custom_tooltip = { + text = fp2_struggle_secure_iberian_foothold_kingdom_faith_tt + fp2_struggle_secure_iberian_foothold_faith_trigger = yes + } + # Borders held lands in a non-Iberian kingdom you hold + custom_tooltip = { + text = fp2_struggle_secure_iberian_foothold_kingdom_border_tt + scope:iberian_kingdom_temp = { fp2_struggle_secure_iberian_foothold_outsider_kingdom_trigger = yes } + } + # Held that kingdom for a while + custom_tooltip = { + text = fp2_struggle_secure_iberian_foothold_kingdom_held_tt + scope:iberian_kingdom_temp = { title_held_years >= fp2_struggle_secure_iberian_foothold_years_value } + } + } + # Fake tooltips + trigger_else = { + custom_tooltip = { + text = fp2_struggle_secure_iberian_foothold_kingdom_faith_tt + always = no + } + # Borders held lands in a non-Iberian kingdom you hold + custom_tooltip = { + text = fp2_struggle_secure_iberian_foothold_kingdom_border_tt + always = no + } + custom_tooltip = { + text = fp2_struggle_secure_iberian_foothold_kingdom_held_tt + always = no + } + } + } + + is_valid_showing_failures_only = { + trigger_if = { + limit = { exists = struggle:iberian_struggle } + custom_tooltip = { + text = fp2_struggle_phase_hostility_or_opportunity_tt + struggle:iberian_struggle = { + has_struggle_phase_parameter = unlocks_secure_iberian_foothold_decision + } + } + } + } + + effect = { + legend_seed_struggle_ending_effect = { + ENDER = root + STRUGGLE = iberian_struggle + } + if = { + limit = { has_ach_dlc_trigger = yes } + add_character_flag = ach_ended_struggle + } + if = { + limit = { + any_held_title = { title_tier = empire } + } + custom_tooltip = fp2_struggle_secure_iberian_foothold_empire_held_effect_tt + } + else = { custom_tooltip = fp2_struggle_secure_iberian_foothold_empire_dejure_effect_tt } + + trigger_event = { + id = fp2_other_decisions.1000 + } + + custom_tooltip = fp2_struggle_secure_iberian_foothold_ends_the_struggle_tt + } + + cost = {} + + ai_check_interval_by_tier = { + barony = 0 + county = 0 + duchy = 0 + kingdom = 120 + empire = 120 + hegemony = 120 + } + + ai_potential = {} + + ai_will_do = { + base = 100 + } +} + +################################### +# Build Pilgrim Roads +# By Hugo Cortell +################################### +build_holy_pilgrim_roads_decision = { + picture = { + reference = "gfx/interface/illustrations/decisions/fp2_decision_struggle_opening.dds" + } + sort_order = 300 + decision_group_type = struggle + + is_shown = { + faith = { + any_holy_site = { + holder.top_liege = root + count > 0 + } + } + any_character_struggle = { + involvement = involved + has_struggle_phase_parameter = unlocks_build_pilgrim_roads_decision + } + } + + is_valid = { + custom_tooltip = { + text = build_holy_pilgrim_roads_decision_hardcoded_trigger_text.a + faith = { + any_holy_site = { + holder.top_liege = root + NOT = { county = { has_county_modifier = fp2_pilgrim_roads_modifier } } + count > 0 + } + } + } + } + + effect = { + hidden_effect = { + faith = { + random_holy_site = { + limit = { + holder.top_liege = root + NOT = { county = { has_county_modifier = fp2_pilgrim_roads_modifier } } + } + save_scope_as = chosen_holy_site_for_pilgrim_roads + county = { + save_scope_as = chosen_location_for_pilgrim_roads + add_county_modifier = { + modifier = fp2_pilgrim_roads_modifier + years = 50 + } + } + } + } + } + send_interface_toast = { + type = event_toast_effect_good + title = build_holy_pilgrim_roads_decision_construction_notif.t + desc = build_holy_pilgrim_roads_decision_construction_notif.desc + + add_piety = major_piety_gain + show_as_tooltip = { + scope:chosen_location_for_pilgrim_roads = { + add_county_modifier = { + modifier = fp2_pilgrim_roads_modifier + years = 50 + } + } + } + } + + if = { # QA QoL + limit = { debug_only = yes } + custom_tooltip = debug_generic_option_shortened_trigger_can_disable + hidden_effect = { + random_list = { + 1 = { + trigger_event = { + id = iberia_north_africa.2011 + days = 4 + } + } + 1 = { + trigger_event = { + id = iberia_north_africa.2012 + days = 4 + } + } + 1 = { + trigger_event = { + id = iberia_north_africa.2013 + days = 4 + } + } + } + } + } + else = { + hidden_effect = { + random_list = { + 1 = { + trigger_event = { + id = iberia_north_africa.2011 + days = { 32 2048 } + } + } + 1 = { + trigger_event = { + id = iberia_north_africa.2012 + days = { 32 2048 } + } + } + 1 = { + trigger_event = { + id = iberia_north_africa.2013 + days = { 32 2048 } + } + } + } + } + } + } + + cost = { + gold = { + value = 0 + if = { + limit = { + has_treasury = no + } + add = massive_gold_value + } + } + treasury = { + value = 0 + if = { + limit = { + has_treasury = yes + } + add = massive_gold_value + } + } + } + + ai_check_interval_by_tier = { + barony = 0 + county = 730 + duchy = 730 + kingdom = 730 + empire = 730 + hegemony = 730 + } + ai_potential = {} + ai_will_do = { + base = 50 + modifier = { + add = learning + always = yes + } + modifier = { + add = -50 + has_trait = cynical + } + modifier = { + add = 10 + has_trait = zealous + } + modifier = { + add = -40 + short_term_gold < massive_gold_value + } + } +} + +############################################# +# Found Kingdom of Toledo +# by Joe Parkin +############################################# +found_kingdom_toledo_decision = { + title = found_kingdom_toledo_decision_title + picture = { + reference = "gfx/interface/illustrations/decisions/decision_found_kingdom.dds" + } + desc = found_kingdom_toledo_decision_desc + selection_tooltip = found_kingdom_toledo_decision_tooltip + sort_order = 80 + + decision_group_type = major + + is_shown = { + # DLC check + has_fp2_dlc_trigger = yes + culture = { has_cultural_pillar = heritage_iberian } + faith = { + portrait_religious_faith_or_foundational_trigger = { FAITH = faith:mozarabic_church } + } + NOT = { + is_target_in_global_variable_list = { + name = unavailable_unique_decisions + target = flag:form_toledo_decision + } + } + title:e_spain = { + any_in_de_jure_hierarchy = { + any_title_to_title_neighboring_and_across_water_duchy = { this = title:d_toledo } + de_jure_liege = { + any_in_de_jure_hierarchy = { + count > 2 + tier = tier_duchy + } + } + } + } + } + + is_valid = { + top_liege = this + custom_tooltip = { + text = found_kingdom_toledo_capital_tt + capital_county = title:c_toledo + } + custom_tooltip = { + text = found_kingdom_toledo_culture_tt + culture = { has_cultural_pillar = heritage_iberian } + } + custom_tooltip = { + text = found_kingdom_toledo_faith_tt + faith = { + portrait_religious_faith_or_foundational_trigger = { FAITH = faith:mozarabic_church } + } + } + completely_controls = title:d_toledo + custom_tooltip = { + text = found_kingdom_toledo_duchy_tt + any_held_title = { + title_tier = duchy + is_titular = no + NOT = { this = title:d_toledo } + root = { completely_controls = prev } + any_title_to_title_neighboring_and_across_water_duchy = { this = title:d_toledo } + } + } + } + + is_valid_showing_failures_only = { + is_landed = yes + } + + cost = { + gold = { + value = 0 + if = { + limit = { + has_treasury = no + } + add = 250 + } + } + treasury = { + value = 0 + if = { + limit = { + has_treasury = yes + } + add = 250 + } + } + } + + effect = { + save_scope_as = toledo_former + gain_heroic_legend_seed_tooltip_effect = yes + fp2_struggle_found_kingdom_toledo_empire_effect = yes + save_scope_value_as = { + name = has_kingdom_toledo_absorb_list_been_created + value = yes + } + trigger_event = fp2_other_decisions.1100 + #Can only happen once + add_to_global_variable_list = { + name = unavailable_unique_decisions + target = flag:form_toledo_decision + } + set_global_variable = { + name = form_toledo_decision + value = scope:toledo_former + } + } + ai_check_interval_by_tier = { + barony = 0 + county = 0 + duchy = 120 + kingdom = 120 + empire = 120 + hegemony = 120 + } + + ai_potential = {} + + ai_will_do = { + base = 100 + } +} + +############################################# +# Develop a city +# by Maxence Voleau +############################################# +improve_city_province_decision = { + title = improve_city_province_decision_name + picture = { + reference = "gfx/interface/illustrations/decisions/decision_misc.dds" + } + desc = improve_city_province_decision_desc + selection_tooltip = improve_city_province_decision_tooltip + cooldown = { years = 50 } + sort_order = 90 + + is_shown = { + is_landless_adventurer = no + dynasty ?= { + has_dynasty_perk = fp2_urbanism_legacy_5 + } + } + + is_valid_showing_failures_only = { + custom_tooltip = { + text = improve_city_province_decision_at_least_one_city_tt + any_sub_realm_county = { + count > 0 + holder = root + any_county_province = { + building_slots <= 5 + has_holding_type = city_holding + } + } + } + } + + effect = { + + #Generate intelligible effect + if = { + limit = { + any_sub_realm_county = { + count > 0 + holder = root + any_county_province = { + building_slots <= 5 + has_holding_type = city_holding + } + } + } + every_sub_realm_county = { + # only county directly owned by the character + limit = { holder = root } + every_county_province = { + limit = { + has_holding_type = city_holding + building_slots <= 5 + } + save_scope_as = current_province + prev.holder = { + send_interface_toast = { + type = event_toast_effect_good + title = city_gained_building_slots + left_icon = scope:current_province.barony + + scope:current_province = { + add_province_modifier = extra_building_slot + } + } + } + + } + } + } + else = { + custom_tooltip = improve_city_province_decision_decision_no_effect + } + } + + cost = { + gold = { + value = 0 + if = { + limit = { + has_treasury = no + } + add = improve_city_province_decision_cost + multiply = { + value = 1 + every_sub_realm_county = { + # only county directly owned by the character + limit = { holder = root } + every_county_province = { + limit = { + building_slots <= 5 + has_holding_type = city_holding + } + add = 1 + } + } + } + } + } + treasury = { + value = 0 + if = { + limit = { + has_treasury = yes + } + add = improve_city_province_decision_cost + multiply = { + value = 1 + every_sub_realm_county = { + # only county directly owned by the character + limit = { holder = root } + every_county_province = { + limit = { + building_slots <= 5 + has_holding_type = city_holding + } + add = 1 + } + } + } + } + } + } + + ai_check_interval_by_tier = { + barony = 0 + county = 0 + duchy = 120 + kingdom = 120 + empire = 120 + hegemony = 120 + } + + ai_potential = { + is_at_war = no + # Has enough gold. + short_term_gold >= ai_war_chest_desired_gold_value + NOR = { + has_trait = lazy + has_trait = callous + } + } + + ai_will_do = { + base = 100 + } +} From 6276a312ef864184d9550870fa74bc4975f52350 Mon Sep 17 00:00:00 2001 From: Fishedotjpg Date: Sat, 20 Dec 2025 17:27:13 +0000 Subject: [PATCH 3/3] fix --- .../00_religious_triggers.txt | 2169 +++++++++++++++++ 1 file changed, 2169 insertions(+) create mode 100644 N3OW/common/scripted_triggers/00_religious_triggers.txt diff --git a/N3OW/common/scripted_triggers/00_religious_triggers.txt b/N3OW/common/scripted_triggers/00_religious_triggers.txt new file mode 100644 index 00000000..53e73dbc --- /dev/null +++ b/N3OW/common/scripted_triggers/00_religious_triggers.txt @@ -0,0 +1,2169 @@ + +###TRIGGER LIST + +# has_strong_religious_conviction_trigger +# is_christian_trigger + +###DOCTRINE BASED### +# is_weak_claimant_due_to_gender_trigger +# can_be_combatant_based_on_gender_trigger +# can_be_clergy_due_to_gender_trigger +# faith_is_aniconic_trigger +# relation_with_character_is_incestuous_in_faith_trigger - Relation would be shunned in faith +# relation_with_character_is_incestuous_in_my_faith_trigger - Relation would be shunned in the faith of character you use trigger in +# relation_with_character_is_incestuous_in_my_or_lieges_faith_trigger - Relation would be shunned in the faith of the character you use trigger in or their liege's faith +# faith_allows_marriage_consanguinity_trigger +# relation_with_character_is_sodomy_in_faith_trigger +# relation_with_character_is_sodomy_trigger +# relation_with_character_is_sodomy_in_my_or_lieges_faith_trigger +# trait_is_shunned_in_faith_trigger +# trait_is_criminal_in_faith_trigger +# trait_is_shunned_or_criminal_in_my_or_lieges_faith_trigger +# has_negative_attitude_towards_trait_trigger +# secret_is_shunned_in_faith_trigger +# secret_is_criminal_in_faith_trigger +# secret_is_shunned_or_criminal_in_my_or_lieges_faith_trigger +# religion_has_angels_trigger +# highgod_is_passive_trigger +# highgod_is_active_trigger +# is_reincarnation_trigger +# holy_order_1000_request_target_trigger - Is this ruler a valid target for a holy order to request land from? + +###HERESY TRIGGERS### +# is_valid_heresiarch + +###RELIGIOUS INTERACTIONS### +# can_take_religious_vows_trigger + + +# CHECK A NUMBER OF RELIGION-RELATED CONDITIONS TO DETERMINE HOW STRONG OF A BELIEVER THEY SEEM TO BE +has_strong_religious_conviction_trigger = { + NOR = { + has_trait = cynical + has_trait = excommunicated + } + OR = { + has_trait = zealous + has_trait = pilgrim + has_trait = devoted + has_trait = sayyid + has_trait = saoshyant + has_trait = savior + has_trait = divine_blood + has_trait = blood_of_prophet + has_trait = faith_warrior + has_trait = saint + } +} + +is_christian_trigger = { + faith = { religion_tag = christianity_religion } +} + +# Not-non-XYZ triggers allow us to check for specific historical faiths whilst still defaulting to something positive for variant faiths. +## E.g., looking to see if something would only be of interest to Catholics, but if we're dealing with a player-made heresy, still return true. This way mechanics will default to on rather than off (still likely to result in weird GHWs, but at least less random ones). +not_non_catholic_standard_christian_faith_trigger = { + NOR = { + this = faith:orthodox + this = faith:iconoclast + this = faith:coptic + this = faith:armenian_apostolic + } +} + +not_non_orthodox_standard_christian_faith_trigger = { + NOR = { + this = faith:catholic + this = faith:coptic + this = faith:armenian_apostolic + } +} + +not_non_coptic_standard_christian_faith_trigger = { + NOR = { + this = faith:catholic + this = faith:orthodox + this = faith:iconoclast + this = faith:armenian_apostolic + } +} + +not_non_armenian_standard_christian_faith_trigger = { + NOR = { + this = faith:catholic + this = faith:orthodox + this = faith:iconoclast + this = faith:coptic + } +} + +is_weak_claimant_due_to_gender_trigger = { + OR = { + AND = { + $FAITH$ = { has_doctrine_parameter = female_claims_are_weak } + $CHARACTER$ = { is_female = yes } + } + AND = { + $FAITH$ = { has_doctrine_parameter = male_claims_are_weak } + $CHARACTER$ = { is_male = yes } + } + } +} + +can_be_combatant_based_on_gender_trigger = { + custom_description = { + text = "can_be_combatant_based_on_gender" + object = this + subject = $ARMY_OWNER$ + # Priests only fight if faith has war priests + trigger_if = { + limit = { + is_clergy = yes + } + OR = { + faith = { has_doctrine_parameter = clergy_can_fight } + culture = { has_cultural_parameter = culture_clergy_can_fight } + AND = { + $ARMY_OWNER$.culture = { + has_cultural_parameter = high_prowess_ignores_knight_restrictions + } + prowess >= 10 + } + } + } + OR = { + trigger_if = { # Has the Royal Court and thus can modify pillars + limit = { + has_dlc_feature = diverge_culture # Can modify pillars + } + trigger_if = { + limit = { + $ARMY_OWNER$.culture = { has_cultural_parameter = martial_custom_male_only_combatant } + } + is_male = yes + } + trigger_else_if = { + limit = { + $ARMY_OWNER$.culture = { has_cultural_parameter = martial_custom_female_only_combatant } + } + is_female = yes + } + trigger_else = {} + } + trigger_else = { # Does not have the Royal Court and thus combatant is governed by faith + OR = { + $ARMY_OWNER$.faith = { has_doctrine_parameter = combatant_can_be_either_gender_if_no_roco } + AND = { + $ARMY_OWNER$.faith = { has_doctrine_parameter = combatant_must_be_male_if_no_roco } + is_male = yes + } + AND = { + $ARMY_OWNER$.faith = { has_doctrine_parameter = combatant_must_be_female_if_no_roco } + is_female = yes + } + } + } + AND = { + # No need to gender diversify this: if they're a right-gender shieldperson of the culture, then they've already got permission to fight from the previous AND conditions. + has_trait = shieldmaiden + $ARMY_OWNER$ = { + culture = { has_cultural_parameter = has_access_to_shieldmaidens } + } + } + # Event-based special exceptions + OR = { + has_character_modifier = ignores_gender_army_rules + has_character_modifier = mpo_destined_leader_modifier + } + AND = { + prowess >= 10 + $ARMY_OWNER$.culture = { has_cultural_parameter = high_prowess_ignores_knight_restrictions } + NOT = { $ARMY_OWNER$.culture = { has_cultural_parameter = minimum_prowess_for_knights } } + } + AND = { + prowess >= 12 + $ARMY_OWNER$.culture = { + has_cultural_parameter = high_prowess_ignores_knight_restrictions + has_cultural_parameter = minimum_prowess_for_knights + } + } + } + } +} + +can_be_clergy_due_to_gender_trigger = { + OR = { + AND = { + faith = { has_doctrine_parameter = clergy_must_be_female } + is_female = yes + } + AND = { + faith = { has_doctrine_parameter = clergy_must_be_male } + is_male = yes + } + faith = { has_doctrine_parameter = clergy_can_be_either_gender } + } +} + +is_wrong_gender_in_faith_trigger = { + OR = { + AND = { + is_female = yes + $FAITH$ = { has_doctrine_parameter = male_dominated_law } + } + AND = { + is_male = yes + $FAITH$ = { has_doctrine_parameter = female_dominated_law } + } + } +} + +faith_is_aniconic_trigger = { + faith = { + OR = { + religion = religion:islam_religion + has_doctrine = tenet_aniconism + } + } +} + +#Needs CHARACTER and FAITH +relation_with_character_is_incestuous_in_faith_trigger = { + OR = { + # doctrine_consanguinity_dynastic; not within the same descent group + AND = { + $FAITH$ = { has_doctrine = doctrine_consanguinity_dynastic } + OR = { + is_close_or_extended_family_of = $CHARACTER$ + dynasty = $CHARACTER$.dynasty + } + } + #doctrine_consanguinity_restricted; absolutely no family business + AND = { + $FAITH$ = { has_doctrine = doctrine_consanguinity_restricted } + is_close_or_extended_family_of = $CHARACTER$ #[parents, children, siblings, grandparents, grandchildren, cousins, uncles, aunts, nephews, nieces] + } + #doctrine_consanguinity_cousins; the only acceptable incest is with your cousin + AND = { + $FAITH$ = { has_doctrine = doctrine_consanguinity_cousins } + OR = { + is_close_family_of = $CHARACTER$ #[parents, children, siblings, grandparents, grandchildren] + is_uncle_or_aunt_of = $CHARACTER$ + is_nibling_of = $CHARACTER$ + } + } + #doctrine_consanguinity_aunt_nephew_and_uncle_niece; extended family is ok + AND = { + $FAITH$ = { has_doctrine = doctrine_consanguinity_aunt_nephew_and_uncle_niece } + is_close_family_of = $CHARACTER$ + } + #doctrine_consanguinity_unrestricted; all forms of incest is acceptable + } +} + +#Note: only checks from the viewpoint of current scope. Needs CHARACTER +relation_with_character_is_incestuous_in_my_faith_trigger = { + faith = { save_temporary_scope_as = my_faith } + relation_with_character_is_incestuous_in_faith_trigger = { CHARACTER = $CHARACTER$ FAITH = scope:my_faith } +} + +relation_with_character_is_incestuous_in_my_or_lieges_faith_trigger = { + OR = { + AND = { + faith = { #My faith doesn't approve + save_temporary_scope_as = check_faith + } + relation_with_character_is_incestuous_in_faith_trigger = { CHARACTER = $CHARACTER$ FAITH = scope:check_faith } + } + AND = { #Liege's faith doesn't approve + liege ?= { + faith = { + save_temporary_scope_as = check_faith + } + } + relation_with_character_is_incestuous_in_faith_trigger = { CHARACTER = $CHARACTER$ FAITH = scope:check_faith } + } + } +} + +#Needs CHARACTER_1 and CHARACTER_2 +faith_allows_marriage_consanguinity_trigger = { + save_temporary_scope_as = consanguinity_faith + + NOT = { + $CHARACTER_1$ = { + relation_with_character_is_incestuous_in_faith_trigger = { + CHARACTER = $CHARACTER_2$ + FAITH = scope:consanguinity_faith + } + } + } +} +relation_between_characters_is_sodomy_in_my_faith_trigger = { + $CHARACTER_1$ = { is_male = yes } + $CHARACTER_2$ = { is_male = yes } + faith = { + OR = { + has_doctrine_parameter = homosexuality_shunned + has_doctrine_parameter = homosexuality_illegal + } + } +} + +relation_with_character_is_sodomy_in_faith_trigger = { + is_male = yes + $CHARACTER$ = { is_male = yes } + $FAITH$ = { + OR = { + has_doctrine_parameter = homosexuality_shunned + has_doctrine_parameter = homosexuality_illegal + } + } +} + +#Note: only checks from the viewpoint of current scope. Needs CHARACTER +relation_with_character_is_sodomy_trigger = { + faith = { save_temporary_scope_as = my_faith } + relation_with_character_is_sodomy_in_faith_trigger = { + CHARACTER = $CHARACTER$ + FAITH = scope:my_faith + } +} + +relation_with_character_is_sodomy_in_my_or_lieges_faith_trigger = { + OR = { + AND = { + faith = { #My faith doesn't approve + save_temporary_scope_as = check_faith + } + relation_with_character_is_sodomy_in_faith_trigger = { CHARACTER = $CHARACTER$ FAITH = scope:check_faith } + } + AND = { #Liege's faith doesn't approve + liege ?= { + faith = { + save_temporary_scope_as = check_faith + } + } + relation_with_character_is_sodomy_in_faith_trigger = { CHARACTER = $CHARACTER$ FAITH = scope:check_faith } + } + } +} + +murdering_character_is_kinslaying_in_faith_trigger = { + OR = { + is_close_or_extended_family_of = $CHARACTER$ + dynasty = $CHARACTER$.dynasty + } + $FAITH$ = { NOT = { has_doctrine = doctrine_kinslaying_accepted } } +} + +murdering_character_is_kinslaying_in_my_or_same_dynasty_lieges_faith_trigger = { + save_temporary_scope_as = kinslayer_me + faith = { + save_temporary_scope_as = check_faith + } + trigger_if = { + limit = { + liege ?= { dynasty = scope:kinslayer_me.dynasty } + } + liege = { + faith = { + save_temporary_scope_as = check_faith_liege + } + } + } + OR = { + murdering_character_is_kinslaying_in_faith_trigger = { CHARACTER = $CHARACTER$ FAITH = scope:check_faith } #My faith doesn't approve + AND = { #Liege's faith doesn't approve + liege ?= { dynasty = scope:kinslayer_me.dynasty } + murdering_character_is_kinslaying_in_faith_trigger = { CHARACTER = $CHARACTER$ FAITH = scope:check_faith_liege } + } + } +} + + + +trait_is_shunned_in_faith_trigger = { + save_temporary_scope_value_as = { + name = shunned_trait_check + value = flag:$TRAIT$ + } + OR = { + #INCEST + AND = { + scope:shunned_trait_check = flag:incestuous + $FAITH$ = { NOT = { has_doctrine_parameter = allows_unrestricted_marriage } } + } + #WITCH + AND = { + scope:shunned_trait_check = flag:witch + $FAITH$ = { has_doctrine_parameter = witchcraft_shunned } + } + #SODOMITE + AND = { + scope:shunned_trait_check = flag:sodomite + $FAITH$ = { has_doctrine_parameter = homosexuality_shunned } + } + #DEVIANT + AND = { + scope:shunned_trait_check = flag:deviant + $FAITH$ = { has_doctrine_parameter = deviancy_shunned } + } + #ADULTERER/FORNICATOR + AND = { + OR = { + scope:shunned_trait_check = flag:adulterer + scope:shunned_trait_check = flag:fornicator + } + $GENDER_CHARACTER$ = { + trigger_if = { + limit = { exists = faith } + accepts_adultery_without_penalty_trigger = no + } + } + OR = { + AND = { + $FAITH$ = { has_doctrine_parameter = adultery_female_shunned } + $GENDER_CHARACTER$ = { is_female = yes } + } + AND = { + $FAITH$ = { has_doctrine_parameter = adultery_male_shunned } + $GENDER_CHARACTER$ = { is_male = yes } + } + } + } + #KINSLAYER + AND = { + OR = { + scope:shunned_trait_check = flag:kinslayer_1 + scope:shunned_trait_check = flag:kinslayer_2 + scope:shunned_trait_check = flag:kinslayer_3 + } + $FAITH$ = { has_doctrine_parameter = kinslaying_shunned } + } + } +} + +trait_is_criminal_in_faith_trigger = { + save_temporary_scope_value_as = { + name = criminal_trait_check + value = flag:$TRAIT$ + } + OR = { + #KINSLAYER + AND = { + OR = { + scope:criminal_trait_check = flag:kinslayer_3 + scope:criminal_trait_check = flag:kinslayer_2 + scope:criminal_trait_check = flag:kinslayer_1 + } + $FAITH$ = { has_doctrine_parameter = kinslaying_any_dynasty_member_crime } + } + AND = { + OR = { + scope:criminal_trait_check = flag:kinslayer_3 + scope:criminal_trait_check = flag:kinslayer_2 + } + $FAITH$ = { has_doctrine_parameter = kinslaying_extended_family_crime } + } + AND = { + scope:criminal_trait_check = flag:kinslayer_3 + $FAITH$ = { has_doctrine_parameter = kinslaying_close_kin_crime } + } + #WITCH + AND = { + scope:criminal_trait_check = flag:witch + $FAITH$ = { has_doctrine_parameter = witchcraft_illegal } + } + #CANNIBAL + AND = { + scope:criminal_trait_check = flag:cannibal + NOT = { + $FAITH$ = { has_doctrine_parameter = cannibalism_legal } + } + } + #SODOMITE + AND = { + scope:criminal_trait_check = flag:sodomite + $FAITH$ = { has_doctrine_parameter = homosexuality_illegal } + } + #DEVIANT + AND = { + scope:criminal_trait_check = flag:deviant + $FAITH$ = { has_doctrine_parameter = deviancy_illegal } + } + #INCEST + AND = { + scope:criminal_trait_check = flag:incestuous + $FAITH$ = { NOT = { has_doctrine_parameter = consanguinity_unrestricted_incest } } + } + #ADULTERER/FORNICATOR + AND = { + OR = { + scope:criminal_trait_check = flag:adulterer + scope:criminal_trait_check = flag:fornicator + } + OR = { + AND = { + $FAITH$ = { has_doctrine_parameter = adultery_female_crime } + $GENDER_CHARACTER$ = { is_female = yes } + } + AND = { + $FAITH$ = { has_doctrine_parameter = adultery_male_crime } + $GENDER_CHARACTER$ = { is_male = yes } + } + } + } + } +} + +scoped_trait_is_criminal_in_faith_trigger = { + OR = { + #KINSLAYER + AND = { + OR = { + $TRAIT$ = trait:kinslayer_3 + $TRAIT$ = trait:kinslayer_2 + $TRAIT$ = trait:kinslayer_1 + } + $FAITH$ = { has_doctrine_parameter = kinslaying_any_dynasty_member_crime } + } + AND = { + OR = { + $TRAIT$ = trait:kinslayer_3 + $TRAIT$ = trait:kinslayer_2 + } + $FAITH$ = { has_doctrine_parameter = kinslaying_extended_family_crime } + } + AND = { + $TRAIT$ = trait:kinslayer_3 + $FAITH$ = { has_doctrine_parameter = kinslaying_close_kin_crime } + } + #WITCH + AND = { + $TRAIT$ = trait:witch + $FAITH$ = { has_doctrine_parameter = witchcraft_illegal } + } + #CANNIBAL + AND = { + $TRAIT$ = trait:cannibal + NOT = { + $FAITH$ = { has_doctrine_parameter = cannibalism_legal } + } + } + #SODOMITE + AND = { + $TRAIT$ = trait:sodomite + $FAITH$ = { has_doctrine_parameter = homosexuality_illegal } + } + #DEVIANT + AND = { + $TRAIT$ = trait:deviant + $FAITH$ = { has_doctrine_parameter = deviancy_illegal } + } + #INCEST + AND = { + $TRAIT$ = trait:incestuous + $FAITH$ = { NOT = { has_doctrine_parameter = consanguinity_unrestricted_incest } } + } + #ADULTERER/FORNICATOR + AND = { + OR = { + $TRAIT$ = trait:adulterer + $TRAIT$ = trait:fornicator + } + OR = { + AND = { + $FAITH$ = { has_doctrine_parameter = adultery_female_crime } + $GENDER_CHARACTER$ = { is_female = yes } + } + AND = { + $FAITH$ = { has_doctrine_parameter = adultery_male_crime } + $GENDER_CHARACTER$ = { is_male = yes } + } + } + } + } +} + +trait_is_shunned_or_criminal_in_faith_trigger = { + OR = { + trait_is_shunned_in_faith_trigger = { TRAIT = $TRAIT$ FAITH = $FAITH$ GENDER_CHARACTER = $GENDER_CHARACTER$ } + trait_is_criminal_in_faith_trigger = { TRAIT = $TRAIT$ FAITH = $FAITH$ GENDER_CHARACTER = $GENDER_CHARACTER$ } + } +} + +trait_is_shunned_or_criminal_in_my_or_lieges_faith_trigger = { + OR = { + AND = { + faith = { #My faith doesn't approve + save_temporary_scope_as = check_faith + } + trait_is_shunned_or_criminal_in_faith_trigger = { TRAIT = $TRAIT$ FAITH = scope:check_faith GENDER_CHARACTER = $GENDER_CHARACTER$ } + } + AND = { #Liege's faith doesn't approve + liege ?= { + faith = { + save_temporary_scope_as = check_faith + } + } + trait_is_shunned_or_criminal_in_faith_trigger = { TRAIT = $TRAIT$ FAITH = scope:check_faith GENDER_CHARACTER = $GENDER_CHARACTER$ } + } + } +} + +has_any_shunned_or_criminal_trait_in_faith_trigger = { + $CHARACTER$ = { + OR = { + #KINSLAYER + AND = { + has_trait = kinslayer_3 + trait_is_shunned_or_criminal_in_faith_trigger = { TRAIT = kinslayer_3 FAITH = $FAITH$ GENDER_CHARACTER = $CHARACTER$ } + } + AND = { + has_trait = kinslayer_2 + trait_is_shunned_or_criminal_in_faith_trigger = { TRAIT = kinslayer_2 FAITH = $FAITH$ GENDER_CHARACTER = $CHARACTER$ } + } + AND = { + has_trait = kinslayer_1 + trait_is_shunned_or_criminal_in_faith_trigger = { TRAIT = kinslayer_1 FAITH = $FAITH$ GENDER_CHARACTER = $CHARACTER$ } + } + #WITCH + AND = { + has_trait = witch + trait_is_shunned_or_criminal_in_faith_trigger = { TRAIT = witch FAITH = $FAITH$ GENDER_CHARACTER = $CHARACTER$ } + } + #CANNIBAL + AND = { + has_trait = cannibal + trait_is_shunned_or_criminal_in_faith_trigger = { TRAIT = cannibal FAITH = $FAITH$ GENDER_CHARACTER = $CHARACTER$ } + } + #SODOMITE + AND = { + has_trait = sodomite + trait_is_shunned_or_criminal_in_faith_trigger = { TRAIT = sodomite FAITH = $FAITH$ GENDER_CHARACTER = $CHARACTER$ } + } + #DEVIANT + AND = { + has_trait = deviant + trait_is_shunned_or_criminal_in_faith_trigger = { TRAIT = deviant FAITH = $FAITH$ GENDER_CHARACTER = $CHARACTER$ } + } + AND = { + has_trait = incestuous + trait_is_shunned_or_criminal_in_faith_trigger = { TRAIT = incestuous FAITH = $FAITH$ GENDER_CHARACTER = $CHARACTER$ } + } + #ADULTERER/FORNICATOR + AND = { + has_trait = adulterer + trait_is_shunned_or_criminal_in_faith_trigger = { TRAIT = adulterer FAITH = $FAITH$ GENDER_CHARACTER = $CHARACTER$ } + } + AND = { + has_trait = fornicator + trait_is_shunned_or_criminal_in_faith_trigger = { TRAIT = fornicator FAITH = $FAITH$ GENDER_CHARACTER = $CHARACTER$ } + } + } + } +} + +has_any_criminal_trait_in_faith_trigger = { + $CHARACTER$ = { + OR = { + #KINSLAYER + AND = { + has_trait = kinslayer_3 + trait_is_criminal_in_faith_trigger = { TRAIT = kinslayer_3 FAITH = $FAITH$ GENDER_CHARACTER = $CHARACTER$ } + } + AND = { + has_trait = kinslayer_2 + trait_is_criminal_in_faith_trigger = { TRAIT = kinslayer_2 FAITH = $FAITH$ GENDER_CHARACTER = $CHARACTER$ } + } + AND = { + has_trait = kinslayer_1 + trait_is_criminal_in_faith_trigger = { TRAIT = kinslayer_1 FAITH = $FAITH$ GENDER_CHARACTER = $CHARACTER$ } + } + #WITCH + AND = { + has_trait = witch + trait_is_criminal_in_faith_trigger = { TRAIT = witch FAITH = $FAITH$ GENDER_CHARACTER = $CHARACTER$ } + } + #CANNIBAL + AND = { + has_trait = cannibal + trait_is_criminal_in_faith_trigger = { TRAIT = cannibal FAITH = $FAITH$ GENDER_CHARACTER = $CHARACTER$ } + } + #SODOMITE + AND = { + has_trait = sodomite + trait_is_criminal_in_faith_trigger = { TRAIT = sodomite FAITH = $FAITH$ GENDER_CHARACTER = $CHARACTER$ } + } + #DEVIANT + AND = { + has_trait = deviant + trait_is_criminal_in_faith_trigger = { TRAIT = deviant FAITH = $FAITH$ GENDER_CHARACTER = $CHARACTER$ } + } + AND = { + has_trait = incestuous + trait_is_criminal_in_faith_trigger = { TRAIT = incestuous FAITH = $FAITH$ GENDER_CHARACTER = $CHARACTER$ } + } + #ADULTERER/FORNICATOR + AND = { + has_trait = adulterer + trait_is_criminal_in_faith_trigger = { TRAIT = adulterer FAITH = $FAITH$ GENDER_CHARACTER = $CHARACTER$ } + } + AND = { + has_trait = fornicator + trait_is_criminal_in_faith_trigger = { TRAIT = fornicator FAITH = $FAITH$ GENDER_CHARACTER = $CHARACTER$ } + } + } + } +} + +has_any_shunned_trait_in_faith_trigger = { + $CHARACTER$ = { + OR = { + #KINSLAYER + AND = { + has_trait = kinslayer_3 + trait_isshunnedl_in_faith_trigger = { TRAIT = kinslayer_3 FAITH = $FAITH$ GENDER_CHARACTER = $CHARACTER$ } + } + AND = { + has_trait = kinslayer_2 + trait_is_shunned_in_faith_trigger = { TRAIT = kinslayer_2 FAITH = $FAITH$ GENDER_CHARACTER = $CHARACTER$ } + } + AND = { + has_trait = kinslayer_1 + trait_is_shunned_in_faith_trigger = { TRAIT = kinslayer_1 FAITH = $FAITH$ GENDER_CHARACTER = $CHARACTER$ } + } + #WITCH + AND = { + has_trait = witch + trait_is_shunned_in_faith_trigger = { TRAIT = witch FAITH = $FAITH$ GENDER_CHARACTER = $CHARACTER$ } + } + #CANNIBAL + AND = { + has_trait = cannibal + trait_is_shunned_in_faith_trigger = { TRAIT = cannibal FAITH = $FAITH$ GENDER_CHARACTER = $CHARACTER$ } + } + #SODOMITE + AND = { + has_trait = sodomite + trait_is_shunned_in_faith_trigger = { TRAIT = sodomite FAITH = $FAITH$ GENDER_CHARACTER = $CHARACTER$ } + } + #DEVIANT + AND = { + has_trait = deviant + trait_is_shunned_in_faith_trigger = { TRAIT = deviant FAITH = $FAITH$ GENDER_CHARACTER = $CHARACTER$ } + } + AND = { + has_trait = incestuous + trait_is_shunned_in_faith_trigger = { TRAIT = incestuous FAITH = $FAITH$ GENDER_CHARACTER = $CHARACTER$ } + } + #ADULTERER/FORNICATOR + AND = { + has_trait = adulterer + trait_is_shunned_in_faith_trigger = { TRAIT = adulterer FAITH = $FAITH$ GENDER_CHARACTER = $CHARACTER$ } + } + AND = { + has_trait = fornicator + trait_is_shunned_in_faith_trigger = { TRAIT = fornicator FAITH = $FAITH$ GENDER_CHARACTER = $CHARACTER$ } + } + } + } +} + + +has_negative_attitude_towards_trait_trigger = { + save_temporary_scope_value_as = { + name = negative_status_check + value = flag:$TRAIT$ + } + + NOR = { + has_trait = $TRAIT$ + #INCESTUOUS + AND = { + scope:negative_status_check = flag:incestuous + any_secret = { type = secret_incest } + } + #WITCH + AND = { + scope:negative_status_check = flag:witch + any_secret = { type = secret_witch } + } + #CANNIBAL + AND = { + scope:negative_status_check = flag:cannibal + any_secret = { type = secret_cannibal } + } + #SODOMITE + AND = { + scope:negative_status_check = flag:sodomite + OR = { + has_sexuality = homosexual + has_sexuality = bisexual + } + any_secret = { + type = secret_homosexual + } + } + #ADULTERER + AND = { + scope:negative_status_check = flag:adulterer + OR = { + has_trait = lustful + AND = { + is_married = yes + any_relation = { type = lover NOT = { is_spouse_of = prev } } + } + any_relation = { + type = lover + is_married = yes + NOT = { is_spouse_of = prev } + } + } + } + #FORNICATOR + AND = { + scope:negative_status_check = flag:fornicator + OR = { + has_trait = lustful + any_relation = { type = lover always = yes } + } + } + } + + faith = { save_temporary_scope_as = my_faith } + OR = { + trait_is_shunned_in_faith_trigger = { TRAIT = $TRAIT$ FAITH = scope:my_faith GENDER_CHARACTER = $GENDER_CHARACTER$ } + trait_is_criminal_in_faith_trigger = { TRAIT = $TRAIT$ FAITH = scope:my_faith GENDER_CHARACTER = $GENDER_CHARACTER$ } + } +} + +has_followers_trigger = { + OR = { + num_character_followers >= 1 + num_county_followers >= 1 + } +} + +secret_is_blackmailable_trigger = { + OR = { + secret_is_blackmailable_strong_hook_trigger = { TARGET = $TARGET$ } + secret_is_blackmailable_weak_hook_trigger = { TARGET = $TARGET$ } + } +} + + +################### +# Heresy Triggers # +################### + +is_preferred_heresy = { + is_valid_heresy = { + ORIGIN_FAITH = $ORIGIN_FAITH$ + HERETICAL_FAITH = $HERETICAL_FAITH$ + } + + OR = { + #If we're Chistian, pick a heretical faiths which is in the same regional group as our origin faith (i.e., Lollards for Catholics, Iconoclasts for Orthodox, etc.) + AND = { + religion_tag = christianity_religion + OR = { + faiths_are_in_western_christianity_group = { FAITH_1 = $ORIGIN_FAITH$ FAITH_2 = $HERETICAL_FAITH$ } + faiths_are_in_orthodox_christianity_group = { FAITH_1 = $ORIGIN_FAITH$ FAITH_2 = $HERETICAL_FAITH$ } + faiths_are_in_eastern_christianity_group = { FAITH_1 = $ORIGIN_FAITH$ FAITH_2 = $HERETICAL_FAITH$ } + } + } + + #If we're Muslim, we want to stay within our 'branch' of Islam: + AND = { + religion_tag = islam_religion + OR = { + faiths_are_in_sunni_islam_group = { FAITH_1 = $ORIGIN_FAITH$ FAITH_2 = $HERETICAL_FAITH$} + faiths_are_in_shia_islam_group = { FAITH_1 = $ORIGIN_FAITH$ FAITH_2 = $HERETICAL_FAITH$} + faiths_are_in_muhakkima_islam_group = { FAITH_1 = $ORIGIN_FAITH$ FAITH_2 = $HERETICAL_FAITH$} + } + } + #If we're Zoroastrian, we don't want Sogdian faith in Armenia and vice versa + AND = { + religion_tag = zoroastrianism_religion + OR = { + faiths_are_eastern_zoroastrian = { FAITH_1 = $ORIGIN_FAITH$ FAITH_2 = $HERETICAL_FAITH$} + faiths_are_western_zoroastrian = { FAITH_1 = $ORIGIN_FAITH$ FAITH_2 = $HERETICAL_FAITH$} + } + } + + #Otherwise, we don't have any special preferences. + NOT = { + religion_tag = islam_religion + religion_tag = christianity_religion + religion_tag = zoroastrianism_religion + } + } +} + +is_valid_heresy = { + #The origin faith can never be its own heresy. + NOT = { $ORIGIN_FAITH$ = $HERETICAL_FAITH$ } + #Must not be considered invalid + invalid_for_heresy_events = no + # A heretical faith can't be currently locked off via variable. + $HERETICAL_FAITH$ = { + NOR = { + has_variable = block_conversion_till_decision_taken + has_variable = block_conversion_till_nebulous_circumstances + } + } + #Depending on the origin faith's religion/religion group, there may have additional requirements for a heresy to be considered valid. + OR = { + #For Christian Faiths, the origin and heretical faiths must not both be Ecumenical (excepting the faiths which aren't technically ecumenical). + AND = { + religion_tag = christianity_religion + NAND = { + $ORIGIN_FAITH$ = { + has_doctrine = special_doctrine_ecumenical_christian + OR = { + this = faith:insular_celtic + this = faith:bosnian_church + this = faith:mozarabic_church + } + } + $HERETICAL_FAITH$ = { + has_doctrine = special_doctrine_ecumenical_christian + OR = { + this = faith:insular_celtic + this = faith:bosnian_church + this = faith:mozarabic_church + } + } + } + } + AND = { #FP3: for Zoroastrianism, Bedhin faiths are never heresies of each other + religion_tag = zoroastrianism_religion + NAND = { + $ORIGIN_FAITH$ = { + has_doctrine = doctrine_major_branch_behdin + } + $HERETICAL_FAITH$ = { + has_doctrine = doctrine_major_branch_behdin + } + } + } + #No special requirements for Muslims, Jews, or Yazidis + religion_tag = islam_religion + religion_tag = judaism_religion + #Eastern Faiths can shift and spread amongst each other. + OR = { + religion_tag = buddhism_religion + religion_tag = hinduism_religion + religion_tag = jainism_religion + religion_tag = dualism_religion + } + #No special requirements for Pagan religions. + has_doctrine = pagan_hostility_doctrine + } +} + +is_valid_heresiarch = { + is_landed = yes + faith = root + OR = { + highest_held_title_tier = tier_duchy + highest_held_title_tier = tier_county + } + is_imprisoned = no + is_capable_adult_ai = yes + is_playable_character = yes + is_landless_adventurer = no + primary_title ?= { + is_landless_type_title = no + is_noble_family_title = no + } + exists = capital_county + NOT = { has_trait = heresiarch } + no_heretical_hof_faith_trigger = yes + recently_converted_faith_trigger = no # As amusing as it may be, rulers shouldn't 'flip-flop' between Faiths, so we need to enforce a cooldown on heresy conversions. +} + +no_heretical_hof_faith_trigger = { #Head of Faith shouldn't convert. + OR = { + NOT = { exists = root.religious_head } + AND = { + exists = root.religious_head + this != root.religious_head + } + } +} + +#Christian Heresy Groups +faiths_are_in_western_christianity_group = { + OR = { + $FAITH_1$ = faith:catholic + $FAITH_1$ = faith:cathar + $FAITH_1$ = faith:waldensian + $FAITH_1$ = faith:lollard + AND = { + $FAITH_1$ = faith:insular_celtic + scope:heretic_capital.title_province = { geographical_region = world_europe_west_britannia } + } + AND = { + $FAITH_1$ = faith:mozarabic_church + scope:heretic_capital.title_province = { geographical_region = world_europe_west_iberia } + } + } + OR = { + $FAITH_2$ = faith:catholic + $FAITH_2$ = faith:cathar + $FAITH_2$ = faith:waldensian + $FAITH_2$ = faith:lollard + $FAITH_2$ = faith:priscillianism + AND = { + $FAITH_2$ = faith:insular_celtic + scope:heretic_capital.title_province = { geographical_region = world_europe_west_britannia } + } + AND = { + $FAITH_2$ = faith:mozarabic_church + scope:heretic_capital.title_province = { geographical_region = world_europe_west_iberia } + } + } +} + +faiths_are_in_orthodox_christianity_group = { + OR = { + $FAITH_1$ = faith:orthodox + $FAITH_1$ = faith:iconoclast + $FAITH_1$ = faith:bogomilist + $FAITH_1$ = faith:paulician + AND = { + $FAITH_1$ = faith:bosnian_church + scope:heretic_capital.title_province = { geographical_region = world_europe_south_east } + } + } + OR = { + $FAITH_2$ = faith:orthodox + $FAITH_2$ = faith:iconoclast + $FAITH_2$ = faith:bogomilist + $FAITH_2$ = faith:paulician + $FAITH_2$ = faith:bosnian_church + $FAITH_2$ = faith:cainitism + AND = { + $FAITH_1$ = faith:bosnian_church + scope:heretic_capital.title_province = { geographical_region = world_europe_south_east } + } + } +} + +faiths_are_in_eastern_christianity_group = { + OR = { + $FAITH_1$ = faith:coptic + $FAITH_1$ = faith:armenian_apostolic + $FAITH_1$ = faith:nestorian + $FAITH_1$ = faith:messalian + $FAITH_1$ = faith:paulician + } + OR = { + $FAITH_2$ = faith:coptic + $FAITH_2$ = faith:armenian_apostolic + $FAITH_2$ = faith:nestorian + $FAITH_2$ = faith:messalian + $FAITH_2$ = faith:paulician + $FAITH_2$ = faith:mandeaism + } +} + +faiths_are_shia_zandaqa_sub_group = { + OR = { + this = faith:quranist + this = faith:qarmatian + this = faith:ghulat + this = faith:alawite + this = faith:alevi + this = faith:druze + } +} + +faiths_are_in_sunni_islam_group = { + $FAITH_1$ = { + has_doctrine = muhammad_succession_sunni_doctrine + } + $FAITH_2$ = { + OR = { + has_doctrine = muhammad_succession_sunni_doctrine + has_doctrine = muhammad_succession_muhakkima_doctrine + this = faith:sabianism + this = faith:manichean + this = faith:quranist + } + } +} + +faiths_are_in_shia_islam_group = { + $FAITH_1$ = { + OR = { + has_doctrine = muhammad_succession_shia_doctrine + faiths_are_shia_zandaqa_sub_group = yes + } + } + $FAITH_2$ = { + OR = { + has_doctrine = muhammad_succession_shia_doctrine + has_doctrine = muhammad_succession_muhakkima_doctrine + faiths_are_shia_zandaqa_sub_group = yes + this = faith:valentinianism + this = faith:sabianism + } + } +} + +faiths_are_in_muhakkima_islam_group = { + $FAITH_1$ = { + has_doctrine = muhammad_succession_muhakkima_doctrine + } + $FAITH_2$ = { + OR = { + has_doctrine = muhammad_succession_muhakkima_doctrine + this = faith:manichean + this = faith:valentinianism + } + } +} + +faiths_are_eastern_zoroastrian = { #FP3 update - so that Armenian faith (Arewordik) don't appear as a heresy in Sogdia + OR = { + $FAITH_1$ = faith:mazdayasna + $FAITH_1$ = faith:khurmazta + $FAITH_1$ = faith:gayomarthianism + $FAITH_2$ = faith:zurvanism + $FAITH_2$ = faith:mazdakism + $FAITH_2$ = faith:khurramism + } + OR = { + $FAITH_1$ = faith:mazdayasna + $FAITH_1$ = faith:khurmazta + $FAITH_1$ = faith:gayomarthianism + $FAITH_2$ = faith:zurvanism + $FAITH_2$ = faith:mazdakism + $FAITH_2$ = faith:khurramism + } +} + +faiths_are_western_zoroastrian = { #FP3 update - so that Sogdian faith (Khurmazta) don't appear as a heresy in Armenia + OR = { + $FAITH_1$ = faith:mazdayasna + $FAITH_1$ = faith:gayomarthianism + $FAITH_2$ = faith:zurvanism + $FAITH_2$ = faith:mazdakism + $FAITH_2$ = faith:khurramism + $FAITH_2$ = faith:urartuism + } + OR = { + $FAITH_1$ = faith:mazdayasna + $FAITH_1$ = faith:gayomarthianism + $FAITH_2$ = faith:zurvanism + $FAITH_2$ = faith:mazdakism + $FAITH_2$ = faith:khurramism + $FAITH_2$ = faith:urartuism + } +} + +refusing_conversion_is_crime_trigger = { + faith = { + trigger_if = { # Only apply imprisonment reason if actor's faith is not the state faith + limit = { + $CHARACTER$ = { + top_liege = { government_allows = state_faith } + faith = $CHARACTER$.top_liege.primary_title.state_faith + } + } + always = no + } + OR = { + religion_tag = christianity_religion + religion_tag = islam_religion + religion_tag = judaism_religion + religion_tag = zoroastrianism_religion + } + NOT = { + faith_hostility_level = { + target = $CHARACTER$.faith + value <= faith_astray_level + } + } + } +} + +is_hostile_enough_for_holy_war_trigger = { + faith_hostility_level = { + target = $FAITH$ + value >= religious_cb_enabled_hostility_level + } +} + +barony_is_valid_for_holy_order_lease_trigger = { + title_province = { + OR = { + has_holding_type = castle_holding + has_holding_type = city_holding + } + } + trigger_if = { + limit = { + holder.primary_title.tier != tier_barony + } + can_be_leased_out = yes + } + trigger_if = { + limit = { + NOT = { holder = $CHARACTER$ } + } + holder.primary_title.tier = tier_barony + } + NOT = { + is_leased_out = yes + } +} + +barony_is_valid_for_holy_order_lease_cancellation_trigger = { + is_under_holy_order_lease = yes + has_revokable_lease = yes + lessee = { + NOT = { + has_strong_hook = prev.holder + } + } +} + +religion_has_angels_trigger = { + OR = { + religion = religion:christianity_religion + religion = religion:islam_religion + religion = religion:zoroastrianism_religion + religion = religion:dualism_religion + religion = religion:judaism_religion + religion = religion:yazidi_religion + } +} + +religion_has_circumcision_trigger = { + OR = { + religion = religion:islam_religion + religion = religion:judaism_religion + } +} + +is_heretic_trigger = { + $WHO$.faith.religion = $TARGET$.faith.religion + $WHO$.faith = { + faith_hostility_level = { + target = $TARGET$.faith + value >= religious_cb_enabled_hostility_level + } + } +} + +is_heathen_trigger = { + NOT = { $WHO$.faith.religion = $TARGET$.faith.religion } + $TARGET$.faith = { + has_doctrine = pagan_hostility_doctrine + } + $WHO$.faith = { + faith_hostility_level = { + target = $TARGET$.faith + value >= religious_cb_enabled_hostility_level + } + } +} + +is_infidel_trigger = { + NOT = { $WHO$.faith.religion = $TARGET$.faith.religion } + $TARGET$.faith = { + NOT = { has_doctrine = pagan_hostility_doctrine } + } + $WHO$.faith = { + faith_hostility_level = { + target = $TARGET$.faith + value >= religious_cb_enabled_hostility_level + } + } +} + +valid_demand_conversion_conditions_trigger = { + scope:recipient = { + NOR = { + has_strong_hook = scope:actor + has_trait = devoted + has_trait = order_member + is_imprisoned_by = scope:actor + is_at_war_with = scope:actor + } + } + scope:actor = { + trigger_if = { + limit = { + government_has_flag = government_is_landless_adventurer + scope:recipient = { is_courtier_of = scope:actor } + } + custom_tooltip = { + text = valid_demand_conversion_conditions_trigger.tt.domicile_requires_shrine + domicile = { has_domicile_parameter = camp_enable_conversion } + } + } + NAND = { + has_trait = nomadic_philosophy + has_trait = zealous + } + } + + custom_description = { + text = "is_head_of_religion" + subject = scope:recipient + scope:recipient.faith.religious_head != scope:recipient + } + custom_description = { + text = "is_protected_via_contract" + subject = scope:recipient + # Vassal Contract forbids meddling by liege + NAND = { + exists = scope:recipient.liege + scope:recipient.liege = scope:actor + scope:recipient = { + is_ruler = yes + vassal_contract_has_flag = religiously_protected + } + } + } + trigger_if = { + limit = { + scope:recipient = { + AND = { + has_variable = cannot_be_converted_by_value + var:cannot_be_converted_by_value = scope:actor + } + } + } + custom_tooltip = { + text = promised_to_not_convert_character + scope:recipient = { + NOR = { + has_variable = cannot_be_converted_by_value + var:cannot_be_converted_by_value = scope:actor + } + } + } + } + custom_tooltip = { + text = cannot_take_overt_hostile_actions_against_diarch.tt + NOT = { scope:recipient ?= scope:actor.diarch } + } +} + +valid_ask_for_conversion_conditions_trigger = { # Deliberate variant of the above, so you can ask your diarch nicely to convert if you made a new faith + scope:recipient = { + NOR = { + has_strong_hook = scope:actor + has_trait = devoted + has_trait = order_member + is_imprisoned_by = scope:actor + is_at_war_with = scope:actor + } + } + scope:actor = { + trigger_if = { + limit = { + government_has_flag = government_is_landless_adventurer + scope:recipient = { is_courtier_of = scope:actor } + } + custom_tooltip = { + text = valid_demand_conversion_conditions_trigger.tt.domicile_requires_shrine + domicile = { has_domicile_parameter = camp_enable_conversion } + } + } + NAND = { + has_trait = nomadic_philosophy + has_trait = zealous + } + } + + custom_description = { + text = "is_head_of_religion" + subject = scope:recipient + scope:recipient.faith.religious_head != scope:recipient + } + custom_description = { + text = "is_protected_via_contract" + subject = scope:recipient + # Vassal Contract forbids meddling by liege + NAND = { + exists = scope:recipient.liege + scope:recipient.liege = scope:actor + scope:recipient = { + is_ruler = yes + vassal_contract_has_flag = religiously_protected + } + } + } + trigger_if = { + limit = { + scope:recipient = { + AND = { + has_variable = cannot_be_converted_by_value + var:cannot_be_converted_by_value = scope:actor + } + } + } + custom_tooltip = { + text = promised_to_not_convert_character + scope:recipient = { + NOR = { + has_variable = cannot_be_converted_by_value + var:cannot_be_converted_by_value = scope:actor + } + } + } + } +} + +highgod_is_passive_trigger = { + OR = { + religion_tag = buddhism_religion + religion_tag = jainism_religion + religion_tag = taoism_religion + religion_tag = west_african_roog_religion + religion_tag = zunism_religion + } +} + +highgod_is_active_trigger = { + highgod_is_passive_trigger = no +} + + +fertilitygod_is_active_trigger = { + highgod_is_active_trigger = yes +} + + +###REINCARNATION### +can_become_reincarnation_trigger = { + save_temporary_scope_as = reincarnated_child + faith = { + has_doctrine = tenet_reincarnation + } + any_parent = { + is_playable_character = yes + faith = scope:reincarnated_child.faith + } +} + +can_reincarnate_trigger = { + is_alive = no + OR = { + has_trait = temperate + has_trait = greedy + has_trait = generous + has_trait = diligent + has_trait = calm + has_trait = arrogant + has_trait = humble + has_trait = deceitful + has_trait = honest + has_trait = brave + has_trait = gregarious + has_trait = ambitious + has_trait = just + has_trait = zealous + has_trait = compassionate + has_trait = stubborn + has_trait = forgiving + has_trait = lunatic + has_trait = dull + has_trait = intellect_bad + has_trait = shrewd + has_trait = intellect_good + has_trait = strong + has_trait = physique_good + } +} + +is_reincarnation_trigger = { + can_become_reincarnation_trigger = yes + has_variable = reincarnation_of +} + +# Used in faith scope, COUNT is number of faiths to at least have and CHARACTER is who must own them +num_realm_holy_sites_faithful_holders = { + $CHARACTER$ = { save_temporary_scope_as = root_scope } + trigger_if = { + limit = { + exists = $CHARACTER$.confederation + } + custom_description = { + text = direct_realm_holy_sites_held_by_faithful_confederation + subject = $CHARACTER$ + object = this + value = 1 + any_holy_site = { + county = { + save_temporary_scope_as = current_holy_site + is_holy_site_controlled_by = $CHARACTER$ + holder.faith = $CHARACTER$.faith + } + } + } + } + custom_description = { + text = number_realm_holy_sites_held_by_faithful + subject = $CHARACTER$ + object = this + value = $COUNT$ + any_holy_site = { + count >= $COUNT$ + county = { + save_temporary_scope_as = current_holy_site + OR = { + is_holy_site_controlled_by = $CHARACTER$ + $CHARACTER$.confederation ?= { + is_house_based = no # any_confederation_member is not performant for house blocs + any_confederation_member = { + scope:current_holy_site = { + is_holy_site_controlled_by = prev + } + } + } + } + holder.faith = $CHARACTER$.faith + } + } + } +} + +### Head of Faith +can_create_temporal_head_of_faith_title_trigger = { + num_realm_holy_sites_faithful_holders = { + COUNT = holy_sites_to_create_temporal_head_of_faith + CHARACTER = ROOT + } + root = { piety_level >= high_piety_level } + trigger_if = { + limit = { + root = { top_liege != this } + } + custom_description = { + text = cannot_create_hof_title_at_or_above_liege_tier + root.liege.primary_title.tier > tier_duchy + } + } +} + +can_create_spiritual_head_of_faith_title_trigger = { + num_realm_holy_sites_faithful_holders = { + COUNT = holy_sites_to_create_spiritual_head_of_faith + CHARACTER = ROOT + } + root = { piety_level >= medium_piety_level } + trigger_if = { + limit = { has_doctrine = special_doctrine_not_allowed_to_hof } + NOT = { has_doctrine = special_doctrine_not_allowed_to_hof } + } + NAND = { + exists = religious_head + has_doctrine_parameter = maintains_head_of_faith_on_creation + } +} + +# this = Person trying to create the title +can_afford_create_head_of_faith_title_cost_trigger = { + trigger_if = { + limit = { + faith = { + has_doctrine_parameter = temporal_head_of_faith + OR = { + has_doctrine = muhammad_succession_sunni_doctrine + has_doctrine = muhammad_succession_shia_doctrine + } + } + } + trigger_if = { + limit = { NOT = { has_trait = sayyid } } + piety >= massive_piety_value + } + } + trigger_else_if = { + limit = { + faith = { + has_doctrine_parameter = temporal_head_of_faith + } + } + piety >= major_piety_value + } + trigger_else = { + limit = { + faith = { + has_doctrine_parameter = spiritual_head_of_faith + } + } + gold >= medium_gold_max_value + } +} + +# FAITH = The faith we are trying to make the head of faith title for +# this = Person trying to create the title +can_create_head_of_faith_title_trigger = { + $FAITH$ = { + trigger_if = { + limit = { + has_doctrine_parameter = spiritual_head_of_faith + } + can_create_spiritual_head_of_faith_title_trigger = yes + } + trigger_else_if = { + limit = { + has_doctrine_parameter = temporal_head_of_faith + } + can_create_temporal_head_of_faith_title_trigger = yes + } + trigger_else = { + # We shouldn't hit this point, but if we do use the following as error messages. + has_doctrine_parameter = spiritual_head_of_faith + has_doctrine_parameter = temporal_head_of_faith + } + } + can_afford_create_head_of_faith_title_cost_trigger = yes +} + +can_perform_the_hajj_trigger = { + faith.religion = religion:islam_religion + faith = { has_doctrine_parameter = can_go_on_pilgrimage } +} + +shared_faith_or_hof_trigger = { + OR = { + $ACTOR$.faith = $RECIPIENT$.faith + AND = { + exists = $ACTOR$.faith.religious_head + exists = $RECIPIENT$.faith.religious_head + $ACTOR$.faith.religious_head = $RECIPIENT$.faith.religious_head + } + } +} + + +###RELIGIOUS INTERACTIONS### +#Triggers that applies to both Monastery or Holy Order requirements +can_take_religious_vows_trigger = { + can_take_religious_vows_disregard_marriage_trigger = yes + + #Do they have the "wrong" marriage type? + NOR = { + custom_description = { + text = is_married_matrilineally + subject = scope:recipient + any_spouse = { + is_female = yes + matrilinear_marriage = yes + } + } + custom_description = { + text = is_married_patrilineally + subject = scope:recipient + any_spouse = { + is_male = yes + patrilinear_marriage = yes + } + } + custom_description = { + text = matrilinear_betrothal + subject = scope:recipient + betrothed ?= { + is_female = yes + matrilinear_betrothal = yes + } + } + custom_description = { + text = patrilinear_betrothal + subject = scope:recipient + betrothed ?= { + is_male = yes + patrilinear_betrothal = yes + } + } + } + bp2_valid_for_standard_interactions_trigger = yes +} + +can_take_religious_vows_disregard_marriage_trigger = { + is_available_ai = yes + faith = scope:actor.faith + is_ruler = no + NOT = { has_trait = excommunicated } + NOT = { has_character_flag = holy_order_member_requested_return_home } +} + +does_religion_exist_in_world_region_trigger = { # The most efficient way I could think of to essentially do diplomatic range triggers on religions + trigger_if = { + limit = { location = { geographical_region = world_europe } } # Even though europe has many sub regions, it's overall size is small so no need to sub-divide! + any_county_in_region = { + region = world_europe + faith.religion = $RELIGION$ + } + } + trigger_else_if = { + limit = { location = { geographical_region = world_asia_minor } } # Maybe this should be grouped with both the one above and the one below... + any_county_in_region = { + region = world_asia_minor + faith.religion = $RELIGION$ + } + } + trigger_else_if = { + limit = { location = { geographical_region = world_middle_east } } + any_county_in_region = { + region = world_middle_east + faith.religion = $RELIGION$ + } + } + trigger_else_if = { + limit = { + location = { geographical_region = world_india } } + any_county_in_region = { + region = world_india + faith.religion = $RELIGION$ + } + } + trigger_else_if = { + limit = { location = { geographical_region = world_africa } } + any_county_in_region = { + region = world_africa + faith.religion = $RELIGION$ + } + } + trigger_else_if = { + limit = { location = { geographical_region = world_steppe } } + any_county_in_region = { + region = world_steppe + faith.religion = $RELIGION$ + } + } + trigger_else_if = { + limit = { location = { geographical_region = world_asia } } + any_county_in_region = { + region = world_asia + faith.religion = $RELIGION$ + } + } + + trigger_else_if = { # We group two smaller world regions into one + limit = { + location = { + OR = { + geographical_region = world_tibet + geographical_region = world_burma + } + } + } + OR = { + any_county_in_region = { + region = world_tibet + faith.religion = $RELIGION$ + } + any_county_in_region = { + region = world_burma + faith.religion = $RELIGION$ + } + } + } + trigger_else = { always = no } # This should always go at the end of this scripted trigger +} + +### HOLY ORDERS ### +holy_order_1000_holy_order_trigger = { + title = { + NOR = { + has_variable = received_new_land + has_variable = discarded_for_being_too_big + } + } +} + +holy_order_1000_target_barony_trigger = { + tier = tier_barony + barony_is_valid_for_holy_order_lease_trigger = { CHARACTER = $CHARACTER$ } + #Don't grab something that's held by a vassal player of the one receiving the event. + trigger_if = { + limit = { + NOT = { holder = $CHARACTER$ } + } + holder = { is_ai = yes } + } +} + +holy_order_1000_request_target_trigger = { + highest_held_title_tier >= tier_duchy + is_landed_or_landless_administrative = yes + faith = root + is_available = yes + NOR = { + has_character_flag = holy_order_recently_requested_land + has_character_flag = holy_order_recently_received_land + } + save_temporary_scope_as = ruler + any_sub_realm_barony = { + holy_order_1000_target_barony_trigger = { CHARACTER = scope:ruler } + } +} + +faith_dominant_gender_male_or_equal = { + faith = { + OR = { + has_doctrine_parameter = male_dominated_law + has_doctrine_parameter = gender_equal_law + } + } +} + +faith_dominant_gender_female_or_equal = { + faith = { + OR = { + has_doctrine_parameter = female_dominated_law + has_doctrine_parameter = gender_equal_law + } + } +} + +is_theological_character_trigger = { + OR = { + has_trait = theologian + has_trait = devoted + has_trait = order_member + AND = { + is_playable_character = yes + government_has_flag = government_is_theocracy + } + + } +} + +would_be_sinful_adulterer_trigger = { + is_married = yes + trigger_if = { + limit = { is_male = yes } + NOT = { + faith = { has_doctrine = doctrine_adultery_men_accepted } + } + } + trigger_else = { + NOT = { + faith = { has_doctrine = doctrine_adultery_women_accepted } + } + } +} + +has_tolerant_faith_or_culture_trigger = { + OR = { + faith = { has_doctrine = doctrine_pluralism_pluralistic } + culture = { has_cultural_parameter = less_likely_to_force_conversion } + culture = { has_cultural_tradition = tradition_religion_blending } + has_trait = nomadic_philosophy + } +} + +is_open_to_inviting_other_faiths_trigger = { + OR = { + faith = { has_doctrine = tenet_adaptive } + faith = { has_doctrine = unreformed_faith_doctrine } + faith = { has_doctrine = doctrine_pluralism_pluralistic } + culture = { has_cultural_tradition = tradition_religion_blending } + culture = { has_cultural_tradition = tradition_tgp_religious_hospitality } + } +} + +faith_is_open_minded_trigger = { + OR = { + has_doctrine = tenet_adaptive + has_doctrine = doctrine_pluralism_pluralistic + } +} + +is_mainstream_jewish_faith = { + religion = religion:judaism_religion + NOT = { + this = faith:samaritan + this = faith:haymanot + this = faith:malabarism + this = faith:kabarism + } +} + +is_unprotected_hostile_faith = { # Checks if the faith is at least hostile but not protected by a contract, used in a county scope + faith = { + faith_hostility_level = { + target = prev.holder.top_liege.faith + value >= 2 + } + } + holder = { + NOT = { vassal_contract_has_flag = religiously_protected } + } + trigger_if = { # Does anyone in the hierarchy have religious protection? + limit = { + holder = { + any_liege_or_above = { + faith = prev.faith + } + } + } + holder = { + any_liege_or_above = { + NOT = { vassal_contract_has_flag = religiously_protected } + } + } + } +} + +### SYNCRETIC TRIGGERS ### + +islam_or_syncretic_with_islam_trigger = { + $CHARACTER$ = { + faith = { + OR = { + religion = religion:islam_religion + has_doctrine = tenet_islamic_syncretism + } + } + } +} + +judaism_or_syncretic_with_judaism_trigger = { + $CHARACTER$ = { + faith = { + OR = { + religion = religion:judaism_religion + has_doctrine = tenet_jewish_syncretism + } + } + } +} + +christianity_or_syncretic_with_christianity_trigger = { + $CHARACTER$ = { + faith = { + OR = { + religion = religion:catholic_religion + religion = religion:orthodox_religion + religion = religion:protestant_religion + has_doctrine = tenet_christian_syncretism + } + } + } +} + +unreformed_or_syncretic_with_unreformed_trigger = { + $CHARACTER$ = { + faith = { + OR = { + religion = religion:unreformed_religion + has_doctrine = tenet_unreformed_syncretism + } + } + } +} + +zoroastrian_or_syncretic_with_eastern_trigger = { + $CHARACTER$ = { + faith = { + OR = { + religion = religion:zoroastrianism_religion + has_doctrine = tenet_eastern_syncretism + } + } + } +} + +#Used on faiths +is_dharmic_faith_trigger = { + OR = { + religion = religion:hinduism_religion + religion = religion:buddhism_religion + religion = religion:jainism_religion + } +} + +#Used on provinces +has_holy_building = { + OR = { + has_building_or_higher = holy_site_cathedral_01 + has_building_or_higher = holy_site_mosque_01 + has_building_or_higher = holy_site_pagan_grand_temple_01 + has_building_or_higher = holy_site_indian_grand_temple_01 + has_building_or_higher = holy_site_other_grand_temple_01 + has_building_or_higher = holy_site_cologne_cathedral_01 + has_building_or_higher = holy_site_canterbury_cathedral_01 + has_building_or_higher = temple_of_uppsala_01 + has_building_or_higher = lund_cathedral_01 + has_building_or_higher = notre_dame_01 + has_building_or_higher = holy_site_imam_ali_mosque_01 + has_building_or_higher = holy_site_great_mosque_of_mecca_01 + has_building_or_higher = holy_site_great_mosque_of_cordoba_01 + has_building_or_higher = holy_site_great_mosque_of_djenne_01 + has_building_or_higher = holy_site_great_mosque_of_samarra_01 + has_building_or_higher = holy_site_prophetic_mosque_01 + has_building_or_higher = brihadeeswarar_temple_01 + has_building_or_higher = shwedagon_pagoda_01 + has_building_or_higher = ananda_temple_01 + has_building_or_higher = the_friday_mosque_01 + has_building_or_higher = dome_of_the_rock_01 + has_building_or_higher = temple_in_jerusalem_01 + has_building_or_higher = cluny_abbey_01 + has_building_or_higher = damascus_mosque_01 + has_building_or_higher = jokhang_01 + has_building_or_higher = beta_giyorgis_01 + has_building_or_higher = holy_wisdom_01 + has_building_or_higher = duomo_florence_01 + has_building_or_higher = konark_temple_01 + has_building_or_higher = wawel_cathedral_01 + has_building_or_higher = vatapi_caves_01 + # TGP + has_building_or_higher = holy_site_buddhist_grand_temple_01 + has_building_or_higher = holy_site_japanese_temple_01 + has_building_or_higher = holy_site_chinese_temple_01 + has_building_or_higher = holy_site_se_asia_pagan_temple_01 + has_building_or_higher = kofuku_ji_01 + has_building_or_higher = enryaku_ji_01 + has_building_or_higher = hwangnyongsa_01 + has_building_or_higher = besakih_temple_01 + has_building_or_higher = dau_temple_01 + has_building_or_higher = hanging_temple_01 + has_building_or_higher = liuhe_pagoda_01 + has_building_or_higher = pagoda_of_fogong_temple_01 + has_building_or_higher = giant_wild_goose_pagoda_01 + has_building_or_higher = maoshan_academy_01 + has_building_or_higher = tiantai_monasteries_01 + has_building_or_higher = jizu_shan_temples_01 + has_building_or_higher = nanhua_temple_01 + } +} + +invalid_for_heresy_events = { + OR = { + this = faith:conversos + this = faith:insular_celtic + this = faith:bosnian_church + this = faith:mozarabic_church + this = faith:adamites + this = faith:kabarism + } +} + +is_faith_dominant_gender = { + OR = { + AND = { + is_male = yes + faith = { + OR = { + has_doctrine_parameter = male_dominated_law + has_doctrine_parameter = gender_equal_law + } + } + } + AND = { + is_female = yes + faith = { + OR = { + has_doctrine_parameter = female_dominated_law + has_doctrine_parameter = gender_equal_law + } + } + } + } +} + +religion_is_broadly_asian_trigger = { + OR = { + religion_is_east_asian_trigger = yes + broadly_dharmic_trigger = yes + broadly_chinese_religion_trigger = yes + } +} + +religion_is_east_asian_trigger = { + OR = { + faith.religion = religion:buddhism_religion + faith.religion = religion:confucianism_religion + faith.religion = religion:taoism_religion + faith.religion = religion:shintoism_religion + } +} + +broadly_dharmic_trigger = { + OR = { + faith.religion = religion:buddhism_religion + faith.religion = religion:hinduism_religion + faith.religion = religion:jainism_religion + faith.religion = religion:bon_religion + faith.religion = religion:dab_qhuas_religion + faith.religion = religion:aluk_religion + faith.religion = religion:dayawism_religion + faith.religion = religion:hantuism_religion + faith.religion = religion:kaharingan_religion + faith.religion = religion:satsana_phi_religion + faith.religion = religion:tolotang_religion + faith.religion = religion:utaki_religion + faith.religion = religion:bimoism_religion + faith.religion = religion:moism_religion + faith.religion = religion:muism_religion + faith.religion = religion:qiangic_religion + } +} + +south_east_asian_pagan_trigger = { + OR = { + faith.religion = religion:aluk_religion + faith.religion = religion:dayawism_religion + faith.religion = religion:hantuism_religion + faith.religion = religion:kaharingan_religion + faith.religion = religion:tolotang_religion + faith.religion = religion:biliku_religion + } +} + +broadly_jungle_dwelling_trigger = { + culture = { + OR = { + has_cultural_pillar = heritage_austronesian + has_cultural_pillar = heritage_burman + has_cultural_pillar = heritage_tai + has_cultural_pillar = heritage_hmongic + has_cultural_pillar = heritage_dravidian + has_cultural_pillar = heritage_mon_khmer + has_cultural_pillar = heritage_viet + has_cultural_pillar = heritage_indo_aryan + } + } +} + +broadly_chinese_religion_trigger = { + OR = { + faith.religion = religion:taoism_religion + faith.religion = religion:confucianism_religion + } +} + +broadly_mainland_east_asian_heritage_trigger = { + culture = { + OR = { + has_cultural_pillar = heritage_chinese + has_cultural_pillar = heritage_korean + has_cultural_pillar = heritage_buyeo + has_cultural_pillar = heritage_qiangic + has_cultural_pillar = heritage_viet + } + } +} + +broadly_japanese_island_heritage_trigger = { + culture = { + OR = { + has_cultural_pillar = heritage_japonic + has_cultural_pillar = heritage_ainuic + } + } +}