From f086d8f7ec98fefe54f7d1c63d33ec69b91eb0a0 Mon Sep 17 00:00:00 2001 From: Greekman Date: Fri, 2 Oct 2026 21:57:50 +0100 Subject: [PATCH 1/5] a few changes to loc --- localization/english/replace/religion/rites_l_english.yml | 4 ++-- .../replace/religion/zz_NEOW_religion_orthodox_l_english.yml | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/localization/english/replace/religion/rites_l_english.yml b/localization/english/replace/religion/rites_l_english.yml index 8b0da8ef1..2153aaffe 100644 --- a/localization/english/replace/religion/rites_l_english.yml +++ b/localization/english/replace/religion/rites_l_english.yml @@ -441,8 +441,8 @@ orthodox_slavic_rite_adj: "Muscovite" orthodox_slavic_rite_adherent: "Muscovite Christian" orthodox_slavic_rite_adherent_plural: "Muscovite Christians" - orthodox_slavic_rite_desc: "The Muscovite Rite preserves the apostolic faith, sacramental life, monasticism, icon-veneration, and traditions of the Orthodox Catholic Faith. In the generations after [Glossary( 'the Cataclysm', 'CATACLYSM_GLOSS')], however, the ancient Church of the Rus' emerged from isolation as an independent patriarchal communion centered on Moscow. Rejecting the authority of the exiled Patriarch of Constantinople as that of an uncanonical pretender, the Russian Church came to regard the Patriarch of Moscow as the first hierarch of the Orthodox Church and the rightful first among equals of the Orthodox Faith." - + orthodox_slavic_rite_desc: "The Muscovite Rite is the principal rite of the Church of the Rus', first brought to these lands by the saints of old. Its faithful hold the hallowed traditions of Orthodoxy in the highest esteem, preserving the customs of their forefathers and proclaiming the Patriarch of Moscow as the rightful first among equals within the Orthodox world." + georgian_rite: "Georgian Rite" georgian_rite_adj: "Georgian" georgian_rite_adherent: "Georgian" diff --git a/localization/english/replace/religion/zz_NEOW_religion_orthodox_l_english.yml b/localization/english/replace/religion/zz_NEOW_religion_orthodox_l_english.yml index 34c64e4c5..0cdabe884 100644 --- a/localization/english/replace/religion/zz_NEOW_religion_orthodox_l_english.yml +++ b/localization/english/replace/religion/zz_NEOW_religion_orthodox_l_english.yml @@ -157,7 +157,7 @@ russian_orthodox_adj:0 "Pravoslavie" russian_orthodox_adherent:0 "Russian Orthodox" russian_orthodox_adherent_plural:0 "Russian Orthodox" - russian_orthodox_desc:0 "WRITE ME" + russian_orthodox_desc:0 "The Russian Orthodox Church preserves the apostolic faith, sacramental life, monasticism, icon-veneration, and traditions of the Orthodox Catholic Faith. In the generations after [Glossary( 'the Cataclysm', 'CATACLYSM_GLOSS')], however, the ancient Church of the Rus' emerged from isolation as an independent patriarchal communion centered on Moscow. Rejecting the authority of the exiled Patriarch of Constantinople as that of an uncanonical pretender, the Russian Church came to regard the Patriarch of Moscow as the first hierarch of the Orthodox Church and the rightful first among equals of the Orthodox Faith." russian_orthodox_high_god_name:0 "the Most Holy Trinity" russian_orthodox_high_god_name_possessive:0 "the Most Holy Trinity's" From d8cc7ae2ea8828791cd9288093246921a59f6266 Mon Sep 17 00:00:00 2001 From: Thakia Date: Fri, 2 Oct 2026 18:44:14 -0300 Subject: [PATCH 2/5] character_interactions updated files --- common/character_interactions/00_alliance.txt | 2495 +++--- .../00_artifact_interactions.txt | 920 +- .../00_ce1_interactions.txt | 86 +- .../00_character_interactions.txt | 1498 +--- .../00_courtier_and_guest_interactions.txt | 100 +- .../00_culture_interactions.txt | 20 +- .../00_diarch_interactions.txt | 973 +- .../00_dynast_interactions.txt | 837 +- .../00_faction_interactions.txt | 46 +- common/character_interactions/00_gift.txt | 400 +- .../00_grant_titles_interaction.txt | 663 +- .../00_house_head_interactions.txt | 165 +- .../00_invite_agent_to_scheme.txt | 38 +- .../00_lover_interactions.txt | 2 +- .../00_marriage_interactions.txt | 2973 +++++-- .../00_modifiy_vassal_contract.txt | 844 +- .../00_prison_interactions.txt | 3001 ++++--- .../00_puppet_interactions.txt | 1233 +++ .../00_religious_interactions.txt | 7788 +++++++++++++---- .../00_revoke_title_interaction.txt | 683 +- .../00_scheme_interactions.txt | 1646 +++- .../00_tradition_interactions.txt | 168 +- .../00_tribal_interactions.txt | 454 +- .../00_tributary_interactions.txt | 1511 ++-- .../00_vassal_interactions.txt | 993 ++- common/character_interactions/00_war.txt | 805 +- .../02_ep1_interactions.txt | 46 +- .../03_fp2_interactions.txt | 825 +- .../05_bp2_interactions.txt | 407 +- .../06_ep3_laamp_interactions.txt | 1333 ++- .../09_mpo_interactions.txt | 2429 ++--- .../10_tgp_test_interactions.txt | 10 +- .../NEOW_modified_interactions.txt | 213 +- .../tgp_tribute_mission_interactions.txt | 59 +- 34 files changed, 21815 insertions(+), 13849 deletions(-) create mode 100644 common/character_interactions/00_puppet_interactions.txt diff --git a/common/character_interactions/00_alliance.txt b/common/character_interactions/00_alliance.txt index 2dacf5d7b..62452ee3f 100644 --- a/common/character_interactions/00_alliance.txt +++ b/common/character_interactions/00_alliance.txt @@ -11,9 +11,12 @@ greeting = positive notification_text = CALL_ALLY_NOTIFICATION + is_available = { + is_at_war = yes + } + is_shown = { scope:actor = { - is_at_war = yes trigger_if = { # Avoid calling Adventurers without armies or landed rulers who have been devastated limit = { is_ai = yes @@ -28,13 +31,13 @@ } trigger_if = { limit = { - scope:recipient = { + scope:recipient = { is_tributary_of = scope:actor NOT = { is_allied_to = scope:actor } } } - piety >= 50 has_realm_law_flag = can_call_tributaries_for_piety + piety >= 50 } } scope:recipient = { @@ -138,7 +141,7 @@ scope:recipient = { is_ruler = yes - + # Only rulers of a high enough rank may call a hegemon into wars custom_tooltip = { text = too_low_rank_to_call_hegemon @@ -157,11 +160,11 @@ is_war_leader = scope:actor } } - + # Cannot call the same character multiple times custom_description = { text = cannot_call_same_character_multiple_times - subject = scope:recipient + object = scope:recipient any_character_war = { ALL_FALSE = { was_called = scope:recipient @@ -169,7 +172,7 @@ } } } - + # Cannot call a character of the "wrong" religion to a Great Holy War trigger_if = { limit = { @@ -220,7 +223,7 @@ } } } - + # You cannot call a suzerain against their own tributary trigger_if = { limit = { @@ -241,7 +244,7 @@ } } trigger_else = {} - + # You cannot call a tributary against their suzerain trigger_if = { limit = { @@ -370,12 +373,12 @@ scope:recipient = { #Why should Mandalas care about bickering tributaries in an offensive war if = { - limit = { + limit = { NOT = { government_has_flag = government_is_mandala } } - add_prestige_experience = major_prestige_loss + add_prestige_experience = major_prestige_loss } - } + } } else = { scope:actor = { @@ -597,7 +600,7 @@ } desc = WONT_FIGHT_SPOUSE_REASON } - + modifier = { # Refuse call against Suzerain if Obedient add = -1000 trigger_if = { @@ -670,65 +673,20 @@ } scope:recipient = { # The recipient doesn't have a royal court, but their liege does - top_liege != this + liege != this has_royal_court = no - liege = { - has_royal_court = yes - has_same_court_language = scope:actor - } - } - scope:recipient = { # The recipient doesn't have a royal court, but their liege's liege does, while their liege doesn't have a royal court - top_liege != this - has_royal_court = no - exists = liege.liege - liege = { - top_liege != this - has_royal_court = no - } - liege.liege = { - has_royal_court = yes - has_same_court_language = scope:actor - } - } - scope:recipient = { # The recipient doesn't have a royal court, but their liege's liege's liege does, while their liege doesn't have a royal court - top_liege != this - has_royal_court = no - exists = liege.liege - exists = liege.liege.liege - liege = { - top_liege != this - has_royal_court = no - } - liege.liege = { - top_liege != this - has_royal_court = no - } - liege.liege.liege = { - has_royal_court = yes - has_same_court_language = scope:actor - } - } - scope:recipient = { # The recipient doesn't have a royal court, but their liege's liege's liege's liege does, while their liege doesn't have a royal court - top_liege != this - has_royal_court = no - exists = liege.liege - exists = liege.liege.liege - exists = liege.liege.liege.liege - liege = { - top_liege != this - has_royal_court = no - } - liege.liege = { - top_liege != this - has_royal_court = no - } - liege.liege.liege = { - top_liege != this - has_royal_court = no - } - liege.liege.liege.liege = { + any_liege_or_above = { has_royal_court = yes has_same_court_language = scope:actor + save_temporary_scope_as = liege_temp + NOT = { + prev = { + any_liege_or_above = { + has_royal_court = yes + is_vassal_or_below_of = scope:liege_temp + } + } + } } } } @@ -756,65 +714,20 @@ } scope:recipient = { # The recipient doesn't have a royal court, but their liege does - top_liege != this + liege != this has_royal_court = no - liege = { - has_royal_court = yes - has_same_court_language = scope:actor - } - } - scope:recipient = { # The recipient doesn't have a royal court, but their liege's liege does, while their liege doesn't have a royal court - top_liege != this - has_royal_court = no - exists = liege.liege - liege = { - top_liege != this - has_royal_court = no - } - liege.liege = { - has_royal_court = yes - has_same_court_language = scope:actor - } - } - scope:recipient = { # The recipient doesn't have a royal court, but their liege's liege's liege does, while their liege doesn't have a royal court - top_liege != this - has_royal_court = no - exists = liege.liege - exists = liege.liege.liege - liege = { - top_liege != this - has_royal_court = no - } - liege.liege = { - top_liege != this - has_royal_court = no - } - liege.liege.liege = { - has_royal_court = yes - has_same_court_language = scope:actor - } - } - scope:recipient = { # The recipient doesn't have a royal court, but their liege's liege's liege's liege does, while their liege doesn't have a royal court - top_liege != this - has_royal_court = no - exists = liege.liege - exists = liege.liege.liege - exists = liege.liege.liege.liege - liege = { - top_liege != this - has_royal_court = no - } - liege.liege = { - top_liege != this - has_royal_court = no - } - liege.liege.liege = { - top_liege != this - has_royal_court = no - } - liege.liege.liege.liege = { + any_liege_or_above = { has_royal_court = yes has_same_court_language = scope:actor + save_temporary_scope_as = liege_temp + NOT = { + prev = { + any_liege_or_above = { + has_royal_court = yes + is_vassal_or_below_of = scope:liege_temp + } + } + } } } } @@ -1018,6 +931,7 @@ } fp3_struggle_resist_allied_wars_modifier = yes + } # Score above 0 means the AI will call this ally. Note that DESIRED_WAR_SIDE_STRENGTH still applies and can prevent calling the ally @@ -1117,18 +1031,20 @@ negotiate_alliance_interaction = { greeting = positive notification_text = NEGOTIATE_ALLIANCE_NOTIFICATION - is_shown = { - scope:recipient = { - this != scope:actor - NOT = { is_allied_to = scope:actor } - is_ruler = yes + is_available = { + trigger_if = { + limit = { is_ai = yes } + is_at_war = no } - scope:actor = { - is_ruler = yes + } + + is_shown = { + scope:puppet_or_actor ?= { OR = { - is_ai = no highest_held_title_tier >= 2 + scope:actor = { is_ai = no } } + is_ruler = yes #childhood friendship with hostage event, where they swear to be friends forever OR = { is_any_family_relation_or_spouse_trigger = { CHARACTER = scope:recipient } @@ -1139,7 +1055,7 @@ negotiate_alliance_interaction = { target = scope:recipient } house ?= { - house_head = scope:actor + house_head ?= scope:puppet_or_actor any_house_relation = { any_relation_house = { exists = house_head @@ -1150,80 +1066,69 @@ negotiate_alliance_interaction = { } } } + scope:recipient = { + this != scope:puppet_or_actor + NOT = { is_allied_to = scope:puppet_or_actor } + is_ruler = yes + } } is_valid_showing_failures_only = { scope:recipient = { is_playable_character = yes is_imprisoned = no + highest_held_title_tier < tier_hegemony } - scope:actor = { + scope:puppet_or_actor ?= { is_playable_character = yes is_imprisoned = no NOT = { is_at_war_with = scope:recipient } - } - custom_description = { - text = "has_already_rejected_renegotiation" - subject = scope:recipient - NOT = { - scope:actor = { - has_opinion_modifier = { - modifier = refused_alliance_opinion - target = scope:recipient - } - } - } - } - - scope:actor = { highest_held_title_tier < tier_hegemony } - scope:recipient = { highest_held_title_tier < tier_hegemony } - OR = { - #Ruler has the defensive negotiations perk - scope:actor = { has_perk = defensive_negotiations_perk } - #Ruler is married to other ruler. - scope:actor = { is_spouse_of = scope:recipient } - #Ruler is relative of other ruler - scope:actor = { is_parent_of = scope:recipient } - scope:actor = { is_grandparent_of = scope:recipient } - scope:actor = { is_great_grandparent_of = scope:recipient } - scope:actor = { is_child_of = scope:recipient } - scope:actor = { is_grandchild_of = scope:recipient } - scope:actor = { is_great_grandchild_of = scope:recipient } - scope:actor = { is_uncle_or_aunt_of = scope:recipient } - scope:actor = { is_nibling_of = scope:recipient } - scope:actor = { is_sibling_of = scope:recipient } - #Parents/spouse were blood brothers - scope:actor = { + highest_held_title_tier < tier_hegemony + OR = { + #Ruler has the defensive negotiations perk + has_perk = defensive_negotiations_perk + #Ruler is married to other ruler. + is_spouse_of = scope:recipient + #Ruler is relative of other ruler + is_parent_of = scope:recipient + is_grandparent_of = scope:recipient + is_great_grandparent_of = scope:recipient + is_child_of = scope:recipient + is_grandchild_of = scope:recipient + is_great_grandchild_of = scope:recipient + is_uncle_or_aunt_of = scope:recipient + is_nibling_of = scope:recipient + is_sibling_of = scope:recipient + #Parents/spouse were blood brothers has_opinion_modifier = { modifier = blood_brother_close_family_opinion target = scope:recipient } - } - custom_description = { - text = rulers_family_is_married_to_other_ruler_trigger - subject = scope:recipient - object = scope:actor - #Ruler's child/parent/sibling/grandchild/grandparent/uncle/aunt/niece/nephew is married to other ruler. - scope:recipient = { - any_spouse = { - OR = { - is_close_family_of = scope:actor - is_nibling_of = scope:actor - is_uncle_or_aunt_of = scope:actor + + custom_description = { + text = rulers_family_is_married_to_other_ruler_trigger + subject = scope:recipient + object = scope:puppet_or_actor + #Ruler's child/parent/sibling/grandchild/grandparent/uncle/aunt/niece/nephew is married to other ruler. + scope:recipient = { + any_spouse = { + OR = { + is_close_family_of = scope:puppet_or_actor + is_nibling_of = scope:puppet_or_actor + is_uncle_or_aunt_of = scope:puppet_or_actor + } } } } - } - custom_description = { - text = rulers_family_is_married_to_other_ruler_trigger - subject = scope:actor - object = scope:recipient - #Other ruler's child/parent/sibling/grandchild/grandparent/uncle/aunt/niece/nephew is married to first ruler. - scope:actor = { + custom_description = { + text = rulers_family_is_married_to_other_ruler_trigger + subject = scope:puppet_or_actor + object = scope:recipient + #Other ruler's child/parent/sibling/grandchild/grandparent/uncle/aunt/niece/nephew is married to first ruler. any_spouse = { OR = { is_close_family_of = scope:recipient @@ -1232,19 +1137,17 @@ negotiate_alliance_interaction = { } } } - } - custom_description = { - text = rulers_child_parent_sibling_is_married_to_other_rulers_trigger - subject = scope:recipient - object = scope:actor - # Ruler's child/parent/sibling is married to other ruler's child/parent/sibling. - scope:actor = { + custom_description = { + text = rulers_child_parent_sibling_is_married_to_other_rulers_trigger + subject = scope:recipient + object = scope:puppet_or_actor + # Ruler's child/parent/sibling is married to other ruler's child/parent/sibling. any_close_family_member = { OR = { - is_parent_of = scope:actor - is_child_of = scope:actor - is_sibling_of = scope:actor + is_parent_of = scope:puppet_or_actor + is_child_of = scope:puppet_or_actor + is_sibling_of = scope:puppet_or_actor } any_spouse = { OR = { @@ -1255,28 +1158,38 @@ negotiate_alliance_interaction = { } } } - } - custom_description = { - text = hostage_oath_of_friendship_trigger - subject = scope:recipient - object = scope:actor - #childhood friendship with hostage event, where they swear to be friends forever - scope:actor = { + custom_description = { + text = hostage_oath_of_friendship_trigger + subject = scope:recipient + object = scope:puppet_or_actor + #childhood friendship with hostage event, where they swear to be friends forever hostage_oath_of_friendship_trigger = yes } - } - - custom_tooltip = { - text = house_relation_alliance_trigger - scope:actor.house ?= { - house_head ?= scope:actor - any_house_relation = { - any_relation_house = { - exists = house_head - scope:recipient = house_head + + custom_tooltip = { + text = house_relation_alliance_trigger + house ?= { + house_head ?= scope:puppet_or_actor + any_house_relation = { + any_relation_house = { + exists = house_head + scope:recipient = house_head + } + has_house_relation_parameter = unlocks_house_head_negotiate_alliance } - has_house_relation_parameter = unlocks_house_head_negotiate_alliance + } + } + } + } + custom_description = { + text = "has_already_rejected_renegotiation" + subject = scope:recipient + NOT = { + scope:puppet_or_actor = { + has_opinion_modifier = { + modifier = refused_alliance_opinion + target = scope:recipient } } } @@ -1292,7 +1205,7 @@ negotiate_alliance_interaction = { #Use hook send_option = { is_valid = { - scope:actor = { + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } @@ -1300,23 +1213,23 @@ negotiate_alliance_interaction = { localization = GENERIC_SPEND_A_HOOK } should_use_extra_icon = { - scope:actor = { has_usable_hook = scope:recipient } + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } extra_icon = "gfx/interface/icons/character_interactions/hook_icon.dds" # Admin Gov can spend Influence to increase AI acceptance towards other same-realm admin characters send_option = { is_shown = { - scope:actor = { - government_allows = administrative + scope:puppet_or_actor = { + government_has_flag = government_has_influence } scope:recipient = { - top_liege = scope:actor.top_liege - government_allows = administrative + top_liege = scope:puppet_or_actor.top_liege + government_has_flag = government_has_influence } } is_valid = { - scope:actor = { + scope:puppet_or_actor = { influence >= major_influence_value } custom_tooltip = { @@ -1330,11 +1243,30 @@ negotiate_alliance_interaction = { send_options_exclusive = no + is_highlighted = { + scope:recipient = { + this != scope:puppet_or_actor + NOT = { is_allied_to = scope:puppet_or_actor } + is_ruler = yes + } + scope:puppet_or_actor = { + is_ruler = yes + OR = { + scope:actor = { is_ai = no } + highest_held_title_tier >= 2 + } + has_opinion_modifier = { + modifier = blood_brother_close_family_opinion + target = scope:recipient + } + } + } + on_accept = { - scope:actor = { + scope:puppet_or_actor = { trigger_event = char_interaction.0235 - stress_impact = { + stress_and_fulfillment_impact = { shy = minor_stress_impact_gain } @@ -1362,7 +1294,7 @@ negotiate_alliance_interaction = { #Prioritize marriage between rulers and/or direct blood relation between rulers first. if = { limit = { - scope:actor = { + scope:puppet_or_actor = { OR = { is_spouse_of = scope:recipient is_child_of = scope:recipient @@ -1377,10 +1309,10 @@ negotiate_alliance_interaction = { } } } - scope:actor = { + scope:puppet_or_actor = { create_alliance = { target = scope:recipient - allied_through_owner = scope:actor + allied_through_owner = scope:puppet_or_actor allied_through_target = scope:recipient } } @@ -1391,9 +1323,9 @@ negotiate_alliance_interaction = { scope:recipient = { any_spouse = { OR = { - is_close_family_of = scope:actor - is_nibling_of = scope:actor - is_uncle_or_aunt_of = scope:actor + is_close_family_of = scope:puppet_or_actor + is_nibling_of = scope:puppet_or_actor + is_uncle_or_aunt_of = scope:puppet_or_actor } } } @@ -1402,15 +1334,15 @@ negotiate_alliance_interaction = { random_spouse = { limit = { OR = { - is_close_family_of = scope:actor - is_nibling_of = scope:actor - is_uncle_or_aunt_of = scope:actor + is_close_family_of = scope:puppet_or_actor + is_nibling_of = scope:puppet_or_actor + is_uncle_or_aunt_of = scope:puppet_or_actor } } save_scope_as = recipient_spouse } } - scope:actor = { + scope:puppet_or_actor = { create_alliance = { target = scope:recipient allied_through_owner = scope:recipient_spouse @@ -1420,7 +1352,7 @@ negotiate_alliance_interaction = { } else_if = { limit = { - scope:actor = { + scope:puppet_or_actor = { any_spouse = { OR = { is_close_family_of = scope:recipient @@ -1430,7 +1362,7 @@ negotiate_alliance_interaction = { } } } - scope:actor = { + scope:puppet_or_actor = { random_spouse = { limit = { OR = { @@ -1442,10 +1374,10 @@ negotiate_alliance_interaction = { save_scope_as = actor_spouse } } - scope:actor = { + scope:puppet_or_actor = { create_alliance = { target = scope:recipient - allied_through_owner = scope:actor + allied_through_owner = scope:puppet_or_actor allied_through_target = scope:actor_spouse } } @@ -1453,12 +1385,12 @@ negotiate_alliance_interaction = { #...And finally marriage between close relatives and close relatives. else_if = { limit = { - scope:actor = { + scope:puppet_or_actor = { any_close_family_member = { OR = { - is_child_of = scope:actor - is_parent_of = scope:actor - is_sibling_of = scope:actor + is_child_of = scope:puppet_or_actor + is_parent_of = scope:puppet_or_actor + is_sibling_of = scope:puppet_or_actor } any_spouse = { OR = { @@ -1470,13 +1402,13 @@ negotiate_alliance_interaction = { } } } - scope:actor = { + scope:puppet_or_actor = { random_close_family_member = { limit = { OR = { - is_child_of = scope:actor - is_parent_of = scope:actor - is_sibling_of = scope:actor + is_child_of = scope:puppet_or_actor + is_parent_of = scope:puppet_or_actor + is_sibling_of = scope:puppet_or_actor } any_spouse = { OR = { @@ -1499,7 +1431,7 @@ negotiate_alliance_interaction = { } } } - scope:actor = { + scope:puppet_or_actor = { create_alliance = { target = scope:recipient allied_through_owner = scope:actor_spouse @@ -1509,32 +1441,32 @@ negotiate_alliance_interaction = { } else_if = { limit = { - scope:actor = { has_perk = defensive_negotiations_perk } + scope:puppet_or_actor = { has_perk = defensive_negotiations_perk } } - scope:actor = { + scope:puppet_or_actor = { create_alliance = { target = scope:recipient - allied_through_owner = scope:actor + allied_through_owner = scope:puppet_or_actor allied_through_target = scope:recipient } } scope:recipient = { # This opinion modifier controls the interaction, and is removed when breaking the alliance in any way (though on_actions) add_opinion = { modifier = perk_negotiated_alliance_opinion - target = scope:actor + target = scope:puppet_or_actor } } } else_if = { limit = { - scope:actor = { + scope:puppet_or_actor = { hostage_oath_of_friendship_trigger = yes } } - scope:actor = { + scope:puppet_or_actor = { create_alliance = { target = scope:recipient - allied_through_owner = scope:actor + allied_through_owner = scope:puppet_or_actor allied_through_target = scope:recipient } } @@ -1542,7 +1474,7 @@ negotiate_alliance_interaction = { } add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = minor_unity_gain DESC = clan_unity_alliance.desc @@ -1551,10 +1483,10 @@ negotiate_alliance_interaction = { } on_decline = { - scope:actor = { + scope:puppet_or_actor = { trigger_event = char_interaction.0236 } - scope:actor = { + scope:puppet_or_actor = { add_opinion = { modifier = refused_alliance_opinion target = scope:recipient @@ -1562,7 +1494,7 @@ negotiate_alliance_interaction = { } add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = minor_unity_loss DESC = clan_unity_alliance_refusal.desc @@ -1573,7 +1505,7 @@ negotiate_alliance_interaction = { auto_accept = { custom_description = { text = "spending_hook" - subject = scope:actor + subject = scope:puppet_or_actor object = scope:recipient scope:hook = yes } @@ -1581,6 +1513,8 @@ negotiate_alliance_interaction = { ai_accept = { base = 0 + negotiate_alliance_interaction_ai_acceptance = yes + # Tier Difference (+/-) # Inheritance (+) # Opinion (+/-) @@ -1597,7 +1531,7 @@ negotiate_alliance_interaction = { modifier = { add = 20 scope:recipient = { - is_close_family_of = scope:actor + is_close_family_of = scope:puppet_or_actor } desc = CLOSE_FAMILY_REASON } @@ -1605,8 +1539,8 @@ negotiate_alliance_interaction = { modifier = { add = 10 scope:recipient = { - NOT = { is_close_family_of = scope:actor } - is_extended_family_of = scope:actor + NOT = { is_close_family_of = scope:puppet_or_actor } + is_extended_family_of = scope:puppet_or_actor } desc = EXTENDED_FAMILY_REASON } @@ -1614,115 +1548,18 @@ negotiate_alliance_interaction = { modifier = { add = -20 scope:recipient = { - NOT = { is_close_or_extended_family_of = scope:actor } + NOT = { is_close_or_extended_family_of = scope:puppet_or_actor } any_spouse = { - NOT = { is_close_family_of = scope:actor } - is_extended_family_of = scope:actor + NOT = { is_close_family_of = scope:puppet_or_actor } + is_extended_family_of = scope:puppet_or_actor } } desc = DISTANT_FAMILY_CONNECTION_REASON } - # Tier Differences - modifier = { - scope:actor = { - tier_difference = { - target = scope:recipient - value >= 1 - } - } - add = { - value = 30 - if = { - limit = { - tier_difference = { - target = scope:recipient - value = 2 - } - } - add = 30 - } - if = { - limit = { - tier_difference = { - target = scope:recipient - value = 3 - } - } - add = 60 - } - if = { - limit = { - tier_difference = { - target = scope:recipient - value = 4 - } - } - add = 90 - } - if = { - limit = { - tier_difference = { - target = scope:recipient - value = 5 - } - } - add = 120 - } - } - desc = RANK_DIFFERENCE_REASON - } - modifier = { - scope:actor = { - tier_difference = { - target = scope:recipient - value <= -1 - } - } - add = { - value = -30 - if = { - limit = { - tier_difference = { - target = scope:recipient - value = -2 - } - } - add = -30 - } - if = { - limit = { - tier_difference = { - target = scope:recipient - value = -3 - } - } - add = -60 - } - if = { - limit = { - tier_difference = { - target = scope:recipient - value = -4 - } - } - add = -90 - } - if = { - limit = { - tier_difference = { - target = scope:recipient - value = -5 - } - } - add = -120 - } - } - desc = RANK_DIFFERENCE_REASON - } modifier = { scope:recipient = { - has_relation_lover = scope:actor + has_relation_lover = scope:puppet_or_actor } add = { value = 25 @@ -1731,7 +1568,7 @@ negotiate_alliance_interaction = { } modifier = { scope:recipient = { - has_relation_friend = scope:actor + has_relation_friend = scope:puppet_or_actor } add = { value = 25 @@ -1740,9 +1577,9 @@ negotiate_alliance_interaction = { } modifier = { scope:recipient = { - is_heir_of = scope:actor + is_heir_of = scope:puppet_or_actor } - scope:actor = { + scope:puppet_or_actor = { tier_difference = { target = scope:recipient value > 0 @@ -1752,466 +1589,22 @@ negotiate_alliance_interaction = { value = 10 if = { limit = { - scope:actor = { player_heir = scope:recipient } + scope:puppet_or_actor = { player_heir = scope:recipient } } add = 10 } } desc = IS_HEIR_REASON } - opinion_modifier = { # More likely to accept if Recipient likes the Actor - who = scope:recipient - opinion_target = scope:actor - multiplier = 0.25 - min = 0 - desc = AI_OPINION_REASON - } - opinion_modifier = { # Less likely to accept if Recipient dislikes the Actor - who = scope:recipient - opinion_target = scope:actor - multiplier = 1 - max = 0 - desc = AI_OPINION_REASON - } - modifier = { add = 20 - scope:recipient = { - has_trait = loyal - } - desc = INTERACTION_LOYAL - } - - modifier = { - add = 20 - scope:recipient = { - has_trait = trusting - } - desc = INTERACTION_TRUSTING - } - - modifier = { - add = 5 - scope:recipient = { - has_trait = craven - } - desc = INTERACTION_CRAVEN - } - - modifier = { - add = -20 - scope:recipient = { - has_trait = paranoid - } - desc = INTERACTION_PARANOID - } - - modifier = { - add = -20 - scope:recipient = { - has_trait = arrogant - } - desc = INTERACTION_ARROGANT - } - - modifier = { - add = -20 - scope:recipient = { - has_trait = ambitious - } - desc = INTERACTION_AMBITIOUS - } - - modifier = { - add = -40 - scope:recipient = { - has_trait = disloyal - } - desc = INTERACTION_DISLOYAL - } - - modifier = { - add = -10 - scope:recipient = { - has_trait = fickle - } - desc = INTERACTION_FICKLE - } - - # Rivalry - modifier = { # Say no to rivals - add = -100 - scope:recipient = { - has_relation_rival = scope:actor - NOT = { has_relation_nemesis = scope:actor } - } - desc = "ACTOR_RIVAL_TO_ME_REASON" - } - modifier = { # Say no to nemesis - add = -300 - scope:recipient = { - has_relation_nemesis = scope:actor - } - desc = "ACTOR_NEMESIS_TO_ME_REASON" - } - - # Dynasty Prestige Levels - modifier = { - add = -5 - desc = AI_DYNASTY_PRESTIGE_REASON - scope:actor = { has_dynasty = yes } - scope:actor.dynasty != scope:recipient.dynasty - scope:actor.dynasty = { dynasty_prestige_level = 0 } - } - modifier = { - desc = AI_DYNASTY_PRESTIGE_REASON - scope:actor = { has_dynasty = yes } - scope:actor.dynasty != scope:recipient.dynasty - scope:actor.dynasty = { dynasty_prestige_level >= 2 } - add = { - value = 10 - if = { - limit = { - scope:actor.dynasty = { dynasty_prestige_level >= 3 } - } - add = 5 - } - if = { - limit = { - scope:actor.dynasty = { dynasty_prestige_level >= 4 } - } - add = 5 - } - if = { - limit = { - scope:actor.dynasty = { dynasty_prestige_level >= 5 } - } - add = 5 - } - if = { - limit = { - scope:actor.dynasty = { dynasty_prestige_level >= 6 } - } - add = 5 - } - if = { - limit = { - scope:actor.dynasty = { dynasty_prestige_level >= 7 } - } - add = 5 - } - if = { - limit = { - scope:actor.dynasty = { dynasty_prestige_level >= 8 } - } - add = 5 - } - if = { - limit = { - scope:actor.dynasty = { dynasty_prestige_level >= 9 } - } - add = 5 - } - if = { - limit = { - scope:actor.dynasty = { dynasty_prestige_level >= 10 } - } - add = 5 - } - } - } - modifier = { #Faith compatibility - scope:recipient.faith = { - faith_hostility_level = { - target = scope:actor.faith - value > faith_fully_accepted_level - } - } - NOT = { - scope:recipient.ai_zeal <= -50 - } - add = { - value = -10 - if = { - limit = { - # Exempt certain struggle phases. - NOT = { is_struggle_parameter_active_interfaith_marriages_available_between_involved_characters_trigger = yes } - } - if = { - limit = { - scope:recipient.faith = { - faith_hostility_level = { - target = scope:actor.faith - value >= faith_astray_level - } - } - } - subtract = 20 - } - if = { - limit = { - scope:recipient.faith = { - faith_hostility_level = { - target = scope:actor.faith - value >= faith_hostile_level - } - } - } - subtract = 20 - } - if = { - limit = { - scope:recipient.faith = { - faith_hostility_level = { - target = scope:actor.faith - value >= faith_evil_level - } - } - } - subtract = 50 - } - if = { - limit = { - scope:recipient.ai_zeal <= -25 - } - divide = 2 - } - else_if = { - limit = { - scope:recipient.ai_zeal >= 50 - } - multiply = 2 - } - if = { - limit = { - scope:recipient.faith = { has_doctrine = doctrine_pluralism_pluralistic } - } - divide = 2 - } - } - } - desc = MARRY_DIFFERENT_FAITH_REASON - } - - modifier = { # A Recipient is more likely to agree to an alliance requested by his liege. - add = 20 - scope:recipient = { - target_is_liege_or_above = scope:actor - } - desc = LIEGE_REASON - } - - modifier = { - add = { - value = 1 - subtract = { - value = scope:recipient.max_military_strength # For foreign diplomacy, consider recipients max - divide = { value = scope:actor.current_military_strength min = 1 } - } - multiply = 20 - min = -1000 - max = 100 - } - desc = AI_MILITARY_BALANCE_REASON - } - # Recipient is a Claimant to Actor's titles. - modifier = { - scope:recipient = { - any_claim = { - holder = scope:actor - } - NOR = { - is_heir_of = scope:actor - ai_greed <= -25 - } - } - add = { - value = -50 - if = { - limit = { - scope:recipient.ai_greed >= 25 - } - add = ai_greed - } - if = { - limit = { - scope:recipient.house != scope:actor.house - } - multiply = 2 - } - } - desc = IS_CLAIMANT_TO_ACTORS_TITLES - } - #Actor has claims on recipient's titles. - modifier = { - scope:actor = { - any_claim = { - holder = scope:recipient - } - } - add = 25 - desc = IS_CLAIMANT_TO_RECIPIENT_TITLES - } - modifier = { - scope:recipient = { - NOT = { - any_claim = { - holder = scope:actor - } - } - } - scope:recipient.house = scope:actor.house - add = 15 - desc = IS_SAME_HOUSE_REASON - } - modifier = { - scope:recipient = { + desc = FAMILY_BLOOD_BROTHERHOOD_REASON + scope:puppet_or_actor = { has_opinion_modifier = { - target = scope:actor - modifier = declared_war + modifier = blood_brother_close_family_opinion + target = scope:recipient } } - add = -100 - desc = DECLARED_WAR_REASON - } - - # Don't form new alliances with people already at war. - modifier = { - scope:actor = { - is_at_war = yes - - # Since vassals and lieges can't call us into wars, this doesn't matter for us if we have that relationship. - NOR = { - target_is_liege_or_above = scope:recipient - target_is_vassal_or_below = scope:recipient - } - } - add = -50 - desc = IS_AT_WAR_REASON - } - - #Bonus from Tradition Astute Diplomats - modifier = { - scope:actor.culture = { has_cultural_parameter = facilitate_alliance_acceptance } - add = 50 #should be in a file 00_traditions_values - desc = TRADITION_ASTUTE_DIPLOMATS_ACCEPTANCE_MODIFIER - } - - # The AI doesn't want to form alliances with AI vassals within its capital duchy, so it can revoke them - modifier = { - scope:actor = { - is_ai = yes - is_vassal_or_below_of = scope:recipient - any_held_title = { - title_tier = county - de_jure_liege = scope:actor.primary_title.title_capital_county.de_jure_liege - } - } - scope:recipient = { - is_ai = yes - } - add = -5000 - } - - # Feud - modifier = { - add = -25 - scope:recipient = { - house_has_feud_relation_with_trigger = { TARGET = scope:actor } - } - desc = MARRY_FAMILY_FEUD_REASON - } - - # Existing Alliances - modifier = { - add = { - scope:actor = { - every_ally = { - add = -15 - } - } - } - scope:actor = { - any_ally = { - count >= 2 - } - } - NOT = { - scope:recipient = { - government_has_flag = government_is_clan - is_vassal_or_below_of = scope:actor - } - } - desc = EXISTING_ALLIANCES_REASON - } - - # Existing Alliances - modifier = { - add = { - scope:recipient = { - every_ally = { - add = -15 - } - } - } - scope:recipient = { - any_ally = { - count >= 2 - } - } - NOT = { - scope:recipient = { - government_has_flag = government_is_clan - is_vassal_or_below_of = scope:actor - } - } - desc = THEIR_EXISTING_ALLIANCES_REASON - } - - modifier = { - add = intimidated_reason_value - scope:recipient = { - target_is_liege_or_above = scope:actor - has_dread_level_towards = { - target = scope:actor - level = 1 - } - } - desc = INTIMIDATED_REASON - } - modifier = { - add = cowed_reason_value - scope:recipient = { - target_is_liege_or_above = scope:actor - has_dread_level_towards = { - target = scope:actor - level = 2 - } - } - desc = COWED_REASON - } - - modifier = { - add = intimidated_external_reason_value - scope:recipient = { - NOT = { target_is_liege_or_above = scope:actor } - has_dread_level_towards = { - target = scope:actor - level = 1 - } - } - desc = INTIMIDATED_REASON - } - modifier = { - add = cowed_external_reason_value - scope:recipient = { - NOT = { target_is_liege_or_above = scope:actor } - has_dread_level_towards = { - target = scope:actor - level = 2 - } - } - desc = COWED_REASON } # Unity modifiers @@ -2224,7 +1617,7 @@ negotiate_alliance_interaction = { # LOW LEGITIMACY modifier = { desc = "LOW_LEGITIMACY_REASON" - scope:actor = { + scope:puppet_or_actor = { OR = { has_legitimacy_flag = reduced_alliance_acceptance has_legitimacy_flag = very_reduced_alliance_acceptance @@ -2234,15 +1627,15 @@ negotiate_alliance_interaction = { add = { value = 0 if = { - limit = { scope:actor = { has_legitimacy_flag = reduced_alliance_acceptance } } + limit = { scope:puppet_or_actor = { has_legitimacy_flag = reduced_alliance_acceptance } } add = -25 } if = { - limit = { scope:actor = { has_legitimacy_flag = very_reduced_alliance_acceptance } } + limit = { scope:puppet_or_actor = { has_legitimacy_flag = very_reduced_alliance_acceptance } } add = -50 } if = { - limit = { scope:actor = { has_legitimacy_flag = massively_reduced_alliance_acceptance } } + limit = { scope:puppet_or_actor = { has_legitimacy_flag = massively_reduced_alliance_acceptance } } add = -100 } } @@ -2251,7 +1644,7 @@ negotiate_alliance_interaction = { # HIGH LEGITIMACY modifier = { desc = "HIGH_LEGITIMACY_REASON" - scope:actor = { + scope:puppet_or_actor = { OR = { has_legitimacy_flag = increased_alliance_acceptance has_legitimacy_flag = very_increased_alliance_acceptance @@ -2261,45 +1654,39 @@ negotiate_alliance_interaction = { add = { value = 0 if = { - limit = { scope:actor = { has_legitimacy_flag = increased_alliance_acceptance } } + limit = { scope:puppet_or_actor = { has_legitimacy_flag = increased_alliance_acceptance } } add = 10 } if = { - limit = { scope:actor = { has_legitimacy_flag = very_increased_alliance_acceptance } } + limit = { scope:puppet_or_actor = { has_legitimacy_flag = very_increased_alliance_acceptance } } add = 25 } if = { - limit = { scope:actor = { has_legitimacy_flag = extra_increased_alliance_acceptance } } + limit = { scope:puppet_or_actor = { has_legitimacy_flag = extra_increased_alliance_acceptance } } add = 50 } } } - # INFLUENCE - modifier = { - desc = INFLUENCE_REASON - scope:influence = yes - add = { - value = 10 - multiply = scope:actor.influence_level - min = 5 - } - } - # TGP ALLIANCE WITH NF HOUSE HEAD modifier = { add = 750 - scope:actor = { + scope:puppet_or_actor = { is_house_head = yes scope:recipient.house ?= this.house any_held_title = { is_noble_family_title = yes } } desc = JAPANESE_HOUSE_HEAD_ALLIANCE_REASON } - } - ai_potential = { - is_at_war = no + modifier = { + add = 10 + desc = pam_praised_hunting_alliance_accept_reason + scope:recipient = { + exists = var:pam_praised_hunting_alliance_var + var:pam_praised_hunting_alliance_var = scope:puppet_or_actor + } + } } ai_targets = { @@ -2334,11 +1721,11 @@ negotiate_alliance_interaction = { } scope:recipient = { # Don't propose alliances to tiny insignificant rulers just because OR = { - current_military_strength >= scope:actor.eighty_percent_of_current_military_strength - primary_title.tier >= scope:actor.primary_title.tier + current_military_strength >= scope:puppet_or_actor.eighty_percent_of_current_military_strength + primary_title.tier >= scope:puppet_or_actor.primary_title.tier AND = { primary_title.tier >= tier_duchy - scope:actor.primary_title.tier < tier_empire + scope:puppet_or_actor.primary_title.tier < tier_empire } } } @@ -2346,11 +1733,11 @@ negotiate_alliance_interaction = { modifier = { # Clans always want alliances with Vassals add = 100 - scope:actor = { + scope:puppet_or_actor = { government_has_flag = government_is_clan } scope:recipient = { - is_vassal_of = scope:actor + is_vassal_of = scope:puppet_or_actor } } @@ -2366,11 +1753,11 @@ negotiate_alliance_interaction = { modifier = { # The AI shouldn't propose to their Vassals unless Clan factor = 0 - scope:actor = { + scope:puppet_or_actor = { NOT = { government_has_flag = government_is_clan } } scope:recipient = { - is_vassal_of = scope:actor + is_vassal_of = scope:puppet_or_actor } } } @@ -2389,23 +1776,22 @@ perk_alliance_interaction = { greeting = positive notification_text = PERK_NEGOTIATE_ALLIANCE_NOTIFICATION - is_shown = { - scope:recipient = { - NOR = { - this = scope:actor - is_allied_to = scope:actor - target_is_vassal_or_below = scope:actor # Can only sign with external rulers/peer vassals, though the alliance is preserved if they somehow become your vassals - target_is_liege_or_above = scope:actor - government_has_flag = government_is_true_herder + is_available = { + trigger_if = { + limit = { is_ai = yes } + is_at_war = no + any_ally = { + count < 2 } - is_ruler = yes - primary_title.tier > tier_barony } - scope:actor = { + } + + is_shown = { + scope:puppet_or_actor ?= { has_perk = defensive_negotiations_perk is_landless_adventurer = no NOR = { - government_has_flag = government_is_true_herder + government_has_flag = government_is_herder # This interaction is harder to push through than Negotiate Alliance, and does the same thing, so don't show both is_character_interaction_shown = { recipient = scope:recipient @@ -2413,26 +1799,37 @@ perk_alliance_interaction = { } } } + scope:recipient = { + NOR = { + this = scope:puppet_or_actor + is_allied_to = scope:puppet_or_actor + target_is_vassal_or_below = scope:puppet_or_actor # Can only sign with external rulers/peer vassals, though the alliance is preserved if they somehow become your vassals + target_is_liege_or_above = scope:puppet_or_actor + government_has_flag = government_is_herder + } + is_ruler = yes + primary_title.tier > tier_barony + } } is_valid_showing_failures_only = { - scope:actor = { + scope:puppet_or_actor ?= { is_landless_adventurer = no } scope:recipient = { - NOT = { target_is_vassal_or_below = scope:actor } # Can only sign with external rulers/peer vassals, though the alliance is preserved if they somehow become your vassals - NOT = { target_is_liege_or_above = scope:actor } + NOT = { target_is_vassal_or_below = scope:puppet_or_actor } # Can only sign with external rulers/peer vassals, though the alliance is preserved if they somehow become your vassals + NOT = { target_is_liege_or_above = scope:puppet_or_actor } } custom_description = { text = "already_has_an_alliance_deal" subject = scope:recipient - scope:actor = { + scope:puppet_or_actor = { NOT = { any_ally = { has_opinion_modifier = { modifier = perk_negotiated_alliance_opinion - target = scope:actor + target = scope:puppet_or_actor } } } @@ -2445,16 +1842,16 @@ perk_alliance_interaction = { is_imprisoned = no } - scope:actor = { + scope:puppet_or_actor = { is_playable_character = yes is_at_war = no is_imprisoned = no } - + custom_description = { text = "has_already_rejected_renegotiation" subject = scope:recipient - scope:actor = { + scope:puppet_or_actor = { NOT = { has_opinion_modifier = { modifier = refused_alliance_opinion @@ -2469,7 +1866,7 @@ perk_alliance_interaction = { custom_description = { # Exploit prevention text = "has_sent_interaction_already" subject = scope:recipient - scope:actor = { + scope:puppet_or_actor = { NOT = { has_pending_interaction_of_type = perk_alliance_interaction } @@ -2486,7 +1883,7 @@ perk_alliance_interaction = { #Use hook send_option = { is_valid = { - scope:actor = { + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } @@ -2494,23 +1891,23 @@ perk_alliance_interaction = { localization = GENERIC_SPEND_A_HOOK } should_use_extra_icon = { - scope:actor = { has_usable_hook = scope:recipient } + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } extra_icon = "gfx/interface/icons/character_interactions/hook_icon.dds" # Admin Gov can spend Influence to increase AI acceptance towards other same-realm admin characters send_option = { is_shown = { - scope:actor = { - government_allows = administrative + scope:puppet_or_actor = { + government_has_flag = government_has_influence } scope:recipient = { - top_liege = scope:actor.top_liege - government_allows = administrative + top_liege = scope:puppet_or_actor.top_liege + government_has_flag = government_has_influence } } is_valid = { - scope:actor = { + scope:puppet_or_actor = { influence >= major_influence_value } custom_tooltip = { @@ -2529,16 +1926,16 @@ perk_alliance_interaction = { name = perk_alliance_interaction value = yes } - scope:actor = { + scope:puppet_or_actor = { custom_tooltip = negotiate_alliance_effect_tooltip trigger_event = char_interaction.0235 create_alliance = { target = scope:recipient - allied_through_owner = scope:actor + allied_through_owner = scope:puppet_or_actor allied_through_target = scope:recipient } - stress_impact = { + stress_and_fulfillment_impact = { shy = minor_stress_impact_gain } @@ -2557,12 +1954,12 @@ perk_alliance_interaction = { scope:recipient = { # This opinion modifier controls the interaction, and is removed when breaking the alliance in any way (though on_actions) add_opinion = { modifier = perk_negotiated_alliance_opinion - target = scope:actor + target = scope:puppet_or_actor } } add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = medium_unity_gain DESC = clan_unity_alliance.desc @@ -2571,10 +1968,10 @@ perk_alliance_interaction = { } on_decline = { - scope:actor = { + scope:puppet_or_actor = { trigger_event = char_interaction.0236 } - scope:actor = { + scope:puppet_or_actor = { add_opinion = { modifier = refused_alliance_opinion target = scope:recipient @@ -2582,7 +1979,7 @@ perk_alliance_interaction = { } add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = minor_unity_loss DESC = clan_unity_alliance_refusal.desc @@ -2593,7 +1990,7 @@ perk_alliance_interaction = { auto_accept = { custom_description = { text = "spending_hook" - subject = scope:actor + subject = scope:puppet_or_actor object = scope:recipient scope:hook = yes } @@ -2602,586 +1999,12 @@ perk_alliance_interaction = { ai_accept = { # Similar to Negotiate Alliance, but without modifiers for Liege, being an heir, etc. base = -25 - # Tier Differences - modifier = { - scope:actor = { - tier_difference = { - target = scope:recipient - value >= 1 - } - } - add = { - value = 30 - if = { - limit = { - tier_difference = { - target = scope:recipient - value = 2 - } - } - add = 30 - } - if = { - limit = { - tier_difference = { - target = scope:recipient - value = 3 - } - } - add = 60 - } - if = { - limit = { - tier_difference = { - target = scope:recipient - value = 4 - } - } - add = 90 - } - if = { - limit = { - tier_difference = { - target = scope:recipient - value = 5 - } - } - add = 120 - } - } - desc = RANK_DIFFERENCE_REASON - } - modifier = { - scope:recipient = { - has_relation_lover = scope:actor - } - add = { - value = 25 - } - desc = WE_ARE_LOVERS - } - modifier = { - scope:recipient = { - has_relation_friend = scope:actor - } - add = { - value = 25 - } - desc = WE_ARE_FRIENDS - } - modifier = { - scope:actor = { - tier_difference = { - target = scope:recipient - value <= -1 - } - } - add = { - value = -30 - if = { - limit = { - tier_difference = { - target = scope:recipient - value = -2 - } - } - add = -30 - } - if = { - limit = { - tier_difference = { - target = scope:recipient - value = -3 - } - } - add = -60 - } - if = { - limit = { - tier_difference = { - target = scope:recipient - value = -4 - } - } - add = -90 - } - if = { - limit = { - tier_difference = { - target = scope:recipient - value = -5 - } - } - add = -120 - } - } - desc = RANK_DIFFERENCE_REASON - } - opinion_modifier = { # More likely to accept if Recipient likes the Actor - who = scope:recipient - opinion_target = scope:actor - multiplier = 0.25 - min = 0 - desc = AI_OPINION_REASON - } - opinion_modifier = { # Less likely to accept if Recipient dislikes the Actor - who = scope:recipient - opinion_target = scope:actor - multiplier = 1 - max = 0 - desc = AI_OPINION_REASON - } - - modifier = { - add = 20 - scope:recipient = { - has_trait = loyal - } - desc = INTERACTION_LOYAL - } - - modifier = { - add = 20 - scope:recipient = { - has_trait = trusting - } - desc = INTERACTION_TRUSTING - } - - modifier = { - add = 5 - scope:recipient = { - has_trait = craven - } - desc = INTERACTION_CRAVEN - } - - modifier = { - add = -20 - scope:recipient = { - has_trait = paranoid - } - desc = INTERACTION_PARANOID - } - - modifier = { - add = -20 - scope:recipient = { - has_trait = arrogant - } - desc = INTERACTION_ARROGANT - } - - modifier = { - add = -20 - scope:recipient = { - has_trait = ambitious - } - desc = INTERACTION_AMBITIOUS - } - - modifier = { - add = -40 - scope:recipient = { - has_trait = disloyal - } - desc = INTERACTION_DISLOYAL - } - - modifier = { - add = -10 - scope:recipient = { - has_trait = fickle - } - desc = INTERACTION_FICKLE - } - - # Rivalry - modifier = { # Say no to rivals - add = -100 - scope:recipient = { - has_relation_rival = scope:actor - NOT = { has_relation_nemesis = scope:actor } - } - desc = "ACTOR_RIVAL_TO_ME_REASON" - } - modifier = { # Say no to nemesis - add = -300 - scope:recipient = { - has_relation_nemesis = scope:actor - } - desc = "ACTOR_NEMESIS_TO_ME_REASON" - } - - # Dynasty Prestige Levels - modifier = { - add = -5 - desc = AI_DYNASTY_PRESTIGE_REASON - scope:actor = { has_dynasty = yes } - scope:actor.dynasty != scope:recipient.dynasty - scope:actor.dynasty = { dynasty_prestige_level = 0 } - } - modifier = { - desc = AI_DYNASTY_PRESTIGE_REASON - scope:actor = { has_dynasty = yes } - scope:actor.dynasty != scope:recipient.dynasty - scope:actor.dynasty = { dynasty_prestige_level >= 2 } - add = { - value = 10 - if = { - limit = { - scope:actor.dynasty = { dynasty_prestige_level >= 3 } - } - add = 5 - } - if = { - limit = { - scope:actor.dynasty = { dynasty_prestige_level >= 4 } - } - add = 5 - } - if = { - limit = { - scope:actor.dynasty = { dynasty_prestige_level >= 5 } - } - add = 5 - } - if = { - limit = { - scope:actor.dynasty = { dynasty_prestige_level >= 6 } - } - add = 5 - } - if = { - limit = { - scope:actor.dynasty = { dynasty_prestige_level >= 7 } - } - add = 5 - } - if = { - limit = { - scope:actor.dynasty = { dynasty_prestige_level >= 8 } - } - add = 5 - } - if = { - limit = { - scope:actor.dynasty = { dynasty_prestige_level >= 9 } - } - add = 5 - } - if = { - limit = { - scope:actor.dynasty = { dynasty_prestige_level >= 10 } - } - add = 5 - } - } - } - modifier = { #Faith compatibility - scope:recipient.faith = { - faith_hostility_level = { - target = scope:actor.faith - value > faith_fully_accepted_level - } - } - NOT = { - scope:recipient.ai_zeal <= -50 - } - add = { - value = -10 - if = { - limit = { - # Exempt certain struggle phases. - NOT = { is_struggle_parameter_active_interfaith_marriages_available_between_involved_characters_trigger = yes } - } - if = { - limit = { - scope:recipient.faith = { - faith_hostility_level = { - target = scope:actor.faith - value >= faith_astray_level - } - } - } - subtract = 20 - } - if = { - limit = { - scope:recipient.faith = { - faith_hostility_level = { - target = scope:actor.faith - value >= faith_hostile_level - } - } - } - subtract = 20 - } - if = { - limit = { - scope:recipient.faith = { - faith_hostility_level = { - target = scope:actor.faith - value >= faith_evil_level - } - } - } - subtract = 50 - } - if = { - limit = { - scope:recipient.ai_zeal <= -25 - } - divide = 2 - } - else_if = { - limit = { - scope:recipient.ai_zeal >= 50 - } - multiply = 2 - } - if = { - limit = { - scope:recipient.faith = { has_doctrine = doctrine_pluralism_pluralistic } - } - divide = 2 - } - } - } - desc = MARRY_DIFFERENT_FAITH_REASON - } - - modifier = { # A Recipient is more likely to agree to an alliance requested by his liege. - add = 20 - scope:recipient = { - target_is_liege_or_above = scope:actor - } - desc = LIEGE_REASON - } - - modifier = { - add = { - value = 1 - subtract = { - value = scope:recipient.max_military_strength # For foreign diplomacy, consider recipients max - divide = { value = scope:actor.current_military_strength min = 1 } - } - multiply = 20 - min = -1000 - max = 100 - } - desc = AI_MILITARY_BALANCE_REASON - } - # Recipient is a Claimant to Actor's titles. - modifier = { - scope:recipient = { - any_claim = { - holder = scope:actor - } - NOR = { - is_heir_of = scope:actor - ai_greed <= -25 - } - } - add = { - value = -50 - if = { - limit = { - scope:recipient.ai_greed >= 25 - } - add = ai_greed - } - if = { - limit = { - scope:recipient.house != scope:actor.house - } - multiply = 2 - } - } - desc = IS_CLAIMANT_TO_ACTORS_TITLES - } - #Actor has claims on recipient's titles. - modifier = { - scope:actor = { - any_claim = { - holder = scope:recipient - } - } - add = 25 - desc = IS_CLAIMANT_TO_RECIPIENT_TITLES - } - modifier = { - scope:recipient = { - NOT = { - any_claim = { - holder = scope:actor - } - } - } - scope:recipient.house = scope:actor.house - add = 15 - desc = IS_SAME_HOUSE_REASON - } - modifier = { - scope:recipient = { - has_opinion_modifier = { - target = scope:actor - modifier = declared_war - } - } - add = -100 - desc = DECLARED_WAR_REASON - } - - # Don't form new alliances with people already at war. - modifier = { - scope:actor = { - is_at_war = yes - - # Since vassals and lieges can't call us into wars, this doesn't matter for us if we have that relationship. - NOR = { - target_is_liege_or_above = scope:recipient - target_is_vassal_or_below = scope:recipient - } - } - add = -50 - desc = IS_AT_WAR_REASON - } - - #Bonus from Tradition Astute Diplomats - modifier = { - scope:actor.culture = { has_cultural_parameter = facilitate_alliance_acceptance } - add = 50 #should be in a file 00_traditions_values - desc = TRADITION_ASTUTE_DIPLOMATS_ACCEPTANCE_MODIFIER - } - - # The AI doesn't want to form alliances with AI vassals within its capital duchy, so it can revoke them - modifier = { - scope:actor = { - is_ai = yes - is_vassal_or_below_of = scope:recipient - any_held_title = { - title_tier = county - de_jure_liege = scope:actor.primary_title.title_capital_county.de_jure_liege - } - } - scope:recipient = { - is_ai = yes - } - add = -5000 - } - - # Feud - modifier = { - add = -25 - scope:recipient = { - house_has_feud_relation_with_trigger = { TARGET = scope:actor } - } - desc = MARRY_FAMILY_FEUD_REASON - } - - # Existing Alliances - modifier = { - add = { - scope:actor = { - every_ally = { - add = -15 - } - } - } - scope:actor = { - any_ally = { - count >= 2 - } - } - desc = EXISTING_ALLIANCES_REASON - } - - # Existing Alliances - modifier = { - add = { - scope:recipient = { - every_ally = { - add = -15 - } - } - } - scope:recipient = { - any_ally = { - count >= 2 - } - } - desc = THEIR_EXISTING_ALLIANCES_REASON - } - - modifier = { - add = intimidated_reason_value - scope:recipient = { - target_is_liege_or_above = scope:actor - has_dread_level_towards = { - target = scope:actor - level = 1 - } - } - desc = INTIMIDATED_REASON - } - modifier = { - add = cowed_reason_value - scope:recipient = { - target_is_liege_or_above = scope:actor - has_dread_level_towards = { - target = scope:actor - level = 2 - } - } - desc = COWED_REASON - } - - modifier = { - add = intimidated_external_reason_value - scope:recipient = { - NOT = { target_is_liege_or_above = scope:actor } - has_dread_level_towards = { - target = scope:actor - level = 1 - } - } - desc = INTIMIDATED_REASON - } - modifier = { - add = cowed_external_reason_value - scope:recipient = { - NOT = { target_is_liege_or_above = scope:actor } - has_dread_level_towards = { - target = scope:actor - level = 2 - } - } - desc = COWED_REASON - } + negotiate_alliance_interaction_ai_acceptance = yes # Unity modifiers evaluate_action_increasing_house_unity = { VALUE = 10 } - - # INFLUENCE - modifier = { - desc = INFLUENCE_REASON - scope:influence = yes - add = { - value = 10 - multiply = scope:actor.influence_level - min = 5 - } - } - } - - ai_potential = { - is_at_war = no - any_ally = { - count < 2 - } } ai_targets = { @@ -3216,8 +2039,8 @@ perk_alliance_interaction = { is_ai = no } NOR = { - scope:actor.current_military_strength >= scope:recipient.current_military_strength - scope:actor.primary_title.tier >= scope:recipient.primary_title.tier + scope:puppet_or_actor.current_military_strength >= scope:recipient.current_military_strength + scope:puppet_or_actor.primary_title.tier >= scope:recipient.primary_title.tier } } @@ -3286,6 +2109,23 @@ join_war_interaction = { } } } + # antipope wars + trigger_else_if = { + limit = { + scope:actor.faith = scope:recipient.faith + scope:recipient = { + any_character_war = { + OR = { + using_cb = pam_challenge_hof_cb + AND = { + using_cb = pam_antiking_cb + scope:actor.religious_head_or_challenger ?= scope:recipient + } + } + } + } + } + } # if the target is neither a vassal-or-below, nor a liege-or-above, the recipient must either be an ally or defending against a qualifying holy war - unless the character is an adventurer in which case other rules apply trigger_else_if = { limit = { @@ -3381,7 +2221,7 @@ join_war_interaction = { # suzerains can always join their tributaries' defensive wars trigger_else_if = { limit = { - scope:recipient = { + scope:recipient = { is_tributary_of_suzerain_or_above = scope:actor } } @@ -3397,7 +2237,7 @@ join_war_interaction = { # tributaries can always offer to join their direct suzerains' defensive wars trigger_else_if = { limit = { - scope:actor = { + scope:actor = { is_tributary_of = scope:recipient } } @@ -3463,7 +2303,7 @@ join_war_interaction = { # recipient is war leader is_war_leader = scope:recipient - + # special exception for tributaries and suzerains to fight for one another trigger_if = { limit = { @@ -3518,7 +2358,20 @@ join_war_interaction = { } } } - + trigger_else_if = { + limit = { + scope:actor.faith ?= scope:recipient.faith + scope:target = { + OR = { + using_cb = pam_challenge_hof_cb + AND = { + using_cb = pam_antiking_cb + scope:actor.religious_head_or_challenger ?= scope:recipient + } + } + } + } + } # if holy war, recipient is defender of same faith # and not too far away trigger_else_if = { @@ -3750,7 +2603,7 @@ join_war_interaction = { } } scope:actor = { - stress_impact = { + stress_and_fulfillment_impact = { craven = medium_stress_impact_gain } add_to_variable_list = { @@ -3846,6 +2699,13 @@ join_vassal_war_interaction = { greeting = positive notification_text = join_war_interaction_notification + is_available = { + trigger_if = { + limit = { is_ai = yes } + is_at_war = no + } + } + is_shown = { scope:recipient = { OR = { @@ -3977,7 +2837,7 @@ join_vassal_war_interaction = { } } scope:actor = { - stress_impact = { + stress_and_fulfillment_impact = { craven = medium_stress_impact_gain } add_to_variable_list = { @@ -4028,9 +2888,6 @@ join_vassal_war_interaction = { empire = 6 hegemony = 6 } - ai_potential = { - is_at_war = no - } ai_accept = { base = 100 #no reason to refuse help @@ -4082,7 +2939,7 @@ join_vassal_war_interaction = { any_in_list = { list = target_titles tier >= tier_kingdom - } + } } add = -100 desc = war_aid_vassal_below_kingdom_title @@ -4135,3 +2992,703 @@ join_vassal_war_interaction = { } } } + +religious_head_call_to_war_interaction = { + icon = icon_scheme_challenge_status + category = interaction_category_diplomacy + interface_priority = 60 + + desc = religious_head_call_to_war_interaction_desc + + interface = call_ally + special_interaction = call_ally_interaction + popup_on_receive = yes + pause_on_receive = yes + + greeting = positive + notification_text = CALL_ALLY_NOTIFICATION + + is_shown = { + scope:puppet_or_actor.religious_head_or_challenger ?= scope:puppet_or_actor + scope:recipient = { + religious_head_or_challenger ?= scope:puppet_or_actor + this != scope:puppet_or_actor + highest_held_title_tier >= tier_county + } + scope:puppet_or_actor ?= { + any_character_war = { + is_war_leader = scope:puppet_or_actor + trigger_if = { + limit = { primary_attacker = scope:puppet_or_actor } + scope:puppet_or_actor.faith.religious_head = { + target_is_same_character_or_above = prev.primary_defender + } + } + trigger_else = { + primary_attacker = { + OR = { + pam_is_antipope_trigger = yes + pam_is_antipope_sponsor_trigger = yes + } + faith.religious_head = scope:puppet_or_actor + } + } + } + liege != scope:recipient + } + + scope:puppet_or_actor = { #If you can call them as a House Member then do that + NOR = { + is_character_interaction_valid = { + recipient = scope:recipient + interaction = call_house_member_to_war_interaction + } + is_character_interaction_valid = { + recipient = scope:recipient + interaction = call_ally_interaction + } + } + } + } + + has_valid_target = { + exists = scope:target + } + + has_valid_target_showing_failures_only = { + scope:target = { + is_war_leader = scope:puppet_or_actor + } + joiner_not_already_in_another_war_with_any_target_war_participants_trigger = { + WARRIOR = scope:puppet_or_actor + JOINER = scope:recipient + } + } + + is_valid_showing_failures_only = { + scope:puppet_or_actor.dynasty = { dynasty_prestige >= medium_dynasty_prestige_value } + scope:recipient = { + NOT = { government_has_flag = government_is_mercenary } + NOT = { government_has_flag = government_is_holy_order } + } + custom_description = { + text = "is_already_in_all_wars" + scope:puppet_or_actor = { + any_character_war = { + NOR = { + is_participant = scope:recipient + was_called = scope:recipient + } + OR = { + primary_attacker = scope:puppet_or_actor + primary_defender = scope:puppet_or_actor + } + } + } + } + } + + can_be_picked = { + can_join_war_liege_vassal_check_trigger = { WARRIOR = scope:puppet_or_actor JOINER = scope:recipient } + } + + auto_accept = { + scope:recipient = { + is_clergy = yes + } + } + + on_auto_accept = { + scope:recipient = { + trigger_event = call_ally.0001 + } + scope:target = { + if = { + limit = { + scope:recipient = { + any_active_accolade = { + accolade_parameter = acclaimed_knight_piety_from_battle + } + } + } + scope:recipient = { + add_piety = miniscule_piety_gain + } + } + if = { + limit = { + scope:recipient = { + any_active_accolade = { + accolade_parameter = acclaimed_knight_piety_from_battle_high + } + } + } + scope:recipient = { + add_piety = minor_piety_gain + } + } + } + } + + on_accept = { + call_ally_interaction_effect = yes + + save_scope_value_as = { + name = call_ally_interaction + value = yes + } + + scope:actor = { + hidden_effect = { #To nudge friendship + if = { + limit = { + NOR = { + has_relation_friend = scope:recipient + has_relation_potential_friend = scope:recipient + } + } + set_relation_potential_friend = scope:recipient + } + } + trigger_event = call_ally.0100 + } + scope:target = { + if = { + limit = { + scope:recipient = { + any_active_accolade = { + accolade_parameter = acclaimed_knight_piety_from_battle + } + } + } + scope:recipient = { + add_piety = minor_piety_gain + } + } + if = { + limit = { + scope:recipient = { + any_active_accolade = { + accolade_parameter = acclaimed_knight_piety_from_battle_high + } + } + } + scope:recipient = { + add_piety = medium_piety_gain + } + } + } + } + + on_decline = { + #The war could theoretically end on the day the decline is sent + if = { + limit = { + exists = scope:target + } + scope:target = { + if = { + limit = { + is_attacker = scope:actor + } + scope:actor = { + add_opinion = { + modifier = rejected_call_to_offensive_war + target = scope:recipient + } + } + scope:recipient = { + #Why should Mandalas care about bickering tributaries in an offensive war + if = { + limit = { + NOT = { government_has_flag = government_is_mandala } + } + add_prestige_experience = major_prestige_loss + } + } + } + else = { + scope:actor = { + add_opinion = { + modifier = rejected_call_to_defensive_war + target = scope:recipient + } + } + scope:recipient = { + if = { + limit = { government_has_flag = government_is_mandala } + add_prestige_experience = major_prestige_loss + add_piety_level = -1 + } + else = { add_prestige_experience = massive_prestige_loss } + } + } + if = { + limit = { + scope:actor = { + has_relation_blood_brother = scope:recipient + } + } + scope:recipient = { + add_piety_experience = massive_piety_loss + add_character_modifier = { + modifier = broke_blood_brotherhood_modifier + desc = broke_blood_brotherhood_modifier_acceptance_tt + years = 25 + } + remove_relation_blood_brother = scope:actor + } + scope:actor = { + set_relation_rival = { + target = scope:recipient + reason = rival_blood_brother_refused_call_reason + } + } + } + # Nomad Vassals and Tributaries stop being Obedient if they have the Liege War Support / Suzerain Defensive Guarantee contract right + if = { + limit = { + scope:recipient = scope:actor.obedience_target + scope:actor = { + OR = { + subject_contract_has_flag = vassal_contract_liege_forced_war_override + subject_contract_has_flag = tributary_contract_suzerain_guarantee_override + } + } + } + scope:actor = { + set_variable = { + name = not_obedient_declined_call + value = scope:recipient + years = 5 + } + } + } + if = { + limit = { + scope:recipient = scope:actor.suzerain + is_defender = scope:actor + scope:actor = { + subject_contract_has_flag = tributary_contract_suzerain_guarantee_override + } + } + scope:actor = { + end_tributary = yes + } + } + hidden_effect = { + if = { + limit = { + NOT = { was_called = scope:recipient } + } + set_called_to = scope:recipient + } + } + } + scope:actor = { + trigger_event = call_ally.0101 + } + + # If we're a clan this interaction affects unity + refuse_call_to_arms_add_clan_unity_effect = yes + + scope:recipient = { + if = { + limit = { + exists = house + is_house_head = yes + exists = scope:actor.house + } + house = { + change_house_relation_effect = { + HOUSE = scope:actor.house + VALUE = house_relation_damage_medium_value + REASON = ally_call_ignored + CHAR = scope:recipient + TARGET_CHAR = scope:actor + TITLE = scope:dummy_gender + } + } + } + } + } + } + + ai_accept = { + base = 50 + + modifier = { # Conquerors do not help anyone but themselves + add = -1000 + desc = NO_FRIVOLOUS_ACTIVITIES_REASON + scope:recipient = { has_variable = conqueror } + } + + modifier = { # Refuse call against Heir + add = -1000 + exists = scope:recipient.player_heir + trigger_if = { + limit = { scope:target.casus_belli.primary_defender = scope:actor } + scope:target.casus_belli.primary_attacker = scope:recipient.player_heir + } + trigger_else = { + scope:target.casus_belli.primary_defender = scope:recipient.player_heir + } + desc = WONT_FIGHT_HEIR_REASON + } + + modifier = { # Refuse call against Spouse + add = -1000 + scope:recipient = { + trigger_if = { + limit = { scope:target.casus_belli.primary_defender = scope:actor } + any_spouse = { + this = scope:target.casus_belli.primary_attacker + } + } + trigger_else = { + any_spouse = { + this = scope:target.casus_belli.primary_defender + } + } + + } + desc = WONT_FIGHT_SPOUSE_REASON + } + + modifier = { # Refuse call against Suzerain if Obedient + add = -1000 + trigger_if = { + limit = { + exists = scope:recipient.suzerain + trigger_if = { + limit = { scope:target.casus_belli.primary_defender = scope:actor } + scope:recipient.suzerain = scope:target.casus_belli.primary_attacker + } + trigger_else = { + scope:recipient.suzerain = scope:target.casus_belli.primary_defender + } + scope:recipient = { + exists = obedience_target + is_obedient = yes + } + } + } + trigger_else = { always = no } + desc = WONT_FIGHT_OBEDIENT_REASON + } + + modifier = { # AI's that need to save gold less likely help their lesser AI allies, unless it's a player war + add = -100 + desc = NO_FRIVOLOUS_ACTIVITIES_REASON + scope:actor = { + is_ai = yes + primary_title.tier < scope:recipient.primary_title.tier + } + scope:target.casus_belli = { + primary_attacker = { is_ai = yes } + primary_defender = { is_ai = yes } + } + scope:recipient = { ai_should_focus_on_building_in_their_capital = yes } + } + + opinion_modifier = { # Opinion Factor + who = scope:recipient + opinion_target = scope:actor + multiplier = 1.0 + desc = AI_OPINION_REASON + } + + # Honor factor + ai_value_modifier = { + ai_honor = 0.5 + ai_zeal = 1 + min = 0 + } + + modifier = { # Tends to join defensive wars + add = 50 + scope:target.casus_belli.primary_defender = scope:actor + desc = DEFENSIVE_WAR_REASON + } + + modifier = { # Same language + add = 5 + desc = speaks_same_language_interaction_reason + trigger = { + scope:actor = { + knows_language_of_culture = scope:recipient.culture + } + } + } + + modifier = { # Shared Court Language (non-spoken) + add = 10 + desc = foreign_realm_court_language_non_spoken_interaction_reason + trigger = { + scope:actor = { + has_royal_court = yes + has_dlc_feature = royal_court + NOT = { knows_court_language_of = this } + } + scope:actor.top_liege != scope:recipient.top_liege + OR = { + AND = { + scope:recipient = { + has_royal_court = yes + } + scope:actor = { # You share Court Language + has_same_court_language = scope:recipient + } + } + + scope:recipient = { # The recipient doesn't have a royal court, but their liege does + liege != this + has_royal_court = no + any_liege_or_above = { + has_royal_court = yes + has_same_court_language = scope:actor + save_temporary_scope_as = liege_temp + NOT = { + prev = { + any_liege_or_above = { + has_royal_court = yes + is_vassal_or_below_of = scope:liege_temp + } + } + } + } + } + } + } + } + + modifier = { # Shared Court Language (spoken) + add = 30 + desc = foreign_realm_court_language_spoken_interaction_reason + trigger = { + scope:actor = { + has_royal_court = yes + has_dlc_feature = royal_court + knows_court_language_of = this + } + scope:actor.top_liege != scope:recipient.top_liege + OR = { + AND = { + scope:recipient = { + has_royal_court = yes + } + scope:actor = { # You share Court Language + has_same_court_language = scope:recipient + } + } + + scope:recipient = { # The recipient doesn't have a royal court, but their liege does + liege != this + has_royal_court = no + any_liege_or_above = { + has_royal_court = yes + has_same_court_language = scope:actor + save_temporary_scope_as = liege_temp + NOT = { + prev = { + any_liege_or_above = { + has_royal_court = yes + is_vassal_or_below_of = scope:liege_temp + } + } + } + } + } + } + } + } + + modifier = { # Serious diarchs wish to support their liege + add = 50 + desc = ENTRENCHED_REGENT_WILL_SUPPORT_LIEGE + trigger_if = { + limit = { scope:recipient ?= scope:actor.diarch } + scope:actor = { has_diarchy_parameter = diarchy_type_is_entrenched_regency } + } + trigger_else = { always = no } + } + + modifier = { # Reluctant to attack another ally + add = -50 + scope:target.casus_belli.primary_attacker = scope:actor + scope:recipient = { + is_allied_to = scope:target.casus_belli.primary_defender + } + desc = ATTACK_ON_ALLY_REASON + } + + modifier = { # Reluctant to defend against another ally + add = -25 + scope:target.casus_belli.primary_defender = scope:actor + scope:recipient = { + is_allied_to = scope:target.casus_belli.primary_attacker + } + desc = WAR_WITH_ALLY_REASON + } + + modifier = { # Reluctant to join against Friends + add = -50 + trigger_if = { + limit = { + scope:target.casus_belli.primary_defender = scope:actor + } + has_relation_friend = scope:target.casus_belli.primary_attacker + } + trigger_else = { + has_relation_friend = scope:target.casus_belli.primary_defender + } + desc = WONT_FIGHT_FRIEND_REASON + } + + modifier = { # Reluctant to join against Best Friends + add = -100 + trigger_if = { + limit = { + scope:target.casus_belli.primary_defender = scope:actor + } + has_relation_best_friend = scope:target.casus_belli.primary_attacker + } + trigger_else = { + has_relation_best_friend = scope:target.casus_belli.primary_defender + } + desc = WONT_FIGHT_BEST_FRIEND_REASON + } + modifier = { # Reluctant to join against Lovers + add = -100 + trigger_if = { + limit = { + scope:target.casus_belli.primary_defender = scope:actor + } + has_relation_lover = scope:target.casus_belli.primary_attacker + } + trigger_else = { + has_relation_lover = scope:target.casus_belli.primary_defender + } + desc = WONT_FIGHT_LOVER_REASON + } + modifier = { # Reluctant to join against Soulmate + add = -200 + trigger_if = { + limit = { + scope:target.casus_belli.primary_defender = scope:actor + } + has_relation_soulmate = scope:target.casus_belli.primary_attacker + } + trigger_else = { + has_relation_soulmate = scope:target.casus_belli.primary_defender + } + desc = WONT_FIGHT_SOULMATE_REASON + } + modifier = { # Reluctant to join tributaries + add = -200 + scope:actor = { + is_tributary_of = scope:recipient + NOT = { subject_contract_has_flag = tributary_contract_suzerain_guarantee_override } + } + scope:recipient = { + NOR = { + has_relation_lover = scope:actor + has_relation_friend = scope:actor + is_allied_to = scope:actor + } + } + desc = WONT_FIGHT_MEANINGLESS_REASON + } + modifier = { # Refuse call for hostages' safety + any_home_court_hostage = { + warden = { + OR = { + is_at_war_with = scope:actor + any_ally = { is_at_war_with = scope:actor } + } + } + } + add = { + value = 0 + every_home_court_hostage = { + limit = { + warden = { + OR = { + is_at_war_with = scope:actor + any_ally = { is_at_war_with = scope:actor } + } + } + } + subtract = call_to_arms_hostage_value + } + multiply = 0.25 + } + desc = HOSTAGE_ENEMY_CALL_TO_ARMS_REASON + } + + modifier = { + add = 200 + scope:actor = { + is_tributary_of = scope:recipient + subject_contract_has_flag = tributary_contract_suzerain_guarantee_override + } + desc = MANDALA_GUARANTEE_REASON + } + + fp3_struggle_resist_allied_wars_modifier = yes + } + + # Score above 0 means the AI will call this ally. Note that DESIRED_WAR_SIDE_STRENGTH still applies and can prevent calling the ally + ai_will_do = { + base = 100 + + modifier = { # If the player is at war, do not bother them with offensive calls + scope:target.casus_belli.primary_attacker = scope:actor + scope:recipient = { + is_ai = no + any_character_war = { + primary_defender = scope:recipient + } + } + factor = 0 + } + + modifier = { # Do not call the player if they are in debt + scope:recipient = { + is_ai = no + gold <= -1 + } + factor = 0 + } + + modifier = { # Don't call players in against their heirs (they wouldn't accept the reverse situation... don't be a hypocrite) + exists = scope:recipient.player_heir + scope:recipient = { + is_ai = no + } + trigger_if = { + limit = { scope:target.casus_belli.primary_defender = scope:actor } + scope:target.casus_belli.primary_attacker = scope:recipient.player_heir + } + trigger_else = { + scope:target.casus_belli.primary_defender = scope:recipient.player_heir + } + factor = 0 + } + + modifier = { # If the recipient is allied to both the attacker and the defender, the attacker shouldn't call + scope:target.casus_belli.primary_attacker = scope:actor + scope:target.casus_belli.primary_defender = { + is_allied_to = scope:recipient + } + factor = 0 + } + + #You're a Mandala Suzerain; you don't get off the hook that easily + modifier = { + scope:actor = { subject_contract_has_flag = tributary_contract_suzerain_guarantee_override } + scope:recipient = scope:actor.suzerain + add = 500 + } + } +} diff --git a/common/character_interactions/00_artifact_interactions.txt b/common/character_interactions/00_artifact_interactions.txt index b83f0e615..6950a87b8 100644 --- a/common/character_interactions/00_artifact_interactions.txt +++ b/common/character_interactions/00_artifact_interactions.txt @@ -8,13 +8,14 @@ gift_artifact_interaction = { target_type = artifact target_filter = actor_artifacts + show_all_targets = no greeting = positive notification_text = GIFT_ARTIFACT_PROPOSAL answer_accept_key = GIFT_ARTIFACT_ACCEPT answer_reject_key = GIFT_ARTIFACT_REJECT - + ai_targets = { ai_recipients = scripted_relations ai_recipients = liege @@ -46,20 +47,27 @@ gift_artifact_interaction = { } can_be_picked_artifact = { - trigger_if = { - limit = { - scope:actor = { - is_ai = no - } - } - scope:target = { - is_equipped = no - } + scope:target = { + is_equipped = no } - scope:actor = { + scope:puppet_or_actor = { any_character_artifact = { this = scope:target } + trigger_if = { + limit = { + involved_activity ?= { + activity_host = scope:puppet_or_actor + has_activity_type = activity_coronation + } + } + scope:target = { + NOR = { + artifact_slot_type = helmet + artifact_slot_type = regalia + } + } + } } #Artifacts locked from being giftable by a variable scope:target = { @@ -67,44 +75,43 @@ gift_artifact_interaction = { } } + is_available = { + has_any_unequipped_artifact = yes + trigger_if = { + limit = { is_ai = yes } + OR = { + AND = { + ai_greed <= high_positive_ai_value + is_adult = yes + # the AI shouldn't give away equipped artifacts + NOT = { + has_trait = greedy + } + } + any_character_artifact = { + var:banner_dynasty.dynast ?= { + save_temporary_scope_as = recipient_temp + root = { has_any_bad_relationship_with_character_trigger = { CHARACTER = scope:recipient_temp } } + } + } + } + } + } #You can't give yourself a gift, even if it should count as self-care is_shown = { - scope:recipient != scope:actor - scope:actor = { - has_any_artifact = yes - trigger_if = { - limit = { - exists = involved_activity - } - NOT = { - involved_activity ?= { #do not give out anything during coronation - has_activity_type = activity_coronation - activity_host = scope:actor - } - } - } + scope:puppet_or_actor ?= { + this != scope:recipient } } is_valid_showing_failures_only = { # needs to have an artifact to give away - scope:actor = { + scope:puppet_or_actor = { NOT = { is_at_war_with = scope:recipient } is_imprisoned = no - trigger_if = { - limit = { - is_ai = no - } - custom_description = { - text = "any_unequipped_artifact_tt" - any_character_artifact = { - is_equipped = no - } - } - } } # keep this since a bit stricter than common rule trigger_if = { @@ -125,7 +132,7 @@ gift_artifact_interaction = { limit = { scope:recipient = { has_opinion_modifier = { - target = scope:actor + target = scope:puppet_or_actor modifier = gift_artifact_opinion } } @@ -135,7 +142,7 @@ gift_artifact_interaction = { # Struggle Catalyst if = { # Struggle Catalyst limit = { - scope:actor = { + scope:puppet_or_actor = { any_character_struggle = { involvement = involved activate_struggle_catalyst_secondary_character_involvement_involved_trigger = { @@ -146,12 +153,12 @@ gift_artifact_interaction = { } } hidden_effect = { - scope:actor = { + scope:puppet_or_actor = { every_character_struggle = { involvement = involved activate_struggle_catalyst = { catalyst = catalyst_gift_independent_ruler - character = scope:actor + character = scope:puppet_or_actor } } } @@ -160,10 +167,10 @@ gift_artifact_interaction = { else_if = { limit = { fp3_struggle_involves_one_supporter_and_one_detractor = { - FIRST = scope:actor + FIRST = scope:puppet_or_actor SECOND = scope:recipient } - scope:actor = { + scope:puppet_or_actor = { any_character_struggle = { #involvement = involved activate_struggle_catalyst_secondary_character_involvement_either_trigger = { @@ -174,7 +181,7 @@ gift_artifact_interaction = { } } hidden_effect = { - scope:actor = { + scope:puppet_or_actor = { every_character_struggle = { #involvement = involved limit = { @@ -185,7 +192,7 @@ gift_artifact_interaction = { } activate_struggle_catalyst = { catalyst = catalyst_gift_supporter_detractor_ruler - character = scope:actor + character = scope:puppet_or_actor } log_debug_variable_for_persian_struggle_effect = { VAR = concession_catalyst_gift_supporter_detractor_ruler } } @@ -206,16 +213,16 @@ gift_artifact_interaction = { if = { limit = { NAND = { - has_relation_friend = scope:actor - has_relation_lover = scope:actor - has_relation_soulmate = scope:actor - has_relation_best_friend = scope:actor + has_relation_friend = scope:puppet_or_actor + has_relation_lover = scope:puppet_or_actor + has_relation_soulmate = scope:puppet_or_actor + has_relation_best_friend = scope:puppet_or_actor } } gifting_leads_towards_friendship_effect = yes } } - scope:actor = { + scope:puppet_or_actor = { send_interface_toast = { type = event_toast_effect_neutral title = gift_artifact_interaction_notification @@ -231,22 +238,22 @@ gift_artifact_interaction = { else = { show_as_tooltip = { house = { remove_house_artifact_claim = scope:target } } } } } - + scope:target = { set_owner = scope:recipient } - + if = { limit = { scope:target = { is_unique = yes } } add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = medium_unity_gain DESC = clan_unity_given_artifact.desc REVERSE_NON_HOUSE_TARGET = no } - stress_impact = { + stress_and_fulfillment_impact = { greedy = major_stress_impact_gain generous = major_stress_impact_loss } @@ -254,13 +261,13 @@ gift_artifact_interaction = { else_if = {# Unity goes here, too! limit = { scope:target = { rarity = masterwork } } add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = minor_unity_gain DESC = clan_unity_given_artifact.desc REVERSE_NON_HOUSE_TARGET = no } - stress_impact = { + stress_and_fulfillment_impact = { greedy = minor_stress_impact_gain generous = minor_stress_impact_loss } @@ -268,13 +275,13 @@ gift_artifact_interaction = { else_if = { limit = { scope:target = { rarity = famed } } add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = minor_unity_gain DESC = clan_unity_given_artifact.desc REVERSE_NON_HOUSE_TARGET = no } - stress_impact = { + stress_and_fulfillment_impact = { greedy = medium_stress_impact_gain generous = medium_stress_impact_loss } @@ -282,13 +289,13 @@ gift_artifact_interaction = { else_if = { limit = { scope:target = { rarity = illustrious } } add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = minor_unity_gain DESC = clan_unity_given_artifact.desc REVERSE_NON_HOUSE_TARGET = no } - stress_impact = { + stress_and_fulfillment_impact = { greedy = major_stress_impact_gain generous = major_stress_impact_loss } @@ -301,38 +308,38 @@ gift_artifact_interaction = { opinion = gift_artifact_opinion } } - #FP3 Tenet Communal Possessions Perk - piety gain for gift giving. - if = { + #FP3 Tenet Communal Possessions Perk - piety gain for gift giving. + if = { limit = { - scope:actor = { - faith = { - has_doctrine_parameter = piety_from_gifts_active + scope:puppet_or_actor = { + rite = { + rite_has_parameter = piety_from_gifts_active } } } - scope:actor = { + scope:puppet_or_actor = { if = { limit = { #the better the artifact, the more piety you gain scope:target = { rarity = illustrious } } - add_piety = massive_piety_gain + add_piety = massive_piety_gain } else_if = { limit = { scope:target = { rarity = famed } } - add_piety = major_piety_gain + add_piety = major_piety_gain } else_if = { limit = { scope:target = { rarity = masterwork } } - add_piety = medium_piety_gain + add_piety = medium_piety_gain } else = { add_piety = minor_piety_gain - } - } + } + } } } @@ -342,11 +349,11 @@ gift_artifact_interaction = { scope:target = { OR = { AND = { - artifact_max_durability >= define:NInventory|ARTIFACT_DEFAULT_MAX_DURABILITY + artifact_max_durability >= define:NInventory|ARTIFACT_DEFAULT_MAX_DURABILITY artifact_durability <= define:NInventory|ARTIFACT_LOW_DURABILITY } AND = { #Check %durability left instead of fixed durability - artifact_max_durability < define:NInventory|ARTIFACT_DEFAULT_MAX_DURABILITY + artifact_max_durability < define:NInventory|ARTIFACT_DEFAULT_MAX_DURABILITY artifact_durability_percent <= { value = define:NInventory|ARTIFACT_LOW_DURABILITY divide = 100 @@ -379,7 +386,7 @@ gift_artifact_interaction = { } if = { limit = { - scope:target = { + scope:target = { OR = { AND = { has_variable = banner_house @@ -422,11 +429,11 @@ gift_artifact_interaction = { custom_tooltip = artifact_gift_benefit_tt } if = { - limit = { scope:recipient.liege = scope:actor } + limit = { scope:recipient.liege = scope:puppet_or_actor } custom_tooltip = artifact_gift_vassal_tt } if = { - limit = { scope:recipient = scope:actor.faith.religious_head } + limit = { scope:recipient = scope:puppet_or_actor.faith.religious_head } custom_tooltip = artifact_gift_religious_head_tt } } @@ -435,7 +442,7 @@ gift_artifact_interaction = { send_interface_toast = { type = event_toast_effect_neutral title = gift_artifact_interaction_notification - left_icon = scope:actor + left_icon = scope:puppet_or_actor right_icon = scope:target show_as_tooltip = { @@ -443,7 +450,7 @@ gift_artifact_interaction = { if = { limit = { is_ai = yes } add_opinion = { - target = scope:actor + target = scope:puppet_or_actor modifier = gift_artifact_opinion opinion = gift_artifact_opinion } @@ -453,7 +460,7 @@ gift_artifact_interaction = { if = { # In a better world, this would be a switch limit = { scope:target = { rarity = Masterwork } } add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = minor_unity_gain DESC = clan_unity_given_artifact.desc @@ -463,7 +470,7 @@ gift_artifact_interaction = { else_if = { limit = { scope:target = { rarity = Famed } } add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = medium_unity_gain DESC = clan_unity_given_artifact.desc @@ -473,7 +480,7 @@ gift_artifact_interaction = { else_if = { limit = { scope:target = { rarity = Illustrious } } add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = major_unity_gain DESC = clan_unity_given_artifact.desc @@ -751,7 +758,7 @@ gift_artifact_interaction = { } auto_accept = no - + ai_accept = { base = 0 modifier = { @@ -834,39 +841,13 @@ gift_artifact_interaction = { VALUE = 100 } } - - ai_potential = { - has_any_artifact = yes - trigger_if = { - limit = { - exists = scope:target.var:banner_dynasty - exists = scope:recipient.dynasty - scope:recipient = scope:target.var:banner_dynasty.dynast - } - NOT = { - scope:actor = { - has_any_bad_relationship_with_character_trigger = { CHARACTER = scope:recipient } - } - } - } - trigger_else = { - is_adult = yes - ai_greed <= high_positive_ai_value - # the AI shouldn't give away equipped artifacts - has_any_unequipped_artifact = yes - - NOT = { - has_trait = greedy - } - } - } - + ai_min_reply_days = 0 ai_max_reply_days = 0 - + ai_will_do = { base = 0 - + modifier = { add = 100 scope:actor = { @@ -879,7 +860,7 @@ gift_artifact_interaction = { exists = scope:recipient.dynasty dynasty = scope:recipient.dynasty } - + AND = { ai_greed <= low_negative_ai_value OR = { # Lieges/vassals, within realm @@ -898,11 +879,7 @@ gift_artifact_interaction = { } } } - - scope:target = { - is_equipped = no - } - + scope:recipient = { OR = { AND = { # Players like nice gifts @@ -912,7 +889,7 @@ gift_artifact_interaction = { rarity = illustrious } } - is_ai = no + is_ai = no } AND = { # Might as well give Court Artifacts to their liege if they cant use them themselves has_royal_court = yes @@ -945,7 +922,7 @@ gift_artifact_interaction = { any_equipped_character_artifact = { artifact_slot_type = primary_armament } - } + } } AND = { scope:target = { @@ -960,7 +937,7 @@ gift_artifact_interaction = { any_equipped_character_artifact = { artifact_slot_type = regalia } - } + } } AND = { scope:target = { @@ -975,7 +952,7 @@ gift_artifact_interaction = { any_equipped_character_artifact = { artifact_slot_type = helmet } - } + } } AND = { scope:target = { @@ -990,7 +967,7 @@ gift_artifact_interaction = { any_equipped_character_artifact = { artifact_slot_type = armor } - } + } } AND = { can_equip_artifact = scope:target # To avoid gifting old children's toys to adults... @@ -1026,7 +1003,7 @@ gift_artifact_interaction = { any_equipped_character_artifact = { artifact_slot_type = throne } - } + } } AND = { has_royal_court = yes @@ -1167,49 +1144,42 @@ gift_artifact_interaction = { evaluate_action_increasing_house_unity = { VALUE = 100 } - + modifier = { factor = 2 scope:recipient = { is_ai = no } } - + modifier = { factor = 0.25 scope:recipient = { highest_held_title_tier = tier_barony } } - + modifier = { # Unlanded characters do not equip artifacts, no point in giving them artifacts factor = 0 scope:recipient = { is_ruler = no } } - + modifier = { factor = 0 scope:recipient = { has_relation_rival = scope:actor } } - - modifier = { - factor = 0 - scope:target = { - is_equipped = yes - } - } - + modifier = { factor = 0 scope:target = { has_variable = gifted_artifact } } - + modifier = { # So that the AI doesn't give player toys factor = 0 scope:recipient = { @@ -1228,6 +1198,13 @@ gift_artifact_interaction = { } } + modifier = { + factor = 0 + scope:target = { + is_holy_relic_for = scope:actor.faith + } + } + modifier = { factor = 0 OR = { @@ -1274,6 +1251,7 @@ demand_artifact_interaction = { target_type = artifact target_filter = recipient_artifacts_claimable + show_all_targets = no greeting = negative notification_text = DEMAND_ARTIFACT_PROPOSAL @@ -1313,15 +1291,25 @@ demand_artifact_interaction = { hegemony = 36 } + is_available = { + trigger_if = { + limit = { is_ai = yes } + has_outstanding_artifact_claims = yes + is_at_war = no + ai_greed >= low_negative_ai_value + is_adult = yes + } + } + is_shown = { - scope:recipient != scope:actor + scope:recipient != scope:puppet_or_actor custom_description = { text = "demand_artifact_interaction_valid_tt_1" scope:recipient = { # needs to have an artifact we can claim any_character_artifact = { - can_be_claimed_by = scope:actor + can_be_claimed_by = scope:puppet_or_actor NOT = { has_variable = is_tribute_mission_artifact } } } @@ -1335,15 +1323,15 @@ demand_artifact_interaction = { NOT = { involved_activity ?= { #do not give out anything during coronation has_activity_type = activity_coronation - activity_host = scope:recipient + activity_host ?= scope:recipient } } - } + } } - scope:actor = { + scope:puppet_or_actor ?= { OR = { - is_ai = no + scope:actor = { is_ai = no } max_military_strength >= { value = { value = scope:recipient.max_military_strength @@ -1354,35 +1342,35 @@ demand_artifact_interaction = { } } } - + is_highlighted = { always = yes } is_valid_showing_failures_only = { - scope:actor = { + scope:puppet_or_actor = { NOT = { is_at_war_with = scope:recipient } } - + trigger_if = { limit = { - scope:actor = { + scope:puppet_or_actor = { has_variable = demanded_this_artifact_interaction_recently } } custom_description = { text = "demand_artifact_interaction_is_valid_tt_2" exists = scope:demanded_artifact - scope:actor = { + scope:puppet_or_actor = { has_variable = demanded_this_artifact_interaction_recently var:demanded_this_artifact_interaction_recently = scope:demanded_artifact } } } - scope:actor = { is_imprisoned = no } + scope:puppet_or_actor = { is_imprisoned = no } } on_accept = { @@ -1393,7 +1381,7 @@ demand_artifact_interaction = { limit = { exists = scope:demanded_artifact } - scope:actor = { + scope:puppet_or_actor = { set_variable = { name = demanded_this_artifact_interaction_recently value = scope:demanded_artifact @@ -1401,19 +1389,19 @@ demand_artifact_interaction = { } } } - scope:actor = { + scope:puppet_or_actor = { send_interface_toast = { type = event_toast_effect_neutral title = demand_artifact_interaction_notification left_icon = scope:recipient right_icon = scope:target scope:target = { - set_owner = scope:actor + set_owner = scope:puppet_or_actor } scope:recipient = { add_opinion = { - target = scope:actor + target = scope:puppet_or_actor modifier = insult_opinion opinion = -10 } @@ -1421,22 +1409,36 @@ demand_artifact_interaction = { if = { limit = { scope:recipient = { - can_set_relation_potential_rival_trigger = { CHARACTER = scope:actor } + can_set_relation_potential_rival_trigger = { CHARACTER = scope:puppet_or_actor } } } scope:recipient = { - set_relation_potential_rival = scope:actor + set_relation_potential_rival = scope:puppet_or_actor } } } } + if = { + limit = { + scope:is_puppet_action ?= yes + scope:actor != scope:recipient + } + scope:actor = { + send_interface_toast = { + type = event_toast_effect_neutral + title = demand_artifact_interaction_notification_puppeteer + left_icon = scope:puppet_or_actor + right_icon = scope:recipient + } + } + } if = { limit = { scope:actor = { is_ai = yes } } - scope:actor = { + scope:puppet_or_actor = { add_opinion = { target = scope:recipient modifier = pleased_opinion @@ -1446,7 +1448,7 @@ demand_artifact_interaction = { } add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = minor_unity_loss DESC = clan_unity_demanded_artifact.desc @@ -1457,19 +1459,19 @@ demand_artifact_interaction = { auto_accept = { custom_description = { text = "spending_hook" - subject = scope:actor + subject = scope:puppet_or_actor object = scope:recipient scope:hook = yes - scope:actor = { has_strong_hook = scope:recipient } + scope:puppet_or_actor = { has_strong_hook = scope:recipient } } } - + send_option = { is_shown = { - scope:actor != scope:recipient + scope:puppet_or_actor != scope:recipient } is_valid = { - scope:actor = { + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } @@ -1477,12 +1479,12 @@ demand_artifact_interaction = { localization = GENERIC_SPEND_A_HOOK } should_use_extra_icon = { - scope:actor = { has_usable_hook = scope:recipient } + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } extra_icon = "gfx/interface/icons/character_interactions/hook_icon.dds" send_options_exclusive = no - + ai_accept = { base = 0 modifier = { @@ -1491,12 +1493,12 @@ demand_artifact_interaction = { } modifier = { add = 70 - scope:actor.max_military_strength > scope:recipient.max_military_strength + scope:puppet_or_actor.max_military_strength > scope:recipient.max_military_strength desc = ARTIFACT_MILITARY_STRONGER_REASON } modifier = { add = -70 - scope:actor.max_military_strength < scope:recipient.max_military_strength + scope:puppet_or_actor.max_military_strength < scope:recipient.max_military_strength desc = ARTIFACT_MILITARY_WEAKER_REASON } modifier = { @@ -1515,14 +1517,14 @@ demand_artifact_interaction = { } modifier = { add = -50 - scope:actor = { + scope:puppet_or_actor = { has_relation_rival = scope:recipient } desc = ARTIFACT_RIVAL_REASON } modifier = { add = -80 - scope:actor = { + scope:puppet_or_actor = { has_relation_nemesis = scope:recipient } desc = ARTIFACT_NEMESIS_REASON @@ -1530,7 +1532,7 @@ demand_artifact_interaction = { modifier = { add = 50 scope:recipient = { - target_is_liege_or_above = scope:actor + target_is_liege_or_above = scope:puppet_or_actor } desc = ARTIFACT_LIEGE_REASON } @@ -1543,13 +1545,6 @@ demand_artifact_interaction = { # Unity modifiers evaluate_action_decreasing_house_unity = { VALUE = 100 } } - - ai_potential = { - is_adult = yes - is_at_war = no - ai_greed >= low_negative_ai_value - has_outstanding_artifact_claims = yes - } on_decline = { scope:target = { @@ -1559,7 +1554,7 @@ demand_artifact_interaction = { limit = { exists = scope:demanded_artifact } - scope:actor = { + scope:puppet_or_actor = { set_variable = { name = demanded_this_artifact_interaction_recently value = scope:demanded_artifact @@ -1567,7 +1562,7 @@ demand_artifact_interaction = { } } } - scope:actor = { + scope:puppet_or_actor = { send_interface_toast = { type = event_toast_effect_bad title = demand_artifact_interaction_notification @@ -1577,20 +1572,35 @@ demand_artifact_interaction = { scope:recipient = { add_opinion = { - target = scope:actor + target = scope:puppet_or_actor modifier = insult_opinion opinion = -10 } } } } + if = { + limit = { + scope:is_puppet_action ?= yes + scope:actor != scope:recipient + } + scope:actor = { + send_interface_toast = { + type = event_toast_effect_bad + title = demand_artifact_interaction_notification_puppeteer + left_icon = scope:puppet_or_actor + right_icon = scope:recipient + custom_tooltip = demand_artifact_interaction_notification_refused_puppeteer + } + } + } if = { limit = { scope:actor = { is_ai = yes } } - scope:actor = { + scope:puppet_or_actor = { add_opinion = { target = scope:recipient modifier = refusal_opinion @@ -1599,18 +1609,18 @@ demand_artifact_interaction = { } } } - + ai_min_reply_days = 7 ai_max_reply_days = 14 - + ai_will_do = { base = 100 - + modifier = { # The AI will only use a Hook if they couldn't otherwise do this scope:hook = yes add = -1 } - + modifier = { add = 50 has_relation_rival = scope:recipient @@ -1635,7 +1645,7 @@ demand_artifact_interaction = { } modifier = { # An Intimidated character is very unlikely to raise their hand add = -25 - scope:actor = { + scope:puppet_or_actor = { has_dread_level_towards = { target = scope:recipient level = 1 @@ -1650,7 +1660,7 @@ demand_artifact_interaction = { modifier = { # A Cowed character will never take this interaction factor = 0 - scope:actor = { + scope:puppet_or_actor = { has_dread_level_towards = { target = scope:recipient level = 2 @@ -1662,7 +1672,7 @@ demand_artifact_interaction = { scope:recipient = { is_ai = no } - scope:actor = { + scope:puppet_or_actor = { OR = { has_relation_friend = scope:recipient has_relation_lover = scope:recipient @@ -1678,7 +1688,7 @@ demand_artifact_interaction = { scope:recipient = { is_ai = no } - scope:actor = { + scope:puppet_or_actor = { has_opinion_modifier = { target = scope:recipient modifier = refusal_opinion @@ -1687,10 +1697,10 @@ demand_artifact_interaction = { } modifier = { # Only the House Head will demand house claimed artifacts from existing House members factor = 0 - exists = scope:actor.house.house_head + exists = scope:puppet_or_actor.house.house_head exists = scope:recipient.house - scope:actor.house.house_head = scope:actor - scope:actor.house = scope:recipient.house + scope:puppet_or_actor.house.house_head = scope:puppet_or_actor + scope:puppet_or_actor.house = scope:recipient.house NOT = { any_personal_claimed_artifact = { @@ -1699,7 +1709,7 @@ demand_artifact_interaction = { } } modifier = { - scope:actor = { + scope:puppet_or_actor = { opinion = { target = scope:recipient value >= medium_positive_opinion @@ -1711,14 +1721,14 @@ demand_artifact_interaction = { modifier = { scope:recipient = { OR = { - has_relation_friend = scope:actor - has_relation_lover = scope:actor + has_relation_friend = scope:puppet_or_actor + has_relation_lover = scope:puppet_or_actor } } factor = 0 } modifier = { - scope:actor = { + scope:puppet_or_actor = { has_royal_court = no } scope:target = { @@ -1824,7 +1834,7 @@ demand_artifact_interaction = { rarity = common } } - } + } } AND = { scope:target = { @@ -1869,7 +1879,7 @@ demand_artifact_interaction = { rarity = common } } - } + } } AND = { scope:target = { @@ -2044,6 +2054,7 @@ challenge_for_artifact_interaction = { target_type = artifact target_filter = recipient_artifacts_claimable + show_all_targets = no greeting = negative notification_text = REQUEST_ARTIFACT_COMBAT_TEXT @@ -2051,6 +2062,17 @@ challenge_for_artifact_interaction = { answer_accept_key = REQUEST_ARTIFACT_COMBAT_ACCEPT answer_reject_key = REQUEST_ARTIFACT_COMBAT_REJECT + is_available = { + trigger_if = { + limit = { is_ai = yes } + has_outstanding_artifact_claims = yes + ai_greed >= low_negative_ai_value + can_start_single_combat_trigger = yes + is_imprisoned = no + NOT = { has_trait = craven } + } + } + is_shown = { # Can't duel yourself. scope:actor != scope:recipient @@ -2072,7 +2094,7 @@ challenge_for_artifact_interaction = { NOT = { involved_activity ?= { #do not give out anything during coronation has_activity_type = activity_coronation - activity_host = scope:recipient + activity_host ?= scope:recipient } } } @@ -2100,7 +2122,7 @@ challenge_for_artifact_interaction = { } } } - + is_highlighted = { rival_single_combat_shown_and_not_invalid_trigger = yes # Scope:recipient must be able to fight personally. @@ -2110,10 +2132,10 @@ challenge_for_artifact_interaction = { scope:recipient = { is_imprisoned = no } scope:actor = { is_imprisoned = no } } - + cost = { prestige = challenge_for_artifact_prestige_cost_value } cooldown = { years = 2 } - cooldown_against_recipient = { years = 5 } + cooldown_against_recipient = { years = 5 } on_send = { scope:actor = { @@ -2298,7 +2320,7 @@ challenge_for_artifact_interaction = { } add = -40 } - # Rival modifier + # Rival modifier modifier = { desc = offer_vassalization_interaction_aibehavior_rival_tt trigger = { @@ -2331,15 +2353,6 @@ challenge_for_artifact_interaction = { } } - # AI - ai_potential = { - NOT = { has_trait = craven } - is_imprisoned = no - can_start_single_combat_trigger = yes - ai_greed >= low_negative_ai_value - has_outstanding_artifact_claims = yes - } - ai_target_quick_trigger = { adult = yes } @@ -2376,7 +2389,7 @@ challenge_for_artifact_interaction = { ai_will_do = { base = -50 - + # Factor for personality (excluding realism). modifier = { add = ai_boldness @@ -2592,7 +2605,7 @@ challenge_for_artifact_interaction = { rarity = common } } - } + } } AND = { scope:target = { @@ -2637,7 +2650,7 @@ challenge_for_artifact_interaction = { rarity = common } } - } + } } AND = { scope:target = { @@ -2796,7 +2809,7 @@ challenge_for_artifact_interaction = { } } -#Steal an artifact that you have a claim on +#Steal an artifact that you have a claim on start_stealing_back_artifact = { icon = icon_scheme_steal_back_artifact interface_priority = 70 @@ -2810,22 +2823,45 @@ start_stealing_back_artifact = { target_type = artifact target_filter = recipient_artifacts - + show_all_targets = no + + is_available = { + trigger_if = { + limit = { is_ai = yes } + intrigue >= low_skill_rating + has_outstanding_artifact_claims = yes + NOT = { + any_scheme = { + OR = { + scheme_type = murder + scheme_type = abduct + scheme_type = claim_throne + scheme_type = fabricate_hook + scheme_type = steal_back_artifact + } + } + } + ai_greed >= low_negative_ai_value + is_imprisoned = no + } + } + is_shown = { + exists = scope:puppet_or_actor NOR = { - scope:recipient = scope:actor - scope:recipient = { is_imprisoned_by = scope:actor } + scope:recipient = scope:puppet_or_actor + scope:recipient = { is_imprisoned_by = scope:puppet_or_actor } } OR = { scope:recipient = { # needs to have an artifact we can claim any_character_artifact = { - can_be_claimed_by = scope:actor + can_be_claimed_by = scope:puppet_or_actor } } AND = { scope:recipient = { has_any_artifact = yes } - scope:actor = { + scope:puppet_or_actor ?= { OR = { employs_court_position = master_thief_camp_officer any_character_active_contract = { @@ -2837,7 +2873,7 @@ start_stealing_back_artifact = { } } } - + is_highlighted = { always = yes } @@ -2845,18 +2881,18 @@ start_stealing_back_artifact = { is_valid_showing_failures_only = { trigger_if = { limit = { - scope:actor = { + scope:puppet_or_actor = { any_character_artifact = { - scope:actor = { has_artifact_claim = prev } + scope:puppet_or_actor = { has_artifact_claim = prev } } } } - + custom_description = { text = steal_back_artifact_can_start_scheme - subject = scope:actor + subject = scope:puppet_or_actor object = scope:recipient - scope:actor = { + scope:puppet_or_actor = { can_start_scheme = { type = steal_back_artifact target_character = scope:recipient @@ -2867,9 +2903,9 @@ start_stealing_back_artifact = { } trigger_if = { limit = { - scope:actor = { + scope:puppet_or_actor = { NOR = { - employs_court_position = master_thief_camp_officer + employs_court_position = master_thief_camp_officer any_character_task_contract = { task_contract_type = laamp_steal_artifact_contract var:task_contract_target ?= scope:recipient @@ -2879,12 +2915,12 @@ start_stealing_back_artifact = { } custom_description = { text = steal_back_artifact_must_have_claim_blocker - subject = scope:actor + subject = scope:puppet_or_actor object = scope:recipient scope:recipient = { any_character_artifact = { - scope:actor = { + scope:puppet_or_actor = { has_artifact_claim = prev } } @@ -2897,7 +2933,7 @@ start_stealing_back_artifact = { scope:recipient = { NOT = { has_opinion_modifier = { - target = scope:actor + target = scope:puppet_or_actor modifier = attempted_to_steal_artifact_from_me } } @@ -2910,7 +2946,7 @@ start_stealing_back_artifact = { scope:recipient = { NOT = { has_opinion_modifier = { - target = scope:actor + target = scope:puppet_or_actor modifier = stole_artifact_from_me } } @@ -2919,18 +2955,18 @@ start_stealing_back_artifact = { trigger_if = { #In range for LAAMP limit = { - scope:actor = { is_landless_adventurer = yes } + scope:puppet_or_actor = { is_landless_adventurer = yes } scope:recipient = { NOT = { any_character_artifact = { - scope:actor = { has_artifact_claim = prev } + scope:puppet_or_actor = { has_artifact_claim = prev } } } } } ep3_laamp_diplo_range_trigger = { TARGET = scope:recipient - LAAMP = scope:actor + LAAMP = scope:puppet_or_actor } } } @@ -2938,7 +2974,7 @@ start_stealing_back_artifact = { desc = { triggered_desc = { trigger = { - scope:actor = { + scope:puppet_or_actor = { can_start_scheme = { type = steal_back_artifact target_character = scope:recipient @@ -2951,7 +2987,7 @@ start_stealing_back_artifact = { can_be_picked_artifact = { trigger_if = { limit = { - scope:actor = { + scope:puppet_or_actor = { NOR = { employs_court_position = master_thief_camp_officer any_character_active_contract = { @@ -2961,7 +2997,7 @@ start_stealing_back_artifact = { } } } - scope:actor = { + scope:puppet_or_actor = { has_artifact_claim = scope:target } } @@ -2995,20 +3031,20 @@ start_stealing_back_artifact = { } on_accept = { - scope:actor = { - stress_impact = { + scope:puppet_or_actor = { + stress_and_fulfillment_impact = { vengeful = medium_stress_impact_loss honest = minor_stress_impact_gain just = minor_stress_impact_loss } } hidden_effect = { - scope:actor = { + scope:puppet_or_actor = { send_interface_toast = { type = event_toast_effect_neutral title = start_stealing_back_artifact_notification - left_icon = scope:actor + left_icon = scope:puppet_or_actor right_icon = scope:recipient if = { @@ -3173,7 +3209,7 @@ start_stealing_back_artifact = { } } show_as_tooltip = { - stress_impact = { + stress_and_fulfillment_impact = { vengeful = medium_stress_impact_loss honest = minor_stress_impact_gain just = minor_stress_impact_loss @@ -3181,28 +3217,23 @@ start_stealing_back_artifact = { } } } - } - } - - # AI - ai_potential = { - is_imprisoned = no - ai_greed >= low_negative_ai_value - intrigue >= low_skill_rating - has_outstanding_artifact_claims = yes - NOT = { - any_scheme = { - OR = { - scheme_type = murder - scheme_type = abduct - scheme_type = claim_throne - scheme_type = fabricate_hook - scheme_type = steal_back_artifact + if = { + limit = { + scope:is_puppet_action ?= yes + scope:actor != scope:recipient + } + scope:actor = { + send_interface_toast = { + type = event_toast_effect_neutral + title = start_stealing_back_artifact_notification_puppeteer + left_icon = scope:puppet_or_actor + right_icon = scope:recipient + } } } } } - + ai_target_quick_trigger = { adult = yes } @@ -3257,13 +3288,13 @@ start_stealing_back_artifact = { } } modifier = { - scope:actor = { + scope:puppet_or_actor = { has_relation_rival = scope:recipient } add = 60 } modifier = { - scope:actor = { + scope:puppet_or_actor = { has_relation_nemesis = scope:recipient } add = 150 @@ -3279,7 +3310,7 @@ start_stealing_back_artifact = { add = 35 } modifier = { - scope:actor = { + scope:puppet_or_actor = { opinion = { target = scope:recipient value >= medium_positive_opinion @@ -3291,14 +3322,14 @@ start_stealing_back_artifact = { modifier = { scope:recipient = { OR = { - has_relation_friend = scope:actor - has_relation_lover = scope:actor + has_relation_friend = scope:puppet_or_actor + has_relation_lover = scope:puppet_or_actor } } factor = 0 } modifier = { - scope:actor = { + scope:puppet_or_actor = { has_royal_court = no } scope:target = { @@ -3404,7 +3435,7 @@ start_stealing_back_artifact = { rarity = common } } - } + } } AND = { scope:target = { @@ -3449,7 +3480,7 @@ start_stealing_back_artifact = { rarity = common } } - } + } } AND = { scope:target = { @@ -3618,14 +3649,29 @@ buy_artifact_claim = { icon = artisan_inspiration target_type = artifact - target_filter = recipient_artifacts + target_filter = recipient_artifacts + show_all_targets = no + + is_available = { + has_perk = accomplished_forger_perk + trigger_if = { + limit = { is_ai = yes } + # Only really greedy AI characters get to use this + ai_greed >= high_positive_ai_value + piety > major_piety_value + is_playable_character = yes + + # The basic requirements + is_imprisoned = no + # They must be well supplied + prestige > major_prestige_value + + is_available_ai_adult = yes + } + is_landless_adventurer = no + } is_shown = { - # interaction locked behind Accomplished Forger perk from the Diplomacy lifestyle - scope:actor = { - has_perk = accomplished_forger_perk - is_landless_adventurer = no - } NOR = { # Can't buy from yourself scope:recipient = scope:actor @@ -3655,7 +3701,7 @@ buy_artifact_claim = { NOT = { involved_activity ?= { #do not give out anything during coronation has_activity_type = activity_coronation - activity_host = scope:recipient + activity_host ?= scope:recipient } } } @@ -3684,7 +3730,7 @@ buy_artifact_claim = { } scope:recipient = { # needs to have an artifact - any_character_artifact = { + any_character_artifact = { exists = this # actor can't already have a claim on said artifact scope:actor = { @@ -3698,65 +3744,65 @@ buy_artifact_claim = { # Checks to determine piety cost for Religious Artifacts trigger_if = { limit = { - exists = scope:target.var:relic - scope:target = { rarity = common } + scope:target ?= { is_holy_relic_for = scope:actor.faith } } - scope:actor = { piety >= minor_buy_claim_piety_value } - } - trigger_else_if = { - limit = { - exists = scope:target.var:relic - scope:target = { rarity = masterwork } + trigger_if = { + limit = { + scope:target = { + rarity = common + } + } + scope:actor = { piety >= minor_buy_claim_piety_value } } - scope:actor = { piety >= medium_buy_claim_piety_value } - } - trigger_else_if = { - limit = { - exists = scope:target.var:relic - scope:target = { rarity = famed } + trigger_else_if = { + limit = { + scope:target = { + rarity = masterwork + } + } + scope:actor = { piety >= medium_buy_claim_piety_value } + } + trigger_else_if = { + limit = { + scope:target = { + rarity = famed + } + } + scope:actor = { piety >= major_buy_claim_piety_value } + } + trigger_else = { + scope:actor = { piety >= massive_buy_claim_piety_value } } - scope:actor = { piety >= major_buy_claim_piety_value } } trigger_else = { - limit = { - exists = scope:target.var:relic - scope:target = { rarity = illustrious } + # Checks to determine prestige cost for regular artifacts + trigger_if = { + limit = { + scope:target ?= { + rarity = common + } + } + scope:actor = { prestige >= minor_buy_claim_prestige_value } } - scope:actor = { piety >= massive_buy_claim_piety_value } - } - - # Checks to determine prestige cost for regular artifacts - trigger_if = { - limit = { - exists = scope:target - NOT = { exists = scope:target.var:relic } - scope:target = { rarity = common } + trigger_else_if = { + limit = { + scope:target ?= { + rarity = masterwork + } + } + scope:actor = { prestige >= medium_buy_claim_prestige_value } } - scope:actor = { prestige >= minor_buy_claim_prestige_value } - } - trigger_else_if = { - limit = { - exists = scope:target - NOT = { exists = scope:target.var:relic } - scope:target = { rarity = masterwork } + trigger_else_if = { + limit = { + scope:target ?= { + rarity = famed + } + } + scope:actor = { prestige >= major_buy_claim_prestige_value } } - scope:actor = { prestige >= medium_buy_claim_prestige_value } - } - trigger_else_if = { - limit = { - exists = scope:target - NOT = { exists = scope:target.var:relic } - scope:target = { rarity = famed } + trigger_else = { + scope:actor = { prestige >= massive_buy_claim_prestige_value } } - scope:actor = { prestige >= major_buy_claim_prestige_value } - } - trigger_else = { - limit = { - exists = scope:target - NOT = { exists = scope:target.var:relic } - scope:target = { rarity = illustrious } - } - scope:actor = { prestige >= massive_buy_claim_prestige_value } } } @@ -3768,7 +3814,9 @@ buy_artifact_claim = { # If it's a religous artifact... if = { limit = { - exists = scope:target.var:relic + scope:target = { + is_holy_relic_for = scope:actor.faith + } } # Toast to the actor scope:actor = { @@ -3780,29 +3828,37 @@ buy_artifact_claim = { # Determine piety cost if = { limit = { - exists = scope:target.var:relic - scope:target = { rarity = common } + scope:target = { + is_holy_relic_for = scope:actor.faith + rarity = common + } } scope:actor = { add_piety = minor_buy_claim_piety_loss } } else_if = { limit = { - exists = scope:target.var:relic - scope:target = { rarity = masterwork } + scope:target = { + is_holy_relic_for = scope:actor.faith + rarity = masterwork + } } scope:actor = { add_piety = medium_buy_claim_piety_loss } } else_if = { limit = { - exists = scope:target.var:relic - scope:target = { rarity = famed } + scope:target = { + is_holy_relic_for = scope:actor.faith + rarity = famed + } } scope:actor = { add_piety = major_buy_claim_piety_loss } } else_if = { limit = { - exists = scope:target.var:relic - scope:target = { rarity = illustrious } + scope:target = { + is_holy_relic_for = scope:actor.faith + rarity = illustrious + } } scope:actor = { add_piety = massive_buy_claim_piety_loss } } @@ -3820,11 +3876,11 @@ buy_artifact_claim = { } } } - # If it's not a religous artifact... + # If it's not a religious artifact... else = { scope:actor = { send_interface_toast = { - type = event_artifact_bad + type = event_artifact_good title = bought_artifact_claim.t left_icon = scope:recipient right_icon = scope:target @@ -3860,7 +3916,7 @@ buy_artifact_claim = { add_personal_artifact_claim = scope:target } } - + scope:recipient = { send_interface_message = { type = event_artifact_bad_text @@ -3872,7 +3928,7 @@ buy_artifact_claim = { } } scope:actor = { - stress_impact = { + stress_and_fulfillment_impact = { just = medium_stress_impact_gain honest = medium_stress_impact_gain } @@ -3886,7 +3942,7 @@ buy_artifact_claim = { # Recipient grows closer to forming a rivalry with the actor if = { limit = { - can_set_relation_potential_rival_trigger = { + can_set_relation_potential_rival_trigger = { CHARACTER = scope:actor } } @@ -3923,20 +3979,6 @@ buy_artifact_claim = { hegemony = 30 } - ai_potential = { - # The basic requirements - is_imprisoned = no - is_playable_character = yes - is_available_ai_adult = yes - - # They must be well supplied - prestige > major_prestige_value - piety > major_piety_value - - # Only really greedy AI characters get to use this - ai_greed >= high_positive_ai_value - } - ai_will_do = { base = 30 @@ -3948,7 +3990,7 @@ buy_artifact_claim = { # Make it more likely for AI characters to buy claims if they have a royal court modifier = { scope:actor = { - has_royal_court = yes + has_royal_court = yes has_dlc_feature = court_artifacts } factor = 2 @@ -3997,6 +4039,7 @@ demand_dynasty_banner_interaction = { target_type = artifact target_filter = recipient_artifacts + show_all_targets = no greeting = negative notification_text = DEMAND_ARTIFACT_PROPOSAL @@ -4036,27 +4079,37 @@ demand_dynasty_banner_interaction = { hegemony = 36 } + is_available = { + trigger_if = { + limit = { is_ai = yes } + has_outstanding_artifact_claims = yes + is_at_war = no + ai_greed >= low_negative_ai_value + is_adult = yes + } + } + is_shown = { - scope:recipient != scope:actor + exists = scope:actor.dynasty NOT = { #Landless have no court in which to display such a banner, and no real authority over a landed relative scope:actor = { government_has_flag = government_is_landless_adventurer } } - exists = scope:actor.dynasty + scope:recipient != scope:actor exists = scope:recipient.dynasty - scope:recipient.dynasty = scope:actor.dynasty + scope:recipient.dynasty ?= scope:actor.dynasty scope:recipient = { # needs to have a banner of our dynasty any_character_artifact = { AND = { exists = var:banner_dynasty - var:banner_dynasty = scope:recipient.dynasty - var:banner_dynasty.dynast = scope:actor + var:banner_dynasty ?= scope:recipient.dynasty + var:banner_dynasty.dynast ?= scope:actor NOT = { has_variable = is_tribute_mission_artifact } } } } } - + is_highlighted = { always = yes } @@ -4198,7 +4251,7 @@ demand_dynasty_banner_interaction = { scope:actor = { has_strong_hook = scope:recipient } } } - + send_option = { is_shown = { scope:actor != scope:recipient @@ -4217,7 +4270,7 @@ demand_dynasty_banner_interaction = { extra_icon = "gfx/interface/icons/character_interactions/hook_icon.dds" send_options_exclusive = no - + ai_accept = { base = 100 modifier = { @@ -4270,22 +4323,13 @@ demand_dynasty_banner_interaction = { VALUE = 100 } } - - ai_potential = { - is_adult = yes - is_at_war = no - ai_greed >= low_negative_ai_value - has_outstanding_artifact_claims = yes - } - - ai_min_reply_days = 7 ai_max_reply_days = 14 - + ai_will_do = { base = 100 - + modifier = { # The AI will only use a Hook if they couldn't otherwise do this scope:hook = yes add = -1 @@ -4347,39 +4391,44 @@ destroy_artifact_interaction = { target_type = artifact target_filter = actor_artifacts + show_all_targets = no ai_targets = { ai_recipients = self } - # You can only destroy your own artifacts - is_shown = { - scope:recipient = scope:actor - scope:actor = { - has_any_artifact = yes - } - scope:actor = { - trigger_if = { - limit = { - exists = involved_activity + is_available = { + has_any_artifact = yes + trigger_if = { + limit = { is_ai = yes } + OR = { + gold <= minor_gold_value # Poor rulers will consider getting rid of their trash for gold + rite ?= { # Aniconists will always want to destroy artifacts + rite_has_parameter = destroying_artifacts_is_pious } - NOT = { - involved_activity ?= { #do not give out anything during coronation - has_activity_type = activity_coronation - activity_host = scope:actor - } + AND = { # Economic boom personalities will bolster their treasury by getting rid of trash more often + ai_has_builder_or_pious_builder_personality = yes + gold <= medium_gold_value + } + any_character_artifact = { # All rulers want to get rid of actively detrimental trash + has_variable = unwanted_artifact } } } } + # You can only destroy your own artifacts + is_shown = { + scope:recipient = scope:actor + } + can_be_picked_artifact = { custom_tooltip = { text = artifact_is_related_to_contract_tt scope:target = { - NOR = { - has_variable = 1025_treasure_map - has_variable = is_tribute_mission_artifact + has_none_of_variables = { + name = 1025_treasure_map + name = is_tribute_mission_artifact } } } @@ -4389,13 +4438,31 @@ destroy_artifact_interaction = { NOT = { has_variable = mandala_capital_05_unconfirmed_talisman } } } + # don't mess the list + scope:target = { is_equipped = no } + scope:actor = { + trigger_if = { + limit = { + involved_activity ?= { + activity_host = scope:puppet_or_actor + has_activity_type = activity_coronation + } + } + scope:target = { + NOR = { + artifact_slot_type = helmet + artifact_slot_type = regalia + } + } + } + } } has_valid_target_showing_failures_only = { trigger_if = { limit = { NOT = { - scope:recipient.faith = { has_doctrine_parameter = destroying_artifacts_is_pious } + scope:recipient.rite = { rite_has_parameter = destroying_artifacts_is_pious } } } custom_tooltip = { @@ -4415,7 +4482,7 @@ destroy_artifact_interaction = { } custom_tooltip = { text = destroying_artifacts_is_not_pious_tt - scope:recipient.faith = { has_doctrine_parameter = destroying_artifacts_is_pious } + scope:recipient.rite = { rite_has_parameter = destroying_artifacts_is_pious } } } scope:actor = { @@ -4444,22 +4511,6 @@ destroy_artifact_interaction = { hegemony = 24 } - ai_potential = { - OR = { - faith = { # Aniconists will always want to destroy artifacts - has_doctrine_parameter = destroying_artifacts_is_pious - } - gold <= minor_gold_value # Poor rulers will consider getting rid of their trash for gold - AND = { # Economic boom personalities will bolster their treasury by getting rid of trash more often - gold <= medium_gold_value - ai_has_builder_or_pious_builder_personality = yes - } - any_character_artifact = { # All rulers want to get rid of actively detrimental trash - has_variable = unwanted_artifact - } - } - } - ai_will_do = { base = 0 modifier = { # Rulers will always destroy unwanted artifacts @@ -4485,15 +4536,11 @@ destroy_artifact_interaction = { } scope:target = { rarity = common - is_equipped = no } } modifier = { # AI rulers will destroy all unequipped artifacts to get out of debt add = 100 gold <= 0 - scope:target = { - is_equipped = no - } } modifier = { # Common artifact trinkets on their last legs can be considered for destruction if money is low add = 100 @@ -4524,13 +4571,8 @@ destroy_artifact_interaction = { } modifier = { # Aniconists destroy most things add = 100 - faith = { - has_doctrine_parameter = destroying_artifacts_is_pious - } - OR = { # This errors in the ai_potential so it's been moved here - has_trait = zealous - scope:target = { is_equipped = no } - scope:target = { exists = var:relic } + rite = { + rite_has_parameter = destroying_artifacts_is_pious } # The logic below relies on the idea that they have the destroying_artifacts_is_pious doctrine parameter. If the restrictions are loosened, these triggers should be updated NOR = { @@ -4540,28 +4582,34 @@ destroy_artifact_interaction = { NOT = { has_trait = zealous } } } - OR = { - has_trait = zealous # Destroy all the artifacts - any_character_artifact = { - is_equipped = no - } - any_character_artifact = { - exists = var:relic - } - } + scope:target = { is_holy_relic = yes } } modifier = { #Piety _and_ gold? Sign me up! add = 50 ai_has_pious_builder_personality = yes - faith = { - has_doctrine_parameter = destroying_artifacts_is_pious + scope:target = { is_holy_relic = yes } + rite = { + rite_has_parameter = destroying_artifacts_is_pious } } - modifier = { # Icon venerating faiths will never destroy artifacts - factor = 0 - faith = { - has_doctrine_paramter = destroying_artifacts_costs_piety + # NEVER destroy your crown + modifier = { + add = -500 + coronation_trigger = yes + any_character_artifact = { + is_coronation_artifact_trigger = yes + count = 1 + } + scope:target = { + is_coronation_artifact_trigger = yes + } + } + modifier = { + add = -500 + scope:target = { + var:artifact_succession_title ?= scope:actor.primary_title } } } } + diff --git a/common/character_interactions/00_ce1_interactions.txt b/common/character_interactions/00_ce1_interactions.txt index 975583e16..ee5f71004 100644 --- a/common/character_interactions/00_ce1_interactions.txt +++ b/common/character_interactions/00_ce1_interactions.txt @@ -12,14 +12,22 @@ ce1_ask_to_promote_legend_interaction = { greeting = positive notification_text = PROMOTE_LEGEND_NOTIFICATION + is_available = { + trigger_if = { + limit = { is_ai = yes } + is_physically_able = yes + } + } + is_shown = { - scope:actor.promoted_legend.legend_owner ?= scope:actor - scope:actor != scope:recipient + scope:puppet_or_actor.promoted_legend.legend_owner ?= scope:puppet_or_actor + exists = scope:puppet_or_actor + scope:puppet_or_actor != scope:recipient scope:recipient = { is_landed = yes age >= 12 is_physically_able = yes - NOT = { government_has_flag = government_is_true_herder } + NOT = { government_has_flag = government_is_herder } } } @@ -33,16 +41,16 @@ ce1_ask_to_promote_legend_interaction = { custom_tooltip = { text = recipient_close_or_neighbor_tt OR = { - scope:recipient.dynasty = scope:actor.dynasty - scope:recipient = { knows_language_of_culture = scope:actor.culture } - scope:actor = { + scope:recipient.dynasty = scope:puppet_or_actor.dynasty + scope:recipient = { knows_language_of_culture = scope:puppet_or_actor.culture } + scope:puppet_or_actor = { has_any_moderate_good_relationship_with_character_trigger = { CHARACTER = scope:recipient } } scope:recipient = { any_character_to_title_neighboring_county = { any_county_province = { any_province_legend = { - this = scope:actor.promoted_legend + this = scope:puppet_or_actor.promoted_legend } } } @@ -92,7 +100,7 @@ ce1_ask_to_promote_legend_interaction = { modifier = { add = 10 desc = REASON_ILLUSTRIOUS_LEGEND - scope:actor = { + scope:puppet_or_actor = { promoted_legend = { legend_quality = illustrious } @@ -101,7 +109,7 @@ ce1_ask_to_promote_legend_interaction = { modifier = { add = 20 desc = REASON_MYTHICAL_LEGEND - scope:actor = { + scope:puppet_or_actor = { promoted_legend = { legend_quality = mythical } @@ -127,7 +135,7 @@ ce1_ask_to_promote_legend_interaction = { # Do they like you? opinion_modifier = { who = scope:recipient - opinion_target = scope:actor + opinion_target = scope:puppet_or_actor multiplier = 1 desc = AI_OPINION_REASON } @@ -181,7 +189,7 @@ ce1_ask_to_promote_legend_interaction = { add = intimidated_halved_reason_value scope:recipient = { has_dread_level_towards = { - target = scope:actor + target = scope:puppet_or_actor level = 1 } } @@ -191,7 +199,7 @@ ce1_ask_to_promote_legend_interaction = { add = cowed_halved_reason_value scope:recipient = { has_dread_level_towards = { - target = scope:actor + target = scope:puppet_or_actor level = 2 } } @@ -208,7 +216,7 @@ ce1_ask_to_promote_legend_interaction = { ## Low Gold modifier = { add = -100 - scope:actor.promoted_legend = { + scope:puppet_or_actor.promoted_legend = { legend_quality = famed } scope:recipient = { @@ -218,7 +226,7 @@ ce1_ask_to_promote_legend_interaction = { } modifier = { add = -100 - scope:actor.promoted_legend = { + scope:puppet_or_actor.promoted_legend = { legend_quality = illustrious } scope:recipient = { @@ -228,7 +236,7 @@ ce1_ask_to_promote_legend_interaction = { } modifier = { add = -100 - scope:actor.promoted_legend = { + scope:puppet_or_actor.promoted_legend = { legend_quality = mythical } scope:recipient = { @@ -239,21 +247,21 @@ ce1_ask_to_promote_legend_interaction = { modifier = { add = 25 scope:recipient = { - is_contact_of = scope:actor + is_contact_of = scope:puppet_or_actor } desc = IS_CONTACT_REASON } } on_accept = { - scope:actor.promoted_legend = { + scope:puppet_or_actor.promoted_legend = { save_scope_as = promoted_legend } - scope:actor = { + scope:puppet_or_actor = { send_interface_toast = { type = event_toast_effect_good title = ce1_ask_to_promote_legend_acceptance_tt - left_icon = scope:actor + left_icon = scope:puppet_or_actor right_icon = scope:recipient if = { @@ -275,21 +283,49 @@ ce1_ask_to_promote_legend_interaction = { } } scope:recipient = { - set_promoted_legend = scope:actor.promoted_legend + set_promoted_legend = scope:puppet_or_actor.promoted_legend + } + } + } + if = { + limit = { + scope:is_puppet_action ?= yes + scope:actor != scope:recipient + } + scope:actor = { + send_interface_toast = { + type = event_toast_effect_good + title = ce1_ask_to_promote_legend_acceptance_tt_puppeteer + left_icon = scope:puppet_or_actor + right_icon = scope:recipient } } } } on_decline = { - scope:actor = { + scope:puppet_or_actor = { send_interface_toast = { type = event_toast_effect_bad title = ce1_ask_to_promote_legend_decline_tt - left_icon = scope:actor + left_icon = scope:puppet_or_actor right_icon = scope:recipient } } + if = { + limit = { + scope:is_puppet_action ?= yes + scope:actor != scope:recipient + } + scope:actor = { + send_interface_toast = { + type = event_toast_effect_bad + title = ce1_ask_to_promote_legend_decline_tt_puppeteer + left_icon = scope:puppet_or_actor + right_icon = scope:recipient + } + } + } } # Use gold to increase acceptance @@ -300,7 +336,7 @@ ce1_ask_to_promote_legend_interaction = { send_option = { flag = hook is_valid = { - scope:actor = { + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } @@ -308,10 +344,6 @@ ce1_ask_to_promote_legend_interaction = { } send_options_exclusive = no - ai_potential = { - is_physically_able = yes - } - ai_targets = { ai_recipients = neighboring_rulers } diff --git a/common/character_interactions/00_character_interactions.txt b/common/character_interactions/00_character_interactions.txt index 9113ee7f9..f686d38e5 100644 --- a/common/character_interactions/00_character_interactions.txt +++ b/common/character_interactions/00_character_interactions.txt @@ -21,16 +21,24 @@ offer_vassalization_interaction = { hegemony = 12 } - is_shown = { - scope:actor = { - is_landed = yes + is_available = { + is_landed = yes + trigger_if = { + limit = { is_ai = yes } + highest_held_title_tier > tier_county + this = top_liege + vassal_limit_available > 1 + is_adult = yes } + } + + is_shown = { scope:recipient = { this != scope:actor is_playable_character = yes OR = { AND = { - top_liege = this + top_liege ?= this is_tributary = no } is_tributary_of_suzerain_or_above = scope:actor @@ -45,7 +53,7 @@ offer_vassalization_interaction = { } NOR = { government_has_flag = cannot_be_vassal_or_liege - government_has_flag = government_is_true_herder + government_has_flag = government_is_herder } } # Temujin cannot make Jamukha his subject once he leaves him @@ -67,22 +75,22 @@ offer_vassalization_interaction = { limit = { has_title = title:h_china } - situation:dynastic_cycle ?= { - NOT = { - situation_current_phase = situation_dynastic_cycle_phase_instability - } - trigger_if = { - limit = { - situation_current_phase = situation_dynastic_cycle_phase_stability_advancement - } - scope:recipient = { - custom_tooltip = { - text = recipient_is_not_celestial_desc - government_has_flag = government_is_celestial - } - } - } - } +# situation:dynastic_cycle ?= { +# NOT = { +# situation_current_phase = situation_dynastic_cycle_phase_instability +# } +# trigger_if = { +# limit = { +# situation_current_phase = situation_dynastic_cycle_phase_stability_advancement +# } +# scope:recipient = { +# custom_tooltip = { +# text = recipient_is_not_celestial_desc +# government_has_flag = government_is_celestial +# } +# } +# } +# } } } scope:recipient = { @@ -142,78 +150,12 @@ offer_vassalization_interaction = { ai_accept = { base = -50 - # MAIN - # Heretic/Infidel modifier. - # Tier difference modifier. - # Dejure modifier. - # Distant/Remote Realm modifier. + # Military power difference modifier. - - # MINOR - # Rivalry modifier. - # Same Dynasty modifier. - # Cultural/Cultural Group modifiers. - # Ageism modifier vs kids. - # Ruler Legitimacy modifier. - # Claimant modifier. - # FP3 Piety Level modifier. - - # OPINION SCALES - # Dread - # Compare Opinion modifier. + offer_vassalization_interaction_ai_acceptance_general = yes #ALL these modifiers are also used in impress_intent_vassalization_acceptance_value, keep them synced - # PERKS - modifier = { # Perk boost - desc = offer_vassalization_true_ruler_perk_tt - trigger = { - scope:actor = { has_perk = true_ruler_perk } - } - add = true_ruler_value - } - modifier = { # Education 5 boost - desc = offer_vassalization_education_diplomacy_5_tt - trigger = { - scope:actor = { has_trait_with_flag = offer_vassalisation_25 } - } - add = 25 - } - - # EVENTS - temporary bonuses gained by events - modifier = { - desc = event_bonus_to_vassal_accept_tt - trigger = { - scope:actor = { has_character_modifier = event_bonus_to_vassal_accept } - } - add = 20 - } - - - # STRUGGLES - bonus gained by successful Sway scheme during the Persian Struggle - modifier = { - desc = fp3_persian_struggle_previously_swayed_tt - trigger = { - scope:recipient = { - has_opinion_modifier = { - modifier = scheme_sway_and_compelled_to_submit_opinion - target = scope:actor - } - } - } - add = 20 - } - - modifier = { #Rekindler of Iran - desc = fp3_rekindler_of_iran_modifier_reason - trigger = { - AND = { - scope:actor = { dynasty ?={ has_dynasty_modifier = fp3_rekindler_of_iran_modifier } } - scope:recipient = { culture = { has_cultural_pillar = heritage_iranian } } - } - } - add = 20 - } # OBEDIENCE modifier = { @@ -224,21 +166,12 @@ offer_vassalization_interaction = { add = 20 } - modifier = { # Cultural Acceptance - add = offer_vassalage_acceptance_value - desc = cultural_acceptance_interaction_reason + modifier = { + desc = tenet_love_thy_neighbour_boon_reason trigger = { - scope:actor = { - NOR = { - has_same_culture_as = scope:recipient - government_has_flag = government_is_nomadic # Nomads do not care about Culture - has_trait = nomadic_philosophy - } - culture = { - cultural_acceptance = { target = scope:recipient.culture value <= 90 } - } - } + scope:actor = { has_personal_tenet_flag = tenet_love_thy_neighbour_vassalage_acceptance } } + add = 15 } modifier = { #Has no Available Vassal Limit @@ -252,434 +185,69 @@ offer_vassalization_interaction = { value = -1000 } } - - # MAIN - modifier = { #Different faith, no pluralism. - desc = offer_vassalization_interaction_aibehavior_differentfaith_tt - trigger = { - scope:actor = { - NOR = { # Nomads do not care about Faith - government_has_flag = government_is_nomadic - has_trait = nomadic_philosophy + # GOVERNMENT + modifier = { # I am Tribal and you are not + desc = interaction_tribal_vs_nontribal + trigger = { + scope:recipient = { + government_has_flag = government_is_tribal } - } - scope:recipient = { - NOR = { #Of two different faiths AND the potential vassal's faith is not pluralistic. - faith = scope:actor.faith - faith = { has_doctrine = doctrine_pluralism_pluralistic } - } - } - } - add = { - value = -40 - if = { - limit = { - scope:recipient.faith = { - faith_hostility_level = { - target = scope:actor.faith - value >= faith_hostile_level - } - } - } - add = -40 - } - if = { - limit = { - scope:recipient.faith = { - faith_hostility_level = { - target = scope:actor.faith - value >= faith_evil_level - } - } - } - add = -40 - } - } - } - - modifier = { #Different faith, pluralism. - desc = offer_vassalization_interaction_aibehavior_differentfaith_tt - trigger = { - scope:actor = { - NOR = { # Nomads do not care about Faith - government_has_flag = government_is_nomadic - has_trait = nomadic_philosophy - } - } - scope:recipient = { - faith != scope:actor.faith - NOT = { - scope:actor.faith = { has_doctrine = doctrine_pluralism_pluralistic } - } - faith = { has_doctrine = doctrine_pluralism_pluralistic } - } - } - add = { - value = -20 - if = { - limit = { - scope:recipient.faith = { - faith_hostility_level = { - target = scope:actor.faith - value >= faith_hostile_level - } - } - } - add = -20 - } - if = { - limit = { - scope:recipient.faith = { - faith_hostility_level = { - target = scope:actor.faith - value >= faith_evil_level - } - } - } - add = -20 - } - } - } - - modifier = { #Different faith, both have pluralism. - desc = offer_vassalization_interaction_aibehavior_differentfaith_tt - trigger = { - scope:actor = { - NOR = { # Nomads do not care about Faith - government_has_flag = government_is_nomadic - has_trait = nomadic_philosophy - } - } - scope:recipient = { - faith != scope:actor.faith - scope:actor.faith = { has_doctrine = doctrine_pluralism_pluralistic } - faith = { has_doctrine = doctrine_pluralism_pluralistic } - } - } - add = { - value = -10 - if = { - limit = { - scope:recipient.faith = { - faith_hostility_level = { - target = scope:actor.faith - value >= faith_hostile_level - } - } - } - add = -10 - } - if = { - limit = { - scope:recipient.faith = { - faith_hostility_level = { - target = scope:actor.faith - value >= faith_evil_level - } - } - } - add = -10 - } - } - } - modifier = { #I am a King! Or Emperor! - desc = offer_vassalization_interaction_aibehavior_hightier_tt - trigger = { - NAND = { scope:actor = { - government_has_flag = government_is_celestial - highest_held_title_tier >= tier_hegemony + NOT = { government_has_flag = government_is_tribal } + } + } + add = -20 + } + modifier = { # You are Tribal and I am not + desc = interaction_nontribal_vs_tribal + trigger = { + scope:actor = { + government_has_flag = government_is_tribal } scope:recipient = { - government_has_flag = government_is_celestial + NOT = { government_has_flag = government_is_tribal } } } - scope:recipient = { highest_held_title_tier >= tier_kingdom } + add = -20 } - add = { - value = -50 - if = { - limit = { - scope:recipient = { - OR = { - government_has_flag = government_is_republic - government_has_flag = government_is_theocracy - } - } + modifier = { # I am Nomadic and you are Nomadic + desc = interaction_is_nomadic + trigger = { + scope:recipient = { + government_has_flag = government_is_nomadic } - add = -50 - } - if = { - limit = { - scope:recipient.sub_realm_size >= 10 - } - add = -50 - } - if = { - limit = { - scope:recipient.sub_realm_size >= 20 - } - add = -100 - } - if = { - limit = { - scope:recipient = { highest_held_title_tier = tier_empire } - } - multiply = 1.5 # We bump this up for emperors - } - } - } - modifier = { #We just fought against each other. - desc = offer_vassalization_interaction_aibehavior_recent_war_tt - trigger = { - scope:recipient = { - any_truce_holder = { - this = scope:actor + scope:actor = { + government_has_flag = government_is_nomadic } } - # Ensure the truce wasn't purchased and is indeed from a war - scope:actor = { - NOT = { - has_purchased_truce_with_char = { TARGET = scope:recipient } + add = -50 + } + modifier = { # I am Nomadic and you are not + desc = interaction_nomadic_vs_nonnomadic + trigger = { + scope:recipient = { + government_has_flag = government_is_nomadic + } + scope:actor = { + NOT = { government_has_flag = government_is_nomadic } } } - scope:recipient = { - NOT = { - has_purchased_truce_with_char = { TARGET = scope:actor } + add = -75 + } + modifier = { # You are Nomadic and I am not + desc = interaction_nonnomadic_vs_nomadic + trigger = { + scope:actor = { + government_has_flag = government_is_nomadic + } + scope:recipient = { + NOT = { government_has_flag = government_is_nomadic } } } + add = -75 } - add = -50 - } - modifier = { #I fought an independence war against you. - desc = offer_vassalization_interaction_aibehavior_independence_war_tt - trigger = { - scope:recipient = { - exists = var:independence_war_former_liege - var:independence_war_former_liege = scope:actor - } - } - add = -200 - } - modifier = { # I am Tribal and you are not - desc = interaction_tribal_vs_nontribal - trigger = { - scope:recipient = { - government_has_flag = government_is_tribal - } - scope:actor = { - NOT = { government_has_flag = government_is_tribal } - } - } - add = -20 - } - modifier = { # You are Tribal and I am not - desc = interaction_nontribal_vs_tribal - trigger = { - scope:actor = { - government_has_flag = government_is_tribal - } - scope:recipient = { - NOT = { government_has_flag = government_is_tribal } - } - } - add = -20 - } - modifier = { # I am Nomadic and you are Nomadic - desc = interaction_is_nomadic - trigger = { - scope:recipient = { - government_has_flag = government_is_nomadic - } - scope:actor = { - government_has_flag = government_is_nomadic - } - } - add = -50 - } - modifier = { # I am Nomadic and you are not - desc = interaction_nomadic_vs_nonnomadic - trigger = { - scope:recipient = { - government_has_flag = government_is_nomadic - } - scope:actor = { - NOT = { government_has_flag = government_is_nomadic } - } - } - add = -75 - } - modifier = { # You are Nomadic and I am not - desc = interaction_nonnomadic_vs_nomadic - trigger = { - scope:actor = { - government_has_flag = government_is_nomadic - } - scope:recipient = { - NOT = { government_has_flag = government_is_nomadic } - } - } - add = -75 - } - modifier = { # Isolationist tradition - desc = isolationist_reason - trigger = { - scope:actor.culture != scope:recipient.culture - scope:recipient.culture = { - has_cultural_tradition = tradition_isolationist - } - } - add = -20 - } - modifier = { #Bankrupt - desc = bankrupt_reason - trigger = { - scope:actor.gold <= -1 - } - add = -100 - } - modifier = { #Wide difference in rank - desc = offer_vassalization_interaction_aibehavior_widetitletier_tt - trigger = { - scope:actor = { - OR = { - NOT = { government_has_flag = government_is_celestial } - scope:recipient = { - NOT = { government_has_flag = government_is_celestial } - } - } - tier_difference = { - target = scope:recipient - value > 1 - } - } - } - add = 10 - } - modifier = { #Wide difference in rank (Celestial to Celestial) - desc = offer_vassalization_interaction_aibehavior_widetitletier_tt - trigger = { - scope:actor = { - government_has_flag = government_is_celestial - tier_difference = { - target = scope:recipient - value > 1 - } - } - scope:recipient = { - government_has_flag = government_is_celestial - } - } - add = { - value = 20 - multiply = { - value = scope:actor.highest_held_title_tier - subtract = scope:recipient.highest_held_title_tier - } - } - } - modifier = { # Is a Hegemon - desc = offer_vassalization_interaction_aibehavior_hegemony_tt - trigger = { - scope:actor = { highest_held_title_tier = tier_hegemony } - } - add = 10 - } - modifier = { # Allied - desc = offer_vassalization_interaction_aibehavior_allied_tt - trigger = { - scope:recipient = { - is_allied_to = scope:actor - } - } - add = 20 - } - modifier = { # Is the Rightful Liege of recipient - desc = offer_vassalization_interaction_aibehavior_rightfulliegetitleholder_tt - trigger = { - scope:actor = { is_rightful_liege_of = scope:recipient } - } - add = 20 - } - modifier = { #Is not the Rightful Liege of recipient - desc = offer_vassalization_interaction_aibehavior_not_rightfulliegetitleholder_tt - trigger = { - NOT = { - scope:actor = { is_rightful_liege_of = scope:recipient } - } - } - add = -20 - } - modifier = { # Encircled - desc = offer_vassalization_interaction_aibehavior_encircled_tt - trigger = { - scope:recipient = { - NOT = { - any_neighboring_top_liege_realm_owner = { - this != scope:actor - } - } - NOT = { - any_realm_county = { - is_coastal_county = yes - } - } - } - } - add = 20 - } - modifier = { #Distant Realm — Overseas Connection - desc = offer_vassalization_interaction_aibehavior_distantrealm_tt - trigger = { - scope:actor = { - character_is_realm_neighbor = scope:recipient - NOT = { #Ibiza should want to be a vassal of Mallorca, etc. - character_is_land_realm_neighbor = scope:recipient - scope:actor = { is_rightful_liege_of = scope:recipient } - } - } - } - add = -100 - } - modifier = { #Distant Realm — No Connection - desc = offer_vassalization_interaction_aibehavior_distantrealm_tt - trigger = { - scope:actor = { - NOT = { - character_is_realm_neighbor = scope:recipient - } - } - scope:recipient = { - # landless ruler count as within realm - trigger_if = { - limit = { is_landed = no } - NOT = { capital_county.holder = { target_is_same_character_or_above = scope:actor } } - } - capital_province = { squared_distance = { target = scope:actor.capital_province value < 200000 } } - } - } - add = -250 - } - modifier = { #Remote Realm. - desc = offer_vassalization_interaction_aibehavior_remoterealm_tt - trigger = { - scope:actor = { - NOT = { - character_is_realm_neighbor = scope:recipient - } - } - scope:recipient = { - # landless ruler count as within realm - trigger_if = { - limit = { is_landed = no } - NOT = { capital_county.holder = { target_is_same_character_or_above = scope:actor } } - } - capital_province = { squared_distance = { target = scope:actor.capital_province value >= 200000 } } - } - } - add = -500 - } + modifier = { #Military Strength desc = offer_vassalization_interaction_aibehavior_power_tt add = { @@ -692,339 +260,75 @@ offer_vassalization_interaction = { ceiling = yes } } - modifier = { #Vassal opinion - desc = offer_vassalization_interaction_aibehavior_vassal_opinion_tt - trigger = { - scope:actor = { number_of_powerful_vassals >= 1 } - } - add = { - value = 0 - scope:actor = { - every_powerful_vassal = { - if = { - limit = { - save_temporary_opinion_value_as = { - name = vassal_opinion - target = scope:actor - } - } - add = scope:vassal_opinion - } - } - - if = { - limit = { - number_of_powerful_vassals > 0 - } - divide = number_of_powerful_vassals - } - else = { - divide = 5 - } - } - - divide = 5 - } - } - - # MINOR - modifier = { #Friend modifier. - desc = offer_vassalization_interaction_aibehavior_friend_tt - trigger = { - scope:recipient = { - has_relation_friend = scope:actor - NOT = { has_relation_best_friend = scope:actor } - } - } - add = 10 - } - modifier = { #Best Friend modifier. - desc = offer_vassalization_interaction_aibehavior_best_friend_tt - trigger = { - scope:recipient = { - has_relation_best_friend = scope:actor - } - } - add = 20 - } - modifier = { #Lover modifier. - desc = interaction_lover - trigger = { - scope:recipient = { - has_relation_lover = scope:actor - NOT = { has_relation_soulmate = scope:actor } - } - } - add = 10 - } - modifier = { #Soulmate modifier. - desc = interaction_soulmate - trigger = { - scope:recipient = { - has_relation_soulmate = scope:actor - } - } - add = 20 - } - modifier = { #Rivalry modifier. - desc = offer_vassalization_interaction_aibehavior_rival_tt - trigger = { - scope:recipient = { - has_relation_rival = scope:actor - NOT = { has_relation_nemesis = scope:actor } - } - } - add = -100 - } - modifier = { #Nemesis modifier. - desc = offer_vassalization_interaction_aibehavior_nemesis_tt - trigger = { - scope:recipient = { - has_relation_nemesis = scope:actor - } - } - add = -1000 - } - modifier = { #Same Dynasty modifier. - desc = offer_vassalization_interaction_aibehavior_dynasty_tt - trigger = { - scope:recipient = { - dynasty = scope:actor.dynasty - } - } - add = 5 - } - - modifier = { # Same language - add = 5 - desc = speaks_same_language_interaction_reason - trigger = { - scope:actor = { - knows_language_of_culture = scope:recipient.culture - } - } - } - -# modifier = { # Iberian Struggle, less likely for outsiders to vassalize inside -# add = -35 -# desc = iberian_struggle_reason_reason -# trigger = { -# scope:actor = { -# NOT = { -# any_character_struggle = { is_struggle_type = iberian_struggle } -# } -# } -# scope:recipient = { -# any_character_struggle = { is_struggle_type = iberian_struggle } -# } -# } -# } -# - modifier = { #Ageism modifier vs kids. - desc = offer_vassalization_interaction_aibehavior_child_tt - trigger = { - scope:actor = { - age < 12 - } - scope:recipient = { - age > 16 - } - } - add = -5 - } - modifier = { #Illegitimacy modifier. - desc = offer_vassalization_interaction_aibehavior_illegitimate_tt - trigger = { - scope:actor = { - OR = { - AND = { - has_trait = bastard - scope:recipient = { - faith = { NOT = { has_doctrine = doctrine_bastardry_none } } - } - } - has_trait = denounced - has_trait = disinherited - } - } - } - add = -10 - } - - modifier = { #Claimant modifier. - desc = offer_vassalization_interaction_aibehavior_claimant_tt - trigger = { - scope:actor.primary_title = { + # TRAITS/PERSONALITY + modifier = { # Ambitious + desc = TAKE_THE_VOWS_AMBITIOUS + trigger = { scope:recipient = { - has_claim_on = prev + has_trait = ambitious } } + add = -20 } - add = -20 - } - - modifier = { # Ambitious - desc = TAKE_THE_VOWS_AMBITIOUS - trigger = { - scope:recipient = { - has_trait = ambitious - } - } - add = -20 - } - - modifier = { # Paranoid - desc = INTERACTION_PARANOID - trigger = { - scope:recipient = { - has_trait = paranoid - } - } - add = -20 - } - - modifier = { # Arrogant - desc = INTERACTION_ARROGANT - trigger = { - scope:recipient = { - has_trait = arrogant - } - } - add = -20 - } - - modifier = { # Fickle - desc = INTERACTION_FICKLE - trigger = { - scope:recipient = { - has_trait = fickle - } - } - add = -10 - } - - modifier = { # Stubborn - desc = INTERACTION_STUBBORN - trigger = { - scope:recipient = { - has_trait = stubborn - } - } - add = -10 - } - - modifier = { # Trusting - desc = TAKE_THE_VOWS_TRUSTING - trigger = { - scope:recipient = { - has_trait = trusting - } - } - add = 5 - } - - modifier = { # Content - desc = INTERACTION_CONTENT - trigger = { - scope:recipient = { - has_trait = content - } - } - add = 5 - } -# -# modifier = { # FP3 modifier. -# desc = GENERIC_YOUR_PIETY_LEVEL_MODIFIER -# trigger = { scope:actor = { any_character_struggle = { has_struggle_phase_parameter = piety_level_affects_vassalage_acceptance } } } -# add = { -# value = { -# value = scope:actor.piety_level -# subtract = low_piety_level -# } -# multiply = 10 -# } -# } - - # OPINION INFLUENCE - modifier = { - add = intimidated_external_reason_value - scope:recipient = { - has_dread_level_towards = { - target = scope:actor - level = 1 - } - } - desc = INTIMIDATED_REASON - } - modifier = { - add = cowed_external_reason_value - scope:recipient = { - has_dread_level_towards = { - target = scope:actor - level = 2 - } - } - desc = COWED_REASON - } - opinion_modifier = { #Compare Opinion modifier - Clans care more about opinion - trigger = { - scope:actor = { - government_has_flag = government_is_clan - } - scope:recipient = { - government_has_flag = government_is_clan - } - } - who = scope:recipient - opinion_target = scope:actor - multiplier = 0.7 - } - opinion_modifier = { #Compare Opinion modifier. - trigger = { - NOT = { - scope:actor = { government_has_flag = government_is_mandala } #Has their own Opinion modifier - } - OR = { - scope:actor = { - NOT = { government_has_flag = government_is_clan } - } + modifier = { # Paranoid + desc = INTERACTION_PARANOID + trigger = { scope:recipient = { - NOT = { government_has_flag = government_is_clan } + has_trait = paranoid } } + add = -20 + } + modifier = { # Arrogant + desc = INTERACTION_ARROGANT + trigger = { + scope:recipient = { + has_trait = arrogant + } + } + add = -20 } - who = scope:recipient - opinion_target = scope:actor - multiplier = 0.35 - } - # DIPLOMATIC COURT GRANDEUR BONUS - modifier = { - trigger = { - scope:actor = { - has_royal_court = yes - has_dlc_feature = royal_court - has_court_type = court_diplomatic - court_grandeur_current_level >= 1 - } - } - add = { - value = scope:actor.court_grandeur_current - if = { - limit = { # Reduce the bonus if you are below your expected level - scope:actor = { - court_grandeur_current_level < court_grandeur_minimum_expected_level - } + modifier = { # Fickle + desc = INTERACTION_FICKLE + trigger = { + scope:recipient = { + has_trait = fickle } - multiply = 0.15 - } - else = { - multiply = 0.3 } + add = -10 + } + + modifier = { # Stubborn + desc = INTERACTION_STUBBORN + trigger = { + scope:recipient = { + has_trait = stubborn + } + } + add = -10 + } + + modifier = { # Trusting + desc = TAKE_THE_VOWS_TRUSTING + trigger = { + scope:recipient = { + has_trait = trusting + } + } + add = 5 + } + + modifier = { # Content + desc = INTERACTION_CONTENT + trigger = { + scope:recipient = { + has_trait = content + } + } + add = 5 } - desc = DIPLOMATIC_COURT_ACCEPTANCE_INCREASE_REASON - } # CONTRACT OPTIONS modifier = { @@ -1052,143 +356,6 @@ offer_vassalization_interaction = { desc = CONTRACT_HIGH_TAXES_REASON } - # INSPECTION BONUSES - modifier = { - desc = "INSPECTION_REASON" - add = 5 - scope:recipient = { - has_variable_list = lesser_inspection_bonus - is_target_in_variable_list = { - name = lesser_inspection_bonus - target = scope:actor - } - } - } - modifier = { - desc = "INSPECTION_REASON" - add = 10 - scope:recipient = { - has_variable_list = inspection_bonus - is_target_in_variable_list = { - name = inspection_bonus - target = scope:actor - } - } - } - modifier = { - desc = "INSPECTION_REASON_REWARD" - add = 10 - scope:recipient = { - has_variable_list = inspection_reward - is_target_in_variable_list = { - name = inspection_reward - target = scope:actor - } - } - } - modifier = { - desc = "INSPECTION_REASON_REWARD_FOCUSED" - add = 10 - scope:actor = { has_character_modifier = inspection_reward_focused_vassal_acceptance } - } - - # LOW LEGITIMACY - modifier = { - desc = "LOW_LEGITIMACY_REASON" - add = -25 - scope:actor = { - has_legitimacy_flag = reduced_vassalization_acceptance - } - } - modifier = { - desc = "LOW_LEGITIMACY_REASON" - add = -50 - scope:actor = { - has_legitimacy_flag = very_reduced_vassalization_acceptance - } - } - modifier = { - desc = "LOW_LEGITIMACY_REASON" - add = -75 - scope:actor = { - has_legitimacy_flag = massively_reduced_vassalization_acceptance - } - } - - # HIGH LEGITIMACY - modifier = { - desc = "HIGH_LEGITIMACY_REASON" - add = 25 - scope:actor = { - has_legitimacy_flag = increased_vassalization_acceptance - } - } - modifier = { - desc = "HIGH_LEGITIMACY_REASON" - add = 50 - scope:actor = { - has_legitimacy_flag = very_increased_vassalization_acceptance - } - } - modifier = { - desc = "HIGH_LEGITIMACY_REASON" - add = 75 - scope:actor = { - has_legitimacy_flag = extra_increased_vassalization_acceptance - } - } - - # INFLUENCE - modifier = { - add = 25 - scope:influence_send_option = yes - desc = INFLUENCE_INTERACTION_ACCEPTANCE_SEND_OPTION - } - - #HISTORICALLY ADMIN PEOPLES WANT TO BE ADMIN -# modifier = { -# add = 30 -# scope:actor = { -# government_has_flag = government_is_administrative -# } -# scope:recipient = { -# culture = { -# OR = { -# this = culture:greek -# any_parent_culture_or_above = { -# this = culture:greek -# } -# this = culture:han -# any_parent_culture_or_above = { -# this = culture:han -# } -# } -# } -# } -# -# desc = "HISTORICAL_ADMIN_REASON" -# } - - modifier = { # AI-only weights, keep the pope from vassalizing too fast - trigger = { - exists = faith:roman_catholic.religious_head - faith:roman_catholic.religious_head = scope:actor - scope:actor = { is_ai = yes } - } - add = -50 - } - - modifier = { - scope:actor = { - has_variable = severed_head_vassalization - var:severed_head_vassalization = { - this = scope:recipient - } - } - add = 200 - desc = COWED_BY_SEVERED_HEAD_MODIFIER - } - #ALL these modifiers are also used in impress_intent_vassalization_acceptance_value, keep them synced #Mandala @@ -1251,7 +418,7 @@ offer_vassalization_interaction = { } flag = normal_obligations # If selected then scope:flag_name will be set to yes localization = normal_obligations # Loc_key for option label - starts_enabled = { always = yes } # Trigger for whether this should be on when the window opens. If not defined, defaults to off + starts_enabled = { always = yes } # Trigger for whether this should be on when the window opens. If not defined, defaults to off } @@ -1320,6 +487,21 @@ offer_vassalization_interaction = { flag = influence_send_option localization = TRADE_INFLUENCE_FOR_BETTER_AI_ACCEPTANCE } + send_option = { # EP3 Influence - give you an option doesn't cost influence when there's nothing to pick + is_shown = { + scope:actor = { + government_has_flag = government_has_influence + } + scope:recipient = { + NOR = { + government_has_flag = government_is_feudal + government_has_flag = government_is_clan + } + } + } + flag = offer_nothing + localization = offer_nothing + } send_options_exclusive = yes @@ -1347,13 +529,6 @@ offer_vassalization_interaction = { } } - ai_potential = { - is_adult = yes - top_liege = this - highest_held_title_tier > tier_county - vassal_limit_available > 1 - } - ai_will_do = { base = 100 @@ -1395,32 +570,20 @@ offer_fealty_interaction = { desc = offer_fealty_interaction_desc + is_available = { + is_landed = yes + top_liege ?= this # You have to be independent - This check exists to prevent a lot of edge-cases where you can change liege + is_confederation_member = no + NOT = { government_has_flag = cannot_be_vassal_or_liege } + } + is_shown = { scope:recipient = { this != scope:actor is_landed = yes - top_liege = this # Target has to be independent + top_liege ?= this # Target has to be independent } scope:actor.highest_held_title_tier < scope:recipient.highest_held_title_tier - scope:actor = { - OR = { - is_landed = yes - AND = { - government_has_flag = government_is_landless_minority - scope:recipient = { - any_held_title = { - title_tier = county - any_county_province = { - this = scope:actor.domicile.domicile_location - } - } - } - } - } - top_liege = this # You have to be independent - This check exists to prevent a lot of edge-cases where you can change liege - NOT = { government_has_flag = cannot_be_vassal_or_liege } - is_confederation_member = no - } } is_valid_showing_failures_only = { @@ -1478,7 +641,7 @@ offer_fealty_interaction = { scope:actor = { NOR = { # Of two different faiths AND the potential vassal's faith is not pluralistic. faith = scope:recipient.faith - faith = { has_doctrine = doctrine_pluralism_pluralistic } + rite = { rite_has_doctrine = doctrine_pluralism_pluralistic } } } } @@ -1731,6 +894,26 @@ offer_fealty_interaction = { } } } + #Just refused to be transferred to me + modifier = { + add = -75 + desc = refused_transfer_reason + scope:actor = { + var:refused_transfer_target ?= { + this = scope:recipient + } + } + } + #I promised church to stop being your liege + modifier = { + add = -200 + desc = refused_transfer_liege_reason + scope:actor = { + var:refused_transfer_liege ?= { + this = scope:recipient + } + } + } } # Low starting obligations @@ -1753,7 +936,7 @@ offer_fealty_interaction = { } flag = normal_obligations localization = normal_obligations - starts_enabled = { always = yes } + starts_enabled = { always = yes } } @@ -1819,8 +1002,8 @@ offer_fealty_interaction = { trigger_event = char_interaction.0010 if = { limit = { - government_has_flag = government_is_administrative - scope:recipient = { NOT = { government_has_flag = government_is_administrative } } + government_has_mechanic = administrative + scope:recipient = { NOT = { government_has_mechanic = administrative } } } custom_tooltip = will_change_from_administrative_tt custom_tooltip = will_lose_administrative_government_type_tt @@ -1983,6 +1166,15 @@ set_primary_spouse_interaction = { auto_accept = yes + is_available = { + trigger_if = { + limit = { is_ai = yes } + any_spouse = { + count >= 2 + } + } + } + is_shown = { scope:actor = { is_spouse_of = scope:recipient @@ -2117,12 +1309,6 @@ set_primary_spouse_interaction = { hegemony = 72 } - ai_potential = { - any_spouse = { - count >= 2 - } - } - ai_will_do = { base = 0 @@ -2153,71 +1339,64 @@ grant_independence_interaction = { desc = grant_independence_interaction_desc is_shown = { - scope:actor = { + scope:puppet_or_actor ?= { trigger_if = { limit = { is_confederation_member = yes } exists = house.house_confederation } } scope:recipient = { - is_vassal_of = scope:actor - OR = { - is_landed = yes - AND = { - government_has_flag = government_is_landless_minority - } - } + is_vassal_of = scope:puppet_or_actor + is_landed = yes } - scope:recipient != scope:actor + scope:recipient != scope:puppet_or_actor } is_valid_showing_failures_only = { - NOT = { scope:actor = { is_at_war_with = scope:recipient } } - scope:actor = { + NOT = { scope:puppet_or_actor = { is_at_war_with = scope:recipient } } + scope:puppet_or_actor = { top_liege = this - NOT = { - is_at_war = yes - } - } - custom_description = { - text = is_at_war_with_another_vassal - object = scope:recipient - NOT = { - scope:actor = { - any_vassal_or_below = { - is_at_war_with = scope:recipient - } - } - } - } - custom_description = { - text = is_de_jure_vassal_check - object = scope:recipient - - trigger_if = { # Admin rulers can grant tribal vassals independence regardless of de jure - limit = { - scope:actor = { government_has_flag = government_is_administrative } - scope:recipient = { government_has_flag = government_is_tribal } - } - # Always possible - } - trigger_else = { - NOT = { #Cannot be used against de jure vassals - scope:recipient.primary_title = { - any_this_title_or_de_jure_above = { - holder = scope:actor + is_at_war = no + custom_description = { + text = is_at_war_with_another_vassal + object = scope:recipient + NOT = { + scope:puppet_or_actor = { + any_vassal_or_below = { + is_at_war_with = scope:recipient } } } } + custom_description = { + text = is_de_jure_vassal_check + object = scope:recipient - } - custom_tooltip = { - text = can_only_remove_diarch_by_elevating_them.tt - NOT = { scope:recipient ?= scope:actor.diarch } + trigger_if = { # Admin rulers can grant tribal vassals independence regardless of de jure + limit = { + scope:puppet_or_actor = { government_has_mechanic = administrative } + scope:recipient = { government_has_flag = government_is_tribal } + } + # Always possible + } + trigger_else = { + NOT = { #Cannot be used against de jure vassals + scope:recipient.primary_title = { + any_this_title_or_de_jure_above = { + holder = scope:puppet_or_actor + } + } + } + } + + } + custom_tooltip = { + text = can_only_remove_diarch_by_elevating_them.tt + NOT = { scope:recipient ?= scope:puppet_or_actor.diarch } + } } tgp_blocked_action_against_tenno_trigger = { - ACTOR = scope:actor + ACTOR = scope:puppet_or_actor TARGET = scope:recipient } } @@ -2225,8 +1404,18 @@ grant_independence_interaction = { auto_accept = yes on_accept = { - scope:actor = { - stress_impact = { + if = { # The puppet action cooldown is paced on the puppeteer, so it is shared across all their puppets + limit = { + exists = scope:is_puppet_action + scope:is_puppet_action = yes + } + scope:actor = { + add_character_flag = { flag = pam_puppet_grant_independence_cooldown years = 5 } + } + } + + scope:puppet_or_actor = { + stress_and_fulfillment_impact = { ambitious = medium_stress_impact_gain arrogant = minor_stress_impact_gain greedy = minor_stress_impact_gain @@ -2262,19 +1451,37 @@ grant_independence_interaction = { } } + hidden_effect = { + if = { + limit = { + scope:is_puppet_action ?= yes + } + scope:actor = { + send_interface_toast = { + type = event_toast_effect_neutral + title = grant_vassal_independence_interaction_toast + left_icon = scope:puppet_or_actor + right_icon = scope:recipient + + custom_tooltip = grant_vassal_independence_interaction_toast_desc + } + } + } + } + scope:recipient = { #Send notifications if = { limit = { any_liege_or_above = { is_ai = no - this != scope:actor + this != scope:puppet_or_actor } } every_liege_or_above = { limit = { is_ai = no - this != scope:actor + this != scope:puppet_or_actor } trigger_event = vassal_interaction.0023 } @@ -2286,7 +1493,7 @@ grant_independence_interaction = { is_ai = no NOR = { this = scope:recipient - this = scope:actor + this = scope:puppet_or_actor } } } @@ -2297,7 +1504,7 @@ grant_independence_interaction = { is_ai = no NOR = { this = scope:recipient - this = scope:actor + this = scope:puppet_or_actor } } } @@ -2315,12 +1522,12 @@ grant_independence_interaction = { } add_opinion = { - target = scope:actor + target = scope:puppet_or_actor modifier = granted_independence_opinion } add_truce_both_ways = { - character = scope:actor + character = scope:puppet_or_actor days = 3650 name = TRUCE_GRANT_INDEPENDENCE } @@ -2337,12 +1544,12 @@ grant_independence_interaction = { resolve_title_and_vassal_change = scope:change } -# # Struggle Catalysts. -# scope:actor = { + # Struggle Catalysts. +# scope:puppet_or_actor = { # if = { # limit = { # catalyst_gave_independence_to_powerful_diff_faith_culture_vassal_preliminary_trigger = { -# CHAR1 = scope:actor +# CHAR1 = scope:puppet_or_actor # CHAR2 = scope:recipient # } # any_character_struggle = { @@ -2363,7 +1570,7 @@ grant_independence_interaction = { # } # activate_struggle_catalyst = { # catalyst = catalyst_gave_independence_to_powerful_diff_faith_culture_vassal -# character = scope:actor +# character = scope:puppet_or_actor # } # } # } @@ -2393,7 +1600,7 @@ grant_independence_interaction = { # } # activate_struggle_catalyst = { # catalyst = catalyst_independence_from_non_dejure_vassal -# character = scope:actor +# character = scope:puppet_or_actor # } # } # } @@ -2404,7 +1611,7 @@ grant_independence_interaction = { # If we're a clan this interaction affects unity add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = medium_unity_loss DESC = clan_unity_grant_independence.desc @@ -2416,27 +1623,27 @@ grant_independence_interaction = { base = 0 #The AI should never do this! # Except in the context of Struggle - modifier = { - scope:recipient = { - any_character_struggle = { - involvement = involved - } - } - scope:actor = { - any_character_struggle = { - involvement = involved - } - NOT = { - any_held_title = { - is_de_jure_liege_or_above_target = scope:recipient.primary_title - } - } - } +# modifier = { +# scope:recipient = { +# any_character_struggle = { +# involvement = involved +# } +# } +# scope:puppet_or_actor = { +# any_character_struggle = { +# involvement = involved +# } +# NOT = { +# any_held_title = { +# is_de_jure_liege_or_above_target = scope:recipient.primary_title +# } +# } +# } # add = { # value = 0 # if = { # limit = { -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # phase_has_catalyst = catalyst_independence_from_non_dejure_vassal # } @@ -2447,7 +1654,7 @@ grant_independence_interaction = { # } # else_if = { # limit = { -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # phase_has_catalyst = catalyst_independence_from_non_dejure_vassal # } @@ -2456,7 +1663,7 @@ grant_independence_interaction = { # add = 100 # } # } - } +# } # Unity modifiers evaluate_action_decreasing_house_unity = { @@ -2475,11 +1682,12 @@ expose_secret_interaction = { desc = expose_secret_interaction_desc is_shown = { + exists = scope:puppet_or_actor scope:recipient = { any_secret = { - is_known_by = scope:actor + is_known_by = scope:puppet_or_actor } - this != scope:actor + this != scope:puppet_or_actor age > 10 } } @@ -2488,7 +1696,7 @@ expose_secret_interaction = { } on_accept = { - scope:actor = { + scope:puppet_or_actor = { if = { limit = { is_landless_adventurer = yes @@ -2508,7 +1716,7 @@ expose_secret_interaction = { exists = scope:target } scope:target = { - expose_secret = scope:actor + expose_secret = scope:puppet_or_actor } } else = { @@ -2516,7 +1724,7 @@ expose_secret_interaction = { limit = { secret_owner = scope:recipient } - expose_secret = scope:actor + expose_secret = scope:puppet_or_actor } } # if = { @@ -2557,21 +1765,27 @@ expose_secret_interaction = { # } # trigger_situation_catalyst = { # catalyst = catalyst_minister_exposed_secret -# character = scope:actor +# character = scope:puppet_or_actor # } # } # } # } - - stress_impact = { - honest = minor_stress_impact_loss - just = minor_stress_impact_loss - shy = miniscule_stress_impact_gain + # Only get stressed/SP penalties if you don't have the parameter + if = { + limit = { + NOT = { sp_hostile_schemes_except_murder_no_stress_or_fulfillment_trigger = yes } + } + stress_and_fulfillment_impact = { + honest = minor_stress_impact_loss + just = minor_stress_impact_loss + shy = miniscule_stress_impact_gain + } } } + # recipient gets the penalties even if they have the parameter scope:recipient = { - stress_impact = { + stress_and_fulfillment_impact = { honest = minor_stress_impact_loss just = minor_stress_impact_loss deceitful = minor_stress_impact_gain @@ -2580,7 +1794,7 @@ expose_secret_interaction = { # If we're a clan this interaction affects unity add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = major_unity_loss DESC = clan_unity_secret_exposure.desc @@ -2594,23 +1808,23 @@ expose_secret_interaction = { base = 0 # Struggle - modifier = { - scope:recipient = { - any_character_struggle = { - involvement = involved - } - is_important_or_vip_struggle_character = yes - } - scope:actor = { - any_character_struggle = { - involvement = involved - } - } - add = { - value = 0 +# modifier = { +# scope:recipient = { +# any_character_struggle = { +# involvement = involved +# } +# is_important_or_vip_struggle_character = yes +# } +# scope:puppet_or_actor = { +# any_character_struggle = { +# involvement = involved +# } +# } +# add = { +# value = 0 # if = { # limit = { -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # phase_has_catalyst = catalyst_reveal_secret_important # } @@ -2621,7 +1835,7 @@ expose_secret_interaction = { # } # else_if = { # limit = { -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # phase_has_catalyst = catalyst_reveal_secret_important # } @@ -2629,25 +1843,25 @@ expose_secret_interaction = { # } # add = -100 # } - } - } - modifier = { - scope:recipient = { - any_character_struggle = { - involvement = involved - } - has_trait = fp3_struggle_supporter - } - scope:actor = { - any_character_struggle = { - involvement = involved - } - } - add = { - value = 0 +# } +# } +# modifier = { +# scope:recipient = { +# any_character_struggle = { +# involvement = involved +# } +# has_trait = fp3_struggle_supporter +# } +# scope:puppet_or_actor = { +# any_character_struggle = { +# involvement = involved +# } +# } +# add = { +# value = 0 # if = { # limit = { -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # phase_has_catalyst = catalyst_reveal_secret_supporter # } @@ -2658,7 +1872,7 @@ expose_secret_interaction = { # } # else_if = { # limit = { -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # phase_has_catalyst = catalyst_reveal_secret_supporter # } @@ -2666,8 +1880,8 @@ expose_secret_interaction = { # } # add = -100 # } - } - } +# } +# } # modifier = { # scope:recipient = { # any_character_struggle = { @@ -2675,7 +1889,7 @@ expose_secret_interaction = { # } # has_trait = fp3_struggle_detractor # } -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # involvement = involved # } @@ -2684,7 +1898,7 @@ expose_secret_interaction = { # value = 0 # if = { # limit = { -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # phase_has_catalyst = catalyst_reveal_secret_detractor # } @@ -2695,7 +1909,7 @@ expose_secret_interaction = { # } # else_if = { # limit = { -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # phase_has_catalyst = catalyst_reveal_secret_detractor # } @@ -2712,3 +1926,5 @@ expose_secret_interaction = { } } } + + diff --git a/common/character_interactions/00_courtier_and_guest_interactions.txt b/common/character_interactions/00_courtier_and_guest_interactions.txt index c03c3a67e..595ffdfb3 100644 --- a/common/character_interactions/00_courtier_and_guest_interactions.txt +++ b/common/character_interactions/00_courtier_and_guest_interactions.txt @@ -13,12 +13,24 @@ } extra_icon = "gfx/interface/icons/character_interactions/hook_icon.dds" + is_available = { + trigger_if = { + limit = { is_ai = yes } + short_term_gold >= yearly_character_income + is_at_war = no # Try to avoid wasting your war chest! + ai_should_focus_on_building_in_their_capital = no + NOT = { government_has_flag = government_is_nomadic } + any_courtier_or_guest = { + is_alive = yes + count <= 30 + } + NOT = { has_variable = conqueror } + } + } + is_shown = { scope:actor != scope:recipient scope:recipient = { is_pool_guest_of = scope:actor } - scope:actor = { - is_ruler = yes - } } is_valid_showing_failures_only = { @@ -30,6 +42,8 @@ NOR = { scope:recipient = { is_close_family_of = scope:actor } # Close family members are free scope:actor = { has_usable_hook = scope:recipient } # Using a hook makes it free + # PAM - Ritual Hospitality PT: hospitality is never bought + scope:actor = { has_personal_tenet_flag = tenet_ritual_hospitality_free_guest_recruitment } } } scope:actor = { @@ -92,6 +106,11 @@ limit = { scope:recipient = { is_close_family_of = scope:actor } } # Close family members are free # do nothing } + else_if = { + # PAM - Ritual Hospitality PT: hospitality is never bought + limit = { scope:actor = { has_personal_tenet_flag = tenet_ritual_hospitality_free_guest_recruitment } } + # do nothing + } else_if = { limit = { always = scope:hook } scope:actor = { use_hook = scope:recipient } @@ -129,7 +148,7 @@ type = event_generic_neutral title = msg_recruited_guest_to_court_interaction_title right_icon = scope:recipient - stress_impact = { + stress_and_fulfillment_impact = { shy = minor_stress_impact_gain paranoid = minor_stress_impact_gain } @@ -164,18 +183,6 @@ hegemony = 12 } - ai_potential = { - is_at_war = no # Try to avoid wasting your war chest! - NOT = { has_variable = conqueror } - short_term_gold >= yearly_character_income - any_courtier_or_guest = { - is_alive = yes - count <= 30 - } - ai_should_focus_on_building_in_their_capital = no - NOT = { government_has_flag = government_is_nomadic } - } - ai_will_do = { base = 0 @@ -435,7 +442,7 @@ kick_from_court_interaction = { on_accept = { scope:actor = { - stress_impact = { + stress_and_fulfillment_impact = { gregarious = minor_stress_impact_gain } @@ -597,7 +604,7 @@ invite_to_court_interaction = { host ?= scope:actor has_trait = order_member is_ruler = yes - location = { is_sea_province = yes } + location ?= { is_sea_province = yes } } } } @@ -627,6 +634,33 @@ invite_to_court_interaction = { } text = nomad_defected_invite_desc } + custom_tooltip = { + scope:recipient = { + NAND = { + OR = { + has_trait = devoted + has_trait = order_member + } + liege ?= { + government_has_flag = government_is_holy_order + } + has_variable = recent_vows + } + } + text = recently_joined_holy_order_desc + } + custom_tooltip = { + scope:recipient = { + NAND = { + has_trait = devoted + liege ?= { + government_has_flag = government_is_holy_order + } + is_adult = no + } + } + text = child_in_holy_order_desc + } } #Pay som gold to persuade a wandering character to come to your court @@ -742,7 +776,7 @@ invite_to_court_interaction = { } target = scope:recipient } - stress_impact = { + stress_and_fulfillment_impact = { greedy = minor_stress_impact_gain } } @@ -1166,20 +1200,43 @@ invite_to_court_interaction = { desc = estate_buildings_with_value_desc } + # PAM - Ritual Hospitality PT + modifier = { + add = 50 + desc = doctrine_parameter_tenet_ritual_hospitality_invite_to_court_acceptance + scope:actor = { + has_personal_tenet_flag = tenet_ritual_hospitality_invite_to_court_acceptance + } + } + modifier = { add = -1000 desc = MALUS_TO_RECRUITMENT_FOR_IMPERIAL_EUNUCHS scope:recipient = { is_eunuch_trigger = yes liege ?= { - government_allows = administrative + government_has_mechanic = administrative primary_title.tier >= tier_empire culture = { has_cultural_parameter = can_appoint_chief_eunuch } } } } - + modifier = { + add = -100 + desc = INVITE_DEVOTED_TO_CLERICAL_LIEGE + scope:recipient = { + has_trait = devoted + liege ?= { + OR = { + government_has_flag = government_is_theocracy + government_has_flag = government_is_monastic_holy_order + } + faith = scope:recipient.faith + } + } + } + modifier = { scope:actor.culture = { has_cultural_parameter = invite_courtiers_reasons @@ -1208,3 +1265,4 @@ invite_to_court_interaction = { } } } + diff --git a/common/character_interactions/00_culture_interactions.txt b/common/character_interactions/00_culture_interactions.txt index e64ec67e9..41b4be10b 100644 --- a/common/character_interactions/00_culture_interactions.txt +++ b/common/character_interactions/00_culture_interactions.txt @@ -19,8 +19,7 @@ request_culture_conversion_interaction = { is_shown = { scope:actor.culture != scope:recipient.culture - scope:recipient.liege = scope:actor - NOT = { scope:recipient = { government_has_flag = government_is_landless_minority } } + scope:recipient.liege ?= scope:actor } is_valid_showing_failures_only = { @@ -113,24 +112,19 @@ ai_cultural_hybridization_interaction = { auto_accept = yes - ai_potential = { - has_dlc_feature = hybridize_culture + is_available = { + sub_realm_size >= 4 OR = { - top_liege = this + top_liege ?= this highest_held_title_tier >= tier_kingdom } - sub_realm_size >= 4 - is_physically_able_adult = yes is_at_war = no + is_physically_able_adult = yes game_rule_can_create_hybird_culture_trigger = yes + has_dlc_feature = hybridize_culture + is_ai = yes } - is_shown = { - scope:actor = { - is_ai = yes - } - } - has_valid_target = { exists = scope:target } diff --git a/common/character_interactions/00_diarch_interactions.txt b/common/character_interactions/00_diarch_interactions.txt index 5a742e053..05e756c48 100644 --- a/common/character_interactions/00_diarch_interactions.txt +++ b/common/character_interactions/00_diarch_interactions.txt @@ -74,30 +74,37 @@ diarch_revoke_title_interaction = { on_decline_summary = diarch_rebel_or_crime_summary prompt = RETRACT_VASSAL_SELECT_VASSAL_TO_RETRACT + is_available = { + trigger_if = { + limit = { is_ai = yes } + is_diarch = yes + liege ?= { has_realm_law_flag = title_revocation_allowed } + # Loyal diarchs don't engage in skullduggery. + diarch_loyalty < diarch_loyalty_visibly_loyal_threshold + } + liege ?= { + has_diarchy_parameter = unlock_diarch_revoke_title_interaction + } + # If you're not in a diarchy, we don't care. + OR = { + is_designated_diarch = yes + AND = { + is_diarch_of_target = liege + exists = liege + } + } + } + is_shown = { # The obvious. scope:actor != scope:recipient - # Diarchy checks for scope:actor. - scope:actor = { - # If you're not in a diarchy, we don't care. - OR = { - AND = { - exists = liege - is_diarch_of_target = liege - } - is_designated_diarch = yes - } - liege = { - has_diarchy_parameter = unlock_diarch_revoke_title_interaction - } - } # Make sure scope:recipient is suitable. scope:recipient = { # We only target vassals of the liege... - liege = scope:actor.liege + liege ?= scope:actor.liege this != scope:actor.liege # ... who are appropriately landed. - is_landed_or_landless_administrative = yes + is_landed_or_landless_administrative_or_theocratic = yes scope:recipient.highest_held_title_tier >= tier_county } } @@ -121,7 +128,7 @@ diarch_revoke_title_interaction = { } } trigger_else_if = { - limit = { government_has_flag = government_is_administrative } + limit = { government_has_mechanic = administrative } custom_description = { text = "cannot_diarch_revoke_administrative_titles" always = no @@ -252,7 +259,7 @@ diarch_revoke_title_interaction = { scope:actor = { if = { limit = { - is_landed_or_landless_administrative = no + is_landed_or_landless_administrative_or_theocratic = no scope:intermediary != scope:recipient } # This has a delay of 1 day (if no delay then the liege change doesn't stick) which really isn't ideal and should be looked into/fixed so that it happens when the action goes into effect @@ -506,7 +513,7 @@ diarch_revoke_title_interaction = { max = 20 } desc = offer_vassalization_interaction_aibehavior_power_tt - scope:actor = { is_landed_or_landless_administrative = yes } + scope:actor = { is_landed_or_landless_administrative_or_theocratic = yes } } # Legalistic tradition modifier = { @@ -562,13 +569,6 @@ diarch_revoke_title_interaction = { hegemony = 6 } - ai_potential = { - is_diarch = yes - liege = { has_realm_law_flag = title_revocation_allowed } - # Loyal diarchs don't engage in skullduggery. - diarch_loyalty < diarch_loyalty_visibly_loyal_threshold - } - ai_will_do = { # We're generally ruthless here. base = @ai_core_loop_base_value @@ -698,6 +698,16 @@ diarch_revoke_title_interaction = { factor = 0 prestige <= 0 } + ### x0 Don't strip a prelate of his lands while he is still in the Church's good graces. + ## No war check here: refusal is a two-party claim war, not a realm rising, and char_interaction.0263 + ## already weighs whether that war is worth starting. + modifier = { + factor = 0 + scope:recipient = { + government_has_flag = government_is_ecclesiastical + NOT = { has_trait = excommunicated } + } + } } } @@ -738,30 +748,38 @@ diarch_retract_vassal_interaction = { on_decline_summary = diarch_rebel_or_crime_summary.retract + is_available = { + trigger_if = { + limit = { is_ai = yes } + has_realm_law_flag = title_revocation_allowed + is_diarch = yes + # Loyal diarchs don't engage in skullduggery. + diarch_loyalty < diarch_loyalty_visibly_loyal_threshold + primary_title.tier > tier_county + } + # Plus you need to be landed for this. + is_landed_or_landless_administrative_or_theocratic = yes + liege ?= { has_diarchy_parameter = unlock_diarch_retract_vassal_interaction } + # If you're not in a diarchy, we don't care. + OR = { + is_designated_diarch = yes + AND = { + is_diarch_of_target = liege + exists = liege + } + } + } + is_shown = { # The obvious. scope:actor != scope:recipient - # Diarchy checks for scope:actor. - scope:actor = { - # If you're not in a diarchy, we don't care. - OR = { - AND = { - exists = liege - is_diarch_of_target = liege - } - is_designated_diarch = yes - } - liege = { has_diarchy_parameter = unlock_diarch_retract_vassal_interaction } - # Plus you need to be landed for this. - is_landed_or_landless_administrative = yes - } # Make sure scope:recipient is suitable. scope:recipient = { # We only target vassals of the liege... - liege = scope:actor.liege + liege ?= scope:actor.liege this != scope:actor.liege # ... who are appropriately landed. - is_landed_or_landless_administrative = yes + is_landed_or_landless_administrative_or_theocratic = yes scope:recipient.highest_held_title_tier >= tier_duchy } } @@ -1194,7 +1212,7 @@ diarch_retract_vassal_interaction = { scope:actor = { NOR = { #Of two different faiths AND the potential vassal's faith is not pluralistic. faith = scope:recipient.faith - faith = { has_doctrine = doctrine_pluralism_pluralistic } + rite = { rite_has_doctrine = doctrine_pluralism_pluralistic } } } } @@ -1211,14 +1229,6 @@ diarch_retract_vassal_interaction = { hegemony = 24 } - ai_potential = { - is_diarch = yes - has_realm_law_flag = title_revocation_allowed - primary_title.tier > tier_county - # Loyal diarchs don't engage in skullduggery. - diarch_loyalty < diarch_loyalty_visibly_loyal_threshold - } - ai_will_do = { # We're generally ruthless here. base = @ai_secondary_powers_base_value @@ -1380,23 +1390,23 @@ diarch_imprison_interaction = { on_decline_summary = diarch_rebel_or_crime_summary.crominal + is_available = { + # If you're not in a diarchy, we don't care. + OR = { + is_designated_diarch = yes + AND = { + is_diarch_of_target = liege + exists = liege + } + } + # The prisoner goes to your dungeon, so we want you to actually have one. + is_landed_or_landless_administrative_or_theocratic = yes + liege ?= { has_diarchy_parameter = unlock_diarch_imprison_interaction } + } + is_shown = { # The obvious. scope:actor != scope:recipient - # Diarchy checks for scope:actor. - scope:actor = { - # If you're not in a diarchy, we don't care. - OR = { - AND = { - exists = liege - is_diarch_of_target = liege - } - is_designated_diarch = yes - } - liege = { has_diarchy_parameter = unlock_diarch_imprison_interaction } - # The prisoner goes to your dungeon, so we want you to actually have one. - is_landed_or_landless_administrative = yes - } # Make sure scope:recipient is suitable. scope:recipient = { is_imprisoned = no } # Scope:recipient can't be visiting elsewhere. @@ -1412,7 +1422,7 @@ diarch_imprison_interaction = { } # Finally, make sure this isn't someone scope:actor could use the conventional interaction on. scope:actor = { - liege = { + liege ?= { basic_allowed_to_imprison_character_trigger = { CHARACTER = scope:recipient } } NOT = { @@ -1590,7 +1600,7 @@ diarch_imprison_interaction = { # If target is count or higher, we want the option to start a war. if = { limit = { - is_landed_or_landless_administrative = yes + is_landed_or_landless_administrative_or_theocratic = yes highest_held_title_tier >= tier_county } # Send the choosing event. @@ -1635,7 +1645,7 @@ diarch_imprison_interaction = { } } if = { - limit = { is_landed_or_landless_administrative = yes } + limit = { is_landed_or_landless_administrative_or_theocratic = yes } depose_effect = { DEPOSER = scope:actor } } if = { @@ -1721,7 +1731,7 @@ diarch_imprison_interaction = { OR = { is_playable_character = no AND = { - is_landed_or_landless_administrative = yes + is_landed_or_landless_administrative_or_theocratic = yes primary_title.tier = tier_barony } } @@ -2183,20 +2193,32 @@ diarch_subsidise_crown_authority_interaction = { popup_on_receive = yes pause_on_receive = yes + is_available = { + trigger_if = { + limit = { is_ai = yes } + is_diarch = yes + # Loyal diarchs don't engage in skullduggery. + diarch_loyalty < diarch_loyalty_visibly_loyal_threshold + # You also need prestige left over afterwards to use other interactions, so make sure the AI doesn't bankrupt itself on this. + prestige >= { + value = liege.increase_crown_authority_prestige_cost + multiply = subsidised_liege_authority_discount_value + add = major_prestige_value + } + } + liege ?= { has_diarchy_parameter = diarch_can_subsidise_liege_authority } + liege_has_co_emperorship_trigger = no + is_diarch_of_target = liege + # If you're not in a diarchy, we don't care. + exists = liege + } + is_shown = { # The obvious. scope:actor != scope:recipient - # Diarchy checks for scope:actor. - scope:actor = { - # If you're not in a diarchy, we don't care. - exists = liege - is_diarch_of_target = liege - liege_has_co_emperorship_trigger = no - liege = { has_diarchy_parameter = diarch_can_subsidise_liege_authority } - } # Same sub-realm only. OR = { - scope:actor.liege = scope:recipient + scope:actor.liege ?= scope:recipient scope:recipient = { any_liege_or_above = { this = scope:actor.liege } } @@ -2229,27 +2251,9 @@ diarch_subsidise_crown_authority_interaction = { } # Aaaand, if you're not tribal/administrative, we need to check some innovations. scope:recipient = { - # CA0 -> CA1. - trigger_if = { - limit = { has_realm_law = crown_authority_0 } - can_pass_law_ca1_trigger = yes - } - # CA1 -> CA2. - trigger_if = { - limit = { has_realm_law = crown_authority_1 } - can_pass_law_ca2_trigger = yes - } - # CA2 -> CA3. - trigger_if = { - limit = { has_realm_law = crown_authority_2 } - can_pass_law_ca3_trigger = yes - } - + can_increase_government_authority = yes # If the liege is administrative, they have to be independent. - trigger_if = { - limit = { government_allows = administrative } - is_independent_ruler = yes - } + should_synchronize_liege_law = no } # Cannot be at war with your liege. NOT = { @@ -2275,9 +2279,7 @@ diarch_subsidise_crown_authority_interaction = { left_icon = scope:recipient scope:recipient = { # Try to change authority. - increase_crown_authority_effect = yes - increase_tribal_authority_effect = yes - increase_imperial_bureaucracy_effect = yes + change_authority_effect = { CHANGE = 1 } # No one blames the liege for this. add_character_modifier = { modifier = liege_authority_boost_has_scapegoat_modifier @@ -2336,17 +2338,6 @@ diarch_subsidise_crown_authority_interaction = { empire = 24 hegemony = 24 } - ai_potential = { - is_diarch = yes - # Loyal diarchs don't engage in skullduggery. - diarch_loyalty < diarch_loyalty_visibly_loyal_threshold - # You also need prestige left over afterwards to use other interactions, so make sure the AI doesn't bankrupt itself on this. - prestige >= { - value = liege.increase_crown_authority_prestige_cost - multiply = subsidised_liege_authority_discount_value - add = major_prestige_value - } - } ai_will_do = { base = 0 @@ -2388,20 +2379,32 @@ diarch_adjust_bureaucracy_interaction = { popup_on_receive = yes pause_on_receive = yes + is_available = { + trigger_if = { + limit = { is_ai = yes } + is_diarch = yes + # Loyal diarchs don't engage in skullduggery. + diarch_loyalty < diarch_loyalty_visibly_loyal_threshold + # You also need prestige left over afterwards to use other interactions, so make sure the AI doesn't bankrupt itself on this. + prestige >= { + value = liege.increase_crown_authority_prestige_cost + multiply = subsidised_liege_authority_discount_value + add = major_prestige_value + } + } + liege_has_co_emperorship_trigger = yes + liege ?= { has_diarchy_parameter = unlock_adjust_imperial_bureaucracy_interaction } + is_diarch_of_target = liege + # If you're not in a diarchy, we don't care. + exists = liege + } + is_shown = { # The obvious. scope:actor != scope:recipient - # Diarchy checks for scope:actor. - scope:actor = { - # If you're not in a diarchy, we don't care. - exists = liege - is_diarch_of_target = liege - liege_has_co_emperorship_trigger = yes - liege = { has_diarchy_parameter = unlock_adjust_imperial_bureaucracy_interaction } - } # Same sub-realm only. OR = { - scope:actor.liege = scope:recipient + scope:actor.liege ?= scope:recipient scope:recipient = { any_liege_or_above = { this = scope:actor.liege } } @@ -2493,14 +2496,14 @@ diarch_adjust_bureaucracy_interaction = { # Try to change authority. if = { limit = { scope:increase_centralisation = yes } - increase_imperial_bureaucracy_effect = yes + change_authority_effect = { CHANGE = 1 } # No one blames the liege for this. add_character_modifier = { modifier = liege_authority_boost_has_scapegoat_modifier years = 10 } } - else = { decrease_imperial_bureaucracy_effect = yes } + else = { change_authority_effect = { CHANGE = -1 } } } # Aaaaand everyone knows what you did. ## For good. @@ -2674,18 +2677,6 @@ diarch_adjust_bureaucracy_interaction = { empire = 24 hegemony = 24 } - ai_potential = { - is_diarch = yes - liege_has_co_emperorship_trigger = yes - # Loyal diarchs don't engage in skullduggery. - diarch_loyalty < diarch_loyalty_visibly_loyal_threshold - # You also need prestige left over afterwards to use other interactions, so make sure the AI doesn't bankrupt itself on this. - prestige >= { - value = liege.increase_crown_authority_prestige_cost - multiply = subsidised_liege_authority_discount_value - add = major_prestige_value - } - } ai_will_do = { base = 0 @@ -2738,28 +2729,34 @@ diarch_legal_meddling_interaction = { target_filter = recipient_domain_titles popup_on_receive = yes + is_available = { + trigger_if = { + limit = { is_ai = yes } + is_diarch = yes + # Loyal diarchs don't engage in skullduggery. + diarch_loyalty < diarch_loyalty_visibly_loyal_threshold + } + liege ?= { has_diarchy_parameter = unlock_legal_meddling_interaction } + # If you're not in a diarchy, we don't care. + OR = { + is_designated_diarch = yes + AND = { + is_diarch_of_target = liege + exists = liege + } + } + } + is_shown = { # The obvious. scope:actor != scope:recipient - # Diarchy checks for scope:actor. - scope:actor = { - # If you're not in a diarchy, we don't care. - OR = { - AND = { - exists = liege - is_diarch_of_target = liege - } - is_designated_diarch = yes - } - liege = { has_diarchy_parameter = unlock_legal_meddling_interaction } - } # Make sure scope:recipient is suitable. scope:recipient = { # We only target vassals of the liege... - liege = scope:actor.liege + liege ?= scope:actor.liege this != scope:actor.liege # ... who are appropriately landed. - is_landed_or_landless_administrative = yes + is_landed_or_landless_administrative_or_theocratic = yes scope:recipient.highest_held_title_tier >= tier_county } } @@ -2934,12 +2931,6 @@ diarch_legal_meddling_interaction = { hegemony = 6 } - ai_potential = { - is_diarch = yes - # Loyal diarchs don't engage in skullduggery. - diarch_loyalty < diarch_loyalty_visibly_loyal_threshold - } - ai_will_do = { # We're generally ruthless here. base = @ai_core_loop_base_value @@ -2992,7 +2983,7 @@ diarch_legal_meddling_interaction = { ## Weight up for bordering or de jure areas. modifier = { add = 50 - is_landed_or_landless_administrative = yes + is_landed_or_landless_administrative_or_theocratic = yes any_sub_realm_county = { any_neighboring_county = { holder = { @@ -3006,7 +2997,7 @@ diarch_legal_meddling_interaction = { } modifier = { add = 50 - is_landed_or_landless_administrative = yes + is_landed_or_landless_administrative_or_theocratic = yes scope:actor = { any_held_title = { any_direct_de_jure_vassal_title = { @@ -3025,7 +3016,7 @@ diarch_legal_meddling_interaction = { ## Weight down for folks outside of our de jure kingdom. modifier = { add = -100 - is_landed_or_landless_administrative = yes + is_landed_or_landless_administrative_or_theocratic = yes scope:recipient.primary_title.de_jure_liege ?= { this != scope:actor.primary_title.de_jure_liege } @@ -3151,21 +3142,32 @@ diarch_syphon_treasury_interaction = { interface_priority = 60 + is_available = { + trigger_if = { + limit = { is_ai = yes } + is_diarch = yes + # Honest and generous characters never embezzle. + NOR = { + has_trait = generous + has_trait = honest + } + # Loyal diarchs don't engage in skullduggery. + diarch_loyalty < diarch_loyalty_visibly_loyal_threshold + } + liege ?= { has_diarchy_parameter = unlock_syphon_treasury_interaction } + # If you're not in a diarchy, we don't care. + OR = { + is_designated_diarch = yes + AND = { + is_diarch_of_target = liege + exists = liege + } + } + } + is_shown = { # The obvious. scope:actor != scope:recipient - # Diarchy checks for scope:actor. - scope:actor = { - # If you're not in a diarchy, we don't care. - OR = { - AND = { - exists = liege - is_diarch_of_target = liege - } - is_designated_diarch = yes - } - liege = { has_diarchy_parameter = unlock_syphon_treasury_interaction } - } # Make sure scope:recipient is suitable. scope:recipient = { OR = { @@ -3620,17 +3622,6 @@ diarch_syphon_treasury_interaction = { hegemony = 12 } - ai_potential = { - is_diarch = yes - # Loyal diarchs don't engage in skullduggery. - diarch_loyalty < diarch_loyalty_visibly_loyal_threshold - # Honest and generous characters never embezzle. - NOR = { - has_trait = honest - has_trait = generous - } - } - ai_will_do = { # Embezzlement is serious, so you need actual reasons for it. base = 0 @@ -3815,28 +3806,34 @@ diarch_shift_privileges_interaction = { interface_priority = 285 + is_available = { + trigger_if = { + limit = { is_ai = yes } + is_diarch = yes + # Loyal diarchs don't engage in skullduggery. + diarch_loyalty < diarch_loyalty_visibly_loyal_threshold + } + liege ?= { has_diarchy_parameter = unlock_shift_privileges_interaction } + # If you're not in a diarchy, we don't care. + OR = { + is_designated_diarch = yes + AND = { + is_diarch_of_target = liege + exists = liege + } + } + } + is_shown = { # The obvious. scope:actor != scope:recipient - # Diarchy checks for scope:actor. - scope:actor = { - # If you're not in a diarchy, we don't care. - OR = { - AND = { - exists = liege - is_diarch_of_target = liege - } - is_designated_diarch = yes - } - liege = { has_diarchy_parameter = unlock_shift_privileges_interaction } - } # Make sure scope:recipient is suitable. scope:recipient = { # We only target vassals of the liege... - liege = scope:actor.liege + liege ?= scope:actor.liege this != scope:actor.liege # ... who are appropriately landed. - is_landed_or_landless_administrative = yes + is_landed_or_landless_administrative_or_theocratic = yes scope:recipient.highest_held_title_tier >= tier_county } } @@ -4019,12 +4016,6 @@ diarch_shift_privileges_interaction = { hegemony = 6 } - ai_potential = { - is_diarch = yes - # Loyal diarchs don't engage in skullduggery. - diarch_loyalty < diarch_loyalty_visibly_loyal_threshold - } - ai_will_do = { # We're generally ruthless here. base = @ai_secondary_powers_base_value @@ -4150,19 +4141,29 @@ diarch_request_imperial_expedition_interaction = { popup_on_receive = yes pause_on_receive = yes + is_available = { + trigger_if = { + limit = { is_ai = yes } + is_diarch = yes + liege ?= { has_diarchy_active_parameter = unlock_diarch_requests_military_expedition_interaction } + NOR = { + has_trait = content + has_trait = lazy + has_trait = craven + } + } + liege ?= { has_diarchy_parameter = unlock_diarch_requests_military_expedition_interaction } + is_diarch_of_target = liege + # If you're not in a diarchy, we don't care. + exists = liege + } + is_shown = { # The obvious. scope:actor != scope:recipient - # Diarchy checks for scope:actor. - scope:actor = { - # If you're not in a diarchy, we don't care. - exists = liege - is_diarch_of_target = liege - liege = { has_diarchy_parameter = unlock_diarch_requests_military_expedition_interaction } - } # Same sub-realm only. OR = { - scope:actor.liege = scope:recipient + scope:actor.liege ?= scope:recipient scope:recipient = { any_liege_or_above = { this = scope:actor.liege } } @@ -4439,15 +4440,6 @@ diarch_request_imperial_expedition_interaction = { empire = 24 hegemony = 24 } - ai_potential = { - is_diarch = yes - liege = { has_diarchy_active_parameter = unlock_diarch_requests_military_expedition_interaction } - NOR = { - has_trait = craven - has_trait = lazy - has_trait = content - } - } ai_will_do = { base = -50 @@ -4551,19 +4543,30 @@ diarch_demand_despotate_interaction = { popup_on_receive = yes pause_on_receive = yes + is_available = { + trigger_if = { + limit = { is_ai = yes } + is_diarch = yes + liege ?= { has_diarchy_active_parameter = unlock_diarch_demand_kingdom_interaction } + NOR = { + has_trait = content + has_trait = humble + } + # Loyal diarchs don't ask for what their liege could give freely. + diarch_loyalty < diarch_loyalty_visibly_loyal_threshold + } + liege ?= { has_diarchy_parameter = unlock_diarch_demand_kingdom_interaction } + is_diarch_of_target = liege + # If you're not in a diarchy, we don't care. + exists = liege + } + is_shown = { # The obvious. scope:actor != scope:recipient - # Diarchy checks for scope:actor. - scope:actor = { - # If you're not in a diarchy, we don't care. - exists = liege - is_diarch_of_target = liege - liege = { has_diarchy_parameter = unlock_diarch_demand_kingdom_interaction } - } # Same sub-realm only. OR = { - scope:actor.liege = scope:recipient + scope:actor.liege ?= scope:recipient scope:recipient = { any_liege_or_above = { this = scope:actor.liege } } @@ -4889,16 +4892,6 @@ diarch_demand_despotate_interaction = { empire = 24 hegemony = 24 } - ai_potential = { - is_diarch = yes - liege = { has_diarchy_active_parameter = unlock_diarch_demand_kingdom_interaction } - NOR = { - has_trait = humble - has_trait = content - } - # Loyal diarchs don't ask for what their liege could give freely. - diarch_loyalty < diarch_loyalty_visibly_loyal_threshold - } ai_will_do = { base = 25 @@ -5030,16 +5023,22 @@ diarch_coup_liege_interaction = { } } + is_available = { + # If you're not in a diarchy, we don't care. + OR = { + is_designated_diarch = yes + AND = { + is_diarch_of_target = liege + exists = liege + } + } + } + is_shown = { - # Diarchy checks for scope:actor. - scope:actor = { - # If you're not in a diarchy, we don't care. + liege ?= { OR = { - AND = { - exists = liege - is_diarch_of_target = liege - } - is_designated_diarch = yes + NOT = { government_allows = deny_powerful_vassal } + government_has_flag = government_has_powerful_families } } # secondary_recipient is always saved whenever you use it on anyone who isn't yourself or your liege, so we use this fact to validate it after the redirect, otherwise it will show up on every other ruler in the game @@ -5125,14 +5124,8 @@ diarch_coup_liege_interaction = { can_send = { # We check this here to make the interaction generally findable, so you can get at the list easily, but prevent you from inviting randos to the coup. ## It's actually technically harmless - they won't help but don't get their payout if they're not powerful when the coup hits. - trigger_if = { - limit = { - scope:recipient = { government_has_flag = government_has_powerful_families } - } - scope:secondary_recipient.house = { is_powerful_family = yes } - } - trigger_else = { - scope:secondary_recipient = { is_powerful_vassal = yes } + scope:secondary_recipient = { + is_powerful_vassal_or_house_head_trigger = yes } } @@ -5495,13 +5488,21 @@ mulct_vizier_interaction = { desc = mulct_vizier_interaction_desc + is_available = { + # Plus only on viziers. + has_diarchy_active_parameter = unlock_mulct_vizier_interaction + trigger_if = { + limit = { is_ai = yes } + has_diarchy_parameter = unlock_mulct_vizier_interaction + has_active_diarchy = yes + } + } + is_shown = { # Diarchy checks for scope:actor. scope:actor = { # If you're not in a diarchy, we don't care. diarch ?= scope:recipient - # Plus only on viziers. - has_diarchy_active_parameter = unlock_mulct_vizier_interaction } } @@ -5649,7 +5650,7 @@ mulct_vizier_interaction = { mulct_vizier_for_cash_opinion_reaction_effect = { MULT = 5 } } # How much stress is this causing them? - stress_impact = { + stress_and_fulfillment_impact = { ambitious = major_stress_impact_loss arrogant = medium_stress_impact_loss generous = minor_stress_impact_loss @@ -5679,10 +5680,6 @@ mulct_vizier_interaction = { empire = 120 hegemony = 120 } - ai_potential = { - has_active_diarchy = yes - has_diarchy_parameter = unlock_mulct_vizier_interaction - } ai_will_do = { # You generally want to do this if you can. @@ -5785,6 +5782,52 @@ scapegoat_counterpart_interaction = { interface_priority = 25 + is_available = { + trigger_if = { + limit = { is_ai = yes } + OR = { + # Either they're a liege. + AND = { + has_active_diarchy = yes + # With suitable skill diffs to give some kind of a gain. + OR = { + diplomacy_diff = { + target = diarch + value >= 5 + } + intrigue_diff = { + target = diarch + value >= 5 + } + } + } + # Or they're the diarch. + AND = { + is_diarch = yes + # With suitable skill diffs to give some kind of a gain. + OR = { + intrigue_diff = { + target = liege + value >= 5 + } + diplomacy_diff = { + target = liege + value >= 5 + } + } + # Loyal diarchs don't engage in skullduggery. + diarch_loyalty < diarch_loyalty_visibly_loyal_threshold + } + } + # Filter out some traits that would never do this. + NOR = { + has_trait = honest + has_trait = just + has_trait = loyal + } + } + } + is_shown = { # You must be one of the partners in a diarchy. is_in_scapegoating_diarchy_visibility_trigger = { PARAMETER_TYPE = has_diarchy_parameter } @@ -5953,49 +5996,6 @@ scapegoat_counterpart_interaction = { hegemony = 12 } - ai_potential = { - OR = { - # Either they're a liege. - AND = { - has_active_diarchy = yes - # With suitable skill diffs to give some kind of a gain. - OR = { - diplomacy_diff = { - target = diarch - value >= 5 - } - intrigue_diff = { - target = diarch - value >= 5 - } - } - } - # Or they're the diarch. - AND = { - is_diarch = yes - # With suitable skill diffs to give some kind of a gain. - OR = { - diplomacy_diff = { - target = liege - value >= 5 - } - intrigue_diff = { - target = liege - value >= 5 - } - } - # Loyal diarchs don't engage in skullduggery. - diarch_loyalty < diarch_loyalty_visibly_loyal_threshold - } - } - # Filter out some traits that would never do this. - NOR = { - has_trait = just - has_trait = honest - has_trait = loyal - } - } - ai_will_do = { base = -50 @@ -6179,8 +6179,33 @@ swing_scales_currency_interaction = { interface_priority = 20 + is_available = { + trigger_if = { + limit = { is_ai = yes } + OR = { + # Or they're the diarch. + AND = { + is_diarch = yes + # Loyal diarchs don't engage in skullduggery. + diarch_loyalty < diarch_loyalty_visibly_loyal_threshold + } + # Either they're a liege. + AND = { + has_active_diarchy = yes + # With some kind of valid cause to worry. + OR = { + # ... unless they could get out of it. + can_leave_diarchy_trigger = yes + # Lieges don't care unless your regency is entrenched _and_ it's looking to stay that way... + has_diarchy_active_parameter = regency_cant_be_ended_above_this_point + } + } + } + } + is_playable_character = yes + } + is_shown = { - # You must be one of the partners in a diarchy. OR = { scope:actor = { is_diarch_of_target = scope:recipient } scope:recipient = { is_diarch_of_target = scope:actor } @@ -6319,16 +6344,16 @@ swing_scales_currency_interaction = { OR = { AND = { scope:recipient.liege ?= scope:actor - scope:actor = { government_allows = administrative } + scope:actor = { government_has_flag = government_has_influence } } AND = { scope:actor.liege ?= scope:recipient - scope:recipient = { government_allows = administrative } + scope:recipient = { government_has_flag = government_has_influence } } } } is_valid = { - scope:actor = { government_allows = administrative } + scope:actor = { government_has_flag = government_has_influence } # Can't be a liege with the scales swung completely towards them. trigger_if = { limit = { @@ -6487,6 +6512,7 @@ swing_scales_currency_interaction = { is_shown = { # Filter out for the liege in vizierates - they can mulct the vizier, so we don't give them the chance to spend that gold back. interaction_actor_is_liege_with_vizierate_trigger = no + NOT = { religious_head_or_challenger ?= scope:recipient } } is_valid = { diarch_swing_scales_valid_shared_hof_trigger = yes @@ -6768,28 +6794,6 @@ swing_scales_currency_interaction = { hegemony = 24 } - ai_potential = { - OR = { - # Either they're a liege. - AND = { - has_active_diarchy = yes - # With some kind of valid cause to worry. - OR = { - # Lieges don't care unless your regency is entrenched _and_ it's looking to stay that way... - has_diarchy_active_parameter = regency_cant_be_ended_above_this_point - # ... unless they could get out of it. - can_leave_diarchy_trigger = yes - } - } - # Or they're the diarch. - AND = { - is_diarch = yes - # Loyal diarchs don't engage in skullduggery. - diarch_loyalty < diarch_loyalty_visibly_loyal_threshold - } - } - } - ai_will_do = { # We're generally ruthless here. base = @ai_secondary_powers_base_value @@ -6860,11 +6864,21 @@ diarch_swing_scales_currency_interaction = { interface_priority = 20 + is_available = { + trigger_if = { + limit = { is_ai = yes } + # Double check due to some irritating errors. + is_diarch = yes + # Loyal diarchs don't engage in skullduggery. + diarch_loyalty < diarch_loyalty_visibly_loyal_threshold + liege ?= { has_active_diarchy = yes } + } + is_playable_character = no + is_ai = yes + } + is_shown = { scope:recipient = scope:actor.liege - # This is for landless diarchs only, and we pre-filter them, so we don't really care about this block. - ## But filter out players anyway for that _seamless_ debug play experience. - scope:actor = { is_ai = yes } } is_valid_showing_failures_only = { @@ -6996,16 +7010,16 @@ diarch_swing_scales_currency_interaction = { OR = { AND = { scope:recipient.liege ?= scope:actor - scope:actor = { government_allows = administrative } + scope:actor = { government_has_flag = government_has_influence } } AND = { scope:actor.liege ?= scope:recipient - scope:recipient = { government_allows = administrative } + scope:recipient = { government_has_flag = government_has_influence } } } } is_valid = { - scope:actor = { government_allows = administrative } + scope:actor = { government_has_flag = government_has_influence } } starts_enabled = { scope:actor.influence >= scope:actor.swing_scales_influence_cost_value } flag = swing_influence @@ -7083,6 +7097,7 @@ diarch_swing_scales_currency_interaction = { } # HoF send_option = { + is_shown = { NOT = { religious_head_or_challenger ?= scope:recipient } } is_valid = { diarch_swing_scales_valid_shared_hof_trigger = yes } # Top of the prio order for enablement. starts_enabled = { diarch_swing_scales_valid_shared_hof_trigger = yes } @@ -7140,14 +7155,6 @@ diarch_swing_scales_currency_interaction = { hegemony = 6 } - ai_potential = { - # Double check due to some irritating errors. - is_diarch = yes - liege = { has_active_diarchy = yes } - # Loyal diarchs don't engage in skullduggery. - diarch_loyalty < diarch_loyalty_visibly_loyal_threshold - } - ai_will_do = { # We're generally ruthless here. base = @ai_core_loop_base_value @@ -7207,17 +7214,23 @@ diarch_entrench_regency_interaction = { popup_on_receive = yes pause_on_receive = yes + is_available = { + trigger_if = { + limit = { is_ai = yes } + is_diarch = yes + # Don't entrench for no reason — we want to have a bit of a delay so that the AI can go off travelling or get locked in prison once in a while. + liege ?= { years_in_diarchy >= 2 } + } + # With the extra consideration that we only want this to appear for Temporary Regencies. + liege ?= { has_diarchy_parameter = unlock_entrench_regency_interaction } + is_diarch_of_target = liege + # If you're not in a diarchy, we don't care. + exists = liege + } + is_shown = { # The obvious. scope:actor != scope:recipient - # Diarchy checks for scope:actor. - scope:actor = { - # If you're not in a diarchy, we don't care. - exists = liege - is_diarch_of_target = liege - # With the extra consideration that we only want this to appear for Temporary Regencies. - liege = { has_diarchy_parameter = unlock_entrench_regency_interaction } - } } is_valid_showing_failures_only = { @@ -7278,11 +7291,6 @@ diarch_entrench_regency_interaction = { empire = 6 hegemony = 6 } - ai_potential = { - is_diarch = yes - # Don't entrench for no reason — we want to have a bit of a delay so that the AI can go off travelling or get locked in prison once in a while. - liege = { years_in_diarchy >= 2 } - } ai_will_do = { # You never _don't_ want to do this. @@ -7302,20 +7310,28 @@ diarch_regent_appoints_self_co_emperor_interaction = { popup_on_receive = yes pause_on_receive = yes + is_available = { + trigger_if = { + limit = { is_ai = yes } + is_diarch = yes + # Filter us down nice'n'tight. + liege ?= { may_appoint_co_emperors_trigger = yes } + # Loyal diarchs don't engage in skullduggery. + diarch_loyalty < diarch_loyalty_visibly_loyal_threshold + } + # With the extra consideration that we only want this to appear for those who can actually _have_ co-emperors. + liege ?= { + has_diarchy_parameter = diarch_can_appoint_self_co_emperor + may_appoint_co_emperors_trigger = yes + } + is_diarch_of_target = liege + # If you're not in a diarchy, we don't care. + exists = liege + } + is_shown = { # The obvious. scope:actor != scope:recipient - # Diarchy checks for scope:actor. - scope:actor = { - # If you're not in a diarchy, we don't care. - exists = liege - is_diarch_of_target = liege - # With the extra consideration that we only want this to appear for those who can actually _have_ co-emperors. - liege = { - has_diarchy_parameter = diarch_can_appoint_self_co_emperor - may_appoint_co_emperors_trigger = yes - } - } } is_valid_showing_failures_only = { @@ -7399,13 +7415,6 @@ diarch_regent_appoints_self_co_emperor_interaction = { empire = 12 hegemony = 12 } - ai_potential = { - is_diarch = yes - # Filter us down nice'n'tight. - liege = { may_appoint_co_emperors_trigger = yes } - # Loyal diarchs don't engage in skullduggery. - diarch_loyalty < diarch_loyalty_visibly_loyal_threshold - } ai_will_do = { # You never _don't_ want to do this. @@ -7422,6 +7431,15 @@ liege_dismiss_temporary_regency_interaction = { desc = liege_dismiss_temporary_regency_interaction_desc + is_available = { + # With the extra consideration that we only want this to appear for Temporary Regencies. + has_diarchy_parameter = can_be_instantly_dismissed + trigger_if = { + limit = { is_ai = yes } + has_active_diarchy = yes + } + } + is_shown = { # The obvious. scope:actor != scope:recipient @@ -7429,8 +7447,6 @@ liege_dismiss_temporary_regency_interaction = { scope:actor = { # If you're not in a diarchy, we don't care. diarch ?= scope:recipient - # With the extra consideration that we only want this to appear for Temporary Regencies. - has_diarchy_parameter = can_be_instantly_dismissed } } @@ -7491,7 +7507,6 @@ liege_dismiss_temporary_regency_interaction = { empire = 12 hegemony = 12 } - ai_potential = { has_active_diarchy = yes } ai_will_do = { # You never _don't_ want to do this. @@ -7517,6 +7532,26 @@ liege_dismiss_entrenched_regency_interaction = { ai_min_reply_days = 4 ai_max_reply_days = 9 + is_available = { + # With the extra consideration that we only want this to appear for Entrenched Regencies. + OR = { + has_diarchy_parameter = dismissal_requires_gift + AND = { + has_diarchy_parameter = dismissal_requires_no_ministry + tgp_has_access_to_ministry_trigger = no + } + } + trigger_if = { + limit = { is_ai = yes } + # Are we in a diarchy at all? + has_active_diarchy = yes + # Can we leave it? + can_leave_diarchy_trigger = yes + # Are we locked into a speed-leave cycle? + NOT = { has_character_flag = trying_to_dismiss_regent } + } + } + is_shown = { # The obvious. scope:actor != scope:recipient @@ -7524,14 +7559,6 @@ liege_dismiss_entrenched_regency_interaction = { scope:actor = { # If you're not in a diarchy, we don't care. diarch ?= scope:recipient - # With the extra consideration that we only want this to appear for Entrenched Regencies. - OR = { - has_diarchy_parameter = dismissal_requires_gift - AND = { - has_diarchy_parameter = dismissal_requires_no_ministry - tgp_has_access_to_ministry_trigger = no - } - } } } @@ -8266,14 +8293,6 @@ liege_dismiss_entrenched_regency_interaction = { empire = 12 hegemony = 12 } - ai_potential = { - # Are we in a diarchy at all? - has_active_diarchy = yes - # Can we leave it? - can_leave_diarchy_trigger = yes - # Are we locked into a speed-leave cycle? - NOT = { has_character_flag = trying_to_dismiss_regent } - } ai_will_do = { # You never _don't_ want to do this. @@ -8334,6 +8353,15 @@ liege_dismiss_vizier_interaction = { desc = liege_dismiss_vizier_interaction_desc + is_available = { + # With the extra consideration that we only want this to appear for Vizierates. + has_diarchy_parameter = primeminister_dismissal_will_upset_administration + trigger_if = { + limit = { is_ai = yes } + has_active_diarchy = yes + } + } + is_shown = { # The obvious. scope:actor != scope:recipient @@ -8341,8 +8369,6 @@ liege_dismiss_vizier_interaction = { scope:actor = { # If you're not in a diarchy, we don't care. diarch ?= scope:recipient - # With the extra consideration that we only want this to appear for Vizierates. - has_diarchy_parameter = primeminister_dismissal_will_upset_administration } } @@ -8430,7 +8456,7 @@ liege_dismiss_vizier_interaction = { } } # Plus some stress. - stress_impact = { + stress_and_fulfillment_impact = { lazy = major_stress_impact_loss humble = medium_stress_impact_loss content = medium_stress_impact_loss @@ -8479,7 +8505,6 @@ liege_dismiss_vizier_interaction = { empire = 24 hegemony = 24 } - ai_potential = { has_active_diarchy = yes } ai_will_do = { # You should actively want to get rid of them. @@ -8614,6 +8639,10 @@ declare_me_regent_interaction = { ai_min_reply_days = 4 ai_max_reply_days = 9 + is_available = { + is_designated_diarch = no + } + is_shown = { # The obvious. scope:actor != scope:recipient @@ -8639,7 +8668,6 @@ declare_me_regent_interaction = { } # ... or have declared you their regent already! scope:actor = { - is_designated_diarch = no NOR = { is_diarch_of_target = scope:recipient # Can't be used during the Cid story cycle @@ -8657,7 +8685,7 @@ declare_me_regent_interaction = { # Or imprisoned. is_imprisoned = no # Or, for that matter, incapable. - NOT = { has_trait = incapable } + is_incapable = no is_diarch_valid_trigger = yes } # Put a general cooldown on this stuff. @@ -9210,13 +9238,14 @@ appoint_vizier_interaction = { desc = appoint_vizier_interaction_desc interface_priority = 20 + is_available = { + # Must be able to retain a vizier. + government_has_flag = may_appoint_viziers + # Plus obscure the interaction if we've already got one, else it's annoyingly redundant. + NOT = { has_diarchy_active_parameter = diarchy_is_vizierate } + } + is_shown = { - scope:actor = { - # Must be able to retain a vizier. - government_has_flag = may_appoint_viziers - # Plus obscure the interaction if we've already got one, else it's annoyingly redundant. - NOT = { has_diarchy_active_parameter = diarchy_is_vizierate } - } # We perform this upon ourselves or our (probable) candidates. trigger_if = { limit = { @@ -9228,7 +9257,7 @@ appoint_vizier_interaction = { is_courtier_of = scope:actor AND = { highest_held_title_tier = tier_barony - liege = scope:actor + liege ?= scope:actor } } } @@ -9332,7 +9361,7 @@ appoint_vizier_interaction = { modifier = compliment_opinion opinion = 30 } - stress_impact = { + stress_and_fulfillment_impact = { ambitious = minor_stress_impact_loss arrogant = minor_stress_impact_loss lazy = major_stress_impact_gain @@ -9347,7 +9376,7 @@ appoint_vizier_interaction = { modifier = compliment_opinion opinion = 30 } - stress_impact = { + stress_and_fulfillment_impact = { ambitious = minor_stress_impact_loss arrogant = minor_stress_impact_loss lazy = major_stress_impact_gain @@ -9408,7 +9437,7 @@ appoint_vizier_interaction = { value = scope:recipient } # Finally, let's do some stress. - stress_impact = { + stress_and_fulfillment_impact = { trusting = massive_stress_impact_loss lazy = major_stress_impact_loss paranoid = minor_stress_impact_gain @@ -9444,10 +9473,6 @@ appoint_vizier_interaction = { hegemony = 120 } - ai_potential = { - government_has_flag = may_appoint_viziers - } - ai_will_do = { base = 0 @@ -9555,6 +9580,22 @@ appoint_junior_emperor_interaction = { desc = appoint_junior_emperor_interaction_desc interface_priority = 20 + is_available = { + trigger_if = { + limit = { is_ai = yes } + # Aaaand finally, the AI won't do this unless they're considering their age and they've got no adult kids. + age >= 50 + # Plus rule out any diarchies already on the go. + has_active_diarchy = no + # Filter us down nice'n'tight. + may_appoint_co_emperors_trigger = yes + any_child = { + count = all + is_adult = no + } + } + } + is_shown = { # Must be able to retain a co-emperor. scope:actor = { may_appoint_co_emperors_trigger = yes } @@ -9723,19 +9764,6 @@ appoint_junior_emperor_interaction = { hegemony = 60 } - ai_potential = { - # Filter us down nice'n'tight. - may_appoint_co_emperors_trigger = yes - # Plus rule out any diarchies already on the go. - has_active_diarchy = no - # Aaaand finally, the AI won't do this unless they're considering their age and they've got no adult kids. - age >= 50 - any_child = { - count = all - is_adult = no - } - } - ai_will_do = { # The AI doesn't like doing this without good reason. base = -100 @@ -9769,6 +9797,19 @@ appoint_co_emperor_interaction = { desc = appoint_co_emperor_interaction_desc interface_priority = 280 + is_available = { + trigger_if = { + limit = { is_ai = yes } + # Aaaand finally, the AI won't do this unless they're considering their age and they've got adult kids. + age >= 50 + # Plus rule out any diarchies already on the go. + has_active_diarchy = no + # Filter us down nice'n'tight. + may_appoint_co_emperors_trigger = yes + any_child = { is_adult = yes } + } + } + is_shown = { # Must be able to retain a co-emperor. scope:actor = { may_appoint_co_emperors_trigger = yes } @@ -9968,16 +10009,6 @@ appoint_co_emperor_interaction = { hegemony = 60 } - ai_potential = { - # Filter us down nice'n'tight. - may_appoint_co_emperors_trigger = yes - # Plus rule out any diarchies already on the go. - has_active_diarchy = no - # Aaaand finally, the AI won't do this unless they're considering their age and they've got adult kids. - age >= 50 - any_child = { is_adult = yes } - } - ai_will_do = { # The AI doesn't like doing this without good reason. base = -100 @@ -10009,6 +10040,19 @@ appoint_co_monarch_interaction = { desc = appoint_co_monarch_interaction_desc interface_priority = 20 + is_available = { + trigger_if = { + limit = { is_ai = yes } + # Aaaand finally, the AI won't do this unless they're considering their age and they've got adult kids. + age >= 50 + # Filter us down nice'n'tight. + may_appoint_co_monarchs_trigger = yes + any_child = { is_adult = yes } + # Plus rule out any diarchies already on the go. + has_active_diarchy = no + } + } + is_shown = { # Must be able to retain a co-emperor. scope:actor = { may_appoint_co_monarchs_trigger = yes } @@ -10175,16 +10219,6 @@ appoint_co_monarch_interaction = { hegemony = 120 } - ai_potential = { - # Filter us down nice'n'tight. - may_appoint_co_monarchs_trigger = yes - # Plus rule out any diarchies already on the go. - has_active_diarchy = no - # Aaaand finally, the AI won't do this unless they're considering their age and they've got adult kids. - age >= 50 - any_child = { is_adult = yes } - } - ai_will_do = { # The AI doesn't like doing this without good reason. base = -100 @@ -10204,12 +10238,37 @@ overthrow_regent_scheme_interaction = { interface_priority = 20 + is_available = { + trigger_if = { + limit = { is_ai = yes } + # Some traits lock the AI out. + ## Calc these first 'cause they're cheaper. + NOR = { + has_trait = content + has_trait = humble + has_trait = lazy + } + OR = { + # Driven by traits or personality. + has_trait = arrogant + has_trait = ambitious + # Family think themselves worthy. + any_close_or_extended_family_member = { this = liege } + # If you're rivals with the current regent, that's a good cause. + any_relation = { + is_diarch_of_target = root.liege + type = rival + } + } + } + } + is_shown = { # Standard setup. scope:actor.liege ?= { - has_active_diarchy = yes # You can't overthrow non-regencies. At least not this way. has_diarchy_parameter = diarchy_is_regency + has_active_diarchy = yes } scope:recipient = { this != scope:actor @@ -10356,28 +10415,6 @@ overthrow_regent_scheme_interaction = { hegemony = 60 } - ai_potential = { - # Some traits lock the AI out. - ## Calc these first 'cause they're cheaper. - NOR = { - has_trait = lazy - has_trait = humble - has_trait = content - } - OR = { - # Driven by traits or personality. - has_trait = arrogant - has_trait = ambitious - # Family think themselves worthy. - any_close_or_extended_family_member = { this = liege } - # If you're rivals with the current regent, that's a good cause. - any_relation = { - type = rival - is_diarch_of_target = root.liege - } - } - } - ai_will_do = { # Most AI think this is audacious. base = -50 diff --git a/common/character_interactions/00_dynast_interactions.txt b/common/character_interactions/00_dynast_interactions.txt index 7942e6515..43c177155 100644 --- a/common/character_interactions/00_dynast_interactions.txt +++ b/common/character_interactions/00_dynast_interactions.txt @@ -8,22 +8,33 @@ disinherit_interaction = { desc = disinherit_interaction_desc use_diplomatic_range = no + is_available = { + trigger_if = { + limit = { is_ai = yes } + is_dynast = yes + NOT = { + has_trait = forgiving + } + is_at_war = no + } + } + is_shown = { - NOT = { - scope:recipient = scope:actor + NOR = { + scope:recipient = scope:puppet_or_actor AND = { # Explicit AND to ensure no funny business - scope:recipient = { is_child_of = scope:actor } - scope:actor.dynasty = { + scope:recipient = { is_child_of = scope:puppet_or_actor } + scope:puppet_or_actor.dynasty ?= { this = scope:recipient.dynasty has_dynasty_perk = fp2_coterie_legacy_5 } } } - scope:actor = { + scope:puppet_or_actor ?= { is_dynast = yes - dynasty = scope:recipient.dynasty + dynasty ?= scope:recipient.dynasty } scope:recipient = { @@ -35,7 +46,7 @@ disinherit_interaction = { is_valid = { custom_description = { - scope:actor.culture = { + scope:puppet_or_actor.culture = { NOT = { has_cultural_parameter = cannot_disherit } } text = "mystical_ancestors_disinherit" @@ -51,37 +62,38 @@ disinherit_interaction = { has_trait = disputed_heritage any_secret = { type = secret_disputed_heritage - is_known_by = scope:actor + is_known_by = scope:puppet_or_actor } has_trait = bastard } } } } - scope:actor.dynasty = { + scope:puppet_or_actor.dynasty = { dynasty_prestige >= medium_dynasty_prestige_value } } - scope:recipient = { NOT = { has_strong_hook = scope:actor } } + scope:recipient = { NOT = { has_strong_hook = scope:puppet_or_actor } } trigger_if = { limit = { scope:recipient = { NOR = { - is_child_of = scope:actor - is_grandchild_of = scope:actor - is_great_grandchild_of = scope:actor + is_child_of = scope:puppet_or_actor + is_grandchild_of = scope:puppet_or_actor + is_great_grandchild_of = scope:puppet_or_actor } } } custom_description = { - scope:recipient.top_liege = scope:actor.top_liege + scope:recipient.top_liege = scope:puppet_or_actor.top_liege + subject = scope:puppet_or_actor text = "same_realm_as" } } custom_tooltip = { text = cannot_take_overt_hostile_actions_against_diarch.tt - NOT = { scope:recipient ?= scope:actor.diarch } + NOT = { scope:recipient ?= scope:puppet_or_actor.diarch } } } @@ -92,33 +104,39 @@ disinherit_interaction = { } on_accept = { - scope:actor = { - stress_impact = { - forgiving = minor_stress_impact_gain - compassionate = minor_stress_impact_gain + scope:puppet_or_actor = { + # Only get stressed/SP penalties if you don't have the parameter + if = { + limit = { + NOT = { sp_hostile_schemes_except_murder_no_stress_or_fulfillment_trigger = yes } + } + stress_and_fulfillment_impact = { + forgiving = minor_stress_impact_gain + compassionate = minor_stress_impact_gain + } } #Legitimacy loss if = { limit = { has_legitimacy = yes } if = { - limit = { scope:recipient = { is_primary_heir_of = scope:actor } } + limit = { scope:recipient = { is_primary_heir_of = scope:puppet_or_actor } } add_legitimacy = { value = medium_legitimacy_loss - multiply = scope:actor.primary_title.tier + multiply = scope:puppet_or_actor.primary_title.tier } } else_if = { - limit = { scope:recipient = { is_child_of = scope:actor } } + limit = { scope:recipient = { is_child_of = scope:puppet_or_actor } } add_legitimacy = { value = minor_legitimacy_loss - multiply = scope:actor.primary_title.tier + multiply = scope:puppet_or_actor.primary_title.tier } } else = { add_legitimacy = { value = miniscule_legitimacy_loss - multiply = scope:actor.primary_title.tier + multiply = scope:puppet_or_actor.primary_title.tier } } } @@ -127,12 +145,34 @@ disinherit_interaction = { type = event_toast_effect_neutral title = disinherit_interaction_notification - left_icon = scope:actor + left_icon = scope:puppet_or_actor right_icon = scope:recipient scope:recipient = { show_as_tooltip = { - disinherit_effect = { DISINHERITOR = scope:actor } + disinherit_effect = { DISINHERITOR = scope:puppet_or_actor } + } + } + } + } + } + hidden_effect = { + if = { + limit = { + scope:is_puppet_action ?= yes + } + scope:actor = { + send_interface_toast = { + type = event_toast_effect_neutral + title = disinherit_interaction_notification + + left_icon = scope:puppet_or_actor + right_icon = scope:recipient + + scope:recipient = { + show_as_tooltip = { + disinherit_effect = { DISINHERITOR = scope:puppet_or_actor } + } } } } @@ -140,12 +180,12 @@ disinherit_interaction = { } scope:recipient = { - disinherit_effect = { DISINHERITOR = scope:actor } + disinherit_effect = { DISINHERITOR = scope:puppet_or_actor } } # If we're a clan this interaction affects unity add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = medium_unity_loss DESC = clan_unity_disinheritance.desc @@ -157,7 +197,7 @@ disinherit_interaction = { scope:recipient = { any_secret = { type = secret_disputed_heritage - is_known_by = scope:actor + is_known_by = scope:puppet_or_actor save_temporary_scope_as = secret_to_reveal } } @@ -176,25 +216,25 @@ disinherit_interaction = { cost = { renown = { value = { - add = scope:actor.dynasty.medium_dynasty_prestige_value + add = scope:puppet_or_actor.dynasty.medium_dynasty_prestige_value if = { limit = { scope:recipient = { - is_landed_or_landless_administrative = yes + is_landed_or_landless_administrative_or_theocratic = yes } } - add = scope:actor.dynasty.major_dynasty_prestige_value + add = scope:puppet_or_actor.dynasty.major_dynasty_prestige_value } if = { limit = { scope:recipient = { - is_landed_or_landless_administrative = no + is_landed_or_landless_administrative_or_theocratic = no any_heir_title = { exists = holder } } } - add = scope:actor.dynasty.medium_dynasty_prestige_value + add = scope:puppet_or_actor.dynasty.medium_dynasty_prestige_value } if = { limit = { @@ -203,7 +243,7 @@ disinherit_interaction = { has_trait = disputed_heritage any_secret = { type = secret_disputed_heritage - is_known_by = scope:actor + is_known_by = scope:puppet_or_actor } has_trait = bastard } @@ -212,6 +252,10 @@ disinherit_interaction = { multiply = 0 } } + if = { + limit = { scope:is_puppet_action ?= yes } + multiply = 0 + } } prestige = { value = { @@ -219,7 +263,7 @@ disinherit_interaction = { if = { limit = { scope:recipient = { - is_landed_or_landless_administrative = yes + is_landed_or_landless_administrative_or_theocratic = yes } } add = massive_prestige_value @@ -227,7 +271,7 @@ disinherit_interaction = { if = { limit = { scope:recipient = { - is_landed_or_landless_administrative = no + is_landed_or_landless_administrative_or_theocratic = no any_heir_title = { exists = holder } @@ -242,7 +286,7 @@ disinherit_interaction = { has_trait = disputed_heritage any_secret = { type = secret_disputed_heritage - is_known_by = scope:actor + is_known_by = scope:puppet_or_actor } has_trait = bastard } @@ -251,19 +295,15 @@ disinherit_interaction = { multiply = 0 } } + if = { + limit = { scope:is_puppet_action ?= yes } + multiply = 0 + } } } auto_accept = yes - ai_potential = { - is_at_war = no - NOT = { - has_trait = forgiving - } - is_dynast = yes - } - ai_targets = { ai_recipients = dynasty max = 20 @@ -283,21 +323,21 @@ disinherit_interaction = { modifier = { add = -100 - scope:actor = { + scope:puppet_or_actor = { OR = { legitimacy_level = 0 legitimacy_level = 1 } } - scope:recipient = { is_primary_heir_of = scope:actor } + scope:recipient = { is_primary_heir_of = scope:puppet_or_actor } } modifier = { add = 100 scope:recipient = { OR = { - has_relation_rival = scope:actor - has_relation_nemesis = scope:actor + has_relation_rival = scope:puppet_or_actor + has_relation_nemesis = scope:puppet_or_actor } } } @@ -305,7 +345,7 @@ disinherit_interaction = { modifier = { add = 100 scope:recipient = { - is_primary_heir_of = scope:actor + is_primary_heir_of = scope:puppet_or_actor OR = { has_trait = inbred has_trait = intellect_bad_3 @@ -318,7 +358,7 @@ disinherit_interaction = { add = 5 ai_vengefulness >= medium_positive_ai_value scope:recipient = { - is_heir_of = scope:actor + is_heir_of = scope:puppet_or_actor } OR = { AND = { @@ -326,7 +366,7 @@ disinherit_interaction = { has_trait = incestuous } NOT = { is_incestuous_trigger = yes } - trait_is_criminal_in_faith_trigger = { TRAIT = trait:incestuous FAITH = scope:actor.faith GENDER_CHARACTER = scope:recipient } + trait_is_criminal_in_rite_trigger = { TRAIT = trait:incestuous RITE = scope:puppet_or_actor.rite GENDER_CHARACTER = scope:recipient } } AND = { scope:recipient = { @@ -342,7 +382,7 @@ disinherit_interaction = { has_trait = adulterer has_trait = fornicator } - trait_is_criminal_in_faith_trigger = { TRAIT = trait:adulterer FAITH = scope:actor.faith GENDER_CHARACTER = scope:recipient } + trait_is_criminal_in_rite_trigger = { TRAIT = trait:adulterer RITE = scope:puppet_or_actor.rite GENDER_CHARACTER = scope:recipient } } AND = { scope:recipient = { @@ -352,25 +392,21 @@ disinherit_interaction = { has_trait = adulterer has_trait = fornicator } - trait_is_criminal_in_faith_trigger = { TRAIT = trait:fornicator FAITH = scope:actor.faith GENDER_CHARACTER = scope:recipient } + trait_is_criminal_in_rite_trigger = { TRAIT = trait:fornicator RITE = scope:puppet_or_actor.rite GENDER_CHARACTER = scope:recipient } } AND = { scope:recipient = { has_trait = deviant } - NOT = { - is_deviant_trigger = yes - } - trait_is_criminal_in_faith_trigger = { TRAIT = trait:deviant FAITH = scope:actor.faith GENDER_CHARACTER = scope:recipient } + is_deviant_trigger = no + trait_is_criminal_in_rite_trigger = { TRAIT = trait:deviant RITE = scope:puppet_or_actor.rite GENDER_CHARACTER = scope:recipient } } AND = { scope:recipient = { has_trait = witch } - NOT = { - is_witch_trigger = yes - } - trait_is_criminal_in_faith_trigger = { TRAIT = trait:witch FAITH = scope:actor.faith GENDER_CHARACTER = scope:recipient } + is_witch_trigger = no + trait_is_criminal_in_rite_trigger = { TRAIT = trait:witch RITE = scope:puppet_or_actor.rite GENDER_CHARACTER = scope:recipient } } AND = { scope:recipient = { @@ -382,16 +418,14 @@ disinherit_interaction = { type = secret_homosexual } } - trait_is_criminal_in_faith_trigger = { TRAIT = trait:sodomite FAITH = scope:actor.faith GENDER_CHARACTER = scope:recipient } + trait_is_criminal_in_rite_trigger = { TRAIT = trait:sodomite RITE = scope:puppet_or_actor.rite GENDER_CHARACTER = scope:recipient } } AND = { scope:recipient = { has_trait = cannibal } - NOT = { - is_cannibal_trigger = yes - } - trait_is_criminal_in_faith_trigger = { TRAIT = trait:cannibal FAITH = scope:actor.faith GENDER_CHARACTER = scope:recipient } + is_cannibal_trigger = no + trait_is_criminal_in_rite_trigger = { TRAIT = trait:cannibal RITE = scope:puppet_or_actor.rite GENDER_CHARACTER = scope:recipient } } } } @@ -405,8 +439,8 @@ disinherit_interaction = { factor = 0 scope:recipient = { OR = { - has_relation_friend = scope:actor - has_relation_best_friend = scope:actor + has_relation_friend = scope:puppet_or_actor + has_relation_best_friend = scope:puppet_or_actor } } } @@ -428,13 +462,24 @@ disinherit_children_interaction = { desc = disinherit_children_interaction_desc use_diplomatic_range = no + is_available = { + trigger_if = { + limit = { is_ai = yes } + is_dynast = yes + NOT = { + has_trait = forgiving + } + is_at_war = no + } + } + is_shown = { # DLC checking has_fp2_dlc_trigger = yes # Standard check - scope:recipient != scope:actor + scope:recipient != scope:puppet_or_actor - scope:actor.dynasty = { + scope:puppet_or_actor.dynasty ?= { this = scope:recipient.dynasty has_dynasty_perk = fp2_coterie_legacy_5 } @@ -446,11 +491,11 @@ disinherit_children_interaction = { } is_valid = { - scope:actor = { is_parent_of = scope:recipient } + scope:puppet_or_actor = { is_parent_of = scope:recipient } custom_description = { - scope:actor.culture = { + scope:puppet_or_actor.culture = { NOT = { has_cultural_parameter = cannot_disherit } } text = "mystical_ancestors_disinherit" @@ -458,28 +503,29 @@ disinherit_children_interaction = { } is_valid_showing_failures_only = { - scope:actor = { + scope:puppet_or_actor = { prestige >= major_prestige_value } - scope:recipient = { NOT = { has_strong_hook = scope:actor } } + scope:recipient = { NOT = { has_strong_hook = scope:puppet_or_actor } } trigger_if = { limit = { scope:recipient = { NOR = { - is_child_of = scope:actor - is_grandchild_of = scope:actor - is_great_grandchild_of = scope:actor + is_child_of = scope:puppet_or_actor + is_grandchild_of = scope:puppet_or_actor + is_great_grandchild_of = scope:puppet_or_actor } } } custom_description = { - scope:recipient.top_liege = scope:actor.top_liege + scope:recipient.top_liege = scope:puppet_or_actor.top_liege + subject = scope:puppet_or_actor text = "same_realm_as" } } custom_tooltip = { text = cannot_take_overt_hostile_actions_against_diarch.tt - NOT = { scope:recipient ?= scope:actor.diarch } + NOT = { scope:recipient ?= scope:puppet_or_actor.diarch } } } @@ -490,10 +536,16 @@ disinherit_children_interaction = { } on_accept = { - scope:actor = { - stress_impact = { - forgiving = minor_stress_impact_gain - compassionate = minor_stress_impact_gain + scope:puppet_or_actor = { + # Only get stressed/SP penalties if you don't have the parameter + if = { + limit = { + NOT = { sp_hostile_schemes_except_murder_no_stress_or_fulfillment_trigger = yes } + } + stress_and_fulfillment_impact = { + forgiving = minor_stress_impact_gain + compassionate = minor_stress_impact_gain + } } add_tyranny = massive_tyranny_value hidden_effect = { @@ -501,12 +553,34 @@ disinherit_children_interaction = { type = event_toast_effect_neutral title = disinherit_interaction_notification - left_icon = scope:actor + left_icon = scope:puppet_or_actor right_icon = scope:recipient scope:recipient = { show_as_tooltip = { - disinherit_effect = { DISINHERITOR = scope:actor } + disinherit_effect = { DISINHERITOR = scope:puppet_or_actor } + } + } + } + } + } + hidden_effect = { + if = { + limit = { + scope:is_puppet_action ?= yes + } + scope:actor = { + send_interface_toast = { + type = event_toast_effect_neutral + title = disinherit_interaction_notification + + left_icon = scope:puppet_or_actor + right_icon = scope:recipient + + scope:recipient = { + show_as_tooltip = { + disinherit_effect = { DISINHERITOR = scope:puppet_or_actor } + } } } } @@ -514,12 +588,12 @@ disinherit_children_interaction = { } scope:recipient = { - disinherit_effect = { DISINHERITOR = scope:actor } + disinherit_effect = { DISINHERITOR = scope:puppet_or_actor } } # If we're a clan this interaction affects unity add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = minor_unity_loss DESC = clan_unity_disinheritance.desc @@ -534,7 +608,7 @@ disinherit_children_interaction = { if = { limit = { scope:recipient = { - is_landed_or_landless_administrative = yes + is_landed_or_landless_administrative_or_theocratic = yes } } add = massive_prestige_value @@ -542,7 +616,7 @@ disinherit_children_interaction = { if = { limit = { scope:recipient = { - is_landed_or_landless_administrative = no + is_landed_or_landless_administrative_or_theocratic = no any_heir_title = { exists = holder } @@ -551,19 +625,15 @@ disinherit_children_interaction = { add = medium_prestige_value } } + if = { + limit = { scope:is_puppet_action ?= yes } + multiply = 0 + } } } auto_accept = yes - ai_potential = { - is_at_war = no - NOT = { - has_trait = forgiving - } - is_dynast = yes - } - ai_targets = { ai_recipients = dynasty max = 20 @@ -585,8 +655,8 @@ disinherit_children_interaction = { add = 100 scope:recipient = { OR = { - has_relation_rival = scope:actor - has_relation_nemesis = scope:actor + has_relation_rival = scope:puppet_or_actor + has_relation_nemesis = scope:puppet_or_actor } } } @@ -594,7 +664,7 @@ disinherit_children_interaction = { modifier = { add = 100 scope:recipient = { - is_primary_heir_of = scope:actor + is_primary_heir_of = scope:puppet_or_actor OR = { has_trait = inbred has_trait = intellect_bad_3 @@ -607,7 +677,7 @@ disinherit_children_interaction = { add = 5 ai_vengefulness >= medium_positive_ai_value scope:recipient = { - is_heir_of = scope:actor + is_heir_of = scope:puppet_or_actor } OR = { AND = { @@ -615,7 +685,7 @@ disinherit_children_interaction = { has_trait = incestuous } NOT = { is_incestuous_trigger = yes } - trait_is_criminal_in_faith_trigger = { TRAIT = trait:incestuous FAITH = scope:actor.faith GENDER_CHARACTER = scope:recipient } + trait_is_criminal_in_rite_trigger = { TRAIT = trait:incestuous RITE = scope:puppet_or_actor.rite GENDER_CHARACTER = scope:recipient } } AND = { scope:recipient = { @@ -631,7 +701,7 @@ disinherit_children_interaction = { has_trait = adulterer has_trait = fornicator } - trait_is_criminal_in_faith_trigger = { TRAIT = trait:adulterer FAITH = scope:actor.faith GENDER_CHARACTER = scope:recipient } + trait_is_criminal_in_rite_trigger = { TRAIT = trait:adulterer RITE = scope:puppet_or_actor.rite GENDER_CHARACTER = scope:recipient } } AND = { scope:recipient = { @@ -641,25 +711,21 @@ disinherit_children_interaction = { has_trait = adulterer has_trait = fornicator } - trait_is_criminal_in_faith_trigger = { TRAIT = trait:fornicator FAITH = scope:actor.faith GENDER_CHARACTER = scope:recipient } + trait_is_criminal_in_rite_trigger = { TRAIT = trait:fornicator RITE = scope:puppet_or_actor.rite GENDER_CHARACTER = scope:recipient } } AND = { scope:recipient = { has_trait = deviant } - NOT = { - is_deviant_trigger = yes - } - trait_is_criminal_in_faith_trigger = { TRAIT = trait:deviant FAITH = scope:actor.faith GENDER_CHARACTER = scope:recipient } + is_deviant_trigger = no + trait_is_criminal_in_rite_trigger = { TRAIT = trait:deviant RITE = scope:puppet_or_actor.rite GENDER_CHARACTER = scope:recipient } } AND = { scope:recipient = { has_trait = witch } - NOT = { - is_witch_trigger = yes - } - trait_is_criminal_in_faith_trigger = { TRAIT = trait:witch FAITH = scope:actor.faith GENDER_CHARACTER = scope:recipient } + is_witch_trigger = no + trait_is_criminal_in_rite_trigger = { TRAIT = trait:witch RITE = scope:puppet_or_actor.rite GENDER_CHARACTER = scope:recipient } } AND = { scope:recipient = { @@ -671,16 +737,14 @@ disinherit_children_interaction = { type = secret_homosexual } } - trait_is_criminal_in_faith_trigger = { TRAIT = trait:sodomite FAITH = scope:actor.faith GENDER_CHARACTER = scope:recipient } + trait_is_criminal_in_rite_trigger = { TRAIT = trait:sodomite RITE = scope:puppet_or_actor.rite GENDER_CHARACTER = scope:recipient } } AND = { scope:recipient = { has_trait = cannibal } - NOT = { - is_cannibal_trigger = yes - } - trait_is_criminal_in_faith_trigger = { TRAIT = trait:cannibal FAITH = scope:actor.faith GENDER_CHARACTER = scope:recipient } + is_cannibal_trigger = no + trait_is_criminal_in_rite_trigger = { TRAIT = trait:cannibal RITE = scope:puppet_or_actor.rite GENDER_CHARACTER = scope:recipient } } } } @@ -694,8 +758,8 @@ disinherit_children_interaction = { factor = 0 scope:recipient = { OR = { - has_relation_friend = scope:actor - has_relation_best_friend = scope:actor + has_relation_friend = scope:puppet_or_actor + has_relation_best_friend = scope:puppet_or_actor } } } @@ -716,10 +780,18 @@ restore_inheritance_interaction = { interface_priority = 60 - is_shown = { - scope:actor = { + is_available = { + trigger_if = { + limit = { is_ai = yes } is_dynast = yes - dynasty = scope:recipient.dynasty + is_at_war = no + } + } + + is_shown = { + scope:puppet_or_actor ?= { + is_dynast = yes + dynasty ?= scope:recipient.dynasty } scope:recipient = { @@ -728,7 +800,7 @@ restore_inheritance_interaction = { } is_valid_showing_failures_only = { - scope:actor.dynasty ={ + scope:puppet_or_actor.dynasty ={ dynasty_prestige >= miniscule_dynasty_prestige_value } } @@ -740,8 +812,8 @@ restore_inheritance_interaction = { } on_accept = { - scope:actor = { - stress_impact = { + scope:puppet_or_actor = { + stress_and_fulfillment_impact = { vengeful = minor_stress_impact_gain stubborn = minor_stress_impact_gain } @@ -765,7 +837,7 @@ restore_inheritance_interaction = { # If we're a clan this interaction affects unity add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = minor_unity_gain DESC = clan_unity_re_inheritance.desc @@ -775,17 +847,16 @@ restore_inheritance_interaction = { cost = { renown = { - value = scope:actor.dynasty.medium_dynasty_prestige_value + value = scope:puppet_or_actor.dynasty.medium_dynasty_prestige_value + if = { + limit = { scope:is_puppet_action ?= yes } + multiply = 0 + } } } auto_accept = yes - ai_potential = { - is_at_war = no - is_dynast = yes - } - ai_targets = { ai_recipients = dynasty max = 20 @@ -807,8 +878,8 @@ restore_inheritance_interaction = { add = 100 scope:recipient = { OR = { - has_relation_friend = scope:actor - has_relation_best_friend = scope:actor + has_relation_friend = scope:puppet_or_actor + has_relation_best_friend = scope:puppet_or_actor } } } @@ -820,7 +891,7 @@ restore_inheritance_interaction = { modifier = { add = 100 - scope:recipient = scope:actor + scope:recipient = scope:puppet_or_actor } # Unity modifiers @@ -832,8 +903,8 @@ restore_inheritance_interaction = { factor = 0 scope:recipient = { OR = { - has_relation_rival = scope:actor - has_relation_nemesis = scope:actor + has_relation_rival = scope:puppet_or_actor + has_relation_nemesis = scope:puppet_or_actor } } } @@ -847,12 +918,23 @@ denounce_interaction = { desc = denounce_interaction_desc - is_shown = { - scope:recipient != scope:actor - - scope:actor = { + is_available = { + trigger_if = { + limit = { is_ai = yes } + is_adult = yes is_dynast = yes - dynasty = scope:recipient.dynasty + NOT = { + has_trait = forgiving + } + } + } + + is_shown = { + scope:recipient != scope:puppet_or_actor + + scope:puppet_or_actor ?= { + is_dynast = yes + dynasty ?= scope:recipient.dynasty } scope:recipient = { NOT = { @@ -862,13 +944,13 @@ denounce_interaction = { } is_valid_showing_failures_only = { - scope:actor.dynasty = { + scope:puppet_or_actor.dynasty = { dynasty_prestige >= minor_dynasty_prestige_value } - scope:recipient = { NOT = { has_strong_hook = scope:actor } } + scope:recipient = { NOT = { has_strong_hook = scope:puppet_or_actor } } custom_tooltip = { text = cannot_take_overt_hostile_actions_against_diarch.tt - NOT = { scope:recipient ?= scope:actor.diarch } + NOT = { scope:recipient ?= scope:puppet_or_actor.diarch } } } @@ -879,10 +961,16 @@ denounce_interaction = { } on_accept = { - scope:actor = { - stress_impact = { - forgiving = minor_stress_impact_gain - compassionate = minor_stress_impact_gain + scope:puppet_or_actor = { + # Only get stressed/SP penalties if you don't have the parameter + if = { + limit = { + NOT = { sp_hostile_schemes_except_murder_no_stress_or_fulfillment_trigger = yes } + } + stress_and_fulfillment_impact = { + forgiving = minor_stress_impact_gain + compassionate = minor_stress_impact_gain + } } hidden_effect = { @@ -890,12 +978,34 @@ denounce_interaction = { type = event_toast_effect_neutral title = denounce_interaction_notification - left_icon = scope:actor + left_icon = scope:puppet_or_actor right_icon = scope:recipient scope:recipient = { show_as_tooltip = { - denounce_effect = { ACTOR = scope:actor RECIPIENT = scope:recipient } + denounce_effect = { ACTOR = scope:puppet_or_actor RECIPIENT = scope:recipient } + } + } + } + } + } + hidden_effect = { + if = { + limit = { + scope:is_puppet_action ?= yes + } + scope:actor = { + send_interface_toast = { + type = event_toast_effect_neutral + title = denounce_interaction_notification + + left_icon = scope:puppet_or_actor + right_icon = scope:recipient + + scope:recipient = { + show_as_tooltip = { + denounce_effect = { ACTOR = scope:puppet_or_actor RECIPIENT = scope:recipient } + } } } } @@ -903,12 +1013,12 @@ denounce_interaction = { } scope:recipient = { - denounce_effect = { ACTOR = scope:actor RECIPIENT = scope:recipient } + denounce_effect = { ACTOR = scope:puppet_or_actor RECIPIENT = scope:recipient } } # If we're a clan this interaction affects unity add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = minor_unity_loss DESC = clan_unity_denouncement.desc @@ -919,27 +1029,31 @@ denounce_interaction = { cost = { renown = { value = { - add = scope:actor.dynasty.minor_dynasty_prestige_value + add = scope:puppet_or_actor.dynasty.minor_dynasty_prestige_value if = { limit = { scope:recipient = { - is_landed_or_landless_administrative = yes + is_landed_or_landless_administrative_or_theocratic = yes } } - add = scope:actor.dynasty.medium_dynasty_prestige_value + add = scope:puppet_or_actor.dynasty.medium_dynasty_prestige_value } if = { limit = { scope:recipient = { - is_landed_or_landless_administrative = no + is_landed_or_landless_administrative_or_theocratic = no any_heir_title = { exists = holder } } } - add = scope:actor.dynasty.minor_dynasty_prestige_value + add = scope:puppet_or_actor.dynasty.minor_dynasty_prestige_value } } + if = { + limit = { scope:is_puppet_action ?= yes } + multiply = 0 + } } prestige = { value = { @@ -947,7 +1061,7 @@ denounce_interaction = { if = { limit = { scope:recipient = { - is_landed_or_landless_administrative = yes + is_landed_or_landless_administrative_or_theocratic = yes } } add = major_prestige_value @@ -955,7 +1069,7 @@ denounce_interaction = { if = { limit = { scope:recipient = { - is_landed_or_landless_administrative = no + is_landed_or_landless_administrative_or_theocratic = no any_heir_title = { exists = holder } @@ -964,19 +1078,15 @@ denounce_interaction = { add = medium_prestige_value } } + if = { + limit = { scope:is_puppet_action ?= yes } + multiply = 0 + } } } auto_accept = yes - ai_potential = { - is_adult = yes - NOT = { - has_trait = forgiving - } - is_dynast = yes - } - ai_targets = { ai_recipients = dynasty max = 20 @@ -998,8 +1108,8 @@ denounce_interaction = { add = 100 scope:recipient = { OR = { - has_relation_rival = scope:actor - has_relation_nemesis = scope:actor + has_relation_rival = scope:puppet_or_actor + has_relation_nemesis = scope:puppet_or_actor } } } @@ -1013,7 +1123,7 @@ denounce_interaction = { has_trait = incestuous } NOT = { is_incestuous_trigger = yes } - trait_is_criminal_in_faith_trigger = { TRAIT = trait:incestuous FAITH = scope:actor.faith GENDER_CHARACTER = scope:recipient } + trait_is_criminal_in_rite_trigger = { TRAIT = trait:incestuous RITE = scope:puppet_or_actor.rite GENDER_CHARACTER = scope:recipient } } AND = { scope:recipient = { @@ -1029,7 +1139,7 @@ denounce_interaction = { has_trait = adulterer has_trait = fornicator } - trait_is_criminal_in_faith_trigger = { TRAIT = trait:adulterer FAITH = scope:actor.faith GENDER_CHARACTER = scope:recipient } + trait_is_criminal_in_rite_trigger = { TRAIT = trait:adulterer RITE = scope:puppet_or_actor.rite GENDER_CHARACTER = scope:recipient } } AND = { scope:recipient = { @@ -1039,25 +1149,21 @@ denounce_interaction = { has_trait = adulterer has_trait = fornicator } - trait_is_criminal_in_faith_trigger = { TRAIT = trait:fornicator FAITH = scope:actor.faith GENDER_CHARACTER = scope:recipient } + trait_is_criminal_in_rite_trigger = { TRAIT = trait:fornicator RITE = scope:puppet_or_actor.rite GENDER_CHARACTER = scope:recipient } } AND = { scope:recipient = { has_trait = deviant } - NOT = { - is_deviant_trigger = yes - } - trait_is_criminal_in_faith_trigger = { TRAIT = trait:deviant FAITH = scope:actor.faith GENDER_CHARACTER = scope:recipient } + is_deviant_trigger = no + trait_is_criminal_in_rite_trigger = { TRAIT = trait:deviant RITE = scope:puppet_or_actor.rite GENDER_CHARACTER = scope:recipient } } AND = { scope:recipient = { has_trait = witch } - NOT = { - is_witch_trigger = yes - } - trait_is_criminal_in_faith_trigger = { TRAIT = trait:witch FAITH = scope:actor.faith GENDER_CHARACTER = scope:recipient } + is_witch_trigger = no + trait_is_criminal_in_rite_trigger = { TRAIT = trait:witch RITE = scope:puppet_or_actor.rite GENDER_CHARACTER = scope:recipient } } AND = { scope:recipient = { @@ -1069,16 +1175,14 @@ denounce_interaction = { type = secret_homosexual } } - trait_is_criminal_in_faith_trigger = { TRAIT = trait:sodomite FAITH = scope:actor.faith GENDER_CHARACTER = scope:recipient } + trait_is_criminal_in_rite_trigger = { TRAIT = trait:sodomite RITE = scope:puppet_or_actor.rite GENDER_CHARACTER = scope:recipient } } AND = { scope:recipient = { has_trait = cannibal } - NOT = { - is_cannibal_trigger = yes - } - trait_is_criminal_in_faith_trigger = { TRAIT = trait:cannibal FAITH = scope:actor.faith GENDER_CHARACTER = scope:recipient } + is_cannibal_trigger = no + trait_is_criminal_in_rite_trigger = { TRAIT = trait:cannibal RITE = scope:puppet_or_actor.rite GENDER_CHARACTER = scope:recipient } } } } @@ -1092,8 +1196,8 @@ denounce_interaction = { factor = 0 scope:recipient = { OR = { - has_relation_friend = scope:actor - has_relation_best_friend = scope:actor + has_relation_friend = scope:puppet_or_actor + has_relation_best_friend = scope:puppet_or_actor } } } @@ -1107,12 +1211,18 @@ forgive_interaction = { desc = forgive_interaction_desc - is_shown = { - scope:recipient != scope:actor - - scope:actor = { + is_available = { + trigger_if = { + limit = { is_ai = yes } is_dynast = yes - dynasty = scope:recipient.dynasty + is_at_war = no + } + } + + is_shown = { + scope:puppet_or_actor ?= { + is_dynast = yes + dynasty ?= scope:recipient.dynasty } scope:recipient = { has_trait = denounced @@ -1120,7 +1230,7 @@ forgive_interaction = { } is_valid_showing_failures_only = { - scope:actor.dynasty = { + scope:puppet_or_actor.dynasty = { dynasty_prestige >= miniscule_dynasty_prestige_value } } @@ -1132,8 +1242,8 @@ forgive_interaction = { } on_accept = { - scope:actor = { - stress_impact = { + scope:puppet_or_actor = { + stress_and_fulfillment_impact = { vengeful = minor_stress_impact_gain stubborn = minor_stress_impact_gain } @@ -1157,7 +1267,7 @@ forgive_interaction = { # If we're a clan this interaction affects unity add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = minor_unity_gain DESC = clan_unity_forgiveness.desc @@ -1167,17 +1277,16 @@ forgive_interaction = { cost = { renown = { - value = scope:actor.dynasty.miniscule_dynasty_prestige_value + value = scope:puppet_or_actor.dynasty.miniscule_dynasty_prestige_value + if = { + limit = { scope:is_puppet_action ?= yes } + multiply = 0 + } } } auto_accept = yes - ai_potential = { - is_at_war = no - is_dynast = yes - } - ai_targets = { ai_recipients = dynasty max = 20 @@ -1199,8 +1308,8 @@ forgive_interaction = { add = 100 scope:recipient = { OR = { - has_relation_friend = scope:actor - has_relation_best_friend = scope:actor + has_relation_friend = scope:puppet_or_actor + has_relation_best_friend = scope:puppet_or_actor } } } @@ -1212,7 +1321,7 @@ forgive_interaction = { modifier = { add = 100 - scope:recipient = scope:actor + scope:recipient = scope:puppet_or_actor } # Unity modifiers @@ -1224,8 +1333,8 @@ forgive_interaction = { factor = 0 scope:recipient = { OR = { - has_relation_rival = scope:actor - has_relation_nemesis = scope:actor + has_relation_rival = scope:puppet_or_actor + has_relation_nemesis = scope:puppet_or_actor } } } @@ -1248,16 +1357,16 @@ call_dynasty_member_to_war_interaction = { notification_text = CALL_DYNASTY_MEMBER_NOTIFICATION is_shown = { - scope:recipient != scope:actor + scope:recipient != scope:puppet_or_actor - scope:actor = { - is_dynast = yes - religion = scope:recipient.religion - dynasty = scope:recipient.dynasty - house != scope:recipient.house # Use the House Head version instead + scope:puppet_or_actor ?= { any_character_war = { - is_war_leader = scope:actor + is_war_leader = scope:puppet_or_actor } + is_dynast = yes + religion ?= scope:recipient.religion + dynasty ?= scope:recipient.dynasty + house != scope:recipient.house # Use the House Head version instead } scope:recipient = { is_ruler = yes @@ -1265,7 +1374,7 @@ call_dynasty_member_to_war_interaction = { scope:recipient = { NOT = { - target_is_liege_or_above = scope:actor + target_is_liege_or_above = scope:puppet_or_actor } } } @@ -1276,31 +1385,31 @@ call_dynasty_member_to_war_interaction = { has_valid_target_showing_failures_only = { scope:target = { - is_war_leader = scope:actor + is_war_leader = scope:puppet_or_actor } joiner_not_already_in_another_war_with_any_target_war_participants_trigger = { - WARRIOR = scope:actor + WARRIOR = scope:puppet_or_actor JOINER = scope:recipient } } is_valid_showing_failures_only = { - scope:actor.dynasty = { dynasty_prestige >= medium_dynasty_prestige_value } + scope:puppet_or_actor.dynasty = { dynasty_prestige >= medium_dynasty_prestige_value } scope:recipient = { NOT = { government_has_flag = government_is_mercenary } NOT = { government_has_flag = government_is_holy_order } } custom_description = { text = "is_already_in_all_wars" - scope:actor = { + scope:puppet_or_actor = { any_character_war = { NOR = { is_participant = scope:recipient was_called = scope:recipient } OR = { - primary_attacker = scope:actor - primary_defender = scope:actor + primary_attacker = scope:puppet_or_actor + primary_defender = scope:puppet_or_actor } } } @@ -1308,7 +1417,7 @@ call_dynasty_member_to_war_interaction = { } can_be_picked = { - can_join_war_liege_vassal_check_trigger = { WARRIOR = scope:actor JOINER = scope:recipient } + can_join_war_liege_vassal_check_trigger = { WARRIOR = scope:puppet_or_actor JOINER = scope:recipient } } on_auto_accept = { @@ -1329,7 +1438,7 @@ call_dynasty_member_to_war_interaction = { limit = { exists = scope:target } - scope:actor = { + scope:puppet_or_actor = { trigger_event = call_ally.0100 } } @@ -1344,9 +1453,9 @@ call_dynasty_member_to_war_interaction = { scope:target = { if = { limit = { - is_attacker = scope:actor + is_attacker = scope:puppet_or_actor } - scope:actor = { + scope:puppet_or_actor = { add_opinion = { modifier = rejected_call_to_offensive_war target = scope:recipient @@ -1354,7 +1463,7 @@ call_dynasty_member_to_war_interaction = { } } else = { - scope:actor = { + scope:puppet_or_actor = { add_opinion = { modifier = rejected_call_to_defensive_war target = scope:recipient @@ -1370,7 +1479,7 @@ call_dynasty_member_to_war_interaction = { } } } - scope:actor.dynasty = { + scope:puppet_or_actor.dynasty = { add_dynasty_prestige = medium_dynasty_prestige_loss } } @@ -1379,7 +1488,7 @@ call_dynasty_member_to_war_interaction = { limit = { exists = scope:target } - scope:actor = { + scope:puppet_or_actor = { trigger_event = call_ally.0101 } } @@ -1408,7 +1517,7 @@ call_dynasty_member_to_war_interaction = { add = -1000 exists = scope:recipient.player_heir trigger_if = { - limit = { scope:target.casus_belli.primary_defender = scope:actor } + limit = { scope:target.casus_belli.primary_defender = scope:puppet_or_actor } scope:target.casus_belli.primary_attacker = scope:recipient.player_heir } trigger_else = { @@ -1421,7 +1530,7 @@ call_dynasty_member_to_war_interaction = { add = -1000 scope:recipient = { trigger_if = { - limit = { scope:target.casus_belli.primary_defender = scope:actor } + limit = { scope:target.casus_belli.primary_defender = scope:puppet_or_actor } any_spouse = { this = scope:target.casus_belli.primary_attacker } @@ -1446,7 +1555,7 @@ call_dynasty_member_to_war_interaction = { opinion_modifier = { # Opinion Factor who = scope:recipient - opinion_target = scope:actor + opinion_target = scope:puppet_or_actor multiplier = 1.0 desc = AI_OPINION_REASON } @@ -1459,17 +1568,17 @@ call_dynasty_member_to_war_interaction = { modifier = { # Tends to join defensive wars add = 50 - scope:target.casus_belli.primary_defender = scope:actor + scope:target.casus_belli.primary_defender = scope:puppet_or_actor desc = DEFENSIVE_WAR_REASON } compare_modifier = { # Likes fighting infidels trigger = { - scope:recipient.faith = scope:actor.faith + scope:recipient.faith = scope:puppet_or_actor.faith OR = { AND = { scope:target.casus_belli.primary_attacker = { - this = scope:actor + this = scope:puppet_or_actor faith = { faith_hostility_level = { target = scope:target.casus_belli.primary_defender.faith @@ -1480,10 +1589,10 @@ call_dynasty_member_to_war_interaction = { } AND = { scope:target.casus_belli.primary_defender = { - this = scope:actor + this = scope:puppet_or_actor faith = { faith_hostility_level = { - target = scope:target.casus_belli.primary_defender.faith + target = scope:target.casus_belli.primary_attacker.faith value >= religious_cb_enabled_hostility_level } } @@ -1500,7 +1609,7 @@ call_dynasty_member_to_war_interaction = { modifier = { # Reluctant to attack another ally add = -50 - scope:target.casus_belli.primary_attacker = scope:actor + scope:target.casus_belli.primary_attacker = scope:puppet_or_actor scope:recipient = { is_allied_to = scope:target.casus_belli.primary_defender } @@ -1509,7 +1618,7 @@ call_dynasty_member_to_war_interaction = { modifier = { # Reluctant to defend against another ally add = -25 - scope:target.casus_belli.primary_defender = scope:actor + scope:target.casus_belli.primary_defender = scope:puppet_or_actor scope:recipient = { is_allied_to = scope:target.casus_belli.primary_attacker } @@ -1518,8 +1627,8 @@ call_dynasty_member_to_war_interaction = { modifier = { # Reluctant to join wars against religious brethren. add = -50 - scope:recipient.faith != scope:actor.faith - scope:target.casus_belli.primary_attacker = scope:actor + scope:recipient.faith != scope:puppet_or_actor.faith + scope:target.casus_belli.primary_attacker = scope:puppet_or_actor scope:target.casus_belli.primary_defender.faith = scope:recipient.faith scope:target.casus_belli.war = { OR = { @@ -1539,7 +1648,7 @@ call_dynasty_member_to_war_interaction = { auto_accept = { custom_description = { text = "spending_hook" - subject = scope:actor + subject = scope:puppet_or_actor object = scope:recipient scope:hook = yes } @@ -1547,7 +1656,7 @@ call_dynasty_member_to_war_interaction = { send_option = { is_valid = { - scope:actor = { + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } @@ -1555,7 +1664,7 @@ call_dynasty_member_to_war_interaction = { localization = SCHEME_HOOK } should_use_extra_icon = { - scope:actor = { has_usable_hook = scope:recipient } + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } extra_icon = "gfx/interface/icons/character_interactions/hook_icon.dds" @@ -1569,27 +1678,39 @@ dynast_claim_title_interaction = { desc = dynast_claim_title_interaction_desc target_type = title target_filter = recipient_domain_titles + show_all_targets = no ignores_pending_interaction_block = yes - cost = { renown = scope:actor.dynasty.major_dynasty_prestige_value } + cost = { + renown = { + value = dynast_claim_title_interaction_cost_value + if = { + limit = { scope:is_puppet_action ?= yes } + multiply = 0 + } + } + } is_shown = { - scope:recipient != scope:actor - - scope:actor = { + scope:puppet_or_actor ?= { + this != scope:recipient is_dynast = yes - religion = scope:recipient.religion - dynasty = scope:recipient.dynasty + religion ?= scope:recipient.religion + dynasty ?= scope:recipient.dynasty } scope:recipient = { is_playable_character = yes + any_held_title = { + is_landless_type_title = no + } } } - can_be_picked = { - custom_description = { - scope:target = { NOT = { any_claimant = { this = scope:actor } } } - text = "already_have_a_claim_on_this_title" + can_be_picked_title = { + custom_tooltip = { + NOT = { any_claimant = { this = scope:puppet_or_actor } } + text = "ALREADY_HAVE_CLAIM_ON_THIS_TITLE" } + is_landless_type_title = no } is_valid_showing_failures_only = { @@ -1597,13 +1718,22 @@ dynast_claim_title_interaction = { scope:recipient = { any_held_title = { title_tier >= county - NOT = { any_claimant = { this = scope:actor } } + NOT = { any_claimant = { this = scope:puppet_or_actor } } + is_landless_type_title = no } } object = scope:recipient text = "already_have_claims_on_all_titles" } + trigger_if = { + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + dynasty ?= { + dynasty_prestige >= dynast_claim_title_interaction_cost_value + } + } + } } on_auto_accept = { @@ -1613,14 +1743,23 @@ dynast_claim_title_interaction = { } on_accept = { + if = { + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + if = { + limit = { dynast_claim_title_interaction_cost_value > 0 } + dynasty ?= { add_dynasty_prestige = { value = { add = dynast_claim_title_interaction_cost_value multiply = -1 } } } + } + } + } dynast_claim_title_effect = yes - scope:actor = { + scope:puppet_or_actor = { hidden_effect = { send_interface_toast = { type = event_toast_effect_neutral title = dynast_claim_title_interaction_notification - left_icon = scope:actor + left_icon = scope:puppet_or_actor right_icon = scope:recipient show_as_tooltip = { @@ -1629,10 +1768,30 @@ dynast_claim_title_interaction = { } } } + hidden_effect = { + if = { + limit = { + scope:is_puppet_action ?= yes + } + scope:actor = { + send_interface_toast = { + type = event_toast_effect_neutral + title = dynast_claim_title_interaction_notification + + left_icon = scope:puppet_or_actor + right_icon = scope:recipient + + show_as_tooltip = { + dynast_claim_title_effect = yes + } + } + } + } + } # If we're a clan this interaction affects unity add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = medium_unity_loss DESC = clan_unity_title_claim.desc @@ -1649,29 +1808,29 @@ dynast_end_dynasty_wars_interaction = { desc = dynast_end_dynasty_wars_interaction_desc is_shown = { - scope:actor != scope:recipient + scope:puppet_or_actor != scope:recipient - scope:actor = { + scope:puppet_or_actor ?= { is_dynast = yes - religion = scope:recipient.religion - dynasty = scope:recipient.dynasty + religion ?= scope:recipient.religion + dynasty ?= scope:recipient.dynasty } scope:recipient = { is_playable_character = yes any_character_war = { - primary_defender != scope:actor - primary_attacker = scope:recipient - primary_defender.dynasty = scope:recipient.dynasty + primary_defender != scope:puppet_or_actor + primary_attacker ?= scope:recipient + primary_defender.dynasty ?= scope:recipient.dynasty } } } is_valid_showing_failures_only = { - scope:actor.dynasty = { + scope:puppet_or_actor.dynasty = { dynasty_prestige >= medium_dynasty_prestige_value } - scope:actor = { + scope:puppet_or_actor = { NOT = { is_at_war_with = scope:recipient } @@ -1686,7 +1845,7 @@ dynast_end_dynasty_wars_interaction = { on_accept = { - scope:actor = { + scope:puppet_or_actor = { hidden_effect = { send_interface_message = { type = event_dynasty_neutral @@ -1710,21 +1869,21 @@ dynast_legitimize_bastard_interaction = { desc = dynast_legitimize_bastard_interaction_desc is_shown = { - scope:actor = { + scope:puppet_or_actor ?= { this = scope:recipient.dynasty.dynast - religion = scope:recipient.religion + religion ?= scope:recipient.religion house != scope:recipient.house - faith = { has_doctrine_parameter = bastards_legitimize } + rite ?= { rite_has_parameter = bastards_legitimize } } scope:recipient = { has_trait = bastard - this != scope:actor - faith = { has_doctrine_parameter = bastards_legitimize } + this != scope:puppet_or_actor + rite ?= { rite_has_parameter = bastards_legitimize } } } is_valid = { - scope:actor.dynasty = { + scope:puppet_or_actor.dynasty = { dynasty_prestige >= medium_dynasty_prestige_value } } @@ -1732,12 +1891,18 @@ dynast_legitimize_bastard_interaction = { auto_accept = yes cost = { - renown = scope:actor.dynasty.medium_dynasty_prestige_value + renown = { + value = scope:puppet_or_actor.dynasty.medium_dynasty_prestige_value + if = { + limit = { scope:is_puppet_action ?= yes } + multiply = 0 + } + } } on_accept = { - scope:actor = { - stress_impact = { + scope:puppet_or_actor = { + stress_and_fulfillment_impact = { arrogant = minor_stress_impact_gain } send_interface_message = { @@ -1748,7 +1913,7 @@ dynast_legitimize_bastard_interaction = { scope:recipient = { add_trait_force_tooltip = legitimized_bastard add_opinion = { - target = scope:actor + target = scope:puppet_or_actor modifier = legitimized_me_opinion } } @@ -1762,17 +1927,17 @@ dynast_legitimize_bastard_interaction = { every_parent = { limit = { is_playable_character = yes - this != scope:actor + this != scope:puppet_or_actor } hidden_effect = { #Nudge towards friendship if = { limit = { NOR = { - has_relation_friend = scope:actor - has_relation_potential_friend = scope:actor + has_relation_friend = scope:puppet_or_actor + has_relation_potential_friend = scope:puppet_or_actor } } - set_relation_potential_friend = scope:actor + set_relation_potential_friend = scope:puppet_or_actor } } trigger_event = bastard_interaction.0010 @@ -1780,13 +1945,13 @@ dynast_legitimize_bastard_interaction = { every_sibling = { limit = { is_playable_character = yes - this != scope:actor + this != scope:puppet_or_actor } trigger_event = bastard_interaction.0010 } } - scope:actor = { + scope:puppet_or_actor = { if = { limit = { has_character_modifier = oath_of_children @@ -1810,25 +1975,47 @@ dynast_legitimize_bastard_interaction = { # use_diplomatic_range = no # common_interaction = yes # -# is_shown = { -# scope:recipient != scope:actor -# -# scope:actor = { +# is_available = { +# trigger_if = { +# limit = { is_ai = yes } # is_dynast = yes -# dynasty = scope:recipient.dynasty +# dynasty ?= { +# has_dynasty_perk = fp1_adventure_legacy_1 +# } +# +# NOR = { +# faith ?= { +# has_doctrine_parameter = pacifist +# } +# this = title:e_byzantium.holder +# is_at_war_with = title:e_byzantium.holder +# has_truce = title:e_byzantium.holder +# } +# +# exists = title:e_byzantium.holder +# is_at_war = no +# } +# } +# +# is_shown = { +# scope:recipient != scope:puppet_or_actor +# +# scope:puppet_or_actor ?= { +# is_dynast = yes +# dynasty ?= scope:recipient.dynasty # -# dynasty = { +# dynasty ?= { # has_dynasty_perk = fp1_adventure_legacy_1 # } # # exists = title:e_byzantium.holder # NOR = { -# faith = { -# has_doctrine_parameter = pacifist_opinion_active +# faith ?= { +# has_doctrine_parameter = pacifist # } # this = title:e_byzantium.holder -# has_truce = title:e_byzantium.holder # is_at_war_with = title:e_byzantium.holder +# has_truce = title:e_byzantium.holder # } # } # } @@ -1836,7 +2023,7 @@ dynast_legitimize_bastard_interaction = { # cooldown = { years = 2 } # # is_valid_showing_failures_only = { -# scope:actor = { +# scope:puppet_or_actor = { # is_at_war = no # NOT = { # has_relation_rival = title:e_byzantium.holder @@ -1875,14 +2062,15 @@ dynast_legitimize_bastard_interaction = { # limit = { # scope:recipient = { # NOR = { -# is_child_of = scope:actor -# is_grandchild_of = scope:actor -# is_great_grandchild_of = scope:actor +# is_child_of = scope:puppet_or_actor +# is_grandchild_of = scope:puppet_or_actor +# is_great_grandchild_of = scope:puppet_or_actor # } # } # } # custom_description = { -# scope:recipient.top_liege = scope:actor.top_liege +# scope:recipient.top_liege = scope:puppet_or_actor.top_liege +# subject = scope:puppet_or_actor # text = "same_realm_as" # } # } @@ -1900,8 +2088,8 @@ dynast_legitimize_bastard_interaction = { # } # } # -# scope:actor = { -# stress_impact = { +# scope:puppet_or_actor = { +# stress_and_fulfillment_impact = { # paranoid = minor_stress_impact_gain # } # hidden_effect = { @@ -1916,6 +2104,24 @@ dynast_legitimize_bastard_interaction = { # } # } # } +# hidden_effect = { +# if = { +# limit = { +# scope:is_puppet_action ?= yes +# } +# scope:actor = { +# send_interface_toast = { +# type = event_toast_effect_neutral +# title = send_to_varangian_guard_interaction_toast +# +# left_icon = scope:recipient +# right_icon = scope:emperor +# +# custom_tooltip = send_to_varangian_guard_interaction_toast_desc +# } +# } +# } +# } # # scope:recipient = { # save_scope_as = varangian_candidate @@ -1939,7 +2145,7 @@ dynast_legitimize_bastard_interaction = { # # # If we're a clan this interaction affects unity # add_clan_unity_interaction_effect = { -# CHARACTER = scope:actor +# CHARACTER = scope:puppet_or_actor # TARGET = scope:recipient # VALUE = miniscule_unity_loss # DESC = clan_unity_vaering.desc @@ -1950,30 +2156,15 @@ dynast_legitimize_bastard_interaction = { # cost = { # prestige = { # value = 350 +# if = { +# limit = { scope:is_puppet_action ?= yes } +# multiply = 0 +# } # } # } # # auto_accept = yes # -# ai_potential = { -# is_at_war = no -# is_dynast = yes -# -# dynasty = { -# has_dynasty_perk = fp1_adventure_legacy_1 -# } -# -# exists = title:e_byzantium.holder -# NOR = { -# faith = { -# has_doctrine_parameter = pacifist_opinion_active -# } -# this = title:e_byzantium.holder -# has_truce = title:e_byzantium.holder -# is_at_war_with = title:e_byzantium.holder -# } -# } -# # ai_targets = { # ai_recipients = children # max = 10 @@ -1992,4 +2183,4 @@ dynast_legitimize_bastard_interaction = { # base = 100 # } #} -# \ No newline at end of file + diff --git a/common/character_interactions/00_faction_interactions.txt b/common/character_interactions/00_faction_interactions.txt index 0d0ff65db..12aff73d3 100644 --- a/common/character_interactions/00_faction_interactions.txt +++ b/common/character_interactions/00_faction_interactions.txt @@ -10,12 +10,22 @@ force_join_faction_interaction = { greeting = positive notification_text = FORCE_JOIN_FACTION_NOTIFICATION + is_available = { + is_a_faction_member = yes + trigger_if = { + limit = { is_ai = yes } + top_liege != this + + # Only force others to join a faction if you joined by your own free will + is_forced_into_faction = no + } + } + is_shown = { scope:actor = { - is_a_faction_member = yes - liege = scope:recipient.liege + liege ?= scope:recipient.liege NOR = { - joined_faction = scope:recipient.joined_faction + joined_faction ?= scope:recipient.joined_faction scope:recipient = scope:actor.liege } } @@ -24,7 +34,7 @@ force_join_faction_interaction = { is_valid_showing_failures_only = { scope:actor = { trigger_if = { - limit = { government_allows = administrative } + limit = { government_has_mechanic = administrative } custom_tooltip = { text = force_join_faction_admin_requirement_desc OR = { @@ -49,8 +59,8 @@ force_join_faction_interaction = { limit = { is_a_faction_member = yes } joined_faction.faction_leader ?= { is_ai = yes } } - is_forced_into_faction = no - can_join_faction = scope:actor.joined_faction + is_forced_into_faction = no + can_join_faction = scope:actor.joined_faction } custom_description = { text = barons_joining_independence_factions @@ -60,7 +70,7 @@ force_join_faction_interaction = { } } } - + on_accept = { scope:actor = { send_interface_message = { @@ -106,15 +116,15 @@ force_join_faction_interaction = { exists = scope:recipient scope:actor ?= { has_strong_usable_hook = scope:recipient } } - flag = hook + flag = hook localization = GENERIC_SPEND_A_HOOK } #Spend influence send_option = { is_shown = { - scope:actor = { government_allows = administrative } - scope:actor.top_liege ?= { government_allows = administrative } + scope:actor = { government_has_flag = government_has_influence } + scope:actor.top_liege ?= { government_has_flag = government_has_influence } } is_valid = { # Convincing someone with influence is not available if they hate you or love the liege scope:actor ?= { influence >= { value = scope:actor.monumental_influence_value multiply = 2 } } @@ -123,12 +133,12 @@ force_join_faction_interaction = { NOT = { opinion = { target = scope:recipient.liege value >= 50 } } } } - flag = influence + flag = influence localization = SPEND_INFLUENCE } send_options_exclusive = yes - + # AI ai_targets = { ai_recipients = peer_vassals @@ -141,18 +151,10 @@ force_join_faction_interaction = { empire = 12 hegemony = 0 } - - ai_potential = { - top_liege != this - is_a_faction_member = yes - - # Only force others to join a faction if you joined by your own free will - is_forced_into_faction = no - } - + ai_will_do = { base = 100 - + # Don't steal players' factions' members modifier = { factor = 0 diff --git a/common/character_interactions/00_gift.txt b/common/character_interactions/00_gift.txt index 97f680fd7..63d7ec566 100644 --- a/common/character_interactions/00_gift.txt +++ b/common/character_interactions/00_gift.txt @@ -38,11 +38,24 @@ gift_interaction = { hegemony = 36 } - is_shown = { - scope:recipient != scope:actor + is_available = { + trigger_if = { + limit = { is_ai = yes } + ai_greed < medium_positive_ai_value + short_term_gold >= gift_interaction_cutoff + ai_should_focus_on_building_in_their_capital = no + is_available_at_peace_ai_adult = yes + NOR = { + has_trait = greedy + has_variable = conqueror + } + } + } + is_shown = { # Prioritize paying back loans first - scope:actor = { + scope:puppet_or_actor ?= { + this != scope:recipient trigger_if = { limit = { exists = var:loan_amount_owed @@ -50,6 +63,11 @@ gift_interaction = { } NOT = { var:loan_holder = scope:recipient } } + # A landless puppet has nothing to gift that is not already the puppeteer's + trigger_if = { + limit = { scope:recipient = scope:actor } + is_ruler = yes + } } } @@ -69,9 +87,17 @@ gift_interaction = { highlighted_reason = HIGHLIGHTED_FAMILY_RATING is_valid_showing_failures_only = { - scope:actor.gold >= gift_value - scope:recipient = { - NOT = { is_imprisoned_by = scope:actor } + scope:puppet_or_actor.gold >= gift_value + scope:recipient = { + NOT = { is_imprisoned_by = scope:puppet_or_actor } + } + # puppet_or_actor only differs from the actor on puppet actions, where the puppet's own purse pays + trigger_if = { + limit = { scope:is_puppet_action ?= yes } + custom_tooltip = { + text = puppet_gift_cooldown_tt + NOT = { scope:puppet_or_actor = { has_variable = puppet_gift_cooldown } } + } } } @@ -87,10 +113,10 @@ gift_interaction = { if = { limit = { NAND = { - has_relation_friend = scope:actor - has_relation_lover = scope:actor - has_relation_soulmate = scope:actor - has_relation_best_friend = scope:actor + has_relation_friend = scope:puppet_or_actor + has_relation_lover = scope:puppet_or_actor + has_relation_soulmate = scope:puppet_or_actor + has_relation_best_friend = scope:puppet_or_actor } } gifting_leads_towards_friendship_effect = yes @@ -99,14 +125,14 @@ gift_interaction = { # HOUSE RELATIONS if = { limit = { - scope:actor = { + scope:puppet_or_actor = { is_house_head = yes } scope:recipient = { is_house_head = yes NOT = { has_opinion_modifier = { - target = scope:actor + target = scope:puppet_or_actor modifier = gift_opinion } } @@ -114,29 +140,30 @@ gift_interaction = { } scope:recipient.house = { change_house_relation_effect = { - HOUSE = scope:actor.house + HOUSE = scope:puppet_or_actor.house VALUE = house_relation_improve_medium_value REASON = sent_a_gift - CHAR = scope:actor + CHAR = scope:puppet_or_actor TARGET_CHAR = scope:recipient TITLE = scope:dummy_gender } } } - scope:actor = { + scope:puppet_or_actor = { # Warning for multiple gifts if = { limit = { + scope:actor != scope:recipient scope:recipient = { has_opinion_modifier = { - target = scope:actor + target = scope:puppet_or_actor modifier = gift_opinion } } } custom_tooltip = ALREADY_SENT_GIFT_WARNING } - + send_interface_message = { type = event_gold_neutral title = gift_interaction_notification @@ -145,53 +172,92 @@ gift_interaction = { gold = gift_value target = scope:recipient } - stress_impact = { + stress_and_fulfillment_impact = { greedy = medium_stress_impact_gain } if = { limit = { scope:recipient = { NOT = { - is_heir_of = scope:actor + is_heir_of = scope:puppet_or_actor } } } - stress_impact = { + stress_and_fulfillment_impact = { generous = medium_stress_impact_loss } } - - #FP3 Tenet Communal Possessions Perk - piety gain for gift giving. if = { limit = { - scope:actor = { - faith = { - has_doctrine_parameter = piety_from_gifts_active + scope:puppet_or_actor = { + has_personal_tenet_flag = tenet_simony_personal_gifts + } + } + # Doubled: personal pick has stress_loss_mult -0.5 + add_stress = medium_stress_loss + change_spiritual_fulfillment = miniscule_spiritual_fulfillment_value + } + + #FP3 Tenet Communal Possessions Perk - piety gain for gift giving. + if = { + limit = { + scope:puppet_or_actor = { + rite = { + rite_has_parameter = piety_from_gifts_active } } + NOT = { + scope:recipient = { + has_opinion_modifier = { + target = scope:puppet_or_actor + modifier = gift_opinion + } + } + } } - scope:actor = { + scope:puppet_or_actor = { add_piety = minor_piety_gain } } - + + if = { + limit = { + scope:puppet_or_actor = { + has_personal_tenet_flag = tenet_philanthropia_alms_to_the_destitute + } + scope:recipient = { is_in_debt = yes } + NOT = { + scope:recipient = { + has_opinion_modifier = { + target = scope:puppet_or_actor + modifier = gift_opinion + } + } + } + } + scope:puppet_or_actor = { + add_prestige = minor_prestige_gain + add_piety = minor_piety_gain + } + } + # Check if the target already has been sent a gift or not. If not, apply the following effects if = { limit = { NOT = { scope:recipient = { has_opinion_modifier = { - target = scope:actor + target = scope:puppet_or_actor modifier = gift_opinion } } } } - -# # Struggle Catalyst + + # Struggle Catalyst # if = { # limit = { -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # involvement = involved # phase_has_catalyst = catalyst_gift_independent_ruler @@ -203,13 +269,13 @@ gift_interaction = { # } # } # hidden_effect = { -# scope:actor = { +# scope:puppet_or_actor = { # every_character_struggle = { # involvement = involved # limit = { phase_has_catalyst = catalyst_gift_independent_ruler } # activate_struggle_catalyst = { # catalyst = catalyst_gift_independent_ruler -# character = scope:actor +# character = scope:puppet_or_actor # } # } # } @@ -218,10 +284,10 @@ gift_interaction = { # if = { # limit = { # fp3_struggle_involves_one_supporter_and_one_detractor = { -# FIRST = scope:actor +# FIRST = scope:puppet_or_actor # SECOND = scope:recipient # } -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # #involvement = involved # activate_struggle_catalyst_secondary_character_involvement_either_trigger = { @@ -232,7 +298,7 @@ gift_interaction = { # } # } # hidden_effect = { -# scope:actor = { +# scope:puppet_or_actor = { # every_character_struggle = { # #involvement = involved # limit = { @@ -243,31 +309,31 @@ gift_interaction = { # } # activate_struggle_catalyst = { # catalyst = catalyst_gift_supporter_detractor_ruler -# character = scope:actor +# character = scope:puppet_or_actor # } # log_debug_variable_for_persian_struggle_effect = { VAR = concession_catalyst_gift_supporter_detractor_ruler } # } # } # } # } - + # FP2 Urbanism Legacy Perk 2: increase cultural acceptance when gifting a republican vassal if = { limit = { - scope:actor = { + scope:puppet_or_actor = { dynasty ?= { has_dynasty_perk = fp2_urbanism_legacy_4 } } scope:recipient = { AND = { - is_vassal_of = scope:actor + is_vassal_of = scope:puppet_or_actor government_has_flag = government_is_republic } } - scope:actor.culture != scope:recipient.capital_province.county.culture + scope:puppet_or_actor.culture != scope:recipient.capital_province.county.culture } scope:recipient.capital_province.county.culture = { change_cultural_acceptance = { - target = scope:actor.culture + target = scope:puppet_or_actor.culture value = { value = 20 multiply = scope:recipient.capital_province.county.development_level @@ -278,21 +344,66 @@ gift_interaction = { } } } - + # Let's apply the opinion modifier last, as to apply everything else correctly first - scope:recipient = { - add_opinion = { - target = scope:actor - modifier = gift_opinion - opinion = send_gift_opinion + # Don't grant the puppeteer opinion of their own puppet when they are the gift recipient + if = { + limit = { + scope:actor != scope:recipient + scope:puppet_or_actor = { + NOT = { has_personal_tenet_flag = tenet_simony_personal_gifts } + } } + scope:recipient = { + add_opinion = { + target = scope:puppet_or_actor + modifier = gift_opinion + opinion = send_gift_opinion + } + } + } + if = { + limit = { + scope:actor != scope:recipient + scope:puppet_or_actor = { + has_personal_tenet_flag = tenet_simony_personal_gifts + } + } + scope:recipient = { + add_opinion = { + target = scope:puppet_or_actor + modifier = friendliness_opinion + opinion = send_gift_opinion + } + } + } + } + if = { + limit = { + scope:actor != scope:recipient + scope:puppet_or_actor = { + has_personal_tenet_flag = tenet_simony_personal_gifts + } + scope:recipient = { + NOT = { + has_opinion_modifier = { + target = scope:puppet_or_actor + modifier = friendliness_opinion + } + } + } + } + progress_towards_friend_effect = { + REASON = friend_simony_gift + CHARACTER = scope:recipient + OPINION = 0 } } if = { # for tutorial purposes limit = { is_ai = no - scope:recipient = { is_child_of = scope:actor } + scope:recipient = { is_child_of = scope:puppet_or_actor } } add_character_flag = { flag = tutorial_sent_gift @@ -303,13 +414,11 @@ gift_interaction = { if = { limit = { is_ruler = yes - government_allows = administrative + government_has_flag = government_has_influence scope:recipient = { is_ruler = yes - government_allows = administrative - any_held_title = { - is_noble_family_title = yes - } + government_has_flag = government_has_influence + is_governor_or_landless_admin = yes } } if = { @@ -319,7 +428,7 @@ gift_interaction = { house = { is_dominant_family = yes } - this = scope:actor.top_liege + this = scope:puppet_or_actor.top_liege } influence_level >= 5 } @@ -336,7 +445,7 @@ gift_interaction = { house = { is_dominant_family = yes } - this = scope:actor.top_liege + this = scope:puppet_or_actor.top_liege } influence_level >= 3 } @@ -353,7 +462,7 @@ gift_interaction = { house = { is_dominant_family = yes } - this = scope:actor.top_liege + this = scope:puppet_or_actor.top_liege } } } @@ -369,7 +478,7 @@ gift_interaction = { house = { is_powerful_family = yes } - this = scope:actor.top_liege + this = scope:puppet_or_actor.top_liege } influence_level >= 5 } @@ -386,7 +495,7 @@ gift_interaction = { house = { is_powerful_family = yes } - this = scope:actor.top_liege + this = scope:puppet_or_actor.top_liege } influence_level >= 3 } @@ -403,7 +512,7 @@ gift_interaction = { house = { is_powerful_family = yes } - this = scope:actor.top_liege + this = scope:puppet_or_actor.top_liege } } } @@ -435,8 +544,20 @@ gift_interaction = { } } } + if = { + limit = { + scope:is_puppet_action ?= yes + scope:actor = { is_ai = no } + } + scope:puppet_or_actor = { + set_variable = { + name = puppet_gift_cooldown + years = 5 + } + } + } } - + ai_accept = { base = 0 modifier = { @@ -445,16 +566,16 @@ gift_interaction = { } # Struggle motive - modifier = { - desc = AI_STRUGGLE_INTENT - scope:recipient = { - top_liege = this - any_character_struggle = { - involvement = involved - } - } - add = { - value = 0 +# modifier = { +# desc = AI_STRUGGLE_INTENT +# scope:recipient = { +# top_liege = this +# any_character_struggle = { +# involvement = involved +# } +# } +# add = { +# value = 0 # if = { # limit = { # scope:recipient = { @@ -476,76 +597,77 @@ gift_interaction = { # } # add = 200 # } - } - } +# } +# } } - - ai_potential = { - is_available_at_peace_ai_adult = yes - ai_greed < medium_positive_ai_value - short_term_gold >= gift_interaction_cutoff - NOT = { - has_trait = greedy - } - NOT = { has_variable = conqueror } - ai_should_focus_on_building_in_their_capital = no - } - + auto_accept = { custom_description = { - text = auto_accept_interaction_ai + text = auto_accept_interaction_ai object = scope:recipient scope:recipient = { is_ai = yes } } } - + ai_min_reply_days = 1 ai_max_reply_days = 1 - + ai_will_do = { base = 100 - + modifier = { # Do not send double-gifts factor = 0 scope:recipient = { has_opinion_modifier = { - target = scope:actor + target = scope:puppet_or_actor modifier = gift_opinion } } } - + modifier = { # Do not repeat Simony gifts + factor = 0 + scope:puppet_or_actor = { + has_personal_tenet_flag = tenet_simony_personal_gifts + } + scope:recipient = { + has_opinion_modifier = { + target = scope:puppet_or_actor + modifier = friendliness_opinion + } + } + } + modifier = { # Basic Filtering factor = 0 scope:recipient = { NOR = { AND = { # Bankrupt lovers, friends and a bankrupt liege should be considered OR = { - scope:actor = { + scope:puppet_or_actor = { any_liege_or_above = { this = scope:recipient } } - has_secret_relation_lover = scope:actor - has_relation_lover = scope:actor - has_relation_soulmate = scope:actor - has_relation_friend = scope:actor - has_relation_best_friend = scope:actor + has_secret_relation_lover = scope:puppet_or_actor + has_relation_lover = scope:puppet_or_actor + has_relation_soulmate = scope:puppet_or_actor + has_relation_friend = scope:puppet_or_actor + has_relation_best_friend = scope:puppet_or_actor } gold < 0 } AND = { # Generous characters will give gifts to their friends/lovers is_ruler = yes OR = { - has_secret_relation_lover = scope:actor - has_relation_lover = scope:actor - has_relation_soulmate = scope:actor - has_relation_friend = scope:actor - has_relation_best_friend = scope:actor + has_secret_relation_lover = scope:puppet_or_actor + has_relation_lover = scope:puppet_or_actor + has_relation_soulmate = scope:puppet_or_actor + has_relation_friend = scope:puppet_or_actor + has_relation_best_friend = scope:puppet_or_actor } - scope:actor = { + scope:puppet_or_actor = { OR = { ai_greed <= high_negative_ai_value AND = { @@ -560,10 +682,10 @@ gift_interaction = { AND = { # Characters with the Generous Cultural Tradition will give gifts to more people is_ruler = yes OR = { - is_allied_to = scope:actor - is_close_or_extended_family_of = scope:actor + is_allied_to = scope:puppet_or_actor + is_close_or_extended_family_of = scope:puppet_or_actor } - scope:actor = { + scope:puppet_or_actor = { ai_greed < 0 culture = { has_cultural_parameter = gives_more_gifts @@ -572,13 +694,13 @@ gift_interaction = { } AND = { # Characters with the loyal trait more likely to give gifts to friends/lieges OR = { - scope:actor.liege ?= this - has_relation_friend = scope:actor - has_relation_best_friend = scope:actor - is_allied_to = scope:actor - is_close_or_extended_family_of = scope:actor + scope:puppet_or_actor.liege ?= this + has_relation_friend = scope:puppet_or_actor + has_relation_best_friend = scope:puppet_or_actor + is_allied_to = scope:puppet_or_actor + is_close_or_extended_family_of = scope:puppet_or_actor } - scope:actor = { + scope:puppet_or_actor = { ai_greed <= 0 has_trait = loyal } @@ -592,46 +714,46 @@ gift_interaction = { } primary_defender = scope:recipient } - scope:actor = { + scope:puppet_or_actor = { ai_zeal >= 50 } } AND = { # Powerful vassals should be considered - is_powerful_vassal_of = scope:actor + is_powerful_vassal_of = scope:puppet_or_actor opinion = { - target = scope:actor + target = scope:puppet_or_actor value < 0 } NOT ={ has_opinion_modifier = { - target = scope:actor + target = scope:puppet_or_actor modifier = gift_opinion } } } AND = { # Factioneering vassals should be considered - is_vassal_of = scope:actor + is_vassal_of = scope:puppet_or_actor is_a_faction_member = yes NOT ={ has_opinion_modifier = { - target = scope:actor + target = scope:puppet_or_actor modifier = gift_opinion } } } AND = { # Realm Priests should be considered - scope:actor = { - faith = { has_doctrine = doctrine_theocracy_temporal } + scope:puppet_or_actor = { + rite = { rite_has_doctrine = doctrine_theocracy_temporal } exists = cp:councillor_court_chaplain cp:councillor_court_chaplain = scope:recipient } opinion = { - target = scope:actor + target = scope:puppet_or_actor value <= 25 } NOT = { has_opinion_modifier = { - target = scope:actor + target = scope:puppet_or_actor modifier = gift_opinion } } @@ -640,7 +762,7 @@ gift_interaction = { gold < 0 is_at_war = yes any_war_enemy = { - has_relation_rival = scope:actor + has_relation_rival = scope:puppet_or_actor } } # AND = { # Independent ruler within the struggle should be considered @@ -652,7 +774,7 @@ gift_interaction = { } } -# # Struggle + # Struggle # modifier = { # scope:recipient = { # any_character_struggle = { @@ -660,7 +782,7 @@ gift_interaction = { # phase_has_catalyst = catalyst_gift_independent_ruler # } # } -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # involvement = involved # phase_has_catalyst = catalyst_gift_independent_ruler @@ -673,7 +795,7 @@ gift_interaction = { # value = 0 # if = { # limit = { -# scope:actor = { +# scope:puppet_or_actor = { # has_character_flag = agenda_towards_escalation # } # } @@ -681,7 +803,7 @@ gift_interaction = { # } # else_if = { # limit = { -# scope:actor = { +# scope:puppet_or_actor = { # has_character_flag = agenda_towards_deescalation # } # scope:recipient = { @@ -707,7 +829,7 @@ gift_interaction = { # } # else_if = { # limit = { -# scope:actor = { +# scope:puppet_or_actor = { # has_character_flag = agenda_towards_deescalation # } # } @@ -730,26 +852,26 @@ gift_interaction = { # } # } # } - + modifier = { factor = 0.1 scope:recipient = { opinion = { - target = scope:actor + target = scope:puppet_or_actor value < 0 } NAND = { - is_vassal_of = scope:actor - scope:actor = { + is_vassal_of = scope:puppet_or_actor + scope:puppet_or_actor = { ai_rationality > 50 } } } } - + # modifier = { # add = 100 -# scope:actor = { +# scope:puppet_or_actor = { # is_at_war = no # has_trait = fp3_struggle_supporter # any_character_struggle = { is_struggle_type = persian_struggle } @@ -759,28 +881,28 @@ gift_interaction = { # gold < 0 # } # } - + # Nomads are slightly less likely to do this since they'd prefer to send Herd instead modifier = { add = -10 - scope:actor = { + scope:puppet_or_actor = { government_has_flag = government_is_nomadic } scope:recipient = { government_has_flag = government_is_nomadic } } - + modifier = { factor = 0.1 scope:recipient = { - has_relation_rival = scope:actor + has_relation_rival = scope:puppet_or_actor } } modifier = { factor = 2 - scope:actor.house.house_confederation ?= { + scope:puppet_or_actor.house.house_confederation ?= { has_cohesion_level_parameter = bloc_members_send_leader_gifts leading_house.house_head ?= scope:recipient } diff --git a/common/character_interactions/00_grant_titles_interaction.txt b/common/character_interactions/00_grant_titles_interaction.txt index b539914d5..dfdcb30a0 100644 --- a/common/character_interactions/00_grant_titles_interaction.txt +++ b/common/character_interactions/00_grant_titles_interaction.txt @@ -1,4 +1,14 @@ -#be aware that the actual granting of the title happens in code! +# Be aware that the actual granting of the title happens in code! +# Extra custom Grant Titles functionality: +# - scope:government_type may be set when a specific government type will be switched to with the title grant (not set = default government type) +# +# Related scripted rules: +# - allowed_to_be_granted_titles_by: checked outside of the interaction for candidates +# - is_grant_government_shown: checks if a government type should be shown as possible granting government type (for any recipient) - hidden in interface if not true +# - is_grant_government_valid: checks if a government type is valid to be given to a specific recipient (will create tooltip) +# Government Type database: +# - possible_grant_vassal_governments = {..} - list of base government types a government could possibly grant +# - grant_vassal_ai_will_do = {} - scoring of each possible government type to grant (after filtered by 'possible_grant_vassal_governments', 'is_grant_government_shown' and 'is_grant_government_valid' grant_titles_interaction = { category = interaction_category_vassal @@ -9,41 +19,41 @@ grant_titles_interaction = { special_interaction = grant_titles_interaction interface = grant_titles target_type = title - target_filter = actor_domain_titles + target_source = puppet_or_actor + target_filter = domain_titles interface_priority = 60 # actor character giving the titles # recipient character receiving the titles is_shown = { - scope:actor != scope:recipient - scope:actor = { + scope:puppet_or_actor != scope:recipient + scope:puppet_or_actor ?= { NOT = { - government_has_flag = government_is_landless_adventurer + government_has_flag = cannot_be_vassal_or_liege } } scope:recipient = { OR = { - target_is_liege_or_above = scope:actor - is_pool_guest_of = scope:actor + target_is_liege_or_above = scope:puppet_or_actor + is_pool_guest_of = scope:puppet_or_actor AND = { - scope:actor.faith.religious_head = scope:recipient - is_independent_ruler = yes - scope:actor.faith = { NOT = { has_doctrine = doctrine_holy_order_head } } + scope:puppet_or_actor.faith.religious_head ?= scope:recipient + top_liege ?= this } } } trigger_if = { limit = { - scope:actor = { government_allows = administrative } + scope:puppet_or_actor = { government_has_mechanic = administrative } } - scope:recipient = { NOT = { government_allows = administrative } } + scope:recipient = { NOT = { government_has_mechanic = administrative } } } trigger_if = { limit = { - scope:actor = { government_has_flag = government_is_nomadic NOT = { government_has_flag = government_allows_nomad_domicile_titles }} + scope:puppet_or_actor = { government_has_flag = government_is_nomadic } } - scope:recipient = { NOT = { government_has_flag = government_is_true_herder } } + scope:recipient = { NOT = { government_has_flag = government_is_herder } } } } @@ -52,16 +62,19 @@ grant_titles_interaction = { custom_tooltip = { text = can_be_granted_titles_interaction_tt OR = { - can_be_granted_titles_by = { RULER = scope:actor } - can_be_granted_theocratic_titles_by = { RULER = scope:actor } + can_be_granted_titles_by = { RULER = scope:puppet_or_actor } + can_be_granted_theocratic_titles_by = { RULER = scope:puppet_or_actor } AND = { - is_diarch_of_target = scope:actor - scope:actor = { has_diarchy_active_parameter = diarchy_is_co_rulership } + is_diarch_of_target = scope:puppet_or_actor + scope:puppet_or_actor = { has_diarchy_active_parameter = diarchy_is_co_rulership } } } } - NOT = { is_at_war_with = scope:actor } - NOT = { has_trait = devoted } # Monks are disinherited, and should not have land granted to them + NOT = { is_at_war_with = scope:puppet_or_actor } + OR = { # Monks are disinherited from secular land; the exemption keys on the granter's government because the titles are picked after this check + NOT = { has_trait = devoted } + scope:puppet_or_actor = { government_has_flag = government_is_theocracy } + } bp2_valid_for_standard_interactions_trigger = yes trigger_if = { limit = { is_ruler = no } @@ -76,7 +89,7 @@ grant_titles_interaction = { is_acclaimed = yes liege ?= { is_ai = no - this != scope:actor + this != scope:puppet_or_actor } } AND = { @@ -89,7 +102,7 @@ grant_titles_interaction = { NOT = { has_trait = gallivanter } # TGP JAPAN tgp_japan_grant_titles_restriction_trigger = { - GRANTER = scope:actor + GRANTER = scope:puppet_or_actor GRANTEE = scope:recipient } } @@ -97,19 +110,20 @@ grant_titles_interaction = { text = is_not_theocratic_court_chaplain subject = scope:recipient NAND = { - scope:actor.faith = { - has_doctrine = doctrine_theocracy_temporal + scope:puppet_or_actor.rite = { + rite_has_doctrine = doctrine_theocracy_temporal } + scope:puppet_or_actor = { NOT = { government_has_flag = government_is_theocracy } } scope:recipient = { - faith = { - has_doctrine = doctrine_theocracy_temporal + rite = { + rite_has_doctrine = doctrine_theocracy_temporal } has_council_position = councillor_court_chaplain } - scope:actor.faith.religious_head != scope:recipient + scope:puppet_or_actor.faith.religious_head != scope:recipient } } - scope:actor = { + scope:puppet_or_actor = { any_held_title = { count > 1 } @@ -119,7 +133,7 @@ grant_titles_interaction = { can_send = { trigger_if = { limit = { - scope:actor = { + scope:puppet_or_actor = { highest_held_title_tier >= tier_kingdom has_diarchy_active_parameter = primeminister_requires_duchy diarch = scope:recipient @@ -149,7 +163,7 @@ grant_titles_interaction = { trigger_if = { limit = { - scope:actor = { + scope:puppet_or_actor = { NOT = { has_government = nomad_government } @@ -181,22 +195,23 @@ grant_titles_interaction = { trigger_if = { limit = { is_head_of_faith = yes - scope:recipient.faith.religious_head != scope:actor.faith.religious_head + scope:recipient.faith.religious_head != scope:puppet_or_actor.faith.religious_head } custom_tooltip = { text = GRANT_TITLES_ITEM_CANT_HEAD_OF_FAITH_TO_INFIDEL - scope:recipient.faith.religious_head = scope:actor.faith.religious_head + scope:recipient.faith.religious_head = scope:puppet_or_actor.faith.religious_head } } trigger_if = { limit = { - scope:recipient = scope:actor.player_heir - scope:actor = { has_partition_succession_realm_law_trigger = yes } + scope:recipient = scope:puppet_or_actor.player_heir + scope:puppet_or_actor = { has_partition_succession_realm_law_trigger = yes } } custom_description = { text = partition_primary_heir_unfair subject = scope:recipient + object = scope:puppet_or_actor current_heir = scope:recipient } } @@ -208,21 +223,56 @@ grant_titles_interaction = { text = cannot_grant_ceremonial_title NOT = { exists = var:ceremonial_title } } + + trigger_if = { + limit = { has_clerical_region = yes } + custom_tooltip = { + text = GRANT_TITLES_ITEM_CANT_GIVE_CLERICAL_TITLE + always = no + } + } + + trigger_if = { + limit = { pam_title_is_clerical_elector_trigger = yes } + custom_tooltip = { + text = GRANT_TITLES_ITEM_CANT_GIVE_CLERICAL_ELECTOR + always = no + } + } + + trigger_if = { + limit = { pam_title_is_antipope_office_trigger = yes } + custom_tooltip = { + text = GRANT_TITLES_ITEM_CANT_GIVE_ANTIPOPE_TITLE + always = no + } + } + + trigger_if = { + limit = { + exists = situation:the_christian_church + this = title:k_papal_state + } + custom_tooltip = { + text = GRANT_TITLES_ITEM_CANT_HEAD_OF_FAITH + always = no + } + } } custom_description = { text = grant_titles_interaction_can_only_give_diarch_de_jure_liege_to_diarch - subject = scope:actor.diarch + subject = scope:puppet_or_actor.diarch NAND = { # Only applies if we have an active diarchy. - scope:actor = { has_active_diarchy = yes } + scope:puppet_or_actor = { has_active_diarchy = yes } # Now, prevent us from giving away our diarch's land to invalidate them... scope:target = { - any_dejure_vassal_title_holder = { this = scope:actor.diarch } + any_dejure_vassal_title_holder = { this = scope:puppet_or_actor.diarch } # ... _unless_ we're giving it _to_ the diarch. - scope:recipient != scope:actor.diarch + scope:recipient != scope:puppet_or_actor.diarch # Plus we only care if the title is below our tier. - tier < scope:actor.highest_held_title_tier + tier < scope:puppet_or_actor.highest_held_title_tier } } } @@ -275,12 +325,12 @@ grant_titles_interaction = { on_accept = { if = { limit = { - scope:actor = { + scope:puppet_or_actor = { government_has_flag = government_is_nomadic vassal_limit_available <= 0 is_independent_ruler = yes scope:recipient = { - NOT = { is_vassal_of = scope:actor } + NOT = { is_vassal_of = scope:puppet_or_actor } } } } @@ -297,7 +347,7 @@ grant_titles_interaction = { scope:recipient = { is_acclaimed = yes liege = { - this = scope:actor + this = scope:puppet_or_actor } } scope:target = { @@ -306,24 +356,26 @@ grant_titles_interaction = { } custom_tooltip = grant_title_landing_acclaimed_knight_warning } -# scope:recipient = { -# if = { -# limit = { -# top_liege = this -# save_temporary_scope_as = recipient_is_independent -# } -# } -# if = { -# limit = { -# NOT = { -# has_relation_friend = scope:actor -# } -# } + + grant_title_holy_order_patronage_warning_effect = yes + scope:recipient = { + if = { + limit = { + top_liege = this + save_temporary_scope_as = recipient_is_independent + } + } + if = { + limit = { + NOT = { + has_relation_friend = scope:puppet_or_actor + } + } # if = { # # then verify the right struggle phase # limit = { # is_diff_faith_or_culture_trigger = { -# CHAR = scope:actor +# CHAR = scope:puppet_or_actor # STATUS = involved # } # any_character_struggle = { @@ -333,12 +385,12 @@ grant_titles_interaction = { # } # progress_towards_friend_effect = { # REASON = friend_granted_title -# CHARACTER = scope:actor +# CHARACTER = scope:puppet_or_actor # OPINION = 0 # } # } -# } -# } + } + } if = { limit = { @@ -348,7 +400,7 @@ grant_titles_interaction = { tier = tier_county culture = scope:recipient.culture NOR = { - culture = scope:actor.culture + culture = scope:puppet_or_actor.culture recent_history = { type = granted years = 10 @@ -359,7 +411,7 @@ grant_titles_interaction = { list = target_titles tier >= tier_duchy title_capital_county = { - culture != scope:actor.culture + culture != scope:puppet_or_actor.culture culture = scope:recipient.culture } NOT = { @@ -373,7 +425,7 @@ grant_titles_interaction = { } scope:recipient.culture = { change_cultural_acceptance = { - target = scope:actor.culture + target = scope:puppet_or_actor.culture value = grant_title_cultural_acceptance_impact desc = cultural_acceptance_gain_granted_title } @@ -385,7 +437,7 @@ grant_titles_interaction = { list = target_titles tier = tier_county } - scope:actor.culture = { has_cultural_parameter = grants_to_lowborns_bonuses } + scope:puppet_or_actor.culture = { has_cultural_parameter = grants_to_lowborns_bonuses } scope:recipient = { is_lowborn = yes } @@ -405,14 +457,19 @@ grant_titles_interaction = { list = target_titles tier >= tier_county } - scope:actor.culture = { has_cultural_parameter = landing_house_members_give_prestige } - exists = scope:actor.house + scope:puppet_or_actor.culture = { has_cultural_parameter = landing_house_members_give_prestige } + exists = scope:puppet_or_actor.house exists = scope:recipient.house - scope:actor.house = scope:recipient.house + scope:puppet_or_actor.house = scope:recipient.house } - scope:actor = { + scope:puppet_or_actor = { add_prestige = { value = 0 + every_in_list = { + list = target_titles + limit = { tier = tier_hegemony } + add = monumental_prestige_gain + } every_in_list = { list = target_titles limit = { tier = tier_empire } @@ -442,33 +499,38 @@ grant_titles_interaction = { list = target_titles tier >= tier_county } - scope:actor.culture = { has_cultural_parameter = landing_house_members_gives_renown } - exists = scope:actor.house + scope:puppet_or_actor.culture = { has_cultural_parameter = landing_house_members_gives_renown } + exists = scope:puppet_or_actor.house exists = scope:recipient.house - scope:actor.house = scope:recipient.house + scope:puppet_or_actor.house = scope:recipient.house } - scope:actor.dynasty = { + scope:puppet_or_actor.dynasty = { add_dynasty_prestige = { value = 0 + every_in_list = { + list = target_titles + limit = { tier = tier_hegemony } + add = scope:puppet_or_actor.dynasty.monumental_dynasty_prestige_gain + } every_in_list = { list = target_titles limit = { tier = tier_empire } - add = scope:actor.dynasty.massive_dynasty_prestige_gain + add = scope:puppet_or_actor.dynasty.massive_dynasty_prestige_gain } every_in_list = { list = target_titles limit = { tier = tier_kingdom } - add = scope:actor.dynasty.major_dynasty_prestige_gain + add = scope:puppet_or_actor.dynasty.major_dynasty_prestige_gain } every_in_list = { list = target_titles limit = { tier = tier_duchy } - add = scope:actor.dynasty.medium_dynasty_prestige_gain + add = scope:puppet_or_actor.dynasty.medium_dynasty_prestige_gain } every_in_list = { list = target_titles limit = { tier = tier_county } - add = scope:actor.dynasty.minor_dynasty_prestige_gain + add = scope:puppet_or_actor.dynasty.minor_dynasty_prestige_gain } } } @@ -492,7 +554,7 @@ grant_titles_interaction = { hidden_effect = { add_opinion = { - target = scope:actor + target = scope:puppet_or_actor modifier = received_title_barony } } @@ -507,22 +569,22 @@ grant_titles_interaction = { hidden_effect = { add_opinion = { - target = scope:actor + target = scope:puppet_or_actor modifier = received_title_county } if = { limit = { is_lowborn = yes } - scope:actor = { + scope:puppet_or_actor = { if = { limit = { - is_ai = no + scope:actor = { is_ai = no } } every_vassal = { vassal_stance = courtly add_opinion = { - target = scope:actor + target = scope:puppet_or_actor modifier = courtly_lowborn_grant_opinion opinion = -5 } @@ -534,7 +596,7 @@ grant_titles_interaction = { every_vassal = { vassal_stance = courtly add_opinion = { - target = scope:actor + target = scope:puppet_or_actor modifier = courtly_lowborn_grant_opinion opinion = -5 } @@ -555,18 +617,18 @@ grant_titles_interaction = { hidden_effect = { add_opinion = { - target = scope:actor + target = scope:puppet_or_actor modifier = received_title_duchy } if = { limit = { is_lowborn = yes } - scope:actor = { + scope:puppet_or_actor = { every_vassal = { vassal_stance = courtly add_opinion = { - target = scope:actor + target = scope:puppet_or_actor modifier = courtly_lowborn_grant_opinion opinion = -20 } @@ -585,18 +647,18 @@ grant_titles_interaction = { hidden_effect = { add_opinion = { - target = scope:actor + target = scope:puppet_or_actor modifier = received_title_kingdom } if = { limit = { is_lowborn = yes } - scope:actor = { + scope:puppet_or_actor = { every_vassal = { vassal_stance = courtly add_opinion = { - target = scope:actor + target = scope:puppet_or_actor modifier = courtly_lowborn_grant_opinion opinion = -50 } @@ -610,25 +672,25 @@ grant_titles_interaction = { else_if = { limit = { - scope:this_title.tier = tier_empire + scope:this_title.tier >= tier_empire } hidden_effect = { add_opinion = { - target = scope:actor + target = scope:puppet_or_actor modifier = received_title_empire } if = { limit = { is_lowborn = yes } - scope:actor = { + scope:puppet_or_actor = { every_vassal = { vassal_stance = courtly add_opinion = { - target = scope:actor + target = scope:puppet_or_actor modifier = courtly_lowborn_grant_opinion - opinion = -5 + opinion = -80 } } } @@ -648,7 +710,7 @@ grant_titles_interaction = { #Promised a vassal this title they had a claim on (vassal.2901) if = { limit = { - scope:actor = { + scope:puppet_or_actor = { exists = var:was_promised_title var:was_promised_title = scope:recipient } @@ -660,7 +722,7 @@ grant_titles_interaction = { } scope:landed_title = scope:recipient.var:promised_title } - scope:actor = { + scope:puppet_or_actor = { trigger_event = { id = vassal.2910 days = { 7 14 } @@ -691,12 +753,12 @@ grant_titles_interaction = { } # Viziers may be booted from their job. - scope:actor = { + scope:puppet_or_actor = { if = { limit = { # Assuming this is relevant at all. diarch ?= scope:recipient - # And that scope:actor can do without a supervisor atm. + # And that scope:puppet_or_actor can do without a supervisor atm. can_leave_diarchy_trigger = yes # Aaaaand that their diarchy supports this type of thing. OR = { @@ -752,7 +814,7 @@ grant_titles_interaction = { limit = { any_in_list = { list = target_titles - tier = tier_empire + tier >= tier_empire } } custom_tooltip = grant_title_modifier_stack_empires @@ -796,8 +858,8 @@ grant_titles_interaction = { if = { limit = { trigger_if = { - limit = { scope:actor = { is_ai = yes } } - scope:actor = { + limit = { scope:actor = { is_ai = no } } + scope:puppet_or_actor = { any_vassal = { vassal_stance = courtly } @@ -854,7 +916,7 @@ grant_titles_interaction = { } scope:recipient = { save_scope_as = claimant_scope } } - scope:actor = { + scope:puppet_or_actor = { trigger_event = { id = bp1_yearly.8070 days = 5 @@ -867,7 +929,7 @@ grant_titles_interaction = { } #Stress impact - scope:actor = { + scope:puppet_or_actor = { if = { limit = { any_in_list = { @@ -893,13 +955,11 @@ grant_titles_interaction = { # Gnostics lose stress for giving away titles. if = { limit = { - scope:actor = { - faith = { - has_doctrine_parameter = granting_titles_gives_stress - } + scope:puppet_or_actor.rite = { + rite_has_parameter = granting_titles_gives_stress } } - scope:actor = { + scope:puppet_or_actor = { add_stress = { value = 0 @@ -929,7 +989,7 @@ grant_titles_interaction = { } } else_if = { - limit = { this.tier = tier_empire } + limit = { this.tier >= tier_empire } add = { value = monumental_stress_loss multiply = 2 # 200 base @@ -940,7 +1000,7 @@ grant_titles_interaction = { multiply = { value = this.tier add = 1 - divide = scope:actor.primary_title.tier + divide = scope:puppet_or_actor.primary_title.tier } # Round to the nearest multiple of 5. @@ -988,7 +1048,7 @@ grant_titles_interaction = { list = target_titles count = all trigger_if = { - limit = { tier = tier_county} + limit = { tier = tier_county } de_jure_liege = scope:granted_duchy } } @@ -1001,7 +1061,7 @@ grant_titles_interaction = { limit = { domain_size = domain_limit } - stress_impact = { + stress_and_fulfillment_impact = { greedy = minor_stress_impact_gain ambitious = minor_stress_impact_gain } @@ -1010,7 +1070,7 @@ grant_titles_interaction = { limit = { domain_size < domain_limit } - stress_impact = { + stress_and_fulfillment_impact = { greedy = medium_stress_impact_gain ambitious = medium_stress_impact_gain } @@ -1025,7 +1085,7 @@ grant_titles_interaction = { has_fp1_dlc_trigger = yes fp1_remove_stele_new_holder_trigger = { TITLE = scope:target - PREVIOUS_HOLDER = scope:actor + PREVIOUS_HOLDER = scope:puppet_or_actor NEW_HOLDER = scope:recipient } } @@ -1043,16 +1103,27 @@ grant_titles_interaction = { # Actually removed in religious_decision.0312 custom_tooltip = runestone_grant_title_warning } + if = { # Maintenance for khachkar decision + limit = { + has_pam_dlc_trigger = yes + scope:target = { + exists = var:pam_khachkar_ancestor + has_county_modifier = pam_khachkar_ancestral_county + } + NOT = { scope:recipient.dynasty = scope:target.var:pam_khachkar_ancestor.dynasty } + } + custom_tooltip = pam_khachkar_grant_title_warning + } if = { limit = { - exists = scope:actor.dynasty - scope:actor.dynasty = { + exists = scope:puppet_or_actor.dynasty + scope:puppet_or_actor.dynasty = { has_dynasty_perk = ep1_culture_legacy_3 } scope:recipient = { is_playable_character = no - culture != scope:actor.culture + culture != scope:puppet_or_actor.culture any_in_list = { list = target_titles OR = { @@ -1063,7 +1134,7 @@ grant_titles_interaction = { } } } - scope:actor = { + scope:puppet_or_actor = { if = { limit = { can_add_hook = { @@ -1087,14 +1158,14 @@ grant_titles_interaction = { vassal_limit_available <= 0 is_independent_ruler = yes scope:recipient = { - NOT = { is_vassal_of = scope:actor } + NOT = { is_vassal_of = scope:puppet_or_actor } } } send_interface_toast = { type = event_toast_effect_neutral title = grant_titles_interaction_notification - left_icon = scope:actor + left_icon = scope:puppet_or_actor right_icon = scope:recipient custom_tooltip = grant_titles_interaction_notification_effect_7 @@ -1105,7 +1176,7 @@ grant_titles_interaction = { any_in_list = { list = target_titles count = 1 - NOT = { tier = scope:actor.highest_held_title_tier } + NOT = { tier = scope:puppet_or_actor.highest_held_title_tier } } NOT = { exists = scope:recipient_is_independent } scope:recipient = { @@ -1125,7 +1196,7 @@ grant_titles_interaction = { type = event_toast_effect_neutral title = grant_titles_interaction_notification - left_icon = scope:actor + left_icon = scope:puppet_or_actor right_icon = scope:recipient custom_tooltip = grant_titles_interaction_notification_effect_2 @@ -1154,7 +1225,7 @@ grant_titles_interaction = { any_in_list = { list = target_titles count > 1 - NOT = { tier = scope:actor.highest_held_title_tier } + NOT = { tier = scope:puppet_or_actor.highest_held_title_tier } } NOT = { exists = scope:recipient_is_independent } scope:recipient = { @@ -1174,7 +1245,7 @@ grant_titles_interaction = { type = event_toast_effect_neutral title = grant_titles_interaction_notification - left_icon = scope:actor + left_icon = scope:puppet_or_actor right_icon = scope:recipient custom_tooltip = grant_titles_interaction_notification_effect_3 @@ -1193,7 +1264,7 @@ grant_titles_interaction = { type = event_toast_effect_neutral title = grant_titles_interaction_notification - left_icon = scope:actor + left_icon = scope:puppet_or_actor right_icon = scope:recipient custom_tooltip = grant_titles_interaction_notification_effect_6 @@ -1204,16 +1275,16 @@ grant_titles_interaction = { scope:recipient = { any_in_list = { #Became independent from you, but still have the same liege list = target_titles - tier = scope:actor.highest_held_title_tier + tier = scope:puppet_or_actor.highest_held_title_tier } - top_liege = scope:actor.top_liege + top_liege = scope:puppet_or_actor.top_liege } } send_interface_toast = { type = event_toast_effect_neutral title = grant_titles_interaction_notification - left_icon = scope:actor + left_icon = scope:puppet_or_actor right_icon = scope:recipient custom_tooltip = grant_titles_interaction_notification_effect_5 @@ -1224,7 +1295,7 @@ grant_titles_interaction = { scope:recipient = { any_in_list = { #Became independent list = target_titles - tier = scope:actor.highest_held_title_tier + tier = scope:puppet_or_actor.highest_held_title_tier } } } @@ -1232,7 +1303,7 @@ grant_titles_interaction = { type = event_toast_effect_neutral title = grant_titles_interaction_notification - left_icon = scope:actor + left_icon = scope:puppet_or_actor right_icon = scope:recipient custom_tooltip = grant_titles_interaction_notification_effect_4 @@ -1243,7 +1314,7 @@ grant_titles_interaction = { type = event_toast_effect_neutral title = grant_titles_interaction_notification - left_icon = scope:actor + left_icon = scope:puppet_or_actor right_icon = scope:recipient custom_tooltip = grant_titles_interaction_notification_effect @@ -1252,11 +1323,11 @@ grant_titles_interaction = { } } - hidden_effect = { - # Struggle Catalyst +# hidden_effect = { +# # Struggle Catalyst # if = { # limit = { -# scope:actor = { +# scope:puppet_or_actor = { # is_diff_faith_or_culture_trigger = { # CHAR = scope:recipient # STATUS = involved @@ -1270,7 +1341,7 @@ grant_titles_interaction = { # } # } # } -# scope:actor = { +# scope:puppet_or_actor = { # every_character_struggle = { # involvement = involved # limit = { @@ -1281,12 +1352,12 @@ grant_titles_interaction = { # } # activate_struggle_catalyst = { # catalyst = catalyst_grant_privilege_to_diff_faith_culture_vassal -# character = scope:actor +# character = scope:puppet_or_actor # } # } # } # } - } +# } # Achievements. scope:actor = { @@ -1304,6 +1375,78 @@ grant_titles_interaction = { } } } + + # Government type grant cooldown: prevents rapidly granting multiple government-type vassals. + if = { + limit = { + exists = scope:government_type + } + scope:puppet_or_actor = { + set_variable = { + name = grant_vassal_government_cooldown + value = yes + days = 365 + } + } + } + #Opinion loss with underlings who think they should get the title you're granting + if = { + limit = { + #AI will usually grant title to de jure holders, it's players who could use this steering + scope:actor = { + is_ai = no + } + } + if = { + limit = { + any_in_list = { + list = titles_to_grant + any_claimant = { + this = scope:recipient + } + } + } + ordered_in_list = { + order_by = tier + list = titles_to_grant + limit = { + any_claimant = { + this = scope:recipient + } + } + save_scope_as = highest_claim + } + scope:recipient = { claimant_jealousy_immunity_effect = yes } + } + every_in_list = { + list = titles_to_grant + save_scope_as = title_granted + scope:puppet_or_actor = { + title_granting_controversy_effect = { + TITLE = scope:title_granted + INTERACTION = grant_titles_interaction + } + } + } + every_in_list = { + list = strong_claimants + limit = { + NOT = { this = scope:recipient } + } + save_scope_as = claimer + ordered_in_list = { + order_by = tier + list = titles_to_grant + limit = { + any_claimant = { + this = scope:claimer + } + } + save_scope_as = highest_denied_claim + } + claimant_rivalry_mercy_effect = yes + } + } } } @@ -1315,7 +1458,7 @@ grant_title_to_new_random_character_interaction = { use_diplomatic_range = no is_valid_showing_failures_only = { - scope:actor = { + scope:puppet_or_actor = { this != scope:recipient any_held_title = { count > 1 @@ -1324,7 +1467,8 @@ grant_title_to_new_random_character_interaction = { } } -#be aware that the actual granting of the title happens in code! +# Be aware that the actual granting of the title happens in code! +# See 'grant_titles_interaction' for functionality of granting different government types. grant_governorship_interaction = { icon = grant_governorship category = interaction_category_vassal @@ -1335,22 +1479,23 @@ grant_governorship_interaction = { special_interaction = grant_governorship_interaction interface = grant_titles target_type = title - target_filter = actor_domain_titles + target_source = puppet_or_actor + target_filter = domain_titles interface_priority = 60 # actor character giving the titles # recipient character receiving the titles is_shown = { - scope:actor != scope:recipient + scope:puppet_or_actor != scope:recipient scope:recipient = { OR = { - target_is_liege_or_above = scope:actor - is_pool_guest_of = scope:actor + target_is_liege_or_above = scope:puppet_or_actor + is_pool_guest_of = scope:puppet_or_actor } } - scope:actor = { - government_allows = administrative + scope:puppet_or_actor ?= { + government_has_mechanic = administrative highest_held_title_tier >= tier_county } @@ -1365,7 +1510,7 @@ grant_governorship_interaction = { } is_valid_showing_failures_only = { - scope:actor = { + scope:puppet_or_actor = { custom_tooltip = { text = grant_governorship_interaction_no_title_tt any_held_title = { @@ -1373,25 +1518,25 @@ grant_governorship_interaction = { is_noble_family_title = no is_landless_type_title = no NOR = { - this = scope:actor.capital_county - this = scope:actor.primary_title + this = scope:puppet_or_actor.capital_county + this = scope:puppet_or_actor.primary_title } } } } scope:recipient = { is_adult = yes - NOT = { is_at_war_with = scope:actor } + NOT = { is_at_war_with = scope:puppet_or_actor } bp2_valid_for_standard_interactions_trigger = yes trigger_if = { limit = { is_ruler = no } is_imprisoned = no } - government_allows = administrative + government_has_mechanic = administrative # Only the preferred gender can be appointed unless they hold titles already trigger_if = { limit = { - scope:actor = { + scope:puppet_or_actor = { OR = { has_realm_law = male_only_law has_realm_law = male_preference_law @@ -1406,7 +1551,7 @@ grant_governorship_interaction = { } trigger_if = { limit = { - scope:actor = { + scope:puppet_or_actor = { OR = { has_realm_law = female_only_law has_realm_law = female_preference_law @@ -1428,7 +1573,7 @@ grant_governorship_interaction = { is_acclaimed = yes liege ?= { is_ai = no - this != scope:actor + this != scope:puppet_or_actor } } AND = { @@ -1442,7 +1587,7 @@ grant_governorship_interaction = { NOT = { has_trait = gallivanter } # TGP JAPAN tgp_japan_grant_titles_restriction_trigger = { - GRANTER = scope:actor + GRANTER = scope:puppet_or_actor GRANTEE = scope:recipient } # Cannot be a minister @@ -1499,8 +1644,8 @@ grant_governorship_interaction = { NOT = { exists = holder } holder = { NOR = { - is_vassal_or_below_of = scope:actor - this = scope:actor + is_vassal_or_below_of = scope:puppet_or_actor + this = scope:puppet_or_actor } } } @@ -1575,6 +1720,7 @@ grant_governorship_interaction = { target_is_de_jure_liege_or_above = scope:target # Or is a neighboring county which de jure duchy is not part of your realm AND = { + tier >= tier_county any_title_to_title_neighboring_county = { this = scope:target } scope:target = { tier = tier_county @@ -1583,8 +1729,8 @@ grant_governorship_interaction = { NOT = { exists = holder } holder = { NOR = { - is_vassal_or_below_of = scope:actor - this = scope:actor + is_vassal_or_below_of = scope:puppet_or_actor + this = scope:puppet_or_actor } } } @@ -1620,7 +1766,7 @@ grant_governorship_interaction = { custom_tooltip = { text = GRANT_TITLES_ITEM_CANT_GIVE_ADMIN_PRIMARY - this != scope:actor.capital_province.duchy + this != scope:puppet_or_actor.capital_province.duchy } trigger_if = { @@ -1659,17 +1805,17 @@ grant_governorship_interaction = { custom_description = { text = grant_titles_interaction_can_only_give_diarch_de_jure_liege_to_diarch - subject = scope:actor.diarch + subject = scope:puppet_or_actor.diarch NAND = { # Only applies if we have an active diarchy. - scope:actor = { has_active_diarchy = yes } + scope:puppet_or_actor = { has_active_diarchy = yes } # Now, prevent us from giving away our diarch's land to invalidate them... scope:target = { - any_dejure_vassal_title_holder = { this = scope:actor.diarch } + any_dejure_vassal_title_holder = { this = scope:puppet_or_actor.diarch } # ... _unless_ we're giving it _to_ the diarch. - scope:recipient != scope:actor.diarch + scope:recipient != scope:puppet_or_actor.diarch # Plus we only care if the title is below our tier. - tier < scope:actor.highest_held_title_tier + tier < scope:puppet_or_actor.highest_held_title_tier } } } @@ -1685,17 +1831,10 @@ grant_governorship_interaction = { auto_accept = yes on_auto_accept = { - if = { - limit = { - scope:actor = { - government_allows = administrative - } - } - scope:recipient = { - trigger_event = { - id = char_interaction.0111 - delayed = yes #this has to be delayed in case you grant it to someone that doesn't have an estate yet, for the change_government effect to work and generate the estate - } + scope:recipient = { + trigger_event = { + id = char_interaction.0111 + delayed = yes #this has to be delayed in case you grant it to someone that doesn't have an estate yet, for the change_government effect to work and generate the estate } } } @@ -1706,12 +1845,13 @@ grant_governorship_interaction = { scope:recipient = { is_acclaimed = yes liege = { - this = scope:actor + this = scope:puppet_or_actor } } } custom_tooltip = grant_title_landing_acclaimed_knight_warning } + grant_title_holy_order_patronage_warning_effect = yes if = { limit = { @@ -1719,7 +1859,7 @@ grant_governorship_interaction = { list = target_titles tier >= tier_duchy title_capital_county = { - culture != scope:actor.culture + culture != scope:puppet_or_actor.culture culture = scope:recipient.culture } NOT = { @@ -1732,7 +1872,7 @@ grant_governorship_interaction = { } scope:recipient.culture = { change_cultural_acceptance = { - target = scope:actor.culture + target = scope:puppet_or_actor.culture value = grant_title_cultural_acceptance_impact desc = cultural_acceptance_gain_granted_title } @@ -1744,14 +1884,19 @@ grant_governorship_interaction = { list = target_titles tier >= tier_county } - scope:actor.culture = { has_cultural_parameter = landing_house_members_give_prestige } - exists = scope:actor.house + scope:puppet_or_actor.culture = { has_cultural_parameter = landing_house_members_give_prestige } + exists = scope:puppet_or_actor.house exists = scope:recipient.house - scope:actor.house = scope:recipient.house + scope:puppet_or_actor.house = scope:recipient.house } - scope:actor = { + scope:puppet_or_actor = { add_prestige = { value = 0 + every_in_list = { + list = target_titles + limit = { tier = tier_hegemony } + add = monumental_prestige_gain + } every_in_list = { list = target_titles limit = { tier = tier_empire } @@ -1776,23 +1921,23 @@ grant_governorship_interaction = { list = target_titles tier >= tier_county } - scope:actor.culture = { has_cultural_parameter = landing_house_members_gives_renown } - exists = scope:actor.house + scope:puppet_or_actor.culture = { has_cultural_parameter = landing_house_members_gives_renown } + exists = scope:puppet_or_actor.house exists = scope:recipient.house - scope:actor.house = scope:recipient.house + scope:puppet_or_actor.house = scope:recipient.house } - scope:actor.dynasty = { + scope:puppet_or_actor.dynasty = { add_dynasty_prestige = { value = 0 every_in_list = { list = target_titles limit = { tier = tier_kingdom } - add = scope:actor.dynasty.major_dynasty_prestige_gain + add = scope:puppet_or_actor.dynasty.major_dynasty_prestige_gain } every_in_list = { list = target_titles limit = { tier = tier_duchy } - add = scope:actor.dynasty.medium_dynasty_prestige_gain + add = scope:puppet_or_actor.dynasty.medium_dynasty_prestige_gain } } } @@ -1813,19 +1958,18 @@ grant_governorship_interaction = { if = { limit = { scope:this_title.tier = tier_county - scope:actor = { min_appointment_tier = tier_county } } hidden_effect = { add_opinion = { - target = scope:actor + target = scope:puppet_or_actor modifier = received_title_county } } scope:this_title = { add_to_temporary_list = titles_to_grant } } - + else_if = { limit = { scope:this_title.tier = tier_duchy @@ -1833,18 +1977,18 @@ grant_governorship_interaction = { hidden_effect = { add_opinion = { - target = scope:actor + target = scope:puppet_or_actor modifier = received_title_duchy } if = { limit = { is_lowborn = yes } - scope:actor = { + scope:puppet_or_actor = { every_vassal = { vassal_stance = courtly add_opinion = { - target = scope:actor + target = scope:puppet_or_actor modifier = courtly_lowborn_grant_opinion opinion = -10 #less than usual because admin realms are more tolerant of bureaucratic "new" nobility } @@ -1863,18 +2007,18 @@ grant_governorship_interaction = { hidden_effect = { add_opinion = { - target = scope:actor + target = scope:puppet_or_actor modifier = received_title_kingdom } if = { limit = { is_lowborn = yes } - scope:actor = { + scope:puppet_or_actor = { every_vassal = { vassal_stance = courtly add_opinion = { - target = scope:actor + target = scope:puppet_or_actor modifier = courtly_lowborn_grant_opinion opinion = -30 #less than usual because admin realms are more tolerant of bureaucratic "new" nobility } @@ -1888,23 +2032,23 @@ grant_governorship_interaction = { else_if = { limit = { - scope:this_title.tier = tier_empire + scope:this_title.tier >= tier_empire } hidden_effect = { add_opinion = { - target = scope:actor + target = scope:puppet_or_actor modifier = received_title_empire } if = { limit = { is_lowborn = yes } - scope:actor = { + scope:puppet_or_actor = { every_vassal = { vassal_stance = courtly add_opinion = { - target = scope:actor + target = scope:puppet_or_actor modifier = courtly_lowborn_grant_opinion opinion = -30 #less than usual because admin realms are more tolerant of bureaucratic "new" nobility } @@ -1920,7 +2064,7 @@ grant_governorship_interaction = { #Promised a vassal this title they had a claim on (vassal.2901) if = { limit = { - scope:actor = { + scope:puppet_or_actor = { exists = var:was_promised_title var:was_promised_title = scope:recipient } @@ -1932,7 +2076,7 @@ grant_governorship_interaction = { } scope:landed_title = scope:recipient.var:promised_title } - scope:actor = { + scope:puppet_or_actor = { trigger_event = { id = vassal.2910 days = { 7 14 } @@ -1966,7 +2110,7 @@ grant_governorship_interaction = { limit = { any_in_list = { list = target_titles - tier = tier_empire + tier >= tier_empire } } custom_tooltip = grant_title_modifier_stack_empires @@ -1994,17 +2138,17 @@ grant_governorship_interaction = { any_in_list = { list = titles_to_grant tier = tier_county - scope:actor = { min_appointment_tier = tier_county } + scope:puppet_or_actor = { min_appointment_tier = tier_county } } } custom_tooltip = grant_title_modifier_stack_counties } - + if = { limit = { trigger_if = { - limit = { scope:actor = { is_ai = yes } } - scope:actor = { + limit = { scope:actor = { is_ai = no } } + scope:puppet_or_actor = { any_vassal = { vassal_stance = courtly } @@ -2061,7 +2205,7 @@ grant_governorship_interaction = { } scope:recipient = { save_scope_as = claimant_scope } } - scope:actor = { + scope:puppet_or_actor = { trigger_event = { id = bp1_yearly.8070 days = 5 @@ -2073,7 +2217,7 @@ grant_governorship_interaction = { } } - scope:actor = { + scope:puppet_or_actor = { # Maintenance for runestones if = { limit = { @@ -2081,7 +2225,7 @@ grant_governorship_interaction = { has_fp1_dlc_trigger = yes fp1_remove_stele_new_holder_trigger = { TITLE = scope:target - PREVIOUS_HOLDER = scope:actor + PREVIOUS_HOLDER = scope:puppet_or_actor NEW_HOLDER = scope:recipient } } @@ -2099,13 +2243,24 @@ grant_governorship_interaction = { # Actually removed in religious_decision.0312 custom_tooltip = runestone_grant_title_warning } +# if = { +# limit = { +# has_pam_dlc_trigger = yes +# scope:target = { +# exists = var:pam_khachkar_ancestor +# has_county_modifier = pam_khachkar_ancestral_county +# } +# NOT = { scope:recipient.dynasty = scope:target.var:pam_khachkar_ancestor.dynasty } +# } +# custom_tooltip = pam_khachkar_grant_title_warning +# } if = { limit = { dynasty ?= { has_dynasty_perk = ep1_culture_legacy_3 } scope:recipient = { is_playable_character = no - culture != scope:actor.culture + culture != scope:puppet_or_actor.culture any_in_list = { list = target_titles OR = { @@ -2149,7 +2304,7 @@ grant_governorship_interaction = { every_in_list = { list = target_titles limit = { - NOT = { tier = scope:actor.highest_held_title_tier } + NOT = { tier = scope:puppet_or_actor.highest_held_title_tier } } add = 1 } @@ -2161,7 +2316,7 @@ grant_governorship_interaction = { value = 0 every_in_list = { list = target_titles - limit = { tier = scope:actor.highest_held_title_tier } + limit = { tier = scope:puppet_or_actor.highest_held_title_tier } add = 1 } } @@ -2177,24 +2332,24 @@ grant_governorship_interaction = { left_icon = scope:recipient right_icon = scope:loc_title if = { - limit = { scope:actor.var:lower_count ?= 0 } + limit = { scope:puppet_or_actor.var:lower_count ?= 0 } custom_tooltip = grant_governorship_interaction_notification_effect_2 } else_if = { limit = { - exists = scope:actor.var:lower_count - scope:actor.var:lower_count > 1 + exists = scope:puppet_or_actor.var:lower_count + scope:puppet_or_actor.var:lower_count > 1 } custom_tooltip = grant_governorship_interaction_notification_effect_3 } else_if = { - limit = { scope:actor.var:lower_count ?= 1 } + limit = { scope:puppet_or_actor.var:lower_count ?= 1 } custom_tooltip = grant_governorship_interaction_notification_effect_4 } else_if = { limit = { scope:equal_count >= 1 - scope:recipient.top_liege ?= scope:actor.top_liege + scope:recipient.top_liege ?= scope:puppet_or_actor.top_liege } custom_tooltip = grant_titles_interaction_notification_effect_5 } @@ -2219,11 +2374,11 @@ grant_governorship_interaction = { } } - hidden_effect = { - # Struggle Catalyst +# hidden_effect = { +# # Struggle Catalyst # if = { # limit = { -# scope:actor = { +# scope:puppet_or_actor = { # is_diff_faith_or_culture_trigger = { # CHAR = scope:recipient # STATUS = involved @@ -2237,7 +2392,7 @@ grant_governorship_interaction = { # } # } # } -# scope:actor = { +# scope:puppet_or_actor = { # every_character_struggle = { # involvement = involved # limit = { @@ -2248,12 +2403,12 @@ grant_governorship_interaction = { # } # activate_struggle_catalyst = { # catalyst = catalyst_grant_privilege_to_diff_faith_culture_vassal -# character = scope:actor +# character = scope:puppet_or_actor # } # } # } # } - } +# } # Achievements. scope:actor = { @@ -2274,7 +2429,7 @@ grant_governorship_interaction = { # TGP Catalyst - triggered in on_title_gain if = { limit = { - title:h_china.holder ?= scope:actor + title:h_china.holder ?= scope:puppet_or_actor any_in_list = { list = target_titles OR = { @@ -2302,7 +2457,7 @@ grant_governorship_interaction = { if = { limit = { situation_top_has_catalyst = catalyst_hegemon_appointing_low_merit_governor - title:h_china.holder = scope:actor + title:h_china.holder = scope:puppet_or_actor } trigger_situation_catalyst = { catalyst = catalyst_hegemon_appointing_low_merit_governor @@ -2312,5 +2467,63 @@ grant_governorship_interaction = { } } } + #Opinion loss with underlings who think they should get the title you're granting + if = { + limit = { + #AI will usually grant title to de jure holders, it's players who could use this steering + scope:actor = { + is_ai = no + } + } + if = { + limit = { + any_in_list = { + list = titles_to_grant + any_claimant = { + this = scope:recipient + } + } + } + ordered_in_list = { + order_by = tier + list = titles_to_grant + limit = { + any_claimant = { + this = scope:recipient + } + } + save_scope_as = highest_claim + } + scope:recipient = { claimant_jealousy_immunity_effect = yes } + } + every_in_list = { + list = titles_to_grant + save_scope_as = title_granted + scope:puppet_or_actor = { + title_granting_controversy_effect = { + TITLE = scope:title_granted + INTERACTION = grant_governorship_interaction + } + } + } + every_in_list = { + list = strong_claimants + limit = { + NOT = { this = scope:recipient } + } + save_scope_as = claimer + ordered_in_list = { + order_by = tier + list = titles_to_grant + limit = { + any_claimant = { + this = scope:claimer + } + } + save_scope_as = highest_denied_claim + } + claimant_rivalry_mercy_effect = yes + } + } } } diff --git a/common/character_interactions/00_house_head_interactions.txt b/common/character_interactions/00_house_head_interactions.txt index 564f5846d..0be890efa 100644 --- a/common/character_interactions/00_house_head_interactions.txt +++ b/common/character_interactions/00_house_head_interactions.txt @@ -16,22 +16,25 @@ call_house_member_to_war_interaction = { notification_text = CALL_HOUSE_MEMBER_NOTIFICATION + is_available = { + OR = { + is_house_head = yes + AND = { + exists = dynasty + # Standard check + dynasty ?= { has_dynasty_perk = fp2_coterie_legacy_3 } + # DLC checking + has_fp2_dlc_trigger = yes + } + } + } + is_shown = { scope:recipient != scope:actor scope:actor = { - OR = { - is_house_head = yes - AND = { - exists = dynasty - # DLC checking - has_fp2_dlc_trigger = yes - # Standard check - dynasty = { has_dynasty_perk = fp2_coterie_legacy_3 } - } - } - religion = scope:recipient.religion - house = scope:recipient.house + religion ?= scope:recipient.religion + house ?= scope:recipient.house any_character_war = { is_war_leader = scope:actor } @@ -249,7 +252,7 @@ call_house_member_to_war_interaction = { this = scope:actor faith = { faith_hostility_level = { - target = scope:target.casus_belli.primary_defender.faith + target = scope:target.casus_belli.primary_attacker.faith value >= religious_cb_enabled_hostility_level } } @@ -436,39 +439,49 @@ legitimize_bastard_interaction = { } } + is_available = { + is_lowborn = no + is_concubine = no + } + is_shown = { - scope:actor.house.house_head.faith = { - has_doctrine_parameter = bastards_legitimize + scope:actor.rite ?= { + rite_has_parameter = bastards_legitimize } - scope:actor.faith = { - has_doctrine_parameter = bastards_legitimize + scope:actor.house.house_head.rite ?= { + rite_has_parameter = bastards_legitimize } - scope:secondary_recipient = { - faith = { - has_doctrine_parameter = bastards_legitimize + scope:secondary_recipient ?= { + rite ?= { + rite_has_parameter = bastards_legitimize } this != scope:actor has_trait = bastard OR = { - father = scope:actor - mother = scope:actor - scope:actor.house.house_head = scope:actor + father ?= scope:actor + mother ?= scope:actor + scope:actor.house.house_head ?= scope:actor } OR = { - house = scope:actor.house + house ?= scope:actor.house AND = { OR = { - father.house = scope:actor.house - mother.house = scope:actor.house + father.house ?= scope:actor.house + mother.house ?= scope:actor.house } has_dynasty = no } + AND = { + scope:actor.rite ?= { + rite_has_parameter = tenet_adoptionism_legitimize_own_children + } + OR = { + father ?= scope:actor + mother ?= scope:actor + } + } } } - scope:actor = { - is_lowborn = no - is_concubine = no - } } is_valid_showing_failures_only = { @@ -584,7 +597,7 @@ legitimize_bastard_interaction = { on_accept = { scope:actor = { - stress_impact = { + stress_and_fulfillment_impact = { arrogant = minor_stress_impact_gain } @@ -677,10 +690,21 @@ accuse_of_decandence_interaction = { desc = accuse_of_decandence_interaction_desc + is_available = { + government_has_flag = government_is_clan + house.house_head ?= this + trigger_if = { + limit = { is_ai = yes } + is_adult = yes + NOT = { + has_trait = forgiving + } + is_at_war = no + } + } + is_shown = { - scope:actor = { government_has_flag = government_is_clan } scope:recipient != scope:actor - scope:actor.house.house_head ?= scope:actor scope:recipient.house ?= scope:actor.house scope:recipient = { NOT = { @@ -706,9 +730,15 @@ accuse_of_decandence_interaction = { on_accept = { scope:actor = { - stress_impact = { - forgiving = minor_stress_impact_gain - compassionate = minor_stress_impact_gain + # Only get stressed/SP penalties if you don't have the parameter + if = { + limit = { + NOT = { sp_hostile_schemes_except_murder_no_stress_or_fulfillment_trigger = yes } + } + stress_and_fulfillment_impact = { + forgiving = minor_stress_impact_gain + compassionate = minor_stress_impact_gain + } } send_interface_toast = { type = event_toast_effect_neutral @@ -780,16 +810,6 @@ accuse_of_decandence_interaction = { auto_accept = yes - ai_potential = { - is_at_war = no - government_has_flag = government_is_clan - house.house_head ?= this - is_adult = yes - NOT = { - has_trait = forgiving - } - } - ai_targets = { ai_recipients = dynasty max = 30 @@ -883,7 +903,7 @@ accuse_of_decandence_interaction = { has_trait = incestuous } NOT = { is_incestuous_trigger = yes } - trait_is_criminal_in_faith_trigger = { TRAIT = trait:incestuous FAITH = scope:actor.faith GENDER_CHARACTER = scope:recipient } + trait_is_criminal_in_rite_trigger = { TRAIT = trait:incestuous RITE = scope:actor.rite GENDER_CHARACTER = scope:recipient } } AND = { scope:recipient = { @@ -899,7 +919,7 @@ accuse_of_decandence_interaction = { has_trait = adulterer has_trait = fornicator } - trait_is_criminal_in_faith_trigger = { TRAIT = trait:adulterer FAITH = scope:actor.faith GENDER_CHARACTER = scope:recipient } + trait_is_criminal_in_rite_trigger = { TRAIT = trait:adulterer RITE = scope:actor.rite GENDER_CHARACTER = scope:recipient } } AND = { scope:recipient = { @@ -909,25 +929,21 @@ accuse_of_decandence_interaction = { has_trait = adulterer has_trait = fornicator } - trait_is_criminal_in_faith_trigger = { TRAIT = trait:fornicator FAITH = scope:actor.faith GENDER_CHARACTER = scope:recipient } + trait_is_criminal_in_rite_trigger = { TRAIT = trait:fornicator RITE = scope:actor.rite GENDER_CHARACTER = scope:recipient } } AND = { scope:recipient = { has_trait = deviant } - NOT = { - is_deviant_trigger = yes - } - trait_is_criminal_in_faith_trigger = { TRAIT = trait:deviant FAITH = scope:actor.faith GENDER_CHARACTER = scope:recipient } + is_deviant_trigger = no + trait_is_criminal_in_rite_trigger = { TRAIT = trait:deviant RITE = scope:actor.rite GENDER_CHARACTER = scope:recipient } } AND = { scope:recipient = { has_trait = witch } - NOT = { - is_witch_trigger = yes - } - trait_is_criminal_in_faith_trigger = { TRAIT = trait:witch FAITH = scope:actor.faith GENDER_CHARACTER = scope:recipient } + is_witch_trigger = no + trait_is_criminal_in_rite_trigger = { TRAIT = trait:witch RITE = scope:actor.rite GENDER_CHARACTER = scope:recipient } } AND = { scope:recipient = { @@ -939,16 +955,14 @@ accuse_of_decandence_interaction = { type = secret_homosexual } } - trait_is_criminal_in_faith_trigger = { TRAIT = trait:sodomite FAITH = scope:actor.faith GENDER_CHARACTER = scope:recipient } + trait_is_criminal_in_rite_trigger = { TRAIT = trait:sodomite RITE = scope:actor.rite GENDER_CHARACTER = scope:recipient } } AND = { scope:recipient = { has_trait = cannibal } - NOT = { - is_cannibal_trigger = yes - } - trait_is_criminal_in_faith_trigger = { TRAIT = trait:cannibal FAITH = scope:actor.faith GENDER_CHARACTER = scope:recipient } + is_cannibal_trigger = no + trait_is_criminal_in_rite_trigger = { TRAIT = trait:cannibal RITE = scope:actor.rite GENDER_CHARACTER = scope:recipient } } } } @@ -989,10 +1003,21 @@ extoll_virtuousness_interaction = { desc = extoll_virtuousness_interaction_desc + is_available = { + government_has_flag = government_is_clan + house.house_head ?= this + trigger_if = { + limit = { is_ai = yes } + is_adult = yes + NOT = { + has_trait = paranoid + } + is_at_war = no + } + } + is_shown = { - scope:actor = { government_has_flag = government_is_clan } scope:recipient != scope:actor - scope:actor.house.house_head ?= scope:actor scope:recipient.house ?= scope:actor.house scope:recipient = { NOT = { @@ -1013,7 +1038,7 @@ extoll_virtuousness_interaction = { on_accept = { scope:actor = { - stress_impact = { + stress_and_fulfillment_impact = { sadistic = minor_stress_impact_gain callous = minor_stress_impact_gain } @@ -1086,16 +1111,6 @@ extoll_virtuousness_interaction = { auto_accept = yes - ai_potential = { - is_at_war = no - government_has_flag = government_is_clan - house.house_head ?= this - is_adult = yes - NOT = { - has_trait = paranoid - } - } - ai_targets = { ai_recipients = dynasty max = 30 diff --git a/common/character_interactions/00_invite_agent_to_scheme.txt b/common/character_interactions/00_invite_agent_to_scheme.txt index 856884147..badd91290 100644 --- a/common/character_interactions/00_invite_agent_to_scheme.txt +++ b/common/character_interactions/00_invite_agent_to_scheme.txt @@ -34,7 +34,7 @@ invite_agent_to_scheme_interaction = { force_add_to_agent_slot = { agent_slot = scope:agent_slot years = 5 - } + } } else = { add_to_agent_slot = scope:agent_slot } } @@ -80,7 +80,7 @@ invite_agent_to_scheme_interaction = { gold = bribe_value target = scope:recipient } - stress_impact = { greedy = minor_stress_impact_gain } + stress_and_fulfillment_impact = { greedy = minor_stress_impact_gain } } # Big Bribe if = { @@ -89,7 +89,7 @@ invite_agent_to_scheme_interaction = { gold = greater_bribe_value target = scope:recipient } - stress_impact = { greedy = medium_stress_impact_gain } + stress_and_fulfillment_impact = { greedy = medium_stress_impact_gain } } # Treasury Bribe if = { @@ -110,7 +110,7 @@ invite_agent_to_scheme_interaction = { # Offer Hook if = { limit = { always = scope:offer_hook } - stress_impact = { + stress_and_fulfillment_impact = { base = minor_stress_impact_gain paranoid = major_stress_impact_gain } @@ -124,7 +124,7 @@ invite_agent_to_scheme_interaction = { # Offer Strong Hook if = { limit = { always = scope:offer_hook_strong } - stress_impact = { base = major_stress_impact_gain } + stress_and_fulfillment_impact = { base = major_stress_impact_gain } scope:recipient = { add_hook = { type = strong_favor_hook @@ -294,7 +294,7 @@ invite_agent_to_scheme_interaction = { modifier = forced_me_to_help_crimes_opinion opinion = -20 } - stress_impact = { + stress_and_fulfillment_impact = { just = minor_stress_impact_gain compassionate = miniscule_stress_impact_gain } @@ -307,7 +307,7 @@ invite_agent_to_scheme_interaction = { modifier = forced_me_to_work_opinion opinion = -10 } - stress_impact = { lazy = miniscule_stress_impact_gain } + stress_and_fulfillment_impact = { lazy = miniscule_stress_impact_gain } } } } @@ -317,7 +317,7 @@ invite_agent_to_scheme_interaction = { base = 0 scheme_modifier = { object = scope:scheme - target = scope:recipient + target = scope:recipient } # You should not add modifiers here! If you want to add modifiers, they should be added to either: ## - ai_agent_join_chance_hostile_general_suite_modifier @@ -374,7 +374,7 @@ invite_agent_to_scheme_interaction = { } trigger_else = { always = no } } - + options_heading = invite_agent_to_scheme_interaction.t.options_header # Everyone ## Spend opportunities. @@ -433,7 +433,7 @@ invite_agent_to_scheme_interaction = { scope:scheme = { is_scheme_category = contract } scope:recipient = { is_courtier_of = scope:actor } } - scope:actor = { + scope:actor = { government_has_flag = government_is_mandala house = { has_house_head_parameter = unlock_force_agent_using_piety } is_house_head = yes @@ -449,7 +449,7 @@ invite_agent_to_scheme_interaction = { text = not_two_overrides trigger_if = { limit = { scope:hook = yes } - NOT = { + NOT = { scope:actor = { has_strong_hook = scope:recipient } } } @@ -652,7 +652,7 @@ invite_agent_to_scheme_interaction = { scope:actor = { has_strong_hook = scope:recipient } } scope:mandala_trickster = no - } + } } would_agent_accept_petty_bribes_against_target_trigger = yes } @@ -687,14 +687,14 @@ invite_agent_to_scheme_interaction = { flag = influence is_shown = { scope:actor.top_liege ?= scope:recipient.top_liege - scope:actor = { government_allows = administrative } + scope:actor = { government_has_flag = government_has_influence } scope:recipient = { OR = { - government_allows = administrative - host = { government_allows = administrative } + government_has_flag = government_has_influence + host = { government_has_flag = government_has_influence } AND = { highest_held_title_tier = tier_barony - liege = { government_allows = administrative } + liege = { government_has_flag = government_has_influence } } } } @@ -870,7 +870,7 @@ invite_agent_to_scheme_interaction = { flag = piety is_shown = { trigger_if = { #Mandala override - limit = { + limit = { scope:actor = { government_has_flag = government_is_mandala } } scope:actor = { @@ -910,8 +910,8 @@ invite_agent_to_scheme_interaction = { is_valid = { scope:actor.piety >= piety_bribe_value trigger_if = { #Mandala override - limit = { - scope:actor = { + limit = { + scope:actor = { NOT = { government_has_flag = government_is_mandala } } } diff --git a/common/character_interactions/00_lover_interactions.txt b/common/character_interactions/00_lover_interactions.txt index 188ff6f21..c9653442e 100644 --- a/common/character_interactions/00_lover_interactions.txt +++ b/common/character_interactions/00_lover_interactions.txt @@ -25,7 +25,7 @@ break_up_with_lover_interaction = { BREAKER = scope:actor LOVER = scope:recipient } - stress_impact = { + stress_and_fulfillment_impact = { lustful = minor_stress_impact_gain compassionate = minor_stress_impact_gain } diff --git a/common/character_interactions/00_marriage_interactions.txt b/common/character_interactions/00_marriage_interactions.txt index a0ae0a0ec..0142fcc09 100644 --- a/common/character_interactions/00_marriage_interactions.txt +++ b/common/character_interactions/00_marriage_interactions.txt @@ -45,13 +45,13 @@ arrange_marriage_interaction = { first_valid = { triggered_desc = { trigger = { - scope:actor = scope:recipient + scope:puppet_or_actor = scope:recipient } desc = arrange_marriage_interaction_desc_ruler_at_own_court } triggered_desc = { trigger = { - scope:actor = { + scope:puppet_or_actor = { can_marry_character_trigger = { CHARACTER = scope:recipient } @@ -79,7 +79,7 @@ arrange_marriage_interaction = { } triggered_desc = { trigger = { - scope:actor = { + scope:puppet_or_actor = { can_marry_character_trigger = { CHARACTER = scope:recipient } @@ -93,7 +93,7 @@ arrange_marriage_interaction = { redirect = { # If the define MARRIAGE_OWNER_IS_MATCHMAKER is set to yes, the actor must end up as the "matchmaker" link for courtiers - scope:actor = { + scope:puppet_or_actor = { if = { limit = { exists = matchmaker @@ -102,6 +102,7 @@ arrange_marriage_interaction = { save_scope_as = secondary_actor matchmaker = { save_scope_as = actor + save_scope_as = puppet_or_actor } } if = { @@ -118,7 +119,7 @@ arrange_marriage_interaction = { if = { limit = { is_betrothed = yes - betrothed.matchmaker = scope:actor + betrothed.matchmaker = scope:puppet_or_actor is_adult = yes betrothed = { is_adult = yes @@ -160,16 +161,27 @@ arrange_marriage_interaction = { } populate_actor_list = { - scope:actor = { - add_to_list = characters + scope:puppet_or_actor = { + if = { + limit = { + trigger_if = { + limit = { exists = scope:secondary_recipient } + can_marry_character_trigger = { CHARACTER = scope:secondary_recipient } + } + } + add_to_list = characters + } every_courtier = { limit = { trigger_if = { limit = { is_concubine = yes } - is_concubine_of = scope:actor - can_marry_character_trigger = { CHARACTER = scope:actor } + is_concubine_of = scope:puppet_or_actor + } + trigger_if = { + limit = { exists = scope:secondary_recipient } + can_marry_character_trigger = { CHARACTER = scope:secondary_recipient } } } add_to_list = characters @@ -180,8 +192,11 @@ arrange_marriage_interaction = { limit = { is_concubine = yes } - is_concubine_of = scope:actor - can_marry_character_trigger = { CHARACTER = scope:actor } + is_concubine_of = scope:puppet_or_actor + } + trigger_if = { + limit = { exists = scope:secondary_recipient } + can_marry_character_trigger = { CHARACTER = scope:secondary_recipient } } } add_to_list = characters @@ -196,8 +211,11 @@ arrange_marriage_interaction = { limit = { is_concubine = yes } - is_concubine_of = scope:actor - can_marry_character_trigger = { CHARACTER = scope:actor } + is_concubine_of = scope:puppet_or_actor + } + trigger_if = { + limit = { exists = scope:secondary_recipient } + can_marry_character_trigger = { CHARACTER = scope:secondary_recipient } } } add_to_list = characters @@ -209,16 +227,19 @@ arrange_marriage_interaction = { is_alive = yes NOT = { is_in_list = characters } OR = { - top_liege = scope:actor - house.house_head = scope:actor - dynasty.dynast = scope:actor + top_liege = scope:puppet_or_actor + house.house_head = scope:puppet_or_actor + dynasty.dynast = scope:puppet_or_actor } trigger_if = { limit = { is_concubine = yes } - is_concubine_of = scope:actor - can_marry_character_trigger = { CHARACTER = scope:actor } + is_concubine_of = scope:puppet_or_actor + } + trigger_if = { + limit = { exists = scope:secondary_recipient } + can_marry_character_trigger = { CHARACTER = scope:secondary_recipient } } } add_to_list = characters @@ -229,16 +250,19 @@ arrange_marriage_interaction = { is_alive = yes NOT = { is_in_list = characters } OR = { - top_liege = scope:actor - house.house_head = scope:actor - dynasty.dynast = scope:actor + top_liege = scope:puppet_or_actor + house.house_head = scope:puppet_or_actor + dynasty.dynast = scope:puppet_or_actor } trigger_if = { limit = { is_concubine = yes } - is_concubine_of = scope:actor - can_marry_character_trigger = { CHARACTER = scope:actor } + is_concubine_of = scope:puppet_or_actor + } + trigger_if = { + limit = { exists = scope:secondary_recipient } + can_marry_character_trigger = { CHARACTER = scope:secondary_recipient } } } add_to_list = characters @@ -251,16 +275,40 @@ arrange_marriage_interaction = { populate_recipient_list = { scope:recipient = { - add_to_list = characters + if = { + limit = { + trigger_if = { + limit = { exists = scope:secondary_actor } + can_marry_character_trigger = { CHARACTER = scope:secondary_actor } + } + } + add_to_list = characters + } every_courtier = { + limit = { + trigger_if = { + limit = { exists = scope:secondary_actor } + can_marry_character_trigger = { CHARACTER = scope:secondary_actor } + } + } add_to_list = characters } every_courtier_away = { + limit = { + trigger_if = { + limit = { exists = scope:secondary_actor } + can_marry_character_trigger = { CHARACTER = scope:secondary_actor } + } + } add_to_list = characters } every_child = { limit = { NOT = { is_in_list = characters } + trigger_if = { + limit = { exists = scope:secondary_actor } + can_marry_character_trigger = { CHARACTER = scope:secondary_actor } + } } add_to_list = characters } @@ -274,27 +322,27 @@ arrange_marriage_interaction = { value = 0 if = { limit = { - exists = scope:actor + exists = scope:puppet_or_actor exists = scope:recipient exists = scope:secondary_recipient exists = scope:secondary_actor - scope:secondary_actor = { is_close_family_of = scope:actor } + scope:secondary_actor = { is_close_family_of = scope:puppet_or_actor } scope:recipient = { OR = { AND = { vassal_contract_has_flag = vassal_contract_marriage_favor - is_allied_to = scope:actor + is_allied_to = scope:puppet_or_actor } NOT = { vassal_contract_has_flag = vassal_contract_marriage_favor} } } } add = { - scope:actor = { + scope:puppet_or_actor = { every_vassal = { limit = { vassal_contract_has_flag = vassal_contract_marriage_favor - NOT = { is_allied_to = scope:actor } + NOT = { is_allied_to = scope:puppet_or_actor } NOR = { this = scope:recipient this = scope:secondary_recipient @@ -312,16 +360,36 @@ arrange_marriage_interaction = { # value = 0 # if = { # limit = { scope:piety_cost_reduction = yes } -# add = scope:actor.medium_piety_value +# add = scope:puppet_or_actor.medium_piety_value # desc = STRUGGLE_MARRIAGE_ACCEPTANCE_USING_PIETY_AS_CURRENCY # } +# if = { +# limit = { +# exists = scope:puppet_or_actor +# exists = scope:recipient +# exists = scope:secondary_recipient +# exists = scope:secondary_actor +# scope:secondary_actor = { +# faith != scope:secondary_recipient.faith +# } +# scope:puppet_or_actor = { +# any_character_struggle = { +# has_struggle_phase_parameter = interfaith_marriages_between_involved_characters_costs_piety +# } +# } +# } +# add = { +# value = major_piety_value +# desc = CB_STRUGGLE_PHASE_SURCHARGE +# } +# } # } influence = { value = 0 if = { limit = { scope:influence_send_option = yes } - add = scope:actor.medium_influence_value + add = scope:puppet_or_actor.medium_influence_value desc = INFLUENCE_INTERACTION_ACCEPTANCE_SEND_OPTION } } @@ -331,7 +399,7 @@ arrange_marriage_interaction = { # secondary_actor, secondary_recipient ... characters that should marry is_shown = { - scope:actor = { + scope:puppet_or_actor ?= { OR = { is_ruler = yes #Can arrange marriages for others #You're just a courtier? Only use the interaction on characters you can marry @@ -355,10 +423,10 @@ arrange_marriage_interaction = { AND = { ready_to_marry_betrothed_trigger = yes OR = { - betrothed = scope:secondary_actor + betrothed ?= scope:secondary_actor trigger_if = { limit = { exists = betrothed.liege } - betrothed.liege = scope:actor + betrothed.liege = scope:puppet_or_actor } } } @@ -368,22 +436,22 @@ arrange_marriage_interaction = { limit = { is_concubine = yes } - is_concubine_of = scope:actor - can_marry_character_trigger = { CHARACTER = scope:actor } + is_concubine_of = scope:puppet_or_actor + can_marry_character_trigger = { CHARACTER = scope:puppet_or_actor } } } } #allow landless adventurers to marry only within their camp, or with Contact list courtiers (after using request_marriage option in contact_list_request_interaction), or prieviously betrothed characters trigger_if = { limit = { - scope:actor = { - OR = { government_has_flag = government_is_landless_adventurer government_has_flag = government_is_landless_minority } + scope:puppet_or_actor = { + government_has_flag = government_is_landless_adventurer } } trigger_if = { limit = { OR = { - scope:actor = { + scope:puppet_or_actor ?= { is_target_in_variable_list = { name = contact_list_marriage target = scope:recipient @@ -391,18 +459,18 @@ arrange_marriage_interaction = { } scope:recipient = { is_betrothed = yes - betrothed = { + betrothed ?= { OR = { - scope:actor = this + scope:puppet_or_actor ?= this scope:secondary_actor ?= this } } } scope:secondary_recipient ?= { is_betrothed = yes - betrothed = { + betrothed ?= { OR = { - scope:actor = this + scope:puppet_or_actor ?= this scope:secondary_actor ?= this } } @@ -412,12 +480,13 @@ arrange_marriage_interaction = { always = yes } trigger_else = { - scope:recipient = scope:actor + scope:recipient = scope:puppet_or_actor } } } is_valid_showing_failures_only = { + pam_ai_marriage_respects_clerical_restraint_trigger = yes #If we're opening this interaction through the interaction menu (i.e. not all scopes exist yet) #This was giving double-warnings about a marry-able character existing so it's commented out for now #custom_description = { @@ -445,7 +514,7 @@ arrange_marriage_interaction = { #There is an available marriage custom_description = { text = "basic_can_marry_check_recipient" - subject = scope:actor + subject = scope:puppet_or_actor object = scope:recipient scope:recipient = { OR = { @@ -457,15 +526,15 @@ arrange_marriage_interaction = { limit = { is_concubine = yes } - is_concubine_of = scope:actor - can_marry_character_trigger = { CHARACTER = scope:actor } + is_concubine_of = scope:puppet_or_actor + can_marry_character_trigger = { CHARACTER = scope:puppet_or_actor } } } AND = { is_ruler = yes #(Following are only for rulers) OR = { any_child = { - matchmaker = scope:actor + matchmaker = scope:puppet_or_actor OR = { #Any of recipient's children can marry AND = { @@ -475,13 +544,13 @@ arrange_marriage_interaction = { limit = { is_concubine = yes } - is_concubine_of = scope:actor + is_concubine_of = scope:puppet_or_actor } } #Any of recipient's children are ready to marry their betrothed AND = { ready_to_marry_betrothed_trigger = yes - betrothed.matchmaker = scope:actor + betrothed.matchmaker = scope:puppet_or_actor } } } @@ -495,13 +564,13 @@ arrange_marriage_interaction = { limit = { is_concubine = yes } - is_concubine_of = scope:actor + is_concubine_of = scope:puppet_or_actor } } #Any of recipient's courtiers are ready to marry their betrothed AND = { ready_to_marry_betrothed_trigger = yes - betrothed.matchmaker = scope:actor + betrothed.matchmaker = scope:puppet_or_actor } } } @@ -516,7 +585,7 @@ arrange_marriage_interaction = { is_imprisoned = no } NOT = { - scope:actor = { + scope:puppet_or_actor = { is_at_war_with = scope:recipient } } @@ -533,7 +602,7 @@ arrange_marriage_interaction = { trigger_if = { #(must be here because secondary_recipient can be set at the start) limit = { exists = scope:secondary_actor - scope:secondary_actor != scope:actor + scope:secondary_actor != scope:puppet_or_actor } scope:secondary_actor = { is_imprisoned = no @@ -543,7 +612,7 @@ arrange_marriage_interaction = { # Account for regents being bolshy. marriage_interaction_non_loyal_diarchs_refuse_secondary_marriage_trigger = { TARGET = secondary_actor } marriage_interaction_non_loyal_diarchs_refuse_secondary_marriage_trigger = { TARGET = secondary_recipient } - marriage_interaction_non_loyal_diarchs_refuse_secondary_marriage_trigger = { TARGET = actor } + marriage_interaction_non_loyal_diarchs_refuse_secondary_marriage_trigger = { TARGET = puppet_or_actor } marriage_interaction_non_loyal_diarchs_refuse_secondary_marriage_trigger = { TARGET = recipient } } @@ -571,7 +640,7 @@ arrange_marriage_interaction = { is_pool_guest = yes host = { is_ai = no - this != scope:actor + this != scope:puppet_or_actor } } NOT = { is_pool_guest_of = host } @@ -581,7 +650,7 @@ arrange_marriage_interaction = { #Blocks most AI's from marrying Evil faiths trigger_if = { limit = { - scope:actor = { + scope:puppet_or_actor = { is_ai = yes NOT = { has_trait = cynical } #AI should honor betrothal even if faiths change @@ -590,7 +659,7 @@ arrange_marriage_interaction = { } scope:recipient.faith = { faith_hostility_level = { - target = scope:actor.faith + target = scope:puppet_or_actor.faith value < faith_hostility_prevents_marriage_level } } @@ -599,7 +668,7 @@ arrange_marriage_interaction = { #Blocks AI from marrying single mayors in their area unless they are also mayors trigger_if = { limit = { - scope:actor = { + scope:puppet_or_actor = { is_ai = yes NOT = { government_has_flag = government_is_republic } } @@ -611,7 +680,7 @@ arrange_marriage_interaction = { trigger_if = { # Cultural Traditions, for AI limit = { - scope:actor = { + scope:puppet_or_actor = { is_ai = yes culture = { has_cultural_parameter = dislikes_marrying_outside_of_culture @@ -619,8 +688,20 @@ arrange_marriage_interaction = { } } OR = { - scope:actor.culture = scope:recipient.culture - scope:actor.culture = scope:secondary_recipient.culture + scope:puppet_or_actor.culture = scope:recipient.culture + scope:puppet_or_actor.culture = scope:secondary_recipient.culture + } + } + trigger_if = { # Pastoral Isolation personal tenet, for AI + limit = { + scope:puppet_or_actor = { + is_ai = yes + has_personal_tenet_flag = tenet_pastoral_isolation_endogamy + } + } + OR = { + scope:puppet_or_actor.faith = scope:recipient.faith + scope:puppet_or_actor.faith = scope:secondary_recipient.faith } } } @@ -629,7 +710,7 @@ arrange_marriage_interaction = { if = { limit = { NOR = { - scope:recipient = scope:actor + scope:recipient = scope:puppet_or_actor scope:secondary_actor = { has_been_promised_grand_wedding = yes } scope:secondary_recipient = { has_been_promised_grand_wedding = yes } } @@ -659,7 +740,7 @@ arrange_marriage_interaction = { limit = { scope:grand_wedding_promise = yes } - scope:actor = { + scope:puppet_or_actor = { set_variable = { name = grand_wedding_promise_pending days = 10 @@ -693,14 +774,14 @@ arrange_marriage_interaction = { on_accept = { marriage_interaction_on_accept_effect = yes - scope:actor = { + scope:puppet_or_actor = { if = { limit = { scope:herd_send_option = yes } pay_herd = { target = scope:recipient - value = scope:actor.domicile.medium_herd_value + value = scope:puppet_or_actor.domicile.medium_herd_value } } if = { @@ -725,7 +806,7 @@ arrange_marriage_interaction = { } on_decline = { - scope:actor = { + scope:puppet_or_actor = { if = { limit = { this != scope:recipient } trigger_event = marriage_interaction.0011 @@ -752,7 +833,7 @@ arrange_marriage_interaction = { ai_accept = { base = 0 - marriage_ai_accept_modifier = yes + marriage_ai_accept_modifier = yes } # If you want the AI to set these options then it needs to be hooked into the code as well @@ -761,9 +842,9 @@ arrange_marriage_interaction = { localization = GRAND_WEDDING_PROMISE is_shown = { - scope:actor = { #Can organize a Grand Wedding + scope:puppet_or_actor = { #Can organize a Grand Wedding highest_held_title_tier > tier_barony - is_landed_or_landless_administrative = yes + is_landed_or_landless_administrative_or_theocratic = yes trigger_if = { limit = { is_ai = yes @@ -781,7 +862,7 @@ arrange_marriage_interaction = { } is_valid = { - scope:actor = { + scope:puppet_or_actor = { gold >= real_wedding_cost_actor_scope is_available = yes custom_tooltip = { @@ -819,7 +900,7 @@ arrange_marriage_interaction = { custom_tooltip = { text = grand_wedding_only_family scope:secondary_actor ?= { - is_close_or_extended_family_of = scope:actor + is_close_or_extended_family_of = scope:puppet_or_actor } } # Cannot promise grand weddings with regents due to regency and travel limitations @@ -843,7 +924,7 @@ arrange_marriage_interaction = { trigger_if = { limit = { OR = { - scope:actor = { is_ai = no } + scope:puppet_or_actor = { is_ai = no } scope:secondary_actor ?= { is_ai = no } } } @@ -894,23 +975,6 @@ arrange_marriage_interaction = { desc = "MATRILINEAL_OFFER_BETROTHAL_INFO" } } - is_valid = { - custom_tooltip = { # TGP TENNO EXCEPTION - text = tgp_blocked_ceremonial_house_matrilineal_marriage_trigger - NOT = { - scope:secondary_actor.top_liege.primary_title.var:administrative_ui_special_title.holder ?= { - scope:recipient ?= this - NOR = { - faith = { has_doctrine = doctrine_gender_female_dominated } - AND = { - scope:secondary_recipient ?= { is_female = yes } - faith = { has_doctrine = doctrine_gender_equal } - } - } - } - } - } - } can_be_changed = { trigger_if = { limit = { @@ -944,8 +1008,8 @@ arrange_marriage_interaction = { } trigger_else_if = { limit = { - scope:secondary_actor ?= scope:actor - scope:actor = { + scope:secondary_actor ?= scope:puppet_or_actor + scope:puppet_or_actor = { is_female = yes is_ai = no } @@ -953,17 +1017,17 @@ arrange_marriage_interaction = { always = yes } trigger_else = { - scope:actor = { + scope:puppet_or_actor = { OR = { - faith = { - has_doctrine = doctrine_gender_female_dominated + rite = { + rite_has_doctrine = doctrine_gender_female_dominated } AND = { this = scope:recipient scope:secondary_recipient ?= { is_female = yes } - faith = { has_doctrine = doctrine_gender_equal } + rite = { rite_has_doctrine = doctrine_gender_equal } } AND = { scope:secondary_actor ?= this @@ -987,7 +1051,7 @@ arrange_marriage_interaction = { } } is_valid = { - scope:actor = { + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } @@ -997,7 +1061,7 @@ arrange_marriage_interaction = { # send_option = { # FP3 # is_shown = { -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # is_struggle_type = persian_struggle # has_struggle_phase_parameter = can_trade_piety_for_marriage_acceptance @@ -1005,7 +1069,7 @@ arrange_marriage_interaction = { # } # } # is_valid = { -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # involvement = involved # is_struggle_type = persian_struggle @@ -1024,17 +1088,17 @@ arrange_marriage_interaction = { send_option = { # EP3 Influence is_shown = { # Actor must have a government that uses influence - scope:actor = { + scope:puppet_or_actor = { government_has_flag = government_has_influence } } is_valid = { # Actor has enough influence - scope:actor = { influence >= medium_influence_value } + scope:puppet_or_actor = { influence >= medium_influence_value } # Both characters are within the same top realm custom_tooltip = { text = not_same_realm_tt - scope:recipient.top_liege = scope:actor.top_liege + scope:recipient.top_liege = scope:puppet_or_actor.top_liege } } flag = influence_send_option @@ -1043,7 +1107,7 @@ arrange_marriage_interaction = { send_option = { # MPO Herd is_shown = { # Actor must have a government that uses Herd - scope:actor = { + scope:puppet_or_actor = { government_has_flag = government_is_nomadic is_ai = no } @@ -1054,14 +1118,14 @@ arrange_marriage_interaction = { } is_valid = { # Actor has enough Herd - scope:actor = { domicile.herd >= domicile.medium_herd_value } + scope:puppet_or_actor = { domicile.herd >= domicile.medium_herd_value } } flag = herd_send_option localization = TRADE_HERD_FOR_BETTER_AI_ACCEPTANCE } should_use_extra_icon = { - scope:actor = { has_usable_hook = scope:recipient } + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } extra_icon = "gfx/interface/icons/character_interactions/hook_icon.dds" @@ -1090,7 +1154,7 @@ arrange_marriage_interaction = { triggered_desc = { trigger = { scope:matrilineal = yes - scope:secondary_actor = scope:actor + scope:secondary_actor = scope:puppet_or_actor scope:secondary_recipient = scope:recipient } desc = MARRIAGE_NOTIFICATION_BOTH_PERSONAL_MATRI @@ -1098,7 +1162,7 @@ arrange_marriage_interaction = { triggered_desc = { trigger = { scope:matrilineal = yes - scope:secondary_actor = scope:actor + scope:secondary_actor = scope:puppet_or_actor } desc = MARRIAGE_NOTIFICATION_ACTOR_PERSONAL_MATRI } @@ -1117,14 +1181,14 @@ arrange_marriage_interaction = { } triggered_desc = { trigger = { - scope:secondary_actor = scope:actor + scope:secondary_actor = scope:puppet_or_actor scope:secondary_recipient = scope:recipient } desc = MARRIAGE_NOTIFICATION_BOTH_PERSONAL } triggered_desc = { trigger = { - scope:secondary_actor = scope:actor + scope:secondary_actor = scope:puppet_or_actor } desc = MARRIAGE_NOTIFICATION_ACTOR_PERSONAL } @@ -1143,7 +1207,7 @@ arrange_marriage_interaction = { triggered_desc = { trigger = { scope:matrilineal = yes - scope:secondary_actor = scope:actor + scope:secondary_actor = scope:puppet_or_actor scope:secondary_recipient = scope:recipient } desc = BETROTHAL_NOTIFICATION_BOTH_PERSONAL_MATRI @@ -1151,7 +1215,7 @@ arrange_marriage_interaction = { triggered_desc = { trigger = { scope:matrilineal = yes - scope:secondary_actor = scope:actor + scope:secondary_actor = scope:puppet_or_actor } desc = BETROTHAL_NOTIFICATION_ACTOR_PERSONAL_MATRI } @@ -1170,14 +1234,14 @@ arrange_marriage_interaction = { } triggered_desc = { trigger = { - scope:secondary_actor = scope:actor + scope:secondary_actor = scope:puppet_or_actor scope:secondary_recipient = scope:recipient } desc = BETROTHAL_NOTIFICATION_BOTH_PERSONAL } triggered_desc = { trigger = { - scope:secondary_actor = scope:actor + scope:secondary_actor = scope:puppet_or_actor } desc = BETROTHAL_NOTIFICATION_ACTOR_PERSONAL } @@ -1231,14 +1295,14 @@ marry_off_interaction = { #populate only with your courtiers or children/grandchildren if you are a landless adventurer if = { limit = { - scope:actor = { + scope:puppet_or_actor = { has_government = landless_adventurer_government } } scope:secondary_actor = { if = { limit = { - scope:actor != this + scope:puppet_or_actor != this } add_to_list = characters } @@ -1248,8 +1312,8 @@ marry_off_interaction = { limit = { is_concubine = yes } - is_concubine_of = scope:actor - can_marry_character_trigger = { CHARACTER = scope:actor } + is_concubine_of = scope:puppet_or_actor + can_marry_character_trigger = { CHARACTER = scope:puppet_or_actor } } } add_to_list = characters @@ -1260,8 +1324,8 @@ marry_off_interaction = { limit = { is_concubine = yes } - is_concubine_of = scope:actor - can_marry_character_trigger = { CHARACTER = scope:actor } + is_concubine_of = scope:puppet_or_actor + can_marry_character_trigger = { CHARACTER = scope:puppet_or_actor } } } add_to_list = characters @@ -1276,8 +1340,8 @@ marry_off_interaction = { limit = { is_concubine = yes } - is_concubine_of = scope:actor - can_marry_character_trigger = { CHARACTER = scope:actor } + is_concubine_of = scope:puppet_or_actor + can_marry_character_trigger = { CHARACTER = scope:puppet_or_actor } } } add_to_list = characters @@ -1292,8 +1356,8 @@ marry_off_interaction = { limit = { is_concubine = yes } - is_concubine_of = scope:actor - can_marry_character_trigger = { CHARACTER = scope:actor } + is_concubine_of = scope:puppet_or_actor + can_marry_character_trigger = { CHARACTER = scope:puppet_or_actor } } } add_to_list = characters @@ -1307,8 +1371,8 @@ marry_off_interaction = { limit = { is_concubine = yes } - is_concubine_of = scope:actor - can_marry_character_trigger = { CHARACTER = scope:actor } + is_concubine_of = scope:puppet_or_actor + can_marry_character_trigger = { CHARACTER = scope:puppet_or_actor } } } add_to_list = characters @@ -1365,27 +1429,27 @@ marry_off_interaction = { value = 0 if = { limit = { - exists = scope:actor + exists = scope:puppet_or_actor exists = scope:recipient exists = scope:secondary_recipient exists = scope:secondary_actor - scope:secondary_actor = { is_close_family_of = scope:actor } + scope:secondary_actor = { is_close_family_of = scope:puppet_or_actor } scope:recipient = { OR = { AND = { vassal_contract_has_flag = vassal_contract_marriage_favor - is_allied_to = scope:actor + is_allied_to = scope:puppet_or_actor } NOT = { vassal_contract_has_flag = vassal_contract_marriage_favor} } } } add = { - scope:actor = { + scope:puppet_or_actor = { every_vassal = { limit = { vassal_contract_has_flag = vassal_contract_marriage_favor - NOT = { is_allied_to = scope:actor } + NOT = { is_allied_to = scope:puppet_or_actor } NOR = { this = scope:recipient this = scope:secondary_recipient @@ -1403,10 +1467,34 @@ marry_off_interaction = { value = 0 if = { limit = { scope:influence_send_option = yes } - add = scope:actor.medium_influence_value + add = scope:puppet_or_actor.medium_influence_value desc = INFLUENCE_INTERACTION_ACCEPTANCE_SEND_OPTION } } + +# piety = { +# value = 0 +# if = { +# limit = { +# exists = scope:puppet_or_actor +# exists = scope:recipient +# exists = scope:secondary_recipient +# exists = scope:secondary_actor +# scope:secondary_actor = { +# faith != scope:secondary_recipient.faith +# } +# scope:puppet_or_actor = { +# any_character_struggle = { +# has_struggle_phase_parameter = interfaith_marriages_between_involved_characters_costs_piety +# } +# } +# } +# add = { +# value = major_piety_value +# desc = CB_STRUGGLE_PHASE_SURCHARGE +# } +# } +# } } interface_priority = 60 @@ -1418,23 +1506,23 @@ marry_off_interaction = { # Enable only for yourself if you're a landless adventurer trigger_if = { limit = { - scope:actor = { + scope:puppet_or_actor = { has_government = landless_adventurer_government } } scope:secondary_actor = { - scope:actor = this + scope:puppet_or_actor = this } } - scope:secondary_actor = { + scope:secondary_actor ?= { #Is this someone I can marry off? OR = { - is_courtier_of = scope:actor + is_courtier_of = scope:puppet_or_actor AND = { - is_child_of = scope:actor - target_is_liege_or_above = scope:actor + is_child_of = scope:puppet_or_actor + target_is_liege_or_above = scope:puppet_or_actor } - scope:actor = this + scope:puppet_or_actor ?= this } #They can be married can_marry_trigger = yes @@ -1443,8 +1531,8 @@ marry_off_interaction = { limit = { is_concubine = yes } - is_concubine_of = scope:actor - can_marry_character_trigger = { CHARACTER = scope:actor } + is_concubine_of = scope:puppet_or_actor + can_marry_character_trigger = { CHARACTER = scope:puppet_or_actor } } } # Block further marriage proposals for people who have a pending grand wedding @@ -1467,7 +1555,7 @@ marry_off_interaction = { } marriage_interaction_non_loyal_diarchs_refuse_secondary_marriage_trigger = { TARGET = secondary_recipient } } - marriage_interaction_non_loyal_diarchs_refuse_secondary_marriage_trigger = { TARGET = actor } + marriage_interaction_non_loyal_diarchs_refuse_secondary_marriage_trigger = { TARGET = puppet_or_actor } marriage_interaction_non_loyal_diarchs_refuse_secondary_marriage_trigger = { TARGET = recipient } } @@ -1479,7 +1567,7 @@ marry_off_interaction = { is_imprisoned = no } NOT = { - scope:actor = { + scope:puppet_or_actor = { is_at_war_with = scope:recipient } } @@ -1499,7 +1587,7 @@ marry_off_interaction = { is_pool_guest = yes host = { is_ai = no - this != scope:actor + this != scope:puppet_or_actor } } NOT = { is_pool_guest_of = host } @@ -1512,7 +1600,7 @@ marry_off_interaction = { limit = { scope:grand_wedding_promise = yes } - scope:actor = { + scope:puppet_or_actor = { set_variable = { name = grand_wedding_promise_pending days = 10 @@ -1549,21 +1637,21 @@ marry_off_interaction = { # If we're a clan this interaction affects unity add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = medium_unity_gain DESC = clan_unity_marry_off.desc REVERSE_NON_HOUSE_TARGET = no } - scope:actor = { + scope:puppet_or_actor = { if = { limit = { scope:herd_send_option = yes } pay_herd = { target = scope:recipient - value = scope:actor.domicile.medium_herd_value + value = scope:puppet_or_actor.domicile.medium_herd_value } } if = { @@ -1576,7 +1664,7 @@ marry_off_interaction = { } on_decline = { - scope:actor = { + scope:puppet_or_actor = { if = { limit = { this != scope:recipient } trigger_event = marriage_interaction.0011 @@ -1591,7 +1679,7 @@ marry_off_interaction = { # If we're a clan this interaction affects unity add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = medium_unity_loss DESC = clan_unity_marry_off_decline.desc @@ -1619,9 +1707,9 @@ marry_off_interaction = { localization = GRAND_WEDDING_PROMISE is_shown = { - scope:actor = { #Can organize a Grand Wedding + scope:puppet_or_actor = { #Can organize a Grand Wedding highest_held_title_tier > tier_barony - is_landed_or_landless_administrative = yes + is_landed_or_landless_administrative_or_theocratic = yes trigger_if = { limit = { is_ai = yes @@ -1639,7 +1727,7 @@ marry_off_interaction = { } is_valid = { - scope:actor = { + scope:puppet_or_actor = { gold >= real_wedding_cost_actor_scope is_available = yes custom_tooltip = { @@ -1676,7 +1764,7 @@ marry_off_interaction = { custom_tooltip = { text = grand_wedding_only_family scope:secondary_actor ?= { - is_close_or_extended_family_of = scope:actor + is_close_or_extended_family_of = scope:puppet_or_actor } } } @@ -1692,14 +1780,14 @@ marry_off_interaction = { } } starts_enabled = { - scope:actor = { + scope:puppet_or_actor = { OR = { - faith = { - has_doctrine = doctrine_gender_female_dominated + rite = { + rite_has_doctrine = doctrine_gender_female_dominated } AND = { scope:secondary_actor ?= { is_female = yes } - faith = { has_doctrine = doctrine_gender_equal } + rite = { rite_has_doctrine = doctrine_gender_equal } } AND = { scope:secondary_actor ?= this @@ -1724,7 +1812,7 @@ marry_off_interaction = { send_option = { is_valid = { - scope:actor = { + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } @@ -1735,17 +1823,17 @@ marry_off_interaction = { send_option = { # EP3 Influence is_shown = { # Actor must have a government that uses influence - scope:actor = { + scope:puppet_or_actor = { government_has_flag = government_has_influence } } is_valid = { # Actor has enough influence - scope:actor = { influence >= medium_influence_value } + scope:puppet_or_actor = { influence >= medium_influence_value } # Both characters are within the same top realm custom_tooltip = { text = not_same_realm_tt - scope:recipient.top_liege = scope:actor.top_liege + scope:recipient.top_liege = scope:puppet_or_actor.top_liege } } flag = influence_send_option @@ -1753,7 +1841,7 @@ marry_off_interaction = { } send_option = { # MPO Herd is_shown = { # Actor must have a government that uses Herd - scope:actor = { + scope:puppet_or_actor = { government_has_flag = government_is_nomadic is_ai = no } @@ -1764,7 +1852,7 @@ marry_off_interaction = { } is_valid = { # Actor has enough Herd - scope:actor = { domicile.herd >= domicile.medium_herd_value } + scope:puppet_or_actor = { domicile.herd >= domicile.medium_herd_value } } flag = herd_send_option localization = TRADE_HERD_FOR_BETTER_AI_ACCEPTANCE @@ -1795,7 +1883,7 @@ marry_off_interaction = { triggered_desc = { trigger = { scope:matrilineal = yes - scope:secondary_actor = scope:actor + scope:secondary_actor = scope:puppet_or_actor scope:secondary_recipient = scope:recipient } desc = MARRIAGE_NOTIFICATION_BOTH_PERSONAL_MATRI @@ -1803,7 +1891,7 @@ marry_off_interaction = { triggered_desc = { trigger = { scope:matrilineal = yes - scope:secondary_actor = scope:actor + scope:secondary_actor = scope:puppet_or_actor } desc = MARRIAGE_NOTIFICATION_ACTOR_PERSONAL_MATRI } @@ -1822,14 +1910,14 @@ marry_off_interaction = { } triggered_desc = { trigger = { - scope:secondary_actor = scope:actor + scope:secondary_actor = scope:puppet_or_actor scope:secondary_recipient = scope:recipient } desc = MARRIAGE_NOTIFICATION_BOTH_PERSONAL } triggered_desc = { trigger = { - scope:secondary_actor = scope:actor + scope:secondary_actor = scope:puppet_or_actor } desc = MARRIAGE_NOTIFICATION_ACTOR_PERSONAL } @@ -1848,7 +1936,7 @@ marry_off_interaction = { triggered_desc = { trigger = { scope:matrilineal = yes - scope:secondary_actor = scope:actor + scope:secondary_actor = scope:puppet_or_actor scope:secondary_recipient = scope:recipient } desc = BETROTHAL_NOTIFICATION_BOTH_PERSONAL_MATRI @@ -1856,7 +1944,7 @@ marry_off_interaction = { triggered_desc = { trigger = { scope:matrilineal = yes - scope:secondary_actor = scope:actor + scope:secondary_actor = scope:puppet_or_actor } desc = BETROTHAL_NOTIFICATION_ACTOR_PERSONAL_MATRI } @@ -1875,14 +1963,14 @@ marry_off_interaction = { } triggered_desc = { trigger = { - scope:secondary_actor = scope:actor + scope:secondary_actor = scope:puppet_or_actor scope:secondary_recipient = scope:recipient } desc = BETROTHAL_NOTIFICATION_BOTH_PERSONAL } triggered_desc = { trigger = { - scope:secondary_actor = scope:actor + scope:secondary_actor = scope:puppet_or_actor } desc = BETROTHAL_NOTIFICATION_ACTOR_PERSONAL } @@ -1909,18 +1997,18 @@ break_betrothal_interaction = { is_shown = { OR = { #Actor breaking their betrothal to recipient or recipient's courtier/vassal child - scope:actor.betrothed ?= { + scope:puppet_or_actor.betrothed ?= { break_betrothal_valid_target_trigger = { CHARACTER = scope:recipient } } #Actor breaking the betrothal of their courtier/vassal child scope:recipient = { - break_betrothal_valid_target_trigger = { CHARACTER = scope:actor } + break_betrothal_valid_target_trigger = { CHARACTER = scope:puppet_or_actor } } #Break recipient's betrothal with actor, or actor's vassal child/courtier scope:recipient.betrothed ?= { - break_betrothal_valid_target_trigger = { CHARACTER = scope:actor } + break_betrothal_valid_target_trigger = { CHARACTER = scope:puppet_or_actor } } } } @@ -1940,7 +2028,7 @@ break_betrothal_interaction = { limit = { betrothed ?= { is_ai = yes - break_betrothal_valid_target_trigger = { CHARACTER = scope:actor } + break_betrothal_valid_target_trigger = { CHARACTER = scope:puppet_or_actor } } } add_to_list = characters @@ -1955,7 +2043,7 @@ break_betrothal_interaction = { } OR = { is_playable_character = no - any_parent = { this = scope:actor } + any_parent = { this = scope:puppet_or_actor } } } add_to_list = characters @@ -1966,16 +2054,16 @@ break_betrothal_interaction = { # secondary_actor is the one under actor's control, could be actor if = { limit = { - scope:actor.betrothed ?= { + scope:puppet_or_actor.betrothed ?= { break_betrothal_valid_target_trigger = { CHARACTER = scope:recipient } } } - scope:actor = { save_scope_as = secondary_actor } + scope:puppet_or_actor = { save_scope_as = secondary_actor } } else_if = { limit = { scope:recipient = { - break_betrothal_valid_target_trigger = { CHARACTER = scope:actor } + break_betrothal_valid_target_trigger = { CHARACTER = scope:puppet_or_actor } } } scope:recipient = { save_scope_as = secondary_actor } @@ -1986,7 +2074,7 @@ break_betrothal_interaction = { } is_valid_showing_failures_only = { - scope:recipient = { NOT = { has_strong_hook = scope:actor } } + scope:recipient = { NOT = { has_strong_hook = scope:puppet_or_actor } } # Recipient is the betrothed custom_description = { text = break_betrothal_hook_used @@ -1994,7 +2082,7 @@ break_betrothal_interaction = { trigger_if = { limit = { scope:recipient.betrothed ?= { - break_betrothal_valid_target_trigger = { CHARACTER = scope:actor } + break_betrothal_valid_target_trigger = { CHARACTER = scope:puppet_or_actor } } exists = scope:recipient.var:hook_used_for_betrothal } @@ -2010,7 +2098,7 @@ break_betrothal_interaction = { trigger_if = { limit = { scope:recipient.betrothed ?= { - break_betrothal_valid_target_trigger = { CHARACTER = scope:actor } + break_betrothal_valid_target_trigger = { CHARACTER = scope:puppet_or_actor } } exists = scope:recipient.betrothed.var:hook_used_for_betrothal } @@ -2031,16 +2119,16 @@ break_betrothal_interaction = { #Check for courtiers any_courtier = { is_betrothed = yes - betrothed = scope:actor + betrothed = scope:puppet_or_actor liege = scope:recipient var:hook_used_for_betrothal ?= { - this = scope:actor + this = scope:puppet_or_actor } } #Check for vassal children any_child = { is_betrothed = yes - betrothed = scope:actor + betrothed = scope:puppet_or_actor OR = { is_playable_character = no target_is_liege_or_above = scope:recipient @@ -2048,11 +2136,11 @@ break_betrothal_interaction = { NOT = { matchmaker = { is_parent_of = prev - this != scope:actor + this != scope:puppet_or_actor } } var:hook_used_for_betrothal ?= { - this = scope:actor + this = scope:puppet_or_actor } } } @@ -2155,7 +2243,7 @@ break_betrothal_interaction = { #Only applied for relevant characters cost_prestige_for_break_betrothal_trigger = yes } - scope:actor = { add_prestige = monumental_prestige_loss } + scope:puppet_or_actor = { add_prestige = monumental_prestige_loss } } else_if = { @@ -2167,7 +2255,7 @@ break_betrothal_interaction = { #Only applied for relevant characters cost_prestige_for_break_betrothal_trigger = yes } - scope:actor = { add_prestige = massive_prestige_loss } + scope:puppet_or_actor = { add_prestige = massive_prestige_loss } } else_if = { @@ -2179,7 +2267,7 @@ break_betrothal_interaction = { #Only applied for relevant characters cost_prestige_for_break_betrothal_trigger = yes } - scope:actor = { add_prestige = major_prestige_loss } + scope:puppet_or_actor = { add_prestige = major_prestige_loss } } else_if = { @@ -2191,7 +2279,7 @@ break_betrothal_interaction = { #Only applied for relevant characters cost_prestige_for_break_betrothal_trigger = yes } - scope:actor = { add_prestige = medium_prestige_loss } + scope:puppet_or_actor = { add_prestige = medium_prestige_loss } } else_if = { @@ -2203,7 +2291,7 @@ break_betrothal_interaction = { #Only applied for relevant characters cost_prestige_for_break_betrothal_trigger = yes } - scope:actor = { add_prestige = minor_prestige_loss } + scope:puppet_or_actor = { add_prestige = minor_prestige_loss } } else_if = { @@ -2215,7 +2303,7 @@ break_betrothal_interaction = { #Only applied for relevant characters cost_prestige_for_break_betrothal_trigger = yes } - scope:actor = { add_prestige = miniscule_prestige_loss } + scope:puppet_or_actor = { add_prestige = miniscule_prestige_loss } } } @@ -2236,7 +2324,7 @@ break_betrothal_interaction = { } } } - scope:actor = { break_grand_wedding_betrothal_effect = yes } + scope:puppet_or_actor = { break_grand_wedding_betrothal_effect = yes } } ###################################### @@ -2251,20 +2339,20 @@ break_betrothal_interaction = { scope:rejected_betrothed = { show_as_tooltip = { add_opinion = { - target = scope:actor + target = scope:puppet_or_actor modifier = broke_betrothal_opinion } } } if = { limit = { - scope:actor != scope:rejected_betrothal_owner + scope:puppet_or_actor != scope:rejected_betrothal_owner scope:rejected_betrothal_owner != scope:rejected_betrothed } scope:rejected_betrothal_owner = { show_as_tooltip = { add_opinion = { - target = scope:actor + target = scope:puppet_or_actor modifier = broke_betrothal_opinion } } @@ -2273,7 +2361,7 @@ break_betrothal_interaction = { } if = { limit = { - scope:actor != scope:rejected_betrothal_owner + scope:puppet_or_actor != scope:rejected_betrothal_owner } scope:rejected_betrothal_owner = { trigger_event = marriage_interaction.0001 } } @@ -2294,7 +2382,7 @@ break_betrothal_interaction = { #Opinion hit for close relatives of the rejected_betrothed (that are not rejected_betrothed_owner) if = { limit = { - scope:rejected_betrothed != scope:actor + scope:rejected_betrothed != scope:puppet_or_actor scope:rejected_betrothed = { any_close_or_extended_family_member = { this != scope:rejected_betrothal_owner @@ -2317,7 +2405,7 @@ break_betrothal_interaction = { custom = all_family_members add_opinion = { - target = scope:actor + target = scope:puppet_or_actor modifier = broke_betrothal_grand_wedding_opinion opinion = -50 } @@ -2332,7 +2420,7 @@ break_betrothal_interaction = { } custom = all_family_members add_opinion = { - target = scope:actor + target = scope:puppet_or_actor modifier = broke_betrothal_opinion } } @@ -2343,8 +2431,8 @@ break_betrothal_interaction = { #Opinion hit for close relatives of the rejecting_betrothed (that are not also close relatives to rejected_betrothed) if = { limit = { - scope:rejecting_betrothed != scope:actor - scope:rejected_betrothed != scope:actor + scope:rejecting_betrothed != scope:puppet_or_actor + scope:rejected_betrothed != scope:puppet_or_actor scope:rejecting_betrothed = { any_close_or_extended_family_member = { NOR = { @@ -2370,12 +2458,12 @@ break_betrothal_interaction = { is_close_or_extended_family_of = scope:rejected_betrothed this = scope:rejected_betrothal_owner this = scope:rejected_betrothed - this = scope:actor + this = scope:puppet_or_actor } } custom = all_family_members add_opinion = { - target = scope:actor + target = scope:puppet_or_actor modifier = broke_betrothal_grand_wedding_opinion opinion = -50 } @@ -2390,12 +2478,12 @@ break_betrothal_interaction = { is_close_or_extended_family_of = scope:rejected_betrothed this = scope:rejected_betrothal_owner this = scope:rejected_betrothed - this = scope:actor + this = scope:puppet_or_actor } } custom = all_family_members add_opinion = { - target = scope:actor + target = scope:puppet_or_actor modifier = broke_betrothal_opinion } } @@ -2404,12 +2492,12 @@ break_betrothal_interaction = { } } - scope:actor = { + scope:puppet_or_actor = { # Was the marriage of relevence to the player? if = { limit = { scope:rejecting_betrothed = { - is_child_of = scope:actor + is_child_of = scope:puppet_or_actor } } hidden_effect = { @@ -2424,7 +2512,7 @@ break_betrothal_interaction = { } else_if = { limit = { - scope:actor != scope:rejecting_betrothed + scope:puppet_or_actor != scope:rejecting_betrothed } hidden_effect = { send_interface_message = { @@ -2443,12 +2531,12 @@ break_betrothal_interaction = { var:promised_to_marry_1 ?= { this = scope:rejected_betrothed any_parent = { - is_vassal_of = scope:actor + is_vassal_of = scope:puppet_or_actor } } var:promised_to_marry_2 ?= { this = scope:rejecting_betrothed - is_close_family_of = scope:actor + is_close_family_of = scope:puppet_or_actor } } remove_variable = promised_to_marry_1 @@ -2459,7 +2547,7 @@ break_betrothal_interaction = { # If we're a clan this interaction affects unity add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = major_unity_loss DESC = clan_unity_betrothal_breakage.desc @@ -2495,15 +2583,18 @@ ai_make_concubine_interaction = { hegemony = 3 } - ai_potential = { - is_playable_character = yes - is_adult = yes - fertility > 0 - allowed_more_concubines = yes - NOR = { - has_trait = chaste - has_trait = celibate - has_sexuality = asexual + is_available = { + trigger_if = { + limit = { is_ai = yes } + allowed_more_concubines = yes + is_playable_character = yes + NOR = { + has_trait = chaste + has_sexuality = asexual + has_trait = celibate + } + fertility > 0 + is_adult = yes } } @@ -2605,7 +2696,7 @@ ai_make_concubine_interaction = { modifier = { # Incest Filtering: Hard NO! factor = 0 scope:actor = { - relation_with_character_is_incestuous_in_my_faith_trigger = { CHARACTER = scope:recipient } + relation_with_character_is_incestuous_in_my_rite_trigger = { CHARACTER = scope:recipient } NOR = { accepts_incest_with_trigger = { CHARACTER = scope:recipient } sexually_liberal_trigger = yes @@ -2624,7 +2715,7 @@ ai_make_concubine_interaction = { modifier = { # Incest Filtering: Not likely, but keep the door open... factor = 0.2 scope:actor = { - relation_with_character_is_incestuous_in_my_faith_trigger = { CHARACTER = scope:recipient } + relation_with_character_is_incestuous_in_my_rite_trigger = { CHARACTER = scope:recipient } OR = { accepts_incest_with_trigger = { CHARACTER = scope:recipient } sexually_liberal_trigger = yes @@ -2686,7 +2777,7 @@ make_concubine_interaction = { redirect = { # The UI will open to the already filled left and right first if we don't tell it we've got both sides filled - scope:actor = { + scope:puppet_or_actor = { save_scope_as = secondary_actor } scope:recipient = { @@ -2695,17 +2786,17 @@ make_concubine_interaction = { } populate_recipient_list = { - scope:actor = { + scope:puppet_or_actor = { every_courtier = { limit = { - can_become_concubine_of_character_trigger = { CHARACTER = scope:actor } + can_become_concubine_of_character_trigger = { CHARACTER = scope:puppet_or_actor } } add_to_list = characters } every_prisoner = { limit = { NOT = { is_in_list = characters } - can_become_concubine_of_character_trigger = { CHARACTER = scope:actor } + can_become_concubine_of_character_trigger = { CHARACTER = scope:puppet_or_actor } } add_to_list = characters } @@ -2723,11 +2814,14 @@ make_concubine_interaction = { auto_accept = yes on_accept = { + scope:puppet_or_actor = { + save_scope_as = secondary_actor + } concubine_on_accept_effect = yes # If we're a clan this interaction affects unity add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = minor_unity_gain DESC = clan_unity_concubinage.desc @@ -2747,7 +2841,7 @@ find_concubine = { needs_recipient_to_open = no redirect = { - scope:actor = { # The UI will open to the already filled left first if we don't tell it we've got "our side" actor which is always ourselves + scope:puppet_or_actor = { # The UI will open to the already filled left first if we don't tell it we've got "our side" actor which is always ourselves save_scope_as = secondary_actor } if = { @@ -2755,7 +2849,7 @@ find_concubine = { # This is needed for the UI to function properly. Initially UI opens with player as both actor and recipient # After UI opens with empty recipient, player can click on a candidate # When candidate is selected both primary and secondary recipient must be set for the interaction to work - scope:actor != scope:recipient + scope:puppet_or_actor != scope:recipient } scope:recipient = { save_scope_as = secondary_recipient @@ -2764,17 +2858,17 @@ find_concubine = { } populate_recipient_list = { - scope:actor = { + scope:puppet_or_actor = { every_courtier = { limit = { - can_become_concubine_of_character_trigger = { CHARACTER = scope:actor } + can_become_concubine_of_character_trigger = { CHARACTER = scope:puppet_or_actor } } add_to_list = characters } every_prisoner = { limit = { NOT = { is_in_list = characters } - can_become_concubine_of_character_trigger = { CHARACTER = scope:actor } + can_become_concubine_of_character_trigger = { CHARACTER = scope:puppet_or_actor } } add_to_list = characters } @@ -2782,35 +2876,35 @@ find_concubine = { } is_shown = { - scope:actor = { + scope:puppet_or_actor ?= { allowed_concubines = yes is_adult = yes trigger_if = { #So that we show the recipient list, but can also only use this on ourselves, we have to do this check in the beginning limit = { NOT = { exists = scope:secondary_recipient } } - scope:actor = scope:recipient + scope:puppet_or_actor = scope:recipient } } trigger_if = { limit = { - scope:actor != scope:recipient + scope:puppet_or_actor != scope:recipient } - scope:actor = { + scope:puppet_or_actor ?= { trigger_if = { limit = { allowed_to_marry_same_sex_trigger = no } sex_opposite_of = scope:recipient } - NOT = { relation_with_character_is_incestuous_in_my_faith_trigger = { CHARACTER = scope:recipient } } + NOT = { relation_with_character_is_incestuous_in_my_rite_trigger = { CHARACTER = scope:recipient } } } scope:recipient = { - can_become_concubine_of_character_trigger = { CHARACTER = scope:actor } + can_become_concubine_of_character_trigger = { CHARACTER = scope:puppet_or_actor } is_adult = yes OR = { - is_imprisoned_by = scope:actor - is_courtier_of = scope:actor + is_imprisoned_by = scope:puppet_or_actor + is_courtier_of = scope:puppet_or_actor } } } @@ -2820,30 +2914,30 @@ find_concubine = { custom_description = { text = take_concubine_allowed_more object = scope:recipient - scope:actor = { + scope:puppet_or_actor = { allowed_more_concubines = yes } } custom_description = { text = take_concubine_available_character_opp - object = scope:actor - scope:actor = { + object = scope:puppet_or_actor + scope:puppet_or_actor = { OR = { any_courtier = { - can_become_concubine_of_character_trigger = { CHARACTER = scope:actor } + can_become_concubine_of_character_trigger = { CHARACTER = scope:puppet_or_actor } } any_prisoner = { - can_become_concubine_of_character_trigger = { CHARACTER = scope:actor } + can_become_concubine_of_character_trigger = { CHARACTER = scope:puppet_or_actor } } } } } trigger_if = { limit = { - scope:actor != scope:recipient + scope:puppet_or_actor != scope:recipient } scope:recipient = { - can_become_concubine_of_character_trigger = { CHARACTER = scope:actor } + can_become_concubine_of_character_trigger = { CHARACTER = scope:puppet_or_actor } } } } @@ -2863,7 +2957,7 @@ find_concubine = { # If we're a clan this interaction affects unity add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = minor_unity_gain DESC = clan_unity_concubinage.desc @@ -2902,11 +2996,11 @@ offer_concubine = { #interface = concubine_list populate_recipient_list = { - scope:actor = { + scope:puppet_or_actor = { every_courtier = { limit = { can_be_offered_as_concubine_to_character_trigger = { - GIVER = scope:actor + GIVER = scope:puppet_or_actor CHARACTER = scope:recipient } } @@ -2916,7 +3010,7 @@ offer_concubine = { limit = { NOT = { is_in_list = characters } can_be_offered_as_concubine_to_character_trigger = { - GIVER = scope:actor + GIVER = scope:puppet_or_actor CHARACTER = scope:recipient } } @@ -2925,13 +3019,24 @@ offer_concubine = { } } - is_shown = { - scope:actor != scope:recipient - scope:actor = { - allowed_more_concubines = yes + is_available = { + trigger_if = { + limit = { is_ai = yes } + allowed_concubines = yes + NOR = { + has_trait = greedy + ai_greed > very_high_positive_ai_value + } + is_adult = yes + is_at_war = no + is_incapable = no } + } + + is_shown = { + scope:puppet_or_actor != scope:recipient scope:recipient = { - #NOT = { government_has_flag = government_is_true_herder } + NOT = { government_has_flag = government_is_herder } allowed_concubines = yes is_adult = yes } @@ -2941,17 +3046,17 @@ offer_concubine = { custom_description = { text = take_concubine_available_character_opp object = scope:recipient - scope:actor = { + scope:puppet_or_actor = { OR = { any_courtier = { can_be_offered_as_concubine_to_character_trigger = { - GIVER = scope:actor + GIVER = scope:puppet_or_actor CHARACTER = scope:recipient } } any_prisoner = { can_be_offered_as_concubine_to_character_trigger = { - GIVER = scope:actor + GIVER = scope:puppet_or_actor CHARACTER = scope:recipient } } @@ -2968,13 +3073,13 @@ offer_concubine = { trigger_if = { #Landless adventurers check range limit = { - scope:actor = { + scope:puppet_or_actor = { is_landless_adventurer = yes } } ep3_laamp_diplo_range_trigger = { TARGET = scope:recipient - LAAMP = scope:actor + LAAMP = scope:puppet_or_actor } } } @@ -2989,7 +3094,7 @@ offer_concubine = { object = scope:secondary_recipient scope:secondary_recipient = { can_be_offered_as_concubine_to_character_trigger = { - GIVER = scope:actor + GIVER = scope:puppet_or_actor CHARACTER = scope:recipient } } @@ -3071,7 +3176,7 @@ offer_concubine = { opinion_modifier = { # Opinion of you who = scope:recipient - opinion_target = scope:actor + opinion_target = scope:puppet_or_actor multiplier = 1.0 desc = AI_OPINION_REASON } @@ -3141,10 +3246,10 @@ offer_concubine = { modifier = { # A Recipient is more likely to agree if you're their liege add = 40 - scope:actor = { is_landed = yes } + scope:puppet_or_actor = { is_landed = yes } scope:recipient = { is_landed = yes - target_is_liege_or_above = scope:actor + target_is_liege_or_above = scope:puppet_or_actor } desc = LIEGE_REASON } @@ -3152,7 +3257,7 @@ offer_concubine = { #More/Less likely based on difference in rank between actor and recipient modifier = { add = 20 - scope:actor = { + scope:puppet_or_actor = { tier_difference = { target = scope:recipient value = 1 @@ -3162,7 +3267,7 @@ offer_concubine = { } modifier = { add = 30 - scope:actor = { + scope:puppet_or_actor = { tier_difference = { target = scope:recipient value = 2 @@ -3172,7 +3277,7 @@ offer_concubine = { } modifier = { add = 40 - scope:actor = { + scope:puppet_or_actor = { tier_difference = { target = scope:recipient value = 3 @@ -3182,7 +3287,7 @@ offer_concubine = { } modifier = { add = 50 - scope:actor = { + scope:puppet_or_actor = { tier_difference = { target = scope:recipient value = 4 @@ -3192,7 +3297,7 @@ offer_concubine = { } modifier = { add = 60 - scope:actor = { + scope:puppet_or_actor = { tier_difference = { target = scope:recipient value = 5 @@ -3202,7 +3307,7 @@ offer_concubine = { } modifier = { add = -20 - scope:actor = { + scope:puppet_or_actor = { tier_difference = { target = scope:recipient value = -1 @@ -3212,7 +3317,7 @@ offer_concubine = { } modifier = { add = -30 - scope:actor = { + scope:puppet_or_actor = { tier_difference = { target = scope:recipient value = -2 @@ -3222,7 +3327,7 @@ offer_concubine = { } modifier = { add = -40 - scope:actor = { + scope:puppet_or_actor = { tier_difference = { target = scope:recipient value = -3 @@ -3232,7 +3337,7 @@ offer_concubine = { } modifier = { add = -50 - scope:actor = { + scope:puppet_or_actor = { tier_difference = { target = scope:recipient value = -4 @@ -3242,7 +3347,7 @@ offer_concubine = { } modifier = { add = -60 - scope:actor = { + scope:puppet_or_actor = { tier_difference = { target = scope:recipient value = -5 @@ -3254,9 +3359,9 @@ offer_concubine = { modifier = { add = intimidated_reason_value scope:recipient = { - target_is_liege_or_above = scope:actor + target_is_liege_or_above = scope:puppet_or_actor has_dread_level_towards = { - target = scope:actor + target = scope:puppet_or_actor level = 1 } } @@ -3265,9 +3370,9 @@ offer_concubine = { modifier = { add = cowed_reason_value scope:recipient = { - target_is_liege_or_above = scope:actor + target_is_liege_or_above = scope:puppet_or_actor has_dread_level_towards = { - target = scope:actor + target = scope:puppet_or_actor level = 2 } } @@ -3277,9 +3382,9 @@ offer_concubine = { modifier = { add = intimidated_external_reason_value scope:recipient = { - NOT = { target_is_liege_or_above = scope:actor } + NOT = { target_is_liege_or_above = scope:puppet_or_actor } has_dread_level_towards = { - target = scope:actor + target = scope:puppet_or_actor level = 1 } } @@ -3288,9 +3393,9 @@ offer_concubine = { modifier = { add = cowed_external_reason_value scope:recipient = { - NOT = { target_is_liege_or_above = scope:actor } + NOT = { target_is_liege_or_above = scope:puppet_or_actor } has_dread_level_towards = { - target = scope:actor + target = scope:puppet_or_actor level = 2 } } @@ -3320,13 +3425,13 @@ offer_concubine = { modifier = { scope:hook = yes add = 500 - scope:actor = { NOT = { has_strong_hook = scope:recipient } } + scope:puppet_or_actor = { NOT = { has_strong_hook = scope:recipient } } desc = SCHEME_WEAK_HOOK_USED } modifier = { scope:hook = yes add = 1000 - scope:actor = { has_strong_hook = scope:recipient } + scope:puppet_or_actor = { has_strong_hook = scope:recipient } desc = SCHEME_STRONG_HOOK_USED } @@ -3336,17 +3441,6 @@ offer_concubine = { } } - ai_potential = { - is_adult = yes - NOT = { has_trait = incapable } - is_at_war = no - NOR = { - has_trait = greedy - ai_greed > very_high_positive_ai_value - } - allowed_concubines = yes - } - ai_will_do = { base = 0 @@ -3470,7 +3564,7 @@ offer_concubine = { modifier = { # Incest Filtering: Hard NO! factor = 0 scope:recipient = { - relation_with_character_is_incestuous_in_my_faith_trigger = { CHARACTER = scope:secondary_recipient } + relation_with_character_is_incestuous_in_my_rite_trigger = { CHARACTER = scope:secondary_recipient } NOR = { accepts_incest_with_trigger = { CHARACTER = scope:secondary_recipient } sexually_liberal_trigger = yes @@ -3481,7 +3575,7 @@ offer_concubine = { modifier = { # Incest Filtering: Not likely, but keep the door open... factor = 0.2 scope:recipient = { - relation_with_character_is_incestuous_in_my_faith_trigger = { CHARACTER = scope:secondary_recipient } + relation_with_character_is_incestuous_in_my_rite_trigger = { CHARACTER = scope:secondary_recipient } OR = { accepts_incest_with_trigger = { CHARACTER = scope:secondary_recipient } sexually_liberal_trigger = yes @@ -3520,7 +3614,7 @@ offer_concubine = { # If we're a clan this interaction affects unity add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = minor_unity_gain DESC = clan_unity_concubinage_offer.desc @@ -3529,7 +3623,7 @@ offer_concubine = { } on_decline = { - scope:actor = { + scope:puppet_or_actor = { send_interface_toast = { type = event_toast_effect_bad title = msg_concubine_offer_rejected_title @@ -3541,7 +3635,7 @@ offer_concubine = { # If we're a clan this interaction affects unity add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = medium_unity_loss DESC = clan_unity_concubinage_offer_decline.desc @@ -3552,7 +3646,7 @@ offer_concubine = { send_options_exclusive = no send_option = { is_valid = { - scope:actor = { + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } @@ -3560,7 +3654,7 @@ offer_concubine = { localization = SCHEME_HOOK } should_use_extra_icon = { - scope:actor = { has_usable_hook = scope:recipient } + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } extra_icon = "gfx/interface/icons/character_interactions/hook_icon.dds" } @@ -3572,13 +3666,13 @@ dismiss_concubine_interaction = { is_shown = { scope:recipient = { - is_concubine_of = scope:actor + is_concubine_of = scope:puppet_or_actor } } is_valid_showing_failures_only = { - scope:recipient = { NOT = { has_strong_hook = scope:actor } } - scope:actor = { + scope:recipient = { NOT = { has_strong_hook = scope:puppet_or_actor } } + scope:puppet_or_actor = { custom_tooltip = { NOT = { var:family_widow_forbidden_divorce ?= scope:recipient @@ -3591,8 +3685,8 @@ dismiss_concubine_interaction = { auto_accept = yes on_accept = { - scope:actor = { - stress_impact = { + scope:puppet_or_actor = { + stress_and_fulfillment_impact = { compassionate = minor_stress_impact_gain } hidden_effect = { @@ -3612,12 +3706,12 @@ dismiss_concubine_interaction = { # Being thrown aside is humiliating, even if you didn't want to be a concubine in the first place. add_opinion = { modifier = set_me_aside_opinion - target = scope:actor + target = scope:puppet_or_actor } if = { - limit = { scope:actor = { has_relation_lover = scope:recipient } } + limit = { scope:puppet_or_actor = { has_relation_lover = scope:recipient } } lover_breakup_effect = { - BREAKER = scope:actor + BREAKER = scope:puppet_or_actor LOVER = scope:recipient } } @@ -3625,27 +3719,27 @@ dismiss_concubine_interaction = { # Figure out where we should go now that we're no longer a concubine. if = { limit = { - is_councillor_of = scope:actor + is_councillor_of = scope:puppet_or_actor } # Then they should remain in court } else_if = { #Dismiss to relevant court, or to pool limit = { any_close_family_member = { - is_landed_or_landless_administrative = yes + is_landed_or_landless_administrative_or_theocratic = yes } } random_close_family_member = { limit = { is_child_of = scope:recipient - is_landed_or_landless_administrative = yes + is_landed_or_landless_administrative_or_theocratic = yes } alternative_limit = { is_parent_of = scope:recipient - is_landed_or_landless_administrative = yes + is_landed_or_landless_administrative_or_theocratic = yes } alternative_limit = { - is_landed_or_landless_administrative = yes + is_landed_or_landless_administrative_or_theocratic = yes } add_courtier = scope:recipient } @@ -3657,7 +3751,7 @@ dismiss_concubine_interaction = { # If we're a clan this interaction affects unity add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = medium_unity_loss DESC = clan_unity_concubinage_dismissal.desc @@ -3672,51 +3766,104 @@ divorce_character_interaction = { icon = icon_marriage desc = divorce_character_interaction_desc - cost = { piety = divorce_cost } - - is_shown = { - scope:actor.faith = { - # We are not required to seek approval of a spiritual HoF - NAND = { - has_doctrine = doctrine_divorce_approval - has_doctrine = doctrine_spiritual_head - exists = religious_head - } - # We are not required to seek approval of a house head - NAND = { - has_doctrine = doctrine_divorce_approval - exists = scope:actor.house - exists = scope:actor.house.house_head - scope:actor = { is_house_head = no } + cost = { + piety = { + value = divorce_cost + if = { + limit = { scope:is_puppet_action ?= yes } + multiply = 0 } } + } + + is_shown = { + # A clerical ruler holds that religious authority themselves, so no approval is sought + trigger_if = { + limit = { + scope:puppet_or_actor ?= { pam_grants_own_divorce_trigger = no } + } + # We are not required to seek approval of a spiritual HoF + NAND = { + scope:puppet_or_actor.rite ?= { rite_has_doctrine = doctrine_divorce_approval } + scope:puppet_or_actor.faith ?= { + has_doctrine = doctrine_spiritual_head + exists = religious_head + } + } + } + # We are not required to seek approval of a house head + NAND = { + scope:puppet_or_actor.rite ?= { rite_has_doctrine = doctrine_divorce_approval } + exists = scope:puppet_or_actor.house + exists = scope:puppet_or_actor.house.house_head + scope:puppet_or_actor = { is_house_head = no } + } + exists = scope:puppet_or_actor scope:recipient = { - is_spouse_of = scope:actor + is_spouse_of = scope:puppet_or_actor is_concubine = no # Can set aside Concubines at any time } } is_valid_showing_failures_only = { - custom_tooltip = { - NOT = { - scope:actor.culture = { - has_cultural_parameter = cannot_divorce - } - } - text = CULTURE_FORBIDS_DIVORCE - } - NOT = { - scope:actor.faith = { - has_doctrine = doctrine_divorce_disallowed - } - } - scope:recipient = { NOT = { has_strong_hook = scope:actor } } - scope:actor = { + trigger_if = { + limit = { scope:actor = scope:puppet_or_actor } custom_tooltip = { NOT = { - var:family_widow_forbidden_divorce ?= scope:recipient + scope:puppet_or_actor.culture = { + has_cultural_parameter = cannot_divorce + } } - text = BOUND_TO_FAMILY_WIDOW + text = CULTURE_FORBIDS_DIVORCE + } + } + trigger_else = { + custom_tooltip = { + NOT = { + scope:puppet_or_actor.culture = { + has_cultural_parameter = cannot_divorce + } + } + text = CULTURE_FORBIDS_DIVORCE_puppeteer + } + } + OR = { + NOT = { + scope:puppet_or_actor.rite = { + rite_has_doctrine = doctrine_divorce_disallowed + } + } + AND = { + scope:puppet_or_actor.rite = { + rite_has_parameter = tenet_be_fruitful_and_multiply_low_fertility_divorce + } + scope:recipient = { fertility < 0.1 } + } + } + scope:recipient = { NOT = { has_strong_hook = scope:puppet_or_actor } } + scope:puppet_or_actor = { + trigger_if = { + limit = { scope:actor = scope:puppet_or_actor } + custom_tooltip = { + NOT = { + var:family_widow_forbidden_divorce ?= scope:recipient + } + text = BOUND_TO_FAMILY_WIDOW + } + } + trigger_else = { + custom_tooltip = { + NOT = { + var:family_widow_forbidden_divorce ?= scope:recipient + } + text = BOUND_TO_FAMILY_WIDOW_puppeteer + } + } + } + trigger_if = { + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + piety >= divorce_cost } } } @@ -3724,16 +3871,28 @@ divorce_character_interaction = { auto_accept = yes on_accept = { - scope:actor = { + if = { + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + add_piety = { value = { add = divorce_cost max = piety multiply = -1 } } + } + } + scope:puppet_or_actor = { divorce_effect = { - DIVORCER = scope:actor + DIVORCER = scope:puppet_or_actor DIVORCEE = scope:recipient } if = { limit = { allowed_concubines = yes } - custom_tooltip = divorce_cannot_concubine_ex_wife + if = { + limit = { scope:actor = scope:puppet_or_actor } + custom_tooltip = divorce_cannot_concubine_ex_wife + } + else = { + custom_tooltip = divorce_cannot_concubine_ex_wife_puppeteer + } } } scope:recipient = { @@ -3742,7 +3901,7 @@ divorce_character_interaction = { # If we're a clan this interaction affects unity add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = major_unity_loss DESC = clan_unity_divorce.desc @@ -3763,20 +3922,16 @@ divorce_character_interaction = { hegemony = 36 } - ai_potential = { - is_ruler = yes - } - ai_will_do = { base = 0 modifier = { # The AI wants to divorce should they not have an heir that is their own child, and their spouse is infertile add = 100 - scope:actor = { + scope:puppet_or_actor = { fertility > 0.1 NOT = { any_child = { - is_heir_of = scope:actor + is_heir_of = scope:puppet_or_actor } } } @@ -3788,7 +3943,7 @@ divorce_character_interaction = { modifier = { # The AI will divorce if they're in a same-sex marriage and their faith changes its stance on the topic add = 100 - scope:actor = { + scope:puppet_or_actor = { sex_same_as = scope:recipient allowed_to_marry_same_sex_trigger = no } @@ -3802,7 +3957,13 @@ divorce_character_house_head_interaction = { icon = icon_marriage cost = { - piety = divorce_cost + piety = { + value = divorce_cost + if = { + limit = { scope:is_puppet_action ?= yes } + multiply = 0 + } + } } redirect = { @@ -3811,9 +3972,9 @@ divorce_character_house_head_interaction = { } if = { limit = { - exists = scope:actor.house.house_head + exists = scope:puppet_or_actor.house.house_head } - scope:actor.house.house_head = { + scope:puppet_or_actor.house.house_head = { save_scope_as = recipient } } @@ -3823,41 +3984,77 @@ divorce_character_house_head_interaction = { notification_text = ASK_FOR_DIVORCE_NOTIFICATION is_shown = { - exists = scope:actor.house.house_head - scope:actor != scope:actor.house.house_head # no need to ask yourself - scope:actor.faith = { - has_doctrine = doctrine_divorce_approval + scope:puppet_or_actor.rite ?= { + rite_has_doctrine = doctrine_divorce_approval } - NAND = { - exists = scope:actor.faith.religious_head - scope:actor.faith = { - has_doctrine = doctrine_spiritual_head + exists = scope:puppet_or_actor.house.house_head + scope:puppet_or_actor != scope:puppet_or_actor.house.house_head # no need to ask yourself + # A clerical ruler needs no religious blessing, so their house head is the only approval left to seek + trigger_if = { + limit = { + scope:puppet_or_actor ?= { pam_grants_own_divorce_trigger = no } + } + NAND = { + exists = scope:puppet_or_actor.faith.religious_head + scope:puppet_or_actor.faith = { + has_doctrine = doctrine_spiritual_head + } } } - scope:secondary_recipient = { - is_spouse_of = scope:actor + scope:secondary_recipient ?= { + is_spouse_of = scope:puppet_or_actor is_concubine = no # Can set aside Concubines at any time } } is_valid_showing_failures_only = { - custom_tooltip = { - NOT = { - scope:actor.culture = { - has_cultural_parameter = cannot_divorce - } - } - text = CULTURE_FORBIDS_DIVORCE - } - NOT = { - scope:secondary_recipient = { has_strong_hook = scope:actor } - } - scope:actor = { + trigger_if = { + limit = { scope:actor = scope:puppet_or_actor } custom_tooltip = { NOT = { - var:family_widow_forbidden_divorce ?= scope:recipient + scope:puppet_or_actor.culture = { + has_cultural_parameter = cannot_divorce + } } - text = BOUND_TO_FAMILY_WIDOW + text = CULTURE_FORBIDS_DIVORCE + } + } + trigger_else = { + custom_tooltip = { + NOT = { + scope:puppet_or_actor.culture = { + has_cultural_parameter = cannot_divorce + } + } + text = CULTURE_FORBIDS_DIVORCE_puppeteer + } + } + NOT = { + scope:secondary_recipient = { has_strong_hook = scope:puppet_or_actor } + } + scope:puppet_or_actor = { + trigger_if = { + limit = { scope:actor = scope:puppet_or_actor } + custom_tooltip = { + NOT = { + var:family_widow_forbidden_divorce ?= scope:secondary_recipient + } + text = BOUND_TO_FAMILY_WIDOW + } + } + trigger_else = { + custom_tooltip = { + NOT = { + var:family_widow_forbidden_divorce ?= scope:secondary_recipient + } + text = BOUND_TO_FAMILY_WIDOW_puppeteer + } + } + } + trigger_if = { + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + piety >= divorce_cost } } } @@ -3870,7 +4067,7 @@ divorce_character_house_head_interaction = { modifier = { # Infertility add = 20 desc = DIVORCE_INFERTILE - scope:actor = { + scope:puppet_or_actor = { fertility > 0.1 } scope:secondary_recipient = { @@ -3878,7 +4075,7 @@ divorce_character_house_head_interaction = { is_eunuch_trigger = no NOT = { any_child = { - is_child_of = scope:actor + is_child_of = scope:puppet_or_actor } } } @@ -3890,8 +4087,8 @@ divorce_character_house_head_interaction = { scope:secondary_recipient = { any_child = { count >= 3 - is_child_of = scope:actor - dynasty ?= scope:actor.dynasty + is_child_of = scope:puppet_or_actor + dynasty ?= scope:puppet_or_actor.dynasty } } @@ -3911,12 +4108,12 @@ divorce_character_house_head_interaction = { dynasty = scope:secondary_recipient.dynasty NOR = { house = scope:secondary_recipient.house - is_close_or_extended_family_of = scope:actor - is_cousin_of = scope:actor - is_child_of = scope:actor + is_close_or_extended_family_of = scope:puppet_or_actor + is_cousin_of = scope:puppet_or_actor + is_child_of = scope:puppet_or_actor AND = { - exists = scope:actor.dynasty - scope:recipient.dynasty = scope:actor.dynasty + exists = scope:puppet_or_actor.dynasty + scope:recipient.dynasty = scope:puppet_or_actor.dynasty } } } @@ -3934,11 +4131,11 @@ divorce_character_house_head_interaction = { } house = scope:secondary_recipient.house NOR = { - house = scope:actor.house - is_close_or_extended_family_of = scope:actor - is_cousin_of = scope:actor - is_child_of = scope:actor - scope:recipient.house = scope:actor.house + house = scope:puppet_or_actor.house + is_close_or_extended_family_of = scope:puppet_or_actor + is_cousin_of = scope:puppet_or_actor + is_child_of = scope:puppet_or_actor + scope:recipient.house = scope:puppet_or_actor.house } } } @@ -3958,9 +4155,9 @@ divorce_character_house_head_interaction = { modifier = { add = intimidated_reason_value scope:recipient = { - target_is_liege_or_above = scope:actor + target_is_liege_or_above = scope:puppet_or_actor has_dread_level_towards = { - target = scope:actor + target = scope:puppet_or_actor level = 1 } } @@ -3969,9 +4166,9 @@ divorce_character_house_head_interaction = { modifier = { add = cowed_reason_value scope:recipient = { - target_is_liege_or_above = scope:actor + target_is_liege_or_above = scope:puppet_or_actor has_dread_level_towards = { - target = scope:actor + target = scope:puppet_or_actor level = 2 } } @@ -3981,9 +4178,9 @@ divorce_character_house_head_interaction = { modifier = { add = intimidated_external_reason_value scope:recipient = { - NOT = { target_is_liege_or_above = scope:actor } + NOT = { target_is_liege_or_above = scope:puppet_or_actor } has_dread_level_towards = { - target = scope:actor + target = scope:puppet_or_actor level = 1 } } @@ -3992,9 +4189,9 @@ divorce_character_house_head_interaction = { modifier = { add = cowed_external_reason_value scope:recipient = { - NOT = { target_is_liege_or_above = scope:actor } + NOT = { target_is_liege_or_above = scope:puppet_or_actor } has_dread_level_towards = { - target = scope:actor + target = scope:puppet_or_actor level = 2 } } @@ -4004,8 +4201,8 @@ divorce_character_house_head_interaction = { modifier = { # You're in a same-sex marriage and your faith doesn't allow it add = 100 desc = SAME_SEX_MARRIAGE_FAITH_REASON_ACTOR - scope:actor.faith = scope:recipient.faith - scope:actor = { + scope:puppet_or_actor.faith = scope:recipient.faith + scope:puppet_or_actor = { sex_same_as = scope:secondary_recipient allowed_to_marry_same_sex_trigger = no } @@ -4016,7 +4213,7 @@ divorce_character_house_head_interaction = { desc = SAME_SEX_MARRIAGE_FAITH_REASON scope:secondary_recipient.faith = scope:recipient.faith scope:secondary_recipient = { - sex_same_as = scope:actor + sex_same_as = scope:puppet_or_actor allowed_to_marry_same_sex_trigger = no } } @@ -4030,7 +4227,7 @@ divorce_character_house_head_interaction = { auto_accept = { custom_description = { text = "spending_hook" - subject = scope:actor + subject = scope:puppet_or_actor object = scope:recipient scope:divorce_hook = yes } @@ -4038,10 +4235,10 @@ divorce_character_house_head_interaction = { send_option = { is_shown = { - scope:actor != scope:recipient + scope:puppet_or_actor != scope:recipient } is_valid = { - scope:actor = { + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } @@ -4049,7 +4246,7 @@ divorce_character_house_head_interaction = { localization = GENERIC_SPEND_A_HOOK } should_use_extra_icon = { - scope:actor = { has_usable_hook = scope:recipient } + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } extra_icon = "gfx/interface/icons/character_interactions/hook_icon.dds" @@ -4061,7 +4258,7 @@ divorce_character_house_head_interaction = { on_accept = { if = { limit = { always = scope:divorce_hook } - scope:actor = { + scope:puppet_or_actor = { if = { limit = { has_usable_hook = scope:recipient @@ -4071,33 +4268,47 @@ divorce_character_house_head_interaction = { } } if = { - limit = { - scope:actor = scope:actor.house.house_head + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + add_piety = { value = { add = divorce_cost max = piety multiply = -1 } } } scope:actor = { + send_interface_toast = { + type = event_toast_effect_neutral + title = divorce_interaction_notification_puppeteer + left_icon = scope:puppet_or_actor + right_icon = scope:secondary_recipient + } + } + } + if = { + limit = { + scope:puppet_or_actor = scope:puppet_or_actor.house.house_head + } + scope:puppet_or_actor = { divorce_effect = { - DIVORCER = scope:actor + DIVORCER = scope:puppet_or_actor DIVORCEE = scope:secondary_recipient } } } else = { show_as_tooltip = { - scope:actor = { + scope:puppet_or_actor = { divorce_effect = { - DIVORCER = scope:actor + DIVORCER = scope:puppet_or_actor DIVORCEE = scope:secondary_recipient } } } - scope:actor = { + scope:puppet_or_actor = { trigger_event = religious_interaction.2 } } # If we're a clan this interaction affects unity add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = major_unity_loss DESC = clan_unity_divorce_grant.desc @@ -4106,17 +4317,17 @@ divorce_character_house_head_interaction = { } on_decline = { - scope:actor = { + scope:puppet_or_actor = { send_interface_toast = { type = event_toast_effect_bad title = divorce_character_rel_head_interaction_decline_notification - right_icon = scope:actor.house.house_head + right_icon = scope:puppet_or_actor.house.house_head } } # If we're a clan this interaction affects unity add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = minor_unity_loss DESC = clan_unity_divorce_grant_refusal.desc @@ -4137,20 +4348,16 @@ divorce_character_house_head_interaction = { hegemony = 36 } - ai_potential = { - is_ruler = yes - } - ai_will_do = { base = 0 modifier = { # The AI wants to divorce should they not have an heir that is their own child, and their spouse is infertile add = 100 - scope:actor = { + scope:puppet_or_actor = { fertility > 0.1 NOT = { any_child = { - is_heir_of = scope:actor + is_heir_of = scope:puppet_or_actor } } } @@ -4167,7 +4374,7 @@ divorce_character_house_head_interaction = { modifier = { # You're in a same-sex marriage and your faith doesn't allow it add = 100 - scope:actor = { + scope:puppet_or_actor = { sex_same_as = scope:secondary_recipient allowed_to_marry_same_sex_trigger = no } @@ -4181,60 +4388,314 @@ divorce_character_rel_head_interaction = { icon = icon_marriage cost = { - piety = divorce_cost + piety = { + value = divorce_cost + if = { + limit = { scope:is_puppet_action ?= yes } + multiply = 0 + } + } } redirect = { scope:recipient = { save_scope_as = secondary_recipient - } - + } + #Recipient should be cleric or hof if = { limit = { - exists = scope:actor.faith.religious_head + scope:puppet_or_actor = { + government_has_flag = government_is_theocracy + exists = superior + } } - scope:actor.faith.religious_head = { + scope:puppet_or_actor.superior = { save_scope_as = recipient } + } + #Redirect to bishop superior of court chaplain + else_if = { + limit = { + OR = { + scope:puppet_or_actor.highest_held_title_tier < tier_kingdom + scope:puppet_or_actor.faith = { + NOR = { + has_doctrine = doctrine_spiritual_head + exists = scope:faith.religious_head + } + } + } + scope:puppet_or_actor.cp:councillor_court_chaplain ?= { + highest_held_title_tier < tier_duchy + superior ?= { + highest_held_title_tier >= tier_duchy + is_clergy = yes + } + } + } + scope:puppet_or_actor.cp:councillor_court_chaplain.superior = { + save_scope_as = recipient + } + } + #Redirect to bishop + else_if = { + limit = { + OR = { + scope:puppet_or_actor.highest_held_title_tier < tier_kingdom + scope:puppet_or_actor.faith = { + NOR = { + has_doctrine = doctrine_spiritual_head + exists = scope:faith.religious_head + } + } + } + scope:puppet_or_actor.cp:councillor_court_chaplain ?= { + highest_held_title_tier >= tier_duchy + is_clergy = yes + } + } + scope:puppet_or_actor.cp:councillor_court_chaplain = { + save_scope_as = recipient + } + } + else = { + scope:puppet_or_actor.faith.religious_head ?= { save_scope_as = recipient } } } greeting = positive - notification_text = ASK_FOR_DIVORCE_NOTIFICATION + notification_text = { + desc = ASK_FOR_DIVORCE_NOTIFICATION + first_valid = { + triggered_desc = { + trigger = { + scope:puppet_or_actor = { + faith = scope:recipient.faith + sex_same_as = scope:secondary_recipient + allowed_to_marry_same_sex_trigger = no + } + } + desc = ASK_FOR_DIVORCE_NOTIFICATION_SAME_SEX + } + triggered_desc = { + trigger = { + scope:puppet_or_actor = { + relation_with_character_is_incestuous_in_my_faith_trigger = { CHARACTER = scope:secondary_recipient } + } + } + desc = ASK_FOR_DIVORCE_NOTIFICATION_INCESTUOUS + } + triggered_desc = { + trigger = { + scope:secondary_recipient = { + any_relation = { + type = lover + NOR = { + this = scope:puppet_or_actor + this = scope:recipient + } + relation_with_character_is_incestuous_in_my_rite_trigger = { CHARACTER = scope:secondary_recipient } + } + } + } + desc = ASK_FOR_DIVORCE_NOTIFICATION_INCESTUOUS_LOVER + } + triggered_desc = { + trigger = { + scope:secondary_recipient = { + is_female = no + is_eunuch_trigger = yes + } + } + desc = ASK_FOR_DIVORCE_NOTIFICATION_EUNUCH + } + triggered_desc = { + trigger = { + scope:puppet_or_actor = { + has_opinion_modifier = { + modifier = attempted_murder_me_crime + target = scope:secondary_recipient + } + } + } + desc = ASK_FOR_DIVORCE_NOTIFICATION_ATTEMPTED_MURDER + } + triggered_desc = { + trigger = { + scope:secondary_recipient = { + has_character_modifier = wedding_accused_impotency_modifier + } + } + desc = ASK_FOR_DIVORCE_NOTIFICATION_IMPOTENCE + } + triggered_desc = { + trigger = { + scope:puppet_or_actor = { + any_consort = { + is_alive = yes + this != scope:secondary_recipient + } + any_consort = { + this = scope:secondary_recipient + } + } + scope:secondary_recipient = { + culture = { NOT = { has_cultural_tradition = tradition_polygamous } } + rite = { NOT = { rite_has_doctrine = doctrine_polygamy } } + } + } + desc = ASK_FOR_DIVORCE_NOTIFICATION_MULTIPLE_CONSORTS + } + triggered_desc = { + trigger = { + scope:secondary_recipient.faith = { + faith_hostility_level = { + target = scope:recipient.faith + value >= faith_hostile_level + } + } + } + desc = ASK_FOR_DIVORCE_NOTIFICATION_HOSTILE_FAITH + } + triggered_desc = { + trigger = { + scope:secondary_recipient = { + exposed_cheating_on_spouse_trigger = { SPOUSE = scope:puppet_or_actor } + } + } + desc = ASK_FOR_DIVORCE_NOTIFICATION_EXPOSED_CHEATING + } + triggered_desc = { + trigger = { + scope:secondary_recipient = { + fertility < 0.1 + NOT = { + any_child = { + any_parent = { + this = scope:puppet_or_actor + } + } + } + } + } + desc = ASK_FOR_DIVORCE_NOTIFICATION_INFERTILITY + } + triggered_desc = { + trigger = { + scope:secondary_recipient = { + has_trait = adulterer + } + } + desc = ASK_FOR_DIVORCE_NOTIFICATION_ADULTERY_TRAIT + } + triggered_desc = { + trigger = { + scope:puppet_or_actor = { + opinion = { + target = scope:secondary_recipient + value < -50 + } + } + } + desc = ASK_FOR_DIVORCE_NOTIFICATION_HATRED + } + desc = ASK_FOR_DIVORCE_NOTIFICATION_NOT_JUSTIFIED + } + } + + is_available = { + trigger_if = { + limit = { is_ai = yes } + NOT = { has_character_modifier = rekindled_marriage_modifier } + } + } is_shown = { - exists = scope:actor.faith.religious_head - scope:actor.faith = { - has_doctrine = doctrine_spiritual_head - has_doctrine = doctrine_divorce_approval + scope:puppet_or_actor.rite ?= { rite_has_doctrine = doctrine_divorce_approval } + # A clerical ruler grants their own divorce and never petitions for one, least of all themselves + scope:puppet_or_actor ?= { pam_grants_own_divorce_trigger = no } + scope:puppet_or_actor ?= { + OR = { + faith ?= { + has_doctrine = doctrine_spiritual_head + exists = religious_head + } + cp:councillor_court_chaplain ?= { + highest_held_title_tier >= tier_duchy + is_clergy = yes + } + AND = { + government_has_flag = government_is_theocracy + exists = superior + } + cp:councillor_court_chaplain.superior ?= { + highest_held_title_tier >= tier_duchy + is_clergy = yes + } + } } - scope:secondary_recipient = { - is_spouse_of = scope:actor + scope:secondary_recipient ?= { + is_spouse_of = scope:puppet_or_actor is_concubine = no # Can set aside Concubines at any time } } is_valid_showing_failures_only = { - scope:actor = { + scope:puppet_or_actor = { NOT = { has_trait = excommunicated } } - custom_tooltip = { - NOT = { - scope:actor.culture = { - has_cultural_parameter = cannot_divorce - } - } - text = CULTURE_FORBIDS_DIVORCE - } - NOT = { - scope:secondary_recipient = { has_strong_hook = scope:actor } - } - scope:actor = { + trigger_if = { + limit = { scope:actor = scope:puppet_or_actor } custom_tooltip = { NOT = { - var:family_widow_forbidden_divorce ?= scope:recipient + scope:puppet_or_actor.culture = { + has_cultural_parameter = cannot_divorce + } } - text = BOUND_TO_FAMILY_WIDOW + text = CULTURE_FORBIDS_DIVORCE + } + } + trigger_else = { + custom_tooltip = { + NOT = { + scope:puppet_or_actor.culture = { + has_cultural_parameter = cannot_divorce + } + } + text = CULTURE_FORBIDS_DIVORCE_puppeteer + } + } + NOT = { + scope:secondary_recipient = { has_strong_hook = scope:puppet_or_actor } + } + scope:puppet_or_actor = { + trigger_if = { + limit = { scope:actor = scope:puppet_or_actor } + custom_tooltip = { + NOT = { + var:family_widow_forbidden_divorce ?= scope:secondary_recipient + } + text = BOUND_TO_FAMILY_WIDOW + } + } + trigger_else = { + custom_tooltip = { + NOT = { + var:family_widow_forbidden_divorce ?= scope:secondary_recipient + } + text = BOUND_TO_FAMILY_WIDOW_puppeteer + } + } + } + scope:puppet_or_actor = { + NOT = { + has_character_modifier = promised_pilgrimage_to_clergy_modifier + } + } + trigger_if = { + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + piety >= divorce_cost } } } @@ -4248,9 +4709,9 @@ divorce_character_rel_head_interaction = { add = -100 desc = DIVORCE_INCESTUOUS - scope:actor = { + scope:puppet_or_actor = { is_close_or_extended_family_of = scope:secondary_recipient - faith = { has_doctrine = tenet_divine_marriage } + rite = { rite_has_tenet = tenet_divine_marriage } } } @@ -4258,7 +4719,7 @@ divorce_character_rel_head_interaction = { add = 100 desc = DIVORCE_INCESTUOUS - scope:actor = { + scope:puppet_or_actor = { relation_with_character_is_incestuous_in_my_faith_trigger = { CHARACTER = scope:secondary_recipient } } } @@ -4273,10 +4734,10 @@ divorce_character_rel_head_interaction = { dynasty = scope:secondary_recipient.dynasty NOR = { house = scope:secondary_recipient.house - is_close_or_extended_family_of = scope:actor - is_cousin_of = scope:actor - is_child_of = scope:actor - scope:recipient.dynasty = scope:actor.dynasty + is_close_or_extended_family_of = scope:puppet_or_actor + is_cousin_of = scope:puppet_or_actor + is_child_of = scope:puppet_or_actor + scope:recipient.dynasty = scope:puppet_or_actor.dynasty } } } @@ -4287,12 +4748,12 @@ divorce_character_rel_head_interaction = { scope:recipient = { is_lowborn = no exists = dynasty - exists = scope:actor.dynasty - dynasty = scope:actor.dynasty + exists = scope:puppet_or_actor.dynasty + dynasty = scope:puppet_or_actor.dynasty NOR = { - is_close_or_extended_family_of = scope:actor - is_cousin_of = scope:actor - is_child_of = scope:actor + is_close_or_extended_family_of = scope:puppet_or_actor + is_cousin_of = scope:puppet_or_actor + is_child_of = scope:puppet_or_actor scope:recipient.dynasty = scope:secondary_recipient.dynasty } } @@ -4307,11 +4768,11 @@ divorce_character_rel_head_interaction = { exists = scope:secondary_recipient.house house = scope:secondary_recipient.house NOR = { - house = scope:actor.house - is_close_or_extended_family_of = scope:actor - is_cousin_of = scope:actor - is_child_of = scope:actor - scope:recipient.house = scope:actor.house + house = scope:puppet_or_actor.house + is_close_or_extended_family_of = scope:puppet_or_actor + is_cousin_of = scope:puppet_or_actor + is_child_of = scope:puppet_or_actor + scope:recipient.house = scope:puppet_or_actor.house } } } @@ -4322,12 +4783,12 @@ divorce_character_rel_head_interaction = { scope:recipient = { is_lowborn = no exists = house - exists = scope:actor.house - house = scope:actor.house + exists = scope:puppet_or_actor.house + house = scope:puppet_or_actor.house NOR = { - is_close_or_extended_family_of = scope:actor - is_cousin_of = scope:actor - is_child_of = scope:actor + is_close_or_extended_family_of = scope:puppet_or_actor + is_cousin_of = scope:puppet_or_actor + is_child_of = scope:puppet_or_actor scope:recipient.house = scope:secondary_recipient.house } } @@ -4338,10 +4799,10 @@ divorce_character_rel_head_interaction = { desc = YOU_ARE_MY_RELATIVE scope:recipient = { OR = { - is_close_or_extended_family_of = scope:actor - is_cousin_of = scope:actor + is_close_or_extended_family_of = scope:puppet_or_actor + is_cousin_of = scope:puppet_or_actor } - NOT = { is_child_of = scope:actor } + NOT = { is_child_of = scope:puppet_or_actor } } } @@ -4349,16 +4810,16 @@ divorce_character_rel_head_interaction = { add = 50 desc = PARENTS #YOU_ARE_MY_PARENT scope:recipient = { - is_child_of = scope:actor + is_child_of = scope:puppet_or_actor } } modifier = { add = { add = 10 - multiply = scope:actor.num_virtuous_traits + multiply = scope:puppet_or_actor.num_virtuous_traits } - scope:actor.num_virtuous_traits > 0 + scope:puppet_or_actor.num_virtuous_traits > 0 desc = I_AM_VIRTUOUS } @@ -4374,9 +4835,9 @@ divorce_character_rel_head_interaction = { modifier = { add = { add = -10 - multiply = scope:actor.num_sinful_traits + multiply = scope:puppet_or_actor.num_sinful_traits } - scope:actor.num_sinful_traits > 0 + scope:puppet_or_actor.num_sinful_traits > 0 desc = I_AM_SINFUL } @@ -4392,8 +4853,8 @@ divorce_character_rel_head_interaction = { modifier = { # You're in a same-sex marriage and your faith doesn't allow it add = 100 desc = SAME_SEX_MARRIAGE_FAITH_REASON_ACTOR - scope:actor.faith = scope:recipient.faith - scope:actor = { + scope:puppet_or_actor.faith = scope:recipient.faith + scope:puppet_or_actor = { sex_same_as = scope:secondary_recipient allowed_to_marry_same_sex_trigger = no } @@ -4404,7 +4865,7 @@ divorce_character_rel_head_interaction = { desc = SAME_SEX_MARRIAGE_FAITH_REASON scope:secondary_recipient.faith = scope:recipient.faith scope:secondary_recipient = { - sex_same_as = scope:actor + sex_same_as = scope:puppet_or_actor allowed_to_marry_same_sex_trigger = no } } @@ -4420,28 +4881,258 @@ divorce_character_rel_head_interaction = { evaluate_action_decreasing_house_unity = { VALUE = 100 } + modifier = { + add = 100 + scope:puppet_or_actor.puppet:theological_agent_puppet ?= scope:recipient + desc = IS_YOUR_PUPPET + } + + modifier = { + add = { + value = 25 + if = { + limit = { + pam_actor_rite_has_core_simony_trigger = yes + } + multiply = 5 + } + } + scope:donate_faith ?= yes + scope:puppet_or_actor.major_gold_value < scope:recipient.minor_gold_value + desc = DONATE_FAITH_INTERACTION_OPTION_REASON + } + modifier = { + add = { + value = 50 + if = { + limit = { + pam_actor_rite_has_core_simony_trigger = yes + } + multiply = 5 + } + } + scope:donate_faith ?= yes + scope:puppet_or_actor.major_gold_value < scope:recipient.major_gold_value + scope:puppet_or_actor.major_gold_value >= scope:recipient.minor_gold_value + desc = DONATE_FAITH_INTERACTION_OPTION_REASON + } + modifier = { + add = { + value = 75 + if = { + limit = { + pam_actor_rite_has_core_simony_trigger = yes + } + multiply = 5 + } + } + scope:donate_faith ?= yes + scope:puppet_or_actor.major_gold_value >= scope:recipient.major_gold_value + scope:puppet_or_actor.major_gold_value < scope:recipient.monumental_gold_value + desc = DONATE_FAITH_INTERACTION_OPTION_REASON + } + modifier = { + add = { + value = 100 + if = { + limit = { + pam_actor_rite_has_core_simony_trigger = yes + } + multiply = 5 + } + } + scope:donate_faith ?= yes + scope:puppet_or_actor.major_gold_value >= scope:recipient.monumental_gold_value + desc = DONATE_FAITH_INTERACTION_OPTION_REASON + } + modifier = { + add = 25 + scope:divorce_justified ?= yes + desc = JUSTIFY_DIVORCE_REASON + } + modifier = { + add = { + value = 20 + if = { + limit = { + scope:puppet_or_actor.highest_held_title_tier > scope:recipient.highest_held_title_tier + } + multiply = { + value = scope:puppet_or_actor.highest_held_title_tier + subtract = scope:recipient.highest_held_title_tier + add = 1 + } + } + else_if = { + limit = { + scope:puppet_or_actor.highest_held_title_tier < scope:recipient.highest_held_title_tier_minus_one + } + multiply = 0.25 + } + else_if = { + limit = { + scope:puppet_or_actor.highest_held_title_tier < scope:recipient.highest_held_title_tier + } + multiply = 0.5 + } + if = { + limit = { + OR = { + is_liege_or_above_of = scope:recipient + liege ?= scope:recipient.liege + capital_county.holder ?= { + OR = { + this = scope:puppet_or_actor + any_liege_or_above = { + this = scope:puppet_or_actor + } + } + } + } + } + multiply = 3 + } + else_if = { + limit = { + scope:recipient = { + OR = { + any_neighboring_top_liege_realm_owner = { + this = scope:puppet_or_actor + } + capital_county = { + any_neighboring_county = { + OR = { + holder = scope:puppet_or_actor + holder = { + any_liege_or_above = { + this = scope:puppet_or_actor + } + } + } + } + } + } + } + } + multiply = 2 + } + } + scope:threaten_priest = yes + desc = THREATEN_PRIEST_INTERACTION_OPTION_REASON + } + modifier = { + add = pam_offer_pilgrimage_acceptance_value + scope:offer_pilgrimage = yes + desc = OFFER_PILGRIMAGE_INTERACTION_OPTION_REASON + } + secular_to_ecclesiastical_pam_factors_acceptance_modifier = yes } auto_accept = { custom_description = { text = "spending_hook" - subject = scope:actor + subject = scope:puppet_or_actor object = scope:recipient scope:divorce_hook = yes } } - + options_heading = DIVORCE_INDUCEMENTS send_option = { is_valid = { - scope:actor = { + scope:puppet_or_actor = { + custom_tooltip = { + text = divorce_justified_tt + divorce_is_justified_trigger = { DIVORCER = scope:puppet_or_actor } + } + } + } + flag = divorce_justified + localization = JUSTIFY_DIVORCE_INTERACTION_OPTION + } + send_option = { + is_valid = { + scope:puppet_or_actor = { + dread >= medium_dread_value + current_military_strength > scope:recipient.current_military_strength + custom_tooltip = { + text = must_neighbor_recipient_tt + OR = { + any_vassal_or_below = { + this = scope:recipient + } + any_sub_realm_county = { + OR = { + clerical_region_title ?= { + holder ?= scope:recipient + } + any_neighboring_county = { + holder = { + OR = { + this = scope:recipient + any_liege_or_above = { + this = scope:recipient + } + } + } + } + } + } + } + } + } + scope:recipient = { + NOR = { + has_trait = stubborn + has_trait = brave + has_trait = arrogant + has_trait = ambitious + } + } + } + flag = threaten_priest + localization = THREATEN_PRIEST_INTERACTION_OPTION + } + send_option = { + is_valid = { + scope:puppet_or_actor = { + trigger_if = { + limit = { + scope:actor = { + is_ai = yes + } + } + short_term_gold >= monumental_gold_value + } + trigger_else = { + gold >= major_gold_value + } + } + } + flag = donate_faith + localization = DONATE_TO_THE_FAITH_INTERACTION_OPTION + } + send_option = { + is_valid = { + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } flag = divorce_hook localization = GENERIC_SPEND_A_HOOK } + send_option = { + is_shown = { + has_pam_dlc_trigger = yes + pam_offer_pilgrimage_option_shown_trigger = { ACTOR = scope:puppet_or_actor } + } + is_valid = { + pam_offer_pilgrimage_option_valid_trigger = { ACTOR = scope:puppet_or_actor } + } + flag = offer_pilgrimage + localization = OFFER_PILGRIMAGE_INTERACTION_OPTION + } should_use_extra_icon = { - scope:actor = { has_usable_hook = scope:recipient } + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } extra_icon = "gfx/interface/icons/character_interactions/hook_icon.dds" @@ -4450,10 +5141,89 @@ divorce_character_rel_head_interaction = { ai_min_reply_days = 1 ai_max_reply_days = 5 + on_send = { + #Make sure AI always justifies divorce when valid + scope:puppet_or_actor = { + if = { + limit = { + scope:actor = { is_ai = yes } + divorce_is_justified_trigger = { DIVORCER = scope:puppet_or_actor } + NOT = { + scope:divorce_justified ?= yes + } + } + save_scope_as = ai_divorce_justified + } + } + } + on_accept = { + scope:puppet_or_actor = { + save_scope_as = divorcer + } + if = { + limit = { scope:is_puppet_action ?= yes } + scope:actor = { + scope:puppet_or_actor = { add_piety = { value = { add = divorce_cost max = piety multiply = -1 } } } + send_interface_toast = { + type = event_toast_effect_neutral + title = divorce_interaction_notification_puppeteer + left_icon = scope:puppet_or_actor + right_icon = scope:secondary_recipient + } + } + } + scope:recipient = { + if = { + limit = { + #No inducement given + NOR = { + scope:divorce_hook ?= yes + scope:donate_faith ?= yes + scope:divorce_justified ?= yes + exists = scope:ai_divorce_justified + scope:threaten_priest ?= yes + scope:offer_pilgrimage ?= yes + } + #One of the methods is possible + OR = { + divorce_can_cause_house_feud_trigger = yes + divorce_can_cause_holy_order_lease_trigger = yes + divorce_can_cause_hook_trigger = yes + divorce_can_put_spouse_in_monastery_trigger = yes + } + } + custom_tooltip = cleric_divorce_fuckery_tt + if = { + limit = { + divorce_can_cause_house_feud_trigger = yes + } + custom_tooltip = cleric_cause_house_feud_tt + } + if = { + limit = { + divorce_can_cause_holy_order_lease_trigger = yes + } + custom_tooltip = cleric_force_holy_order_lease_tt + } + if = { + limit = { + divorce_can_cause_hook_trigger = yes + } + custom_tooltip = cleric_get_hook_tt + } + if = { + limit = { + divorce_can_put_spouse_in_monastery_trigger = yes + } + custom_tooltip = cleric_put_spouse_in_monastery_tt + } + save_scope_as = no_inducement + } + } if = { limit = { always = scope:divorce_hook } - scope:actor = { + scope:puppet_or_actor = { if = { limit = { has_usable_hook = scope:recipient @@ -4462,21 +5232,76 @@ divorce_character_rel_head_interaction = { } } } + pam_offer_pilgrimage_effect = { + ACTOR = scope:puppet_or_actor + CLERIC = scope:recipient + } show_as_tooltip = { - scope:actor = { + scope:divorcer = { divorce_effect = { - DIVORCER = scope:actor + DIVORCER = scope:divorcer DIVORCEE = scope:secondary_recipient } } } - scope:actor = { - trigger_event = religious_interaction.1 + if = { + limit = { + NOR = { + scope:divorce_justified ?= yes + exists = scope:ai_divorce_justified + } + } + if = { + limit = { + scope:recipient = { + is_ai = no + } + } + scope:recipient = { + change_spiritual_fulfillment = minor_spiritual_fulfillment_loss + } + } + else = { + hidden_effect = { + scope:recipient = { + change_spiritual_fulfillment = miniscule_spiritual_fulfillment_loss + } + } + } + } + else = { + scope:recipient = { add_piety = minor_piety_gain } + } + scope:puppet_or_actor = { + if = { + limit = { + scope:donate_faith ?= yes + } + pay_short_term_gold = { + target = scope:recipient + gold = scope:puppet_or_actor.major_gold_value + } + } + } + #Recipient is free to fuck with the divorce + if = { + limit = { + exists = scope:no_inducement + } + scope:recipient = { + trigger_event = pam_interactions_events.0060 + } + } + #Divorcer (the puppet when puppeted) gets confirmation directly + else = { + scope:divorcer = { + trigger_event = religious_interaction.1 + } } # If we're a clan this interaction affects unity add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = major_unity_loss DESC = clan_unity_alliance.desc @@ -4485,18 +5310,85 @@ divorce_character_rel_head_interaction = { } on_decline = { - scope:actor = { + scope:puppet_or_actor = { send_interface_toast = { type = event_toast_effect_bad title = divorce_character_rel_head_interaction_decline_notification - right_icon = scope:actor.faith.religious_head + right_icon = scope:puppet_or_actor.faith.religious_head + clerical_interaction_refusal_minor_effect = yes + } + } + if = { + limit = { + scope:recipient = { + is_ai = no + } + scope:actor = { + is_ai = yes + } + } + scope:recipient = { + if = { + limit = { + learning > extremely_high_skill_rating + scope:actor = { + is_ai = yes + } + NOR = { + rite = { + trait_is_virtue_rite = lustful + } + rite = { + trait_is_sin_rite = chaste + } + scope:puppet_or_actor = { + has_trait = lustful + } + } + } + custom_tooltip = refuse_divorce_celibacy_tt + } + if = { + limit = { + scope:puppet_or_actor = { + is_imprisoned = no + is_incapable = no + } + scope:secondary_recipient = { + is_imprisoned = no + is_incapable = no + } + } + custom_tooltip = refuse_divorce_comfort_tt + } + custom_tooltip = refuse_divorce_condemn_tt + trigger_event = { + id = pam_interactions_events.0050 + days = 1 + } + #Gain stress for ignoring threat from actor + if = { + limit = { + + scope:threaten_priest ?= yes + } + if = { + limit = { + ai_boldness < 0 + } + add_stress = major_stress_gain + } + else = { + add_stress = medium_stress_gain + } + } } } # If we're a clan this interaction affects unity add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = minor_unity_loss DESC = clan_unity_alliance.desc @@ -4517,20 +5409,16 @@ divorce_character_rel_head_interaction = { hegemony = 36 } - ai_potential = { - is_ruler = yes - } - ai_will_do = { base = 0 modifier = { # The AI wants to divorce should they not have an heir that is their own child, and their spouse is infertile add = 100 - scope:actor = { + scope:puppet_or_actor = { fertility > 0.1 NOT = { any_child = { - is_heir_of = scope:actor + is_heir_of = scope:puppet_or_actor } } } @@ -4547,11 +5435,17 @@ divorce_character_rel_head_interaction = { modifier = { # You're in a same-sex marriage and your faith doesn't allow it add = 100 - scope:actor = { + scope:puppet_or_actor = { sex_same_as = scope:secondary_recipient allowed_to_marry_same_sex_trigger = no } } + modifier = { + add = -66 + scope:puppet_or_actor = { + NOT = { divorce_is_justified_trigger = { DIVORCER = scope:puppet_or_actor } } + } + } } } @@ -4563,8 +5457,20 @@ divorce_character_dynast_request_interaction = { desc = divorce_character_dynast_request_interaction_desc cost = { - piety = divorce_cost - renown = scope:actor.dynasty.minor_dynasty_prestige_value + piety = { + value = divorce_cost + if = { + limit = { scope:is_puppet_action ?= yes } + multiply = 0 + } + } + renown = { + value = scope:puppet_or_actor.dynasty.minor_dynasty_prestige_value + if = { + limit = { scope:is_puppet_action ?= yes } + multiply = 0 + } + } } redirect = { @@ -4583,28 +5489,29 @@ divorce_character_dynast_request_interaction = { } is_shown = { - scope:secondary_actor != scope:actor - scope:secondary_actor.dynasty.dynast = scope:actor + scope:secondary_actor != scope:puppet_or_actor + scope:puppet_or_actor ?= { pam_grants_own_divorce_trigger = no } + scope:secondary_actor.dynasty.dynast ?= scope:puppet_or_actor - scope:actor.faith = { - # We are not required to seek approval of a spiritual HoF - NAND = { - has_doctrine = doctrine_divorce_approval + # We are not required to seek approval of a spiritual HoF + NAND = { + scope:puppet_or_actor.rite = { rite_has_doctrine = doctrine_divorce_approval } + scope:puppet_or_actor.faith = { has_doctrine = doctrine_spiritual_head exists = religious_head } } OR = { AND = { - scope:actor.faith != scope:secondary_actor.faith + scope:puppet_or_actor.faith != scope:secondary_actor.faith # They are not required to seek approval of a spiritual HoF of the Dynasty Member - scope:secondary_actor.faith = { + scope:secondary_actor.rite ?= { NOT = { - has_doctrine = doctrine_divorce_approval + rite_has_doctrine = doctrine_divorce_approval } } } - scope:actor.faith = scope:secondary_actor.faith + scope:puppet_or_actor.faith ?= scope:secondary_actor.faith } scope:recipient = { @@ -4614,50 +5521,75 @@ divorce_character_dynast_request_interaction = { } is_valid_showing_failures_only = { - custom_tooltip = { - NOT = { - scope:actor.culture = { - has_cultural_parameter = cannot_divorce + trigger_if = { + limit = { scope:actor = scope:puppet_or_actor } + custom_tooltip = { + NOT = { + scope:puppet_or_actor.culture = { + has_cultural_parameter = cannot_divorce + } } + text = CULTURE_FORBIDS_DIVORCE + } + } + trigger_else = { + custom_tooltip = { + NOT = { + scope:puppet_or_actor.culture = { + has_cultural_parameter = cannot_divorce + } + } + text = CULTURE_FORBIDS_DIVORCE_puppeteer } - text = CULTURE_FORBIDS_DIVORCE } NOT = { - scope:actor.faith = { - has_doctrine = doctrine_divorce_disallowed + scope:puppet_or_actor.rite = { + rite_has_doctrine = doctrine_divorce_disallowed } } - scope:actor.dynasty = { + scope:puppet_or_actor.dynasty = { dynasty_prestige >= minor_dynasty_prestige_value } NOT = { - scope:secondary_actor.faith = { - has_doctrine = doctrine_divorce_disallowed + scope:secondary_actor.rite = { + rite_has_doctrine = doctrine_divorce_disallowed } } - scope:secondary_actor = { NOT = { has_strong_hook = scope:actor } } + scope:secondary_actor = { NOT = { has_strong_hook = scope:puppet_or_actor } } trigger_if = { limit = { scope:secondary_actor = { NOR = { - is_child_of = scope:actor - is_grandchild_of = scope:actor - is_great_grandchild_of = scope:actor + is_child_of = scope:puppet_or_actor + is_grandchild_of = scope:puppet_or_actor + is_great_grandchild_of = scope:puppet_or_actor } } } custom_description = { - scope:secondary_actor.top_liege = scope:actor.top_liege + scope:secondary_actor.top_liege = scope:puppet_or_actor.top_liege + subject = scope:puppet_or_actor text = "same_realm_as" } } - scope:actor = { - custom_tooltip = { - NOT = { - var:family_widow_forbidden_divorce ?= scope:recipient + scope:puppet_or_actor = { + trigger_if = { + limit = { scope:actor = scope:puppet_or_actor } + custom_tooltip = { + NOT = { + var:family_widow_forbidden_divorce ?= scope:recipient + } + text = BOUND_TO_FAMILY_WIDOW + } + } + trigger_else = { + custom_tooltip = { + NOT = { + var:family_widow_forbidden_divorce ?= scope:recipient + } + text = BOUND_TO_FAMILY_WIDOW_puppeteer } - text = BOUND_TO_FAMILY_WIDOW } } } @@ -4665,7 +5597,14 @@ divorce_character_dynast_request_interaction = { auto_accept = yes on_accept = { - scope:actor = { + if = { + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + add_piety = { value = { add = divorce_cost max = piety multiply = -1 } } + dynasty ?= { add_dynasty_prestige = { value = { add = scope:puppet_or_actor.dynasty.minor_dynasty_prestige_value multiply = -1 } } } + } + } + scope:puppet_or_actor = { send_interface_toast = { type = event_toast_effect_good title = divorce_character_dynast_request_interaction_title @@ -4685,19 +5624,19 @@ divorce_character_dynast_request_interaction = { add_opinion = { modifier = forced_divorce_opinion - target = scope:actor + target = scope:puppet_or_actor } } if = { limit = { - scope:recipient != scope:actor + scope:recipient != scope:puppet_or_actor } scope:recipient = { trigger_event = marriage_interaction.0030 add_opinion = { modifier = forced_divorce_opinion - target = scope:actor + target = scope:puppet_or_actor } } } @@ -4717,10 +5656,6 @@ divorce_character_dynast_request_interaction = { hegemony = 72 } - ai_potential = { - is_ruler = yes - } - ai_will_do = { base = 0 @@ -4733,9 +5668,9 @@ divorce_character_dynast_request_interaction = { is_ai = yes fertility < 0.1 } - exists = scope:actor.primary_heir - exists = scope:actor.primary_heir.dynasty - scope:actor.primary_heir.dynasty != this.dynasty + exists = scope:puppet_or_actor.primary_heir + exists = scope:puppet_or_actor.primary_heir.dynasty + scope:puppet_or_actor.primary_heir.dynasty != this.dynasty } #Players should not be targeted @@ -4754,9 +5689,23 @@ divorce_character_dynast_request_rel_head_interaction = { use_diplomatic_range = no icon = icon_dynasty + desc = divorce_character_dynast_request_interaction_desc + cost = { - piety = divorce_cost - renown = scope:actor.dynasty.minor_dynasty_prestige_value + piety = { + value = divorce_cost + if = { + limit = { scope:is_puppet_action ?= yes } + multiply = 0 + } + } + renown = { + value = scope:puppet_or_actor.dynasty.minor_dynasty_prestige_value + if = { + limit = { scope:is_puppet_action ?= yes } + multiply = 0 + } + } } redirect = { @@ -4772,72 +5721,317 @@ divorce_character_dynast_request_rel_head_interaction = { save_scope_as = secondary_recipient } } - + #Recipient should be cleric or hof if = { limit = { - exists = scope:actor.faith.religious_head + scope:puppet_or_actor = { + government_has_flag = government_is_theocracy + exists = superior + } } - scope:actor.faith.religious_head = { + scope:puppet_or_actor.superior = { save_scope_as = recipient } + } + #Redirect to bishop superior of court chaplain + else_if = { + limit = { + OR = { + scope:puppet_or_actor.highest_held_title_tier < tier_kingdom + scope:puppet_or_actor.faith = { + NOR = { + has_doctrine = doctrine_spiritual_head + exists = scope:faith.religious_head + } + } + } + scope:puppet_or_actor.cp:councillor_court_chaplain ?= { + highest_held_title_tier < tier_duchy + superior ?= { + highest_held_title_tier >= tier_duchy + is_clergy = yes + } + } + } + scope:puppet_or_actor.cp:councillor_court_chaplain.superior = { + save_scope_as = recipient + } + } + #Redirect to bishop + else_if = { + limit = { + OR = { + scope:puppet_or_actor.highest_held_title_tier < tier_kingdom + scope:puppet_or_actor.faith = { + NOR = { + has_doctrine = doctrine_spiritual_head + exists = scope:faith.religious_head + } + } + } + scope:puppet_or_actor.cp:councillor_court_chaplain ?= { + highest_held_title_tier >= tier_duchy + is_clergy = yes + } + } + scope:puppet_or_actor.cp:councillor_court_chaplain = { + save_scope_as = recipient + } + } + else = { + scope:puppet_or_actor.faith.religious_head ?= { save_scope_as = recipient } } } greeting = positive - notification_text = ASK_FOR_DIVORCE_NOTIFICATION - - is_shown = { - scope:secondary_actor != scope:actor - scope:secondary_actor.dynasty.dynast = scope:actor - NOT = { - scope:secondary_actor = { is_spouse_of = scope:actor } - } - - exists = scope:secondary_recipient - - scope:actor.faith = scope:secondary_actor.faith - exists = scope:actor.faith.religious_head - scope:actor.faith = { - has_doctrine = doctrine_spiritual_head - has_doctrine = doctrine_divorce_approval + + notification_text = { + desc = ASK_FOR_DIVORCE_THIRD_PERSON_NOTIFICATION + first_valid = { + triggered_desc = { + trigger = { + scope:secondary_actor = { + faith = scope:recipient.faith + sex_same_as = scope:secondary_recipient + allowed_to_marry_same_sex_trigger = no + } + } + desc = ASK_FOR_DIVORCE_NOTIFICATION_SAME_SEX_SECONDARY + } + triggered_desc = { + trigger = { + scope:secondary_actor = { + relation_with_character_is_incestuous_in_my_faith_trigger = { CHARACTER = scope:secondary_recipient } + } + } + desc = ASK_FOR_DIVORCE_NOTIFICATION_INCESTUOUS_SECONDARY + } + triggered_desc = { + trigger = { + scope:secondary_recipient = { + any_relation = { + type = lover + NOR = { + this = scope:secondary_actor + this = scope:recipient + } + relation_with_character_is_incestuous_in_my_rite_trigger = { CHARACTER = scope:secondary_recipient } + } + } + } + desc = ASK_FOR_DIVORCE_NOTIFICATION_INCESTUOUS_LOVER_SECONDARY + } + triggered_desc = { + trigger = { + scope:secondary_recipient = { + is_female = no + is_eunuch_trigger = yes + } + } + desc = ASK_FOR_DIVORCE_NOTIFICATION_EUNUCH_SECONDARY + } + triggered_desc = { + trigger = { + scope:secondary_actor = { + has_opinion_modifier = { + modifier = attempted_murder_me_crime + target = scope:secondary_recipient + } + } + } + desc = ASK_FOR_DIVORCE_NOTIFICATION_ATTEMPTED_MURDER_SECONDARY + } + triggered_desc = { + trigger = { + scope:secondary_recipient = { + has_character_modifier = wedding_accused_impotency_modifier + } + } + desc = ASK_FOR_DIVORCE_NOTIFICATION_IMPOTENCE_SECONDARY + } + triggered_desc = { + trigger = { + scope:secondary_actor = { + any_consort = { + is_alive = yes + this != scope:secondary_recipient + } + any_consort = { + this = scope:secondary_recipient + } + } + scope:secondary_recipient = { + culture = { NOT = { has_cultural_tradition = tradition_polygamous } } + rite = { NOT = { rite_has_doctrine = doctrine_polygamy } } + } + } + desc = ASK_FOR_DIVORCE_NOTIFICATION_MULTIPLE_CONSORTS_SECONDARY + } + triggered_desc = { + trigger = { + scope:secondary_recipient.faith = { + faith_hostility_level = { + target = scope:recipient.faith + value >= faith_hostile_level + } + } + } + desc = ASK_FOR_DIVORCE_NOTIFICATION_HOSTILE_FAITH_SECONDARY + } + triggered_desc = { + trigger = { + scope:secondary_recipient = { + exposed_cheating_on_spouse_trigger = { SPOUSE = scope:secondary_actor } + } + } + desc = ASK_FOR_DIVORCE_NOTIFICATION_EXPOSED_CHEATING_SECONDARY + } + triggered_desc = { + trigger = { + scope:secondary_recipient = { + fertility < 0.1 + NOT = { + any_child = { + any_parent = { + this = scope:secondary_actor + } + } + } + } + } + desc = ASK_FOR_DIVORCE_NOTIFICATION_INFERTILITY_SECONDARY + } + triggered_desc = { + trigger = { + scope:secondary_recipient = { + has_trait = adulterer + } + } + desc = ASK_FOR_DIVORCE_NOTIFICATION_ADULTERY_TRAIT_SECONDARY + } + triggered_desc = { + trigger = { + scope:secondary_actor = { + opinion = { + target = scope:secondary_recipient + value < -50 + } + } + } + desc = ASK_FOR_DIVORCE_NOTIFICATION_HATRED_SECONDARY + } + desc = ASK_FOR_DIVORCE_NOTIFICATION_NOT_JUSTIFIED_SECONDARY } } - is_valid_showing_failures_only = { - custom_tooltip = { - NOT = { - scope:actor.culture = { - has_cultural_parameter = cannot_divorce + is_shown = { + scope:puppet_or_actor.rite ?= { rite_has_doctrine = doctrine_divorce_approval } + scope:puppet_or_actor ?= { pam_grants_own_divorce_trigger = no } + scope:puppet_or_actor ?= { + OR = { + faith ?= { + has_doctrine = doctrine_spiritual_head + exists = religious_head + } + cp:councillor_court_chaplain ?= { + highest_held_title_tier >= tier_duchy + is_clergy = yes + } + AND = { + government_has_flag = government_is_theocracy + exists = superior + } + cp:councillor_court_chaplain.superior ?= { + highest_held_title_tier >= tier_duchy + is_clergy = yes } } - text = CULTURE_FORBIDS_DIVORCE } - scope:actor.dynasty = { - dynasty_prestige >= minor_dynasty_prestige_value + scope:secondary_actor != scope:puppet_or_actor + + scope:secondary_actor.dynasty.dynast ?= scope:puppet_or_actor + + NOT = { + scope:secondary_actor = { is_spouse_of = scope:puppet_or_actor } + } + exists = scope:secondary_recipient + scope:puppet_or_actor.faith ?= scope:secondary_actor.faith + } + + is_valid_showing_failures_only = { + scope:puppet_or_actor = { + NOT = { + has_character_modifier = promised_pilgrimage_to_clergy_modifier + } + } + trigger_if = { + limit = { scope:actor = scope:puppet_or_actor } + custom_tooltip = { + NOT = { + scope:puppet_or_actor.culture = { + has_cultural_parameter = cannot_divorce + } + } + text = CULTURE_FORBIDS_DIVORCE + } + } + trigger_else = { + custom_tooltip = { + NOT = { + scope:puppet_or_actor.culture = { + has_cultural_parameter = cannot_divorce + } + } + text = CULTURE_FORBIDS_DIVORCE_puppeteer + } } - scope:secondary_actor = { NOT = { has_strong_hook = scope:actor } } + scope:secondary_actor = { NOT = { has_strong_hook = scope:puppet_or_actor } } trigger_if = { limit = { scope:secondary_actor = { NOR = { - is_child_of = scope:actor - is_grandchild_of = scope:actor - is_great_grandchild_of = scope:actor + is_child_of = scope:puppet_or_actor + is_grandchild_of = scope:puppet_or_actor + is_great_grandchild_of = scope:puppet_or_actor } } } custom_description = { - scope:secondary_actor.top_liege = scope:actor.top_liege + scope:secondary_actor.top_liege = scope:puppet_or_actor.top_liege + subject = scope:puppet_or_actor text = "same_realm_as" } } - scope:actor = { - custom_tooltip = { - NOT = { - var:family_widow_forbidden_divorce ?= scope:recipient + scope:puppet_or_actor = { + trigger_if = { + limit = { scope:actor = scope:puppet_or_actor } + custom_tooltip = { + NOT = { + var:family_widow_forbidden_divorce ?= scope:secondary_recipient + } + text = BOUND_TO_FAMILY_WIDOW } - text = BOUND_TO_FAMILY_WIDOW + } + trigger_else = { + custom_tooltip = { + NOT = { + var:family_widow_forbidden_divorce ?= scope:secondary_recipient + } + text = BOUND_TO_FAMILY_WIDOW_puppeteer + } + } + } + trigger_if = { + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + piety >= divorce_cost + } + } + trigger_if = { + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + dynasty ?= { dynasty_prestige >= scope:puppet_or_actor.dynasty.minor_dynasty_prestige_value } } } } @@ -4853,7 +6047,7 @@ divorce_character_dynast_request_rel_head_interaction = { scope:secondary_actor = { is_close_or_extended_family_of = scope:secondary_recipient - faith = { has_doctrine = tenet_divine_marriage } + rite = { rite_has_tenet = tenet_divine_marriage } } } @@ -4871,11 +6065,11 @@ divorce_character_dynast_request_rel_head_interaction = { desc = YOU_ARE_MY_DYNASTY_MEMBER scope:recipient = { is_lowborn = no - dynasty = scope:actor.dynasty + dynasty = scope:puppet_or_actor.dynasty NOR = { - is_close_or_extended_family_of = scope:actor - is_cousin_of = scope:actor - is_child_of = scope:actor + is_close_or_extended_family_of = scope:puppet_or_actor + is_cousin_of = scope:puppet_or_actor + is_child_of = scope:puppet_or_actor scope:recipient.dynasty = scope:secondary_recipient.dynasty } } @@ -4887,11 +6081,11 @@ divorce_character_dynast_request_rel_head_interaction = { desc = YOU_ARE_MY_HOUSE_MEMBER scope:recipient = { is_lowborn = no - house = scope:actor.house + house = scope:puppet_or_actor.house NOR = { - is_close_or_extended_family_of = scope:actor - is_cousin_of = scope:actor - is_child_of = scope:actor + is_close_or_extended_family_of = scope:puppet_or_actor + is_cousin_of = scope:puppet_or_actor + is_child_of = scope:puppet_or_actor scope:recipient.house = scope:secondary_recipient.house } } @@ -4902,10 +6096,10 @@ divorce_character_dynast_request_rel_head_interaction = { desc = YOU_ARE_MY_RELATIVE scope:recipient = { OR = { - is_close_or_extended_family_of = scope:actor - is_cousin_of = scope:actor + is_close_or_extended_family_of = scope:puppet_or_actor + is_cousin_of = scope:puppet_or_actor } - NOT = { is_child_of = scope:actor } + NOT = { is_child_of = scope:puppet_or_actor } } } @@ -4913,16 +6107,16 @@ divorce_character_dynast_request_rel_head_interaction = { add = 50 desc = PARENTS #YOU_ARE_MY_PARENT scope:recipient = { - is_child_of = scope:actor + is_child_of = scope:puppet_or_actor } } modifier = { add = { add = 10 - multiply = scope:actor.num_virtuous_traits + multiply = scope:puppet_or_actor.num_virtuous_traits } - scope:actor.num_virtuous_traits > 0 + scope:puppet_or_actor.num_virtuous_traits > 0 desc = I_AM_VIRTUOUS } @@ -4938,9 +6132,9 @@ divorce_character_dynast_request_rel_head_interaction = { modifier = { add = { add = -10 - multiply = scope:actor.num_sinful_traits + multiply = scope:puppet_or_actor.num_sinful_traits } - scope:actor.num_sinful_traits > 0 + scope:puppet_or_actor.num_sinful_traits > 0 desc = I_AM_SINFUL } @@ -4952,28 +6146,259 @@ divorce_character_dynast_request_rel_head_interaction = { scope:secondary_recipient.num_sinful_traits > 0 desc = THEY_ARE_SINFUL } + modifier = { + add = 100 + scope:puppet_or_actor.puppet:theological_agent_puppet ?= scope:recipient + desc = IS_YOUR_PUPPET + } + + modifier = { + add = { + value = 25 + if = { + limit = { + pam_actor_rite_has_core_simony_trigger = yes + } + multiply = 5 + } + } + scope:donate_faith ?= yes + scope:puppet_or_actor.major_gold_value < scope:recipient.minor_gold_value + desc = DONATE_FAITH_INTERACTION_OPTION_REASON + } + modifier = { + add = { + value = 50 + if = { + limit = { + pam_actor_rite_has_core_simony_trigger = yes + } + multiply = 5 + } + } + scope:donate_faith ?= yes + scope:puppet_or_actor.major_gold_value < scope:recipient.major_gold_value + scope:puppet_or_actor.major_gold_value >= scope:recipient.minor_gold_value + desc = DONATE_FAITH_INTERACTION_OPTION_REASON + } + modifier = { + add = { + value = 75 + if = { + limit = { + pam_actor_rite_has_core_simony_trigger = yes + } + multiply = 5 + } + } + scope:donate_faith ?= yes + scope:puppet_or_actor.major_gold_value >= scope:recipient.major_gold_value + scope:puppet_or_actor.major_gold_value < scope:recipient.monumental_gold_value + desc = DONATE_FAITH_INTERACTION_OPTION_REASON + } + modifier = { + add = { + value = 100 + if = { + limit = { + pam_actor_rite_has_core_simony_trigger = yes + } + multiply = 5 + } + } + scope:donate_faith ?= yes + scope:puppet_or_actor.major_gold_value >= scope:recipient.monumental_gold_value + desc = DONATE_FAITH_INTERACTION_OPTION_REASON + } + modifier = { + add = 25 + scope:divorce_justified ?= yes + desc = JUSTIFY_DIVORCE_REASON + } + modifier = { + add = { + value = 20 + if = { + limit = { + scope:puppet_or_actor.highest_held_title_tier > scope:recipient.highest_held_title_tier + } + multiply = { + value = scope:puppet_or_actor.highest_held_title_tier + subtract = scope:recipient.highest_held_title_tier + add = 1 + } + } + else_if = { + limit = { + scope:puppet_or_actor.highest_held_title_tier < scope:recipient.highest_held_title_tier_minus_one + } + multiply = 0.25 + } + else_if = { + limit = { + scope:puppet_or_actor.highest_held_title_tier < scope:recipient.highest_held_title_tier + } + multiply = 0.5 + } + if = { + limit = { + OR = { + is_liege_or_above_of = scope:recipient + liege ?= scope:recipient.liege + capital_county.holder ?= { + OR = { + this = scope:puppet_or_actor + any_liege_or_above = { + this = scope:puppet_or_actor + } + } + } + } + } + multiply = 3 + } + else_if = { + limit = { + scope:recipient = { + OR = { + any_neighboring_top_liege_realm_owner = { + this = scope:puppet_or_actor + } + capital_county = { + any_neighboring_county = { + OR = { + holder = scope:puppet_or_actor + holder = { + any_liege_or_above = { + this = scope:puppet_or_actor + } + } + } + } + } + } + } + } + multiply = 2 + } + } + scope:threaten_priest = yes + desc = THREATEN_PRIEST_INTERACTION_OPTION_REASON + } + modifier = { + add = pam_offer_pilgrimage_acceptance_value + scope:offer_pilgrimage = yes + desc = OFFER_PILGRIMAGE_INTERACTION_OPTION_REASON + } + secular_to_ecclesiastical_pam_factors_acceptance_modifier = yes } auto_accept = { custom_description = { text = "spending_hook" - subject = scope:actor + subject = scope:puppet_or_actor object = scope:recipient scope:divorce_hook = yes } } + options_heading = DIVORCE_INDUCEMENTS send_option = { is_valid = { - scope:actor = { + scope:secondary_actor = { + custom_tooltip = { + text = divorce_justified_secondary_tt + divorce_is_justified_trigger = { DIVORCER = scope:secondary_actor } + } + } + } + flag = divorce_justified + localization = JUSTIFY_DIVORCE_INTERACTION_OPTION + } + send_option = { + is_valid = { + scope:puppet_or_actor = { + dread >= medium_dread_value + current_military_strength > scope:recipient.current_military_strength + custom_tooltip = { + text = must_neighbor_recipient_tt + OR = { + any_vassal_or_below = { + this = scope:recipient + } + any_sub_realm_county = { + OR = { + clerical_region_title ?= { + holder ?= scope:recipient + } + any_neighboring_county = { + holder = { + OR = { + this = scope:recipient + any_liege_or_above = { + this = scope:recipient + } + } + } + } + } + } + } + } + } + scope:recipient = { + NOR = { + has_trait = stubborn + has_trait = brave + has_trait = arrogant + has_trait = ambitious + } + } + } + flag = threaten_priest + localization = THREATEN_PRIEST_INTERACTION_OPTION + } + send_option = { + is_valid = { + scope:puppet_or_actor = { + trigger_if = { + limit = { + scope:actor = { + is_ai = yes + } + } + short_term_gold >= massive_gold_value + } + trigger_else = { + gold >= medium_gold_value + } + } + } + flag = donate_faith + localization = DONATE_TO_THE_FAITH_INTERACTION_OPTION + } + send_option = { + is_valid = { + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } flag = divorce_hook localization = GENERIC_SPEND_A_HOOK } + send_option = { + is_shown = { + has_pam_dlc_trigger = yes + pam_offer_pilgrimage_option_shown_trigger = { ACTOR = scope:puppet_or_actor } + } + is_valid = { + pam_offer_pilgrimage_option_valid_trigger = { ACTOR = scope:puppet_or_actor } + } + flag = offer_pilgrimage + localization = OFFER_PILGRIMAGE_INTERACTION_OPTION + } should_use_extra_icon = { - scope:actor = { has_usable_hook = scope:recipient } + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } extra_icon = "gfx/interface/icons/character_interactions/hook_icon.dds" @@ -4982,10 +6407,98 @@ divorce_character_dynast_request_rel_head_interaction = { ai_min_reply_days = 1 ai_max_reply_days = 5 + on_send = { + #Make sure AI always justifies divorce when valid + scope:puppet_or_actor = { + if = { + limit = { + scope:actor = { is_ai = yes } + scope:secondary_actor = { + divorce_is_justified_trigger = { DIVORCER = scope:secondary_actor } + } + NOT = { + scope:divorce_justified ?= yes + } + } + save_scope_as = ai_divorce_justified + } + } + } + on_accept = { + if = { + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + add_piety = { value = { add = divorce_cost max = piety multiply = -1 } } + dynasty ?= { add_dynasty_prestige = { value = { add = scope:puppet_or_actor.dynasty.minor_dynasty_prestige_value multiply = -1 } } } + } + } + scope:secondary_actor = { + save_scope_as = divorcer + } + scope:puppet_or_actor = { + save_scope_as = forcing_divorce + } + scope:recipient = { + if = { + limit = { + #No inducement given + NOR = { + scope:divorce_hook ?= yes + scope:donate_faith ?= yes + scope:divorce_justified ?= yes + exists = scope:ai_divorce_justified + scope:threaten_priest ?= yes + scope:offer_pilgrimage ?= yes + } + #One of the methods is possible + OR = { + divorce_can_cause_house_feud_trigger = yes + divorce_can_cause_holy_order_lease_trigger = yes + divorce_can_cause_hook_trigger = yes + divorce_can_put_spouse_in_monastery_trigger = yes + } + } + custom_tooltip = cleric_divorce_fuckery_tt + if = { + limit = { + divorce_can_cause_house_feud_trigger = yes + } + custom_tooltip = cleric_cause_house_feud_tt + } + if = { + limit = { + divorce_can_cause_holy_order_lease_trigger = yes + } + custom_tooltip = cleric_force_holy_order_lease_tt + } + if = { + limit = { + divorce_can_cause_hook_trigger = yes + } + custom_tooltip = cleric_get_hook_forcer_tt + } + if = { + limit = { + divorce_can_put_spouse_in_monastery_trigger = yes + } + custom_tooltip = cleric_put_spouse_in_monastery_tt + } + save_scope_as = no_inducement + } + } + show_as_tooltip = { + scope:secondary_actor = { + divorce_effect = { + DIVORCER = scope:secondary_actor + DIVORCEE = scope:secondary_recipient + } + } + } + if = { limit = { always = scope:divorce_hook } - scope:actor = { + scope:puppet_or_actor = { if = { limit = { has_usable_hook = scope:recipient @@ -4994,36 +6507,162 @@ divorce_character_dynast_request_rel_head_interaction = { } } } - scope:actor = { - trigger_event = religious_interaction.6 + scope:puppet_or_actor = { + if = { + limit = { + scope:donate_faith ?= yes + } + pay_short_term_gold = { + target = scope:recipient + gold = scope:puppet_or_actor.medium_gold_value + } + } + } + pam_offer_pilgrimage_effect = { + ACTOR = scope:puppet_or_actor + CLERIC = scope:recipient + } + if = { + limit = { + NOR = { + scope:divorce_justified ?= yes + exists = scope:ai_divorce_justified + } + } + if = { + limit = { + scope:recipient = { + is_ai = no + } + } + scope:recipient = { + change_spiritual_fulfillment = minor_spiritual_fulfillment_loss + } + } + else = { + hidden_effect = { + scope:recipient = { + change_spiritual_fulfillment = miniscule_spiritual_fulfillment_loss + } + } + } + } + else = { + scope:recipient = { add_piety = minor_piety_gain } } scope:secondary_actor = { - divorce_effect = { - DIVORCER = scope:secondary_actor - DIVORCEE = scope:secondary_recipient - } add_opinion = { modifier = forced_divorce_opinion - target = scope:actor + target = scope:puppet_or_actor } } scope:secondary_recipient = { add_opinion = { modifier = forced_divorce_opinion - target = scope:actor + target = scope:puppet_or_actor + } + } + #For follow-up event + scope:secondary_actor = { + save_scope_as = actor + save_scope_as = puppet_or_actor + } + #Recipient is free to fuck with the divorce + if = { + limit = { + exists = scope:no_inducement + } + scope:recipient = { + trigger_event = pam_interactions_events.0060 + } + } + #Actor just gets confirmation directly + else = { + scope:forcing_divorce = { + trigger_event = religious_interaction.6 } } } on_decline = { - scope:actor = { + scope:puppet_or_actor = { send_interface_toast = { type = event_toast_effect_bad title = divorce_character_dynast_request_rel_head_interaction_decline_notification - right_icon = scope:actor.faith.religious_head + right_icon = scope:recipient + clerical_interaction_refusal_minor_effect = yes + } + } + if = { + limit = { + scope:recipient = { + is_ai = no + } + scope:actor = { + is_ai = yes + } + } + scope:secondary_actor = { + save_scope_as = actor + save_scope_as = puppet_or_actor + } + scope:recipient = { + if = { + limit = { + learning > extremely_high_skill_rating + scope:actor = { + is_ai = yes + } + NOR = { + rite = { + trait_is_virtue_rite = lustful + } + rite = { + trait_is_sin_rite = chaste + } + scope:puppet_or_actor = { + has_trait = lustful + } + } + } + custom_tooltip = refuse_divorce_celibacy_tt + } + if = { + limit = { + scope:puppet_or_actor = { + is_imprisoned = no + is_incapable = no + } + scope:secondary_recipient = { + is_imprisoned = no + is_incapable = no + } + } + custom_tooltip = refuse_divorce_comfort_tt + } + custom_tooltip = refuse_divorce_condemn_tt + trigger_event = { + id = pam_interactions_events.0050 + days = 1 + } + #Gain stress for ignoring threat from actor + if = { + limit = { + scope:threaten_priest ?= yes + } + if = { + limit = { + ai_boldness < 0 + } + add_stress = major_stress_gain + } + else = { + add_stress = medium_stress_gain + } + } } } } @@ -5042,10 +6681,6 @@ divorce_character_dynast_request_rel_head_interaction = { hegemony = 72 } - ai_potential = { - is_ruler = yes - } - ai_will_do = { base = 0 @@ -5058,9 +6693,9 @@ divorce_character_dynast_request_rel_head_interaction = { is_ai = yes fertility < 0.1 } - exists = scope:actor.primary_heir - exists = scope:actor.primary_heir.dynasty - scope:actor.primary_heir.dynasty != this.dynasty + exists = scope:puppet_or_actor.primary_heir + exists = scope:puppet_or_actor.primary_heir.dynasty + scope:puppet_or_actor.primary_heir.dynasty != this.dynasty } modifier = { # The AI will only use a Hook if they couldn't otherwise do this @@ -5076,6 +6711,12 @@ divorce_character_dynast_request_rel_head_interaction = { scope:secondary_recipient = { is_ai = no } } } + modifier = { + add = -66 + scope:secondary_actor = { + NOT = { divorce_is_justified_trigger = { DIVORCER = scope:secondary_actor } } + } + } } } @@ -5114,14 +6755,29 @@ elope_interaction = { } } + is_available = { + trigger_if = { + limit = { is_ai = yes } + OR = { + any_relation = { type = lover } + any_relation = { type = soulmate } + } + NOR = { + has_trait = celibate + scheme_generic_ai_blocker_trigger = yes + } + is_adult = yes + } + } + is_shown = { scope:actor = { OR = { has_relation_lover = scope:recipient has_relation_soulmate = scope:recipient AND = { - has_government = landless_adventurer_government has_perk = accomplished_forger_perk + has_government = landless_adventurer_government } } } @@ -5165,24 +6821,26 @@ elope_interaction = { elopment_ai_accept_modifier = yes } - ai_potential = { - is_adult = yes - OR = { - any_relation = { type = lover } - any_relation = { type = soulmate } - } - NOR = { - has_trait = celibate - scheme_generic_ai_blocker_trigger = yes - } - } - ai_min_reply_days = 1 ai_max_reply_days = 3 + on_send = { + scope:actor = { + if = { + limit = { + OR = { + has_character_modifier = pam_granted_indulgences_modifier + has_character_modifier = pam_granted_indulgences_modifier_small + } + } + change_spiritual_fulfillment = medium_spiritual_fulfillment_loss + } + } + } + on_accept = { scope:actor = { - stress_impact = { + stress_and_fulfillment_impact = { honest = minor_stress_impact_gain just = minor_stress_impact_gain } @@ -5209,7 +6867,7 @@ elope_interaction = { } show_as_tooltip = { - stress_impact = { + stress_and_fulfillment_impact = { honest = minor_stress_impact_gain just = minor_stress_impact_gain } @@ -5231,5 +6889,14 @@ elope_interaction = { ai_will_do = { base = 100 + + #Promised to abstain from sin + modifier = { + OR = { + has_character_modifier = pam_granted_indulgences_modifier + has_character_modifier = pam_granted_indulgences_modifier_small + } + factor = 0.1 + } } } diff --git a/common/character_interactions/00_modifiy_vassal_contract.txt b/common/character_interactions/00_modifiy_vassal_contract.txt index bb6cbe595..a2536eaa5 100644 --- a/common/character_interactions/00_modifiy_vassal_contract.txt +++ b/common/character_interactions/00_modifiy_vassal_contract.txt @@ -14,38 +14,38 @@ is_shown = { scope:recipient = { - this != scope:actor - liege = scope:actor + this != scope:puppet_or_actor + liege ?= scope:puppet_or_actor is_tributary = no # this excludes tributary contracts by default is_ruler = yes vassal_contract_has_modifiable_obligations = yes - NOT = { government_allows = administrative } + NOT = { government_has_mechanic = administrative } NOT = { government_has_flag = government_is_nomadic } } } is_valid_showing_failures_only = { - NOT = { scope:actor = { is_at_war_with = scope:recipient } } + NOT = { scope:puppet_or_actor = { is_at_war_with = scope:recipient } } } can_send = { #Mandala gets special treatment trigger_if = { limit = { - scope:actor = { government_has_flag = government_is_mandala } + scope:puppet_or_actor = { government_has_flag = government_is_mandala } } custom_tooltip = { text = liege_modify_vassal_contract_mandala_cooldown NOT = { - scope:recipient = { var:liege_recently_adjusted_mandala_vassal_contract ?= scope:actor } + scope:recipient = { var:liege_recently_adjusted_mandala_vassal_contract ?= scope:puppet_or_actor } } } - scope:actor = { + scope:puppet_or_actor = { has_changed_contract_obligation_trigger = yes custom_description = { text = "liege_modify_vassal_contract_cannot_exceed_tyranny_cap" - object = scope:actor + object = scope:puppet_or_actor NOT = { vassal_obligation_increase_tyranny_gain_multiplier > 1 } @@ -95,12 +95,12 @@ } } trigger_else = { - scope:actor = { + scope:puppet_or_actor = { has_changed_contract_obligation_trigger = yes custom_description = { text = "liege_modify_vassal_contract_cannot_exceed_tyranny_cap" - object = scope:actor + object = scope:puppet_or_actor NOT = { vassal_obligation_increase_tyranny_gain_multiplier > 1 } @@ -148,7 +148,7 @@ # if = { # limit = { # catalyst_granted_powerful_diff_faith_vassal_religious_protection_preliminary_trigger = { CHAR = scope:recipient } -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # involvement = involved # activate_struggle_catalyst_secondary_character_involvement_involved_trigger = { @@ -158,7 +158,7 @@ # } # } # } -# scope:actor = { +# scope:puppet_or_actor = { # every_character_struggle = { # involvement = involved # limit = { @@ -169,7 +169,7 @@ # } # activate_struggle_catalyst = { # catalyst = catalyst_granted_powerful_diff_faith_vassal_religious_protection -# character = scope:actor +# character = scope:puppet_or_actor # } # } # } @@ -177,7 +177,7 @@ # if = { # limit = { # catalyst_revoked_powerful_diff_faith_vassal_religious_protection_preliminary_trigger = { CHAR = scope:recipient } -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # involvement = involved # activate_struggle_catalyst_secondary_character_involvement_involved_trigger = { @@ -187,7 +187,7 @@ # } # } # } -# scope:actor = { +# scope:puppet_or_actor = { # every_character_struggle = { # involvement = involved # limit = { @@ -198,7 +198,7 @@ # } # activate_struggle_catalyst = { # catalyst = catalyst_revoked_powerful_diff_faith_vassal_religious_protection -# character = scope:actor +# character = scope:puppet_or_actor # } # } # } @@ -208,7 +208,7 @@ # if = { # limit = { # scope:recipient.count_obligation_improvements_for_vassal > 0 -# scope:actor = { +# scope:puppet_or_actor = { # is_diff_faith_or_culture_trigger = { # CHAR = scope:recipient # STATUS = involved @@ -222,7 +222,7 @@ # } # } # } -# scope:actor = { +# scope:puppet_or_actor = { # every_character_struggle = { # involvement = involved # limit = { @@ -233,7 +233,7 @@ # } # activate_struggle_catalyst = { # catalyst = catalyst_grant_privilege_to_diff_faith_culture_vassal -# character = scope:actor +# character = scope:puppet_or_actor # } # } # } @@ -241,7 +241,7 @@ # } # Enact changes. - scope:actor = { + scope:puppet_or_actor = { send_interface_message = { type = msg_vassal_contract_change title = modify_vassal_contract_interaction_notification @@ -250,7 +250,7 @@ add_tyranny = vassal_obligation_increase_tyranny_gain if = { limit = { vassal_obligation_increase_tyranny_gain != 0 } - stress_impact = { + stress_and_fulfillment_impact = { just = medium_stress_impact_gain generous = medium_stress_impact_gain } @@ -269,7 +269,7 @@ } set_variable = { name = liege_recently_adjusted_mandala_vassal_contract - value = scope:actor + value = scope:puppet_or_actor years = mandala_vassal_obligation_cooldown_years } } @@ -296,7 +296,7 @@ send_option = { is_valid = { - scope:actor = { + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } @@ -304,7 +304,7 @@ localization = SCHEME_HOOK } should_use_extra_icon = { - scope:actor = { has_usable_hook = scope:recipient } + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } extra_icon = "gfx/interface/icons/character_interactions/hook_icon.dds" @@ -312,7 +312,7 @@ } vassal_modify_vassal_contract_interaction = { - special_interaction = liege_modify_vassal_contract + special_interaction = vassal_modify_vassal_contract interface = modify_vassal_contract category = interaction_category_vassal common_interaction = yes @@ -324,54 +324,40 @@ vassal_modify_vassal_contract_interaction = { force_notification = yes notification_text = MODIFY_VASSAL_CONTRACT_NOTIFICATION_TO_LIEGE - redirect = { - # need to reverse the role for the UI to work properly - scope:recipient = { - save_scope_as = secondary_recipient - } - scope:actor = { - save_scope_as = recipient - } - - scope:secondary_recipient = { - save_scope_as = actor - } - } - is_shown = { - scope:recipient = { - liege = scope:actor - this != scope:actor + scope:puppet_or_actor = { + liege ?= scope:recipient + this != scope:recipient is_tributary = no # this excludes tributary contracts by default vassal_contract_has_modifiable_obligations = yes NOR = { - government_allows = administrative + government_has_mechanic = administrative government_has_flag = government_is_nomadic } } } is_valid_showing_failures_only = { - NOT = { scope:recipient = { is_at_war_with = scope:actor } } + NOT = { scope:recipient = { is_at_war_with = scope:puppet_or_actor } } } can_send = { #Mandala gets special treatment trigger_if = { limit = { - scope:recipient = { government_has_flag = government_is_mandala } + scope:puppet_or_actor = { government_has_flag = government_is_mandala } } custom_tooltip = { text = vassal_modify_vassal_contract_mandala_cooldown NOT = { - scope:actor = { var:vassal_recently_adjusted_mandala_vassal_contract ?= scope:recipient } + scope:puppet_or_actor = { var:vassal_recently_adjusted_mandala_vassal_contract ?= scope:recipient } } } - scope:actor = { + scope:puppet_or_actor = { has_changed_contract_obligation_trigger = yes } - scope:recipient = { + scope:puppet_or_actor = { # Must be an even trade overall trigger_if = { limit = { @@ -379,7 +365,7 @@ vassal_modify_vassal_contract_interaction = { } custom_description = { text = "vassal_modify_vassal_contract_cannot_increase_obligation_level" - object = scope:actor + object = scope:recipient value = count_obligation_improvements_for_vassal_include_hook count_obligation_improvements_for_vassal_include_hook = 0 } @@ -396,20 +382,20 @@ vassal_modify_vassal_contract_interaction = { #The rest trigger_else_if = { #If you're blocked we don't want to show anything else limit = { - scope:recipient = { + scope:puppet_or_actor = { subject_contract_is_blocked_from_modification = yes } } - scope:recipient = { + scope:puppet_or_actor = { subject_contract_is_blocked_from_modification = no } } trigger_else = { - scope:actor = { + scope:puppet_or_actor = { has_changed_contract_obligation_trigger = yes } - scope:recipient = { + scope:puppet_or_actor = { # Must be an even trade overall trigger_if = { limit = { @@ -417,7 +403,7 @@ vassal_modify_vassal_contract_interaction = { } custom_description = { text = "vassal_modify_vassal_contract_cannot_increase_obligation_level" - object = scope:actor + object = scope:recipient value = count_obligation_improvements_for_vassal_include_hook count_obligation_improvements_for_vassal_include_hook = 0 } @@ -437,14 +423,14 @@ vassal_modify_vassal_contract_interaction = { on_accept = { # Enact changes. - scope:recipient = { + scope:puppet_or_actor = { send_interface_message = { type = msg_vassal_contract_change title = modify_vassal_contract_interaction_notification - right_icon = scope:actor + right_icon = scope:recipient if = { limit = { always = scope:hook } - use_hook = scope:actor + use_hook = scope:recipient add_achievement_flag_effect = { FLAG = achievement_fine_print_flag } } @@ -455,7 +441,7 @@ vassal_modify_vassal_contract_interaction = { save_scope_as = obligation - scope:recipient = { + scope:puppet_or_actor = { vassal_contract_set_obligation_level = { type = scope:obligation.vassal_contract_type level = scope:obligation @@ -464,7 +450,7 @@ vassal_modify_vassal_contract_interaction = { } } } - scope:actor = { + scope:puppet_or_actor = { set_variable = { name = vassal_recently_adjusted_mandala_vassal_contract value = scope:recipient @@ -474,43 +460,43 @@ vassal_modify_vassal_contract_interaction = { # If there's a diarch involved, and they called in their change, that gets flagged. diarch_changed_own_contract_effect = yes - hidden_effect = { - # Struggle Catalysts - ## We work these out first so they're not invalidated by the actual effect block. - if = { - limit = { - catalyst_granted_powerful_diff_faith_vassal_religious_protection_preliminary_trigger = { CHAR = scope:recipient } - scope:actor = { - any_character_struggle = { - involvement = involved - activate_struggle_catalyst_secondary_character_involvement_involved_trigger = { - CATALYST = catalyst_granted_powerful_diff_faith_vassal_religious_protection - CHAR = scope:recipient - } - } - } - } - scope:actor = { - every_character_struggle = { - involvement = involved - limit = { - activate_struggle_catalyst_secondary_character_involvement_involved_trigger = { - CATALYST = catalyst_granted_powerful_diff_faith_vassal_religious_protection - CHAR = scope:recipient - } - } - activate_struggle_catalyst = { - catalyst = catalyst_granted_powerful_diff_faith_vassal_religious_protection - character = scope:recipient - } - } - } - } - # Improving contract catalyst +# hidden_effect = { +# # Struggle Catalysts +# ## We work these out first so they're not invalidated by the actual effect block. +# if = { +# limit = { +# catalyst_granted_powerful_diff_faith_vassal_religious_protection_preliminary_trigger = { CHAR = scope:puppet_or_actor } +# scope:recipient = { +# any_character_struggle = { +# involvement = involved +# activate_struggle_catalyst_secondary_character_involvement_involved_trigger = { +# CATALYST = catalyst_granted_powerful_diff_faith_vassal_religious_protection +# CHAR = scope:puppet_or_actor +# } +# } +# } +# } +# scope:recipient = { +# every_character_struggle = { +# involvement = involved +# limit = { +# activate_struggle_catalyst_secondary_character_involvement_involved_trigger = { +# CATALYST = catalyst_granted_powerful_diff_faith_vassal_religious_protection +# CHAR = scope:puppet_or_actor +# } +# } +# activate_struggle_catalyst = { +# catalyst = catalyst_granted_powerful_diff_faith_vassal_religious_protection +# character = scope:recipient +# } +# } +# } +# } +# # Improving contract catalyst # if = { # limit = { # scope:recipient.count_obligation_improvements_for_vassal > 0 -# scope:actor = { +# scope:puppet_or_actor = { # is_diff_faith_or_culture_trigger = { # CHAR = scope:recipient # STATUS = involved @@ -524,7 +510,7 @@ vassal_modify_vassal_contract_interaction = { # } # } # } -# scope:actor = { +# scope:puppet_or_actor = { # every_character_struggle = { # involvement = involved # limit = { @@ -535,21 +521,21 @@ vassal_modify_vassal_contract_interaction = { # } # activate_struggle_catalyst = { # catalyst = catalyst_grant_privilege_to_diff_faith_culture_vassal -# character = scope:actor +# character = scope:puppet_or_actor # } # } # } # } - } +# } # Additional Flavor Titles - scope:recipient = { additional_flavor_check_effect = yes } + scope:puppet_or_actor = { additional_flavor_check_effect = yes } } send_option = { is_valid = { - scope:recipient = { - has_usable_hook = scope:actor + scope:puppet_or_actor = { + has_usable_hook = scope:recipient } } flag = hook @@ -557,28 +543,28 @@ vassal_modify_vassal_contract_interaction = { } send_option = { is_shown = { - scope:recipient = { is_diarch_of_target = scope:actor } - scope:actor = { has_diarchy_parameter = diarch_gets_a_free_change_on_vassal_contract } + scope:puppet_or_actor = { is_diarch_of_target = scope:recipient } + scope:recipient = { has_diarchy_parameter = diarch_gets_a_free_change_on_vassal_contract } } is_valid = { - scope:recipient = { + scope:puppet_or_actor = { trigger_if = { limit = { has_variable_list = diarch_contract_rights_used_list } NOT = { is_target_in_variable_list = { name = diarch_contract_rights_used_list - target = scope:actor + target = scope:recipient } } } } - scope:actor = { has_diarchy_active_parameter = diarch_gets_a_free_change_on_vassal_contract } + scope:recipient = { has_diarchy_active_parameter = diarch_gets_a_free_change_on_vassal_contract } } flag = diarch localization = CALL_IN_DIARCH_RIGHTS } should_use_extra_icon = { - scope:recipient = { has_usable_hook = scope:actor } + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } extra_icon = "gfx/interface/icons/character_interactions/hook_icon.dds" send_options_exclusive = no @@ -591,14 +577,23 @@ ai_only_liege_modify_vassal_contract_interaction = { auto_accept = yes + is_available = { + trigger_if = { + limit = { + NOT = { government_has_mechanic = administrative } + } + is_at_war = no + } + is_ai = yes + } + is_shown = { scope:actor = { - is_ai = yes has_usable_hook = scope:recipient } scope:recipient = { this != scope:actor - liege = scope:actor + liege ?= scope:actor NOT = { has_strong_hook = scope:actor } @@ -612,7 +607,7 @@ ai_only_liege_modify_vassal_contract_interaction = { on_accept = { scope:actor = { - stress_impact = { + stress_and_fulfillment_impact = { generous = minor_stress_impact_gain } } @@ -626,15 +621,6 @@ ai_only_liege_modify_vassal_contract_interaction = { scope:recipient = { additional_flavor_check_effect = yes } } - ai_potential = { - trigger_if = { - limit = { - NOT = { government_allows = administrative } - } - is_at_war = no - } - } - ai_targets = { ai_recipients = vassals } @@ -677,9 +663,14 @@ ai_only_liege_modify_vassal_contract_admin_province_interaction = { auto_accept = yes + is_available = { + # This also blocks non-admin govs with admin vassals from changing province obligations... but we're OK with that. + government_has_flag = government_uses_admin_province_obligations + is_ai = yes + } + is_shown = { scope:actor = { - is_ai = yes AND = { government_has_flag = government_uses_admin_province_obligations scope:recipient = { government_has_flag = government_uses_admin_province_obligations } @@ -687,13 +678,14 @@ ai_only_liege_modify_vassal_contract_admin_province_interaction = { } scope:recipient = { this != scope:actor - liege = scope:actor + liege ?= scope:actor is_tributary = no NOT = { has_strong_hook = scope:actor } is_ruler = yes government_has_flag = government_uses_admin_province_obligations + NOT = { has_variable = admin_contract_cooldown } does_ai_liege_in_vassal_contract_desire_admin_province_obligation_change = yes } @@ -702,13 +694,18 @@ ai_only_liege_modify_vassal_contract_admin_province_interaction = { on_accept = { scope:actor = { - stress_impact = { + stress_and_fulfillment_impact = { generous = minor_stress_impact_gain } } scope:recipient = { trigger_event = char_interaction.0253 + set_variable = { + name = admin_contract_cooldown + value = yes + years = admin_contract_cooldown_value + } } # Additional Flavor Titles @@ -729,11 +726,6 @@ ai_only_liege_modify_vassal_contract_admin_province_interaction = { hegemony = 3 } - is_available = { - # This also blocks non-admin govs with admin vassals from changing province obligations... but we're OK with that. - government_has_flag = government_uses_admin_province_obligations - } - ai_will_do = { base = 100 } @@ -746,15 +738,18 @@ ai_only_vassal_modify_vassal_contract_interaction = { auto_accept = yes + is_available = { + top_liege != this + vassal_contract_can_be_modified_trigger = yes + does_ai_vassal_in_vassal_contract_desire_obligation_change = yes + is_ai = yes + is_tributary = no # this excludes tributary contracts by default + } + is_shown = { scope:actor = { - is_ai = yes - top_liege != this has_usable_hook = scope:recipient - vassal_contract_can_be_modified_trigger = yes - does_ai_vassal_in_vassal_contract_desire_obligation_change = yes - is_tributary = no # this excludes tributary contracts by default - liege = scope:recipient + liege ?= scope:recipient } scope:recipient = { this != scope:actor @@ -775,10 +770,6 @@ ai_only_vassal_modify_vassal_contract_interaction = { scope:recipient = { additional_flavor_check_effect = yes } } - ai_potential = { - always = yes - } - ai_targets = { ai_recipients = liege } @@ -829,16 +820,16 @@ admin_liege_modify_vassal_contract_interaction = { is_shown = { scope:recipient = { - this != scope:actor - liege = scope:actor + this != scope:puppet_or_actor + liege ?= scope:puppet_or_actor OR = { is_landed = yes - is_councillor_of = scope:actor.top_liege + is_councillor_of = scope:puppet_or_actor.top_liege } is_tributary = no # this excludes tributary contracts by default is_ruler = yes vassal_contract_has_modifiable_obligations = yes - government_allows = administrative + government_has_mechanic = administrative any_held_title = { OR = { tier >= holder.main_administrative_tier @@ -850,7 +841,7 @@ admin_liege_modify_vassal_contract_interaction = { } is_valid_showing_failures_only = { - scope:actor = { + scope:puppet_or_actor = { NOT = { is_at_war_with = scope:recipient } tgp_is_ceremonial_liege_trigger = no } @@ -883,7 +874,7 @@ admin_liege_modify_vassal_contract_interaction = { } } trigger_else = { - scope:actor = { + scope:puppet_or_actor = { has_changed_contract_obligation_trigger = yes } } @@ -898,7 +889,7 @@ admin_liege_modify_vassal_contract_interaction = { # if = { # limit = { # catalyst_granted_powerful_diff_faith_vassal_religious_protection_preliminary_trigger = { CHAR = scope:recipient } -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # involvement = involved # activate_struggle_catalyst_secondary_character_involvement_involved_trigger = { @@ -908,7 +899,7 @@ admin_liege_modify_vassal_contract_interaction = { # } # } # } -# scope:actor = { +# scope:puppet_or_actor = { # every_character_struggle = { # involvement = involved # limit = { @@ -919,7 +910,7 @@ admin_liege_modify_vassal_contract_interaction = { # } # activate_struggle_catalyst = { # catalyst = catalyst_granted_powerful_diff_faith_vassal_religious_protection -# character = scope:actor +# character = scope:puppet_or_actor # } # } # } @@ -927,7 +918,7 @@ admin_liege_modify_vassal_contract_interaction = { # if = { # limit = { # catalyst_revoked_powerful_diff_faith_vassal_religious_protection_preliminary_trigger = { CHAR = scope:recipient } -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # involvement = involved # activate_struggle_catalyst_secondary_character_involvement_involved_trigger = { @@ -937,7 +928,7 @@ admin_liege_modify_vassal_contract_interaction = { # } # } # } -# scope:actor = { +# scope:puppet_or_actor = { # every_character_struggle = { # involvement = involved # limit = { @@ -948,7 +939,7 @@ admin_liege_modify_vassal_contract_interaction = { # } # activate_struggle_catalyst = { # catalyst = catalyst_revoked_powerful_diff_faith_vassal_religious_protection -# character = scope:actor +# character = scope:puppet_or_actor # } # } # } @@ -956,42 +947,42 @@ admin_liege_modify_vassal_contract_interaction = { # # # Improving contract catalyst # if = { -## limit = { -## scope:recipient.count_obligation_improvements_for_vassal > 0 -## scope:actor = { -## is_diff_faith_or_culture_trigger = { -## CHAR = scope:recipient -## STATUS = involved -## } -## any_character_struggle = { -## involvement = involved -## activate_struggle_catalyst_secondary_character_involvement_involved_trigger = { -## CATALYST = catalyst_grant_privilege_to_diff_faith_culture_vassal -## CHAR = scope:recipient -## } -## } -## } -## } -## scope:actor = { -## every_character_struggle = { -## involvement = involved -## limit = { -## activate_struggle_catalyst_secondary_character_involvement_involved_trigger = { -## CATALYST = catalyst_grant_privilege_to_diff_faith_culture_vassal -## CHAR = scope:recipient -## } -## } -## activate_struggle_catalyst = { -## catalyst = catalyst_grant_privilege_to_diff_faith_culture_vassal -## character = scope:actor -## } -## } -## } -## } +# limit = { +# scope:recipient.count_obligation_improvements_for_vassal > 0 +# scope:puppet_or_actor = { +# is_diff_faith_or_culture_trigger = { +# CHAR = scope:recipient +# STATUS = involved +# } +# any_character_struggle = { +# involvement = involved +# activate_struggle_catalyst_secondary_character_involvement_involved_trigger = { +# CATALYST = catalyst_grant_privilege_to_diff_faith_culture_vassal +# CHAR = scope:recipient +# } +# } +# } +# } +# scope:puppet_or_actor = { +# every_character_struggle = { +# involvement = involved +# limit = { +# activate_struggle_catalyst_secondary_character_involvement_involved_trigger = { +# CATALYST = catalyst_grant_privilege_to_diff_faith_culture_vassal +# CHAR = scope:recipient +# } +# } +# activate_struggle_catalyst = { +# catalyst = catalyst_grant_privilege_to_diff_faith_culture_vassal +# character = scope:puppet_or_actor +# } +# } +# } +# } # } # Enact changes. - scope:actor = { + scope:puppet_or_actor = { send_interface_message = { type = msg_vassal_contract_change title = modify_vassal_contract_interaction_notification @@ -1026,21 +1017,14 @@ admin_liege_modify_vassal_contract_interaction = { } if = { limit = { - OR = { - vassal_contract_has_flag = celestial_province_military - vassal_contract_has_flag = celestial_province_protectorate - } + vassal_contract_has_flag = celestial_military_appointment NOT = { has_realm_law = celestial_military_appointment_succession_law } } add_realm_law_skip_effects = celestial_military_appointment_succession_law } else_if = { limit = { - OR = { - vassal_contract_has_flag = celestial_province_standard - vassal_contract_has_flag = celestial_province_industrial - vassal_contract_has_flag = celestial_province_metropolitan - } + vassal_contract_has_flag = celestial_civil_appointment NOT = { has_realm_law = celestial_appointment_succession_law } } add_realm_law_skip_effects = celestial_appointment_succession_law @@ -1049,22 +1033,22 @@ admin_liege_modify_vassal_contract_interaction = { # Update the succession law for meritocratic province types if applicable - That way, we don't have to wait until the current law invalidates. else_if = { limit = { - government_has_flag = government_is_meritocratic + OR = { + government_has_flag = government_is_meritocratic + government_has_flag = government_is_steppe_admin + } scope:obligation.vassal_contract_type = vassal_contract:meritocratic_provinces } if = { limit = { - vassal_contract_has_flag = meritocratic_province_military + vassal_contract_has_flag = meritocratic_military_appointment NOT = { has_realm_law = meritocratic_military_appointment_succession_law } } add_realm_law_skip_effects = meritocratic_military_appointment_succession_law } else_if = { limit = { - OR = { - vassal_contract_has_flag = meritocratic_province_standard - vassal_contract_has_flag = meritocratic_province_industrial - } + vassal_contract_has_flag = meritocratic_civil_appointment NOT = { has_realm_law = meritocratic_appointment_succession_law } } add_realm_law_skip_effects = meritocratic_appointment_succession_law @@ -1073,7 +1057,7 @@ admin_liege_modify_vassal_contract_interaction = { # Update the succession law for japanese province types if applicable - That way, we don't have to wait until the current law invalidates. else_if = { limit = { - government_has_flag = government_is_japanese_administrative + government_has_flag = government_is_japan_administrative scope:obligation.vassal_contract_type = vassal_contract:japan_administrative_provinces } if = { @@ -1115,21 +1099,22 @@ admin_vassal_modify_vassal_contract_interaction = { send_name = "admin_vassal_modify_vassal_contract_interaction_send" desc = admin_vassal_modify_vassal_contract_interaction_desc + notification_text = MODIFY_VASSAL_CONTRACT_NOTIFICATION_TO_LIEGE is_shown = { - scope:actor = { - top_liege != this - this != scope:recipient - liege = scope:recipient - is_tributary = no # this excludes tributary contracts by default + scope:puppet_or_actor = { + government_has_mechanic = administrative vassal_contract_has_modifiable_obligations = yes - government_allows = administrative tgp_is_ceremonial_liege_trigger = no + top_liege != this + is_tributary = no # this excludes tributary contracts by default + this != scope:recipient + liege ?= scope:recipient } } is_valid_showing_failures_only = { - scope:actor = { + scope:puppet_or_actor = { custom_tooltip = { text = admin_vassal_not_holding_a_theme_desc any_held_title = { @@ -1147,11 +1132,11 @@ admin_vassal_modify_vassal_contract_interaction = { can_send = { trigger_if = { #If you're blocked we don't want to show anything else (we don't really use this for admin, but we'll keep the logic, just in case) limit = { - scope:actor = { + scope:puppet_or_actor = { subject_contract_is_blocked_from_modification = yes } } - scope:actor = { + scope:puppet_or_actor = { subject_contract_is_blocked_from_modification = no } } @@ -1159,13 +1144,13 @@ admin_vassal_modify_vassal_contract_interaction = { # There is no cooldown present - To make sure we somehow don't show both cooldowns at the same time, we split them into separate triggers trigger_if = { limit = { - scope:actor = { + scope:puppet_or_actor = { has_variable = admin_contract_cooldown } } custom_tooltip = { text = admin_contract_cooldown_desc_vassal - scope:actor = { + scope:puppet_or_actor = { NOT = { has_variable = admin_contract_cooldown } } } @@ -1173,11 +1158,11 @@ admin_vassal_modify_vassal_contract_interaction = { trigger_else = { custom_tooltip = { text = admin_contract_request_cooldown_desc - scope:actor = { + scope:puppet_or_actor = { NOT = { has_variable = admin_contract_request_cooldown } } } - scope:actor = { + scope:puppet_or_actor = { has_changed_contract_obligation_trigger = yes } } @@ -1190,7 +1175,7 @@ admin_vassal_modify_vassal_contract_interaction = { scope:dominant_family = yes } } - scope:actor = { + scope:puppet_or_actor = { influence >= major_influence_value } } @@ -1210,7 +1195,7 @@ admin_vassal_modify_vassal_contract_interaction = { on_accept = { # Enact changes - scope:actor = { + scope:puppet_or_actor = { send_interface_message = { type = msg_vassal_contract_change title = modify_vassal_contract_interaction_notification @@ -1233,7 +1218,7 @@ admin_vassal_modify_vassal_contract_interaction = { scope:diarch = yes } } - scope:actor = { + scope:puppet_or_actor = { change_influence = major_influence_loss } } @@ -1252,7 +1237,7 @@ admin_vassal_modify_vassal_contract_interaction = { save_scope_as = obligation - scope:actor = { + scope:puppet_or_actor = { vassal_contract_set_obligation_level = { type = scope:obligation.vassal_contract_type level = scope:obligation @@ -1267,21 +1252,14 @@ admin_vassal_modify_vassal_contract_interaction = { if = { limit = { - OR = { - vassal_contract_has_flag = celestial_province_military - vassal_contract_has_flag = celestial_province_protectorate - } + vassal_contract_has_flag = celestial_military_appointment NOT = { has_realm_law = celestial_military_appointment_succession_law } } add_realm_law_skip_effects = celestial_military_appointment_succession_law } else_if = { limit = { - OR = { - vassal_contract_has_flag = celestial_province_standard - vassal_contract_has_flag = celestial_province_industrial - vassal_contract_has_flag = celestial_province_metropolitan - } + vassal_contract_has_flag = celestial_civil_appointment NOT = { has_realm_law = celestial_appointment_succession_law } } add_realm_law_skip_effects = celestial_appointment_succession_law @@ -1290,22 +1268,22 @@ admin_vassal_modify_vassal_contract_interaction = { # Update the succession law for meritocratic province types if applicable - That way, we don't have to wait until the current law invalidates. else_if = { limit = { - government_has_flag = government_is_meritocratic + OR = { + government_has_flag = government_is_meritocratic + government_has_flag = government_is_steppe_admin + } scope:obligation.vassal_contract_type = vassal_contract:meritocratic_provinces } if = { limit = { - vassal_contract_has_flag = meritocratic_province_military + vassal_contract_has_flag = meritocratic_military_appointment NOT = { has_realm_law = meritocratic_military_appointment_succession_law } } add_realm_law_skip_effects = meritocratic_military_appointment_succession_law } else_if = { limit = { - OR = { - vassal_contract_has_flag = meritocratic_province_standard - vassal_contract_has_flag = meritocratic_province_industrial - } + vassal_contract_has_flag = meritocratic_civil_appointment NOT = { has_realm_law = meritocratic_appointment_succession_law } } add_realm_law_skip_effects = meritocratic_appointment_succession_law @@ -1314,7 +1292,7 @@ admin_vassal_modify_vassal_contract_interaction = { # Update the succession law for japanese province types if applicable - That way, we don't have to wait until the current law invalidates. else_if = { limit = { - government_has_flag = government_is_japanese_administrative + government_has_flag = government_is_japan_administrative scope:obligation.vassal_contract_type = vassal_contract:japan_administrative_provinces } if = { @@ -1340,52 +1318,52 @@ admin_vassal_modify_vassal_contract_interaction = { # If there's a diarch involved, and they called in their change, that gets flagged. diarch_changed_own_contract_effect = yes - hidden_effect = { - # Struggle Catalysts - ## We work these out first so they're not invalidated by the actual effect block. - if = { - limit = { - catalyst_granted_powerful_diff_faith_vassal_religious_protection_preliminary_trigger = { CHAR = scope:recipient } - scope:recipient = { - any_character_struggle = { - involvement = involved - activate_struggle_catalyst_secondary_character_involvement_involved_trigger = { - CATALYST = catalyst_granted_powerful_diff_faith_vassal_religious_protection - CHAR = scope:actor - } - } - } - } - scope:recipient = { - every_character_struggle = { - involvement = involved - limit = { - activate_struggle_catalyst_secondary_character_involvement_involved_trigger = { - CATALYST = catalyst_granted_powerful_diff_faith_vassal_religious_protection - CHAR = scope:actor - } - } - activate_struggle_catalyst = { - catalyst = catalyst_granted_powerful_diff_faith_vassal_religious_protection - character = scope:actor - } - } - } - } - # Improving contract catalyst +# hidden_effect = { +# # Struggle Catalysts +# ## We work these out first so they're not invalidated by the actual effect block. # if = { # limit = { -# scope:actor.count_obligation_improvements_for_vassal > 0 +# catalyst_granted_powerful_diff_faith_vassal_religious_protection_preliminary_trigger = { CHAR = scope:recipient } +# scope:recipient = { +# any_character_struggle = { +# involvement = involved +# activate_struggle_catalyst_secondary_character_involvement_involved_trigger = { +# CATALYST = catalyst_granted_powerful_diff_faith_vassal_religious_protection +# CHAR = scope:puppet_or_actor +# } +# } +# } +# } +# scope:recipient = { +# every_character_struggle = { +# involvement = involved +# limit = { +# activate_struggle_catalyst_secondary_character_involvement_involved_trigger = { +# CATALYST = catalyst_granted_powerful_diff_faith_vassal_religious_protection +# CHAR = scope:puppet_or_actor +# } +# } +# activate_struggle_catalyst = { +# catalyst = catalyst_granted_powerful_diff_faith_vassal_religious_protection +# character = scope:recipient +# } +# } +# } +# } +# # Improving contract catalyst +# if = { +# limit = { +# scope:puppet_or_actor.count_obligation_improvements_for_vassal > 0 # scope:recipient = { # is_diff_faith_or_culture_trigger = { -# CHAR = scope:actor +# CHAR = scope:puppet_or_actor # STATUS = involved # } # any_character_struggle = { # involvement = involved # activate_struggle_catalyst_secondary_character_involvement_involved_trigger = { # CATALYST = catalyst_grant_privilege_to_diff_faith_culture_vassal -# CHAR = scope:actor +# CHAR = scope:puppet_or_actor # } # } # } @@ -1396,7 +1374,7 @@ admin_vassal_modify_vassal_contract_interaction = { # limit = { # activate_struggle_catalyst_secondary_character_involvement_involved_trigger = { # CATALYST = catalyst_grant_privilege_to_diff_faith_culture_vassal -# CHAR = scope:actor +# CHAR = scope:puppet_or_actor # } # } # activate_struggle_catalyst = { @@ -1406,13 +1384,13 @@ admin_vassal_modify_vassal_contract_interaction = { # } # } # } - } +# } } on_decline = { # Activate cooldown - You may only ask for it to be changed every so often (this mostly exists for MP, since you cannot send it to the AI unless they accept) hidden_effect = { - scope:actor = { + scope:puppet_or_actor = { set_variable = { name = admin_contract_request_cooldown value = yes @@ -1426,7 +1404,7 @@ admin_vassal_modify_vassal_contract_interaction = { # Hook send_option = { is_valid = { - scope:actor = { + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } @@ -1436,7 +1414,7 @@ admin_vassal_modify_vassal_contract_interaction = { # Dominant Family send_option = { is_shown = { - scope:actor = { + scope:puppet_or_actor = { house ?= { is_dominant_family = yes } } } @@ -1446,10 +1424,10 @@ admin_vassal_modify_vassal_contract_interaction = { # Diarch send_option = { is_shown = { - scope:actor = { is_diarch_of_target = scope:recipient } + scope:puppet_or_actor = { is_diarch_of_target = scope:recipient } } is_valid = { - scope:actor = { + scope:puppet_or_actor = { trigger_if = { limit = { has_variable_list = diarch_contract_rights_used_list } NOT = { @@ -1465,7 +1443,7 @@ admin_vassal_modify_vassal_contract_interaction = { localization = CALL_IN_DIARCH_RIGHTS } should_use_extra_icon = { - scope:actor = { has_usable_hook = scope:recipient } + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } extra_icon = "gfx/interface/icons/character_interactions/hook_icon.dds" send_options_exclusive = no @@ -1476,20 +1454,20 @@ admin_vassal_modify_vassal_contract_interaction = { # Opinion Factor opinion_modifier = { who = scope:recipient - opinion_target = scope:actor + opinion_target = scope:puppet_or_actor multiplier = 1 desc = AI_OPINION_REASON } # Governor efficiency - Skilled governors are more likely to get accepted modifier = { - add = scope:actor.governor_efficiency_presented + add = scope:puppet_or_actor.governor_efficiency_presented desc = AI_GOVERNOR_EFFICIENCY } # Members of a powerful family are more likely to get accepted modifier = { - scope:actor = { + scope:puppet_or_actor = { house ?= { is_powerful_family = yes } NOT = { house ?= scope:recipient.house } } @@ -1499,7 +1477,7 @@ admin_vassal_modify_vassal_contract_interaction = { # Members of the emperors family are much more likely to get accepted modifier = { - scope:actor = { + scope:puppet_or_actor = { house ?= scope:recipient.house } add = 60 @@ -1524,8 +1502,8 @@ nomad_liege_modify_vassal_contract_interaction = { is_shown = { scope:recipient = { - this != scope:actor - liege = scope:actor + this != scope:puppet_or_actor + liege ?= scope:puppet_or_actor is_tributary = no # this excludes tributary contracts by default is_ruler = yes vassal_contract_has_modifiable_obligations = yes @@ -1534,7 +1512,7 @@ nomad_liege_modify_vassal_contract_interaction = { } is_valid_showing_failures_only = { - NOT = { scope:actor = { is_at_war_with = scope:recipient } } + NOT = { scope:puppet_or_actor = { is_at_war_with = scope:recipient } } } can_send = { @@ -1549,12 +1527,12 @@ nomad_liege_modify_vassal_contract_interaction = { } } trigger_else = { - scope:actor = { + scope:puppet_or_actor = { has_changed_contract_obligation_trigger = yes custom_description = { text = "liege_modify_vassal_contract_cannot_exceed_tyranny_cap" - object = scope:actor + object = scope:puppet_or_actor NOT = { vassal_obligation_increase_tyranny_gain_multiplier > 1 } @@ -1602,7 +1580,7 @@ nomad_liege_modify_vassal_contract_interaction = { # if = { # limit = { # catalyst_granted_powerful_diff_faith_vassal_religious_protection_preliminary_trigger = { CHAR = scope:recipient } -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # involvement = involved # activate_struggle_catalyst_secondary_character_involvement_involved_trigger = { @@ -1612,7 +1590,7 @@ nomad_liege_modify_vassal_contract_interaction = { # } # } # } -# scope:actor = { +# scope:puppet_or_actor = { # every_character_struggle = { # involvement = involved # limit = { @@ -1623,7 +1601,7 @@ nomad_liege_modify_vassal_contract_interaction = { # } # activate_struggle_catalyst = { # catalyst = catalyst_granted_powerful_diff_faith_vassal_religious_protection -# character = scope:actor +# character = scope:puppet_or_actor # } # } # } @@ -1631,7 +1609,7 @@ nomad_liege_modify_vassal_contract_interaction = { # if = { # limit = { # catalyst_revoked_powerful_diff_faith_vassal_religious_protection_preliminary_trigger = { CHAR = scope:recipient } -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # involvement = involved # activate_struggle_catalyst_secondary_character_involvement_involved_trigger = { @@ -1641,7 +1619,7 @@ nomad_liege_modify_vassal_contract_interaction = { # } # } # } -# scope:actor = { +# scope:puppet_or_actor = { # every_character_struggle = { # involvement = involved # limit = { @@ -1652,57 +1630,93 @@ nomad_liege_modify_vassal_contract_interaction = { # } # activate_struggle_catalyst = { # catalyst = catalyst_revoked_powerful_diff_faith_vassal_religious_protection -# character = scope:actor +# character = scope:puppet_or_actor # } # } # } # } # # # Improving contract catalyst -## if = { -## limit = { -## scope:recipient.count_obligation_improvements_for_vassal > 0 -## scope:actor = { -## is_diff_faith_or_culture_trigger = { -## CHAR = scope:recipient -## STATUS = involved -## } -## any_character_struggle = { -## involvement = involved -## activate_struggle_catalyst_secondary_character_involvement_involved_trigger = { -## CATALYST = catalyst_grant_privilege_to_diff_faith_culture_vassal -## CHAR = scope:recipient -## } -## } -## } -## } -## scope:actor = { -## every_character_struggle = { -## involvement = involved -## limit = { -## activate_struggle_catalyst_secondary_character_involvement_involved_trigger = { -## CATALYST = catalyst_grant_privilege_to_diff_faith_culture_vassal -## CHAR = scope:recipient -## } -## } -## activate_struggle_catalyst = { -## catalyst = catalyst_grant_privilege_to_diff_faith_culture_vassal -## character = scope:actor -## } -## } -## } -## } +# if = { +# limit = { +# scope:recipient.count_obligation_improvements_for_vassal > 0 +# scope:puppet_or_actor = { +# is_diff_faith_or_culture_trigger = { +# CHAR = scope:recipient +# STATUS = involved +# } +# any_character_struggle = { +# involvement = involved +# activate_struggle_catalyst_secondary_character_involvement_involved_trigger = { +# CATALYST = catalyst_grant_privilege_to_diff_faith_culture_vassal +# CHAR = scope:recipient +# } +# } +# } +# } +# scope:puppet_or_actor = { +# every_character_struggle = { +# involvement = involved +# limit = { +# activate_struggle_catalyst_secondary_character_involvement_involved_trigger = { +# CATALYST = catalyst_grant_privilege_to_diff_faith_culture_vassal +# CHAR = scope:recipient +# } +# } +# activate_struggle_catalyst = { +# catalyst = catalyst_grant_privilege_to_diff_faith_culture_vassal +# character = scope:puppet_or_actor +# } +# } +# } +# } +# +# # Improving contract catalyst +# if = { +# limit = { +# scope:recipient.count_obligation_improvements_for_vassal > 0 +# scope:puppet_or_actor = { +# is_diff_faith_or_culture_trigger = { +# CHAR = scope:recipient +# STATUS = involved +# } +# any_character_struggle = { +# involvement = involved +# activate_struggle_catalyst_secondary_character_involvement_involved_trigger = { +# CATALYST = catalyst_grant_privilege_to_diff_faith_culture_vassal +# CHAR = scope:recipient +# } +# } +# } +# } +# scope:puppet_or_actor = { +# every_character_struggle = { +# involvement = involved +# limit = { +# activate_struggle_catalyst_secondary_character_involvement_involved_trigger = { +# CATALYST = catalyst_grant_privilege_to_diff_faith_culture_vassal +# CHAR = scope:recipient +# } +# } +# activate_struggle_catalyst = { +# catalyst = catalyst_grant_privilege_to_diff_faith_culture_vassal +# character = scope:puppet_or_actor +# } +# } +# } +# } +# # } # Enact changes. - scope:actor = { + scope:puppet_or_actor = { send_interface_message = { type = msg_vassal_contract_change title = modify_vassal_contract_interaction_notification right_icon = scope:recipient if = { limit = { vassal_obligation_increase_tyranny_gain != 0 } - stress_impact = { + stress_and_fulfillment_impact = { just = medium_stress_impact_gain generous = medium_stress_impact_gain } @@ -1748,7 +1762,7 @@ nomad_liege_modify_vassal_contract_interaction = { send_option = { is_valid = { - scope:actor = { + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } @@ -1756,7 +1770,7 @@ nomad_liege_modify_vassal_contract_interaction = { localization = SCHEME_HOOK } should_use_extra_icon = { - scope:actor = { has_usable_hook = scope:recipient } + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } extra_icon = "gfx/interface/icons/character_interactions/hook_icon.dds" send_options_exclusive = no @@ -1773,25 +1787,11 @@ nomad_vassal_modify_vassal_contract_interaction = { send_name = "nomad_vassal_modify_vassal_contract_interaction_send" desc = nomad_vassal_modify_vassal_contract_interaction_desc - redirect = { - # need to reverse the role for the UI to work properly - scope:recipient = { - save_scope_as = secondary_recipient - } - scope:actor = { - save_scope_as = recipient - } - - scope:secondary_recipient = { - save_scope_as = actor - } - } - is_shown = { - scope:recipient = { + scope:puppet_or_actor = { is_independent_ruler = no - this != scope:actor - liege = scope:actor + this != scope:recipient + liege ?= scope:recipient is_tributary = no # this excludes tributary contracts by default vassal_contract_has_modifiable_obligations = yes government_has_flag = government_is_nomadic @@ -1799,17 +1799,17 @@ nomad_vassal_modify_vassal_contract_interaction = { } is_valid_showing_failures_only = { - NOT = { scope:recipient = { is_at_war_with = scope:actor } } + NOT = { scope:recipient = { is_at_war_with = scope:puppet_or_actor } } } can_send = { trigger_if = { #If you're blocked we don't want to show anything else limit = { - scope:recipient = { + scope:puppet_or_actor = { subject_contract_is_blocked_from_modification = yes } } - scope:recipient = { + scope:puppet_or_actor = { subject_contract_is_blocked_from_modification = no } } @@ -1817,13 +1817,13 @@ nomad_vassal_modify_vassal_contract_interaction = { # There is no cooldown present - To make sure we somehow don't show both cooldowns at the same time, we split them into separate triggers trigger_if = { limit = { - scope:actor = { + scope:puppet_or_actor = { has_variable = vassal_modify_contract_cooldown } } custom_tooltip = { text = vassal_modify_contract_cooldown_desc - scope:actor = { + scope:puppet_or_actor = { NOT = { has_variable = vassal_modify_contract_cooldown } } } @@ -1831,22 +1831,27 @@ nomad_vassal_modify_vassal_contract_interaction = { trigger_else = { custom_tooltip = { text = nomad_contract_request_cooldown_desc - scope:actor = { + scope:puppet_or_actor = { NOT = { has_variable = nomad_contract_request_cooldown } } } } - scope:actor = { + scope:puppet_or_actor = { has_changed_contract_obligation_trigger = yes } - scope:recipient = { + scope:puppet_or_actor = { # Must be an even trade overall - custom_description = { - text = "vassal_modify_vassal_contract_cannot_increase_obligation_level" - object = scope:actor - value = count_obligation_improvements_for_vassal_include_hook - count_obligation_improvements_for_vassal_include_hook = 0 + trigger_if = { + limit = { + count_obligation_improvements_for_vassal_include_hook >= 0 + } + custom_description = { + text = "vassal_modify_vassal_contract_cannot_increase_obligation_level" + object = scope:recipient + value = count_obligation_improvements_for_vassal_include_hook + count_obligation_improvements_for_vassal_include_hook = 0 + } } # Cannot change more than three things at once @@ -1863,14 +1868,14 @@ nomad_vassal_modify_vassal_contract_interaction = { on_accept = { # Enact changes - scope:recipient = { + scope:puppet_or_actor = { send_interface_message = { type = msg_vassal_contract_change title = modify_vassal_contract_interaction_notification - right_icon = scope:actor + right_icon = scope:recipient if = { limit = { always = scope:hook } - use_hook = scope:actor + use_hook = scope:recipient add_achievement_flag_effect = { FLAG = achievement_fine_print_flag } } @@ -1890,7 +1895,7 @@ nomad_vassal_modify_vassal_contract_interaction = { save_scope_as = obligation - scope:recipient = { + scope:puppet_or_actor = { vassal_contract_set_obligation_level = { type = scope:obligation.vassal_contract_type level = scope:obligation @@ -1902,13 +1907,13 @@ nomad_vassal_modify_vassal_contract_interaction = { # If there's a diarch involved, and they called in their change, that gets flagged. diarch_changed_own_contract_effect = yes # Additional Flavor Titles - scope:recipient = { additional_flavor_check_effect = yes } + scope:puppet_or_actor = { additional_flavor_check_effect = yes } } on_decline = { # Activate cooldown - You may only ask for it to be changed every so often (this mostly exists for MP, since you cannot send it to the AI unless they accept) hidden_effect = { - scope:recipient = { + scope:puppet_or_actor = { set_variable = { name = nomad_contract_request_cooldown value = yes @@ -1922,8 +1927,8 @@ nomad_vassal_modify_vassal_contract_interaction = { # Hook send_option = { is_valid = { - scope:recipient = { - has_usable_hook = scope:actor + scope:puppet_or_actor = { + has_usable_hook = scope:recipient } } flag = hook @@ -1931,16 +1936,16 @@ nomad_vassal_modify_vassal_contract_interaction = { } send_option = { is_shown = { - scope:recipient = { is_diarch_of_target = scope:actor } + scope:puppet_or_actor = { is_diarch_of_target = scope:recipient } } is_valid = { - scope:recipient = { + scope:puppet_or_actor = { trigger_if = { limit = { has_variable_list = diarch_contract_rights_used_list } NOT = { is_target_in_variable_list = { name = diarch_contract_rights_used_list - target = scope:actor + target = scope:recipient } } } @@ -1950,7 +1955,7 @@ nomad_vassal_modify_vassal_contract_interaction = { localization = CALL_IN_DIARCH_RIGHTS } should_use_extra_icon = { - scope:recipient = { has_usable_hook = scope:actor } + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } extra_icon = "gfx/interface/icons/character_interactions/hook_icon.dds" send_options_exclusive = no @@ -1971,29 +1976,29 @@ suzerain_modify_tributary_contract_interaction = { is_shown = { scope:recipient = { - is_tributary_of = scope:actor # excludes vassals by default + is_tributary_of = scope:puppet_or_actor # excludes vassals by default subject_contract_has_modifiable_obligations = yes NOT = { government_has_flag = government_is_herder } } } is_valid_showing_failures_only = { - NOT = { scope:recipient = { is_at_war_with = scope:actor } } + NOT = { scope:recipient = { is_at_war_with = scope:puppet_or_actor } } } can_send = { #Mandala gets special treatment trigger_if = { limit = { - scope:actor = { government_has_flag = government_is_mandala } + scope:puppet_or_actor = { government_has_flag = government_is_mandala } } custom_tooltip = { text = suzerain_modify_subject_contract_mandala_cooldown NOT = { - scope:recipient = { var:suzerain_recently_adjusted_mandala_subject_contract ?= scope:actor } + scope:recipient = { var:suzerain_recently_adjusted_mandala_subject_contract ?= scope:puppet_or_actor } } } - scope:actor = { + scope:puppet_or_actor = { has_changed_contract_obligation_trigger = yes # Cannot change more than three things at once @@ -2011,7 +2016,7 @@ suzerain_modify_tributary_contract_interaction = { trigger_if = { limit = { scope:obligations_favoring_tributary > 0 } custom_description = { - text = "tributary_modify_vassal_contract_unnecessary_hook_usage_vassal_favor" + text = "vassal_modify_vassal_contract_unnecessary_hook_usage_vassal_favor" object = scope:recipient value = scope:obligations_favoring_tributary NOT = { always = scope:hook } @@ -2020,7 +2025,7 @@ suzerain_modify_tributary_contract_interaction = { trigger_else_if = { limit = { scope:obligations_favoring_tributary = 0 } custom_description = { - text = "tributary_modify_vassal_contract_unnecessary_hook_usage_equal" + text = "vassal_modify_vassal_contract_unnecessary_hook_usage_equal" object = scope:recipient NOT = { always = scope:hook } } @@ -2032,7 +2037,7 @@ suzerain_modify_tributary_contract_interaction = { scope:obligations_favoring_tributary < 0 NOT = { always = scope:hook } } - scope:actor = { piety >= major_piety_value } + scope:puppet_or_actor = { piety >= major_piety_value } } trigger_else = {} # Otherwise we're fine! } @@ -2048,7 +2053,7 @@ suzerain_modify_tributary_contract_interaction = { } } trigger_else = { - scope:actor = { + scope:puppet_or_actor = { has_changed_contract_obligation_trigger = yes # Cannot change more than three things at once @@ -2066,7 +2071,7 @@ suzerain_modify_tributary_contract_interaction = { trigger_if = { limit = { scope:obligations_favoring_tributary > 0 } custom_description = { - text = "tributary_modify_vassal_contract_unnecessary_hook_usage_vassal_favor" + text = "vassal_modify_vassal_contract_unnecessary_hook_usage_vassal_favor" object = scope:recipient value = scope:obligations_favoring_tributary NOT = { always = scope:hook } @@ -2075,7 +2080,7 @@ suzerain_modify_tributary_contract_interaction = { trigger_else_if = { limit = { scope:obligations_favoring_tributary = 0 } custom_description = { - text = "tributary_modify_vassal_contract_unnecessary_hook_usage_equal" + text = "vassal_modify_vassal_contract_unnecessary_hook_usage_equal" object = scope:recipient NOT = { always = scope:hook } } @@ -2087,7 +2092,7 @@ suzerain_modify_tributary_contract_interaction = { scope:obligations_favoring_tributary < 0 NOT = { always = scope:hook } } - scope:actor = { + scope:puppet_or_actor = { prestige >= medium_prestige_value } } @@ -2099,7 +2104,7 @@ suzerain_modify_tributary_contract_interaction = { auto_accept = yes on_accept = { - scope:actor = { + scope:puppet_or_actor = { send_interface_message = { type = msg_vassal_contract_change title = modify_vassal_contract_interaction_notification @@ -2129,7 +2134,7 @@ suzerain_modify_tributary_contract_interaction = { add_opinion = { modifier = outraged_opinion opinion = -30 - target = scope:actor + target = scope:puppet_or_actor } } @@ -2140,7 +2145,7 @@ suzerain_modify_tributary_contract_interaction = { add_opinion = { modifier = outraged_opinion opinion = -10 - target = scope:actor + target = scope:puppet_or_actor } } } @@ -2151,7 +2156,7 @@ suzerain_modify_tributary_contract_interaction = { } set_variable = { name = suzerain_recently_adjusted_mandala_subject_contract - value = scope:actor + value = scope:puppet_or_actor years = mandala_vassal_obligation_cooldown_years } } @@ -2177,7 +2182,7 @@ suzerain_modify_tributary_contract_interaction = { send_option = { is_valid = { - scope:actor = { + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } @@ -2185,7 +2190,7 @@ suzerain_modify_tributary_contract_interaction = { localization = SCHEME_HOOK } should_use_extra_icon = { - scope:actor = { has_usable_hook = scope:recipient } + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } extra_icon = "gfx/interface/icons/character_interactions/hook_icon.dds" @@ -2202,19 +2207,20 @@ subject_modify_tributary_contract_interaction = { send_name = "subject_modify_tributary_contract_interaction_send" desc = subject_modify_tributary_contract_interaction_desc + notification_text = MODIFY_VASSAL_CONTRACT_NOTIFICATION_TO_LIEGE is_shown = { - scope:actor = { + scope:puppet_or_actor = { is_tributary_of = scope:recipient # excludes vassals by default subject_contract_has_modifiable_obligations = yes } } is_valid_showing_failures_only = { - scope:actor = { + scope:puppet_or_actor = { is_travelling = no } - NOT = { scope:recipient = { is_at_war_with = scope:actor } } + NOT = { scope:recipient = { is_at_war_with = scope:puppet_or_actor } } } can_send = { @@ -2226,11 +2232,11 @@ subject_modify_tributary_contract_interaction = { custom_tooltip = { text = subject_modify_subject_contract_mandala_cooldown NOT = { - scope:actor = { var:subject_recently_adjusted_mandala_subject_contract ?= scope:recipient } + scope:puppet_or_actor = { var:subject_recently_adjusted_mandala_subject_contract ?= scope:recipient } } } # You can afford the cost if there is one - scope:actor = { + scope:puppet_or_actor = { has_changed_contract_obligation_trigger = yes trigger_if = { limit = { scope:hook = no } # no cost @@ -2255,25 +2261,28 @@ subject_modify_tributary_contract_interaction = { } trigger_else_if = { #If you're blocked we don't want to show anything else (we don't really use this for admin, but we'll keep the logic, just in case) limit = { - scope:actor = { + scope:puppet_or_actor = { subject_contract_is_blocked_from_modification = yes } } - scope:actor = { + scope:puppet_or_actor = { subject_contract_is_blocked_from_modification = no } } trigger_else = { + scope:puppet_or_actor = { + has_changed_contract_obligation_trigger = yes + } # There is no cooldown present - To make sure we somehow don't show both cooldowns at the same time, we split them into separate triggers trigger_if = { limit = { - scope:actor = { + scope:puppet_or_actor = { has_variable = tributary_modify_contract_cooldown } } custom_tooltip = { text = tributary_modify_contract_cooldown_desc - scope:actor = { + scope:puppet_or_actor = { NOT = { has_variable = tributary_modify_contract_cooldown } } } @@ -2281,14 +2290,14 @@ subject_modify_tributary_contract_interaction = { trigger_else = { custom_tooltip = { text = tributary_modify_contract_cooldown_desc - scope:actor = { + scope:puppet_or_actor = { NOT = { has_variable = tributary_modify_contract_cooldown } } } } # You can afford the cost if there is one - scope:actor = { + scope:puppet_or_actor = { trigger_if = { limit = { scope:hook = no } # no cost trigger_if = { @@ -2321,7 +2330,7 @@ subject_modify_tributary_contract_interaction = { on_accept = { # Enact changes - scope:actor = { + scope:puppet_or_actor = { send_interface_message = { type = msg_vassal_contract_change title = modify_vassal_contract_interaction_notification @@ -2382,7 +2391,7 @@ subject_modify_tributary_contract_interaction = { save_scope_as = obligation - scope:actor = { + scope:puppet_or_actor = { tributary_contract_set_obligation_level = { type = scope:obligation.subject_contract_type level = scope:obligation @@ -2399,7 +2408,7 @@ subject_modify_tributary_contract_interaction = { on_decline = { # Activate cooldown - You may only ask for it to be changed every so often (this mostly exists for MP, since you cannot send it to the AI unless they accept) hidden_effect = { - scope:actor = { + scope:puppet_or_actor = { set_variable = { name = tributary_modify_contract_cooldown value = yes @@ -2413,7 +2422,7 @@ subject_modify_tributary_contract_interaction = { # Hook send_option = { is_valid = { - scope:actor = { + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } @@ -2422,10 +2431,10 @@ subject_modify_tributary_contract_interaction = { } send_option = { is_shown = { - scope:actor = { is_diarch_of_target = scope:recipient } + scope:puppet_or_actor = { is_diarch_of_target = scope:recipient } } is_valid = { - scope:actor = { + scope:puppet_or_actor = { trigger_if = { limit = { has_variable_list = diarch_contract_rights_used_list } NOT = { @@ -2441,7 +2450,7 @@ subject_modify_tributary_contract_interaction = { localization = CALL_IN_DIARCH_RIGHTS } should_use_extra_icon = { - scope:actor = { has_usable_hook = scope:recipient } + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } extra_icon = "gfx/interface/icons/character_interactions/hook_icon.dds" send_options_exclusive = no @@ -2452,7 +2461,7 @@ subject_modify_tributary_contract_interaction = { # Opinion Factor opinion_modifier = { who = scope:recipient - opinion_target = scope:actor + opinion_target = scope:puppet_or_actor multiplier = 1 desc = AI_OPINION_REASON } @@ -2464,7 +2473,7 @@ subject_modify_tributary_contract_interaction = { if = { # the Chinese Emperor cares less since they get tribute through missions as well limit = { scope:new_value < 0 - scope:actor = { + scope:puppet_or_actor = { OR = { has_subject_contract_group = tributary_celestial has_subject_contract_group = tributary_hegemonic @@ -2485,18 +2494,21 @@ ai_only_hegemonic_tributary_modify_tributary_contract_interaction = { auto_accept = yes + is_available = { + subject_standing > 40 + is_ai = yes + is_available = yes # Let's not have the AI do this when they're away from home etc (like paying tribute) + OR = { + has_subject_contract_group = tributary_celestial + has_subject_contract_group = tributary_hegemonic + } + does_ai_subject_in_subject_contract_desire_obligation_change = yes + subject_contract_has_modifiable_obligations = yes + } + is_shown = { scope:actor = { - is_ai = yes - is_available = yes # Let's not have the AI do this when they're away from home etc (like paying tribute) is_tributary_of = scope:recipient # excludes vassals by default - OR = { - has_subject_contract_group = tributary_celestial - has_subject_contract_group = tributary_hegemonic - } - subject_standing > 40 - subject_contract_has_modifiable_obligations = yes - does_ai_subject_in_subject_contract_desire_obligation_change = yes NOT = { is_at_war_with = scope:recipient } } } @@ -2540,10 +2552,6 @@ ai_only_hegemonic_tributary_modify_tributary_contract_interaction = { } } - ai_potential = { - always = yes - } - ai_targets = { ai_recipients = suzerain } diff --git a/common/character_interactions/00_prison_interactions.txt b/common/character_interactions/00_prison_interactions.txt index 9aa372676..52dc67e27 100644 --- a/common/character_interactions/00_prison_interactions.txt +++ b/common/character_interactions/00_prison_interactions.txt @@ -7,20 +7,36 @@ highlighted_reason = { triggered_desc = { trigger = { - scope:actor = { + scope:puppet_or_actor = { has_title = title:e_minister_of_justice NOT = { has_imprisonment_reason = scope:recipient } } } - desc = HIGHLIGHTED_MINISTER_IMPRISONMENT_REASON + desc = { + first_valid = { + triggered_desc = { + trigger = { NOT = { scope:actor = scope:puppet_or_actor } } + desc = HIGHLIGHTED_MINISTER_IMPRISONMENT_REASON_puppeteer + } + desc = HIGHLIGHTED_MINISTER_IMPRISONMENT_REASON + } + } } triggered_desc = { trigger = { - scope:actor = { + scope:puppet_or_actor = { has_imprisonment_reason = scope:recipient } } - desc = HIGHLIGHTED_HAS_IMPRISONMENT_REASON + desc = { + first_valid = { + triggered_desc = { + trigger = { NOT = { scope:actor = scope:puppet_or_actor } } + desc = HIGHLIGHTED_HAS_IMPRISONMENT_REASON_puppeteer + } + desc = HIGHLIGHTED_HAS_IMPRISONMENT_REASON + } + } } } ai_maybe = yes @@ -47,17 +63,23 @@ AND = { has_government = landless_adventurer_government reverse_has_opinion_modifier = { - target = scope:actor + target = scope:puppet_or_actor modifier = eviction_ignored_opinion } } - scope:actor = { + scope:puppet_or_actor = { has_title = title:e_minister_of_justice } scope:recipient = { is_landed = no - any_held_title = { - is_noble_family_title = yes + OR = { + exists = clerical_elector_title + any_held_title = { + OR = { + is_noble_family_title = yes + has_clerical_region = yes + } + } } } } @@ -67,23 +89,15 @@ } } - ai_potential = { - trigger_if = { - limit = { has_realm_law_flag = imprisonment_toggle_enable } - has_realm_law_flag = imprisonment_toggle_on - } - is_imprisoned = no - } - is_shown = { - scope:actor != scope:recipient - scope:actor = { + scope:puppet_or_actor ?= { + this != scope:recipient OR = { AND = { has_title = title:e_minister_of_justice scope:recipient = { tgp_is_any_minister = no - liege = { + liege ?= { basic_allowed_to_imprison_character_trigger = { CHARACTER = scope:recipient } @@ -94,11 +108,22 @@ CHARACTER = scope:recipient } } + trigger_if = { + limit = { + is_ai = yes + NOT = { puppeteer ?= { is_ai = no } } + } + trigger_if = { + limit = { has_realm_law_flag = imprisonment_toggle_enable } + has_realm_law_flag = imprisonment_toggle_on + } + is_imprisoned = no + } } # Scope:recipient can't be visiting elsewhere. trigger_if = { limit = { - scope:recipient = { is_courtier_of = scope:actor } + scope:recipient = { is_courtier_of = scope:puppet_or_actor } } NOT = { scope:recipient.host = { @@ -109,7 +134,7 @@ } is_valid_showing_failures_only = { - scope:actor = { + scope:puppet_or_actor = { trigger_if = { limit = { has_title = title:e_minister_of_justice @@ -139,34 +164,68 @@ } scope:recipient = { NOT = { - is_close_or_extended_family_of = scope:actor.top_liege + is_close_or_extended_family_of = scope:puppet_or_actor.top_liege } } } } imprison_neutral_is_valid_showing_failures_only_triggers_trigger = yes - custom_tooltip = { - text = cannot_take_overt_hostile_actions_against_diarch.tt - NOT = { scope:recipient ?= scope:actor.diarch } + trigger_if = { + limit = { scope:actor = scope:puppet_or_actor } + custom_tooltip = { + text = cannot_take_overt_hostile_actions_against_diarch.tt + NOT = { scope:recipient ?= scope:puppet_or_actor.diarch } + } + } + trigger_else = { + custom_tooltip = { + text = cannot_take_overt_hostile_actions_against_diarch.tt_puppeteer + NOT = { scope:recipient ?= scope:puppet_or_actor.diarch } + } + } + trigger_if = { + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + prestige >= liege_diarchy_surcharge_interaction_imprison_interaction_value + } + } + trigger_if = { + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + treasury >= { + value = 0 + if = { + limit = { + scope:puppet_or_actor = { + has_title = title:e_minister_of_justice + } + scope:recipient = { + NOT = { is_courtier_of = scope:puppet_or_actor } + } + } + add = scope:puppet_or_actor.major_treasury_value + } + } + } } } can_send = { - scope:actor = { + scope:puppet_or_actor = { custom_description = { text = "character_interactions_hostile_actions_disabled_delay" NOT = { has_character_flag = flag_hostile_actions_disabled_delay } } trigger_if = { limit = { - is_ai = no + scope:actor = { is_ai = no } } scope:recipient = { trigger_if = { limit = { has_government = landless_adventurer_government reverse_has_opinion_modifier = { - target = scope:actor + target = scope:puppet_or_actor modifier = eviction_ignored_opinion } } @@ -189,7 +248,7 @@ scope:recipient = { is_imprisoned = no } - scope:actor = { + scope:puppet_or_actor = { OR = { has_imprisonment_reason = scope:recipient has_title = title:e_minister_of_justice @@ -201,7 +260,7 @@ send_option = { is_valid = { exists = scope:recipient - scope:actor = { + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } @@ -209,7 +268,7 @@ localization = SCHEME_HOOK } should_use_extra_icon = { - scope:actor = { has_usable_hook = scope:recipient } + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } extra_icon = "gfx/interface/icons/character_interactions/hook_icon.dds" @@ -217,15 +276,21 @@ cost = { # Usually, this action is free, but during certain diarchies, we want it to cost. - prestige = liege_diarchy_surcharge_interaction_imprison_interaction_value + prestige = { + value = liege_diarchy_surcharge_interaction_imprison_interaction_value + if = { + limit = { scope:is_puppet_action ?= yes } + multiply = 0 + } + } treasury = { if = { limit = { - scope:actor = { + scope:puppet_or_actor = { has_title = title:e_minister_of_justice } scope:recipient = { - NOT = { is_courtier_of = scope:actor } + NOT = { is_courtier_of = scope:puppet_or_actor } } } value = { @@ -233,15 +298,19 @@ desc = BASE } add = { - value = scope:actor.major_treasury_value + value = scope:puppet_or_actor.major_treasury_value desc = IMPRISON_MINISTER_OF_JUSTICE_TREASURY_COST } } + if = { + limit = { scope:is_puppet_action ?= yes } + multiply = 0 + } } } on_send = { - scope:actor = { + scope:puppet_or_actor = { add_character_flag = { flag = flag_hostile_actions_disabled_delay days = 10 @@ -257,7 +326,25 @@ } on_accept = { - scope:actor = { + if = { + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + if = { + limit = { liege_diarchy_surcharge_interaction_imprison_interaction_value > 0 } + add_prestige = { value = { add = liege_diarchy_surcharge_interaction_imprison_interaction_value max = prestige multiply = -1 } } + } + if = { + limit = { + has_title = title:e_minister_of_justice + scope:recipient = { + NOT = { is_courtier_of = scope:puppet_or_actor } + } + } + remove_treasury = scope:puppet_or_actor.major_treasury_value + } + } + } + scope:puppet_or_actor = { if = { limit = { has_title = title:e_minister_of_justice @@ -315,7 +402,7 @@ } if = { limit = { scope:hook = yes } - scope:actor = { use_hook = scope:recipient } + scope:puppet_or_actor = { use_hook = scope:recipient } } illegal_imprisonment_dread_effect = yes imprison_court_chaplain_consequences_effect = yes @@ -324,30 +411,30 @@ if = { limit = { is_a_faction_member = yes - liege = scope:actor + liege = scope:puppet_or_actor } joined_faction = { save_scope_as = retaliating_faction } } } imprison_character_effect = { TARGET = scope:recipient - IMPRISONER = scope:actor + IMPRISONER = scope:puppet_or_actor } # If they recently revoked your title, or asked for your excommunication, they become your rival imprison_attempt_escalates_rivalry_effect = yes - scope:actor = { + scope:puppet_or_actor = { trigger_event = char_interaction.0231 if = { limit = { has_imprisonment_reason = scope:recipient } - stress_impact = { + stress_and_fulfillment_impact = { compassionate = minor_stress_impact_gain forgiving = minor_stress_impact_gain } } else = { - stress_impact = { + stress_and_fulfillment_impact = { just = medium_stress_impact_gain compassionate = medium_stress_impact_gain } @@ -361,19 +448,19 @@ } if = { limit = { - scope:actor = { has_character_flag = flag_hostile_actions_disabled_delay } + scope:puppet_or_actor = { has_character_flag = flag_hostile_actions_disabled_delay } } - scope:actor = { remove_character_flag = flag_hostile_actions_disabled_delay } + scope:puppet_or_actor = { remove_character_flag = flag_hostile_actions_disabled_delay } } # If we're a clan this interaction affects unity if = { # If you don't have an imprisonment reason, and the target is landed, you lose more unity limit = { - NOT = { scope:actor = { has_imprisonment_reason = scope:recipient } } - scope:recipient = { is_landed_or_landless_administrative = yes } + NOT = { scope:puppet_or_actor = { has_imprisonment_reason = scope:recipient } } + scope:recipient = { is_landed_or_landless_administrative_or_theocratic = yes } } add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = major_unity_loss DESC = clan_unity_imprison.desc @@ -382,11 +469,11 @@ } else_if = { # If you don't have an imprisonment reason, and the target is unlanded, you lose slightly less unity limit = { - NOT = { scope:actor = { has_imprisonment_reason = scope:recipient } } - scope:recipient = { is_landed_or_landless_administrative = no } + NOT = { scope:puppet_or_actor = { has_imprisonment_reason = scope:recipient } } + scope:recipient = { is_landed_or_landless_administrative_or_theocratic = no } } add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = medium_unity_loss DESC = clan_unity_imprison.desc @@ -395,7 +482,7 @@ } else = { # If you have a valid reason, you lose only a tiny bit of unity (criminal or not, they are still family) add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = minor_unity_loss DESC = clan_unity_imprison.desc @@ -403,8 +490,8 @@ } } -# # Harrying logic. -# scope:actor = { + # Harrying logic. +# scope:puppet_or_actor = { # if = { # limit = { # character_is_valid_for_harrying_of_the_north_trigger = yes @@ -434,9 +521,46 @@ } on_decline = { + #Close family might get rival progress if = { limit = { - scope:actor = { + scope:recipient = { + is_close_family_of = scope:puppet_or_actor + } + #Legal imprisonment + trigger_if = { + limit = { + scope:puppet_or_actor = { + has_imprisonment_reason = scope:recipient + } + } + scope:recipient = { + NOR = { + has_trait = forgiving + ai_honor >= low_positive_ai_value + } + } + } + #Illegal imprisonment + trigger_else = { + scope:recipient = { + NOT = { + has_trait = forgiving + } + } + } + } + scope:recipient = { + progress_towards_rival_effect = { + CHARACTER = scope:puppet_or_actor + REASON = rival_imprisoned_family + OPINION = 0 + } + } + } + if = { + limit = { + scope:puppet_or_actor = { NOT = { has_title = title:e_minister_of_justice } } } @@ -451,7 +575,7 @@ limit = { current_military_strength >= ep3_interactions_events_0500_troops_count_value } start_war = { cb = ep3_laamp_apprehend_adventurer_cb - target = scope:actor + target = scope:puppet_or_actor } } else = { @@ -464,7 +588,7 @@ } } else = { - scope:actor = { + scope:puppet_or_actor = { imprison_HoF_consequences_effect = yes imprison_tyranny_effect = yes } @@ -478,9 +602,9 @@ if = { limit = { is_a_faction_member = yes - liege = scope:actor + liege = scope:puppet_or_actor joined_faction = { - faction_target = scope:actor + faction_target = scope:puppet_or_actor NOT = { faction_is_type = populist_faction } } } @@ -491,38 +615,44 @@ hidden_effect = { if = { limit = { NOT = { exists = joined_faction.faction_war } } - war_for_imprison_effect = yes + war_for_imprison_effect = { + LIEGE = scope:puppet_or_actor + REBEL = scope:recipient + } } } } else = { - war_for_imprison_effect = yes + war_for_imprison_effect = { + LIEGE = scope:puppet_or_actor + REBEL = scope:recipient + } } } #If target is a baron or unlanded, have them escape. else = { if = { #To block them from being instantly rehired limit = { - is_councillor_of = scope:actor - can_be_fired_from_council_trigger = { COURT_OWNER = scope:actor } + is_councillor_of = scope:puppet_or_actor + can_be_fired_from_council_trigger = { COURT_OWNER = scope:puppet_or_actor } } set_variable = { name = escaped_imprisonment_from - value = scope:actor + value = scope:puppet_or_actor years = 20 } } imprison_court_chaplain_consequences_effect = yes if = { limit = { - is_landed_or_landless_administrative = yes + is_landed_or_landless_administrative_or_theocratic = yes } - depose_effect = { DEPOSER = scope:actor } + depose_effect = { DEPOSER = scope:puppet_or_actor } } else_if = { limit = { is_hostage = yes - warden = scope:actor + warden = scope:puppet_or_actor } save_scope_as = imprison_failure save_scope_as = hostage @@ -534,7 +664,7 @@ } else_if = { limit = { - is_landed_or_landless_administrative = no + is_landed_or_landless_administrative_or_theocratic = no trigger_if = { limit = { is_councillor = yes @@ -543,15 +673,15 @@ } trigger_if = { limit = { - exists = scope:actor.faith.religious_head + exists = scope:puppet_or_actor.faith.religious_head } - scope:actor.faith.religious_head != scope:recipient + scope:puppet_or_actor.faith.religious_head != scope:recipient } } select_and_move_to_pool_effect = yes } add_opinion = { - target = scope:actor + target = scope:puppet_or_actor modifier = attempted_imprisonment_opinion } } @@ -559,9 +689,9 @@ if = { limit = { - scope:actor = { has_realm_law_flag = vassal_refusal_is_treason } + scope:puppet_or_actor = { has_realm_law_flag = vassal_refusal_is_treason } } - scope:actor = { + scope:puppet_or_actor = { add_opinion = { target = scope:recipient modifier = treasonous_imprison_refusal @@ -571,7 +701,7 @@ } #Remove them as guardian/ward for any courtier (feedback given in char_interaction.0230) - scope:actor = { + scope:puppet_or_actor = { if = { limit = { any_courtier = { @@ -595,7 +725,7 @@ guardian_remove_opinion_effect = { GUARDIAN = scope:recipient WARD = this - WARD_LIEGE = scope:actor + WARD_LIEGE = scope:puppet_or_actor } } @@ -625,7 +755,7 @@ guardian_remove_opinion_effect = { GUARDIAN = this WARD = scope:recipient - WARD_LIEGE = scope:actor + WARD_LIEGE = scope:puppet_or_actor } } @@ -676,12 +806,12 @@ if = { # If you don't have an imprisonment reason, and the target is landed, you lose more unity limit = { NOT = { - scope:actor = { has_imprisonment_reason = scope:recipient } + scope:puppet_or_actor = { has_imprisonment_reason = scope:recipient } } - scope:recipient = { is_landed_or_landless_administrative = yes } + scope:recipient = { is_landed_or_landless_administrative_or_theocratic = yes } } add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = major_unity_loss DESC = clan_unity_imprison.desc @@ -691,12 +821,12 @@ else_if = { # If you don't have an imprisonment reason, and the target is unlanded, you lose slightly less unity limit = { NOT = { - scope:actor = { has_imprisonment_reason = scope:recipient } + scope:puppet_or_actor = { has_imprisonment_reason = scope:recipient } } - scope:recipient = { is_landed_or_landless_administrative = no } + scope:recipient = { is_landed_or_landless_administrative_or_theocratic = no } } add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = medium_unity_loss DESC = clan_unity_imprison.desc @@ -705,7 +835,7 @@ } else = { # If you have a valid reason, you lose only a tiny bit of unity (criminal or not, they are still family) add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = miniscule_unity_loss DESC = clan_unity_imprison.desc @@ -719,13 +849,13 @@ # OR does not display properly here trigger_if = { limit = { - scope:actor = { + scope:puppet_or_actor = { has_title = title:e_minister_of_justice } } custom_description = { text = you_are_the_minister_of_justice - scope:actor = { + scope:puppet_or_actor = { has_title = title:e_minister_of_justice } } @@ -734,8 +864,15 @@ limit = { scope:recipient = { is_landed = no - any_held_title = { - is_noble_family_title = yes + # Landless prelates: a cardinalate or clerical region cannot sustain the refusal war + OR = { + exists = clerical_elector_title + any_held_title = { + OR = { + is_noble_family_title = yes + has_clerical_region = yes + } + } } } } @@ -743,8 +880,14 @@ text = noble_family_head_cannot_refuse_your_power scope:recipient = { is_landed = no - any_held_title = { - is_noble_family_title = yes + OR = { + exists = clerical_elector_title + any_held_title = { + OR = { + is_noble_family_title = yes + has_clerical_region = yes + } + } } } } @@ -757,9 +900,37 @@ ai_accept = { base = 0 # Try to make it 0 for most interactions + modifier = { + add = -25 + scope:recipient = { + has_personal_tenet_flag = tenet_false_conversion_sanction_elusive + } + desc = SANCTIONED_FALSE_CONVERSION_IMPRISONMENT_RESISTANCE + } + + legalism_lawful_authority_acceptance_modifier = { + ACTOR = scope:puppet_or_actor + } + + celestial_hierarchy_acceptance_modifier = { + ACTOR = scope:puppet_or_actor + RECIPIENT = scope:recipient + } modifier = { add = { - value = scope:actor.intrigue + value = scope:puppet_or_actor.learning + multiply = 2 + } + scope:puppet_or_actor = { + has_personal_tenet_flag = tenet_religious_law_imprisonment_bonus + has_imprisonment_reason = scope:recipient + } + desc = RELIGIOUS_LAW_IMPRISONMENT_LEARNING_REASON + } + + modifier = { + add = { + value = scope:puppet_or_actor.intrigue multiply = 1 } desc = IMPRISON_INTRIGUE_ACTOR @@ -779,7 +950,7 @@ } opinion_modifier = { # Opinion Factor who = scope:recipient - opinion_target = scope:actor + opinion_target = scope:puppet_or_actor multiplier = 0.5 desc = AI_OPINION_REASON } @@ -799,7 +970,7 @@ scope:recipient = { #If AI is honorable and the law compels to obey the liege, AI will be more likely to obey. ai_honor > 0 } - scope:actor = { + scope:puppet_or_actor = { has_imprisonment_reason = scope:recipient has_realm_law_flag = vassal_refusal_is_treason } @@ -810,7 +981,7 @@ } modifier = { add = 20 - scope:actor = { + scope:puppet_or_actor = { any_vassal_or_below = { this = scope:recipient } has_realm_law_flag = vassal_refusal_is_treason } @@ -818,7 +989,7 @@ } modifier = { add = 50 - scope:actor = { + scope:puppet_or_actor = { has_perk = prison_feudal_complex_perk } desc = AI_PRISON_FEUDAL_COMPLEX_PERK @@ -833,18 +1004,26 @@ scope:recipient = { is_ruler = no } add = 50 } + modifier = { + desc = AI_REFUSAL_HUMAN_SACRIFICE_COURTIER + scope:puppet_or_actor = { + has_personal_tenet_flag = tenet_human_sacrifice_courtier_imprisonment_chance + } + scope:recipient = { is_ruler = no } + add = 25 + } modifier = { # Your young children can't really stop you desc = AI_REFUSAL_YOUNG_CHILD scope:recipient = { - is_child_of = scope:actor - is_courtier_of = scope:actor + is_child_of = scope:puppet_or_actor + is_courtier_of = scope:puppet_or_actor is_adult = no } add = 200 } modifier = { #They're a claimant against you desc = AI_CLAIMANT_PENALTY - scope:actor = { + scope:puppet_or_actor = { OR = { any_targeting_faction = { faction_type = claimant_faction @@ -870,7 +1049,7 @@ value = -15 if = { limit = { - scope:actor = { + scope:puppet_or_actor = { tier_difference = { target = scope:recipient value >= 2 @@ -881,7 +1060,7 @@ } if = { limit = { - scope:actor = { + scope:puppet_or_actor = { tier_difference = { target = scope:recipient value >= 3 @@ -892,7 +1071,7 @@ } if = { #King asking Baron, modifier becomes positive. limit = { - scope:actor = { + scope:puppet_or_actor = { tier_difference = { target = scope:recipient value >= 4 @@ -906,9 +1085,9 @@ modifier = { add = intimidated_halved_reason_value scope:recipient = { - target_is_liege_or_above = scope:actor + target_is_liege_or_above = scope:puppet_or_actor has_dread_level_towards = { - target = scope:actor + target = scope:puppet_or_actor level = 1 } } @@ -917,9 +1096,9 @@ modifier = { add = cowed_halved_reason_value scope:recipient = { - target_is_liege_or_above = scope:actor + target_is_liege_or_above = scope:puppet_or_actor has_dread_level_towards = { - target = scope:actor + target = scope:puppet_or_actor level = 2 } } @@ -929,9 +1108,9 @@ modifier = { add = intimidated_external_reason_value scope:recipient = { - NOT = { target_is_liege_or_above = scope:actor } + NOT = { target_is_liege_or_above = scope:puppet_or_actor } has_dread_level_towards = { - target = scope:actor + target = scope:puppet_or_actor level = 1 } } @@ -940,9 +1119,9 @@ modifier = { add = cowed_external_reason_value scope:recipient = { - NOT = { target_is_liege_or_above = scope:actor } + NOT = { target_is_liege_or_above = scope:puppet_or_actor } has_dread_level_towards = { - target = scope:actor + target = scope:puppet_or_actor level = 2 } } @@ -951,14 +1130,14 @@ modifier = { #Comparative military strength. desc = offer_vassalization_interaction_aibehavior_power_tt trigger = { - scope:actor = { is_ruler = yes } + scope:puppet_or_actor = { is_ruler = yes } scope:recipient = { is_ruler = yes } } add = { value = 1 subtract = { value = scope:recipient.current_military_strength - divide = { value = scope:actor.current_military_strength min = 1 } + divide = { value = scope:puppet_or_actor.current_military_strength min = 1 } } multiply = 100 min = -1000 @@ -970,8 +1149,8 @@ desc = offer_vassalization_interaction_aibehavior_rival_tt trigger = { scope:recipient = { - has_relation_rival = scope:actor - NOT = { has_relation_nemesis = scope:actor } + has_relation_rival = scope:puppet_or_actor + NOT = { has_relation_nemesis = scope:puppet_or_actor } } } add = -50 @@ -980,14 +1159,14 @@ desc = offer_vassalization_interaction_aibehavior_nemesis_tt trigger = { scope:recipient = { - has_relation_nemesis = scope:actor + has_relation_nemesis = scope:puppet_or_actor } } add = -100 } modifier = { add = 10 - scope:actor = { + scope:puppet_or_actor = { has_royal_court = yes has_dlc_feature = royal_court is_liege_or_above_of = scope:recipient @@ -998,7 +1177,7 @@ } modifier = { add = 20 - scope:actor = { + scope:puppet_or_actor = { has_royal_court = yes has_dlc_feature = royal_court is_liege_or_above_of = scope:recipient @@ -1008,14 +1187,14 @@ } modifier = { # Legalistic tradition desc = tradition_legalistic_name - scope:actor = { + scope:puppet_or_actor = { has_imprisonment_reason = scope:recipient culture = { has_cultural_parameter = vassals_more_likely_accept_punishments } } add = legalistic_vassal_punishment_acceptance } modifier = { # AI Mongols, tyranny wars just delay the inevitable fun! - scope:actor = { + scope:puppet_or_actor = { is_ai = yes OR = { has_trait = greatest_of_khans @@ -1029,7 +1208,7 @@ } # Thug accolade increases imprison chance because they scary modifier = { - scope:actor = { + scope:puppet_or_actor = { any_active_accolade = { accolade_parameter = accolade_imprisonment_chance } @@ -1038,7 +1217,7 @@ add = accolade_imprisonment_chance_value } modifier = { - scope:actor = { + scope:puppet_or_actor = { any_active_accolade = { accolade_parameter = accolade_imprisonment_chance_high } @@ -1092,14 +1271,14 @@ modifier = { # Default imprisonment reason weight add = 200 - scope:actor = { + scope:puppet_or_actor = { has_imprisonment_reason = scope:recipient } } modifier = { # More likely to imprison criminal Soryo's if Ritsuryo add = 200 - scope:actor = { + scope:puppet_or_actor = { has_imprisonment_reason = scope:recipient government_has_flag = government_is_japan_administrative } @@ -1110,19 +1289,19 @@ modifier = { # Even more imprisonment reason if you are a danger to the Kampaku add = 400 - scope:actor = { + scope:puppet_or_actor = { primary_title = title:e_japan has_imprisonment_reason = scope:recipient } scope:recipient = { exists = house.house_confederation - house.house_confederation.combined_military_strength > scope:actor.current_military_strength + house.house_confederation.combined_military_strength > scope:puppet_or_actor.current_military_strength } } modifier = { # Avoid Tyranny wars at inopportune times add = -190 - scope:actor = { + scope:puppet_or_actor = { ai_rationality > -100 # Lunatics can do whatever, let the world burn... is_at_war = yes } @@ -1133,7 +1312,7 @@ modifier = { # Avoid imprisonments in certain circumstances add = -190 - scope:actor = { + scope:puppet_or_actor = { ai_rationality > -100 # Lunatics can do whatever, let the world burn... NOR = { AND = { @@ -1143,7 +1322,7 @@ has_perk = prison_feudal_complex_perk scope:recipient = { has_dread_level_towards = { - target = scope:actor + target = scope:puppet_or_actor level >= 1 } } @@ -1159,20 +1338,20 @@ modifier = { # If the AI is not very bold, avoid imprisoning people unless you're more powerful add = -190 - scope:actor.ai_rationality > -100 # Lunatics can do whatever, let the world burn... - scope:actor.ai_boldness <= 25 - scope:actor.current_military_strength < scope:recipient.one_and_a_half_times_current_military_strength + scope:puppet_or_actor.ai_rationality > -100 # Lunatics can do whatever, let the world burn... + scope:puppet_or_actor.ai_boldness <= 25 + scope:puppet_or_actor.current_military_strength < scope:recipient.one_and_a_half_times_current_military_strength } modifier = { # Avoid imprisoning people that would destroy you add = -190 - scope:actor.ai_rationality > -100 # Lunatics can do whatever, let the world burn... - scope:actor.current_military_strength < scope:recipient.current_military_strength + scope:puppet_or_actor.ai_rationality > -100 # Lunatics can do whatever, let the world burn... + scope:puppet_or_actor.current_military_strength < scope:recipient.current_military_strength } modifier = { # Do not imprison when the chance of success if exceedingly low add = -190 - scope:actor.ai_rationality > -100 # Lunatics can do whatever, let the world burn... + scope:puppet_or_actor.ai_rationality > -100 # Lunatics can do whatever, let the world burn... scope:recipient = { is_playable_character = yes } @@ -1181,13 +1360,13 @@ highest_held_title_tier = tier_barony } } - scope:actor = { + scope:puppet_or_actor = { gold < minimum_ai_gold_value_for_tyranny_wars } } modifier = { # Don't imprison people you like - scope:actor = { + scope:puppet_or_actor = { NOT = { has_trait = sadistic } @@ -1208,10 +1387,10 @@ modifier = { # Don't imprison your own children... unless they're your rival/nemesis scope:recipient = { - is_child_of = scope:actor + is_child_of = scope:puppet_or_actor NOR = { - has_relation_rival = scope:actor - has_relation_nemesis = scope:actor + has_relation_rival = scope:puppet_or_actor + has_relation_nemesis = scope:puppet_or_actor } } add = -1000 @@ -1219,11 +1398,11 @@ modifier = { # Don't imprison your spouse, unless they're your rival/have cheated on you scope:recipient = { - is_spouse_of = scope:actor + is_spouse_of = scope:puppet_or_actor NOR = { - has_relation_rival = scope:actor - has_relation_nemesis = scope:actor - exposed_cheating_on_spouse_trigger = { SPOUSE = scope:actor } + has_relation_rival = scope:puppet_or_actor + has_relation_nemesis = scope:puppet_or_actor + exposed_cheating_on_spouse_trigger = { SPOUSE = scope:puppet_or_actor } } } add = -1000 @@ -1232,130 +1411,130 @@ modifier = { # Try to avoid pointless imprisonments scope:recipient = { NOR = { - scope:actor = { # Sadists want people to torture + scope:puppet_or_actor = { # Sadists want people to torture has_trait = sadistic } AND = { # Imprisoning vassals you have revoke reasons on is relevant is_playable_character = yes - scope:actor = { has_revoke_title_reason = scope:recipient } + scope:puppet_or_actor = { has_revoke_title_reason = scope:recipient } } is_a_faction_member = yes - has_relation_rival = scope:actor - has_relation_nemesis = scope:actor - exposed_cheating_on_spouse_trigger = { SPOUSE = scope:actor } - scope:actor = { # Scheme Agents should be imprisoned indiscriminately + has_relation_rival = scope:puppet_or_actor + has_relation_nemesis = scope:puppet_or_actor + exposed_cheating_on_spouse_trigger = { SPOUSE = scope:puppet_or_actor } + scope:puppet_or_actor = { # Scheme Agents should be imprisoned indiscriminately any_targeting_scheme = { hostile_scheme_trigger = yes is_scheme_agent_exposed = scope:recipient } } AND = { # Zealots will imprison characters of other faiths - scope:actor.ai_zeal >= medium_positive_ai_value - scope:actor.faith != scope:recipient.faith + scope:puppet_or_actor.ai_zeal >= medium_positive_ai_value + scope:puppet_or_actor.faith != scope:recipient.faith } - scope:actor = { + scope:puppet_or_actor = { has_opinion_modifier = { modifier = murdered_close_family_crime target = scope:recipient } } - scope:actor = { + scope:puppet_or_actor = { has_opinion_modifier = { modifier = attempted_murder_close_family_crime target = scope:recipient } } - scope:actor = { + scope:puppet_or_actor = { has_opinion_modifier = { modifier = executed_close_family target = scope:recipient } } - scope:actor = { + scope:puppet_or_actor = { has_opinion_modifier = { modifier = slept_with_spouse_discovered_opinion target = scope:recipient } } - scope:actor = { + scope:puppet_or_actor = { has_opinion_modifier = { modifier = slept_with_spouse_exposed_opinion target = scope:recipient } } - scope:actor = { + scope:puppet_or_actor = { has_opinion_modifier = { modifier = unfaithful_spouse_discovered_opinion target = scope:recipient } } - scope:actor = { + scope:puppet_or_actor = { has_opinion_modifier = { modifier = unfaithful_spouse_exposed_opinion target = scope:recipient } } - scope:actor = { + scope:puppet_or_actor = { has_opinion_modifier = { modifier = refused_to_renounce_lover_opinion target = scope:recipient } } - scope:actor = { + scope:puppet_or_actor = { has_opinion_modifier = { modifier = betrayed_our_promise target = scope:recipient } } - scope:actor = { + scope:puppet_or_actor = { has_opinion_modifier = { modifier = botched_my_treatment_crime_opinion target = scope:recipient } } - scope:actor = { + scope:puppet_or_actor = { has_opinion_modifier = { modifier = botched_treatment_of_kin_crime_opinion target = scope:recipient } } - scope:actor = { + scope:puppet_or_actor = { has_opinion_modifier = { modifier = smeared_opinion target = scope:recipient } } - scope:actor = { + scope:puppet_or_actor = { has_opinion_modifier = { modifier = insulted_opinion target = scope:recipient } } - scope:actor = { + scope:puppet_or_actor = { has_opinion_modifier = { modifier = mocked_me_in_time_of_need target = scope:recipient } } - scope:actor = { + scope:puppet_or_actor = { has_opinion_modifier = { modifier = loved_one_dungeon_death target = scope:recipient } } - scope:actor = { + scope:puppet_or_actor = { has_opinion_modifier = { modifier = abandoned_me_opinion target = scope:recipient } } - scope:actor = { + scope:puppet_or_actor = { has_opinion_modifier = { modifier = reason_child_died target = scope:recipient } } - scope:actor = { + scope:puppet_or_actor = { has_opinion_modifier = { modifier = falsely_accused target = scope:recipient @@ -1383,7 +1562,7 @@ # value = 0 # if = { # limit = { -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # phase_has_catalyst = catalyst_imprison_important # } @@ -1394,7 +1573,7 @@ # } # else_if = { # limit = { -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # phase_has_catalyst = catalyst_imprison_important # } @@ -1415,7 +1594,7 @@ # value = 0 # if = { # limit = { -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # phase_has_catalyst = catalyst_imprison_supporter # } @@ -1426,7 +1605,7 @@ # } # else_if = { # limit = { -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # phase_has_catalyst = catalyst_imprison_supporter # } @@ -1447,7 +1626,7 @@ # value = 0 # if = { # limit = { -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # phase_has_catalyst = catalyst_imprison_detractor # } @@ -1458,7 +1637,7 @@ # } # else_if = { # limit = { -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # phase_has_catalyst = catalyst_imprison_detractor # } @@ -1474,7 +1653,7 @@ modifier = { # Avoid triggering Tyranny wars mid-grand activity factor = 0 - scope:actor = { + scope:puppet_or_actor = { has_ongoing_grand_activity_trigger = yes } scope:recipient = { @@ -1484,7 +1663,7 @@ modifier = { # Expel first, even if they criminals factor = 0 - scope:actor = { + scope:puppet_or_actor = { NOT = { has_opinion_modifier = { target = scope:recipient @@ -1508,11 +1687,11 @@ move_to_dungeon_interaction = { icon = prison is_shown = { - scope:actor = { + scope:puppet_or_actor ?= { is_landless_ruler = no } scope:recipient = { - is_imprisoned_by = scope:actor + is_imprisoned_by = scope:puppet_or_actor is_in_prison_type = house_arrest } } @@ -1525,7 +1704,7 @@ move_to_dungeon_interaction = { } } tgp_blocked_action_against_tenno_trigger = { - ACTOR = scope:actor + ACTOR = scope:puppet_or_actor TARGET = scope:recipient } custom_tooltip = { @@ -1552,22 +1731,22 @@ move_to_dungeon_interaction = { every_close_or_extended_family_member = { custom = all_family_members limit = { - scope:actor != this + scope:puppet_or_actor != this } add_opinion = { modifier = family_moved_to_dungeon_opinion - target = scope:actor + target = scope:puppet_or_actor } } } - scope:actor = { - stress_impact = { + scope:puppet_or_actor = { + stress_and_fulfillment_impact = { compassionate = medium_stress_impact_gain forgiving = medium_stress_impact_gain } hidden_effect = { send_interface_message = { - type = event_prison_neutral + type = interaction_prison_single_side title = msg_move_prisoner_to_dungeon right_icon = scope:recipient custom_tooltip = MOVE_PRISONER_TO_DUNGEON @@ -1577,7 +1756,7 @@ move_to_dungeon_interaction = { # If we're a clan this interaction affects unity add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = medium_unity_loss DESC = clan_unity_move_to_dungeon.desc @@ -1600,17 +1779,13 @@ move_to_dungeon_interaction = { hegemony = 12 } - ai_potential = { - always = yes - } - ai_will_do = { base = 0 modifier = { add = 100 - scope:actor.ai_compassion < medium_positive_ai_value - scope:actor = { + scope:puppet_or_actor.ai_compassion < medium_positive_ai_value + scope:puppet_or_actor = { opinion = { target = scope:recipient value <= high_negative_opinion @@ -1620,7 +1795,7 @@ move_to_dungeon_interaction = { modifier = { # Family Feud add = 25 trigger = { - scope:actor = { + scope:puppet_or_actor = { house_has_feud_relation_with_trigger = { TARGET = scope:recipient } } @@ -1637,11 +1812,11 @@ move_to_house_arrest_interaction = { icon = prison is_shown = { - scope:actor = { + scope:puppet_or_actor ?= { is_landless_ruler = no } scope:recipient = { - is_imprisoned_by = scope:actor + is_imprisoned_by = scope:puppet_or_actor is_in_prison_type = dungeon } } @@ -1681,22 +1856,22 @@ move_to_house_arrest_interaction = { every_close_or_extended_family_member = { custom = all_family_members limit = { - scope:actor != this + scope:puppet_or_actor != this } add_opinion = { modifier = moved_to_house_arrest_opinion - target = scope:actor + target = scope:puppet_or_actor } } } - scope:actor = { - stress_impact = { + scope:puppet_or_actor = { + stress_and_fulfillment_impact = { sadistic = medium_stress_impact_gain vengeful = medium_stress_impact_gain } hidden_effect = { send_interface_message = { - type = event_prison_neutral + type = interaction_prison_single_side title = msg_move_prisoner_to_house_arrest right_icon = scope:recipient custom_tooltip = MOVE_PRISONER_TO_HOUSE_ARREST @@ -1745,11 +1920,11 @@ ransom_interaction = { } is_shown = { - scope:secondary_recipient = { + scope:secondary_recipient ?= { #exists = liege - is_imprisoned_by = scope:actor + is_imprisoned_by = scope:puppet_or_actor } - scope:actor != scope:recipient + scope:puppet_or_actor != scope:recipient } is_valid_showing_failures_only = { @@ -1764,8 +1939,8 @@ ransom_interaction = { } } cannot_release_former_regent_whilst_old_regent_holds_power_trigger = { - PRISONER = scope:recipient - REGENT = scope:recipient.var:imprisoned_by_diarch + PRISONER = scope:secondary_recipient + REGENT = scope:secondary_recipient.var:imprisoned_by_diarch } custom_tooltip = { text = is_currently_being_purged_tt @@ -1786,7 +1961,7 @@ ransom_interaction = { } # Set up event scopes and trigger the exchange. if = { - limit = { scope:secondary_recipient = { is_imprisoned_by = scope:actor } } # To prevent simultaneous release-shenanigans + limit = { scope:secondary_recipient = { is_imprisoned_by = scope:puppet_or_actor } } # To prevent simultaneous release-shenanigans scope:secondary_recipient = { save_scope_as = prisoner } @@ -1823,7 +1998,7 @@ ransom_interaction = { } } } - scope:actor = { + scope:puppet_or_actor = { save_scope_as = imprisoner if = { limit = { @@ -1854,7 +2029,7 @@ ransom_interaction = { scope:prisoner = { save_scope_as = portrait_second } # Must come after we save the payment value, or the payer won't know how much they need to pay. send_interface_message = { - type = event_prison_good + type = interaction_prison_ransom title = msg_ransom_prisoner right_icon = scope:portrait_first left_icon = scope:portrait_second @@ -1864,7 +2039,7 @@ ransom_interaction = { else = { # Must come after we save the payment value, or the payer won't know how much they need to pay. send_interface_message = { - type = event_prison_good + type = interaction_prison_ransom title = msg_ransom_prisoner right_icon = scope:portrait_first ransom_interaction_effect = yes @@ -1872,30 +2047,30 @@ ransom_interaction = { } # Struggle Catalyst - if = { - limit = { - any_character_struggle = { - involvement = involved - activate_struggle_catalyst_secondary_character_involvement_involved_trigger = { - CATALYST = catalyst_ransom_important - CHAR = scope:secondary_recipient - } - } - } - every_character_struggle = { - involvement = involved - limit = { - activate_struggle_catalyst_secondary_character_involvement_involved_trigger = { - CATALYST = catalyst_ransom_important - CHAR = scope:secondary_recipient - } - } - activate_struggle_catalyst = { - catalyst = catalyst_ransom_important - character = scope:actor - } - } - } +# if = { +# limit = { +# any_character_struggle = { +# involvement = involved +# activate_struggle_catalyst_secondary_character_involvement_involved_trigger = { +# CATALYST = catalyst_ransom_important +# CHAR = scope:secondary_recipient +# } +# } +# } +# every_character_struggle = { +# involvement = involved +# limit = { +# activate_struggle_catalyst_secondary_character_involvement_involved_trigger = { +# CATALYST = catalyst_ransom_important +# CHAR = scope:secondary_recipient +# } +# } +# activate_struggle_catalyst = { +# catalyst = catalyst_ransom_important +# character = scope:puppet_or_actor +# } +# } +# } } } } @@ -1913,7 +2088,7 @@ ransom_interaction = { } # Trigger notification event - scope:actor = { + scope:puppet_or_actor = { trigger_event = char_interaction.0131 } } @@ -1921,11 +2096,7 @@ ransom_interaction = { # Pay me an extortionate amount! send_option = { is_shown = { - scope:actor = { - dynasty ?= { - has_dynasty_perk = fp1_pillage_legacy_3 - } - } + scope:puppet_or_actor.dynasty ?= { has_dynasty_perk = fp1_pillage_legacy_3 } scope:recipient ?= { gold >= scope:secondary_recipient.increased_ransom_cost_value } @@ -1937,11 +2108,7 @@ ransom_interaction = { # If you don't have what they're worth, pay me what you have (extort version)! send_option = { is_shown = { - scope:actor = { - dynasty ?= { - has_dynasty_perk = fp1_pillage_legacy_3 - } - } + scope:puppet_or_actor.dynasty ?= { has_dynasty_perk = fp1_pillage_legacy_3 } scope:recipient ?= { gold < scope:secondary_recipient.increased_ransom_cost_value gold >= 1 @@ -1954,18 +2121,9 @@ ransom_interaction = { # Pay me what they're worth! send_option = { is_shown = { - scope:actor = { - OR = { - is_lowborn = yes - NOT = { - dynasty = { - has_dynasty_perk = fp1_pillage_legacy_3 - } - } - } - } + NOT = { scope:puppet_or_actor.dynasty ?= { has_dynasty_perk = fp1_pillage_legacy_3 } } scope:recipient ?= { - gold >= scope:secondary_recipient.ransom_cost_value + gold >= scope:secondary_recipient.normal_ransom_cost_value } } flag = gold @@ -1975,18 +2133,9 @@ ransom_interaction = { # If you don't have what they're worth, pay me what you have! send_option = { is_shown = { - scope:actor = { - OR = { - is_lowborn = yes - NOT = { - dynasty = { - has_dynasty_perk = fp1_pillage_legacy_3 - } - } - } - } + NOT = { scope:puppet_or_actor.dynasty ?= { has_dynasty_perk = fp1_pillage_legacy_3 } } scope:recipient ?= { - gold < scope:secondary_recipient.ransom_cost_value + gold < scope:secondary_recipient.normal_ransom_cost_value gold >= 1 } } @@ -2002,7 +2151,7 @@ ransom_interaction = { } } is_valid = { - scope:actor = { + scope:puppet_or_actor = { can_add_hook = { #To match the hook added through ransom_interaction_effect target = scope:recipient type = favor_hook @@ -2019,19 +2168,19 @@ ransom_interaction = { limit = { exists = scope:mass_action } scope:mass_action = no } - scope:actor = { + scope:puppet_or_actor = { government_has_flag = government_has_influence } } is_valid = { # Actor has enough influence - scope:actor = { influence >= medium_influence_value } + scope:puppet_or_actor = { influence >= medium_influence_value } # Recipient wants your influence scope:recipient = { government_has_flag = government_has_influence } # Both characters are within the same top realm custom_tooltip = { text = not_same_realm_tt - scope:recipient.top_liege = scope:actor.top_liege + scope:recipient.top_liege = scope:puppet_or_actor.top_liege } } flag = influence_send_option @@ -2041,43 +2190,81 @@ ransom_interaction = { # MPO Herd send_option = { is_shown = { # Actor must have a government that uses Herd - scope:actor = { - government_has_flag = government_is_nomadic + scope:puppet_or_actor = { + government_has_flag = government_has_herd exists = domicile is_ai = no } # Recipient must care about Herd scope:recipient ?= { - government_has_flag = government_is_nomadic + government_has_flag = government_has_herd exists = domicile } - } - is_valid = { # Recipient has enough Herd scope:recipient = { domicile.herd >= scope:recipient.ransom_herd_value } } + flag = herd_send_option localization = RANSOM_HERD_OPTION } + # MPO Herd + send_option = { + is_shown = { # Actor must have a government that uses Herd + scope:puppet_or_actor = { + government_has_flag = government_has_herd + exists = domicile + is_ai = no + } + # Recipient must care about Herd + scope:recipient ?= { + government_has_flag = government_has_herd + exists = domicile + } + scope:recipient.domicile.herd < scope:recipient.ransom_herd_value + } + flag = current_herd + localization = RANSOM_CURRENT_HERD_OPTION + } + localization_values = { EXTORTIONATE_RANSOM_COST = scope:secondary_recipient.increased_ransom_cost_value - RANSOM_COST = scope:secondary_recipient.ransom_cost_value + RANSOM_COST = scope:secondary_recipient.normal_ransom_cost_value CURRENT_GOLD = scope:recipient.gold RANSOM_HERD_COST = scope:recipient.ransom_herd_value + CURRENT_HERD = scope:recipient.domicile.herd } ai_accept = { base = 0 + + celestial_hierarchy_acceptance_modifier = { + ACTOR = scope:puppet_or_actor + RECIPIENT = scope:recipient + } + modifier = { # Greedy characters can have their greed get the better of them... add = { value = scope:recipient.ai_greed multiply = -0.5 + if = { + limit = { + OR = { + scope:herd_send_option = yes + scope:current_herd = yes + } + } + multiply = 0.5 + } } scope:recipient.ai_greed >= medium_positive_ai_value OR = { scope:gold = yes + scope:current_gold = yes scope:extortionate_gold = yes + scope:extortionate_current_gold = yes + scope:herd_send_option = yes + scope:current_herd = yes } scope:recipient != scope:secondary_recipient desc = AI_VALUE_MODIFIER_GREED @@ -2086,10 +2273,23 @@ ransom_interaction = { add = { value = scope:recipient.ai_greed multiply = -0.10 + if = { + limit = { + OR = { + scope:herd_send_option = yes + scope:current_herd = yes + } + } + multiply = 0.5 + } } OR = { scope:gold = yes + scope:current_gold = yes scope:extortionate_gold = yes + scope:extortionate_current_gold = yes + scope:herd_send_option = yes + scope:current_herd = yes } scope:recipient != scope:secondary_recipient scope:recipient.ai_greed <= medium_negative_ai_value @@ -2196,9 +2396,9 @@ ransom_interaction = { add = intimidated_reason_value trigger = { scope:recipient = { - target_is_liege_or_above = scope:actor + target_is_liege_or_above = scope:puppet_or_actor has_dread_level_towards = { - target = scope:actor + target = scope:puppet_or_actor level = 1 } } @@ -2210,9 +2410,9 @@ ransom_interaction = { add = cowed_reason_value trigger = { scope:recipient = { - target_is_liege_or_above = scope:actor + target_is_liege_or_above = scope:puppet_or_actor has_dread_level_towards = { - target = scope:actor + target = scope:puppet_or_actor level = 2 } } @@ -2234,10 +2434,6 @@ ransom_interaction = { hegemony = 6 } - ai_potential = { - always = yes - } - ai_will_do = { base = 0 @@ -2284,8 +2480,8 @@ ransom_interaction = { scope:favor = yes scope:recipient = { OR = { - is_vassal_of = scope:actor - liege ?= scope:actor + is_vassal_of = scope:puppet_or_actor + liege ?= scope:puppet_or_actor } } } @@ -2297,7 +2493,7 @@ ransom_interaction = { # involvement = involved # } # } -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # involvement = involved # } @@ -2306,7 +2502,7 @@ ransom_interaction = { # value = 0 # if = { # limit = { -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # phase_has_catalyst = catalyst_ransom_important # } @@ -2317,7 +2513,7 @@ ransom_interaction = { # } # else_if = { # limit = { -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # phase_has_catalyst = catalyst_ransom_important # } @@ -2330,7 +2526,7 @@ ransom_interaction = { modifier = { # Do not ransom at war factor = 0 - scope:actor = { is_at_war = yes } + scope:puppet_or_actor = { is_at_war = yes } } modifier = { # Don't annoy players @@ -2387,28 +2583,38 @@ pay_ransom_interaction = { is_shown = { exists = scope:recipient - scope:secondary_recipient = { - this != scope:actor + exists = scope:puppet_or_actor + scope:puppet_or_actor ?= { + trigger_if = { + limit = { + is_ai = yes + NOT = { puppeteer ?= { is_ai = no } } + } + gold >= 25 + } + } + scope:secondary_recipient ?= { + this != scope:puppet_or_actor is_imprisoned_by = scope:recipient OR = { - liege ?= scope:actor # You can ransom anyone you have in your court - is_close_family_of = scope:actor # And anyone who is your close family + liege ?= scope:puppet_or_actor # You can ransom anyone you have in your court + is_close_family_of = scope:puppet_or_actor # And anyone who is your close family dynasty ?= { # And anyone from your Dynasty - this ?= scope:actor.dynasty + this ?= scope:puppet_or_actor.dynasty } any_spouse = { # And anyone married to one of your close kin or dynasty members OR = { - is_close_family_of = scope:actor + is_close_family_of = scope:puppet_or_actor dynasty ?= { - this ?= scope:actor.dynasty + this ?= scope:puppet_or_actor.dynasty } } } - has_relation_lover = scope:actor # And Lovers - has_relation_friend = scope:actor # And Friends + has_relation_lover = scope:puppet_or_actor # And Lovers + has_relation_friend = scope:puppet_or_actor # And Friends } } - scope:actor != scope:recipient + scope:puppet_or_actor != scope:recipient } is_valid_showing_failures_only = { @@ -2445,7 +2651,7 @@ pay_ransom_interaction = { custom_tooltip = has_person_haggler_increase_ransom_cost } } - scope:actor = { + scope:puppet_or_actor = { save_scope_as = payer if = { limit = { @@ -2470,26 +2676,26 @@ pay_ransom_interaction = { limit = { scope:prisoner = { # Stress impact for random courtiers NOR = { - is_vassal_of = scope:actor - is_consort_of = scope:actor - is_close_family_of = scope:actor + is_vassal_of = scope:puppet_or_actor + is_consort_of = scope:puppet_or_actor + is_close_family_of = scope:puppet_or_actor dynasty ?= { - this ?= scope:actor.dynasty + this ?= scope:puppet_or_actor.dynasty } any_spouse = { OR = { - is_close_family_of = scope:actor + is_close_family_of = scope:puppet_or_actor dynasty ?= { - this ?= scope:actor.dynasty + this ?= scope:puppet_or_actor.dynasty } } } - has_relation_lover = scope:actor - has_relation_friend = scope:actor + has_relation_lover = scope:puppet_or_actor + has_relation_friend = scope:puppet_or_actor } } } - stress_impact = { + stress_and_fulfillment_impact = { compassionate = minor_stress_impact_loss generous = medium_stress_impact_loss } @@ -2498,26 +2704,26 @@ pay_ransom_interaction = { limit = { scope:prisoner = { OR = { - is_vassal_of = scope:actor - is_consort_of = scope:actor - is_close_family_of = scope:actor + is_vassal_of = scope:puppet_or_actor + is_consort_of = scope:puppet_or_actor + is_close_family_of = scope:puppet_or_actor dynasty ?= { - this ?= scope:actor.dynasty + this ?= scope:puppet_or_actor.dynasty } any_spouse = { OR = { - is_close_family_of = scope:actor + is_close_family_of = scope:puppet_or_actor dynasty ?= { - this ?= scope:actor.dynasty + this ?= scope:puppet_or_actor.dynasty } } } - has_relation_lover = scope:actor - has_relation_friend = scope:actor + has_relation_lover = scope:puppet_or_actor + has_relation_friend = scope:puppet_or_actor } } } - stress_impact = { + stress_and_fulfillment_impact = { compassionate = medium_stress_impact_loss generous = minor_stress_impact_loss just = minor_stress_impact_loss @@ -2527,10 +2733,10 @@ pay_ransom_interaction = { if = { # Lustful characters want their lovers back limit = { scope:prisoner = { - has_relation_lover = scope:actor + has_relation_lover = scope:puppet_or_actor } } - stress_impact = { + stress_and_fulfillment_impact = { lustful = major_stress_impact_loss } } @@ -2539,12 +2745,12 @@ pay_ransom_interaction = { limit = { scope:prisoner = { OR = { - has_relation_friend = scope:actor - has_relation_lover = scope:actor + has_relation_friend = scope:puppet_or_actor + has_relation_lover = scope:puppet_or_actor } } } - stress_impact = { + stress_and_fulfillment_impact = { loyal = major_stress_impact_loss } } @@ -2555,7 +2761,7 @@ pay_ransom_interaction = { is_close_family_of = scope:payer } } - stress_impact = { + stress_and_fulfillment_impact = { family_first = miniscule_stress_impact_loss } } @@ -2622,7 +2828,7 @@ pay_ransom_interaction = { } scope:imprisoner = { send_interface_message = { - type = event_prison_neutral + type = interaction_prison_ransom title = recipient_released_from_prison right_icon = scope:prisoner left_icon = scope:imprisoner @@ -2686,7 +2892,7 @@ pay_ransom_interaction = { } if = { limit = { scope:hook = yes } - scope:actor = { + scope:puppet_or_actor = { use_hook = scope:recipient } } @@ -2694,7 +2900,7 @@ pay_ransom_interaction = { # If we're a clan this interaction affects unity add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:prisoner VALUE = medium_unity_gain DESC = clan_unity_ransom.desc @@ -2715,7 +2921,7 @@ pay_ransom_interaction = { } # Trigger notification event - scope:actor = { + scope:puppet_or_actor = { trigger_event = char_interaction.0141 } } @@ -2723,26 +2929,18 @@ pay_ransom_interaction = { send_option = { is_shown = { exists = scope:recipient - scope:recipient = { - dynasty ?= { - has_dynasty_perk = fp1_pillage_legacy_3 - } - } + scope:recipient.dynasty ?= { has_dynasty_perk = fp1_pillage_legacy_3 } } is_valid = { exists = scope:recipient - scope:actor = { + scope:puppet_or_actor = { gold >= scope:secondary_recipient.increased_ransom_cost_value } } starts_enabled = { exists = scope:recipient - scope:recipient = { - dynasty ?= { - has_dynasty_perk = fp1_pillage_legacy_3 - } - } - scope:actor = { + scope:recipient.dynasty ?= { has_dynasty_perk = fp1_pillage_legacy_3 } + scope:puppet_or_actor = { gold >= scope:secondary_recipient.increased_ransom_cost_value } } @@ -2754,24 +2952,16 @@ pay_ransom_interaction = { send_option = { is_shown = { exists = scope:recipient - scope:recipient = { - dynasty ?= { - has_dynasty_perk = fp1_pillage_legacy_3 - } - } - scope:actor = { + scope:recipient.dynasty ?= { has_dynasty_perk = fp1_pillage_legacy_3 } + scope:puppet_or_actor ?= { gold < scope:secondary_recipient.increased_ransom_cost_value gold > 0 } } starts_enabled = { exists = scope:recipient - scope:recipient = { - dynasty ?= { - has_dynasty_perk = fp1_pillage_legacy_3 - } - } - scope:actor = { + scope:recipient.dynasty ?= { has_dynasty_perk = fp1_pillage_legacy_3 } + scope:puppet_or_actor = { gold < scope:secondary_recipient.increased_ransom_cost_value gold > 0 } @@ -2783,37 +2973,19 @@ pay_ransom_interaction = { send_option = { is_shown = { exists = scope:recipient - scope:recipient = { - OR = { - is_lowborn = yes - NOT = { - dynasty = { - has_dynasty_perk = fp1_pillage_legacy_3 - } - } - } - } + NOT = { scope:recipient.dynasty ?= { has_dynasty_perk = fp1_pillage_legacy_3 } } } is_valid = { exists = scope:recipient - scope:actor = { - gold >= scope:secondary_recipient.ransom_cost_value + scope:puppet_or_actor = { + gold >= scope:secondary_recipient.normal_ransom_cost_value } } starts_enabled = { exists = scope:recipient - scope:recipient = { - OR = { - is_lowborn = yes - NOT = { - dynasty = { - has_dynasty_perk = fp1_pillage_legacy_3 - } - } - } - } - scope:actor = { - gold >= scope:secondary_recipient.ransom_cost_value + NOT = { scope:recipient.dynasty ?= { has_dynasty_perk = fp1_pillage_legacy_3 } } + scope:puppet_or_actor = { + gold >= scope:secondary_recipient.normal_ransom_cost_value } } flag = gold @@ -2824,35 +2996,17 @@ pay_ransom_interaction = { send_option = { is_shown = { exists = scope:recipient - scope:recipient = { - OR = { - is_lowborn = yes - NOT = { - dynasty = { - has_dynasty_perk = fp1_pillage_legacy_3 - } - } - } - } - scope:actor = { - gold < scope:secondary_recipient.ransom_cost_value + NOT = { scope:recipient.dynasty ?= { has_dynasty_perk = fp1_pillage_legacy_3 } } + scope:puppet_or_actor ?= { + gold < scope:secondary_recipient.normal_ransom_cost_value gold > 0 } } starts_enabled = { exists = scope:recipient - scope:recipient = { - OR = { - is_lowborn = yes - NOT = { - dynasty = { - has_dynasty_perk = fp1_pillage_legacy_3 - } - } - } - } - scope:actor = { - gold < scope:secondary_recipient.ransom_cost_value + NOT = { scope:recipient.dynasty ?= { has_dynasty_perk = fp1_pillage_legacy_3 } } + scope:puppet_or_actor = { + gold < scope:secondary_recipient.normal_ransom_cost_value gold > 0 } } @@ -2865,7 +3019,7 @@ pay_ransom_interaction = { exists = scope:recipient scope:recipient = { can_add_hook = { #To match the hook added through ransom_interaction_effect - target = scope:actor + target = scope:puppet_or_actor type = favor_hook } } @@ -2876,19 +3030,28 @@ pay_ransom_interaction = { send_option = { # EP3 Influence is_shown = { # Actor must have a government that uses influence - scope:actor = { + scope:puppet_or_actor ?= { government_has_flag = government_has_influence } } is_valid = { # Actor has enough influence - scope:actor = { influence >= medium_influence_value } + scope:puppet_or_actor = { influence >= medium_influence_value } # Recipient has enough influence scope:recipient = { government_has_flag = government_has_influence } # Both characters are within the same top realm - custom_tooltip = { - text = not_same_realm_tt - scope:recipient.top_liege = scope:actor.top_liege + trigger_if = { + limit = { scope:actor = scope:puppet_or_actor } + custom_tooltip = { + text = not_same_realm_tt + scope:recipient.top_liege = scope:puppet_or_actor.top_liege + } + } + trigger_else = { + custom_tooltip = { + text = not_same_realm_tt_puppeteer + scope:recipient.top_liege = scope:puppet_or_actor.top_liege + } } } flag = influence_send_option @@ -2897,30 +3060,47 @@ pay_ransom_interaction = { send_option = { # MPO Herd is_shown = { # Actor must have a government that uses Herd - scope:actor = { - government_has_flag = government_is_nomadic + scope:puppet_or_actor ?= { + government_has_flag = government_has_herd exists = domicile - is_ai = no + scope:actor = { is_ai = no } } # Recipient must care about Herd scope:recipient = { - government_has_flag = government_is_nomadic + government_has_flag = government_has_herd exists = domicile } + scope:puppet_or_actor ?= { domicile.herd >= scope:secondary_recipient.ransom_herd_value } } - is_valid = { - # Actor has enough Herd - scope:actor = { domicile.herd >= scope:actor.ransom_herd_value } - } + flag = herd_send_option localization = PAY_FOR_BETTER_AI_ACCEPTANCE } + send_option = { # MPO Herd + is_shown = { # Actor must have a government that uses Herd + scope:puppet_or_actor ?= { + government_has_flag = government_has_herd + exists = domicile + scope:actor = { is_ai = no } + } + # Recipient must care about Herd + scope:recipient = { + government_has_flag = government_has_herd + exists = domicile + } + scope:puppet_or_actor ?= { domicile.herd < scope:secondary_recipient.ransom_herd_value } + } + + flag = current_herd + localization = RANSOM_CURRENT_HERD_PAY_OPTION + } + #Use hook send_option = { is_valid = { exists = scope:recipient - scope:actor = { + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } @@ -2928,7 +3108,7 @@ pay_ransom_interaction = { localization = SCHEME_HOOK } should_use_extra_icon = { - scope:actor = { has_usable_hook = scope:recipient } + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } extra_icon = "gfx/interface/icons/character_interactions/hook_icon.dds" @@ -2936,13 +3116,20 @@ pay_ransom_interaction = { localization_values = { EXTORTIONATE_RANSOM_COST = scope:secondary_recipient.increased_ransom_cost_value - RANSOM_COST = scope:secondary_recipient.ransom_cost_value - CURRENT_GOLD = scope:actor.gold - RANSOM_HERD_COST = scope:actor.ransom_herd_value + RANSOM_COST = scope:secondary_recipient.normal_ransom_cost_value + CURRENT_GOLD = scope:puppet_or_actor.gold + RANSOM_HERD_COST = scope:secondary_recipient.ransom_herd_value + CURRENT_HERD = scope:puppet_or_actor.domicile.herd } ai_accept = { base = 0 + + celestial_hierarchy_acceptance_modifier = { + ACTOR = scope:puppet_or_actor + RECIPIENT = scope:recipient + } + modifier = { add = 50 OR = { @@ -2955,7 +3142,7 @@ pay_ransom_interaction = { add = 25 scope:current_gold = yes AND = { - scope:actor = { gold >= scope:secondary_recipient.half_ransom_cost_value } + scope:puppet_or_actor = { gold >= scope:secondary_recipient.half_ransom_cost_value } NOT = { scope:recipient.ai_greed >= medium_positive_ai_value } } desc = "GOLD_POSITIVE_REASON" @@ -2964,7 +3151,7 @@ pay_ransom_interaction = { add = 25 scope:extortionate_current_gold = yes AND = { - scope:actor = { gold >= scope:secondary_recipient.half_increased_ransom_cost_value } + scope:puppet_or_actor = { gold >= scope:secondary_recipient.half_increased_ransom_cost_value } NOT = { scope:recipient.ai_greed >= medium_positive_ai_value } } desc = "GOLD_POSITIVE_REASON" @@ -2972,13 +3159,13 @@ pay_ransom_interaction = { modifier = { add = 50 scope:favor = yes - scope:recipient.top_liege = scope:actor.top_liege + scope:recipient.top_liege = scope:puppet_or_actor.top_liege desc = "FAVOR_POSITIVE_REASON" } modifier = { add = 0 scope:favor = yes - scope:recipient.top_liege != scope:actor.top_liege + scope:recipient.top_liege != scope:puppet_or_actor.top_liege desc = "NO_USE_FOR_A_FAVOR_REASON" } modifier = { # For clarification @@ -2988,7 +3175,7 @@ pay_ransom_interaction = { scope:extortionate_current_gold = yes } OR = { - scope:actor = { gold < scope:secondary_recipient.half_ransom_cost_value } + scope:puppet_or_actor = { gold < scope:secondary_recipient.half_ransom_cost_value } scope:recipient.ai_greed >= medium_positive_ai_value } desc = "WANTS_MORE_GOLD" @@ -3010,7 +3197,7 @@ pay_ransom_interaction = { modifier = { # At war add = -300 scope:recipient = { - is_at_war_with = scope:actor + is_at_war_with = scope:puppet_or_actor } desc = "IS_AT_WAR_REASON" } @@ -3035,7 +3222,7 @@ pay_ransom_interaction = { } #opinion_modifier = { # A lot more likely if Recipient likes Actor # who = scope:recipient - # opinion_target = scope:actor + # opinion_target = scope:puppet_or_actor # multiplier = 1.0 # desc = AI_OPINION_REASON #} @@ -3054,9 +3241,9 @@ pay_ransom_interaction = { add = 40 trigger = { scope:recipient = { - target_is_liege_or_above = scope:actor + target_is_liege_or_above = scope:puppet_or_actor has_dread_level_towards = { - target = scope:actor + target = scope:puppet_or_actor level = 1 } } @@ -3068,9 +3255,9 @@ pay_ransom_interaction = { add = 100 trigger = { scope:recipient = { - target_is_liege_or_above = scope:actor + target_is_liege_or_above = scope:puppet_or_actor has_dread_level_towards = { - target = scope:actor + target = scope:puppet_or_actor level = 2 } } @@ -3089,15 +3276,21 @@ pay_ransom_interaction = { scope:herd_send_option = yes desc = HERD_INTERACTION_ACCEPTANCE_SEND_OPTION } + + modifier = { + add = 10 + scope:current_herd = yes + desc = HERD_INTERACTION_ACCEPTANCE_SEND_OPTION + } } auto_accept = { custom_description = { text = "spending_hook" - subject = scope:actor + subject = scope:puppet_or_actor object = scope:recipient scope:hook = yes - scope:actor = { has_strong_hook = scope:recipient } + scope:puppet_or_actor = { has_strong_hook = scope:recipient } } } @@ -3124,10 +3317,6 @@ pay_ransom_interaction = { hegemony = 6 } - ai_potential = { - gold >= 25 - } - ai_target_quick_trigger = { prison = yes } @@ -3141,7 +3330,7 @@ pay_ransom_interaction = { scope:gold = yes scope:extortionate_gold = yes AND = { - scope:actor = { + scope:puppet_or_actor = { gold >= 25 } scope:secondary_recipient = { @@ -3170,8 +3359,8 @@ pay_ransom_interaction = { scope:favor = yes scope:recipient = { OR = { - is_vassal_of = scope:actor - liege ?= scope:actor + is_vassal_of = scope:puppet_or_actor + liege ?= scope:puppet_or_actor } } } @@ -3182,7 +3371,7 @@ pay_ransom_interaction = { scope:gold = yes scope:extortionate_gold = yes AND = { - scope:actor = { + scope:puppet_or_actor = { gold >= 25 } scope:secondary_recipient = { @@ -3197,14 +3386,14 @@ pay_ransom_interaction = { scope:favor = yes scope:recipient = { OR = { - is_vassal_of = scope:actor - liege ?= scope:actor + is_vassal_of = scope:puppet_or_actor + liege ?= scope:puppet_or_actor } } } } scope:secondary_recipient = { - is_primary_heir_of = scope:actor + is_primary_heir_of = scope:puppet_or_actor } } @@ -3213,27 +3402,27 @@ pay_ransom_interaction = { ai_compassion < high_positive_ai_value scope:secondary_recipient = { NOR = { - is_heir_of = scope:actor - is_child_of = scope:actor - is_grandchild_of = scope:actor - is_great_grandchild_of = scope:actor - is_consort_of = scope:actor - is_parent_of = scope:actor - is_grandparent_of = scope:actor - is_great_grandparent_of = scope:actor - has_relation_friend = scope:actor - has_relation_lover = scope:actor - has_secret_relation_lover = scope:actor + is_heir_of = scope:puppet_or_actor + is_child_of = scope:puppet_or_actor + is_grandchild_of = scope:puppet_or_actor + is_great_grandchild_of = scope:puppet_or_actor + is_consort_of = scope:puppet_or_actor + is_parent_of = scope:puppet_or_actor + is_grandparent_of = scope:puppet_or_actor + is_great_grandparent_of = scope:puppet_or_actor + has_relation_friend = scope:puppet_or_actor + has_relation_lover = scope:puppet_or_actor + has_secret_relation_lover = scope:puppet_or_actor any_spouse = { OR = { - is_heir_of = scope:actor - is_child_of = scope:actor - is_grandchild_of = scope:actor - is_great_grandchild_of = scope:actor - is_parent_of = scope:actor - is_grandparent_of = scope:actor - is_great_grandparent_of = scope:actor - has_relation_friend = scope:actor + is_heir_of = scope:puppet_or_actor + is_child_of = scope:puppet_or_actor + is_grandchild_of = scope:puppet_or_actor + is_great_grandchild_of = scope:puppet_or_actor + is_parent_of = scope:puppet_or_actor + is_grandparent_of = scope:puppet_or_actor + is_great_grandparent_of = scope:puppet_or_actor + has_relation_friend = scope:puppet_or_actor } } } @@ -3245,17 +3434,17 @@ pay_ransom_interaction = { ai_compassion >= high_positive_ai_value scope:secondary_recipient = { NOR = { - is_heir_of = scope:actor - is_close_or_extended_family_of = scope:actor - is_consort_of = scope:actor - has_relation_friend = scope:actor - has_relation_lover = scope:actor - has_secret_relation_lover = scope:actor + is_heir_of = scope:puppet_or_actor + is_close_or_extended_family_of = scope:puppet_or_actor + is_consort_of = scope:puppet_or_actor + has_relation_friend = scope:puppet_or_actor + has_relation_lover = scope:puppet_or_actor + has_secret_relation_lover = scope:puppet_or_actor any_spouse = { OR = { - is_heir_of = scope:actor - is_close_or_extended_family_of = scope:actor - has_relation_friend = scope:actor + is_heir_of = scope:puppet_or_actor + is_close_or_extended_family_of = scope:puppet_or_actor + has_relation_friend = scope:puppet_or_actor } } } @@ -3267,22 +3456,22 @@ pay_ransom_interaction = { ai_greed >= high_positive_ai_value scope:secondary_recipient = { NOR = { # Very Greedy rulers only ransom people in their own realm, or their heir - is_courtier_of = scope:actor - is_vassal_or_below_of = scope:actor - is_heir_of = scope:actor + is_courtier_of = scope:puppet_or_actor + is_vassal_or_below_of = scope:puppet_or_actor + is_heir_of = scope:puppet_or_actor } NOR = { - is_heir_of = scope:actor - is_close_or_extended_family_of = scope:actor - is_consort_of = scope:actor - has_relation_friend = scope:actor - has_relation_lover = scope:actor - has_secret_relation_lover = scope:actor + is_heir_of = scope:puppet_or_actor + is_close_or_extended_family_of = scope:puppet_or_actor + is_consort_of = scope:puppet_or_actor + has_relation_friend = scope:puppet_or_actor + has_relation_lover = scope:puppet_or_actor + has_secret_relation_lover = scope:puppet_or_actor any_spouse = { OR = { - is_heir_of = scope:actor - is_close_or_extended_family_of = scope:actor - has_relation_friend = scope:actor + is_heir_of = scope:puppet_or_actor + is_close_or_extended_family_of = scope:puppet_or_actor + has_relation_friend = scope:puppet_or_actor } } } @@ -3295,13 +3484,13 @@ pay_ransom_interaction = { has_trait = lustful ai_greed <= 50 scope:secondary_recipient = { - has_relation_lover = scope:actor + has_relation_lover = scope:puppet_or_actor } OR = { scope:gold = yes scope:extortionate_gold = yes AND = { - scope:actor = { + scope:puppet_or_actor = { gold >= 25 } scope:secondary_recipient = { @@ -3320,15 +3509,15 @@ pay_ransom_interaction = { has_trait = loyal scope:secondary_recipient = { OR = { - has_relation_lover = scope:actor - has_relation_friend = scope:actor + has_relation_lover = scope:puppet_or_actor + has_relation_friend = scope:puppet_or_actor } } OR = { scope:gold = yes scope:extortionate_gold = yes AND = { - scope:actor = { + scope:puppet_or_actor = { gold >= 25 } scope:secondary_recipient = { @@ -3353,7 +3542,7 @@ pay_ransom_interaction = { ai_honor >= high_positive_ai_value } scope:secondary_recipient = { - is_liege_or_above_of = scope:actor + is_liege_or_above_of = scope:puppet_or_actor } OR = { scope:gold = yes @@ -3367,8 +3556,8 @@ pay_ransom_interaction = { scope:favor = yes scope:recipient = { NOR = { - is_vassal_of = scope:actor - liege ?= scope:actor + is_vassal_of = scope:puppet_or_actor + liege ?= scope:puppet_or_actor } } } @@ -3391,7 +3580,7 @@ pay_ransom_interaction = { # involvement = involved # } # } -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # involvement = involved # } @@ -3400,7 +3589,7 @@ pay_ransom_interaction = { # value = 0 # if = { # limit = { -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # phase_has_catalyst = catalyst_ransom_important # } @@ -3411,7 +3600,7 @@ pay_ransom_interaction = { # } # else_if = { # limit = { -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # phase_has_catalyst = catalyst_ransom_important # } @@ -3434,7 +3623,7 @@ pay_ransom_interaction = { scope:extortionate_current_gold = yes scope:gold = yes AND = { - scope:actor = { + scope:puppet_or_actor = { gold >= 25 } scope:current_gold = yes @@ -3477,31 +3666,31 @@ ransom_me_interaction = { redirect = { # So that users can ransom themselves by clicking on their portrait if = { limit = { - scope:actor = scope:recipient - exists = scope:actor.imprisoner + scope:puppet_or_actor = scope:recipient + exists = scope:puppet_or_actor.imprisoner } - scope:actor.imprisoner = { save_scope_as = recipient } + scope:puppet_or_actor.imprisoner = { save_scope_as = recipient } } } is_shown = { - scope:actor = { is_imprisoned_by = scope:recipient } + scope:puppet_or_actor = { is_imprisoned_by = scope:recipient } } is_valid_showing_failures_only = { - scope:actor = { + scope:puppet_or_actor = { custom_description = { text = "currently_being_tortured" NOT = { has_character_flag = is_being_tortured } } } cannot_release_former_regent_whilst_old_regent_holds_power_trigger = { - PRISONER = scope:recipient - REGENT = scope:recipient.var:imprisoned_by_diarch + PRISONER = scope:puppet_or_actor + REGENT = scope:puppet_or_actor.var:imprisoned_by_diarch } custom_tooltip = { text = is_currently_being_purged_tt - scope:recipient = { + scope:puppet_or_actor = { NOT = { has_character_flag = is_currently_being_purged } @@ -3511,14 +3700,14 @@ ransom_me_interaction = { on_accept = { if = { - limit = { scope:actor = { is_imprisoned_by = scope:recipient } } - scope:actor = { + limit = { scope:puppet_or_actor = { is_imprisoned_by = scope:recipient } } + scope:puppet_or_actor = { save_scope_as = prisoner } scope:recipient = { save_scope_as = imprisoner } - scope:actor = { + scope:puppet_or_actor = { save_scope_as = payer if = { limit = { @@ -3563,12 +3752,12 @@ ransom_me_interaction = { type = person_haggler_camp_officer save_scope_as = haggler } - scope:actor = { + scope:puppet_or_actor = { custom_tooltip = has_person_haggler_increase_ransom_cost } } send_interface_message = { - type = event_prison_neutral + type = interaction_prison_ransom title = recipient_released_from_prison right_icon = scope:prisoner left_icon = scope:imprisoner @@ -3576,34 +3765,34 @@ ransom_me_interaction = { } # Struggle Catalyst - if = { - limit = { - any_character_struggle = { - involvement = involved - activate_struggle_catalyst_secondary_character_involvement_involved_trigger = { - CATALYST = catalyst_ransom_important - CHAR = scope:prisoner - } - } - } - every_character_struggle = { - involvement = involved - limit = { - activate_struggle_catalyst_secondary_character_involvement_involved_trigger = { - CATALYST = catalyst_ransom_important - CHAR = scope:prisoner - } - } - activate_struggle_catalyst = { - catalyst = catalyst_ransom_important - character = scope:imprisoner - } - } - } +# if = { +# limit = { +# any_character_struggle = { +# involvement = involved +# activate_struggle_catalyst_secondary_character_involvement_involved_trigger = { +# CATALYST = catalyst_ransom_important +# CHAR = scope:prisoner +# } +# } +# } +# every_character_struggle = { +# involvement = involved +# limit = { +# activate_struggle_catalyst_secondary_character_involvement_involved_trigger = { +# CATALYST = catalyst_ransom_important +# CHAR = scope:prisoner +# } +# } +# activate_struggle_catalyst = { +# catalyst = catalyst_ransom_important +# character = scope:imprisoner +# } +# } +# } } if = { limit = { always = scope:hook } - scope:actor = { + scope:puppet_or_actor = { use_hook = scope:recipient } } @@ -3614,7 +3803,7 @@ ransom_me_interaction = { # If a player declines this ransom offer, wait 10 years before sending another one (they presumably have reasons for keeping you in prison). if = { limit = { scope:recipient = { is_ai = no } } - scope:actor = { + scope:puppet_or_actor = { add_character_flag = { flag = character_ransom_refused_by_player years = 10 @@ -3623,7 +3812,7 @@ ransom_me_interaction = { } # Trigger notification event - scope:actor = { + scope:puppet_or_actor = { trigger_event = char_interaction.0151 } } @@ -3631,14 +3820,10 @@ ransom_me_interaction = { send_option = { is_shown = { exists = scope:recipient - scope:recipient = { - dynasty ?= { - has_dynasty_perk = fp1_pillage_legacy_3 - } - } + scope:recipient.dynasty ?= { has_dynasty_perk = fp1_pillage_legacy_3 } } is_valid = { - scope:actor = { + scope:puppet_or_actor = { gold >= increased_ransom_cost } } @@ -3650,12 +3835,8 @@ ransom_me_interaction = { send_option = { is_shown = { exists = scope:recipient - scope:recipient = { - dynasty ?= { - has_dynasty_perk = fp1_pillage_legacy_3 - } - } - scope:actor = { + scope:recipient.dynasty ?= { has_dynasty_perk = fp1_pillage_legacy_3 } + scope:puppet_or_actor = { gold < increased_ransom_cost gold > 0 } @@ -3667,19 +3848,10 @@ ransom_me_interaction = { send_option = { is_shown = { exists = scope:recipient - scope:recipient = { - OR = { - is_lowborn = yes - NOT = { - dynasty = { - has_dynasty_perk = fp1_pillage_legacy_3 - } - } - } - } + NOT = { scope:recipient.dynasty ?= { has_dynasty_perk = fp1_pillage_legacy_3 } } } is_valid = { - scope:actor = { gold >= ransom_cost } + scope:puppet_or_actor = { gold >= normal_ransom_cost_value } } flag = gold localization = "RANSOM_GOLD_OPTION" @@ -3696,8 +3868,8 @@ ransom_me_interaction = { } } } - scope:actor = { - gold < ransom_cost + scope:puppet_or_actor = { + gold < normal_ransom_cost_value gold > 0 } } @@ -3709,7 +3881,7 @@ ransom_me_interaction = { is_valid = { scope:recipient = { can_add_hook = { #To match the hook added through ransom_interaction_effect - target = scope:actor + target = scope:puppet_or_actor type = favor_hook } } @@ -3720,19 +3892,19 @@ ransom_me_interaction = { send_option = { # EP3 Influence is_shown = { # Actor must have a government that uses influence - scope:actor = { + scope:puppet_or_actor = { government_has_flag = government_has_influence } } is_valid = { # Actor has enough influence - scope:actor = { influence >= medium_influence_value } + scope:puppet_or_actor = { influence >= medium_influence_value } # Recipient wants your influence scope:recipient = { government_has_flag = government_has_influence } # Both characters are within the same top realm custom_tooltip = { text = not_same_realm_tt - scope:recipient.top_liege = scope:actor.top_liege + scope:recipient.top_liege = scope:puppet_or_actor.top_liege } } flag = influence_send_option @@ -3741,28 +3913,45 @@ ransom_me_interaction = { send_option = { # MPO Herd is_shown = { # Actor must have a government that uses Herd - scope:actor = { - government_has_flag = government_is_nomadic + scope:puppet_or_actor = { + government_has_flag = government_has_herd exists = domicile } # Recipient must care about Herd scope:recipient = { - government_has_flag = government_is_nomadic + government_has_flag = government_has_herd exists = domicile } + scope:puppet_or_actor = { domicile.herd >= ransom_herd_value } } - is_valid = { - # Actor has enough Herd - scope:actor = { domicile.herd >= ransom_herd_value } - } + flag = herd_send_option localization = PAY_FOR_BETTER_AI_ACCEPTANCE } + send_option = { # MPO Herd + is_shown = { # Actor must have a government that uses Herd + scope:puppet_or_actor = { + government_has_flag = government_has_herd + exists = domicile + is_ai = no + } + # Recipient must care about Herd + scope:recipient = { + government_has_flag = government_has_herd + exists = domicile + } + scope:puppet_or_actor = { domicile.herd < ransom_herd_value } + } + + flag = current_herd + localization = RANSOM_CURRENT_HERD_PAY_OPTION + } + #Use hook send_option = { is_valid = { - scope:actor = { + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } @@ -3770,21 +3959,28 @@ ransom_me_interaction = { localization = SCHEME_HOOK } should_use_extra_icon = { - scope:actor = { has_usable_hook = scope:recipient } + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } extra_icon = "gfx/interface/icons/character_interactions/hook_icon.dds" send_options_exclusive = no localization_values = { - EXTORTIONATE_RANSOM_COST = scope:actor.increased_ransom_cost_value - RANSOM_COST = scope:actor.ransom_cost_value - CURRENT_GOLD = scope:actor.gold - RANSOM_HERD_COST = scope:actor.ransom_herd_value + EXTORTIONATE_RANSOM_COST = scope:puppet_or_actor.increased_ransom_cost_value + RANSOM_COST = scope:puppet_or_actor.normal_ransom_cost_value + CURRENT_GOLD = scope:puppet_or_actor.gold + RANSOM_HERD_COST = scope:puppet_or_actor.ransom_herd_value + CURRENT_HERD = scope:puppet_or_actor.domicile.herd } ai_accept = { base = 0 + + celestial_hierarchy_acceptance_modifier = { + ACTOR = scope:puppet_or_actor + RECIPIENT = scope:recipient + } + modifier = { add = 50 OR = { @@ -3798,7 +3994,7 @@ ransom_me_interaction = { add = 25 scope:current_gold = yes AND = { - scope:actor = { gold >= half_ransom_cost_value } + scope:puppet_or_actor = { gold >= half_ransom_cost_value } NOT = { scope:recipient.ai_greed >= medium_positive_ai_value } } desc = "GOLD_POSITIVE_REASON" @@ -3808,7 +4004,7 @@ ransom_me_interaction = { add = 25 scope:extortionate_current_gold = yes AND = { - scope:actor = { gold >= half_increased_ransom_cost_value } + scope:puppet_or_actor = { gold >= half_increased_ransom_cost_value } NOT = { scope:recipient.ai_greed >= medium_positive_ai_value } } desc = "GOLD_POSITIVE_REASON" @@ -3817,7 +4013,7 @@ ransom_me_interaction = { modifier = { add = 50 scope:favor = yes - scope:recipient.top_liege = scope:actor.top_liege + scope:recipient.top_liege = scope:puppet_or_actor.top_liege desc = "FAVOR_POSITIVE_REASON" } @@ -3829,7 +4025,7 @@ ransom_me_interaction = { scope:extortionate_gold = yes } OR = { - scope:recipient.top_liege != scope:actor.top_liege + scope:recipient.top_liege != scope:puppet_or_actor.top_liege scope:recipient.ai_greed >= medium_positive_ai_value } desc = "NO_USE_FOR_A_FAVOR_REASON" @@ -3842,7 +4038,7 @@ ransom_me_interaction = { scope:extortionate_current_gold = yes } OR = { - scope:actor = { gold < half_ransom_cost_value } + scope:puppet_or_actor = { gold < half_ransom_cost_value } scope:recipient.ai_greed >= medium_positive_ai_value } desc = "WANTS_MORE_GOLD" @@ -3850,7 +4046,7 @@ ransom_me_interaction = { #opinion_modifier = { # A lot more likely if Recipient likes Actor # who = scope:recipient - # opinion_target = scope:actor + # opinion_target = scope:puppet_or_actor # multiplier = 1.0 # desc = AI_OPINION_REASON #} @@ -3858,14 +4054,14 @@ ransom_me_interaction = { modifier = { # Say no to rivals add = -55 scope:recipient = { - has_relation_rival = scope:actor + has_relation_rival = scope:puppet_or_actor } desc = "ACTOR_RIVAL_TO_ME_REASON" } modifier = { # Say no to nemesis add = -300 scope:recipient = { - has_relation_nemesis = scope:actor + has_relation_nemesis = scope:puppet_or_actor } desc = "ACTOR_NEMESIS_TO_ME_REASON" } @@ -3874,7 +4070,7 @@ ransom_me_interaction = { modifier = { # At war add = -300 scope:recipient = { - is_at_war_with = scope:actor + is_at_war_with = scope:puppet_or_actor } desc = "IS_AT_WAR_REASON" } @@ -3889,9 +4085,9 @@ ransom_me_interaction = { add = intimidated_reason_value trigger = { scope:recipient = { - target_is_liege_or_above = scope:actor + target_is_liege_or_above = scope:puppet_or_actor has_dread_level_towards = { - target = scope:actor + target = scope:puppet_or_actor level = 1 } } @@ -3903,9 +4099,9 @@ ransom_me_interaction = { add = cowed_reason_value trigger = { scope:recipient = { - target_is_liege_or_above = scope:actor + target_is_liege_or_above = scope:puppet_or_actor has_dread_level_towards = { - target = scope:actor + target = scope:puppet_or_actor level = 2 } } @@ -3916,7 +4112,7 @@ ransom_me_interaction = { add = -50 trigger = { scope:recipient = { - house_has_feud_relation_with_trigger = { TARGET = scope:actor } + house_has_feud_relation_with_trigger = { TARGET = scope:puppet_or_actor } } } @@ -3934,15 +4130,21 @@ ransom_me_interaction = { scope:herd_send_option = yes desc = HERD_INTERACTION_ACCEPTANCE_SEND_OPTION } + + modifier = { + add = 10 + scope:current_herd = yes + desc = HERD_INTERACTION_ACCEPTANCE_SEND_OPTION + } } auto_accept = { custom_description = { text = "spending_hook" - subject = scope:actor + subject = scope:puppet_or_actor object = scope:recipient scope:hook = yes - scope:actor = { has_strong_hook = scope:recipient } + scope:puppet_or_actor = { has_strong_hook = scope:recipient } } } @@ -3960,10 +4162,6 @@ ransom_me_interaction = { ai_recipients = self } - ai_potential = { - always = yes - } - ai_will_do = { base = 0 @@ -3973,7 +4171,7 @@ ransom_me_interaction = { scope:gold = yes scope:extortionate_gold = yes AND = { - scope:actor = { + scope:puppet_or_actor = { gold >= 25 } OR = { @@ -3983,6 +4181,7 @@ ransom_me_interaction = { OR = { scope:current_gold = yes scope:extortionate_current_gold = yes + scope:current_herd = yes } } scope:herd_send_option = yes @@ -3994,8 +4193,8 @@ ransom_me_interaction = { scope:favor = yes scope:recipient = { OR = { - is_vassal_of = scope:actor - liege ?= scope:actor + is_vassal_of = scope:puppet_or_actor + liege ?= scope:puppet_or_actor } } } @@ -4005,49 +4204,49 @@ ransom_me_interaction = { scope:favor = yes scope:recipient = { NOR = { - is_vassal_of = scope:actor - liege ?= scope:actor + is_vassal_of = scope:puppet_or_actor + liege ?= scope:puppet_or_actor } } } # Struggle Agenda - modifier = { - scope:recipient = { - any_character_struggle = { - involvement = involved - } - } - scope:actor = { - any_character_struggle = { - involvement = involved - } - } - add = { - value = 0 - if = { - limit = { - scope:actor = { - any_character_struggle = { - phase_has_catalyst = catalyst_ransom_important - } - has_character_flag = agenda_towards_escalation - } - } - add = -100 - } - else_if = { - limit = { - scope:actor = { - any_character_struggle = { - phase_has_catalyst = catalyst_ransom_important - } - } - } - add = 200 - } - } - } +# modifier = { +# scope:recipient = { +# any_character_struggle = { +# involvement = involved +# } +# } +# scope:puppet_or_actor = { +# any_character_struggle = { +# involvement = involved +# } +# } +# add = { +# value = 0 +# if = { +# limit = { +# scope:puppet_or_actor = { +# any_character_struggle = { +# phase_has_catalyst = catalyst_ransom_important +# } +# has_character_flag = agenda_towards_escalation +# } +# } +# add = -100 +# } +# else_if = { +# limit = { +# scope:puppet_or_actor = { +# any_character_struggle = { +# phase_has_catalyst = catalyst_ransom_important +# } +# } +# } +# add = 200 +# } +# } +# } modifier = { # Don't give away prisoners for free factor = 0 @@ -4056,13 +4255,8 @@ ransom_me_interaction = { scope:gold = yes scope:extortionate_gold = yes scope:current_gold = yes + scope:current_herd = yes scope:herd_send_option = yes - AND = { - scope:actor = { - gold >= 25 - } - scope:current_gold = yes - } } } @@ -4071,14 +4265,14 @@ ransom_me_interaction = { scope:recipient = { is_ai = no } OR = { scope:recipient = { is_at_war = yes } - scope:actor = { has_character_flag = character_ransom_refused_by_player } + scope:puppet_or_actor = { has_character_flag = character_ransom_refused_by_player } } } #don't do it if you are tied with a prison break contract, we don't want it invalidating all the time modifier = { factor = 0 - scope:actor = { + scope:puppet_or_actor = { has_character_flag = being_prisonbroken_by_laamp } } @@ -4116,8 +4310,18 @@ release_from_prison_interaction = { } is_shown = { + exists = scope:puppet_or_actor + scope:puppet_or_actor ?= { + trigger_if = { + limit = { + is_ai = yes + NOT = { puppeteer ?= { is_ai = no } } + } + has_prisoners = yes + } + } scope:recipient = { - is_imprisoned_by = scope:actor + is_imprisoned_by = scope:puppet_or_actor } } @@ -4152,7 +4356,7 @@ release_from_prison_interaction = { scope:recipient = { remove_character_modifier = moldy_gruel_diet } } if = { - limit = { scope:recipient = { is_imprisoned_by = scope:actor } } + limit = { scope:recipient = { is_imprisoned_by = scope:puppet_or_actor } } scope:recipient = { if = { @@ -4171,60 +4375,60 @@ release_from_prison_interaction = { demand_conversion_interaction_effect = yes add_opinion = { modifier = demanded_my_conversion_opinion - target = scope:actor + target = scope:puppet_or_actor } # Struggle Catalyst - if = { - limit = { - scope:actor = { - any_character_struggle = { - involvement = involved - activate_struggle_catalyst_secondary_character_involvement_involved_trigger = { - CATALYST = catalyst_demanding_important_conversion - CHAR = scope:recipient - } - } - } - } - scope:actor = { - every_character_struggle = { - involvement = involved - limit = { - activate_struggle_catalyst_secondary_character_involvement_involved_trigger = { - CATALYST = catalyst_demanding_important_conversion - CHAR = scope:recipient - } - } - activate_struggle_catalyst = { - catalyst = catalyst_demanding_important_conversion - character = scope:actor - } - } - } - } +# if = { +# limit = { +# scope:puppet_or_actor = { +# any_character_struggle = { +# involvement = involved +# activate_struggle_catalyst_secondary_character_involvement_involved_trigger = { +# CATALYST = catalyst_demanding_important_conversion +# CHAR = scope:recipient +# } +# } +# } +# } +# scope:puppet_or_actor = { +# every_character_struggle = { +# involvement = involved +# limit = { +# activate_struggle_catalyst_secondary_character_involvement_involved_trigger = { +# CATALYST = catalyst_demanding_important_conversion +# CHAR = scope:recipient +# } +# } +# activate_struggle_catalyst = { +# catalyst = catalyst_demanding_important_conversion +# character = scope:puppet_or_actor +# } +# } +# } +# } } # Banish Landed Character if = { limit = { scope:banish = yes - scope:recipient = { is_landed_or_landless_administrative = yes } + scope:recipient = { is_landed_or_landless_administrative_or_theocratic = yes } } - banish_effect = { BANISHER = scope:actor } + banish_effect = { BANISHER = scope:puppet_or_actor } if = { limit = { NOT = { - scope:actor = { + scope:puppet_or_actor = { has_banish_reason = scope:recipient } } } - scope:actor = { add_tyranny = banishment_tyranny_gain } + scope:puppet_or_actor = { add_tyranny = banishment_tyranny_gain } } add_opinion = { modifier = banished_me - target = scope:actor + target = scope:puppet_or_actor } } # Banish Unlanded Character @@ -4241,12 +4445,12 @@ release_from_prison_interaction = { if = { limit = { this.gold > 0 - NOR = { - has_character_flag = realm_priest - has_character_flag = was_bookmaker + has_none_of_variables = { + name = realm_priest + name = was_bookmaker } } - pay_short_term_gold = { target = scope:actor gold = this.gold } + pay_short_term_gold = { target = scope:puppet_or_actor gold = this.gold } } if = { limit = { @@ -4255,15 +4459,15 @@ release_from_prison_interaction = { every_character_artifact = { limit = { NOT = { has_variable = artifact_prevent_transfer } } set_owner = { - target = scope:actor + target = scope:puppet_or_actor history = { location = scope:recipient.location actor = scope:recipient - recipient = scope:actor + recipient = scope:puppet_or_actor type = stolen } } - scope:actor = { + scope:puppet_or_actor = { if = { limit = { NOT = { has_variable = stolen_artifact } @@ -4285,7 +4489,7 @@ release_from_prison_interaction = { banish = yes add_opinion = { modifier = banished_me - target = scope:actor + target = scope:puppet_or_actor } } # 'Banish' Pool Character @@ -4303,11 +4507,11 @@ release_from_prison_interaction = { limit = { this.gold > 0 } - pay_short_term_gold = { target = scope:actor gold = this.gold } + pay_short_term_gold = { target = scope:puppet_or_actor gold = this.gold } } add_opinion = { modifier = banished_me - target = scope:actor + target = scope:puppet_or_actor } } @@ -4316,7 +4520,7 @@ release_from_prison_interaction = { limit = { scope:recruit = yes } if = { limit = { - scope:actor = { + scope:puppet_or_actor = { culture = { has_cultural_parameter = can_recruit_prisoners_easily } @@ -4324,9 +4528,9 @@ release_from_prison_interaction = { } add_opinion = { modifier = loyal_servant - target = scope:actor + target = scope:puppet_or_actor } - scope:actor = { + scope:puppet_or_actor = { if = { limit = { can_add_hook = { @@ -4344,27 +4548,27 @@ release_from_prison_interaction = { else = { add_opinion = { modifier = demanded_recruitment - target = scope:actor + target = scope:puppet_or_actor } } - scope:actor = { + scope:puppet_or_actor = { if = { limit = { AND = { - scope:actor.faith = { - has_doctrine = tenet_communal_possessions + scope:puppet_or_actor.rite = { + rite_has_tenet = tenet_communal_possessions } scope:recipient = { has_trait = peasant_leader } } } - scope:actor = { + scope:puppet_or_actor = { add_piety = medium_piety_gain } } } - scope:actor = { + scope:puppet_or_actor = { add_courtier = scope:recipient } } @@ -4374,7 +4578,7 @@ release_from_prison_interaction = { limit = { scope:renounce_claims = yes } add_opinion = { modifier = demanded_claim_renouncement - target = scope:actor + target = scope:puppet_or_actor } scope:recipient = { every_claim = { @@ -4382,13 +4586,13 @@ release_from_prison_interaction = { limit = { save_temporary_scope_as = temp_claim OR = { - holder = scope:actor + holder = scope:puppet_or_actor AND = { exists = holder - NOT = { prev = { target_is_liege_or_above = scope:actor } } - holder = { target_is_liege_or_above = scope:actor } + NOT = { prev = { target_is_liege_or_above = scope:puppet_or_actor } } + holder = { target_is_liege_or_above = scope:puppet_or_actor } } - scope:actor = { + scope:puppet_or_actor = { any_held_title = { is_de_jure_liege_or_above_target = scope:temp_claim } @@ -4405,9 +4609,9 @@ release_from_prison_interaction = { limit = { scope:gain_hook = yes } add_opinion = { modifier = demanded_hook - target = scope:actor + target = scope:puppet_or_actor } - scope:actor = { + scope:puppet_or_actor = { add_hook = { #Hook effect must match gain_hook option condition target = scope:recipient type = favor_hook @@ -4415,14 +4619,199 @@ release_from_prison_interaction = { } } + # Make Puppet + if = { + limit = { scope:make_puppet = yes } + play_sound_effect = "event:/DLC/CE3/SFX/UIX/ce3_make_character_puppet" + scope:puppet_or_actor = { + if = { + limit = { + has_puppet_type = external_theological_agent_puppet + scope:recipient = { + is_clergy = yes + religion = scope:puppet_or_actor.religion + } + } + set_puppet = { + target = scope:recipient + type = external_theological_agent_puppet + } + } + else = { + set_puppet = { + target = scope:recipient + type = external_ruler_puppet + } + } + } + } + if = { + limit = { scope:change_prison = yes } + scope:puppet_or_actor = { + imprison_character_effect = { + TARGET = scope:recipient + IMPRISONER = scope:actor # this is on purpose, we are moving the prisoner from puppet's to puppeteer's (actor's) prison + } + } + } + # Take Vows if = { limit = { scope:take_vows = yes } - send_child_to_clergy_effect = yes + scope:puppet_or_actor = { + # Legitimacy loss if you're doing this to your children + if = { + limit = { + has_legitimacy = yes + scope:recipient = { is_primary_heir_of = scope:puppet_or_actor } + } + if = { + limit = { + hyperdulia_take_the_vows_trigger = yes + } + add_legitimacy = { + value = miniscule_legitimacy_gain + multiply = scope:puppet_or_actor.primary_title.tier + } + } + else = { + add_legitimacy = { + value = minor_legitimacy_loss + multiply = scope:puppet_or_actor.primary_title.tier + } + } + } + else_if = { + limit = { + has_legitimacy = yes + scope:recipient = { is_heir_of = scope:puppet_or_actor } + } + if = { + limit = { + hyperdulia_take_the_vows_trigger = yes + } + add_legitimacy = { + value = minor_legitimacy_gain + multiply = scope:puppet_or_actor.primary_title.tier + } + } + else = { + add_legitimacy = { + value = miniscule_legitimacy_loss + multiply = scope:puppet_or_actor.primary_title.tier + } + } + } + else_if = { + limit = { + has_legitimacy = yes + hyperdulia_take_the_vows_trigger = yes + } + add_legitimacy = { + value = medium_legitimacy_gain + multiply = scope:puppet_or_actor.primary_title.tier + } + } + } + #Gain rival progress with heirs/claimants + scope:recipient = { + if = { + limit = { + OR = { + any_claim = { + holder = scope:puppet_or_actor + } + is_heir_of = scope:puppet_or_actor + } + NOR = { + has_trait = forgiving + has_trait = zealous + has_trait = craven + has_trait = content + has_trait = humble + has_trait = bastard + } + } + progress_towards_rival_effect = { + CHARACTER = scope:puppet_or_actor + REASON = rival_forced_to_take_vows + OPINION = 0 + } + } + } + #Send to monastic order if possible + if = { + limit = { + scope:puppet_or_actor.faith = { + any_faith_holy_order = { + take_the_vows_valid_monastic_order_trigger = { CHARACTER = scope:puppet_or_actor } + } + } + } + #Save an archabbot + save_most_suitable_monastic_leader_effect = yes + + scope:puppet_or_actor = { + send_child_to_monastic_order_effect = yes + reverse_add_opinion = { + target = scope:archabbot + modifier = pleased_opinion + opinion = 15 + } + scope:recipient = { + if = { + limit = { + OR = { + is_heir_of = scope:puppet_or_actor + any_claim = { + exists = this + } + } + } + add_opinion = { + modifier = forced_taking_vows + target = scope:puppet_or_actor + } + } + else = { + add_opinion = { + modifier = demanded_taking_vows + target = scope:puppet_or_actor + } + } + } + } + } + #Send to theocratic ruler or pool + else = { + send_child_to_clergy_effect = yes + scope:puppet_or_actor.top_liege = { + random_vassal_or_below = { + limit = { + government_has_flag = government_is_theocracy + primary_title.tier > tier_barony + faith = scope:puppet_or_actor.faith + } + save_scope_as = theocratic_travel_target + } + } + if = { + limit = { exists = scope:theocratic_travel_target } + scope:theocratic_travel_target = { + add_courtier = scope:recipient + } + } + else_if = { + limit = { + exists = scope:puppet_or_actor.capital_province + } + move_to_pool_at = scope:puppet_or_actor.capital_province + } + } #Does Byzan go hay-wire with deposing vassals? if = { limit = { - scope:actor = { + scope:puppet_or_actor = { is_ai = yes culture = { has_cultural_pillar = heritage_byzantine } } @@ -4433,7 +4822,7 @@ release_from_prison_interaction = { #Does the AI in general go haywire with deposing prisoners? else_if = { limit = { - scope:actor = { is_ai = yes } + scope:puppet_or_actor = { is_ai = yes } } debug_log = debug_ai_forced_vows_on_prison_release debug_log_scopes = yes @@ -4467,7 +4856,7 @@ release_from_prison_interaction = { torture_blind_castrate_disfigure_opinion_effect = { VERB = disfigured } - scope:actor = { + scope:puppet_or_actor = { trigger_event = { id = prison.1030 days = 1 @@ -4494,7 +4883,7 @@ release_from_prison_interaction = { } # Merciful Blindings - scope:actor = { + scope:puppet_or_actor = { if = { limit = { culture = { has_cultural_parameter = merciful_blinding } @@ -4509,7 +4898,7 @@ release_from_prison_interaction = { torture_blind_castrate_disfigure_opinion_effect = { VERB = blinded } - scope:actor = { + scope:puppet_or_actor = { trigger_event = { id = prison.1020 days = 1 @@ -4518,9 +4907,9 @@ release_from_prison_interaction = { # If we're a clan this interaction affects unity if = { - limit = { scope:actor.culture = { has_cultural_parameter = merciful_blinding } } # If actor's culture has Merciful Blindings, they lose less unity + limit = { scope:puppet_or_actor.culture = { has_cultural_parameter = merciful_blinding } } add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = minor_unity_loss DESC = clan_unity_blinding.desc @@ -4529,7 +4918,7 @@ release_from_prison_interaction = { } else = { add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = medium_unity_loss DESC = clan_unity_blinding.desc @@ -4566,7 +4955,7 @@ release_from_prison_interaction = { torture_blind_castrate_disfigure_opinion_effect = { VERB = castrated } - scope:actor = { + scope:puppet_or_actor = { trigger_event = { id = prison.1025 days = 1 @@ -4575,7 +4964,7 @@ release_from_prison_interaction = { # If we're a clan this interaction affects unity add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = major_unity_loss DESC = clan_unity_abelarding.desc @@ -4587,6 +4976,7 @@ release_from_prison_interaction = { if = { limit = { scope:demand_admin = yes } scope:recipient = { + scope:puppet_or_actor = { save_scope_as = new_liege } # so ritsuryo can demand it change_to_administrative_effect = yes } } @@ -4602,10 +4992,10 @@ release_from_prison_interaction = { } scope:recipient.house ?= { change_house_relation_effect = { - HOUSE = scope:actor.house + HOUSE = scope:puppet_or_actor.house VALUE = house_relation_damage_medium_value REASON = torture - CHAR = scope:actor + CHAR = scope:puppet_or_actor TARGET_CHAR = scope:recipient TITLE = scope:dummy_gender } @@ -4628,7 +5018,7 @@ release_from_prison_interaction = { scope:demand_admin = no } # Notification to the imprisoner - scope:actor = { + scope:puppet_or_actor = { send_interface_toast = { type = event_toast_effect_neutral title = recipient_released_from_prison @@ -4636,7 +5026,7 @@ release_from_prison_interaction = { scope:recipient = { add_opinion = { modifier = released_from_prison - target = scope:actor + target = scope:puppet_or_actor } } hidden_effect = { @@ -4707,13 +5097,13 @@ release_from_prison_interaction = { HOUSE = scope:recipient.house VALUE = house_relation_improve_medium_value REASON = prison_released - CHAR = scope:actor + CHAR = scope:puppet_or_actor TARGET_CHAR = scope:recipient TITLE = scope:dummy_gender } } add_dread = minor_dread_loss - stress_impact = { + stress_and_fulfillment_impact = { sadistic = medium_stress_impact_gain callous = minor_stress_impact_gain } @@ -4756,14 +5146,14 @@ release_from_prison_interaction = { # } # activate_struggle_catalyst = { # catalyst = catalyst_release_important -# character = scope:actor +# character = scope:puppet_or_actor # } # } # } # if = { # limit = { # fp3_struggle_involves_one_supporter_and_one_detractor = { -# FIRST = scope:actor +# FIRST = scope:puppet_or_actor # SECOND = scope:recipient # } # any_character_struggle = { @@ -4782,16 +5172,30 @@ release_from_prison_interaction = { # } # activate_struggle_catalyst = { # catalyst = catalyst_release_supporter_detractor -# character = scope:actor +# character = scope:puppet_or_actor # } # log_debug_variable_for_persian_struggle_effect = { VAR = concession_catalyst_release_supporter_detractor } # } # } } + if = { + limit = { + scope:is_puppet_action ?= yes + scope:actor != scope:recipient + } + scope:actor = { + send_interface_toast = { + type = event_toast_effect_neutral + title = recipient_released_from_prison_puppeteer + left_icon = scope:puppet_or_actor + right_icon = scope:recipient + } + } + } # If we're a clan (and not making any demands) this interaction affects unity add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = minor_unity_gain DESC = clan_unity_released_from_own_prison.desc @@ -4812,11 +5216,11 @@ release_from_prison_interaction = { subtract = 2 } } - scope:actor = { + scope:puppet_or_actor = { send_interface_toast = { type = msg_legitimacy_gain title = legitimacy_gain_toast - left_icon = scope:actor + left_icon = scope:puppet_or_actor right_icon = scope:recipient add_legitimacy = { value = { @@ -4826,6 +5230,20 @@ release_from_prison_interaction = { } } } + if = { + limit = { + scope:is_puppet_action ?= yes + scope:actor != scope:recipient + } + scope:actor = { + send_interface_toast = { + type = msg_legitimacy_gain + title = legitimacy_gain_toast_puppeteer + left_icon = scope:puppet_or_actor + right_icon = scope:recipient + } + } + } } } else_if = { @@ -4834,7 +5252,7 @@ release_from_prison_interaction = { scope:blind = no scope:castrate = no } - scope:actor = { + scope:puppet_or_actor = { trigger_event = char_interaction.0160 } } @@ -4878,20 +5296,20 @@ release_from_prison_interaction = { } # FP3 - If prisoner is important for war - scope:actor = { # FP3 + scope:puppet_or_actor = { # FP3 if = { limit = { exists = scope:recipient.house any_character_war = { using_cb = fp3_free_house_member_cb - is_defender = scope:actor + is_defender = scope:puppet_or_actor primary_attacker.house = scope:recipient.house } } random_character_war = { limit = { using_cb = fp3_free_house_member_cb - is_defender = scope:actor + is_defender = scope:puppet_or_actor primary_attacker.house = scope:recipient.house } primary_attacker = { @@ -4900,7 +5318,7 @@ release_from_prison_interaction = { type = event_war_good title = lesson_war_final_notes_victory_step_1 left_icon = scope:recipient - right_icon = scope:actor + right_icon = scope:puppet_or_actor show_as_tooltip = { scope:recipient = { release_from_prison = yes } @@ -4915,11 +5333,13 @@ release_from_prison_interaction = { } } } + + tenet_benevolent_governance_clemency_effect = yes } } on_decline = { - scope:actor = { + scope:puppet_or_actor = { trigger_event = char_interaction.0161 } } @@ -4928,7 +5348,7 @@ release_from_prison_interaction = { flag = demand_conversion localization = "RELEASE_DEMAND_CONVERSION" is_shown = { - scope:recipient.faith != scope:actor.faith + scope:recipient.faith != scope:puppet_or_actor.faith } is_valid = { trigger_if = { @@ -4937,9 +5357,10 @@ release_from_prison_interaction = { } scope:recipient = { OR = { - is_close_or_extended_family_of = scope:actor - is_vassal_of = scope:actor + is_close_or_extended_family_of = scope:puppet_or_actor + is_vassal_of = scope:puppet_or_actor } + NOT = { has_character_flag = ai_will_not_convert } } } @@ -4951,7 +5372,7 @@ release_from_prison_interaction = { limit = { is_playable_character = yes } - is_vassal_or_below_of = scope:actor + is_vassal_or_below_of = scope:puppet_or_actor } } } @@ -4964,7 +5385,7 @@ release_from_prison_interaction = { scope:recipient.faith.religious_head = scope:recipient } } - # Cannot ask Holy Order Master to convert + # Cannot ask Military Order Master to convert custom_description = { text = cannot_demand_holy_order_master_conversion NAND = { @@ -4974,6 +5395,13 @@ release_from_prison_interaction = { } } } + # Cannot ask characters who will never renounce their faith to convert + custom_description = { + text = cannot_demand_steadfast_character_conversion + scope:recipient = { + NOT = { has_character_flag = ai_will_not_convert } + } + } } } @@ -4989,17 +5417,17 @@ release_from_prison_interaction = { explicit = yes save_temporary_scope_as = temp_claim OR = { - holder = scope:actor + holder = scope:puppet_or_actor AND = { - NOT = { prev = { target_is_liege_or_above = scope:actor } } + NOT = { prev = { target_is_liege_or_above = scope:puppet_or_actor } } trigger_if = { limit = { exists = holder } - holder = { target_is_liege_or_above = scope:actor } + holder = { target_is_liege_or_above = scope:puppet_or_actor } } } - scope:actor = { + scope:puppet_or_actor = { any_held_title = { is_de_jure_liege_or_above_target = scope:temp_claim } @@ -5027,15 +5455,15 @@ release_from_prison_interaction = { AND = { is_playable_character = no is_ruler = no - gold > scope:actor.gold - gold > scope:actor.medium_gold_value - scope:actor.ai_greed > low_negative_ai_value + gold > scope:puppet_or_actor.gold + gold > scope:puppet_or_actor.medium_gold_value + scope:puppet_or_actor.ai_greed > low_negative_ai_value } AND = { is_playable_character = no is_ruler = no gold > 0 - scope:actor = { + scope:puppet_or_actor = { has_banish_reason = scope:recipient } } @@ -5043,13 +5471,13 @@ release_from_prison_interaction = { is_playable_character = no is_ruler = no gold > 100 - scope:actor.ai_greed >= high_positive_ai_value + scope:puppet_or_actor.ai_greed >= high_positive_ai_value } AND = { - scope:actor = { + scope:puppet_or_actor = { has_banish_reason = scope:recipient } - scope:actor = { + scope:puppet_or_actor = { opinion = { target = scope:recipient value <= medium_negative_opinion @@ -5066,12 +5494,12 @@ release_from_prison_interaction = { } } scope:recipient = { - is_vassal_of = scope:actor + is_vassal_of = scope:puppet_or_actor } } trigger_else = { scope:recipient = { - is_courtier_of = scope:actor + is_courtier_of = scope:puppet_or_actor } } custom_description = { @@ -5082,7 +5510,7 @@ release_from_prison_interaction = { scope:recruit = no #Should be impossible to have both but just in case NOT = { scope:recipient = { - is_spouse_of = scope:actor + is_spouse_of = scope:puppet_or_actor } } } @@ -5098,14 +5526,14 @@ release_from_prison_interaction = { } scope:recipient = { OR = { - is_vassal_of = scope:actor - liege ?= scope:actor + is_vassal_of = scope:puppet_or_actor + liege ?= scope:puppet_or_actor } } } } is_valid = { - scope:actor = { + scope:puppet_or_actor = { can_add_hook = { type = favor_hook #Matches the hook added in the on_accept target = scope:recipient @@ -5118,7 +5546,7 @@ release_from_prison_interaction = { flag = take_vows localization = "RELEASE_TAKE_VOWS" is_shown = { - scope:actor = { take_vows_available_trigger = yes } + scope:puppet_or_actor = { take_vows_available_trigger = yes } } is_valid = { #Handle AI @@ -5129,32 +5557,32 @@ release_from_prison_interaction = { #We're AI and Byzantium trigger_if = { limit = { - scope:actor = { + scope:puppet_or_actor = { culture = { has_cultural_pillar = heritage_byzantine } } } scope:recipient = { is_ai = yes #Not gonna depose player characters, for now OR = { - is_close_or_extended_family_of = scope:actor - is_vassal_or_below_of = scope:actor #Weigh this for Byz AI in the modifiers below - has_relation_rival = scope:actor - is_courtier_of = scope:actor + is_close_or_extended_family_of = scope:puppet_or_actor + is_vassal_or_below_of = scope:puppet_or_actor #Weigh this for Byz AI in the modifiers below + has_relation_rival = scope:puppet_or_actor + is_courtier_of = scope:puppet_or_actor } NOT = { - is_heir_of = scope:actor + is_heir_of = scope:puppet_or_actor } } #Get rid of rivals despite potentially liking them trigger_if = { limit = { - scope:recipient = { has_relation_rival = scope:actor } + scope:recipient = { has_relation_rival = scope:puppet_or_actor } } always = yes } #Only get rid of family members if we dislike them trigger_else = { - scope:actor = { + scope:puppet_or_actor = { opinion = { target = scope:recipient value <= medium_negative_opinion @@ -5166,12 +5594,12 @@ release_from_prison_interaction = { trigger_else = { scope:recipient = { is_ai = yes #Not gonna depose player characters, for now - is_close_or_extended_family_of = scope:actor + is_close_or_extended_family_of = scope:puppet_or_actor NOT = { - is_heir_of = scope:actor + is_heir_of = scope:puppet_or_actor } } - scope:actor = { + scope:puppet_or_actor = { opinion = { target = scope:recipient value <= medium_negative_opinion @@ -5180,9 +5608,9 @@ release_from_prison_interaction = { custom_description = { text = "release_vows_invalid_not_your_court" object = scope:recipient - subject = scope:actor + subject = scope:puppet_or_actor OR = { - scope:recipient = { is_courtier_of = scope:actor } + scope:recipient = { is_courtier_of = scope:puppet_or_actor } scope:recruit = yes } } @@ -5191,7 +5619,7 @@ release_from_prison_interaction = { #Enhanced Take the Vows for Byzantium players -- who do we want to boot to a monastery far, far away? trigger_else_if = { limit = { - scope:actor = { + scope:puppet_or_actor = { culture = { has_cultural_pillar = heritage_byzantine } } } @@ -5200,12 +5628,12 @@ release_from_prison_interaction = { custom_description = { text = "release_byz_vows_invalid" object = scope:recipient - subject = scope:actor + subject = scope:puppet_or_actor OR = { - is_close_or_extended_family_of = scope:actor - is_vassal_or_below_of = scope:actor - has_relation_rival = scope:actor - is_courtier_of = scope:actor + is_close_or_extended_family_of = scope:puppet_or_actor + is_vassal_or_below_of = scope:puppet_or_actor + has_relation_rival = scope:puppet_or_actor + is_courtier_of = scope:puppet_or_actor } } } @@ -5215,13 +5643,13 @@ release_from_prison_interaction = { scope:recipient = { is_ai = yes #Not gonna depose player characters, for now } - scope:actor = { is_close_or_extended_family_of = scope:recipient } #Triggering I_AM_NOT instead of CHARACTER_IS_NOT makes the tooltip look less cursed + scope:puppet_or_actor = { is_close_or_extended_family_of = scope:recipient } #Triggering I_AM_NOT instead of CHARACTER_IS_NOT makes the tooltip look less cursed custom_description = { text = "release_vows_invalid_not_your_court" object = scope:recipient - subject = scope:actor + subject = scope:puppet_or_actor OR = { - scope:recipient = { is_courtier_of = scope:actor } + scope:recipient = { is_courtier_of = scope:puppet_or_actor } scope:recruit = yes } } @@ -5230,10 +5658,10 @@ release_from_prison_interaction = { custom_description = { text = "release_vows_invalid_not_your_faith" object = scope:recipient - subject = scope:actor + subject = scope:puppet_or_actor trigger_if = { limit = { - scope:recipient.faith != scope:actor.faith + scope:recipient.faith != scope:puppet_or_actor.faith } scope:demand_conversion = yes } @@ -5293,12 +5721,60 @@ release_from_prison_interaction = { } } } + + send_option = { + flag = change_prison + localization = "RELEASE_CHANGE_PRISON" + is_shown = { + scope:recipient = { + NOT = { + is_imprisoned_by = scope:actor + } + } + } + } + + send_option = { + flag = make_puppet + localization = "RELEASE_MAKE_PUPPET" + is_shown = { + scope:puppet_or_actor = { + scope:actor = { is_ai = no } + OR = { + has_puppet_type = external_theological_agent_puppet + has_puppet_type = external_ruler_puppet + } + } + scope:recipient = { + is_ai = yes + } + } + is_valid = { + scope:puppet_or_actor = { + OR = { + AND = { + has_puppet_type = external_theological_agent_puppet + scope:recipient = { + is_clergy = yes + religion = scope:puppet_or_actor.religion + } + } + scope:recipient = { + is_landed = yes + is_ruler = yes + is_adult = yes + } + } + } + } + } + send_option = { flag = become_executioner localization = "RELEASE_AS_EXECUTIONER" is_shown = { has_ep1_court_positions_dlc_trigger = yes - scope:actor = { + scope:puppet_or_actor = { has_royal_court = yes } scope:recipient = { @@ -5306,7 +5782,7 @@ release_from_prison_interaction = { } } is_valid = { - scope:actor = { + scope:puppet_or_actor = { can_employ_court_position_type = executioner_court_position NOT = { employs_court_position = executioner_court_position } } @@ -5320,7 +5796,7 @@ release_from_prison_interaction = { } } trigger_else = { - is_courtier_of = scope:actor + is_courtier_of = scope:puppet_or_actor } custom_description = { @@ -5328,7 +5804,9 @@ release_from_prison_interaction = { object = scope:recipient scope:take_vows = no } - NOT = { is_spouse_of = scope:actor } + NOT = { is_spouse_of = scope:puppet_or_actor } + + can_be_combatant_based_on_gender_trigger = { ARMY_OWNER = scope:puppet_or_actor } } } } @@ -5343,18 +5821,18 @@ release_from_prison_interaction = { } scope:recipient = { OR = { - has_relation_best_friend = scope:actor - has_relation_friend = scope:actor - has_relation_lover = scope:actor - has_relation_soulmate = scope:actor - has_secret_relation_lover = scope:actor - is_heir_of = scope:actor + has_relation_best_friend = scope:puppet_or_actor + has_relation_friend = scope:puppet_or_actor + has_relation_lover = scope:puppet_or_actor + has_relation_soulmate = scope:puppet_or_actor + has_secret_relation_lover = scope:puppet_or_actor + is_heir_of = scope:puppet_or_actor } } } scope:recipient = { is_ruler = no - NOT = { is_courtier_of = scope:actor } + NOT = { is_courtier_of = scope:puppet_or_actor } OR = { is_adult = yes AND = { @@ -5376,8 +5854,8 @@ release_from_prison_interaction = { flag = disfigure localization = "RELEASE_DISFIGURE" is_shown = { - scope:actor = { - government_allows = administrative + scope:puppet_or_actor = { + # government_has_mechanic = administrative culture = { has_cultural_tradition = tradition_ep3_palace_politics } # If they're our partner emperor, we should use the maiming interaction instead. liege_should_systematically_maim_co_ruler_trigger = no @@ -5393,7 +5871,7 @@ release_from_prison_interaction = { # Byzantines can't disfigure those not in their realm trigger_if = { limit = { - scope:actor = { + scope:puppet_or_actor = { culture = { has_cultural_pillar = heritage_byzantine } } } @@ -5401,12 +5879,12 @@ release_from_prison_interaction = { custom_description = { text = "release_byz_disfigure_invalid" object = scope:recipient - subject = scope:actor + subject = scope:puppet_or_actor OR = { - is_close_or_extended_family_of = scope:actor - is_vassal_or_below_of = scope:actor - has_relation_rival = scope:actor - is_courtier_of = scope:actor + is_close_or_extended_family_of = scope:puppet_or_actor + is_vassal_or_below_of = scope:puppet_or_actor + has_relation_rival = scope:puppet_or_actor + is_courtier_of = scope:puppet_or_actor } } } @@ -5424,7 +5902,7 @@ release_from_prison_interaction = { flag = blind localization = "RELEASE_BLIND" is_shown = { - scope:actor = { + scope:puppet_or_actor = { is_adult = yes culture = { has_cultural_parameter = can_blind_prisoners } # If they're our partner emperor, we should use the maiming interaction instead. @@ -5452,11 +5930,11 @@ release_from_prison_interaction = { localization = "RELEASE_CASTRATE" is_shown = { scope:recipient = { - is_imprisoned_by = scope:actor + is_imprisoned_by = scope:puppet_or_actor is_eunuch_trigger = no is_male = yes } - scope:actor = { + scope:puppet_or_actor = { is_adult = yes culture = { has_cultural_parameter = can_castrate_prisoners @@ -5482,23 +5960,23 @@ release_from_prison_interaction = { flag = demand_admin localization = "RELEASE_DEMAND_ADMIN" is_shown = { - scope:actor = { government_allows = administrative } - scope:actor = scope:recipient.liege + scope:puppet_or_actor = { government_has_mechanic = administrative } + scope:puppet_or_actor = scope:recipient.liege scope:recipient = { #Requirements match demand admin interaction highest_held_title_tier >= tier_county is_landed = yes is_ruler = yes - NOT = { government_allows = administrative } + NOT = { government_has_mechanic = administrative } NOT = { scope:recipient = { government_has_flag = government_is_tribal } } NOT = { scope:recipient ?= scope:recipient.faith.religious_head } - NOT = { scope:recipient ?= scope:actor.diarch } + NOT = { scope:recipient ?= scope:puppet_or_actor.diarch } } } is_valid = { scope:recipient = { - NOT = { government_allows = administrative } + NOT = { government_has_mechanic = administrative } } } } @@ -5520,6 +5998,12 @@ release_from_prison_interaction = { ai_accept = { base = 0 + + celestial_hierarchy_acceptance_modifier = { + ACTOR = scope:puppet_or_actor + RECIPIENT = scope:recipient + } + modifier = { add = 100 desc = "WANTS_FREEDOM_REASON" @@ -5532,8 +6016,27 @@ release_from_prison_interaction = { add = -20 desc = "RECIPIENT_IS_AMBITIOUS" } + modifier = { + trigger = { + scope:recipient = { + rite.head_of_rite ?= this + } + } + add = -120 + desc = "RECIPIENT_IS_HEAD_OF_RITE_REASON" + } # Demand conversion + modifier = { + trigger = { + scope:demand_conversion = yes + scope:recipient = { + has_character_flag = ai_will_not_convert + } + } + add = -1500 + desc = "ASK_FOR_CONVERSION_RECIPIENT_WILL_NOT_ACCEPT" + } modifier = { trigger = { scope:recipient = { ai_zeal <= 20 } @@ -5553,7 +6056,7 @@ release_from_prison_interaction = { limit = { scope:recipient.faith = { faith_hostility_level = { - target = scope:actor.faith + target = scope:puppet_or_actor.faith value = faith_astray_level } } @@ -5621,7 +6124,7 @@ release_from_prison_interaction = { scope:banish = yes } NOT = { - scope:actor = { + scope:puppet_or_actor = { has_imprisonment_reason = scope:recipient culture = { has_cultural_parameter = vassals_more_likely_accept_punishments } } @@ -5633,7 +6136,7 @@ release_from_prison_interaction = { trigger = { scope:banish = yes } - scope:actor = { + scope:puppet_or_actor = { has_imprisonment_reason = scope:recipient culture = { has_cultural_parameter = vassals_more_likely_accept_punishments } } @@ -5730,7 +6233,7 @@ release_from_prison_interaction = { trigger = { scope:recruit = yes NOT = { - scope:actor = { + scope:puppet_or_actor = { culture = { has_cultural_parameter = can_recruit_prisoners_easily } @@ -5844,21 +6347,14 @@ release_from_prison_interaction = { OR = { culture = { OR = { -# # Historical cultures -# this = culture:greek -# any_parent_culture_or_above = { -# this = culture:greek -# } -# this = culture:han -# any_parent_culture_or_above = { -# this = culture:han -# } + # Historical cultures + culture_is_historically_admin_trigger = yes # Bureaucratic culture has_cultural_pillar = ethos_bureaucratic } } # Another admin government - government_allows = administrative + government_has_mechanic = administrative } } desc = "DEMAND_ADMIN_NEGATIVE_REASON" @@ -5871,20 +6367,13 @@ release_from_prison_interaction = { culture = { OR = { # Historical cultures -# this = culture:greek -# any_parent_culture_or_above = { -# this = culture:greek -# } -# this = culture:han -# any_parent_culture_or_above = { -# this = culture:han -# } + culture_is_historically_admin_trigger = yes # Bureaucratic culture has_cultural_pillar = ethos_bureaucratic } } # Another admin government - government_allows = administrative + government_has_mechanic = administrative } culture = { NOR = { @@ -5903,20 +6392,13 @@ release_from_prison_interaction = { culture = { OR = { # Historical cultures -# this = culture:greek -# any_parent_culture_or_above = { -# this = culture:greek -# } -# this = culture:han -# any_parent_culture_or_above = { -# this = culture:han -# } + culture_is_historically_admin_trigger = yes # Bureaucratic culture has_cultural_pillar = ethos_bureaucratic } } # Another admin government - government_allows = administrative + government_has_mechanic = administrative } culture = { OR = { @@ -5942,7 +6424,7 @@ release_from_prison_interaction = { # involvement = involved # } # } -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # involvement = involved # } @@ -5978,10 +6460,13 @@ release_from_prison_interaction = { ai_targets = { ai_recipients = prisoners } - ai_frequency = 1 - - ai_potential = { - has_prisoners = yes + ai_frequency_by_tier = { + barony = 12 + county = 1 + duchy = 1 + kingdom = 1 + empire = 1 + hegemony = 1 } ai_will_do = { @@ -5995,7 +6480,7 @@ release_from_prison_interaction = { add = 100 scope:demand_conversion = yes scope:recipient = { - is_vassal_of = scope:actor + is_vassal_of = scope:puppet_or_actor } } modifier = { @@ -6028,44 +6513,44 @@ release_from_prison_interaction = { } modifier = { # Rivals can rot add = -40 - scope:actor = { + scope:puppet_or_actor = { NOT = { has_trait = forgiving } } scope:recipient = { OR = { - has_relation_rival = scope:actor - has_relation_nemesis = scope:actor + has_relation_rival = scope:puppet_or_actor + has_relation_nemesis = scope:puppet_or_actor scope:recipient = { - is_spouse_of = scope:actor - exposed_cheating_on_spouse_trigger = { SPOUSE = scope:actor } + is_spouse_of = scope:puppet_or_actor + exposed_cheating_on_spouse_trigger = { SPOUSE = scope:puppet_or_actor } } } } } modifier = { # Rivals can rot FOREVER if vengeful add = -100 - scope:actor = { + scope:puppet_or_actor = { NOT = { has_trait = forgiving } } - scope:actor.ai_vengefulness >= very_high_positive_ai_value + scope:puppet_or_actor.ai_vengefulness >= very_high_positive_ai_value scope:recipient = { OR = { - has_relation_rival = scope:actor - has_relation_nemesis = scope:actor + has_relation_rival = scope:puppet_or_actor + has_relation_nemesis = scope:puppet_or_actor scope:recipient = { - is_spouse_of = scope:actor - exposed_cheating_on_spouse_trigger = { SPOUSE = scope:actor } + is_spouse_of = scope:puppet_or_actor + exposed_cheating_on_spouse_trigger = { SPOUSE = scope:puppet_or_actor } } } } } modifier = { # Compassionate characters don't want to keep children in their dungeon for too long add = 10 - scope:actor = { + scope:puppet_or_actor = { is_at_war = no ai_compassion >= low_positive_ai_value } @@ -6076,7 +6561,7 @@ release_from_prison_interaction = { } modifier = { # Very compassionate characters tend to release prisoners add = 10 - scope:actor = { + scope:puppet_or_actor = { is_at_war = no ai_compassion >= very_high_positive_ai_value } @@ -6086,7 +6571,7 @@ release_from_prison_interaction = { } modifier = { # Somewhat compassionate characters tend to keep people in their dungeon for a while add = 10 - scope:actor = { + scope:puppet_or_actor = { is_at_war = no ai_compassion >= medium_positive_ai_value } @@ -6097,7 +6582,7 @@ release_from_prison_interaction = { } modifier = { # Only truly discompassionate characters will have their dungeon full of hapless victims after 5 years add = 10 - scope:actor = { + scope:puppet_or_actor = { is_at_war = no ai_compassion >= low_negative_ai_value } @@ -6108,7 +6593,7 @@ release_from_prison_interaction = { } modifier = { # Most AI characters will let family out... add = 10 - scope:actor = { + scope:puppet_or_actor = { is_at_war = no OR = { ai_compassion >= very_high_positive_ai_value @@ -6124,18 +6609,18 @@ release_from_prison_interaction = { scope:recipient = { time_in_prison = { years > 1 } is_playable_character = no - is_close_family_of = scope:actor + is_close_family_of = scope:puppet_or_actor } } modifier = { # Almost all will let their own children out add = 40 - scope:actor = { + scope:puppet_or_actor = { is_at_war = no ai_compassion >= very_high_negative_ai_value } scope:recipient = { is_playable_character = no - is_child_of = scope:actor + is_child_of = scope:puppet_or_actor } } # Struggle @@ -6153,7 +6638,7 @@ release_from_prison_interaction = { # involvement = involved # } # } -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # involvement = involved # } @@ -6162,7 +6647,7 @@ release_from_prison_interaction = { # value = 0 # if = { # limit = { -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # phase_has_catalyst = catalyst_release_important # } @@ -6173,7 +6658,7 @@ release_from_prison_interaction = { # } # else_if = { # limit = { -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # phase_has_catalyst = catalyst_release_important # } @@ -6197,7 +6682,7 @@ release_from_prison_interaction = { # } modifier = { # Family Feud add = -50 - scope:actor = { + scope:puppet_or_actor = { house_has_feud_relation_with_trigger = { TARGET = scope:recipient } } @@ -6206,10 +6691,10 @@ release_from_prison_interaction = { modifier = { add = -10 scope:take_vows = yes - scope:actor = { + scope:puppet_or_actor = { culture = { has_cultural_pillar = heritage_byzantine } } - scope:recipient = { is_vassal_or_below_of = scope:actor } + scope:recipient = { is_vassal_or_below_of = scope:puppet_or_actor } } evaluate_action_increasing_house_unity = { @@ -6247,16 +6732,12 @@ execute_prisoner_interaction = { hegemony = 12 } - ai_potential = { - is_at_war = no - } - ai_will_do = { base = 0 opinion_modifier = { trigger = { - scope:actor != scope:recipient + scope:puppet_or_actor != scope:recipient } opinion_target = scope:recipient multiplier = -1 @@ -6273,30 +6754,36 @@ execute_prisoner_interaction = { # Try to avoid Kinslaying modifier = { add = -20 - scope:actor.dynasty = scope:recipient.dynasty - NOT = { faith = { has_doctrine = doctrine_kinslaying_any_dynasty_member_crime } } + scope:puppet_or_actor.dynasty = scope:recipient.dynasty + NOT = { scope:puppet_or_actor.rite = { rite_has_doctrine = doctrine_kinslaying_any_dynasty_member_crime } } } modifier = { add = -20 - is_close_or_extended_family_of = scope:recipient - NOT = { faith = { has_doctrine = doctrine_kinslaying_extended_family_crime } } + scope:puppet_or_actor = { + is_close_or_extended_family_of = scope:recipient + NOT = { rite = { rite_has_doctrine = doctrine_kinslaying_extended_family_crime } } + } } modifier = { add = -20 - is_close_family_of = scope:recipient - NOT = { faith = { has_doctrine = doctrine_kinslaying_close_kin_crime } } + scope:puppet_or_actor = { + is_close_family_of = scope:recipient + NOT = { rite = { rite_has_doctrine = doctrine_kinslaying_close_kin_crime } } + } } modifier = { add = 50 - has_execute_reason = scope:recipient - OR = { - has_trait = sadistic - has_trait = lunatic + scope:puppet_or_actor = { + has_execute_reason = scope:recipient + OR = { + has_trait = sadistic + has_trait = lunatic + } } } modifier = { # Executing your way to new titles is a worthy cause... add = 20 - scope:actor = { + scope:puppet_or_actor = { has_execute_reason = scope:recipient ai_greed > 0 any_heir_title = { # Execute rulers you can inherit land from @@ -6306,22 +6793,22 @@ execute_prisoner_interaction = { } modifier = { # Vengeful characters enjoy executing their rivals add = 20 - scope:actor = { + scope:puppet_or_actor = { has_execute_reason = scope:recipient ai_vengefulness >= medium_positive_ai_value OR = { has_relation_rival = scope:recipient # Execute rivals has_relation_nemesis = scope:recipient # Execute rivals scope:recipient = { - is_spouse_of = scope:actor - exposed_cheating_on_spouse_trigger = { SPOUSE = scope:actor } + is_spouse_of = scope:puppet_or_actor + exposed_cheating_on_spouse_trigger = { SPOUSE = scope:puppet_or_actor } } } } } modifier = { # Executing your way to new titles is a worthy cause... and very greedy characters need no execution reason add = 35 - scope:actor = { + scope:puppet_or_actor = { ai_greed >= very_high_positive_ai_value any_heir_title = { # Execute rulers you can inherit land from holder ?= scope:recipient @@ -6330,14 +6817,14 @@ execute_prisoner_interaction = { } modifier = { # Vengeful characters enjoy executing their rivals, and very vengeful characters need no execution reason add = 35 - scope:actor = { + scope:puppet_or_actor = { ai_vengefulness >= very_high_positive_ai_value OR = { has_relation_rival = scope:recipient # Execute rivals has_relation_nemesis = scope:recipient # Execute rivals scope:recipient = { - is_spouse_of = scope:actor - exposed_cheating_on_spouse_trigger = { SPOUSE = scope:actor } + is_spouse_of = scope:puppet_or_actor + exposed_cheating_on_spouse_trigger = { SPOUSE = scope:puppet_or_actor } } } } @@ -6346,14 +6833,14 @@ execute_prisoner_interaction = { character_hates_scope_due_to_strife_modifier = { TARGET = scope:recipient } modifier = { factor = 0 - scope:actor = { + scope:puppet_or_actor = { NOR = { # Do not execute unless you have some sort of reason to do it has_execute_reason = scope:recipient has_relation_rival = scope:recipient # Execute rivals has_relation_nemesis = scope:recipient # Execute rivals scope:recipient = { - is_spouse_of = scope:actor - exposed_cheating_on_spouse_trigger = { SPOUSE = scope:actor } + is_spouse_of = scope:puppet_or_actor + exposed_cheating_on_spouse_trigger = { SPOUSE = scope:puppet_or_actor } } any_heir_title = { # Execute rulers you can inherit land from holder ?= scope:recipient @@ -6375,7 +6862,7 @@ execute_prisoner_interaction = { # value = 0 # if = { # limit = { -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # phase_has_catalyst = catalyst_execute_important # } @@ -6386,7 +6873,7 @@ execute_prisoner_interaction = { # } # else_if = { # limit = { -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # phase_has_catalyst = catalyst_execute_important # } @@ -6408,7 +6895,7 @@ execute_prisoner_interaction = { # value = 0 # if = { # limit = { -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # phase_has_catalyst = catalyst_execute_supporter # } @@ -6419,7 +6906,7 @@ execute_prisoner_interaction = { # } # else_if = { # limit = { -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # phase_has_catalyst = catalyst_execute_supporter # } @@ -6432,7 +6919,7 @@ execute_prisoner_interaction = { #Nomads get the special beheading stuff modifier = { - scope:actor = { + scope:puppet_or_actor = { mpo_keep_prisoners_heads_trigger = yes scope:recipient = { is_ruler = yes @@ -6441,23 +6928,23 @@ execute_prisoner_interaction = { } NOT = { scope:recipient.top_liege ?= { - current_military_strength > scope:actor.current_military_strength + current_military_strength > scope:puppet_or_actor.current_military_strength tier_difference = { - target = scope:actor + target = scope:puppet_or_actor value >= -1 } } } } NOT = { - scope:actor.faith = { has_doctrine_parameter = human_sacrifice_active } + scope:puppet_or_actor.rite = { rite_has_parameter = human_sacrifice_active } } add = 10 } #Boost further if actor if want to keep head modifier = { #want to keep head - scope:actor = { + scope:puppet_or_actor = { mpo_keep_prisoners_heads_trigger = yes } scope:recipient = { @@ -6465,14 +6952,14 @@ execute_prisoner_interaction = { is_adult = yes } NOT = { - scope:actor.faith = { has_doctrine_parameter = human_sacrifice_active } + scope:puppet_or_actor.rite = { rite_has_parameter = human_sacrifice_active } } add = 20 } #Boost further if actor wants to be scary modifier = { #want to keep head - scope:actor = { + scope:puppet_or_actor = { mpo_keep_prisoners_heads_trigger = yes scope:recipient = { is_ruler = yes @@ -6486,7 +6973,7 @@ execute_prisoner_interaction = { } } NOT = { - scope:actor.faith = { has_doctrine_parameter = human_sacrifice_active } + scope:puppet_or_actor.rite = { rite_has_parameter = human_sacrifice_active } } add = 30 } @@ -6502,7 +6989,7 @@ execute_prisoner_interaction = { # value = 0 # if = { # limit = { -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # phase_has_catalyst = catalyst_execute_detractor # } @@ -6513,7 +7000,7 @@ execute_prisoner_interaction = { # } # else_if = { # limit = { -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # phase_has_catalyst = catalyst_execute_detractor # } @@ -6525,13 +7012,13 @@ execute_prisoner_interaction = { # } modifier = { add = 200 - scope:actor.faith = { - has_doctrine = tenet_extinction_of_dharma + scope:puppet_or_actor.rite = { + rite_has_tenet = tenet_extinction_of_dharma } - scope:recipient.faith = { + scope:recipient.rite = { religion = root.faith.religion NOT = { - has_doctrine = tenet_extinction_of_dharma + rite_has_tenet = tenet_extinction_of_dharma } } } @@ -6542,16 +7029,39 @@ execute_prisoner_interaction = { has_character_flag = being_prisonbroken_by_laamp } } + #don't kill prisoners whose deaths would diminish the realm through inheritance + modifier = { + factor = 0 + scope:recipient = { + is_vassal_or_below_of = scope:puppet_or_actor + any_held_title = { + is_landless_type_title = no + tier >= tier_county + current_heir ?= { + is_ruler = yes + is_landed = yes + top_liege != scope:puppet_or_actor.top_liege + } + } + } + } + } + + is_available = { + trigger_if = { + limit = { is_ai = yes } + is_at_war = no + } } is_shown = { scope:recipient = { - is_imprisoned_by = scope:actor + is_imprisoned_by = scope:puppet_or_actor } } is_valid_showing_failures_only = { - scope:recipient = { NOT = { has_strong_hook = scope:actor } } + scope:recipient = { NOT = { has_strong_hook = scope:puppet_or_actor } } scope:recipient = { custom_description = { text = "currently_being_tortured" @@ -6563,7 +7073,7 @@ execute_prisoner_interaction = { # custom_tooltip = { # text = struggle_parameter_struggle_cannot_execute_involved_prisoners # NOT = { -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # involvement = involved # has_struggle_phase_parameter = struggle_cannot_execute_involved_prisoners @@ -6585,7 +7095,7 @@ execute_prisoner_interaction = { } # For use with co-ruler diarchs. - scope:recipient = { is_imprisoned_by = scope:actor } + scope:recipient = { is_imprisoned_by = scope:puppet_or_actor } } cost = { @@ -6595,7 +7105,7 @@ execute_prisoner_interaction = { on_accept = { # If this is a co-ruler we're executing, tell us if we have alternatives. - scope:actor = { + scope:puppet_or_actor = { if = { limit = { OR = { @@ -6616,15 +7126,15 @@ execute_prisoner_interaction = { } # Otherwise, if they're out diarch, we end it. if = { - limit = { scope:actor.diarch = scope:recipient } + limit = { scope:puppet_or_actor.diarch = scope:recipient } end_diarchy = yes every_player = { limit = { NOR = { - this = scope:actor + this = scope:puppet_or_actor this = scope:recipient } - top_liege = scope:actor.top_liege + top_liege = scope:puppet_or_actor.top_liege } trigger_event = diarchy.8022 } @@ -6653,20 +7163,20 @@ execute_prisoner_interaction = { } } change_title_holder = { - holder = scope:actor + holder = scope:puppet_or_actor change = scope:change } } every_vassal = { custom = custom.recipient_every_vassal change_liege = { - LIEGE = scope:actor + LIEGE = scope:puppet_or_actor CHANGE = scope:change } } hidden_effect = { change_liege = { - LIEGE = scope:actor + LIEGE = scope:puppet_or_actor CHANGE = scope:change } } @@ -6675,29 +7185,29 @@ execute_prisoner_interaction = { every_player = { limit = { NOR = { - this = scope:actor + this = scope:puppet_or_actor this = scope:recipient } - top_liege = scope:actor.top_liege + top_liege = scope:puppet_or_actor.top_liege } trigger_event = diarchy.8023 } } - } - # Regardless, this is legit politics, so we don't deduct legitimacy for it. - save_scope_value_as = { - name = suppress_legitimacy_from_crime - value = yes + # Regardless, this is legit politics, so we don't deduct legitimacy for it. + save_scope_value_as = { + name = suppress_legitimacy_from_crime + value = yes + } } } # Now, the rest of it. if = { - limit = { scope:recipient = { is_imprisoned_by = scope:actor } } + limit = { scope:recipient = { is_imprisoned_by = scope:puppet_or_actor } } # Are you HumSac'ing the HoF of a faith that doesn't practice HumSac? hidden_effect = { - scope:actor = { + scope:puppet_or_actor = { humsacd_a_hof_effect = { - SACRIFICER = scope:actor + SACRIFICER = scope:puppet_or_actor SACRIFICED_HOF = scope:recipient } } @@ -6706,15 +7216,16 @@ execute_prisoner_interaction = { limit = { always = scope:execution_public } if = { limit = { - scope:actor.capital_county = { + scope:puppet_or_actor.capital_county = { NOT = { has_county_modifier = held_public_execution_modifier } } } custom_description_no_bullet = { + subject = scope:puppet_or_actor text = public_execution_tooltip } - scope:actor = { + scope:puppet_or_actor = { capital_county = { add_county_modifier = { modifier = held_public_execution_modifier @@ -6740,7 +7251,7 @@ execute_prisoner_interaction = { if = { # Boil their skull? limit = { NOT = { always = scope:execution_devour } - scope:actor = { + scope:puppet_or_actor = { has_relation_rival = scope:recipient has_personality_malicious_trigger = yes has_royal_court = yes @@ -6750,7 +7261,7 @@ execute_prisoner_interaction = { is_adult = yes } } - scope:actor = { + scope:puppet_or_actor = { random = { chance = { value = 25 @@ -6776,7 +7287,7 @@ execute_prisoner_interaction = { if = { limit = { NOT = { always = scope:execution_devour } - scope:actor = { + scope:puppet_or_actor = { is_adult = no age >= 4 is_ai = no @@ -6786,12 +7297,12 @@ execute_prisoner_interaction = { is_adult = yes } } - scope:actor = { trigger_event = bp1_yearly.9045 } + scope:puppet_or_actor = { trigger_event = bp1_yearly.9045 } } else_if = { limit = { NOT = { always = scope:execution_devour } - scope:actor = { + scope:puppet_or_actor = { OR = { has_relation_friend = scope:recipient has_relation_lover = scope:recipient @@ -6802,10 +7313,10 @@ execute_prisoner_interaction = { is_adult = yes } } - scope:actor = { trigger_event = bp1_yearly.9044 } + scope:puppet_or_actor = { trigger_event = bp1_yearly.9044 } } # Gallowsbait. - scope:actor = { + scope:puppet_or_actor = { if = { limit = { has_government = landless_adventurer_government @@ -6858,34 +7369,34 @@ execute_prisoner_interaction = { # FP3 # Struggle Catalysts - scope:actor = { - if = { # Execute important - limit = { - scope:recipient = { is_important_or_vip_struggle_character = yes } - any_character_struggle = { - activate_struggle_catalyst_secondary_character_involvement_either_trigger = { - CATALYST = catalyst_execute_important - CHAR = scope:recipient - } - } - } - every_character_struggle = { - limit = { - activate_struggle_catalyst_secondary_character_involvement_either_trigger = { - CATALYST = catalyst_execute_important - CHAR = scope:recipient - } - } - activate_struggle_catalyst = { - catalyst = catalyst_execute_important - character = scope:actor - } - } - } +# scope:puppet_or_actor = { +# if = { # Execute important +# limit = { +# scope:recipient = { is_important_or_vip_struggle_character = yes } +# any_character_struggle = { +# activate_struggle_catalyst_secondary_character_involvement_either_trigger = { +# CATALYST = catalyst_execute_important +# CHAR = scope:recipient +# } +# } +# } +# every_character_struggle = { +# limit = { +# activate_struggle_catalyst_secondary_character_involvement_either_trigger = { +# CATALYST = catalyst_execute_important +# CHAR = scope:recipient +# } +# } +# activate_struggle_catalyst = { +# catalyst = catalyst_execute_important +# character = scope:puppet_or_actor +# } +# } +# } # if = { # Execute Supporter/Detractor # limit = { # fp3_struggle_involves_one_supporter_and_one_detractor = { -# FIRST = scope:actor +# FIRST = scope:puppet_or_actor # SECOND = scope:recipient # } # } @@ -6909,7 +7420,7 @@ execute_prisoner_interaction = { # } # activate_struggle_catalyst = { # catalyst = catalyst_execute_detractor -# character = scope:actor +# character = scope:puppet_or_actor # } # log_debug_variable_for_persian_struggle_effect = { VAR = stabil_catalyst_execute_detractor } # } @@ -6935,67 +7446,67 @@ execute_prisoner_interaction = { # } # activate_struggle_catalyst = { # catalyst = catalyst_execute_supporter -# character = scope:actor +# character = scope:puppet_or_actor # } # log_debug_variable_for_persian_struggle_effect = { VAR = unrest_catalyst_execute_supporter } # } # } # } - # Free House Member CB target executed during war - if = { - limit = { - exists = scope:recipient.house - any_character_war = { - using_cb = fp3_free_house_member_cb - is_defender = scope:actor - primary_attacker.house = scope:recipient.house - } - } - random_character_war = { - limit = { - using_cb = fp3_free_house_member_cb - is_defender = scope:actor - primary_attacker.house = scope:recipient.house - } - primary_attacker = { - add_opinion = { - target = scope:actor - modifier = executed_close_relation_opinion - } - } - } - add_prestige = { - value = medium_piety_loss - multiply = { - value = ai_honor - add = 1 - } - } - every_vassal = { - limit = { - OR = { - has_vassal_stance = courtly - has_vassal_stance = glory_hound - ai_honor > 0.48 - } - } - add_opinion = { - target = scope:actor - modifier = executed_valuable_prisoner_modifier - } - } - } - } +# # Free House Member CB target executed during war +# if = { +# limit = { +# exists = scope:recipient.house +# any_character_war = { +# using_cb = fp3_free_house_member_cb +# is_defender = scope:puppet_or_actor +# primary_attacker.house = scope:recipient.house +# } +# } +# random_character_war = { +# limit = { +# using_cb = fp3_free_house_member_cb +# is_defender = scope:puppet_or_actor +# primary_attacker.house = scope:recipient.house +# } +# primary_attacker = { +# add_opinion = { +# target = scope:puppet_or_actor +# modifier = executed_close_relation_opinion +# } +# } +# } +# add_prestige = { +# value = medium_piety_loss +# multiply = { +# value = ai_honor +# add = 1 +# } +# } +# every_vassal = { +# limit = { +# OR = { +# has_vassal_stance = courtly +# has_vassal_stance = glory_hound +# ai_honor > 0.48 +# } +# } +# add_opinion = { +# target = scope:puppet_or_actor +# modifier = executed_valuable_prisoner_modifier +# } +# } +# } +# } if = { limit = { - scope:actor.faith = { - has_doctrine = tenet_extinction_of_dharma + scope:puppet_or_actor.rite = { + rite_has_tenet = tenet_extinction_of_dharma } - scope:recipient.faith = { - religion = scope:actor.faith.religion + scope:recipient.rite = { + religion = scope:puppet_or_actor.faith.religion NOT = { - has_doctrine = tenet_extinction_of_dharma + rite_has_tenet = tenet_extinction_of_dharma } } } @@ -7003,65 +7514,22 @@ execute_prisoner_interaction = { limit = { scope:recipient = { is_ruler = yes - highest_held_title_tier = tier_county } } - scope:actor = { - add_piety = minor_piety_value - } - } - else_if = { - limit = { - scope:recipient = { - highest_held_title_tier = tier_duchy - } - } - scope:actor = { - add_piety = medium_piety_value - } - } - else_if = { - limit = { - scope:recipient = { - highest_held_title_tier = tier_kingdom - } - } - scope:actor = { - add_piety = major_piety_value - } - } - else_if = { - limit = { - scope:recipient = { - highest_held_title_tier = tier_empire - } - } - scope:actor = { - add_piety = massive_piety_value - } - } - else_if = { - limit = { - scope:recipient = { - highest_held_title_tier = tier_hegemony - } - } - scope:actor = { - add_piety = monumental_piety_value + scope:puppet_or_actor = { + add_piety = scope:recipient.tier_scaled_piety_value } } else = { - scope:actor = { + scope:puppet_or_actor = { add_piety = miniscule_piety_value } } } if = { limit = { - scope:actor = { - faith = { - has_doctrine = tenet_cranial_trophies - } + scope:puppet_or_actor = { + tgp_cranial_trophies_collection_trigger = yes } scope:recipient = { is_adult = yes @@ -7069,7 +7537,7 @@ execute_prisoner_interaction = { } } tgp_cranial_trophies_beheading_effect = { - KILLER = scope:actor + KILLER = scope:puppet_or_actor DEAD = scope:recipient } } @@ -7077,13 +7545,13 @@ execute_prisoner_interaction = { if = { limit = { scope:recipient = { is_ai = no } - scope:actor = { is_ai = yes } + scope:puppet_or_actor = { is_ai = yes } } scope:recipient = { trigger_event = char_interaction.0170 } # Give players a chance to see what's about to happen show_as_tooltip = { execute_prisoner_effect = { VICTIM = scope:recipient - EXECUTIONER = scope:actor + EXECUTIONER = scope:puppet_or_actor } } } @@ -7091,42 +7559,20 @@ execute_prisoner_interaction = { scope:recipient = { trigger_event = char_interaction.0171 } execute_prisoner_effect = { VICTIM = scope:recipient - EXECUTIONER = scope:actor + EXECUTIONER = scope:puppet_or_actor } } if = { limit = { always = scope:execution_devour } - scope:actor = { + scope:puppet_or_actor = { custom_tooltip = devour_as_execution_tooltip - if = { - limit = { - faith = { has_doctrine_parameter = cannibalism_legal } - NOT = { has_trait = cannibal } - } - add_trait = cannibal - } - stress_impact = { - base = medium_stress_impact_loss - compassionate = miniscule_stress_impact_gain - forgiving = miniscule_stress_impact_gain - } - random = { - chance = 20 - show_as_tooltip = { add_trait = ill } - hidden_effect = { - trigger_event = { - id = health.1001 - days = { 3 10 } - } - } - } } } if = { limit = { always = scope:execution_provisions } - scope:actor = { + scope:puppet_or_actor = { domicile ?= { change_provisions = human_provision_value } @@ -7136,22 +7582,18 @@ execute_prisoner_interaction = { if = { limit = { always = scope:execution_burned - scope:actor.faith = { - has_doctrine = doctrine_pluralism_fundamentalist - NOT = { - has_doctrine = tenet_extinction_of_dharma - } - } + scope:puppet_or_actor.rite = { rite_has_doctrine = doctrine_pluralism_fundamentalist } + scope:puppet_or_actor.rite = { NOT = { rite_has_tenet = tenet_extinction_of_dharma } } } - scope:actor = { + scope:puppet_or_actor = { add_piety = miniscule_piety_value } } - scope:actor = { + scope:puppet_or_actor = { hidden_effect = { send_interface_message = { - type = event_prison_neutral + type = interaction_prison_single_side title = msg_execute_prisoner right_icon = scope:recipient custom_tooltip = msg_execute_prisoner_desc @@ -7165,17 +7607,18 @@ execute_prisoner_interaction = { send_option = { is_shown = { - scope:actor = { + scope:puppet_or_actor = { OR = { mpo_keep_prisoners_heads_trigger = yes faith = scope:recipient.faith - faith = { - has_doctrine = tenet_cranial_trophies + rite = { + rite_has_parameter = killing_bestows_heads } + has_personal_tenet_flag = killing_bestows_heads culture_has_asian_heritage_pillar_trigger = yes } NOT = { - faith = { has_doctrine_parameter = human_sacrifice_active } + rite = { rite_has_parameter = human_sacrifice_active } } } } @@ -7186,11 +7629,12 @@ execute_prisoner_interaction = { #Cannibal option. Should be treated as a "normal" execution, but that you eat the body afterwards (in secret if faith does not allow it). send_option = { is_shown = { - scope:actor = { + scope:puppet_or_actor = { OR = { - scope:actor.faith = { has_doctrine_parameter = cannibalism_legal } + rite = { rite_has_parameter = cannibalism_legal } has_trait = cannibal any_secret = { type = secret_cannibal } + has_personal_tenet_flag = tenet_ritual_cannibalism_devour_reward } } } @@ -7200,11 +7644,11 @@ execute_prisoner_interaction = { send_option = { is_shown = { - scope:actor = { + scope:puppet_or_actor = { NOR = { AND = { faith = scope:recipient.faith - faith = { has_doctrine_parameter = human_sacrifice_active } + rite = { rite_has_parameter = human_sacrifice_active } } mpo_keep_prisoners_heads_trigger = yes culture_has_asian_heritage_pillar_trigger = yes @@ -7217,7 +7661,7 @@ execute_prisoner_interaction = { send_option = { is_shown = { - scope:actor.faith = { has_doctrine_parameter = human_sacrifice_active } + scope:puppet_or_actor.rite = { rite_has_parameter = human_sacrifice_active } } flag = execution_sacrifice localization = "EXECUTION_SACRIFICE" @@ -7225,7 +7669,7 @@ execute_prisoner_interaction = { send_option = { is_shown = { - scope:actor = { + scope:puppet_or_actor = { employs_court_position = executioner_court_position any_court_position_holder = { type = executioner_court_position @@ -7235,7 +7679,7 @@ execute_prisoner_interaction = { } } is_valid = { - scope:actor = { + scope:puppet_or_actor = { NOT = { capital_county = { has_county_modifier = held_public_execution_modifier @@ -7249,7 +7693,7 @@ execute_prisoner_interaction = { send_option = { is_shown = { - scope:actor = { + scope:puppet_or_actor = { employs_court_position = kennelperson_camp_officer any_court_position_holder = { type = kennelperson_camp_officer @@ -7263,7 +7707,7 @@ execute_prisoner_interaction = { send_option = { is_shown = { - scope:actor = { + scope:puppet_or_actor = { has_government = landless_adventurer_government has_perk = fear_tax_perk } @@ -7317,9 +7761,9 @@ torture_interaction = { cooldown_against_recipient = { years = 5 } is_shown = { - scope:recipient = { is_imprisoned_by = scope:actor } + scope:puppet_or_actor ?= { is_adult = yes } + scope:recipient = { is_imprisoned_by = scope:puppet_or_actor } scope:recipient = { is_adult = yes } - scope:actor = { is_adult = yes } } is_valid_showing_failures_only = { @@ -7328,14 +7772,23 @@ torture_interaction = { # health <= 1.5 #Because torture would definitely kill them # } #} - scope:actor = { + scope:puppet_or_actor = { trigger_if = { limit = { domicile ?= { is_domicile_type = camp } } - custom_tooltip = { - text = laamp_torture_requires_tools_tt - domicile = { has_domicile_parameter = camp_unlocks_torture_interaction } + trigger_if = { + limit = { scope:actor = scope:puppet_or_actor } + custom_tooltip = { + text = laamp_torture_requires_tools_tt + domicile = { has_domicile_parameter = camp_unlocks_torture_interaction } + } + } + trigger_else = { + custom_tooltip = { + text = laamp_torture_requires_tools_tt_puppeteer + domicile = { has_domicile_parameter = camp_unlocks_torture_interaction } + } } } } @@ -7350,7 +7803,7 @@ torture_interaction = { REGENT = scope:recipient.var:imprisoned_by_diarch } tgp_blocked_action_against_tenno_trigger = { - ACTOR = scope:actor + ACTOR = scope:puppet_or_actor TARGET = scope:recipient } custom_tooltip = { @@ -7365,9 +7818,9 @@ torture_interaction = { is_highlighted = { OR = { - scope:actor = { has_trait = sadistic } - scope:actor = { has_relation_rival = scope:recipient } - scope:actor = { has_relation_nemesis = scope:recipient } + scope:puppet_or_actor = { has_trait = sadistic } + scope:puppet_or_actor = { has_relation_rival = scope:recipient } + scope:puppet_or_actor = { has_relation_nemesis = scope:recipient } } } @@ -7378,7 +7831,7 @@ torture_interaction = { months = 6 # Players in MP can keep the event window open... } } - scope:actor = { save_scope_as = bg_override_char } + scope:puppet_or_actor = { save_scope_as = bg_override_char } ###EFFECT TOOLTIP### torture_interaction_actor_effect = yes show_as_tooltip = { @@ -7391,11 +7844,11 @@ torture_interaction = { } if = { limit = { - scope:actor = { + scope:puppet_or_actor = { domicile ?= { has_domicile_parameter = estate_torture_grants_influence } } } - scope:actor = { custom_tooltip = estate_torture_grants_influence_desc } + scope:puppet_or_actor = { custom_tooltip = estate_torture_grants_influence_desc } } ###EVENTS### @@ -7407,7 +7860,7 @@ torture_interaction = { 1 = { save_scope_value_as = { name = torture_method value = flag:rats } } 8 = { trigger = { - scope:actor = { has_trait = lifestyle_poet } + scope:puppet_or_actor = { has_trait = lifestyle_poet } } save_scope_value_as = { name = torture_method @@ -7439,7 +7892,7 @@ torture_interaction = { } } else = { - scope:actor = { + scope:puppet_or_actor = { trigger_event = { id = prison.1010 days = 1 @@ -7451,9 +7904,9 @@ torture_interaction = { # Dark Insights Perk: if = { limit = { - scope:actor = { has_perk = dark_insights_perk } + scope:puppet_or_actor = { has_perk = dark_insights_perk } } - scope:actor = { + scope:puppet_or_actor = { dark_insights_skill_gain_roll_effect = yes } } @@ -7461,10 +7914,10 @@ torture_interaction = { # House Relation scope:recipient.house ?= { change_house_relation_effect = { - HOUSE = scope:actor.house + HOUSE = scope:puppet_or_actor.house VALUE = house_relation_damage_medium_value REASON = torture - CHAR = scope:actor + CHAR = scope:puppet_or_actor TARGET_CHAR = scope:recipient TITLE = scope:dummy_gender } @@ -7487,10 +7940,6 @@ torture_interaction = { hegemony = 12 } - ai_potential = { - always = yes - } - ai_will_do = { base = -25 @@ -7508,13 +7957,13 @@ torture_interaction = { #Scope:target has caused internal strife in the realm character_hates_scope_due_to_strife_modifier = { TARGET = scope:recipient } modifier = { # Family Feud - scope:actor = { + scope:puppet_or_actor = { house_has_feud_relation_with_trigger = { TARGET = scope:recipient } } add = 30 } modifier = { - scope:actor = { + scope:puppet_or_actor = { has_opinion_modifier = { modifier = tried_to_escape_from_prison_opinion target = scope:recipient @@ -7533,16 +7982,11 @@ castrate_interaction = { desc = castrate_interaction_desc is_shown = { - scope:recipient = { - is_imprisoned_by = scope:actor - is_eunuch_trigger = no - is_male = yes - } - scope:actor = { + scope:puppet_or_actor ?= { is_adult = yes OR = { - culture = { has_cultural_parameter = can_castrate_prisoners } - top_liege.primary_title = { + culture ?= { has_cultural_parameter = can_castrate_prisoners } + top_liege.primary_title ?= { has_variable = emulating_byz_punishment_var } } @@ -7550,6 +7994,11 @@ castrate_interaction = { # If they're our partner emperor, we should use the maiming interaction instead. liege_should_systematically_maim_co_ruler_trigger = no } + scope:recipient = { + is_imprisoned_by = scope:puppet_or_actor + is_eunuch_trigger = no + is_male = yes + } } is_valid_showing_failures_only = { @@ -7575,11 +8024,11 @@ castrate_interaction = { is_highlighted = { OR = { - scope:actor = { has_trait = sadistic } - scope:actor = { has_relation_rival = scope:recipient } + scope:puppet_or_actor = { has_trait = sadistic } + scope:puppet_or_actor = { has_relation_rival = scope:recipient } scope:recipient = { any_claim = { - holder = scope:actor + holder = scope:puppet_or_actor } } } @@ -7612,7 +8061,7 @@ castrate_interaction = { torture_blind_castrate_disfigure_opinion_effect = { VERB = castrated } - scope:actor = { + scope:puppet_or_actor = { save_scope_as = bg_override_char trigger_event = { id = prison.1025 @@ -7622,7 +8071,7 @@ castrate_interaction = { # If we're a clan this interaction affects unity add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = major_unity_loss DESC = clan_unity_abelarding.desc @@ -7632,10 +8081,10 @@ castrate_interaction = { # House Relation scope:recipient.house ?= { change_house_relation_effect = { - HOUSE = scope:actor.house + HOUSE = scope:puppet_or_actor.house VALUE = house_relation_damage_medium_value REASON = torture - CHAR = scope:actor + CHAR = scope:puppet_or_actor TARGET_CHAR = scope:recipient TITLE = scope:dummy_gender } @@ -7648,10 +8097,6 @@ castrate_interaction = { ai_recipients = prisoners } - ai_potential = { - always = yes - } - ai_will_do = { base = -20 @@ -7710,21 +8155,21 @@ blind_interaction = { desc = blind_interaction_desc is_shown = { - scope:recipient = { - is_imprisoned_by = scope:actor - NOT = { has_trait = blind } - } - scope:actor = { + scope:puppet_or_actor ?= { is_adult = yes OR = { - culture = { has_cultural_parameter = can_blind_prisoners } - top_liege.primary_title = { + culture ?= { has_cultural_parameter = can_blind_prisoners } + top_liege.primary_title ?= { has_variable = emulating_byz_punishment_var } } # If they're our partner emperor, we should use the maiming interaction instead. liege_should_systematically_maim_co_ruler_trigger = no } + scope:recipient = { + is_imprisoned_by = scope:puppet_or_actor + NOT = { has_trait = blind } + } } is_valid_showing_failures_only = { @@ -7750,14 +8195,14 @@ blind_interaction = { is_highlighted = { OR = { - scope:actor = { has_trait = sadistic } - scope:actor = { has_relation_rival = scope:recipient } + scope:puppet_or_actor = { has_trait = sadistic } + scope:puppet_or_actor = { has_relation_rival = scope:recipient } scope:recipient = { any_claim = { - holder = scope:actor + holder = scope:puppet_or_actor } } - scope:actor = { + scope:puppet_or_actor = { culture = { has_cultural_parameter = merciful_blinding } OR = { has_execute_reason = scope:recipient @@ -7785,7 +8230,7 @@ blind_interaction = { } # Merciful Blindings - scope:actor = { + scope:puppet_or_actor = { if = { limit = { culture = { has_cultural_parameter = merciful_blinding } @@ -7800,7 +8245,7 @@ blind_interaction = { torture_blind_castrate_disfigure_opinion_effect = { VERB = blinded } - scope:actor = { + scope:puppet_or_actor = { save_scope_as = bg_override_char trigger_event = { id = prison.1020 @@ -7810,9 +8255,9 @@ blind_interaction = { # If we're a clan this interaction affects unity if = { - limit = { scope:actor.culture = { has_cultural_parameter = merciful_blinding } } # If actor's culture has Merciful Blindings, they lose less unity + limit = { scope:puppet_or_actor.culture = { has_cultural_parameter = merciful_blinding } } # If actor's culture has Merciful Blindings, they lose less unity add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = minor_unity_loss DESC = clan_unity_blinding.desc @@ -7821,7 +8266,7 @@ blind_interaction = { } else = { add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = medium_unity_loss DESC = clan_unity_blinding.desc @@ -7832,10 +8277,10 @@ blind_interaction = { # House Relation scope:recipient.house ?= { change_house_relation_effect = { - HOUSE = scope:actor.house + HOUSE = scope:puppet_or_actor.house VALUE = house_relation_damage_medium_value REASON = torture - CHAR = scope:actor + CHAR = scope:puppet_or_actor TARGET_CHAR = scope:recipient TITLE = scope:dummy_gender } @@ -7848,10 +8293,6 @@ blind_interaction = { ai_recipients = prisoners } - ai_potential = { - always = yes - } - ai_will_do = { base = -20 @@ -7869,13 +8310,13 @@ blind_interaction = { #Scope:target has caused internal strife in the realm character_hates_scope_due_to_strife_modifier = { TARGET = scope:recipient } modifier = { # Family Feud - scope:actor = { + scope:puppet_or_actor = { house_has_feud_relation_with_trigger = { TARGET = scope:recipient } } add = 30 } modifier = { - scope:actor = { + scope:puppet_or_actor = { has_opinion_modifier = { modifier = tried_to_escape_from_prison_opinion target = scope:recipient @@ -7918,9 +8359,9 @@ prison_break_contract_interaction = { any_character_active_contract = { task_contract_type = laamp_prison_break_contract OR = { - var:task_contract_target = scope:recipient - var:task_contract_object = scope:recipient - var:task_contract_employer = scope:recipient + var:task_contract_target ?= scope:recipient + var:task_contract_object ?= scope:recipient + var:task_contract_employer ?= scope:recipient } } } @@ -7992,18 +8433,30 @@ systematically_maim_character_interaction = { desc = systematically_maim_character_interaction_desc is_shown = { - scope:actor = { liege_should_systematically_maim_co_ruler_trigger = yes } + scope:puppet_or_actor ?= { + liege_should_systematically_maim_co_ruler_trigger = yes + trigger_if = { + limit = { + is_ai = yes + NOT = { puppeteer ?= { is_ai = no } } + } + has_diarchy_active_parameter = diarchy_is_co_rulership + liege_can_maim_co_ruler_without_killing_them_trigger = yes + } + } } is_valid_showing_failures_only = { - scope:actor = { is_adult = yes } + scope:puppet_or_actor ?= { + is_adult = yes + } scope:recipient = { custom_description = { text = "currently_being_tortured" NOT = { has_character_flag = is_being_tortured } } } - scope:recipient = { is_imprisoned_by = scope:actor } + scope:recipient = { is_imprisoned_by = scope:puppet_or_actor } # There's literally nothing left to remove. scope:recipient = { NAND = { @@ -8022,7 +8475,7 @@ systematically_maim_character_interaction = { send_option = { flag = maim_castrate is_shown = { - scope:actor.culture = { + scope:puppet_or_actor.culture ?= { has_cultural_parameter = can_castrate_prisoners } } @@ -8040,7 +8493,7 @@ systematically_maim_character_interaction = { send_option = { flag = maim_blind is_shown = { - scope:actor.culture = { + scope:puppet_or_actor.culture ?= { has_cultural_parameter = can_blind_prisoners } } @@ -8056,7 +8509,7 @@ systematically_maim_character_interaction = { send_option = { flag = maim_face is_shown = { - scope:actor.culture = { + scope:puppet_or_actor.culture ?= { has_cultural_parameter = can_blind_prisoners } } @@ -8100,17 +8553,17 @@ systematically_maim_character_interaction = { explicit = yes save_temporary_scope_as = temp_claim OR = { - holder = scope:actor + holder = scope:puppet_or_actor AND = { - NOT = { prev = { target_is_liege_or_above = scope:actor } } + NOT = { prev = { target_is_liege_or_above = scope:puppet_or_actor } } trigger_if = { limit = { exists = holder } - holder = { target_is_liege_or_above = scope:actor } + holder = { target_is_liege_or_above = scope:puppet_or_actor } } } - scope:actor = { + scope:puppet_or_actor ?= { any_held_title = { is_de_jure_liege_or_above_target = scope:temp_claim } @@ -8138,15 +8591,15 @@ systematically_maim_character_interaction = { AND = { is_playable_character = no is_ruler = no - gold > scope:actor.gold - gold > scope:actor.medium_gold_value - scope:actor.ai_greed > low_negative_ai_value + gold > scope:puppet_or_actor.gold + gold > scope:puppet_or_actor.medium_gold_value + scope:puppet_or_actor.ai_greed > low_negative_ai_value } AND = { is_playable_character = no is_ruler = no gold > 0 - scope:actor = { + scope:puppet_or_actor ?= { has_banish_reason = scope:recipient } } @@ -8154,13 +8607,13 @@ systematically_maim_character_interaction = { is_playable_character = no is_ruler = no gold > 100 - scope:actor.ai_greed >= high_positive_ai_value + scope:puppet_or_actor.ai_greed >= high_positive_ai_value } AND = { - scope:actor = { + scope:puppet_or_actor ?= { has_banish_reason = scope:recipient } - scope:actor = { + scope:puppet_or_actor ?= { opinion = { target = scope:recipient value <= medium_negative_opinion @@ -8177,17 +8630,17 @@ systematically_maim_character_interaction = { } } scope:recipient = { - is_vassal_of = scope:actor + is_vassal_of = scope:puppet_or_actor } } trigger_else = { scope:recipient = { - is_courtier_of = scope:actor + is_courtier_of = scope:puppet_or_actor } } NOT = { scope:recipient = { - is_spouse_of = scope:actor + is_spouse_of = scope:puppet_or_actor } } } @@ -8197,7 +8650,7 @@ systematically_maim_character_interaction = { flag = take_vows localization = "RELEASE_TAKE_VOWS" is_shown = { - scope:actor = { take_vows_available_trigger = yes } + scope:puppet_or_actor ?= { take_vows_available_trigger = yes } } is_valid = { #Handle AI @@ -8208,32 +8661,32 @@ systematically_maim_character_interaction = { #We're AI and Byzantium trigger_if = { limit = { - scope:actor = { + scope:puppet_or_actor = { culture = { has_cultural_pillar = heritage_byzantine } } } scope:recipient = { is_ai = yes #Not gonna depose player characters, for now OR = { - is_close_or_extended_family_of = scope:actor - is_vassal_or_below_of = scope:actor #Weigh this for Byz AI in the modifiers below - has_relation_rival = scope:actor - is_courtier_of = scope:actor + is_close_or_extended_family_of = scope:puppet_or_actor + is_vassal_or_below_of = scope:puppet_or_actor #Weigh this for Byz AI in the modifiers below + has_relation_rival = scope:puppet_or_actor + is_courtier_of = scope:puppet_or_actor } NOT = { - is_heir_of = scope:actor + is_heir_of = scope:puppet_or_actor } } #Get rid of rivals despite potentially liking them trigger_if = { limit = { - scope:recipient = { has_relation_rival = scope:actor } + scope:recipient = { has_relation_rival = scope:puppet_or_actor } } always = yes } #Only get rid of family members if we dislike them trigger_else = { - scope:actor = { + scope:puppet_or_actor = { opinion = { target = scope:recipient value <= medium_negative_opinion @@ -8245,12 +8698,12 @@ systematically_maim_character_interaction = { trigger_else = { scope:recipient = { is_ai = yes #Not gonna depose player characters, for now - is_close_or_extended_family_of = scope:actor + is_close_or_extended_family_of = scope:puppet_or_actor NOT = { - is_heir_of = scope:actor + is_heir_of = scope:puppet_or_actor } } - scope:actor = { + scope:puppet_or_actor = { opinion = { target = scope:recipient value <= medium_negative_opinion @@ -8259,15 +8712,15 @@ systematically_maim_character_interaction = { custom_description = { text = "release_vows_invalid_not_your_court" object = scope:recipient - subject = scope:actor - scope:recipient = { is_courtier_of = scope:actor } + subject = scope:puppet_or_actor + scope:recipient = { is_courtier_of = scope:puppet_or_actor } } } } #Enhanced Take the Vows for Byzantium players -- who do we want to boot to a monastery far, far away? trigger_else_if = { limit = { - scope:actor = { + scope:puppet_or_actor = { culture = { has_cultural_pillar = heritage_byzantine } } } @@ -8276,12 +8729,12 @@ systematically_maim_character_interaction = { custom_description = { text = "release_byz_vows_invalid" object = scope:recipient - subject = scope:actor + subject = scope:puppet_or_actor OR = { - is_close_or_extended_family_of = scope:actor - is_vassal_or_below_of = scope:actor - has_relation_rival = scope:actor - is_courtier_of = scope:actor + is_close_or_extended_family_of = scope:puppet_or_actor + is_vassal_or_below_of = scope:puppet_or_actor + has_relation_rival = scope:puppet_or_actor + is_courtier_of = scope:puppet_or_actor } } } @@ -8291,12 +8744,12 @@ systematically_maim_character_interaction = { scope:recipient = { is_ai = yes #Not gonna depose player characters, for now } - scope:actor = { is_close_or_extended_family_of = scope:recipient } #Triggering I_AM_NOT instead of CHARACTER_IS_NOT makes the tooltip look less cursed + scope:puppet_or_actor = { is_close_or_extended_family_of = scope:recipient } #Triggering I_AM_NOT instead of CHARACTER_IS_NOT makes the tooltip look less cursed custom_description = { text = "release_vows_invalid_not_your_court" object = scope:recipient - subject = scope:actor - scope:recipient = { is_courtier_of = scope:actor } + subject = scope:puppet_or_actor + scope:recipient = { is_courtier_of = scope:puppet_or_actor } } } @@ -8362,7 +8815,7 @@ systematically_maim_character_interaction = { value = yes } show_as_tooltip = { - scope:actor = { maiming_destroy_diarchy_effect = yes } + scope:puppet_or_actor = { maiming_destroy_diarchy_effect = yes } } # Let the enchoppening begin. @@ -8385,7 +8838,7 @@ systematically_maim_character_interaction = { } } torture_blind_castrate_disfigure_opinion_effect = { VERB = castrated } - scope:actor = { + scope:puppet_or_actor = { clear_designated_heir = yes trigger_event = { id = prison.1025 @@ -8393,7 +8846,7 @@ systematically_maim_character_interaction = { } } add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = major_unity_loss DESC = clan_unity_abelarding.desc @@ -8409,7 +8862,7 @@ systematically_maim_character_interaction = { } } torture_blind_castrate_disfigure_opinion_effect = { VERB = blinded } - scope:actor = { + scope:puppet_or_actor = { clear_designated_heir = yes # Merciful Blindings if = { @@ -8430,10 +8883,10 @@ systematically_maim_character_interaction = { # If actor's culture has Merciful Blindings, they lose less unity. if = { limit = { - scope:actor.culture = { has_cultural_parameter = merciful_blinding } + scope:puppet_or_actor.culture = { has_cultural_parameter = merciful_blinding } } add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = minor_unity_loss DESC = clan_unity_blinding.desc @@ -8442,7 +8895,7 @@ systematically_maim_character_interaction = { } else = { add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = medium_unity_loss DESC = clan_unity_blinding.desc @@ -8459,7 +8912,7 @@ systematically_maim_character_interaction = { } } torture_blind_castrate_disfigure_opinion_effect = { VERB = disfigured } - scope:actor = { + scope:puppet_or_actor = { clear_designated_heir = yes trigger_event = { id = prison.1030 @@ -8467,7 +8920,7 @@ systematically_maim_character_interaction = { } } add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = major_unity_loss DESC = clan_unity_maimed.desc @@ -8483,7 +8936,7 @@ systematically_maim_character_interaction = { } } torture_blind_castrate_disfigure_opinion_effect = { VERB = maimed } - scope:actor = { + scope:puppet_or_actor = { clear_designated_heir = yes save_scope_value_as = { name = maim_type @@ -8495,7 +8948,7 @@ systematically_maim_character_interaction = { } } add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = major_unity_loss DESC = clan_unity_maimed.desc @@ -8511,7 +8964,7 @@ systematically_maim_character_interaction = { } } torture_blind_castrate_disfigure_opinion_effect = { VERB = maimed } - scope:actor = { + scope:puppet_or_actor = { clear_designated_heir = yes save_scope_value_as = { name = maim_type @@ -8523,7 +8976,7 @@ systematically_maim_character_interaction = { } } add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = major_unity_loss DESC = clan_unity_maimed.desc @@ -8535,18 +8988,18 @@ systematically_maim_character_interaction = { scope:recipient = { if = { limit = { - is_landed_or_landless_administrative = yes + is_landed_or_landless_administrative_or_theocratic = yes } - banish_effect = { BANISHER = scope:actor } + banish_effect = { BANISHER = scope:puppet_or_actor } if = { limit = { NOT = { - scope:actor = { + scope:puppet_or_actor = { has_banish_reason = scope:recipient } } } - scope:actor = { add_tyranny = banishment_tyranny_gain } + scope:puppet_or_actor = { add_tyranny = banishment_tyranny_gain } } } # Banish Unlanded Character @@ -8558,12 +9011,12 @@ systematically_maim_character_interaction = { if = { limit = { gold > 0 - NOR = { - has_character_flag = realm_priest - has_character_flag = was_bookmaker + has_none_of_variables = { + name = realm_priest + name = was_bookmaker } } - pay_short_term_gold = { target = scope:actor gold = scope:recipient.gold } + pay_short_term_gold = { target = scope:puppet_or_actor gold = scope:recipient.gold } } if = { limit = { @@ -8572,15 +9025,15 @@ systematically_maim_character_interaction = { every_character_artifact = { limit = { NOT = { has_variable = artifact_prevent_transfer } } set_owner = { - target = scope:actor + target = scope:puppet_or_actor history = { location = scope:recipient.location actor = scope:recipient - recipient = scope:actor + recipient = scope:puppet_or_actor type = stolen } } - scope:actor = { + scope:puppet_or_actor = { if = { limit = { NOT = { has_variable = stolen_artifact } @@ -8611,12 +9064,12 @@ systematically_maim_character_interaction = { limit = { gold > 0 } - pay_short_term_gold = { target = scope:actor gold = scope:recipient.gold } + pay_short_term_gold = { target = scope:puppet_or_actor gold = scope:recipient.gold } } } add_opinion = { modifier = banished_me - target = scope:actor + target = scope:puppet_or_actor } release_from_prison = yes } @@ -8626,7 +9079,7 @@ systematically_maim_character_interaction = { scope:recipient = { add_opinion = { modifier = demanded_claim_renouncement - target = scope:actor + target = scope:puppet_or_actor } release_from_prison = yes every_claim = { @@ -8634,13 +9087,13 @@ systematically_maim_character_interaction = { limit = { save_temporary_scope_as = temp_claim OR = { - holder = scope:actor + holder = scope:puppet_or_actor AND = { exists = holder - NOT = { prev = { target_is_liege_or_above = scope:actor } } - holder = { target_is_liege_or_above = scope:actor } + NOT = { prev = { target_is_liege_or_above = scope:puppet_or_actor } } + holder = { target_is_liege_or_above = scope:puppet_or_actor } } - scope:actor = { + scope:puppet_or_actor = { any_held_title = { is_de_jure_liege_or_above_target = scope:temp_claim } @@ -8657,7 +9110,7 @@ systematically_maim_character_interaction = { #Does Byzan go hay-wire with deposing vassals? if = { limit = { - scope:actor = { + scope:puppet_or_actor = { is_ai = yes culture = { has_cultural_pillar = heritage_byzantine } } @@ -8668,7 +9121,7 @@ systematically_maim_character_interaction = { #Does the AI in general go haywire with deposing prisoners? else_if = { limit = { - scope:actor = { is_ai = yes } + scope:puppet_or_actor = { is_ai = yes } } debug_log = debug_ai_forced_vows_on_prison_release debug_log_scopes = yes @@ -8684,11 +9137,6 @@ systematically_maim_character_interaction = { ai_targets = { ai_recipients = prisoners } - ai_potential = { - has_diarchy_active_parameter = diarchy_is_co_rulership - liege_can_maim_co_ruler_without_killing_them_trigger = yes - } - ai_will_do = { base = -50 @@ -8710,13 +9158,13 @@ systematically_maim_character_interaction = { #Scope:target has caused internal strife in the realm character_hates_scope_due_to_strife_modifier = { TARGET = scope:recipient } modifier = { # Family Feud - scope:actor = { + scope:puppet_or_actor = { house_has_feud_relation_with_trigger = { TARGET = scope:recipient } } add = 30 } modifier = { - scope:actor = { + scope:puppet_or_actor = { has_opinion_modifier = { modifier = tried_to_escape_from_prison_opinion target = scope:recipient @@ -8735,3 +9183,4 @@ systematically_maim_character_interaction = { hegemony = 60 } } + diff --git a/common/character_interactions/00_puppet_interactions.txt b/common/character_interactions/00_puppet_interactions.txt new file mode 100644 index 000000000..318f1f48e --- /dev/null +++ b/common/character_interactions/00_puppet_interactions.txt @@ -0,0 +1,1233 @@ +make_clerical_puppet_interaction = { + category = interaction_category_diplomacy + icon = { + trigger = { + scope:actor.rite = { + rite_has_doctrine = special_doctrine_is_western_christian_faith + } + } + reference = theological_agent_puppet_catholic + } + icon = { + trigger = { + scope:actor.rite = { + NOT = { rite_has_doctrine = special_doctrine_is_western_christian_faith } + } + } + reference = theological_agent_puppet + } + + common_interaction = yes + interface_priority = 50 + ai_instant_response = yes + + desc = make_clerical_puppet_interaction_desc + + is_available = { + can_have_realm_priest_puppet_trigger = yes + is_incapable = no + trigger_if = { + limit = { + is_ai = yes + } + NOT = { + exists = puppet:theological_agent_puppet + } + } + } + + cooldown_against_recipient = { years = 10 } # Spam prevention + + is_shown = { + scope:actor.cp:councillor_court_chaplain ?= scope:recipient + } + + is_valid_showing_failures_only = { + scope:actor = { + custom_tooltip = { + text = pam_already_have_clerical_puppet_tt + NOT = { + exists = puppet:theological_agent_puppet + } + } + } + scope:recipient = { + is_ai = yes + NOR = { + is_adult = no + has_trait = incapable + } + custom_tooltip = { + text = pam_recipient_already_puppet_tt + NOT = { exists = puppeteer } + } + } + } + + can_send = { + scope:actor = { + custom_tooltip = { + text = piety_level_dread_or_hook_tt + OR = { + piety_level >= 2 + has_hook = scope:recipient + scope:recipient = { + has_dread_level_towards = { + target = scope:actor + level >= 2 + } + } + } + } + } + } + + ai_targets = { + ai_recipients = councillors + } + ai_frequency_by_tier = { + barony = 0 + county = 72 + duchy = 36 + kingdom = 12 + empire = 12 + hegemony = 12 + } + ai_will_do = { + base = 100 + } + + cost = { + piety = { + value = { + value = medium_piety_value + if = { + limit = { + scope:recipient = { + is_ruler = yes + } + } + multiply = { + value = scope:recipient.highest_held_title_tier + subtract = 1 + } + } + } + } + } + + on_accept = { + scope:actor = { + hidden_effect = { + send_interface_toast = { + type = event_toast_effect_good + title = make_clerical_puppet_interaction_notification + left_icon = scope:actor + right_icon = scope:recipient + set_puppet = { + target = scope:recipient + type = theological_agent_puppet + } + pam_generic_set_puppet_interaction_side_effects = yes + } + } + show_as_tooltip = { + pam_generic_set_puppet_interaction_side_effects = yes + } + } + scope:recipient = { + custom_tooltip = set_clerical_puppet_tt + } + } + + send_option = { + is_valid = { + scope:actor = { has_usable_hook = scope:recipient } + } + flag = hook + localization = SCHEME_HOOK + } + #My skills could be useful to you...? + send_option = { + is_valid = { + scope:actor = { + skill_support_trigger = yes + } + } + flag = skill_support + localization = SKILL_SUPPORT_INTERACTION_OPTION + } + #I will lead you into the light by my piety + send_option = { + is_valid = { + scope:actor = { + piety_support_trigger = yes + custom_tooltip = { + text = pious_puppet_sf_req_tt + has_fulfillment_parameter = pious_puppet_option + } + } + } + flag = piety_support + localization = PIETY_SUPPORT_INTERACTION_OPTION + } + #Become an instrument of my dreadful will, not a target of my will + send_option = { + is_valid = { + scope:actor = { + dread_support_trigger = yes + custom_tooltip = { + text = dread_puppet_sf_req_tt + has_fulfillment_parameter = dread_puppet_option + } + } + } + flag = dread_support + localization = DREAD_SUPPORT_INTERACTION_OPTION + } + #You can trust in me, relation + send_option = { + is_valid = { + scope:actor = { + friendly_support_trigger = yes + custom_tooltip = { + text = friendly_puppet_sf_req_tt + has_fulfillment_parameter = positive_relation_puppet_option + } + } + } + flag = friendly_support + localization = FRIENDLY_SUPPORT_INTERACTION_OPTION + } + #Your mind, your will, is no more + send_option = { + is_valid = { + scope:actor = { + lunacy_support_trigger = yes + } + } + flag = lunacy_support + localization = LUNACY_SUPPORT_INTERACTION_OPTION + } + should_use_extra_icon = { + scope:actor = { has_usable_hook = scope:recipient } + } + extra_icon = "gfx/interface/icons/character_interactions/hook_icon.dds" + send_options_exclusive = no + + ai_accept = { + base = -25 + + celestial_hierarchy_acceptance_modifier = { + ACTOR = scope:actor + RECIPIENT = scope:recipient + } + + theocratic_related_puppet_acceptance_factors_modifier = yes + } +} + +make_external_clerical_puppet_interaction = { + category = interaction_category_diplomacy + icon = { + trigger = { + scope:actor.rite = { + rite_has_doctrine = special_doctrine_is_western_christian_faith + } + } + reference = external_theological_agent_puppet_catholic + } + icon = { + trigger = { + scope:actor.rite = { + NOT = { rite_has_doctrine = special_doctrine_is_western_christian_faith } + } + } + reference = external_theological_agent_puppet + } + common_interaction = yes + interface_priority = 50 + ai_instant_response = yes + # Clergy sit across the faith + use_diplomatic_range = no + + desc = make_external_clerical_puppet_interaction_desc + + is_available = { + is_adult = yes + can_have_theological_agent_puppet_trigger = yes + NOT = { has_trait = incapable } + trigger_if = { + limit = { + is_ai = yes + } + NOT = { + exists = puppet:external_theological_agent_puppet + } + } + has_pam_dlc_trigger = yes + } + + cooldown_against_recipient = { years = 10 } # Spam prevention + + is_shown = { + scope:actor != scope:recipient + scope:actor.faith ?= scope:recipient.faith + scope:recipient = { + is_clergy = yes + is_ruler = yes # Hide against unlanded non-ruler clergy; landless clerical title-holders remain valid + NOR = { + scope:actor.puppet:theological_agent_puppet ?= scope:recipient + scope:actor.cp:councillor_court_chaplain ?= scope:recipient + } + } + } + + is_valid_showing_failures_only = { + scope:actor = { + NOR = { + is_at_war_with = scope:recipient + puppet:external_theological_agent_puppet ?= scope:recipient + } + custom_tooltip = { + text = pam_already_have_external_clerical_puppet_tt + NOT = { + exists = puppet:external_theological_agent_puppet + } + } + custom_tooltip = { + text = actor_is_antipope_sponsor_tt + pam_sponsors_other_antipope_trigger = no + } + } + scope:recipient = { + is_ai = yes + NOR = { + is_adult = no + has_trait = incapable + } + custom_tooltip = { + text = pam_recipient_already_puppet_tt + NOT = { exists = puppeteer } + } + } + } + + can_send = { + scope:actor = { + custom_tooltip = { + text = external_theocratic_puppet_reqs_tt + OR = { + trigger_if = { + limit = { + scope:recipient = { + highest_held_title_tier >= tier_kingdom + } + } + has_strong_hook = scope:recipient + } + trigger_else = { + has_hook = scope:recipient + } + AND = { + is_liege_or_above_of = scope:recipient + scope:recipient = { + has_dread_level_towards = { + target = scope:actor + level >= 2 + } + } + } + AND = { + exists = scope:recipient.house + scope:recipient.house.house_head = scope:actor + } + has_any_moderate_good_relationship_with_character_trigger = { CHARACTER = scope:recipient } + scope:recipient = { + is_imprisoned_by = scope:actor + } + any_subordinate = { + this = scope:recipient + } + scope:recipient = { + has_variable_list = puppeteers + any_in_list = { + variable = puppeteers + this = scope:actor + } + } + } + } + } + } + ai_targets = { + ai_recipients = head_of_faith + ai_recipients = head_of_rite + ai_recipients = superior + ai_recipients = top_superior + ai_recipients = realm_priest_superior + ai_recipients = realm_priest_top_superior + ai_recipients = liege + ai_recipients = top_liege + ai_recipients = papabile + ai_recipients = prisoners + } + ai_targets = { + ai_recipients = clerical_region_rulers_in_realm + ai_recipients = faith_holy_order_leaders + ai_recipients = subordinates + ai_recipients = vassals + ai_recipients = hooked_characters + ai_recipients = scripted_relations + ai_recipients = dynasty + max = 10 + } + ai_targets = { + ai_recipients = neighboring_rulers + ai_recipients = peer_vassals + max = 10 + } + ai_target_quick_trigger = { + adult = yes + } + ai_frequency_by_tier = { + barony = 0 + county = 160 + duchy = 48 + kingdom = 24 + empire = 24 + hegemony = 24 + } + ai_will_do = { + base = 100 + + modifier = { + scope:recipient = { + highest_held_title_tier <= tier_county + } + factor = 0.25 + } + modifier = { + scope:recipient = { + highest_held_title_tier <= tier_county + } + scope:actor.highest_held_title_tier >= tier_duchy + factor = 0 + } + } + + cost = { + piety = { + value = { + value = medium_piety_value + multiply = { + value = scope:recipient.highest_held_title_tier + subtract = 1 + } + } + } + } + + on_accept = { + scope:actor = { + trigger_event = pam_interactions_events.0120 + pam_generic_set_puppet_interaction_side_effects = yes + } + scope:recipient = { + custom_tooltip = set_external_clerical_puppet_tt + } + } + + send_option = { + is_valid = { + scope:actor = { has_usable_hook = scope:recipient } + } + flag = hook + localization = SCHEME_HOOK + } + #My skills could be useful to you...? + send_option = { + is_valid = { + scope:actor = { + skill_support_trigger = yes + } + } + flag = skill_support + localization = SKILL_SUPPORT_INTERACTION_OPTION + } + #I will lead you into the light by my piety + send_option = { + is_valid = { + scope:actor = { + piety_support_trigger = yes + custom_tooltip = { + text = pious_puppet_sf_req_tt + has_fulfillment_parameter = pious_puppet_option + } + } + } + flag = piety_support + localization = PIETY_SUPPORT_INTERACTION_OPTION + } + #Become an instrument of my dreadful will, not a target of my will + send_option = { + is_valid = { + scope:actor = { + dread_support_trigger = yes + custom_tooltip = { + text = dread_puppet_sf_req_tt + has_fulfillment_parameter = dread_puppet_option + } + } + } + flag = dread_support + localization = DREAD_SUPPORT_INTERACTION_OPTION + } + #You can trust in me, relation + send_option = { + is_valid = { + scope:actor = { + friendly_support_trigger = yes + custom_tooltip = { + text = friendly_puppet_sf_req_tt + has_fulfillment_parameter = positive_relation_puppet_option + } + } + } + flag = friendly_support + localization = FRIENDLY_SUPPORT_INTERACTION_OPTION + } + #Your mind, your will, is no more + send_option = { + is_valid = { + scope:actor = { + lunacy_support_trigger = yes + } + } + flag = lunacy_support + localization = LUNACY_SUPPORT_INTERACTION_OPTION + } + should_use_extra_icon = { + scope:actor = { has_usable_hook = scope:recipient } + } + extra_icon = "gfx/interface/icons/character_interactions/hook_icon.dds" + send_options_exclusive = no + + ai_accept = { + base = -75 + + celestial_hierarchy_acceptance_modifier = { + ACTOR = scope:actor + RECIPIENT = scope:recipient + } + + # Head of Faith will not be anyone's puppet + modifier = { + add = -30 + scope:recipient.faith.religious_head = scope:recipient + desc = HEAD_OF_FAITH_REASON + } + + # recipient is militarily weaker than the actor + modifier = { + add = 15 + scope:recipient = { + is_landed = yes + } + scope:recipient.current_military_strength < scope:actor.current_military_strength + desc = PUPPET_RECIPIENT_WEAKER_REASON + } + + # recipient is far weaker (less than half) than the actor + modifier = { + add = 30 + scope:recipient = { + is_landed = yes + } + scope:recipient.current_military_strength < scope:actor.half_current_military_strength + desc = PUPPET_RECIPIENT_MUCH_WEAKER_REASON + } + + # actor is militarily weaker than the recipient + modifier = { + add = -15 + scope:actor.current_military_strength < scope:recipient.current_military_strength + desc = PUPPET_ACTOR_WEAKER_REASON + } + + # actor is far weaker (less than half) than the recipient + modifier = { + add = -30 + scope:actor.current_military_strength < scope:recipient.half_current_military_strength + desc = PUPPET_ACTOR_MUCH_WEAKER_REASON + } + modifier = { + add = -75 + NOR = { + scope:actor = { + government_has_flag = government_is_theocracy + } + exists = scope:actor.puppet:theological_agent_puppet + } + desc = YOU_HAVE_NO_THEOLOGICAL_PUPPET + } + modifier = { + add = 40 + scope:recipient.holy_order.holy_order_patron ?= scope:actor + desc = YOU_ARE_PATRON + } + modifier = { + scope:recipient.holy_order ?= { + any_leased_title = { + holder ?= { + target_is_same_character_or_above = scope:actor + } + } + } + add = { + value = 0 + scope:recipient.holy_order ?= { + every_leased_title = { + limit = { + holder ?= scope:actor + } + add = 15 + } + } + scope:recipient.holy_order ?= { + every_leased_title = { + limit = { + holder ?= { + is_vassal_or_below_of = scope:actor + } + } + add = 5 + } + } + } + desc = YOU_ARE_LEASE_HOLDER + } + modifier = { + add = 25 + scope:recipient = { + has_variable_list = recent_leasers + any_in_list = { + variable = recent_leasers + this = scope:actor + } + } + desc = RECENTLY_LEASED_TO_ORDER + } + modifier = { + add = 25 + scope:recipient = { + has_variable_list = recent_donators + any_in_list = { + variable = recent_donators + this = scope:actor + } + } + desc = RECENTLY_DONATED_TO_ORDER + } + modifier = { + desc = ORDER_SIZE_REASON + scope:recipient.holy_order ?= { + any_leased_title = { + count >= 4 + NOT = { + holder ?= { + target_is_same_character_or_above = scope:actor + } + } + } + } + add = { + #So first 3 don't count + value = 15 + scope:recipient.holy_order ?= { + every_leased_title = { + limit = { + NOT = { + holder ?= { + target_is_same_character_or_above = scope:actor + } + } + } + add = -5 + } + } + } + } + + theocratic_related_puppet_acceptance_factors_modifier = yes + } +} + +make_external_ruler_puppet_interaction = { + category = interaction_category_diplomacy + icon = external_ruler_puppet + common_interaction = yes + interface_priority = 50 + ai_instant_response = yes + + desc = make_external_ruler_puppet_interaction_desc + + is_available = { + is_ai = no + trigger_if = { + limit = { + is_ai = yes + } + NOT = { + exists = puppet:external_ruler_puppet + } + } + NOT = { has_trait = incapable } + is_adult = yes + has_pam_dlc_trigger = yes + } + + cooldown_against_recipient = { years = 10 } + + is_shown = { + scope:actor != scope:recipient + scope:recipient = { + is_landed = yes + is_ruler = yes + NOR = { + has_trait = incapable + is_clergy = yes + } + } + } + + is_valid_showing_failures_only = { + scope:recipient = { + age >= 6 + is_ai = yes + custom_tooltip = { + text = pam_recipient_already_puppet_tt + NOT = { exists = puppeteer } + } + } + scope:actor = { + NOR = { + is_at_war_with = scope:recipient + puppet:external_ruler_puppet ?= scope:recipient + } + custom_tooltip = { + text = pam_already_have_external_ruler_puppet_tt + NOT = { + exists = puppet:external_ruler_puppet + } + } + custom_tooltip = { + text = actor_is_antipope_sponsor_tt + pam_sponsors_other_antipope_trigger = no + } + } + } + + can_send = { + custom_tooltip = { + text = make_external_ruler_puppet_tt + OR = { + scope:actor = { + is_clergy = yes + is_vassal_of = scope:recipient + } + AND = { + scope:actor = { + has_trait = seducer + } + trigger_if = { + limit = { + scope:recipient = { + highest_held_title_tier >= tier_kingdom + } + } + scope:recipient = { + has_relation_soulmate = scope:actor + } + } + trigger_else = { + scope:recipient = { + has_relation_lover = scope:actor + } + } + } + AND = { + scope:actor = { + has_trait = torturer + } + scope:recipient = { + is_imprisoned_by = scope:actor + is_in_prison_type = dungeon + } + } + AND = { + scope:actor = { + has_trait = family_first + } + scope:recipient = { + is_close_family_of = scope:actor + } + } + scope:actor = { + has_trait = schemer + trigger_if = { + limit = { + scope:recipient = { + highest_held_title_tier >= tier_kingdom + } + } + has_strong_hook = scope:recipient + } + trigger_else = { + has_hook = scope:recipient + } + } + scope:actor = { + has_trait = diplomat + is_allied_to = scope:recipient + } + AND = { + scope:actor = { + has_trait = gallant + } + scope:recipient = { + is_spouse_of = scope:actor + } + } + AND = { + scope:actor = { + is_diarch_of_target = scope:recipient + } + scope:recipient = { + has_diarchy_parameter = diarchy_type_is_entrenched_regency + } + } + AND = { + exists = scope:recipient.religious_head_or_challenger + scope:recipient.religious_head_or_challenger = scope:actor + } + AND = { + exists = scope:recipient.rite.head_of_rite + scope:recipient.rite.head_of_rite = scope:actor + } + } + } + scope:actor = { + trigger_if = { + limit = { + scope:recipient = { + highest_held_title_tier >= tier_empire + } + } + custom_tooltip = { + text = pam_empire_dread_or_strong_hook_tt + OR = { + has_strong_hook = scope:recipient + scope:recipient = { + has_dread_level_towards = { + target = scope:actor + level >= 2 + } + } + scope:recipient.religious_head_or_challenger ?= scope:actor + } + } + } + trigger_else_if = { + limit = { + scope:recipient = { + highest_held_title_tier >= tier_kingdom + } + } + custom_tooltip = { + text = piety_level_4_dread_or_strong_hook_tt + OR = { + piety_level >= 4 + has_strong_hook = scope:recipient + scope:recipient = { + has_dread_level_towards = { + target = scope:actor + level >= 2 + } + } + scope:recipient.religious_head_or_challenger ?= scope:actor + } + } + } + trigger_else = { + custom_tooltip = { + text = piety_level_3_dread_or_hook_tt + OR = { + piety_level >= 3 + has_hook = scope:recipient + scope:recipient = { + has_dread_level_towards = { + target = scope:actor + level >= 2 + } + } + scope:recipient.religious_head_or_challenger ?= scope:actor + } + } + } + } + } + + ai_targets = { + ai_recipients = neighboring_rulers + max = 10 + } + ai_targets = { + ai_recipients = peer_vassals + max = 10 + } + ai_targets = { + ai_recipients = rulers_in_clerical_region + max = 10 + } + ai_targets = { + ai_recipients = family + max = 5 + } + ai_targets = { + ai_recipients = liege + ai_recipients = top_liege + ai_recipients = spouses + ai_recipients = prisoners + ai_recipients = scripted_relations + } + ai_target_quick_trigger = { + adult = yes + } + ai_frequency_by_tier = { + barony = 0 + county = 160 + duchy = 36 + kingdom = 24 + empire = 24 + hegemony = 24 + } + + ai_will_do = { + base = 100 + modifier = { + scope:recipient = { + highest_held_title_tier < scope:actor.highest_held_title_tier + } + factor = 0.25 + } + modifier = { + scope:recipient = { + highest_held_title_tier < scope:actor.highest_held_title_tier_minus_one + } + factor = 0 + } + } + + cost = { + prestige = { + value = { + value = minor_prestige_value + multiply = { + value = scope:recipient.highest_held_title_tier + subtract = 1 + } + } + } + } + + on_accept = { + scope:actor = { + trigger_event = pam_interactions_events.0121 + pam_generic_set_puppet_interaction_side_effects = yes + } + scope:recipient = { + custom_tooltip = set_external_ruler_puppet_tt + } + } + + send_option = { + is_valid = { + scope:actor = { has_usable_hook = scope:recipient } + } + flag = hook + localization = SCHEME_HOOK + } + #My skills could be useful to you...? + send_option = { + is_valid = { + scope:actor = { + skill_support_trigger = yes + } + } + flag = skill_support + localization = SKILL_SUPPORT_INTERACTION_OPTION + } + #I will lead you into the light by my piety + send_option = { + is_shown = { + scope:actor = { + pam_is_clergy_ruler_trigger = yes + } + } + is_valid = { + scope:actor = { + piety_support_trigger = yes + } + } + flag = piety_support + localization = PIETY_SUPPORT_INTERACTION_OPTION + } + #Become an instrument of my dreadful will, not a target of my will + send_option = { + is_valid = { + scope:actor = { + trigger_if = { + limit = { pam_is_clergy_ruler_trigger = yes } + dread_support_trigger = yes + } + trigger_else = { + dread_support_secular_trigger = yes + } + } + } + flag = dread_support + localization = DREAD_SUPPORT_INTERACTION_OPTION + } + #You can trust in me, relation + send_option = { + is_valid = { + scope:actor = { + trigger_if = { + limit = { pam_is_clergy_ruler_trigger = yes } + friendly_support_trigger = yes + } + trigger_else = { + friendly_support_secular_trigger = yes + } + } + } + flag = friendly_support + localization = FRIENDLY_SUPPORT_INTERACTION_OPTION + } + #Your mind, your will, is no more + send_option = { + is_valid = { + scope:actor = { + lunacy_support_trigger = yes + } + } + flag = lunacy_support + localization = LUNACY_SUPPORT_INTERACTION_OPTION + } + should_use_extra_icon = { + scope:actor = { has_usable_hook = scope:recipient } + } + extra_icon = "gfx/interface/icons/character_interactions/hook_icon.dds" + send_options_exclusive = no + + ai_accept = { + base = -50 + + celestial_hierarchy_acceptance_modifier = { + ACTOR = scope:actor + RECIPIENT = scope:recipient + } + celestial_hierarchy_external_ruler_puppet_acceptance_modifier = { + ACTOR = scope:actor + RECIPIENT = scope:recipient + } + + # Rank gap: an actor outranked by the recipient has little leverage + modifier = { + scope:actor = { + tier_difference = { + target = scope:recipient + value <= -1 + } + } + add = { + value = -60 + if = { + limit = { + scope:actor = { + tier_difference = { + target = scope:recipient + value = -2 + } + } + } + add = -60 + } + if = { + limit = { + scope:actor = { + tier_difference = { + target = scope:recipient + value = -3 + } + } + } + add = -120 + } + if = { + limit = { + scope:actor = { + tier_difference = { + target = scope:recipient + value <= -4 + } + } + } + add = -180 + } + } + desc = RANK_DIFFERENCE_REASON + } + + # Head of Faith will not be anyone's puppet + modifier = { + add = -30 + scope:recipient.faith.religious_head = scope:recipient + desc = HEAD_OF_FAITH_REASON + } + + # Different faith + modifier = { + add = { + value = -50 + if = { + limit = { + scope:recipient.faith = { + faith_hostility_level = { + target = scope:actor.faith + value >= faith_hostile_level + } + } + } + add = -50 + } + if = { + limit = { + scope:recipient.faith = { + faith_hostility_level = { + target = scope:actor.faith + value >= faith_evil_level + } + } + } + add = -50 + } + } + scope:recipient = { + NOT = { faith = scope:actor.faith } + } + desc = PUPPET_DIFFERENT_FAITH_REASON + } + + # recipient is militarily weaker than the actor + modifier = { + add = 15 + scope:recipient = { + is_landed = yes + } + scope:recipient.current_military_strength < scope:actor.current_military_strength + desc = PUPPET_RECIPIENT_WEAKER_REASON + } + + # recipient is far weaker (less than half) than the actor + modifier = { + add = 30 + scope:recipient = { + is_landed = yes + } + scope:recipient.current_military_strength < scope:actor.half_current_military_strength + desc = PUPPET_RECIPIENT_MUCH_WEAKER_REASON + } + + # actor is militarily weaker than the recipient + modifier = { + add = -15 + scope:actor.current_military_strength < scope:recipient.current_military_strength + desc = PUPPET_ACTOR_WEAKER_REASON + } + + # actor is far weaker (less than half) than the recipient + modifier = { + add = -30 + scope:actor.current_military_strength < scope:recipient.half_current_military_strength + desc = PUPPET_ACTOR_MUCH_WEAKER_REASON + } + + modifier = { + add = 50 + scope:actor = { + is_clergy = yes + } + has_trait = zealous + desc = ASK_FOR_CONVERSION_RECIPIENT_IS_ZEALOUS + } + + theocratic_related_puppet_acceptance_factors_modifier = yes + } +} + + +fire_puppet_interaction = { + category = interaction_category_diplomacy + icon = fire_puppet_interaction + interface_priority = 51 + + desc = fire_puppet_interaction_desc + + is_available = { + is_ai = no + is_adult = yes + } + + is_shown = { + scope:actor != scope:recipient + scope:recipient.puppeteer ?= scope:actor + } + + is_valid_showing_failures_only = { + scope:actor = { is_incapable = no } + } + + auto_accept = yes + + on_accept = { + scope:actor = { + send_interface_toast = { + type = event_toast_effect_neutral + title = fire_puppet_interaction_notification + left_icon = scope:actor + right_icon = scope:recipient + custom_tooltip = fire_puppet_interaction_effect_tt + hidden_effect = { + scope:recipient = { + clear_puppet_status = yes + remove_puppet_modifiers_effect = yes + } + } + scope:recipient = { + add_opinion = { + target = scope:actor + modifier = set_me_aside_opinion + opinion = -10 + } + } + } + } + } + + ai_targets = { + ai_recipients = puppets + } + ai_frequency = 0 +} diff --git a/common/character_interactions/00_religious_interactions.txt b/common/character_interactions/00_religious_interactions.txt index 1b1d3ccca..53cbf125c 100644 --- a/common/character_interactions/00_religious_interactions.txt +++ b/common/character_interactions/00_religious_interactions.txt @@ -10,7 +10,7 @@ ask_for_conversion_interaction = { is_shown = { scope:actor.faith != scope:recipient.faith - scope:recipient.liege = scope:actor + scope:recipient.liege ?= scope:actor NOT = { scope:recipient = { government_has_flag = government_is_landless_minority } } NOT = { scope:recipient = { culture = { has_cultural_parameter = cannot_convert_diasporia } } } } @@ -21,7 +21,14 @@ ask_for_conversion_interaction = { ai_accept = { base = 0 + + celestial_hierarchy_acceptance_modifier = { + ACTOR = scope:actor + RECIPIENT = scope:recipient + } + religion_demand_conversion_default_modifier = yes + religion_demand_conversion_christian_situation_modifier = yes # We add a few extra modifiers if you have a state faith, to make the initial conversion rate more immersive and plausible modifier = { @@ -80,9 +87,14 @@ ask_for_conversion_interaction = { government_allows = state_faith has_perk = prophet_perk } - add = { value = scope:actor.learning add = scope:actor.diplomacy multiply = 0.5 } + add = { + value = scope:actor.learning + add = scope:actor.diplomacy + multiply = 0.5 + } desc = HAS_PERK_PROPHET_REASON } + } ai_min_reply_days = 1 @@ -97,6 +109,7 @@ ask_for_conversion_interaction = { # If character is converting to the state faith, we add influence state_faith_conversion_add_piety_effect = yes + # Piety gain from Struggle Phase # scope:actor = { # if = { # limit = { @@ -111,6 +124,11 @@ ask_for_conversion_interaction = { # add_piety = medium_piety_gain # } # } + + conversion_tenet_acts_of_the_apostles_effect = yes + + # If you have the Mendicant Preaching personal tenet we give you SP + conversion_tenet_mendicant_preachers_effect = yes } on_decline = { @@ -180,6 +198,13 @@ ask_for_conversion_courtier_interaction = { hegemony = 12 } + is_available = { + trigger_if = { + limit = { is_ai = yes } + is_adult = yes + } + } + is_shown = { scope:actor.faith != scope:recipient.faith scope:recipient = { is_courtier_of = scope:actor } @@ -196,12 +221,19 @@ ask_for_conversion_courtier_interaction = { ai_accept = { base = 0 + + celestial_hierarchy_acceptance_modifier = { + ACTOR = scope:actor + RECIPIENT = scope:recipient + } + # Increase base chance modifier = { add = 50 desc = EDUCATE_CHILD_ACTOR_IS_MY_LIEGE } religion_demand_conversion_default_modifier = yes + religion_demand_conversion_christian_situation_modifier = yes } auto_accept = { @@ -243,20 +275,6 @@ ask_for_conversion_courtier_interaction = { } } scope:recipient = { - # trigger_event = char_interaction.0180 - trigger_event = false_conversion.0900 - save_scope_value_as = { - name = forcibly_converted - value = yes - } - } - } - if = { - limit = { scope:recipient = { is_imprisoned_by = scope:actor } } - scope:recipient = { release_from_prison = yes } - scope:recipient = { - # trigger_event = char_interaction.0180 - trigger_event = false_conversion.0900 save_scope_value_as = { name = forcibly_converted value = yes @@ -284,6 +302,11 @@ ask_for_conversion_courtier_interaction = { # add_piety = medium_piety_gain # } # } + + conversion_tenet_acts_of_the_apostles_effect = yes + + # If you have the Mendicant Preaching personal tenet we give you SP + conversion_tenet_mendicant_preachers_effect = yes } on_decline = { @@ -378,10 +401,6 @@ ask_for_conversion_courtier_interaction = { send_options_exclusive = no - ai_potential = { - is_adult = yes - } - ai_will_do = { base = 100 @@ -394,7 +413,7 @@ ask_for_conversion_courtier_interaction = { scope:recipient = { faith.religion = religion:judaism_religion culture = { - has_cultural_parameter = cannot_convert_diasporia + has_cultural_tradition = tradition_diasporic } } factor = 0 @@ -404,10 +423,9 @@ ask_for_conversion_courtier_interaction = { factor = 0 scope:actor = { ai_zeal < 100 - ai_rationality > -50 - faith = { - faith_hostility_level = { - target = scope:recipient.faith + rite = { + rite_hostility_level = { + target = scope:recipient.rite value <= faith_fully_accepted_level } } @@ -419,9 +437,9 @@ ask_for_conversion_courtier_interaction = { scope:actor = { has_tolerant_faith_or_culture_trigger = yes ai_zeal < 100 - faith = { - faith_hostility_level = { - target = scope:recipient.faith + rite = { + rite_hostility_level = { + target = scope:recipient.rite value <= faith_astray_level } } @@ -436,11 +454,11 @@ ask_for_conversion_courtier_interaction = { modifier = { # Astray faiths require specific circumstances to demand conversion of factor = 0 scope:actor = { - faith = { has_doctrine = doctrine_pluralism_fundamentalist } + rite = { rite_has_doctrine = doctrine_pluralism_fundamentalist } ai_zeal < -10 - faith = { - faith_hostility_level = { - target = scope:recipient.faith + rite = { + rite_hostility_level = { + target = scope:recipient.rite value <= faith_astray_level } } @@ -456,13 +474,13 @@ ask_for_conversion_courtier_interaction = { factor = 0 scope:actor = { NOR = { - faith = { has_doctrine = doctrine_pluralism_fundamentalist } + rite = { rite_has_doctrine = doctrine_pluralism_fundamentalist } has_tolerant_faith_or_culture_trigger = yes } ai_zeal < 25 - faith = { - faith_hostility_level = { - target = scope:recipient.faith + rite = { + rite_hostility_level = { + target = scope:recipient.rite value <= faith_astray_level } } @@ -474,13 +492,13 @@ ask_for_conversion_courtier_interaction = { } } - modifier = { # Rulers with State Faith won't try to convert people with faiths that are astray or better + modifier = { # Rulers with State Faith won't try to convert people with rites that are astray or better factor = 0 scope:actor = { government_allows = state_faith - primary_title.state_faith ?= { - faith_hostility_level = { - target = scope:recipient.faith + primary_title.state_rite ?= { + rite_hostility_level = { + target = scope:recipient.rite value <= faith_astray_level } } @@ -501,15 +519,15 @@ demand_conversion_interaction = { notification_text = HOUSE_HEAD_DEMAND_CONVERSION is_shown = { - scope:recipient != scope:actor - scope:actor = { + scope:puppet_or_actor ?= { + this != scope:recipient is_house_head = yes faith != scope:recipient.faith OR = { - house = scope:recipient.house + house ?= scope:recipient.house AND = { # House Bloc house.house_confederation ?= { - scope:recipient.house.house_confederation ?= this + scope:recipient.house.house_confederation ?= this has_cohesion_level_parameter = bloc_members_join_leaders_faith } } @@ -518,7 +536,7 @@ demand_conversion_interaction = { NOT = { scope:recipient = { # Use the vassal-liege interaction instead. is_ruler = yes - target_is_liege_or_above = scope:actor + target_is_liege_or_above = scope:puppet_or_actor } } scope:recipient = { # To avoid you converting someone's entire family, and then asking them. Restricting it to landed rulers at least gives them a chance to create their own cadet house. @@ -535,13 +553,13 @@ demand_conversion_interaction = { desc = demand_conversion_interaction_desc triggered_desc = { trigger = { - scope:actor = { + scope:puppet_or_actor = { refusing_conversion_is_crime_trigger = { CHARACTER = scope:recipient } } scope:recipient = { - target_is_liege_or_above = scope:actor + target_is_liege_or_above = scope:puppet_or_actor } } desc = demand_conversion_vassal_ruler_is_crime @@ -550,54 +568,58 @@ demand_conversion_interaction = { is_valid_showing_failures_only = { valid_demand_conversion_conditions_trigger = yes + trigger_if = { + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + influence >= demand_conversion_influence_cost_value + } + } } cost = { influence = { - value = 0 + value = demand_conversion_influence_cost_value if = { - limit = { scope:influence_send_option = yes } - add = scope:actor.medium_influence_value - desc = INFLUENCE_INTERACTION_ACCEPTANCE_SEND_OPTION + limit = { scope:is_puppet_action ?= yes } + multiply = 0 } } } on_accept = { + if = { + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + if = { + limit = { demand_conversion_influence_cost_value > 0 } + change_influence = { + value = { + value = demand_conversion_influence_cost_value + max = influence + multiply = -1 + } + } + } + } + } demand_conversion_interaction_effect = yes if = { limit = { scope:hook = yes } - scope:actor = { + scope:puppet_or_actor = { use_hook = scope:recipient } scope:recipient = { - # trigger_event = char_interaction.0180 - trigger_event = false_conversion.0900 save_scope_value_as = { name = forcibly_converted value = yes } } } - if = { - limit = { scope:recipient = { is_imprisoned_by = scope:actor } } - scope:recipient = { release_from_prison = yes } - scope:recipient = { - # trigger_event = char_interaction.0180 - trigger_event = false_conversion.0900 - save_scope_value_as = { - name = forcibly_converted - value = yes - } - } - } - else = { - scope:actor = { - trigger_event = char_interaction.0181 - } + scope:puppet_or_actor = { + trigger_event = char_interaction.0181 } -# scope:actor = { +# scope:puppet_or_actor = { # if = { # limit = { # any_character_struggle = { @@ -617,6 +639,11 @@ demand_conversion_interaction = { # If character is converting to the state faith, we add influence state_faith_conversion_add_piety_effect = yes + + conversion_tenet_acts_of_the_apostles_effect = yes + + # If you have the Mendicant Preaching personal tenet we give you SP + conversion_tenet_mendicant_preachers_effect = yes } on_decline = { @@ -628,17 +655,17 @@ demand_conversion_interaction = { scope:recipient = { if = { limit = { - scope:actor = { + scope:puppet_or_actor = { refusing_conversion_is_crime_trigger = { CHARACTER = scope:recipient } } scope:recipient = { - target_is_liege_or_above = scope:actor + target_is_liege_or_above = scope:puppet_or_actor } } - add_opinion = { - target = scope:recipient + reverse_add_opinion = { + target = scope:puppet_or_actor modifier = illegal_resisted_conversion_opinion years = 10 } @@ -646,12 +673,12 @@ demand_conversion_interaction = { else = { add_opinion = { modifier = demanded_my_conversion_opinion - target = scope:actor + target = scope:puppet_or_actor opinion = -10 } } } - scope:actor = { + scope:puppet_or_actor = { trigger_event = char_interaction.0182 } @@ -664,10 +691,10 @@ demand_conversion_interaction = { auto_accept = { custom_description = { text = "spending_hook" - subject = scope:actor + subject = scope:puppet_or_actor object = scope:recipient scope:hook = yes - scope:actor = { has_strong_hook = scope:recipient } + scope:puppet_or_actor = { has_strong_hook = scope:recipient } } } @@ -683,6 +710,12 @@ demand_conversion_interaction = { ai_accept = { base = 0 + + celestial_hierarchy_acceptance_modifier = { + ACTOR = scope:puppet_or_actor + RECIPIENT = scope:recipient + } + # Increase base chance modifier = { add = 50 @@ -705,6 +738,7 @@ demand_conversion_interaction = { desc = ASK_FOR_CONVERSION_CAN_CREATE_CADET_BRANCH } religion_demand_conversion_default_modifier = yes + religion_demand_conversion_christian_situation_modifier = yes } can_send_despite_rejection = yes @@ -713,34 +747,34 @@ demand_conversion_interaction = { #Use hook send_option = { is_valid = { - scope:actor = { + scope:puppet_or_actor = { has_usable_hook = scope:recipient } NOT = { - scope:recipient = { is_imprisoned_by = scope:actor } + scope:recipient = { is_imprisoned_by = scope:puppet_or_actor } } } flag = hook localization = SCHEME_HOOK } should_use_extra_icon = { - scope:actor = { has_usable_hook = scope:recipient } + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } extra_icon = "gfx/interface/icons/character_interactions/hook_icon.dds" send_option = { # EP3 Influence is_shown = { # Actor must have a government that uses influence - scope:actor = { + scope:puppet_or_actor ?= { government_has_flag = government_has_influence } } is_valid = { # Actor has enough influence - scope:actor = { influence >= medium_influence_value } + scope:puppet_or_actor = { influence >= medium_influence_value } # Both characters are within the same top realm custom_tooltip = { text = not_same_realm_tt - scope:recipient.top_liege = scope:actor.top_liege + scope:recipient.top_liege = scope:puppet_or_actor.top_liege } } flag = influence_send_option @@ -781,13 +815,13 @@ demand_conversion_vassal_ruler_interaction = { desc = line_break triggered_desc = { trigger = { - NOT = { scope:recipient = { is_imprisoned_by = scope:actor } } + NOT = { scope:recipient = { is_imprisoned_by = scope:puppet_or_actor } } } desc = might_ask_for_something_in_return_warning } triggered_desc = { trigger = { - scope:actor = { + scope:puppet_or_actor = { refusing_conversion_is_crime_trigger = { CHARACTER = scope:recipient } @@ -799,13 +833,22 @@ demand_conversion_vassal_ruler_interaction = { on_decline_summary = stop_attacker_vassal_war_decline_summary + is_available = { + trigger_if = { + limit = { is_ai = yes } + is_adult = yes + } + } + is_shown = { + scope:puppet_or_actor ?= { + NOT = { faith = scope:recipient.faith } + } scope:recipient = { OR = { - target_is_liege_or_above = scope:actor - is_tributary_of = scope:actor + target_is_liege_or_above = scope:puppet_or_actor + is_tributary_of = scope:puppet_or_actor } - faith != scope:actor.faith is_ai = yes is_ruler = yes } @@ -817,29 +860,25 @@ demand_conversion_vassal_ruler_interaction = { is_valid_showing_failures_only = { valid_demand_conversion_conditions_trigger = yes + trigger_if = { + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + influence >= demand_conversion_influence_cost_value + } + } trigger_if = { limit = { - scope:actor.domicile ?= { + scope:puppet_or_actor.domicile ?= { domicile_uses_culture_and_faith = yes } scope:recipient = { is_ruler = yes - OR = { - government_has_flag = government_is_nomadic - government_has_flag = government_is_true_herder - } + government_has_flag = government_is_in_steppe } } custom_tooltip = { text = nomads_must_inspire_tt - NOT = { - scope:recipient = { - OR = { - government_has_flag = government_is_nomadic - government_has_flag = government_is_true_herder - } - } - } + always = no } } } @@ -847,30 +886,45 @@ demand_conversion_vassal_ruler_interaction = { auto_accept = { custom_description = { text = "spending_hook" - subject = scope:actor + subject = scope:puppet_or_actor object = scope:recipient scope:hook = yes - scope:actor = { has_strong_hook = scope:recipient } + scope:puppet_or_actor = { has_strong_hook = scope:recipient } NOT = { scope:recipient = { has_character_flag = ai_will_not_convert } } } } on_send = { + pam_tax_nonbelievers_conversion_concession_effect = yes } cost = { influence = { - value = 0 + value = demand_conversion_influence_cost_value if = { - limit = { scope:influence_send_option = yes } - add = scope:actor.medium_influence_value - desc = INFLUENCE_INTERACTION_ACCEPTANCE_SEND_OPTION + limit = { scope:is_puppet_action ?= yes } + multiply = 0 } } } on_accept = { - scope:actor = { + if = { + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + if = { + limit = { demand_conversion_influence_cost_value > 0 } + change_influence = { + value = { + value = demand_conversion_influence_cost_value + max = influence + multiply = -1 + } + } + } + } + } + scope:puppet_or_actor = { trigger_event = religious_interaction.2002 } demand_conversion_vassal_ruler_interaction_effect = yes @@ -880,8 +934,8 @@ demand_conversion_vassal_ruler_interaction = { # If character is converting to the state faith, we add influence state_faith_conversion_add_piety_effect = yes -# -# scope:actor = { + +# scope:puppet_or_actor = { # if = { # limit = { # any_character_struggle = { @@ -895,6 +949,11 @@ demand_conversion_vassal_ruler_interaction = { # add_piety = medium_piety_gain # } # } + + conversion_tenet_acts_of_the_apostles_effect = yes + + # If you have the Mendicant Preaching personal tenet we give you SP + conversion_tenet_mendicant_preachers_effect = yes } on_decline = { @@ -912,7 +971,7 @@ demand_conversion_vassal_ruler_interaction = { ai_greed = 0.5 } random_list = { - 50 = { #They ask for gold + 10 = { #They ask for gold modifier = { add = 50 # More likely to ask for gold if they're poor scope:recipient.short_term_gold < medium_gold_value @@ -931,16 +990,16 @@ demand_conversion_vassal_ruler_interaction = { is_war_leader = scope:recipient } } - scope:actor = { + scope:puppet_or_actor = { trigger_event = { id = religious_interaction.2011 } } } - 500 = { #They ask for a favor + 50 = { #They ask for a favor trigger = { exists = scope:recipient.capital_county - NOT = { has_hook = scope:actor } + NOT = { has_hook = scope:puppet_or_actor } } # Direct feudal vassals appreciate favors more (they can improve their contract). modifier = { @@ -948,19 +1007,66 @@ demand_conversion_vassal_ruler_interaction = { value = 50 # This goes double for your Powerful Vassals. A better contract is likely to be much more important than a short-term payout. if = { - limit = { is_powerful_vassal_of = scope:actor } + limit = { is_powerful_vassal_of = scope:puppet_or_actor } add = 100 } } - this.liege = scope:actor + this.liege = scope:puppet_or_actor government_has_flag = government_is_feudal } - scope:actor = { + scope:puppet_or_actor = { trigger_event = { id = religious_interaction.2012 } } } + 40 = { # They ask to study the faith first + trigger = { + # Must not already know the faith well + knows_rite_level = { + target = scope:puppet_or_actor.rite + value < 0.9 + } + can_start_scheme = { + type = study_faith + target_character = scope:puppet_or_actor + } + } + # Higher weight if they would suffer severe penalties + modifier = { + add = 300 + knows_rite_level = { + target = scope:puppet_or_actor.rite + value < 0.7 + } + } + # Scholarly/theologian types prefer this + modifier = { + add = 10 + has_trait = erudite + } + modifier = { + add = 10 + has_trait = theologian + } + modifier = { + add = 10 + OR = { + has_trait = education_learning_3 + has_trait = education_learning_4 + has_trait = education_learning_5 + } + } + modifier = { + add = 10 + learning >= 12 + } + scope:puppet_or_actor = { + trigger_event = { + id = religious_interaction.2015 + } + } + } } } @@ -977,7 +1083,7 @@ demand_conversion_vassal_ruler_interaction = { add = 50 scope:recipient.demand_conversion_likelihood_calculation < 0 } - scope:actor = { + scope:puppet_or_actor = { trigger_event = { id = religious_interaction.2003 } @@ -990,10 +1096,10 @@ demand_conversion_vassal_ruler_interaction = { #Negative opinions add_opinion = { modifier = demanded_my_conversion_opinion - target = scope:actor + target = scope:puppet_or_actor opinion = -10 } - scope:actor = { + scope:puppet_or_actor = { if = { limit = { refusing_conversion_is_crime_trigger = { @@ -1012,46 +1118,68 @@ demand_conversion_vassal_ruler_interaction = { refuse_faith_conversion_add_clan_unity_effect = yes } - ai_potential = { - is_adult = yes - } - # Use hook send_option = { is_valid = { - scope:actor = { + scope:puppet_or_actor = { has_usable_hook = scope:recipient } NOT = { - scope:recipient = { is_imprisoned_by = scope:actor } + scope:recipient = { is_imprisoned_by = scope:puppet_or_actor } } } flag = hook localization = SCHEME_HOOK } should_use_extra_icon = { - scope:actor = { has_usable_hook = scope:recipient } + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } extra_icon = "gfx/interface/icons/character_interactions/hook_icon.dds" send_option = { # EP3 Influence is_shown = { # Actor must have a government that uses influence - scope:actor = { + scope:puppet_or_actor ?= { government_has_flag = government_has_influence } } is_valid = { # Actor has enough influence - scope:actor = { influence >= medium_influence_value } + scope:puppet_or_actor = { influence >= medium_influence_value } # Both characters are within the same top realm custom_tooltip = { text = not_same_realm_tt - scope:recipient.top_liege = scope:actor.top_liege + scope:recipient.top_liege = scope:puppet_or_actor.top_liege } } flag = influence_send_option localization = TRADE_INFLUENCE_FOR_BETTER_AI_ACCEPTANCE } + + send_option = { + is_shown = { + scope:puppet_or_actor = { + has_personal_tenet_flag = tax_nonbelievers_conversion_concession + } + scope:recipient = { + is_vassal_of = scope:puppet_or_actor + } + } + is_valid = { + scope:puppet_or_actor = { + gold >= medium_gold_value + } + } + starts_enabled = { + scope:puppet_or_actor = { + scope:actor = { is_ai = yes } + short_term_gold >= medium_gold_value + } + scope:recipient.demand_conversion_likelihood_calculation < 70 + } + flag = tax_nonbelievers_conversion_concession + localization = pam_tax_nonbelievers_conversion_concession_option + current_description = pam_tax_nonbelievers_conversion_concession_option_desc + } send_options_exclusive = no ai_will_do = { @@ -1061,12 +1189,17 @@ demand_conversion_vassal_ruler_interaction = { scope:hook = yes add = 1 } + modifier = { + scope:tax_nonbelievers_conversion_concession = yes + scope:recipient.demand_conversion_likelihood_calculation < 70 + add = 1 + } modifier = { factor = 0 scope:recipient.demand_conversion_likelihood_calculation < 10 NOT = { - scope:actor = { + scope:puppet_or_actor = { refusing_conversion_is_crime_trigger = { CHARACTER = scope:recipient } @@ -1077,7 +1210,7 @@ demand_conversion_vassal_ruler_interaction = { modifier = { factor = 0 scope:recipient.demand_conversion_likelihood_calculation < 70 - scope:actor = { + scope:puppet_or_actor = { gold < demand_conversion_bribe_size } } @@ -1085,7 +1218,7 @@ demand_conversion_vassal_ruler_interaction = { modifier = { factor = 0 scope:recipient.demand_conversion_likelihood_calculation < 90 - scope:actor = { + scope:puppet_or_actor = { culture = { has_cultural_parameter = less_likely_to_force_conversion } @@ -1094,22 +1227,24 @@ demand_conversion_vassal_ruler_interaction = { modifier = { # Do not convert Righteous faith subjects, unless disturbingly zealous factor = 0 - scope:actor = { + scope:puppet_or_actor = { ai_zeal < 100 - ai_rationality > -50 - faith = { - faith_hostility_level = { - target = scope:recipient.faith + rite = { + rite_hostility_level = { + target = scope:recipient.rite value <= faith_fully_accepted_level } } } NOT = { # If the subject has one of your holy sites, always try to convert - scope:recipient = { - any_sub_realm_county = { - any_county_province = { - barony = { - is_holy_site_of = scope:actor.faith + scope:puppet_or_actor.faith = { + any_holy_site = { + holy_site_county ?= { + holder ?= { + OR = { + this = scope:recipient + is_vassal_or_below_of = scope:recipient + } } } } @@ -1119,22 +1254,25 @@ demand_conversion_vassal_ruler_interaction = { modifier = { # Astray faiths require specific circumstances to demand conversion of factor = 0 - scope:actor = { + scope:puppet_or_actor = { has_tolerant_faith_or_culture_trigger = yes ai_zeal < 100 - faith = { - faith_hostility_level = { - target = scope:recipient.faith + rite = { + rite_hostility_level = { + target = scope:recipient.rite value <= faith_astray_level } } } NOT = { # If the subject has one of your holy sites, always try to convert - scope:recipient = { - any_sub_realm_county = { - any_county_province = { - barony = { - is_holy_site_of = scope:actor.faith + scope:puppet_or_actor.faith = { + any_holy_site = { + holy_site_county ?= { + holder ?= { + OR = { + this = scope:recipient + is_vassal_or_below_of = scope:recipient + } } } } @@ -1142,29 +1280,32 @@ demand_conversion_vassal_ruler_interaction = { } NOT = { scope:recipient = { - is_close_family_of = scope:actor + is_close_family_of = scope:puppet_or_actor } } } modifier = { # Astray faiths require specific circumstances to demand conversion of factor = 0 - scope:actor = { - faith = { has_doctrine = doctrine_pluralism_fundamentalist } + scope:puppet_or_actor = { + rite = { rite_has_doctrine = doctrine_pluralism_fundamentalist } ai_zeal < -10 - faith = { - faith_hostility_level = { - target = scope:recipient.faith + rite = { + rite_hostility_level = { + target = scope:recipient.rite value <= faith_astray_level } } } NOT = { # If the subject has one of your holy sites, always try to convert - scope:recipient = { - any_sub_realm_county = { - any_county_province = { - barony = { - is_holy_site_of = scope:actor.faith + scope:puppet_or_actor.faith = { + any_holy_site = { + holy_site_county ?= { + holder ?= { + OR = { + this = scope:recipient + is_vassal_or_below_of = scope:recipient + } } } } @@ -1172,32 +1313,35 @@ demand_conversion_vassal_ruler_interaction = { } NOT = { scope:recipient = { - is_close_family_of = scope:actor + is_close_family_of = scope:puppet_or_actor } } } modifier = { # Astray faiths require specific circumstances to demand conversion of factor = 0 - scope:actor = { + scope:puppet_or_actor = { NOR = { - faith = { has_doctrine = doctrine_pluralism_fundamentalist } + rite = { rite_has_doctrine = doctrine_pluralism_fundamentalist } has_tolerant_faith_or_culture_trigger = yes } ai_zeal < 25 - faith = { - faith_hostility_level = { - target = scope:recipient.faith + rite = { + rite_hostility_level = { + target = scope:recipient.rite value <= faith_astray_level } } } NOT = { # If the subject has one of your holy sites, always try to convert - scope:recipient = { - any_sub_realm_county = { - any_county_province = { - barony = { - is_holy_site_of = scope:actor.faith + scope:puppet_or_actor.faith = { + any_holy_site = { + holy_site_county ?= { + holder ?= { + OR = { + this = scope:recipient + is_vassal_or_below_of = scope:recipient + } } } } @@ -1205,13 +1349,13 @@ demand_conversion_vassal_ruler_interaction = { } } - modifier = { # Rulers with state faith won't try to convert people with faiths that are astray or better + modifier = { # Rulers with state faith won't try to convert people with rites that are astray or better factor = 0 - scope:actor = { + scope:puppet_or_actor = { government_allows = state_faith - primary_title.state_faith ?= { - faith_hostility_level = { - target = scope:recipient.faith + primary_title.state_rite ?= { + rite_hostility_level = { + target = scope:recipient.rite value <= faith_astray_level } } @@ -1220,17 +1364,29 @@ demand_conversion_vassal_ruler_interaction = { } ai_accept = { base = 0 + + celestial_hierarchy_acceptance_modifier = { + ACTOR = scope:puppet_or_actor + RECIPIENT = scope:recipient + } + # Increase base chance modifier = { add = 50 desc = EDUCATE_CHILD_ACTOR_IS_MY_LIEGE } religion_demand_conversion_default_modifier = yes + religion_demand_conversion_christian_situation_modifier = yes modifier = { desc = might_ask_for_something_in_return_warning_line_break add = 0 } + modifier = { + add = 25 + scope:tax_nonbelievers_conversion_concession = yes + desc = pam_tax_nonbelievers_conversion_acceptance_reason + } } } @@ -1257,11 +1413,20 @@ demand_conversion_player_ruler_interaction = { hegemony = 120 } + is_available = { + trigger_if = { + limit = { is_ai = yes } + is_adult = yes + } + } + is_shown = { + scope:puppet_or_actor ?= { + NOT = { faith = scope:recipient.faith } + } scope:recipient = { is_ai = no - target_is_liege_or_above = scope:actor - faith != scope:actor.faith + target_is_liege_or_above = scope:puppet_or_actor } NOT = { scope:recipient = { government_has_flag = government_is_landless_minority } } NOT = { scope:recipient = { culture = { has_cultural_parameter = cannot_convert_diasporia } } } @@ -1275,7 +1440,7 @@ demand_conversion_player_ruler_interaction = { send_option = { is_valid = { - scope:actor = { + scope:puppet_or_actor = { has_strong_usable_hook = scope:recipient } } @@ -1283,7 +1448,7 @@ demand_conversion_player_ruler_interaction = { localization = GENERIC_SPEND_A_HOOK } should_use_extra_icon = { - scope:actor = { has_strong_usable_hook = scope:recipient } + scope:puppet_or_actor = { has_strong_usable_hook = scope:recipient } } extra_icon = "gfx/interface/icons/character_interactions/hook_icon.dds" @@ -1293,19 +1458,14 @@ demand_conversion_player_ruler_interaction = { auto_accept = { custom_description = { text = "spending_hook" - subject = scope:actor + subject = scope:puppet_or_actor object = scope:recipient scope:demand_conversion_hook = yes } } + # Runs in addition to on_accept when auto-accepted, so no conversion effects here on_auto_accept = { - demand_conversion_player_ruler_interaction_effect = yes - - scope:actor = { - trigger_event = char_interaction.0190 - } - scope:recipient = { save_scope_value_as = { name = forcibly_converted @@ -1318,7 +1478,7 @@ demand_conversion_player_ruler_interaction = { on_accept = { # Do conversion demand_conversion_player_ruler_interaction_effect = yes - scope:actor = { + scope:puppet_or_actor = { trigger_event = char_interaction.0190 } @@ -1328,7 +1488,7 @@ demand_conversion_player_ruler_interaction = { # If character is converting to the state faith, we add influence state_faith_conversion_add_piety_effect = yes -# scope:actor = { +# scope:puppet_or_actor = { # if = { # limit = { # any_character_struggle = { @@ -1342,10 +1502,15 @@ demand_conversion_player_ruler_interaction = { # add_piety = medium_piety_gain # } # } + + conversion_tenet_acts_of_the_apostles_effect = yes + + # If you have the Mendicant Preaching personal tenet we give you SP + conversion_tenet_mendicant_preachers_effect = yes } on_decline = { - scope:actor = { + scope:puppet_or_actor = { #Crime if relevant if = { limit = { @@ -1375,10 +1540,6 @@ demand_conversion_player_ruler_interaction = { state_faith_refuse_conversion_add_piety_effect = yes } - ai_potential = { - is_adult = yes - } - ai_will_do = { base = 100 @@ -1388,28 +1549,31 @@ demand_conversion_player_ruler_interaction = { } modifier = { + # Deliberately no crime exemption here, unlike the vassal variant: don't hound zealous players factor = 0 scope:recipient.demand_conversion_likelihood_calculation < 10 } modifier = { # Do not convert Righteous faith subjects, unless disturbingly zealous factor = 0 - scope:actor = { + scope:puppet_or_actor = { ai_zeal < 100 - ai_rationality > -50 - faith = { - faith_hostility_level = { - target = scope:recipient.faith + rite = { + rite_hostility_level = { + target = scope:recipient.rite value <= faith_fully_accepted_level } } } NOT = { # If the subject has one of your holy sites, always try to convert - scope:recipient = { - any_sub_realm_county = { - any_county_province = { - barony = { - is_holy_site_of = scope:actor.faith + scope:puppet_or_actor.faith = { + any_holy_site = { + holy_site_county ?= { + holder ?= { + OR = { + this = scope:recipient + is_vassal_or_below_of = scope:recipient + } } } } @@ -1419,22 +1583,25 @@ demand_conversion_player_ruler_interaction = { modifier = { # Astray faiths require specific circumstances to demand conversion of factor = 0 - scope:actor = { + scope:puppet_or_actor = { has_tolerant_faith_or_culture_trigger = yes ai_zeal < 100 - faith = { - faith_hostility_level = { - target = scope:recipient.faith + rite = { + rite_hostility_level = { + target = scope:recipient.rite value <= faith_astray_level } } } NOT = { # If the subject has one of your holy sites, always try to convert - scope:recipient = { - any_sub_realm_county = { - any_county_province = { - barony = { - is_holy_site_of = scope:actor.faith + scope:puppet_or_actor.faith = { + any_holy_site = { + holy_site_county ?= { + holder ?= { + OR = { + this = scope:recipient + is_vassal_or_below_of = scope:recipient + } } } } @@ -1442,29 +1609,32 @@ demand_conversion_player_ruler_interaction = { } NOT = { scope:recipient = { - is_close_family_of = scope:actor + is_close_family_of = scope:puppet_or_actor } } } modifier = { # Astray faiths require specific circumstances to demand conversion of factor = 0 - scope:actor = { - faith = { has_doctrine = doctrine_pluralism_fundamentalist } + scope:puppet_or_actor = { + rite = { rite_has_doctrine = doctrine_pluralism_fundamentalist } ai_zeal < -10 - faith = { - faith_hostility_level = { - target = scope:recipient.faith + rite = { + rite_hostility_level = { + target = scope:recipient.rite value <= faith_astray_level } } } NOT = { # If the subject has one of your holy sites, always try to convert - scope:recipient = { - any_sub_realm_county = { - any_county_province = { - barony = { - is_holy_site_of = scope:actor.faith + scope:puppet_or_actor.faith = { + any_holy_site = { + holy_site_county ?= { + holder ?= { + OR = { + this = scope:recipient + is_vassal_or_below_of = scope:recipient + } } } } @@ -1472,32 +1642,35 @@ demand_conversion_player_ruler_interaction = { } NOT = { scope:recipient = { - is_close_family_of = scope:actor + is_close_family_of = scope:puppet_or_actor } } } modifier = { # Astray faiths require specific circumstances to demand conversion of factor = 0 - scope:actor = { + scope:puppet_or_actor = { NOR = { - faith = { has_doctrine = doctrine_pluralism_fundamentalist } + rite = { rite_has_doctrine = doctrine_pluralism_fundamentalist } has_tolerant_faith_or_culture_trigger = yes } ai_zeal < 25 - faith = { - faith_hostility_level = { - target = scope:recipient.faith + rite = { + rite_hostility_level = { + target = scope:recipient.rite value <= faith_astray_level } } } NOT = { # If the subject has one of your holy sites, always try to convert - scope:recipient = { - any_sub_realm_county = { - any_county_province = { - barony = { - is_holy_site_of = scope:actor.faith + scope:puppet_or_actor.faith = { + any_holy_site = { + holy_site_county ?= { + holder ?= { + OR = { + this = scope:recipient + is_vassal_or_below_of = scope:recipient + } } } } @@ -1505,18 +1678,18 @@ demand_conversion_player_ruler_interaction = { } NOT = { scope:recipient = { - is_close_family_of = scope:actor + is_close_family_of = scope:puppet_or_actor } } } - modifier = { # Rulers with state faith won't try to convert people with faiths that are astray or better + modifier = { # Rulers with state faith won't try to convert people with rites that are astray or better factor = 0 - scope:actor = { + scope:puppet_or_actor = { government_allows = state_faith - primary_title.state_faith ?= { - faith_hostility_level = { - target = scope:recipient.faith + primary_title.state_rite ?= { + rite_hostility_level = { + target = scope:recipient.rite value <= faith_astray_level } } @@ -1546,27 +1719,27 @@ demand_conversion_minister_rites_interaction = { on_decline_summary = stop_attacker_vassal_war_decline_summary is_shown = { - scope:actor = { + scope:puppet_or_actor ?= { is_ai = no has_title = title:e_minister_of_rites - } - scope:recipient = { - top_liege = scope:actor.top_liege - this != top_liege - faith = { - OR = { - faith_hostility_level = { - target = scope:actor.faith - value >= faith_hostile_level - } - faith_hostility_level = { - target = scope:actor.top_liege.faith - value >= faith_hostile_level + scope:recipient = { + top_liege ?= scope:puppet_or_actor.top_liege + this != top_liege + rite ?= { + OR = { + rite_hostility_level = { + target = scope:puppet_or_actor.rite + value >= faith_hostile_level + } + rite_hostility_level = { + target = scope:puppet_or_actor.top_liege.rite + value >= faith_hostile_level + } } } + is_ai = yes + is_ruler = yes } - is_ai = yes - is_ruler = yes } NOT = { scope:recipient = { government_has_flag = government_is_landless_minority } } } @@ -1575,6 +1748,12 @@ demand_conversion_minister_rites_interaction = { is_valid_showing_failures_only = { valid_demand_conversion_conditions_trigger = yes + trigger_if = { + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + treasury >= demand_conversion_minister_rites_treasury_cost_value + } + } } on_send = { @@ -1582,34 +1761,45 @@ demand_conversion_minister_rites_interaction = { cost = { treasury = { - value = 0 - add = scope:actor.minor_treasury_value - multiply = { - value = scope:recipient.primary_title.tier + value = demand_conversion_minister_rites_treasury_cost_value + if = { + limit = { scope:is_puppet_action ?= yes } + multiply = 0 } } } on_accept = { - switch = { - trigger = yes - scope:convert_to_minister_faith = { - scope:actor.faith = { - save_scope_as = conversion_faith - } - } - scope:convert_to_top_liege_faith = { - scope:actor.top_liege.faith = { - save_scope_as = conversion_faith - } - } - scope:convert_to_realm_capital_faith = { - scope:actor.top_liege.capital_county.faith = { - save_scope_as = conversion_faith + if = { + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + if = { + limit = { demand_conversion_minister_rites_treasury_cost_value > 0 } + remove_treasury = { + value = demand_conversion_minister_rites_treasury_cost_value + } } } } - scope:actor = { + switch = { + trigger = yes + scope:convert_to_minister_faith = { + scope:puppet_or_actor.rite = { + save_scope_as = conversion_rite + } + } + scope:convert_to_top_liege_faith = { + scope:puppet_or_actor.top_liege.rite = { + save_scope_as = conversion_rite + } + } + scope:convert_to_realm_capital_faith = { + scope:puppet_or_actor.top_liege.capital_county.rite = { + save_scope_as = conversion_rite + } + } + } + scope:puppet_or_actor = { trigger_event = religious_interaction.2002 } demand_conversion_vassal_ruler_interaction_effect = yes @@ -1618,7 +1808,7 @@ demand_conversion_minister_rites_interaction = { accept_faith_conversion_add_clan_unity_effect = yes show_as_tooltip = { - scope:actor = { + scope:puppet_or_actor = { change_influence = { value = minor_influence_gain multiply = scope:recipient.primary_title.tier @@ -1629,24 +1819,29 @@ demand_conversion_minister_rites_interaction = { } } } + + conversion_tenet_acts_of_the_apostles_effect = yes + + # If you have the Mendicant Preaching personal tenet we give you SP + conversion_tenet_mendicant_preachers_effect = yes } on_decline = { switch = { trigger = yes scope:convert_to_minister_faith = { - scope:actor.faith = { - save_scope_as = conversion_faith + scope:puppet_or_actor.rite = { + save_scope_as = conversion_rite } } scope:convert_to_top_liege_faith = { - scope:actor.top_liege.faith = { - save_scope_as = conversion_faith + scope:puppet_or_actor.top_liege.rite = { + save_scope_as = conversion_rite } } scope:convert_to_realm_capital_faith = { - scope:actor.top_liege.capital_county.faith = { - save_scope_as = conversion_faith + scope:puppet_or_actor.top_liege.capital_county.rite = { + save_scope_as = conversion_rite } } } @@ -1683,7 +1878,7 @@ demand_conversion_minister_rites_interaction = { is_war_leader = scope:recipient } } - scope:actor = { + scope:puppet_or_actor = { trigger_event = { id = religious_interaction.2011 } @@ -1692,7 +1887,7 @@ demand_conversion_minister_rites_interaction = { 500 = { #They ask for a favor trigger = { exists = scope:recipient.capital_county - NOT = { has_hook = scope:actor } + NOT = { has_hook = scope:puppet_or_actor } } # Direct feudal vassals appreciate favors more (they can improve their contract). modifier = { @@ -1700,14 +1895,14 @@ demand_conversion_minister_rites_interaction = { value = 50 # This goes double for your Powerful Vassals. A better contract is likely to be much more important than a short-term payout. if = { - limit = { is_powerful_vassal_of = scope:actor } + limit = { is_powerful_vassal_of = scope:puppet_or_actor } add = 100 } } - this.liege = scope:actor + this.liege = scope:puppet_or_actor government_has_flag = government_is_feudal } - scope:actor = { + scope:puppet_or_actor = { trigger_event = { id = religious_interaction.2012 } @@ -1729,7 +1924,7 @@ demand_conversion_minister_rites_interaction = { add = 50 scope:recipient.demand_conversion_likelihood_calculation < 0 } - scope:actor = { + scope:puppet_or_actor = { trigger_event = { id = religious_interaction.2003 } @@ -1742,10 +1937,10 @@ demand_conversion_minister_rites_interaction = { #Negative opinions add_opinion = { modifier = compelled_me_to_convert_opinion - target = scope:actor + target = scope:puppet_or_actor opinion = -10 } - scope:actor = { + scope:puppet_or_actor = { if = { limit = { refusing_conversion_is_crime_trigger = { @@ -1769,7 +1964,7 @@ demand_conversion_minister_rites_interaction = { send_option = { is_shown = { - scope:actor.top_liege.faith != scope:actor.faith + scope:puppet_or_actor.top_liege.faith != scope:puppet_or_actor.faith } flag = convert_to_top_liege_faith localization = TOP_LIEGE_FAITH @@ -1777,10 +1972,10 @@ demand_conversion_minister_rites_interaction = { send_option = { is_shown = { - scope:actor.top_liege.capital_county.faith = { + scope:puppet_or_actor.top_liege.capital_county.faith = { NOR = { - this = scope:actor.top_liege.faith - this = scope:actor.faith + this = scope:puppet_or_actor.top_liege.faith + this = scope:puppet_or_actor.faith } } } @@ -1791,6 +1986,12 @@ demand_conversion_minister_rites_interaction = { ai_accept = { base = 0 # Increase base chance + + celestial_hierarchy_acceptance_modifier = { + ACTOR = scope:puppet_or_actor + RECIPIENT = scope:recipient + } + modifier = { add = 50 desc = ACTOR_IS_MINISTER_OF_RITES @@ -1798,7 +1999,7 @@ demand_conversion_minister_rites_interaction = { modifier = { add = 25 trigger = { - scope:actor.top_liege = { + scope:puppet_or_actor.top_liege = { OR = { has_realm_law = celestial_bureaucracy_0 has_realm_law = celestial_bureaucracy_1 @@ -1810,7 +2011,7 @@ demand_conversion_minister_rites_interaction = { modifier = { add = 50 trigger = { - scope:actor.top_liege = { + scope:puppet_or_actor.top_liege = { has_realm_law = celestial_bureaucracy_2 } } @@ -1819,7 +2020,7 @@ demand_conversion_minister_rites_interaction = { modifier = { add = 75 trigger = { - scope:actor.top_liege = { + scope:puppet_or_actor.top_liege = { has_realm_law = celestial_bureaucracy_3 } } @@ -1828,13 +2029,14 @@ demand_conversion_minister_rites_interaction = { modifier = { add = 25 trigger = { - scope:actor = { + scope:puppet_or_actor = { has_hook = scope:recipient } } desc = HAS_A_HOOK } religion_demand_conversion_default_modifier = yes + religion_demand_conversion_christian_situation_modifier = yes modifier = { desc = might_ask_for_something_in_return_warning_line_break add = 0 @@ -1853,15 +2055,12 @@ convert_to_religion_interaction = { ignores_pending_interaction_block = yes is_shown = { - scope:actor.faith != scope:recipient.faith - scope:actor = { + scope:puppet_or_actor ?= { + NOT = { faith = scope:recipient.faith } is_landless_ruler = no - # They're either your liege, your spouse or your tributary + # They're your overlord OR = { target_is_liege_or_above = scope:recipient - any_consort = { - this = scope:recipient - } is_tributary_of = scope:recipient } # And you've never HumSac'd a tolerated HoF. @@ -1893,24 +2092,24 @@ convert_to_religion_interaction = { ## If we have a valid state faith, we go there. if = { limit = { - scope:actor = { + scope:puppet_or_actor = { government_allows = state_faith } - scope:actor.top_liege.primary_title.state_faith ?= scope:recipient.faith + scope:puppet_or_actor.top_liege.primary_title.state_rite ?= scope:recipient.rite } decision:adopt_state_faith = { open_view_data = { view = decision_detail - player = scope:actor + player = scope:puppet_or_actor } } } ## Otherwise, go to the usual place. else = { - scope:recipient.faith = { + scope:recipient.rite = { open_view_data = { view = faith_conversion - player = scope:actor # interaction effects are executed for all clients, make sure to open the window only for the actor + player = scope:puppet_or_actor # interaction effects are executed for all clients, make sure to open the window only for the actor } } } @@ -1941,10 +2140,13 @@ convert_to_religion_adventurer_interaction = { notification_text = CONVERT_TO_RELIGION ignores_pending_interaction_block = yes + is_available = { + has_government = landless_adventurer_government + } + is_shown = { scope:actor.faith != scope:recipient.faith scope:actor = { - has_government = landless_adventurer_government # They're either your friend or your spouse OR = { target_is_liege_or_above = scope:recipient @@ -1965,15 +2167,10 @@ convert_to_religion_adventurer_interaction = { } } } - NOT = { scope:actor = { government_has_flag = government_is_landless_minority } } - OR = { - is_ai = no - NOT = { scope:actor = { culture = { has_cultural_parameter = cannot_convert_diasporia } } } - } } is_valid_showing_failures_only = { - } + } auto_accept = yes @@ -2008,23 +2205,39 @@ convert_at_war_interaction = { notification_text = CONVERT_AT_WAR_INTERACTION_NOTIFICATION + is_available = { + trigger_if = { + limit = { is_ai = yes } + ai_zeal < 100 + OR = { + faith ?= { + OR = { + has_doctrine_parameter = unreformed + fervor <= 25 + } + } + rite ?= { rite_has_parameter = unattractive_for_character_conversions } + } + } + } + is_shown = { - scope:actor.faith != scope:recipient.faith - scope:actor = { + scope:puppet_or_actor ?= { + NOT = { faith = scope:recipient.faith } any_character_war = { - primary_defender = scope:actor - primary_attacker = scope:recipient + primary_defender ?= scope:puppet_or_actor using_non_ghw_holy_war_cb_trigger = yes + primary_attacker ?= scope:recipient } NOR = { + government_has_flag = government_is_holy_order + #They can convert + scope:puppet_or_actor.faith.religious_head ?= scope:puppet_or_actor #They're neither your liege nor your spouse (so this isn't shown with convert_to_religion_interaction) target_is_liege_or_above = scope:recipient any_spouse = { this = scope:recipient } - #They can convert - scope:actor = scope:actor.faith.religious_head - government_has_flag = government_is_holy_order # And you've never HumSac'd a tolerated HoF. AND = { has_variable_list = humsacd_hofs @@ -2052,33 +2265,22 @@ convert_at_war_interaction = { cooldown_against_recipient = { years = 10 } on_accept = { - scope:actor = { + scope:puppet_or_actor = { + show_as_tooltip = { convert_at_war_interaction_effect = yes } trigger_event = religious_interaction.2500 - convert_at_war_interaction_effect = yes } } on_decline = { - scope:actor = { + scope:puppet_or_actor = { show_as_tooltip = { add_piety_level = -1 - stress_impact = { zealous = major_stress_impact_gain } + stress_and_fulfillment_impact = { zealous = major_stress_impact_gain } } trigger_event = religious_interaction.2501 } } - ai_potential = { - ai_zeal < 100 - faith = { - OR = { - has_doctrine_parameter = unreformed - fervor <= 25 - has_doctrine_parameter = unattractive_for_character_conversions - } - } - } - ai_targets = { ai_recipients = primary_war_enemies } @@ -2096,43 +2298,43 @@ convert_at_war_interaction = { base = 0 ai_value_modifier = { - who = scope:actor + who = scope:puppet_or_actor ai_zeal = -1 ai_boldness = -0.5 max = 40 } modifier = { - scope:actor = { + scope:puppet_or_actor = { any_character_war = { primary_attacker = scope:recipient - primary_defender = scope:actor + primary_defender = scope:puppet_or_actor attacker_war_score >= 30 } } add = 5 } modifier = { - scope:actor = { + scope:puppet_or_actor = { any_character_war = { primary_attacker = scope:recipient - primary_defender = scope:actor + primary_defender = scope:puppet_or_actor attacker_war_score >= 50 } } add = 10 } modifier = { - scope:actor = { + scope:puppet_or_actor = { any_character_war = { primary_attacker = scope:recipient - primary_defender = scope:actor + primary_defender = scope:puppet_or_actor attacker_war_score >= 80 } } add = 15 } modifier = { - scope:actor.faith = { + scope:puppet_or_actor.faith = { fervor < 50 } scope:recipient.faith = { @@ -2141,7 +2343,7 @@ convert_at_war_interaction = { add = 5 } modifier = { - scope:actor.faith = { + scope:puppet_or_actor.faith = { fervor <= 25 } scope:recipient.faith = { @@ -2150,7 +2352,7 @@ convert_at_war_interaction = { add = 5 } modifier = { - scope:actor.faith = { + scope:puppet_or_actor.faith = { fervor <= 25 } scope:recipient.faith = { @@ -2159,13 +2361,13 @@ convert_at_war_interaction = { add = 5 } modifier = { - scope:actor.faith = { + scope:puppet_or_actor.faith = { fervor >= 75 } add = -10 } modifier = { - scope:actor.faith = { + scope:puppet_or_actor.faith = { fervor >= 50 } add = -5 @@ -2189,11 +2391,11 @@ convert_at_war_interaction = { add = -30 } modifier = { - scope:recipient.faith.fervor < scope:actor.faith.fervor + scope:recipient.faith.fervor < scope:puppet_or_actor.faith.fervor factor = 0 } modifier = { # Big rulers shouldn't convert arbitrarily - scope:actor = { + scope:puppet_or_actor = { highest_held_title_tier >= tier_kingdom sub_realm_size >= 10 NOT = { @@ -2212,18 +2414,63 @@ convert_at_war_interaction = { #################### seek_indulgences_interaction = { - icon = religious + icon = letter_of_indulgence category = interaction_category_religion + interface_priority = 110 desc = seek_indulgences_interaction_desc notification_text = RELIGIOUS_HEAD_SEEK_INDULGENCES + greeting = positive + ai_maybe = yes + + is_available = { + trigger_if = { + limit = { + is_ai = yes + } + NOR = { + has_trait = cynical + has_character_flag = hof_request_cooldown + } + short_term_gold >= head_of_faith_gold_value + } + } is_shown = { - scope:recipient != scope:actor - scope:actor.faith = { - religious_head = scope:recipient - has_doctrine = tenet_communion + scope:recipient != scope:puppet_or_actor + scope:puppet_or_actor ?= { + is_playable_character = yes + faith ?= { + OR = { + has_doctrine = doctrine_spiritual_head + has_doctrine = doctrine_temporal_head + has_doctrine_parameter = has_clerical_regions + } + faith_has_sacraments_central_trigger = yes + } + rite ?= { + NOT = { + rite_has_parameter = no_seek_indulgences + } + } + seek_indulgences_show_recipient_trigger = yes + this != religious_head_or_challenger + } + scope:recipient = { + faith = scope:puppet_or_actor.faith + # Antipope uses petition_antipope_indulgences_interaction instead + trigger_if = { + limit = { has_pam_dlc_trigger = yes } + pam_is_antipope_trigger = no + } + } + # Those under an antipope seek indulgences from them instead of the real Head of Faith + trigger_if = { + limit = { + scope:recipient ?= scope:puppet_or_actor.faith.religious_head + } + scope:puppet_or_actor ?= { is_following_religious_head_challenger = no } } } @@ -2231,10 +2478,11 @@ seek_indulgences_interaction = { is_valid_showing_failures_only = { scope:actor = { + seek_indulgences_recipient_trigger = yes trigger_if = { limit = { has_trait = kinslayer_3 - trait_is_shunned_or_criminal_in_faith_trigger = { FAITH = faith TRAIT = trait:kinslayer_3 GENDER_CHARACTER = scope:actor } + trait_is_shunned_or_criminal_in_rite_trigger = { RITE = rite TRAIT = trait:kinslayer_3 GENDER_CHARACTER = scope:actor } } gold >= seek_indulgences_major_criminal_trait_value } @@ -2243,19 +2491,19 @@ seek_indulgences_interaction = { OR = { AND = { has_trait = kinslayer_2 - trait_is_shunned_or_criminal_in_faith_trigger = { FAITH = faith TRAIT = trait:kinslayer_2 GENDER_CHARACTER = scope:actor } + trait_is_shunned_or_criminal_in_rite_trigger = { RITE = rite TRAIT = trait:kinslayer_2 GENDER_CHARACTER = scope:actor } } AND = { has_trait = witch - trait_is_shunned_or_criminal_in_faith_trigger = { FAITH = faith TRAIT = trait:witch GENDER_CHARACTER = scope:actor } + trait_is_shunned_or_criminal_in_rite_trigger = { RITE = rite TRAIT = trait:witch GENDER_CHARACTER = scope:actor } } AND = { has_trait = deviant - trait_is_shunned_or_criminal_in_faith_trigger = { FAITH = faith TRAIT = trait:deviant GENDER_CHARACTER = scope:actor } + trait_is_shunned_or_criminal_in_rite_trigger = { RITE = rite TRAIT = trait:deviant GENDER_CHARACTER = scope:actor } } AND = { has_trait = sodomite - trait_is_shunned_or_criminal_in_faith_trigger = { FAITH = faith TRAIT = trait:sodomite GENDER_CHARACTER = scope:actor } + trait_is_shunned_or_criminal_in_rite_trigger = { RITE = rite TRAIT = trait:sodomite GENDER_CHARACTER = scope:actor } } } } @@ -2266,15 +2514,15 @@ seek_indulgences_interaction = { OR = { AND = { has_trait = kinslayer_1 - trait_is_shunned_or_criminal_in_faith_trigger = { FAITH = faith TRAIT = trait:kinslayer_1 GENDER_CHARACTER = scope:actor } + trait_is_shunned_or_criminal_in_rite_trigger = { RITE = rite TRAIT = trait:kinslayer_1 GENDER_CHARACTER = scope:actor } } AND = { has_trait = fornicator - trait_is_shunned_or_criminal_in_faith_trigger = { FAITH = faith TRAIT = trait:fornicator GENDER_CHARACTER = scope:actor } + trait_is_shunned_or_criminal_in_rite_trigger = { RITE = rite TRAIT = trait:fornicator GENDER_CHARACTER = scope:actor } } AND = { has_trait = adulterer - trait_is_shunned_or_criminal_in_faith_trigger = { FAITH = faith TRAIT = trait:adulterer GENDER_CHARACTER = scope:actor } + trait_is_shunned_or_criminal_in_rite_trigger = { RITE = rite TRAIT = trait:adulterer GENDER_CHARACTER = scope:actor } } } } @@ -2283,14 +2531,22 @@ seek_indulgences_interaction = { trigger_else = { gold >= seek_indulgences_buy_piety_value } + trigger_if = { + limit = { has_pam_dlc_trigger = yes } + custom_tooltip = { + text = actor_is_antipope_sponsor_tt + pam_is_antipope_sponsor_trigger = no + } + } + pam_not_antipope_when_recipient_is_hof_tt = { CHARACTER = scope:actor } custom_description = { text = "seek_indulgences_excommunicated" NOT = { has_trait = excommunicated } } } scope:actor = { - custom_description = { - text = "hof_interaction_unreformed_faith" + custom_tooltip = { + text = HOF_INTERACTION_UNREFORMED_FAITH NOT = { faith = { has_doctrine_parameter = unreformed } } @@ -2299,44 +2555,68 @@ seek_indulgences_interaction = { is_at_war_with = scope:recipient } } + scope:actor = { + NOT = { + has_character_modifier = promised_pilgrimage_to_clergy_modifier + } + } } ai_accept = { - base = 50 + base = 75 - opinion_modifier = { - opinion_target = scope:actor - who = scope:recipient - multiplier = 1 + celestial_hierarchy_acceptance_modifier = { + ACTOR = scope:actor + RECIPIENT = scope:recipient } - modifier = { # Same language - add = 5 - desc = speaks_same_language_interaction_reason - trigger = { - scope:actor = { - knows_language_of_culture = scope:recipient.culture - } - } - } + seek_indulgences_acceptance_modifier = yes - evaluate_action_increasing_house_unity = { - VALUE = 50 + modifier = { + add = pam_offer_pilgrimage_acceptance_value + scope:offer_pilgrimage = yes + desc = OFFER_PILGRIMAGE_INTERACTION_OPTION_REASON } + } - evaluate_action_decreasing_house_unity = { - VALUE = -100 + send_options_exclusive = no + + send_option = { + is_shown = { + has_pam_dlc_trigger = yes + pam_offer_pilgrimage_option_shown_trigger = { ACTOR = scope:actor } } + is_valid = { + pam_offer_pilgrimage_option_valid_trigger = { ACTOR = scope:actor } + } + flag = offer_pilgrimage + localization = OFFER_PILGRIMAGE_INTERACTION_OPTION } ai_min_reply_days = 1 ai_max_reply_days = 5 + can_send = { + # Anti-spam AI blockers + ai_religious_request_blocker_trigger = { INTERACTION = seek_indulgences_interaction } + } + + on_send = { + # Anti-spam AI blockers + ai_religious_request_blocker_effect = { INTERACTION = seek_indulgences_interaction } + } + on_accept = { - seek_indulgences_interaction_effect = yes + show_as_tooltip = { + seek_indulgences_interaction_effect = yes + } scope:actor = { trigger_event = religious_interaction.1010 } + pam_offer_pilgrimage_effect = { + ACTOR = scope:actor + CLERIC = scope:recipient + } # If we're a clan this interaction affects unity add_clan_unity_interaction_effect = { @@ -2349,10 +2629,16 @@ seek_indulgences_interaction = { } on_decline = { + scope:actor = { + show_as_tooltip = { + seek_indulgences_refusal_effect = yes + } + trigger_event = religious_interaction.1011 } + # If we're a clan this interaction affects unity add_clan_unity_interaction_effect = { CHARACTER = scope:actor @@ -2365,15 +2651,12 @@ seek_indulgences_interaction = { # AI will do - ai_potential = { - short_term_gold >= head_of_faith_gold_value - NOT = { - has_trait = cynical - } - } - ai_targets = { ai_recipients = head_of_faith + ai_recipients = realm_priest_superior + ai_recipients = superior + ai_recipients = realm_priest_top_superior + ai_recipients = councillors } ai_frequency_by_tier = { @@ -2423,6 +2706,114 @@ seek_indulgences_interaction = { piety_level > 0 } } + #high chance of success + modifier = { + add = 25 + scope:recipient = { + OR = { + scope:actor.puppet:theological_agent_puppet ?= scope:recipient + scope:recipient.rite = { + rite_has_parameter = increases_seek_indulgences_acceptance + } + ai_greed >= 100 + ai_vengefulness <= -100 + opinion = { + target = scope:actor + value >= 100 + } + } + } + } + #Lowered chance of success + modifier = { + factor = 0.5 + scope:recipient = { + OR = { + opinion = { + target = scope:actor + value < -25 + } + ai_greed <= -50 + ai_vengefulness >= 50 + rite = { + has_tenet_status = { tenet = tenet_vows_of_poverty status = permitted } + } + rite = { + has_tenet_status = { tenet = tenet_communal_possessions status = permitted } + } + NOT = { + exists = scope:actor.puppet:theological_agent_puppet + } + AND = { + scope:actor = { + NOT = { rite = scope:recipient.rite } + } + scope:recipient = { + rite_fulfillment_score = { + target = scope:actor.rite + value < 25 + } + } + } + } + } + } + + #badly lowered chance of success + modifier = { + factor = 0 + scope:recipient = { + OR = { + opinion = { + target = scope:actor + value < -50 + } + ai_greed <= -80 + ai_vengefulness >= 80 + rite = { + has_tenet_status = { tenet = tenet_confession status = prohibited } + } + AND = { + scope:actor = { + NOT = { rite = scope:recipient.rite } + } + any_tenet = { + scope:actor.rite = { + has_tenet_status = { + tenet = prev + status = core + } + } + scope:recipient.rite = { + has_tenet_status = { + tenet = prev + status = prohibited + } + } + } + } + AND = { + scope:actor = { + NOT = { rite = scope:recipient.rite } + } + any_tenet = { + scope:actor.rite = { + has_tenet_status = { + tenet = prev + status = permitted + } + } + scope:recipient.rite = { + has_tenet_status = { + tenet = prev + status = prohibited + } + } + } + } + } + } + } evaluate_action_increasing_house_unity = { VALUE = 50 @@ -2437,7 +2828,7 @@ declaration_of_repentance_interaction = { desc = { desc = declaration_of_repentance_interaction_desc triggered_desc = { - trigger = { scope:actor = { has_hook = scope:recipient } } + trigger = { scope:puppet_or_actor = { has_hook = scope:recipient } } desc = declaration_of_repentance_interaction_desc_hook } } @@ -2445,38 +2836,96 @@ declaration_of_repentance_interaction = { notification_text = RELIGIOUS_HEAD_DECLARATION_OF_REPENTANCE is_shown = { - scope:recipient != scope:actor - scope:actor = { + scope:puppet_or_actor ?= { has_trait = excommunicated - faith = { - religious_head = scope:recipient - has_doctrine_parameter = excommunication_active + faith ?= { + faith_has_sacraments_central_trigger = yes + } + } + scope:recipient != scope:puppet_or_actor + scope:puppet_or_actor ?= { + broader_clergy_show_hof_or_superior_interactions_trigger = yes + } + # With PAM, hide Declaration of Repentance when the player must petition Rome instead (kings+, or pope_excom). + scope:puppet_or_actor ?= { + trigger_if = { + limit = { + scope:actor = { is_ai = no } + has_pam_dlc_trigger = yes + faith = { petition_head_of_faith_faith_qualifies_trigger = yes } + } + need_hof_for_clergy_interaction_trigger = no + NOR = { + petition_head_of_faith_repentance_requires_petition_trigger = yes + # An archbishop or higher answers only to the Head of Faith + AND = { + religious_head_or_challenger ?= scope:recipient + pam_is_archbishop_or_higher_trigger = no + } + } } } } is_valid_showing_failures_only = { - scope:actor = { + scope:puppet_or_actor ?= { + trigger_if = { + limit = { + highest_held_title_tier >= tier_empire + exists = religious_head_or_challenger + faith = { + has_doctrine = doctrine_spiritual_head + } + } + custom_tooltip = { + text = recipient_not_hof_for_emperor_tt + religious_head_or_challenger = scope:recipient + } + } NOT = { has_character_modifier = recent_excommunication } NOT = { is_at_war_with = scope:recipient } + NOT = { + has_character_modifier = promised_pilgrimage_to_clergy_modifier + } + trigger_if = { + limit = { + government_has_flag = government_is_theocracy + } + piety_level >= 2 + } + pam_valid_excommunication_target_trigger = { EXCOMMUNICATOR = scope:recipient } + } + scope:recipient = { + highest_held_title_tier >= tier_duchy } } send_option = { is_valid = { - scope:actor = { + scope:puppet_or_actor ?= { has_usable_hook = scope:recipient } } flag = declaration_hook localization = DECLARATION_OF_REPENTANCE_HOOK } + send_option = { + is_shown = { + has_pam_dlc_trigger = yes + pam_offer_pilgrimage_option_shown_trigger = { ACTOR = scope:puppet_or_actor } + } + is_valid = { + pam_offer_pilgrimage_option_valid_trigger = { ACTOR = scope:puppet_or_actor } + } + flag = offer_pilgrimage + localization = OFFER_PILGRIMAGE_INTERACTION_OPTION + } should_use_extra_icon = { - scope:actor = { has_usable_hook = scope:recipient } + scope:puppet_or_actor ?= { has_usable_hook = scope:recipient } } extra_icon = "gfx/interface/icons/character_interactions/hook_icon.dds" @@ -2485,31 +2934,53 @@ declaration_of_repentance_interaction = { auto_accept = { custom_description = { text = "spending_hook" - subject = scope:actor + subject = scope:puppet_or_actor object = scope:recipient scope:declaration_hook = yes - scope:actor = { has_strong_hook = scope:recipient } + scope:puppet_or_actor = { has_strong_hook = scope:recipient } } } ai_accept = { base = 25 + celestial_hierarchy_acceptance_modifier = { + ACTOR = scope:puppet_or_actor + RECIPIENT = scope:recipient + } + modifier = { scope:declaration_hook = yes add = 20 desc = SCHEME_WEAK_HOOK_USED } - opinion_modifier = { - opinion_target = scope:actor - who = scope:recipient - multiplier = 1 + modifier = { + add = pam_offer_pilgrimage_acceptance_value + scope:offer_pilgrimage = yes + desc = OFFER_PILGRIMAGE_INTERACTION_OPTION_REASON + } + modifier = { + add = 20 + desc = pam_turned_the_other_cheek_accept_reason + trigger = { + scope:puppet_or_actor = { has_variable = pam_turned_the_other_cheek_var } + } + } + modifier = { + desc = AI_SIMPLE_OPINION_REASON + trigger = { + scope:recipient ?= { is_alive = yes } + scope:puppet_or_actor ?= { is_alive = yes } + } + add = { + value = "scope:recipient.opinion(scope:puppet_or_actor)" + } } modifier = { # Same language add = 5 desc = speaks_same_language_interaction_reason trigger = { - scope:actor = { + scope:puppet_or_actor ?= { knows_language_of_culture = scope:recipient.culture } } @@ -2517,66 +2988,102 @@ declaration_of_repentance_interaction = { modifier = { add = { add = 10 - multiply = scope:actor.num_virtuous_traits + multiply = scope:puppet_or_actor.num_virtuous_traits + } + trigger = { + scope:puppet_or_actor ?= { + num_virtuous_traits > 0 + } } - scope:actor.num_virtuous_traits > 0 desc = DECLARATION_OF_REPENTANCE_VIRTUES } modifier = { add = { add = -10 - multiply = scope:actor.num_sinful_traits + multiply = scope:puppet_or_actor.num_sinful_traits + } + trigger = { + scope:puppet_or_actor ?= { + num_sinful_traits > 0 + } } - scope:actor.num_sinful_traits > 0 desc = DECLARATION_OF_REPENTANCE_SINS } modifier = { desc = RELIGIOUS_HEAD_INTERACTION_PARAGON add = 15 - scope:actor = { - has_trait = paragon + trigger = { + scope:puppet_or_actor ?= { + has_trait = paragon + } } } modifier = { desc = RELIGIOUS_HEAD_INTERACTION_CONSECRATED_BLOOD add = 5 - scope:actor = { - has_trait = consecrated_blood + trigger = { + scope:puppet_or_actor ?= { + has_trait = consecrated_blood + } } } modifier = { desc = RELIGIOUS_HEAD_INTERACTION_UNPLEDGED_GHW add = -25 - scope:recipient = { - has_opinion_modifier = { - target = scope:actor - modifier = unpledged_from_ghw_opinion + trigger = { + scope:puppet_or_actor ?= { is_alive = yes } + scope:recipient ?= { + has_opinion_modifier = { + target = scope:puppet_or_actor + modifier = unpledged_from_ghw_opinion + } } } } modifier = { add = 20 - scope:recipient = { - is_landed = no - } - OR = { - scope:recipient.liege ?= scope:actor - scope:recipient.top_liege ?= scope:actor - } desc = I_AM_LIEGE_TOP_LIEGE + trigger = { + scope:puppet_or_actor ?= { is_alive = yes } + scope:recipient ?= { + is_landed = no + OR = { + liege ?= scope:puppet_or_actor + top_liege ?= scope:puppet_or_actor + } + } + } } modifier = { add = 10 - scope:recipient = { - is_landed = yes - } - OR = { - scope:recipient.liege ?= scope:actor - scope:recipient.top_liege ?= scope:actor - } desc = I_AM_LIEGE_TOP_LIEGE + trigger = { + scope:puppet_or_actor ?= { is_alive = yes } + scope:recipient ?= { + is_landed = yes + OR = { + liege ?= scope:puppet_or_actor + top_liege ?= scope:puppet_or_actor + } + } + } } + # AI only: local bishops heavily refuse to lift a Pope excommunication (players are routed to petition Rome instead). + modifier = { + add = -200 + desc = EXCOMMUNICATED_BY_HOF + trigger = { + scope:puppet_or_actor ?= { + has_character_flag = pope_excom + NOT = { + religious_head_or_challenger ?= scope:recipient + } + } + } + } + secular_to_ecclesiastical_pam_factors_acceptance_modifier = yes + evaluate_action_increasing_house_unity = { VALUE = 50 } @@ -2592,16 +3099,23 @@ declaration_of_repentance_interaction = { on_accept = { declaration_of_repentance_interaction_effect = yes - scope:actor = { + scope:puppet_or_actor = { #Letter event to inform character that their excommunication has been lifted. trigger_event = { id = religious_interaction.1024 } } + non_pope_lifting_excommunication_penalty_effect = yes + + pam_offer_pilgrimage_effect = { + ACTOR = scope:puppet_or_actor + CLERIC = scope:recipient + } + # If we're a clan this interaction affects unity add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = medium_unity_gain DESC = clan_unity_repentance.desc @@ -2610,7 +3124,7 @@ declaration_of_repentance_interaction = { } on_decline = { - scope:actor = { + scope:puppet_or_actor = { #Letter event to inform character the pope refused to lift the excommunication. trigger_event = { @@ -2620,7 +3134,7 @@ declaration_of_repentance_interaction = { # If we're a clan this interaction affects unity add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = minor_unity_loss DESC = clan_unity_repentance_declined.desc @@ -2630,12 +3144,11 @@ declaration_of_repentance_interaction = { # AI will do - ai_potential = { - has_trait = excommunicated - } - ai_targets = { ai_recipients = head_of_faith + ai_recipients = realm_priest_superior + ai_recipients = superior + ai_recipients = councillors } ai_frequency_by_tier = { @@ -2649,6 +3162,17 @@ declaration_of_repentance_interaction = { ai_will_do = { base = 100 + #Shouldn't bother the pope unless important or it was his excommunication + modifier = { + add = -90 + scope:puppet_or_actor = { + NOR = { + has_character_flag = pope_excom + } + need_hof_for_clergy_interaction_trigger = no + religious_head_or_challenger ?= scope:recipient + } + } } } @@ -2659,23 +3183,30 @@ excommunicate_interaction = { desc = excommunicate_interaction_desc + is_available = { + trigger_if = { + limit = { is_ai = yes } + piety >= major_piety_value + is_adult = yes + } + } + is_shown = { - scope:actor = scope:actor.faith.religious_head - scope:actor.faith = { - this = scope:recipient.faith - has_doctrine_parameter = excommunication_active - has_doctrine = doctrine_spiritual_head - } - - NOT = { - scope:recipient = { - has_trait = excommunicated + scope:puppet_or_actor ?= { + this != scope:recipient + #Pope or Bishop + is_clergy = yes + is_ruler = yes + faith ?= { + this = scope:recipient.faith + faith_has_sacraments_central_trigger = yes + trigger_if = { + limit = { religious_head ?= scope:puppet_or_actor } + has_doctrine = doctrine_spiritual_head + } + NOT = { religious_head ?= scope:recipient } } } - - NOT = { #Don't do this to yourself - scope:recipient = scope:actor - } } is_valid_showing_failures_only = { @@ -2683,75 +3214,124 @@ excommunicate_interaction = { scope:recipient = { has_character_modifier = excommunication_recently_lifted } - AND = { - exists = scope:actor.faith.great_holy_war - scope:actor.faith.great_holy_war = { - has_pledged_attacker = scope:recipient - } + scope:puppet_or_actor.faith.great_holy_war ?= { + has_pledged_attacker = scope:recipient } } - scope:recipient = { - age >= 12 - } - scope:actor = { - piety >= major_piety_value - } - scope:actor = { - custom_description = { - text = "hof_interaction_unreformed_faith" + scope:puppet_or_actor = { + highest_held_title_tier >= tier_duchy + piety >= excommunication_piety_cost_value + custom_tooltip = { + text = HOF_INTERACTION_UNREFORMED_FAITH NOT = { faith = { has_doctrine_parameter = unreformed } } } + NOT = { + has_trait = excommunicated + } } - scope:recipient = { NOT = { has_strong_hook = scope:actor } } + scope:recipient = { NOT = { has_strong_hook = scope:puppet_or_actor } } custom_tooltip = { text = cannot_take_overt_hostile_actions_against_diarch.tt - NOT = { scope:recipient ?= scope:actor.diarch } + NOT = { scope:recipient ?= scope:puppet_or_actor.diarch } + } + scope:recipient = { + custom_tooltip = { + text = cannot_excommunicate_antipope_protected_tt + NOT = { + pam_antipope_protected_from_excommunication_trigger = { EXCOMMUNICATOR = scope:puppet_or_actor } + } + } + NOT = { + has_trait = excommunicated + } + pam_valid_excommunication_target_trigger = { EXCOMMUNICATOR = scope:puppet_or_actor } } } auto_accept = yes - force_notification = yes - notification_text = religious_interaction.1021 - #answer_accept_key = religious_interaction.1000.strong_negative + + cost = { + piety = { + value = excommunication_piety_cost_value + if = { + limit = { scope:is_puppet_action ?= yes } + multiply = 0 + } + #Peace of God makes excommunication against aggressors easier + if = { + limit = { + scope:puppet_or_actor ?= { + rite = { + rite_has_parameter = tenet_peace_of_god_excommunication + } + scope:puppet_or_actor = { + has_opinion_modifier = { + modifier = declared_war + target = scope:recipient + } + } + } + } + multiply = 0 + } + } + } on_accept = { - scope:actor = { - add_piety = major_piety_loss - hidden_effect = { - send_interface_toast = { - type = event_toast_effect_neutral - title = excommunicate_interaction_desc.tt - left_icon = scope:recipient - scope:recipient = { - show_as_tooltip = { add_trait = excommunicated } + if = { + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + add_piety = { + value = { + value = excommunication_piety_cost_value + max = piety + multiply = -1 } } } } + scope:puppet_or_actor = { + if = { + limit = { + any_character_situation = { + situation_type = the_christian_church + } + situation:the_christian_church ?= { + situation_top_has_catalyst = catalyst_excommunicate + } + } + if = { + limit = { + scope:recipient = { + highest_held_title_tier >= tier_kingdom + } + } + situation:the_christian_church = { trigger_situation_catalyst = catalyst_excommunicate } + } + else = { + situation:the_christian_church = { trigger_situation_catalyst = catalyst_excommunicate_minor } + } + } + } excommunicate_character = { - REQUESTING_CHARACTER = scope:actor + EXCOMMUNICATOR = scope:puppet_or_actor + REQUESTING_CHARACTER = scope:puppet_or_actor TARGET_CHARACTER = scope:recipient } scope:recipient = { - hidden_effect = { #Nudge towards rivalry - if = { - limit = { - NOR = { - has_relation_rival = scope:actor - has_relation_potential_rival = scope:actor - } - } - set_relation_potential_rival = scope:actor - } + # Letter arrives a few days later; gives time for the trait to land before the player reads it. + trigger_event = { + id = religious_interaction.1021 + days = 5 } } # If we're a clan this interaction affects unity add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = medium_unity_loss DESC = clan_unity_excommunication.desc @@ -2761,11 +3341,6 @@ excommunicate_interaction = { # AI will do - ai_potential = { - is_adult = yes - piety >= major_piety_value - } - ai_target_quick_trigger = { adult = yes } @@ -2788,7 +3363,7 @@ excommunicate_interaction = { base = 50 ai_value_modifier = { # +50 to -50 - who = scope:actor + who = scope:puppet_or_actor ai_vengefulness = 0.5 } @@ -2796,13 +3371,59 @@ excommunicate_interaction = { factor = 0 scope:recipient = { NOR = { - has_relation_rival = scope:actor - has_relation_nemesis = scope:actor - is_at_war_with = scope:actor + has_relation_rival = scope:puppet_or_actor + has_relation_nemesis = scope:puppet_or_actor + is_at_war_with = scope:puppet_or_actor + has_character_flag = executed_own_hof_unlawfully + has_character_flag = executed_senior_cleric_unlawfully + AND = { + empire_faith_gate_enabled_trigger = yes + has_contested_empire_trigger = yes + faith_has_existing_empire_holder_trigger = yes + faith = scope:puppet_or_actor.faith + efg_contested_empire_grace_period_elapsed_trigger = yes + } + AND = { + scope:puppet_or_actor = { + has_personal_tenet_flag = tenet_peace_of_god_personal_excommunicate_aggressors + } + pam_peace_of_god_coreligionist_aggressor_trigger = yes + } } } } + modifier = { + add = 50 + scope:recipient = { has_character_flag = executed_own_hof_unlawfully } + } + + modifier = { + add = 25 + scope:recipient = { has_character_flag = executed_senior_cleric_unlawfully } + } + + modifier = { + add = 40 + scope:puppet_or_actor = { + has_personal_tenet_flag = tenet_peace_of_god_personal_excommunicate_aggressors + } + scope:recipient = { + pam_peace_of_god_coreligionist_aggressor_trigger = yes + } + } + + modifier = { + add = 10 + empire_faith_gate_enabled_trigger = yes + scope:recipient = { + has_contested_empire_trigger = yes + faith_has_existing_empire_holder_trigger = yes + faith = scope:puppet_or_actor.faith + efg_contested_empire_grace_period_elapsed_trigger = yes + } + } + modifier = { factor = 0 scope:recipient = { @@ -2823,19 +3444,70 @@ lift_excommunication_interaction = { desc = lift_excommunication_interaction_desc + is_available = { + trigger_if = { + limit = { is_ai = yes } + piety >= major_piety_value + is_adult = yes + } + } + is_shown = { - scope:actor = scope:actor.faith.religious_head - scope:actor.faith = scope:recipient.faith + scope:puppet_or_actor ?= { + #Pope or Bishop + OR = { + AND = { + is_clergy = yes + is_ruler = yes + } + religious_head_or_challenger ?= scope:puppet_or_actor + } + NOT = { + religious_head_or_challenger ?= scope:recipient + } + } + scope:puppet_or_actor.faith ?= { + has_doctrine = doctrine_spiritual_head + faith_has_sacraments_central_trigger = yes + this = scope:recipient.faith + } scope:recipient = { has_trait = excommunicated + this != scope:puppet_or_actor + } + } + + cost = { + piety = { + value = lift_excommunication_interaction_cost_value + if = { + limit = { scope:is_puppet_action ?= yes } + multiply = 0 + } } } is_valid_showing_failures_only = { - scope:actor = { + trigger_if = { + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + piety >= lift_excommunication_interaction_cost_value + } + } + scope:puppet_or_actor = { + highest_held_title_tier >= tier_duchy NOT = { is_at_war_with = scope:recipient } + custom_tooltip = { + text = HOF_INTERACTION_UNREFORMED_FAITH + NOT = { + faith = { has_doctrine_parameter = unreformed } + } + } + } + scope:recipient = { + pam_valid_excommunication_target_trigger = { EXCOMMUNICATOR = scope:puppet_or_actor } } } @@ -2845,14 +3517,52 @@ lift_excommunication_interaction = { #answer_accept_key = religious_interaction.1024.positive on_accept = { + if = { + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + add_piety = { + value = { + value = lift_excommunication_interaction_cost_value + max = piety + multiply = -1 + } + } + } + } lift_character_excommunication_effect = { TARGET_CHARACTER = scope:recipient - REQUESTING_CHARACTER = scope:actor + REQUESTING_CHARACTER = scope:puppet_or_actor + } + scope:puppet_or_actor = { + if = { + limit = { + NOT = { + this = scope:recipient + } + any_character_situation = { + situation_type = the_christian_church + } + situation:the_christian_church ?= { + situation_top_has_catalyst = catalyst_lift_excommunication + } + } + if = { + limit = { + scope:recipient = { + highest_held_title_tier >= tier_kingdom + } + } + situation:the_christian_church = { trigger_situation_catalyst = catalyst_lift_excommunication } + } + else = { + situation:the_christian_church = { trigger_situation_catalyst = catalyst_lift_excommunication_minor } + } + } } # If we're a clan this interaction affects unity add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = medium_unity_gain DESC = clan_unity_excommunication_lifted @@ -2862,11 +3572,6 @@ lift_excommunication_interaction = { # AI will do - ai_potential = { - is_adult = yes - piety >= major_piety_value - } - ai_target_quick_trigger = { adult = yes } @@ -2876,10 +3581,15 @@ lift_excommunication_interaction = { ai_recipients = war_allies } + ai_targets = { + ai_recipients = neighboring_rulers + max = 10 + } + ai_frequency_by_tier = { barony = 0 - county = 96 - duchy = 72 + county = 0 + duchy = 0 kingdom = 12 empire = 12 hegemony = 12 @@ -2889,17 +3599,56 @@ lift_excommunication_interaction = { base = 10 ai_value_modifier = { # +50 to -50 - who = scope:actor + who = scope:puppet_or_actor ai_compassion = 0.5 } + modifier = { + add = 25 + desc = pam_turned_the_other_cheek_accept_reason + scope:recipient = { has_variable = pam_turned_the_other_cheek_var } + } + + modifier = { + add = 20 + scope:puppet_or_actor = { # PAM - Concord phase + top_participant_group:the_christian_church ?= { + has_participant_group_parameter = the_christian_church_more_likely_to_lift_excommunications + } + opinion = { + target = scope:recipient + value >= high_positive_opinion + } + } + } + + modifier = { + factor = 0 + scope:puppet_or_actor = { + has_character_flag = pope_excom + } + NOT = { + scope:puppet_or_actor.religious_head_or_challenger ?= scope:puppet_or_actor + } + } + modifier = { factor = 0 scope:recipient = { - NOR = { - has_relation_friend = scope:actor - has_relation_best_friend = scope:actor - is_allied_to = scope:actor + NOR = { # Only do this for friends + has_relation_friend = scope:puppet_or_actor + has_relation_best_friend = scope:puppet_or_actor + is_allied_to = scope:puppet_or_actor + has_variable = pam_turned_the_other_cheek_var + scope:puppet_or_actor = { # Unless you are in the Concord phase + top_participant_group:the_christian_church ?= { + has_participant_group_parameter = the_christian_church_more_likely_to_lift_excommunications + } + opinion = { # And the actor likes the guy + target = scope:recipient + value >= high_positive_opinion + } + } } } } @@ -2913,55 +3662,172 @@ request_excommunication_interaction = { desc = request_excommunication_interaction_desc redirect = { + #excommunication victim needs to be made secondary recipient + scope:recipient = { + save_scope_as = secondary_recipient + } + scope:puppet_or_actor = { + petition_head_of_faith_save_religious_authority_effect = { SCOPE = excommunication_petition_authority } + } + + # Are we looking for a territorial cleric or going to the target's shared Head of Faith? if = { limit = { - exists = scope:actor.faith.religious_head + OR = { + scope:secondary_recipient = { + need_hof_for_clergy_interaction_trigger = no + } + trigger_if = { + limit = { exists = scope:excommunication_petition_authority } + NOT = { + scope:secondary_recipient = { + petition_head_of_faith_religious_authority_is_trigger = { + CHARACTER = scope:excommunication_petition_authority + } + } + } + } + trigger_else = { always = yes } + } } - scope:recipient = { - save_scope_as = secondary_recipient + #Is it a ruler or just some regular joe? + if = { + limit = { + scope:secondary_recipient = { + is_ruler = yes + } + } + pam_redirect_request_excommunication_ruler_effect = yes } - scope:actor.faith.religious_head = { + else_if = { + limit = { + exists = scope:secondary_recipient.liege + } + pam_redirect_request_excommunication_courtier_effect = yes + } + else = { + pam_redirect_request_excommunication_wanderer_effect = yes + } + } + else = { + scope:excommunication_petition_authority ?= { save_scope_as = recipient } } - scope:actor.faith = { - if = { - limit = { exists = religious_head } - religious_head = { - save_scope_as = recipient + + #Still hasn't been set + #stop errors from the above process failing, this should be blocked anyway + if = { + limit = { + scope:secondary_recipient = scope:recipient + } + clear_saved_scope = recipient + } + } + + cooldown_against_recipient = { years = 3 } + + notification_text = RELIGIOUS_HEAD_REQUEST_EXCOMMUNICATION + + is_available = { + trigger_if = { + limit = { is_ai = yes } + piety >= major_piety_value + is_adult = yes + NOT = { has_character_flag = hof_request_cooldown } + faith ?= { faith_has_sacraments_central_trigger = yes } + } + } + + is_shown = { + scope:puppet_or_actor.faith ?= { + faith_has_sacraments_central_trigger = yes + OR = { + petition_head_of_faith_faith_qualifies_trigger = yes + has_doctrine_parameter = has_clerical_regions + AND = { + has_doctrine = doctrine_spiritual_head + exists = religious_head + } + any_faith_ruler = { + government_has_flag = government_is_theocracy + highest_held_title_tier >= tier_duchy + } + } + this = scope:secondary_recipient.faith + } + NOR = { + scope:puppet_or_actor ?= scope:secondary_recipient + scope:puppet_or_actor.faith.religious_head ?= scope:puppet_or_actor + scope:puppet_or_actor.faith.religious_head ?= scope:secondary_recipient + AND = { + NOT = { exists = scope:puppet_or_actor.faith.religious_head } + OR = { + scope:secondary_recipient.rite.head_of_rite ?= scope:puppet_or_actor + scope:secondary_recipient.rite.head_of_rite ?= scope:secondary_recipient } } } } - notification_text = RELIGIOUS_HEAD_REQUEST_EXCOMMUNICATION - - is_shown = { - exists = scope:actor.faith.religious_head - NOR = { - scope:actor = scope:secondary_recipient - scope:actor.faith.religious_head = scope:actor - scope:actor.faith.religious_head = scope:secondary_recipient - } - scope:actor.faith = { - exists = religious_head - this = scope:secondary_recipient.faith - has_doctrine_parameter = excommunication_active - has_doctrine = doctrine_spiritual_head - } - } - is_valid_showing_failures_only = { - scope:actor = { - piety >= massive_piety_value + # The local path still needs a valid territorial cleric. + trigger_if = { + limit = { + NOT = { + scope:secondary_recipient = { + petition_head_of_faith_religious_authority_is_trigger = { + CHARACTER = scope:recipient + } + } + } + } + custom_tooltip = { + text = no_valid_excommunicator_tt + scope:puppet_or_actor.faith = { + any_faith_subordinate = { + highest_held_title_tier >= tier_duchy + save_temporary_scope_as = cleric_temp + pam_valid_excommunication_target_trigger = { EXCOMMUNICATOR = scope:cleric_temp } + } + } + } + scope:secondary_recipient.highest_held_title_tier < tier_empire } - scope:secondary_recipient = { #Excommunication target - NOT = { has_trait = excommunicated } + # additional checks if not requested through puppet... + trigger_if = { + limit = { NOT = { scope:puppet_or_actor ?= scope:actor } } + scope:secondary_recipient = { + NOT = { has_strong_hook = scope:puppet_or_actor } + } + trigger_if = { + limit = { + petition_head_of_faith_excommunication_target_requires_petition_trigger = yes + NOT = { scope:excommunication_hook = yes } + } + scope:puppet_or_actor = { + piety >= massive_piety_value + } + } + trigger_else = { + scope:puppet_or_actor = { + piety >= request_excommunication_piety_cost_value + } + } + } + + # Excommunication target + scope:secondary_recipient = { + NOR = { + has_trait = excommunicated + has_character_modifier = excommunication_recently_lifted + } age >= 12 } - scope:actor = { - custom_description = { - text = "hof_interaction_unreformed_faith" + scope:puppet_or_actor = { + NOT = { has_trait = excommunicated } + custom_tooltip = { + text = HOF_INTERACTION_UNREFORMED_FAITH NOT = { faith = { has_doctrine_parameter = unreformed } } @@ -2970,61 +3836,175 @@ request_excommunication_interaction = { is_at_war_with = scope:recipient } } - scope:secondary_recipient = { NOT = { has_strong_hook = scope:actor } } + custom_tooltip = { text = cannot_take_overt_hostile_actions_against_diarch.tt - NOT = { scope:recipient ?= scope:actor.diarch } + NOT = { scope:recipient ?= scope:puppet_or_actor.diarch } + } + scope:secondary_recipient = { + custom_tooltip = { + text = cannot_excommunicate_antipope_protected_tt + NOT = { + pam_antipope_protected_from_excommunication_trigger = { EXCOMMUNICATOR = scope:recipient } + } + } + } + scope:puppet_or_actor = { + NOT = { + has_character_modifier = promised_pilgrimage_to_clergy_modifier + } + } + #Can you just do it yourself? + trigger_if = { + limit = { + scope:puppet_or_actor = { + government_has_flag = government_is_theocracy + highest_held_title_tier >= tier_duchy + } + } + scope:secondary_recipient = { + custom_tooltip = { + text = can_excommunicate_directly + NOT = { + pam_valid_excommunication_target_trigger = { EXCOMMUNICATOR = scope:puppet_or_actor } + } + } + } + } + trigger_if = { + limit = { + scope:secondary_recipient = { + government_has_flag = government_is_theocracy + } + } + custom_tooltip = { + text = secondary_recipient_must_have_superior_tt + scope:secondary_recipient = { + OR = { + AND = { + exists = superior + } + any_liege_or_above = { + government_has_flag = government_is_theocracy + faith = scope:secondary_recipient.faith + NOT = { + this = scope:puppet_or_actor + } + } + } + } + } + } + trigger_if = { + limit = { + has_pam_dlc_trigger = yes + } + scope:puppet_or_actor = { + clergy_interaction_generic_piety_level_or_puppet_req_trigger = yes + } } } send_option = { is_valid = { - scope:actor = { - has_usable_hook = scope:recipient + # either the actor or their puppet has a hook on the hof + or = { + scope:secondary_actor ?= { + has_usable_hook = scope:recipient + } + scope:puppet_or_actor = { + has_usable_hook = scope:recipient + } } } flag = excommunication_hook localization = EXCOMMUNICATION_HOOK } should_use_extra_icon = { - scope:actor = { has_usable_hook = scope:recipient } + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } extra_icon = "gfx/interface/icons/character_interactions/hook_icon.dds" send_options_exclusive = no auto_accept = { - custom_description = { - text = "spending_hook" - subject = scope:actor - object = scope:recipient - scope:excommunication_hook = yes - scope:actor = { has_strong_hook = scope:recipient } + trigger_if = { + limit = { + petition_head_of_faith_excommunication_target_requires_petition_trigger = yes + } + petition_head_of_faith_excommunication_target_requires_petition_trigger = yes + } + trigger_else = { + custom_description = { + text = "spending_hook" + subject = scope:puppet_or_actor + object = scope:recipient + scope:excommunication_hook = yes + scope:puppet_or_actor = { has_strong_hook = scope:recipient } + } } } ai_accept = { base = -50 + celestial_hierarchy_acceptance_modifier = { + ACTOR = scope:puppet_or_actor + RECIPIENT = scope:recipient + } + + modifier = { # By God Alone - Secular Faith: the petitioner holds the ear of the clergy + add = 25 + desc = pam_sf_ear_of_clergy_accept_reason + trigger = { + scope:puppet_or_actor = { has_character_modifier = pam_sf_ear_of_clergy_modifier } + } + } + modifier = { scope:excommunication_hook = yes add = 50 desc = SCHEME_WEAK_HOOK_USED } + modifier = { + empire_faith_gate_enabled_trigger = yes + scope:secondary_recipient ?= { + has_contested_empire_trigger = yes + faith_has_existing_empire_holder_trigger = yes + faith = scope:puppet_or_actor.faith + } + add = 25 + desc = EXCOMMUNICATION_CONTESTED_EMPIRE + } + modifier = { + scope:secondary_recipient ?= { has_character_flag = executed_own_hof_unlawfully } + add = 50 + desc = EXCOMMUNICATION_EXECUTED_HOF_CRIME + } + modifier = { + scope:secondary_recipient ?= { has_character_flag = executed_senior_cleric_unlawfully } + add = 25 + desc = EXCOMMUNICATION_EXECUTED_SENIOR_CLERIC_CRIME + } + modifier = { + scope:secondary_recipient ?= { has_character_flag = executed_own_hof_lawfully } + add = 15 + desc = EXCOMMUNICATION_EXECUTED_HOF + } opinion_modifier = { - who = scope:actor.faith.religious_head - opinion_target = scope:actor + who = scope:recipient + opinion_target = scope:puppet_or_actor multiplier = 1 } opinion_modifier = { - who = scope:actor.faith.religious_head + who = scope:recipient opinion_target = scope:secondary_recipient #Excommunication target multiplier = -1 min = 0 } modifier = { add = -100 - scope:actor.faith.religious_head = { + scope:recipient = { opinion = { value > 0 target = scope:secondary_recipient #Excommunication target @@ -3051,78 +4031,169 @@ request_excommunication_interaction = { modifier = { desc = RELIGIOUS_HEAD_INTERACTION_PARAGON add = 15 - scope:actor = { + scope:puppet_or_actor = { has_trait = paragon } } modifier = { desc = RELIGIOUS_HEAD_INTERACTION_CONSECRATED_BLOOD add = 5 - scope:actor = { + scope:puppet_or_actor = { has_trait = consecrated_blood } } + modifier = { + add = 20 + scope:puppet_or_actor = { # PAM - Reform phase + top_participant_group:the_christian_church ?= { + has_participant_group_parameter = the_christian_church_more_likely_to_accept_request_excommunications + } + } + desc = the_christian_church_phase_value_tt + } + modifier = { + add = 100 + scope:puppet_or_actor.puppet:theological_agent_puppet ?= scope:recipient + desc = IS_YOUR_PUPPET + } + secular_to_ecclesiastical_pam_factors_acceptance_modifier = yes } ai_min_reply_days = 1 ai_max_reply_days = 5 + can_send = { + # Anti-spam AI blockers + ai_religious_request_blocker_trigger = { INTERACTION = request_excommunication_interaction } + } + + on_send = { + # Anti-spam AI blockers + ai_religious_request_blocker_effect = { INTERACTION = request_excommunication_interaction } + } + on_accept = { + #If you are trying to excommunicate a duke or below, then it's a simple process of talking to the correct clergy above them if = { limit = { - scope:secondary_recipient = { is_alive = yes } - } - if = { - limit = { scope:excommunication_hook = yes } - scope:actor = { - use_hook = scope:recipient - } - } - - scope:actor = { - #Spend piety for the excommunication. - add_piety = massive_piety_loss - - #Letter event to inform character the pope agreed to their request. - trigger_event = { - id = religious_interaction.1022 - } - } - excommunicate_character = { - TARGET_CHARACTER = scope:secondary_recipient - REQUESTING_CHARACTER = scope:actor - } - scope:secondary_recipient = { - #Letter event to inform character that they have been excommunicated. - trigger_event = { - id = religious_interaction.1020 - } - hidden_effect = { #Nudge towards rivalry - if = { - limit = { - NOR = { - has_relation_rival = scope:actor - has_relation_potential_rival = scope:actor - } - scope:actor = { is_alive = yes } - } - set_relation_potential_rival = scope:actor + OR = { + AND = { + scope:secondary_recipient.highest_held_title_tier < tier_empire + has_pam_dlc_trigger = no + } + #otherwise kings and above you must travel to rome to request excommunication + AND = { + scope:secondary_recipient.highest_held_title_tier < tier_kingdom + has_pam_dlc_trigger = yes } } } - # If we're a clan this interaction affects unity - add_clan_unity_interaction_effect = { - CHARACTER = scope:actor - TARGET = scope:recipient - VALUE = medium_unity_loss - DESC = clan_unity_request_excommunication.desc - REVERSE_NON_HOUSE_TARGET = no + if = { + limit = { + scope:secondary_recipient = { is_alive = yes } + } + if = { + limit = { scope:excommunication_hook = yes } + scope:puppet_or_actor = { + use_hook = scope:recipient + } + } + + scope:puppet_or_actor = { + #Spend piety for the excommunication. + #Peace of God makes it free against aggressors though + if = { + limit = { + NAND = { + rite = { + rite_has_parameter = tenet_peace_of_god_excommunication + } + has_opinion_modifier = { + modifier = declared_war + target = scope:secondary_recipient + } + } + } + add_piety = { + value = { + value = request_excommunication_piety_cost_value + max = piety + multiply = -1 + } + } + } + + #Letter event to inform character the pope agreed to their request. + trigger_event = { + id = religious_interaction.1022 + } + if = { + limit = { + any_character_situation = { + situation_type = the_christian_church + } + situation:the_christian_church ?= { + situation_top_has_catalyst = catalyst_request_excommunication + } + } + if = { + limit = { + scope:secondary_recipient = { + highest_held_title_tier >= tier_kingdom + } + } + situation:the_christian_church = { trigger_situation_catalyst = catalyst_request_excommunication } + } + else = { + situation:the_christian_church = { trigger_situation_catalyst = catalyst_request_excommunication_minor } + } + } + } + excommunicate_character = { + EXCOMMUNICATOR = scope:recipient + TARGET_CHARACTER = scope:secondary_recipient + REQUESTING_CHARACTER = scope:puppet_or_actor + } + scope:secondary_recipient = { + # Excommunication letter (same 5-day delay as direct papal excommunication). + trigger_event = { + id = religious_interaction.1020 + days = 5 + } + } + # If we're a clan this interaction affects unity + add_clan_unity_interaction_effect = { + CHARACTER = scope:puppet_or_actor + TARGET = scope:recipient + VALUE = medium_unity_loss + DESC = clan_unity_request_excommunication.desc + REVERSE_NON_HOUSE_TARGET = no + } + hof_request_accept_consequences_effect = { + HOF = scope:recipient + } } } + # King+ targets require a petition trip to Rome (same pattern as lifting a papal excommunication). + else = { + scope:puppet_or_actor = { + save_scope_as = excom_request + } + custom_tooltip = petition_head_of_faith_excommunication_setup_interaction_accept_tt + petition_head_of_faith_prepare_petition_effect = { + TYPE = request_excommunication + HOOK = excommunication_hook + PIETY_VALUE = massive_piety_value + } + } } on_decline = { - scope:actor = { + hof_request_refuse_consequences_effect = { + HOF = scope:recipient + REQUESTER = scope:puppet_or_actor + } + scope:puppet_or_actor = { #Letter event to inform character the pope refused their request. trigger_event = { id = religious_interaction.1023 @@ -3131,7 +4202,7 @@ request_excommunication_interaction = { # If we're a clan this interaction affects unity add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = miniscule_unity_gain DESC = clan_unity_excommunication_request_denied.desc @@ -3141,11 +4212,6 @@ request_excommunication_interaction = { # AI will do - ai_potential = { - is_adult = yes - piety >= major_piety_value - } - ai_target_quick_trigger = { adult = yes } @@ -3168,7 +4234,7 @@ request_excommunication_interaction = { base = 25 ai_value_modifier = { # +50 to -50 - who = scope:actor + who = scope:puppet_or_actor ai_vengefulness = 0.5 } @@ -3176,18 +4242,62 @@ request_excommunication_interaction = { factor = 0 scope:secondary_recipient = { NOR = { - has_relation_rival = scope:actor - has_relation_nemesis = scope:actor - is_at_war_with = scope:actor + has_relation_rival = scope:puppet_or_actor + has_relation_nemesis = scope:puppet_or_actor + is_at_war_with = scope:puppet_or_actor + has_character_flag = executed_own_hof_unlawfully + has_character_flag = executed_senior_cleric_unlawfully + AND = { + empire_faith_gate_enabled_trigger = yes + has_contested_empire_trigger = yes + faith_has_existing_empire_holder_trigger = yes + faith = scope:puppet_or_actor.faith + } } } } + + modifier = { + add = 50 + scope:secondary_recipient = { has_character_flag = executed_own_hof_unlawfully } + } + + modifier = { + add = 25 + scope:secondary_recipient = { has_character_flag = executed_senior_cleric_unlawfully } + } + + #Clergy can do it themselves to lower tier rulers + modifier = { + scope:puppet_or_actor = { + is_clergy = yes + highest_held_title_tier >= tier_duchy + } + scope:secondary_recipient = { + highest_held_title_tier < tier_kingdom + } + factor = 0 + } + + modifier = { + add = 10 + empire_faith_gate_enabled_trigger = yes + scope:puppet_or_actor = { + has_contested_empire_trigger = yes + faith_has_existing_empire_holder_trigger = yes + } + scope:secondary_recipient = { + has_contested_empire_trigger = yes + faith_has_existing_empire_holder_trigger = yes + faith = scope:puppet_or_actor.faith + } + } } } ### End Communion tenets ### -#Ask to take the vows to join Holy order +#Ask to take the vows to join Military Order #by Linnéa Thimrén & Bianca Savazzi send_to_holy_order_interaction = { category = interaction_category_friendly @@ -3205,16 +4315,41 @@ send_to_holy_order_interaction = { desc = send_to_holy_order_interaction_desc - on_decline_summary = take_vows_decline_summary + on_decline_summary = { + triggered_desc = { + trigger = { NOT = { scope:actor = scope:puppet_or_actor } } + desc = take_vows_decline_summary_puppeteer + } + triggered_desc = { + trigger = { scope:actor = scope:puppet_or_actor } + desc = take_vows_decline_summary + } + } greeting = negative notification_text = REQUEST_VOWS_NOTIFICATION_TEXT + is_available = { + trigger_if = { + limit = { is_ai = yes } + piety >= major_piety_value + is_adult = yes + } + } + is_shown = { + scope:puppet_or_actor.faith ?= { + any_faith_holy_order = { #Your faith must have a Military Order + leader = { + government_has_flag = government_is_military_holy_order + } + } + } + exists = scope:puppet_or_actor scope:recipient = { OR = { - is_courtier_of = scope:actor - is_child_of = scope:actor + is_courtier_of = scope:puppet_or_actor + is_child_of = scope:puppet_or_actor } NOR = { has_trait = devoted @@ -3222,33 +4357,43 @@ send_to_holy_order_interaction = { } } NOT = { #Not your bishop - scope:actor = { + scope:puppet_or_actor ?= { any_learning_councillor = { this = scope:recipient } } } - scope:actor.faith = { - any_faith_holy_order = { #Your faith must have a Holy Order - always = yes - } - } } is_valid_showing_failures_only = { + trigger_if = { + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + piety >= scope:recipient.ask_to_take_vows_piety_cost + } + } + trigger_if = { + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + dynasty ?= { dynasty_prestige >= take_vows_dynasty_prestige_cost_value } + } + } scope:recipient = { - is_courtier_of = scope:actor - #Triggers that applies to both Monastery or Holy Order requirements + is_courtier_of = scope:puppet_or_actor + #Triggers that applies to both Monastery or Military Order requirements can_take_religious_vows_trigger = yes can_be_warrior_trigger = { ARMY_OWNER = scope:recipient } custom_description = { text = TAKE_VOWS_INTERACTION_MARTIAL_EDUCATION object = scope:recipient - has_education_martial_trigger = yes + OR = { + prowess > low_skill_rating + has_education_martial_trigger = yes + } } - custom_description = { #At least one Holy Order whose leader you're not a rival of + custom_description = { #At least one Military Order whose leader you're not a rival of text = not_rival_leader_check object = scope:recipient - scope:actor.faith = { + scope:puppet_or_actor.faith = { any_faith_holy_order = { leader = { NOT = { has_relation_rival = scope:recipient } @@ -3259,7 +4404,12 @@ send_to_holy_order_interaction = { } custom_tooltip = { text = cannot_take_overt_hostile_actions_against_diarch.tt - NOT = { scope:recipient ?= scope:actor.diarch } + NOT = { scope:recipient ?= scope:puppet_or_actor.diarch } + } + scope:puppet_or_actor = { + NOT = { + has_character_modifier = promised_pilgrimage_to_clergy_modifier + } } } @@ -3267,32 +4417,69 @@ send_to_holy_order_interaction = { auto_accept = { custom_description = { text = "spending_hook" - subject = scope:actor + subject = scope:puppet_or_actor object = scope:recipient scope:hook = yes - scope:actor = { has_strong_hook = scope:recipient } + scope:puppet_or_actor = { has_strong_hook = scope:recipient } } } send_option = { is_valid = { - scope:actor = { + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } flag = hook localization = SCHEME_HOOK } + #DEMAND that they take the vows + send_option = { + is_shown = { + scope:actor = { is_ai = no } + } + is_valid = { + scope:recipient.liege ?= scope:puppet_or_actor + scope:puppet_or_actor = { + custom_tooltip = { + text = parent_or_dynast_tt + OR = { + is_parent_of = scope:recipient + AND = { + exists = scope:puppet_or_actor.dynasty + is_dynast = yes + scope:recipient.dynasty ?= scope:puppet_or_actor.dynasty + } + } + } + } + } + flag = demand + localization = INTERACTION_DEMAND_VOWS + } should_use_extra_icon = { - scope:actor = { has_usable_hook = scope:recipient } + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } extra_icon = "gfx/interface/icons/character_interactions/hook_icon.dds" send_options_exclusive = no cost = { - piety = scope:recipient.ask_to_take_vows_piety_cost + piety = { + value = scope:recipient.ask_to_take_vows_piety_cost + if = { + limit = { scope:is_puppet_action ?= yes } + multiply = 0 + } + } + renown = { + value = take_vows_dynasty_prestige_cost_value + if = { + limit = { scope:is_puppet_action ?= yes } + multiply = 0 + } + } } on_send = { @@ -3306,29 +4493,64 @@ send_to_holy_order_interaction = { } on_accept = { - scope:actor = { + if = { + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + add_piety = { + value = { + add = scope:recipient.ask_to_take_vows_piety_cost + max = piety + multiply = -1 + } + } + if = { + limit = { take_vows_dynasty_prestige_cost_value > 0 } + dynasty ?= { + add_dynasty_prestige = { + value = { + value = take_vows_dynasty_prestige_cost_value + multiply = -1 + } + } + } + } + } + } + scope:puppet_or_actor = { if = { limit = { scope:hook = yes } use_hook = scope:recipient } + #You demanded compliance as parent or dynasty head... you get it, but at a cost + if = { + limit = { + scope:demand = yes + } + scope:puppet_or_actor = { + show_as_tooltip = { + take_vows_demand_effect = yes + } + } + } + # Legitimacy loss if you're doing this to your children if = { limit = { - scope:recipient = { is_primary_heir_of = scope:actor } + scope:recipient = { is_primary_heir_of = scope:puppet_or_actor } } add_legitimacy = { value = minor_legitimacy_loss - multiply = scope:actor.primary_title.tier + multiply = scope:puppet_or_actor.primary_title.tier } } else_if = { limit = { - scope:recipient = { is_child_of = scope:actor } + scope:recipient = { is_heir_of = scope:puppet_or_actor } } add_legitimacy = { value = miniscule_legitimacy_loss - multiply = scope:actor.primary_title.tier + multiply = scope:puppet_or_actor.primary_title.tier } } @@ -3336,6 +4558,7 @@ send_to_holy_order_interaction = { show_as_tooltip = { send_child_to_holy_order_tooltip_effect = yes scope:recipient = { kick_from_court_interaction_warning_tooltip_effect = yes } + take_vows_faith_opinion_effect = yes } } hidden_effect = { @@ -3346,7 +4569,7 @@ send_to_holy_order_interaction = { # If we're a clan this interaction affects unity add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = minor_unity_gain DESC = clan_unity_send_to_holy_order.desc @@ -3355,15 +4578,28 @@ send_to_holy_order_interaction = { } on_decline = { + scope:puppet_or_actor = { + #You demanded compliance as parent or dynasty head... you get it, but at a cost + if = { + limit = { + scope:demand = yes + } + scope:puppet_or_actor = { + show_as_tooltip = { + take_vows_demand_effect = yes + } + } + } + } scope:recipient = { add_opinion = { - target = scope:actor + target = scope:puppet_or_actor modifier = asked_me_to_take_vows_opinion years = 10 } } #Letter event informing the character about the rejection. - scope:actor = { + scope:puppet_or_actor = { trigger_event = { id = religious_interaction.1031 } @@ -3371,7 +4607,7 @@ send_to_holy_order_interaction = { # Refund piety cost show_as_tooltip = { - scope:actor = { + scope:puppet_or_actor = { add_piety_no_experience = { value = scope:recipient.ask_to_take_vows_piety_cost } @@ -3384,7 +4620,7 @@ send_to_holy_order_interaction = { has_variable = vows_piety_spent } } - scope:actor = { + scope:puppet_or_actor = { add_piety_no_experience = { value = scope:recipient.var:vows_piety_spent } @@ -3397,7 +4633,7 @@ send_to_holy_order_interaction = { # If we're a clan this interaction affects unity add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = minor_unity_loss DESC = clan_unity_join_holy_order_refusal.desc @@ -3410,14 +4646,29 @@ send_to_holy_order_interaction = { ai_accept = { base = 0 # Try to make it 0 for most interactions + celestial_hierarchy_acceptance_modifier = { + ACTOR = scope:puppet_or_actor + RECIPIENT = scope:recipient + } + modifier = { scope:hook = yes add = 50 desc = SCHEME_WEAK_HOOK_USED } + modifier = { + add = 50 + scope:demand = yes + desc = liege_demands_vow_taking + } + modifier = { + add = 25 + scope:puppet_or_actor = { has_character_modifier = pam_oblate_patron_modifier } + desc = pam_oblate_patron_reason + } opinion_modifier = { # Opinion Factor who = scope:recipient - opinion_target = scope:actor + opinion_target = scope:puppet_or_actor multiplier = 0.25 desc = AI_SIMPLE_OPINION_REASON } @@ -3462,16 +4713,16 @@ send_to_holy_order_interaction = { } modifier = { add = 50 - exists = scope:actor.cp:councillor_court_chaplain + exists = scope:puppet_or_actor.cp:councillor_court_chaplain scope:recipient = { OR = { - has_relation_lover = scope:actor.cp:councillor_court_chaplain - has_relation_friend = scope:actor.cp:councillor_court_chaplain - has_secret_relation_lover = scope:actor.cp:councillor_court_chaplain - has_relation_soulmate = scope:actor.cp:councillor_court_chaplain - has_relation_best_friend = scope:actor.cp:councillor_court_chaplain + has_relation_lover = scope:puppet_or_actor.cp:councillor_court_chaplain + has_relation_friend = scope:puppet_or_actor.cp:councillor_court_chaplain + has_secret_relation_lover = scope:puppet_or_actor.cp:councillor_court_chaplain + has_relation_soulmate = scope:puppet_or_actor.cp:councillor_court_chaplain + has_relation_best_friend = scope:puppet_or_actor.cp:councillor_court_chaplain opinion = { - target = scope:actor.cp:councillor_court_chaplain + target = scope:puppet_or_actor.cp:councillor_court_chaplain value >= very_high_positive_opinion } } @@ -3587,7 +4838,7 @@ send_to_holy_order_interaction = { modifier = { add = -150 scope:recipient = { - is_primary_heir_of = scope:actor + is_primary_heir_of = scope:puppet_or_actor } desc = TAKE_THE_VOWS_PRIMARY_HEIR } @@ -3596,10 +4847,10 @@ send_to_holy_order_interaction = { add = -75 scope:recipient = { NOT = { - is_primary_heir_of = scope:actor + is_primary_heir_of = scope:puppet_or_actor } } - scope:actor.primary_title = { + scope:puppet_or_actor.primary_title = { place_in_line_of_succession = { target = prev value = 2 @@ -3612,10 +4863,10 @@ send_to_holy_order_interaction = { add = -50 scope:recipient = { NOT = { - is_primary_heir_of = scope:actor + is_primary_heir_of = scope:puppet_or_actor } } - scope:actor.primary_title = { + scope:puppet_or_actor.primary_title = { place_in_line_of_succession = { target = prev value = 3 @@ -3628,10 +4879,10 @@ send_to_holy_order_interaction = { add = -25 scope:recipient = { NOT = { - is_primary_heir_of = scope:actor + is_primary_heir_of = scope:puppet_or_actor } } - scope:actor.primary_title = { + scope:puppet_or_actor.primary_title = { place_in_line_of_succession = { target = prev value >= 4 @@ -3644,13 +4895,13 @@ send_to_holy_order_interaction = { modifier = { add = -100 scope:recipient = { - NOT = { is_heir_of = scope:actor } + NOT = { is_heir_of = scope:puppet_or_actor } any_heir_title = { exists = holder - holder != scope:actor + holder != scope:puppet_or_actor } NOT = { - is_primary_heir_of = scope:actor + is_primary_heir_of = scope:puppet_or_actor } } desc = TAKE_THE_VOWS_HEIR_TO_OTHER_TITLE @@ -3659,7 +4910,7 @@ send_to_holy_order_interaction = { modifier = { add = -50 scope:recipient = { - NOT = { is_heir_of = scope:actor } + NOT = { is_heir_of = scope:puppet_or_actor } any_parent = { any_held_title = { place_in_line_of_succession = { @@ -3675,7 +4926,7 @@ send_to_holy_order_interaction = { } } NOT = { - is_primary_heir_of = scope:actor + is_primary_heir_of = scope:puppet_or_actor } } desc = TAKE_THE_VOWS_IN_LINE_TO_OTHER_TITLE @@ -3685,8 +4936,8 @@ send_to_holy_order_interaction = { desc = offer_vassalization_interaction_aibehavior_rival_tt trigger = { scope:recipient = { - has_relation_rival = scope:actor - NOT = { has_relation_nemesis = scope:actor } + has_relation_rival = scope:puppet_or_actor + NOT = { has_relation_nemesis = scope:puppet_or_actor } } } add = -50 @@ -3695,7 +4946,7 @@ send_to_holy_order_interaction = { desc = offer_vassalization_interaction_aibehavior_nemesis_tt trigger = { scope:recipient = { - has_relation_nemesis = scope:actor + has_relation_nemesis = scope:puppet_or_actor } } add = -100 @@ -3706,7 +4957,7 @@ send_to_holy_order_interaction = { add = intimidated_halved_reason_value scope:recipient = { has_dread_level_towards = { - target = scope:actor + target = scope:puppet_or_actor level = 1 } } @@ -3716,21 +4967,36 @@ send_to_holy_order_interaction = { add = cowed_halved_reason_value scope:recipient = { has_dread_level_towards = { - target = scope:actor + target = scope:puppet_or_actor level = 2 } } desc = COWED_REASON } + + # PAM - Concord Phase + modifier = { + add = 25 + situation:the_christian_church ?= { + any_participant_group = { # Both characters are involved in the situation + any_situation_group_participant = { + this = scope:puppet_or_actor + } + trigger_if = { + limit = { scope:recipient = { is_ruler = yes } } + any_situation_group_participant = { + this = scope:recipient + } + } + } + has_situation_top_phase_parameter = the_christian_church_better_take_the_vows_acceptance + } + desc = pam_the_christian_church_better_take_the_vows_acceptance_desc + } } # AI will do - ai_potential = { - is_adult = yes - piety >= major_piety_value - } - ai_target_quick_trigger = { adult = yes } @@ -3763,7 +5029,7 @@ send_to_holy_order_interaction = { modifier = { # Try to send rivals add = 100 - scope:actor = { + scope:puppet_or_actor = { OR = { has_relation_rival = scope:recipient has_relation_nemesis = scope:recipient @@ -3772,26 +5038,35 @@ send_to_holy_order_interaction = { } modifier = { # Try to send people who would make poor heirs - add = 50 + add = 20 scope:recipient = { OR = { - has_trait = murderer - has_trait = incestuous - has_trait = sodomite - has_trait = cannibal - has_trait = deviant - has_trait = kinslayer - has_trait = adulterer - has_trait = fornicator - has_trait = maimed + character_considered_morally_dubious_trigger = { RITE = scope:puppet_or_actor.rite } has_trait = drunkard has_trait = hashishiyah has_trait = flagellant has_trait = reclusive - num_of_bad_genetic_traits >= 1 + num_of_bad_genetic_traits = 1 + num_sinful_traits = 1 + } + scope:puppet_or_actor.primary_title = { + place_in_line_of_succession = { + target = prev + value <= 7 + } + } + } + } + modifier = { # Try to send people who would make terrible heirs + add = 50 + scope:recipient = { + OR = { + character_considered_wicked_trigger = { RITE = scope:puppet_or_actor.rite } + has_trait = maimed + num_of_bad_genetic_traits >= 2 num_sinful_traits >= 2 } - scope:actor.primary_title = { + scope:puppet_or_actor.primary_title = { place_in_line_of_succession = { target = prev value <= 7 @@ -3813,7 +5088,7 @@ send_to_holy_order_interaction = { intrigue < 8 learning < 8 } - scope:actor.primary_title = { + scope:puppet_or_actor.primary_title = { place_in_line_of_succession = { target = prev value <= 7 @@ -3824,7 +5099,7 @@ send_to_holy_order_interaction = { modifier = { # Sending one of your heirs is almost customary add = 100 - scope:actor = { + scope:puppet_or_actor = { any_child = { count >= 3 } @@ -3838,14 +5113,14 @@ send_to_holy_order_interaction = { } } scope:recipient = { - is_child_of = scope:actor + is_child_of = scope:puppet_or_actor has_education_martial_trigger = yes } } - modifier = { # Zealous characters generally want to send characters to the Holy Order + modifier = { # Zealous characters generally want to send characters to the Military Order add = 50 - scope:actor = { + scope:puppet_or_actor = { ai_zeal >= high_positive_ai_value } scope:recipient = { @@ -3855,19 +5130,40 @@ send_to_holy_order_interaction = { modifier = { # Greedy characters want to rid their court of potential threats add = 50 - scope:actor = { + scope:puppet_or_actor = { ai_greed >= medium_positive_ai_value any_child = { } } scope:recipient = { NOT = { - is_child_of = scope:actor + is_child_of = scope:puppet_or_actor } any_claim = { - holder ?= scope:actor + holder ?= scope:puppet_or_actor } } } + #No holy order allowing rulers of recipient's culture + modifier = { + NOT = { + faith = { + any_faith_holy_order = { + leader = { + government_has_flag = government_is_military_holy_order + OR = { + NOT = { + has_realm_law = cultural_holy_order_succession_law + } + culture = { + has_same_culture_heritage = scope:recipient.culture + } + } + } + } + } + } + factor = 0.2 + } modifier = { # The AI doesn't ask married/betrothed people factor = 0 @@ -3882,7 +5178,7 @@ send_to_holy_order_interaction = { modifier = { # Never ask Primary Heir factor = 0 scope:recipient = { - is_primary_heir_of = scope:actor + is_primary_heir_of = scope:puppet_or_actor } } @@ -3890,7 +5186,7 @@ send_to_holy_order_interaction = { factor = 0 scope:recipient = { NOT = { - is_close_or_extended_family_of = scope:actor + is_close_or_extended_family_of = scope:puppet_or_actor } } } @@ -3898,7 +5194,7 @@ send_to_holy_order_interaction = { } -#Ask to take the vows for a monastery +#Ask to take the vows to become a generic monk #by Linnéa Thimrén & Bianca Savazzi take_vows_interaction = { category = interaction_category_vassal @@ -3916,70 +5212,188 @@ take_vows_interaction = { desc = take_vows_interaction_desc - on_decline_summary = take_vows_decline_summary + on_decline_summary = { + triggered_desc = { + trigger = { NOT = { scope:actor = scope:puppet_or_actor } } + desc = take_vows_decline_summary_puppeteer + } + triggered_desc = { + trigger = { scope:actor = scope:puppet_or_actor } + desc = take_vows_decline_summary + } + } greeting = negative notification_text = REQUEST_VOWS_NOTIFICATION_TEXT + is_available = { + trigger_if = { + limit = { is_ai = yes } + piety >= major_piety_value + is_adult = yes + } + } + is_shown = { + #Only for when there are no monastic orders to send char to + scope:puppet_or_actor ?= { + faith ?= { + religious_head ?= scope:puppet_or_actor + NOT = { + any_faith_holy_order = { + take_the_vows_valid_monastic_order_trigger = { CHARACTER = scope:puppet_or_actor } + } + } + } + take_vows_available_trigger = yes + NOT = { + any_learning_councillor = { this = scope:recipient } + } + } scope:recipient = { - is_courtier_of = scope:actor + is_courtier_of = scope:puppet_or_actor NOR = { has_trait = devoted has_trait = order_member } } - NOT = { #Not your bishop - scope:actor = { - any_learning_councillor = { this = scope:recipient } - } - } - scope:actor = { - take_vows_available_trigger = yes # Faith has Monastery order that recipient can be sent to - } } is_valid_showing_failures_only = { + trigger_if = { + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + piety >= scope:recipient.ask_to_take_vows_piety_cost + } + } + trigger_if = { + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + dynasty ?= { dynasty_prestige >= take_vows_dynasty_prestige_cost_value } + } + } scope:recipient = { age >= 10 - is_courtier_of = scope:actor - can_take_religious_vows_trigger = yes #Triggers that applies to both Monastery or Holy Order requirements + is_courtier_of = scope:puppet_or_actor + can_take_religious_vows_trigger = yes #Triggers that applies to both Monastery or Military Order requirements } custom_tooltip = { text = cannot_take_overt_hostile_actions_against_diarch.tt - NOT = { scope:recipient ?= scope:actor.diarch } + NOT = { scope:recipient ?= scope:puppet_or_actor.diarch } + } + scope:puppet_or_actor = { + NOT = { + has_character_modifier = promised_pilgrimage_to_clergy_modifier + } } } #Use hook auto_accept = { - custom_description = { - text = "spending_hook" - subject = scope:actor - object = scope:recipient - scope:hook = yes - scope:actor = { has_strong_hook = scope:recipient } + trigger_if = { + limit = { scope:simony_paid_vows = yes } + custom_description = { + text = PAM_TAKE_VOWS_GOLD_AUTO_ACCEPT + object = scope:recipient + always = yes + } + } + trigger_else = { + custom_description = { + text = "spending_hook" + subject = scope:puppet_or_actor + object = scope:recipient + scope:hook = yes + scope:puppet_or_actor = { has_strong_hook = scope:recipient } + } } } send_option = { is_valid = { - scope:actor = { + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } flag = hook localization = SCHEME_HOOK } + #DEMAND that they take the vows + #TODO_PAM_JC TIT-69874 improvement jira to unlock this for AI and add logic. On other "join an order" type interactions as well + send_option = { + is_shown = { + scope:actor = { is_ai = no } + } + is_valid = { + scope:recipient.liege ?= scope:puppet_or_actor + scope:puppet_or_actor = { + custom_tooltip = { + text = parent_or_dynast_tt + OR = { + is_parent_of = scope:recipient + AND = { + exists = scope:puppet_or_actor.dynasty + is_dynast = yes + scope:recipient.dynasty ?= scope:puppet_or_actor.dynasty + } + } + } + } + } + flag = demand + localization = INTERACTION_DEMAND_VOWS + } + send_option = { + is_shown = { + scope:actor = { + is_ai = no + } + } + is_valid = { + custom_tooltip = { + text = PAM_TAKE_VOWS_GOLD_OPTION_REQUIRES_SIMONY + scope:puppet_or_actor = { + rite = { + rite_has_parameter = tenet_simony_paid_vows + } + } + } + scope:puppet_or_actor = { + gold >= major_gold_value + } + } + flag = simony_paid_vows + localization = PAM_TAKE_VOWS_GOLD_OPTION + } should_use_extra_icon = { - scope:actor = { has_usable_hook = scope:recipient } + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } extra_icon = "gfx/interface/icons/character_interactions/hook_icon.dds" send_options_exclusive = no cost = { - piety = scope:recipient.ask_to_take_vows_piety_cost + piety = { + value = scope:recipient.ask_to_take_vows_piety_cost + if = { + limit = { scope:is_puppet_action ?= yes } + multiply = 0 + } + } + renown = { + value = take_vows_dynasty_prestige_cost_value + if = { + limit = { scope:is_puppet_action ?= yes } + multiply = 0 + } + } + gold = { + value = 0 + if = { + limit = { scope:simony_paid_vows = yes } + add = scope:puppet_or_actor.major_gold_value + } + } } on_send = { @@ -3993,99 +5407,145 @@ take_vows_interaction = { } on_accept = { - scope:actor = { + if = { + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + add_piety = { + value = { + add = scope:recipient.ask_to_take_vows_piety_cost + max = piety + multiply = -1 + } + } + if = { + limit = { take_vows_dynasty_prestige_cost_value > 0 } + dynasty ?= { + add_dynasty_prestige = { + value = { + value = take_vows_dynasty_prestige_cost_value + multiply = -1 + } + } + } + } + } + } + scope:puppet_or_actor = { if = { limit = { scope:hook = yes } use_hook = scope:recipient } + #You demanded compliance as parent or dynasty head... you get it, but at a cost + if = { + limit = { + scope:demand = yes + } + scope:puppet_or_actor = { + show_as_tooltip = { + take_vows_demand_effect = yes + } + } + } + # Legitimacy loss if you're doing this to your children if = { limit = { - scope:recipient = { is_primary_heir_of = scope:actor } + has_legitimacy = yes + scope:recipient = { is_primary_heir_of = scope:puppet_or_actor } } - add_legitimacy = { - value = minor_legitimacy_loss - multiply = scope:actor.primary_title.tier + if = { + limit = { + hyperdulia_take_the_vows_trigger = yes + } + add_legitimacy = { + value = miniscule_legitimacy_gain + multiply = scope:puppet_or_actor.primary_title.tier + } + } + else = { + add_legitimacy = { + value = minor_legitimacy_loss + multiply = scope:puppet_or_actor.primary_title.tier + } } } else_if = { limit = { - scope:recipient = { is_child_of = scope:actor } has_legitimacy = yes + scope:recipient = { is_heir_of = scope:puppet_or_actor } + } + if = { + limit = { + hyperdulia_take_the_vows_trigger = yes + } + add_legitimacy = { + value = minor_legitimacy_gain + multiply = scope:puppet_or_actor.primary_title.tier + } + } + else = { + add_legitimacy = { + value = miniscule_legitimacy_loss + multiply = scope:puppet_or_actor.primary_title.tier + } + } + } + else_if = { + limit = { + has_legitimacy = yes + hyperdulia_take_the_vows_trigger = yes } add_legitimacy = { - value = miniscule_legitimacy_loss - multiply = scope:actor.primary_title.tier + value = medium_legitimacy_gain + multiply = scope:puppet_or_actor.primary_title.tier } } + if = { + limit = { scope:simony_paid_vows = yes } + scope:recipient = { + add_character_flag = { flag = pam_simony_paid_vows days = 1 } + } + } show_as_tooltip = { send_child_to_clergy_effect = yes } scope:recipient = { if = { limit = { - scope:actor.top_liege = { + scope:puppet_or_actor.top_liege = { any_vassal_or_below = { government_has_flag = government_is_theocracy primary_title.tier > tier_barony - faith = scope:actor.faith + faith = scope:puppet_or_actor.faith } } } - scope:actor.top_liege = { + scope:puppet_or_actor.top_liege = { random_vassal_or_below = { limit = { government_has_flag = government_is_theocracy primary_title.tier > tier_barony - faith = scope:actor.faith + faith = scope:puppet_or_actor.faith } save_scope_as = theocratic_travel_target } } - visit_court_of = scope:theocratic_travel_target + scope:theocratic_travel_target = { + add_courtier = scope:recipient + } } else_if = { limit = { - exists = scope:actor.capital_province + exists = scope:puppet_or_actor.capital_province } - move_to_pool_at = scope:actor.capital_province + move_to_pool_at = scope:puppet_or_actor.capital_province } kick_from_court_interaction_warning_tooltip_effect = yes } trigger_event = holy_order.0002 - if = { - limit = { - exists = cp:councillor_court_chaplain - scope:recipient = { - is_close_family_of = scope:actor - } - } - cp:councillor_court_chaplain = { - add_opinion = { - target = scope:actor - modifier = pious_opinion - opinion = 25 - } - } - } - if = { - limit = { - exists = faith.religious_head - faith.religious_head != scope:actor - scope:recipient = { - is_close_family_of = scope:actor - } - } - faith.religious_head = { - add_opinion = { - target = scope:actor - modifier = pious_opinion - opinion = 10 - } - } - } + take_vows_faith_opinion_effect = yes if = { limit = { house = { @@ -4108,7 +5568,7 @@ take_vows_interaction = { # If we're a clan this interaction affects unity add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = minor_unity_gain DESC = clan_unity_take_vows.desc @@ -4117,15 +5577,28 @@ take_vows_interaction = { } on_decline = { + scope:puppet_or_actor = { + #You demanded compliance as parent or dynasty head... you get it, but at a cost + if = { + limit = { + scope:demand = yes + } + scope:puppet_or_actor = { + show_as_tooltip = { + take_vows_demand_effect = yes + } + } + } + } scope:recipient = { add_opinion = { - target = scope:actor + target = scope:puppet_or_actor modifier = asked_me_to_take_vows_opinion years = 10 } } #Letter event informing the character about the rejection. - scope:actor = { + scope:puppet_or_actor = { trigger_event = { id = religious_interaction.1031 } @@ -4133,7 +5606,7 @@ take_vows_interaction = { # Refund piety cost show_as_tooltip = { - scope:actor = { + scope:puppet_or_actor = { add_piety_no_experience = { value = scope:recipient.ask_to_take_vows_piety_cost } @@ -4147,7 +5620,7 @@ take_vows_interaction = { has_variable = vows_piety_spent } } - scope:actor = { + scope:puppet_or_actor = { add_piety_no_experience = { value = scope:recipient.var:vows_piety_spent } @@ -4160,7 +5633,7 @@ take_vows_interaction = { # If we're a clan this interaction affects unity add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = minor_unity_loss DESC = clan_unity_refused_to_take_vows.desc @@ -4173,14 +5646,35 @@ take_vows_interaction = { ai_accept = { base = 0 # Try to make it 0 for most interactions + celestial_hierarchy_acceptance_modifier = { + ACTOR = scope:puppet_or_actor + RECIPIENT = scope:recipient + } + modifier = { scope:hook = yes add = 50 desc = SCHEME_WEAK_HOOK_USED } + modifier = { + add = 50 + scope:demand = yes + desc = liege_demands_vow_taking + } + modifier = { + add = 25 + scope:puppet_or_actor = { has_character_modifier = pam_oblate_patron_modifier } + desc = pam_oblate_patron_reason + } + + modifier = { # Has cloister + scope:puppet_or_actor.domicile ?= { has_domicile_parameter = estate_cloister_take_vows } + add = { value = scope:puppet_or_actor.learning add = scope:puppet_or_actor.diplomacy multiply = 0.5 } + desc = estate_cloister_take_vows_reason + } opinion_modifier = { # Opinion Factor who = scope:recipient - opinion_target = scope:actor + opinion_target = scope:puppet_or_actor multiplier = 0.25 desc = AI_SIMPLE_OPINION_REASON } @@ -4205,6 +5699,22 @@ take_vows_interaction = { ai_greed > 0 desc = TAKE_THE_VOWS_GREED } + modifier = { + add = { + value = ai_boldness + multiply = -1 + } + ai_boldness < 0 + desc = TAKE_THE_VOWS_COWARDLINESS + } + modifier = { + add = { + value = ai_boldness + multiply = -0.5 + } + ai_boldness > 0 + desc = TAKE_THE_VOWS_BOLDNESS + } modifier = { add = 50 scope:recipient = { @@ -4220,16 +5730,16 @@ take_vows_interaction = { } modifier = { add = 50 - exists = scope:actor.cp:councillor_court_chaplain + exists = scope:puppet_or_actor.cp:councillor_court_chaplain scope:recipient = { OR = { - has_relation_lover = scope:actor.cp:councillor_court_chaplain - has_relation_friend = scope:actor.cp:councillor_court_chaplain - has_secret_relation_lover = scope:actor.cp:councillor_court_chaplain - has_relation_soulmate = scope:actor.cp:councillor_court_chaplain - has_relation_best_friend = scope:actor.cp:councillor_court_chaplain + has_relation_lover = scope:puppet_or_actor.cp:councillor_court_chaplain + has_relation_friend = scope:puppet_or_actor.cp:councillor_court_chaplain + has_secret_relation_lover = scope:puppet_or_actor.cp:councillor_court_chaplain + has_relation_soulmate = scope:puppet_or_actor.cp:councillor_court_chaplain + has_relation_best_friend = scope:puppet_or_actor.cp:councillor_court_chaplain opinion = { - target = scope:actor.cp:councillor_court_chaplain + target = scope:puppet_or_actor.cp:councillor_court_chaplain value >= very_high_positive_opinion } } @@ -4262,7 +5772,7 @@ take_vows_interaction = { } any_secret = { type = secret_lover - secret_target = { + secret_target = { is_clergy = yes } } @@ -4339,9 +5849,9 @@ take_vows_interaction = { modifier = { # Loves books & knowledge! add = 20 scope:recipient = { - has_trait = scholar + has_trait = erudite } - desc = TAKE_THE_VOWS_SCHOLAR + desc = TAKE_THE_VOWS_ERUDITE } modifier = { # Loves books & knowledge! add = 20 @@ -4365,14 +5875,14 @@ take_vows_interaction = { desc = TAKE_THE_VOWS_TEMPERATE } modifier = { - add = 50 + add = 100 scope:recipient = { has_trait = celibate } desc = TAKE_THE_VOWS_CELIBATE } modifier = { - add = 25 + add = 40 scope:recipient = { has_trait = chaste } @@ -4472,7 +5982,7 @@ take_vows_interaction = { modifier = { add = -150 scope:recipient = { - is_primary_heir_of = scope:actor + is_primary_heir_of = scope:puppet_or_actor } desc = TAKE_THE_VOWS_PRIMARY_HEIR } @@ -4481,10 +5991,10 @@ take_vows_interaction = { add = -75 scope:recipient = { NOT = { - is_primary_heir_of = scope:actor + is_primary_heir_of = scope:puppet_or_actor } } - scope:actor.primary_title = { + scope:puppet_or_actor.primary_title = { place_in_line_of_succession = { target = prev value = 2 @@ -4497,10 +6007,10 @@ take_vows_interaction = { add = -50 scope:recipient = { NOT = { - is_primary_heir_of = scope:actor + is_primary_heir_of = scope:puppet_or_actor } } - scope:actor.primary_title = { + scope:puppet_or_actor.primary_title = { place_in_line_of_succession = { target = prev value = 3 @@ -4513,10 +6023,10 @@ take_vows_interaction = { add = -25 scope:recipient = { NOT = { - is_primary_heir_of = scope:actor + is_primary_heir_of = scope:puppet_or_actor } } - scope:actor.primary_title = { + scope:puppet_or_actor.primary_title = { place_in_line_of_succession = { target = prev value >= 4 @@ -4529,13 +6039,13 @@ take_vows_interaction = { modifier = { add = -100 scope:recipient = { - NOT = { is_heir_of = scope:actor } + NOT = { is_heir_of = scope:puppet_or_actor } any_heir_title = { exists = holder - holder != scope:actor + holder != scope:puppet_or_actor } NOT = { - is_primary_heir_of = scope:actor + is_primary_heir_of = scope:puppet_or_actor } } desc = TAKE_THE_VOWS_HEIR_TO_OTHER_TITLE @@ -4544,7 +6054,7 @@ take_vows_interaction = { modifier = { add = -50 scope:recipient = { - NOT = { is_heir_of = scope:actor } + NOT = { is_heir_of = scope:puppet_or_actor } any_parent = { any_held_title = { place_in_line_of_succession = { @@ -4560,7 +6070,7 @@ take_vows_interaction = { } } NOT = { - is_primary_heir_of = scope:actor + is_primary_heir_of = scope:puppet_or_actor } } desc = TAKE_THE_VOWS_IN_LINE_TO_OTHER_TITLE @@ -4570,8 +6080,8 @@ take_vows_interaction = { desc = offer_vassalization_interaction_aibehavior_rival_tt trigger = { scope:recipient = { - has_relation_rival = scope:actor - NOT = { has_relation_nemesis = scope:actor } + has_relation_rival = scope:puppet_or_actor + NOT = { has_relation_nemesis = scope:puppet_or_actor } } } add = -50 @@ -4580,7 +6090,7 @@ take_vows_interaction = { desc = offer_vassalization_interaction_aibehavior_nemesis_tt trigger = { scope:recipient = { - has_relation_nemesis = scope:actor + has_relation_nemesis = scope:puppet_or_actor } } add = -100 @@ -4591,7 +6101,7 @@ take_vows_interaction = { add = 25 scope:recipient = { has_dread_level_towards = { - target = scope:actor + target = scope:puppet_or_actor level = 1 } } @@ -4601,7 +6111,7 @@ take_vows_interaction = { add = 50 scope:recipient = { has_dread_level_towards = { - target = scope:actor + target = scope:puppet_or_actor level = 2 } } @@ -4617,24 +6127,39 @@ take_vows_interaction = { limit = { scope:recipient = { is_adult = no - is_child_of = scope:actor + is_child_of = scope:puppet_or_actor } } add = 100 } } - scope:actor.culture = { has_cultural_parameter = monastic_expectations } + scope:puppet_or_actor.culture = { has_cultural_parameter = monastic_expectations } desc = MONASTIC_EXPECTATIONS_REASON } + + # PAM - Concord Phase + modifier = { + add = 25 + situation:the_christian_church ?= { + any_participant_group = { # Both characters are involved in the situation + any_situation_group_participant = { + this = scope:puppet_or_actor + } + trigger_if = { + limit = { scope:recipient = { is_ruler = yes } } + any_situation_group_participant = { + this = scope:recipient + } + } + } + has_situation_top_phase_parameter = the_christian_church_better_take_the_vows_acceptance + } + desc = pam_the_christian_church_better_take_the_vows_acceptance_desc + } } # AI will do - ai_potential = { - is_adult = yes - piety >= major_piety_value - } - ai_target_quick_trigger = { adult = yes } @@ -4662,13 +6187,13 @@ take_vows_interaction = { modifier = { add = -50 - scope:actor = { + scope:puppet_or_actor = { OR = { legitimacy_level = 0 legitimacy_level = 1 } } - scope:recipient = { is_primary_heir_of = scope:actor } + scope:recipient = { is_primary_heir_of = scope:puppet_or_actor } } modifier = { # The AI will always use a Hook @@ -4678,7 +6203,7 @@ take_vows_interaction = { modifier = { # Try to send rivals add = 100 - scope:actor = { + scope:puppet_or_actor = { OR = { has_relation_rival = scope:recipient has_relation_nemesis = scope:recipient @@ -4687,26 +6212,35 @@ take_vows_interaction = { } modifier = { # Try to send people who would make poor heirs - add = 50 + add = 20 scope:recipient = { OR = { - has_trait = murderer - has_trait = incestuous - has_trait = sodomite - has_trait = cannibal - has_trait = deviant - has_trait = kinslayer - has_trait = adulterer - has_trait = fornicator - has_trait = maimed + character_considered_morally_dubious_trigger = { RITE = scope:puppet_or_actor.rite } has_trait = drunkard has_trait = hashishiyah has_trait = flagellant has_trait = reclusive - num_of_bad_genetic_traits >= 1 + num_of_bad_genetic_traits = 1 + num_sinful_traits = 1 + } + scope:puppet_or_actor.primary_title = { + place_in_line_of_succession = { + target = prev + value <= 7 + } + } + } + } + modifier = { # Try to send people who would make terrible heirs + add = 50 + scope:recipient = { + OR = { + character_considered_wicked_trigger = { RITE = scope:puppet_or_actor.rite } + has_trait = maimed + num_of_bad_genetic_traits >= 2 num_sinful_traits >= 2 } - scope:actor.primary_title = { + scope:puppet_or_actor.primary_title = { place_in_line_of_succession = { target = prev value <= 7 @@ -4728,7 +6262,7 @@ take_vows_interaction = { intrigue < 8 learning < 8 } - scope:actor.primary_title = { + scope:puppet_or_actor.primary_title = { place_in_line_of_succession = { target = prev value <= 7 @@ -4739,7 +6273,7 @@ take_vows_interaction = { modifier = { # Sending one of your heirs is almost customary add = 100 - scope:actor = { + scope:puppet_or_actor = { any_child = { count >= 3 } @@ -4753,14 +6287,14 @@ take_vows_interaction = { } } scope:recipient = { - is_child_of = scope:actor + is_child_of = scope:puppet_or_actor has_education_learning_trigger = yes } } modifier = { # Zealous characters generally want to send characters to the clergy add = 50 - scope:actor = { + scope:puppet_or_actor = { ai_zeal >= high_positive_ai_value } scope:recipient = { @@ -4770,16 +6304,16 @@ take_vows_interaction = { modifier = { # Greedy characters want to rid their court of potential threats add = 50 - scope:actor = { + scope:puppet_or_actor = { ai_greed >= medium_positive_ai_value any_child = { } } scope:recipient = { NOT = { - is_child_of = scope:actor + is_child_of = scope:puppet_or_actor } any_claim = { - holder ?= scope:actor + holder ?= scope:puppet_or_actor } } } @@ -4797,7 +6331,7 @@ take_vows_interaction = { modifier = { # Never ask Primary Heir factor = 0 scope:recipient = { - is_primary_heir_of = scope:actor + is_primary_heir_of = scope:puppet_or_actor } } @@ -4805,7 +6339,7 @@ take_vows_interaction = { factor = 0 scope:recipient = { NOT = { - is_close_or_extended_family_of = scope:actor + is_close_or_extended_family_of = scope:puppet_or_actor } } } @@ -4829,7 +6363,7 @@ temporal_condemnation_interaction = { desc = { first_valid = { triggered_desc = { - trigger = { scope:actor.faith = faith:quranist } + trigger = { scope:puppet_or_actor.faith = faith:quranist } desc = temporal_condemnation_interaction_desc_fasiq } desc = temporal_condemnation_interaction_desc @@ -4838,54 +6372,27 @@ temporal_condemnation_interaction = { icon = religious is_shown = { - scope:actor != scope:recipient - scope:actor.faith = { - has_doctrine_parameter = temporal_condemnation_enabled - } - scope:recipient = { - liege = scope:actor + scope:puppet_or_actor != scope:recipient + scope:puppet_or_actor.rite ?= { + rite_has_parameter = temporal_condemnation_enabled } scope:recipient = { + liege ?= scope:puppet_or_actor is_playable_character = yes + is_ruler = yes } } cooldown = { years = 5 } is_valid = { - scope:actor = { + scope:puppet_or_actor = { piety >= medium_piety_value } - custom_description = { - text = temporal_condemnation_learning_requirement - subject = scope:actor - object = scope:recipient - value = religious_legal_pronouncement_learning_requirement - religious_legal_pronouncement_requirements >= 0 - scope:actor = { learning >= 1 } - } } is_valid_showing_failures_only = { - scope:recipient.religion = scope:actor.religion - custom_description = { - text = temporal_condemnation_is_not_sinful - object = scope:recipient - scope:recipient = { - num_sinful_traits = { value > 0 target = scope:actor.faith } - } - } - trigger_if = { - limit = { - scope:recipient.num_sinful_traits > 0 - scope:actor.num_sinful_traits > 0 - } - custom_description = { - text = temporal_condemnation_less_sinful_than_me - object = scope:recipient - scope:actor.num_sinful_traits < scope:recipient.num_sinful_traits - } - } + scope:recipient.religion = scope:puppet_or_actor.religion custom_description = { text = temporal_condemnation_has_been_condemned object = scope:recipient @@ -4896,15 +6403,15 @@ temporal_condemnation_interaction = { } } NAND = { - exists = scope:actor.faith.great_holy_war - scope:actor.faith.great_holy_war = { + exists = scope:puppet_or_actor.faith.great_holy_war + scope:puppet_or_actor.faith.great_holy_war = { has_pledged_attacker = scope:recipient } } scope:recipient = { is_adult = yes } - scope:recipient = { NOT = { has_strong_hook = scope:actor } } + scope:recipient = { NOT = { has_strong_hook = scope:puppet_or_actor } } } auto_accept = yes @@ -4912,44 +6419,126 @@ temporal_condemnation_interaction = { notification_text = temporal_condemnation_interaction.notification on_accept = { - scope:actor = { + scope:puppet_or_actor = { add_piety = medium_piety_loss - add_opinion = { - target = scope:recipient - modifier = temporal_condemnation_opinion - years = 10 - } - custom_tooltip = temporal_condemnation_revoke_reason - hidden_effect = { - send_interface_toast = { - type = event_toast_effect_good - title = temporal_condemnation_interaction.tt - left_icon = scope:recipient - show_as_tooltip = { custom_tooltip = temporal_condemnation_got_revoke_reason } - } - } - stress_impact = { - cynical = minor_stress_impact_gain - } - } - scope:recipient = { - add_character_modifier = { - modifier = temporal_condemnation_modifier - years = 15 - } - add_opinion = { - target = scope:actor - modifier = temporal_condemnation_condemned_me_opinion - } } - # If we're a clan this interaction affects unity - add_clan_unity_interaction_effect = { - CHARACTER = scope:actor - TARGET = scope:recipient - VALUE = medium_unity_gain - DESC = clan_unity_condemn_sins.desc - REVERSE_NON_HOUSE_TARGET = no + scope:puppet_or_actor = { + duel = { + skill = learning + value = religious_legal_pronouncement_learning_requirement + 50 = { + desc = temporal_condemnation_interaction_success + compare_modifier = { + value = scope:duel_value + multiplier = 3 + min = -45 + } + modifier = { + add = 25 + scope:puppet_or_actor = { + has_personal_tenet_flag = tenet_religious_law_condemnation_bonus + } + } + scope:puppet_or_actor = { + add_opinion = { + target = scope:recipient + modifier = temporal_condemnation_opinion + years = 10 + } + custom_tooltip = temporal_condemnation_revoke_reason + hidden_effect = { + send_interface_toast = { + type = event_toast_effect_good + title = temporal_condemnation_interaction.tt + left_icon = scope:recipient + show_as_tooltip = { custom_tooltip = temporal_condemnation_got_revoke_reason } + if = { + limit = { + has_personal_tenet_flag = tenet_religious_law_scholar_trait + } + add_trait_xp = { + trait = lifestyle_scholar + value = 20 + } + } + } + } + stress_and_fulfillment_impact = { + cynical = minor_stress_impact_gain + } + } + if = { + limit = { + scope:is_puppet_action ?= yes + scope:actor != scope:recipient + } + scope:actor = { + send_interface_toast = { + type = event_toast_effect_good + title = temporal_condemnation_interaction.tt_puppeteer + left_icon = scope:puppet_or_actor + right_icon = scope:recipient + } + } + } + scope:recipient = { + add_character_modifier = { + modifier = temporal_condemnation_modifier + years = 15 + } + add_opinion = { + target = scope:puppet_or_actor + modifier = temporal_condemnation_condemned_me_opinion + } + send_interface_toast = { + type = event_toast_effect_bad + title = temporal_condemnation_interaction.recipient_success + left_icon = scope:puppet_or_actor + custom_tooltip = temporal_condemnation_interaction.recipient_success_desc + } + } + + # If we're a clan this interaction affects unity + add_clan_unity_interaction_effect = { + CHARACTER = scope:puppet_or_actor + TARGET = scope:recipient + VALUE = medium_unity_gain + DESC = clan_unity_condemn_sins.desc + REVERSE_NON_HOUSE_TARGET = no + } + } + 50 = { + desc = temporal_condemnation_interaction_failure + compare_modifier = { + value = scope:duel_value + multiplier = -3 + min = -45 + } + scope:puppet_or_actor = { + send_interface_toast = { + type = event_toast_effect_bad + title = temporal_condemnation_interaction.failure + left_icon = scope:recipient + custom_tooltip = temporal_condemnation_interaction.failure_desc + } + } + if = { + limit = { + scope:is_puppet_action ?= yes + scope:actor != scope:recipient + } + scope:actor = { + send_interface_toast = { + type = event_toast_effect_bad + title = temporal_condemnation_interaction.failure + left_icon = scope:recipient + custom_tooltip = temporal_condemnation_interaction.failure_desc + } + } + } + } + } } } } @@ -4982,14 +6571,21 @@ host_honored_guest_interaction = { cooldown = { years = 1 } + is_available = { + trigger_if = { + limit = { is_ai = yes } + piety >= major_piety_value + } + } + is_shown = { - scope:recipient != scope:actor - scope:actor = { + scope:recipient != scope:puppet_or_actor + scope:puppet_or_actor ?= { + rite ?= { + rite_has_parameter = host_honored_guests_active + } is_playable_character = yes is_adult = yes - faith = { - has_doctrine_parameter = host_honored_guests_active - } } } @@ -5000,9 +6596,9 @@ host_honored_guest_interaction = { object = scope:recipient NOT = { scope:recipient = { - faith = { - faith_hostility_level = { - target = scope:actor.faith + rite = { + rite_hostility_level = { + target = scope:puppet_or_actor.rite value = faith_hostile_level } } @@ -5015,9 +6611,9 @@ host_honored_guest_interaction = { object = scope:recipient NOT = { scope:recipient = { - faith = { - faith_hostility_level = { - target = scope:actor.faith + rite = { + rite_hostility_level = { + target = scope:puppet_or_actor.rite value = faith_evil_level } } @@ -5053,7 +6649,7 @@ host_honored_guest_interaction = { text = host_honored_guest_is_at_war object = scope:recipient scope:recipient = { - NOT = { is_at_war_with = scope:actor } + NOT = { is_at_war_with = scope:puppet_or_actor } } } # Is my courtier @@ -5061,7 +6657,7 @@ host_honored_guest_interaction = { text = host_honored_guest_is_my_courtier object = scope:recipient scope:recipient = { - NOT = { is_courtier_of = scope:actor } + NOT = { is_courtier_of = scope:puppet_or_actor } } } } @@ -5072,8 +6668,8 @@ host_honored_guest_interaction = { #answer_accept_key = host_honored_guest_interaction.response on_accept = { - scope:actor = { - stress_impact = { + scope:puppet_or_actor = { + stress_and_fulfillment_impact = { cynical = minor_stress_impact_gain shy = minor_stress_impact_gain } @@ -5083,47 +6679,21 @@ host_honored_guest_interaction = { send_interface_toast = { type = event_toast_effect_good title = host_honored_guest_interaction_recipient.notification - left_icon = scope:actor + left_icon = scope:puppet_or_actor } } # Spend piety based on recipient's tier. - if = { - limit = { - highest_held_title_tier <= tier_county - } - scope:actor = { - add_piety = minor_piety_loss - } - } - else_if = { - limit = { - highest_held_title_tier = tier_duchy - } - scope:actor = { - add_piety = medium_piety_loss - } - } - else_if = { - limit = { - highest_held_title_tier = tier_kingdom - } - scope:actor = { - add_piety = major_piety_loss - } - } - else_if = { - limit = { - highest_held_title_tier = tier_empire - } - scope:actor = { - add_piety = massive_piety_loss + scope:puppet_or_actor = { + add_piety = { + value = 0 + subtract = scope:recipient.tier_scaled_piety_value } } # Increase opinion of recipient. add_opinion = { modifier = pleased_opinion - target = scope:actor + target = scope:puppet_or_actor opinion = { value = 20 @@ -5131,7 +6701,7 @@ host_honored_guest_interaction = { if = { limit = { has_trait = zealous - faith = scope:actor.faith + faith = scope:puppet_or_actor.faith } add = 10 } @@ -5141,8 +6711,8 @@ host_honored_guest_interaction = { OR = { has_trait = cynical NOT = { - faith = { - has_doctrine_parameter = host_honored_guests_active + rite = { + rite_has_parameter = host_honored_guests_active } } } @@ -5163,7 +6733,7 @@ host_honored_guest_interaction = { # If we're a clan this interaction affects unity add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = miniscule_unity_gain DESC = clan_unity_honored_guest.desc @@ -5171,10 +6741,6 @@ host_honored_guest_interaction = { } } - ai_potential = { - piety >= major_piety_value - } - ai_will_do = { base = 0 @@ -5182,11 +6748,11 @@ host_honored_guest_interaction = { add = 100 scope:recipient = { OR = { - is_powerful_vassal_of = scope:actor + is_powerful_vassal_of = scope:puppet_or_actor liege = root } opinion = { - target = scope:actor + target = scope:puppet_or_actor value = {-15 0 } } } @@ -5196,11 +6762,11 @@ host_honored_guest_interaction = { add = 75 scope:recipient = { OR = { - is_powerful_vassal_of = scope:actor + is_powerful_vassal_of = scope:puppet_or_actor liege = root } opinion = { - target = scope:actor + target = scope:puppet_or_actor value = { 0 20 } } } @@ -5210,11 +6776,11 @@ host_honored_guest_interaction = { add = 40 scope:recipient = { OR = { - is_powerful_vassal_of = scope:actor + is_powerful_vassal_of = scope:puppet_or_actor liege = root } opinion = { - target = scope:actor + target = scope:puppet_or_actor value = { 20 60 } } } @@ -5224,11 +6790,11 @@ host_honored_guest_interaction = { add = 10 scope:recipient = { OR = { - is_powerful_vassal_of = scope:actor + is_powerful_vassal_of = scope:puppet_or_actor liege = root } opinion = { - target = scope:actor + target = scope:puppet_or_actor value = { 60 100 } } } @@ -5239,13 +6805,21 @@ host_honored_guest_interaction = { # Spiritual Head of Faith Actions hof_ask_for_gold_interaction = { - icon = icon_gold + icon = icon_clergy_ask_money category = interaction_category_religion + common_interaction = yes desc = hof_ask_for_gold_interaction_desc + notification_text = RECIPIENT_HOF_ASK_FOR_GOLD + ai_targets = { ai_recipients = head_of_faith + ai_recipients = religious_head_challenger + ai_recipients = realm_priest_superior + ai_recipients = superior + ai_recipients = realm_priest_top_superior + ai_recipients = councillors } ai_target_quick_trigger = { adult = yes @@ -5261,38 +6835,96 @@ hof_ask_for_gold_interaction = { cooldown_against_recipient = { years = 3 } - is_shown = { - scope:recipient != scope:actor - scope:actor.faith = { - religious_head = scope:recipient - has_doctrine = doctrine_spiritual_head - } + redirect = { scope:actor = { + spiritual_hof_or_realm_priest_superior_recipient_redirect_effect = yes + } + } + + is_available = { + trigger_if = { + limit = { + is_ai = yes + } + piety >= major_piety_value + NOR = { + has_trait = excommunicated + has_character_flag = hof_request_cooldown + } + OR = { + is_landed = yes + government_has_mechanic = theocracy + } + } + } + + is_shown = { + scope:recipient != scope:puppet_or_actor + scope:puppet_or_actor ?= { + faith ?= { + OR = { + has_doctrine = doctrine_spiritual_head + has_doctrine_parameter = has_clerical_regions + } + } is_playable_character = yes + NOT = { + # Ecclesiasticals have the 'request_ecclesiastical_treasury_interaction' instead + government_has_flag = government_is_ecclesiastical + } + broader_clergy_show_hof_or_superior_interactions_trigger = yes + } + scope:recipient = { + faith = scope:puppet_or_actor.faith + # Antipope uses petition_antipope_gold_interaction instead + trigger_if = { + limit = { has_pam_dlc_trigger = yes } + pam_is_antipope_trigger = no + } + } + # Those under an antipope ask them for gold instead of the real Head of Faith + trigger_if = { + limit = { + scope:recipient ?= scope:puppet_or_actor.faith.religious_head + } + scope:puppet_or_actor ?= { is_following_religious_head_challenger = no } } } is_valid_showing_failures_only = { scope:recipient = { - gold >= scope:actor.head_of_faith_gold_value + trigger_if = { + limit = { + has_treasury = yes + } + treasury >= hof_ask_for_gold_request_value + } + trigger_else = { + gold >= hof_ask_for_gold_request_value + } } + scope:actor = { + spiritual_hof_or_realm_priest_superior_recipient_trigger = yes piety >= major_piety_value - custom_description = { - text = "hof_ask_for_gold_excommunicated" - NOT = { has_trait = excommunicated } + trigger_if = { + limit = { + has_pam_dlc_trigger = yes + } + clergy_interaction_generic_piety_level_or_puppet_req_trigger = yes } - NOT = { + NOR = { + has_trait = excommunicated is_at_war_with = scope:recipient + has_character_modifier = promised_pilgrimage_to_clergy_modifier } - } - scope:actor = { - custom_description = { - text = "hof_interaction_unreformed_faith" + custom_tooltip = { + text = HOF_INTERACTION_UNREFORMED_FAITH NOT = { faith = { has_doctrine_parameter = unreformed } } } + pam_antipope_clerical_request_trigger = { RECIPIENT = scope:recipient } } } @@ -5310,323 +6942,9 @@ hof_ask_for_gold_interaction = { ai_accept = { base = -40 - compare_modifier = { - value = scope:recipient.gold - trigger = { - scope:recipient.gold > 2500 - } - offset = -2500 - multiplier = 0.1 - max = 50 - desc = ASK_FOR_GOLD_OVERFLOWING_COFFERS - } - - opinion_modifier = { - opinion_target = scope:actor - who = scope:recipient - multiplier = 0.5 - } - - modifier = { # Same language - add = 5 - desc = speaks_same_language_interaction_reason - trigger = { - scope:actor = { - knows_language_of_culture = scope:recipient.culture - } - } - } - - modifier = { # Attacking a co-religionist - add = -50 - desc = I_AM_ATTACKING_A_CORELIGIONIST - scope:actor = { - is_at_war = yes - any_character_war = { - primary_attacker = scope:actor - primary_defender.faith = scope:actor.faith - primary_defender = { - NOT = { - has_trait = excommunicated - } - } - } - } - } - - modifier = { # Offensive holy war/excommunication war - add = 30 - desc = I_AM_WAGING_AN_OFFENSIVE_HOLY_OR_EXCOMMUNICATION_WAR - scope:actor = { - is_at_war = yes - any_character_war = { - is_attacker = scope:actor - OR = { - using_non_ghw_holy_war_cb_trigger = yes - using_cb = excommunication_war - } - } - } - } - - modifier = { # Defensive Holy War - add = 50 - desc = I_AM_DEFENDING_AGAINST_A_HOLY_WAR - scope:actor = { - is_at_war = yes - any_character_war = { - is_defender = scope:actor - using_non_ghw_holy_war_cb_trigger = yes - } - } - } - - modifier = { # HoF wants the money for themselves! - add = -20 - desc = THEY_ARE_GREEDY - scope:recipient = { - ai_greed >= high_positive_greed - } - } - - modifier = { # I am rich already - add = -25 - desc = I_AM_RICH - scope:actor = { - gold >= scope:actor.medium_treasury_value - NOT = { - gold >= scope:actor.major_treasury_value - } - } - } - - modifier = { # I am rich already - add = -50 - desc = I_AM_RICH - scope:actor = { - gold >= scope:actor.major_treasury_value - NOT = { - gold >= scope:actor.massive_treasury_value - } - } - } - - modifier = { # I am very rich already - add = -75 - desc = I_AM_RICH - scope:actor = { - gold >= scope:actor.massive_treasury_value - } - } - - modifier = { # I am Adulterer/Fornicator - add = -25 - desc = I_AM_ADULTERER - scope:actor = { - OR = { - AND = { - has_trait = fornicator - trait_is_shunned_or_criminal_in_faith_trigger = { FAITH = faith TRAIT = trait:fornicator GENDER_CHARACTER = scope:actor } - } - AND = { - has_trait = adulterer - trait_is_shunned_or_criminal_in_faith_trigger = { FAITH = faith TRAIT = trait:adulterer GENDER_CHARACTER = scope:actor } - } - } - } - } - - modifier = { # I am a Murderer - add = -50 - desc = I_AM_MURDERER - scope:actor = { - has_trait = murderer - } - } - - modifier = { # I am Incestous - add = -50 - desc = I_AM_INCESTOUS - scope:actor = { - NOT = { scope:recipient = { faith = { has_doctrine = doctrine_consanguinity_unrestricted } } } - has_trait = incestuous - } - } - - modifier = { # I am a Kinslayer - add = -50 - desc = I_AM_A_KINSLAYER - scope:actor = { - OR = { - AND = { - has_trait = kinslayer_1 - trait_is_shunned_or_criminal_in_faith_trigger = { FAITH = faith TRAIT = trait:kinslayer_1 GENDER_CHARACTER = scope:actor } - } - AND = { - has_trait = kinslayer_2 - trait_is_shunned_or_criminal_in_faith_trigger = { FAITH = faith TRAIT = trait:kinslayer_2 GENDER_CHARACTER = scope:actor } - } - AND = { - has_trait = kinslayer_3 - trait_is_shunned_or_criminal_in_faith_trigger = { FAITH = faith TRAIT = trait:kinslayer_3 GENDER_CHARACTER = scope:actor } - } - } - } - } - modifier = { - desc = RELIGIOUS_HEAD_INTERACTION_SAVIOR - add = 15 - scope:actor = { - has_trait = savior - } - } - modifier = { - desc = RELIGIOUS_HEAD_INTERACTION_DIVINE_BLOOD - add = 5 - scope:actor = { - has_trait = divine_blood - } - } - modifier = { - desc = RELIGIOUS_HEAD_INTERACTION_PARAGON - add = 15 - scope:actor = { - has_trait = paragon - } - } - modifier = { - desc = RELIGIOUS_HEAD_INTERACTION_CONSECRATED_BLOOD - add = 5 - scope:actor = { - has_trait = consecrated_blood - } - } - - modifier = { # You are of the same dynasty as the Head of Faith - add = 5 - desc = YOU_ARE_MY_DYNASTY_MEMBER - scope:recipient = { - is_lowborn = no - dynasty = scope:actor.dynasty - NOR = { - is_close_or_extended_family_of = scope:actor - is_cousin_of = scope:actor - is_child_of = scope:actor - scope:recipient.dynasty = scope:secondary_recipient.dynasty - } - } - } - - modifier = { # You are of the same house as the Head of Faith - add = 10 - desc = YOU_ARE_MY_HOUSE_MEMBER - scope:recipient = { - is_lowborn = no - house = scope:actor.house - NOR = { - is_close_or_extended_family_of = scope:actor - is_cousin_of = scope:actor - is_child_of = scope:actor - scope:recipient.house = scope:secondary_recipient.house - } - } - } - - modifier = { # Related to the Head of Faith - add = 10 - desc = YOU_ARE_MY_RELATIVE - scope:recipient = { - OR = { - is_close_or_extended_family_of = scope:actor - is_cousin_of = scope:actor - } - NOT = { is_child_of = scope:actor } - } - } - - modifier = { # Parent of the Head of Faith - add = 25 - desc = YOU_ARE_MY_PARENT - scope:recipient = { - is_child_of = scope:actor - } - } - - modifier = { # Friend of the Head of Faith - add = 25 - desc = WE_ARE_FRIENDS - scope:recipient = { - has_relation_friend = scope:actor - } - } - - modifier = { # Best Friend of the Head of Faith - add = 50 - desc = WE_ARE_BEST_FRIENDS - scope:recipient = { - has_relation_best_friend = scope:actor - } - } - - modifier = { # Lover of the Head of Faith - add = 10 - desc = WE_ARE_LOVERS - scope:recipient = { - has_relation_lover = scope:actor - } - } - - modifier = { # Rival of the Head of Faith - add = -100 - desc = WE_ARE_RIVALS - scope:recipient = { - has_relation_rival = scope:actor - } - } - - modifier = { # Nemesis of the Head of Faith - add = -500 - desc = WE_ARE_NEMESES - scope:recipient = { - has_relation_nemesis = scope:actor - } - } - - modifier = { - add = { - add = 10 - multiply = scope:actor.num_virtuous_traits - } - scope:actor.num_virtuous_traits > 0 - desc = I_AM_VIRTUOUS - } - - modifier = { - add = { - add = 5 - multiply = scope:actor.piety_level - } - scope:actor.piety_level > 1 - desc = I_AM_PIOUS - } - - modifier = { - add = { - add = 5 - multiply = scope:actor.piety_level - } - scope:actor.piety_level > 2 - scope:actor.gold < 0 - desc = I_AM_PIOUS_AND_BROKE - } - - modifier = { - add = { - add = -10 - multiply = scope:actor.num_sinful_traits - } - scope:actor.num_sinful_traits > 0 - desc = I_AM_SINFUL + celestial_hierarchy_acceptance_modifier = { + ACTOR = scope:actor + RECIPIENT = scope:recipient } modifier = { @@ -5634,28 +6952,14 @@ hof_ask_for_gold_interaction = { scope:influence_send_option = yes desc = INFLUENCE_INTERACTION_ACCEPTANCE_SEND_OPTION } - + modifier = { - add = -25 - desc = BASE_RELUCTANCE - trigger = { - has_game_rule = hard_difficulty - scope:actor = { - is_ai = no - } - } - } - - modifier = { - add = -75 - desc = BASE_RELUCTANCE - trigger = { - has_game_rule = very_hard_difficulty - scope:actor = { - is_ai = no - } - } + add = pam_offer_pilgrimage_acceptance_value + scope:offer_pilgrimage = yes + desc = OFFER_PILGRIMAGE_INTERACTION_OPTION_REASON } + + ask_for_gold_acceptance_modifier = yes } auto_accept = { @@ -5703,32 +7007,58 @@ hof_ask_for_gold_interaction = { localization = TRADE_INFLUENCE_FOR_BETTER_AI_ACCEPTANCE } + send_option = { + is_shown = { + has_pam_dlc_trigger = yes + pam_offer_pilgrimage_option_shown_trigger = { ACTOR = scope:actor } + } + is_valid = { + pam_offer_pilgrimage_option_valid_trigger = { ACTOR = scope:actor } + } + flag = offer_pilgrimage + localization = OFFER_PILGRIMAGE_INTERACTION_OPTION + } + send_options_exclusive = no ai_min_reply_days = 1 ai_max_reply_days = 5 + can_send = { + # Anti-spam AI blockers + ai_religious_request_blocker_trigger = { INTERACTION = hof_ask_for_gold_interaction } + } + + on_send = { + # Anti-spam AI blockers + ai_religious_request_blocker_effect = { INTERACTION = hof_ask_for_gold_interaction } + } + on_accept = { hof_ask_for_gold_interaction_effect = yes + pam_offer_pilgrimage_effect = { + ACTOR = scope:actor + CLERIC = scope:recipient + } + scope:actor = { trigger_event = religious_interaction.3 } } on_decline = { + scope:recipient = { + add_piety = miniscule_piety_loss + } scope:actor = { + show_as_tooltip = { + hof_ask_for_gold_refusal_effect = yes + } trigger_event = religious_interaction.32 } } - ai_potential = { - is_playable_character = yes - piety >= major_piety_value - NOT = { has_trait = excommunicated } - exists = faith.religious_head - } - ai_will_do = { base = 0 @@ -5736,33 +7066,58 @@ hof_ask_for_gold_interaction = { scope:hook = yes add = -1 } - + #Make AI clerics do this less - they should use Request Treasury Funds instead + modifier = { + is_clergy = yes + add = -25 + } modifier = { # Counts get a bad 'exchange rate' due to their low income. highest_held_title_tier < tier_county - scope:recipient.gold < 3000 + scope:recipient.treasury_or_gold < 3000 add = -50 } modifier = { # Dukes are also somewhat reluctant to request gold if not independent. - highest_held_title_tier = tier_duchy + highest_held_title_tier = tier_duchy top_liege != this - scope:recipient.gold < 3000 + scope:recipient.treasury_or_gold < 3000 add = -25 } + modifier = { # dont spam on player HoF + scope:recipient = { + is_ai = no + faith.religious_head ?= this + } + add = -50 + } modifier = { # I am low on money while at war - add = 300 + add = 50 scope:actor = { is_at_war = yes gold < medium_gold_value } } modifier = { # I am in debt - add = 300 + add = 50 scope:actor = { gold < 0 } + #Pope demanding hook in return + NOT = { + scope:recipient = { + OR = { + ai_honor < 0 + ai_zeal < low_negative_ai_value + } + } + } + } + modifier = { # I am badly in debt + add = 50 + scope:actor = { + gold < massive_gold_value_negative + } } - modifier = { # Piety to burn, and no reason to keep it. add = 25 scope:actor = { @@ -5781,28 +7136,23 @@ hof_ask_for_gold_interaction = { } modifier = { # If the Pope has overflowing coffers, it'd be rather impious to NOT ask him to give some to a fellow, poor and struggling christian! - add = 50 - scope:actor = { - piety > major_piety_value + add = { + value = scope:recipient.treasury_or_gold + subtract = 1000 + divide = 100 + max = 50 } - scope:recipient.gold >= 3000 - } - - modifier = { - add = 100 scope:actor = { - ai_has_economical_boom_personality = yes + OR = { + ai_has_economical_boom_personality = yes + piety > major_piety_value + AND = { + ai_has_warlike_personality = yes + war_chest_gold < war_chest_gold_maximum + } + } } - scope:recipient.gold >= 1000 - } - - modifier = { - add = 100 - scope:actor = { - ai_has_warlike_personality = yes - war_chest_gold < war_chest_gold_maximum - } - scope:recipient.gold >= 1000 + scope:recipient.treasury_or_gold >= 1000 } modifier = { #That's _my_ piety @@ -5819,21 +7169,22 @@ hof_ask_for_gold_interaction = { hof_ask_for_claim_interaction = { category = interaction_category_diplomacy - icon = religious_claim + icon = icon_clergy_claim_title interface_priority = 35 desc = hof_ask_for_claim_interaction_desc + notification_text = hof_ask_for_claim_interaction_notification target_type = title target_filter = secondary_recipient_domain_titles redirect = { if = { limit = { - exists = scope:actor.faith.religious_head + exists = scope:actor.religious_head_or_challenger } scope:recipient = { save_scope_as = secondary_recipient } - scope:actor.faith.religious_head = { + scope:actor.religious_head_or_challenger = { save_scope_as = recipient } } @@ -5842,16 +7193,16 @@ hof_ask_for_claim_interaction = { has_valid_target_showing_failures_only = { scope:target = { tier >= tier_county - is_noble_family_title = no + is_landless_type_title = no } trigger_if = { # Admin can't request claim on other admin titles, only the top liege's primary title is up for grabs limit = { scope:secondary_recipient = { - government_allows = administrative + government_has_mechanic = administrative top_liege = this } scope:actor = { - government_allows = administrative + government_has_mechanic = administrative } } scope:target = { @@ -5860,25 +7211,54 @@ hof_ask_for_claim_interaction = { } } + cooldown_against_recipient = { years = 3 } + + is_available = { + trigger_if = { + limit = { is_ai = yes } + piety >= major_piety_value + exists = religious_head_or_challenger + is_playable_character = yes + OR = { + ai_greed >= 50 + ai_has_warlike_personality = yes + } + NOR = { + has_trait = excommunicated + has_character_flag = hof_request_cooldown + } + } + NOT = { + has_character_modifier = promised_pilgrimage_to_clergy_modifier + } + } + is_shown = { - exists = scope:actor.faith.religious_head - scope:actor.faith = scope:secondary_recipient.faith + #Pam DLC has new version + has_pam_dlc_trigger = no + exists = scope:actor.religious_head_or_challenger + scope:actor != scope:actor.religious_head_or_challenger + scope:recipient.religious_head_or_challenger ?= scope:actor.religious_head_or_challenger + scope:actor.faith ?= scope:secondary_recipient.faith NOR = { scope:actor = scope:secondary_recipient - scope:secondary_recipient = scope:recipient + scope:secondary_recipient ?= scope:recipient } - exists = scope:actor.faith.religious_head - scope:actor.faith = { + scope:actor.faith ?= { has_doctrine = doctrine_spiritual_head } - scope:secondary_recipient = { + scope:secondary_recipient ?= { is_landed_or_landless_administrative = yes - primary_title = { tier >= tier_county } + primary_title ?= { tier >= tier_county } NOT = { government_has_flag = government_is_holy_order } } } is_valid_showing_failures_only = { + scope:actor = { + pam_antipope_clerical_request_trigger = { RECIPIENT = scope:recipient } + } + pam_not_promised_pilgrimage_trigger = { ACTOR = scope:actor } trigger_if = { # Can't request on titles you already have a pressed claim on limit = { exists = scope:target @@ -5922,11 +7302,11 @@ hof_ask_for_claim_interaction = { trigger_if = { # Admin can't request claims on other admin titles limit = { scope:secondary_recipient = { - government_allows = administrative + government_has_mechanic = administrative NOT = { top_liege = this } } scope:actor = { - government_allows = administrative + government_has_mechanic = administrative } } custom_description = { @@ -5950,8 +7330,8 @@ hof_ask_for_claim_interaction = { } } scope:actor = { - custom_description = { - text = "hof_interaction_unreformed_faith" + custom_tooltip = { + text = HOF_INTERACTION_UNREFORMED_FAITH NOT = { faith = { has_doctrine_parameter = unreformed } } @@ -5987,17 +7367,6 @@ hof_ask_for_claim_interaction = { hegemony = 12 } - ai_potential = { - is_playable_character = yes - OR = { - ai_greed >= 50 - ai_has_warlike_personality = yes - } - piety >= major_piety_value - NOT = { has_trait = excommunicated } - exists = faith.religious_head - } - ai_will_do = { base = 0 @@ -6045,6 +7414,19 @@ hof_ask_for_claim_interaction = { ai_accept = { base = 0 # Should be 0 for all interactions + celestial_hierarchy_acceptance_modifier = { + ACTOR = scope:actor + RECIPIENT = scope:recipient + } + + modifier = { # By God Alone - Secular Faith: the petitioner holds the ear of the clergy + add = 25 + desc = pam_sf_ear_of_clergy_accept_reason + trigger = { + scope:actor = { has_character_modifier = pam_sf_ear_of_clergy_modifier } + } + } + modifier = { scope:claim_hook ?= yes add = 100 @@ -6097,6 +7479,16 @@ hof_ask_for_claim_interaction = { } } } + modifier = { # Easier claims from HoF during instability + add = 25 + desc = CHRISTIAN_CHURCH_PHASE_REASON + situation:the_christian_church ?= { + situation_participant_group:christian_regular_main_power_rulers = { + participant_group_has_character = scope:actor + has_participant_group_parameter = the_christian_church_easier_claims_from_hof + } + } + } modifier = { # Unlikely if recipient likes Secondary Recipient desc = AI_OPINION_RECIPIENT_REASON add = { @@ -6186,8 +7578,8 @@ hof_ask_for_claim_interaction = { scope:actor = { is_adult = yes is_female = no - faith = { - has_doctrine = doctrine_gender_male_dominated + rite = { + rite_has_doctrine = doctrine_gender_male_dominated } } } @@ -6202,8 +7594,8 @@ hof_ask_for_claim_interaction = { scope:actor = { is_adult = yes is_female = yes - faith = { - has_doctrine = doctrine_gender_female_dominated + rite = { + rite_has_doctrine = doctrine_gender_female_dominated } } } @@ -6214,8 +7606,8 @@ hof_ask_for_claim_interaction = { scope:actor = { is_adult = yes is_female = yes - faith = { - has_doctrine = doctrine_gender_male_dominated + rite = { + rite_has_doctrine = doctrine_gender_male_dominated } } scope:secondary_recipient = { @@ -6230,8 +7622,8 @@ hof_ask_for_claim_interaction = { scope:actor = { is_adult = yes is_female = no - faith = { - has_doctrine = doctrine_gender_female_dominated + rite = { + rite_has_doctrine = doctrine_gender_female_dominated } } scope:secondary_recipient = { @@ -6255,11 +7647,11 @@ hof_ask_for_claim_interaction = { OR = { AND = { has_trait = fornicator - trait_is_shunned_or_criminal_in_faith_trigger = { FAITH = faith TRAIT = trait:fornicator GENDER_CHARACTER = scope:actor } + trait_is_shunned_or_criminal_in_rite_trigger = { RITE = rite TRAIT = trait:fornicator GENDER_CHARACTER = scope:actor } } AND = { has_trait = adulterer - trait_is_shunned_or_criminal_in_faith_trigger = { FAITH = faith TRAIT = trait:adulterer GENDER_CHARACTER = scope:actor } + trait_is_shunned_or_criminal_in_rite_trigger = { RITE = rite TRAIT = trait:adulterer GENDER_CHARACTER = scope:actor } } } } @@ -6272,11 +7664,11 @@ hof_ask_for_claim_interaction = { OR = { AND = { has_trait = fornicator - trait_is_shunned_or_criminal_in_faith_trigger = { FAITH = faith TRAIT = trait:fornicator GENDER_CHARACTER = scope:secondary_recipient } + trait_is_shunned_or_criminal_in_rite_trigger = { RITE = rite TRAIT = trait:fornicator GENDER_CHARACTER = scope:secondary_recipient } } AND = { has_trait = adulterer - trait_is_shunned_or_criminal_in_faith_trigger = { FAITH = faith TRAIT = trait:adulterer GENDER_CHARACTER = scope:secondary_recipient } + trait_is_shunned_or_criminal_in_rite_trigger = { RITE = rite TRAIT = trait:adulterer GENDER_CHARACTER = scope:secondary_recipient } } } } @@ -6286,7 +7678,7 @@ hof_ask_for_claim_interaction = { add = -50 desc = I_AM_INCESTOUS scope:actor = { - NOT = { scope:recipient = { faith = { has_doctrine = doctrine_consanguinity_unrestricted } } } + NOT = { scope:recipient = { rite = { rite_has_doctrine = doctrine_consanguinity_unrestricted } } } has_trait = incestuous } } @@ -6311,7 +7703,7 @@ hof_ask_for_claim_interaction = { add = 15 desc = THEY_ARE_INCESTOUS scope:secondary_recipient = { - NOT = { scope:recipient = { faith = { has_doctrine = doctrine_consanguinity_unrestricted } } } + NOT = { scope:recipient = { rite = { rite_has_doctrine = doctrine_consanguinity_unrestricted } } } has_trait = incestuous } } @@ -6323,15 +7715,15 @@ hof_ask_for_claim_interaction = { OR = { AND = { has_trait = kinslayer_1 - trait_is_shunned_or_criminal_in_faith_trigger = { FAITH = faith TRAIT = trait:kinslayer_1 GENDER_CHARACTER = scope:actor } + trait_is_shunned_or_criminal_in_rite_trigger = { RITE = rite TRAIT = trait:kinslayer_1 GENDER_CHARACTER = scope:actor } } AND = { has_trait = kinslayer_2 - trait_is_shunned_or_criminal_in_faith_trigger = { FAITH = faith TRAIT = trait:kinslayer_2 GENDER_CHARACTER = scope:actor } + trait_is_shunned_or_criminal_in_rite_trigger = { RITE = rite TRAIT = trait:kinslayer_2 GENDER_CHARACTER = scope:actor } } AND = { has_trait = kinslayer_3 - trait_is_shunned_or_criminal_in_faith_trigger = { FAITH = faith TRAIT = trait:kinslayer_3 GENDER_CHARACTER = scope:actor } + trait_is_shunned_or_criminal_in_rite_trigger = { RITE = rite TRAIT = trait:kinslayer_3 GENDER_CHARACTER = scope:actor } } } } @@ -6344,15 +7736,15 @@ hof_ask_for_claim_interaction = { OR = { AND = { has_trait = kinslayer_1 - trait_is_shunned_or_criminal_in_faith_trigger = { FAITH = faith TRAIT = trait:kinslayer_1 GENDER_CHARACTER = scope:secondary_recipient } + trait_is_shunned_or_criminal_in_rite_trigger = { RITE = rite TRAIT = trait:kinslayer_1 GENDER_CHARACTER = scope:secondary_recipient } } AND = { has_trait = kinslayer_2 - trait_is_shunned_or_criminal_in_faith_trigger = { FAITH = faith TRAIT = trait:kinslayer_2 GENDER_CHARACTER = scope:secondary_recipient } + trait_is_shunned_or_criminal_in_rite_trigger = { RITE = rite TRAIT = trait:kinslayer_2 GENDER_CHARACTER = scope:secondary_recipient } } AND = { has_trait = kinslayer_3 - trait_is_shunned_or_criminal_in_faith_trigger = { FAITH = faith TRAIT = trait:kinslayer_3 GENDER_CHARACTER = scope:secondary_recipient } + trait_is_shunned_or_criminal_in_rite_trigger = { RITE = rite TRAIT = trait:kinslayer_3 GENDER_CHARACTER = scope:secondary_recipient } } } } @@ -6600,8 +7992,21 @@ hof_ask_for_claim_interaction = { ai_min_reply_days = 1 ai_max_reply_days = 5 + can_send = { + # Anti-spam AI blockers + ai_religious_request_blocker_trigger = { INTERACTION = hof_ask_for_claim_interaction } + } + + on_send = { + # Anti-spam AI blockers + ai_religious_request_blocker_effect = { INTERACTION = hof_ask_for_claim_interaction } + } + on_accept = { hof_ask_for_claim_interaction_effect = yes + hof_request_accept_consequences_effect = { + HOF = scope:recipient + } scope:secondary_recipient = { trigger_event = religious_interaction.5 } @@ -6620,6 +8025,10 @@ hof_ask_for_claim_interaction = { } on_decline = { + hof_request_refuse_consequences_effect = { + HOF = scope:recipient + REQUESTER = scope:actor + } scope:actor = { trigger_event = religious_interaction.42 } @@ -6646,8 +8055,8 @@ hof_redirect_great_holy_war_interaction = { is_shown = { #exists = scope:actor.faith.religious_head #Called by Autonomous Faiths too. exists = scope:actor.faith.great_holy_war - scope:actor.faith = { is_hostile_enough_for_holy_war_trigger = { FAITH = scope:secondary_recipient.faith } } - scope:secondary_recipient = { top_liege = this } + scope:actor.rite ?= { is_hostile_enough_for_holy_war_trigger = { RITE = scope:secondary_recipient.rite } } + scope:secondary_recipient ?= { top_liege = this } NOT = { exists = scope:actor.faith.great_holy_war.ghw_war } scope:target != scope:actor.faith.great_holy_war.ghw_target_title #Do not show the title already targeted in the list. } @@ -6747,7 +8156,7 @@ hof_redirect_great_holy_war_interaction = { scope:target_character = { faith = { every_faith_holy_order = { - trigger_event = { id = great_holy_war.0091 days = { 25 60 } } #Holy order counterpledging + trigger_event = { id = great_holy_war.0091 days = { 25 60 } } #Military Order counterpledging } } } @@ -6787,8 +8196,8 @@ select_ghw_beneficiary_interaction = { populate_recipient_list = { scope:recipient = { - #Any member of your own house. - house = { + #Any member of your own house. Lowborn clerics have none, hence the safe scope switches below. + house ?= { every_house_member = { limit = { # Cannot select them self as beneficiary @@ -6800,13 +8209,13 @@ select_ghw_beneficiary_interaction = { #Any nearby family member who is of your dynasty, even if they're a separate house. every_close_or_extended_family_member = { limit = { - dynasty = scope:recipient.dynasty - house != scope:recipient.house + dynasty ?= scope:recipient.dynasty + NOT = { house ?= scope:recipient.house } } add_to_list = characters } #And then any landless heads of minor houses in your dynasty. - dynasty = { + dynasty ?= { every_dynasty_member = { limit = { this = this.house.house_head @@ -6819,9 +8228,20 @@ select_ghw_beneficiary_interaction = { add_to_list = characters } } + #Whoever called the war has no dynastic stake in its spoils, so their own court supplies the candidates. + if = { + limit = { faith.great_holy_war.ghw_war_declarer ?= scope:recipient } + every_courtier_or_guest = { + limit = { + is_adult = yes + is_ruler = no + } + add_to_list = characters + } + } # If you're a laamp, add you too. if = { - limit = { OR = { government_has_flag = government_is_landless_adventurer government_has_flag = government_is_landless_minority } } + limit = { government_has_flag = government_is_landless_adventurer } add_to_list = characters } } @@ -6830,19 +8250,23 @@ select_ghw_beneficiary_interaction = { auto_accept = yes is_shown = { - exists = scope:actor.faith.great_holy_war - scope:actor = { + exists = scope:puppet_or_actor.faith.great_holy_war + scope:puppet_or_actor ?= { exists = faith.great_holy_war this = scope:recipient is_pledged_ghw_attacker = yes } - scope:actor != scope:recipient.faith.great_holy_war.ghw_war_declarer #Not for the Caliph himself. + #The AI Caliph has its beneficiary assigned by event, but a player who called the war picks their own. + trigger_if = { + limit = { scope:actor = { is_ai = yes } } + NOT = { scope:recipient.faith.great_holy_war.ghw_war_declarer ?= scope:puppet_or_actor } + } } can_be_picked = { is_adult = yes is_ruler = no - faith = scope:actor.faith + faith = scope:puppet_or_actor.faith custom_tooltip = { text = ghw_heir_to_a_title NOT = { @@ -6878,28 +8302,34 @@ select_ghw_beneficiary_interaction = { has_trait_with_flag = debilitating_illness custom_description = { text = "ghw_recipient_must_not_be_realm_priest" - faith = { - has_doctrine = doctrine_theocracy_temporal + rite = { + rite_has_doctrine = doctrine_theocracy_temporal } has_council_position = councillor_court_chaplain } } - faith = scope:actor.faith + faith = scope:puppet_or_actor.faith is_adult = yes trigger_if = { limit = { - NOT = { OR = { government_has_flag = government_is_landless_adventurer government_has_flag = government_is_landless_minority } } + NOT = { government_has_flag = government_is_landless_adventurer } } is_ruler = no } - NOT = { - any_heir_title = {} # Not heir to anything - } - OR = { #Either not married, or not married to a ruler. - is_married = no + custom_tooltip = { + text = ghw_heir_to_a_title NOT = { - any_spouse = { - is_ruler = yes + any_heir_title = {} # Not heir to anything + } + } + custom_tooltip = { + text = ghw_married_to_a_ruler + OR = { #Either not married, or not married to a ruler. + is_married = no + NOT = { + any_spouse = { + is_ruler = yes + } } } } @@ -6907,7 +8337,7 @@ select_ghw_beneficiary_interaction = { } on_accept = { - scope:actor = { + scope:puppet_or_actor = { send_interface_toast = { type = event_toast_effect_neutral title = select_ghw_beneficiary_interaction_notification @@ -6917,6 +8347,20 @@ select_ghw_beneficiary_interaction = { set_beneficiary = scope:secondary_recipient } } + if = { + limit = { + scope:is_puppet_action ?= yes + scope:actor != scope:recipient + } + scope:actor = { + send_interface_toast = { + type = event_toast_effect_neutral + title = select_ghw_beneficiary_interaction_notification_puppeteer + left_icon = scope:puppet_or_actor + right_icon = scope:secondary_recipient + } + } + } } ai_will_do = { base = 0 #Assigned directly by event for the AI. @@ -6930,7 +8374,7 @@ sun_trial_interaction = { category = interaction_category_prison is_shown = { - scope:actor = { faith = { has_doctrine_parameter = trial_by_sun_active } } + scope:actor = { rite = { rite_has_parameter = trial_by_sun_active } } scope:recipient = { is_imprisoned_by = scope:actor is_adult = yes @@ -7012,31 +8456,31 @@ literalist_debate_interaction = { desc = literalist_debate_interaction_desc is_shown = { - scope:actor != scope:recipient - scope:actor.faith = { - has_doctrine_parameter = literalist_debate_enabled + scope:puppet_or_actor != scope:recipient + scope:puppet_or_actor.rite ?= { + rite_has_parameter = literalist_debate_enabled } scope:recipient = { is_playable_character = yes OR = { - liege = scope:actor #You may debate direct vassals. - liege = scope:actor.liege #You may debate vassals with whom you share a liege. - scope:actor.liege = scope:recipient #You may debate your direct liege. + liege ?= scope:puppet_or_actor #You may debate direct vassals. + liege ?= scope:puppet_or_actor.liege #You may debate vassals with whom you share a liege. + scope:puppet_or_actor.liege ?= scope:recipient #You may debate your direct liege. } } } is_valid_showing_failures_only = { - scope:actor = { + scope:puppet_or_actor = { is_available_adult = yes NOT = { is_at_war_with = scope:recipient } } scope:recipient = { - faith = scope:actor.faith + faith = scope:puppet_or_actor.faith is_available_adult = yes - NOT = { has_strong_hook = scope:actor } + NOT = { has_strong_hook = scope:puppet_or_actor } } custom_description = { text = literalist_debate_interaction_has_been_debated @@ -7048,7 +8492,7 @@ literalist_debate_interaction = { } custom_description = { text = literalist_debate_timing - scope:actor = { + scope:puppet_or_actor = { NOT = { has_character_modifier = used_literalist_debate_modifier } } } @@ -7058,7 +8502,7 @@ literalist_debate_interaction = { on_accept = { hidden_effect = { - scope:actor = { + scope:puppet_or_actor = { add_character_modifier = { modifier = used_literalist_debate_modifier years = 2 @@ -7072,20 +8516,38 @@ literalist_debate_interaction = { } } } - custom_tooltip = literalist_debate_interaction.tt_modifiers - scope:actor = { - stress_impact = { + if = { + limit = { scope:actor = scope:puppet_or_actor } + custom_tooltip = literalist_debate_interaction.tt_modifiers + } + else = { + custom_tooltip = literalist_debate_interaction.tt_modifiers_puppeteer + } + scope:puppet_or_actor = { + stress_and_fulfillment_impact = { cynical = minor_stress_impact_gain } - custom_tooltip = literalist_debate_interaction.tt_winnings_actor + if = { + limit = { scope:actor = scope:puppet_or_actor } + custom_tooltip = literalist_debate_interaction.tt_winnings_actor + } + else = { + custom_tooltip = literalist_debate_interaction.tt_winnings_actor_puppeteer + } } scope:recipient = { - custom_tooltip = literalist_debate_interaction.tt_winnings_recipient + if = { + limit = { scope:actor = scope:puppet_or_actor } + custom_tooltip = literalist_debate_interaction.tt_winnings_recipient + } + else = { + custom_tooltip = literalist_debate_interaction.tt_winnings_recipient_puppeteer + } } # If we're a clan this interaction affects unity add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = medium_unity_loss DESC = clan_unity_literalist_debate.desc @@ -7107,28 +8569,27 @@ attempt_conversion_of_local_ruler_interaction = { desc = attempt_conversion_of_local_ruler_interaction_desc is_shown = { - scope:actor = { - has_government = landless_adventurer_government - has_perk = prophet_perk + scope:puppet_or_actor ?= { + OR = { + has_personal_tenet_flag = tenet_mendicant_preachers_local_conversion + AND = { + has_perk = prophet_perk + has_government = landless_adventurer_government + } + } } scope:recipient = { - faith != scope:actor.faith is_ai = yes is_ruler = yes is_landed = yes } - OR = { - is_ai = no - NOT = { scope:actor = { government_has_flag = government_is_landless_minority } } - } - OR = { - is_ai = no - NOT = { scope:actor = { culture = { has_cultural_parameter = cannot_convert_diasporia } } } + scope:puppet_or_actor ?= { + NOT = { faith = scope:recipient.faith } } } is_highlighted = { - scope:actor = { + scope:puppet_or_actor = { is_character_interaction_potentially_accepted = { recipient = scope:recipient interaction = attempt_conversion_of_local_ruler_interaction @@ -7139,20 +8600,31 @@ attempt_conversion_of_local_ruler_interaction = { cooldown_against_recipient = { years = 15 } can_send = { - custom_tooltip = { - text = must_be_in_domain_tt - scope:recipient = { - OR = { - capital_province ?= scope:actor.domicile.domicile_location - any_held_title = { - title_tier = county - any_county_province = { - this = scope:actor.domicile.domicile_location + trigger_if = { + limit = { + scope:puppet_or_actor ?= { has_government = landless_adventurer_government } + } + custom_tooltip = { + text = must_be_in_domain_tt + scope:recipient = { + OR = { + capital_province ?= scope:puppet_or_actor.domicile.domicile_location + any_held_title = { + title_tier = county + any_county_province = { + this = scope:puppet_or_actor.domicile.domicile_location + } } } } } } + trigger_else = { + custom_tooltip = { + text = must_be_in_same_county_tt + scope:puppet_or_actor.location.county.holder ?= scope:recipient + } + } } # Use Stress @@ -7166,14 +8638,14 @@ attempt_conversion_of_local_ruler_interaction = { } send_option = { is_valid = { - scope:actor.intrigue >= scope:recipient.intrigue + scope:puppet_or_actor.intrigue >= scope:recipient.intrigue } flag = lie localization = USE_INTRIGUE } send_option = { is_valid = { - scope:actor.domicile ?= { + scope:puppet_or_actor.domicile ?= { provisions >= { value = 300 multiply = scope:recipient.highest_held_title_tier @@ -7190,7 +8662,7 @@ attempt_conversion_of_local_ruler_interaction = { } send_option = { is_valid = { - scope:actor = { + scope:puppet_or_actor = { gold >= scope:recipient.medium_gold_value } NOR = { @@ -7203,11 +8675,11 @@ attempt_conversion_of_local_ruler_interaction = { } send_option = { is_valid = { - scope:actor = { + scope:puppet_or_actor = { has_usable_hook = scope:recipient } NOT = { - scope:recipient = { is_imprisoned_by = scope:actor } + scope:recipient = { is_imprisoned_by = scope:puppet_or_actor } } } flag = hook @@ -7215,11 +8687,17 @@ attempt_conversion_of_local_ruler_interaction = { } send_options_exclusive = no should_use_extra_icon = { - scope:actor = { has_usable_hook = scope:recipient } + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } extra_icon = "gfx/interface/icons/character_interactions/hook_icon.dds" is_valid_showing_failures_only = { + trigger_if = { + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + piety >= attempt_conversion_of_local_ruler_piety_cost_value + } + } scope:recipient = { is_available = yes } @@ -7231,21 +8709,28 @@ attempt_conversion_of_local_ruler_interaction = { cost = { piety = { - value = { - add = medium_piety_value - multiply = scope:recipient.highest_held_title_tier - if = { - limit = { - scope:piety = yes - } - multiply = 2 - } + value = attempt_conversion_of_local_ruler_piety_cost_value + if = { + limit = { scope:is_puppet_action ?= yes } + multiply = 0 } } } on_accept = { - scope:actor = { + if = { + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + add_piety = { + value = { + value = attempt_conversion_of_local_ruler_piety_cost_value + max = piety + multiply = -1 + } + } + } + } + scope:puppet_or_actor = { trigger_event = religious_interaction.2002 show_as_tooltip = { if = { @@ -7256,7 +8741,7 @@ attempt_conversion_of_local_ruler_interaction = { faith = { change_fervor = { value = { - add = 1 + add = trivial_fervor_value multiply = scope:recipient.highest_held_title_tier } desc = imperial_capital_sacked_fervor_gain @@ -7284,7 +8769,7 @@ attempt_conversion_of_local_ruler_interaction = { limit = { scope:lie = yes } - stress_impact = { + stress_and_fulfillment_impact = { honest = medium_stress_impact_gain forgiving = medium_stress_impact_gain compassionate = minor_stress_impact_gain @@ -7319,7 +8804,7 @@ attempt_conversion_of_local_ruler_interaction = { limit = { scope:lie = yes } - stress_impact = { + stress_and_fulfillment_impact = { base = minor_stress_impact_gain paranoid = medium_stress_impact_gain trusting = medium_stress_impact_gain @@ -7331,27 +8816,27 @@ attempt_conversion_of_local_ruler_interaction = { } add_opinion = { modifier = showed_me_the_light_opinion - target = scope:actor + target = scope:puppet_or_actor opinion = 40 } if = { limit = { top_liege != this liege ?= { - faith != scope:actor.faith + faith != scope:puppet_or_actor.faith } } liege = { add_opinion = { modifier = annoyed_opinion - target = scope:actor + target = scope:puppet_or_actor opinion = -20 } } } } -# scope:actor = { +# scope:puppet_or_actor = { # if = { # limit = { # any_character_struggle = { @@ -7365,10 +8850,15 @@ attempt_conversion_of_local_ruler_interaction = { # add_piety = medium_piety_gain # } # } + + conversion_tenet_acts_of_the_apostles_effect = yes + + # If you have the Mendicant Preaching personal tenet we give you SP + conversion_tenet_mendicant_preachers_effect = yes } on_decline = { - scope:actor = { + scope:puppet_or_actor = { trigger_event = { id = religious_interaction.2003 } @@ -7382,7 +8872,7 @@ attempt_conversion_of_local_ruler_interaction = { limit = { scope:lie = yes } - stress_impact = { + stress_and_fulfillment_impact = { honest = medium_stress_impact_gain forgiving = medium_stress_impact_gain compassionate = minor_stress_impact_gain @@ -7416,7 +8906,7 @@ attempt_conversion_of_local_ruler_interaction = { limit = { scope:lie = yes } - stress_impact = { + stress_and_fulfillment_impact = { base = minor_stress_impact_gain paranoid = medium_stress_impact_gain trusting = medium_stress_impact_gain @@ -7426,19 +8916,19 @@ attempt_conversion_of_local_ruler_interaction = { #Negative opinions add_opinion = { modifier = unwanted_religious_conversion_opinion - target = scope:actor + target = scope:puppet_or_actor } if = { limit = { top_liege != this liege ?= { - faith != scope:actor.faith + faith != scope:puppet_or_actor.faith } } liege = { add_opinion = { modifier = religious_rebel_opinion - target = scope:actor + target = scope:puppet_or_actor } } } @@ -7448,6 +8938,12 @@ attempt_conversion_of_local_ruler_interaction = { ai_accept = { base = 0 + + celestial_hierarchy_acceptance_modifier = { + ACTOR = scope:puppet_or_actor + RECIPIENT = scope:recipient + } + modifier = { desc = SCHEME_WEAK_HOOK_USED add = 20 @@ -7457,7 +8953,7 @@ attempt_conversion_of_local_ruler_interaction = { desc = ASK_FOR_CONVERSION_RECIPIENT_INTRIGUE scope:lie = yes add = { - value = scope:actor.intrigue + value = scope:puppet_or_actor.intrigue subtract = scope:recipient.intrigue min = 1 } @@ -7491,31 +8987,31 @@ attempt_conversion_of_local_ruler_interaction = { } modifier = { scope:recipient = { - has_relation_lover = scope:actor + has_relation_lover = scope:puppet_or_actor } add = 25 desc = AI_YOUR_LOVER } modifier = { scope:recipient = { - has_relation_friend = scope:actor + has_relation_friend = scope:puppet_or_actor } add = 25 desc = AI_YOUR_FRIEND } modifier = { scope:recipient = { - is_child_of = scope:actor + is_child_of = scope:puppet_or_actor } add = 50 desc = AI_YOUR_CHILD } modifier = { add = { - value = scope:actor.piety_level + value = scope:puppet_or_actor.piety_level multiply = 10 } - scope:actor = { + scope:puppet_or_actor = { piety_level > 1 } desc = ASK_FOR_CONVERSION_ACTOR_IS_PIOUS @@ -7540,9 +9036,9 @@ attempt_conversion_of_local_ruler_interaction = { scope:recipient = { top_liege != this faith = liege.faith - faith = { - faith_hostility_level = { - target = scope:actor.faith + rite = { + rite_hostility_level = { + target = scope:puppet_or_actor.rite value >= faith_hostile_level } } @@ -7552,13 +9048,13 @@ attempt_conversion_of_local_ruler_interaction = { modifier = { add = -50 scope:recipient = { - faith = { - faith_hostility_level = { - target = scope:actor.faith + rite = { + rite_hostility_level = { + target = scope:puppet_or_actor.rite value >= faith_astray_level } - faith_hostility_level = { - target = scope:actor.faith + rite_hostility_level = { + target = scope:puppet_or_actor.rite value < faith_hostile_level } } @@ -7568,13 +9064,13 @@ attempt_conversion_of_local_ruler_interaction = { modifier = { add = -75 scope:recipient = { - faith = { - faith_hostility_level = { - target = scope:actor.faith + rite = { + rite_hostility_level = { + target = scope:puppet_or_actor.rite value >= faith_hostile_level } - faith_hostility_level = { - target = scope:actor.faith + rite_hostility_level = { + target = scope:puppet_or_actor.rite value < faith_evil_level } } @@ -7584,9 +9080,9 @@ attempt_conversion_of_local_ruler_interaction = { modifier = { add = -100 scope:recipient = { - faith = { - faith_hostility_level = { - target = scope:actor.faith + rite = { + rite_hostility_level = { + target = scope:puppet_or_actor.rite value >= faith_evil_level } } @@ -7611,10 +9107,26 @@ revel_in_pain_interaction = { greeting = positive notification_text = REVEL_IN_PAIN_INTERACTION_NOTIFICATION + is_available = { + has_personal_tenet_flag = self_mutilation_active + trigger_if = { + limit = { is_ai = yes } + OR = { + has_trait = zealous + has_trait = sadistic + } + NOR = { + has_trait = craven + has_trait = wounded_1 + has_trait = wounded_2 + } + is_at_war = no + } + } + is_shown = { NOT = { scope:actor = scope:recipient } scope:actor = { - faith = { has_doctrine_parameter = self_mutilation_active } OR = { has_relation_friend = scope:recipient has_relation_lover = scope:recipient @@ -7638,7 +9150,7 @@ revel_in_pain_interaction = { } is_adult = yes NOT = { has_trait = craven } - faith = { has_doctrine_parameter = self_mutilation_active } + has_personal_tenet_flag = self_mutilation_active NOT = { is_at_war_with = scope:actor } custom_tooltip = { text = recipient_is_severely_injured_tt @@ -7665,7 +9177,7 @@ revel_in_pain_interaction = { if = { limit = { is_ai = no } trigger_event = religious_interaction.2600 - show_as_tooltip = { + show_as_tooltip = { revel_in_pain_effect = yes revel_in_pain_opinion_effect = yes } @@ -7678,7 +9190,7 @@ revel_in_pain_interaction = { } on_decline = { - scope:actor = { + scope:actor = { trigger_event = religious_interaction.2610 } } @@ -7700,20 +9212,6 @@ revel_in_pain_interaction = { hegemony = 36 } - ai_potential = { - faith = { has_doctrine_parameter = self_mutilation_active } - is_at_war = no - OR = { - has_trait = zealous - has_trait = sadistic - } - NOR = { - has_trait = craven - has_trait = wounded_1 - has_trait = wounded_2 - } - } - ai_will_do = { base = 0 modifier = { @@ -7722,6 +9220,3176 @@ revel_in_pain_interaction = { modifier = { has_trait = flagellant add = 25 - } + } + } +} + +exaltation_of_pain_wound_courtier_interaction = { + icon = wound + category = interaction_category_religion + desc = exaltation_of_pain_wound_courtier_interaction_desc + + cooldown = { years = 3 } + + greeting = negative + notification_text = EXALTATION_OF_PAIN_WOUND_COURTIER_NOTIFICATION + + is_available = { + has_personal_tenet_flag = tenet_exaltation_of_pain_wound_courtier_interaction + trigger_if = { + limit = { is_ai = yes } + OR = { + has_trait = zealous + has_trait = sadistic + has_trait = flagellant + } + is_at_war = no + } + } + + is_shown = { + NOT = { scope:actor = scope:recipient } + scope:recipient = { + is_courtier_of = scope:actor + } + } + + is_valid_showing_failures_only = { + scope:actor = { + is_adult = yes + is_available = yes + } + scope:recipient = { + is_ruler = no + is_available = yes + custom_tooltip = { + text = exaltation_of_pain_recipient_too_unwell_tt + NOR = { + has_trait = incapable + health <= 2.5 + has_trait_rank = { + trait = wounded + rank >= 2 + } + } + } + } + } + + auto_accept = yes + + on_accept = { + scope:actor = { + if = { + limit = { is_ai = no } + show_as_tooltip = { + exaltation_of_pain_wound_courtier_effect = { + ACTOR = scope:actor + TARGET = scope:recipient + } + } + trigger_event = religious_interaction.2620 + } + else = { + if = { + limit = { scope:recipient = { is_ai = no } } + scope:recipient = { + trigger_event = religious_interaction.2620 + } + } + else = { + exaltation_of_pain_wound_courtier_effect = { + ACTOR = scope:actor + TARGET = scope:recipient + } + } + } + } + } + + ai_targets = { + ai_recipients = courtiers + } + + ai_target_quick_trigger = { + adult = yes + } + + ai_frequency_by_tier = { + barony = 0 + county = 240 + duchy = 240 + kingdom = 240 + empire = 240 + hegemony = 240 + } + + ai_will_do = { + base = -100 + # Let players choose any valid courtier; keep the AI away from characters whose loss harms the realm. + modifier = { + factor = 0 + scope:recipient = { + is_close_or_extended_family_of = scope:actor + } + } + modifier = { + factor = 0 + scope:recipient = { + is_heir_of = scope:actor + } + } + modifier = { + factor = 0 + scope:recipient = { + is_councillor_of = scope:actor + } + } + modifier = { + factor = 0 + scope:recipient = { + is_knight_of = scope:actor + } + } + modifier = { + factor = 0 + scope:recipient = { + has_any_court_position = yes + } + } + ai_value_modifier = { + ai_compassion = tiny_chance_impact_negative_ai_value + } + opinion_modifier = { + opinion_target = scope:recipient + multiplier = -0.5 + } + modifier = { + add = ai_zeal + has_trait = zealous + } + modifier = { + add = 25 + OR = { + has_trait = flagellant + has_trait = sadistic + } + } + } +} + +debug_force_next_realm_priest_interaction = { + icon = religious + category = interaction_debug_pam + common_interaction = yes + + auto_accept = yes + + populate_recipient_list = { + scope:actor = { + every_courtier = { + limit = { + faith = scope:recipient.faith + } + + add_to_list = characters + } + } + } + + is_shown = { + debug_only = yes + scope:puppet_or_actor ?= { + religion = religion:christianity_religion + } + } + + on_accept = { + scope:recipient = { + council_task:councillor_court_chaplain = { + force_next_councillor = scope:secondary_recipient + } + } + } +} + +#Ask to take the vows to join an actual monastic order +#By Friar Jason Cantalini +take_monastic_vows_interaction = { + category = interaction_category_vassal + icon = religious + filter_tags = { holy_order } + + ai_maybe = yes + ai_min_reply_days = 4 + ai_max_reply_days = 9 + #Commented out on other version, so commented out here + #can_send_despite_rejection = yes + popup_on_receive = yes + pause_on_receive = yes + common_interaction = yes + + populate_recipient_list = { + scope:puppet_or_actor.faith = { + every_faith_holy_order = { + limit = { + take_the_vows_valid_monastic_order_trigger = { CHARACTER = scope:puppet_or_actor } + } + leader = { + add_to_list = characters + } + } + } + } + + cooldown_against_recipient = { years = 10 } + + desc = take_monastic_vows_interaction_desc + + on_decline_summary = { + triggered_desc = { + trigger = { NOT = { scope:actor = scope:puppet_or_actor } } + desc = take_vows_decline_summary_puppeteer + } + triggered_desc = { + trigger = { scope:actor = scope:puppet_or_actor } + desc = take_vows_decline_summary + } + } + + greeting = negative + notification_text = REQUEST_MONASTIC_VOWS_NOTIFICATION_TEXT + prompt = TAKE_THE_VOWS_SELECT_HOLY_ORDER_LEADER + + + is_available = { + trigger_if = { + limit = { is_ai = yes } + piety >= major_piety_value + is_adult = yes + } + } + + is_shown = { + #have a monastic order to send char to + scope:puppet_or_actor ?= { + faith ?= { + any_faith_holy_order = { + take_the_vows_valid_monastic_order_trigger = { CHARACTER = scope:puppet_or_actor } + } + } + #Not your bishop + NOT = { any_learning_councillor = { this = scope:recipient } } + take_vows_available_trigger = yes + } + scope:recipient = { + is_courtier_of = scope:puppet_or_actor + NOR = { + has_trait = devoted + has_trait = order_member + } + } + trigger_if = { + limit = { + scope:actor = { + is_ai = yes + } + } + scope:recipient = { + is_close_or_extended_family_of = scope:puppet_or_actor + NOR = { + exists = betrothed + is_married = yes + is_primary_heir_of = scope:puppet_or_actor + } + } + } + } + + is_valid_showing_failures_only = { + trigger_if = { + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + piety >= scope:recipient.ask_to_take_vows_piety_cost + } + } + trigger_if = { + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + dynasty ?= { dynasty_prestige >= take_vows_dynasty_prestige_cost_value } + } + } + scope:recipient = { + age >= 10 + is_courtier_of = scope:puppet_or_actor + can_take_religious_vows_trigger = yes #Triggers that applies to both Monastery or Military Order requirements + } + custom_tooltip = { + text = cannot_take_overt_hostile_actions_against_diarch.tt + NOT = { scope:recipient ?= scope:puppet_or_actor.diarch } + } + scope:puppet_or_actor = { + NOT = { + has_character_modifier = promised_pilgrimage_to_clergy_modifier + } + } + trigger_if = { + limit = { + scope:secondary_recipient ?= { + has_realm_law = female_monastic_holy_order_succession_law + } + } + custom_tooltip = { + text = female_monastic_order_not_female_tt + scope:recipient = { + is_female = yes + } + } + } + trigger_if = { + limit = { + scope:secondary_recipient ?= { + has_realm_law = male_monastic_holy_order_succession_law + } + } + custom_tooltip = { + text = male_monastic_order_not_male_tt + scope:recipient = { + is_male = yes + } + } + } + } + + #Use hook + auto_accept = { + trigger_if = { + limit = { scope:simony_paid_vows = yes } + custom_description = { + text = PAM_TAKE_VOWS_GOLD_AUTO_ACCEPT + object = scope:recipient + always = yes + } + } + trigger_else = { + custom_description = { + text = "spending_hook" + subject = scope:puppet_or_actor + object = scope:recipient + scope:hook = yes + scope:puppet_or_actor = { has_strong_hook = scope:recipient } + } + } + } + + send_option = { + is_valid = { + scope:puppet_or_actor = { + has_usable_hook = scope:recipient + } + } + flag = hook + localization = SCHEME_HOOK + } + #DEMAND that they take the vows + send_option = { + is_valid = { + scope:recipient.liege ?= scope:puppet_or_actor + scope:puppet_or_actor = { + #AI can't be trusted with the ramifications of this + scope:actor = { is_ai = no } + custom_tooltip = { + text = parent_or_dynast_tt + OR = { + is_parent_of = scope:recipient + AND = { + exists = scope:puppet_or_actor.dynasty + is_dynast = yes + scope:recipient.dynasty ?= scope:puppet_or_actor.dynasty + } + } + } + + } + } + flag = demand + localization = INTERACTION_DEMAND_VOWS + } + send_option = { + is_shown = { + scope:actor = { + is_ai = no + } + } + is_valid = { + custom_tooltip = { + text = PAM_TAKE_VOWS_GOLD_OPTION_REQUIRES_SIMONY + scope:puppet_or_actor = { + rite = { + rite_has_parameter = tenet_simony_paid_vows + } + } + } + scope:puppet_or_actor = { + gold >= major_gold_value + } + } + flag = simony_paid_vows + localization = PAM_TAKE_VOWS_GOLD_OPTION + } + should_use_extra_icon = { + scope:puppet_or_actor = { has_usable_hook = scope:recipient } + } + extra_icon = "gfx/interface/icons/character_interactions/hook_icon.dds" + + send_options_exclusive = no + + cost = { + piety = { + value = scope:recipient.ask_to_take_vows_piety_cost + if = { + limit = { scope:is_puppet_action ?= yes } + multiply = 0 + } + } + renown = { + value = take_vows_dynasty_prestige_cost_value + if = { + limit = { scope:is_puppet_action ?= yes } + multiply = 0 + } + } + gold = { + value = 0 + if = { + limit = { scope:simony_paid_vows = yes } + add = scope:puppet_or_actor.major_gold_value + } + } + } + + on_send = { + scope:secondary_recipient = { + save_scope_as = archabbot + } + scope:recipient = { + set_variable = { + name = vows_piety_spent + value = ask_to_take_vows_piety_cost + days = 10 + } + } + } + + on_accept = { + if = { + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + add_piety = { + value = { + add = scope:recipient.ask_to_take_vows_piety_cost + max = piety + multiply = -1 + } + } + if = { + limit = { take_vows_dynasty_prestige_cost_value > 0 } + dynasty ?= { + add_dynasty_prestige = { + value = { + value = take_vows_dynasty_prestige_cost_value + multiply = -1 + } + } + } + } + } + } + scope:secondary_recipient = { + save_scope_as = archabbot + } + scope:puppet_or_actor = { + if = { + limit = { scope:hook = yes } + use_hook = scope:recipient + } + + #You demanded compliance as parent or dynasty head... you get it, but at a cost + if = { + limit = { + scope:demand = yes + } + scope:puppet_or_actor = { + show_as_tooltip = { + take_vows_demand_effect = yes + } + } + } + + show_as_tooltip = { + send_child_to_monastic_order_effect = yes + } + take_vows_faith_opinion_effect = yes + reverse_add_opinion = { + target = scope:archabbot + modifier = pleased_opinion + opinion = 25 + } + scope:recipient = { + if = { + limit = { + OR = { + scope:demand ?= yes + AND = { + is_imprisoned_by = scope:puppet_or_actor + OR = { + is_heir_of = scope:puppet_or_actor + any_claim = { + exists = this + } + } + } + } + } + add_opinion = { + modifier = forced_taking_vows + target = scope:puppet_or_actor + } + } + else = { + add_opinion = { + modifier = demanded_taking_vows + target = scope:puppet_or_actor + } + } + kick_from_court_interaction_warning_tooltip_effect = yes + } + trigger_event = holy_order.2020 + } + + hidden_effect = { + scope:recipient = { + remove_variable = vows_piety_spent + } + } + + # If we're a clan this interaction affects unity + add_clan_unity_interaction_effect = { + CHARACTER = scope:puppet_or_actor + TARGET = scope:recipient + VALUE = minor_unity_gain + DESC = clan_unity_take_vows.desc + REVERSE_NON_HOUSE_TARGET = no + } + scope:recipient = { + if = { + limit = { + is_adult = no + has_focus = education_learning + } + custom_tooltip = take_vows_improve_education_learning_tt + } + if = { + limit = { + is_adult = no + has_focus = education_stewardship + } + custom_tooltip = take_vows_improve_education_stewardship_tt + } + } + scope:puppet_or_actor = { + if = { + limit = { + faith = { + any_faith_holy_order = { + leader = scope:secondary_recipient + holy_order_patron = scope:puppet_or_actor + } + } + } + custom_tooltip = take_vows_patron_boost_monk_xp_tt + } + } + } + + on_decline = { + scope:puppet_or_actor = { + #You demanded compliance as parent or dynasty head... you get it, but at a cost + if = { + limit = { + scope:demand = yes + } + scope:puppet_or_actor = { + show_as_tooltip = { + take_vows_demand_effect = yes + } + } + } + } + scope:recipient = { + add_opinion = { + target = scope:puppet_or_actor + modifier = asked_me_to_take_vows_opinion + years = 10 + } + } + #Letter event informing the character about the rejection. + scope:puppet_or_actor = { + trigger_event = { + id = religious_interaction.1031 + } + } + + # Refund piety cost + show_as_tooltip = { + scope:puppet_or_actor = { + add_piety_no_experience = { + value = scope:recipient.ask_to_take_vows_piety_cost + } + } + } + # Refund piety cost + hidden_effect = { + if = { + limit = { + scope:recipient = { + has_variable = vows_piety_spent + } + } + scope:puppet_or_actor = { + add_piety_no_experience = { + value = scope:recipient.var:vows_piety_spent + } + } + scope:recipient = { + remove_variable = vows_piety_spent + } + } + } + + # If we're a clan this interaction affects unity + add_clan_unity_interaction_effect = { + CHARACTER = scope:puppet_or_actor + TARGET = scope:recipient + VALUE = minor_unity_loss + DESC = clan_unity_refused_to_take_vows.desc + REVERSE_NON_HOUSE_TARGET = no + } + } + + auto_accept = no + + ai_accept = { + base = 0 # Try to make it 0 for most interactions + + modifier = { + scope:hook = yes + add = 50 + desc = SCHEME_WEAK_HOOK_USED + } + modifier = { + add = 50 + scope:demand = yes + desc = liege_demands_vow_taking + } + opinion_modifier = { # Opinion Factor + who = scope:recipient + opinion_target = scope:puppet_or_actor + multiplier = 0.25 + desc = AI_SIMPLE_OPINION_REASON + } + modifier = { + add = ai_zeal + ai_zeal < 0 + desc = TAKE_THE_VOWS_SKEPTIC + } + modifier = { + add = { + value = ai_zeal + divide = 2 + } + ai_zeal > 0 + desc = TAKE_THE_VOWS_ZEALOUS + } + modifier = { + add = { + value = ai_greed + multiply = -1 + } + ai_greed > 0 + desc = TAKE_THE_VOWS_GREED + } + modifier = { + add = { + value = ai_boldness + multiply = -1 + } + ai_boldness < 0 + desc = TAKE_THE_VOWS_COWARDLINESS + } + modifier = { + add = { + value = ai_boldness + multiply = -0.5 + } + ai_boldness > 0 + desc = TAKE_THE_VOWS_BOLDNESS + } + modifier = { + add = 20 + dynasty ?= scope:puppet_or_actor.dynasty + scope:puppet_or_actor.faith = { + any_faith_holy_order = { + leader = scope:secondary_recipient + holy_order_patron = scope:puppet_or_actor + } + } + desc = TAKE_THE_VOWS_MONASTIC_PATRON + } + modifier = { + add = 5 + scope:puppet_or_actor.faith = { + any_faith_holy_order = { + leader = scope:secondary_recipient + any_leased_title = { + county.holder ?= scope:puppet_or_actor + } + } + } + desc = TAKE_THE_VOWS_NEAR_ORDER + } + modifier = { + add = -15 + NOT = { + scope:puppet_or_actor.faith = { + any_faith_holy_order = { + leader = scope:secondary_recipient + any_leased_title = { + county.holder.top_liege ?= { + this = scope:puppet_or_actor.top_liege + } + } + } + } + } + desc = TAKE_THE_VOWS_DISTANT_ORDER + } + modifier = { + add = 70 + scope:recipient = { + age >= 45 + is_visibly_fertile = no + NOT = { + any_heir_title = { + exists = holder + } + } + } + desc = TAKE_THE_VOWS_RETIRE_IN_CHURCH + } + modifier = { + add = 50 + exists = scope:puppet_or_actor.cp:councillor_court_chaplain + scope:recipient = { + OR = { + has_relation_lover = scope:puppet_or_actor.cp:councillor_court_chaplain + has_relation_friend = scope:puppet_or_actor.cp:councillor_court_chaplain + has_secret_relation_lover = scope:puppet_or_actor.cp:councillor_court_chaplain + has_relation_soulmate = scope:puppet_or_actor.cp:councillor_court_chaplain + has_relation_best_friend = scope:puppet_or_actor.cp:councillor_court_chaplain + opinion = { + target = scope:puppet_or_actor.cp:councillor_court_chaplain + value >= very_high_positive_opinion + } + } + } + desc = TAKE_THE_VOWS_INSPIRING_COURT_CHAPLAIN + } + modifier = { + add = 50 + scope:recipient = { + OR = { + any_relation = { + type = friend + is_clergy = yes + } + any_relation = { + type = best_friend + is_clergy = yes + } + any_relation = { + type = lover + is_clergy = yes + } + any_relation = { + type = soulmate + is_clergy = yes + } + any_relation = { + type = crush + is_clergy = yes + } + any_secret = { + type = secret_lover + secret_target = { + is_clergy = yes + } + } + } + } + desc = TAKE_THE_VOWS_INSPIRING_CLERGY + } + modifier = { + add = 50 + scope:recipient = { + has_education_learning_trigger = yes + } + desc = TAKE_THE_VOWS_LEARNING_EDUCATION + } + + modifier = { + add = { + add = 20 + multiply = scope:recipient.num_virtuous_traits + } + scope:recipient.num_virtuous_traits > 0 + desc = TAKE_THE_VOWS_VIRTUOUS + } + + modifier = { + add = { + add = -20 + multiply = scope:recipient.num_sinful_traits + } + scope:recipient.num_sinful_traits > 0 + desc = TAKE_THE_VOWS_SINFUL + } + + #Positive Personality Modifiers + modifier = { # Wants to help people + add = { + value = ai_compassion + divide = 2 + } + scope:recipient = { + ai_compassion > 0 + has_trait = lifestyle_physician + } + desc = TAKE_THE_VOWS_PHYSICIAN_WANTS_TO_HELP + } + modifier = { + add = 1200 + scope:recipient = { + has_trait = reclusive + } + desc = TAKE_THE_VOWS_RECLUSIVE + } + modifier = { + add = 25 + scope:recipient = { + has_trait = curious + } + desc = TAKE_THE_VOWS_CURIOUS + } + modifier = { + add = 50 + scope:recipient = { + has_trait = pensive + } + desc = TAKE_THE_VOWS_PENSIVE + } + modifier = { # Loves books & knowledge! + add = 20 + scope:recipient = { + has_trait = lifestyle_mystic + } + desc = TAKE_THE_VOWS_MYSTIC + } + modifier = { # Loves books & knowledge! + add = 20 + scope:recipient = { + has_trait = erudite + } + desc = TAKE_THE_VOWS_ERUDITE + } + modifier = { # Loves books & knowledge! + add = 20 + scope:recipient = { + has_trait = theologian + } + desc = TAKE_THE_VOWS_THEOLOGIAN + } + modifier = { # Plants! + add = 20 + scope:recipient = { + has_trait = lifestyle_herbalist + } + desc = TAKE_THE_VOWS_HERBALIST + } + modifier = { + add = 25 + scope:recipient = { + has_trait = temperate + } + desc = TAKE_THE_VOWS_TEMPERATE + } + modifier = { + add = 100 + scope:recipient = { + has_trait = celibate + } + desc = TAKE_THE_VOWS_CELIBATE + } + modifier = { + add = 40 + scope:recipient = { + has_trait = chaste + } + desc = TAKE_THE_VOWS_CHASTE + } + modifier = { + add = 25 + scope:recipient = { + has_trait = content + } + desc = TAKE_THE_VOWS_CONTENT + } + modifier = { + add = 25 + scope:recipient = { + has_trait = humble + } + desc = TAKE_THE_VOWS_HUMBLE + } + modifier = { + add = 10 + scope:recipient = { + has_trait = drunkard + } + desc = TAKE_THE_VOWS_DRUNKARD + } + modifier = { + add = 10 + scope:recipient = { + has_trait = hashishiyah + } + desc = TAKE_THE_VOWS_HASHISHIYAH + } + modifier = { + add = 50 + scope:recipient = { + has_trait = trusting + } + desc = TAKE_THE_VOWS_TRUSTING + } + + #Negative Personality Modifiers + modifier = { + add = -50 + scope:recipient = { + has_trait = rowdy + } + desc = TAKE_THE_VOWS_ROWDY + } + modifier = { + add = -25 + scope:recipient = { + has_trait = bossy + } + desc = TAKE_THE_VOWS_BOSSY + } + modifier = { + add = -20 + scope:recipient = { + has_trait = gluttonous + } + desc = TAKE_THE_VOWS_GLUTTONOUS + } + modifier = { + add = -20 + scope:recipient = { + has_trait = lustful + } + desc = TAKE_THE_VOWS_LUSTFUL + } + modifier = { + add = -500 + scope:recipient = { + has_trait = pregnant + } + desc = TAKE_THE_VOWS_PREGNANT + } + modifier = { + add = -500 + scope:recipient = { + has_trait = ambitious + } + desc = TAKE_THE_VOWS_AMBITIOUS + } + + modifier = { + add = -50 + scope:recipient = { + OR = { + is_married = yes + exists = betrothed + } + } + desc = TAKE_THE_VOWS_MARRIED_OR_BETROTHED + } + + modifier = { + add = -150 + scope:recipient = { + is_primary_heir_of = scope:puppet_or_actor + } + desc = TAKE_THE_VOWS_PRIMARY_HEIR + } + + modifier = { + add = -75 + scope:recipient = { + NOT = { + is_primary_heir_of = scope:puppet_or_actor + } + } + scope:puppet_or_actor.primary_title = { + place_in_line_of_succession = { + target = prev + value = 2 + } + } + desc = TAKE_THE_VOWS_SECOND_HEIR + } + + modifier = { + add = -50 + scope:recipient = { + NOT = { + is_primary_heir_of = scope:puppet_or_actor + } + } + scope:puppet_or_actor.primary_title = { + place_in_line_of_succession = { + target = prev + value = 3 + } + } + desc = TAKE_THE_VOWS_THIRD_HEIR + } + + modifier = { + add = -25 + scope:recipient = { + NOT = { + is_primary_heir_of = scope:puppet_or_actor + } + } + scope:puppet_or_actor.primary_title = { + place_in_line_of_succession = { + target = prev + value >= 4 + value <= 10 + } + } + desc = TAKE_THE_VOWS_HEIR + } + + modifier = { + add = -100 + scope:recipient = { + NOT = { is_heir_of = scope:puppet_or_actor } + any_heir_title = { + exists = holder + holder != scope:puppet_or_actor + } + NOT = { + is_primary_heir_of = scope:puppet_or_actor + } + } + desc = TAKE_THE_VOWS_HEIR_TO_OTHER_TITLE + } + + modifier = { + add = -50 + scope:recipient = { + NOT = { is_heir_of = scope:puppet_or_actor } + any_parent = { + any_held_title = { + place_in_line_of_succession = { + target = scope:recipient + value < 5 + } + NOT = { + place_in_line_of_succession = { + target = scope:recipient + value < 2 + } + } + } + } + NOT = { + is_primary_heir_of = scope:puppet_or_actor + } + } + desc = TAKE_THE_VOWS_IN_LINE_TO_OTHER_TITLE + } + + modifier = { #Rivalry modifier. + desc = offer_vassalization_interaction_aibehavior_rival_tt + trigger = { + scope:recipient = { + has_relation_rival = scope:puppet_or_actor + NOT = { has_relation_nemesis = scope:puppet_or_actor } + } + } + add = -50 + } + modifier = { #Nemesis modifier. + desc = offer_vassalization_interaction_aibehavior_nemesis_tt + trigger = { + scope:recipient = { + has_relation_nemesis = scope:puppet_or_actor + } + } + add = -100 + } + + #Dread modifiers + modifier = { + add = 25 + scope:recipient = { + has_dread_level_towards = { + target = scope:puppet_or_actor + level = 1 + } + } + desc = INTIMIDATED_REASON + } + modifier = { + add = 50 + scope:recipient = { + has_dread_level_towards = { + target = scope:puppet_or_actor + level = 2 + } + } + desc = COWED_REASON + } + + # Culture Tradition modifiers + + modifier = { + add = { + value = 25 + if = { + limit = { + scope:recipient = { + is_adult = no + is_child_of = scope:puppet_or_actor + } + } + add = 100 + } + } + scope:puppet_or_actor.culture = { has_cultural_parameter = monastic_expectations } + desc = MONASTIC_EXPECTATIONS_REASON + } + + # PAM - Concord Phase + modifier = { + add = 25 + situation:the_christian_church ?= { + any_participant_group = { # Both characters are involved in the situation + any_situation_group_participant = { + this = scope:puppet_or_actor + } + trigger_if = { + limit = { scope:recipient = { is_ruler = yes } } + any_situation_group_participant = { + this = scope:recipient + } + } + } + has_situation_top_phase_parameter = the_christian_church_better_take_the_vows_acceptance + } + desc = pam_the_christian_church_better_take_the_vows_acceptance_desc + } + } + + # AI will do + + ai_target_quick_trigger = { + adult = yes + } + + ai_targets = { + ai_recipients = courtiers + max = 5 + } + + ai_targets = { + ai_recipients = children + max = 5 + } + + ai_frequency_by_tier = { + barony = 0 + county = 144 + duchy = 72 + kingdom = 24 + empire = 24 + hegemony = 24 + } + + ai_will_do = { + base = 0 + + modifier = { + add = -50 + scope:puppet_or_actor = { + OR = { + legitimacy_level = 0 + legitimacy_level = 1 + } + } + scope:recipient = { is_primary_heir_of = scope:puppet_or_actor } + } + + modifier = { # The AI will always use a Hook + scope:hook = yes + add = 1 + } + + modifier = { # Try to send rivals + add = 100 + scope:puppet_or_actor = { + OR = { + has_relation_rival = scope:recipient + has_relation_nemesis = scope:recipient + } + } + } + modifier = { # Has cloister to send the child to + scope:puppet_or_actor.domicile ?= { has_domicile_parameter = estate_cloister_take_vows } + add = { + value = scope:puppet_or_actor.learning + add = scope:puppet_or_actor.diplomacy + multiply = 0.5 + } + desc = demand_child_as_monk_ai_priest_cloister + } + modifier = { # Try to send people who would make poor heirs + add = 20 + scope:recipient = { + is_child_of = scope:actor + OR = { + character_considered_morally_dubious_trigger = { RITE = scope:puppet_or_actor.rite } + has_trait = drunkard + has_trait = hashishiyah + has_trait = flagellant + has_trait = reclusive + num_of_bad_genetic_traits = 1 + num_sinful_traits = 1 + } + scope:puppet_or_actor.primary_title = { + place_in_line_of_succession = { + target = prev + value <= 7 + } + } + } + } + modifier = { # Try to send people who would make terrible heirs + add = 50 + scope:recipient = { + is_child_of = scope:actor + OR = { + character_considered_wicked_trigger = { RITE = scope:puppet_or_actor.rite } + has_trait = maimed + num_of_bad_genetic_traits >= 2 + num_sinful_traits >= 2 + } + scope:puppet_or_actor.primary_title = { + place_in_line_of_succession = { + target = prev + value <= 7 + } + } + } + } + + modifier = { # Try to send people who would make poor heirs + add = 25 + scope:recipient = { + is_child_of = scope:actor + calc_true_if = { + amount >= 3 + + diplomacy < 8 + stewardship < 8 + martial < 8 + intrigue < 8 + learning < 8 + } + scope:puppet_or_actor.primary_title = { + place_in_line_of_succession = { + target = prev + value <= 7 + } + } + } + } + + modifier = { # Sending one of your heirs is almost customary + add = 100 + scope:recipient = { + is_child_of = scope:puppet_or_actor + has_education_learning_trigger = yes + } + scope:puppet_or_actor = { + any_child = { + count >= 3 + } + NOT = { + any_child = { + OR = { + has_trait = devoted + has_trait = order_member + } + } + } + } + } + + modifier = { # is not patron of the order + add = -10 + NOT = { + scope:secondary_recipient.holy_order ?= { + holy_order_patron = scope:puppet_or_actor + } + } + } + modifier = { # order is in domain + add = 20 + scope:secondary_recipient.holy_order ?= { + any_leased_title = { + county.holder = scope:puppet_or_actor + } + } + } + modifier = { # order is not in realm or de jure kingdom + add = -20 + scope:secondary_recipient.holy_order ?= { + NOR = { + any_leased_title = { + county.holder.top_liege = scope:puppet_or_actor.top_liege + } + any_leased_title = { + kingdom ?= scope:puppet_or_actor.capital_county.kingdom + } + } + } + } + modifier = { # order is not in diplomatic range + add = -50 + scope:secondary_recipient = { + NOT = { + in_diplomatic_range = scope:puppet_or_actor + } + } + } + modifier = { # is patron of the order + add = 30 + scope:secondary_recipient.holy_order ?= { + holy_order_patron = scope:puppet_or_actor + } + } + + modifier = { # Zealous characters generally want to send characters to the clergy + add = 50 + scope:puppet_or_actor = { + ai_zeal >= high_positive_ai_value + } + scope:recipient = { + has_education_learning_trigger = yes + } + } + + modifier = { # Greedy characters want to rid their court of potential threats + add = 50 + scope:puppet_or_actor = { + ai_greed >= medium_positive_ai_value + any_child = { } + } + scope:recipient = { + NOT = { + is_child_of = scope:puppet_or_actor + } + any_claim = { + holder ?= scope:puppet_or_actor + } + } + } + + #if you have personal tenet and are religion nerd + modifier = { + add = 20 + exists = scope:secondary_recipient.holy_order.order_tenet + any_personal_tenet = { + this = scope:secondary_recipient.holy_order.order_tenet + } + OR = { + piety_level >= 3 + has_education_learning_trigger = yes + rite.head_of_rite ?= this + } + } + + #if you have personal tenet + modifier = { + add = 10 + exists = scope:secondary_recipient.holy_order.order_tenet + any_personal_tenet = { + this = scope:secondary_recipient.holy_order.order_tenet + } + } + + modifier = { + factor = 1.25 + exists = capital_county.kingdom + exists = scope:secondary_recipient.capital_county.kingdom + capital_county.kingdom = scope:secondary_recipient.capital_county.kingdom + } + + modifier = { + factor = 0.1 + exists = scope:secondary_recipient + rite != scope:secondary_recipient.rite + } + + modifier = { + factor = 0.1 + OR = { + #Don't want to send to faraway orders + NOT = { + scope:secondary_recipient.holy_order = { + any_leased_title = { + trigger_if = { + limit = { + exists = scope:target + } + empire = scope:target.empire + } + trigger_else = { + empire = scope:puppet_or_actor.capital_county.empire + } + } + } + } + #You think their tenet is bad and dumb + AND = { + exists = scope:secondary_recipient.holy_order.order_tenet + NOR = { + scope:puppet_or_actor = { + any_personal_tenet = { + this = scope:secondary_recipient.holy_order.order_tenet + } + any_desired_tenet = { + selection_count = 30 + only_positive = yes + threshold = 1 + this = scope:secondary_recipient.holy_order.order_tenet + } + } + } + } + } + } + } +} + +#Donate to Monastic Orders in exchange for spiritual fulfillment +#By Brother Jason +monastic_donation_interaction = { + category = interaction_category_religion + icon = request_funding_interaction + filter_tags = { holy_order } + + ai_min_reply_days = 3 + ai_max_reply_days = 6 + common_interaction = yes + + cooldown_against_recipient = { years = 5 } + + desc = monastic_donation_interaction_desc + + greeting = positive + notification_text = MONASTIC_DONATION_NOTIFICATION_TEXT + + + is_available = { + trigger_if = { + limit = { is_ai = yes } + short_term_gold > major_gold_value + spiritual_fulfillment < 0 + } + } + + is_shown = { + scope:puppet_or_actor ?= { + faith ?= { + any_faith_holy_order = { + leader = scope:recipient + } + } + NOT = { + government_has_flag = government_is_monastic_holy_order + } + } + scope:recipient = { + is_ruler = yes + in_diplomatic_range = scope:puppet_or_actor + government_has_flag = government_is_monastic_holy_order + } + } + + is_valid_showing_failures_only = { + scope:puppet_or_actor = { + is_imprisoned = no + trigger_if = { + limit = { + has_treasury = yes + government_has_flag = government_is_theocracy + } + treasury >= monastic_donation_treasury_value + } + trigger_else = { + gold >= monastic_donation_value + } + + } + #Monastic holding's leases are all in realms actor is at war with + custom_tooltip = { + text = monastic_holdings_in_hostile_realms_tt + scope:puppet_or_actor.faith = { + any_faith_holy_order = { + leader = scope:recipient + any_leased_title = { + NOT = { + county.holder = { + OR = { + is_at_war_with = scope:puppet_or_actor + any_liege_or_above = { + is_at_war_with = scope:puppet_or_actor + } + } + } + } + } + } + } + } + #Holdings are all too far away + custom_tooltip = { + text = monastic_holdings_too_distant_tt + scope:puppet_or_actor.faith = { + any_faith_holy_order = { + leader = scope:recipient + holy_order_range_trigger = { CHARACTER = scope:puppet_or_actor } + } + } + } + scope:puppet_or_actor = { + NOT = { + has_character_modifier = promised_pilgrimage_to_clergy_modifier + } + } + } + # Use hook + send_option = { + is_valid = { + scope:puppet_or_actor = { + has_usable_hook = scope:recipient + } + NOT = { + scope:recipient = { is_imprisoned_by = scope:puppet_or_actor } + } + } + flag = hook + localization = SCHEME_HOOK + } + + #Use hook + auto_accept = { + custom_description = { + text = "spending_hook" + subject = scope:puppet_or_actor + object = scope:recipient + scope:hook = yes + scope:puppet_or_actor = { has_strong_hook = scope:recipient } + } + } + + + #Humiliate self + send_option = { + is_valid = { + custom_tooltip = { + text = low_piety_or_spiritual_fulfillment_tt + scope:puppet_or_actor = { + OR = { + piety_level = 0 + has_fulfillment_parameter = sp_ceremonial_humbling + } + } + } + scope:puppet_or_actor = { + trigger_if = { + limit = { + scope:actor = { is_ai = yes } + } + OR = { + AND = { + prestige >= monumental_prestige_value + has_fulfillment_parameter = sp_ceremonial_humbling + } + spiritual_fulfillment <= spiritual_fulfillment_minus_3 + } + } + } + + } + flag = ceremonial_humbling + localization = INTERACTION_CEREMONIAL_HUMBLING + } + #HUGE DONATION + send_option = { + is_valid = { + scope:puppet_or_actor = { + trigger_if = { + limit = { + has_treasury = yes + government_has_flag = government_is_theocracy + } + treasury >= monastic_huge_donation_treasury_value + } + trigger_else = { + gold >= monastic_huge_donation_value + } + #AI further restrictions + trigger_if = { + limit = { + scope:actor = { is_ai = yes } + } + trigger_if = { + limit = { + has_treasury = yes + government_has_flag = government_is_theocracy + } + short_term_treasury >= monastic_huge_donation_treasury_value + } + trigger_else = { + short_term_gold >= monastic_huge_donation_value + } + spiritual_fulfillment < spiritual_fulfillment_minus_1 + } + } + } + flag = huge_donation + localization = INTERACTION_HUGE_DONATION + } + should_use_extra_icon = { + scope:puppet_or_actor = { has_usable_hook = scope:recipient } + } + extra_icon = "gfx/interface/icons/character_interactions/hook_icon.dds" + + send_options_exclusive = no + + cost = { + } + + on_send = { + } + + on_accept = { + show_as_tooltip = { + donate_to_monastic_order_effect = yes + scope:recipient = { + custom_tooltip = monk_can_use_money_for_actions_tt + } + } + scope:puppet_or_actor = { + trigger_event = { + id = holy_order.2030 + } + } + } + + on_decline = { + #Letter event informing you about decline + scope:puppet_or_actor = { + trigger_event = { + id = holy_order.2031 + } + } + } + + auto_accept = no + + ai_accept = { + base = 0 # Try to make it 0 for most interactions + + celestial_hierarchy_acceptance_modifier = { + ACTOR = scope:puppet_or_actor + RECIPIENT = scope:recipient + } + + modifier = { + scope:hook = yes + add = 100 + desc = SCHEME_WEAK_HOOK_USED + } + modifier = { + add = 50 + scope:huge_donation = yes + desc = monastic_huge_donation_acceptance + } + modifier = { + add = 150 + scope:ceremonial_humbling = yes + desc = monastic_humbling_acceptance + } + opinion_modifier = { # Opinion Factor + who = scope:recipient + opinion_target = scope:puppet_or_actor + multiplier = 0.25 + desc = AI_SIMPLE_OPINION_REASON + } + #Personality + modifier = { + add = { + value = scope:puppet_or_actor.ai_zeal + divide = 5 + } + ai_zeal != 0 + desc = INTERACTION_AI_ZEAL + } + modifier = { + ai_greed > 0 + add = ai_greed + desc = INTERACTION_RECIPIENT_AI_GREED_HIGH + } + #Relationship stuff + + #Close family member + modifier = { + is_close_family_of = scope:puppet_or_actor + add = 50 + desc = is_close_family_reason + } + #House member + modifier = { + exists = scope:puppet_or_actor.house + house ?= scope:puppet_or_actor.house + add = 50 + desc = AI_SAME_HOUSE_REASON + } + modifier = { + exists = scope:puppet_or_actor.house + NOT = { house ?= scope:puppet_or_actor.house } + dynasty ?= scope:puppet_or_actor.dynasty + add = 20 + desc = AI_SAME_DYNASTY_REASON + } + #You are house head + modifier = { + exists = scope:puppet_or_actor.house + house.house_head ?= scope:puppet_or_actor + add = 50 + desc = AI_YOU_ARE_THE_HOUSE_HEAD + } + modifier = { + exists = scope:puppet_or_actor.house + NOT = { house.house_head ?= scope:puppet_or_actor } + dynasty.dynast ?= scope:puppet_or_actor + add = 25 + desc = AI_YOU_ARE_THE_DYNAST + } + #Leases holdings from char + modifier = { + faith = { + any_faith_holy_order = { + leader = scope:recipient + any_leased_title = { + county.holder = scope:puppet_or_actor + } + } + } + add = 25 + desc = INTERACTION_LEASES_HOLDINGS + } + #Shared rite + modifier = { + add = 25 + exists = scope:puppet_or_actor.rite + scope:recipient.rite ?= scope:puppet_or_actor.rite + desc = I_HAVE_THE_SAME_RITE + } + modifier = { + add = -25 + exists = scope:puppet_or_actor.rite + exists = scope:recipient.rite + # Same medium_rite_divergence step the donor uses + scope:puppet_or_actor.rite = { + "divergence(scope:recipient.rite)" >= medium_rite_divergence_value + } + desc = I_HAVE_A_DIFFERENT_RITE + } + #The donor's rite forbids the very tenet the order was founded on + modifier = { + add = -100 + exists = scope:recipient.holy_order.order_tenet + scope:puppet_or_actor.rite ?= { + has_tenet_status = { + tenet = scope:recipient.holy_order.order_tenet + status = prohibited + } + } + desc = MONASTIC_DONATION_ORDER_TENET_PROHIBITED + } + #Rival + modifier = { + has_relation_rival = scope:puppet_or_actor + add = -200 + desc = ARTIFACT_RIVAL_REASON + } + + #Your tier (thus your power and size of donation) + modifier = { + scope:puppet_or_actor = { + highest_held_title_tier >= tier_duchy + } + add = { + value = scope:puppet_or_actor.highest_held_title_tier + subtract = 2 + multiply = 20 + } + desc = TITLE_TIER_REASON + } + + #Piety level + modifier = { + scope:puppet_or_actor = { + piety_level >= 2 + } + add = { + value = scope:puppet_or_actor.piety_level + subtract = 1 + multiply = 20 + } + desc = I_AM_PIOUS + } + modifier = { + scope:puppet_or_actor = { + piety_level < 1 + } + add = -50 + desc = I_AM_SINFUL + } + + #Very pious traits + modifier = { + scope:puppet_or_actor = { + OR = { + has_trait = saint + has_trait = herald + has_trait = saoshyant_descendant + has_trait = order_member + has_trait = faith_warrior + has_trait = saoshyant + has_trait = paragon + has_trait = savior + has_trait = crusader_king + } + } + add = 100 + desc = VERY_PIOUS_TRAITS_REASON + } + + #Pious traits + modifier = { + scope:puppet_or_actor = { + OR = { + has_trait = zealous + has_trait = theologian + has_trait = divine_blood + has_trait = consecrated_blood + has_trait = sayyid + } + } + add = 30 + desc = PIOUS_TRAITS_REASON + } + + #Sinful traits + modifier = { + scope:puppet_or_actor = { + OR = { + has_any_shunned_trait_in_rite_trigger = { + CHARACTER = scope:puppet_or_actor + RITE = scope:recipient.rite + } + has_trait = bastard + has_trait = gallowsbait + has_trait = decadent + } + } + add = -30 + desc = SINFUL_TRAITS_REASON + } + #Major sinful traits + modifier = { + scope:puppet_or_actor = { + OR = { + has_any_criminal_trait_in_rite_trigger = { + CHARACTER = scope:puppet_or_actor + RITE = scope:recipient.rite + } + has_trait = despoiler_of_byzantium + has_trait = incestuous + has_trait = murderer + } + } + add = -100 + desc = VERY_SINFUL_TRAITS_REASON + } + #Excommunicated + modifier = { + scope:puppet_or_actor = { + has_trait = excommunicated + } + add = -300 + desc = EXCOMMUNICATED_REASON + } + #Same rite + modifier = { + scope:puppet_or_actor.rite = scope:recipient.rite + add = 30 + desc = MONASTIC_SAME_RITE_REASON + } + #Heretical rite + modifier = { + scope:puppet_or_actor.rite = { + "divergence(scope:recipient.rite)" >= scope:recipient.faith.heresy_threshold + } + add = -100 + desc = MONASTIC_HERETICAL_RITE_REASON + } + #Personally holds the order's tenet + modifier = { + exists = scope:recipient.holy_order.order_tenet + scope:puppet_or_actor = { + any_personal_tenet = { + this = scope:recipient.holy_order.order_tenet + } + } + add = 20 + desc = MONASTIC_ORDER_TENET_REASON + } + } + + # AI will do + + ai_target_quick_trigger = { + adult = yes + } + + ai_targets = { + ai_recipients = neighboring_rulers + ai_recipients = faith_holy_order_leaders + } + + ai_frequency_by_tier = { + barony = 0 + county = 48 + duchy = 24 + kingdom = 12 + empire = 12 + hegemony = 12 + } + + ai_will_do = { + base = 0 + + modifier = { # is not patron of the order + add = -25 + NOT = { + faith = { + any_faith_holy_order = { + leader = scope:recipient + holy_order_patron = scope:puppet_or_actor + } + } + } + } + modifier = { # order is in domain + add = 20 + faith = { + any_faith_holy_order = { + leader = scope:recipient + any_leased_title = { + county.holder = scope:puppet_or_actor + } + } + } + } + modifier = { # order is not in realm or de jure kingdom + add = -40 + faith = { + any_faith_holy_order = { + leader = scope:recipient + NOR = { + any_leased_title = { + county.holder.top_liege = scope:puppet_or_actor.top_liege + } + any_leased_title = { + kingdom ?= scope:puppet_or_actor.capital_county.kingdom + } + } + } + } + } + modifier = { # order is not in diplomatic range + add = -75 + scope:recipient = { + NOT = { + in_diplomatic_range = scope:puppet_or_actor + } + } + } + modifier = { # is patron of the order + add = 30 + faith = { + any_faith_holy_order = { + leader = scope:recipient + holy_order_patron = scope:puppet_or_actor + } + } + } + + modifier = { # Zealous characters + add = 25 + scope:puppet_or_actor = { + ai_zeal >= high_positive_ai_value + } + } + + modifier = { + add = 50 + scope:puppet_or_actor = { + spiritual_fulfillment < spiritual_fulfillment_minus_1 + } + } + + modifier = { + add = 100 + scope:puppet_or_actor = { + spiritual_fulfillment < spiritual_fulfillment_minus_2 + } + } + + modifier = { + add = 100 + scope:puppet_or_actor = { + spiritual_fulfillment <= spiritual_fulfillment_minus_3 + } + } + + modifier = { + factor = 1.25 + capital_county.kingdom = scope:recipient.capital_county.kingdom + } + + modifier = { + factor = 0.5 + ai_greed >= low_positive_ai_value + } + + #if you have personal tenet and are religion nerd + modifier = { + add = 20 + exists = scope:recipient.holy_order.order_tenet + any_personal_tenet = { + this = scope:recipient.holy_order.order_tenet + } + OR = { + piety_level >= 3 + has_education_learning_trigger = yes + rite.head_of_rite ?= this + } + } + + modifier = { + factor = 0.1 + OR = { + has_trait = cynical + ai_greed >= high_positive_ai_value + #Don't want to donate to faraway orders + NOT = { + scope:recipient.holy_order = { + any_leased_title = { + trigger_if = { + limit = { + exists = scope:target + } + empire = scope:target.empire + } + trigger_else = { + empire = scope:puppet_or_actor.capital_county.empire + } + } + } + } + #You think their tenet is bad and dumb + AND = { + exists = scope:recipient.holy_order.order_tenet + scope:puppet_or_actor ?= { + NOR = { + scope:puppet_or_actor = { + any_personal_tenet = { + this = scope:recipient.holy_order.order_tenet + } + any_desired_tenet = { + selection_count = 30 + only_positive = yes + threshold = 1 + this = scope:recipient.holy_order.order_tenet + } + } + } + } + } + } + } + + modifier = { # shares the order's rite + add = 25 + scope:puppet_or_actor.rite = scope:recipient.rite + } + modifier = { # rite has diverged from the order's + add = -20 + scope:puppet_or_actor.rite = { + "divergence(scope:recipient.rite)" >= medium_rite_divergence_value + } + } + modifier = { # order is heretical to the donor, by the donor's own threshold + factor = 0.1 + scope:puppet_or_actor.rite = { + "divergence(scope:recipient.rite)" >= scope:puppet_or_actor.faith.heresy_threshold + } + } + } +} + +#Lease an additional holding to Monastic Order +# by Secular Canon Jason Cantalini +lease_title_to_existing_monastic_order_interaction = { + category = interaction_category_religion + icon = icon_scheme_study_faith + target_type = title + target_source = puppet_or_actor + target_filter = domain_titles_including_leases + # No barony-only filter exists, so hide the counties and duchies this one also offers + show_all_targets = no + filter_tags = { holy_order } + + ai_min_reply_days = 3 + ai_max_reply_days = 6 + common_interaction = yes + + desc = lease_title_to_existing_monastic_order_interaction_desc + + greeting = positive + notification_text = MONASTIC_ORDER_LEASE_NOTIFICATION_TEXT + + + is_available = { + trigger_if = { + limit = { is_ai = yes } + any_held_title = { + count >= 2 + tier = tier_county + any_county_province = { + has_holding_type = church_holding + barony ?= { + trigger_if = { + limit = { + exists = barony.lessee + } + NOT = { + barony.lessee = { + government_has_flag = government_is_monastic_holy_order + } + } + } + } + } + } + #either needs spiritual fulfillment or a monastic holy order to patron + OR = { + spiritual_fulfillment < 0 + AND = { + highest_held_title_tier >= tier_kingdom + NOT = { + any_patroned_holy_order = { + leader = { + government_has_flag = government_is_monastic_holy_order + } + } + } + } + } + is_imprisoned = no + } + } + + is_shown = { + scope:puppet_or_actor ?= { + highest_held_title_tier >= tier_county + is_landed = yes + } + scope:puppet_or_actor.faith ?= { + any_faith_holy_order = { + leader = scope:recipient + } + } + scope:recipient = { + is_ruler = yes + in_diplomatic_range = scope:puppet_or_actor + government_has_flag = government_is_monastic_holy_order + } + } + + can_be_picked_title = { + scope:target = { + tier = tier_barony + title_province = { + has_holding_type = church_holding + } + trigger_if = { + limit = { + exists = lessee + } + custom_tooltip = { + text = already_has_monastic_lease_tt + NOT = { + lessee = { + government_has_flag = government_is_monastic_holy_order + } + } + } + } + is_landless_type_title = no + } + } + + is_valid_showing_failures_only = { + scope:puppet_or_actor = { + is_imprisoned = no + } + custom_tooltip = { + text = no_valid_temple_holdings_to_lease_tt + scope:puppet_or_actor = { + any_held_title = { + tier = tier_county + any_county_province = { + has_holding_type = church_holding + NOT = { + is_county_capital = yes + } + trigger_if = { + limit = { + exists = barony.lessee + } + NOT = { + barony.lessee = { + government_has_flag = government_is_monastic_holy_order + } + } + } + } + } + } + } + #Monastic holding's leases are all in realms actor is at war with + custom_tooltip = { + text = monastic_holdings_in_hostile_realms_tt + scope:puppet_or_actor.faith = { + any_faith_holy_order = { + leader = scope:recipient + any_leased_title = { + NOT = { + county.holder = { + OR = { + is_at_war_with = scope:puppet_or_actor + any_liege_or_above = { + is_at_war_with = scope:puppet_or_actor + } + } + } + } + } + } + } + } + } + # Use hook + send_option = { + is_valid = { + scope:puppet_or_actor = { + has_usable_hook = scope:recipient + } + NOT = { + scope:recipient = { is_imprisoned_by = scope:puppet_or_actor } + } + } + flag = hook + localization = SCHEME_HOOK + } + + #Use hook + auto_accept = { + custom_description = { + text = "spending_hook" + subject = scope:puppet_or_actor + object = scope:recipient + scope:hook = yes + scope:puppet_or_actor = { has_strong_hook = scope:recipient } + } + } + #Make lavish donations to the abbey + send_option = { + is_valid = { + scope:puppet_or_actor = { + gold >= monastic_donation_value + trigger_if = { + limit = { + scope:actor = { is_ai = yes } + } + short_term_gold >= monastic_donation_value + spiritual_fulfillment < spiritual_fulfillment_minus_1 + } + } + } + flag = huge_donation + localization = INTERACTION_LEASE_DONATION + } + should_use_extra_icon = { + scope:puppet_or_actor = { has_usable_hook = scope:recipient } + } + extra_icon = "gfx/interface/icons/character_interactions/hook_icon.dds" + + send_options_exclusive = no + + cost = { + } + + on_send = { + } + + on_accept = { + # Must search puppet_or_actor.faith like is_valid, or a different-faith barony finds no order + scope:puppet_or_actor.faith = { + random_faith_holy_order = { + limit = { + leader = scope:recipient + } + save_scope_as = monastic_order + } + } + scope:target.county = { + save_scope_as = target_county + } + show_as_tooltip = { + lease_to_monastic_order_interaction_effect = yes + scope:recipient = { + custom_tooltip = monk_can_use_lease_for_actions_tt + custom_tooltip = monk_can_use_lease_region_for_actions_tt + } + } + scope:puppet_or_actor = { + trigger_event = { + id = holy_order.2040 + } + } + } + + on_decline = { + #Letter event informing you about decline + scope:puppet_or_actor = { + trigger_event = { + id = holy_order.2041 + } + } + } + + auto_accept = no + + ai_accept = { + base = 50 # Try to make it 0 for most interactions + + celestial_hierarchy_acceptance_modifier = { + ACTOR = scope:puppet_or_actor + RECIPIENT = scope:recipient + } + + modifier = { + scope:hook = yes + add = 100 + desc = SCHEME_WEAK_HOOK_USED + } + modifier = { + add = 50 + scope:huge_donation = yes + desc = monastic_huge_donation_acceptance + } + opinion_modifier = { # Opinion Factor + who = scope:recipient + opinion_target = scope:puppet_or_actor + multiplier = 0.25 + desc = AI_SIMPLE_OPINION_REASON + } + #Personality + modifier = { + add = { + value = scope:puppet_or_actor.ai_zeal + divide = 5 + } + desc = INTERACTION_AI_ZEAL + } + modifier = { + ai_greed > 0 + add = ai_greed + desc = INTERACTION_RECIPIENT_AI_GREED_HIGH + } + #Relationship stuff + + #Close family member + modifier = { + is_close_family_of = scope:puppet_or_actor + add = 50 + desc = is_close_family_reason + } + #House member + modifier = { + exists = scope:puppet_or_actor.house + house ?= scope:puppet_or_actor.house + add = 50 + desc = AI_SAME_HOUSE_REASON + } + modifier = { + exists = scope:puppet_or_actor.house + NOT = { house ?= scope:puppet_or_actor.house } + dynasty ?= scope:puppet_or_actor.dynasty + add = 20 + desc = AI_SAME_DYNASTY_REASON + } + #You are house head + modifier = { + exists = scope:puppet_or_actor.house + house.house_head ?= scope:puppet_or_actor + add = 50 + desc = AI_YOU_ARE_THE_HOUSE_HEAD + } + modifier = { + exists = scope:puppet_or_actor.house + NOT = { house.house_head ?= scope:puppet_or_actor } + dynasty.dynast ?= scope:puppet_or_actor + add = 25 + desc = AI_YOU_ARE_THE_DYNAST + } + #Leases holdings from char + modifier = { + faith = { + any_faith_holy_order = { + leader = scope:recipient + any_leased_title = { + county.holder = scope:puppet_or_actor + } + } + } + add = 10 + desc = INTERACTION_LEASES_HOLDINGS + } + #Rival + modifier = { + has_relation_rival = scope:puppet_or_actor + add = -200 + desc = ARTIFACT_RIVAL_REASON + } + + #Your tier (thus your power and size of donation) + modifier = { + scope:puppet_or_actor = { + highest_held_title_tier >= tier_duchy + } + add = { + value = scope:puppet_or_actor.highest_held_title_tier + subtract = 2 + multiply = 10 + } + desc = TITLE_TIER_REASON + } + + #Piety level + modifier = { + scope:puppet_or_actor = { + piety_level >= 2 + } + add = { + value = scope:puppet_or_actor.piety_level + subtract = 1 + multiply = 20 + } + desc = I_AM_PIOUS + } + modifier = { + scope:puppet_or_actor = { + piety_level < 1 + } + add = -50 + desc = I_AM_SINFUL + } + #Order is weak + modifier = { + scope:recipient = { + faith = { + any_faith_holy_order = { + leader = scope:recipient + num_leased_titles = 3 + } + } + } + add = 25 + desc = SMALL_ORDER_REASON + } + modifier = { + scope:recipient = { + faith = { + any_faith_holy_order = { + leader = scope:recipient + num_leased_titles = 2 + } + } + } + add = 50 + desc = SMALL_ORDER_REASON + } + modifier = { + scope:recipient = { + faith = { + any_faith_holy_order = { + leader = scope:recipient + num_leased_titles = 1 + } + } + } + add = 100 + desc = SMALL_ORDER_REASON + } + + #Very pious traits + modifier = { + scope:puppet_or_actor = { + OR = { + has_trait = saint + has_trait = herald + has_trait = saoshyant_descendant + has_trait = order_member + has_trait = faith_warrior + has_trait = saoshyant + has_trait = paragon + has_trait = savior + has_trait = crusader_king + } + } + add = 100 + desc = VERY_PIOUS_TRAITS_REASON + } + + #Pious traits + modifier = { + scope:puppet_or_actor = { + OR = { + has_trait = zealous + has_trait = theologian + has_trait = divine_blood + has_trait = consecrated_blood + has_trait = sayyid + } + } + add = 30 + desc = PIOUS_TRAITS_REASON + } + + #Sinful traits + modifier = { + scope:puppet_or_actor = { + OR = { + has_any_shunned_trait_in_rite_trigger = { + CHARACTER = scope:puppet_or_actor + RITE = scope:recipient.rite + } + has_trait = bastard + has_trait = gallowsbait + has_trait = decadent + } + } + add = -30 + desc = SINFUL_TRAITS_REASON + } + #Major sinful traits + modifier = { + scope:puppet_or_actor = { + OR = { + has_any_criminal_trait_in_rite_trigger = { + CHARACTER = scope:puppet_or_actor + RITE = scope:recipient.rite + } + has_trait = despoiler_of_byzantium + has_trait = incestuous + has_trait = murderer + } + } + add = -100 + desc = VERY_SINFUL_TRAITS_REASON + } + #Excommunicated + modifier = { + scope:puppet_or_actor = { + has_trait = excommunicated + } + add = -300 + desc = EXCOMMUNICATED_REASON + } + #Same rite + modifier = { + scope:puppet_or_actor.rite = scope:recipient.rite + add = 30 + desc = MONASTIC_SAME_RITE_REASON + } + #Heretical rite + modifier = { + scope:puppet_or_actor.rite = { + "divergence(scope:recipient.rite)" >= scope:recipient.faith.heresy_threshold + } + add = -100 + desc = MONASTIC_HERETICAL_RITE_REASON + } + #Personally holds the order's tenet + modifier = { + exists = scope:recipient.holy_order.order_tenet + scope:puppet_or_actor = { + any_personal_tenet = { + this = scope:recipient.holy_order.order_tenet + } + } + add = 20 + desc = MONASTIC_ORDER_TENET_REASON + } + } + + # AI will do + + ai_target_quick_trigger = { + adult = yes + } + + ai_targets = { + ai_recipients = neighboring_rulers + ai_recipients = faith_holy_order_leaders + } + + ai_frequency_by_tier = { + barony = 0 + county = 120 + duchy = 48 + kingdom = 24 + empire = 24 + hegemony = 24 + } + + ai_will_do = { + base = 0 + + modifier = { # is patron of the order + add = 20 + scope:recipient.holy_order.holy_order_patron ?= scope:puppet_or_actor + highest_held_title_tier >= tier_duchy + } + modifier = { # order is out of range + add = 10 + scope:puppet_or_actor.faith = { + any_faith_holy_order = { + leader = scope:recipient + NOT = { holy_order_range_trigger = { CHARACTER = scope:puppet_or_actor } } + } + } + } + + modifier = { # Zealous characters + add = 25 + scope:puppet_or_actor = { + ai_zeal >= high_positive_ai_value + } + } + + modifier = { + add = 25 + scope:puppet_or_actor = { + spiritual_fulfillment < spiritual_fulfillment_minus_1 + } + } + + modifier = { + add = 50 + scope:puppet_or_actor = { + spiritual_fulfillment < spiritual_fulfillment_minus_2 + } + } + + modifier = { + add = 100 + scope:puppet_or_actor = { + spiritual_fulfillment <= spiritual_fulfillment_minus_3 + } + } + + #if you have personal tenet and are religion nerd + modifier = { + add = 10 + exists = scope:recipient.holy_order.order_tenet + any_personal_tenet = { + this = scope:recipient.holy_order.order_tenet + } + OR = { + piety_level >= 3 + has_education_learning_trigger = yes + rite.head_of_rite ?= this + } + } + + modifier = { + factor = 1.25 + capital_county.kingdom = scope:recipient.capital_county.kingdom + } + + modifier = { + factor = 0.5 + scope:puppet_or_actor = { + OR = { + ai_greed >= low_positive_ai_value + domain_size <= 3 + } + } + } + + #Don't want to lease to faraway orders if there are closer ones that vibe + modifier = { + factor = 0.25 + NOT = { + scope:recipient.holy_order = { + any_leased_title = { + trigger_if = { + limit = { + exists = scope:target + } + empire = scope:target.empire + } + trigger_else = { + empire = scope:puppet_or_actor.capital_county.empire + } + } + } + } + faith = { + any_faith_holy_order = { + any_leased_title = { + trigger_if = { + limit = { + exists = scope:target + } + empire = scope:target.empire + } + trigger_else = { + empire = scope:puppet_or_actor.capital_county.empire + } + } + leader.rite ?= scope:puppet_or_actor.rite + order_tenet ?= { + save_temporary_scope_as = order_tenet_temp + } + scope:puppet_or_actor ?= { + OR = { + any_personal_tenet = { + this = scope:order_tenet_temp + } + any_desired_tenet = { + selection_count = 97 + only_positive = yes + threshold = 1 + this = scope:order_tenet_temp + } + } + } + } + } + } + + modifier = { + factor = 0.1 + scope:puppet_or_actor = { + OR = { + has_trait = cynical + ai_greed >= high_positive_ai_value + domain_size <= 2 + #You think their tenet is bad and dumb + AND = { + exists = scope:recipient.holy_order.order_tenet + NOR = { + scope:puppet_or_actor = { + any_personal_tenet = { + this = scope:recipient.holy_order.order_tenet + } + any_desired_tenet = { + selection_count = 30 + only_positive = yes + threshold = 1 + this = scope:recipient.holy_order.order_tenet + } + } + } + } + } + } + } + modifier = { # shares the order's rite + add = 20 + scope:puppet_or_actor.rite = scope:recipient.rite + } + modifier = { # rite has diverged from the order's + add = -15 + scope:puppet_or_actor.rite = { + "divergence(scope:recipient.rite)" >= medium_rite_divergence_value + } + } + modifier = { # order is heretical to the lessor, by the lessor's own threshold + factor = 0.1 + scope:puppet_or_actor.rite = { + "divergence(scope:recipient.rite)" >= scope:puppet_or_actor.faith.heresy_threshold + } + } + } +} + +offer_bedside_support_interaction = { + icon = religious + category = interaction_category_friendly + + desc = offer_bedside_support_interaction_desc + + cooldown_against_recipient = { years = 1 } + + is_available = { + rite ?= { + rite_has_parameter = tenet_sacred_childbirth_offer_bedside_support + } + } + + is_shown = { + NOT = { scope:actor = scope:recipient } + scope:recipient = { + is_pregnant = yes + OR = { + is_courtier_of = scope:actor + is_close_or_extended_family_of = scope:actor + is_vassal_or_below_of = scope:actor + } + } + } + + is_valid_showing_failures_only = { + scope:actor = { + is_adult = yes + is_available = yes + } + scope:recipient = { + is_available = yes + } + } + + cost = { + piety = minor_piety_value + } + + auto_accept = yes + + on_accept = { + scope:recipient = { + hidden_effect = { + if = { + limit = { + has_variable = { + name = birth_child_will_become_sickly + name = birth_mother_will_become_ill + } + } + random = { + chance = pam_bedside_support_avert_chance_value + remove_character_flag = birth_child_will_become_sickly + remove_character_flag = birth_mother_will_become_ill + add_character_flag = { + flag = birth_will_go_smoothly + days = 270 + } + save_scope_value_as = { + name = bedside_support_averted + value = yes + } + } + } + } + send_interface_toast = { + type = event_toast_effect_good + title = offer_bedside_support_interaction_notification + left_icon = scope:actor + right_icon = scope:recipient + add_opinion = { + modifier = pleased_opinion + target = scope:actor + opinion = 15 + } + add_stress = medium_stress_loss + } + } + scope:actor = { + if = { + limit = { exists = scope:bedside_support_averted } + send_interface_toast = { + type = event_toast_effect_good + title = offer_bedside_support_interaction_actor_averted_notification + left_icon = scope:actor + right_icon = scope:recipient + add_piety = medium_piety_gain + change_spiritual_fulfillment = minor_spiritual_fulfillment_value + } + } + else = { + send_interface_toast = { + type = event_toast_effect_neutral + title = offer_bedside_support_interaction_actor_notification + left_icon = scope:actor + right_icon = scope:recipient + change_spiritual_fulfillment = minor_spiritual_fulfillment_value + } + } + } + } + + ai_targets = { + ai_recipients = courtiers + } + + ai_target_quick_trigger = { + adult = yes + } + + ai_frequency_by_tier = { + barony = 0 + county = 120 + duchy = 120 + kingdom = 120 + empire = 120 + hegemony = 120 + } + + ai_will_do = { + base = 60 + + modifier = { + factor = 0 + scope:actor = { is_at_war = yes } + } + } +} + +#Get Monastic Order to spread tenet +#By Mother Superior Jasonetta Cantalini +monastic_espouse_beliefs_interaction = { + category = interaction_category_religion + icon = devoted + filter_tags = { holy_order } + common_interaction = yes + use_diplomatic_range = no + + desc = monastic_espouse_beliefs_interaction_desc + + is_available = { + can_have_theological_agent_puppet_trigger = yes + } + + is_shown = { + scope:recipient = { + faith = scope:puppet_or_actor.faith + this != scope:puppet_or_actor + government_has_flag = government_is_monastic_holy_order + exists = holy_order + exists = holy_order.order_tenet + } + } + + cooldown = { years = 1 } + + is_valid_showing_failures_only = { + scope:actor = { + is_incapable = no + } + scope:recipient = { + custom_tooltip = { + text = recipient_clerical_puppet_req_tt + puppeteer ?= scope:actor + } + + is_physically_able_adult = yes + custom_tooltip = { + text = espoused_order_beliefs_recently + NOT = { + has_character_flag = mon_tenet_cooldown + } + } + gold >= monastic_tenet_espousing_minimum_value + + custom_tooltip = { + text = order_espousing_targets_exist_tt + scope:recipient.holy_order = { + #Spread Tenet to AI characters as personal tenet + any_leased_title = { + OR = { + #leases' duchies' counties + duchy ?= { + any_de_jure_county_holder = { + pam_monastic_tenet_spread_target_trigger = { ORDER_LEADER = scope:recipient } + } + } + #Neighboring counties to leases + county ?= { + any_neighboring_county = { + holder ?= { + pam_monastic_tenet_spread_target_trigger = { ORDER_LEADER = scope:recipient } + } + } + } + } + } + } + } + } + } + + cost = { + piety = { + value = 0 + if = { + limit = { + scope:recipient.holy_order = { + num_leased_titles > 1 + } + } + scope:recipient.holy_order = { + every_leased_title = { + add = { + value = scope:actor.miniscule_piety_value + divide = 2 + } + } + } + } + } + } + + auto_accept = yes + + on_accept = { + scope:recipient = { + remove_short_term_gold = monastic_tenet_espousing_minimum_value + hidden_effect = { + monastic_belief_spreading_targeting_effect = yes + } + monastic_tenet_espousing_effect = yes + custom_tooltip = monastic_tenet_espousing_info_tt + } + } + + ai_frequency_by_tier = { + barony = 0 + county = 180 + duchy = 36 + kingdom = 12 + empire = 12 + hegemony = 12 + } + ai_targets = { + ai_recipients = puppets + } + ai_will_do = { + base = 10 + modifier = { + add = scope:actor.ai_zeal + } + modifier = { + scope:actor = { + any_personal_tenet = { + this = scope:recipient.holy_order.order_tenet + } + } + add = 50 + } + modifier = { + add = { + value = scope:actor.piety_level + multiply = 10 + } + scope:actor.piety_level > 2 + } + modifier = { + factor = 0 + scope:actor = { + NOR = { + rite = scope:recipient.rite + any_personal_tenet = { + this = scope:recipient.holy_order.order_tenet + } + } + } + } + modifier = { + factor = 0 + #You think their tenet is bad and dumb + exists = scope:recipient.holy_order.order_tenet + NOR = { + scope:puppet_or_actor = { + any_personal_tenet = { + this = scope:recipient.holy_order.order_tenet + } + any_desired_tenet = { + selection_count = 30 + only_positive = yes + threshold = 1 + this = scope:recipient.holy_order.order_tenet + } + } + } + } } } diff --git a/common/character_interactions/00_revoke_title_interaction.txt b/common/character_interactions/00_revoke_title_interaction.txt index 167be81aa..c0159fa7c 100644 --- a/common/character_interactions/00_revoke_title_interaction.txt +++ b/common/character_interactions/00_revoke_title_interaction.txt @@ -1,6 +1,6 @@ revoke_title_interaction = { category = interaction_category_vassal - common_interaction = no + common_interaction = yes highlighted_reason = HIGHLIGHTED_HAS_REVOKE_TITLE_REASON notification_text = REVOKE_TITLE_PROPOSAL interface_priority = 110 @@ -9,11 +9,11 @@ first_valid = { triggered_desc = { trigger = { - scope:actor = { - government_allows = administrative + scope:puppet_or_actor = { + government_has_mechanic = administrative } scope:recipient = { - government_allows = administrative + government_has_mechanic = administrative } } desc = revoke_governorship_interaction @@ -26,11 +26,11 @@ first_valid = { triggered_desc = { trigger = { - scope:actor = { - government_allows = administrative + scope:puppet_or_actor = { + government_has_mechanic = administrative } scope:recipient = { - government_allows = administrative + government_has_mechanic = administrative } } desc = revoke_governorship_interaction_desc @@ -41,11 +41,11 @@ icon = { trigger = { - scope:actor = { - government_allows = administrative + scope:puppet_or_actor = { + government_has_mechanic = administrative } scope:recipient = { - government_allows = administrative + government_has_mechanic = administrative } } reference = revoke_governorship @@ -61,7 +61,6 @@ popup_on_receive = yes pause_on_receive = yes - interface_priority = 60 ai_min_reply_days = 4 ai_max_reply_days = 9 @@ -72,18 +71,18 @@ is_shown = { scope:recipient = { - NOT = { government_has_flag = government_is_true_herder } # They have their own interaction without cooldowns/maluses + NOT = { government_has_flag = government_is_herder } # They have their own interaction without cooldowns/maluses is_landed_or_landless_administrative = yes # should be shown but be disabled for indirect vassals - target_is_liege_or_above = scope:actor - # is_vassal_of = scope:actor + target_is_liege_or_above = scope:puppet_or_actor + # is_vassal_of = scope:puppet_or_actor } } is_valid_showing_failures_only = { title_revocation_standard_valid_showing_failures_only_trigger = yes # Plus make sure there's a legal right to revoke. - scope:actor = { + scope:puppet_or_actor = { trigger_if = { limit = { government_has_flag = government_is_tribal } custom_description = { @@ -99,7 +98,14 @@ } } trigger_else_if = { - limit = { government_allows = administrative } + limit = { government_has_mechanic = administrative } + } + trigger_else_if = { + limit = { realm_law_use_church_authority = yes } + custom_description = { + text = "has_law_allowing_title_revocation_church" + has_realm_law_flag = title_revocation_allowed + } } trigger_else = { custom_description = { @@ -126,7 +132,7 @@ scope:recipient = { vassal_contract_has_flag = admin_cannot_revoke_titles_without_cause } - scope:actor = { + scope:puppet_or_actor = { NOT = { has_revoke_title_reason = scope:recipient } } } @@ -139,10 +145,10 @@ } # And uhh... the sensible check. scope:recipient = { - is_vassal_of = scope:actor - NOT = { has_strong_hook = scope:actor } + is_vassal_of = scope:puppet_or_actor + NOT = { has_strong_hook = scope:puppet_or_actor } trigger_if = { # If admin, they need to hold a title that isn't their noble family title - limit = { government_allows = administrative } + limit = { government_has_mechanic = administrative } custom_tooltip = { text = admin_no_valid_appointment any_held_title = { is_landless_type_title = no } @@ -151,7 +157,7 @@ } custom_tooltip = { text = cannot_take_overt_hostile_actions_against_diarch.tt - NOT = { scope:recipient ?= scope:actor.diarch } + NOT = { scope:recipient ?= scope:puppet_or_actor.diarch } } custom_tooltip = { text = protected_from_revocation.tt @@ -160,7 +166,7 @@ } can_send = { - scope:actor = { + scope:puppet_or_actor = { custom_description = { text = "character_interactions_hostile_actions_disabled_delay" NOT = { has_character_flag = flag_hostile_actions_disabled_delay } @@ -172,7 +178,7 @@ trigger_if = { limit = { government_has_flag = government_is_japan_feudal - var:petition_liege_house_fief_allowed_flag ?= scope:actor + var:petition_liege_house_fief_allowed_flag ?= scope:puppet_or_actor } NOT = { ask_for_pardon_available_trigger = { ACTOR = scope:recipient } @@ -187,18 +193,18 @@ # Highlighted in the interaction menu when right-clicking a character is_highlighted = { OR = { - scope:actor = { + scope:puppet_or_actor = { has_revoke_title_reason = scope:recipient } scope:recipient = { any_held_title = { - scope:actor = { + scope:puppet_or_actor = { has_claim_on = prev } } NOT = { any_ally = { - this = scope:actor + this = scope:puppet_or_actor } } } @@ -210,12 +216,12 @@ title_revocation_standard_can_pick_title_trigger = yes trigger_if = { limit = { - scope:actor = { government_allows = administrative } - scope:recipient = { government_allows = administrative } + scope:puppet_or_actor = { government_has_mechanic = administrative } + scope:recipient = { government_has_mechanic = administrative } } custom_description = { text = "admin_revoke_primary_tier_only" - subject = scope:actor + subject = scope:puppet_or_actor object = scope:target scope:target.tier = scope:recipient.highest_held_title_tier } @@ -228,6 +234,10 @@ NOR = { is_noble_family_title = yes is_nomad_title = yes + is_head_of_faith = yes + has_clerical_region = yes + pam_title_is_clerical_elector_trigger = yes + pam_title_is_antipope_office_trigger = yes } } } @@ -235,7 +245,7 @@ #Use hook send_option = { is_valid = { - scope:actor = { + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } @@ -243,14 +253,14 @@ localization = SCHEME_HOOK } should_use_extra_icon = { - scope:actor = { has_usable_hook = scope:recipient } + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } extra_icon = "gfx/interface/icons/character_interactions/hook_icon.dds" send_options_exclusive = no on_send = { - scope:actor = { + scope:puppet_or_actor = { add_character_flag = { flag = flag_hostile_actions_disabled_delay days = 10 @@ -260,16 +270,27 @@ cost = { # Usually, this action is free, but during certain diarchies, we want it to cost. - prestige = liege_diarchy_surcharge_interaction_revoke_title_interaction_value + prestige = { + value = liege_diarchy_surcharge_interaction_revoke_title_interaction_value + + if = { + limit = { scope:is_puppet_action ?= yes } + multiply = 0 + } + } # Admin has to pay an influence cost unless they have a revocation reason on the recipient influence = { value = 0 if = { limit = { - scope:actor = { - government_allows = administrative + scope:puppet_or_actor = { + government_has_flag = government_has_influence + government_has_mechanic = administrative NOT = { has_revoke_title_reason = scope:recipient } + scope:recipient = { + government_has_mechanic = administrative + } } scope:recipient.highest_held_title_tier >= tier_county } @@ -363,7 +384,7 @@ } if = { limit = { - scope:actor = { + scope:puppet_or_actor = { scope:recipient.top_liege ?= this any_character_situation = { OR = { @@ -385,10 +406,14 @@ } if = { limit = { - scope:actor = { has_realm_law_flag = manor_reform_law } + scope:puppet_or_actor = { has_realm_law_flag = manor_reform_law } } multiply = 0.5 } + if = { + limit = { scope:is_puppet_action ?= yes } + multiply = 0 + } } } @@ -405,132 +430,28 @@ } if = { # Safety flag to ensure admin revocations behave properly limit = { - scope:actor = { government_allows = administrative } - scope:recipient = { government_allows = administrative } + scope:puppet_or_actor = { government_has_mechanic = administrative } + scope:recipient = { government_has_mechanic = administrative } } save_scope_value_as = { name = administrative_revocation value = yes } - } - scope:actor = { - if = { # Admin has to pay an influence cost unless they have a revocation reason on the recipient - limit = { - government_allows = administrative - NOT = { has_revoke_title_reason = scope:recipient } - scope:recipient = { - highest_held_title_tier >= tier_county - } - } - show_as_tooltip = { # Actual cost is deducted in the the interaction cost - change_influence = { - scope:recipient ?= { - if = { - limit = { - any_held_title = { - title_tier = kingdom - is_landless_type_title = no - is_noble_family_title = no - } - } - add = { - add = { - value = scope:recipient.massive_influence_value - multiply = 3 - } - desc = GOVERNOR_RESIGNATION_KINGDOM_COST - } - } - else_if = { - limit = { - any_held_title = { - title_tier = duchy - is_landless_type_title = no - is_noble_family_title = no - } - } - add = { - add = scope:recipient.massive_influence_value - desc = GOVERNOR_RESIGNATION_DUCHY_COST - } - } - else = { - add = { - add = scope:recipient.major_influence_value - desc = concept_county - } - } - if = { - limit = { house ?= { is_powerful_family = yes } } - add = { - value = scope:recipient.massive_influence_value - desc = GOVERNOR_RESIGNATION_POWERFUL_COST - } - } - else_if = { - limit = { house ?= { is_dominant_family = yes } } - add = { - value = scope:recipient.monumental_influence_value - desc = GOVERNOR_RESIGNATION_DOMINANT_COST - } - } - if = { - limit = { scope:recipient.governor_efficiency < 1 } - add = { - value = -100 - add = { - value = scope:recipient.governor_efficiency - multiply = 100 - } - desc = GOVERNOR_RESIGNATION_EFFICIENCY_COST - } - } - else_if = { - limit = { scope:recipient.governor_efficiency > 1 } - add = { - value = -100 - add = { - value = scope:recipient.governor_efficiency - multiply = 100 - } - desc = GOVERNOR_RESIGNATION_EFFICIENCY_COST - } - } - if = { - limit = { - influence_level != 1 - } - add = { - value = { - value = influence_level - subtract = 1 - } - multiply = 50 - desc = GOVERNOR_RESIGNATION_INFLUENCE_LEVEL_COST - } - } - } - multiply = -1.25 - if = { - limit = { has_realm_law_flag = manor_reform_law } - multiply = 0.5 - } - } - } + scope:puppet_or_actor = { + trigger_event = char_interaction.0199 } - trigger_event = char_interaction.0199 } revoke_title_interaction_effect = yes if = { limit = { - scope:actor = { has_character_flag = flag_hostile_actions_disabled_delay } + scope:puppet_or_actor = { has_character_flag = flag_hostile_actions_disabled_delay } } - scope:actor = { remove_character_flag = flag_hostile_actions_disabled_delay } + scope:puppet_or_actor = { remove_character_flag = flag_hostile_actions_disabled_delay } } -# # Harrying logic. -# scope:actor = { + # Harrying logic. +# scope:puppet_or_actor = { # if = { # limit = { # character_is_valid_for_harrying_of_the_north_trigger = yes @@ -560,13 +481,16 @@ } on_decline = { - scope:actor = { + scope:puppet_or_actor = { if = { # Admin has to pay an influence cost unless they have a revocation reason on the recipient limit = { - government_allows = administrative + NOT = { scope:is_puppet_action ?= yes } + government_has_mechanic = administrative + government_has_flag = government_has_influence NOT = { has_revoke_title_reason = scope:recipient } scope:recipient = { highest_held_title_tier >= tier_county + government_has_mechanic = administrative } NOT = { has_realm_law_flag = manor_reform_law } } @@ -667,21 +591,21 @@ limit = { scope:landed_title.tier != tier_barony NOT = { - scope:recipient = { government_has_flag = government_is_true_herder } + scope:recipient = { government_has_flag = government_is_herder } } } - scope:actor = { + scope:puppet_or_actor = { revocation_tyranny_effect = { VASSAL = scope:recipient } title_revocation_stress_effect = { VASSAL = scope:recipient } } } if = { limit = { - scope:recipient = { government_has_flag = government_is_true_herder } + scope:recipient = { government_has_flag = government_is_herder } } scope:recipient = { add_opinion = { - target = scope:actor + target = scope:puppet_or_actor opinion = -10 # Herders don't care much modifier = revoked_title } @@ -689,24 +613,24 @@ } else = { war_for_revoke_effect = { - LIEGE = scope:actor + LIEGE = scope:puppet_or_actor REBEL = scope:recipient } scope:recipient = { add_opinion = { - target = scope:actor + target = scope:puppet_or_actor modifier = revoked_title } } } if = { limit = { - scope:actor = { has_realm_law_flag = vassal_refusal_is_treason } + scope:puppet_or_actor = { has_realm_law_flag = vassal_refusal_is_treason } NOT = { - scope:recipient = { government_has_flag = government_is_true_herder } + scope:recipient = { government_has_flag = government_is_herder } } } - scope:actor = { + scope:puppet_or_actor = { add_opinion = { target = scope:recipient modifier = treasonous_revoke_refusal @@ -715,7 +639,7 @@ } # Harrying logic. -# scope:actor = { +# scope:puppet_or_actor = { # if = { # limit = { # character_is_valid_for_harrying_of_the_north_trigger = yes @@ -745,55 +669,80 @@ if = { limit = { - scope:actor = { has_character_flag = flag_hostile_actions_disabled_delay } + scope:puppet_or_actor = { has_character_flag = flag_hostile_actions_disabled_delay } } - scope:actor = { remove_character_flag = flag_hostile_actions_disabled_delay } + scope:puppet_or_actor = { remove_character_flag = flag_hostile_actions_disabled_delay } } } auto_accept = { scope:recipient = { - calc_true_if = { - amount >= 1 - custom_description = { - text = "baron_revocation" - highest_held_title_tier = tier_barony - } - custom_description = { - text = "prisoner_revocation" - is_imprisoned_by = scope:actor + trigger_if = { + limit = { + scope:hook = yes + scope:puppet_or_actor = { has_strong_hook = scope:recipient } } custom_description = { text = "spending_hook" - subject = scope:actor + subject = scope:puppet_or_actor object = scope:recipient scope:hook = yes - scope:actor = { has_strong_hook = scope:recipient } + scope:puppet_or_actor = { has_strong_hook = scope:recipient } } + } + trigger_else_if = { + limit = { is_imprisoned_by = scope:puppet_or_actor } + custom_description = { + text = "prisoner_revocation" + is_imprisoned_by = scope:puppet_or_actor + } + } + trigger_else_if = { + limit = { is_imprisoned = yes } custom_description = { text = "foreign_prison_revocation" - subject = scope:actor + subject = scope:puppet_or_actor object = scope:recipient scope:recipient = { is_imprisoned = yes - NOT = { is_imprisoned_by = scope:actor } + NOT = { is_imprisoned_by = scope:puppet_or_actor } + } + } + } + trigger_else_if = { + limit = { + scope:puppet_or_actor = { government_has_mechanic = administrative } + scope:recipient = { + government_has_mechanic = administrative + highest_held_title_tier = tier_county + is_ai = yes } } custom_tooltip = { text = "has_admin_gov" - scope:actor = { government_allows = administrative } + scope:puppet_or_actor = { government_has_mechanic = administrative } scope:recipient = { - government_allows = administrative + government_has_mechanic = administrative highest_held_title_tier = tier_county is_ai = yes } } } + trigger_else = { + custom_description = { + text = "baron_revocation" + highest_held_title_tier = tier_barony + } + } } } ai_accept = { base = 0 # Try to make it 0 for most interactions + legalism_lawful_authority_acceptance_modifier = { + ACTOR = scope:puppet_or_actor + } + modifier = { has_game_rule = hard_difficulty scope:actor = { is_ai = no } @@ -828,7 +777,7 @@ modifier = { scope:recipient = { - government_has_flag = government_is_true_herder + government_has_flag = government_is_herder } add = 40 desc = MIGRATION_INTERACTION_HERDER @@ -836,14 +785,14 @@ opinion_modifier = { # Opinion Factor who = scope:recipient - opinion_target = scope:actor + opinion_target = scope:puppet_or_actor multiplier = 0.8 desc = AI_OPINION_REASON } modifier = { add = 20 - scope:actor = { + scope:puppet_or_actor = { has_realm_law_flag = vassal_refusal_is_treason } desc = AI_REFUSAL_IS_TREASON @@ -867,7 +816,7 @@ modifier = { add = 20 - scope:actor.current_military_strength > scope:recipient.current_military_strength + scope:puppet_or_actor.current_military_strength > scope:recipient.current_military_strength scope:recipient = { has_trait = craven } @@ -875,29 +824,29 @@ } modifier = { - exists = scope:actor.primary_title.title_capital_county + exists = scope:puppet_or_actor.primary_title.title_capital_county OR = { - scope:landed_title = scope:actor.primary_title.title_capital_county - scope:landed_title = scope:actor.primary_title.title_capital_county.de_jure_liege + scope:landed_title = scope:puppet_or_actor.primary_title.title_capital_county + scope:landed_title = scope:puppet_or_actor.primary_title.title_capital_county.de_jure_liege } add = 50 desc = AI_TITLE_IS_REALM_CAPITAL } modifier = { - exists = scope:actor.primary_title.title_capital_county + exists = scope:puppet_or_actor.primary_title.title_capital_county NOR = { - scope:landed_title = scope:actor.primary_title.title_capital_county - scope:landed_title = scope:actor.primary_title.title_capital_county.de_jure_liege + scope:landed_title = scope:puppet_or_actor.primary_title.title_capital_county + scope:landed_title = scope:puppet_or_actor.primary_title.title_capital_county.de_jure_liege } - scope:landed_title.de_jure_liege = scope:actor.primary_title.title_capital_county.de_jure_liege + scope:landed_title.de_jure_liege = scope:puppet_or_actor.primary_title.title_capital_county.de_jure_liege add = 30 desc = AI_TITLE_IS_IN_CAPITAL_DUCHY } modifier = { add = 30 - scope:actor = { + scope:puppet_or_actor = { has_claim_on = scope:landed_title } desc = AI_LIEGE_HAS_CLAIM_ON_TITLE @@ -919,7 +868,7 @@ scope:recipient = { #If AI is honorable and the law compels to obey the liege, AI will be more likely to obey. ai_honor > 0 } - scope:actor = { + scope:puppet_or_actor = { has_realm_law_flag = vassal_refusal_is_treason } } @@ -936,7 +885,7 @@ } modifier = { #Title is part of vassal's primary title de-jure. Not relevant for Admin. add = -25 - NOT = { scope:recipient = { government_allows = administrative } } + NOT = { scope:recipient = { government_has_mechanic = administrative } } scope:recipient.primary_title.tier > tier_county OR = { scope:recipient.primary_title = { @@ -950,7 +899,7 @@ add = intimidated_halved_reason_value scope:recipient = { has_dread_level_towards = { - target = scope:actor + target = scope:puppet_or_actor level = 1 } } @@ -960,7 +909,7 @@ add = cowed_halved_reason_value scope:recipient = { has_dread_level_towards = { - target = scope:actor + target = scope:puppet_or_actor level = 2 } } @@ -972,7 +921,7 @@ value = 1 subtract = { value = scope:recipient.current_military_strength - divide = { value = scope:actor.current_military_strength min = 1 } + divide = { value = scope:puppet_or_actor.current_military_strength min = 1 } } multiply = 50 max = 20 @@ -980,14 +929,14 @@ } modifier = { # Legalistic tradition desc = tradition_legalistic_name - scope:actor = { + scope:puppet_or_actor = { has_revoke_title_reason = scope:recipient culture = { has_cultural_parameter = vassals_more_likely_accept_punishments } } add = legalistic_vassal_punishment_acceptance } modifier = { # AI Mongols, tyranny wars just delay the inevitable fun! - scope:actor = { + scope:puppet_or_actor = { is_ai = yes OR = { has_trait = greatest_of_khans @@ -1027,7 +976,7 @@ # And even if we can avoid tyranny we don't want to revoke just because we can, so this only gets us to -10 # Certain characters will revoke despite tyranny, if their rationality is sufficiently low modifier = { - scope:actor = { + scope:puppet_or_actor = { OR = { NOT = { title_revocation_is_tyrannical_trigger = { VASSAL = scope:recipient } @@ -1047,7 +996,7 @@ } # Only certain rulers won't revoke vassals who have revolted against them modifier = { - scope:actor = { + scope:puppet_or_actor = { ai_compassion <= 75 ai_greed >= -50 ai_honor <= 50 @@ -1061,7 +1010,7 @@ is_ai = yes } opinion = { - target = scope:actor + target = scope:puppet_or_actor value <= 0 } } @@ -1085,22 +1034,22 @@ } add = { value = 100 - add = scope:actor.ai_greed + add = scope:puppet_or_actor.ai_greed add = { - value = scope:actor.ai_honor + value = scope:puppet_or_actor.ai_honor multiply = -1 } if = { limit = { - scope:actor.ai_vengefulness > 0 + scope:puppet_or_actor.ai_vengefulness > 0 } - add = scope:actor.ai_vengefulness + add = scope:puppet_or_actor.ai_vengefulness } } } # Vengeful AI's want to revoke modifier = { - scope:actor = { + scope:puppet_or_actor = { ai_vengefulness > 0 scope:recipient = { is_imprisoned = yes @@ -1110,7 +1059,7 @@ } } add = { - value = scope:actor.ai_vengefulness + value = scope:puppet_or_actor.ai_vengefulness multiply = 2 } } @@ -1118,7 +1067,7 @@ modifier = { years_from_game_start >= 3 OR = { - scope:actor = { + scope:puppet_or_actor = { is_at_war = no OR = { AND = { @@ -1132,24 +1081,24 @@ } } scope:recipient = { - is_imprisoned_by = scope:actor + is_imprisoned_by = scope:puppet_or_actor } } -# scope:actor = { # The HRE doesn't need endless civil wars -# NOT = { -# primary_title = title:e_hre -# } -# } - exists = scope:actor.primary_title.title_capital_county + scope:puppet_or_actor = { # Europa doesn't need endless civil wars + NOT = { + primary_title = title:e_europa + } + } + exists = scope:puppet_or_actor.primary_title.title_capital_county OR = { - scope:landed_title = scope:actor.primary_title.title_capital_county - scope:landed_title = scope:actor.primary_title.title_capital_county.de_jure_liege + scope:landed_title = scope:puppet_or_actor.primary_title.title_capital_county + scope:landed_title = scope:puppet_or_actor.primary_title.title_capital_county.de_jure_liege } NAND = { # Don't revoke player titles tyranically, it must be possible to play and succeed as Ulm! scope:landed_title.holder = { is_ai = no } - scope:actor = { + scope:puppet_or_actor = { title_revocation_is_tyrannical_trigger = { VASSAL = scope:recipient } } } @@ -1159,7 +1108,7 @@ modifier = { years_from_game_start >= 3 OR = { - scope:actor = { + scope:puppet_or_actor = { is_at_war = no OR = { AND = { @@ -1173,54 +1122,54 @@ } } scope:recipient = { - is_imprisoned_by = scope:actor + is_imprisoned_by = scope:puppet_or_actor } } -# scope:actor = { # The HRE doesn't need endless civil wars -# NOT = { -# primary_title = title:e_hre -# } -# } - scope:actor.domain_size < scope:actor.domain_limit - scope:actor.primary_title.tier > tier_county + scope:puppet_or_actor = { # Europa doesn't need endless civil wars + NOT = { + primary_title = title:e_europa + } + } + scope:puppet_or_actor.domain_size < scope:puppet_or_actor.domain_limit + scope:puppet_or_actor.primary_title.tier > tier_county trigger_if = { limit = { - scope:actor = { + scope:puppet_or_actor = { title_revocation_is_tyrannical_trigger = { VASSAL = scope:recipient } domain_size > 3 } } - scope:actor = { + scope:puppet_or_actor = { NOR = { has_trait = generous has_trait = just } } } - exists = scope:actor.primary_title.title_capital_county + exists = scope:puppet_or_actor.primary_title.title_capital_county OR = { - scope:actor.primary_title.title_capital_county.holder = scope:actor # You have your de jure capital already + scope:puppet_or_actor.primary_title.title_capital_county.holder = scope:puppet_or_actor # You have your de jure capital already NOT = { - scope:actor.primary_title.title_capital_county.holder.top_liege = scope:actor.top_liege # Or your De Jure capital isn't in your realm + scope:puppet_or_actor.primary_title.title_capital_county.holder.top_liege = scope:puppet_or_actor.top_liege # Or your De Jure capital isn't in your realm } } scope:landed_title.tier = tier_county # Only Counties OR = { # The AI gives away wrong-holding counties almost instantly, so we restrict to counties with holdings they can hold scope:landed_title.title_province = { has_holding_type = castle_holding } # Everyone is valid for castles AND = { - scope:actor = { + scope:puppet_or_actor = { government_has_flag = government_is_tribal } scope:landed_title.title_province = { has_holding_type = tribal_holding } } AND = { - scope:actor = { + scope:puppet_or_actor = { government_has_flag = government_is_republic } scope:landed_title.title_province = { has_holding_type = city_holding } } AND = { - scope:actor = { + scope:puppet_or_actor = { OR = { government_has_flag = government_is_clan government_has_flag = government_is_theocracy @@ -1231,19 +1180,19 @@ } OR = { # And the capital duchy, if it exists at all AND = { - exists = scope:actor.primary_title.title_capital_county.de_jure_liege.holder - scope:actor.primary_title.title_capital_county.de_jure_liege.holder = scope:actor + exists = scope:puppet_or_actor.primary_title.title_capital_county.de_jure_liege.holder + scope:puppet_or_actor.primary_title.title_capital_county.de_jure_liege.holder = scope:puppet_or_actor } AND = { - exists = scope:actor.primary_title.title_capital_county.de_jure_liege.holder - scope:actor.primary_title.title_capital_county.de_jure_liege.holder.top_liege != scope:actor.top_liege + exists = scope:puppet_or_actor.primary_title.title_capital_county.de_jure_liege.holder + scope:puppet_or_actor.primary_title.title_capital_county.de_jure_liege.holder.top_liege != scope:puppet_or_actor.top_liege } - scope:actor.primary_title.title_capital_county.de_jure_liege = { + scope:puppet_or_actor.primary_title.title_capital_county.de_jure_liege = { is_title_created = no } } - scope:landed_title.de_jure_liege = scope:actor.primary_title.title_capital_county.de_jure_liege # Under the same Duchy as your capital + scope:landed_title.de_jure_liege = scope:puppet_or_actor.primary_title.title_capital_county.de_jure_liege # Under the same Duchy as your capital scope:recipient = { # Not from players is_ai = yes @@ -1251,55 +1200,55 @@ OR = { # Tyranny tolerance is based on rationality AND = { - scope:actor.ai_rationality < 0 - scope:actor.tyranny <= 15 # Don't go crazy with tyranny, just a bit is fine + scope:puppet_or_actor.ai_rationality < 0 + scope:puppet_or_actor.tyranny <= 15 # Don't go crazy with tyranny, just a bit is fine } AND = { - scope:actor.ai_rationality >= 0 - scope:actor.ai_rationality < 50 - scope:actor.tyranny <= 5 # Don't go crazy with tyranny, just a bit is fine + scope:puppet_or_actor.ai_rationality >= 0 + scope:puppet_or_actor.ai_rationality < 50 + scope:puppet_or_actor.tyranny <= 5 # Don't go crazy with tyranny, just a bit is fine } AND = { - scope:actor.ai_rationality >= 50 - scope:actor.tyranny <= 0 # Don't go crazy with tyranny, just a bit is fine + scope:puppet_or_actor.ai_rationality >= 50 + scope:puppet_or_actor.tyranny <= 0 # Don't go crazy with tyranny, just a bit is fine } AND = { - scope:actor.ai_rationality >= 0 + scope:puppet_or_actor.ai_rationality >= 0 scope:recipient = { - is_imprisoned_by = scope:actor + is_imprisoned_by = scope:puppet_or_actor } - scope:actor = { has_revoke_title_reason = scope:recipient } + scope:puppet_or_actor = { has_revoke_title_reason = scope:recipient } } AND = { - scope:actor.ai_rationality < 0 + scope:puppet_or_actor.ai_rationality < 0 scope:recipient = { - is_imprisoned_by = scope:actor + is_imprisoned_by = scope:puppet_or_actor } } } # To do this, the target must be weak or willing in some way OR = { - scope:actor.current_military_strength > scope:recipient.current_military_strength # Must be stronger + scope:puppet_or_actor.current_military_strength > scope:recipient.current_military_strength # Must be stronger scope:recipient = { - is_imprisoned_by = scope:actor + is_imprisoned_by = scope:puppet_or_actor } } scope:recipient = { OR = { AND = { scope:recipient.primary_title.tier <= tier_county - scope:actor.primary_title.tier >= tier_duchy + scope:puppet_or_actor.primary_title.tier >= tier_duchy } has_trait = craven has_trait = content has_trait = trusting has_dread_level_towards = { - target = scope:actor + target = scope:puppet_or_actor level >= 1 } - opinion = { target = scope:actor value >= 40 } - is_imprisoned_by = scope:actor - scope:actor = { has_revoke_title_reason = scope:recipient } + opinion = { target = scope:puppet_or_actor value >= 40 } + is_imprisoned_by = scope:puppet_or_actor + scope:puppet_or_actor = { has_revoke_title_reason = scope:recipient } } } @@ -1307,62 +1256,55 @@ } # Revoke counties we're dejure liege of if below domain limit modifier = { - scope:actor.domain_size < scope:actor.domain_limit + scope:puppet_or_actor.domain_size < scope:puppet_or_actor.domain_limit scope:landed_title.tier = tier_county - scope:landed_title.de_jure_liege.holder = scope:actor + scope:landed_title.de_jure_liege.holder = scope:puppet_or_actor add = 500 } # Revoke appropriate baronies if below domain limit, it's tyranny free modifier = { - scope:actor.domain_size < scope:actor.domain_limit + scope:puppet_or_actor.domain_size < scope:puppet_or_actor.domain_limit scope:recipient = { highest_held_title_tier = tier_barony } scope:landed_title.tier = tier_barony OR = { scope:landed_title.title_province = { has_holding_type = castle_holding } scope:landed_title.title_province = { has_holding_type = temple_citadel_holding } AND = { - OR = { - scope:actor = { government_has_flag = government_is_clan } - scope:actor = { government_has_flag = government_is_theocracy } - scope:actor = { government_has_flag = government_is_mandala } - scope:actor.faith = { has_doctrine_parameter = lay_clergy } - } scope:landed_title.title_province = { has_holding_type = church_holding } + OR = { + scope:puppet_or_actor = { government_has_flag = government_is_clan } + scope:puppet_or_actor = { government_has_flag = government_is_theocracy } + scope:puppet_or_actor = { government_has_flag = government_is_mandala } + scope:puppet_or_actor.rite = { rite_has_parameter = lay_clergy } + } } AND = { - OR = { - scope:actor = { government_has_flag = government_is_republic } - scope:actor = { government_has_flag = government_is_administrative } - scope:actor = { government_has_flag = government_is_celestial } - scope:actor = { government_has_flag = government_is_steppe_admin } - scope:actor = { government_has_flag = government_is_meritocratic } - scope:actor = { government_has_flag = government_is_japan_administrative } - } scope:landed_title.title_province = { has_holding_type = city_holding } + scope:puppet_or_actor = { government_has_mechanic = administrative } } } add = 1100 } # Revoke from vassals of the wrong faith if you can do it without tyranny modifier = { - scope:actor.faith != scope:recipient.faith + scope:puppet_or_actor.faith != scope:recipient.faith scope:recipient.primary_title.tier > tier_barony OR = { - scope:actor.faith.religion != scope:recipient.faith.religion - scope:actor.ai_zeal >= low_negative_ai_value + scope:puppet_or_actor.faith.religion != scope:recipient.faith.religion + scope:puppet_or_actor.ai_zeal >= low_negative_ai_value NOT = { - scope:actor.faith = { has_doctrine = doctrine_pluralism_pluralistic } + scope:puppet_or_actor.rite = { rite_has_doctrine = doctrine_pluralism_pluralistic } } } OR = { # Chill a bit until you've dealth with the ones already in your prison scope:recipient = { - is_imprisoned_by = scope:actor + is_imprisoned_by = scope:puppet_or_actor } NOT = { any_vassal = { - faith != scope:actor.faith + faith != scope:puppet_or_actor.faith primary_title.tier > tier_barony - is_imprisoned_by = scope:actor + is_imprisoned_by = scope:puppet_or_actor time_in_prison = { years < 1 } } } @@ -1371,7 +1313,7 @@ } # Revoke from characters you dislike if you can do it without tyranny modifier = { - scope:actor = { + scope:puppet_or_actor = { OR = { has_relation_rival = scope:recipient has_relation_nemesis = scope:recipient @@ -1385,7 +1327,7 @@ } # Do not revoke titles from certain characters modifier = { - scope:actor = { + scope:puppet_or_actor = { OR = { has_relation_friend = scope:recipient has_relation_best_friend = scope:recipient @@ -1402,20 +1344,20 @@ modifier = { NOR = { scope:recipient = { - is_imprisoned_by = scope:actor + is_imprisoned_by = scope:puppet_or_actor } scope:recipient = { highest_held_title_tier = tier_barony } } - scope:actor = { + scope:puppet_or_actor = { OR = { AND = { has_treasury = no OR = { gold < minimum_ai_gold_value_for_tyranny_wars AND = { - scope:actor.current_military_strength < scope:recipient.current_military_strength + scope:puppet_or_actor.current_military_strength < scope:recipient.current_military_strength gold < comfortable_ai_gold_value_for_tyranny_wars } } @@ -1425,7 +1367,7 @@ OR = { gold < minimum_ai_treasury_value_for_tyranny_wars AND = { - scope:actor.current_military_strength < scope:recipient.current_military_strength + scope:puppet_or_actor.current_military_strength < scope:recipient.current_military_strength treasury < comfortable_ai_treasury_value_for_tyranny_wars } } @@ -1445,43 +1387,83 @@ scope:recipient = { has_character_flag = is_party_baron } } - modifier = { # Avoid triggering Tyranny wars mid-war - factor = 0 - scope:actor = { - is_at_war = yes - } - NOR = { - scope:recipient = { - is_imprisoned_by = scope:actor - } - scope:recipient = { - highest_held_title_tier = tier_barony + # Revoke from prisoners whose deaths would diminish the realm through inheritance + modifier = { + add = 1000 + scope:recipient = { + is_vassal_or_below_of = scope:puppet_or_actor + any_held_title = { + is_landless_type_title = no + tier >= tier_county + current_heir ?= { + is_ruler = yes + is_landed = yes + top_liege != scope:puppet_or_actor.top_liege + } } } } # Clan Government: Avoid revoking titles from house members if the AI wants to have high unity modifier = { - scope:actor = { + scope:puppet_or_actor = { government_has_flag = government_is_clan exists = house ai_wants_high_unity = yes } scope:recipient = { government_has_flag = government_is_clan - house ?= scope:actor.house + house ?= scope:puppet_or_actor.house } add = -1000 + } # Admin Government: Do not revoke titles from your house unless it's really needed + modifier = { + scope:puppet_or_actor = { government_has_mechanic = administrative } + exists = scope:recipient.house + scope:puppet_or_actor.house ?= scope:recipient.house + add = -500 } + # Japanese Admin wants to revoke Japanese Feudal if they have a reason + modifier = { + add = 5000 + scope:puppet_or_actor = { + government_has_flag = government_is_japan_administrative + exists = house + has_revoke_title_reason = scope:recipient + NOT = { has_relation_friend = scope:recipient } + } + scope:recipient = { + government_has_flag = government_is_japan_feudal + is_imprisoned = yes + house != scope:puppet_or_actor.house + } + } + # And Japanese Feudal wants to revoke Japanese Admin if they have a reason + modifier = { + add = 5000 + scope:puppet_or_actor = { + government_has_flag = government_is_japan_feudal + exists = house + has_revoke_title_reason = scope:recipient + NOT = { has_relation_friend = scope:recipient } + } + scope:recipient = { + government_has_flag = government_is_japan_administrative + is_imprisoned = yes + house != scope:puppet_or_actor.house + } + } + # TGP Be more careful with blocs generally + house_bloc_tyranny_war_modifiers = yes - modifier = { # Avoid triggering Tyranny wars mid-grand activity + modifier = { # Avoid triggering Tyranny wars mid-war factor = 0 - scope:actor = { - has_ongoing_grand_activity_trigger = yes + scope:puppet_or_actor = { + is_at_war = yes } NOR = { scope:recipient = { - is_imprisoned_by = scope:actor + is_imprisoned_by = scope:puppet_or_actor } scope:recipient = { highest_held_title_tier = tier_barony @@ -1489,25 +1471,62 @@ } } - # Admin Government: Do not revoke titles from your house unless it's really needed + # Don't take a title off anyone when refusing would raise half the realm against us. A prisoner, baron and lawful revocations are exempt, because they don't cause civil wars modifier = { - scope:actor = { government_allows = administrative } - exists = scope:recipient.house - scope:actor.house ?= scope:recipient.house - add = -500 + factor = 0 + scope:recipient = { + NOR = { + is_imprisoned_by = scope:puppet_or_actor + highest_held_title_tier = tier_barony + government_has_flag = government_is_ecclesiastical + } + } + scope:puppet_or_actor = { + title_revocation_is_tyrannical_trigger = { VASSAL = scope:recipient } + revoke_refusal_war_would_be_massive_trigger = { VASSAL = scope:recipient } + } } + + # Recipient Ecclesiastical: Don't revoke if not excommunicated + modifier = { + factor = 0 + scope:recipient = { + government_has_flag = government_is_ecclesiastical + NOT = { has_trait = excommunicated } + } + scope:puppet_or_actor = { + title_revocation_is_tyrannical_trigger = { VASSAL = scope:recipient } + revoke_refusal_war_would_be_massive_trigger = { VASSAL = scope:recipient } + } + } + + modifier = { # Avoid triggering Tyranny wars mid-grand activity + factor = 0 + scope:puppet_or_actor = { + has_ongoing_grand_activity_trigger = yes + } + NOR = { + scope:recipient = { + is_imprisoned_by = scope:puppet_or_actor + } + scope:recipient = { + highest_held_title_tier = tier_barony + } + } + } + # Admin rulers should be less likely to revoke titles without a revocation reason, as they should prefer to depose governors modifier = { - scope:actor = { - government_allows = administrative + scope:puppet_or_actor = { + government_has_mechanic = administrative NOT = { has_revoke_title_reason = scope:recipient } } scope:recipient = { NOT = { highest_held_title_tier = tier_barony } - government_allows = administrative + government_has_mechanic = administrative trigger_if = { limit = { - scope:actor = { has_government = japan_administrative_government } + scope:puppet_or_actor = { has_government = japan_administrative_government } } highest_held_title_tier >= tier_county } @@ -1524,40 +1543,6 @@ } } - # Japanese Admin wants to revoke Japanese Feudal if they have a reason - modifier = { - add = 5000 - scope:actor = { - government_has_flag = government_is_japan_administrative - exists = house - has_revoke_title_reason = scope:recipient - NOT = { has_relation_friend = scope:recipient } - } - scope:recipient = { - government_has_flag = government_is_japan_feudal - is_imprisoned = yes - house != scope:actor.house - } - } - # And Japanese Feudal wants to revoke Japanese Admin if they have a reason - modifier = { - add = 5000 - scope:actor = { - government_has_flag = government_is_japan_feudal - exists = house - has_revoke_title_reason = scope:recipient - NOT = { has_relation_friend = scope:recipient } - } - scope:recipient = { - government_has_flag = government_is_japan_administrative - is_imprisoned = yes - house != scope:actor.house - } - } - - # TGP Be more careful with blocs generally - house_bloc_tyranny_war_modifiers = yes - #Don't revoke titles from the frankokratia leader # modifier = { # scope:recipient = { diff --git a/common/character_interactions/00_scheme_interactions.txt b/common/character_interactions/00_scheme_interactions.txt index e287ec95f..537aadc79 100644 --- a/common/character_interactions/00_scheme_interactions.txt +++ b/common/character_interactions/00_scheme_interactions.txt @@ -13,7 +13,8 @@ start_murder_interaction = { send_name = START_SCHEME is_shown = { - scope:recipient != scope:actor + exists = scope:puppet_or_actor + scope:recipient != scope:puppet_or_actor NAND = { # Game Rules! has_game_rule = no_players_multiplayer_murder_schemes @@ -45,30 +46,30 @@ start_murder_interaction = { } is_valid_showing_failures_only = { - scope:actor = { + scope:puppet_or_actor = { can_start_scheme = { type = murder target_character = scope:recipient } } - scope:recipient = { NOT = { has_strong_hook = scope:actor } } + scope:recipient = { NOT = { has_strong_hook = scope:puppet_or_actor } } trigger_if = { limit = { - scope:actor = { + scope:puppet_or_actor = { has_government = landless_adventurer_government } } #Has to be used instead of diplo range checks in laamp to landed interactions ep3_laamp_diplo_range_trigger = { TARGET = scope:recipient - LAAMP = scope:actor + LAAMP = scope:puppet_or_actor } } trigger_if = { - limit = { scope:actor = { has_variable = no_scheming_allowed_var } } + limit = { scope:puppet_or_actor = { has_variable = no_scheming_allowed_var } } custom_tooltip = { text = no_scheming_allowed_var_tt - scope:actor.var:no_scheming_allowed_var != scope:recipient + scope:puppet_or_actor.var:no_scheming_allowed_var != scope:recipient } } } @@ -76,7 +77,7 @@ start_murder_interaction = { desc = { triggered_desc = { trigger = { - scope:actor = { + scope:puppet_or_actor = { can_start_scheme = { type = murder target_character = scope:recipient @@ -111,20 +112,36 @@ start_murder_interaction = { current_description = start_murder_interaction.tt.agent_focus_secrecy } - on_accept = { - scope:actor = { - stress_impact = { - compassionate = major_stress_impact_gain - honest = medium_stress_impact_gain - just = medium_stress_impact_gain + on_send = { + scope:puppet_or_actor = { + if = { + limit = { + OR = { + has_character_modifier = pam_granted_indulgences_modifier + has_character_modifier = pam_granted_indulgences_modifier_small + } + } + change_spiritual_fulfillment = major_spiritual_fulfillment_loss } } - scope:actor = { + } + on_accept = { + scope:puppet_or_actor = { + if = { # Only get stressed/SP penalties if you don't have the parameter + limit = { + NOT = { has_fulfillment_parameter = sp_murder_yields_no_sp_or_stress_loss } + } + stress_and_fulfillment_impact = { + compassionate = major_stress_impact_gain + honest = medium_stress_impact_gain + just = medium_stress_impact_gain + } + } send_interface_toast = { type = event_toast_effect_neutral title = start_murder_interaction_notification - left_icon = scope:actor + left_icon = scope:puppet_or_actor right_icon = scope:recipient # Success. @@ -210,6 +227,20 @@ start_murder_interaction = { remove_variable = feast_events_ewan_0001_bonus_value } } + if = { + limit = { + scope:is_puppet_action ?= yes + scope:actor != scope:recipient + } + scope:actor = { + send_interface_toast = { + type = event_toast_effect_neutral + title = start_murder_interaction_notification_puppeteer + left_icon = scope:puppet_or_actor + right_icon = scope:recipient + } + } + } } auto_accept = yes @@ -227,8 +258,17 @@ start_abduct = { scheme = abduct ignores_pending_interaction_block = yes + is_available = { + trigger_if = { + limit = { is_ai = yes } + is_diarch = yes + liege ?= { has_diarchy_active_parameter = diarchy_is_co_rulership } + ai_diarch_would_maim_execute_superior_if_got_chance_trigger = { LIEGE = liege } + } + } + is_shown = { - scope:actor = { + scope:puppet_or_actor ?= { OR = { has_perk = kidnapper_perk # Scheme unlocked by the Kidnapper Perk domicile ?= { has_domicile_parameter = camp_unlocks_abduct_scheme } @@ -245,8 +285,8 @@ start_abduct = { } NOR = { - scope:recipient = scope:actor - scope:recipient = { is_imprisoned_by = scope:actor } + scope:recipient = scope:puppet_or_actor + scope:recipient = { is_imprisoned_by = scope:puppet_or_actor } } #exists = scope:recipient.court_owner @@ -280,31 +320,31 @@ start_abduct = { } is_valid_showing_failures_only = { - scope:actor = { + scope:puppet_or_actor = { can_start_scheme = { type = abduct target_character = scope:recipient } } - scope:recipient = { NOT = { has_strong_hook = scope:actor } } + scope:recipient = { NOT = { has_strong_hook = scope:puppet_or_actor } } #limit range for landless adventurers trigger_if = { limit = { - scope:actor = { + scope:puppet_or_actor = { has_government = landless_adventurer_government } } #Has to be used instead of diplo range checks in laamp to landed interactions ep3_laamp_diplo_range_trigger = { TARGET = scope:recipient - LAAMP = scope:actor + LAAMP = scope:puppet_or_actor } } trigger_if = { - limit = { scope:actor = { has_variable = no_scheming_allowed_var } } + limit = { scope:puppet_or_actor = { has_variable = no_scheming_allowed_var } } custom_tooltip = { text = no_scheming_allowed_var_tt - scope:actor.var:no_scheming_allowed_var != scope:recipient + scope:puppet_or_actor.var:no_scheming_allowed_var != scope:recipient } } } @@ -312,7 +352,7 @@ start_abduct = { desc = { triggered_desc = { trigger = { - scope:actor = { + scope:puppet_or_actor = { can_start_scheme = { type = abduct target_character = scope:recipient @@ -347,20 +387,37 @@ start_abduct = { current_description = start_abduct.tt.agent_focus_secrecy } - on_accept = { - scope:actor = { - stress_impact = { - compassionate = medium_stress_impact_gain - honest = minor_stress_impact_gain - just = minor_stress_impact_gain + on_send = { + scope:puppet_or_actor = { + if = { + limit = { + OR = { + has_character_modifier = pam_granted_indulgences_modifier + has_character_modifier = pam_granted_indulgences_modifier_small + } + } + change_spiritual_fulfillment = medium_spiritual_fulfillment_loss } } - scope:actor = { + } + + on_accept = { + scope:puppet_or_actor = { # Only get stressed/SP penalties if you don't have the parameter + if = { + limit = { + NOT = { sp_hostile_schemes_except_murder_no_stress_or_fulfillment_trigger = yes } + } + stress_and_fulfillment_impact = { + compassionate = medium_stress_impact_gain + honest = minor_stress_impact_gain + just = minor_stress_impact_gain + } + } send_interface_toast = { type = event_toast_effect_neutral title = start_abduct_notification - left_icon = scope:actor + left_icon = scope:puppet_or_actor right_icon = scope:recipient # Success. @@ -432,6 +489,23 @@ start_abduct = { } } } + if = { + limit = { + scope:is_puppet_action ?= yes + scope:actor != scope:recipient + } + scope:actor = { + send_interface_toast = { + type = event_toast_effect_neutral + title = start_abduct_notification_puppeteer + left_icon = scope:puppet_or_actor + right_icon = scope:recipient + } + } + } + scope:puppet_or_actor = { save_scope_as = owner } + scope:recipient = { save_scope_as = target} + abduction_rivalry_progress_tooltip_forecast_effect = yes } ai_targets = { ai_recipients = liege } @@ -444,13 +518,6 @@ start_abduct = { hegemony = 0 } - ai_potential = { - liege ?= { has_diarchy_active_parameter = diarchy_is_co_rulership } - is_diarch = yes - is_ruler = yes - ai_diarch_would_maim_execute_superior_if_got_chance_trigger = { LIEGE = liege } - } - ai_will_do = { # They shouldn't always do this. base = -100 @@ -515,15 +582,20 @@ start_abduct = { } always = yes } + #Promised to abstain from sin + modifier = { + OR = { + has_character_modifier = pam_granted_indulgences_modifier + has_character_modifier = pam_granted_indulgences_modifier_small + } + factor = 0.1 + } } auto_accept = yes } end_scheme = { - is_shown = { - #debug_only = yes - } special_interaction = remove_scheme_interaction use_diplomatic_range = no hidden = yes @@ -566,15 +638,52 @@ befriend_interaction = { hegemony = 12 } + is_available = { + trigger_if = { + limit = { is_ai = yes } + OR = { + has_perk = befriend_perk # Unlocked by the Befriend Perk + culture ?= { has_cultural_parameter = automatic_befriend_access } +# any_character_struggle = { +# involvement = involved +# has_struggle_phase_parameter = struggle_unlocks_befriend_schemes_for_everyone +# } + house ?= { has_house_aspiration_parameter = aspect_of_serenity } + dynasty ?= { + has_dynasty_perk = fp1_adventure_legacy_5 + } + } + NOR = { + has_trait = shy + has_trait = callous + AND = { # No one cares about City barons + is_lowborn = yes + primary_title.tier <= tier_barony + } + any_scheme = { + OR = { + scheme_type = befriend + #scheme_type = sway # We allow the AI to override Sway with Befriend + scheme_type = seduce + scheme_type = courting + scheme_type = elope + scheme_type = learn_language + scheme_type = teach_governor + } + } + } + } + } + is_shown = { - scope:actor = { + scope:puppet_or_actor ?= { can_use_befriend_scheme_trigger = { TARGET = scope:recipient } } - scope:actor != scope:recipient + scope:puppet_or_actor != scope:recipient } is_valid_showing_failures_only = { - scope:actor = { + scope:puppet_or_actor = { can_start_scheme = { type = befriend target_character = scope:recipient @@ -583,64 +692,30 @@ befriend_interaction = { #limit range for landless adventurers trigger_if = { limit = { - scope:actor = { + scope:puppet_or_actor = { has_government = landless_adventurer_government } } #Has to be used instead of diplo range checks in laamp to landed interactions ep3_laamp_diplo_range_trigger = { TARGET = scope:recipient - LAAMP = scope:actor + LAAMP = scope:puppet_or_actor + } + } + trigger_if = { + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + prestige >= befriend_interaction_cost_value } } } cost = { prestige = { - value = 0 + value = befriend_interaction_cost_value if = { - limit = { - scope:actor = { - government_has_flag = government_is_nomadic - NOR = { - has_perk = befriend_perk - AND = { - exists = dynasty - dynasty = { - has_dynasty_perk = fp1_adventure_legacy_5 - } - target_is_vassal_or_below = scope:recipient - } - culture = { has_cultural_parameter = automatic_befriend_access } -# any_character_struggle = { -# involvement = involved -# has_struggle_phase_parameter = struggle_unlocks_befriend_schemes_for_everyone -# } - AND = { - government_has_flag = government_is_clan - is_in_same_clan_as_trigger = { CHARACTER = scope:recipient } - house = { has_house_unity_stage = harmonious } - } - } - } - } - add = scope:actor.minor_prestige_value - if = { - limit = { - scope:recipient = { - is_vassal_of = scope:actor - } - } - add = scope:actor.miniscule_prestige_value - } - if = { - limit = { - scope:actor = { - is_vassal_of = scope:recipient - } - } - add = scope:actor.minor_prestige_value - } + limit = { scope:is_puppet_action ?= yes } + multiply = 0 } } } @@ -648,7 +723,7 @@ befriend_interaction = { desc = { triggered_desc = { trigger = { - scope:actor = { + scope:puppet_or_actor = { NOT = { is_at_war_with = scope:recipient } can_start_scheme = { type = befriend @@ -661,12 +736,27 @@ befriend_interaction = { } on_accept = { - scope:actor = { + if = { + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + if = { + limit = { befriend_interaction_cost_value > 0 } + add_prestige = { + value = { + add = befriend_interaction_cost_value + max = prestige + multiply = -1 + } + } + } + } + } + scope:puppet_or_actor = { send_interface_toast = { type = event_toast_effect_neutral title = befriend_interaction_notification - left_icon = scope:actor + left_icon = scope:puppet_or_actor right_icon = scope:recipient begin_scheme_basic_effect = { @@ -676,13 +766,27 @@ befriend_interaction = { } } } + if = { + limit = { + scope:is_puppet_action ?= yes + scope:actor != scope:recipient + } + scope:actor = { + send_interface_toast = { + type = event_toast_effect_neutral + title = befriend_interaction_notification_puppeteer + left_icon = scope:puppet_or_actor + right_icon = scope:recipient + } + } + } if = { #Stubborness effect limit = { scope:recipient = { has_trait = stubborn } } - scope:actor = { + scope:puppet_or_actor = { random_scheme = { type = befriend limit = { @@ -727,40 +831,6 @@ befriend_interaction = { } } - ai_potential = { - OR = { - has_perk = befriend_perk # Unlocked by the Befriend Perk - dynasty ?= { - has_dynasty_perk = fp1_adventure_legacy_5 - } - culture = { has_cultural_parameter = automatic_befriend_access } -# any_character_struggle = { -# involvement = involved -# has_struggle_phase_parameter = struggle_unlocks_befriend_schemes_for_everyone -# } - house ?= { has_house_aspiration_parameter = aspect_of_serenity } - } - NOR = { - has_trait = shy - has_trait = callous - any_scheme = { - OR = { - scheme_type = befriend - #scheme_type = sway # We allow the AI to override Sway with Befriend - scheme_type = seduce - scheme_type = courting - scheme_type = elope - scheme_type = learn_language - scheme_type = teach_governor - } - } - AND = { # No one cares about City barons - is_lowborn = yes - primary_title.tier <= tier_barony - } - } - } - auto_accept = yes ai_will_do = { @@ -768,12 +838,11 @@ befriend_interaction = { modifier = { # Try to befriend those who you might want to vassalize add = 30 - scope:actor = { + scope:puppet_or_actor = { top_liege = this primary_title.tier >= tier_county NOT = { any_targeting_faction = { - exists = yes OR = { faction_is_type = liberty_faction faction_is_type = claimant_faction @@ -785,15 +854,15 @@ befriend_interaction = { scope:recipient = { top_liege = this is_playable_character = yes - primary_title.tier < scope:actor.primary_title.tier + primary_title.tier < scope:puppet_or_actor.primary_title.tier OR = { - faith.religion = scope:actor.faith.religion + faith.religion = scope:puppet_or_actor.faith.religion AND = { - faith = { - has_doctrine = doctrine_pluralism_pluralistic + rite = { + rite_has_doctrine = doctrine_pluralism_pluralistic } - scope:actor.faith = { - has_doctrine = doctrine_pluralism_pluralistic + scope:puppet_or_actor.rite = { + rite_has_doctrine = doctrine_pluralism_pluralistic } } } @@ -802,7 +871,7 @@ befriend_interaction = { modifier = { factor = 0.1 - scope:actor = { + scope:puppet_or_actor = { opinion = { target = scope:recipient value < -50 @@ -814,7 +883,7 @@ befriend_interaction = { factor = 0.1 scope:recipient = { opinion = { - target = scope:actor + target = scope:puppet_or_actor value > 50 } } @@ -824,7 +893,7 @@ befriend_interaction = { factor = 0.5 scope:recipient = { number_of_personality_traits_in_common = { - target = scope:actor + target = scope:puppet_or_actor value < 2 } } @@ -834,7 +903,7 @@ befriend_interaction = { factor = 0.1 scope:recipient = { number_of_personality_traits_in_common = { - target = scope:actor + target = scope:puppet_or_actor value < 1 } } @@ -842,7 +911,7 @@ befriend_interaction = { # Struggle # modifier = { -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # involvement = involved # is_struggle_type = iberian_struggle @@ -860,7 +929,7 @@ befriend_interaction = { # value = 0 # if = { # limit = { -# scope:actor = { +# scope:puppet_or_actor = { # has_character_flag = agenda_towards_deescalation # trait_compatibility = { # target = scope:recipient @@ -875,7 +944,7 @@ befriend_interaction = { # } # else_if = { # limit = { -# scope:actor = { +# scope:puppet_or_actor = { # has_character_flag = agenda_towards_deescalation # trait_compatibility = { # target = scope:recipient @@ -887,7 +956,7 @@ befriend_interaction = { # } # else_if = { # limit = { -# scope:actor = { +# scope:puppet_or_actor = { # has_character_flag = agenda_towards_escalation # } # } @@ -909,17 +978,17 @@ befriend_interaction = { modifier = { factor = 2 - scope:recipient.liege = scope:actor + scope:recipient.liege = scope:puppet_or_actor } modifier = { factor = 0.5 - scope:recipient.faith != scope:actor.faith + scope:recipient.faith != scope:puppet_or_actor.faith } modifier = { factor = 0.25 - scope:actor = { + scope:puppet_or_actor = { is_ruler = yes tier_difference = { target = scope:recipient @@ -929,13 +998,13 @@ befriend_interaction = { } modifier = { factor = 0.35 - scope:actor = { + scope:puppet_or_actor = { has_personality_malicious_trigger = yes } } modifier = { factor = 2 - scope:actor = { + scope:puppet_or_actor = { OR = { has_trait = gregarious has_trait = diplomat @@ -946,31 +1015,31 @@ befriend_interaction = { } modifier = { factor = 1.5 - scope:actor = { + scope:puppet_or_actor = { num_of_relation_friend < 3 } } modifier = { #Better to Court rather than befriend. factor = 0.25 - scope:actor = { + scope:puppet_or_actor = { is_spouse_of = scope:recipient } } modifier = { factor = 0.75 scope:recipient = { - is_child_of = scope:actor + is_child_of = scope:puppet_or_actor } } modifier = { factor = 2 - scope:actor = { + scope:puppet_or_actor = { is_child_of = scope:recipient } } modifier = { factor = 2 - scope:actor = { #Friends of friends + scope:puppet_or_actor = { #Friends of friends any_relation = { type = friend any_relation = { @@ -984,7 +1053,7 @@ befriend_interaction = { factor = 0.25 scope:recipient = { any_claim = { - this = scope:actor.primary_title + this = scope:puppet_or_actor.primary_title } } } @@ -1044,10 +1113,31 @@ seduce_interaction = { hegemony = 12 } + is_available = { + trigger_if = { + limit = { is_ai = yes } + is_adult = yes + NOR = { + has_trait = chaste + AND = { # No one cares about City barons + is_lowborn = yes + primary_title.tier <= tier_barony + } + has_trait = celibate + primary_title ?= { + is_mercenary_company = yes + } + scheme_generic_ai_blocker_trigger = yes + has_character_modifier = clerical_chastity_vow_modifier + } + might_cheat_on_every_partner_trigger = yes + } + } + is_shown = { - scope:actor != scope:recipient + scope:puppet_or_actor ?= { is_adult = yes } + scope:puppet_or_actor != scope:recipient scope:recipient = { is_adult = yes } - scope:actor = { is_adult = yes } # Avoid seducing lowborn nobodies in foreign courts trigger_if = { @@ -1059,16 +1149,16 @@ seduce_interaction = { is_lowborn = yes is_playable_character = no NOR = { - is_courtier_of = scope:actor - is_foreign_court_or_pool_guest_of = scope:actor + is_courtier_of = scope:puppet_or_actor + is_foreign_court_or_pool_guest_of = scope:puppet_or_actor } } } } - scope:actor = { # Some early filtering for the AI to focus it towards fruitful seductions + scope:puppet_or_actor ?= { # Some early filtering for the AI to focus it towards fruitful seductions trigger_if = { limit = { - is_ai = yes + scope:actor = { is_ai = yes } } trigger_if = { # Deviants will seduce anyone limit = { @@ -1077,7 +1167,7 @@ seduce_interaction = { } trigger_else_if = { # It's always fine to seduce your spouse limit = { - scope:recipient = { is_consort_of = scope:actor } + scope:recipient = { is_consort_of = scope:puppet_or_actor } } } trigger_else_if = { # If the target is a close family member, only certain AI's will seduce much older members @@ -1094,29 +1184,29 @@ seduce_interaction = { } } } - scope:recipient.age <= scope:actor.age_plus_25 + scope:recipient.age <= scope:puppet_or_actor.age_plus_25 } trigger_else_if = { # Lustful/seduction-focused characters have a wider range limit = { OR = { has_trait = lustful - has_trait = rakish has_focus = intrigue_temptation_focus + has_trait = rakish } } OR = { - scope:recipient.age <= scope:actor.age_plus_10 + scope:recipient.age <= scope:puppet_or_actor.age_plus_10 AND = { # Seducing your vassals/liege/realm priest is good realm management, AND drama! has_focus = intrigue_temptation_focus OR = { scope:recipient = { - is_vassal_of = scope:actor + is_vassal_of = scope:puppet_or_actor } liege ?= scope:recipient scope:recipient = { is_theocratic_lessee = yes - is_courtier_of = scope:actor + is_courtier_of = scope:puppet_or_actor } } } @@ -1139,12 +1229,12 @@ seduce_interaction = { count <= 1 } } - scope:recipient.age <= scope:actor.age_plus_5 + scope:recipient.age <= scope:puppet_or_actor.age_plus_5 scope:recipient.age <= scope:recipient.marriage_female_fertility_cutoff_age_value } trigger_else = { # Otherwise, try to not seduce with *too* large an age gap - scope:recipient.age <= scope:actor.age_plus_5 - scope:recipient.age >= scope:actor.age_minus_10 + scope:recipient.age <= scope:puppet_or_actor.age_plus_5 + scope:recipient.age >= scope:puppet_or_actor.age_minus_10 } } trigger_else = { @@ -1153,43 +1243,61 @@ seduce_interaction = { } is_valid_showing_failures_only = { - scope:actor = { + scope:puppet_or_actor = { NOT = { is_at_war_with = scope:recipient } can_start_scheme = { type = seduce target_character = scope:recipient } + custom_tooltip = { + text = clerical_chastity_vow_blocks_scheme_tt + NOT = { has_character_modifier = clerical_chastity_vow_modifier } + } } trigger_if = { limit = { scope:recipient = { exists = primary_spouse } } - scope:recipient = { primary_spouse = { NOT = { has_strong_hook = scope:actor } } } + scope:recipient = { primary_spouse = { NOT = { has_strong_hook = scope:puppet_or_actor } } } } #limit range for landless adventurers trigger_if = { limit = { - scope:actor = { + scope:puppet_or_actor = { has_government = landless_adventurer_government } } #Has to be used instead of diplo range checks in laamp to landed interactions ep3_laamp_diplo_range_trigger = { TARGET = scope:recipient - LAAMP = scope:actor + LAAMP = scope:puppet_or_actor } } } desc = scheme_interaction_tt_seduce_approved + on_send = { + scope:puppet_or_actor = { + if = { + limit = { + OR = { + has_character_modifier = pam_granted_indulgences_modifier + has_character_modifier = pam_granted_indulgences_modifier_small + } + } + change_spiritual_fulfillment = medium_spiritual_fulfillment_loss + } + } + } + on_accept = { - scope:actor = { + scope:puppet_or_actor = { send_interface_toast = { type = event_toast_effect_neutral title = seduce_interaction_notification - left_icon = scope:actor + left_icon = scope:puppet_or_actor right_icon = scope:recipient begin_scheme_basic_effect = { @@ -1201,7 +1309,21 @@ seduce_interaction = { seduce_interaction_stress_effect = yes } } - scope:actor = { + if = { + limit = { + scope:is_puppet_action ?= yes + scope:actor != scope:recipient + } + scope:actor = { + send_interface_toast = { + type = event_toast_effect_neutral + title = seduce_interaction_notification_puppeteer + left_icon = scope:puppet_or_actor + right_icon = scope:recipient + } + } + } + scope:puppet_or_actor = { if = { limit = { NOT = { is_attracted_to_gender_of = scope:recipient } @@ -1211,23 +1333,6 @@ seduce_interaction = { } } - ai_potential = { - is_adult = yes - NOR = { - has_trait = celibate - has_trait = chaste - scheme_generic_ai_blocker_trigger = yes - primary_title = { - is_mercenary_company = yes - } - AND = { # No one cares about City barons - is_lowborn = yes - primary_title.tier <= tier_barony - } - } - might_cheat_on_every_partner_trigger = yes - } - auto_accept = yes ai_will_do = { @@ -1235,21 +1340,21 @@ seduce_interaction = { modifier = { add = -50 - scope:actor = { - primary_spouse ?= { has_strong_hook = scope:actor } + scope:puppet_or_actor = { + primary_spouse ?= { has_strong_hook = scope:puppet_or_actor } } } modifier = { add = 50 - scope:actor = { + scope:puppet_or_actor = { has_focus = intrigue_temptation_focus } } modifier = { add = 50 - scope:actor = { + scope:puppet_or_actor = { has_opinion_modifier = { modifier = childhood_crush target = scope:recipient @@ -1259,25 +1364,25 @@ seduce_interaction = { modifier = { add = 25 - exists = scope:actor.dynasty - scope:actor.dynasty = { + exists = scope:puppet_or_actor.dynasty + scope:puppet_or_actor.dynasty = { has_dynasty_perk = fp1_adventure_legacy_2 } } modifier = { # Focus on befriending if that's the path you've chosen add = -50 - scope:actor = { + scope:puppet_or_actor = { has_perk = befriend_perk } } modifier = { # Non-lustful clergy tend to not seduce add = -25 - scope:actor = { + scope:puppet_or_actor = { is_clergy = yes - faith = { - NOT = { has_doctrine_parameter = clergy_can_marry } + rite = { + NOT = { rite_has_parameter = clergy_can_marry } } NOR = { has_trait = lustful @@ -1288,7 +1393,7 @@ seduce_interaction = { modifier = { # Seducing your unmarried courtiers is good for producing bastards, which the AI will want to do if they have few heirs add = 10 - scope:actor = { + scope:puppet_or_actor = { any_child = { count <= 1 } @@ -1297,22 +1402,22 @@ seduce_interaction = { is_married = no fertility > low_fertility OR = { - is_courtier_of = scope:actor - is_pool_guest_of = scope:actor + is_courtier_of = scope:puppet_or_actor + is_pool_guest_of = scope:puppet_or_actor } } } modifier = { add = 30 - scope:actor = { + scope:puppet_or_actor = { has_trait = lustful } } modifier = { # ( ͡° ͜ʖ ͡°) add = 50 - scope:actor = { + scope:puppet_or_actor = { is_close_or_extended_family_of = scope:recipient is_deviant_trigger = yes } @@ -1326,7 +1431,7 @@ seduce_interaction = { modifier = { add = 25 - scope:actor = { + scope:puppet_or_actor = { is_close_or_extended_family_of = scope:recipient is_deviant_trigger = yes } @@ -1340,9 +1445,9 @@ seduce_interaction = { modifier = { add = 50 - scope:actor = { + scope:puppet_or_actor = { is_close_or_extended_family_of = scope:recipient - faith = { has_doctrine = tenet_divine_marriage } + rite = { rite_has_tenet = tenet_divine_marriage } } } @@ -1351,8 +1456,8 @@ seduce_interaction = { scope:recipient = { primary_spouse ?= { OR = { - has_relation_rival = scope:actor - has_relation_nemesis = scope:actor + has_relation_rival = scope:puppet_or_actor + has_relation_nemesis = scope:puppet_or_actor } } } @@ -1360,17 +1465,17 @@ seduce_interaction = { modifier = { add = -20 - scope:actor = { + scope:puppet_or_actor = { NOR = { has_trait = lustful has_trait = arbitrary is_deviant_trigger = yes - faith = { has_doctrine = tenet_divine_marriage } + rite = { rite_has_tenet = tenet_divine_marriage } has_perk = subtle_desire_perk } } scope:recipient = { - is_close_family_of = scope:actor + is_close_family_of = scope:puppet_or_actor } } @@ -1378,9 +1483,9 @@ seduce_interaction = { add = -20 scope:recipient = { is_married = yes - primary_spouse != scope:actor + primary_spouse != scope:puppet_or_actor } - scope:actor = { + scope:puppet_or_actor = { NOR = { has_trait = lustful has_focus = intrigue_temptation_focus @@ -1390,7 +1495,7 @@ seduce_interaction = { modifier = { # Try to avoid aggressive seduction unless you're geared for it add = -10 - scope:actor = { + scope:puppet_or_actor = { NOR = { has_trait = lustful has_focus = intrigue_temptation_focus @@ -1398,11 +1503,11 @@ seduce_interaction = { } scope:recipient = { is_lowborn = no - NOT = { is_pool_guest_of = scope:actor } + NOT = { is_pool_guest_of = scope:puppet_or_actor } } } -# # Struggle + # Struggle # modifier = { # scope:recipient = { # any_character_struggle = { @@ -1411,7 +1516,7 @@ seduce_interaction = { # phase_has_catalyst = catalyst_became_friend_lover_with_character # } # } -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # involvement = involved # is_struggle_type = iberian_struggle @@ -1422,7 +1527,7 @@ seduce_interaction = { # value = 0 # if = { # limit = { -# scope:actor = { +# scope:puppet_or_actor = { # has_character_flag = agenda_towards_deescalation # trait_compatibility = { # target = scope:recipient @@ -1437,7 +1542,7 @@ seduce_interaction = { # } # else_if = { # limit = { -# scope:actor = { +# scope:puppet_or_actor = { # has_character_flag = agenda_towards_escalation # } # } @@ -1453,7 +1558,7 @@ seduce_interaction = { factor = 1.25 scope:recipient = { number_of_personality_traits_in_common = { - target = scope:actor + target = scope:puppet_or_actor value >= 1 } } @@ -1463,7 +1568,7 @@ seduce_interaction = { factor = 1.5 scope:recipient = { number_of_personality_traits_in_common = { - target = scope:actor + target = scope:puppet_or_actor value >= 2 } } @@ -1473,7 +1578,7 @@ seduce_interaction = { factor = 2 scope:recipient = { number_of_personality_traits_in_common = { - target = scope:actor + target = scope:puppet_or_actor value >= 3 } } @@ -1515,7 +1620,7 @@ seduce_interaction = { limit = { scope:recipient = { opinion = { - target = scope:actor + target = scope:puppet_or_actor value < -15 } } @@ -1525,7 +1630,7 @@ seduce_interaction = { } scope:recipient = { opinion = { - target = scope:actor + target = scope:puppet_or_actor value < -5 } } @@ -1535,7 +1640,7 @@ seduce_interaction = { factor = 0.1 scope:recipient = { number_of_opposing_personality_traits = { - target = scope:actor + target = scope:puppet_or_actor value >= 1 } } @@ -1550,7 +1655,7 @@ seduce_interaction = { modifier = { # Barons tend to not seduce anyone landed above them factor = 0.1 - scope:actor = { + scope:puppet_or_actor = { is_playable_character = yes primary_title = { tier = tier_barony @@ -1602,10 +1707,18 @@ seduce_interaction = { modifier = { # Family Feud add = 50 - scope:actor = { + scope:puppet_or_actor = { house_has_feud_relation_with_trigger = { TARGET = scope:recipient } } } + #Promised to abstain from sin + modifier = { + OR = { + has_character_modifier = pam_granted_indulgences_modifier + has_character_modifier = pam_granted_indulgences_modifier_small + } + factor = 0.1 + } } } @@ -1659,35 +1772,66 @@ court_interaction = { hegemony = 12 } - is_shown = { - scope:recipient = { + is_available = { + trigger_if = { + limit = { is_ai = yes } + highest_held_title_tier > tier_barony + trigger_if = { + limit = { + NOR = { + culture ?= { + has_cultural_parameter = ai_romance_scheme_increase + } +# AND = { +# has_character_flag = agenda_towards_deescalation +# any_character_struggle = { +# involvement = involved +# phase_has_catalyst = catalyst_became_best_friend_soulmate_with_very_important_character +# is_struggle_type = iberian_struggle +# } +# } + } + } + ai_honor >= high_positive_ai_value + ai_compassion >= low_positive_ai_value + } is_adult = yes - is_attracted_to_gender_of = scope:actor + NOR = { + has_trait = chaste + AND = { # No one cared about City barons + is_lowborn = yes + primary_title.tier <= tier_barony + } + has_trait = celibate + scheme_generic_ai_blocker_trigger = yes + } } + } - scope:actor = { + is_shown = { + scope:puppet_or_actor ?= { this != scope:recipient is_adult = yes #Some asexuality handling trigger_if = { limit = { has_sexuality = asexual } trigger_if = { - limit = { is_ai = yes } + limit = { scope:actor = { is_ai = yes } } always = no } trigger_else = { - scope:recipient = { is_consort_of = scope:actor } + scope:recipient = { is_consort_of = scope:puppet_or_actor } } } # Some early filtering for the AI to focus it towards fruitful romance trigger_if = { - limit = { is_ai = yes } + limit = { scope:actor = { is_ai = yes } } trigger_if = { # Deviants will romance anyone limit = { is_deviant_trigger = yes } } trigger_else_if = { # It's always fine to romance your spouse limit = { - scope:recipient = { is_consort_of = scope:actor } + scope:recipient = { is_consort_of = scope:puppet_or_actor } } } trigger_else_if = { # If the target is a close family member, only certain AI's will romance much older members @@ -1704,29 +1848,29 @@ court_interaction = { } } } - scope:recipient.age <= scope:actor.age_plus_25 + scope:recipient.age <= scope:puppet_or_actor.age_plus_25 } trigger_else_if = { # Lustful/seduction-focused characters have a wider range limit = { OR = { has_trait = lustful - has_trait = rakish has_focus = intrigue_temptation_focus + has_trait = rakish } } OR = { - scope:recipient.age <= scope:actor.age_plus_10 + scope:recipient.age <= scope:puppet_or_actor.age_plus_10 AND = { # Romancing your vassals/liege/realm priest is good realm management, AND drama! has_focus = intrigue_temptation_focus OR = { scope:recipient = { - is_vassal_of = scope:actor + is_vassal_of = scope:puppet_or_actor } liege ?= scope:recipient scope:recipient = { is_theocratic_lessee = yes - is_courtier_of = scope:actor + is_courtier_of = scope:puppet_or_actor } } } @@ -1749,46 +1893,68 @@ court_interaction = { count <= 1 } } - scope:recipient.age <= scope:actor.age_plus_5 + scope:recipient.age <= scope:puppet_or_actor.age_plus_5 scope:recipient.age <= scope:recipient.marriage_female_fertility_cutoff_age_value } trigger_else = { # Otherwise, try to not seduce with *too* large an age gap - scope:recipient.age <= scope:actor.age_plus_5 - scope:recipient.age >= scope:actor.age_minus_10 + scope:recipient.age <= scope:puppet_or_actor.age_plus_5 + scope:recipient.age >= scope:puppet_or_actor.age_minus_10 } } trigger_else = { } } + scope:recipient = { + is_adult = yes + is_attracted_to_gender_of = scope:puppet_or_actor + } } is_valid_showing_failures_only = { - scope:actor = { + scope:puppet_or_actor = { NOT = { is_at_war_with = scope:recipient } can_start_scheme = { type = courting target_character = scope:recipient } + custom_tooltip = { + text = clerical_chastity_vow_blocks_scheme_tt + NOT = { has_character_modifier = clerical_chastity_vow_modifier } + } } #limit range for landless adventurers trigger_if = { limit = { - scope:actor = { + scope:puppet_or_actor = { has_government = landless_adventurer_government } } #Has to be used instead of diplo range checks in laamp to landed interactions ep3_laamp_diplo_range_trigger = { TARGET = scope:recipient - LAAMP = scope:actor + LAAMP = scope:puppet_or_actor } } } desc = scheme_interaction_tt_courtship_approved + on_send = { + scope:puppet_or_actor = { + if = { + limit = { + OR = { + has_character_modifier = pam_granted_indulgences_modifier + has_character_modifier = pam_granted_indulgences_modifier_small + } + } + change_spiritual_fulfillment = medium_spiritual_fulfillment_loss + } + } + } + on_accept = { - scope:actor = { + scope:puppet_or_actor = { # If you already have a soulmate, they get very mad every_relation = { type = soulmate @@ -1796,16 +1962,16 @@ court_interaction = { add_opinion = { modifier = betrayed_our_promise - target = scope:actor + target = scope:puppet_or_actor } } } - scope:actor = { + scope:puppet_or_actor = { send_interface_toast = { type = event_toast_effect_neutral title = court_interaction_notification - left_icon = scope:actor + left_icon = scope:puppet_or_actor right_icon = scope:recipient begin_scheme_basic_effect = { @@ -1822,12 +1988,26 @@ court_interaction = { add_opinion = { modifier = betrayed_our_promise - target = scope:actor + target = scope:puppet_or_actor } } } } } + if = { + limit = { + scope:is_puppet_action ?= yes + scope:actor != scope:recipient + } + scope:actor = { + send_interface_toast = { + type = event_toast_effect_neutral + title = court_interaction_notification_puppeteer + left_icon = scope:puppet_or_actor + right_icon = scope:recipient + } + } + } scope:recipient = { if = { limit = { @@ -1841,39 +2021,6 @@ court_interaction = { } } - ai_potential = { - is_adult = yes -# trigger_if = { -# limit = { -# NOR = { -# culture = { -# has_cultural_parameter = ai_romance_scheme_increase -# } -# AND = { -# has_character_flag = agenda_towards_deescalation -# any_character_struggle = { -# involvement = involved -# is_struggle_type = iberian_struggle -# phase_has_catalyst = catalyst_became_best_friend_soulmate_with_very_important_character -# } -# } -# } -# } -# ai_honor >= high_positive_ai_value -# ai_compassion >= low_positive_ai_value -# } - highest_held_title_tier > tier_barony - NOR = { - has_trait = celibate - has_trait = chaste - scheme_generic_ai_blocker_trigger = yes - AND = { # No one cared about City barons - is_lowborn = yes - primary_title.tier <= tier_barony - } - } - } - auto_accept = yes ai_will_do = { @@ -1881,9 +2028,9 @@ court_interaction = { -# # Struggle + # Struggle # modifier = { -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # involvement = involved # is_struggle_type = iberian_struggle @@ -1901,7 +2048,7 @@ court_interaction = { # value = 0 # if = { # limit = { -# scope:actor = { +# scope:puppet_or_actor = { # has_character_flag = agenda_towards_deescalation # } # scope:recipient = { @@ -1912,7 +2059,7 @@ court_interaction = { # } # else_if = { # limit = { -# scope:actor = { +# scope:puppet_or_actor = { # has_character_flag = agenda_towards_escalation # } # } @@ -1926,7 +2073,7 @@ court_interaction = { # modifier = { # Motivate AI's to use it on catalyst providers exclusively # add = -50 -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # involvement = involved # is_struggle_type = iberian_struggle @@ -1943,7 +2090,7 @@ court_interaction = { # } # } # } -# + opinion_modifier = { opinion_target = scope:recipient multiplier = 0.4 @@ -1969,7 +2116,7 @@ court_interaction = { modifier = { add = 50 - scope:actor = { + scope:puppet_or_actor = { has_opinion_modifier = { modifier = childhood_crush target = scope:recipient @@ -1979,7 +2126,7 @@ court_interaction = { modifier = { add = -50 - scope:actor = { + scope:puppet_or_actor = { is_close_family_of = scope:recipient NOR = { is_deviant_trigger = yes @@ -2014,7 +2161,7 @@ court_interaction = { limit = { scope:recipient = { opinion = { - target = scope:actor + target = scope:puppet_or_actor value < -20 } } @@ -2024,7 +2171,7 @@ court_interaction = { } scope:recipient = { opinion = { - target = scope:actor + target = scope:puppet_or_actor value < 0 } } @@ -2054,6 +2201,27 @@ court_interaction = { is_married = no } } + + modifier = { # Clergy sworn to celibacy don't partake in courtly love + factor = 0 + scope:puppet_or_actor = { + is_clergy = yes + rite = { + NOT = { rite_has_parameter = clergy_can_marry } + } + NOT = { + has_trait = lustful + } + } + } + #Promised to abstain from sin + modifier = { + OR = { + has_character_modifier = pam_granted_indulgences_modifier + has_character_modifier = pam_granted_indulgences_modifier_small + } + factor = 0.1 + } } } @@ -2091,12 +2259,89 @@ sway_interaction = { hegemony = 6 } + is_available = { + trigger_if = { + limit = { is_ai = yes } + NOR = { + primary_title ?= { + is_mercenary_company = yes + } + scheme_generic_ai_blocker_trigger = yes + } + #Don't override Befriend with Sway? + trigger_if = { + limit = { + OR = { + AND = { + has_royal_court = yes + court_grandeur_current_level >= 10 + has_court_type = court_diplomatic + has_dlc_feature = royal_court + } + AND = { + has_royal_court = yes + court_grandeur_current_level >= 10 + dynasty ?= { has_dynasty_perk = glory_legacy_5 } + has_court_type = court_diplomatic + has_dlc_feature = royal_court + } + } + } + always = yes + } + trigger_else = { + NOT = { + any_scheme = { scheme_type = befriend } + } + } + } + } + is_shown = { - scope:actor != scope:recipient + exists = scope:puppet_or_actor + scope:puppet_or_actor != scope:recipient + trigger_if = { + limit = { scope:actor = { is_ai = yes } } + scope:recipient = { + trigger_if = { # The unlanded are only worth it as realm priest, spymaster, or a clan's tax collector + limit = { is_ruler = no } + OR = { + is_theocratic_lessee = yes + has_council_position = councillor_spymaster + AND = { + is_tax_collector = yes + scope:puppet_or_actor = { government_has_flag = government_is_clan } + } + } + } + trigger_else = { # Only rulers have a tier or a government to judge + trigger_if = { # Barons are only worth the effort on the council + limit = { primary_title.tier = tier_barony } + is_councillor = yes + } + trigger_if = { # Leave independent kings and above to diplomacy proper + limit = { is_independent_ruler = yes } + OR = { + primary_title.tier < tier_kingdom + is_playable_character = no + } + } + NOT = { government_has_flag = government_is_herder } + } + trigger_if = { # Only the forgiving court a rival + limit = { scope:puppet_or_actor = { has_relation_rival = scope:recipient } } + scope:puppet_or_actor = { has_trait = forgiving } + } + opinion = { # Opinion last: it is the dearest check here + target = scope:puppet_or_actor + value < 100 + } + } + } } is_valid_showing_failures_only = { - scope:actor = { + scope:puppet_or_actor = { can_start_scheme = { type = sway target_character = scope:recipient @@ -2105,14 +2350,14 @@ sway_interaction = { #limit range for landless adventurers trigger_if = { limit = { - scope:actor = { + scope:puppet_or_actor = { has_government = landless_adventurer_government } } #Has to be used instead of diplo range checks in laamp to landed interactions ep3_laamp_diplo_range_trigger = { TARGET = scope:recipient - LAAMP = scope:actor + LAAMP = scope:puppet_or_actor } } } @@ -2120,12 +2365,12 @@ sway_interaction = { desc = scheme_interaction_tt_sway_approved on_accept = { - scope:actor = { + scope:puppet_or_actor = { send_interface_toast = { type = event_toast_effect_neutral title = sway_interaction_notification - left_icon = scope:actor + left_icon = scope:puppet_or_actor right_icon = scope:recipient begin_scheme_basic_effect = { @@ -2135,39 +2380,18 @@ sway_interaction = { } } } - } - - ai_potential = { - NOR = { - scheme_generic_ai_blocker_trigger = yes - primary_title = { - is_mercenary_company = yes - } - } - #Don't override Befriend with Sway? - trigger_if = { + if = { limit = { - OR = { - AND = { - has_royal_court = yes - has_dlc_feature = royal_court - has_court_type = court_diplomatic - court_grandeur_current_level >= 10 - } - AND = { - dynasty ?= { has_dynasty_perk = glory_legacy_5 } - has_royal_court = yes - has_dlc_feature = royal_court - has_court_type = court_diplomatic - court_grandeur_current_level >= 10 - } - } + scope:is_puppet_action ?= yes + scope:actor != scope:recipient } - always = yes - } - trigger_else = { - NOT = { - any_scheme = { scheme_type = befriend } + scope:actor = { + send_interface_toast = { + type = event_toast_effect_neutral + title = sway_interaction_notification_puppeteer + left_icon = scope:puppet_or_actor + right_icon = scope:recipient + } } } } @@ -2179,7 +2403,7 @@ sway_interaction = { modifier = { # Prefer seducing if you've got the focus for it add = -20 - scope:actor = { + scope:puppet_or_actor = { has_focus = intrigue_temptation_focus } } @@ -2187,18 +2411,17 @@ sway_interaction = { modifier = { add = 10 scope:recipient = { - is_vassal_of = scope:actor + is_vassal_of = scope:puppet_or_actor } } modifier = { # Try to sway those who you might want to vassalize add = 30 - scope:actor = { + scope:puppet_or_actor = { top_liege = this primary_title.tier >= tier_county NOT = { any_targeting_faction = { - exists = yes OR = { faction_is_type = liberty_faction faction_is_type = claimant_faction @@ -2210,15 +2433,15 @@ sway_interaction = { scope:recipient = { top_liege = this is_playable_character = yes - primary_title.tier < scope:actor.primary_title.tier + primary_title.tier < scope:puppet_or_actor.primary_title.tier OR = { - faith.religion = scope:actor.faith.religion + faith.religion = scope:puppet_or_actor.faith.religion AND = { - faith = { - has_doctrine = doctrine_pluralism_pluralistic + rite = { + rite_has_doctrine = doctrine_pluralism_pluralistic } - scope:actor.faith = { - has_doctrine = doctrine_pluralism_pluralistic + scope:puppet_or_actor.rite = { + rite_has_doctrine = doctrine_pluralism_pluralistic } } } @@ -2229,7 +2452,7 @@ sway_interaction = { add = 10 scope:recipient = { joined_faction ?= { - faction_target = scope:actor + faction_target = scope:puppet_or_actor faction_is_type = liberty_faction faction_is_at_war = no } @@ -2240,7 +2463,7 @@ sway_interaction = { add = 20 scope:recipient = { joined_faction ?= { - faction_target = scope:actor + faction_target = scope:puppet_or_actor faction_is_type = claimant_faction faction_is_at_war = no } @@ -2251,7 +2474,7 @@ sway_interaction = { add = 30 scope:recipient = { joined_faction ?= { - faction_target = scope:actor + faction_target = scope:puppet_or_actor faction_is_type = independence_faction faction_is_at_war = no } @@ -2262,16 +2485,16 @@ sway_interaction = { factor = 2 scope:recipient = { is_a_faction_leader = yes - is_vassal_of = scope:actor + is_vassal_of = scope:puppet_or_actor } } modifier = { factor = 3 scope:recipient = { - is_vassal_of = scope:actor + is_vassal_of = scope:puppet_or_actor opinion = { - target = scope:actor + target = scope:puppet_or_actor value < 0 } } @@ -2280,9 +2503,9 @@ sway_interaction = { modifier = { factor = 4 scope:recipient = { - is_powerful_vassal_of = scope:actor + is_powerful_vassal_of = scope:puppet_or_actor opinion = { - target = scope:actor + target = scope:puppet_or_actor value < 0 } } @@ -2290,12 +2513,12 @@ sway_interaction = { modifier = { factor = 0.5 - scope:recipient.faith != scope:actor.faith + scope:recipient.faith != scope:puppet_or_actor.faith } modifier = { factor = 0.25 - scope:actor = { + scope:puppet_or_actor = { is_ruler = yes tier_difference = { target = scope:recipient @@ -2308,13 +2531,13 @@ sway_interaction = { } modifier = { factor = 0.5 - scope:actor = { + scope:puppet_or_actor = { has_personality_malicious_trigger = yes } } modifier = { factor = 2 - scope:actor = { + scope:puppet_or_actor = { OR = { has_trait = gregarious has_trait = diplomat @@ -2326,12 +2549,12 @@ sway_interaction = { modifier = { factor = 0.75 scope:recipient = { - is_child_of = scope:actor + is_child_of = scope:puppet_or_actor } } modifier = { factor = 2 - scope:actor = { + scope:puppet_or_actor = { is_child_of = scope:recipient } } @@ -2339,7 +2562,7 @@ sway_interaction = { factor = 0.25 scope:recipient = { any_claim = { - this = scope:actor.primary_title + this = scope:puppet_or_actor.primary_title } } } @@ -2348,81 +2571,24 @@ sway_interaction = { scope:recipient = { is_theocratic_lessee = yes opinion = { - target = scope:actor + target = scope:puppet_or_actor value <= 50 } } } modifier = { # Try to make your tax collectors like you factor = 10 - scope:actor = { + scope:puppet_or_actor = { government_has_flag = government_is_clan } scope:recipient = { is_tax_collector = yes opinion = { - target = scope:actor + target = scope:puppet_or_actor value <= 50 } } } - - modifier = { # No point in swaying if opinion is already at 100 - factor = 0 - scope:recipient = { - opinion = { - target = scope:actor - value >= 100 - } - } - } - - modifier = { # If they are unlanded, they have to be a realm priest or spymaster, or in the case for clan rulers, a tax collector - factor = 0 - scope:recipient = { - is_ruler = no - NOR = { - is_theocratic_lessee = yes - has_council_position = councillor_spymaster - AND = { - is_tax_collector = yes - scope:actor = { government_has_flag = government_is_clan } - } - } - } - } - - modifier = { # Ignore rivals unless forgiving - factor = 0 - scope:actor = { - has_relation_rival = scope:recipient - NOT = { has_trait = forgiving } - } - } - - modifier = { # Ignore non-councillor barons - factor = 0 - scope:recipient = { - primary_title.tier = tier_barony - is_councillor = no - } - } - - modifier = { # Ignore neighboring Kings+ - factor = 0 - scope:recipient = { - top_liege = this - is_playable_character = yes - primary_title.tier >= tier_kingdom - } - } - - modifier = { # Ignore neighboring Herders - factor = 0 - scope:recipient = { - government_has_flag = government_is_true_herder - } - } } } @@ -2439,13 +2605,17 @@ learn_language_interaction = { ai_targets = { ai_recipients = liege - ai_recipients = head_of_faith ai_recipients = spouses ai_recipients = scripted_relations + ai_recipients = suzerain + ai_recipients = top_suzerain + ai_recipients = activity_host + ai_recipients = war_allies } ai_targets = { ai_recipients = vassals ai_recipients = peer_vassals + ai_recipients = tributaries max = 10 } ai_targets = { @@ -2461,19 +2631,34 @@ learn_language_interaction = { hegemony = 12 } + is_available = { + trigger_if = { + limit = { is_ai = yes } + primary_title.tier >= tier_county + NOR = { + has_trait = paranoid + has_trait = lazy + primary_title ?= { + is_mercenary_company = yes + } + scheme_generic_ai_blocker_trigger = yes + } + } + } + is_shown = { - scope:actor = { + scope:puppet_or_actor ?= { NOT = { culture = { has_same_culture_language = scope:recipient.culture } } } - scope:actor != scope:recipient + scope:puppet_or_actor != scope:recipient } is_valid_showing_failures_only = { - scope:actor = { + scope:puppet_or_actor = { can_start_scheme = { type = learn_language target_character = scope:recipient @@ -2482,14 +2667,14 @@ learn_language_interaction = { #limit range for landless adventurers trigger_if = { limit = { - scope:actor = { + scope:puppet_or_actor = { has_government = landless_adventurer_government } } #Has to be used instead of diplo range checks in laamp to landed interactions ep3_laamp_diplo_range_trigger = { TARGET = scope:recipient - LAAMP = scope:actor + LAAMP = scope:puppet_or_actor } } } @@ -2497,12 +2682,12 @@ learn_language_interaction = { desc = scheme_interaction_tt_learn_language_approved on_accept = { - scope:actor = { + scope:puppet_or_actor = { send_interface_toast = { type = event_toast_effect_neutral title = learn_language_interaction_notification - left_icon = scope:actor + left_icon = scope:puppet_or_actor right_icon = scope:recipient begin_scheme_basic_effect = { @@ -2512,16 +2697,18 @@ learn_language_interaction = { } } } - } - - ai_potential = { - primary_title.tier >= tier_county - NOR = { - has_trait = lazy - has_trait = paranoid - scheme_generic_ai_blocker_trigger = yes - primary_title = { - is_mercenary_company = yes + if = { + limit = { + scope:is_puppet_action ?= yes + scope:actor != scope:recipient + } + scope:actor = { + send_interface_toast = { + type = event_toast_effect_neutral + title = learn_language_interaction_notification_puppeteer + left_icon = scope:puppet_or_actor + right_icon = scope:recipient + } } } } @@ -2539,7 +2726,7 @@ learn_language_interaction = { # phase_has_catalyst = catalyst_learned_new_language_important # } # } -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # involvement = involved # phase_has_catalyst = catalyst_learned_new_language_important @@ -2549,7 +2736,7 @@ learn_language_interaction = { # value = 0 # if = { # limit = { -# scope:actor = { +# scope:puppet_or_actor = { # has_character_flag = agenda_towards_deescalation # } # } @@ -2557,7 +2744,7 @@ learn_language_interaction = { # } # else_if = { # limit = { -# scope:actor = { +# scope:puppet_or_actor = { # has_character_flag = agenda_towards_escalation # } # } @@ -2568,45 +2755,45 @@ learn_language_interaction = { modifier = { # Focus on befriending if that's the path you've chosen add = -50 - scope:actor = { + scope:puppet_or_actor = { has_perk = befriend_perk } } modifier = { # Prefer seducing if you've got the focus for it add = -20 - scope:actor = { + scope:puppet_or_actor = { has_focus = intrigue_temptation_focus } } modifier = { add = 50 - scope:actor = { + scope:puppet_or_actor = { has_perk = open_minded_perk } } modifier = { add = 50 - scope:actor = { + scope:puppet_or_actor = { culture = { has_cultural_parameter = rulers_want_to_learn_languages_of_coreligionists } } - scope:actor.religion = scope:recipient.religion + scope:puppet_or_actor.religion = scope:recipient.religion } modifier = { add = 25 - scope:actor = { + scope:puppet_or_actor = { has_trait = curious } } modifier = { add = 50 - scope:actor = { + scope:puppet_or_actor = { is_adult = no } } @@ -2614,35 +2801,35 @@ learn_language_interaction = { modifier = { add = 25 scope:recipient = { - has_relation_friend = scope:actor + has_relation_friend = scope:puppet_or_actor } } modifier = { add = 25 scope:recipient = { - has_relation_lover = scope:actor + has_relation_lover = scope:puppet_or_actor } } modifier = { add = 10 scope:recipient = { - has_relation_potential_friend = scope:actor + has_relation_potential_friend = scope:puppet_or_actor } } modifier = { add = 5 scope:recipient = { - is_close_family_of = scope:actor + is_close_family_of = scope:puppet_or_actor is_ruler = yes } } modifier = { # Muslims want to learn arabic add = 25 - scope:actor = { + scope:puppet_or_actor = { faith.religion = religion:islam_religion NOT = { knows_language = language_arabic @@ -2657,7 +2844,7 @@ learn_language_interaction = { modifier = { # Catholic clergy/pious people want to learn latin add = 50 - scope:actor = { + scope:puppet_or_actor = { religion = religion:catholic_religion OR = { has_trait = zealous @@ -2677,7 +2864,7 @@ learn_language_interaction = { modifier = { # Catholic clergy/pious people want to learn Italian add = 50 - scope:actor = { + scope:puppet_or_actor = { religion = religion:catholic_religion OR = { has_trait = zealous @@ -2697,20 +2884,20 @@ learn_language_interaction = { modifier = { # Clergy/pious people want to learn their HoF's language add = 50 - scope:actor = { + scope:puppet_or_actor = { exists = faith.religious_head OR = { has_trait = zealous is_clergy = yes } - NOT = { knows_language_of_culture = scope:actor.faith.religious_head.culture } + NOT = { knows_language_of_culture = scope:puppet_or_actor.faith.religious_head.culture } } - scope:recipient = { knows_language_of_culture = scope:actor.faith.religious_head.culture } + scope:recipient = { knows_language_of_culture = scope:puppet_or_actor.faith.religious_head.culture } } modifier = { # Coptic/Orthodox clergy/pious people want to learn greek add = 50 - scope:actor = { + scope:puppet_or_actor = { faith.religion = religion:eastern_orthodox_religion OR = { has_trait = zealous @@ -2730,7 +2917,7 @@ learn_language_interaction = { # modifier = { # Nestorian clergy/pious people want to learn aramaic # add = 50 -# scope:actor = { +# scope:puppet_or_actor = { # faith = faith:nestorian # OR = { # has_trait = zealous @@ -2745,12 +2932,12 @@ learn_language_interaction = { # culture = { # has_cultural_pillar = language_aramaic # } -## } -## } +# } +# } modifier = { add = 20 - scope:actor = { + scope:puppet_or_actor = { has_focus = diplomacy_foreign_affairs_focus any_neighboring_realm_same_rank_owner = { this = scope:recipient @@ -2760,32 +2947,32 @@ learn_language_interaction = { modifier = { add = 20 - scope:actor = { + scope:puppet_or_actor = { OR = { has_focus = learning_scholarship_focus has_focus = stewardship_duty_focus } } scope:recipient = { - is_vassal_of = scope:actor + is_vassal_of = scope:puppet_or_actor } } modifier = { add = 10 - exists = scope:actor.capital_county + exists = scope:puppet_or_actor.capital_county scope:recipient.culture = { - has_same_culture_language = scope:actor.capital_county.culture + has_same_culture_language = scope:puppet_or_actor.capital_county.culture } } modifier = { add = 100 - scope:actor.culture = { + scope:puppet_or_actor.culture = { has_cultural_tradition = tradition_loyal_soldiers } top_liege != this - scope:actor = { + scope:puppet_or_actor = { liege = scope:recipient } } @@ -2793,20 +2980,20 @@ learn_language_interaction = { modifier = { factor = 2 scope:recipient = { - is_powerful_vassal_of = scope:actor + is_powerful_vassal_of = scope:puppet_or_actor } } modifier = { factor = 2 - scope:actor = { + scope:puppet_or_actor = { learning >= 12 } } modifier = { factor = 0.5 - scope:actor = { + scope:puppet_or_actor = { learning <= 6 } } @@ -2814,8 +3001,8 @@ learn_language_interaction = { modifier = { factor = 0 - scope:actor.num_of_known_languages >= 5 - scope:actor = { + scope:puppet_or_actor.num_of_known_languages >= 5 + scope:puppet_or_actor = { NOR = { has_perk = pedagogy_perk has_trait = intellect_good_2 @@ -2828,7 +3015,508 @@ learn_language_interaction = { modifier = { factor = 0 - scope:actor.num_of_known_languages >= language_soft_cap + scope:puppet_or_actor.num_of_known_languages >= language_soft_cap + } + } +} + +study_faith_interaction = { + icon = icon_scheme_study_faith + category = interaction_category_friendly + common_interaction = yes + + send_name = START_SCHEME + + interface_priority = 42 + scheme = study_faith + + ai_targets = { + ai_recipients = liege + ai_recipients = spouses + ai_recipients = scripted_relations + ai_recipients = suzerain + ai_recipients = top_suzerain + ai_recipients = activity_host + ai_recipients = war_allies + } + ai_targets = { + ai_recipients = vassals + ai_recipients = peer_vassals + ai_recipients = tributaries + max = 10 + } + ai_targets = { + ai_recipients = neighboring_rulers + max = 5 + } + ai_frequency_by_tier = { + barony = 0 + county = 144 + duchy = 60 + kingdom = 36 + empire = 36 + hegemony = 36 + } + + is_available = { + trigger_if = { + limit = { is_ai = yes } + NOR = { + has_trait = paranoid + has_trait = lazy + primary_title ?= { + is_mercenary_company = yes + } + scheme_generic_ai_blocker_trigger = yes + } + } + } + + is_shown = { + scope:puppet_or_actor ?= { faith != scope:recipient.faith } + scope:puppet_or_actor != scope:recipient + } + + is_valid_showing_failures_only = { + trigger_if = { + limit = { + scope:is_puppet_action ?= yes + scope:actor = scope:recipient + } + custom_tooltip = { + text = study_faith_nothing_left_to_learn_tt_puppet_self + scope:puppet_or_actor = { + study_faith_has_anything_to_learn_trigger = { RITE = scope:recipient.rite } + } + } + } + trigger_else = { + custom_tooltip = { + text = study_faith_nothing_left_to_learn_tt + scope:puppet_or_actor = { + study_faith_has_anything_to_learn_trigger = { RITE = scope:recipient.rite } + } + } + } + scope:puppet_or_actor = { + can_start_scheme = { + type = study_faith + target_character = scope:recipient + } + } + #limit range for landless adventurers + trigger_if = { + limit = { + scope:puppet_or_actor = { + has_government = landless_adventurer_government + } + } + #Has to be used instead of diplo range checks in laamp to landed interactions + ep3_laamp_diplo_range_trigger = { + TARGET = scope:recipient + LAAMP = scope:puppet_or_actor + } + } + trigger_if = { + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + piety >= medium_piety_value + } + } + } + + desc = { + first_valid = { + triggered_desc = { + trigger = { + scope:is_puppet_action ?= yes + scope:actor = scope:recipient + } + desc = scheme_interaction_tt_study_faith_approved_puppet_self + } + desc = scheme_interaction_tt_study_faith_approved + } + } + notification_text = study_faith_interaction_notification_int + + cost = { + piety = { + value = medium_piety_value + if = { + limit = { scope:is_puppet_action ?= yes } + multiply = 0 + } + } + } + + send_option = { + flag = study_faith_ask_directly + current_description = { + first_valid = { + triggered_desc = { + trigger = { + scope:is_puppet_action ?= yes + scope:actor = scope:recipient + } + desc = study_faith_interaction.tt.ask_directly_puppet_self + } + desc = study_faith_interaction.tt.ask_directly + } + } + } + send_option = { + flag = study_faith_ask_for_emissary + current_description = { + first_valid = { + triggered_desc = { + trigger = { + scope:is_puppet_action ?= yes + scope:actor = scope:recipient + } + desc = study_faith_interaction.tt.ask_for_emissary_puppet_self + } + desc = study_faith_interaction.tt.ask_for_emissary + } + } + } + send_option = { + flag = study_faith_study_from_afar + is_valid = { + custom_tooltip = { + text = can_only_be_learned_in_person_tt + scope:recipient.faith = { + NOT = { has_doctrine_parameter = can_only_be_learned_in_person } + } + } + } + current_description = { + first_valid = { + triggered_desc = { + trigger = { + scope:is_puppet_action ?= yes + scope:actor = scope:recipient + } + desc = study_faith_interaction.tt.study_from_afar_puppet_self + } + desc = study_faith_interaction.tt.study_from_afar + } + } + } + + auto_accept = { scope:study_faith_study_from_afar = yes } + + on_accept = { + if = { + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + add_piety = { value = { add = medium_piety_value max = piety multiply = -1 } } + } + } + scope:puppet_or_actor = { + send_interface_toast = { + type = event_toast_effect_neutral + title = study_faith_interaction_notification + + left_icon = scope:puppet_or_actor + right_icon = scope:recipient + + begin_scheme_basic_effect = { + SCHEME_TYPE = study_faith + TARGET_TYPE = target_character + TARGET_SCOPE = scope:recipient + } + scope:new_scheme ?= { + if = { + limit = { scope:study_faith_ask_directly = yes } + add_scheme_modifier = { + type = study_faith_ask_directly_modifier + } + } + else_if = { + limit = { scope:study_faith_ask_for_emissary = yes } + add_scheme_modifier = { + type = study_faith_ask_for_emissary_modifier + } + } + else_if = { + limit = { scope:study_faith_study_from_afar = yes } + add_scheme_modifier = { + type = study_faith_study_from_afar_modifier + } + } + } + } + } + if = { + limit = { + scope:is_puppet_action ?= yes + scope:actor != scope:recipient + } + scope:actor = { + send_interface_toast = { + type = event_toast_effect_neutral + title = study_faith_interaction_notification_puppeteer + left_icon = scope:puppet_or_actor + right_icon = scope:recipient + } + } + } + if = { + limit = { + scope:study_faith_ask_directly = yes + scope:is_puppet_action ?= yes + scope:actor = scope:recipient + } + custom_label = study_faith_interaction.accept.study_faith_ask_directly_puppet_self + } + else_if = { + limit = { scope:study_faith_ask_directly = yes } + custom_label = study_faith_interaction.accept.study_faith_ask_directly + } + else_if = { + limit = { + scope:study_faith_ask_for_emissary = yes + scope:is_puppet_action ?= yes + scope:actor = scope:recipient + } + custom_label = study_faith_interaction.accept.study_faith_ask_for_emissary_puppet_self + } + else_if = { + limit = { scope:study_faith_ask_for_emissary = yes } + custom_label = study_faith_interaction.accept.study_faith_ask_for_emissary + } + else_if = { + limit = { + scope:study_faith_study_from_afar = yes + scope:is_puppet_action ?= yes + scope:actor = scope:recipient + } + custom_label = study_faith_interaction.accept.study_faith_study_from_afar_puppet_self + } + else_if = { + limit = { scope:study_faith_study_from_afar = yes } + custom_label = study_faith_interaction.accept.study_faith_study_from_afar + } + } + + ai_accept = { + base = 0 + + modifier = { + add = 25 + scope:puppet_or_actor = { + has_perk = theologian_perk + } + desc = study_faith_interaction.ai_accept.theologian_perk + } + + modifier = { + add = 25 + scope:recipient = { + has_trait = curious + } + desc = study_faith_interaction.ai_accept.curious + } + + modifier = { + add = 25 + scope:recipient = { + has_relation_friend = scope:puppet_or_actor + } + desc = WE_ARE_FRIENDS + } + + modifier = { + add = 25 + scope:recipient = { + has_relation_lover = scope:puppet_or_actor + } + desc = WE_ARE_LOVERS + } + + modifier = { + add = 25 + scope:recipient = { + is_close_family_of = scope:puppet_or_actor + is_ruler = yes + } + desc = study_faith_interaction.ai_accept.close_family_ruler + } + + opinion_modifier = { # Opinion Factor + who = scope:recipient + opinion_target = scope:puppet_or_actor + multiplier = 0.5 + desc = AI_OPINION_REASON + } + + modifier = { + add = -30 + scope:recipient.faith = { + faith_hostility_level = { + target = scope:puppet_or_actor.faith + value = faith_evil_level + } + } + desc = study_faith_interaction.ai_accept.evil_faith + } + modifier = { + add = -15 + scope:recipient.faith = { + faith_hostility_level = { + target = scope:puppet_or_actor.faith + value = faith_hostile_level + } + } + desc = study_faith_interaction.ai_accept.hostile_faith + } + modifier = { + add = 5 + scope:recipient.faith = { + faith_hostility_level = { + target = scope:puppet_or_actor.faith + value = faith_astray_level + } + } + desc = study_faith_interaction.ai_accept.astray_faith + } + modifier = { + add = 25 + scope:recipient.faith = { + faith_hostility_level = { + target = scope:puppet_or_actor.faith + value = faith_fully_accepted_level + } + } + desc = study_faith_interaction.ai_accept.accepted_faith + } + + modifier = { + add = 60 + scope:study_faith_ask_for_emissary = yes + desc = study_faith_interaction.ai_accept.ask_for_emissary + } + } + + ai_will_do = { + base = 0 + + modifier = { # Focus on befriending if that's the path you've chosen + add = -50 + scope:puppet_or_actor = { + has_perk = befriend_perk + } + } + + modifier = { # Prefer seducing if you've got the focus for it + add = -20 + scope:puppet_or_actor = { + has_focus = intrigue_temptation_focus + } + } + + modifier = { + add = 35 + scope:puppet_or_actor = { + has_focus = learning_theology_focus + } + } + + modifier = { + add = 35 + scope:puppet_or_actor = { + has_perk = theologian_perk + } + } + + modifier = { + add = 25 + scope:puppet_or_actor = { + has_perk = open_minded_perk + } + } + + modifier = { + add = 25 + scope:puppet_or_actor = { + has_trait = curious + } + } + + modifier = { + add = 25 + scope:recipient = { + has_relation_friend = scope:puppet_or_actor + } + } + + modifier = { + add = 25 + scope:recipient = { + has_relation_lover = scope:puppet_or_actor + } + } + + modifier = { + add = 10 + scope:recipient = { + has_relation_potential_friend = scope:puppet_or_actor + } + } + + modifier = { + add = 25 + scope:recipient = { + is_close_family_of = scope:puppet_or_actor + is_ruler = yes + } + } + + modifier = { + add = 20 + scope:puppet_or_actor = { + has_focus = diplomacy_foreign_affairs_focus + any_neighboring_realm_same_rank_owner = { + this = scope:recipient + } + } + } + + modifier = { + add = 20 + scope:puppet_or_actor = { + has_focus = stewardship_duty_focus + } + scope:recipient = { + is_vassal_of = scope:puppet_or_actor + } + } + + modifier = { + add = 10 + exists = scope:puppet_or_actor.capital_county + scope:recipient.faith = scope:puppet_or_actor.capital_county.faith + } + + modifier = { + factor = 2 + scope:recipient = { + is_powerful_vassal_of = scope:puppet_or_actor + } + } + + modifier = { + factor = 2 + scope:puppet_or_actor = { + learning >= 12 + } + } + + modifier = { + factor = 0.5 + scope:puppet_or_actor = { + learning <= 6 + } } } } diff --git a/common/character_interactions/00_tradition_interactions.txt b/common/character_interactions/00_tradition_interactions.txt index 3872424e3..e4232da1f 100644 --- a/common/character_interactions/00_tradition_interactions.txt +++ b/common/character_interactions/00_tradition_interactions.txt @@ -12,12 +12,40 @@ greeting = positive notification_text = REQUEST_SPARRING_TEXT + filter_tags = { accolade } + + is_available = { + trigger_if = { + limit = { is_ai = yes } + number_of_knights > 0 + OR = { + culture ?= { + has_cultural_parameter = can_use_sparring_duel + } + has_personal_tenet_flag = tenet_unrelenting_faith_sparring + } + NOT = { has_trait = craven } + can_start_single_combat_trigger = yes + is_imprisoned = no + } + OR = { + culture ?= { + has_cultural_parameter = can_use_sparring_duel + } + has_personal_tenet_flag = tenet_unrelenting_faith_sparring + top_participant_group:dynastic_cycle ?= { + participant_group_type = expansion_movement + } + } + } + is_shown = { scope:actor = { OR = { culture = { has_cultural_parameter = can_use_sparring_duel } + has_personal_tenet_flag = tenet_unrelenting_faith_sparring top_participant_group:dynastic_cycle ?= { participant_group_type = expansion_movement } @@ -137,17 +165,6 @@ } } - # AI - ai_potential = { - culture = { - has_cultural_parameter = can_use_sparring_duel - } - NOT = { has_trait = craven } - is_imprisoned = no - can_start_single_combat_trigger = yes - number_of_knights > 0 - } - ai_target_quick_trigger = { adult = yes } @@ -217,25 +234,30 @@ appoint_podesta_interaction = { greeting = positive notification_text = REQUEST_REPUBLIC_TEXT - is_shown = { - scope:actor != scope:recipient # Can't make yourself a Podesta. - scope:actor = { - culture = { + is_available = { + trigger_if = { + limit = { is_ai = yes } + culture ?= { + has_cultural_era_or_later = culture_era_high_medieval has_cultural_parameter = can_make_republican_vassals } - any_held_title = { - count > 1 - } + primary_title.tier > tier_county } + culture ?= { + has_cultural_parameter = can_make_republican_vassals + } + any_held_title = { + count > 1 + } + } + + is_shown = { + scope:actor != scope:recipient # Can't make yourself a Podesta. scope:recipient = { is_ai = yes is_landed = yes target_is_liege_or_above = scope:actor - NOR = { - government_has_flag = government_is_republic - government_has_flag = government_is_prepublic - government_has_flag = government_is_urepublic - } + NOT = { government_has_flag = government_is_republic } } } @@ -258,11 +280,7 @@ appoint_podesta_interaction = { scope:recipient = { target_is_liege_or_above = scope:actor - NOR = { - government_has_flag = government_is_republic - government_has_flag = government_is_prepublic - government_has_flag = government_is_urepublic - } + NOT = { government_has_flag = government_is_republic } is_claimant = no custom_description = { @@ -310,15 +328,9 @@ appoint_podesta_interaction = { any_held_title = { count = 1 title_tier = county - OR = { - any_county_province = { - culture = { - has_cultural_parameter = can_make_republican_vassals - } - } - OR = { - government_has_flag = government_is_prepublic - government_has_flag = government_is_urepublic + any_county_province = { + culture = { + has_cultural_parameter = can_make_republican_vassals } } } @@ -350,71 +362,14 @@ appoint_podesta_interaction = { left_icon = scope:actor right_icon = scope:recipient - if = { - limit = { - scope:actor = { government_has_flag = government_is_urepublic } - } - scope:recipient = { - show_as_tooltip = { - change_government = urbanrepublic_government - create_title_and_vassal_change = { - type = returned - save_scope_as = change - add_claim_on_loss = no - } - primary_title = { - add_to_global_variable_list = { - name = urepublic_list - target = prev - } - } - every_vassal = { - limit = { - government_has_flag = government_is_republic - } - every_held_title = { - change_title_holder = { - holder = scope:recipient - change = scope:change - take_baronies = yes - } - } - } - resolve_title_and_vassal_change = scope:change - } - } - } - else_if = { - limit = { - scope:actor = { government_has_flag = government_is_prepublic } - } - scope:recipient = { - show_as_tooltip = { - change_government = peasantrepublic_government - create_title_and_vassal_change = { - type = returned - save_scope_as = change - add_claim_on_loss = no - } - primary_title = { - add_to_global_variable_list = { - name = prepublic_list - target = prev - } - } - every_vassal = { - limit = { - government_has_flag = government_is_republic - } - every_held_title = { - change_title_holder = { - holder = scope:recipient - change = scope:change - take_baronies = yes - } - } - } - resolve_title_and_vassal_change = scope:change + + scope:recipient = { + show_as_tooltip = { + change_government = republic_government + create_title_and_vassal_change = { + type = returned + save_scope_as = change + add_claim_on_loss = no } every_vassal = { limit = { @@ -468,15 +423,6 @@ appoint_podesta_interaction = { auto_accept = yes - # AI - ai_potential = { - culture = { - has_cultural_parameter = can_make_republican_vassals - has_cultural_era_or_later = culture_era_high_medieval - } - primary_title.tier > tier_county - } - ai_target_quick_trigger = { adult = yes } diff --git a/common/character_interactions/00_tribal_interactions.txt b/common/character_interactions/00_tribal_interactions.txt index 17e51d450..cb1642738 100644 --- a/common/character_interactions/00_tribal_interactions.txt +++ b/common/character_interactions/00_tribal_interactions.txt @@ -10,14 +10,16 @@ auto_accept = yes + is_available = { + NOR = { + government_has_flag = government_is_tribal + government_has_flag = government_is_in_steppe + } + } + is_shown = { scope:actor = { this = scope:recipient - NOR = { - government_has_flag = government_is_tribal - government_has_flag = government_is_nomadic - government_has_flag = government_is_true_herder - } } } @@ -59,65 +61,7 @@ cost = { treasury_or_gold = { scope:actor = { - if = { - limit = { - scope:target.county = { - has_variable = was_razed - } - } - add = { - value = 50 - desc = BASE - } - } - else_if = { - limit = { - scope:target.county = { - culture = scope:actor.culture - } - } - add = { - value = 200 - desc = BASE - } - } - else = { - add = { - value = feudalize_holding_interaction_cost - desc = BASE - } - } - if = { - limit = { # More expensive for admin to make barbarians civilized... - government_has_flag = government_is_administrative - } - add = { - value = feudalize_holding_interaction_cost - multiply = 0.25 - desc = has_admin_government - } - if = { - limit = { # Admin get a bonus for high bureaucracy levels - OR = { - has_realm_law = imperial_bureaucracy_2 - has_realm_law = imperial_bureaucracy_3 - } - } - subtract = { - value = feudalize_holding_interaction_cost - multiply = { - value = 0.1 - if = { - limit = { - has_realm_law = imperial_bureaucracy_3 - } - add = 0.15 - } - } - desc = imperial_bureaucracy - } - } - } + add = feudalize_holding_interaction_cost } } } @@ -127,84 +71,17 @@ send_interface_toast = { type = event_toast_effect_good title = feudalize_holding_interaction_notification - right_icon = scope:actor - if = { - limit = { - scope:target.title_province = { - OR = { - has_holding_type = nomad_holding - has_holding_type = herder_holding - } - } - } - if = { - limit = { - OR = { - scope:target.county.culture = scope:actor.culture - scope:target.county = { has_variable = was_razed } - } - } - } - else_if = { - limit = { - OR = { - government_has_flag = government_is_tribal - scope:target.county.culture = { has_same_culture_heritage = scope:actor.culture } - } - } - scope:target.county = { - add_county_modifier = { - modifier = mpo_feudalize_nomadic_land_modifier - years = 5 - } - } - } - else = { - scope:target.county = { - add_county_modifier = { - modifier = mpo_feudalize_nomadic_land_modifier - years = 30 - } - } - } - # SILK ROAD - scope:target = { - tgp_silk_road_feudalize_holding_effect = yes - } - } - - if = { - limit = { exists = scope:target.title_province } - scope:target.title_province = { - set_holding_type = castle_holding - } - } - - scope:target ?= { - if = { - limit = { - title_province = { - geographical_region = geographical_region:mpo_region_permafrost - } - } - if = { - limit = { has_county_modifier = mpo_siberian_permafrost_modifier } - remove_county_modifier = mpo_siberian_permafrost_modifier - } - else_if = { - limit = { has_county_modifier = mpo_siberian_permafrost_modifier_bad } - remove_county_modifier = mpo_siberian_permafrost_modifier_bad - } - } - } + scope:target.title_province ?= { + holding_pre_feudalize_effect = yes + set_holding_type = castle_holding + } } } } - # Interaction frequency determined by code, do not change - ai_frequency = 0 + # Interaction frequency determined by code, do not set frequency # Used to determine which holding should be feudalized over another AND how important this AI goal is compared to others, like creating titles and constructing new holdings ai_will_do = { @@ -224,10 +101,13 @@ tribalize_holding_interaction = { auto_accept = yes + is_available = { + government_has_flag = government_is_tribal + } + is_shown = { scope:actor = { this = scope:recipient - government_has_flag = government_is_tribal } } @@ -333,41 +213,17 @@ tribalize_holding_interaction = { send_interface_toast = { type = event_toast_effect_good title = feudalize_holding_interaction_notification - right_icon = scope:actor - if = { - limit = { - OR = { - scope:target.county.culture = scope:actor.culture - scope:target.county = { - has_variable = was_razed - } - } - } - } - else = { - scope:target.county = { - add_county_modifier = { - modifier = mpo_feudalize_nomadic_land_modifier - years = 5 - } - } - } - - if = { - limit = { exists = scope:target.title_province } - scope:target.title_province = { - set_holding_type = tribal_holding - } + scope:target.title_province ?= { + holding_pre_tribalize_effect = yes + set_holding_type = tribal_holding } } } } - # Interaction frequency determined by code, do not change - ai_frequency = 0 - + # Interaction frequency determined by code, do not set frequency # Used to determine which holding should be feudalized over another AND how important this AI goal is compared to others, like creating titles and constructing new holdings ai_will_do = { base = 1500 @@ -385,13 +241,27 @@ support_feudalize_tribal_holding_interaction = { auto_accept = yes - is_shown = { - scope:actor = { - NOR = { - government_has_flag = government_is_tribal - government_has_flag = government_is_nomadic - } + is_available = { + trigger_if = { + limit = { is_ai = yes } + is_adult = yes + # The AI only does this if they have plenty of gold to spare + gold >= { value = feudalize_holding_interaction_cost multiply = 4 } + # Some basic triggers + is_at_war = no + # Piety and Legitimacy, you say... ? + ai_has_pious_builder_personality = yes + NOT = { has_variable = conqueror } + # Warring AI don't do this - They want to spend their gold on war! + ai_has_warlike_personality = no } + NOR = { + government_has_flag = government_is_tribal + government_has_flag = government_is_nomadic + } + } + + is_shown = { scope:recipient = { target_is_liege_or_above = scope:actor NOR = { @@ -401,7 +271,7 @@ support_feudalize_tribal_holding_interaction = { this != scope:actor any_held_title = { tier <= tier_county - title_province = { + title_province ?= { OR = { has_holding_type = tribal_holding has_holding_type = nomad_holding @@ -448,170 +318,22 @@ support_feudalize_tribal_holding_interaction = { } cost = { - gold = { - value = 0 + treasury_or_gold = { scope:actor = { - if = { - limit = { - has_treasury = no - } - add = { - value = feudalize_holding_interaction_cost - desc = BASE - } - if = { - limit = { # More expensive for admin to make these barbarians civilized... - government_has_flag = government_is_administrative - } - add = { - value = feudalize_holding_interaction_cost - multiply = 0.25 - desc = has_admin_government - } - if = { - limit = { # Admin get a bonus for high bureaucracy levels - OR = { - has_realm_law = imperial_bureaucracy_2 - has_realm_law = imperial_bureaucracy_3 - } - } - subtract = { - value = feudalize_holding_interaction_cost - multiply = { - value = 0.1 - if = { - limit = { - has_realm_law = imperial_bureaucracy_3 - } - add = 0.15 - } - } - desc = imperial_bureaucracy - } - } - } - } - } - } - treasury = { - value = 0 - scope:actor = { - if = { - limit = { - has_treasury = yes - } - add = { - value = feudalize_holding_interaction_cost - desc = BASE - } - if = { - limit = { # More expensive for admin to make these barbarians civilized... - government_has_flag = government_is_administrative - } - add = { - value = feudalize_holding_interaction_cost - multiply = 0.25 - desc = has_admin_government - } - if = { - limit = { # Admin get a bonus for high bureaucracy levels - OR = { - has_realm_law = imperial_bureaucracy_2 - has_realm_law = imperial_bureaucracy_3 - } - } - subtract = { - value = feudalize_holding_interaction_cost - multiply = { - value = 0.1 - if = { - limit = { - has_realm_law = imperial_bureaucracy_3 - } - add = 0.15 - } - } - desc = imperial_bureaucracy - } - } - } - } + add = feudalize_holding_interaction_cost } } } - + is_highlighted = { # Highlight the interaction if we have the gold to spare scope:actor = { - gold >= { - value = feudalize_holding_interaction_cost - if = { - limit = { # More expensive for admin to convert these... Barbarians... - government_has_flag = government_is_administrative - } - multiply = { - value = 1.25 - desc = has_admin_government - } - } - } + treasury_or_gold >= feudalize_holding_interaction_cost } } on_accept = { scope:recipient = { - # Add some opinion to make it worthwhile - add_opinion = { - target = scope:actor - modifier = grateful_opinion - opinion = 30 - } - - if = { - limit = { - scope:target.title_province = { - OR = { - has_holding_type = nomad_holding - has_holding_type = herder_holding - } - } - } - if = { - limit = { - OR = { - scope:target.culture = scope:recipient.culture - scope:target = { has_variable = was_razed } - } - } - } - else_if = { - limit = { - OR = { - government_has_flag = government_is_tribal - scope:target.culture = { has_same_culture_heritage = scope:recipient.culture } - } - } - scope:target = { - add_county_modifier = { - modifier = mpo_feudalize_nomadic_land_modifier - years = 5 - } - } - } - else = { - scope:target = { - add_county_modifier = { - modifier = mpo_feudalize_nomadic_land_modifier - years = 30 - } - } - } - # SILK ROAD - scope:target = { - tgp_silk_road_feudalize_holding_effect = yes - } - } - # Notify actor and recipient scope:actor = { if = { #Temple Citadel @@ -623,11 +345,9 @@ support_feudalize_tribal_holding_interaction = { left_icon = scope:actor right_icon = scope:target - if = { - limit = { exists = scope:target.title_province } - scope:target.title_province = { - set_holding_type = temple_citadel_holding - } + scope:target.title_province ?= { + holding_pre_feudalize_effect = yes + set_holding_type = temple_citadel_holding } mandala_piety_gain_effect = { PIETY_AMOUNT = massive_piety_gain } add_legitimacy_effect = { LEGITIMACY = medium_legitimacy_gain } @@ -642,11 +362,9 @@ support_feudalize_tribal_holding_interaction = { right_icon = scope:target show_as_tooltip = { - if = { - limit = { exists = scope:target.title_province } - scope:target.title_province = { - set_holding_type = temple_citadel_holding - } + scope:target.title_province ?= { + holding_pre_feudalize_effect = yes + set_holding_type = temple_citadel_holding } } } @@ -661,11 +379,9 @@ support_feudalize_tribal_holding_interaction = { left_icon = scope:actor right_icon = scope:target - if = { - limit = { exists = scope:target.title_province } - scope:target.title_province = { - set_holding_type = castle_holding - } + scope:target.title_province ?= { + holding_pre_feudalize_effect = yes + set_holding_type = castle_holding } add_legitimacy_effect = { LEGITIMACY = medium_legitimacy_gain } } @@ -679,11 +395,9 @@ support_feudalize_tribal_holding_interaction = { right_icon = scope:target show_as_tooltip = { - if = { - limit = { exists = scope:target.title_province } - scope:target.title_province = { - set_holding_type = castle_holding - } + scope:target.title_province ?= { + holding_pre_feudalize_effect = yes + set_holding_type = castle_holding } } } @@ -695,7 +409,7 @@ support_feudalize_tribal_holding_interaction = { scope:actor = { # If you are admin, you get some influence for your efforts if = { - limit = { government_has_flag = government_is_administrative } + limit = { government_has_flag = government_has_influence } change_influence = medium_influence_gain } } @@ -716,19 +430,6 @@ support_feudalize_tribal_holding_interaction = { max = 10 } - ai_potential = { - # Some basic triggers - is_at_war = no - is_adult = yes - # The AI only does this if they have plenty of gold to spare - gold >= { value = feudalize_holding_interaction_cost multiply = 4 } - # Warring AI don't do this - They want to spend their gold on war! - ai_has_warlike_personality = no - # Piety and Legitimacy, you say... ? - ai_has_pious_builder_personality = yes - NOT = { has_variable = conqueror } - } - ai_will_do = { base = 25 modifier = { @@ -759,6 +460,9 @@ turn_subject_into_mandala_interaction = { ai_targets = { ai_recipients = vassals } + ai_targets = { + ai_recipients = tributaries + } ai_target_quick_trigger = { adult = yes } @@ -773,6 +477,14 @@ turn_subject_into_mandala_interaction = { desc = turn_subject_into_mandala_interaction_desc + is_available = { + trigger_if = { + limit = { is_ai = yes } + government_has_flag = government_is_mandala + is_adult = yes + } + } + is_shown = { scope:actor = { government_has_flag = government_is_mandala } scope:recipient = { @@ -782,9 +494,9 @@ turn_subject_into_mandala_interaction = { is_landed = yes is_ruler = yes OR = { - liege = scope:actor + liege ?= scope:actor AND = { - overlord = scope:actor + overlord ?= scope:actor scope:actor = { has_realm_law_flag = can_convert_all_subjects_to_mandalas } @@ -824,9 +536,9 @@ turn_subject_into_mandala_interaction = { NOT = { scope:actor.diarch ?= scope:recipient } } custom_tooltip = { - text = head_of_faith_unable_to_change_government_desc + text = clergy_unable_to_change_government_desc NOT = { - scope:recipient = { faith.religious_head ?= this } + scope:recipient = { holds_religious_office_trigger = yes } } } } @@ -890,34 +602,28 @@ turn_subject_into_mandala_interaction = { scope:recipient = { custom_tooltip = demand_mandala_interaction_vassal_refuses } } - ai_potential = { - government_has_flag = government_is_mandala - is_adult = yes - } - ai_will_do = { base = 100 modifier = { factor = 0 scope:recipient = { highest_held_title_tier >= tier_county } - gold >= 300 + gold < 300 } modifier = { factor = 0 scope:recipient = { highest_held_title_tier >= tier_duchy } - gold >= 600 + gold < 600 } modifier = { factor = 0 scope:recipient = { highest_held_title_tier >= tier_kingdom } - gold >= 2000 + gold < 2000 } modifier = { scope:recipient.capital_county.title_province = { - NOR = { - has_holding_type = temple_citadel_holding - has_holding_type = church_holding - has_holding_type = castle_holding + OR = { + has_holding_type = nomad_holding + has_holding_type = herder_holding } } factor = 0 diff --git a/common/character_interactions/00_tributary_interactions.txt b/common/character_interactions/00_tributary_interactions.txt index 587714ef4..d3a895c2d 100644 --- a/common/character_interactions/00_tributary_interactions.txt +++ b/common/character_interactions/00_tributary_interactions.txt @@ -17,7 +17,7 @@ become_tributary_interaction = { NOR = { this = scope:actor this = scope:actor.suzerain - top_suzerain = scope:actor + top_suzerain ?= scope:actor } can_have_tributaries_trigger = yes } @@ -51,7 +51,7 @@ become_tributary_interaction = { limit = { scope:recipient = { government_has_flag = government_is_mandala } scope:actor = { - OR = { + OR = { government_has_flag = government_is_tribal government_has_flag = government_is_mandala } @@ -67,9 +67,7 @@ become_tributary_interaction = { } } scope:actor = { - is_physically_able = yes - is_travelling = no - NOT = { exists = involved_activity } + is_available_allow_travelling = yes is_confederation_member = no is_at_war = no } @@ -92,7 +90,7 @@ become_tributary_interaction = { send_option = { flag = normal_obligations localization = normal_tributary_obligations - starts_enabled = { always = yes } + starts_enabled = { always = yes } } # High starting obligations @@ -106,66 +104,134 @@ become_tributary_interaction = { on_send = { if = { limit = { scope:recipient = { highest_held_title_tier >= tier_hegemony } } - if = { - limit = { scope:recipient.primary_title = title:h_china } - open_view_data = { - view = decision_detail - data = decision:tribute_mission_decision_china - player = scope:actor + scope:actor = { + if = { + limit = { scope:recipient.primary_title = title:h_china } + open_view_data = { + view = decision_detail + data = decision:tribute_mission_decision_china + player = scope:actor + } } - } - else_if = { - limit = { scope:recipient.primary_title = title:h_roman_empire } - open_view_data = { - view = decision_detail - data = decision:tribute_mission_decision_roman_empire - player = scope:actor + else_if = { + limit = { scope:recipient.primary_title = title:h_roman_empire } + open_view_data = { + view = decision_detail + data = decision:tribute_mission_decision_roman_empire + player = scope:actor + } } - } - else_if = { - limit = { scope:recipient.primary_title = title:h_eastern_roman_empire } - open_view_data = { - view = decision_detail - data = decision:tribute_mission_decision_eastern_roman_empire - player = scope:actor + else_if = { + limit = { scope:recipient.primary_title = title:h_eastern_roman_empire } + open_view_data = { + view = decision_detail + data = decision:tribute_mission_decision_eastern_roman_empire + player = scope:actor + } } - } - else_if = { - limit = { scope:recipient.primary_title = title:h_dar_al_islam } - open_view_data = { - view = decision_detail - data = decision:tribute_mission_decision_dar_al_islam - player = scope:actor + else_if = { + limit = { scope:recipient.primary_title = title:h_dar_al_islam } + open_view_data = { + view = decision_detail + data = decision:tribute_mission_decision_dar_al_islam + player = scope:actor + } } - } - else_if = { - limit = { scope:recipient.primary_title = title:h_india } - open_view_data = { - view = decision_detail - data = decision:tribute_mission_decision_india - player = scope:actor + else_if = { + limit = { scope:recipient.primary_title = title:h_india } + open_view_data = { + view = decision_detail + data = decision:tribute_mission_decision_india + player = scope:actor + } } - } - else_if = { + else_if = { limit = { scope:recipient.primary_title = title:h_numenor } open_view_data = { view = decision_detail data = decision:tribute_mission_decision_numenor player = scope:actor + } } - } - else_if = { + else_if = { limit = { scope:recipient.primary_title = title:h_europa } open_view_data = { view = decision_detail data = decision:tribute_mission_decision_europa player = scope:actor + } } } } } on_accept = { + #Non-mandala existing suzerains get really pissed + if = { + limit = { + scope:actor.suzerain ?= { + NOR = { + government_has_flag = government_is_mandala + this = scope:actor + } + } + } + scope:actor.suzerain = { + if = { + limit = { + has_relation_rival = scope:actor + } + scope:actor = { + set_relation_nemesis = { + reason = rival_disloyal_tributary + target = scope:actor.suzerain + } + } + + } + else = { + scope:actor = { + set_relation_rival = { + reason = rival_disloyal_tributary + target = scope:actor.suzerain + } + } + } + add_opinion = { + modifier = betrayal_opinion + target = scope:actor + opinion = -75 + } + + if = { + limit = { + NOT = { + any_claim = { + this = scope:actor.primary_title + } + } + } + add_unpressed_claim = scope:actor.primary_title + } + } + } + #Mandala suzerain is a little annoyed + else_if = { + limit = { + scope:actor.suzerain ?= { + NOT = { + this = scope:actor + } + } + } + scope:actor.suzerain = { + add_opinion = { + modifier = betrayal_opinion + target = scope:actor + opinion = -30 + } + } + } if = { limit = { scope:recipient = { highest_held_title_tier < tier_hegemony } } scope:actor = { @@ -214,9 +280,10 @@ become_tributary_interaction = { } is_available = { - NOT = { government_has_flag = cannot_be_vassal_or_liege } - top_liege = this # You have to be independent - This check exists to prevent a lot of edge-cases where you can change liege + is_landed = yes # Landless have no realm to render tribute from; + top_liege ?= this # You have to be independent - This check exists to prevent a lot of edge-cases where you can change liege is_confederation_member = no + NOT = { government_has_flag = cannot_be_vassal_or_liege } } ai_targets = { @@ -276,13 +343,13 @@ become_tributary_interaction = { add = -100 } # Different faith, no pluralism - modifier = { + modifier = { desc = offer_vassalization_interaction_aibehavior_differentfaith_tt trigger = { scope:actor = { NOR = { # Of two different faiths AND the potential vassal's faith is not pluralistic. faith = scope:recipient.faith - faith = { has_doctrine = doctrine_pluralism_pluralistic } + rite = { rite_has_doctrine = doctrine_pluralism_pluralistic } } } } @@ -313,7 +380,7 @@ become_tributary_interaction = { } } # Cultural Acceptance - modifier = { + modifier = { scope:actor = { NOT = { # cultural condition below doesn't have to apply if both actor and recipient have nomadic_philosophy has_trait = nomadic_philosophy @@ -334,7 +401,7 @@ become_tributary_interaction = { desc = cultural_acceptance_interaction_reason } # Same language - modifier = { + modifier = { add = 5 desc = speaks_same_language_interaction_reason trigger = { @@ -426,7 +493,7 @@ become_tributary_interaction = { any_neighboring_top_liege_realm_owner = { has_unruined_mandala_capital_trigger = yes government_has_flag = government_is_mandala - NOR = { + NOR = { this = scope:recipient this = scope:actor } @@ -435,14 +502,14 @@ become_tributary_interaction = { any_neighboring_top_suzerain_realm_owner = { has_unruined_mandala_capital_trigger = yes government_has_flag = government_is_mandala - NOR = { + NOR = { this = scope:recipient this = scope:actor } save_temporary_scope_as = suzerain_comparison } } - } + } always = yes } trigger_else = { always = no } @@ -476,7 +543,7 @@ become_tributary_interaction = { add = tgp_sea_legacy_tributary_acceptance_value } # I am higher rank than you - modifier = { + modifier = { desc = tributary_interaction_aibehavior_recipient_tier_tt trigger = { scope:actor = { @@ -485,13 +552,13 @@ become_tributary_interaction = { } add = { value = scope:actor.highest_held_title_tier - subtract = scope:recipient.highest_held_title_tier + subtract = scope:recipient.highest_held_title_tier multiply = 50 multiply = -1 } } # Same Faith and Actor is a god King - modifier = { + modifier = { desc = embrace_as_tributary_interaction_same_faith scope:recipient = { faith = scope:actor.faith @@ -502,16 +569,12 @@ become_tributary_interaction = { } } # Different faith, no pluralism. - modifier = { + modifier = { desc = offer_vassalization_interaction_aibehavior_differentfaith_tt trigger = { - scope:recipient = { - faith = { - NOR = { # Of two different faiths AND the potential tributary's faith is not pluralistic - this = scope:actor.faith - has_doctrine = doctrine_pluralism_pluralistic - } - } + NOR = { # Of two different faiths AND the potential tributary's faith is not pluralistic + scope:recipient.faith = scope:actor.faith + scope:recipient.rite = { rite_has_doctrine = doctrine_pluralism_pluralistic } } } add = { @@ -541,26 +604,12 @@ become_tributary_interaction = { } } # Different religion Family - We prefer god kings to be vaguely within our own world view - modifier = { + modifier = { desc = embrace_as_tributary_interaction_other_religion_family - scope:actor = { - NOT = { government_has_flag = government_is_wanua } - } - scope:recipient.faith.religion = { - switch = { - trigger = is_in_family - rf_pagan = { - scope:actor.faith.religion = { NOT = { is_in_family = rf_pagan } } - } - rf_sinitic = { - scope:actor.faith.religion = { NOT = { is_in_family = rf_sinitic } } - } - rf_eastern = { - scope:actor.faith.religion = { NOT = { is_in_family = rf_eastern } } - } - rf_abrahamic = { - scope:actor.faith.religion = { NOT = { is_in_family = rf_abrahamic } } - } + scope:actor = { + NOR = { + government_has_flag = government_is_wanua + faith = { faith_is_in_same_rf = { FAITH = scope:recipient.faith } } } } add = -25 @@ -582,7 +631,7 @@ become_tributary_interaction = { limit = { scope:recipient = { OR = { - government_allows = administrative + government_has_mechanic = administrative government_is_japanese_trigger = yes government_has_flag = government_is_nomadic } @@ -604,9 +653,19 @@ become_tributary_interaction = { } } #Far away - modifier = { + modifier = { desc = offer_vassalization_interaction_aibehavior_remoterealm_tt trigger = { + # Distance leads: every recipient list here is a neighbour list, so most candidates fail it before the border scan below runs + trigger_if = { #Islands we can get farther away + limit = { + scope:actor.capital_county = { is_coastal_county = yes } + } + scope:actor.capital_province = { squared_distance = { target = scope:recipient.capital_province value >= squared_distance_huge } } + } + trigger_else = { #Inland is harder + scope:actor.capital_province = { squared_distance = { target = scope:recipient.capital_province value >= squared_distance_major } } + } scope:recipient = { NOT = { any_land_neighboring_realm_with_tributaries_owner = { @@ -614,16 +673,6 @@ become_tributary_interaction = { } } } - trigger_if = { #Islands we can get farther away - limit = { - scope:actor.capital_county = { is_coastal_county = yes } - any_sub_realm_county = { is_coastal_county = yes } - } - scope:actor.capital_province = { squared_distance = { target = scope:recipient.capital_province value >= squared_distance_huge } } - } - trigger_else = { #Inland is harder - scope:actor.capital_province = { squared_distance = { target = scope:recipient.capital_province value >= squared_distance_major } } - } } add = -250 } @@ -784,7 +833,7 @@ become_tributary_interaction = { # OPINION INFLUENCE opinion_modifier = { # Compare Opinion modifier. trigger = { - NOT = { + NOT = { scope:recipient = { government_has_flag = government_is_mandala } } } @@ -818,31 +867,43 @@ demand_tributary_interaction = { desc = demand_tributary_interaction_desc + is_available = { + trigger_if = { + limit = { is_ai = yes } + highest_held_title_tier > 1 # at least a count-level ruler + is_independent_ruler = yes + + # Hegemonic Tributary AIs never proactively demand tributaries, they wait for offers instead + NOT = { highest_held_title_tier >= tier_hegemony } + } + } + is_shown = { - scope:actor = { - NOT = { - this = scope:recipient - top_suzerain = scope:recipient.top_suzerain # ensures the actor and recipient is not already in the same "suzerain bloc" - } + scope:puppet_or_actor ?= { can_get_tributaries_peacefully_trigger = yes - - highest_held_title_tier < tier_hegemony # hegemonies get tributaries from exacting tribute - + is_landed = yes # Landless have no realm to render tribute from #Mandala Embraces; not Demand trigger_if = { - limit = { - scope:actor = { government_has_flag = government_is_mandala } + limit = { + scope:puppet_or_actor ?= { government_has_flag = government_is_mandala } } always = no } trigger_else = { can_get_tributaries_peacefully_trigger = yes } + + highest_held_title_tier < tier_hegemony # hegemonies get tributaries from exacting tribute + + NOT = { + this = scope:recipient + top_suzerain ?= scope:recipient.top_suzerain # ensures the actor and recipient is not already in the same "suzerain bloc" + } #Should be neighboring to increase growth organically any_land_neighboring_realm_with_tributaries_owner = { this = scope:recipient } trigger_if = { limit = { - is_ai = yes + scope:actor = { is_ai = yes } } current_military_strength >= scope:recipient.one_and_a_half_times_current_military_strength primary_title.tier >= scope:recipient.primary_title.tier @@ -850,15 +911,17 @@ demand_tributary_interaction = { } scope:recipient = { highest_held_title_tier >= tier_county + is_landed = yes # A tributary must hold land is_independent_ruler = yes # target cannot be a vassal NOR = { government_has_flag = cannot_be_vassal_or_liege government_has_flag = government_is_mandala + government_has_flag = government_is_holy_order # Monastic and military holy orders cannot become tributaries } } # Temujin cannot make Jamukha his subject once he leaves him NOT = { - scope:actor = { + scope:puppet_or_actor ?= { has_variable = had_mpo_temujin_flavor_0010 var:had_mpo_temujin_flavor_0010 ?= scope:recipient } @@ -866,11 +929,9 @@ demand_tributary_interaction = { } is_valid_showing_failures_only = { - scope:actor = { - NOT = { has_truce = scope:actor } - is_physically_able = yes - is_travelling = no - NOT = { exists = involved_activity } + scope:puppet_or_actor = { + NOT = { has_truce = scope:recipient } + is_available_allow_travelling = yes } scope:recipient = { is_tributary = no @@ -880,45 +941,63 @@ demand_tributary_interaction = { NOT = { has_opinion_modifier = { modifier = tributary_demanded_opinion - target = scope:actor + target = scope:puppet_or_actor } } } is_confederation_member = no } - scope:actor = { + scope:puppet_or_actor = { custom_tooltip = { text = mpo_interaction_not_neighbouring_tt - any_land_neighboring_realm_with_tributaries_owner = { + any_land_neighboring_realm_with_tributaries_owner = { this = scope:recipient } } } + trigger_if = { + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + prestige >= minor_prestige_value + } + } } cost = { - prestige = minor_prestige_value + prestige = { + value = minor_prestige_value + if = { + limit = { scope:is_puppet_action ?= yes } + multiply = 0 + } + } } greeting = positive notification_text = DEMAND_TRIBUTARY_INTERACTION_NOTIFICATION on_accept = { + if = { + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + add_prestige = { value = { add = minor_prestige_value max = prestige multiply = -1 } } + } + } start_tributary_interaction_effect = { TRIBUTARY = scope:recipient - SUZERAIN = scope:actor + SUZERAIN = scope:puppet_or_actor } - scope:actor = { + scope:puppet_or_actor = { trigger_event = char_interaction.0362 } scope:recipient = { add_opinion = { modifier = tributary_demanded_opinion # this opinion also acts as a built-in cooldown - target = scope:actor + target = scope:puppet_or_actor } } consume_all_criminal_reasons_effect = { - LIEGE = scope:actor + LIEGE = scope:puppet_or_actor CRIMINAL = scope:recipient } } @@ -927,11 +1006,11 @@ demand_tributary_interaction = { scope:recipient = { add_opinion = { modifier = tributary_demanded_opinion # this opinion also acts as a built-in cooldown - target = scope:actor + target = scope:puppet_or_actor } custom_tooltip = demand_tributary_interaction_cooldown_tt } - scope:actor = { + scope:puppet_or_actor = { trigger_event = char_interaction.0363 if = { limit = { highest_held_title_tier >= tier_hegemony } @@ -942,19 +1021,11 @@ demand_tributary_interaction = { ai_maybe = yes - ai_potential = { - highest_held_title_tier > 1 # at least a count-level ruler - is_independent_ruler = yes - - # Hegemonic Tributary AIs never proactively demand tributaries, they wait for offers instead - NOT = { highest_held_title_tier >= tier_hegemony } - } - ai_targets = { ai_recipients = neighboring_rulers_including_tributary_borders max = 5 } - + ai_frequency_by_tier = { barony = 0 county = 12 @@ -979,46 +1050,46 @@ demand_tributary_interaction = { } ai_military_threat_modifier_with_cbs = { - SENDER = scope:actor + SENDER = scope:puppet_or_actor RECEIVER = scope:recipient MULTIPLIER = -1 } modifier = { - scope:recipient = { is_obedient_to = scope:actor } + scope:recipient = { is_obedient_to = scope:puppet_or_actor } add = 40 desc = obedient_interaction_reason } modifier = { # Generally don't try to tributarize those of higher rank than you trigger = { - "scope:recipient.tier_difference(scope:actor)" > 1 + "scope:recipient.tier_difference(scope:puppet_or_actor)" > 1 } add = -20 } modifier = { # Generally don't try to tributarize those of higher dominance than you trigger = { - scope:recipient.dominance_value > scope:actor.dominance_value + scope:recipient.dominance_value > scope:puppet_or_actor.dominance_value } add = -30 } modifier = { # Remote Realm. trigger = { - scope:actor = { + scope:puppet_or_actor = { NOT = { any_neighboring_top_liege_realm_owner = { this = scope:recipient } } } - scope:actor.capital_province = { squared_distance = { target = scope:recipient.capital_province value >= squared_distance_major } } + scope:puppet_or_actor.capital_province = { squared_distance = { target = scope:recipient.capital_province value >= squared_distance_major } } } add = -25 } modifier = { trigger = { - scope:recipient = { government_has_flag = government_is_true_herder } + scope:recipient = { government_has_flag = government_is_herder } } add = 1000 } @@ -1030,7 +1101,7 @@ demand_tributary_interaction = { auto_accept = { custom_tooltip = { text = scheme_agent_aptitude.is_herder - scope:recipient = { government_has_flag = government_is_true_herder } + scope:recipient = { government_has_flag = government_is_herder } } } @@ -1039,14 +1110,14 @@ demand_tributary_interaction = { modifier = { # Hegemonic Tributaries are gentler and kinder trigger = { - scope:actor = { highest_held_title_tier >= tier_hegemony } + scope:puppet_or_actor ?= { highest_held_title_tier >= tier_hegemony } } add = 100 desc = tributary_interaction_aibehavior_actor_hegemon_tier_tt } modifier = { # Special case for Confucian-style governments towards China - scope:actor = { + scope:puppet_or_actor ?= { primary_title = title:h_china } government_has_flag = government_is_meritocratic @@ -1057,7 +1128,7 @@ demand_tributary_interaction = { modifier = { # Perk boost desc = offer_vassalization_true_ruler_perk_tt trigger = { - scope:actor = { has_perk = true_ruler_perk } + scope:puppet_or_actor ?= { has_perk = true_ruler_perk } } add = true_ruler_value } @@ -1066,7 +1137,7 @@ demand_tributary_interaction = { modifier = { desc = tributary_yurt_02_domicile_building trigger = { - scope:actor.domicile ?= { has_domicile_parameter = nomad_yurt_increased_tributary_acceptance_lvl_1 } + scope:puppet_or_actor.domicile ?= { has_domicile_parameter = nomad_yurt_increased_tributary_acceptance_lvl_1 } } add = 5 } @@ -1074,7 +1145,7 @@ demand_tributary_interaction = { modifier = { desc = tributary_yurt_02_domicile_building trigger = { - scope:actor.domicile ?= { has_domicile_parameter = nomad_yurt_increased_tributary_acceptance_lvl_2 } + scope:puppet_or_actor.domicile ?= { has_domicile_parameter = nomad_yurt_increased_tributary_acceptance_lvl_2 } } add = 10 } @@ -1082,7 +1153,7 @@ demand_tributary_interaction = { modifier = { desc = tributary_yurt_02_domicile_building trigger = { - scope:actor.domicile ?= { has_domicile_parameter = nomad_yurt_increased_tributary_acceptance_lvl_3 } + scope:puppet_or_actor.domicile ?= { has_domicile_parameter = nomad_yurt_increased_tributary_acceptance_lvl_3 } } add = 15 } @@ -1108,13 +1179,14 @@ demand_tributary_interaction = { } modifier = { - is_obedient_to = scope:actor + exists = scope:puppet_or_actor + is_obedient_to = scope:puppet_or_actor add = 40 desc = obedient_interaction_reason } modifier = { - scope:actor = { is_gurkhan = yes } + scope:puppet_or_actor ?= { is_gurkhan = yes } scope:recipient = { government_has_flag = government_is_nomadic } add = 20 desc = gurkhan_interaction_reason @@ -1122,12 +1194,13 @@ demand_tributary_interaction = { # Easier to make Tributaries during the Zud season modifier = { + exists = scope:puppet_or_actor any_character_situation = { any_situation_sub_region = { has_sub_region_phase_parameter = the_great_steppe_easier_tributaries any_situation_sub_region_participant_group = { participant_group_type = nomad_rulers_capital - participant_group_has_character = scope:actor + participant_group_has_character = scope:puppet_or_actor } } } @@ -1139,7 +1212,7 @@ demand_tributary_interaction = { # if the actor is a major threat to the recipient they're more likely to accept ai_military_threat_modifier_with_cbs = { SENDER = scope:recipient - RECEIVER = scope:actor + RECEIVER = scope:puppet_or_actor MULTIPLIER = 1 } @@ -1162,9 +1235,9 @@ demand_tributary_interaction = { modifier = { # Recipient has higher Dominance than the actor desc = demand_tributary_interaction_aibehavior_dominance_tt trigger = { - scope:actor = { government_has_flag = government_is_nomadic } + scope:puppet_or_actor ?= { government_has_flag = government_is_nomadic } scope:recipient = { government_has_flag = government_is_nomadic } - scope:recipient.dominance_value > scope:actor.dominance_value + scope:recipient.dominance_value > scope:puppet_or_actor.dominance_value } add = -20 } @@ -1172,9 +1245,9 @@ demand_tributary_interaction = { modifier = { # Actor has higher Dominance than the recipient desc = demand_tributary_interaction_aibehavior_dominance_tt trigger = { - scope:actor = { government_has_flag = government_is_nomadic } + scope:puppet_or_actor ?= { government_has_flag = government_is_nomadic } scope:recipient = { government_has_flag = government_is_nomadic } - scope:actor.dominance_value > scope:recipient.dominance_value + scope:puppet_or_actor.dominance_value > scope:recipient.dominance_value } add = 20 } @@ -1182,7 +1255,7 @@ demand_tributary_interaction = { modifier = { # Actor is a Meritocratic Khanate trying to tributarize a Nomad desc = demand_tributary_interaction_steppe_admin trigger = { - scope:actor = { government_has_flag = government_is_steppe_admin } + scope:puppet_or_actor ?= { government_has_flag = government_is_steppe_admin } scope:recipient = { government_has_flag = government_is_nomadic } } add = 60 # This offsets base reluctance @@ -1192,7 +1265,7 @@ demand_tributary_interaction = { modifier = { desc = AI_FILTHY_HORSE_LORD_REASON trigger = { - scope:actor = { government_has_flag = government_is_nomadic } + scope:puppet_or_actor ?= { government_has_flag = government_is_nomadic } scope:recipient = { NOT = { government_has_flag = government_is_nomadic } } @@ -1212,9 +1285,10 @@ demand_tributary_interaction = { modifier = { # Rivalry modifier. desc = offer_vassalization_interaction_aibehavior_rival_tt trigger = { + exists = scope:puppet_or_actor scope:recipient = { - has_relation_rival = scope:actor - NOT = { has_relation_nemesis = scope:actor } + has_relation_rival = scope:puppet_or_actor + NOT = { has_relation_nemesis = scope:puppet_or_actor } } } add = -100 @@ -1222,8 +1296,9 @@ demand_tributary_interaction = { modifier = { # Nemesis modifier. desc = offer_vassalization_interaction_aibehavior_nemesis_tt trigger = { + exists = scope:puppet_or_actor scope:recipient = { - has_relation_nemesis = scope:actor + has_relation_nemesis = scope:puppet_or_actor } } add = -200 @@ -1231,8 +1306,9 @@ demand_tributary_interaction = { modifier = { # Same Dynasty modifier. desc = offer_vassalization_interaction_aibehavior_dynasty_tt trigger = { + exists = scope:puppet_or_actor scope:recipient = { - dynasty = scope:actor.dynasty + dynasty = scope:puppet_or_actor.dynasty } } add = 10 @@ -1240,16 +1316,14 @@ demand_tributary_interaction = { modifier = { # Different faith, no pluralism. desc = offer_vassalization_interaction_aibehavior_differentfaith_tt trigger = { - scope:actor = { + scope:puppet_or_actor ?= { NOT = { # faith condition below doesn't have to apply if both actor and recipient have nomadic_philosophy has_trait = nomadic_philosophy scope:recipient = { has_trait = nomadic_philosophy } } - faith = { - NOR = { # Of two different faiths AND the potential vassal's faith is not pluralistic - this = scope:recipient.faith - has_doctrine = doctrine_pluralism_pluralistic - } + NOR = { # Of two different faiths AND the potential vassal's rite is not pluralistic + faith = scope:recipient.faith + rite = { rite_has_doctrine = doctrine_pluralism_pluralistic } } } } @@ -1257,7 +1331,7 @@ demand_tributary_interaction = { value = -25 if = { limit = { - scope:actor.faith = { + scope:puppet_or_actor.faith ?= { faith_hostility_level = { target = scope:recipient.faith value >= faith_hostile_level @@ -1268,7 +1342,7 @@ demand_tributary_interaction = { } if = { limit = { - scope:actor.faith = { + scope:puppet_or_actor.faith ?= { faith_hostility_level = { target = scope:recipient.faith value >= faith_evil_level @@ -1283,10 +1357,11 @@ demand_tributary_interaction = { modifier = { # Encircled desc = offer_vassalization_interaction_aibehavior_encircled_tt trigger = { + exists = scope:puppet_or_actor scope:recipient = { NOT = { any_neighboring_top_suzerain_realm_owner = { - this != scope:actor + this != scope:puppet_or_actor } } NOT = { @@ -1298,7 +1373,7 @@ demand_tributary_interaction = { } modifier = { # Cultural Acceptance - scope:actor = { + scope:puppet_or_actor ?= { NOT = { # cultural condition below doesn't have to apply if both actor and recipient have nomadic_philosophy has_trait = nomadic_philosophy scope:recipient = { has_trait = nomadic_philosophy } @@ -1311,7 +1386,7 @@ demand_tributary_interaction = { add = { add = -10 if = { - limit = { scope:actor.culture = { has_cultural_pillar = ethos_bellicose } } + limit = { scope:puppet_or_actor.culture ?= { has_cultural_pillar = ethos_bellicose } } add = -10 } } @@ -1322,7 +1397,7 @@ demand_tributary_interaction = { add = 5 desc = speaks_same_language_interaction_reason trigger = { - scope:actor = { + scope:puppet_or_actor ?= { knows_language_of_culture = scope:recipient.culture } } @@ -1332,28 +1407,28 @@ demand_tributary_interaction = { modifier = { desc = "LOW_LEGITIMACY_REASON" add = -15 - scope:actor = { + scope:puppet_or_actor ?= { has_legitimacy_flag = slightly_reduced_tributarization_acceptance } } modifier = { desc = "LOW_LEGITIMACY_REASON" add = -25 - scope:actor = { + scope:puppet_or_actor ?= { has_legitimacy_flag = reduced_tributarization_acceptance } } modifier = { desc = "LOW_LEGITIMACY_REASON" add = -50 - scope:actor = { + scope:puppet_or_actor ?= { has_legitimacy_flag = very_reduced_tributarization_acceptance } } modifier = { desc = "LOW_LEGITIMACY_REASON" add = -75 - scope:actor = { + scope:puppet_or_actor ?= { has_legitimacy_flag = massively_reduced_tributarization_acceptance } } @@ -1362,36 +1437,37 @@ demand_tributary_interaction = { modifier = { desc = "HIGH_LEGITIMACY_REASON" add = 25 - scope:actor = { + scope:puppet_or_actor ?= { has_legitimacy_flag = increased_tributarization_acceptance } } modifier = { desc = "HIGH_LEGITIMACY_REASON" add = 50 - scope:actor = { + scope:puppet_or_actor ?= { has_legitimacy_flag = very_increased_tributarization_acceptance } } modifier = { desc = "HIGH_LEGITIMACY_REASON" add = 75 - scope:actor = { + scope:puppet_or_actor ?= { has_legitimacy_flag = extra_increased_tributarization_acceptance } } # OPINION INFLUENCE opinion_modifier = { # Compare Opinion modifier. + trigger = { exists = scope:puppet_or_actor } who = scope:recipient - opinion_target = scope:actor + opinion_target = scope:puppet_or_actor multiplier = 1 } #Severed head acceptance modifier = { add = 200 - scope:actor = { + scope:puppet_or_actor ?= { has_variable = severed_head_vassalization var:severed_head_vassalization = { this = scope:recipient @@ -1416,19 +1492,71 @@ cease_paying_tribute_interaction = { desc = cease_paying_tribute_interaction_desc + is_available = { + trigger_if = { + limit = { is_ai = yes } + suzerain ?= { + is_migrating = no + + OR = { + AND = { + NOT = { root = { government_has_flag = government_is_herder } } + trigger_if = { # Obedience is a hard blocker, but only if suzerain is landed + limit = { + is_landed = yes + } + root = { is_obedient = no } + } + } + NOT = { # disconnected tributaries can always do this, even herders + any_land_neighboring_realm_with_tributaries_owner = { + this = root + } + } + is_landed = no + } + trigger_if = { + limit = { + any_character_situation = { + situation_type = dynastic_cycle + } + } + OR = { + root.subject_standing <= 0 + any_character_situation = { + situation_type = dynastic_cycle + OR = { + situation_current_phase = situation_dynastic_cycle_phase_instability + situation_current_phase = situation_dynastic_cycle_phase_instability_conquest + } + } + } + } + } + is_at_war = no + trigger_if = { + limit = { + suzerain = { + highest_held_title_tier >= tier_hegemony + } + } + subject_standing < 20 + } + is_migrating = no + } + } + is_shown = { - scope:actor = { + scope:puppet_or_actor ?= { this != scope:recipient - suzerain = scope:recipient + suzerain ?= scope:recipient is_tributary = yes } } is_valid_showing_failures_only = { - scope:actor = { - is_physically_able = yes - is_travelling = no - NOT = { exists = involved_activity } + scope:puppet_or_actor = { + is_available_allow_travelling = yes trigger_if = { limit = { OR = { @@ -1447,35 +1575,45 @@ cease_paying_tribute_interaction = { subject_can_break_tributary = yes } } + trigger_if = { + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + prestige >= cease_paying_tribute_interaction_cost_value + } + } } cost = { prestige = { - value = 0 + value = cease_paying_tribute_interaction_cost_value if = { - limit = { - scope:actor = { - OR = { - any_land_neighboring_realm_with_tributaries_owner = { - this = scope:recipient - } - scope:recipient = { - is_landed = no - } - } - } - } - add = minor_prestige_value + limit = { scope:is_puppet_action ?= yes } + multiply = 0 } } } auto_accept = yes on_accept = { - scope:actor = { + if = { + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + if = { + limit = { cease_paying_tribute_interaction_cost_value > 0 } + add_prestige = { + value = { + add = cease_paying_tribute_interaction_cost_value + max = prestige + multiply = -1 + } + } + } + } + } + scope:puppet_or_actor = { end_tributary = yes if = { - limit = { + limit = { scope:recipient = { government_has_flag = government_is_mandala } } add_opinion = { @@ -1484,7 +1622,7 @@ cease_paying_tribute_interaction = { opinion = -100 } } - + } scope:recipient = { # Losing legitimacy if you are the Chinese Hegemon in the Dynastic Cycle Instability phase @@ -1513,7 +1651,7 @@ cease_paying_tribute_interaction = { months = 6 } } - + } if = { @@ -1529,58 +1667,7 @@ cease_paying_tribute_interaction = { add_opinion = { modifier = tributary_ceased_payments_opinion - target = scope:actor - } - } - } - - ai_potential = { - is_at_war = no - is_migrating = no - trigger_if = { - limit = { - suzerain = { - highest_held_title_tier >= tier_hegemony - } - } - subject_standing < 20 - } - suzerain = { - is_migrating = no - - OR = { - is_landed = no - NOT = { # disconnected tributaries can always do this, even herders - any_land_neighboring_realm_with_tributaries_owner = { - this = root - } - } - AND = { - NOT = { root = { government_has_flag = government_is_true_herder } } - trigger_if = { # Obedience is a hard blocker, but only if suzerain is landed - limit = { - is_landed = yes - } - root = { is_obedient = no } - } - } - } - trigger_if = { - limit = { - any_character_situation = { - situation_type = dynastic_cycle - } - } - OR = { - root.subject_standing <= 0 - any_character_situation = { - situation_type = dynastic_cycle - OR = { - situation_current_phase = situation_dynastic_cycle_phase_instability - situation_current_phase = situation_dynastic_cycle_phase_instability_conquest - } - } - } + target = scope:puppet_or_actor } } } @@ -1613,7 +1700,7 @@ cease_paying_tribute_interaction = { # if the actor is sufficiently scared of the recipient they're way less likely to do this ai_military_threat_modifier = { - SENDER = scope:actor + SENDER = scope:puppet_or_actor RECEIVER = scope:recipient MULTIPLIER = -2 } @@ -1633,7 +1720,7 @@ cease_paying_tribute_interaction = { } desc = obedience_value_reason } - + modifier = { scope:recipient = { has_variable = temp_tributary_protection @@ -1641,16 +1728,16 @@ cease_paying_tribute_interaction = { add = -150 desc = temp_tributary_protection_reason } - + modifier = { dominance_value > suzerain.dominance_value add = 30 desc = cease_tribute_higher_dominance_reason } - + modifier = { - suzerain = { - any_memory = { + suzerain = { + any_memory = { has_memory_type = nomad_showed_weakness_in_war memory_age_years < 5 } @@ -1658,9 +1745,9 @@ cease_paying_tribute_interaction = { add = 30 desc = cease_tribute_showed_weakness_in_war_reason } - + modifier = { - any_memory = { + any_memory = { has_memory_type = suzerain_defended_me_in_war has_memory_participant = root.suzerain memory_age_years < 10 @@ -1668,10 +1755,10 @@ cease_paying_tribute_interaction = { add = -100 desc = cease_tribute_defended_me_in_war_reason } - + modifier = { - suzerain = { - any_memory = { + suzerain = { + any_memory = { has_memory_type = had_chaotic_kurultai_succession memory_age_years < 5 } @@ -1681,11 +1768,11 @@ cease_paying_tribute_interaction = { } #General Modifiers #Is the Tributary Connected? - modifier = { + modifier = { scope:recipient = { trigger_if = { #Mandalas, China, Wanua, and Meritocratic realms can keep overseas tributaries, if they are coastal. limit = { - scope:actor = { + scope:puppet_or_actor = { OR = { government_has_flag = government_is_mandala government_has_flag = government_is_celestial @@ -1704,7 +1791,7 @@ cease_paying_tribute_interaction = { } NOT = { any_land_neighboring_realm_with_tributaries_owner = { - this = scope:actor + this = scope:puppet_or_actor } } } @@ -1712,7 +1799,7 @@ cease_paying_tribute_interaction = { desc = cease_tribute_disconnected_suzerain } #Is the suzerain landless? - modifier = { + modifier = { scope:recipient = { is_landed = no is_migrating = no @@ -1796,7 +1883,7 @@ cease_paying_tribute_interaction = { #I am a Tribal! modifier = { scope:recipient = { government_has_flag = government_is_mandala } - scope:actor = { government_has_flag = government_is_tribal } + scope:puppet_or_actor = { government_has_flag = government_is_tribal } add = -20 desc = actor_is_a_tribal_government } @@ -1827,16 +1914,16 @@ cease_paying_tribute_interaction = { #Tributary Realm Size subject_realm_size_add_weight_modifier = { DEVARAJA = scope:recipient - SUBJECT = scope:actor + SUBJECT = scope:puppet_or_actor } ##Radience of other potential Suzerains is not calculated here since they can directly ask the tributary to switch over to them. #Pacing for Mandala Suzerains modifier = { - scope:recipient = { + scope:recipient = { government_has_flag = government_is_mandala - has_variable = tributary_recently_ceased + has_variable = tributary_recently_ceased } factor = 0.1 } @@ -1864,18 +1951,18 @@ cease_paying_tribute_interaction = { # I am higher rank than you modifier = { desc = tributary_interaction_aibehavior_actor_tier_tt - scope:actor = { highest_held_title_tier > scope:recipient.highest_held_title_tier } + scope:puppet_or_actor = { highest_held_title_tier > scope:recipient.highest_held_title_tier } add = { - value = scope:actor.highest_held_title_tier - subtract = scope:recipient.highest_held_title_tier + value = scope:puppet_or_actor.highest_held_title_tier + subtract = scope:recipient.highest_held_title_tier multiply = 50 } } # I have a Capital Temple Complex of my own (I am also a God King) - modifier = { + modifier = { desc = tributary_interaction_aibehavior_actor_capital_complex scope:recipient = { government_has_flag = government_is_mandala } - scope:actor = { + scope:puppet_or_actor = { government_has_flag = government_is_mandala capital_province = { has_building_with_flag = mandala_capital_building @@ -1891,11 +1978,11 @@ cease_paying_tribute_interaction = { desc = mandala_ai_godking_modifier } # Same Faith and Recipient is a God King - modifier = { + modifier = { desc = tributary_interaction_aibehavior_recipient_same_faith scope:recipient = { government_has_flag = government_is_mandala - faith = scope:actor.faith + faith = scope:puppet_or_actor.faith capital_province = { has_building_with_flag = mandala_capital_building has_ruined_great_building = no @@ -1904,52 +1991,38 @@ cease_paying_tribute_interaction = { add = -10 } # Different religion Family - We prefer god kings to be vaguely within our own world view - modifier = { + modifier = { desc = tributary_interaction_aibehavior_recipient_other_religion_family - scope:actor = { - NOT = { government_has_flag = government_is_wanua } - } - scope:recipient.faith.religion = { - switch = { - trigger = is_in_family - rf_pagan = { - scope:actor.faith.religion = { NOT = { is_in_family = rf_pagan } } - } - rf_sinitic = { - scope:actor.faith.religion = { NOT = { is_in_family = rf_sinitic } } - } - rf_eastern = { - scope:actor.faith.religion = { NOT = { is_in_family = rf_eastern } } - } - rf_abrahamic = { - scope:actor.faith.religion = { NOT = { is_in_family = rf_abrahamic } } - } + scope:puppet_or_actor = { + NOR = { + government_has_flag = government_is_wanua + faith = { faith_is_in_same_rf = { FAITH = scope:recipient.faith } } } } add = 25 } - ### + ### # Rivalry modifier. modifier = { desc = embrace_tributarization_interaction_aibehavior_rival_tt scope:recipient = { - has_relation_rival = scope:actor - NOT = { has_relation_nemesis = scope:actor } + has_relation_rival = scope:puppet_or_actor + NOT = { has_relation_nemesis = scope:puppet_or_actor } } add = 30 } # Nemesis modifier. - modifier = { + modifier = { desc = embrace_tributarization_interaction_aibehavior_nemesis_tt - scope:recipient = { has_relation_nemesis = scope:actor } + scope:recipient = { has_relation_nemesis = scope:puppet_or_actor } add = 50 } # OPINION INFLUENCE opinion_modifier = { # Compare Opinion modifier. - who = scope:actor + who = scope:puppet_or_actor opinion_target = scope:recipient multiplier = -1 - } + } } } @@ -1966,11 +2039,11 @@ release_tributary_interaction = { is_shown = { scope:recipient = { - this != scope:actor - suzerain = scope:actor + this != scope:puppet_or_actor + suzerain ?= scope:puppet_or_actor OR = { # AI should only ever consider releasing unruly subjects scope:actor = { is_ai = no } - NOT = { is_obedient_to = scope:actor } + NOT = { is_obedient_to = scope:puppet_or_actor } } } } @@ -1982,26 +2055,32 @@ release_tributary_interaction = { # subject_standing = 0 # } #} + trigger_if = { + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + prestige >= release_tributary_interaction_prestige_cost_value + } + } + trigger_if = { + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + piety >= release_tributary_interaction_piety_cost_value + } + } } cost = { prestige = { - value = minor_prestige_value + value = release_tributary_interaction_prestige_cost_value if = { - limit = { - scope:actor = { government_has_flag = government_is_mandala } - } + limit = { scope:is_puppet_action ?= yes } multiply = 0 } } piety = { - value = medium_piety_value + value = release_tributary_interaction_piety_cost_value if = { - limit = { - scope:actor = { - NOT = { government_has_flag = government_is_mandala } - } - } + limit = { scope:is_puppet_action ?= yes } multiply = 0 } } @@ -2009,31 +2088,56 @@ release_tributary_interaction = { auto_accept = yes on_accept = { + if = { + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + if = { + limit = { release_tributary_interaction_prestige_cost_value > 0 } + add_prestige = { + value = { + add = release_tributary_interaction_prestige_cost_value + max = prestige + multiply = -1 + } + } + } + if = { + limit = { release_tributary_interaction_piety_cost_value > 0 } + add_piety = { + value = { + add = release_tributary_interaction_piety_cost_value + max = piety + multiply = -1 + } + } + } + } + } scope:recipient = { end_tributary = yes save_scope_as = tributary_loc - scope:actor = { save_scope_as = suzerain_loc } + scope:puppet_or_actor = { save_scope_as = suzerain_loc } add_truce_both_ways = { - character = scope:actor + character = scope:puppet_or_actor years = 5 override = yes name = TRUCE_TRIBUTARY_STOPPED } add_opinion = { - target = scope:actor - modifier = tributary_released_opinion - opinion = 25 - } - if = { - limit = { - scope:actor = { government_has_flag = government_is_mandala } - } - set_variable = { - name = recent_mandala_suzerain - value = scope:actor - years = 5 - } - } + target = scope:puppet_or_actor + modifier = tributary_released_opinion + opinion = 25 + } + if = { + limit = { + scope:puppet_or_actor = { government_has_flag = government_is_mandala } + } + set_variable = { + name = recent_mandala_suzerain + value = scope:puppet_or_actor + years = 5 + } + } trigger_event = char_interaction.0380 } } @@ -2051,14 +2155,20 @@ release_as_tributary_interaction = { desc = release_as_tributary_interaction_desc - is_shown = { - scope:actor = { - OR = { - government_has_flag = government_is_nomadic - government_has_flag = government_is_mandala - government_has_flag = government_is_wanua - } + is_available = { + trigger_if = { + limit = { is_ai = yes } + vassal_count > vassal_limit + this = top_liege } + OR = { + government_has_flag = government_is_nomadic + government_has_flag = government_is_wanua + government_has_flag = government_is_mandala + } + } + + is_shown = { scope:recipient = { is_vassal_of = scope:actor highest_held_title_tier >= tier_county @@ -2110,16 +2220,6 @@ release_as_tributary_interaction = { } } - ai_potential = { - OR = { - government_has_flag = government_is_nomadic - government_has_flag = government_is_mandala - government_has_flag = government_is_wanua - } - this = top_liege - vassal_count > vassal_limit - } - ai_targets = { ai_recipients = vassals } @@ -2207,6 +2307,39 @@ exact_tribute_interaction = { text = exact_tribute_interaction_recently_tribute_missioned_tt NOT = { var:tribute_mission_grace ?= scope:actor } } + trigger_if = { + limit = { scope:actor = { government_has_flag = government_is_mandala } } + can_execute_decision = tribute_mission_decision_mandala + } + trigger_else_if = { + limit = { scope:actor.primary_title = title:h_china } + can_execute_decision = tribute_mission_decision_china + } + trigger_else_if = { + limit = { scope:actor.primary_title = title:h_roman_empire } + can_execute_decision = tribute_mission_decision_roman_empire + } + trigger_else_if = { + limit = { scope:actor.primary_title = title:h_eastern_roman_empire } + can_execute_decision = tribute_mission_decision_eastern_roman_empire + } + trigger_else_if = { + limit = { scope:actor.primary_title = title:h_dar_al_islam } + can_execute_decision = tribute_mission_decision_dar_al_islam + } + trigger_else_if = { + limit = { scope:actor.primary_title = title:h_india } + can_execute_decision = tribute_mission_decision_india + } + trigger_else_if = { + limit = { scope:actor.primary_title = title:h_numenor } + can_execute_decision = tribute_mission_decision_numenor + } + trigger_else_if = { + limit = { scope:actor.primary_title = title:h_europa } + can_execute_decision = tribute_mission_decision_europa + } + trigger_else = { always = no } trigger_if = { limit = { @@ -2246,24 +2379,9 @@ exact_tribute_interaction = { custom_tooltip = { text = exact_tribute_interaction_no_tribute_tt OR = { - has_gold_tribute_trigger = yes - has_herd_tribute_trigger = yes - has_artifact_tribute_trigger = yes - AND = { - any_courtier_or_guest = { - can_become_concubine_of_character_valid_trigger = { CHARACTER = scope:actor } - } - scope:actor = { - allowed_more_concubines = yes - is_adult = yes - } - } - AND = { - has_eunuch_tribute_trigger = yes - scope:actor = { - culture = { has_cultural_parameter = can_appoint_chief_eunuch } - } - } + tribute_mission_decision_generic_trigger = yes + tribute_mission_decision_concubine_trigger = { OVERLORD = scope:actor } + tribute_mission_decision_eunuch_trigger = { OVERLORD = scope:actor } } } } @@ -2275,7 +2393,7 @@ exact_tribute_interaction = { #Is already engaged custom_tooltip = { text = exact_tribute_interaction_already_engaged_tt - NOR = { + NOR = { var:requested_tribute_mission ?= scope:actor has_variable = tribute_mission_type } @@ -2308,16 +2426,16 @@ exact_tribute_interaction = { send_option = { flag = artifact is_valid = { - scope:recipient = { + scope:recipient = { custom_tooltip = { text = exact_tribute_interaction_no_suitable_artifact_tt - has_artifact_tribute_trigger = yes + has_artifact_tribute_trigger = yes } } } localization = request_artifact_tribute } - + #Request Concubine send_option = { flag = concubine @@ -2326,7 +2444,7 @@ exact_tribute_interaction = { is_adult = yes can_have_concubines_trigger = { CHAR = scope:actor } } - scope:recipient = { + scope:recipient = { custom_tooltip = { text = exact_tribute_interaction_no_suitable_concubine_tt any_courtier_or_guest = { @@ -2343,22 +2461,22 @@ exact_tribute_interaction = { flag = eunuch is_valid = { trigger_if = { - limit = { - scope:actor = { + limit = { + scope:actor = { can_employ_court_eunuchs_trigger = { CHAR = scope:actor } } } - scope:recipient = { + scope:recipient = { custom_tooltip = { text = exact_tribute_interaction_no_suitable_eunuchs_tt - has_eunuch_tribute_trigger = yes + has_eunuch_tribute_trigger = yes } } } trigger_else = { scope:actor = { can_employ_court_eunuchs_trigger = { CHAR = scope:actor } - } + } } } localization = request_eunuch_tribute @@ -2389,7 +2507,7 @@ exact_tribute_interaction = { set_variable = { name = requested_tribute_mission_type_gold years = requested_tribute_mission_deadline_years - } + } custom_tooltip = exact_tribute_interaction_gold_tt } scope:herd ?= { @@ -2405,7 +2523,7 @@ exact_tribute_interaction = { years = requested_tribute_mission_deadline_years } custom_tooltip = exact_tribute_interaction_artifact_tt - random_character_artifact = { + random_character_artifact = { limit = { is_suitable_artifact_tribute_trigger = yes } scope:recipient = { set_variable = { @@ -2485,10 +2603,10 @@ exact_tribute_interaction = { } custom_tooltip = exact_tribute_interaction_eunuch_tt every_courtier = { - limit = { + limit = { tribute_mission_is_available_eunuch_trigger = yes NAND = { - faith = { has_doctrine = doctrine_theocracy_temporal } + rite = { rite_has_doctrine = doctrine_theocracy_temporal } this = scope:actor.cp:councillor_court_chaplain } has_any_disease_trigger = no @@ -2614,10 +2732,6 @@ exact_tribute_interaction = { } } - ai_potential = { - always = yes - } - ai_will_do = { base = 50 modifier = { @@ -2640,7 +2754,7 @@ exact_tribute_interaction = { } desc = TRIBUTARY_GREED_REASON } - + } ai_accept = { @@ -2658,9 +2772,9 @@ exact_tribute_interaction = { add = { add = 25 if = { - limit = { + limit = { OR = { - NOT = { scope:recipient.primary_title = title:h_china } + NOT = { scope:recipient.primary_title = title:h_china } government_has_flag = government_is_meritocratic } } @@ -2672,7 +2786,7 @@ exact_tribute_interaction = { # Unstable Phase modifier = { scope:actor = { highest_held_title_tier >= tier_hegemony } - situation:dynastic_cycle ?= { + situation:dynastic_cycle ?= { OR = { situation_current_phase = situation_dynastic_cycle_phase_instability situation_current_phase = situation_dynastic_cycle_phase_instability_conquest @@ -2683,11 +2797,11 @@ exact_tribute_interaction = { } # Stable Phase modifier = { - scope:actor = { + scope:actor = { highest_held_title_tier >= tier_hegemony legitimacy_level < dynastic_cycle_legitimacy_expectation } - situation:dynastic_cycle ?= { + situation:dynastic_cycle ?= { NOR = { situation_current_phase = situation_dynastic_cycle_phase_instability situation_current_phase = situation_dynastic_cycle_phase_instability_conquest @@ -2697,11 +2811,11 @@ exact_tribute_interaction = { desc = tributary_interaction_aibehavior_actor_low_legitimacy_tt } modifier = { - scope:actor = { + scope:actor = { highest_held_title_tier >= tier_hegemony legitimacy_level > dynastic_cycle_legitimacy_expectation } - situation:dynastic_cycle ?= { + situation:dynastic_cycle ?= { NOR = { situation_current_phase = situation_dynastic_cycle_phase_instability situation_current_phase = situation_dynastic_cycle_phase_instability_conquest @@ -2847,7 +2961,7 @@ exact_tribute_player_interaction = { trigger_else = { scope:actor = { government_has_flag = government_is_mandala } scope:recipient = { is_tributary_of = scope:actor } - } + } } is_valid_showing_failures_only = { @@ -2857,7 +2971,7 @@ exact_tribute_player_interaction = { custom_tooltip = { text = exact_tribute_interaction_recently_tribute_missioned_tt NOT = { var:tribute_mission_grace ?= scope:actor } - } + } #Has something to offer as Tribute Mission trigger_if = { limit = { @@ -2880,7 +2994,7 @@ exact_tribute_player_interaction = { } AND = { has_eunuch_tribute_trigger = yes - scope:actor = { + scope:actor = { culture = { has_cultural_parameter = can_appoint_chief_eunuch } } } @@ -2895,7 +3009,7 @@ exact_tribute_player_interaction = { #Is already engaged custom_tooltip = { text = exact_tribute_interaction_already_engaged_tt - NOR = { + NOR = { var:requested_tribute_mission ?= scope:actor has_variable = tribute_mission_type } @@ -3022,10 +3136,6 @@ exact_tribute_player_interaction = { } } - ai_potential = { - always = yes - } - ai_will_do = { base = 50 modifier = { @@ -3093,11 +3203,26 @@ offer_courtier_interaction = { } } + is_available = { + trigger_if = { + limit = { is_ai = yes } + OR = { + is_tributary = yes + num_of_relation_friend > 0 + num_of_relation_lover > 0 + } + OR = { + ai_greed <= 25 + is_obedient = yes + } + } + } + is_shown = { scope:actor != scope:recipient scope:recipient = { is_ruler = yes - NOT = { government_has_flag = government_is_true_herder } + NOT = { government_has_flag = government_is_herder } } } @@ -3294,18 +3419,6 @@ offer_courtier_interaction = { } } - ai_potential = { - OR = { - ai_greed <= 25 - is_obedient = yes - } - OR = { - is_tributary = yes - num_of_relation_friend > 0 - num_of_relation_lover > 0 - } - } - ai_will_do = { base = 0 @@ -3347,9 +3460,8 @@ offer_courtier_interaction = { modifier = { factor = 0 scope:actor = { - NOR = { - government_has_flag = government_is_nomadic - government_has_flag = government_is_true_herder + NOT = { + government_has_flag = government_is_in_steppe } } scope:secondary_actor = { @@ -3425,88 +3537,102 @@ offer_courtier_interaction = { on_accept = { if = { limit = { - scope:actor = { - has_title = title:e_minister_of_personnel - } scope:recipient = { - top_liege = scope:actor.top_liege - } - } - scope:recipient = { - add_courtier = scope:secondary_actor - scope:secondary_actor = { - every_consort = { - limit = { - is_courtier_of = scope:actor - } - scope:recipient = { - add_courtier = prev - } - } - every_child = { - limit = { - is_adult = no - is_courtier_of = scope:recipient - } - scope:actor = { - add_courtier = prev - } + has_opinion_modifier = { + target = scope:actor + modifier = offer_courtier_opinion } } + scope:actor = { is_ai = no } } - scope:actor = { + custom_tooltip = ALREADY_OFFERED_COURTIER_WARNING + } + + scope:actor = { + send_interface_toast = { + type = event_toast_effect_good + title = msg_courtier_offer_accepted_title + right_icon = scope:recipient + left_icon = scope:secondary_actor if = { limit = { - government_has_flag = government_has_influence - } - change_influence = { - value = scope:secondary_actor.average_of_all_skills_and_prowess - multiply = 5 - if = { - limit = { - scope:secondary_actor = { - is_close_or_extended_family_of = scope:actor - } - } - add = 100 - } - } - } - } - } - else = { - scope:secondary_actor = { - add_opinion = { - target = scope:recipient - modifier = annoyed_opinion - opinion = -10 - } - } - scope:recipient = { - add_courtier = scope:secondary_actor - scope:secondary_actor = { - every_consort = { - limit = { - is_courtier_of = scope:actor + scope:actor = { + has_title = title:e_minister_of_personnel } scope:recipient = { - add_courtier = prev + top_liege = scope:actor.top_liege } } - every_child = { - limit = { - is_adult = no - is_courtier_of = scope:recipient + scope:recipient = { + add_courtier = scope:secondary_actor + scope:secondary_actor = { + every_consort = { + limit = { + is_courtier_of = scope:actor + } + scope:recipient = { + add_courtier = prev + } + } + every_child = { + limit = { + is_adult = no + is_courtier_of = scope:recipient + } + scope:actor = { + add_courtier = prev + } + } } - scope:actor = { - add_courtier = prev + } + scope:actor = { + if = { + limit = { + government_has_flag = government_has_influence + } + change_influence = { + value = scope:secondary_actor.average_of_all_skills_and_prowess + multiply = 5 + if = { + limit = { + scope:secondary_actor = { + is_close_or_extended_family_of = scope:actor + } + } + add = 100 + } + } } } } - add_opinion = { - target = scope:actor - modifier = grateful_opinion - opinion = 10 + else = { + scope:recipient = { + add_courtier = scope:secondary_actor + scope:secondary_actor = { + every_consort = { + limit = { + is_courtier_of = scope:actor + } + scope:recipient = { + add_courtier = prev + } + } + every_child = { + limit = { + is_adult = no + is_courtier_of = scope:recipient + } + scope:actor = { + add_courtier = prev + } + } + } + add_opinion = { + target = scope:actor + modifier = offer_courtier_opinion + opinion = 10 + } + } } } } @@ -3640,6 +3766,14 @@ demand_courtier_interaction = { } } + is_available = { + trigger_if = { + limit = { is_ai = yes } + any_tributary = { } + ai_greed >= 0 + } + } + is_shown = { scope:actor != scope:recipient scope:recipient = { @@ -3655,12 +3789,12 @@ demand_courtier_interaction = { is_tributary_of = scope:actor AND = { # Celestial has this available towards vassals scope:actor = { government_has_flag = government_is_celestial } - liege = scope:actor + liege ?= scope:actor } AND = { # The minister of personnel can use it against every ruler in the realm scope:actor = { has_title = title:e_minister_of_personnel } is_ruler = yes - top_liege = scope:actor.top_liege + top_liege ?= scope:actor.top_liege # Except the top liege top_liege != this } @@ -3713,9 +3847,9 @@ demand_courtier_interaction = { is_ai = yes } } - + send_options_exclusive = no - + # Use hook send_option = { is_shown = { # Not available towards tributaries @@ -3821,7 +3955,7 @@ demand_courtier_interaction = { } desc = AI_FRIEND_REASON } - + # Used a hook modifier = { add = 100 @@ -3838,11 +3972,6 @@ demand_courtier_interaction = { } } - ai_potential = { - ai_greed >= 0 - any_tributary = { } - } - ai_will_do = { base = 0 @@ -3924,83 +4053,92 @@ demand_courtier_interaction = { } on_accept = { - if = { - limit = { - scope:actor = { - has_title = title:e_minister_of_personnel - } - scope:recipient = { - top_liege = scope:actor.top_liege - } - } - scope:actor = { - add_courtier = scope:secondary_actor - scope:secondary_actor = { - every_consort = { - limit = { - is_courtier_of = scope:recipient - } - scope:actor = { - add_courtier = prev - } - } - every_child = { - limit = { - is_adult = no - is_courtier_of = scope:recipient - } - scope:actor = { - add_courtier = prev - } - } - } - } - } - else = { - scope:secondary_actor = { - add_opinion = { - target = scope:recipient - modifier = annoyed_opinion - opinion = -10 - } - } - scope:actor = { - add_courtier = scope:secondary_actor - scope:secondary_actor = { - every_consort = { - limit = { - is_courtier_of = scope:recipient - } - scope:actor = { - add_courtier = prev - } - } - every_child = { - limit = { - is_adult = no - is_courtier_of = scope:recipient - } - scope:actor = { - add_courtier = prev - } - } - } - add_opinion = { - target = scope:recipient - modifier = pleased_opinion - opinion = 20 - } - # Use Hook + scope:actor = { + send_interface_toast = { + type = event_toast_effect_good + title = msg_courtier_demand_accepted_title + right_icon = scope:recipient + left_icon = scope:secondary_actor + if = { - limit = { scope:hook = yes } - use_hook = scope:recipient + limit = { + scope:actor = { + has_title = title:e_minister_of_personnel + } + scope:recipient = { + top_liege = scope:actor.top_liege + } + } + scope:actor = { + add_courtier = scope:secondary_actor + scope:secondary_actor = { + every_consort = { + limit = { + is_courtier_of = scope:recipient + } + scope:actor = { + add_courtier = prev + } + } + every_child = { + limit = { + is_adult = no + is_courtier_of = scope:recipient + } + scope:actor = { + add_courtier = prev + } + } + } + } } - } - scope:recipient = { - add_opinion = { - target = scope:actor - modifier = upset_opinion - opinion = -15 + else = { + scope:secondary_actor = { + add_opinion = { + target = scope:recipient + modifier = annoyed_opinion + opinion = -10 + } + } + scope:actor = { + add_courtier = scope:secondary_actor + scope:secondary_actor = { + every_consort = { + limit = { + is_courtier_of = scope:recipient + } + scope:actor = { + add_courtier = prev + } + } + every_child = { + limit = { + is_adult = no + is_courtier_of = scope:recipient + } + scope:actor = { + add_courtier = prev + } + } + } + add_opinion = { + target = scope:recipient + modifier = offer_courtier_opinion + opinion = 20 + } + # Use Hook + if = { + limit = { scope:hook = yes } + use_hook = scope:recipient + } + } + scope:recipient = { + add_opinion = { + target = scope:actor + modifier = upset_opinion + opinion = -15 + } + } } } } @@ -4064,16 +4202,28 @@ demand_concubine_interaction = { is_physically_able_adult = yes is_ruler = no could_marry_character_trigger = { CHARACTER = scope:actor } + NOT = { has_character_flag = has_been_offered_as_concubine } } add_to_list = characters } } } + is_available = { + allowed_concubines = yes + trigger_if = { + limit = { is_ai = yes } + any_tributary = { } + OR = { + ai_honor <= 0 + has_trait = lustful + } + } + } + is_shown = { scope:actor != scope:recipient scope:actor = { - allowed_concubines = yes NOR = { # We expect scope:actor to Exact Tribute for this purpose when Merit- or Mandala-based instead government_has_flag = government_has_merit government_has_flag = government_is_mandala @@ -4106,6 +4256,7 @@ demand_concubine_interaction = { is_physically_able_adult = yes is_ruler = no could_marry_character_trigger = { CHARACTER = scope:actor } + NOT = { has_character_flag = has_been_offered_as_concubine } } } } @@ -4122,7 +4273,7 @@ demand_concubine_interaction = { ai_accept = { base = 0 - + modifier = { add = 1000 scope:recipient = { @@ -4130,7 +4281,7 @@ demand_concubine_interaction = { } desc = AI_OBEDIENT_REASON } - + modifier = { add = 25 scope:recipient = { @@ -4141,7 +4292,7 @@ demand_concubine_interaction = { } desc = INTIMIDATED_REASON } - + modifier = { add = 50 scope:recipient = { @@ -4152,14 +4303,14 @@ demand_concubine_interaction = { } desc = COWED_REASON } - + opinion_modifier = { # Opinion Factor who = scope:recipient opinion_target = scope:actor multiplier = 1.0 desc = AI_OPINION_REASON } - + modifier = { add = -25 scope:secondary_actor = { @@ -4170,7 +4321,7 @@ demand_concubine_interaction = { } desc = AI_EMPLOYED_COURTIER_REASON } - + modifier = { add = -15 scope:secondary_actor = { @@ -4178,13 +4329,13 @@ demand_concubine_interaction = { } desc = AI_IS_KNIGHT_REASON } - + modifier = { add = -50 exists = scope:secondary_actor.inspiration desc = AI_INSPIRED_REASON } - + modifier = { add = -25 scope:secondary_actor = { @@ -4192,7 +4343,7 @@ demand_concubine_interaction = { } desc = AI_FAMILY_REASON } - + modifier = { add = -50 scope:secondary_actor = { @@ -4200,7 +4351,7 @@ demand_concubine_interaction = { } desc = AI_FRIEND_REASON } - + modifier = { add = -50 scope:secondary_actor = { @@ -4208,7 +4359,7 @@ demand_concubine_interaction = { } desc = AI_SPOUSE_REASON } - + modifier = { add = -50 scope:secondary_actor = { @@ -4216,7 +4367,7 @@ demand_concubine_interaction = { } desc = AI_CHILD_REASON } - + modifier = { add = 1000 scope:secondary_actor = { @@ -4226,17 +4377,9 @@ demand_concubine_interaction = { } } - ai_potential = { - OR = { - has_trait = lustful - ai_honor <= 0 - } - any_tributary = { } - } - ai_will_do = { base = 0 - + modifier = { add = 100 scope:secondary_actor = { @@ -4264,7 +4407,7 @@ demand_concubine_interaction = { } } } - + modifier = { factor = 0 scope:recipient = { @@ -4274,7 +4417,7 @@ demand_concubine_interaction = { } } } - + modifier = { factor = 0 scope:secondary_actor = { @@ -4295,7 +4438,7 @@ demand_concubine_interaction = { } } } - + on_accept = { scope:recipient = { if = { @@ -4359,16 +4502,23 @@ offer_tributary_status_interaction = { #Embrace as Tributary category = interaction_category_vassal common_interaction = yes icon = icon_liege - + desc = offer_tributary_status_interaction_desc + is_available = { + government_allows = ask_for_tribute #Mandala Government + trigger_if = { + limit = { is_ai = yes } + is_independent_ruler = yes + } + is_landed = yes + } + is_shown = { scope:actor = { - government_allows = ask_for_tribute #Mandala Government - is_landed = yes NOT = { this = scope:recipient - top_suzerain = scope:recipient.top_suzerain # ensures the actor and recipient is not already in the same "suzerain bloc" + top_suzerain ?= scope:recipient.top_suzerain # ensures the actor and recipient is not already in the same "suzerain bloc" } } scope:recipient = { @@ -4395,7 +4545,7 @@ offer_tributary_status_interaction = { #Embrace as Tributary custom_tooltip = { text = offer_tributary_status_interaction_tributary_was_recently_subjugated NOT = { has_truce = scope:recipient.suzerain } - } + } } trigger_else = { is_tributary = no } custom_tooltip = { @@ -4429,20 +4579,20 @@ offer_tributary_status_interaction = { #Embrace as Tributary value = { value = { value = minor_piety_value - divide = 2 + divide = 2 } multiply = scope:actor.primary_title.tier if = { limit = { - scope:recipient = { + scope:recipient = { has_opinion_modifier = { modifier = tributary_ceased_payments_opinion target = scope:actor } } } - multiply = activity_cost_scale_by_era - } + multiply = scope:actor.activity_cost_scale_by_era + } #Mandala Godking AI if = { limit = { @@ -4453,8 +4603,8 @@ offer_tributary_status_interaction = { #Embrace as Tributary } multiply = 0.25 } - } - } + } + } } greeting = positive @@ -4464,7 +4614,7 @@ offer_tributary_status_interaction = { #Embrace as Tributary send_option = { flag = low_obligations localization = low_tributary_obligations - starts_enabled = { + starts_enabled = { scope:actor = { is_ai = yes } } } @@ -4473,10 +4623,10 @@ offer_tributary_status_interaction = { #Embrace as Tributary send_option = { flag = normal_obligations localization = normal_tributary_obligations - starts_enabled = { + starts_enabled = { scope:actor = { is_ai = no } } - is_valid = { + is_valid = { scope:actor = { is_ai = no } } } @@ -4485,7 +4635,7 @@ offer_tributary_status_interaction = { #Embrace as Tributary send_option = { flag = high_obligations localization = high_tributary_obligations - is_valid = { + is_valid = { scope:actor = { is_ai = no } } } @@ -4549,10 +4699,6 @@ offer_tributary_status_interaction = { #Embrace as Tributary ai_maybe = yes - ai_potential = { - is_independent_ruler = yes - } - ai_targets = { ai_recipients = neighboring_rulers_including_tributary_borders } @@ -4616,7 +4762,7 @@ offer_tributary_status_interaction = { #Embrace as Tributary this = scope:actor } } - } + } } add = -25 } @@ -4677,7 +4823,7 @@ offer_tributary_status_interaction = { #Embrace as Tributary any_neighboring_top_liege_realm_owner = { has_unruined_mandala_capital_trigger = yes government_has_flag = government_is_mandala - NOR = { + NOR = { this = scope:actor this = scope:recipient } @@ -4686,14 +4832,14 @@ offer_tributary_status_interaction = { #Embrace as Tributary any_neighboring_top_suzerain_realm_owner ?= { has_unruined_mandala_capital_trigger = yes government_has_flag = government_is_mandala - NOR = { + NOR = { this = scope:actor this = scope:recipient } save_temporary_scope_as = suzerain_comparison } } - } + } always = yes } trigger_else = { always = no } @@ -4714,7 +4860,7 @@ offer_tributary_status_interaction = { #Embrace as Tributary limit = { scope:recipient = { is_tributary = yes - overlord = { + overlord = { government_has_flag = government_is_mandala has_unruined_mandala_capital_trigger = yes mandala_radiance_value > 0 @@ -4790,7 +4936,7 @@ offer_tributary_status_interaction = { #Embrace as Tributary } add = { value = scope:recipient.highest_held_title_tier - subtract = scope:actor.highest_held_title_tier + subtract = scope:actor.highest_held_title_tier multiply = 50 multiply = -1 } @@ -4813,13 +4959,9 @@ offer_tributary_status_interaction = { #Embrace as Tributary modifier = { # Different faith, no pluralism. desc = offer_vassalization_interaction_aibehavior_differentfaith_tt trigger = { - scope:recipient = { - faith = { - NOR = { # Of two different faiths AND the potential tributary's faith is not pluralistic - this = scope:actor.faith - has_doctrine = doctrine_pluralism_pluralistic - } - } + NOR = { # Of two different faiths AND the potential tributary's faith is not pluralistic + scope:recipient.faith = scope:actor.faith + scope:recipient.rite = { rite_has_doctrine = doctrine_pluralism_pluralistic } } } add = { @@ -4852,24 +4994,10 @@ offer_tributary_status_interaction = { #Embrace as Tributary modifier = { # Different religion Family - We prefer god kings to be vaguely within our own world view desc = embrace_as_tributary_interaction_other_religion_family trigger = { - scope:recipient = { - NOT = { government_has_flag = government_is_wanua } - } - scope:actor.faith.religion = { - switch = { - trigger = is_in_family - rf_pagan = { - scope:recipient.faith.religion = { NOT = { is_in_family = rf_pagan } } - } - rf_sinitic = { - scope:recipient.faith.religion = { NOT = { is_in_family = rf_sinitic } } - } - rf_eastern = { - scope:recipient.faith.religion = { NOT = { is_in_family = rf_eastern } } - } - rf_abrahamic = { - scope:recipient.faith.religion = { NOT = { is_in_family = rf_abrahamic } } - } + scope:recipient = { + NOR = { + faith = { faith_is_in_same_rf = { FAITH = scope:actor.faith } } + government_has_flag = government_is_wanua } } } @@ -4884,7 +5012,7 @@ offer_tributary_status_interaction = { #Embrace as Tributary } } # They are not Mandalas nor Tribes - modifier = { + modifier = { desc = embrace_as_tributary_interaction_wrong_government scope:recipient = { NOR = { @@ -4898,7 +5026,8 @@ offer_tributary_status_interaction = { #Embrace as Tributary limit = { scope:recipient = { OR = { - government_allows = administrative + government_has_mechanic = administrative + government_is_japanese_trigger = yes government_has_flag = government_is_nomadic } } @@ -4915,7 +5044,7 @@ offer_tributary_status_interaction = { #Embrace as Tributary #Not radiant enough if = { limit = { - scope:actor = { + scope:actor = { has_unruined_mandala_capital_trigger = yes mandala_radiance_value <= 40 } @@ -4925,13 +5054,13 @@ offer_tributary_status_interaction = { #Embrace as Tributary } } #We single out Japan specifically - modifier = { + modifier = { desc = embrace_as_tributary_interaction_wrong_government scope:recipient = { government_is_japanese_trigger = yes } add = -1000 } #Far away - modifier = { + modifier = { desc = offer_vassalization_interaction_aibehavior_remoterealm_tt trigger = { scope:recipient = { @@ -5018,7 +5147,7 @@ offer_tributary_status_interaction = { #Embrace as Tributary add = { value = 0 if = { - limit = { + limit = { scope:recipient.suzerain = { has_unruined_mandala_capital_trigger = yes } } subtract = { @@ -5148,7 +5277,7 @@ offer_tributary_status_interaction = { #Embrace as Tributary trigger_else = { always = no } add = -30 desc = proposed_obligation_level_high - } + } #Legitimacy modifier = { @@ -5225,10 +5354,11 @@ reassert_tributary_interaction = { desc = reassert_tributary_interaction_desc + is_available = { + government_has_flag = government_is_mandala + } + is_shown = { - scope:actor = { - government_has_flag = government_is_mandala - } scope:recipient = { is_tributary_of = scope:actor is_ai = yes @@ -5260,7 +5390,7 @@ reassert_tributary_interaction = { cost = { piety = { value = minor_piety_value - multiply = activity_cost_scale_by_era + multiply = scope:actor.activity_cost_scale_by_era #Mandala Godking AI if = { limit = { @@ -5295,7 +5425,7 @@ reassert_tributary_interaction = { is_valid = { custom_tooltip = { text = ALREADY_LOWEST_TAX_OBLIGATION - scope:recipient = { + scope:recipient = { OR = { has_subject_contract_group = tributary_mandala has_subject_contract_group = tributary_mandala_tribal @@ -5309,7 +5439,7 @@ reassert_tributary_interaction = { } send_option = { is_shown = { - scope:recipient = { + scope:recipient = { OR = { has_subject_contract_group = tributary_mandala has_subject_contract_group = tributary_mandala_tribal @@ -5322,7 +5452,7 @@ reassert_tributary_interaction = { } send_option = { is_shown = { - scope:recipient = { + scope:recipient = { OR = { has_subject_contract_group = tributary_mandala has_subject_contract_group = tributary_mandala_tribal @@ -5335,7 +5465,7 @@ reassert_tributary_interaction = { } send_option = { is_shown = { - scope:recipient = { + scope:recipient = { OR = { has_subject_contract_group = tributary_mandala has_subject_contract_group = tributary_mandala_tribal @@ -5348,7 +5478,7 @@ reassert_tributary_interaction = { } send_option = { is_shown = { - scope:recipient = { + scope:recipient = { OR = { has_subject_contract_group = tributary_mandala has_subject_contract_group = tributary_mandala_tribal @@ -5363,7 +5493,7 @@ reassert_tributary_interaction = { ##Piety send_option = { is_shown = { - scope:recipient = { + scope:recipient = { has_subject_contract_group = tributary_mandala OR = { vassal_contract_obligation_level:mandala_government_piety = 1 @@ -5374,7 +5504,7 @@ reassert_tributary_interaction = { is_valid = { custom_tooltip = { text = ALREADY_LOWEST_PIETY_OBLIGATION - scope:recipient = { + scope:recipient = { has_subject_contract_group = tributary_mandala vassal_contract_obligation_level:mandala_government_piety = 1 } @@ -5385,7 +5515,7 @@ reassert_tributary_interaction = { } send_option = { is_shown = { - scope:recipient = { + scope:recipient = { has_subject_contract_group = tributary_mandala vassal_contract_obligation_level:mandala_government_piety = 2 } @@ -5397,7 +5527,7 @@ reassert_tributary_interaction = { ##Prestige send_option = { is_shown = { - scope:recipient = { + scope:recipient = { has_subject_contract_group = tributary_mandala_tribal OR = { vassal_contract_obligation_level:mandala_government_prestige = 1 @@ -5408,7 +5538,7 @@ reassert_tributary_interaction = { is_valid = { custom_tooltip = { text = ALREADY_LOWEST_PRESTIGE_OBLIGATION - scope:recipient = { + scope:recipient = { has_subject_contract_group = tributary_mandala vassal_contract_obligation_level:mandala_government_prestige = 1 } @@ -5419,7 +5549,7 @@ reassert_tributary_interaction = { } send_option = { is_shown = { - scope:recipient = { + scope:recipient = { has_subject_contract_group = tributary_mandala_tribal vassal_contract_obligation_level:mandala_government_prestige = 2 } @@ -5445,7 +5575,7 @@ reassert_tributary_interaction = { is_valid = { custom_tooltip = { text = ALREADY_LOWEST_LEVY_OBLIGATION - scope:recipient = { + scope:recipient = { OR = { has_subject_contract_group = tributary_mandala has_subject_contract_group = tributary_mandala_tribal @@ -5459,7 +5589,7 @@ reassert_tributary_interaction = { } send_option = { is_shown = { - scope:recipient = { + scope:recipient = { OR = { has_subject_contract_group = tributary_mandala has_subject_contract_group = tributary_mandala_tribal @@ -5472,7 +5602,7 @@ reassert_tributary_interaction = { } send_option = { is_shown = { - scope:recipient = { + scope:recipient = { OR = { has_subject_contract_group = tributary_mandala has_subject_contract_group = tributary_mandala_tribal @@ -5485,7 +5615,7 @@ reassert_tributary_interaction = { } send_option = { is_shown = { - scope:recipient = { + scope:recipient = { OR = { has_subject_contract_group = tributary_mandala has_subject_contract_group = tributary_mandala_tribal @@ -5498,7 +5628,7 @@ reassert_tributary_interaction = { } send_option = { is_shown = { - scope:recipient = { + scope:recipient = { OR = { has_subject_contract_group = tributary_mandala has_subject_contract_group = tributary_mandala_tribal @@ -5512,7 +5642,7 @@ reassert_tributary_interaction = { #Dread send_option = { - is_valid = { + is_valid = { scope:actor = { dread >= high_dread } } flag = dread @@ -5589,7 +5719,7 @@ reassert_tributary_interaction = { #LOWER OBLIGATIONS ##Taxes if = { - limit = { + limit = { OR = { scope:decrease_tax_obligation_1 = yes scope:decrease_tax_obligation_2 = yes @@ -5637,10 +5767,10 @@ reassert_tributary_interaction = { } ##Piety if = { - limit = { + limit = { OR = { scope:decrease_piety_obligation_1 = yes - scope:decrease_piety_obligation_2 = yes + scope:decrease_piety_obligation_2 = yes } } scope:recipient = { @@ -5661,10 +5791,10 @@ reassert_tributary_interaction = { } ##Prestige if = { - limit = { + limit = { OR = { scope:decrease_prestige_obligation_1 = yes - scope:decrease_prestige_obligation_2 = yes + scope:decrease_prestige_obligation_2 = yes } } scope:recipient = { @@ -5685,7 +5815,7 @@ reassert_tributary_interaction = { } ##Levies if = { - limit = { + limit = { OR = { scope:decrease_levy_obligation_1 = yes scope:decrease_levy_obligation_2 = yes @@ -5731,7 +5861,7 @@ reassert_tributary_interaction = { } } } - + #Strong hook if = { limit = { @@ -5827,7 +5957,7 @@ reassert_tributary_interaction = { trigger_event = tgp_east_asia_interaction_events.0025 } scope:recipient = { - show_as_tooltip = { + show_as_tooltip = { add_opinion = { modifier = reassertion_request_denied_opinion # this opinion also acts as a built-in cooldown target = scope:actor @@ -5974,10 +6104,6 @@ reassert_tributary_interaction = { ai_maybe = yes - ai_potential = { - government_has_flag = government_is_mandala - } - ai_targets = { ai_recipients = tributaries } @@ -6048,7 +6174,7 @@ reassert_tributary_interaction = { } modifier = { - suzerain = { + suzerain = { government_has_flag = government_is_mandala has_unruined_mandala_capital_trigger = yes mandala_radiance_value > 0 @@ -6083,3 +6209,4 @@ reassert_tributary_interaction = { } } } + diff --git a/common/character_interactions/00_vassal_interactions.txt b/common/character_interactions/00_vassal_interactions.txt index 6d7320510..86e6e4fbf 100644 --- a/common/character_interactions/00_vassal_interactions.txt +++ b/common/character_interactions/00_vassal_interactions.txt @@ -9,7 +9,7 @@ grant_vassal_interaction = { special_interaction = grant_vassal_interaction populate_actor_list = { - scope:actor = { + scope:puppet_or_actor = { every_vassal = { add_to_list = characters } @@ -27,20 +27,21 @@ grant_vassal_interaction = { pre_answer_no_key = DECLINE is_shown = { - scope:recipient != scope:actor + scope:recipient != scope:puppet_or_actor OR = { AND = { exists = scope:recipient.liege - scope:recipient.liege = scope:actor + scope:recipient.liege ?= scope:puppet_or_actor } AND = { - exists = scope:actor.liege - scope:actor.liege = scope:recipient + exists = scope:puppet_or_actor.liege + scope:puppet_or_actor.liege ?= scope:recipient } AND = { - scope:actor.faith.religious_head = scope:recipient - scope:recipient = { is_independent_ruler = yes } -# scope:actor.faith = { NOT = { has_doctrine = doctrine_holy_order_head } } + scope:puppet_or_actor.faith.religious_head ?= scope:recipient + scope:recipient = { + top_liege = this + } } } scope:recipient.highest_held_title_tier > tier_barony @@ -52,7 +53,7 @@ grant_vassal_interaction = { # Gallivanters won't accept additional responsibilities. NOT = { has_trait = gallivanter } } - NOT = { scope:actor = { is_at_war_with = scope:recipient } } + NOT = { scope:puppet_or_actor = { is_at_war_with = scope:recipient } } trigger_if = { limit = { exists = scope:secondary_actor } NOT = { scope:secondary_actor = { is_at_war_with = scope:recipient } } @@ -60,7 +61,7 @@ grant_vassal_interaction = { } trigger_if = { limit = { - scope:actor = { is_ai = yes } + scope:puppet_or_actor = { is_ai = yes } exists = scope:secondary_actor } trigger_if = { @@ -84,7 +85,7 @@ grant_vassal_interaction = { scope:recipient = { highest_held_title_tier > tier_county } } trigger_else = { - scope:actor = { + scope:puppet_or_actor = { custom_description = { text = "basic_valid_vassal_to_tranfer" object = scope:recipient @@ -97,20 +98,20 @@ grant_vassal_interaction = { } # Prevent Admin AI transferring admin vassals under non-admin vassals NAND = { - scope:actor ?= { + scope:puppet_or_actor ?= { is_ai = yes - government_allows = administrative + government_has_mechanic = administrative } scope:recipient ?= { - NOT = { government_allows = administrative } + NOT = { government_has_mechanic = administrative } } - scope:secondary_actor ?= { government_allows = administrative } + scope:secondary_actor ?= { government_has_mechanic = administrative } } # Ritsuryo cannot transfer Soryo to Ritsuryo custom_tooltip = { text = ritsuryo_to_soryo_invalid_to_transfer NAND = { - scope:actor ?= { has_government = japan_administrative_government } + scope:puppet_or_actor ?= { has_government = japan_administrative_government } scope:recipient ?= { has_government = japan_administrative_government } scope:secondary_actor ?= { has_government = japan_feudal_government } } @@ -133,13 +134,13 @@ grant_vassal_interaction = { highest_held_title_tier < scope:recipient.highest_held_title_tier trigger_if = { - limit = { scope:actor.liege = scope:recipient } + limit = { scope:puppet_or_actor.liege = scope:recipient } custom_tooltip = { text = is_de_jure_liege_of_target NOT = { primary_title = { any_this_title_or_de_jure_above = { - holder = scope:actor + holder = scope:puppet_or_actor } } } @@ -149,18 +150,18 @@ grant_vassal_interaction = { # You can't give your diarch away as a vassal. custom_description = { text = cannot_grant_own_diarch_as_vassal - subject = scope:actor.diarch - NOT = { root ?= scope:actor.diarch } + subject = scope:puppet_or_actor.diarch + NOT = { scope:puppet_or_actor.diarch ?= root } } # Not at war with the vassal being transferred (blocks explicit transfer of war enemies, which invalidates the war). custom_description = { text = "basic_is_at_war_with_vassal" subject = root - object = scope:actor + object = scope:puppet_or_actor NOT = { root = { - is_at_war_with = scope:actor + is_at_war_with = scope:puppet_or_actor } } } @@ -169,10 +170,12 @@ grant_vassal_interaction = { custom_description = { text = "basic_is_at_war_with_sub_vassal" subject = root - object = scope:actor + object = scope:puppet_or_actor NOT = { - any_vassal_or_below = { - is_at_war_with = root + scope:puppet_or_actor = { + any_vassal_or_below = { + is_at_war_with = root + } } } } @@ -181,13 +184,8 @@ grant_vassal_interaction = { custom_description = { text = admin_cannot_grant_vassal_noble_family subject = root - trigger_if = { - limit = { - government_allows = administrative - } - any_held_title = { - is_noble_family_title = no - } + any_held_title = { + is_noble_family_title = no } } } @@ -202,7 +200,27 @@ grant_vassal_interaction = { } on_accept = { - scope:actor = { + #Holy Order patronage loss warning + if = { + limit = { + #Holy order is actually involved + scope:puppet_or_actor = { + any_patroned_holy_order = { + leader.capital_county.holder ?= { + target_is_same_character_or_above = scope:secondary_actor + } + } + } + scope:recipient = { + highest_held_title_tier >= tier_duchy + } + } + scope:puppet_or_actor = { + custom_tooltip = holy_order_control_loss_warning_tt + } + } + + scope:puppet_or_actor = { send_interface_toast = { type = event_toast_effect_good title = grant_vassal_interaction_notification @@ -212,7 +230,7 @@ grant_vassal_interaction = { # If we're granting a vassal to our liege, gain a truce with our former vassal (we can't immediately reconquer them, and they can't attack us either). if = { limit = { - scope:actor = { + scope:puppet_or_actor = { is_vassal_of = scope:recipient } } @@ -240,7 +258,7 @@ grant_vassal_interaction = { # Gain an opinion bonus with the person we gave a vassal to. scope:recipient = { add_opinion = { - target = scope:actor + target = scope:puppet_or_actor modifier = granted_vassal } } @@ -249,7 +267,7 @@ grant_vassal_interaction = { # If we're a clan this interaction affects unity add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = miniscule_unity_gain DESC = clan_unity_grant_vassal.desc @@ -261,10 +279,10 @@ grant_vassal_interaction = { # if = { # limit = { # fp3_struggle_involves_one_supporter_and_one_detractor = { -# FIRST = scope:actor +# FIRST = scope:puppet_or_actor # SECOND = scope:recipient # } -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # involvement = involved # phase_has_catalyst = catalyst_grants_vassal_to_de_jure_liege_supporter_detractor @@ -279,12 +297,12 @@ grant_vassal_interaction = { # } # } # } -# scope:actor = { +# scope:puppet_or_actor = { # every_character_struggle = { # involvement = involved # activate_struggle_catalyst = { # catalyst = catalyst_grants_vassal_to_de_jure_liege_supporter_detractor -# character = scope:actor +# character = scope:puppet_or_actor # } # log_debug_variable_for_persian_struggle_effect = { VAR = concession_catalyst_grants_vassal_to_de_jure_liege_supporter_detractor } # } @@ -315,17 +333,100 @@ grant_vassal_interaction = { } } } + #Opinion loss with underlings who think they should get the vassal you're granting + if = { + limit = { + #AI will usually grant title to de jure holders, it's players who could use this steering + scope:puppet_or_actor = { + is_ai = no + } + } + scope:secondary_actor = { + if = { + limit = { + any_held_title = { + any_claimant = { + this = scope:recipient + } + } + } + ordered_held_title = { + order_by = tier + limit = { + any_claimant = { + this = scope:recipient + } + } + save_scope_as = highest_claim + } + scope:recipient = { claimant_jealousy_immunity_effect = yes } + } + every_held_title = { + limit = { + tier >= tier_county + tier = scope:secondary_actor.primary_title.tier + } + save_scope_as = title_transfered + scope:puppet_or_actor = { + title_granting_controversy_effect = { + TITLE = scope:title_transfered + INTERACTION = grant_vassal_interaction + } + } + } + every_in_list = { + list = strong_claimants + limit = { + NOT = { this = scope:recipient } + } + save_scope_as = claimer + scope:secondary_actor = { + ordered_held_title = { + limit = { + any_claimant = { + this = scope:claimer + } + } + save_scope_as = highest_denied_claim + } + } + claimant_rivalry_mercy_effect = yes + } + } + #Being given to a non de jure liege should piss vassals off + if = { + limit = { + NOT = { + scope:secondary_actor = { + any_held_title = { + any_this_title_or_de_jure_above = { + holder ?= scope:recipient + } + } + } + } + } + scope:secondary_actor = { + add_opinion = { + modifier = subordinated_to_non_de_jure_liege_opinion + target = scope:puppet_or_actor + opinion = -30 + } + } + } + + } } on_decline = { - scope:actor = { + scope:puppet_or_actor = { trigger_event = char_interaction.0211 } # If we're a clan this interaction affects unity add_clan_unity_interaction_effect = { CHARACTER = scope:recipient - TARGET = scope:actor + TARGET = scope:puppet_or_actor VALUE = miniscule_unity_loss DESC = clan_unity_grant_vassal_decline.desc REVERSE_NON_HOUSE_TARGET = no @@ -364,11 +465,19 @@ retract_vassal_interaction = { } } + is_available = { + trigger_if = { + limit = { is_ai = yes } + has_realm_law_flag = title_revocation_allowed + primary_title.tier > tier_county + } + } + is_shown = { - scope:recipient != scope:actor + scope:recipient != scope:puppet_or_actor scope:recipient = { highest_held_title_tier > tier_barony - liege = scope:actor + liege ?= scope:puppet_or_actor } } @@ -378,13 +487,14 @@ retract_vassal_interaction = { scope:recipient = { custom_description = { text = "basic_vassal_to_retract" + object = scope:actor any_vassal = { highest_held_title_tier > tier_barony } } } # Plus make sure there's a legal right to retract. - scope:actor = { + scope:puppet_or_actor = { trigger_if = { limit = { government_has_flag = government_is_tribal @@ -403,6 +513,15 @@ retract_vassal_interaction = { has_realm_law_flag = vassal_retraction_allowed } } + trigger_else_if = { + limit = { + realm_law_use_church_authority = yes + } + custom_description = { + text = "has_law_allowing_vassal_retraction_church" + has_realm_law_flag = vassal_retraction_allowed + } + } trigger_else = { custom_description = { text = "has_law_allowing_vassal_retraction_crown" @@ -411,16 +530,16 @@ retract_vassal_interaction = { } } scope:recipient = { - NOT = { has_strong_hook = scope:actor } + NOT = { has_strong_hook = scope:puppet_or_actor } } custom_tooltip = { text = cannot_take_overt_hostile_actions_against_diarch.tt - NOT = { scope:recipient ?= scope:actor.diarch } + NOT = { scope:recipient ?= scope:puppet_or_actor.diarch } } } can_send = { - scope:actor = { + scope:puppet_or_actor = { custom_description = { text = "character_interactions_hostile_actions_disabled_delay" NOT = { has_character_flag = flag_hostile_actions_disabled_delay } @@ -434,11 +553,18 @@ retract_vassal_interaction = { cost = { # Usually, this action is free, but during certain diarchies, we want it to cost. - prestige = liege_diarchy_surcharge_interaction_retract_vassal_interaction_value + prestige = { + value = liege_diarchy_surcharge_interaction_retract_vassal_interaction_value + + if = { + limit = { scope:is_puppet_action ?= yes } + multiply = 0 + } + } } on_send = { - scope:actor = { + scope:puppet_or_actor = { add_character_flag = { flag = flag_hostile_actions_disabled_delay days = 10 @@ -456,33 +582,36 @@ retract_vassal_interaction = { on_accept = { retract_vassal_interaction_effect = yes - if = { limit = { - scope:actor = { has_character_flag = flag_hostile_actions_disabled_delay } + scope:puppet_or_actor = { has_character_flag = flag_hostile_actions_disabled_delay } } - scope:actor = { remove_character_flag = flag_hostile_actions_disabled_delay } + scope:puppet_or_actor = { remove_character_flag = flag_hostile_actions_disabled_delay } } - scope:actor = { + scope:puppet_or_actor = { trigger_event = char_interaction.0220 } } on_decline = { - scope:actor = { vassal_revocation_tyranny_effect = yes } - war_for_retraction_effect = yes + scope:puppet_or_actor = { vassal_revocation_tyranny_effect = yes } + war_for_retraction_effect = { + LIEGE = scope:puppet_or_actor + REBEL = scope:recipient + SUBVASSAL = scope:secondary_recipient + } scope:recipient = { add_opinion = { - target = scope:actor + target = scope:puppet_or_actor modifier = retracted_vassal } } if = { limit = { - scope:actor = { has_realm_law_flag = vassal_refusal_is_treason } + scope:puppet_or_actor = { has_realm_law_flag = vassal_refusal_is_treason } } - scope:actor = { + scope:puppet_or_actor = { add_opinion = { target = scope:recipient modifier = treasonous_retract_refusal @@ -491,23 +620,23 @@ retract_vassal_interaction = { } if = { limit = { - scope:actor = { has_character_flag = flag_hostile_actions_disabled_delay } + scope:puppet_or_actor = { has_character_flag = flag_hostile_actions_disabled_delay } } - scope:actor = { remove_character_flag = flag_hostile_actions_disabled_delay } + scope:puppet_or_actor = { remove_character_flag = flag_hostile_actions_disabled_delay } } } auto_accept = { OR = { scope:recipient = { - is_imprisoned_by = scope:actor + is_imprisoned_by = scope:puppet_or_actor } custom_description = { text = "spending_hook" - subject = scope:actor + subject = scope:puppet_or_actor object = scope:recipient scope:hook = yes - scope:actor = { has_strong_hook = scope:recipient } + scope:puppet_or_actor = { has_strong_hook = scope:recipient } } } } @@ -516,11 +645,11 @@ retract_vassal_interaction = { custom_description = { #Hook from Recipient can counteract, but only if Actor is not forcing the action via Strong Hook. text = "spending_hook" subject = scope:recipient - object = scope:actor - scope:recipient = { has_hook = scope:actor } + object = scope:puppet_or_actor + scope:recipient = { has_hook = scope:puppet_or_actor } NAND = { scope:hook = yes - scope:actor = { has_strong_hook = scope:recipient } + scope:puppet_or_actor = { has_strong_hook = scope:recipient } } } } @@ -528,7 +657,7 @@ retract_vassal_interaction = { on_blocked_effect = { scope:recipient = { remove_hook = { - target = scope:actor + target = scope:puppet_or_actor } } } @@ -536,6 +665,10 @@ retract_vassal_interaction = { ai_accept = { base = 0 # Try to make it 0 for most interactions + legalism_lawful_authority_acceptance_modifier = { + ACTOR = scope:puppet_or_actor + } + modifier = { has_game_rule = hard_difficulty scope:actor = { is_ai = no } @@ -570,14 +703,14 @@ retract_vassal_interaction = { opinion_modifier = { # Opinion Factor who = scope:recipient - opinion_target = scope:actor + opinion_target = scope:puppet_or_actor multiplier = 1.0 desc = AI_OPINION_REASON } modifier = { add = 25 - scope:actor = { + scope:puppet_or_actor = { has_realm_law_flag = vassal_refusal_is_treason } desc = AI_REFUSAL_IS_TREASON @@ -601,7 +734,7 @@ retract_vassal_interaction = { modifier = { add = 20 - scope:actor.current_military_strength > scope:recipient.current_military_strength + scope:puppet_or_actor.current_military_strength > scope:recipient.current_military_strength scope:recipient = { has_trait = craven } @@ -624,7 +757,7 @@ retract_vassal_interaction = { scope:recipient = { #If AI is honorable and the law compels to obey the liege, AI will be more likely to obey. ai_honor > 0 } - scope:actor = { + scope:puppet_or_actor = { has_realm_law_flag = vassal_refusal_is_treason } } @@ -633,14 +766,14 @@ retract_vassal_interaction = { } } modifier = { - exists = scope:actor.primary_title.title_capital_county + exists = scope:puppet_or_actor.primary_title.title_capital_county scope:secondary_recipient = { OR = { any_sub_realm_county = { - this = scope:actor.primary_title.title_capital_county + this = scope:puppet_or_actor.primary_title.title_capital_county } any_sub_realm_duchy = { - this = scope:actor.primary_title.title_capital_county.de_jure_liege + this = scope:puppet_or_actor.primary_title.title_capital_county.de_jure_liege } } } @@ -649,19 +782,19 @@ retract_vassal_interaction = { } modifier = { - exists = scope:actor.primary_title.title_capital_county + exists = scope:puppet_or_actor.primary_title.title_capital_county scope:secondary_recipient = { NOR = { any_sub_realm_county = { - this = scope:actor.primary_title.title_capital_county + this = scope:puppet_or_actor.primary_title.title_capital_county } any_sub_realm_duchy = { - this = scope:actor.primary_title.title_capital_county.de_jure_liege + this = scope:puppet_or_actor.primary_title.title_capital_county.de_jure_liege } } primary_title.tier = tier_county any_sub_realm_county = { - de_jure_liege = scope:actor.primary_title.title_capital_county.de_jure_liege + de_jure_liege = scope:puppet_or_actor.primary_title.title_capital_county.de_jure_liege } } add = 30 @@ -681,7 +814,7 @@ retract_vassal_interaction = { } modifier = { #Sub-Vassal is De jure of liege title. add = 15 - scope:actor = { + scope:puppet_or_actor = { any_held_title = { this = scope:secondary_recipient.primary_title.de_jure_liege } @@ -692,7 +825,7 @@ retract_vassal_interaction = { add = intimidated_halved_reason_value scope:recipient = { has_dread_level_towards = { - target = scope:actor + target = scope:puppet_or_actor level = 1 } } @@ -702,7 +835,7 @@ retract_vassal_interaction = { add = cowed_halved_reason_value scope:recipient = { has_dread_level_towards = { - target = scope:actor + target = scope:puppet_or_actor level = 2 } } @@ -714,7 +847,7 @@ retract_vassal_interaction = { value = 1 subtract = { value = scope:recipient.current_military_strength - divide = { value = scope:actor.current_military_strength min = 1 } + divide = { value = scope:puppet_or_actor.current_military_strength min = 1 } } multiply = 100 } @@ -722,11 +855,11 @@ retract_vassal_interaction = { modifier = { #Different faith, no pluralism. desc = AI_REFUSAL_SPLITTING_SAME_FAITH_VASSALS trigger = { - scope:actor.faith = scope:secondary_recipient.faith #Will not care as much if the vassal being retracted is of a different faith. - scope:actor = { + scope:puppet_or_actor.faith = scope:secondary_recipient.faith #Will not care as much if the vassal being retracted is of a different faith. + scope:puppet_or_actor = { NOR = { #Of two different faiths AND the potential vassal's faith is not pluralistic. faith = scope:recipient.faith - faith = { has_doctrine = doctrine_pluralism_pluralistic } + rite = { rite_has_doctrine = doctrine_pluralism_pluralistic } } } } @@ -734,7 +867,7 @@ retract_vassal_interaction = { value = -25 if = { limit = { - scope:actor.faith = { + scope:puppet_or_actor.faith = { faith_hostility_level = { target = scope:recipient.faith value >= faith_hostile_level @@ -745,7 +878,7 @@ retract_vassal_interaction = { } if = { limit = { - scope:actor.faith = { + scope:puppet_or_actor.faith = { faith_hostility_level = { target = scope:recipient.faith value >= faith_evil_level @@ -757,7 +890,7 @@ retract_vassal_interaction = { } } modifier = { # AI Mongols, tyranny wars just delay the inevitable fun! - scope:actor = { + scope:puppet_or_actor = { is_ai = yes OR = { has_trait = greatest_of_khans @@ -781,7 +914,7 @@ retract_vassal_interaction = { #Use hook send_option = { is_valid = { - scope:actor = { + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } @@ -789,7 +922,7 @@ retract_vassal_interaction = { localization = SCHEME_HOOK } should_use_extra_icon = { - scope:actor = { has_usable_hook = scope:recipient } + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } extra_icon = "gfx/interface/icons/character_interactions/hook_icon.dds" @@ -810,11 +943,6 @@ retract_vassal_interaction = { hegemony = 12 } - ai_potential = { - has_realm_law_flag = title_revocation_allowed - primary_title.tier > tier_county - } - ai_will_do = { base = -1000 @@ -822,7 +950,7 @@ retract_vassal_interaction = { # And even if we can avoid tyranny we don't want to retract just because we can, so this only gets us to -10 # Certain characters will retract despite tyranny, if their rationality is sufficiently low modifier = { - scope:actor = { + scope:puppet_or_actor = { OR = { has_revoke_title_reason = scope:recipient AND = { @@ -842,40 +970,40 @@ retract_vassal_interaction = { modifier = { years_from_game_start >= 3 OR = { - scope:actor = { + scope:puppet_or_actor = { is_at_war = no gold > 0 } scope:recipient = { - is_imprisoned_by = scope:actor + is_imprisoned_by = scope:puppet_or_actor } } -# scope:actor = { # The HRE doesn't need endless civil wars -# NOT = { -# primary_title = title:e_hre -# } -# } - exists = scope:actor.primary_title.title_capital_county + scope:puppet_or_actor = { # Europa doesn't need endless civil wars + NOT = { + primary_title = title:e_europa + } + } + exists = scope:puppet_or_actor.primary_title.title_capital_county OR = { - scope:actor = { + scope:puppet_or_actor = { any_held_title = { - this = scope:actor.primary_title.title_capital_county.de_jure_liege + this = scope:puppet_or_actor.primary_title.title_capital_county.de_jure_liege } } - scope:actor.primary_title.title_capital_county.de_jure_liege = { + scope:puppet_or_actor.primary_title.title_capital_county.de_jure_liege = { is_title_created = no } } scope:secondary_recipient = { any_sub_realm_county = { - this = scope:actor.primary_title.title_capital_county + this = scope:puppet_or_actor.primary_title.title_capital_county } } NAND = { # Don't retract player vassals tyrannically scope:recipient = { is_ai = no } - scope:actor = { + scope:puppet_or_actor = { NOT = { has_revoke_title_reason = scope:recipient } } } @@ -884,50 +1012,50 @@ retract_vassal_interaction = { # If below domain limit, try to revoke counties in your capital duchy despite tyranny, sometimes modifier = { years_from_game_start >= 3 - scope:actor = { is_at_war = no } - scope:actor = { # The HRE doesn't need endless civil wars + scope:puppet_or_actor = { is_at_war = no } + scope:puppet_or_actor = { # Europa doesn't need endless civil wars NOT = { - primary_title = title:e_hre + primary_title = title:e_europa } } - scope:actor.domain_size < scope:actor.domain_limit - scope:actor.primary_title.tier >= tier_kingdom + scope:puppet_or_actor.domain_size < scope:puppet_or_actor.domain_limit + scope:puppet_or_actor.primary_title.tier >= tier_kingdom trigger_if = { limit = { - scope:actor = { + scope:puppet_or_actor = { domain_size > 3 } } - scope:actor = { + scope:puppet_or_actor = { NOR = { has_trait = generous has_trait = just } } } - exists = scope:actor.primary_title.title_capital_county + exists = scope:puppet_or_actor.primary_title.title_capital_county OR = { - scope:actor.primary_title.title_capital_county.holder = scope:actor # You have your de jure capital already + scope:puppet_or_actor.primary_title.title_capital_county.holder = scope:puppet_or_actor # You have your de jure capital already NOT = { - scope:actor.primary_title.title_capital_county.holder.top_liege = scope:actor.top_liege # Or your De Jure capital isn't in your realm + scope:puppet_or_actor.primary_title.title_capital_county.holder.top_liege = scope:puppet_or_actor.top_liege # Or your De Jure capital isn't in your realm } } scope:secondary_recipient = { primary_title.tier = tier_county any_sub_realm_county = { - de_jure_liege = scope:actor.primary_title.title_capital_county.de_jure_liege # Under the same Duchy as your capital + de_jure_liege = scope:puppet_or_actor.primary_title.title_capital_county.de_jure_liege # Under the same Duchy as your capital } } OR = { # And the capital duchy, if it exists at all AND = { - exists = scope:actor.primary_title.title_capital_county.de_jure_liege.holder - scope:actor.primary_title.title_capital_county.de_jure_liege.holder = scope:actor + exists = scope:puppet_or_actor.primary_title.title_capital_county.de_jure_liege.holder + scope:puppet_or_actor.primary_title.title_capital_county.de_jure_liege.holder = scope:puppet_or_actor } AND = { - exists = scope:actor.primary_title.title_capital_county.de_jure_liege.holder - scope:actor.primary_title.title_capital_county.de_jure_liege.holder.top_liege != scope:actor.top_liege + exists = scope:puppet_or_actor.primary_title.title_capital_county.de_jure_liege.holder + scope:puppet_or_actor.primary_title.title_capital_county.de_jure_liege.holder.top_liege != scope:puppet_or_actor.top_liege } - scope:actor.primary_title.title_capital_county.de_jure_liege = { + scope:puppet_or_actor.primary_title.title_capital_county.de_jure_liege = { is_title_created = no } } @@ -938,37 +1066,37 @@ retract_vassal_interaction = { OR = { # Tyranny tolernance is based on rationality AND = { - scope:actor.ai_rationality < 0 - scope:actor.tyranny <= 15 # Don't go crazy with tyranny, just a bit is fine + scope:puppet_or_actor.ai_rationality < 0 + scope:puppet_or_actor.tyranny <= 15 # Don't go crazy with tyranny, just a bit is fine } AND = { - scope:actor.ai_rationality >= 0 - scope:actor.ai_rationality < 50 - scope:actor.tyranny <= 5 # Don't go crazy with tyranny, just a bit is fine + scope:puppet_or_actor.ai_rationality >= 0 + scope:puppet_or_actor.ai_rationality < 50 + scope:puppet_or_actor.tyranny <= 5 # Don't go crazy with tyranny, just a bit is fine } AND = { - scope:actor.ai_rationality >= 50 - scope:actor.tyranny <= 0 # Don't go crazy with tyranny, just a bit is fine + scope:puppet_or_actor.ai_rationality >= 50 + scope:puppet_or_actor.tyranny <= 0 # Don't go crazy with tyranny, just a bit is fine } AND = { - scope:actor.ai_rationality >= 0 + scope:puppet_or_actor.ai_rationality >= 0 scope:recipient = { - is_imprisoned_by = scope:actor + is_imprisoned_by = scope:puppet_or_actor } - scope:actor = { has_revoke_title_reason = scope:recipient } + scope:puppet_or_actor = { has_revoke_title_reason = scope:recipient } } AND = { - scope:actor.ai_rationality < 0 + scope:puppet_or_actor.ai_rationality < 0 scope:recipient = { - is_imprisoned_by = scope:actor + is_imprisoned_by = scope:puppet_or_actor } } } # To do this, the target must be weak or willing in some way OR = { - scope:actor.current_military_strength > scope:recipient.current_military_strength # Must be stronger + scope:puppet_or_actor.current_military_strength > scope:recipient.current_military_strength # Must be stronger scope:recipient = { - is_imprisoned_by = scope:actor + is_imprisoned_by = scope:puppet_or_actor } } scope:recipient = { @@ -977,12 +1105,12 @@ retract_vassal_interaction = { has_trait = content has_trait = trusting has_dread_level_towards = { - target = scope:actor + target = scope:puppet_or_actor level >= 1 } - opinion = { target = scope:actor value >= 40 } - is_imprisoned_by = scope:actor - scope:actor = { has_revoke_title_reason = scope:recipient } + opinion = { target = scope:puppet_or_actor value >= 40 } + is_imprisoned_by = scope:puppet_or_actor + scope:puppet_or_actor = { has_revoke_title_reason = scope:recipient } } } @@ -990,17 +1118,17 @@ retract_vassal_interaction = { } # Always retract preferred capital duchy modifier = { - exists = scope:actor.primary_title.title_capital_county + exists = scope:puppet_or_actor.primary_title.title_capital_county scope:secondary_recipient = { any_sub_realm_duchy = { - this = scope:actor.primary_title.title_capital_county.de_jure_liege + this = scope:puppet_or_actor.primary_title.title_capital_county.de_jure_liege } } NAND = { # Don't retract player vassals tyranically scope:recipient = { is_ai = no } - scope:actor = { + scope:puppet_or_actor = { NOT = { has_revoke_title_reason = scope:recipient } } } @@ -1008,15 +1136,15 @@ retract_vassal_interaction = { } # Retract vassal we're dejure liege of if below domain limit modifier = { - scope:actor = { + scope:puppet_or_actor = { vassal_limit_available > 0 } - scope:secondary_recipient.primary_title.de_jure_liege.holder = scope:actor + scope:secondary_recipient.primary_title.de_jure_liege.holder = scope:puppet_or_actor add = 500 } # Retract non-De Jure vassals from Megadukes (only if a revoke reason is present, so we don't end up in massive tyranny war spirals) modifier = { - scope:actor = { + scope:puppet_or_actor = { has_revoke_title_reason = scope:recipient } scope:recipient = { @@ -1030,7 +1158,7 @@ retract_vassal_interaction = { } # Do not revoke titles from certain characters modifier = { - scope:actor = { + scope:puppet_or_actor = { OR = { has_relation_friend = scope:recipient has_relation_best_friend = scope:recipient @@ -1045,14 +1173,14 @@ retract_vassal_interaction = { modifier = { NOT = { scope:recipient = { - is_imprisoned_by = scope:actor + is_imprisoned_by = scope:puppet_or_actor } } - scope:actor = { + scope:puppet_or_actor = { OR = { gold < minimum_ai_gold_value_for_tyranny_wars AND = { - scope:actor.current_military_strength < scope:recipient.current_military_strength + scope:puppet_or_actor.current_military_strength < scope:recipient.current_military_strength gold < comfortable_ai_gold_value_for_tyranny_wars } } @@ -1072,24 +1200,24 @@ retract_vassal_interaction = { modifier = { # Avoid triggering Tyranny wars mid-war factor = 0 - scope:actor = { + scope:puppet_or_actor = { is_at_war = yes } scope:recipient = { NOT = { - is_imprisoned_by = scope:actor + is_imprisoned_by = scope:puppet_or_actor } } } modifier = { # Avoid triggering Tyranny wars mid-grand activity factor = 0 - scope:actor = { + scope:puppet_or_actor = { has_ongoing_grand_activity_trigger = yes } NOR = { scope:recipient = { - is_imprisoned_by = scope:actor + is_imprisoned_by = scope:puppet_or_actor } scope:recipient = { highest_held_title_tier = tier_barony @@ -1104,15 +1232,19 @@ start_independence_faction_interaction = { category = interaction_category_vassal desc = start_independence_faction_interaction_desc + is_available = { + is_landed = yes + highest_held_title_tier > tier_barony + is_governor = no + is_a_faction_member = no + } + is_shown = { scope:actor != scope:recipient scope:actor = { - highest_held_title_tier > tier_barony liege = scope:recipient - is_a_faction_member = no } scope:recipient = { - is_landed_or_landless_administrative = no NOT = { any_targeting_faction = { faction_type = independence_faction @@ -1147,7 +1279,7 @@ start_independence_faction_interaction = { limit = { is_de_jure_vassal_of_liege_trigger = yes } - stress_impact = { + stress_and_fulfillment_impact = { just = medium_stress_impact_gain } } @@ -1163,14 +1295,16 @@ join_independence_faction_interaction = { category = interaction_category_vassal desc = join_independence_faction_interaction_desc + is_available = { + is_landed = yes + highest_held_title_tier > tier_barony + is_governor = no + is_a_faction_member = no + } + is_shown = { scope:actor != scope:recipient - scope:actor.liege = scope:recipient - scope:actor = { - is_landed_or_landless_administrative = no - is_a_faction_member = no - highest_held_title_tier > tier_barony - } + scope:actor.liege ?= scope:recipient scope:recipient = { highest_held_title_tier > tier_barony any_targeting_faction = { @@ -1219,7 +1353,7 @@ join_independence_faction_interaction = { limit = { is_de_jure_vassal_of_liege_trigger = yes } - stress_impact = { + stress_and_fulfillment_impact = { just = minor_stress_impact_gain } } @@ -1242,15 +1376,18 @@ create_claimant_faction_against_interaction = { special_interaction = create_claimant_faction_against_interaction interface = create_claimant_faction_against + is_available = { + highest_held_title_tier > tier_barony + custom_description = { + text = "faction_can_join_create_in_another_faction" + is_a_faction_member = no + } + } + is_shown = { scope:actor = { NOT = { scope:secondary_actor ?= this } scope:secondary_actor ?= liege - custom_description = { - text = "faction_can_join_create_in_another_faction" - is_a_faction_member = no - } - highest_held_title_tier > tier_barony } } @@ -1277,7 +1414,7 @@ create_claimant_faction_against_interaction = { text = "basic_capable_claimant_found" any_held_title = { any_claimant = { - NOT = { has_trait = incapable } + is_incapable = no } } } @@ -1313,7 +1450,7 @@ create_claimant_faction_against_interaction = { } scope:recipient = { NOT = { is_at_war_with = scope:actor } - NOT = { has_trait = incapable } + is_incapable = no } } scope:secondary_actor = { NOT = { has_strong_hook = scope:actor } } @@ -1321,11 +1458,11 @@ create_claimant_faction_against_interaction = { # Admin vassals can only start and join a claimant faction if the target is independent trigger_if = { limit = { - scope:actor = { government_allows = administrative } + scope:actor = { government_has_mechanic = administrative } } trigger_if = { limit = { - scope:secondary_actor = { government_allows = administrative } + scope:secondary_actor = { government_has_mechanic = administrative } } scope:secondary_actor = { is_independent_ruler = yes } } @@ -1355,7 +1492,7 @@ create_claimant_faction_against_interaction = { trigger_if = { limit = { scope:landed_title = { - holder.faith = { has_doctrine = doctrine_gender_male_dominated } + holder.rite = { rite_has_doctrine = doctrine_gender_male_dominated } any_claimant = { is_male = yes } } } @@ -1364,7 +1501,7 @@ create_claimant_faction_against_interaction = { trigger_else_if = { limit = { scope:landed_title = { - holder.faith = { has_doctrine = doctrine_gender_female_dominated } + holder.rite = { rite_has_doctrine = doctrine_gender_female_dominated } any_claimant = { is_female = yes } } } @@ -1636,15 +1773,22 @@ force_onto_council = { } extra_icon = "gfx/interface/icons/character_interactions/hook_icon.dds" + is_available = { + is_councillor = no + trigger_if = { + limit = { is_ai = yes } + is_councillor = no + top_liege != this + } + liege ?= { + tgp_has_access_to_ministry_trigger = no + } + } + is_shown = { scope:recipient != scope:actor scope:actor = { liege = scope:recipient - NOT = { - is_councillor = yes - } - # Merit based realms cannot force themselves onto the council - they should compete with merit and score instead - NOT = { government_allows = merit } } trigger_if = { @@ -1672,8 +1816,8 @@ force_onto_council = { } NAND = { has_council_position = councillor_court_chaplain - faith = { - has_doctrine_parameter = clerical_appointment_fixed + rite = { + rite_has_parameter = clerical_appointment_fixed } } } @@ -1721,7 +1865,7 @@ force_onto_council = { custom_tooltip = force_onto_council.actor.tt.duration } } - stress_impact = { content = minor_stress_impact_gain } + stress_and_fulfillment_impact = { content = minor_stress_impact_gain } } scope:recipient = { assign_council_task = { @@ -1963,11 +2107,6 @@ force_onto_council = { } } - ai_potential = { - top_liege != this - is_councillor = no - } - ai_targets = { ai_recipients = liege } @@ -2038,7 +2177,7 @@ stop_attacker_vassal_war_interaction = { liege ?= scope:actor highest_held_title_tier > tier_barony any_character_war = { - primary_attacker = scope:recipient + primary_attacker ?= scope:recipient save_temporary_scope_as = target_war } } @@ -2177,7 +2316,7 @@ stop_defender_vassal_war_interaction = { liege ?= scope:actor highest_held_title_tier > tier_barony any_character_war = { - primary_defender = scope:recipient + primary_defender ?= scope:recipient save_temporary_scope_as = target_war } } @@ -2292,9 +2431,9 @@ ask_for_pardon_interaction = { is_shown = { ask_for_pardon_available_trigger = { ACTOR = scope:actor } OR = { - scope:actor.top_liege = scope:recipient + scope:actor.top_liege ?= scope:recipient scope:recipient = { - top_liege = scope:actor.top_liege + top_liege ?= scope:actor.top_liege has_title = title:e_minister_of_justice } } @@ -2421,8 +2560,8 @@ ask_for_pardon_interaction = { REVERSE_NON_HOUSE_TARGET = no } - hidden_effect = { - # Struggle catalysts +# hidden_effect = { +# # Struggle catalysts # if = { # limit = { # fp3_struggle_involves_one_supporter_and_one_detractor = { @@ -2450,7 +2589,7 @@ ask_for_pardon_interaction = { # } # } # } - } +# } } on_auto_accept = { @@ -2533,7 +2672,7 @@ pardon_interaction = { first_valid = { triggered_desc = { trigger = { - scope:actor != scope:recipient.liege + scope:puppet_or_actor != scope:recipient.liege } desc = pardon_interaction_minister_desc } @@ -2541,7 +2680,7 @@ pardon_interaction = { } triggered_desc = { trigger = { - scope:actor = { + scope:puppet_or_actor = { culture = { has_cultural_parameter = pardoning_gives_prestige } @@ -2550,8 +2689,20 @@ pardon_interaction = { desc = pardon_interaction_has_jirga_desc } } + is_available = { + trigger_if = { + limit = { is_ai = yes } + OR = { + ai_vengefulness <= 0 + culture ?= { + has_cultural_parameter = pardoning_gives_loyalty + } + } + } + } + is_shown = { - scope:actor = { + scope:puppet_or_actor ?= { OR = { has_imprisonment_reason = scope:recipient AND = { @@ -2566,64 +2717,43 @@ pardon_interaction = { } scope:recipient = { OR = { - scope:actor = { + scope:puppet_or_actor ?= { has_title = title:e_minister_of_justice - top_liege = scope:recipient.top_liege + top_liege ?= scope:recipient.top_liege } - target_is_liege_or_above = scope:actor + target_is_liege_or_above = scope:puppet_or_actor } } } + + is_valid_showing_failures_only = { + trigger_if = { + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + influence >= pardon_interaction_influence_cost_value + } + } + trigger_if = { + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + treasury >= pardon_interaction_treasury_cost_value + } + } + } + cost = { influence = { - value = 0 + value = pardon_interaction_influence_cost_value if = { - limit = { - scope:actor = { - has_title = title:e_minister_of_justice - NOT = { has_imprisonment_reason = scope:recipient } - } - } - add = { - value = 25 - if = { - limit = { - scope:actor.top_liege = { - has_realm_law = celestial_bureaucracy_0 - } - } - add = 75 - } - else_if = { - limit = { - scope:actor.top_liege = { - has_realm_law = celestial_bureaucracy_1 - } - } - add = 50 - } - else_if = { - limit = { - scope:actor.top_liege = { - has_realm_law = celestial_bureaucracy_2 - } - } - add = 25 - } - } + limit = { scope:is_puppet_action ?= yes } + multiply = 0 } } treasury = { - value = 0 + value = pardon_interaction_treasury_cost_value if = { - limit = { - scope:actor = { - has_title = title:e_minister_of_justice - has_treasury = yes - NOT = { has_imprisonment_reason = scope:recipient } - } - } - add = scope:actor.minor_treasury_value + limit = { scope:is_puppet_action ?= yes } + multiply = 0 } } } @@ -2634,19 +2764,42 @@ pardon_interaction = { scope:recipient = { is_imprisoned = no } - scope:actor = { + scope:puppet_or_actor = { has_title = title:e_minister_of_justice } } on_accept = { + if = { + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + if = { + limit = { pardon_interaction_influence_cost_value > 0 } + change_influence = { + value = { + add = pardon_interaction_influence_cost_value + max = influence + multiply = -1 + } + } + } + if = { + limit = { pardon_interaction_treasury_cost_value > 0 } + remove_treasury = { + value = { + add = pardon_interaction_treasury_cost_value + } + } + } + } + } if = { limit = { - scope:actor = { + scope:puppet_or_actor = { has_title = title:e_minister_of_justice } } - scope:actor = { + scope:puppet_or_actor = { add_merit_if_relevant_effect = { MERIT = minor_merit_value } @@ -2665,7 +2818,7 @@ pardon_interaction = { type = event_toast_effect_neutral title = pardon_interaction_toast_title desc = pardon_interaction_toast_minister - right_icon = scope:actor + right_icon = scope:puppet_or_actor if = { limit = { OR = { @@ -2674,15 +2827,15 @@ pardon_interaction = { CRIMINAL = scope:recipient } } - is_close_or_extended_family_of = scope:actor + is_close_or_extended_family_of = scope:puppet_or_actor } } - scope:actor = { + scope:puppet_or_actor = { change_strife_opinion = massive_strife_gain situation:dynastic_cycle = { trigger_situation_catalyst = { catalyst = catalyst_minister_pardoned_dangerous_criminal - character = scope:actor + character = scope:puppet_or_actor } } } @@ -2699,7 +2852,7 @@ pardon_interaction = { type = event_toast_effect_neutral title = pardon_interaction_toast_title desc = pardon_interaction_toast_minister_liege - right_icon = scope:actor + right_icon = scope:puppet_or_actor left_icon = scope:recipient show_as_tooltip = { if = { @@ -2709,16 +2862,16 @@ pardon_interaction = { CRIMINAL = scope:recipient } scope:recipient = { - is_close_or_extended_family_of = scope:actor + is_close_or_extended_family_of = scope:puppet_or_actor } } } - scope:actor = { + scope:puppet_or_actor = { change_strife_opinion = massive_strife_gain situation:dynastic_cycle = { trigger_situation_catalyst = { catalyst = catalyst_minister_pardoned_dangerous_criminal - character = scope:actor + character = scope:puppet_or_actor } } } @@ -2738,22 +2891,22 @@ pardon_interaction = { type = event_toast_effect_neutral title = pardon_interaction_toast_title desc = pardon_interaction_toast - right_icon = scope:actor + right_icon = scope:puppet_or_actor consume_all_criminal_reasons_effect = { - LIEGE = scope:actor + LIEGE = scope:puppet_or_actor CRIMINAL = scope:recipient } } } } - scope:actor = { - stress_impact = { + scope:puppet_or_actor = { + stress_and_fulfillment_impact = { forgiving = medium_stress_loss } } - scope:actor = { + scope:puppet_or_actor = { if = { limit = { culture = { @@ -2763,12 +2916,12 @@ pardon_interaction = { add_prestige = minor_prestige_gain } - hidden_effect = { - # Struggle catalysts +# hidden_effect = { +# # Struggle catalysts # if = { # limit = { # fp3_struggle_involves_one_supporter_and_one_detractor = { -# FIRST = scope:actor +# FIRST = scope:puppet_or_actor # SECOND = scope:recipient # } # scope:recipient = { @@ -2776,7 +2929,7 @@ pardon_interaction = { # involvement = involved # phase_has_catalyst = catalyst_grants_pardon_supporter_detractor # is_secondary_character_involvement_involved_trigger = { -# CHAR = scope:actor +# CHAR = scope:puppet_or_actor # } # } # } @@ -2790,13 +2943,13 @@ pardon_interaction = { # log_debug_variable_for_persian_struggle_effect = { VAR = concession_catalyst_grants_pardon_supporter_detractor } # } # } - } +# } } scope:recipient = { if = { limit = { - scope:actor = { + scope:puppet_or_actor = { culture = { has_cultural_parameter = pardoning_gives_loyalty } @@ -2804,9 +2957,9 @@ pardon_interaction = { } add_opinion = { modifier = loyal_servant - target = scope:actor + target = scope:puppet_or_actor } - scope:actor = { + scope:puppet_or_actor = { if = { limit = { can_add_hook = { @@ -2823,7 +2976,7 @@ pardon_interaction = { } else = { add_opinion = { - target = scope:actor + target = scope:puppet_or_actor modifier = grateful_opinion opinion = 15 } @@ -2832,7 +2985,7 @@ pardon_interaction = { # If we're a clan this interaction affects unity add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = minor_unity_gain DESC = clan_unity_forgiveness.desc @@ -2840,14 +2993,6 @@ pardon_interaction = { } } - ai_potential = { - OR = { - ai_vengefulness <= 0 - culture = { - has_cultural_parameter = pardoning_gives_loyalty - } - } - } ai_targets = { ai_recipients = vassals } @@ -2870,19 +3015,19 @@ pardon_interaction = { add = 100 scope:recipient = { OR = { - has_relation_friend = scope:actor - has_relation_best_friend = scope:actor - has_relation_lover = scope:actor - has_relation_soulmate = scope:actor - is_primary_heir_of = scope:actor + has_relation_friend = scope:puppet_or_actor + has_relation_best_friend = scope:puppet_or_actor + has_relation_lover = scope:puppet_or_actor + has_relation_soulmate = scope:puppet_or_actor + is_primary_heir_of = scope:puppet_or_actor } } } modifier = { add = 25 - scope:actor = { - scope:actor.ai_vengefulness <= 0 + scope:puppet_or_actor = { + scope:puppet_or_actor.ai_vengefulness <= 0 culture = { has_cultural_parameter = pardoning_gives_loyalty } @@ -2894,7 +3039,7 @@ pardon_interaction = { value = ai_vengefulness multiply = -1 } - scope:actor.ai_vengefulness <= -25 + scope:puppet_or_actor.ai_vengefulness <= -25 } } } @@ -2914,12 +3059,12 @@ vassal_claim_liege_title_interaction = { add = monumental_prestige_value if = { limit = { - scope:actor.prestige_level > scope:recipient.prestige_level + scope:puppet_or_actor.prestige_level > scope:recipient.prestige_level } subtract = { value = major_prestige_value multiply = { - value = scope:actor.prestige_level + value = scope:puppet_or_actor.prestige_level subtract = scope:recipient.prestige_level } desc = higher_prestige_level_than_liege @@ -2927,30 +3072,45 @@ vassal_claim_liege_title_interaction = { } else_if = { limit = { - scope:actor.prestige_level < scope:recipient.prestige_level + scope:puppet_or_actor.prestige_level < scope:recipient.prestige_level } add = { value = major_prestige_value multiply = { value = scope:recipient.prestige_level - subtract = scope:actor.prestige_level + subtract = scope:puppet_or_actor.prestige_level } desc = lower_prestige_level_than_liege } } min = 0 } + if = { + limit = { scope:is_puppet_action ?= yes } + multiply = 0 + } + } + } + + is_available = { + trigger_if = { + limit = { is_ai = yes } + domain_size > 1 + NOR = { + has_trait = content + has_trait = craven + } } } is_shown = { - scope:recipient != scope:actor + scope:recipient != scope:puppet_or_actor - scope:actor = { + scope:puppet_or_actor ?= { is_physically_able_adult = yes } - scope:recipient = scope:actor.liege + scope:recipient = scope:puppet_or_actor.liege scope:recipient = { is_playable_character = yes @@ -2961,7 +3121,7 @@ vassal_claim_liege_title_interaction = { has_title_law = landless_adventurer_succession_law has_title_law = mandala_succession_law } - scope:actor = { + scope:puppet_or_actor ?= { NOT = { has_claim_on = prev } @@ -2971,24 +3131,24 @@ vassal_claim_liege_title_interaction = { } is_highlighted = { - scope:actor.prestige >= vassal_claim_liege_title_interaction_highlight_value + scope:puppet_or_actor.prestige >= vassal_claim_liege_title_interaction_highlight_value } can_be_picked = { -# trigger_if = { + trigger_if = { # limit = { -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # involvement = involved # has_struggle_phase_parameter = powerful_vassal_can_claim_liege_titles # } # } # } -# scope:actor = { is_powerful_vassal_of = scope:recipient } -# } + scope:puppet_or_actor = { is_powerful_vassal_of = scope:recipient } + } trigger_if = { limit = { - scope:actor = { legitimacy_level = 5 } + scope:puppet_or_actor = { legitimacy_level = 5 } } scope:target = { tier >= tier_duchy @@ -3002,9 +3162,9 @@ vassal_claim_liege_title_interaction = { tier > tier_county } OR = { - holder = scope:actor + holder = scope:puppet_or_actor holder = { - target_is_liege_or_above = scope:actor + target_is_liege_or_above = scope:puppet_or_actor } } percent >= 0.15 @@ -3014,7 +3174,7 @@ vassal_claim_liege_title_interaction = { } trigger_if = { limit = { - scope:actor = { legitimacy_level = 4 } + scope:puppet_or_actor = { legitimacy_level = 4 } } scope:target = { tier >= tier_duchy @@ -3028,9 +3188,9 @@ vassal_claim_liege_title_interaction = { tier > tier_county } OR = { - holder = scope:actor + holder = scope:puppet_or_actor holder = { - target_is_liege_or_above = scope:actor + target_is_liege_or_above = scope:puppet_or_actor } } percent >= 0.21 @@ -3040,7 +3200,7 @@ vassal_claim_liege_title_interaction = { } trigger_if = { limit = { - scope:actor = { legitimacy_level = 3 } + scope:puppet_or_actor = { legitimacy_level = 3 } } scope:target = { tier >= tier_duchy @@ -3054,9 +3214,9 @@ vassal_claim_liege_title_interaction = { tier > tier_county } OR = { - holder = scope:actor + holder = scope:puppet_or_actor holder = { - target_is_liege_or_above = scope:actor + target_is_liege_or_above = scope:puppet_or_actor } } percent >= 0.31 @@ -3066,7 +3226,7 @@ vassal_claim_liege_title_interaction = { } trigger_if = { limit = { - scope:actor = { legitimacy_level = 2 } + scope:puppet_or_actor = { legitimacy_level = 2 } } scope:target = { tier >= tier_duchy @@ -3080,9 +3240,9 @@ vassal_claim_liege_title_interaction = { tier > tier_county } OR = { - holder = scope:actor + holder = scope:puppet_or_actor holder = { - target_is_liege_or_above = scope:actor + target_is_liege_or_above = scope:puppet_or_actor } } percent >= 0.41 @@ -3092,7 +3252,7 @@ vassal_claim_liege_title_interaction = { } trigger_if = { limit = { - scope:actor = { + scope:puppet_or_actor = { OR = { legitimacy_level = 1 legitimacy_level = 0 @@ -3112,9 +3272,9 @@ vassal_claim_liege_title_interaction = { tier > tier_county } OR = { - holder = scope:actor + holder = scope:puppet_or_actor holder = { - target_is_liege_or_above = scope:actor + target_is_liege_or_above = scope:puppet_or_actor } } percent >= 0.51 @@ -3125,7 +3285,7 @@ vassal_claim_liege_title_interaction = { custom_description = { NOT = { - scope:actor = { + scope:puppet_or_actor = { has_claim_on = scope:target } } @@ -3161,16 +3321,16 @@ vassal_claim_liege_title_interaction = { scope:recipient = { any_held_title = { title_tier >= county - NOT = { any_claimant = { this = scope:actor } } + NOT = { any_claimant = { this = scope:puppet_or_actor } } } } object = scope:recipient text = "already_have_claims_on_all_titles" } - scope:recipient = { NOT = { has_strong_hook = scope:actor } } + scope:recipient = { NOT = { has_strong_hook = scope:puppet_or_actor } } NOT = { - scope:actor = { + scope:puppet_or_actor = { is_allied_to = scope:recipient } } @@ -3182,9 +3342,9 @@ vassal_claim_liege_title_interaction = { limit = { tier = tier_county OR = { - holder = scope:actor + holder = scope:puppet_or_actor holder = { - target_is_liege_or_above = scope:actor + target_is_liege_or_above = scope:puppet_or_actor } } } @@ -3199,7 +3359,7 @@ vassal_claim_liege_title_interaction = { } on_accept = { - scope:actor = { + scope:puppet_or_actor = { send_interface_toast = { type = event_toast_effect_good title = buy_claim_interaction.message @@ -3207,12 +3367,18 @@ vassal_claim_liege_title_interaction = { right_icon = scope:recipient vassal_claim_liege_title_interaction_effect = yes } + } + notify_puppeteer_of_outcome_effect = { + TYPE = event_toast_effect_good + TITLE = buy_claim_interaction.message + } + scope:actor = { claim_title_achievement_effect = yes } # If we're a clan this interaction affects unity add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = major_unity_loss DESC = clan_unity_title_claim.desc @@ -3234,42 +3400,34 @@ vassal_claim_liege_title_interaction = { hegemony = 0 } - ai_potential = { - domain_size > 1 - NOR = { - has_trait = content - has_trait = craven - } - } - ai_will_do = { base = 25 ai_value_modifier = { - who = scope:actor + who = scope:puppet_or_actor ai_greed = 1 ai_boldness = 0.5 ai_honor = -0.5 } modifier = { - add = scope:actor.ai_zeal - scope:actor = { + add = scope:puppet_or_actor.ai_zeal + scope:puppet_or_actor = { ai_zeal > 0 } - scope:actor.faith != scope:recipient.faith + scope:puppet_or_actor.faith != scope:recipient.faith } modifier = { add = 25 - scope:actor = { + scope:puppet_or_actor = { is_powerful_vassal_of = scope:recipient } } modifier = { add = 50 - scope:actor = { + scope:puppet_or_actor = { opinion = { target = scope:recipient value <= 0 @@ -3281,8 +3439,8 @@ vassal_claim_liege_title_interaction = { add = 25 scope:recipient = { OR = { - has_relation_rival = scope:actor - has_relation_nemesis = scope:actor + has_relation_rival = scope:puppet_or_actor + has_relation_nemesis = scope:puppet_or_actor } } } @@ -3290,13 +3448,13 @@ vassal_claim_liege_title_interaction = { modifier = { add = -15 scope:recipient = { - has_relation_lover = scope:actor + has_relation_lover = scope:puppet_or_actor } } # Agenda impact # modifier = { -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # involvement = involved # is_struggle_type = iberian_struggle @@ -3306,7 +3464,7 @@ vassal_claim_liege_title_interaction = { # value = 0 # if = { # limit = { -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # phase_has_catalyst = catalyst_gain_claim_on_title_fp2 # } @@ -3317,7 +3475,7 @@ vassal_claim_liege_title_interaction = { # } # else_if = { # limit = { -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # phase_has_catalyst = catalyst_gain_claim_on_title_fp2 # } @@ -3327,9 +3485,9 @@ vassal_claim_liege_title_interaction = { # } # } # } -# + # modifier = { -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # involvement = involved # is_struggle_type = persian_struggle @@ -3339,7 +3497,7 @@ vassal_claim_liege_title_interaction = { # value = 0 # if = { # limit = { -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # phase_has_catalyst = catalyst_gain_claim_on_title_fp3 # } @@ -3350,7 +3508,7 @@ vassal_claim_liege_title_interaction = { # } # else_if = { # limit = { -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # phase_has_catalyst = catalyst_gain_claim_on_title_fp3 # } @@ -3363,7 +3521,7 @@ vassal_claim_liege_title_interaction = { modifier = { factor = 0.25 - scope:actor = { + scope:puppet_or_actor = { ai_greed < 100 opinion = { target = scope:recipient @@ -3374,7 +3532,7 @@ vassal_claim_liege_title_interaction = { modifier = { factor = 0 - scope:actor = { + scope:puppet_or_actor = { ai_greed < 100 opinion = { target = scope:recipient @@ -3385,7 +3543,7 @@ vassal_claim_liege_title_interaction = { modifier = { add = -25 - scope:actor = { + scope:puppet_or_actor = { has_dread_level_towards = { target = scope:recipient level = 1 @@ -3395,7 +3553,7 @@ vassal_claim_liege_title_interaction = { modifier = { factor = 0 - scope:actor = { + scope:puppet_or_actor = { has_dread_level_towards = { target = scope:recipient level = 2 @@ -3407,9 +3565,9 @@ vassal_claim_liege_title_interaction = { factor = 0 scope:recipient = { OR = { - has_relation_friend = scope:actor - has_relation_best_friend = scope:actor - has_relation_soulmate = scope:actor + has_relation_friend = scope:puppet_or_actor + has_relation_best_friend = scope:puppet_or_actor + has_relation_soulmate = scope:puppet_or_actor } } } @@ -3424,30 +3582,38 @@ give_vassal_directive_interaction = { auto_accept = yes + is_available = { + trigger_if = { + limit = { is_ai = yes } + government_has_mechanic = administrative + } + } + is_shown = { + exists = scope:puppet_or_actor scope:recipient = { trigger_if = { limit = { - scope:actor = { government_allows = administrative } + scope:puppet_or_actor ?= { government_has_mechanic = administrative } } - is_vassal_or_below_of = scope:actor + is_vassal_or_below_of = scope:puppet_or_actor } trigger_else = { - is_vassal_of = scope:actor + is_vassal_of = scope:puppet_or_actor } is_landed = yes - NOT = { government_has_flag = government_is_true_herder } + NOT = { government_has_flag = government_is_herder } highest_held_title_tier >= tier_county is_ai = yes } } is_valid = { - vassal_follows_directive_trigger = { VASSAL = scope:recipient LIEGE = scope:actor } + vassal_follows_directive_trigger = { VASSAL = scope:recipient LIEGE = scope:puppet_or_actor } } is_valid_showing_failures_only = { - vassal_follows_directive_valid_trigger = { VASSAL = scope:recipient LIEGE = scope:actor } + vassal_follows_directive_valid_trigger = { VASSAL = scope:recipient LIEGE = scope:puppet_or_actor } scope:recipient = { is_physically_able = yes } } @@ -3455,7 +3621,7 @@ give_vassal_directive_interaction = { flag = improve_development is_shown = { scope:recipient = { - government_allows = administrative + government_has_mechanic = administrative } } is_valid = { @@ -3469,7 +3635,7 @@ give_vassal_directive_interaction = { flag = train_commanders is_shown = { scope:recipient = { - government_allows = administrative + government_has_mechanic = administrative } } is_valid = { @@ -3480,7 +3646,7 @@ give_vassal_directive_interaction = { flag = build_maa is_shown = { scope:recipient = { - government_allows = administrative + government_has_mechanic = administrative } } is_valid = { @@ -3643,20 +3809,20 @@ give_vassal_directive_interaction = { custom_tooltip = { text = has_any_directive scope:recipient = { - OR = { - has_character_flag = vassal_directive_improve_development - has_character_flag = vassal_directive_train_commanders - has_character_flag = vassal_directive_build_maa - has_character_flag = vassal_directive_convert_faith - has_character_flag = vassal_directive_convert_culture - has_character_flag = vassal_directive_improve_cultural_acceptance - has_character_flag = vassal_directive_building_focus_fortification - has_character_flag = vassal_directive_building_focus_military - has_character_flag = vassal_directive_building_focus_economy - has_character_flag = vassal_directive_manage_fertility - has_character_flag = vassal_directive_explore_cultures - has_character_flag = vassal_directive_raid_innovation_intent - has_character_flag = vassal_directive_raid_herd_intent + has_variable = { + name = vassal_directive_improve_development + name = vassal_directive_train_commanders + name = vassal_directive_build_maa + name = vassal_directive_convert_faith + name = vassal_directive_convert_culture + name = vassal_directive_improve_cultural_acceptance + name = vassal_directive_building_focus_fortification + name = vassal_directive_building_focus_military + name = vassal_directive_building_focus_economy + name = vassal_directive_manage_fertility + name = vassal_directive_explore_cultures + name = vassal_directive_raid_innovation_intent + name = vassal_directive_raid_herd_intent } } } @@ -3667,20 +3833,20 @@ give_vassal_directive_interaction = { scope:recipient = { if = { limit = { - OR = { - has_character_flag = vassal_directive_improve_development - has_character_flag = vassal_directive_train_commanders - has_character_flag = vassal_directive_build_maa - has_character_flag = vassal_directive_convert_faith - has_character_flag = vassal_directive_convert_culture - has_character_flag = vassal_directive_improve_cultural_acceptance - has_character_flag = vassal_directive_building_focus_fortification - has_character_flag = vassal_directive_building_focus_military - has_character_flag = vassal_directive_building_focus_economy - has_character_flag = vassal_directive_manage_fertility - has_character_flag = vassal_directive_explore_cultures - has_character_flag = vassal_directive_raid_innovation_intent - has_character_flag = vassal_directive_raid_herd_intent + has_variable = { + name = vassal_directive_improve_development + name = vassal_directive_train_commanders + name = vassal_directive_build_maa + name = vassal_directive_convert_faith + name = vassal_directive_convert_culture + name = vassal_directive_improve_cultural_acceptance + name = vassal_directive_building_focus_fortification + name = vassal_directive_building_focus_military + name = vassal_directive_building_focus_economy + name = vassal_directive_manage_fertility + name = vassal_directive_explore_cultures + name = vassal_directive_raid_innovation_intent + name = vassal_directive_raid_herd_intent } } custom_tooltip = { @@ -3802,9 +3968,6 @@ give_vassal_directive_interaction = { } } - ai_potential = { - government_allows = administrative - } ai_targets = { ai_recipients = vassals } @@ -3823,9 +3986,9 @@ give_vassal_directive_interaction = { add = 100 scope:improve_development ?= yes scope:recipient = { - NOR = { - has_character_flag = vassal_directive_building_focus_economy - has_character_flag = vassal_directive_improve_development + has_none_of_variables = { + name = vassal_directive_building_focus_economy + name = vassal_directive_improve_development } OR = { vassal_contract_has_flag = admin_theme_civilian @@ -3838,9 +4001,9 @@ give_vassal_directive_interaction = { add = 100 scope:building_focus_economy ?= yes scope:recipient = { - NOR = { - has_character_flag = vassal_directive_building_focus_economy - has_character_flag = vassal_directive_improve_development + has_none_of_variables = { + name = vassal_directive_building_focus_economy + name = vassal_directive_improve_development } OR = { vassal_contract_has_flag = admin_theme_civilian @@ -3853,9 +4016,9 @@ give_vassal_directive_interaction = { add = 100 scope:building_focus_fortification ?= yes scope:recipient = { - NOR = { - has_character_flag = vassal_directive_building_focus_fortification - has_character_flag = vassal_directive_build_maa + has_none_of_variables = { + name = vassal_directive_building_focus_fortification + name = vassal_directive_build_maa } vassal_contract_has_flag = admin_theme_frontier } @@ -3865,10 +4028,10 @@ give_vassal_directive_interaction = { add = 100 scope:build_maa ?= yes scope:recipient = { - NOR = { - has_character_flag = vassal_directive_building_focus_fortification - has_character_flag = vassal_directive_building_focus_military - has_character_flag = vassal_directive_build_maa + has_none_of_variables = { + name = vassal_directive_building_focus_fortification + name = vassal_directive_building_focus_military + name = vassal_directive_build_maa } OR = { vassal_contract_has_flag = admin_theme_military @@ -3881,9 +4044,9 @@ give_vassal_directive_interaction = { add = 100 scope:building_focus_military ?= yes scope:recipient = { - NOR = { - has_character_flag = vassal_directive_building_focus_military - has_character_flag = vassal_directive_build_maa + has_none_of_variables = { + name = vassal_directive_building_focus_military + name = vassal_directive_build_maa } OR = { vassal_contract_has_flag = admin_theme_military @@ -3902,6 +4065,7 @@ request_court_position = { icon = seneschal_court_position desc = request_court_position_desc + notification_text = request_court_position_notification special_interaction = request_court_position interface = court_task_interaction @@ -4023,3 +4187,4 @@ grant_court_position = { auto_accept = yes } + diff --git a/common/character_interactions/00_war.txt b/common/character_interactions/00_war.txt index 4b2e12706..2d3f82425 100644 --- a/common/character_interactions/00_war.txt +++ b/common/character_interactions/00_war.txt @@ -3,18 +3,20 @@ common_interaction = yes special_interaction = declare_war_interaction interface = declare_war - interface_priority = 70 + interface_priority = 80 popup_on_receive = yes pause_on_receive = no # this is handled by the interface instead desc = declare_war_desc is_shown = { + scope:recipient != scope:puppet_or_actor + # Only differs from puppet_or_actor on puppet actions; a puppet cannot be ordered to attack their own puppeteer scope:recipient != scope:actor scope:recipient = { is_playable_character = yes } - scope:actor = { + scope:puppet_or_actor ?= { NOT = { is_at_war_with = scope:recipient } @@ -22,228 +24,18 @@ } is_valid_showing_failures_only = { - scope:actor = { - custom_tooltip = { - text = sworn_peace_tt - NOT = { has_character_flag = sworn_peace } - } - NOT = { has_trait = incapable } - can_attack_in_hierarchy = scope:recipient + scope:puppet_or_actor = { trigger_if = { - limit = { - NOT = { - government_has_flag = can_start_war_with_raised_troops - } - } - NOT = { - has_raised_armies = yes + limit = { government_has_flag = government_is_theocracy } + custom_tooltip = { + text = theocratic_government_war_restriction + has_any_display_cb_on = scope:recipient } } trigger_else = { - custom_description = { - text = army_blocks_defender_army - NOT = { - any_army = { - location.county.holder ?= scope:recipient - } - } - } - } - has_any_display_cb_on = scope:recipient - NOT = { - is_allied_in_war = scope:recipient - } - custom_description = { - text = "is_not_bankrupt" - is_in_debt = no - } - NOT = { - custom_description = { - text = "is_in_an_activity" - exists = involved_activity - } - } - trigger_if = { - limit = { - culture = { has_cultural_parameter = cannot_attack_allies } - } - NOT = { - is_allied_to = scope:recipient - } - } - trigger_if = { - limit = { - culture = { has_cultural_parameter = cannot_attack_truces } - } - NOT = { - has_truce = scope:recipient - } - } - is_imprisoned = no - trigger_if = { - limit = { - has_variable_list = subjugation_offer_under_consideration - } - custom_description = { - text = is_not_considering_offer_of_subjugation - NOT = { - is_target_in_variable_list = { - name = subjugation_offer_under_consideration - target = scope:recipient - } - } - } - } - trigger_if = { - limit = { - has_realm_law = japanese_bureaucracy_3 - this != top_liege - } - custom_tooltip = { - text = non_admin_vassal_japanese_bureaucracy_3 - government_allows = administrative - } - } - } - scope:recipient = { - custom_tooltip = { - text = is_a_herder_recipient_tt - NOT = { government_has_flag = government_is_true_herder } # herders can't fight - } - NOT = { is_tributary_of_suzerain_or_above = scope:actor } # can't fight your tributaries or your tributaries' tributaries - NOT = { has_strong_hook = scope:actor } - trigger_if = { - limit = { is_imprisoned = yes } - NOT = { - imprisoner = scope:actor - } - } - } - scope:actor = { - trigger_if = { - limit = { - NOT = { government_allows = administrative } - liege ?= { - has_realm_law_flag = vassal_all_wars_banned_permanent - this != scope:actor - } - } - custom_tooltip = { - text = admin_all_vassal_wars_banned - always = no - } - } - trigger_if = { - limit = { - government_allows = administrative - top_liege = scope:recipient.top_liege - scope:recipient = { government_allows = administrative } - top_liege != scope:recipient - NOT = { - top_participant_group:dynastic_cycle ?= { - has_participant_group_parameter = dynastic_cycle_vassal_internal_wars_allowed - } - } - } - custom_tooltip = { - text = admin_cannot_declare_internal_wars - always = no - } - } - trigger_if = { # Admin - Laws only allow frontier and naval themes to declare war - limit = { - government_allows = administrative - top_liege != this - top_liege = { - this != scope:recipient.top_liege - has_realm_law_flag = admin_vassal_wars_restricted - } - } - custom_tooltip = { - text = admin_all_vassal_wars_banned - OR = { - vassal_contract_has_flag = admin_theme_frontier - vassal_contract_has_flag = admin_theme_naval - } - } - } - trigger_if = { # Admin - Laws only allow frontier and naval themes to declare war IF they have permission - limit = { - government_allows = administrative - OR = { - vassal_contract_has_flag = admin_theme_frontier - vassal_contract_has_flag = admin_theme_naval - } - top_liege = { - this != scope:recipient.top_liege - has_realm_law_flag = admin_vassal_wars_permission_only - NOT = { has_realm_law_flag = admin_vassal_wars_banned } - } - } - custom_tooltip = { - text = admin_vassal_wars_permission_only_desc - has_variable = admin_permission_to_declare_war - } - } - trigger_if = { # Admin - Laws prevent all vassals from declaring war - limit = { - government_allows = administrative - OR = { - vassal_contract_has_flag = admin_theme_frontier - vassal_contract_has_flag = admin_theme_naval - } - top_liege = { - this != scope:recipient.top_liege - has_realm_law_flag = admin_vassal_wars_banned - } - } - custom_tooltip = { - text = admin_all_vassal_wars_banned - always = no - } - } - trigger_if = { - limit = { - scope:recipient = { - OR = { - has_subject_contract_group = tributary_celestial - has_subject_contract_group = tributary_hegemonic - } - } - is_independent_ruler = no # to avoid duplicating tooltips already applying to the top_liege - } - NOT = { - scope:recipient = { - is_tributary_of = scope:actor.top_liege - } - } - } - } - scope:actor = { - trigger_if = { - limit = { has_government = landless_adventurer_government } - custom_tooltip = { - text = camp_located_in_defender_realm.tt - domicile.domicile_location.county.holder = { - NOR = { - this = scope:recipient - any_liege_or_above = { this = scope:recipient } - } - } - } - } - } - trigger_if = { - limit = { - scope:actor = { - is_confederation_member = yes - } - } - NOT = { - scope:recipient = { - is_member_of_confederation = scope:actor.confederation - } + has_any_display_cb_on = scope:recipient } + allows_declaring_war_against_target_trigger = { TARGET = scope:recipient } } } @@ -251,11 +43,11 @@ custom_description = { text = "declare_war_hook_on_liege" OR = { - war_declarer_needs_hook_on_liege = no + scope:puppet_or_actor = { war_declarer_needs_hook_on_liege = no } always = scope:hook } } - scope:actor = { + scope:puppet_or_actor = { NOR = { is_at_war_with = scope:recipient custom_description = { #A vassal cannot go to war against someone their Liege is already at war with @@ -272,10 +64,10 @@ send_options_exclusive = no send_option = { is_shown = { - war_declarer_needs_hook_on_liege = yes + scope:puppet_or_actor = { war_declarer_needs_hook_on_liege = yes } } is_valid = { - scope:actor = { + scope:puppet_or_actor = { has_usable_hook = liege } } @@ -284,20 +76,20 @@ can_invalidate_interaction = yes } should_use_extra_icon = { - war_declarer_needs_hook_on_liege = yes - scope:actor = { has_usable_hook = liege } + scope:puppet_or_actor = { war_declarer_needs_hook_on_liege = yes } + scope:puppet_or_actor = { has_usable_hook = liege } } extra_icon = "gfx/interface/icons/character_interactions/hook_icon.dds" - + on_accept = { - scope:actor = { + scope:puppet_or_actor = { #Feedback! hidden_effect = { send_interface_toast = { type = event_toast_effect_neutral title = declare_war_interaction_notification - left_icon = scope:actor + left_icon = scope:puppet_or_actor right_icon = scope:recipient custom_tooltip = declare_war_interaction_notification_tooltip @@ -338,7 +130,7 @@ NOT = { has_relation_rival = scope:recipient } #To enable really strange love stories any_character_war = { casus_belli = { - primary_attacker = scope:actor + primary_attacker = scope:puppet_or_actor primary_defender = scope:recipient any_target_title = { } } @@ -358,7 +150,7 @@ limit = { any_character_war = { primary_attacker = { - is_vassal_or_below_of = scope:actor + is_vassal_or_below_of = scope:puppet_or_actor trigger_if = { #Ai should never invalidate a player's war! limit = { this = { is_ai = no } @@ -373,7 +165,7 @@ every_character_war = { limit = { primary_attacker = { - is_vassal_or_below_of = scope:actor + is_vassal_or_below_of = scope:puppet_or_actor trigger_if = { #Ai should never invalidate a player's war! limit = { this = { is_ai = no } @@ -397,7 +189,7 @@ save_temporary_scope_as = attacked_vassal any_character_war = { casus_belli = { - primary_attacker = scope:actor + primary_attacker = scope:puppet_or_actor primary_defender = scope:recipient any_target_title = { holder = { @@ -416,7 +208,7 @@ limit = { any_character_war = { casus_belli = { - primary_attacker = scope:actor + primary_attacker = scope:puppet_or_actor primary_defender = scope:recipient any_target_title = { holder = { @@ -433,7 +225,7 @@ type = msg_war_declared_on_liege title = declare_war_interaction_notification - left_icon = scope:actor + left_icon = scope:puppet_or_actor right_icon = scope:recipient custom_tooltip = declare_war_interaction_notification_tooltip @@ -441,7 +233,7 @@ } } } - + # If you are admin and had permission to start war, spend said permission if = { limit = { @@ -450,8 +242,26 @@ remove_variable = admin_permission_to_declare_war } } + hidden_effect = { + if = { + limit = { + scope:is_puppet_action ?= yes + } + scope:actor = { + send_interface_toast = { + type = event_toast_effect_neutral + title = declare_war_interaction_notification + + left_icon = scope:puppet_or_actor + right_icon = scope:recipient + + custom_tooltip = declare_war_interaction_notification_tooltip + } + } + } + } } - + auto_accept = yes } @@ -540,25 +350,24 @@ end_war_attacker_victory_interaction = { } on_accept = { - casus_belli = { - primary_attacker = { - save_scope_as = attacker_winner + scope:war ?= { + casus_belli = { + primary_attacker = { + save_scope_as = attacker_winner + set_signature_weapon_effect = yes + } + primary_defender = { + save_scope_as = defender_loser + } } - primary_defender = { - save_scope_as = defender_loser + if = { + limit = { + NOT = { using_cb = fp3_free_house_member_cb } + } + release_prisoners_of_war_effect = yes } } - if = { - limit = { - scope:war ?= { - using_cb = fp3_free_house_member_cb - } - } - } - else = { - release_prisoners_of_war_effect = yes - } # Hostages # Save scopes for clarity @@ -575,7 +384,7 @@ end_war_attacker_victory_interaction = { if = { limit = { exists = scope:secondary_actor - scope:recipient = { is_landed_or_landless_administrative = yes } + scope:recipient = { is_landed_or_landless_administrative_or_theocratic = yes } } hostage_depart_effect = { HOSTAGE = scope:secondary_actor @@ -586,7 +395,7 @@ end_war_attacker_victory_interaction = { if = { limit = { exists = scope:secondary_recipient - scope:actor = { is_landed_or_landless_administrative = yes } + scope:actor = { is_landed_or_landless_administrative_or_theocratic = yes } } hostage_depart_effect = { HOSTAGE = scope:secondary_recipient @@ -641,74 +450,14 @@ end_war_attacker_victory_interaction = { #Special bookmark event for Aella of Northumbria bookmark_867_northmen_aellas_capture_war_imprisonment_effect = yes - end_war = attacker + scope:war ?= { + end_war = attacker + } } on_decline = { } - ai_potential = { - is_at_war = yes - any_character_war = { - is_war_leader = root - OR = { - attacker_war_score >= 100 - AND = { - OR = { - attacker_war_score >= 90 - AND = { - attacker_war_score >= 80 - root = { - dynasty ?= { has_dynasty_perk = mpo_nomad_legacy_3 } - } - } - } - root = { - has_perk = peacemaker_perk - } - primary_defender = { - is_ai = yes - } - } - AND = { - OR = { - attacker_war_score >= 90 - AND = { - attacker_war_score >= 80 - root = { - has_perk = peacemaker_perk - } - } - } - root = { - dynasty ?= { has_dynasty_perk = mpo_nomad_legacy_3 } - } - primary_defender = { - is_ai = yes - } - } - #SENT A SCARY SEVERED HEAD AAAAHHH - AND = { - attacker_war_score >= 70 - primary_defender = { - is_ai = yes - save_temporary_scope_as = defender - } - root = { - has_variable = peace_acceptance_head_scare - var:peace_acceptance_head_scare = { - this = scope:defender - } - } - } - primary_defender = { - is_ai = yes - has_variable = conqueror - } - } - } - } - ai_will_do = { base = 0 @@ -882,8 +631,8 @@ end_war_attacker_victory_interaction = { } # This is a bit of a hidden modifier, only used to make sure we get the right icon when you force it through at 100 war score, and the opponent has more realm left modifier = { - scope:war = { - attacker_war_score >= 100 + scope:war = { + attacker_war_score >= 100 OR = { exists = scope:secondary_actor exists = scope:secondary_recipient @@ -917,7 +666,7 @@ end_war_attacker_victory_interaction = { } AND = { scope:recipient = { is_ai = yes } - primary_attacker = scope:recipient + scope:war.casus_belli.primary_attacker ?= scope:recipient } scope:war.casus_belli = { # Conquerors know when to fold primary_attacker = { @@ -967,6 +716,71 @@ end_war_attacker_victory_interaction = { } } + is_available = { + trigger_if = { + limit = { is_ai = yes } + is_at_war = yes + any_character_war = { + is_war_leader = root + OR = { + attacker_war_score >= 100 + AND = { + primary_defender ?= { + is_ai = yes + } + OR = { + attacker_war_score >= 90 + AND = { + root = { + dynasty ?= { has_dynasty_perk = mpo_nomad_legacy_3 } + } + attacker_war_score >= 80 + } + } + root = { + has_perk = peacemaker_perk + } + } + AND = { + primary_defender ?= { + is_ai = yes + } + root = { + dynasty ?= { has_dynasty_perk = mpo_nomad_legacy_3 } + } + OR = { + attacker_war_score >= 90 + AND = { + root = { + has_perk = peacemaker_perk + } + attacker_war_score >= 80 + } + } + } + #SENT A SCARY SEVERED HEAD AAAAHHH + AND = { + primary_defender ?= { + save_temporary_scope_as = defender + is_ai = yes + } + attacker_war_score >= 70 + root = { + has_variable = peace_acceptance_head_scare + var:peace_acceptance_head_scare ?= { + this = scope:defender + } + } + } + primary_defender ?= { + is_ai = yes + has_variable = conqueror + } + } + } + } + } + is_valid_showing_failures_only = { scope:war = { has_valid_casus_belli = yes @@ -1038,7 +852,7 @@ end_war_attacker_white_peace_interaction = { desc = end_war_attacker_white_peace_defender_desc } } - + redirect = { # secondary recipient is always set, so we need to clear it # if can_send condition depends on the scope being empty @@ -1086,24 +900,21 @@ end_war_attacker_white_peace_interaction = { } on_accept = { - casus_belli = { - primary_attacker = { - save_scope_as = attacker_white_peace - } - primary_defender = { - save_scope_as = defender_white_peace - } - } - - if = { - limit = { - scope:war ?= { - using_cb = fp3_free_house_member_cb + scope:war ?= { + casus_belli = { + primary_attacker = { + save_scope_as = attacker_white_peace + } + primary_defender = { + save_scope_as = defender_white_peace } } - } - else = { - release_prisoners_of_war_effect = yes + if = { + limit = { + NOT = { using_cb = fp3_free_house_member_cb } + } + release_prisoners_of_war_effect = yes + } } # Hostages @@ -1121,7 +932,7 @@ end_war_attacker_white_peace_interaction = { if = { limit = { exists = scope:secondary_actor - scope:recipient = { is_landed_or_landless_administrative = yes } + scope:recipient = { is_landed_or_landless_administrative_or_theocratic = yes } } hostage_depart_effect = { HOSTAGE = scope:secondary_actor @@ -1132,7 +943,7 @@ end_war_attacker_white_peace_interaction = { if = { limit = { exists = scope:secondary_recipient - scope:actor = { is_landed_or_landless_administrative = yes } + scope:actor = { is_landed_or_landless_administrative_or_theocratic = yes } } hostage_depart_effect = { HOSTAGE = scope:secondary_recipient @@ -1184,50 +995,14 @@ end_war_attacker_white_peace_interaction = { } } - end_war = white_peace + scope:war ?= { + end_war = white_peace + } } on_decline = { } - ai_potential = { - any_character_war = { - count >= 1 - casus_belli = { - OR = { - primary_attacker = root - primary_defender = root - } - } - } - - trigger_if = { - limit = { - exists = scope:war - } - NOR = { # Don't send inane white peace offers to the player - scope:war = { - casus_belli = { - primary_defender = root - primary_attacker = { - is_ai = no - } - } - attacker_war_score >= 10 - } - scope:war = { - casus_belli = { - primary_attacker = root - primary_defender = { - is_ai = no - } - } - defender_war_score >= 70 - } - } - } - } - ai_will_do = { base = 0 @@ -1642,7 +1417,7 @@ end_war_attacker_white_peace_interaction = { } } add = 10 - + desc = CONCERN_ABOUT_OTHER_WARS } @@ -1723,7 +1498,7 @@ end_war_attacker_white_peace_interaction = { } } add = peacemaker_value - + desc = "PEACEMAKER_PERK_MODIFIER" } modifier = { @@ -1734,20 +1509,20 @@ end_war_attacker_white_peace_interaction = { } } add = peacemaker_value - + desc = "PEACEMAKER_PERK_MODIFIER" } modifier = { trigger = { scope:war.casus_belli = { primary_defender = scope:recipient - primary_attacker = { + primary_attacker = { dynasty ?= { has_dynasty_perk = mpo_nomad_legacy_3 } } } } add = 10 - + desc = "NOMAD_LEGACY_PERK_MODIFIER" } modifier = { @@ -1760,7 +1535,7 @@ end_war_attacker_white_peace_interaction = { } } add = 10 - + desc = "NOMAD_LEGACY_PERK_MODIFIER" } modifier = { @@ -1780,7 +1555,7 @@ end_war_attacker_white_peace_interaction = { } } add = 30 - + desc = "COWED_BY_SEVERED_HEAD_MODIFIER" } modifier = { @@ -1800,7 +1575,7 @@ end_war_attacker_white_peace_interaction = { } } add = 30 - + desc = "COWED_BY_SEVERED_HEAD_MODIFIER" } @@ -1813,7 +1588,7 @@ end_war_attacker_white_peace_interaction = { } } add = 10 - + desc = "TRADITION_BONUS_WHITE_PEACE" } modifier = { @@ -1824,7 +1599,7 @@ end_war_attacker_white_peace_interaction = { } } add = 10 - + desc = "TRADITION_BONUS_WHITE_PEACE" } @@ -1909,13 +1684,53 @@ end_war_attacker_white_peace_interaction = { desc = WAR_OVERVIEW_WHITE_PEACE_HOSTAGE_DEMAND_VALUE } } - - is_valid_showing_failures_only = { - exists = scope:war - scope:war = { - has_valid_casus_belli = yes + + is_available = { + trigger_if = { + limit = { is_ai = yes } + any_character_war = { + count >= 1 + casus_belli = { + OR = { + primary_attacker ?= root + primary_defender ?= root + } + } + } + + trigger_if = { + limit = { + exists = scope:war + } + NOR = { # Don't send inane white peace offers to the player + scope:war ?= { + casus_belli ?= { + primary_defender ?= root + primary_attacker ?= { + is_ai = no + } + } + attacker_war_score >= 10 + } + scope:war ?= { + casus_belli ?= { + primary_attacker ?= root + primary_defender ?= { + is_ai = no + } + } + defender_war_score >= 70 + } + } + } + } + } + + is_valid_showing_failures_only = { + scope:war ?= { + has_valid_casus_belli = yes + is_white_peace_possible = yes } - is_white_peace_possible = yes } } @@ -1928,7 +1743,7 @@ end_war_attacker_defeat_interaction = { ai_targets = { ai_recipients = primary_war_enemies } - + ai_frequency_by_tier = { barony = 0 county = 1 @@ -1937,7 +1752,7 @@ end_war_attacker_defeat_interaction = { empire = 1 hegemony = 1 } - + # Depending on who was the attacker, we need to send a different notification message to the recipient. notification_text = { first_valid = { @@ -1956,7 +1771,7 @@ end_war_attacker_defeat_interaction = { desc = end_war_attacker_defeat_defender_desc } } - + populate_actor_list = { scope:actor = { every_close_family_member = { @@ -2004,27 +1819,24 @@ end_war_attacker_defeat_interaction = { } on_accept = { - casus_belli = { - primary_attacker = { - save_scope_as = attacker_loser + scope:war ?= { + casus_belli = { + primary_attacker = { + save_scope_as = attacker_loser + } + primary_defender = { + save_scope_as = defender_winner + set_signature_weapon_effect = yes + } } - primary_defender = { - save_scope_as = defender_winner - set_signature_weapon_effect = yes + if = { + limit = { + NOT = { using_cb = fp3_free_house_member_cb } + } + release_prisoners_of_war_effect = yes } } - if = { - limit = { - scope:war ?= { - using_cb = fp3_free_house_member_cb - } - } - } - else = { - release_prisoners_of_war_effect = yes - } - # Hostages # Save scopes for clarity if = { @@ -2079,7 +1891,7 @@ end_war_attacker_defeat_interaction = { title = war_event.notification_liege_loss.t left_icon = scope:attacker_loser right_icon = scope:defender_winner - custom_tooltip = war_event.1905 + custom_tooltip = war_event.1905 } } } @@ -2098,80 +1910,25 @@ end_war_attacker_defeat_interaction = { title = war_event.notification_liege_win.t left_icon = scope:defender_winner right_icon = scope:attacker_loser - custom_tooltip = war_event.1906 + custom_tooltip = war_event.1906 } } } } } - end_war = defender + scope:war ?= { + end_war = defender + } } - + on_decline = { } - - ai_potential = { - is_at_war = yes - any_character_war = { - is_war_leader = root - OR = { - defender_war_score >= 100 - AND = { - OR = { - attacker_war_score >= 90 - AND = { - attacker_war_score >= 80 - root = { - dynasty ?= { has_dynasty_perk = mpo_nomad_legacy_3 } - } - } - } - root = { - has_perk = peacemaker_perk - } - primary_defender = { - is_ai = yes - } - } - AND = { - OR = { - attacker_war_score >= 90 - AND = { - attacker_war_score >= 80 - root = { - has_perk = peacemaker_perk - } - } - } - root = { - dynasty ?= { has_dynasty_perk = mpo_nomad_legacy_3 } - } - primary_defender = { - is_ai = yes - } - } - AND = { - defender_war_score >= 70 - primary_attacker = { - is_ai = yes - save_temporary_scope_as = attacker - } - root = { - has_variable = peace_acceptance_head_scare - var:peace_acceptance_head_scare = { - this = scope:attacker - } - } - } - } - } - } ai_will_do = { base = 0 - + modifier = { scope:war = { primary_defender = scope:actor @@ -2213,20 +1970,20 @@ end_war_attacker_defeat_interaction = { } } } - } - } + } + } add = 100 } modifier = { scope:war = { primary_attacker = scope:actor defender_war_score >= 100 - days_since_max_war_score >= 180 - } + days_since_max_war_score >= 180 + } add = 100 } } - + ai_accept = { base = -99 @@ -2249,9 +2006,9 @@ end_war_attacker_defeat_interaction = { this != scope:recipient } } - + add = peacemaker_value - + desc = "PEACEMAKER_PERK_MODIFIER" } modifier = { @@ -2261,9 +2018,9 @@ end_war_attacker_defeat_interaction = { NOT = { this = scope:recipient } } } - + add = 10 - + desc = "NOMAD_LEGACY_PERK_MODIFIER" } @@ -2292,9 +2049,9 @@ end_war_attacker_defeat_interaction = { this != scope:recipient } } - + add = 10 - + desc = "TRADITION_BONUS_DEFENSIVE_WARS" } # Hostages @@ -2309,21 +2066,81 @@ end_war_attacker_defeat_interaction = { desc = WAR_OVERVIEW_HOSTAGE_DEMAND_VALUE } } - + auto_accept = { OR = { - scope:war = { + scope:war ?= { defender_war_score >= 100 } AND = { scope:recipient = { is_ai = yes } - primary_defender = scope:recipient + scope:war.casus_belli.primary_defender ?= scope:recipient } } } - + + is_available = { + trigger_if = { + limit = { is_ai = yes } + is_at_war = yes + any_character_war = { + is_war_leader = root + OR = { + defender_war_score >= 100 + AND = { + primary_defender ?= { + is_ai = yes + } + OR = { + attacker_war_score >= 90 + AND = { + root = { + dynasty ?= { has_dynasty_perk = mpo_nomad_legacy_3 } + } + attacker_war_score >= 80 + } + } + root = { + has_perk = peacemaker_perk + } + } + AND = { + primary_defender ?= { + is_ai = yes + } + root = { + dynasty ?= { has_dynasty_perk = mpo_nomad_legacy_3 } + } + OR = { + attacker_war_score >= 90 + AND = { + root = { + has_perk = peacemaker_perk + } + attacker_war_score >= 80 + } + } + } + AND = { + primary_attacker ?= { + save_temporary_scope_as = attacker + is_ai = yes + } + defender_war_score >= 70 + root = { + has_variable = peace_acceptance_head_scare + var:peace_acceptance_head_scare ?= { + this = scope:attacker + } + } + } + } + } + } + } + is_valid_showing_failures_only = { - scope:war = { + scope:war ?= { has_valid_casus_belli = yes } } @@ -2362,10 +2179,10 @@ offer_peace_interaction = { use_diplomatic_range = no is_shown = { - scope:actor = { - is_at_war_with = scope:recipient + scope:puppet_or_actor = { + is_at_war_with = scope:recipient any_character_war = { - is_war_leader = scope:actor + is_war_leader = scope:puppet_or_actor is_participant = scope:recipient } } diff --git a/common/character_interactions/02_ep1_interactions.txt b/common/character_interactions/02_ep1_interactions.txt index a26cdc5f5..af72e7d8b 100644 --- a/common/character_interactions/02_ep1_interactions.txt +++ b/common/character_interactions/02_ep1_interactions.txt @@ -11,6 +11,22 @@ fund_inspiration_interaction = { category = interaction_category_vassal desc = fund_inspiration_interaction_desc + is_available = { + trigger_if = { + limit = { is_ai = yes } + OR = { + has_royal_court = yes + OR = { government_has_flag = government_is_landless_adventurer government_has_flag = government_is_landless_minority } + } + is_at_war = no + gold > ai_inspiration_desired_gold_value + ai_should_focus_on_building_in_their_capital = no + save_temporary_scope_as = inspiration_sponsor + NOT = { has_character_flag = recently_fund_inspiration } + NOT = { has_variable = conqueror } + } + } + is_shown = { scope:recipient = { is_ruler = no @@ -90,15 +106,18 @@ fund_inspiration_interaction = { limit = { scope:recipient.inspiration = { has_inspiration_type = bow_inspiration } } custom_description_no_bullet = { text = bow_inspiration_cost_tt } } + else_if = { + limit = { scope:recipient.inspiration = { has_inspiration_type = religious_artifact_inspiration } } + custom_description_no_bullet = { text = religious_artifact_inspiration_cost_tt } + } # Add a flag on AI to have an extra cooldown of 3 years if = { limit = { scope:actor = { + save_temporary_scope_as = inspiration_sponsor is_ai = yes - NOT = { - gold >= 1000 - } + gold < 1000 OR = { short_term_gold < ai_inspiration_desired_gold_value ai_greed >= 50 @@ -163,18 +182,6 @@ fund_inspiration_interaction = { adult = yes } - ai_potential = { - is_at_war = no - OR = { - has_royal_court = yes - OR = { government_has_flag = government_is_landless_adventurer government_has_flag = government_is_landless_minority } - } - gold > ai_inspiration_desired_gold_value - NOT = { has_character_flag = recently_fund_inspiration } - NOT = { has_variable = conqueror } - ai_should_focus_on_building_in_their_capital = no - } - ai_will_do = { base = 100 @@ -280,9 +287,12 @@ indebt_guest_interaction = { pre_answer_yes_key = ANSWER_WILL_SUCCEED pre_answer_maybe_breakdown_key = ANSWER_SUM_CHANCE - ai_potential = { - # Repeat some is_shown triggers for performance gains. - indebt_guest_interaction_basic_checks_trigger = { ACTOR = this } + is_available = { + trigger_if = { + limit = { is_ai = yes } + # Repeat some is_shown triggers for performance gains. + indebt_guest_interaction_basic_checks_trigger = { ACTOR = this } + } } is_shown = { diff --git a/common/character_interactions/03_fp2_interactions.txt b/common/character_interactions/03_fp2_interactions.txt index b8de40504..0dcf07ede 100644 --- a/common/character_interactions/03_fp2_interactions.txt +++ b/common/character_interactions/03_fp2_interactions.txt @@ -26,14 +26,23 @@ share_known_secrets_interaction = { hegemony = 180 } + is_available = { + trigger_if = { + limit = { is_ai = yes } + #Has access to the appropriate cultural parameter. + dynasty ?= { has_dynasty_perk = fp2_coterie_legacy_4 } + prestige > major_prestige_value + } + } + is_shown = { - scope:actor = { + scope:puppet_or_actor ?= { # Standard check # Has access to the appropriate legacy perk. - dynasty = { has_dynasty_perk = fp2_coterie_legacy_4 } + dynasty ?= { has_dynasty_perk = fp2_coterie_legacy_4 } # they are from the same house - house = scope:recipient.house + house ?= scope:recipient.house } } @@ -41,9 +50,9 @@ share_known_secrets_interaction = { custom_tooltip = { text = share_known_secrets_interaction.tt.no_secrets_to_share # We try to keep the criteria vague to obfuscate things. - scope:actor = { any_known_secret = { } } # Must have a secret to share + scope:puppet_or_actor = { any_known_secret = { } } # Must have a secret to share OR = { - scope:actor = { + scope:puppet_or_actor = { # At least one secret is unknown from recipient any_known_secret = { NOT = { is_known_by = scope:recipient } @@ -52,7 +61,7 @@ share_known_secrets_interaction = { scope:recipient = { # At least one secret is unknown from actor any_known_secret = { - NOT = { is_known_by = scope:actor } + NOT = { is_known_by = scope:puppet_or_actor } } } } @@ -60,15 +69,16 @@ share_known_secrets_interaction = { } desc = share_known_secrets_interaction_desc + notification_text = share_known_secrets_interaction_notification on_accept = { - scope:actor = { + scope:puppet_or_actor = { if = { limit = { scope:recipient = { any_known_secret = { count >= 7 - NOT = { is_known_by = scope:actor } + NOT = { is_known_by = scope:puppet_or_actor } } } } @@ -83,7 +93,7 @@ share_known_secrets_interaction = { scope:recipient = { any_known_secret = { count >= 3 - NOT = { is_known_by = scope:actor } + NOT = { is_known_by = scope:puppet_or_actor } } } } @@ -100,7 +110,7 @@ share_known_secrets_interaction = { } # Stress impact - stress_impact = { + stress_and_fulfillment_impact = { honest = minor_stress_impact_gain just = minor_stress_impact_gain compassionate = minor_stress_impact_gain @@ -110,7 +120,7 @@ share_known_secrets_interaction = { scope:recipient = { if = { limit = { - scope:actor = { + scope:puppet_or_actor = { any_known_secret = { count >= 7 NOT = { is_known_by = scope:recipient } @@ -141,19 +151,19 @@ share_known_secrets_interaction = { } else_if = { limit = { - scope:actor = { + scope:puppet_or_actor = { any_known_secret = { count >= 3 NOT = { is_known_by = scope:recipient } OR = { NOR = { - secret_owner = scope:actor + secret_owner = scope:puppet_or_actor AND = { exists = secret_target - secret_target = scope:actor + secret_target = scope:puppet_or_actor } } - scope:actor = { + scope:puppet_or_actor = { OR = { has_trait = dull has_trait = intellect_bad @@ -179,7 +189,7 @@ share_known_secrets_interaction = { } # Stress impact - stress_impact = { + stress_and_fulfillment_impact = { honest = minor_stress_impact_gain just = minor_stress_impact_gain compassionate = minor_stress_impact_gain @@ -188,12 +198,12 @@ share_known_secrets_interaction = { hidden_effect = { scope:recipient = { save_scope_as = END_TARGET } # This should make the loc work 2-ways, as notifs do not update themselves - scope:actor = { + scope:puppet_or_actor = { if = { # Recipient has no secrets to share limit = { scope:recipient = { any_known_secret = { - NOT = { is_known_by = scope:actor } + NOT = { is_known_by = scope:puppet_or_actor } OR = { NOR = { secret_owner = scope:recipient @@ -220,6 +230,21 @@ share_known_secrets_interaction = { desc = share_known_secrets_interaction_recipient_had_no_secrets left_icon = scope:recipient } + if = { + limit = { + scope:is_puppet_action ?= yes + scope:actor != scope:recipient + } + scope:actor = { + send_interface_message = { + type = event_intrigue_bad_with_text + title = share_known_secrets_interaction_outcome_notif_title_puppeteer + desc = share_known_secrets_interaction_recipient_had_no_secrets_puppeteer + left_icon = scope:recipient + right_icon = scope:puppet_or_actor + } + } + } } else = { # They had secrets to share send_interface_message = { @@ -231,7 +256,7 @@ share_known_secrets_interaction = { scope:recipient = { every_known_secret = { limit = { - NOT = { is_known_by = scope:actor } + NOT = { is_known_by = scope:puppet_or_actor } OR = { NOR = { secret_owner = scope:recipient @@ -249,29 +274,44 @@ share_known_secrets_interaction = { } } } - reveal_to = scope:actor + reveal_to = scope:puppet_or_actor + } + } + } + if = { + limit = { + scope:is_puppet_action ?= yes + scope:actor != scope:recipient + } + scope:actor = { + send_interface_message = { + type = event_intrigue_good_with_text + title = share_known_secrets_interaction_outcome_notif_title_puppeteer + desc = share_known_secrets_interaction_desc_intro_puppeteer + left_icon = scope:recipient + right_icon = scope:puppet_or_actor } } } } } - scope:actor = { save_scope_as = END_TARGET } + scope:puppet_or_actor = { save_scope_as = END_TARGET } scope:recipient = { if = { # actor has no secrets to share limit = { - scope:actor = { + scope:puppet_or_actor = { any_known_secret = { NOT = { is_known_by = scope:recipient } OR = { NOR = { - secret_owner = scope:actor + secret_owner = scope:puppet_or_actor AND = { exists = secret_target - secret_target = scope:actor + secret_target = scope:puppet_or_actor } } - scope:actor = { + scope:puppet_or_actor = { OR = { has_trait = dull has_trait = intellect_bad @@ -287,7 +327,7 @@ share_known_secrets_interaction = { type = event_intrigue_bad_with_text title = share_known_secrets_interaction_outcome_notif_title desc = share_known_secrets_interaction_recipient_had_no_secrets - left_icon = scope:actor + left_icon = scope:puppet_or_actor } } else = { # They had secrets to share @@ -295,21 +335,21 @@ share_known_secrets_interaction = { type = event_intrigue_good_with_text title = share_known_secrets_interaction_outcome_notif_title desc = share_known_secrets_interaction_desc_intro - left_icon = scope:actor + left_icon = scope:puppet_or_actor - scope:actor = { + scope:puppet_or_actor = { every_known_secret = { limit = { NOT = { is_known_by = scope:recipient } OR = { NOR = { - secret_owner = scope:actor + secret_owner = scope:puppet_or_actor AND = { exists = secret_target - secret_target = scope:actor + secret_target = scope:puppet_or_actor } } - scope:actor = { + scope:puppet_or_actor = { OR = { has_trait = dull has_trait = intellect_bad @@ -329,7 +369,7 @@ share_known_secrets_interaction = { # If we're a clan this interaction affects unity add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = minor_unity_loss DESC = clan_unity_secret_sharing.desc @@ -340,40 +380,29 @@ share_known_secrets_interaction = { auto_accept = { custom_description = { text = "spending_hook" - subject = scope:actor + subject = scope:puppet_or_actor object = scope:recipient AND = { always = scope:hook - scope:actor = { has_strong_hook = scope:recipient } + scope:puppet_or_actor = { has_strong_hook = scope:recipient } } } } send_option = { is_valid = { - scope:actor = { has_strong_hook = scope:recipient } + scope:puppet_or_actor = { has_strong_hook = scope:recipient } } flag = hook localization = SCHEME_HOOK } should_use_extra_icon = { - scope:actor = { has_strong_hook = scope:recipient } + scope:puppet_or_actor = { has_strong_hook = scope:recipient } } extra_icon = "gfx/interface/icons/character_interactions/hook_icon.dds" send_options_exclusive = no - ai_potential = { - #Has access to the appropriate cultural parameter. - AND = { - exists = dynasty - dynasty = { has_dynasty_perk = fp2_coterie_legacy_4 } - } - prestige > major_prestige_value - } - - auto_accept = no - ai_accept = { # AI should accept by default base = 10 @@ -458,11 +487,15 @@ propose_best_friendship_interaction = { cooldown = { years = 5 } cooldown_against_recipient = { years = 10 } - is_shown = { - # Scope:actor needs to have a suitable CulTrad. - scope:actor = { - culture = { has_cultural_parameter = may_propose_best_friendship } + is_available = { + culture ?= { has_cultural_parameter = may_propose_best_friendship } + trigger_if = { + limit = { is_ai = yes } + is_imprisoned = no } + } + + is_shown = { # Scope:actor needs to have scope:recipient as a friend. scope:actor = { has_relation_friend = scope:recipient } } @@ -662,8 +695,6 @@ propose_best_friendship_interaction = { desc = PROPOSE_BEST_FRIEND_OPINION_LACKING_CULTURAL_PARAMETER } } - ## Performance-enhancement - ai_potential = { is_imprisoned = no } ai_target_quick_trigger = { adult = yes } ai_targets = { ai_recipients = scripted_relations } ## Frequency @@ -703,11 +734,15 @@ reaffirm_best_friendship_interaction = { cooldown = { years = 5 } cooldown_against_recipient = { years = 10 } - is_shown = { - # Scope:actor needs to have a suitable CulTrad. - scope:actor = { - culture = { has_cultural_parameter = may_propose_best_friendship } + is_available = { + culture ?= { has_cultural_parameter = may_propose_best_friendship } + trigger_if = { + limit = { is_ai = yes } + is_imprisoned = no } + } + + is_shown = { # Scope:actor needs to have scope:recipient for their best friend. scope:actor = { has_relation_best_friend = scope:recipient } # Either friend lacks a strong hook on the other. @@ -840,8 +875,6 @@ reaffirm_best_friendship_interaction = { desc = REAFFIRM_BEST_FRIEND_OPINION_HAS_CULTURAL_PARAMETER } } - ## Performance-enhancement - ai_potential = { is_imprisoned = no } ai_target_quick_trigger = { adult = yes } ai_targets = { ai_recipients = scripted_relations } ## Frequency @@ -881,11 +914,15 @@ synergise_friendship_interaction = { cooldown = { years = 5 } cooldown_against_recipient = { years = 10 } - is_shown = { - # Scope:actor needs to have a suitable CulTrad. - scope:actor = { - culture = { has_cultural_parameter = may_select_friendship_synergy_bonus } + is_available = { + culture ?= { has_cultural_parameter = may_select_friendship_synergy_bonus } + trigger_if = { + limit = { is_ai = yes } + is_imprisoned = no } + } + + is_shown = { # Scope:actor needs to have scope:recipient for their best friend. scope:actor = { has_relation_best_friend = scope:recipient } } @@ -1020,8 +1057,6 @@ synergise_friendship_interaction = { fp2_ritual_best_friendship_interactions_ai_accept_modifier = yes } - ## Performance-enhancement - ai_potential = { is_imprisoned = no } ai_target_quick_trigger = { adult = yes } ai_targets = { ai_recipients = scripted_relations } ## Frequency @@ -1060,16 +1095,27 @@ challenge_to_2p_chess_interaction = { cooldown = { years = 1 } cooldown_against_recipient = { years = 10 } + is_available = { + # Actor needs to either have a CulTrad or be a fan of board games + OR = { + has_perk = befriend_perk + culture ?= { has_cultural_parameter = may_challenge_to_board_games } + has_character_modifier = fp3_chess_playing_monkey_modifier #addition from FP3 + } + # Plus be able to start & continue such a game generally. + bg_can_start_board_game_trigger = yes + trigger_if = { + limit = { is_ai = yes } + OR = { + has_perk = befriend_perk + culture ?= { has_cultural_parameter = may_challenge_to_board_games } + } + is_imprisoned = no + } + } + is_shown = { scope:actor = { - # Actor needs to either have a CulTrad or be a fan of board games - OR = { - culture = { has_cultural_parameter = may_challenge_to_board_games } - has_perk = befriend_perk - has_character_modifier = fp3_chess_playing_monkey_modifier #addition from FP3 - } - # Plus be able to start & continue such a game generally. - bg_can_start_board_game_trigger = yes # ... no, I'm sorry, you can't play yourself at board games. this != scope:recipient } @@ -1895,14 +1941,6 @@ challenge_to_2p_chess_interaction = { add = -30 } } - ## Performance-enhancement - ai_potential = { - OR = { - culture = { has_cultural_parameter = may_challenge_to_board_games } - has_perk = befriend_perk - } - is_imprisoned = no - } ai_target_quick_trigger = { adult = yes } # AI will only challenge adults ai_targets = { ai_recipients = scripted_relations @@ -2028,14 +2066,29 @@ purchase_truce_interaction = { cooldown = { years = 5 } cooldown_against_recipient = { years = 10 } + is_available = { + trigger_if = { + limit = { is_ai = yes } + OR = { + has_perk = defensive_measures_perk + any_character_struggle = { involvement = involved } + } + is_playable_character = yes + is_at_war = no + # Matches the regular minimum triggers. + # Might actually be wurf evaluating the costs. + can_make_expensive_purchase_trigger = { PRICE = purchase_truce_interaction_small_sum } + is_imprisoned = no + } + } + is_shown = { - scope:actor != scope:recipient # Scope:actor needs to either be involved in certain struggle types or else have a specific perk. - scope:actor = { + scope:puppet_or_actor ?= { + this != scope:recipient is_landless_adventurer = no - # If scope:recipient is a nomad and the actor is not, this is always available; otherwise, - # scope:actor needs to either be involved in certain struggle types or else have a specific perk. + # Always available when the recipient is a nomad and the actor is not OR = { AND = { scope:recipient = { government_has_flag = government_is_nomadic } @@ -2050,53 +2103,70 @@ purchase_truce_interaction = { top_liege = scope:recipient.top_liege } } - # Scope:recipient must be landed, and neither over or under scope:actor. + # Scope:recipient must be landed, and neither over or under scope:puppet_or_actor. scope:recipient = { is_playable_character = yes NOR = { - any_liege_or_above = { this = scope:actor } - any_vassal_or_below = { this = scope:actor } + any_liege_or_above = { this = scope:puppet_or_actor } + any_vassal_or_below = { this = scope:puppet_or_actor } } } } is_valid_showing_failures_only = { # Scope:actor must be an available (adult or child). - scope:actor = { - gold >= pt_sum_small_value - is_available = yes + scope:puppet_or_actor = { + trigger_if = { + limit = { + has_personal_tenet_flag = tenet_peace_of_god_personal_truce + } + piety >= pt_sum_small_value + } + trigger_else = { + gold >= pt_sum_small_value + } + is_physically_able = yes } # Scope:recipient must be at least available. - scope:recipient = { is_available = yes } - # Make sure that scope:actor is going into this with a clean, no-recent/active/forbidden hostilities mindset. - scope:actor = { - NOR = { - # Involved characters can't be on opposite sides in an active war. - is_at_war_with = scope:recipient - # Allied characters aren't allowed to do this because it _should_ be redundant. Unless you're planning something. Which you shouldn't announce like that. - is_allied_to = scope:recipient - # And we should just disallow anyone who already has a truce with you, even though I guess you might technically want to replace it. - any_truce_holder = { this = scope:recipient } + scope:recipient = { + is_physically_able = yes + } + # Make sure that scope:puppet_or_actor is going into this with a clean, no-recent/active/forbidden hostilities mindset. + scope:puppet_or_actor = { + # Involved characters can't be on opposite sides in an active war. + custom_tooltip = { + text = purchase_truce_interaction.at_war.tt + NOT = { is_at_war_with = scope:recipient } + } + # Allied characters aren't allowed to do this because it _should_ be redundant. Unless you're planning something. Which you shouldn't announce like that. + custom_tooltip = { + text = purchase_truce_interaction.allied.tt + NOT = { is_allied_to = scope:recipient } + } + # And we should just disallow anyone who already has a truce with you, even though I guess you might technically want to replace it. + custom_tooltip = { + text = purchase_truce_interaction.existing_truce.tt + NOT = { any_truce_holder = { this = scope:recipient } } } } #limit range for landless adventurers trigger_if = { limit = { - scope:actor = { + scope:puppet_or_actor = { has_government = landless_adventurer_government } } #Has to be used instead of diplo range checks in laamp to landed interactions ep3_laamp_diplo_range_trigger = { TARGET = scope:recipient - LAAMP = scope:actor + LAAMP = scope:puppet_or_actor } } } on_accept = { # Notifications with most effects. - scope:actor = { + scope:puppet_or_actor = { send_interface_toast = { type = event_toast_effect_good title = purchase_truce_interaction.accept.actor.tt @@ -2109,19 +2179,33 @@ purchase_truce_interaction = { # Outside of the notification, since we'll send a separate one anyway, we want to point out the catalyst activation (if relevant). show_as_tooltip = { purchase_truce_interaction_activate_catalyst_effect = yes } } + if = { + limit = { + scope:is_puppet_action ?= yes + scope:actor != scope:recipient + } + scope:actor = { + send_interface_toast = { + type = event_toast_effect_good + title = purchase_truce_interaction.accept.actor.tt_puppeteer + left_icon = scope:puppet_or_actor + right_icon = scope:recipient + } + } + } scope:recipient = { send_interface_toast = { type = event_toast_effect_neutral title = purchase_truce_interaction.accept.recipient.tt - left_icon = scope:actor + left_icon = scope:puppet_or_actor show_as_tooltip = { - purchase_truce_interaction_work_out_truce_days_effect = { TARGET = scope:actor } + purchase_truce_interaction_work_out_truce_days_effect = { TARGET = scope:puppet_or_actor } } } } # Then we apply the actual truce. hidden_effect = { - scope:actor = { + scope:puppet_or_actor = { purchase_truce_interaction_work_out_truce_days_effect = { TARGET = scope:recipient } purchase_truce_interaction_activate_catalyst_effect = yes # Variable used for checking if we should apply the "Recently Waged War" ai behavior in ai_acceptance modifiers, specifically in the Offer Vassalization interaction @@ -2151,7 +2235,7 @@ purchase_truce_interaction = { # If we're a clan this interaction affects unity add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = minor_unity_gain DESC = clan_unity_purchased_truce.desc @@ -2161,7 +2245,7 @@ purchase_truce_interaction = { on_decline = { # Scope:actor gains some stress over the whole ordeal. - scope:actor = { + scope:puppet_or_actor = { send_interface_toast = { type = event_toast_effect_bad title = purchase_truce_interaction.decline.actor.tt @@ -2169,14 +2253,28 @@ purchase_truce_interaction = { add_stress = minor_stress_gain } } + if = { + limit = { + scope:is_puppet_action ?= yes + scope:actor != scope:recipient + } + scope:actor = { + send_interface_toast = { + type = event_toast_effect_bad + title = purchase_truce_interaction.decline.actor.tt_puppeteer + left_icon = scope:puppet_or_actor + right_icon = scope:recipient + } + } + } # Scope:actor loses opinion of scope:recipient. scope:recipient = { send_interface_toast = { type = event_toast_effect_neutral title = purchase_truce_interaction.decline.recipient.tt - left_icon = scope:actor + left_icon = scope:puppet_or_actor reverse_add_opinion = { - target = scope:actor + target = scope:puppet_or_actor modifier = warmonger_opinion } } @@ -2185,7 +2283,7 @@ purchase_truce_interaction = { # If we're a clan this interaction affects unity add_clan_unity_interaction_effect = { CHARACTER = scope:recipient - TARGET = scope:actor + TARGET = scope:puppet_or_actor VALUE = minor_unity_loss DESC = clan_unity_purchased_truce_refusal.desc REVERSE_NON_HOUSE_TARGET = no @@ -2197,7 +2295,17 @@ purchase_truce_interaction = { send_option = { is_shown = { always = yes } is_valid = { - scope:actor = { gold >= pt_sum_small_value } + scope:puppet_or_actor ?= { + trigger_if = { + limit = { + has_personal_tenet_flag = tenet_peace_of_god_personal_truce + } + scope:puppet_or_actor ?= { piety >= pt_sum_small_value } + } + trigger_else = { + scope:puppet_or_actor ?= { gold >= pt_sum_small_value } + } + } } flag = pt_sum_small localization = "PT_SUM_SMALL" @@ -2205,14 +2313,31 @@ purchase_truce_interaction = { ## Medium Sum send_option = { is_shown = { - # We use the most expensive of scope:actor or scope:recipient's income, so we check both. - scope:actor = { - can_make_expensive_purchase_trigger = { PRICE = scope:actor.purchase_truce_interaction_medium_sum } - can_make_expensive_purchase_trigger = { PRICE = scope:recipient.purchase_truce_interaction_medium_sum } + scope:puppet_or_actor ?= { + trigger_if = { + limit = { + NOT = { + has_personal_tenet_flag = tenet_peace_of_god_personal_truce + } + } + # Use the most expensive of the two incomes + can_make_expensive_purchase_trigger = { PRICE = scope:puppet_or_actor.purchase_truce_interaction_medium_sum } + can_make_expensive_purchase_trigger = { PRICE = scope:recipient.purchase_truce_interaction_medium_sum } + } } } is_valid = { - scope:actor = { gold >= pt_sum_medium_value } + scope:puppet_or_actor ?= { + trigger_if = { + limit = { + has_personal_tenet_flag = tenet_peace_of_god_personal_truce + } + piety >= pt_sum_medium_value + } + trigger_else = { + gold >= pt_sum_medium_value + } + } } flag = pt_sum_medium starts_enabled = { always = yes } @@ -2221,14 +2346,30 @@ purchase_truce_interaction = { ## Large Sum send_option = { is_shown = { - # We use the most expensive of scope:actor or scope:recipient's income, so we check both. - scope:actor = { - can_make_expensive_purchase_trigger = { PRICE = scope:actor.purchase_truce_interaction_major_sum } - can_make_expensive_purchase_trigger = { PRICE = scope:recipient.purchase_truce_interaction_major_sum } + scope:puppet_or_actor ?= { + trigger_if = { + limit = { + NOT = { + has_personal_tenet_flag = tenet_peace_of_god_personal_truce + } + } + can_make_expensive_purchase_trigger = { PRICE = scope:puppet_or_actor.purchase_truce_interaction_major_sum } + can_make_expensive_purchase_trigger = { PRICE = scope:recipient.purchase_truce_interaction_major_sum } + } } } is_valid = { - scope:actor = { gold >= pt_sum_large_value } + scope:puppet_or_actor ?= { + trigger_if = { + limit = { + has_personal_tenet_flag = tenet_peace_of_god_personal_truce + } + piety >= pt_sum_large_value + } + trigger_else = { + gold >= pt_sum_large_value + } + } } flag = pt_sum_large localization = "PT_SUM_LARGE" @@ -2241,7 +2382,7 @@ purchase_truce_interaction = { base = 0 # Struggle - # modifier = { +# modifier = { # trigger_if = { # limit = { # scope:recipient = { @@ -2249,7 +2390,7 @@ purchase_truce_interaction = { # involvement = involved # } # } -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # involvement = involved # } @@ -2304,6 +2445,12 @@ purchase_truce_interaction = { add = 75 always = scope:pt_sum_large desc = PT_AMOUNT_OF_GOLD_OFFERED + } + # PAM Peace of God + modifier = { + add = 30 + scope:recipient.rite ?= { rite_has_parameter = tenet_peace_of_god_cheaper_truce_purchase } + desc = PT_PAM_PEACE_OF_GOD_RITE } ## Plus a bit of base-line acceptance if the AI's coffers are currently pretty anaemic. modifier = { @@ -2314,7 +2461,7 @@ purchase_truce_interaction = { # AI take opinion into account, but reduced so they'll at least occasionally accept from folks they dislike. opinion_modifier = { who = scope:recipient - opinion_target = scope:actor + opinion_target = scope:puppet_or_actor multiplier = 0.5 desc = AI_OPINION_REASON } @@ -2356,7 +2503,7 @@ purchase_truce_interaction = { # Pacifist AI are happy to avoid war. modifier = { add = 25 - faith = { has_doctrine_parameter = pacifist_opinion_active } + faith = { has_doctrine_parameter = pacifist } desc = PT_AI_IS_PACIFIST_FAITH } modifier = { @@ -2366,42 +2513,42 @@ purchase_truce_interaction = { } # War likeliness. ## This is primarily intended to mitigate conquest, invasion, and religious CBs, so we don't account for them. - ## Scope:recipient has some claim to scope:actor's lands. + ## Scope:recipient has some claim to scope:puppet_or_actor's lands. modifier = { add = -20 any_claim = { count = 1 exists = holder - holder = scope:actor + holder = scope:puppet_or_actor } desc = PT_AI_PERSONALLY_CLAIMS_YOUR_LAND } - ## Scope:recipient has decent claim to scope:actor's lands. + ## Scope:recipient has decent claim to scope:puppet_or_actor's lands. modifier = { add = -40 OR = { any_claim = { count >= 2 exists = holder - holder = scope:actor + holder = scope:puppet_or_actor } any_claim = { count = 1 exists = holder - holder = scope:actor + holder = scope:puppet_or_actor save_temporary_scope_as = claim_temp scope:recipient = { has_strong_claim_on = scope:claim_temp } } } desc = PT_AI_PERSONALLY_CLAIMS_YOUR_LAND } - ## Scope:recipient has strong claim to scope:actor's lands. + ## Scope:recipient has strong claim to scope:puppet_or_actor's lands. modifier = { add = -60 any_claim = { count >= 2 exists = holder - holder = scope:actor + holder = scope:puppet_or_actor save_temporary_scope_as = claim_temp scope:recipient = { has_strong_claim_on = scope:claim_temp } } @@ -2413,10 +2560,10 @@ purchase_truce_interaction = { add = -30 highest_held_title_tier = tier_duchy purchase_truce_interaction_recipient_can_de_jure_war_actor_trigger = yes - scope:actor = { + scope:puppet_or_actor = { any_sub_realm_county = { count >= 3 - any_this_title_or_de_jure_above = { holder = scope:actor } + any_this_title_or_de_jure_above = { holder = scope:puppet_or_actor } } } desc = PT_AI_DE_JURE_CLAIMS_YOUR_LAND @@ -2426,10 +2573,10 @@ purchase_truce_interaction = { add = -30 highest_held_title_tier = tier_kingdom purchase_truce_interaction_recipient_can_de_jure_war_actor_trigger = yes - scope:actor = { + scope:puppet_or_actor = { any_sub_realm_county = { count >= 10 - any_this_title_or_de_jure_above = { holder = scope:actor } + any_this_title_or_de_jure_above = { holder = scope:puppet_or_actor } } } desc = PT_AI_DE_JURE_CLAIMS_YOUR_LAND @@ -2439,10 +2586,22 @@ purchase_truce_interaction = { add = -30 highest_held_title_tier = tier_empire purchase_truce_interaction_recipient_can_de_jure_war_actor_trigger = yes - scope:actor = { + scope:puppet_or_actor = { any_sub_realm_county = { count >= 20 - any_this_title_or_de_jure_above = { holder = scope:actor } + any_this_title_or_de_jure_above = { holder = scope:puppet_or_actor } + } + } + desc = PT_AI_DE_JURE_CLAIMS_YOUR_LAND + } + modifier = { + add = -30 + highest_held_title_tier = tier_hegemony + purchase_truce_interaction_recipient_can_de_jure_war_actor_trigger = yes + scope:puppet_or_actor = { + any_sub_realm_county = { + count >= 30 + any_this_title_or_de_jure_above = { holder = scope:puppet_or_actor } } } desc = PT_AI_DE_JURE_CLAIMS_YOUR_LAND @@ -2451,50 +2610,37 @@ purchase_truce_interaction = { ## Scope:actor has far fewer levies than scope:recipient. modifier = { add = -30 - scope:actor.max_military_strength <= scope:recipient.purchase_truce_interaction_recipient_far_weaker_value + scope:puppet_or_actor.max_military_strength <= scope:recipient.purchase_truce_interaction_recipient_far_weaker_value desc = PT_AI_RECIPIENT_IS_MUCH_STRONGER } ## Scope:actor has fewer levies than scope:recipient. modifier = { add = -10 - scope:actor.max_military_strength > scope:recipient.purchase_truce_interaction_recipient_far_weaker_value - scope:actor.max_military_strength <= scope:recipient.purchase_truce_interaction_recipient_somewhat_weaker_value + scope:puppet_or_actor.max_military_strength > scope:recipient.purchase_truce_interaction_recipient_far_weaker_value + scope:puppet_or_actor.max_military_strength <= scope:recipient.purchase_truce_interaction_recipient_somewhat_weaker_value desc = PT_AI_RECIPIENT_IS_SOMEWHAT_STRONGER } ## Scope:actor has roughly equal levies with scope:recipient. modifier = { add = 10 - scope:actor.max_military_strength > scope:recipient.purchase_truce_interaction_recipient_somewhat_weaker_value - scope:actor.max_military_strength <= scope:recipient.purchase_truce_interaction_recipient_somewhat_stronger_value + scope:puppet_or_actor.max_military_strength > scope:recipient.purchase_truce_interaction_recipient_somewhat_weaker_value + scope:puppet_or_actor.max_military_strength <= scope:recipient.purchase_truce_interaction_recipient_somewhat_stronger_value desc = PT_AI_RECIPIENT_IS_ROUGHLY_EQUAL } ## Scope:actor has more levies than scope:recipient. modifier = { add = 25 - scope:actor.max_military_strength > scope:recipient.purchase_truce_interaction_recipient_somewhat_stronger_value - scope:actor.max_military_strength <= scope:recipient.purchase_truce_interaction_recipient_far_stronger_value + scope:puppet_or_actor.max_military_strength > scope:recipient.purchase_truce_interaction_recipient_somewhat_stronger_value + scope:puppet_or_actor.max_military_strength <= scope:recipient.purchase_truce_interaction_recipient_far_stronger_value desc = PT_AI_RECIPIENT_IS_SOMEWHAT_WEAKER } ## Scope:actor has far more levies than scope:recipient. modifier = { add = 50 - scope:actor.max_military_strength > scope:recipient.purchase_truce_interaction_recipient_far_stronger_value + scope:puppet_or_actor.max_military_strength > scope:recipient.purchase_truce_interaction_recipient_far_stronger_value desc = PT_AI_RECIPIENT_IS_MUCH_WEAKER } } - ## Performance-enhancement - ai_potential = { - is_playable_character = yes - is_at_war = no - is_imprisoned = no - # Matches the regular minimum triggers. - OR = { - any_character_struggle = { involvement = involved } - has_perk = defensive_measures_perk - } - # Might actually be wurf evaluating the costs. - can_make_expensive_purchase_trigger = { PRICE = purchase_truce_interaction_small_sum } - } ai_target_quick_trigger = { adult = yes } ai_targets = { ai_recipients = neighboring_rulers @@ -2529,7 +2675,7 @@ purchase_truce_interaction = { ## Pacifists. modifier = { add = 25 - faith = { has_doctrine_parameter = pacifist_opinion_active } + faith = { has_doctrine_parameter = pacifist } } modifier = { add = 25 @@ -2570,12 +2716,12 @@ purchase_truce_interaction = { ## Try to buy truces from somewhat stronger realms... modifier = { add = 50 - scope:recipient.max_military_strength >= scope:actor.purchase_truce_interaction_recipient_somewhat_stronger_value + scope:recipient.max_military_strength >= scope:puppet_or_actor.purchase_truce_interaction_recipient_somewhat_stronger_value } ## ... and much stronger realms. modifier = { add = 50 - scope:recipient.max_military_strength >= scope:actor.purchase_truce_interaction_recipient_far_stronger_value + scope:recipient.max_military_strength >= scope:puppet_or_actor.purchase_truce_interaction_recipient_far_stronger_value } # Struggle @@ -2585,7 +2731,7 @@ purchase_truce_interaction = { # involvement = involved # } # } -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # involvement = involved # } @@ -2594,7 +2740,7 @@ purchase_truce_interaction = { # value = 0 # if = { # limit = { -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # phase_has_catalyst = catalyst_sign_truce_outside_war # } @@ -2605,7 +2751,7 @@ purchase_truce_interaction = { # } # else_if = { # limit = { -# scope:actor = { +# scope:puppet_or_actor = { # any_character_struggle = { # phase_has_catalyst = catalyst_sign_truce_outside_war # } @@ -2619,7 +2765,7 @@ purchase_truce_interaction = { ## Only buy truces from weaker/roughly-equal realms if you're craven have been at war forever. modifier = { factor = 0 - max_military_strength <= scope:actor.purchase_truce_interaction_recipient_somewhat_weaker_value + max_military_strength <= scope:puppet_or_actor.purchase_truce_interaction_recipient_somewhat_weaker_value NOR = { has_trait = craven days_of_continuous_war <= 3650 @@ -2629,7 +2775,7 @@ purchase_truce_interaction = { modifier = { factor = 0 scope:recipient = { - NOT = { has_any_cb_on = scope:actor } + NOT = { has_any_cb_on = scope:puppet_or_actor } } } ## Don't buy truces from people who are likely going to be dead soon, or if you yourself will die soon, since they'll be wasted. @@ -2680,6 +2826,30 @@ incite_revolts_interaction = { } } + is_available = { + trigger_if = { + limit = { is_ai = yes } + OR = { +# any_character_struggle = { +# involvement = involved +# has_struggle_phase_parameter = unlocks_incite_revolts_interaction +# OR = { +# is_struggle_phase = struggle_iberia_phase_opportunity +# is_struggle_phase = struggle_iberia_phase_hostility +# } +# } +# any_character_struggle = { +# involvement = involved +# is_struggle_type = persian_struggle +# } + domicile ?= { + has_domicile_parameter = can_use_incite_revolts + } + } + short_term_gold >= medium_gold_value + } + } + is_shown = { scope:recipient != scope:actor OR = { @@ -2692,7 +2862,7 @@ incite_revolts_interaction = { has_relation_rival = scope:recipient } } -# # Only available during Opportunity, Hostility and Tension phases + # Only available during Opportunity, Hostility and Tension phases # scope:actor = { # any_character_struggle = { # involvement = involved @@ -2764,7 +2934,7 @@ incite_revolts_interaction = { send_option = { flag = medium_investment_in_revolt localization = medium_investment - starts_enabled = { always = yes } + starts_enabled = { always = yes } } # High investment @@ -2819,33 +2989,41 @@ incite_revolts_interaction = { } scope:actor = { - stress_impact = { - just = medium_stress_impact_gain - honest = medium_stress_impact_gain - trusting = medium_stress_impact_gain - greedy = minor_stress_impact_gain - } + # Only get stressed/SP penalties if you don't have the parameter if = { limit = { - scope:actor = { - OR = { - has_relation_rival = scope:recipient - has_relation_nemesis = scope:recipient + NOT = { sp_hostile_schemes_except_murder_no_stress_or_fulfillment_trigger = yes } + } + + stress_and_fulfillment_impact = { + just = medium_stress_impact_gain + honest = medium_stress_impact_gain + trusting = medium_stress_impact_gain + greedy = minor_stress_impact_gain + } + + if = { + limit = { + scope:actor = { + OR = { + has_relation_rival = scope:recipient + has_relation_nemesis = scope:recipient + } } } - } - stress_impact = { - vengeful = medium_stress_impact_loss - } - } - if = { - limit = { - scope:actor = { - is_vassal_of = scope:recipient + stress_and_fulfillment_impact = { + vengeful = medium_stress_impact_loss } } - stress_impact = { - ambitious = medium_stress_impact_loss + if = { + limit = { + scope:actor = { + is_vassal_of = scope:recipient + } + } + stress_and_fulfillment_impact = { + ambitious = medium_stress_impact_loss + } } } } @@ -3023,27 +3201,6 @@ incite_revolts_interaction = { hegemony = 60 } - ai_potential = { - short_term_gold >= medium_gold_value - OR = { -# any_character_struggle = { -# has_struggle_phase_parameter = unlocks_incite_revolts_interaction -# involvement = involved -# OR = { -# is_struggle_phase = struggle_iberia_phase_opportunity -# is_struggle_phase = struggle_iberia_phase_hostility -# } -# } -# any_character_struggle = { -# is_struggle_type = persian_struggle -# involvement = involved -# } - domicile ?= { - has_domicile_parameter = can_use_incite_revolts - } - } - } - ai_targets = { # For the AI, we limit it to neighboring_rulers ai_recipients = neighboring_rulers @@ -3167,7 +3324,7 @@ incite_revolts_interaction = { # Contract Assistance # by Joe Parkin ################################################## -# + #contract_assistance_interaction = { # category = interaction_category_diplomacy # interface_priority = 15 @@ -3186,19 +3343,26 @@ incite_revolts_interaction = { # # cooldown_against_recipient = { years = 5 } # -# is_shown = { -# # Actor is Involved in Struggle -# scope:actor = { -# NOT = { government_has_flag = government_is_true_herder } -# OR = { -# any_character_struggle = { -# involvement = involved -# has_struggle_phase_parameter = unlocks_contract_assistance_interaction -# } -# culture = { has_cultural_parameter = unlocks_contract_assistance } -# OR = { government_has_flag = government_is_landless_adventurer government_has_flag = government_is_landless_minority } -# } +# is_available = { +# trigger_if = { +# limit = { is_ai = yes } +# current_military_strength >= 500 +# ai_boldness >= -25 +# is_at_war = no +# is_imprisoned = no # } +# OR = { +# any_character_struggle = { +# involvement = involved +# has_struggle_phase_parameter = unlocks_contract_assistance_interaction +# } +# culture ?= { has_cultural_parameter = unlocks_contract_assistance } +# government_has_flag = government_is_landless_adventurer +# } +# NOT = { government_has_flag = government_is_herder } +# } +# +# is_shown = { # # Recipient is Involved in Struggle, at war, and not at war with Actor # scope:recipient = { # trigger_if = { @@ -3373,7 +3537,7 @@ incite_revolts_interaction = { # name = owed_contract_assistance_gold # value = scope:recipient.offer_assistance_interaction_gold_value # } -# stress_impact = { +# stress_and_fulfillment_impact = { # craven = medium_stress_impact_gain # shy = minor_stress_impact_gain # } @@ -3407,7 +3571,7 @@ incite_revolts_interaction = { # } # # Recipient effects # scope:recipient = { -# stress_impact = { +# stress_and_fulfillment_impact = { # greedy = medium_stress_impact_gain # arrogant = medium_stress_impact_gain # } @@ -3671,12 +3835,6 @@ incite_revolts_interaction = { # # } # } # -# ai_potential = { -# is_imprisoned = no -# is_at_war = no -# ai_boldness >= -25 -# current_military_strength >= 500 -# } # ai_target_quick_trigger = { adult = yes } # ai_targets = { # ai_recipients = neighboring_rulers @@ -3801,12 +3959,12 @@ incite_revolts_interaction = { # } # } #} -# -################################################### -## Request Contract Assistance -## by Maxence Voleau -################################################### -# + +################################################## +# Request Contract Assistance +# by Maxence Voleau +################################################## + #request_contract_assistance_interaction = { # category = interaction_category_diplomacy # interface_priority = 15 @@ -3825,14 +3983,24 @@ incite_revolts_interaction = { # # cooldown_against_recipient = { years = 5 } # +# is_available = { +# is_at_war = yes +# any_character_struggle = { +# involvement = involved +# has_struggle_phase_parameter = unlocks_contract_assistance_interaction +# } +# trigger_if = { +# limit = { is_ai = yes } +# gold >= ai_war_chest_desired_gold_value +# is_at_war = no +# # the AI cannot use it for now so let's block it +# is_imprisoned = no +# } +# } +# # is_shown = { # # Actor is Involved in Struggle # scope:actor = { -# any_character_struggle = { -# involvement = involved -# has_struggle_phase_parameter = unlocks_contract_assistance_interaction -# } -# is_at_war = yes # NOR = { # this = scope:recipient # is_at_war_with = scope:recipient @@ -3961,7 +4129,7 @@ incite_revolts_interaction = { # name = owed_contract_assistance_gold # value = offer_assistance_interaction_gold_value # } -# stress_impact = { +# stress_and_fulfillment_impact = { # craven = medium_stress_impact_gain # shy = minor_stress_impact_gain # } @@ -3996,7 +4164,7 @@ incite_revolts_interaction = { # } # # Recipient effects # scope:actor = { -# stress_impact = { +# stress_and_fulfillment_impact = { # greedy = medium_stress_impact_gain # arrogant = medium_stress_impact_gain # } @@ -4149,12 +4317,6 @@ incite_revolts_interaction = { # } # } # -# ai_potential = { -# # the AI cannot use it for now so let's block it -# is_imprisoned = no -# is_at_war = no -# gold >= ai_war_chest_desired_gold_value -# } # ai_target_quick_trigger = { adult = yes } # ai_targets = { # ai_recipients = neighboring_rulers @@ -4287,6 +4449,13 @@ enforce_truce_interaction = { cooldown = { years = 5 } + is_available = { + trigger_if = { + limit = { is_ai = yes } + is_imprisoned = no + } + } + is_shown = { OR = { # During the Struggle @@ -4314,15 +4483,15 @@ enforce_truce_interaction = { # Comrpomise ending AND = { scope:actor = { - primary_title.tier >= tier_duchy exists = house - house = { + primary_title.tier >= tier_duchy + house ?= { has_house_modifier = fp2_struggle_compromise_house_reward_modifier } } scope:recipient = { # Primary title in Iberia exists = house - house = { + house ?= { has_house_modifier = fp2_struggle_compromise_house_reward_modifier } tier_difference = { @@ -4503,7 +4672,7 @@ enforce_truce_interaction = { } } } - stress_impact = { + stress_and_fulfillment_impact = { wrathful = minor_stress_impact_gain brave = minor_stress_impact_gain ambitious = minor_stress_impact_gain @@ -4532,7 +4701,7 @@ enforce_truce_interaction = { } } } - stress_impact = { + stress_and_fulfillment_impact = { wrathful = minor_stress_impact_gain brave = minor_stress_impact_gain ambitious = minor_stress_impact_gain @@ -4541,26 +4710,31 @@ enforce_truce_interaction = { } } scope:target = { end_war = white_peace } - if = { - limit = { - scope:actor = { + scope:actor = { + if = { + limit = { any_character_struggle = { involvement = involved activate_struggle_catalyst_secondary_character_involvement_involved_trigger = { CATALYST = catalyst_truce_was_enforced - CHAR = scope:target + CHAR = scope:recipient } } } - } - every_character_struggle = { - involvement = involved - activate_struggle_catalyst = { - catalyst = catalyst_truce_was_enforced - character = scope:actor + every_character_struggle = { + involvement = involved + limit = { + activate_struggle_catalyst_secondary_character_involvement_involved_trigger = { + CATALYST = catalyst_truce_was_enforced + CHAR = scope:recipient + } + } + activate_struggle_catalyst = { + catalyst = catalyst_truce_was_enforced + character = scope:actor + } } } - } } @@ -4737,9 +4911,6 @@ enforce_truce_interaction = { } } - ai_potential = { - is_imprisoned = no - } ai_target_quick_trigger = { adult = yes } ai_targets = { ai_recipients = neighboring_rulers @@ -4776,18 +4947,25 @@ bargain_fealty_interaction = { cooldown_against_recipient = { years = 5 } + is_available = { + is_at_war = yes + any_character_struggle = { + involvement = involved + struggle_can_access_unlocks_bargain_fealty_interaction_trigger = yes + } + trigger_if = { + limit = { is_ai = yes } + is_imprisoned = no + } + top_liege ?= this + } + is_shown = { # Actor is Involved in Struggle scope:actor = { - any_character_struggle = { - involvement = involved - struggle_can_access_unlocks_bargain_fealty_interaction_trigger = yes - } - top_liege = this - is_at_war = yes any_character_war = { + primary_defender ?= scope:actor is_war_leader = scope:actor - primary_defender = scope:actor } trigger_if = { limit = { @@ -4809,7 +4987,7 @@ bargain_fealty_interaction = { } scope:recipient = { NOT = { this = scope:actor } - primary_title = { is_mercenary_company = no } + primary_title ?= { is_mercenary_company = no } } } @@ -4866,40 +5044,44 @@ bargain_fealty_interaction = { } on_accept = { - scope:target = { - # Add Recipient to Actor's war - hidden_effect = { set_called_to = scope:recipient } - add_defender = scope:recipient - } - create_title_and_vassal_change = { - type = swear_fealty - save_scope_as = change - } - scope:actor = { - change_liege = { - liege = scope:recipient - change = scope:change - } - resolve_title_and_vassal_change = scope:change - } - # Actor effects - scope:actor = { - stress_impact = { - arrogant = medium_stress_impact_gain - craven = medium_stress_impact_gain - } - } - # Recipient effects - scope:recipient = { - stress_impact = { - greedy = medium_stress_impact_gain - craven = medium_stress_impact_gain - } - } if = { - limit = { - NOT = { exists = scope:target } + limit = { exists = scope:target } + # Add Recipient to Actor's war + scope:target = { + hidden_effect = { set_called_to = scope:recipient } + if = { + limit = { is_attacker = scope:actor } + add_attacker = scope:recipient + } + else = { add_defender = scope:recipient } } + create_title_and_vassal_change = { + type = swear_fealty + save_scope_as = change + } + scope:actor = { + change_liege = { + liege = scope:recipient + change = scope:change + } + resolve_title_and_vassal_change = scope:change + } + # Actor effects + scope:actor = { + stress_and_fulfillment_impact = { + arrogant = medium_stress_impact_gain + craven = medium_stress_impact_gain + } + } + # Recipient effects + scope:recipient = { + stress_and_fulfillment_impact = { + greedy = medium_stress_impact_gain + craven = medium_stress_impact_gain + } + } + } + else = { scope:actor = { send_interface_toast = { type = event_toast_effect_neutral @@ -4957,6 +5139,9 @@ bargain_fealty_interaction = { # Actor is de jure vassal of recipient modifier = { add = 25 + scope:recipient = { + exists = primary_title + } scope:actor = { any_held_title = { target_is_de_jure_liege_or_above = scope:recipient.primary_title } } @@ -5039,7 +5224,6 @@ bargain_fealty_interaction = { } } } - ai_potential = { is_imprisoned = no } ai_target_quick_trigger = { adult = yes } ai_targets = { ai_recipients = neighboring_rulers } ai_frequency_by_tier = { @@ -5071,18 +5255,18 @@ invite_foreign_ruler_to = { cooldown = { years = 1 } cooldown_against_recipient = { years = 5 } + is_available = { + any_character_struggle = { + involvement = involved + is_struggle_type = iberian_struggle + } + } + is_shown = { # Interaction deprecated by new activity planning system always = no # scope:actor != scope:recipient -# # Scope:actor needs to either be involved in certain struggle types or else have a specific perk. -# scope:actor = { -# any_character_struggle = { -# involvement = involved -# is_struggle_type = iberian_struggle -# } -# } # # Scope:recipient must be landed, and neither over or under scope:actor. # scope:recipient = { # any_character_struggle = { @@ -5509,3 +5693,4 @@ invite_foreign_ruler_to = { # } #} } + diff --git a/common/character_interactions/05_bp2_interactions.txt b/common/character_interactions/05_bp2_interactions.txt index 0c0d81c39..46062fb70 100644 --- a/common/character_interactions/05_bp2_interactions.txt +++ b/common/character_interactions/05_bp2_interactions.txt @@ -43,14 +43,14 @@ offer_hostage_interaction = { scope:recipient = { NOR = { government_has_flag = government_is_landless_adventurer - government_has_flag = government_is_true_herder + government_has_flag = government_is_herder } } #Inside a merit realm vassals won't offer hostages except to your top liege. trigger_if = { limit = { - scope:actor.top_liege = { government_has_flag = government_has_merit } scope:actor.top_liege != scope:actor + scope:actor.top_liege ?= { government_has_flag = government_has_merit } scope:recipient != scope:actor.top_liege } NAND = { @@ -94,16 +94,12 @@ offer_hostage_interaction = { } scope:actor = { OR = { - government_has_flag = government_is_urepublic - government_has_flag = government_is_prepublic is_landless_ruler = no is_landless_administrative = yes } } scope:recipient = { OR = { - government_has_flag = government_is_urepublic - government_has_flag = government_is_prepublic is_landless_ruler = no is_landless_administrative = yes } @@ -465,15 +461,15 @@ offer_hostage_interaction = { } is_available = { + NOT = { + government_has_flag = government_is_landless_adventurer + } trigger_if = { limit = { is_ai = yes } NOT = { has_variable = conqueror } } - NOT = { - government_has_flag = government_is_landless_adventurer - } } ai_will_do = { @@ -624,11 +620,19 @@ demand_hostage_interaction = { cooldown_against_recipient = { years = 3 } + is_available = { + trigger_if = { + limit = { is_ai = yes } + highest_held_title_tier >= tier_county + NOT = { has_variable = conqueror } + } + } + is_shown = { # Cannot exchange hostages with self scope:recipient != scope:actor # Cannot exchange hostages with a herder - NOT = { scope:recipient = { government_has_flag = government_is_true_herder } } + NOT = { scope:recipient = { government_has_flag = government_is_herder } } # Only significant rulers use hostages scope:actor.highest_held_title_tier > tier_barony OR = { @@ -650,8 +654,8 @@ demand_hostage_interaction = { #Inside a merit realm vassals won't demand hostages. trigger_if = { limit = { - scope:actor.top_liege = { government_has_flag = government_has_merit } scope:actor.top_liege != scope:actor + scope:actor.top_liege ?= { government_has_flag = government_has_merit } } NAND = { scope:actor = { government_has_flag = government_has_merit } @@ -681,16 +685,12 @@ demand_hostage_interaction = { } scope:actor = { OR = { - government_has_flag = government_is_urepublic - government_has_flag = government_is_prepublic is_landless_ruler = no is_landless_administrative = yes } } scope:recipient = { OR = { - government_has_flag = government_is_urepublic - government_has_flag = government_is_prepublic is_landless_ruler = no is_landless_administrative = yes } @@ -1208,11 +1208,6 @@ demand_hostage_interaction = { hegemony = 36 } - ai_potential = { - highest_held_title_tier >= tier_county - NOT = { has_variable = conqueror } - } - ai_will_do = { base = 0 opinion_modifier = { # Opinion Factor @@ -1328,11 +1323,20 @@ exchange_hostage_interaction = { cooldown_against_recipient = { years = 3 } + is_available = { + trigger_if = { + limit = { is_ai = yes } + highest_held_title_tier >= tier_county + is_adult = yes + NOT = { has_variable = conqueror } + } + } + is_shown = { # Cannot exchange hostages with self scope:recipient != scope:actor # Cannot exchange hostages with a herder - NOT = { scope:recipient = { government_has_flag = government_is_true_herder } } + NOT = { scope:recipient = { government_has_flag = government_is_herder } } # Only significant rulers use hostages scope:actor.highest_held_title_tier > tier_barony OR = { @@ -1354,8 +1358,8 @@ exchange_hostage_interaction = { #Inside a merit realm vassals won't exchange hostages. trigger_if = { limit = { - scope:actor.top_liege = { government_has_flag = government_has_merit } scope:actor.top_liege != scope:actor + scope:actor.top_liege ?= { government_has_flag = government_has_merit } } NAND = { scope:actor = { government_has_flag = government_has_merit } @@ -1423,8 +1427,6 @@ exchange_hostage_interaction = { } } OR = { - government_has_flag = government_is_urepublic - government_has_flag = government_is_prepublic is_landless_ruler = no is_landless_administrative = yes } @@ -1903,12 +1905,6 @@ exchange_hostage_interaction = { hegemony = 36 } - ai_potential = { - is_adult = yes - highest_held_title_tier >= tier_county - NOT = { has_variable = conqueror } - } - ai_will_do = { base = 0 opinion_modifier = { # Opinion Factor @@ -2057,7 +2053,7 @@ return_hostage_interaction = { desc = return_hostage_interaction_desc populate_recipient_list = { - scope:actor = { + scope:puppet_or_actor = { every_warden_hostage = { limit = { home_court ?= scope:recipient } add_to_list = characters @@ -2067,22 +2063,31 @@ return_hostage_interaction = { cost = {} + is_available = { + # Implied by is_shown, but asked once per character instead of once per recipient + trigger_if = { + limit = { is_ai = yes } + any_warden_hostage = { count >= 1 } + } + } + is_shown = { # Cannot return hostages to self - scope:recipient != scope:actor + exists = scope:puppet_or_actor + scope:recipient != scope:puppet_or_actor # Must have a hostage OR = { - scope:actor = { + scope:puppet_or_actor ?= { any_warden_hostage = { home_court ?= scope:recipient } } - scope:recipient.warden ?= scope:actor + scope:recipient.warden ?= scope:puppet_or_actor } } redirect = { if = { limit = { - scope:recipient.warden ?= scope:actor + scope:recipient.warden ?= scope:puppet_or_actor } scope:recipient = { save_scope_as = secondary_recipient } scope:recipient.home_court = { save_scope_as = recipient } @@ -2092,9 +2097,9 @@ return_hostage_interaction = { is_valid_showing_failures_only = { NOR = { # Must be at peace - scope:recipient = { is_at_war_with = scope:actor } + scope:recipient = { is_at_war_with = scope:puppet_or_actor } # Only family oriented governments use hostages - scope:actor = { + scope:puppet_or_actor = { OR = { government_has_flag = government_is_theocracy government_has_flag = government_is_landless_adventurer @@ -2115,7 +2120,7 @@ return_hostage_interaction = { can_send = { NOT = { - scope:actor = { is_at_war_with = scope:recipient } + scope:puppet_or_actor = { is_at_war_with = scope:recipient } } } @@ -2125,7 +2130,7 @@ return_hostage_interaction = { on_accept = { # Save scopes for clarity - scope:actor = { save_scope_as = warden } + scope:puppet_or_actor = { save_scope_as = warden } scope:recipient = { save_scope_as = home_court } scope:secondary_recipient = { save_scope_as = hostage } # Send toast informing sender of acceptance @@ -2203,8 +2208,8 @@ return_hostage_interaction = { } NOT = { scope:recipient = { - has_any_cb_on = scope:actor - scope:recipient.current_strength_with_allies_fifty_percent_value > scope:actor.current_strength_with_allies_value + has_any_cb_on = scope:puppet_or_actor + scope:recipient.current_strength_with_allies_fifty_percent_value > scope:puppet_or_actor.current_strength_with_allies_value } } } @@ -2213,21 +2218,21 @@ return_hostage_interaction = { } opinion_modifier = { # Opinion Factor who = scope:recipient - opinion_target = scope:actor + opinion_target = scope:puppet_or_actor multiplier = 0.5 desc = AI_OPINION_REASON } modifier = { add = 25 - scope:actor = { + scope:puppet_or_actor = { has_any_cb_on = scope:recipient - scope:actor.current_strength_with_allies_fifty_percent_value > scope:recipient.current_strength_with_allies_value + scope:puppet_or_actor.current_strength_with_allies_fifty_percent_value > scope:recipient.current_strength_with_allies_value } } modifier = { scope:recipient = { OR = { - is_allied_to = scope:actor + is_allied_to = scope:puppet_or_actor is_spouse_of = scope:recipient } } @@ -2235,26 +2240,26 @@ return_hostage_interaction = { } modifier = { scope:recipient = { - has_any_cb_on = scope:actor - scope:recipient.current_strength_with_allies_fifty_percent_value > scope:actor.current_strength_with_allies_value + has_any_cb_on = scope:puppet_or_actor + scope:recipient.current_strength_with_allies_fifty_percent_value > scope:puppet_or_actor.current_strength_with_allies_value } add = -50 } bp2_hostage_return_personality_modifier = { - WARDEN = scope:actor + WARDEN = scope:puppet_or_actor HOME_COURT = scope:recipient } # Cultural traditions modifier = { - scope:actor.culture = { has_cultural_tradition = tradition_equitable } + scope:puppet_or_actor.culture = { has_cultural_tradition = tradition_equitable } add = 25 } modifier = { - scope:actor.culture = { has_cultural_tradition = tradition_esteemed_hospitality } + scope:puppet_or_actor.culture = { has_cultural_tradition = tradition_esteemed_hospitality } add = 25 } modifier = { - scope:actor = { + scope:puppet_or_actor = { is_vassal_of = scope:recipient culture = { has_cultural_tradition = tradition_loyal_soldiers } } @@ -2756,6 +2761,13 @@ influence_child_personality_interaction = { desc = influence_child_personality_interaction_desc + is_available = { + trigger_if = { + limit = { is_ai = yes } + any_relation = { type = ward } + } + } + is_shown = { #any ai ward/hostage has_bp2_dlc_trigger = yes scope:recipient = { @@ -3990,183 +4002,183 @@ influence_child_personality_interaction = { switch = { trigger = yes scope:sadistic = { - scope:recipient.faith = { - trait_is_virtue = trait:sadistic + scope:recipient.rite = { + trait_is_virtue_rite = trait:sadistic } } scope:lustful = { - scope:recipient.faith = { - trait_is_virtue = trait:lustful + scope:recipient.rite = { + trait_is_virtue_rite = trait:lustful } } scope:chaste = { - scope:recipient.faith = { - trait_is_virtue = trait:chaste + scope:recipient.rite = { + trait_is_virtue_rite = trait:chaste } } scope:gluttonous = { - scope:recipient.faith = { - trait_is_virtue = trait:gluttonous + scope:recipient.rite = { + trait_is_virtue_rite = trait:gluttonous } } scope:temperate = { - scope:recipient.faith = { - trait_is_virtue = trait:temperate + scope:recipient.rite = { + trait_is_virtue_rite = trait:temperate } } scope:greedy = { - scope:recipient.faith = { - trait_is_virtue = trait:greedy + scope:recipient.rite = { + trait_is_virtue_rite = trait:greedy } } scope:generous = { - scope:recipient.faith = { - trait_is_virtue = trait:generous + scope:recipient.rite = { + trait_is_virtue_rite = trait:generous } } scope:lazy = { - scope:recipient.faith = { - trait_is_virtue = trait:lazy + scope:recipient.rite = { + trait_is_virtue_rite = trait:lazy } } scope:diligent = { - scope:recipient.faith = { - trait_is_virtue = trait:diligent + scope:recipient.rite = { + trait_is_virtue_rite = trait:diligent } } scope:wrathful = { - scope:recipient.faith = { - trait_is_virtue = trait:wrathful + scope:recipient.rite = { + trait_is_virtue_rite = trait:wrathful } } scope:calm = { - scope:recipient.faith = { - trait_is_virtue = trait:calm + scope:recipient.rite = { + trait_is_virtue_rite = trait:calm } } scope:patient = { - scope:recipient.faith = { - trait_is_virtue = trait:patient + scope:recipient.rite = { + trait_is_virtue_rite = trait:patient } } scope:impatient = { - scope:recipient.faith = { - trait_is_virtue = trait:impatient + scope:recipient.rite = { + trait_is_virtue_rite = trait:impatient } } scope:arrogant = { - scope:recipient.faith = { - trait_is_virtue = trait:arrogant + scope:recipient.rite = { + trait_is_virtue_rite = trait:arrogant } } scope:humble = { - scope:recipient.faith = { - trait_is_virtue = trait:humble + scope:recipient.rite = { + trait_is_virtue_rite = trait:humble } } scope:deceitful = { - scope:recipient.faith = { - trait_is_virtue = trait:deceitful + scope:recipient.rite = { + trait_is_virtue_rite = trait:deceitful } } scope:honest = { - scope:recipient.faith = { - trait_is_virtue = trait:honest + scope:recipient.rite = { + trait_is_virtue_rite = trait:honest } } scope:craven = { - scope:recipient.faith = { - trait_is_virtue = trait:craven + scope:recipient.rite = { + trait_is_virtue_rite = trait:craven } } scope:brave = { - scope:recipient.faith = { - trait_is_virtue = trait:brave + scope:recipient.rite = { + trait_is_virtue_rite = trait:brave } } scope:shy = { - scope:recipient.faith = { - trait_is_virtue = trait:shy + scope:recipient.rite = { + trait_is_virtue_rite = trait:shy } } scope:gregarious = { - scope:recipient.faith = { - trait_is_virtue = trait:gregarious + scope:recipient.rite = { + trait_is_virtue_rite = trait:gregarious } } scope:ambitious = { - scope:recipient.faith = { - trait_is_virtue = trait:ambitious + scope:recipient.rite = { + trait_is_virtue_rite = trait:ambitious } } scope:content = { - scope:recipient.faith = { - trait_is_virtue = trait:content + scope:recipient.rite = { + trait_is_virtue_rite = trait:content } } scope:arbitrary = { - scope:recipient.faith = { - trait_is_virtue = trait:arbitrary + scope:recipient.rite = { + trait_is_virtue_rite = trait:arbitrary } } scope:just = { - scope:recipient.faith = { - trait_is_virtue = trait:just + scope:recipient.rite = { + trait_is_virtue_rite = trait:just } } scope:cynical = { - scope:recipient.faith = { - trait_is_virtue = trait:cynical + scope:recipient.rite = { + trait_is_virtue_rite = trait:cynical } } scope:zealous = { - scope:recipient.faith = { - trait_is_virtue = trait:zealous + scope:recipient.rite = { + trait_is_virtue_rite = trait:zealous } } scope:paranoid = { - scope:recipient.faith = { - trait_is_virtue = trait:paranoid + scope:recipient.rite = { + trait_is_virtue_rite = trait:paranoid } } scope:trusting = { - scope:recipient.faith = { - trait_is_virtue = trait:trusting + scope:recipient.rite = { + trait_is_virtue_rite = trait:trusting } } scope:compassionate = { - scope:recipient.faith = { - trait_is_virtue = trait:compassionate + scope:recipient.rite = { + trait_is_virtue_rite = trait:compassionate } } scope:callous = { - scope:recipient.faith = { - trait_is_virtue = trait:callous + scope:recipient.rite = { + trait_is_virtue_rite = trait:callous } } scope:stubborn = { - scope:recipient.faith = { - trait_is_virtue = trait:stubborn + scope:recipient.rite = { + trait_is_virtue_rite = trait:stubborn } } scope:fickle = { - scope:recipient.faith = { - trait_is_virtue = trait:fickle + scope:recipient.rite = { + trait_is_virtue_rite = trait:fickle } } scope:eccentric = { - scope:recipient.faith = { - trait_is_virtue = trait:eccentric + scope:recipient.rite = { + trait_is_virtue_rite = trait:eccentric } } scope:vengeful = { - scope:recipient.faith = { - trait_is_virtue = trait:vengeful + scope:recipient.rite = { + trait_is_virtue_rite = trait:vengeful } } scope:forgiving = { - scope:recipient.faith = { - trait_is_virtue = trait:forgiving + scope:recipient.rite = { + trait_is_virtue_rite = trait:forgiving } } } @@ -4730,183 +4742,183 @@ influence_child_personality_interaction = { switch = { trigger = yes scope:sadistic = { - scope:recipient.faith = { - trait_is_sin = trait:sadistic + scope:recipient.rite = { + trait_is_sin_rite = trait:sadistic } } scope:lustful = { - scope:recipient.faith = { - trait_is_sin = trait:lustful + scope:recipient.rite = { + trait_is_sin_rite = trait:lustful } } scope:chaste = { - scope:recipient.faith = { - trait_is_sin = trait:chaste + scope:recipient.rite = { + trait_is_sin_rite = trait:chaste } } scope:gluttonous = { - scope:recipient.faith = { - trait_is_sin = trait:gluttonous + scope:recipient.rite = { + trait_is_sin_rite = trait:gluttonous } } scope:temperate = { - scope:recipient.faith = { - trait_is_sin = trait:temperate + scope:recipient.rite = { + trait_is_sin_rite = trait:temperate } } scope:greedy = { - scope:recipient.faith = { - trait_is_sin = trait:greedy + scope:recipient.rite = { + trait_is_sin_rite = trait:greedy } } scope:generous = { - scope:recipient.faith = { - trait_is_sin = trait:generous + scope:recipient.rite = { + trait_is_sin_rite = trait:generous } } scope:lazy = { - scope:recipient.faith = { - trait_is_sin = trait:lazy + scope:recipient.rite = { + trait_is_sin_rite = trait:lazy } } scope:diligent = { - scope:recipient.faith = { - trait_is_sin = trait:diligent + scope:recipient.rite = { + trait_is_sin_rite = trait:diligent } } scope:wrathful = { - scope:recipient.faith = { - trait_is_sin = trait:wrathful + scope:recipient.rite = { + trait_is_sin_rite = trait:wrathful } } scope:calm = { - scope:recipient.faith = { - trait_is_sin = trait:calm + scope:recipient.rite = { + trait_is_sin_rite = trait:calm } } scope:patient = { - scope:recipient.faith = { - trait_is_sin = trait:patient + scope:recipient.rite = { + trait_is_sin_rite = trait:patient } } scope:impatient = { - scope:recipient.faith = { - trait_is_sin = trait:impatient + scope:recipient.rite = { + trait_is_sin_rite = trait:impatient } } scope:arrogant = { - scope:recipient.faith = { - trait_is_sin = trait:arrogant + scope:recipient.rite = { + trait_is_sin_rite = trait:arrogant } } scope:humble = { - scope:recipient.faith = { - trait_is_sin = trait:humble + scope:recipient.rite = { + trait_is_sin_rite = trait:humble } } scope:deceitful = { - scope:recipient.faith = { - trait_is_sin = trait:deceitful + scope:recipient.rite = { + trait_is_sin_rite = trait:deceitful } } scope:honest = { - scope:recipient.faith = { - trait_is_sin = trait:honest + scope:recipient.rite = { + trait_is_sin_rite = trait:honest } } scope:craven = { - scope:recipient.faith = { - trait_is_sin = trait:craven + scope:recipient.rite = { + trait_is_sin_rite = trait:craven } } scope:brave = { - scope:recipient.faith = { - trait_is_sin = trait:brave + scope:recipient.rite = { + trait_is_sin_rite = trait:brave } } scope:shy = { - scope:recipient.faith = { - trait_is_sin = trait:shy + scope:recipient.rite = { + trait_is_sin_rite = trait:shy } } scope:gregarious = { - scope:recipient.faith = { - trait_is_sin = trait:gregarious + scope:recipient.rite = { + trait_is_sin_rite = trait:gregarious } } scope:ambitious = { - scope:recipient.faith = { - trait_is_sin = trait:ambitious + scope:recipient.rite = { + trait_is_sin_rite = trait:ambitious } } scope:content = { - scope:recipient.faith = { - trait_is_sin = trait:content + scope:recipient.rite = { + trait_is_sin_rite = trait:content } } scope:arbitrary = { - scope:recipient.faith = { - trait_is_sin = trait:arbitrary + scope:recipient.rite = { + trait_is_sin_rite = trait:arbitrary } } scope:just = { - scope:recipient.faith = { - trait_is_sin = trait:just + scope:recipient.rite = { + trait_is_sin_rite = trait:just } } scope:cynical = { - scope:recipient.faith = { - trait_is_sin = trait:cynical + scope:recipient.rite = { + trait_is_sin_rite = trait:cynical } } scope:zealous = { - scope:recipient.faith = { - trait_is_sin = trait:zealous + scope:recipient.rite = { + trait_is_sin_rite = trait:zealous } } scope:paranoid = { - scope:recipient.faith = { - trait_is_sin = trait:paranoid + scope:recipient.rite = { + trait_is_sin_rite = trait:paranoid } } scope:trusting = { - scope:recipient.faith = { - trait_is_sin = trait:trusting + scope:recipient.rite = { + trait_is_sin_rite = trait:trusting } } scope:compassionate = { - scope:recipient.faith = { - trait_is_sin = trait:compassionate + scope:recipient.rite = { + trait_is_sin_rite = trait:compassionate } } scope:callous = { - scope:recipient.faith = { - trait_is_sin = trait:callous + scope:recipient.rite = { + trait_is_sin_rite = trait:callous } } scope:stubborn = { - scope:recipient.faith = { - trait_is_sin = trait:stubborn + scope:recipient.rite = { + trait_is_sin_rite = trait:stubborn } } scope:fickle = { - scope:recipient.faith = { - trait_is_sin = trait:fickle + scope:recipient.rite = { + trait_is_sin_rite = trait:fickle } } scope:eccentric = { - scope:recipient.faith = { - trait_is_sin = trait:eccentric + scope:recipient.rite = { + trait_is_sin_rite = trait:eccentric } } scope:vengeful = { - scope:recipient.faith = { - trait_is_sin = trait:vengeful + scope:recipient.rite = { + trait_is_sin_rite = trait:vengeful } } scope:forgiving = { - scope:recipient.faith = { - trait_is_sin = trait:forgiving + scope:recipient.rite = { + trait_is_sin_rite = trait:forgiving } } } @@ -4944,10 +4956,6 @@ influence_child_personality_interaction = { } } - # AI - ai_potential = { - any_relation = { type = ward } - } ai_frequency_by_tier = { barony = 0 county = 36 @@ -4996,3 +5004,4 @@ influence_child_personality_interaction = { } } + diff --git a/common/character_interactions/06_ep3_laamp_interactions.txt b/common/character_interactions/06_ep3_laamp_interactions.txt index 87834cd55..4aa698406 100644 --- a/common/character_interactions/06_ep3_laamp_interactions.txt +++ b/common/character_interactions/06_ep3_laamp_interactions.txt @@ -5,7 +5,6 @@ purchase_land_interaction = { category = interaction_category_laamp - interface_priority = 30 icon = purchase_land_interaction desc = purchase_land_interaction_desc @@ -54,21 +53,19 @@ purchase_land_interaction = { send_options_exclusive = no + is_available = { + OR = { + government_has_flag = government_is_landless_adventurer + government_has_flag = government_is_landless_minority + } + } + is_shown = { has_ep3_dlc_trigger = yes - scope:actor = { - OR = { government_has_flag = government_is_landless_adventurer government_has_flag = government_is_landless_minority } - } scope:recipient = { is_landed = yes # Need to own the land/cannot directly buy a governorship (procure estate first) - NOR = { - government_has_flag = government_is_administrative - government_has_flag = government_is_japan_administrative - government_has_flag = government_is_japan_feudal - government_has_flag = government_is_celestial - government_has_flag = government_is_meritocratic - } + NOT = { government_allows = noble_families } } scope:recipient != scope:actor } @@ -161,6 +158,15 @@ purchase_land_interaction = { } } } + custom_tooltip = { + text = PURCHASE_LAND_COMPLETE_CONTROL_TT + trigger_if = { + limit = { scope:target = { tier = tier_duchy } } + scope:recipient = { + completely_controls = scope:target + } + } + } trigger_if = { limit = { exists = scope:target.holder } scope:target.holder = scope:recipient @@ -177,6 +183,7 @@ purchase_land_interaction = { } } scope:recipient = { + is_contact_of = scope:actor is_at_war = no NOT = { has_strong_hook = scope:actor } } @@ -269,6 +276,12 @@ purchase_land_interaction = { } } } + if = { + limit = { + scope:actor = { has_variable = ep3_grace_to_the_family_var } + } + multiply = 0.5 + } if = { limit = { scope:offer_gold = yes } multiply = 2 @@ -279,12 +292,43 @@ purchase_land_interaction = { on_accept = { scope:actor = { save_scope_as = adventurer } scope:target = { + save_scope_as = purchase_land_target add_to_list = purchased_titles if = { limit = { tier = tier_duchy } every_de_jure_county = { - limit = { ep3_purchase_land_valid_county_trigger = yes } - add_to_list = purchased_titles + limit = { + holder ?= { + OR = { + this = scope:recipient + target_is_liege_or_above = scope:recipient + } + } + } + if = { + limit = { holder = scope:recipient } + add_to_list = purchased_titles + } + else_if = { + limit = { + holder ?= { + highest_held_title_tier < scope:purchase_land_target.tier + NOT = { government_has_flag = government_is_administrative } + target_is_liege_or_above = scope:recipient + } + } + holder = { + if = { + limit = { + NOT = { is_in_list = purchase_land_vassals_taken } + } + add_to_list = purchase_land_vassals_taken + } + } + } + else = { + add_to_list = purchased_titles + } } } } @@ -296,15 +340,17 @@ purchase_land_interaction = { save_scope_value_as = { name = purchase_land_cost value = { - every_in_list = { - list = purchased_titles - if = { - limit = { tier = tier_county } - add = purchase_land_county_cost_value - } - else_if = { - limit = { tier = tier_duchy } - add = purchase_land_duchy_cost_value + if = { + limit = { scope:target.tier = tier_county } + add = purchase_land_county_cost_value + } + else = { + add = purchase_land_duchy_cost_value + scope:target = { + every_de_jure_county = { + limit = { ep3_purchase_land_valid_county_trigger = yes } + add = purchase_land_county_cost_value + } } } if = { @@ -335,16 +381,21 @@ purchase_land_interaction = { } else = { add = medium_legitimacy_loss } } - } + } } } - show_as_tooltip = { + show_as_tooltip = { scope:actor = { purchase_land_interaction_effect = yes } } if = { limit = { always = scope:hook } scope:actor = { use_hook = scope:recipient } } + hidden_effect = { # will be paid again so refund same amount as cost + scope:actor = { + add_gold = scope:purchase_land_cost + } + } scope:actor = { trigger_event = ep3_laamps.0100 } } @@ -434,7 +485,6 @@ purchase_land_interaction = { } modifier = { # Land is foreign add = 10 - desc = PURCHASE_LAND_FOREIGN_COUNTY_CULTURE_REASON add = { value = 0 if = { @@ -580,7 +630,7 @@ purchase_land_interaction = { min = -200 } desc = PURCHASE_LAND_MY_FAITH_REASON - scope:actor.faith != scope:recipient.faith + scope:actor.faith != scope:recipient.faith trigger_if = { limit = { scope:target.tier = tier_county } scope:target.faith = scope:recipient.faith @@ -655,7 +705,7 @@ purchase_land_interaction = { AND = { scope:target.tier = tier_county scope:target.culture = scope:recipient.culture - } + } scope:target = { any_de_jure_county = { ep3_purchase_land_valid_county_trigger = yes @@ -699,7 +749,7 @@ purchase_land_interaction = { AND = { scope:target.tier = tier_county scope:target.culture = scope:recipient.culture - } + } scope:target = { any_de_jure_county = { ep3_purchase_land_valid_county_trigger = yes @@ -765,7 +815,7 @@ purchase_land_interaction = { add = 80 scope:vassal_obligation = yes desc = PURCHASE_LAND_OBLIGATIONS_REASON - } + } } ai_will_do = { @@ -786,6 +836,567 @@ purchase_land_interaction = { } } +purchase_sacred_land_interaction = { + category = interaction_category_laamp + icon = purchase_land_interaction + + desc = purchase_sacred_land_interaction_desc + target_type = title + target_filter = recipient_de_jure_titles + + cooldown_against_recipient = { years = 10 } + + notification_text = { + first_valid = { + triggered_desc = { + trigger = { + scope:recipient = { top_liege != this } + scope:recipient.highest_held_title_tier = tier_county + } + desc = PURCHASE_SACRED_LAND_PROPOSAL_FELLOW_VASSAL + } + triggered_desc = { + trigger = { + scope:recipient.highest_held_title_tier >= tier_duchy + } + desc = PURCHASE_SACRED_LAND_PROPOSAL_LIEGE + } + desc = PURCHASE_SACRED_LAND_PROPOSAL + } + } + + popup_on_receive = yes + pause_on_receive = yes + + interface_priority = 60 + ai_min_reply_days = 4 + ai_max_reply_days = 9 + + send_options_exclusive = no + + is_available = { + OR = { + government_has_flag = government_is_landless_adventurer + government_has_flag = government_is_landless_minority + } + } + + is_shown = { + has_ep3_dlc_trigger = yes + scope:recipient = { + is_landed = yes + NOT = { government_allows = noble_families } + } + scope:recipient != scope:actor + } + + has_valid_target = { + custom_tooltip = { + text = blank_line + scope:target ?= { + is_title_created = yes + tier = tier_county + NOT = { this = scope:recipient.capital_county } + holder = { + is_ai = yes + this = scope:recipient + } + any_county_province = { holding_is_church = yes } + } + } + } + + send_option = { + flag = offer_gold + localization = purchase_land_interaction_offer_gold + current_description = purchase_land_interaction_offer_gold_desc + } + + send_option = { + flag = hook + is_valid = { + scope:actor = { + has_usable_hook = scope:recipient + } + } + localization = GENERIC_SPEND_A_HOOK + } + + send_option = { + flag = offer_hook + is_valid = { + NOT = { + scope:recipient = { + has_usable_hook = scope:actor + } + } + } + localization = purchase_land_interaction_offer_hook + current_description = purchase_land_interaction_offer_hook_desc + } + + send_option = { + flag = vassal_obligation + is_shown = { + scope:recipient = { + government_has_flag = government_is_feudal + } + } + localization = purchase_land_interaction_offer_obligations + current_description = purchase_land_interaction_offer_obligations_desc + } + + can_be_picked_title = { + custom_tooltip = { + text = purchase_sacred_land_tier_tt + scope:target = { + tier = tier_county + } + } + custom_tooltip = { + text = purchase_land_capital_tt + scope:target != scope:recipient.capital_county + } + custom_tooltip = { + text = purchase_land_primary_tt + scope:target != scope:recipient.primary_title + } + custom_tooltip = { + text = purchase_sacred_land_temple_tt + scope:target = { + any_county_province = { holding_is_church = yes } + } + } + trigger_if = { + limit = { exists = scope:target.holder } + scope:target.holder = scope:recipient + } + } + + is_valid_showing_failures_only = { + scope:actor = { + top_liege = this + piety_level >= 3 + NOT = { has_trait = gallowsbait } + } + scope:recipient = { + is_contact_of = scope:actor + is_at_war = no + NOT = { has_strong_hook = scope:actor } + } + custom_tooltip = { + text = purchase_sacred_land_same_faith_tt + scope:recipient = { faith = scope:actor.faith } + } + trigger_if = { + limit = { + scope:target ?= { is_head_of_faith = yes } + } + custom_description = { + text = purchase_land_religious_tt + always = no + } + } + trigger_if = { + limit = { + scope:target ?= { is_noble_family_title = yes } + } + custom_description = { + text = purchase_land_noble_family_tt + always = no + } + } + trigger_if = { + limit = { + scope:target ?= { has_variable = adventurer_creation_reason } + } + custom_description = { + text = purchase_land_landless_adventurer_tt + always = no + } + } + trigger_if = { + limit = { + scope:recipient = { + any_held_county = { count < 2 } + } + } + custom_description = { + text = purchase_land_minimum_county_tt + object = scope:recipient + always = no + } + } + custom_tooltip = { + text = purchase_sacred_land_no_valid_title_tt + scope:recipient = { + any_held_county = { + NOT = { this = scope:recipient.capital_county } + any_county_province = { holding_is_church = yes } + } + } + } + ep3_laamp_diplo_range_trigger = { + TARGET = scope:recipient + LAAMP = scope:actor + } + custom_tooltip = { + text = the_wake_1 + NOT = { + is_laamp_exiled_from_province_trigger = { + PROVINCE = scope:recipient.capital_province + LAAMP = scope:actor + } + } + } + } + + cost = { + piety = major_piety_value + gold = { + value = purchase_land_county_cost_value + multiply = 0.5 + if = { + limit = { + scope:actor = { has_variable = ep3_grace_to_the_family_var } + } + multiply = 0.5 + } + if = { + limit = { scope:offer_gold = yes } + multiply = 2 + } + } + } + + on_accept = { + scope:actor = { save_scope_as = adventurer } + scope:target = { + save_scope_as = purchase_land_target + add_to_list = purchased_titles + } + ordered_in_list = { + list = purchased_titles + order_by = tier + save_scope_as = new_primary_title + } + save_scope_value_as = { + name = purchase_land_cost + value = { + value = purchase_land_county_cost_value + multiply = 0.5 + if = { + limit = { + scope:actor = { has_variable = ep3_grace_to_the_family_var } + } + multiply = 0.5 + } + if = { + limit = { scope:offer_gold = yes } + multiply = 2 + } + } + } + save_scope_value_as = { + name = purchase_land_legitimacy_cost + value = { + value = 0 + if = { + limit = { + scope:target.holder != scope:recipient + } + every_in_list = { + list = purchased_titles + add = minor_legitimacy_loss + } + } + } + } + show_as_tooltip = { + scope:actor = { purchase_land_interaction_effect = yes } + } + scope:actor = { + if = { + limit = { + faith.faith_theocratic_goverment_type = government_type:ecclesiastical_government + } + custom_tooltip = purchase_sacred_land_ecclesiastical_tt + } + else = { + custom_tooltip = purchase_sacred_land_theocracy_tt + } + } + if = { + limit = { + always = scope:hook + scope:actor = { has_usable_hook = scope:recipient } + } + scope:actor = { use_hook = scope:recipient } + } + hidden_effect = { + scope:actor = { + add_gold = scope:purchase_land_cost + } + } + scope:actor = { trigger_event = ep3_laamps.0100 } + scope:actor = { + trigger_event = { + id = ep3_laamps.0103 + days = 0 + } + } + } + + on_decline = { + scope:actor = { + save_scope_as = adventurer + trigger_event = ep3_laamps.0102 + } + } + + ai_targets = { + ai_recipients = domicile_location_top_ruler + ai_recipients = contacts + } + + ai_targets = { + ai_recipients = domicile_location_neighboring_top_realm_vassals + ai_recipients = domicile_location_top_realm_vassals + ai_recipients = domicile_location_neighboring_top_rulers + max = 20 + } + ai_frequency_by_tier = { + barony = 0 + county = 0 + duchy = 60 + kingdom = 0 + empire = 0 + hegemony = 0 + } + + ai_accept = { + base = 0 + + opinion_modifier = { + who = scope:recipient + opinion_target = scope:actor + multiplier = 1 + desc = AI_OPINION_REASON + } + modifier = { + add = -30 + desc = PURCHASE_LAND_NUM_TITLES_REASON + } + modifier = { + add = -50 + desc = PURCHASE_LAND_DE_JURE_DUCHY_REASON + scope:target.duchy ?= scope:recipient.capital_county.duchy + } + modifier = { + add = { + value = 0 + if = { + limit = { exists = scope:target } + add = scope:target.development_level + scope:target = { + every_county_province = { add = num_buildings } + } + } + multiply = -2 + } + desc = PURCHASE_LAND_VALUE_REASON + } + modifier = { + add = 20 + desc = PURCHASE_LAND_FOREIGN_CULTURE_REASON + scope:target.culture != scope:recipient.culture + } + modifier = { + add = 10 + desc = PURCHASE_LAND_DIFFERENT_FAITH_REASON + scope:target.faith != scope:recipient.faith + } + modifier = { + add = { + value = -40 + if = { + limit = { scope:acceptance != 0 } + divide = scope:acceptance + } + multiply = 2 + min = -200 + } + desc = PURCHASE_LAND_MY_CULTURE_REASON + scope:actor.culture != scope:recipient.culture + scope:target.culture = scope:recipient.culture + scope:recipient.culture = { + save_temporary_scope_value_as = { + name = acceptance + value = { + value = "cultural_acceptance(scope:actor.culture)" + divide = 25 + ceiling = yes + } + } + } + } + modifier = { + add = { + value = 0 + add = scope:distance + divide = scope:recipient.highest_held_title_tier + if = { + limit = { scope:distance <= squared_distance_medium } + multiply = -0.01 + } + else = { multiply = 0.0005 } + min = -25 + max = 50 + } + desc = PURCHASE_LAND_DISTANCE_REASON + scope:target = { save_temporary_scope_as = distance_target } + scope:recipient.capital_county = { + save_temporary_scope_value_as = { + name = distance + value = "squared_distance(scope:distance_target)" + } + } + } + opinion_modifier = { + trigger = { + NOT = { + scope:target.holder ?= scope:recipient + } + } + who = scope:recipient + opinion_target = scope:target.holder + multiplier = -1 + desc = AI_OPINION_REASON + } + modifier = { + add = { + value = scope:actor.piety_level + multiply = 20 + } + desc = PURCHASE_SACRED_LAND_PIETY_LEVEL_REASON + } + modifier = { + add = 40 + scope:recipient = { has_trait = zealous } + desc = ASK_FOR_CONVERSION_RECIPIENT_IS_ZEALOUS + } + modifier = { + add = { + value = scope:actor.prestige_level + multiply = 20 + } + scope:actor.prestige_level >= 4 + desc = PURCHASE_LAND_PRESTIGE_LEVEL_REASON + } + modifier = { + add = 40 + trigger = { + scope:actor.culture != scope:recipient.culture + scope:target.culture = scope:recipient.culture + } + scope:actor.primary_spouse ?= { + culture = scope:recipient.culture + dynasty ?= { + dynasty_prestige_level >= 2 + } + } + desc = PURCHASE_LAND_MARRIED_TO_CULTURE_NOBLE_REASON + } + modifier = { + add = 80 + scope:actor.primary_spouse ?= { + house ?= scope:recipient.house + } + desc = PURCHASE_LAND_MARRIED_TO_HOUSE_REASON + } + modifier = { + add = 20 + trigger = { + scope:target.culture = scope:recipient.culture + } + scope:actor = { + knows_language_of_culture = scope:recipient.culture + culture != scope:recipient.culture + } + desc = PURCHASE_LAND_SPEAKS_LANGUAGE_REASON + } + modifier = { + add = -40 + scope:actor = { + NOT = { + knows_language_of_culture = scope:recipient.culture + culture = scope:recipient.culture + } + } + desc = PURCHASE_LAND_DOES_NOT_SPEAK_LANGUAGE_REASON + } + modifier = { + add = { + value = 40 + multiply = scope:recipient.debt_level + } + trigger = { + scope:recipient = { + OR = { + debt_level > 0 + treasury_debt_level > 0 + } + } + } + desc = PURCHASE_LAND_IS_IN_DEBT_REASON + } + modifier = { + add = 60 + scope:actor = { + has_any_moderate_good_relationship_with_character_trigger = { CHARACTER = scope:recipient } + } + desc = PURCHASE_LAND_RELATIONSHIP_REASON + } + modifier = { + add = 80 + scope:offer_gold = yes + desc = PURCHASE_LAND_DOUBLE_GOLD_REASON + } + modifier = { + add = 160 + scope:hook = yes + desc = YOU_HAVE_HOOK_REASON + } + modifier = { + add = 60 + scope:offer_hook = yes + desc = PURCHASE_LAND_OFFER_HOOK_REASON + } + modifier = { + add = 80 + scope:vassal_obligation = yes + desc = PURCHASE_LAND_OBLIGATIONS_REASON + } + } + + ai_will_do = { + base = -25 + ai_value_modifier = { + ai_boldness = -0.5 + ai_energy = -0.5 + ai_zeal = 0.5 + } + modifier = { + piety < major_piety_value + factor = 0 + } + modifier = { + piety_level >= 4 + add = 50 + } + } +} + ################## # Request Invasion Sponsorship # by Joe Parkin @@ -807,11 +1418,11 @@ request_laamp_invasion_sponsorship_interaction = { desc = request_laamp_invasion_sponsorship_interaction_desc is_shown = { - has_ep3_dlc_trigger = yes scope:actor = { OR = { government_has_flag = government_is_landless_adventurer government_has_flag = government_is_landless_minority } } + NOT = { scope:actor = { has_realm_law = camp_purpose_legitimists } } + has_ep3_dlc_trigger = yes scope:recipient = { is_landed = yes } scope:recipient != scope:actor - NOT = { scope:actor = { has_realm_law = camp_purpose_legitimists } } } is_valid_showing_failures_only = { @@ -862,7 +1473,7 @@ request_laamp_invasion_sponsorship_interaction = { add_to_list = characters } } - + send_options_exclusive = no send_option = { @@ -928,7 +1539,7 @@ request_laamp_invasion_sponsorship_interaction = { scope:join_war = yes scope:request_soldiers = yes } - } + } } on_accept = { @@ -1089,7 +1700,7 @@ request_laamp_invasion_sponsorship_interaction = { # Pacifist AI don't like raiding modifier = { add = -25 - scope:recipient.faith = { has_doctrine_parameter = pacifist_opinion_active } + scope:recipient.faith = { has_doctrine_parameter = pacifist } desc = PT_AI_IS_PACIFIST_FAITH } modifier = { @@ -1277,11 +1888,32 @@ negotiate_settlement_interaction = { ai_min_reply_days = 4 ai_max_reply_days = 9 - is_shown = { + is_available = { + trigger_if = { + limit = { is_ai = yes } + OR = { + has_trait = generous + has_trait = craven + is_at_war = yes + } + OR = { + top_liege ?= this + highest_held_title_tier >= tier_kingdom + } + NOT = { + government_has_flag = government_is_nomadic + } + } + is_landed = yes has_ep3_dlc_trigger = yes - scope:actor = { is_landed = yes } + } + + is_shown = { scope:recipient = { - OR = { government_has_flag = government_is_landless_adventurer government_has_flag = government_is_landless_minority } + OR = { + government_has_flag = government_is_landless_adventurer + government_has_flag = government_is_landless_minority + } } scope:recipient != scope:actor } @@ -1311,7 +1943,7 @@ negotiate_settlement_interaction = { tier = tier_duchy any_de_jure_county = { ep3_negotiate_settlement_valid_county_trigger = yes - } + } } } trigger_if = { @@ -1442,15 +2074,10 @@ negotiate_settlement_interaction = { always = no } } - trigger_if = { - limit = { - scope:actor = { - any_held_county = { count < 2 } - } - } + scope:actor = { custom_description = { text = negotiate_settlement_minimum_county_tt - always = no + any_held_county = { count >= 2 } } } scope:recipient = { @@ -1473,9 +2100,9 @@ negotiate_settlement_interaction = { } # Story blockers. ## Hereward cannot be exiled by active participants in the Harrying of the North. -# disable_interaction_for_hereward_trigger = yes + disable_interaction_for_hereward_trigger = yes ## Hasan cannot be exiled by anyone during his story. -# disable_interaction_for_hasan_trigger = yes + disable_interaction_for_hasan_trigger = yes } on_send = { @@ -1499,22 +2126,7 @@ negotiate_settlement_interaction = { list = offered_titles save_scope_as = new_primary_title } - save_scope_value_as = { - name = negotiate_settlement_legitimacy_cost - value = { - value = 0 - every_in_list = { - list = offered_titles - if = { - limit = { tier = tier_county } - add = -25 - } - else = { add = -50 } - } - multiply = scope:actor.highest_held_title_tier - } - } - show_as_tooltip = { negotiate_settlement_interaction_effect = yes } + show_as_tooltip = { scope:actor = { negotiate_settlement_interaction_effect = yes } } scope:actor = { trigger_event = ep3_laamps.0300 } } @@ -1526,7 +2138,6 @@ negotiate_settlement_interaction = { ai_targets = { ai_recipients = scripted_relations - ai_recipients = spouses max = 5 } ai_targets = { @@ -1543,27 +2154,12 @@ negotiate_settlement_interaction = { ai_frequency_by_tier = { barony = 0 county = 0 - duchy = 3 + duchy = 12 kingdom = 3 empire = 3 hegemony = 3 } - ai_potential = { - OR = { - top_liege = this - highest_held_title_tier >= tier_kingdom - } - OR = { - is_at_war = yes - has_trait = craven - has_trait = generous - } - NOT = { - government_has_flag = government_is_nomadic - } - } - ai_accept = { base = 0 # Try to make it 0 for most interactions @@ -1999,7 +2595,10 @@ negotiate_settlement_interaction = { } modifier = { scope:recipient = { - has_government = landless_adventurer_government + OR = { + has_government = landless_adventurer_government + has_government = landless_minority_government + } has_realm_law = camp_purpose_legitimists any_claim = { OR = { @@ -2018,10 +2617,13 @@ negotiate_settlement_interaction = { primary_defender = scope:actor any_war_attacker = { scope:recipient ?= this - has_government = landless_adventurer_government + OR = { + has_government = landless_adventurer_government + has_government = landless_minority_government + } NOT = { has_realm_law = camp_purpose_legitimists } # Attacking laamp's troops at least 10% of defender's total troops - current_military_strength > war_defender_total_strength_tenth_value + current_military_strength > prev.war_defender_total_strength_tenth_value } OR = { attacker_war_score >= 25 @@ -2037,10 +2639,13 @@ negotiate_settlement_interaction = { primary_defender = scope:actor any_war_attacker = { scope:recipient ?= this - has_government = landless_adventurer_government + OR = { + has_government = landless_adventurer_government + has_government = landless_minority_government + } NOT = { has_realm_law = camp_purpose_legitimists } # Attacking laamp's troops at least 10% of defender's total troops - current_military_strength > war_defender_total_strength_tenth_value + current_military_strength > prev.war_defender_total_strength_tenth_value } } add = { @@ -2068,9 +2673,12 @@ negotiate_settlement_interaction = { primary_attacker = scope:actor any_war_defender = { scope:recipient ?= this - has_government = landless_adventurer_government + OR = { + has_government = landless_adventurer_government + has_government = landless_minority_government + } # Defending laamp's troops at least 10% of attacker's total troops - current_military_strength > war_attacker_total_strength_tenth_value + current_military_strength > prev.war_attacker_total_strength_tenth_value } OR = { defender_war_score >= 25 @@ -2086,9 +2694,12 @@ negotiate_settlement_interaction = { primary_attacker = scope:actor any_war_defender = { scope:recipient ?= this - has_government = landless_adventurer_government + OR = { + has_government = landless_adventurer_government + has_government = landless_minority_government + } # Defending laamp's troops at least 10% of attacker's total troops - current_military_strength > war_attacker_total_strength_tenth_value + current_military_strength > prev.war_attacker_total_strength_tenth_value } } add = { @@ -2422,9 +3033,16 @@ trade_oath_interaction = { desc = trade_oath_interaction_desc + is_available = { + domicile ?= { has_domicile_parameter = camp_unlock_trade_oath_interaction } + trigger_if = { + limit = { is_ai = yes } + has_realm_law = camp_purpose_legitimists + } + } + is_shown = { scope:actor = { - domicile ?= { has_domicile_parameter = camp_unlock_trade_oath_interaction } NOT = { has_strong_hook = scope:recipient } } scope:recipient = { @@ -2454,7 +3072,7 @@ trade_oath_interaction = { type = loyalty_hook target = scope:recipient } - } + } scope:recipient = { add_hook = { type = follower_oath_hook @@ -2512,9 +3130,6 @@ trade_oath_interaction = { has_trait = honest } } - ai_potential = { - has_realm_law = camp_purpose_legitimists - } # Always do it if you get the chance. ai_will_do = { base = 1000 } @@ -2544,10 +3159,14 @@ pawn_gear_interaction = { target_type = artifact target_filter = actor_artifacts + show_all_targets = no + + is_available = { + domicile ?= { has_domicile_parameter = camp_unlocks_pawn_gear_interaction } + } is_shown = { scope:actor = { - domicile ?= { has_domicile_parameter = camp_unlocks_pawn_gear_interaction } this = scope:recipient } } @@ -2556,24 +3175,15 @@ pawn_gear_interaction = { scope:actor = { is_at_war = no is_imprisoned = no - has_any_artifact = yes - trigger_if = { - limit = { is_ai = no } - custom_description = { - text = "any_unequipped_artifact_tt" - any_character_artifact = { is_equipped = no } - } + custom_description = { + text = "any_unequipped_artifact_tt" + has_any_unequipped_artifact = yes } } } can_be_picked_artifact = { - trigger_if = { - limit = { - scope:actor = { is_ai = no } - } - scope:target = { is_equipped = no } - } + scope:target = { is_equipped = no } scope:actor = { any_character_artifact = { this = scope:target } } @@ -2627,8 +3237,11 @@ complete_task_contract_interaction = { } } } - + is_valid_showing_failures_only = { + scope:actor = { + is_available = yes + } } is_highlighted = { @@ -2641,6 +3254,16 @@ complete_task_contract_interaction = { send_option = { flag = with_domicile + is_valid = { + custom_tooltip = { + text = the_wake_1 + NOT = { + scope:recipient = { + is_laamp_exiled_from_holder_or_liege_trigger = { LAAMP = scope:actor } + } + } + } + } } on_accept = { @@ -2786,7 +3409,7 @@ complete_task_contract_interaction = { ################## # Make a Request # by Arkadiusz Majewski -# As a LAAMP you can ask characters on your contact list for something +# As a LAAMP you can ask characters on your contact list for something ################## contact_list_request_interaction = { # make a request, make_a_request @@ -2794,6 +3417,7 @@ contact_list_request_interaction = { # make a request, make_a_request interface_priority = 110 icon = icon_scheme_befriend desc = contact_list_request_interaction_desc + notification_text = contact_list_request_interaction_notification common_interaction = yes popup_on_receive = yes @@ -2804,9 +3428,19 @@ contact_list_request_interaction = { # make a request, make_a_request cooldown_against_recipient = { months = 8 } + is_available = { + trigger_if = { + limit = { is_ai = yes } + OR = { + government_has_flag = government_is_landless_adventurer + government_has_flag = government_is_landless_minority + } + } + } + is_shown = { - has_ep3_dlc_trigger = yes scope:actor = { OR = { government_has_flag = government_is_landless_adventurer government_has_flag = government_is_landless_minority } } + has_ep3_dlc_trigger = yes scope:actor != scope:recipient } is_valid_showing_failures_only = { @@ -2862,7 +3496,7 @@ contact_list_request_interaction = { # make a request, make_a_request is_landed = yes gold > 20 AND = { - is_landed_or_landless_administrative = yes + is_landed_or_landless_administrative_or_theocratic = yes scope:actor.maa_regiments_count < scope:actor.maa_regiments_max_count } AND = { @@ -2920,7 +3554,7 @@ contact_list_request_interaction = { # make a request, make_a_request flag = request_maa is_valid = { scope:recipient = { - is_landed_or_landless_administrative = yes + is_landed_or_landless_administrative_or_theocratic = yes } custom_tooltip = { scope:actor.maa_regiments_count < scope:actor.maa_regiments_max_count @@ -3032,6 +3666,7 @@ contact_list_request_interaction = { # make a request, make_a_request scope:actor = { any_character_task_contract = { count = all + exists = task_contract_employer task_contract_employer != scope:recipient } is_ai = no @@ -3103,7 +3738,7 @@ contact_list_request_interaction = { # make a request, make_a_request has_perk = inspiring_rule_perk } scope:recipient = { - is_landed_or_landless_administrative = yes + is_landed_or_landless_administrative_or_theocratic = yes capital_province ?= { squared_distance = { target = scope:actor.capital_province @@ -3121,7 +3756,7 @@ contact_list_request_interaction = { # make a request, make_a_request } scope:actor = { custom_tooltip = { - text = ACTIVITY_SUMMARY_COOLDOWN_HEADER + text = contact_list_request_interaction.request_feast_cooldown NOT = { has_character_flag = laamp_recently_requested_feast } } } @@ -3995,7 +4630,6 @@ contact_list_request_interaction = { # make a request, make_a_request scope:actor = { has_usable_hook = scope:recipient } scope:recipient = { is_ai = yes } } - ai_potential = { OR = { government_has_flag = government_is_landless_adventurer government_has_flag = government_is_landless_minority } } ai_accept = { base = 0 @@ -4244,7 +4878,7 @@ contact_list_request_interaction = { # make a request, make_a_request } } } - + ## Persuasive modifier = { add = 6 @@ -4412,7 +5046,7 @@ seize_realm_interaction = { on_accept = { scope:actor = { - stress_impact = { + stress_and_fulfillment_impact = { compassionate = major_stress_impact_gain honest = medium_stress_impact_gain just = medium_stress_impact_gain @@ -4422,7 +5056,7 @@ seize_realm_interaction = { send_interface_toast = { title = start_seize_realm_interaction_notification - left_icon = scope:actor + left_icon = scope:actor right_icon = scope:recipient # Success. @@ -4494,7 +5128,7 @@ seize_realm_interaction = { } show_as_tooltip = { - stress_impact = { + stress_and_fulfillment_impact = { honest = medium_stress_impact_gain just = medium_stress_impact_gain } @@ -4503,7 +5137,7 @@ seize_realm_interaction = { } custom_tooltip = seize_realm_warning } - + auto_accept = yes } @@ -4520,12 +5154,17 @@ reinforce_soldiers_interaction = { desc = reinforce_soldiers_interaction_desc cooldown = { months = 6 } + is_available = { + government_allows = conditional_maa_refill + NOT = { government_has_flag = government_is_nomadic } + trigger_if = { + limit = { is_ai = yes } + any_maa_regiment = { maa_current_troops_count < maa_max_troops_count } + } + } + is_shown = { has_ep3_dlc_trigger = yes - scope:actor = { - government_allows = conditional_maa_refill - NOT = { government_has_flag = government_is_nomadic } - } scope:recipient = scope:actor } @@ -4587,11 +5226,11 @@ reinforce_soldiers_interaction = { localization = reinforce_soldiers_option_dread current_description = reinforce_soldiers_option_dread_desc is_valid = { - custom_tooltip = { - text = reinforce_soldiers_option_dread_tt - OR = { - scope:actor.dread >= reinforce_soldiers_dread_cost_value - scope:actor = { + scope:actor = { + custom_tooltip = { + text = reinforce_soldiers_option_dread_tt + OR = { + dread >= reinforce_soldiers_dread_cost_value has_character_modifier = ep3_friend_to_old_soldiers_modifier } } @@ -4726,10 +5365,6 @@ reinforce_soldiers_interaction = { ai_targets = { ai_recipients = self } - ai_potential = { - government_allows = conditional_maa_refill - any_maa_regiment = { maa_current_troops_count < maa_max_troops_count } - } ai_will_do = { base = 100 @@ -4780,16 +5415,29 @@ hire_laamp_mercenaries_interaction = { can_send_despite_rejection = yes ai_accept_negotiation = yes send_options_exclusive = no + is_available = { + trigger_if = { + limit = { is_ai = yes } + any_character_war = { + is_war_leader = prev + } + war_chest_gold >= quarter_ai_war_chest_gold_maximum + } + } + is_shown = { has_ep3_dlc_trigger = yes scope:recipient = { - has_government = landless_adventurer_government + OR = { + has_government = landless_adventurer_government + has_government = landless_minority_government + } } - scope:actor != scope:recipient - scope:actor = { + scope:puppet_or_actor ?= { + this != scope:recipient trigger_if = { # Avoid calling Adventurers without armies limit = { - is_ai = yes + scope:actor = { is_ai = yes } } scope:recipient.current_military_strength >= 100 scope:recipient = { @@ -4806,42 +5454,45 @@ hire_laamp_mercenaries_interaction = { is_at_war = no is_imprisoned = no } - scope:actor = { + scope:puppet_or_actor = { custom_tooltip = { text = MERCENARY_COMPANY_COST_BANKRUPTCY debt_level <= 1 } is_at_war = yes custom_tooltip = { - text = I_MUST_BE_THE_WAR_LEADER + text = I_MUST_BE_THE_WAR_LEADER any_character_war = { - is_war_leader = scope:actor + is_war_leader = scope:puppet_or_actor } } NOT = { is_at_war_with = scope:recipient } } - scope:actor = { + scope:puppet_or_actor = { NOT = { any_war_ally = { count >= 3 - has_government = landless_adventurer_government + OR = { + has_government = landless_adventurer_government + has_government = landless_minority_government + } } } } - scope:actor = { + scope:puppet_or_actor = { OR = { - is_ai = no + scope:actor = { is_ai = no } any_character_war = { count = all OR = { AND = { - primary_attacker = scope:actor + primary_attacker = scope:puppet_or_actor defender_war_score <= 95 } AND = { - primary_defender = scope:actor + primary_defender = scope:puppet_or_actor attacker_war_score <= 95 } } @@ -4851,13 +5502,13 @@ hire_laamp_mercenaries_interaction = { # Adventurers can't join wars in places they're exiled from. trigger_if = { limit = { - scope:actor = { top_liege != this } + scope:puppet_or_actor = { top_liege != this } } custom_tooltip = { text = the_wake_1 NOT = { is_laamp_exiled_from_province_trigger = { - PROVINCE = scope:actor.capital_province + PROVINCE = scope:puppet_or_actor.capital_province LAAMP = scope:recipient } } @@ -4868,15 +5519,15 @@ hire_laamp_mercenaries_interaction = { auto_accept = { custom_description = { text = "spending_hook" - subject = scope:actor + subject = scope:puppet_or_actor object = scope:recipient scope:hook = yes - scope:actor = { has_strong_hook = scope:recipient } + scope:puppet_or_actor = { has_strong_hook = scope:recipient } } } on_accept = { - scope:actor = { + scope:puppet_or_actor = { every_character_war = { add_to_list = actor_wars } @@ -4884,7 +5535,7 @@ hire_laamp_mercenaries_interaction = { every_in_list = { list = actor_wars limit = { - primary_defender = scope:actor + primary_defender = scope:puppet_or_actor } add_to_list = join_as_defender remove_from_list = actor_wars @@ -4892,12 +5543,12 @@ hire_laamp_mercenaries_interaction = { every_in_list = { list = actor_wars limit = { - primary_attacker = scope:actor + primary_attacker = scope:puppet_or_actor } add_to_list = join_as_attacker remove_from_list = actor_wars } - + every_in_list = { list = join_as_attacker add_attacker = scope:recipient @@ -4917,7 +5568,7 @@ hire_laamp_mercenaries_interaction = { custom_tooltip = hire_laamp_mercenaries_interaction.war } } - scope:actor = { + scope:puppet_or_actor = { if = { limit = { has_treasury = no @@ -4945,20 +5596,22 @@ hire_laamp_mercenaries_interaction = { situation_top_has_catalyst = catalyst_hegemon_hired_mercenary } } - trigger_situation_catalyst = { - catalyst = catalyst_hegemon_hired_mercenary - character = scope:actor + situation:dynastic_cycle ?= { + trigger_situation_catalyst = { + catalyst = catalyst_hegemon_hired_mercenary + character = scope:puppet_or_actor + } } } } scope:recipient = { set_variable = { name = joined_as_mercenary - value = scope:actor + value = scope:puppet_or_actor } } add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = medium_unity_gain DESC = clan_unity_alliance.desc @@ -5002,7 +5655,7 @@ hire_laamp_mercenaries_interaction = { # } #} add_clan_unity_interaction_effect = { - CHARACTER = scope:actor + CHARACTER = scope:puppet_or_actor TARGET = scope:recipient VALUE = minor_unity_loss DESC = clan_unity_alliance_refusal.desc @@ -5013,7 +5666,7 @@ hire_laamp_mercenaries_interaction = { # Use hook send_option = { is_valid = { - scope:actor = { + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } @@ -5021,7 +5674,7 @@ hire_laamp_mercenaries_interaction = { localization = SCHEME_HOOK } should_use_extra_icon = { - scope:actor = { has_usable_hook = scope:recipient } + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } extra_icon = "gfx/interface/icons/character_interactions/hook_icon.dds" @@ -5036,12 +5689,6 @@ hire_laamp_mercenaries_interaction = { ai_targets = { ai_recipients = nearby_domicile_owners } - ai_potential = { - any_character_war = { - is_war_leader = prev - } - war_chest_gold >= quarter_ai_war_chest_gold_maximum - } ai_accept = { base = -20 @@ -5058,9 +5705,9 @@ hire_laamp_mercenaries_interaction = { name = attacker_war value = 2 } - scope:actor = { + scope:puppet_or_actor = { any_character_war = { - primary_attacker = scope:actor + primary_attacker = scope:puppet_or_actor attacker_war_score < 0 save_temporary_scope_value_as = { name = attacker_war @@ -5080,9 +5727,9 @@ hire_laamp_mercenaries_interaction = { name = defender_war value = 2 } - scope:actor = { + scope:puppet_or_actor = { any_character_war = { - primary_defender = scope:actor + primary_defender = scope:puppet_or_actor defender_war_score < 0 save_temporary_scope_value_as = { name = defender_war @@ -5099,7 +5746,7 @@ hire_laamp_mercenaries_interaction = { modifier = { # Refuse call against Heir add = -1000 exists = scope:recipient.player_heir - scope:actor = { + scope:puppet_or_actor = { any_character_war = { OR = { primary_defender = scope:recipient.player_heir @@ -5112,7 +5759,7 @@ hire_laamp_mercenaries_interaction = { modifier = { # Refuse call against Spouse add = -1000 - scope:actor = { + scope:puppet_or_actor = { any_character_war = { OR = { primary_defender = { @@ -5129,7 +5776,7 @@ hire_laamp_mercenaries_interaction = { opinion_modifier = { # Opinion Factor who = scope:recipient - opinion_target = scope:actor + opinion_target = scope:puppet_or_actor desc = AI_OPINION_REASON } @@ -5143,35 +5790,35 @@ hire_laamp_mercenaries_interaction = { modifier = { # Tends to join defensive wars add = 50 - scope:actor = { + scope:puppet_or_actor = { any_character_war = { - primary_defender = scope:actor + primary_defender = scope:puppet_or_actor } } desc = DEFENSIVE_WAR_REASON } - + modifier = { # Same language add = 5 desc = speaks_same_language_interaction_reason - scope:actor = { + scope:puppet_or_actor = { knows_language_of_culture = scope:recipient.culture } } compare_modifier = { # Likes fighting infidels trigger = { - scope:recipient.faith = scope:actor.faith - scope:actor = { + scope:recipient.faith = scope:puppet_or_actor.faith + scope:puppet_or_actor = { any_character_war = { trigger_if = { limit = { - primary_defender = scope:actor + primary_defender = scope:puppet_or_actor } primary_attacker = { faith = { faith_hostility_level = { - target = scope:actor.faith + target = scope:puppet_or_actor.faith value >= religious_cb_enabled_hostility_level } } @@ -5179,16 +5826,16 @@ hire_laamp_mercenaries_interaction = { } trigger_else_if = { limit = { - primary_attacker = scope:actor + primary_attacker = scope:puppet_or_actor } primary_defender = { faith = { faith_hostility_level = { - target = scope:actor.faith + target = scope:puppet_or_actor.faith value >= religious_cb_enabled_hostility_level } } - } + } } trigger_else = { always = no @@ -5205,9 +5852,9 @@ hire_laamp_mercenaries_interaction = { modifier = { # Reluctant to attack another ally add = -50 - scope:actor = { + scope:puppet_or_actor = { any_character_war = { - primary_defender != scope:actor + primary_defender != scope:puppet_or_actor primary_defender = { is_allied_to = scope:recipient } @@ -5218,9 +5865,9 @@ hire_laamp_mercenaries_interaction = { modifier = { # Reluctant to defend against another ally add = -25 - scope:actor = { + scope:puppet_or_actor = { any_character_war = { - primary_attacker != scope:actor + primary_attacker != scope:puppet_or_actor primary_attacker = { is_allied_to = scope:recipient } @@ -5231,8 +5878,8 @@ hire_laamp_mercenaries_interaction = { modifier = { # Reluctant to join wars against religious brethren. add = -50 - scope:recipient.faith != scope:actor.faith - scope:actor = { + scope:recipient.faith != scope:puppet_or_actor.faith + scope:puppet_or_actor = { any_character_war = { OR = { using_cb = minor_religious_war @@ -5242,11 +5889,11 @@ hire_laamp_mercenaries_interaction = { using_cb = directed_great_holy_war OR = { AND = { - primary_attacker != scope:actor + primary_attacker != scope:puppet_or_actor primary_attacker.faith = scope:recipient.faith } AND = { - primary_defender != scope:actor + primary_defender != scope:puppet_or_actor primary_defender.faith = scope:recipient.faith } } @@ -5258,17 +5905,17 @@ hire_laamp_mercenaries_interaction = { modifier = { # Reluctant to join against Friends add = -50 - scope:actor = { + scope:puppet_or_actor = { any_character_war = { OR = { AND = { - primary_attacker != scope:actor + primary_attacker != scope:puppet_or_actor primary_attacker = { has_relation_friend = scope:recipient } } AND = { - primary_defender != scope:actor + primary_defender != scope:puppet_or_actor primary_defender = { has_relation_friend = scope:recipient } @@ -5280,17 +5927,17 @@ hire_laamp_mercenaries_interaction = { modifier = { # Reluctant to join against Best Friends add = -100 - scope:actor = { + scope:puppet_or_actor = { any_character_war = { OR = { AND = { - primary_attacker != scope:actor + primary_attacker != scope:puppet_or_actor primary_attacker = { has_relation_best_friend = scope:recipient } } AND = { - primary_defender != scope:actor + primary_defender != scope:puppet_or_actor primary_defender = { has_relation_best_friend = scope:recipient } @@ -5301,17 +5948,17 @@ hire_laamp_mercenaries_interaction = { } modifier = { # Reluctant to join against Lovers add = -100 - scope:actor = { + scope:puppet_or_actor = { any_character_war = { OR = { AND = { - primary_attacker != scope:actor + primary_attacker != scope:puppet_or_actor primary_attacker = { has_relation_lover = scope:recipient } } AND = { - primary_defender != scope:actor + primary_defender != scope:puppet_or_actor primary_defender = { has_relation_lover = scope:recipient } @@ -5322,17 +5969,17 @@ hire_laamp_mercenaries_interaction = { } modifier = { # Reluctant to join against Soul mate add = -200 - scope:actor = { + scope:puppet_or_actor = { any_character_war = { OR = { AND = { - primary_attacker != scope:actor + primary_attacker != scope:puppet_or_actor primary_attacker = { has_relation_soulmate = scope:recipient } } AND = { - primary_defender != scope:actor + primary_defender != scope:puppet_or_actor primary_defender = { has_relation_soulmate = scope:recipient } @@ -5345,8 +5992,8 @@ hire_laamp_mercenaries_interaction = { any_home_court_hostage = { warden = { OR = { - is_at_war_with = scope:actor - any_ally = { is_at_war_with = scope:actor } + is_at_war_with = scope:puppet_or_actor + any_ally = { is_at_war_with = scope:puppet_or_actor } } } } @@ -5356,8 +6003,8 @@ hire_laamp_mercenaries_interaction = { limit = { warden = { OR = { - is_at_war_with = scope:actor - any_ally = { is_at_war_with = scope:actor } + is_at_war_with = scope:puppet_or_actor + any_ally = { is_at_war_with = scope:puppet_or_actor } } } } @@ -5376,23 +6023,23 @@ hire_laamp_mercenaries_interaction = { #don't do it if hired army wouldn't have an impact modifier = { - scope:actor = { + scope:puppet_or_actor = { any_character_war = { count = all OR = { AND = { - primary_attacker = scope:actor + primary_attacker = scope:puppet_or_actor primary_defender.current_military_strength > { value = scope:recipient.current_military_strength - add = scope:actor.current_military_strength + add = scope:puppet_or_actor.current_military_strength multiply = 1.5 } - } + } AND = { - primary_defender = scope:actor + primary_defender = scope:puppet_or_actor primary_attacker.current_military_strength > { value = scope:recipient.current_military_strength - add = scope:actor.current_military_strength + add = scope:puppet_or_actor.current_military_strength multiply = 1.5 } } @@ -5404,17 +6051,17 @@ hire_laamp_mercenaries_interaction = { #don't do it if you are stronger than the enemy modifier = { - scope:actor = { + scope:puppet_or_actor = { any_character_war = { count = all OR = { AND = { - primary_attacker = scope:actor - primary_defender.current_military_strength < scope:actor.current_military_strength + primary_attacker = scope:puppet_or_actor + primary_defender.current_military_strength < scope:puppet_or_actor.current_military_strength } AND = { - primary_defender = scope:actor - primary_attacker.current_military_strength < scope:actor.current_military_strength + primary_defender = scope:puppet_or_actor + primary_attacker.current_military_strength < scope:puppet_or_actor.current_military_strength } } } @@ -5424,14 +6071,14 @@ hire_laamp_mercenaries_interaction = { #more likely to ask if on contact list modifier = { - scope:actor = { + scope:puppet_or_actor = { is_contact_of = scope:recipient } add = 100 } #merc laamp wants to join, so why not asking them more? - modifier = { + modifier = { scope:recipient = { has_realm_law = camp_purpose_mercenaries } @@ -5440,15 +6087,15 @@ hire_laamp_mercenaries_interaction = { #more likely to ask if losing modifier = { - scope:actor = { + scope:puppet_or_actor = { any_character_war = { OR = { AND = { - primary_attacker = scope:actor + primary_attacker = scope:puppet_or_actor defender_war_score > 25 } AND = { - primary_defender = scope:actor + primary_defender = scope:puppet_or_actor attacker_war_score > 25 } } @@ -5459,16 +6106,16 @@ hire_laamp_mercenaries_interaction = { #don't do it if they betrayed you already in any of your ongoing wars modifier = { - scope:actor = { + scope:puppet_or_actor = { any_character_war = { OR = { is_target_in_variable_list = { name = already_switched_side - target = scope:recipient + target = scope:recipient } is_target_in_variable_list = { name = left_voluntarily - target = scope:recipient + target = scope:recipient } } } @@ -5478,13 +6125,13 @@ hire_laamp_mercenaries_interaction = { #don't do it if you cannot afford it modifier = { - scope:actor = { + scope:puppet_or_actor = { war_chest_gold < ep3_hire_laamp_mercs_cost_value } add = -50 } modifier = { - scope:actor = { + scope:puppet_or_actor = { gold < ep3_hire_laamp_mercs_cost_value } add = -1000 @@ -5504,12 +6151,17 @@ refill_maa_interaction = { desc = refill_maa_interaction_desc cooldown = { months = 6 } + is_available = { + government_allows = conditional_maa_refill + NOT = { government_has_flag = government_is_nomadic } + trigger_if = { + limit = { is_ai = yes } + any_maa_regiment = { maa_current_troops_count < maa_max_troops_count } + } + } + is_shown = { has_ep3_dlc_trigger = yes - scope:actor = { - government_allows = conditional_maa_refill - NOT = { government_has_flag = government_is_nomadic } - } scope:recipient = scope:actor } @@ -5606,7 +6258,7 @@ refill_maa_interaction = { } } } - + ai_frequency_by_tier = { barony = 0 county = 0 @@ -5618,10 +6270,6 @@ refill_maa_interaction = { ai_targets = { ai_recipients = self } - ai_potential = { - government_allows = conditional_maa_refill - any_maa_regiment = { maa_current_troops_count < maa_max_troops_count } - } ai_will_do = { base = 100 @@ -5653,18 +6301,30 @@ evict_adventurer_interaction = { ai_min_reply_days = 4 ai_max_reply_days = 9 + is_available = { + trigger_if = { + limit = { is_ai = yes } + is_at_war = no + is_imprisoned = no + is_incapable = no + } + } + is_shown = { + scope:puppet_or_actor ?= { is_landed = yes } has_ep3_dlc_trigger = yes - scope:actor = { is_landed = yes } - scope:recipient != scope:actor + scope:recipient != scope:puppet_or_actor scope:recipient = { - OR = { government_has_flag = government_is_landless_adventurer government_has_flag = government_is_landless_minority } + OR = { + government_has_flag = government_is_landless_adventurer + government_has_flag = government_is_landless_minority + } is_landed = no } } is_valid_showing_failures_only = { - scope:actor = { + scope:puppet_or_actor = { is_at_war = no NOR = { is_spouse_of = scope:recipient @@ -5675,7 +6335,7 @@ evict_adventurer_interaction = { scope:recipient = { # Adventurer must be in the subrealm domicile.domicile_location.county.holder ?= { - target_is_same_character_or_above = scope:actor + target_is_same_character_or_above = scope:puppet_or_actor } } # AI should not against hired adventurers @@ -5683,7 +6343,7 @@ evict_adventurer_interaction = { limit = { scope:actor = { is_ai = yes } } - scope:actor = { + scope:puppet_or_actor = { opinion = { target = scope:recipient value < 25 @@ -5691,18 +6351,18 @@ evict_adventurer_interaction = { } NOT = { scope:recipient = { - any_character_active_contract = { task_contract_employer = scope:actor } + any_character_active_contract = { task_contract_employer = scope:puppet_or_actor } } } } scope:recipient = { - NOT = { has_strong_hook = scope:actor } + NOT = { has_strong_hook = scope:puppet_or_actor } } # Story blockers. ## Hereward cannot be exiled by active participants in the Harrying of the North. -# disable_interaction_for_hereward_trigger = yes + disable_interaction_for_hereward_trigger = yes ## Hasan cannot be exiled by anyone during his story. -# disable_interaction_for_hasan_trigger = yes + disable_interaction_for_hasan_trigger = yes } on_send = { @@ -5710,13 +6370,13 @@ evict_adventurer_interaction = { send_interface_toast = { type = diplo_contract_scheme_invalidated_message title = evict_adventurer_interaction.tt.contracts_invalidated.t - right_icon = scope:actor + right_icon = scope:puppet_or_actor custom_tooltip = { text = evict_adventurer_interaction.tt.contracts_invalidated every_character_task_contract = { limit = { task_contract_location.county.holder = { - target_is_same_character_or_above = scope:actor + target_is_same_character_or_above = scope:puppet_or_actor } } invalidate_contract = yes @@ -5729,22 +6389,22 @@ evict_adventurer_interaction = { } on_accept = { - scope:actor = { save_scope_as = expeller } + scope:puppet_or_actor = { save_scope_as = expeller } scope:recipient = { save_scope_as = adventurer add_opinion = { - target = scope:actor + target = scope:puppet_or_actor modifier = demanded_eviction_opinion } custom_tooltip = evict_adventurer_contracts_tt custom_description_no_bullet = { text = evict_adventurer_consequences_tt - object = scope:actor + object = scope:puppet_or_actor subject = scope:recipient } custom_tooltip = evict_adventurer_casus_belli_tt } - scope:actor = { + scope:puppet_or_actor = { show_as_tooltip = { add_opinion = { target = scope:recipient @@ -5755,12 +6415,12 @@ evict_adventurer_interaction = { scope:recipient = { set_variable = { name = adventurer_expeller - value = scope:actor + value = scope:puppet_or_actor months = 4 } trigger_event = { id = ep3_interactions_events.0500 - days = 1 + days = 1 } trigger_event = { id = ep3_interactions_events.0501 @@ -5773,7 +6433,7 @@ evict_adventurer_interaction = { scope:recipient = { start_war = { cb = ep3_laamp_apprehend_adventurer_cb - target = scope:actor + target = scope:puppet_or_actor } } } @@ -5792,15 +6452,10 @@ evict_adventurer_interaction = { ai_recipients = sub_realm_domicile_owners max = 10 } - ai_potential = { - is_at_war = no - is_imprisoned = no - NOT = { has_trait = incapable } - } ai_will_do = { base = -25 opinion_modifier = { - who = scope:actor + who = scope:puppet_or_actor opinion_target = scope:recipient multiplier = -0.5 } @@ -5813,8 +6468,8 @@ evict_adventurer_interaction = { } scope:recipient = { any_claim = { - tier >= scope:actor.highest_held_title_tier - holder ?= scope:actor + tier >= scope:puppet_or_actor.highest_held_title_tier + holder ?= scope:puppet_or_actor } } } @@ -5963,13 +6618,15 @@ evict_adventurer_interaction = { ## Don't evict people we can't beat up. modifier = { factor = 0 - scope:actor.current_military_strength < scope:recipient.military_strength_75_percent_value + scope:puppet_or_actor.current_military_strength < scope:recipient.military_strength_75_percent_value } ## Don't evict anyone currently doing a job for us. modifier = { factor = 0 scope:recipient = { - any_character_task_contract = { task_contract_employer = scope:actor } + any_character_task_contract = { + task_contract_employer ?= scope:puppet_or_actor + } } } ## We _only_ evict if we actually dislike someone. @@ -6036,8 +6693,8 @@ procure_estate_interaction = { ai_max_reply_days = 9 is_shown = { - has_ep3_dlc_trigger = yes scope:actor = { OR = { government_has_flag = government_is_landless_adventurer government_has_flag = government_is_landless_minority } } + has_ep3_dlc_trigger = yes scope:recipient = { is_landed = yes government_allows = noble_families @@ -6336,20 +6993,18 @@ procure_estate_interaction = { multiplier = 0.5 desc = AI_OPINION_REASON } - #DIFFERENT FAITH FROM STATE FAITH (if recipient is state faith) + #DIFFERENT RITE FROM STATE RITE (if recipient is state rite) modifier = { add = -20 desc = PROCURE_ESTATE_STATE_FAITH_REASON - exists = scope:recipient.top_liege.primary_title.state_faith - scope:actor.faith = { - this != scope:recipient.top_liege.primary_title.state_faith + exists = scope:recipient.top_liege.primary_title.state_rite + scope:actor.rite = { + this != scope:recipient.top_liege.primary_title.state_rite } - scope:recipient.faith = { - this = scope:recipient.top_liege.primary_title.state_faith - } - NOT = { - scope:piety_option = yes + scope:recipient.rite = { + this = scope:recipient.top_liege.primary_title.state_rite } + scope:piety_option = no } #Hey you're actually a local in my capital modifier = { @@ -6636,9 +7291,7 @@ procure_estate_interaction = { scope:recipient = { gold <= minor_gold_value } - NOT = { - scope:gold_option = yes - } + scope:gold_option = no desc = PROCURE_ESTATE_NEEDS_GOLD_REASON } #Needs gold and offering gold @@ -6710,20 +7363,27 @@ request_laamp_legitimist_support = { icon = request_invasion_sponsorship_interaction desc = request_laamp_legitimist_support_interaction_desc + is_available = { + has_realm_law = camp_purpose_legitimists + trigger_if = { + limit = { is_ai = yes } + ai_greed <= 25 + is_at_war = no + } + government_has_flag = government_is_landless_adventurer + government_has_flag = government_is_landless_minority + } + is_shown = { has_ep3_dlc_trigger = yes - scope:actor = { - OR = { government_has_flag = government_is_landless_adventurer government_has_flag = government_is_landless_minority } - has_realm_law = camp_purpose_legitimists - } - scope:recipient = { + scope:recipient = { is_landed = yes is_ai = yes primary_title.tier >= tier_kingdom } scope:recipient != scope:actor } - + is_valid_showing_failures_only = { NOR = { #so legitimist AI can get lucky. It looks ugly but formats the tooltip correctly NOT = { @@ -6734,10 +7394,10 @@ request_laamp_legitimist_support = { } scope:actor = { is_available_ai_adult = yes - } + } } - - + + custom_tooltip = { text = request_laamp_legitimist_have_claim_on_target scope:actor = { @@ -6898,10 +7558,6 @@ request_laamp_legitimist_support = { ai_recipients = domicile_location_neighboring_top_rulers ai_recipients = contacts } - ai_potential = { - is_at_war = no - ai_greed <= 25 - } ai_will_do = { base = 100 #no downside to ai trying this } @@ -6916,11 +7572,15 @@ relocate_camp_to_interaction = { ignores_pending_interaction_block = yes icon = icon_contract_escort desc = relocate_camp_to_interaction_desc + is_available = { + OR = { + has_government = landless_adventurer_government + has_government = landless_minority_government + } + } + is_shown = { scope:recipient != scope:actor - scope:actor = { - has_government = landless_adventurer_government - } scope:recipient = { exists = capital_province } #just to make sure proper scopes will be set up } @@ -6930,9 +7590,7 @@ relocate_camp_to_interaction = { scope:actor.domicile.domicile_location != scope:recipient.capital_province } scope:actor = { - is_travelling = no - is_in_army = no - is_imprisoned = no + is_available = yes } # Adventurers can't join wars in places they're exiled from. custom_tooltip = { @@ -6980,6 +7638,13 @@ task_contract_train_knight_interaction = { popup_on_receive = yes pause_on_receive = yes + is_available = { + trigger_if = { + limit = { is_ai = yes } + is_at_war = no + } + } + is_shown = { has_ep3_dlc_trigger = yes scope:actor = { @@ -6989,16 +7654,16 @@ task_contract_train_knight_interaction = { task_contract_employer ?= scope:recipient task_contract_target ?= scope:recipient any_in_list = { - variable = knights_to_train - is_alive = yes is_knight = yes + is_alive = yes + variable = knights_to_train this = scope:recipient } } } } } - + is_valid_showing_failures_only = { } @@ -7028,7 +7693,7 @@ task_contract_train_knight_interaction = { variable = knights_to_train is_alive = yes is_knight = yes - this = scope:recipient + this = scope:recipient } } } @@ -7127,9 +7792,6 @@ task_contract_train_knight_interaction = { ai_recipients = liege ai_recipients = contacts } - ai_potential = { - is_at_war = no - } ai_will_do = { base = 100 #no downside to ai trying this } @@ -7151,11 +7813,15 @@ laamp_war_change_sides_interaction = { cooldown_against_recipient = { years = 3 } send_options_exclusive = yes - is_shown = { - scope:actor = { - is_at_war = yes + is_available = { + is_at_war = yes + OR = { has_government = landless_adventurer_government + has_government = landless_minority_government } + } + + is_shown = { scope:recipient = { this != scope:actor any_war_ally = { this = scope:actor } @@ -7186,7 +7852,7 @@ laamp_war_change_sides_interaction = { text = laamp_war_change_sides_interaction.already_switched_side is_target_in_variable_list = { name = already_switched_side - target = scope:actor + target = scope:actor } } } @@ -7233,7 +7899,7 @@ laamp_war_change_sides_interaction = { scope:actor = { #ROOT is a 4th crusader and should not be one anymore # frankokratia_remove__war_leader_var_effect = yes -# #ROOT is not a 4th crusader and should be one + #ROOT is not a 4th crusader and should be one # if = { # limit = { # any_character_war = { @@ -7394,7 +8060,7 @@ laamp_war_change_sides_interaction = { break_alliance = scope:recipient } # And don't forget stress! - stress_impact = { + stress_and_fulfillment_impact = { base = major_stress_impact_gain disloyal = medium_stress_impact_loss ambitious = minor_stress_impact_loss @@ -7485,10 +8151,6 @@ laamp_war_change_sides_interaction = { auto_accept = yes - ai_potential = { - is_at_war = yes - } - ai_targets = { ai_recipients = war_allies } @@ -7534,9 +8196,9 @@ laamp_war_change_sides_interaction = { any_character_war = { is_war_leader = scope:recipient } - has_any_criminal_trait_in_faith_trigger = { + has_any_criminal_trait_in_rite_trigger = { CHARACTER = scope:recipient - FAITH = scope:actor.faith + RITE = scope:actor.rite } add = 5 } @@ -7612,7 +8274,7 @@ laamp_war_change_sides_interaction = { AND = { primary_attacker = scope:recipient attacker_war_score >= 0 - } + } } } add = -1000 @@ -7642,11 +8304,15 @@ laamp_leave_war_interaction = { cooldown_against_recipient = { years = 3 } send_options_exclusive = yes - is_shown = { - scope:actor = { - is_at_war = yes + is_available = { + is_at_war = yes + OR = { has_government = landless_adventurer_government + has_government = landless_minority_government } + } + + is_shown = { scope:recipient = { this != scope:actor any_war_ally = { this = scope:actor } @@ -7682,7 +8348,7 @@ laamp_leave_war_interaction = { text = laamp_war_change_sides_interaction.already_switched_side is_target_in_variable_list = { name = already_switched_side - target = scope:actor + target = scope:actor } } } @@ -7791,7 +8457,7 @@ laamp_leave_war_interaction = { break_alliance = scope:recipient } # And don't forget stress! - stress_impact = { + stress_and_fulfillment_impact = { base = major_stress_impact_gain disloyal = medium_stress_impact_loss ambitious = minor_stress_impact_loss @@ -7830,10 +8496,6 @@ laamp_leave_war_interaction = { auto_accept = yes - ai_potential = { - is_at_war = yes - } - ai_targets = { ai_recipients = war_allies } @@ -7880,9 +8542,9 @@ laamp_leave_war_interaction = { any_character_war = { is_war_leader = scope:recipient } - has_any_criminal_trait_in_faith_trigger = { + has_any_criminal_trait_in_rite_trigger = { CHARACTER = scope:recipient - FAITH = scope:actor.faith + RITE = scope:actor.rite } add = 5 } @@ -7958,7 +8620,7 @@ laamp_leave_war_interaction = { AND = { primary_attacker = scope:recipient attacker_war_score >= 0 - } + } } } add = -1000 @@ -7971,3 +8633,4 @@ laamp_leave_war_interaction = { } } } + diff --git a/common/character_interactions/09_mpo_interactions.txt b/common/character_interactions/09_mpo_interactions.txt index f274f9888..9365f9987 100644 --- a/common/character_interactions/09_mpo_interactions.txt +++ b/common/character_interactions/09_mpo_interactions.txt @@ -22,19 +22,38 @@ cooldown_against_recipient = { years = 3 } - is_shown = { - scope:actor = { - is_playable_character = yes - OR = { - is_independent_ruler = yes - is_confederation_member = no - confederation ?= { is_house_based = no } - } + is_available = { + OR = { + government_has_flag = government_is_tribal + government_has_flag = government_is_nomadic } + trigger_if = { + limit = { is_ai = yes } + OR = { + is_confederation_member = yes + AND = { + has_character_flag = forming_confederation + highest_held_title_tier < tier_kingdom + is_independent_ruler = yes + } + } + age >= 6 + } + is_playable_character = yes + OR = { + is_independent_ruler = yes + confederation ?= { is_house_based = no } + } + } + + is_shown = { scope:recipient = { is_playable_character = yes is_independent_ruler = yes - is_confederation_member = no + OR = { + government_has_flag = government_is_tribal + government_has_flag = government_is_nomadic + } NOT = { this = scope:actor } } } @@ -126,29 +145,29 @@ # STRUGGLES - bonus gained by successful Sway scheme during the Persian Struggle - modifier = { - desc = fp3_persian_struggle_previously_swayed_tt - trigger = { - scope:recipient = { - has_opinion_modifier = { - modifier = scheme_sway_and_compelled_to_submit_opinion - target = scope:actor - } - } - } - add = 20 - } +# modifier = { +# desc = fp3_persian_struggle_previously_swayed_tt +# trigger = { +# scope:recipient = { +# has_opinion_modifier = { +# modifier = scheme_sway_and_compelled_to_submit_opinion +# target = scope:actor +# } +# } +# } +# add = 20 +# } - modifier = { - desc = fp3_rekindler_of_iran_modifier_reason - trigger = { - AND = { - scope:actor = { dynasty ?={ has_dynasty_modifier = fp3_rekindler_of_iran_modifier } } - scope:recipient = { culture = { has_cultural_pillar = heritage_iranian } } - } - } - add = 20 - } +# modifier = { +# desc = fp3_rekindler_of_iran_modifier_reason +# trigger = { +# AND = { +# scope:actor = { dynasty ?={ has_dynasty_modifier = fp3_rekindler_of_iran_modifier } } +# scope:recipient = { culture = { has_cultural_pillar = heritage_iranian } } +# } +# } +# add = 20 +# } modifier = { # Cultural Acceptance @@ -171,9 +190,8 @@ scope:recipient = { NOR = { #Of two different faiths AND the potential vassal's faith is not pluralistic. faith = scope:actor.faith - faith = { has_doctrine = doctrine_pluralism_pluralistic } - government_has_flag = government_is_nomadic - government_has_flag = government_is_true_herder + rite = { rite_has_doctrine = doctrine_pluralism_pluralistic } + government_has_flag = government_is_in_steppe } } } @@ -210,11 +228,10 @@ scope:recipient = { NOR = { faith = scope:actor.faith - scope:actor.faith = { has_doctrine = doctrine_pluralism_pluralistic } - government_has_flag = government_is_nomadic - government_has_flag = government_is_true_herder + scope:actor.rite = { rite_has_doctrine = doctrine_pluralism_pluralistic } + government_has_flag = government_is_in_steppe } - faith = { has_doctrine = doctrine_pluralism_pluralistic } + rite = { rite_has_doctrine = doctrine_pluralism_pluralistic } } } add = { @@ -250,11 +267,10 @@ scope:recipient = { NOR = { faith = scope:actor.faith - government_has_flag = government_is_nomadic - government_has_flag = government_is_true_herder + government_has_flag = government_is_in_steppe } - scope:actor.faith = { has_doctrine = doctrine_pluralism_pluralistic } - faith = { has_doctrine = doctrine_pluralism_pluralistic } + scope:actor.rite = { rite_has_doctrine = doctrine_pluralism_pluralistic } + rite = { rite_has_doctrine = doctrine_pluralism_pluralistic } } } add = { @@ -400,7 +416,7 @@ } } } - scope:recipient.capital_province = { squared_distance = { target = scope:actor.capital_province value < 100000 } } + scope:recipient.capital_province = { squared_distance = { target = scope:actor.capital_province value < 150000 } } } add = -25 } @@ -429,7 +445,16 @@ } } } - scope:recipient.capital_province = { squared_distance = { target = scope:actor.capital_province value >= 100000 } } + scope:recipient.capital_province = { + squared_distance = { + target = scope:actor.capital_province + value >= 150000 + } + squared_distance = { + target = scope:actor.capital_province + value < 300000 + } + } } add = -100 } @@ -458,9 +483,9 @@ } } } - scope:recipient.capital_province = { squared_distance = { target = scope:actor.capital_province value >= 200000 } } + scope:recipient.capital_province = { squared_distance = { target = scope:actor.capital_province value >= 300000 } } } - add = -175 + add = -200 } #Relative power modifier = { @@ -696,7 +721,7 @@ AND = { has_trait = bastard scope:recipient = { - faith = { NOT = { has_doctrine = doctrine_bastardry_none } } + rite = { NOT = { rite_has_doctrine = doctrine_bastardry_none } } } } has_trait = denounced @@ -1054,17 +1079,10 @@ modifier = { add = -100 desc = ANOTHER_CULTURE_CONFEDERATION_REASON - NOT = { - scope:actor.culture = { - this = scope:recipient.culture - } - } + scope:actor.culture != scope:recipient.culture any_confederation = { - NOT = { - this = scope:actor.confederation - } - has_variable = confederation_culture - var:confederation_culture = scope:actor.culture + this != scope:actor.confederation + var:confederation_culture ?= scope:recipient.culture } } @@ -1191,7 +1209,7 @@ desc = CONFEDERATION_HERDER_REASON trigger = { scope:recipient = { - government_has_flag = government_is_true_herder + government_has_flag = government_is_herder } } } @@ -1599,6 +1617,10 @@ } } } + if = { + limit = { scope:hook = yes } + scope:actor = { use_hook = scope:recipient } + } } } @@ -1625,18 +1647,6 @@ } } - ai_potential = { - age >= 6 - OR = { - AND = { - is_independent_ruler = yes - highest_held_title_tier < tier_kingdom - has_character_flag = forming_confederation - } - is_confederation_member = yes - } - } - ai_will_do = { base = 50 @@ -1725,15 +1735,23 @@ promote_divergent_or_hybrid_culture_interaction = { common_interaction = yes + is_available = { + trigger_if = { + limit = { is_ai = yes } + highest_held_title_tier >= tier_duchy + government_has_flag = government_is_nomadic + } + } + is_shown = { scope:actor.domicile ?= { + domicile_culture ?= scope:actor.culture domicile_uses_culture_and_faith = yes - domicile_culture = scope:actor.culture } scope:actor.culture ?= { OR = { - is_hybrid_culture = yes is_divergent_culture = yes + is_hybrid_culture = yes } } scope:recipient = { @@ -1761,12 +1779,11 @@ promote_divergent_or_hybrid_culture_interaction = { is_at_war_with = scope:actor } } - custom_tooltip = { - text = not_a_nomad_or_herder_tt - scope:recipient = { - OR = { - government_has_flag = government_is_nomadic - government_has_flag = government_is_true_herder + NOT = { + custom_tooltip = { + text = not_a_nomad_or_herder_tt + scope:recipient = { + NOT = { government_has_flag = government_is_in_steppe } } } } @@ -1874,7 +1891,7 @@ promote_divergent_or_hybrid_culture_interaction = { desc = CONFEDERATION_HERDER_REASON trigger = { scope:recipient = { - government_has_flag = government_is_true_herder + government_has_flag = government_is_herder } } } @@ -2035,11 +2052,6 @@ promote_divergent_or_hybrid_culture_interaction = { } } - ai_potential = { - government_has_flag = government_is_nomadic - highest_held_title_tier >= tier_duchy - } - ai_will_do = { base = 100 @@ -2083,9 +2095,29 @@ inspire_conversion_interaction = { common_interaction = yes + is_available = { + trigger_if = { + limit = { is_ai = yes } + highest_held_title_tier >= tier_duchy + government_has_flag = government_is_nomadic + NOR = { + any_owned_story = { + OR = { + story_type = story_mongol_invasion + story_type = story_greatest_of_khans + + } + } + mpo_has_gok_mongol_empire_trigger = yes + } + } + } + is_shown = { - scope:actor.domicile ?= { - domicile_uses_culture_and_faith = yes + scope:puppet_or_actor ?= { + domicile ?= { + domicile_uses_culture_and_faith = yes + } } scope:recipient = { OR = { @@ -2093,14 +2125,20 @@ inspire_conversion_interaction = { limit = { domicile ?= { domicile_uses_culture_and_faith = yes } } - domicile.domicile_faith != scope:actor.domicile.domicile_faith + scope:puppet_or_actor.domicile ?= { + domicile_faith != scope:recipient.domicile.domicile_faith + } + } + scope:puppet_or_actor.domicile ?= { + domicile_faith != scope:recipient.faith + } + scope:puppet_or_actor ?= { + faith != scope:recipient.faith # Tooltip reasons } - faith != scope:actor.domicile.domicile_faith - faith != scope:actor.faith # Tooltip reasons } OR = { - is_tributary_of_suzerain_or_above = scope:actor - is_vassal_or_below_of = scope:actor + is_tributary_of_suzerain_or_above = scope:puppet_or_actor + is_vassal_or_below_of = scope:puppet_or_actor } } } @@ -2108,9 +2146,9 @@ inspire_conversion_interaction = { is_valid_showing_failures_only = { scope:recipient = { NOR = { - is_imprisoned_by = scope:actor - has_strong_hook = scope:actor - is_at_war_with = scope:actor + is_imprisoned_by = scope:puppet_or_actor + has_strong_hook = scope:puppet_or_actor + is_at_war_with = scope:puppet_or_actor } } custom_description = { @@ -2123,7 +2161,7 @@ inspire_conversion_interaction = { subject = scope:recipient NAND = { # Vassal Contract forbids meddling by liege exists = scope:recipient.liege - scope:recipient.liege = scope:actor + scope:recipient.liege = scope:puppet_or_actor scope:recipient = { is_ruler = yes vassal_contract_has_flag = religiously_protected @@ -2138,18 +2176,17 @@ inspire_conversion_interaction = { limit = { domicile ?= { domicile_uses_culture_and_faith = yes } } - domicile.domicile_faith != scope:actor.domicile.domicile_faith + domicile.domicile_faith != scope:puppet_or_actor.domicile.domicile_faith } - faith != scope:actor.domicile.domicile_faith + faith != scope:puppet_or_actor.domicile.domicile_faith } } } - custom_tooltip = { - text = not_a_nomad_or_herder_tt - scope:recipient = { - OR = { - government_has_flag = government_is_nomadic - government_has_flag = government_is_true_herder + NOT = { + custom_tooltip = { + text = not_a_nomad_or_herder_tt + scope:recipient = { + NOT = { government_has_flag = government_is_in_steppe } } } } @@ -2164,7 +2201,7 @@ inspire_conversion_interaction = { modifier = { add = 1000 scope:recipient = { - is_obedient_to = scope:actor + is_obedient_to = scope:puppet_or_actor } desc = MIGRATION_INTERACTION_OBEDIENT_ACCEPTANCE } @@ -2180,14 +2217,14 @@ inspire_conversion_interaction = { modifier = { desc = INSPIRE_UNREFORMED_FAITH add = -50 - scope:actor.faith = { has_doctrine_parameter = unreformed } + scope:puppet_or_actor.faith = { has_doctrine_parameter = unreformed } } modifier = { add = 50 desc = ZEALOUS_PROSELYTIZER_REASON trigger = { - scope:actor = { + scope:puppet_or_actor = { has_perk = zealous_proselytizer_perk } } @@ -2197,7 +2234,7 @@ inspire_conversion_interaction = { add = 20 desc = NOMADIC_AUTHORITY_POSITIVE_REASON trigger = { - scope:actor = { + scope:puppet_or_actor = { has_realm_law = nomadic_authority_3 } } @@ -2207,7 +2244,7 @@ inspire_conversion_interaction = { add = 50 desc = NOMADIC_AUTHORITY_POSITIVE_REASON trigger = { - scope:actor = { + scope:puppet_or_actor = { has_realm_law = nomadic_authority_4 } } @@ -2217,14 +2254,14 @@ inspire_conversion_interaction = { add = 100 desc = NOMADIC_AUTHORITY_POSITIVE_REASON trigger = { - scope:actor = { + scope:puppet_or_actor = { has_realm_law = nomadic_authority_5 } } } opinion_modifier = { - opinion_target = scope:actor + opinion_target = scope:puppet_or_actor who = scope:recipient multiplier = 1 desc = AI_OPINION_REASON @@ -2258,7 +2295,7 @@ inspire_conversion_interaction = { desc = CONFEDERATION_HERDER_REASON trigger = { scope:recipient = { - government_has_flag = government_is_true_herder + government_has_flag = government_is_herder } } } @@ -2267,7 +2304,7 @@ inspire_conversion_interaction = { send_option = { flag = hook is_valid = { - scope:actor = { + scope:puppet_or_actor = { has_usable_hook = scope:recipient } } @@ -2276,7 +2313,7 @@ inspire_conversion_interaction = { send_option = { # Herd is_shown = { - scope:actor = { + scope:puppet_or_actor ?= { government_has_flag = government_is_nomadic exists = domicile } @@ -2286,7 +2323,7 @@ inspire_conversion_interaction = { government_has_flag = government_is_nomadic exists = domicile } - scope:actor.domicile = { herd >= minor_herd_value } + scope:puppet_or_actor.domicile = { herd >= minor_herd_value } } flag = herd_send_option localization = TRADE_HERD_FOR_BETTER_AI_ACCEPTANCE_CONFEDERATION @@ -2297,7 +2334,7 @@ inspire_conversion_interaction = { always = yes } is_valid = { - scope:actor = { piety >= medium_piety_value } + scope:puppet_or_actor = { piety >= medium_piety_value } } flag = piety_send_option localization = TRADE_PRESTIGE_FOR_BETTER_AI_ACCEPTANCE_ICON @@ -2306,7 +2343,7 @@ inspire_conversion_interaction = { send_options_exclusive = no on_accept = { - scope:actor = { + scope:puppet_or_actor = { send_interface_toast = { type = event_toast_effect_good title = inspire_conversion_accepted_tt @@ -2323,7 +2360,7 @@ inspire_conversion_interaction = { tier = tier_county is_landless_type_title = no culture = scope:recipient.domicile.domicile_culture - faith != scope:actor.domicile.domicile_faith + faith != scope:puppet_or_actor.domicile.domicile_faith } add_to_list = counties_to_convert } @@ -2331,16 +2368,17 @@ inspire_conversion_interaction = { every_close_or_extended_family_member = { limit = { is_courtier_of = scope:recipient - faith != scope:actor.domicile.domicile_faith + faith != scope:puppet_or_actor.domicile.domicile_faith + NOT = { has_character_flag = ai_will_not_convert } } add_to_list = spouses_and_family_to_convert } domicile = { if = { limit = { - domicile_faith != scope:actor.domicile.domicile_faith + domicile_faith != scope:puppet_or_actor.domicile.domicile_faith } - set_domicile_faith = scope:actor.domicile.domicile_faith + set_domicile_faith = scope:puppet_or_actor.domicile.domicile_faith } } } @@ -2353,7 +2391,7 @@ inspire_conversion_interaction = { tier = tier_county is_landless_type_title = no culture = scope:recipient.culture - faith != scope:actor.domicile.domicile_faith + faith != scope:puppet_or_actor.domicile.domicile_faith } add_to_list = counties_to_convert } @@ -2361,7 +2399,8 @@ inspire_conversion_interaction = { every_close_or_extended_family_member = { limit = { is_courtier_of = scope:recipient - faith != scope:actor.domicile.domicile_faith + faith != scope:puppet_or_actor.domicile.domicile_faith + NOT = { has_character_flag = ai_will_not_convert } } add_to_list = spouses_and_family_to_convert } @@ -2369,35 +2408,35 @@ inspire_conversion_interaction = { } if = { limit = { - faith != scope:actor.domicile.domicile_faith + faith != scope:puppet_or_actor.domicile.domicile_faith } - set_character_faith = scope:actor.domicile.domicile_faith + set_character_rite = scope:puppet_or_actor.rite } hidden_effect = { every_in_list = { list = counties_to_convert - set_county_faith = scope:actor.domicile.domicile_faith + set_county_rite = scope:puppet_or_actor.rite } every_in_list = { list = spouses_and_family_to_convert - set_character_faith = scope:actor.domicile.domicile_faith + set_character_rite = scope:puppet_or_actor.rite } } if = { # If you have the Religious Icon perk they become obedient limit = { - scope:actor = { + scope:puppet_or_actor = { government_has_flag = government_is_nomadic has_perk = religious_icon_perk } scope:recipient = { - obedience_target = scope:actor + obedience_target = scope:puppet_or_actor is_obedient = no } } scope:recipient = { add_opinion = { modifier = obedience_opinion - target = scope:actor + target = scope:puppet_or_actor } } } @@ -2405,7 +2444,7 @@ inspire_conversion_interaction = { add_opinion = { modifier = respect_opinion opinion = 10 - target = scope:actor + target = scope:puppet_or_actor } } } @@ -2414,44 +2453,47 @@ inspire_conversion_interaction = { limit = { scope:piety_send_option = yes } - scope:actor = { - add_piety = scope:actor.medium_piety_loss + scope:puppet_or_actor = { + add_piety = scope:puppet_or_actor.medium_piety_loss } scope:recipient = { - add_piety = scope:actor.medium_piety_value + add_piety = scope:puppet_or_actor.medium_piety_value } } if = { limit = { scope:herd_send_option = yes } - scope:actor = { + scope:puppet_or_actor = { pay_herd = { target = scope:recipient value = domicile.minor_herd_value } } } + if = { + limit = { scope:hook = yes } + scope:puppet_or_actor = { use_hook = scope:recipient } + } + } + if = { + limit = { + scope:is_puppet_action ?= yes + scope:actor != scope:recipient + } + scope:actor = { + send_interface_toast = { + type = event_toast_effect_good + title = inspire_conversion_accepted_tt_puppeteer + left_icon = scope:puppet_or_actor + right_icon = scope:recipient + } + } } } on_decline = { - scope:actor = { - } - } - - ai_potential = { - government_has_flag = government_is_nomadic - highest_held_title_tier >= tier_duchy - NOR = { - any_owned_story = { - OR = { - story_type = story_mongol_invasion - story_type = story_greatest_of_khans - - } - } - mpo_has_gok_mongol_empire_trigger = yes + scope:puppet_or_actor = { } } @@ -2499,17 +2541,15 @@ migration_interaction = { desc = migration_interaction_desc - is_shown = { - scope:actor = { - government_has_flag = government_is_nomadic - trigger_if = { - limit = { - is_ai = yes - } - is_at_war = no + is_available = { + government_has_flag = government_is_nomadic + trigger_if = { + limit = { + is_ai = yes } - highest_held_title_tier >= tier_county + is_at_war = no } + highest_held_title_tier >= tier_county } is_valid_showing_failures_only = { @@ -2544,22 +2584,6 @@ migration_interaction = { } scope:recipient = { is_ruler = yes - NOR = { - government_has_flag = government_is_feudal - government_has_flag = government_is_republic - government_has_flag = government_is_theocracy - government_has_flag = government_is_clan - government_has_flag = government_is_tribal - government_has_flag = government_is_holy_order - government_has_flag = government_is_mercenary - government_has_flag = government_is_administrative - government_has_flag = government_is_prepublic - government_has_flag = government_is_urepublic - government_has_flag = government_is_celestial - government_has_flag = government_is_mandala - government_has_flag = government_is_steppe_admin - government_has_flag = government_is_meritocratic - } NOT = { is_allied_to = scope:actor } } } @@ -2637,9 +2661,9 @@ migration_interaction = { } if = { limit = { - OR = { - has_variable = crowned_king_var - has_variable = crowned_emperor_var + has_variable = { + name = crowned_king_var + name = crowned_emperor_var } } set_variable = { @@ -2783,9 +2807,9 @@ migration_interaction = { scope:actor = { if = { limit = { - OR = { - has_variable = crowned_king_var - has_variable = crowned_emperor_var + has_variable = { + name = crowned_king_var + name = crowned_emperor_var } } set_variable = { @@ -2893,9 +2917,8 @@ migration_interaction = { if = { #Non-Nomads should try to keep their lands limit = { scope:recipient = { - NOR = { - government_has_flag = government_is_nomadic - government_has_flag = government_is_true_herder + NOT = { + government_has_flag = government_is_in_steppe } } } @@ -2914,7 +2937,7 @@ migration_interaction = { } modifier = { # Herders move away immediately trigger = { - scope:recipient = { government_has_flag = government_is_true_herder } + scope:recipient = { government_has_flag = government_is_herder } } add = 150 desc = MIGRATION_INTERACTION_HERDER @@ -3099,10 +3122,8 @@ migration_interaction = { } # Relative Herd modifier = { - trigger_if = { - exists = scope:recipient.domicile # Herders won't have a domicile - } add = 25 + exists = scope:recipient.domicile # Herders won't have a domicile domicile.herd >= scope:recipient.domicile.herd desc = MIGRATION_INTERACTION_HERD_ACCEPTANCE } @@ -3110,19 +3131,13 @@ migration_interaction = { modifier = { add = -1000 exists = situation:the_great_steppe - scope:recipient = { - this = situation:the_great_steppe.situation_top_herd - } + scope:recipient = situation:the_great_steppe.situation_top_herd desc = MIGRATION_INTERACTION_GURKHAN_ACCEPTANCE } modifier = { add = 50 - trigger_if = { - exists = situation:the_great_steppe - } - scope:actor = { - this = situation:the_great_steppe.situation_top_herd - } + exists = situation:the_great_steppe + scope:actor = situation:the_great_steppe.situation_top_herd desc = MIGRATION_INTERACTION_GURKHAN_ACTOR_ACCEPTANCE } # Dread @@ -3176,7 +3191,7 @@ migration_interaction = { desc = JUST_SETTLED_REASON scope:recipient = { is_tributary = yes - NOT = { government_has_flag = government_is_true_herder } + NOT = { government_has_flag = government_is_herder } capital_county = { title_held_years < 3 } @@ -3281,7 +3296,7 @@ migration_interaction = { # The recipient is a Herder modifier = { - scope:recipient = { government_has_flag = government_is_true_herder } + scope:recipient = { government_has_flag = government_is_herder } add = 10 } @@ -3390,18 +3405,13 @@ migration_interaction = { modifier = { factor = 0 scope:domain = { + tier = tier_county OR = { - AND = { - tier = tier_county - any_county_situation_sub_region = { - sub_region_current_phase = situation_steppe_havsarsan_zud_season - } - } - AND = { - tier = tier_county - any_county_province_epidemic = { - } + any_county_situation_sub_region = { + situation_sub_region_has_county = prev + sub_region_current_phase = situation_steppe_havsarsan_zud_season } + any_county_province_epidemic = {} } } } @@ -3676,6 +3686,7 @@ migration_interaction = { } capital_county = { any_county_situation_sub_region = { + situation_sub_region_has_county = prev NOR = { sub_region_current_phase = situation_steppe_havsarsan_zud_season sub_region_current_phase = situation_steppe_severe_drought_season @@ -3828,6 +3839,7 @@ mpo_interaction_grant_paiza = { common_interaction = no desc = mpo_interaction_grant_paiza_desc + notification_text = mpo_interaction_grant_paiza_notification ai_frequency_by_tier = { barony = 0 @@ -3840,15 +3852,16 @@ mpo_interaction_grant_paiza = { popup_on_receive = yes pause_on_receive = yes - is_shown = { - scope:actor = { - has_character_flag = established_paiza_system - exists = situation:the_great_steppe - any_character_situation = { - this = situation:the_great_steppe - } - government_has_flag = government_is_nomadic + is_available = { + has_character_flag = established_paiza_system + exists = situation:the_great_steppe + any_character_situation = { + this = situation:the_great_steppe } + government_has_flag = government_is_nomadic + } + + is_shown = { scope:recipient = { government_has_flag = government_is_nomadic OR = { @@ -3907,21 +3920,7 @@ mpo_interaction_grant_paiza = { custom_tooltip = mpo_establish_paiza_system_decision.leverage_khan_authority_unlocked } scope:actor = { - switch = { - trigger = scope:recipient.primary_title.tier - tier_empire = { - add_legitimacy_effect = { LEGITIMACY = massive_legitimacy_gain } - } - tier_kingdom = { - add_legitimacy_effect = { LEGITIMACY = major_legitimacy_gain } - } - tier_duchy = { - add_legitimacy_effect = { LEGITIMACY = medium_legitimacy_gain } - } - tier_county = { - add_legitimacy_effect = { LEGITIMACY = miniscule_legitimacy_gain } - } - } + add_legitimacy_effect = { LEGITIMACY = scope:recipient.tier_scaled_legitimacy_value } } } @@ -4003,6 +4002,7 @@ mpo_interaction_ask_for_paiza = { common_interaction = no desc = mpo_interaction_ask_for_paiza_desc + notification_text = mpo_interaction_ask_for_paiza_notification ai_frequency_by_tier = { barony = 0 @@ -4015,6 +4015,13 @@ mpo_interaction_ask_for_paiza = { popup_on_receive = yes pause_on_receive = yes + is_available = { + trigger_if = { + limit = { is_ai = yes } + is_adult = yes + } + } + is_shown = { scope:recipient = { government_has_flag = government_is_nomadic @@ -4023,7 +4030,7 @@ mpo_interaction_ask_for_paiza = { scope:actor = { OR = { government_has_flag = government_is_nomadic - top_liege = scope:recipient + top_liege ?= scope:recipient } NOT = { is_at_war_with = scope:recipient @@ -4112,21 +4119,7 @@ mpo_interaction_ask_for_paiza = { } } scope:recipient = { - switch = { - trigger = scope:actor.primary_title.tier - tier_empire = { - add_legitimacy_effect = { LEGITIMACY = massive_legitimacy_gain } - } - tier_kingdom = { - add_legitimacy_effect = { LEGITIMACY = major_legitimacy_gain } - } - tier_duchy = { - add_legitimacy_effect = { LEGITIMACY = medium_legitimacy_gain } - } - tier_county = { - add_legitimacy_effect = { LEGITIMACY = miniscule_legitimacy_gain } - } - } + add_legitimacy_effect = { LEGITIMACY = scope:actor.tier_scaled_legitimacy_value } add_character_flag = { flag = paiza_recently_granted years = 2 @@ -4216,10 +4209,6 @@ mpo_interaction_ask_for_paiza = { } } - ai_potential = { - is_adult = yes - } - ai_will_do = { base = 0 @@ -4302,13 +4291,27 @@ mpo_interaction_leverage_khan_authority = { cooldown_against_recipient = { years = 10 } + is_available = { + NOT = { + has_character_flag = established_paiza_system + } + } + is_shown = { + scope:recipient = { + is_ai = yes + is_gurkhan = no + age >= 12 + NOT = { + has_character_flag = established_paiza_system + } + } scope:actor = { any_character_artifact = { - scope:actor = { can_benefit_from_artifact = prev } has_variable = paiza_patron + scope:actor = { can_benefit_from_artifact = prev } OR = { - scope:recipient.top_liege = var:paiza_patron + scope:recipient.top_liege ?= var:paiza_patron scope:recipient = { is_independent_ruler = yes primary_title.tier < scope:actor.primary_title.tier @@ -4318,23 +4321,12 @@ mpo_interaction_leverage_khan_authority = { liege = { OR = { government_has_flag = government_is_nomadic - scope:recipient.top_liege = prev.var:paiza_patron + scope:recipient.top_liege ?= prev.var:paiza_patron } } } } } - NOT = { - has_character_flag = established_paiza_system - } - } - scope:recipient = { - is_ai = yes - is_gurkhan = no - age >= 12 - NOT = { - has_character_flag = established_paiza_system - } } } @@ -4558,6 +4550,12 @@ interrogate_interaction = { desc = interrogate_interaction_desc + is_available = { + any_courtier_or_guest = { + has_variable = achmach_loyalty + } + } + is_shown = { scope:actor = { has_variable = can_interrogate_var } scope:recipient = { @@ -4566,12 +4564,6 @@ interrogate_interaction = { target = scope:actor } } - # And Achmach is still around - scope:actor = { - any_courtier_or_guest = { - has_variable = achmach_loyalty - } - } } cooldown_against_recipient = { years = 10 } @@ -4603,13 +4595,36 @@ steal_herd_interaction = { scheme = steal_herd ignores_pending_interaction_block = yes + is_available = { + government_has_flag = government_is_nomadic + is_adult = yes + trigger_if = { + limit = { is_ai = yes } + prestige >= medium_prestige_value # In case they fail + trigger_if = { + limit = { + NOT = { + domicile ?= { + has_domicile_building_or_higher = steal_herd_yurt_01 + } + } + } + ai_honor <= 50 + } + NOR = { + primary_title ?= { + is_mercenary_company = yes + } + scheme_generic_ai_blocker_trigger = yes + } + } + is_imprisoned = no + is_landed = yes + } + is_shown = { NOT = { scope:recipient = scope:actor } scope:actor = { - is_landed = yes - is_adult = yes - is_imprisoned = no - government_has_flag = government_is_nomadic in_diplomatic_range = scope:recipient trigger_if = { limit = { @@ -4665,10 +4680,22 @@ steal_herd_interaction = { desc = scheme_interaction_tt_steal_herd_approved } } - + on_send = { + scope:actor = { + if = { + limit = { + OR = { + has_character_modifier = pam_granted_indulgences_modifier + has_character_modifier = pam_granted_indulgences_modifier_small + } + } + change_spiritual_fulfillment = medium_spiritual_fulfillment_loss + } + } + } on_accept = { scope:actor = { - stress_impact = { + stress_and_fulfillment_impact = { compassionate = minor_stress_impact_gain honest = minor_stress_impact_gain craven = minor_stress_impact_gain @@ -4717,26 +4744,6 @@ steal_herd_interaction = { } } - ai_potential = { - prestige >= medium_prestige_value # In case they fail - trigger_if = { - limit = { - NOT = { - domicile ?= { - has_domicile_building_or_higher = steal_herd_yurt_01 - } - } - } - ai_honor <= 50 - } - NOR = { - scheme_generic_ai_blocker_trigger = yes - primary_title = { - is_mercenary_company = yes - } - } - } - auto_accept = yes ai_will_do = { @@ -4865,11 +4872,16 @@ mpo_ask_for_herd_interaction = { popup_on_receive = yes pause_on_receive = yes - is_shown = { - scope:actor = { - government_has_flag = government_is_nomadic - exists = domicile + is_available = { + government_has_flag = government_is_nomadic + exists = domicile + trigger_if = { + limit = { is_ai = yes } + primary_title.tier >= tier_duchy } + } + + is_shown = { scope:recipient = { government_has_flag = government_is_nomadic exists = domicile @@ -4885,16 +4897,14 @@ mpo_ask_for_herd_interaction = { is_valid_showing_failures_only = { scope:actor = { - NOT = { - is_imprisoned = yes - } + is_imprisoned = no } scope:recipient = { NOR = { is_imprisoned = yes is_at_war = yes is_a_faction_member = yes - custom_description = { + custom_tooltip = { text = ask_for_herd_not_enough_herd domicile.herd < scope:recipient.domicile.ask_for_herd_base_value government_has_flag = government_is_nomadic @@ -4903,10 +4913,6 @@ mpo_ask_for_herd_interaction = { } } - ai_potential = { - primary_title.tier >= tier_duchy - } - send_option = { is_valid = { scope:actor = { @@ -4924,7 +4930,7 @@ mpo_ask_for_herd_interaction = { } scope:recipient = { NOT = { - government_has_flag = government_is_true_herder + government_has_flag = government_is_herder } } } @@ -5098,7 +5104,7 @@ mpo_ask_for_herd_interaction = { if = { limit = { #herders cannot give you more herd scope:recipient = { - government_has_flag = government_is_true_herder + government_has_flag = government_is_herder } } scope:actor = { @@ -5150,6 +5156,10 @@ mpo_ask_for_herd_interaction = { } } } + if = { + limit = { scope:hook = yes } + use_hook = scope:recipient + } } } } @@ -5174,10 +5184,15 @@ mpo_demand_obedience_interaction = { popup_on_receive = yes pause_on_receive = yes - is_shown = { - scope:actor = { - government_allows = obedience + is_available = { + government_allows = obedience + trigger_if = { + limit = { is_ai = yes } + primary_title.tier >= tier_duchy } + } + + is_shown = { scope:recipient = { is_ai = yes obedience_target ?= scope:actor @@ -5198,11 +5213,6 @@ mpo_demand_obedience_interaction = { cost = { prestige = minor_prestige_value } - ai_potential = { - government_allows = obedience - primary_title.tier >= tier_duchy - } - send_option = { is_valid = { scope:actor = { @@ -5396,6 +5406,10 @@ mpo_demand_obedience_interaction = { } } } + if = { + limit = { scope:hook = yes } + use_hook = scope:recipient + } } } } @@ -5414,12 +5428,17 @@ refill_maa_nomad_interaction = { cooldown = { months = 6 } hidden = yes + is_available = { + government_allows = conditional_maa_refill + trigger_if = { + limit = { is_ai = yes } + any_maa_regiment = { maa_current_troops_count < maa_max_troops_count } + } + is_nomad = yes + } + is_shown = { has_mpo_dlc_trigger = yes - scope:actor = { - is_nomad = yes - government_allows = conditional_maa_refill - } scope:recipient = scope:actor } @@ -5521,11 +5540,6 @@ refill_maa_nomad_interaction = { ai_targets = { ai_recipients = self } - ai_potential = { - is_nomad = yes - government_allows = conditional_maa_refill - any_maa_regiment = { maa_current_troops_count < maa_max_troops_count } - } ai_will_do = { base = 100 @@ -5555,6 +5569,16 @@ influence_child_commander_interaction = { desc = influence_child_commander_interaction_desc + is_available = { + trigger_if = { + limit = { is_ai = yes } + any_relation = { + type = ward + count >= 1 + } + } + } + is_shown = { #any ai ward/hostage has_mpo_dlc_trigger = yes scope:recipient = { @@ -6524,13 +6548,6 @@ influence_child_commander_interaction = { } } - # AI - ai_potential = { - any_relation = { - type = ward - count >= 1 - } - } ai_frequency_by_tier = { barony = 0 county = 72 @@ -6578,13 +6595,24 @@ mpo_make_blood_brother = { popup_on_receive = yes ai_maybe = yes + filter_tags = { accolade } + cooldown = { months = 1 } cooldown_against_recipient = { years = 5 } + is_available = { + mpo_valid_for_blood_brotherhood_trigger = yes + trigger_if = { + limit = { is_ai = yes } + is_at_war = no + is_imprisoned = no + has_blood_brother = no + } + } + is_shown = { # Scope:actor needs to have a suitable CulTrad. scope:actor = { - mpo_valid_for_blood_brotherhood_trigger = yes NOT = { var:had_mpo_temujin_flavor_0020 ?= scope:recipient } } scope:recipient = { @@ -6663,7 +6691,7 @@ mpo_make_blood_brother = { } flag = normal localization = BLOOD_BROTHER_NORMAL - starts_enabled = { always = yes } + starts_enabled = { always = yes } } cost = { @@ -6807,6 +6835,37 @@ mpo_make_blood_brother = { custom_tooltip = blood_brother_foe_modifier_tt } } + show_as_tooltip = { + if = { + limit = { + scope:recipient = { + is_acclaimed = yes + is_knight_of = scope:actor + } + } + scope:recipient = { + if = { + limit = { + scope:actor = { + prestige_level >= 4 + } + } + custom_tooltip = recipient_accolade_major_glory_tt + } + else_if = { + limit = { + scope:actor = { + prestige_level >= 2 + } + } + custom_tooltip = recipient_accolade_medium_glory_tt + } + else = { + custom_tooltip = recipient_accolade_minor_glory_tt + } + } + } + } # If we're a clan this interaction affects unity add_clan_unity_interaction_effect = { @@ -6931,12 +6990,6 @@ mpo_make_blood_brother = { desc = BLOOD_BROTHER_WAR_ALLIES_VALUE } } - ## Performance-enhancement - ai_potential = { - is_imprisoned = no - is_at_war = no - has_blood_brother = no - } ai_target_quick_trigger = { adult = yes } ai_targets = { ai_recipients = liege @@ -7066,7 +7119,7 @@ mpo_make_blood_brother = { } } -# # Jamukha offers Temujin via Event + # Jamukha offers Temujin via Event # modifier = { # trigger = { # scope:actor = { this = character:mpo_mongol_1 } @@ -7093,13 +7146,15 @@ feudalize_nomadic_holding_interaction = { auto_accept = yes + is_available = { + NOT = { + government_has_flag = government_is_in_steppe + } + } + is_shown = { scope:actor = { this = scope:recipient - NOR = { - government_has_flag = government_is_nomadic - government_has_flag = government_is_true_herder - } } } @@ -7135,104 +7190,20 @@ feudalize_nomadic_holding_interaction = { } cost = { - gold = { + treasury_or_gold = { value = 0 - if = { - limit = { - has_treasury = no - } - scope:actor = { - if = { - limit = { # Less expensive for tribals - government_has_flag = government_is_tribal - } - add = { - value = 50 - desc = BASE - } + scope:actor = { + if = { + limit = { # Less expensive for tribals + government_has_flag = government_is_tribal } - else = { - add = { - value = feudalize_holding_interaction_cost - desc = BASE - } - if = { - limit = { # More expensive for admin to make barbarians civilized... - government_has_flag = government_is_administrative - } - add = { - value = feudalize_holding_interaction_cost - multiply = 0.25 - desc = has_admin_government - } - if = { - limit = { # Admin get a bonus for high bureaucracy levels - OR = { - has_realm_law = imperial_bureaucracy_2 - has_realm_law = imperial_bureaucracy_3 - } - } - subtract = { - value = feudalize_holding_interaction_cost - multiply = { - value = 0.1 - if = { - limit = { - has_realm_law = imperial_bureaucracy_3 - } - add = 0.15 - } - } - desc = imperial_bureaucracy - } - } - } - } - } - } - } - treasury = { - value = 0 - if = { - limit = { - has_treasury = yes - } - scope:actor = { add = { - value = feudalize_holding_interaction_cost + value = 50 desc = BASE } - if = { - limit = { # More expensive for admin to make barbarians civilized... - government_has_flag = government_is_administrative - } - add = { - value = feudalize_holding_interaction_cost - multiply = 0.25 - desc = has_admin_government - } - if = { - limit = { # Admin get a bonus for high bureaucracy levels - OR = { - has_realm_law = imperial_bureaucracy_2 - has_realm_law = imperial_bureaucracy_3 - } - } - subtract = { - value = feudalize_holding_interaction_cost - multiply = { - value = 0.1 - if = { - limit = { - has_realm_law = imperial_bureaucracy_3 - } - add = 0.15 - } - } - desc = imperial_bureaucracy - } - } - } + } + else = { + add = feudalize_holding_interaction_cost } } } @@ -7281,48 +7252,17 @@ feudalize_nomadic_holding_interaction = { if = { limit = { - exists = scope:target.title_province - NOT = { government_has_flag = government_is_tribal } - } - scope:target.title_province = { - set_holding_type = castle_holding - } - } - - if = { - limit = { - exists = scope:target.title_province government_has_flag = government_is_tribal } - scope:target.title_province = { + scope:target.title_province ?= { + holding_pre_tribalize_effect = yes set_holding_type = tribal_holding } } - if = { - limit = { - scope:target.county.culture = scope:actor.culture - } - } - else_if = { - limit = { - OR = { - government_has_flag = government_is_tribal - scope:target.county.culture = { has_same_culture_heritage = scope:actor.culture } - } - } - scope:target.county = { - add_county_modifier = { - modifier = mpo_feudalize_nomadic_land_modifier - years = 5 - } - } - } else = { - scope:target.county = { - add_county_modifier = { - modifier = mpo_feudalize_nomadic_land_modifier - years = 30 - } + scope:target.title_province ?= { + holding_pre_feudalize_effect = yes + set_holding_type = castle_holding } } } @@ -7349,13 +7289,15 @@ feudalize_herder_holding_interaction = { auto_accept = yes + is_available = { + NOT = { + government_has_flag = government_is_in_steppe + } + } + is_shown = { scope:actor = { this = scope:recipient - NOR = { - government_has_flag = government_is_nomadic - government_has_flag = government_is_true_herder - } } } @@ -7391,104 +7333,20 @@ feudalize_herder_holding_interaction = { } cost = { - gold = { + treasury_or_gold = { value = 0 - if = { - limit = { - has_treasury = no - } - scope:actor = { - if = { - limit = { # Less expensive for tribals - government_has_flag = government_is_tribal - } - add = { - value = 50 - desc = BASE - } + scope:actor = { + if = { + limit = { # Less expensive for tribals + government_has_flag = government_is_tribal } - else = { - add = { - value = feudalize_holding_interaction_cost - desc = BASE - } - if = { - limit = { # More expensive for admin to make barbarians civilized... - government_has_flag = government_is_administrative - } - add = { - value = feudalize_holding_interaction_cost - multiply = 0.25 - desc = has_admin_government - } - if = { - limit = { # Admin get a bonus for high bureaucracy levels - OR = { - has_realm_law = imperial_bureaucracy_2 - has_realm_law = imperial_bureaucracy_3 - } - } - subtract = { - value = feudalize_holding_interaction_cost - multiply = { - value = 0.1 - if = { - limit = { - has_realm_law = imperial_bureaucracy_3 - } - add = 0.15 - } - } - desc = imperial_bureaucracy - } - } - } - } - } - } - } - treasury = { - value = 0 - if = { - limit = { - has_treasury = yes - } - scope:actor = { add = { - value = feudalize_holding_interaction_cost + value = 50 desc = BASE } - if = { - limit = { # More expensive for admin to make barbarians civilized... - government_has_flag = government_is_administrative - } - add = { - value = feudalize_holding_interaction_cost - multiply = 0.25 - desc = has_admin_government - } - if = { - limit = { # Admin get a bonus for high bureaucracy levels - OR = { - has_realm_law = imperial_bureaucracy_2 - has_realm_law = imperial_bureaucracy_3 - } - } - subtract = { - value = feudalize_holding_interaction_cost - multiply = { - value = 0.1 - if = { - limit = { - has_realm_law = imperial_bureaucracy_3 - } - add = 0.15 - } - } - desc = imperial_bureaucracy - } - } - } + } + else = { + add = feudalize_holding_interaction_cost } } } @@ -7541,6 +7399,7 @@ feudalize_herder_holding_interaction = { NOT = { government_has_flag = government_is_tribal } } scope:target.title_province = { + holding_pre_feudalize_effect = yes set_holding_type = castle_holding } } @@ -7551,36 +7410,10 @@ feudalize_herder_holding_interaction = { government_has_flag = government_is_tribal } scope:target.title_province = { + holding_pre_tribalize_effect = yes set_holding_type = tribal_holding } } - if = { - limit = { - scope:target.county.culture = scope:actor.culture - } - } - else_if = { - limit = { - OR = { - government_has_flag = government_is_tribal - scope:target.county.culture = { has_same_culture_heritage = scope:actor.culture } - } - } - scope:target.county = { - add_county_modifier = { - modifier = mpo_feudalize_nomadic_land_modifier - years = 5 - } - } - } - else = { - scope:target.county = { - add_county_modifier = { - modifier = mpo_feudalize_nomadic_land_modifier - years = 30 - } - } - } } } } @@ -7606,16 +7439,23 @@ mpo_retrieve_land_from_herder_interaction = { popup_on_receive = yes pause_on_receive = yes - interface_priority = 60 ai_min_reply_days = 4 ai_max_reply_days = 9 # actor character giving the titles # recipient character receiving the titles + is_available = { + trigger_if = { + limit = { is_ai = yes } + primary_title.tier >= tier_county + domain_size < domain_limit + } + } + is_shown = { scope:recipient = { - government_has_flag = government_is_true_herder + government_has_flag = government_is_herder } } @@ -7630,9 +7470,7 @@ mpo_retrieve_land_from_herder_interaction = { text = mpo_retrieve_land_from_herder_interaction_neighbour_tt any_sub_realm_county = { any_neighboring_county = { - holder = { - this = scope:recipient - } + holder = scope:recipient } } } @@ -7670,8 +7508,6 @@ mpo_retrieve_land_from_herder_interaction = { has_valid_target = { scope:target = { is_landless_type_title = no - NOT = { is_noble_family_title = yes } - NOT = { is_nomad_title = yes } } } @@ -7743,6 +7579,10 @@ mpo_retrieve_land_from_herder_interaction = { else = { revoke_title_interaction_effect = yes } + if = { + limit = { scope:hook = yes } + use_hook = scope:recipient + } } } @@ -7753,7 +7593,6 @@ mpo_retrieve_land_from_herder_interaction = { # AI ai_targets = { ai_recipients = tributaries - ai_recipients = top_realm_domicile_owners } ai_targets = { ai_recipients = neighboring_rulers @@ -7768,11 +7607,6 @@ mpo_retrieve_land_from_herder_interaction = { hegemony = 4 } - ai_potential = { - domain_size < domain_limit - primary_title.tier >= tier_county - } - ai_accept = { base = 0 modifier = { @@ -7826,16 +7660,20 @@ mpo_vassal_to_tributary_interaction = { common_interaction = yes desc = mpo_vassal_to_tributary_interaction_desc + notification_text = mpo_vassal_to_tributary_interaction_notification #ai_frequency = 0 popup_on_receive = yes pause_on_receive = yes + is_available = { + is_ai = no + government_has_flag = government_is_nomadic + } + is_shown = { scope:actor = { - is_ai = no is_vassal_of = scope:recipient - government_has_flag = government_is_nomadic } } @@ -7886,8 +7724,10 @@ mpo_vassal_to_tributary_interaction = { show_as_tooltip = { break_subject_contract_and_establish_tributary_effect = { SUZERAIN = scope:recipient TRIBUTARY = scope:actor } } - } - scope:actor = { + if = { + limit = { scope:hook = yes } + use_hook = scope:recipient + } trigger_event = mpo_interactions_events.0010 } } @@ -7950,7 +7790,7 @@ mpo_vassal_to_tributary_interaction = { # Are they Nomadic modifier = { add = 25 - desc = game_concept_nomadic_government + desc = RECIPIENT_IS_NOMADIC_RERASON scope:recipient = { government_has_flag = government_is_nomadic } } } @@ -8008,6 +7848,20 @@ mpo_gift_herd_interaction = { hegemony = 0 } + is_available = { + trigger_if = { + limit = { is_ai = yes } + ai_greed < medium_positive_ai_value + domicile.herd >= { + value = major_herd_value_static + multiply = 3 + } + is_available_at_peace_ai_adult = yes + NOT = { has_variable = conqueror } + ai_should_focus_on_building_in_their_capital = no + } + } + is_shown = { NOT = { scope:recipient = scope:actor @@ -8068,7 +7922,7 @@ mpo_gift_herd_interaction = { target = scope:recipient value = domicile.herd_gift_value } - stress_impact = { + stress_and_fulfillment_impact = { greedy = medium_stress_impact_gain } if = { @@ -8079,7 +7933,7 @@ mpo_gift_herd_interaction = { } } } - stress_impact = { + stress_and_fulfillment_impact = { generous = medium_stress_impact_loss } } @@ -8088,8 +7942,8 @@ mpo_gift_herd_interaction = { if = { limit = { scope:actor = { - faith = { - has_doctrine_parameter = piety_from_gifts_active + rite = { + rite_has_parameter = piety_from_gifts_active } } } @@ -8118,17 +7972,6 @@ mpo_gift_herd_interaction = { } } - ai_potential = { - is_available_at_peace_ai_adult = yes - ai_greed < medium_positive_ai_value - domicile.herd >= { - value = major_herd_value_static - multiply = 3 - } - NOT = { has_variable = conqueror } - ai_should_focus_on_building_in_their_capital = no - } - auto_accept = { custom_description = { text = auto_accept_interaction_ai @@ -8271,7 +8114,7 @@ mpo_gift_herd_interaction = { } AND = { # Realm Priests should be considered scope:actor = { - faith = { has_doctrine = doctrine_theocracy_temporal } + rite = { rite_has_doctrine = doctrine_theocracy_temporal } exists = cp:councillor_court_chaplain cp:councillor_court_chaplain = scope:recipient } @@ -8339,14 +8182,46 @@ mpo_offer_submission_or_ruin = { common_interaction = yes force_notification = yes - is_shown = { - scope:actor = { - OR = { - mpo_has_gok_mongol_empire_trigger = yes - has_trait = greatest_of_khans + is_available = { + trigger_if = { + limit = { is_ai = yes } + any_owned_story = { + OR = { + story_type = story_greatest_of_khans + story_type = story_mongol_invasion + } } - mpo_offer_submission_or_ruin_shown_actor_trigger = yes + #Not defending or losing an attacking war + NOT = { + any_character_war = { + OR = { + any_war_defender = { + this = root + } + AND = { + any_war_attacker = { + this = root + } + attacker_war_score < 0 + } + } + } + } + #Already engaged in three wars + any_character_war = { + count >= 3 + exists = this + } + is_independent_ruler = yes } + mpo_offer_submission_or_ruin_shown_actor_trigger = yes + OR = { + mpo_has_gok_mongol_empire_trigger = yes + has_trait = greatest_of_khans + } + } + + is_shown = { scope:recipient = { mpo_offer_submission_or_ruin_shown_recipient_trigger = yes } @@ -8376,25 +8251,9 @@ mpo_offer_submission_or_ruin = { ai_accept = { base = -50 - # MAIN - # Heretic/Infidel modifier. - # Tier difference modifier. - # Dejure modifier. - # Distant/Remote Realm modifier. + # Military power difference modifier. - - # MINOR - # Rivalry modifier. - # Same Dynasty modifier. - # Cultural/Cultural Group modifiers. - # Ageism modifier vs kids. - # Ruler Legitimacy modifier. - # Claimant modifier. - # FP3 Piety Level modifier. - - # OPINION SCALES - # Dread - # Compare Opinion modifier. + offer_vassalization_interaction_ai_acceptance_general = yes #CONFEDERATION modifier = { @@ -8407,7 +8266,7 @@ mpo_offer_submission_or_ruin = { #HERDER modifier = { - scope:recipient = { government_has_flag = government_is_true_herder } + scope:recipient = { government_has_flag = government_is_herder } add = 10000 desc = HERDER_REASON } @@ -8460,57 +8319,6 @@ mpo_offer_submission_or_ruin = { add = 30 } - # PERKS - modifier = { # Perk boost - desc = offer_vassalization_true_ruler_perk_tt - trigger = { - scope:actor = { has_perk = true_ruler_perk } - } - add = 30 - } - modifier = { # Education 5 boost - desc = offer_vassalization_education_diplomacy_5_tt - trigger = { - scope:actor = { has_trait_with_flag = offer_vassalisation_25 } - } - add = 25 - } - - # EVENTS - temporary bonuses gained by events - modifier = { - desc = event_bonus_to_vassal_accept_tt - trigger = { - scope:actor = { has_character_modifier = event_bonus_to_vassal_accept } - } - add = 20 - } - - - # STRUGGLES - bonus gained by successful Sway scheme during the Persian Struggle - modifier = { - desc = fp3_persian_struggle_previously_swayed_tt - trigger = { - scope:recipient = { - has_opinion_modifier = { - modifier = scheme_sway_and_compelled_to_submit_opinion - target = scope:actor - } - } - } - add = 20 - } - - modifier = { - desc = fp3_rekindler_of_iran_modifier_reason - trigger = { - AND = { - scope:actor = { dynasty ?={ has_dynasty_modifier = fp3_rekindler_of_iran_modifier } } - scope:recipient = { culture = { has_cultural_pillar = heritage_iranian } } - } - } - add = 20 - } - # OBEDIENCE modifier = { desc = obedient_interaction_reason @@ -8520,373 +8328,22 @@ mpo_offer_submission_or_ruin = { add = 100 } - modifier = { # Cultural Acceptance - add = offer_vassalage_acceptance_value - desc = cultural_acceptance_interaction_reason - trigger = { - scope:actor = { - NOR = { - has_same_culture_as = scope:recipient - government_has_flag = government_is_nomadic # Nomads do not care about Culture - has_trait = nomadic_philosophy - } - culture = { - cultural_acceptance = { target = scope:recipient.culture value <= 90 } - } - } - } - } - # MAIN - modifier = { #Different faith, no pluralism. - desc = offer_vassalization_interaction_aibehavior_differentfaith_tt - trigger = { - scope:actor = { - NOR = { # Nomads do not care about Faith + # GOVERNMENT + modifier = { # We are both nomadic + desc = interaction_nonnomad_vs_nomad + trigger = { + scope:actor = { + government_has_flag = government_is_nomadic + } + scope:recipient = { government_has_flag = government_is_nomadic - has_trait = nomadic_philosophy - } - } - scope:recipient = { - NOR = { #Of two different faiths AND the potential vassal's faith is not pluralistic. - faith = scope:actor.faith - faith = { has_doctrine = doctrine_pluralism_pluralistic } } } + add = 25 } - add = { - value = -40 - if = { - limit = { - scope:recipient.faith = { - faith_hostility_level = { - target = scope:actor.faith - value >= faith_hostile_level - } - } - } - add = -40 - } - if = { - limit = { - scope:recipient.faith = { - faith_hostility_level = { - target = scope:actor.faith - value >= faith_evil_level - } - } - } - add = -40 - } - } - } - modifier = { #Different faith, pluralism. - desc = offer_vassalization_interaction_aibehavior_differentfaith_tt - trigger = { - scope:actor = { - NOR = { # Nomads do not care about Faith - government_has_flag = government_is_nomadic - has_trait = nomadic_philosophy - } - } - scope:recipient = { - NOT = { - faith = scope:actor.faith - } - NOT = { - scope:actor.faith = { has_doctrine = doctrine_pluralism_pluralistic } - } - faith = { has_doctrine = doctrine_pluralism_pluralistic } - } - } - add = { - value = -20 - if = { - limit = { - scope:recipient.faith = { - faith_hostility_level = { - target = scope:actor.faith - value >= faith_hostile_level - } - } - } - add = -20 - } - if = { - limit = { - scope:recipient.faith = { - faith_hostility_level = { - target = scope:actor.faith - value >= faith_evil_level - } - } - } - add = -20 - } - } - } - - modifier = { #Different faith, both have pluralism. - desc = offer_vassalization_interaction_aibehavior_differentfaith_tt - trigger = { - scope:actor = { - NOR = { # Nomads do not care about Faith - government_has_flag = government_is_nomadic - has_trait = nomadic_philosophy - } - } - scope:recipient = { - NOT = { - faith = scope:actor.faith - } - scope:actor.faith = { has_doctrine = doctrine_pluralism_pluralistic } - faith = { has_doctrine = doctrine_pluralism_pluralistic } - } - } - add = { - value = -10 - if = { - limit = { - scope:recipient.faith = { - faith_hostility_level = { - target = scope:actor.faith - value >= faith_hostile_level - } - } - } - add = -10 - } - if = { - limit = { - scope:recipient.faith = { - faith_hostility_level = { - target = scope:actor.faith - value >= faith_evil_level - } - } - } - add = -10 - } - } - } - modifier = { #I am a King! - desc = offer_vassalization_interaction_aibehavior_hightier_tt - trigger = { - scope:recipient = { highest_held_title_tier = tier_kingdom } - } - add = { - value = -50 - if = { - limit = { - scope:recipient = { - OR = { - government_has_flag = government_is_republic - government_has_flag = government_is_theocracy - } - } - } - add = -50 - } - if = { - limit = { - scope:recipient.sub_realm_size >= 5 - } - add = -50 - } - if = { - limit = { - scope:recipient.sub_realm_size >= 10 - } - add = -100 - } - if = { - limit = { - scope:recipient.sub_realm_size >= 20 - } - add = -100 - } - if = { - limit = { - scope:actor = { - is_ai = yes - } - } - add = -10000 - } - } - } - modifier = { #I am an Emperor!!! - desc = offer_vassalization_interaction_aibehavior_hightier_tt - trigger = { - scope:recipient = { highest_held_title_tier >= tier_empire } - } - add = { - value = -200 - if = { - limit = { - scope:recipient = { - OR = { - government_has_flag = government_is_republic - government_has_flag = government_is_theocracy - } - } - } - add = -100 - } - if = { - limit = { - scope:recipient.sub_realm_size >= 10 - } - add = -100 - } - if = { - limit = { - scope:recipient.sub_realm_size >= 20 - } - add = -200 - } - if = { - limit = { - scope:recipient.sub_realm_size >= 40 - } - add = -200 - } - if = { - limit = { - scope:actor = { - is_ai = yes - } - } - add = -10000 - } - } - } - modifier = { #I fought an independence war against you. - desc = offer_vassalization_interaction_aibehavior_independence_war_tt - trigger = { - scope:recipient = { - exists = var:independence_war_former_liege - var:independence_war_former_liege = scope:actor - } - } - add = -300 - } - modifier = { # We are both nomadic - desc = interaction_nonnomad_vs_nomad - trigger = { - scope:actor = { - government_has_flag = government_is_nomadic - } - scope:recipient = { - government_has_flag = government_is_nomadic - } - } - add = 25 - } - modifier = { # Isolationist tradition - desc = isolationist_reason - trigger = { - NOT = { - scope:actor.culture = scope:recipient.culture - } - scope:recipient.culture = { - has_cultural_tradition = tradition_isolationist - } - } - add = -25 - } - modifier = { #Bankrupt - desc = bankrupt_reason - trigger = { - scope:actor.gold <= -1 - } - add = -100 - } - modifier = { #Wide difference in rank - desc = offer_vassalization_interaction_aibehavior_widetitletier_tt - trigger = { - scope:actor = { - tier_difference = { - target = scope:recipient - value > 2 - } - } - } - add = 40 - } - modifier = { # Allied - desc = offer_vassalization_interaction_aibehavior_allied_tt - trigger = { - scope:recipient = { - is_allied_to = scope:actor - } - } - add = 25 - } - modifier = { # Is the Rightful Liege of recipient - desc = offer_vassalization_interaction_aibehavior_rightfulliegetitleholder_tt - trigger = { - scope:actor = { is_rightful_liege_of = scope:recipient } - } - add = 50 - } - modifier = { # Encircled - desc = offer_vassalization_interaction_aibehavior_encircled_tt - trigger = { - scope:recipient = { - NOT = { - any_neighboring_top_liege_realm_owner = { - this != scope:actor - } - } - NOT = { - any_realm_county = { - is_coastal_county = yes - } - } - } - } - add = 50 - } - modifier = { #Distant Realm — Overseas Connection - desc = offer_vassalization_interaction_aibehavior_distantrealm_tt - trigger = { - scope:actor = { - character_is_realm_neighbor = scope:recipient - NOT = { #Ibiza should want to be a vassal of Mallorca, etc. - character_is_land_realm_neighbor = scope:recipient - scope:actor = { is_rightful_liege_of = scope:recipient } - } - } - } - add = -50 - } - modifier = { #Distant Realm — No Connection - desc = offer_vassalization_interaction_aibehavior_distantrealm_tt - trigger = { - scope:actor = { - NOT = { - character_is_realm_neighbor = scope:recipient - } - } - scope:recipient.capital_province = { squared_distance = { target = scope:actor.capital_province value < 200000 } } - } - add = -100 - } - modifier = { #Remote Realm. - desc = offer_vassalization_interaction_aibehavior_remoterealm_tt - trigger = { - scope:actor = { - NOT = { - character_is_realm_neighbor = scope:recipient - } - } - scope:recipient.capital_province = { squared_distance = { target = scope:actor.capital_province value >= 200000 } } - } - add = -200 - } - modifier = { + modifier = { #Military Strength desc = offer_vassalization_interaction_aibehavior_power_tt_submission_or_ruin add = { value = 1 @@ -8898,580 +8355,180 @@ mpo_offer_submission_or_ruin = { ceiling = yes } } - modifier = { - desc = offer_vassalization_interaction_aibehavior_vassal_opinion_tt - trigger = { - scope:actor = { - number_of_powerful_vassals >= 1 - } - } - add = { - value = 0 - scope:actor = { - every_powerful_vassal = { - if = { - limit = { - save_temporary_opinion_value_as = { - name = vassal_opinion - target = scope:actor - } - } - add = scope:vassal_opinion - } - } - - if = { - limit = { - number_of_powerful_vassals > 0 - } - divide = number_of_powerful_vassals - } - else = { - divide = 10 - } - } - - divide = 10 - } - } - - # MINOR - modifier = { #Friend modifier. - desc = offer_vassalization_interaction_aibehavior_friend_tt - trigger = { - scope:recipient = { - has_relation_friend = scope:actor - NOT = { has_relation_best_friend = scope:actor } - } - } - add = 20 - } - modifier = { #Best Friend modifier. - desc = offer_vassalization_interaction_aibehavior_best_friend_tt - trigger = { - scope:recipient = { - has_relation_best_friend = scope:actor - } - } - add = 50 - } - modifier = { #Lover modifier. - desc = interaction_lover - trigger = { - scope:recipient = { - has_relation_lover = scope:actor - NOT = { has_relation_soulmate = scope:actor } - } - } - add = 20 - } - modifier = { #Soulmate modifier. - desc = interaction_soulmate - trigger = { - scope:recipient = { - has_relation_soulmate = scope:actor - } - } - add = 50 - } - modifier = { #Rivalry modifier. - desc = offer_vassalization_interaction_aibehavior_rival_tt - trigger = { - scope:recipient = { - has_relation_rival = scope:actor - NOT = { has_relation_nemesis = scope:actor } - } - } - add = -200 - } - modifier = { #Nemesis modifier. - desc = offer_vassalization_interaction_aibehavior_nemesis_tt - trigger = { - scope:recipient = { - has_relation_nemesis = scope:actor - } - } - add = -2000 - } - modifier = { #Same Dynasty modifier. - desc = offer_vassalization_interaction_aibehavior_dynasty_tt - trigger = { - scope:recipient = { - dynasty = scope:actor.dynasty - } - } - add = 25 - } - - modifier = { # Same language - add = 5 - desc = speaks_same_language_interaction_reason - trigger = { - scope:actor = { - knows_language_of_culture = scope:recipient.culture - } - } - } - -# modifier = { # Iberian Struggle, less likely for outsiders to vassalize inside -# add = -35 -# desc = iberian_struggle_reason_reason -# trigger = { -# scope:actor = { -# NOT = { -# any_character_struggle = { is_struggle_type = iberian_struggle } -# } -# } -# scope:recipient = { -# any_character_struggle = { is_struggle_type = iberian_struggle } -# } -# } -# } - - modifier = { #Ageism modifier vs kids. - desc = offer_vassalization_interaction_aibehavior_child_tt - trigger = { - scope:actor = { - age < 12 - } - scope:recipient = { - age > 16 - } - } - add = -5 - } - modifier = { #Illegitimacy modifier. - desc = offer_vassalization_interaction_aibehavior_illegitimate_tt - trigger = { - scope:actor = { - OR = { - AND = { - has_trait = bastard - scope:recipient = { - faith = { NOT = { has_doctrine = doctrine_bastardry_none } } - } - } - has_trait = denounced - has_trait = disinherited - } - } - } - add = -10 - } - - modifier = { #Claimant modifier. - desc = offer_vassalization_interaction_aibehavior_claimant_tt - trigger = { - scope:actor.primary_title = { + # TRAITS/PERSONALITY + modifier = { # Ambitious + desc = TAKE_THE_VOWS_AMBITIOUS + trigger = { scope:recipient = { - has_claim_on = prev + has_trait = ambitious } } + add = -30 } - add = -50 - } - - modifier = { # Ambitious - desc = TAKE_THE_VOWS_AMBITIOUS - trigger = { - scope:recipient = { - has_trait = ambitious - } - } - add = -30 - } - modifier = { # Brave - desc = INTERACTION_BRAVE - trigger = { - scope:recipient = { - has_trait = brave - } - } - add = -30 - } - modifier = { # wrathful - desc = INTERACTION_WRATHFUL - trigger = { - scope:recipient = { - has_trait = wrathful - } - } - add = -40 - } - modifier = { # vengeful - desc = INTERACTION_VENGEFUL - trigger = { - scope:recipient = { - has_trait = vengeful - } - } - add = -20 - } - modifier = { # peasant leader - desc = INTERACTION_PEASANT_LEADER - trigger = { - scope:recipient = { - has_trait = peasant_leader - } - } - add = -40 - } - modifier = { # populist leader - desc = INTERACTION_POPULIST_LEADER - trigger = { - scope:recipient = { - has_trait = populist_leader - } - } - add = -100 - } - modifier = { #martial leader - desc = INTERACTION_MARTIAL_EDUCATION - trigger = { - scope:recipient = { - OR = { - has_education_martial_trigger = yes - has_martial_lifestyle_trait_trigger = yes - } - } - } - add = -10 - } - modifier = { # Arrogant - desc = INTERACTION_ARROGANT - trigger = { - scope:recipient = { - has_trait = arrogant - } - } - add = -60 - } - - modifier = { # Fickle - desc = INTERACTION_FICKLE - trigger = { - scope:recipient = { - has_trait = fickle - } - } - add = -10 - } - - modifier = { # Stubborn - desc = INTERACTION_STUBBORN - trigger = { - scope:recipient = { - has_trait = stubborn - } - } - add = -180 - } - - modifier = { # Trusting - desc = TAKE_THE_VOWS_TRUSTING - trigger = { - scope:recipient = { - has_trait = trusting - } - } - add = 20 - } - - modifier = { # Humble - desc = INTERACTION_HUMBLE - trigger = { - scope:recipient = { - has_trait = humble - } - } - add = 20 - } - - modifier = { # Content - desc = INTERACTION_CONTENT - trigger = { - scope:recipient = { - has_trait = content - } - } - add = 20 - } - - modifier = { # Craven - desc = INTERACTION_CRAVEN - trigger = { - scope:recipient = { - has_trait = craven - } - } - add = 100 - } - -# modifier = { # FP3 modifier. -# desc = GENERIC_YOUR_PIETY_LEVEL_MODIFIER -# trigger = { scope:actor = { any_character_struggle = { has_struggle_phase_parameter = piety_level_affects_vassalage_acceptance } } } -# add = { -# value = { -# value = scope:actor.piety_level -# subtract = low_piety_level -# } -# multiply = 10 -# } -# } - - # OPINION INFLUENCE - modifier = { - add = intimidated_reason_value - scope:recipient = { - has_dread_level_towards = { - target = scope:actor - level = 1 - } - } - desc = INTIMIDATED_REASON - } - modifier = { - add = cowed_reason_value - scope:recipient = { - has_dread_level_towards = { - target = scope:actor - level = 2 - } - } - desc = COWED_REASON - } - opinion_modifier = { #Compare Opinion modifier - Clans care more about opinion - trigger = { - scope:actor = { - government_has_flag = government_is_clan - } - scope:recipient = { - government_has_flag = government_is_clan - } - } - who = scope:recipient - opinion_target = scope:actor - multiplier = 0.7 - } - opinion_modifier = { #Compare Opinion modifier. - trigger = { - OR = { - scope:actor = { - NOT = { government_has_flag = government_is_clan } - } + modifier = { # Brave + desc = INTERACTION_BRAVE + trigger = { scope:recipient = { - NOT = { government_has_flag = government_is_clan } + has_trait = brave } } + add = -30 } - who = scope:recipient - opinion_target = scope:actor - multiplier = 0.35 - } - - # DIPLOMATIC COURT GRANDEUR BONUS - modifier = { - trigger = { - scope:actor = { - has_royal_court = yes - has_dlc_feature = royal_court - has_court_type = court_diplomatic - court_grandeur_current_level >= 1 + modifier = { # wrathful + desc = INTERACTION_WRATHFUL + trigger = { + scope:recipient = { + has_trait = wrathful + } } + add = -40 } - add = { - value = scope:actor.court_grandeur_current - if = { - limit = { # Reduce the bonus if you are below your expected level - scope:actor = { - court_grandeur_current_level < court_grandeur_minimum_expected_level + modifier = { # vengeful + desc = INTERACTION_VENGEFUL + trigger = { + scope:recipient = { + has_trait = vengeful + } + } + add = -20 + } + modifier = { # peasant leader + desc = INTERACTION_PEASANT_LEADER + trigger = { + scope:recipient = { + has_trait = peasant_leader + } + } + add = -40 + } + modifier = { # populist leader + desc = INTERACTION_POPULIST_LEADER + trigger = { + scope:recipient = { + has_trait = populist_leader + } + } + add = -100 + } + modifier = { #martial leader + desc = INTERACTION_MARTIAL_EDUCATION + trigger = { + scope:recipient = { + OR = { + has_education_martial_trigger = yes + has_martial_lifestyle_trait_trigger = yes } } - multiply = 0.15 - } - else = { - multiply = 0.3 } + add = -10 + } + modifier = { # Arrogant + desc = INTERACTION_ARROGANT + trigger = { + scope:recipient = { + has_trait = arrogant + } + } + add = -60 + } + + modifier = { # Fickle + desc = INTERACTION_FICKLE + trigger = { + scope:recipient = { + has_trait = fickle + } + } + add = -10 + } + + modifier = { # Stubborn + desc = INTERACTION_STUBBORN + trigger = { + scope:recipient = { + has_trait = stubborn + } + } + add = -180 + } + + modifier = { # Trusting + desc = TAKE_THE_VOWS_TRUSTING + trigger = { + scope:recipient = { + has_trait = trusting + } + } + add = 20 + } + + modifier = { # Humble + desc = INTERACTION_HUMBLE + trigger = { + scope:recipient = { + has_trait = humble + } + } + add = 20 + } + + modifier = { # Content + desc = INTERACTION_CONTENT + trigger = { + scope:recipient = { + has_trait = content + } + } + add = 20 + } + + modifier = { # Craven + desc = INTERACTION_CRAVEN + trigger = { + scope:recipient = { + has_trait = craven + } + } + add = 100 } - desc = DIPLOMATIC_COURT_ACCEPTANCE_INCREASE_REASON - } # CONTRACT OPTIONS - modifier = { - add = 20 - scope:actor = { - faith = { - has_doctrine = doctrine_pluralism_pluralistic - } - } - scope:recipient = { - OR = { - government_has_flag = government_is_feudal - government_has_flag = government_is_clan - } - } - desc = CONTRACT_RELIGIOUS_EXEMPTION_REASON - } - modifier = { - add = 30 - scope:low_obligations = yes - desc = CONTRACT_MERCIFUL_KHAN_REASON - } - modifier = { - add = -10 - scope:send_siege_weapons = yes - desc = CONTRACT_SEND_SIEGE_WEAPONS_REASON - } - modifier = { - add = -50 - scope:recipient = { - NOT = { - government_has_flag = government_is_true_herder - } - } - scope:send_tribute = yes - desc = CONTRACT_SEND_TRIBUTE_REASON - } - - # INSPECTION BONUSES - modifier = { - desc = "INSPECTION_REASON" - add = 5 - scope:recipient = { - has_variable_list = lesser_inspection_bonus - is_target_in_variable_list = { - name = lesser_inspection_bonus - target = scope:actor - } - } - } - modifier = { - desc = "INSPECTION_REASON" - add = 10 - scope:recipient = { - has_variable_list = inspection_bonus - is_target_in_variable_list = { - name = inspection_bonus - target = scope:actor - } - } - } - modifier = { - desc = "INSPECTION_REASON_REWARD" - add = 10 - scope:recipient = { - has_variable_list = inspection_reward - is_target_in_variable_list = { - name = inspection_reward - target = scope:actor - } - } - } - modifier = { - desc = "INSPECTION_REASON_REWARD_FOCUSED" - add = 10 - scope:actor = { has_character_modifier = inspection_reward_focused_vassal_acceptance } - } - - # LOW LEGITIMACY - modifier = { - desc = "LOW_LEGITIMACY_REASON" - add = -10 - scope:actor = { - has_legitimacy_flag = reduced_vassalization_acceptance - } - } - modifier = { - desc = "LOW_LEGITIMACY_REASON" - add = -20 - scope:actor = { - has_legitimacy_flag = very_reduced_vassalization_acceptance - } - } - modifier = { - desc = "LOW_LEGITIMACY_REASON" - add = -50 - scope:actor = { - has_legitimacy_flag = massively_reduced_vassalization_acceptance - } - } - - # HIGH LEGITIMACY - modifier = { - desc = "HIGH_LEGITIMACY_REASON" - add = 25 - scope:actor = { - has_legitimacy_flag = increased_vassalization_acceptance - } - } - modifier = { - desc = "HIGH_LEGITIMACY_REASON" - add = 50 - scope:actor = { - has_legitimacy_flag = very_increased_vassalization_acceptance - } - } - modifier = { - desc = "HIGH_LEGITIMACY_REASON" - add = 75 - scope:actor = { - has_legitimacy_flag = extra_increased_vassalization_acceptance - } - } - - # INFLUENCE - modifier = { - add = 25 - scope:influence_send_option = yes - desc = INFLUENCE_INTERACTION_ACCEPTANCE_SEND_OPTION - } - - #HISTORICALLY ADMIN PEOPLES WANT TO BE ADMIN -# modifier = { -# add = 30 -# scope:actor = { -# government_has_flag = government_is_administrative -# } -# scope:recipient = { -# culture = { -# OR = { -# this = culture:greek -# any_parent_culture_or_above = { -# this = culture:greek -# } -# this = culture:han -# any_parent_culture_or_above = { -# this = culture:han -# } -# } -# } -# } -# -# desc = "HISTORICAL_ADMIN_REASON" -# } - - modifier = { # AI-only weights, keep the pope from vassalizing too fast - trigger = { - exists = faith:roman_catholic.religious_head - faith:roman_catholic.religious_head = scope:actor - scope:actor = { is_ai = yes } - } - add = -50 - } - - modifier = { - trigger = { + modifier = { + add = 20 scope:actor = { - has_variable = severed_head_vassalization - var:severed_head_vassalization = { - this = scope:recipient + rite = { + rite_has_doctrine = doctrine_pluralism_pluralistic } } + scope:recipient = { + OR = { + government_has_flag = government_is_feudal + government_has_flag = government_is_clan + } + } + desc = CONTRACT_RELIGIOUS_EXEMPTION_REASON + } + modifier = { + add = 30 + scope:low_obligations = yes + desc = CONTRACT_MERCIFUL_KHAN_REASON + } + modifier = { + add = -10 + scope:send_siege_weapons = yes + desc = CONTRACT_SEND_SIEGE_WEAPONS_REASON + } + modifier = { + add = -50 + scope:recipient = { + NOT = { + government_has_flag = government_is_herder + } + } + scope:send_tribute = yes + desc = CONTRACT_SEND_TRIBUTE_REASON } - add = 200 - desc = COWED_BY_SEVERED_HEAD_MODIFIER - } modifier = { #You're distracted by another war desc = IS_AT_WAR_REASON @@ -9556,6 +8613,18 @@ mpo_offer_submission_or_ruin = { } add = -1000 } + modifier = { # Pacing needed for AI genghis + trigger = { + scope:actor = { + is_ai = yes + } + scope:recipient = { + is_ai = yes + highest_held_title_tier >= tier_kingdom + } + } + add = -1000 + } } # Low starting obligations @@ -9563,7 +8632,7 @@ mpo_offer_submission_or_ruin = { is_shown = { scope:recipient = { NOT = { - government_has_flag = government_is_true_herder + government_has_flag = government_is_herder } } } @@ -9577,11 +8646,11 @@ mpo_offer_submission_or_ruin = { scope:recipient = { OR = { highest_held_title_tier < tier_duchy - government_has_flag = government_is_true_herder + government_has_flag = government_is_herder } } } - starts_enabled = { always = yes } + starts_enabled = { always = yes } flag = normal_obligations localization = gok_normal_obligations } @@ -9590,7 +8659,7 @@ mpo_offer_submission_or_ruin = { is_shown = { scope:recipient = { NOT = { - government_has_flag = government_is_true_herder + government_has_flag = government_is_herder } highest_held_title_tier >= tier_duchy } @@ -9609,9 +8678,8 @@ mpo_offer_submission_or_ruin = { is_shown = { scope:recipient = { NOR = { - government_has_flag = government_is_true_herder government_has_flag = government_is_tribal - government_has_flag = government_is_nomadic + government_has_flag = government_is_in_steppe } highest_held_title_tier >= tier_duchy } @@ -9631,7 +8699,7 @@ mpo_offer_submission_or_ruin = { is_shown = { scope:recipient = { NOT = { - government_has_flag = government_is_true_herder + government_has_flag = government_is_herder } } } @@ -9716,37 +8784,6 @@ mpo_offer_submission_or_ruin = { } } - ai_potential = { - any_owned_story = { - OR = { - story_type = story_greatest_of_khans - story_type = story_mongol_invasion - } - } - is_independent_ruler = yes - #Not defending or losing an attacking war - NOT = { - any_character_war = { - OR = { - AND = { - any_war_attacker = { - this = root - } - attacker_war_score < 0 - } - any_war_defender = { - this = root - } - } - } - } - #Already engaged in three wars - any_character_war = { - count >= 3 - exists = this - } - } - ai_will_do = { base = 100 @@ -9856,10 +8893,16 @@ mpo_negotiate_obedience_interaction = { popup_on_receive = yes pause_on_receive = yes - is_shown = { - scope:actor = { - government_allows = obedience + is_available = { + government_allows = obedience + trigger_if = { + limit = { is_ai = yes } + prestige >= major_prestige_value + primary_title.tier >= tier_duchy } + } + + is_shown = { scope:recipient = { is_ai = yes obedience_target ?= scope:actor @@ -9941,12 +8984,6 @@ mpo_negotiate_obedience_interaction = { trigger_else = {} } - ai_potential = { - government_allows = obedience - primary_title.tier >= tier_duchy - prestige >= major_prestige_value - } - send_option = { is_valid = { scope:actor = { @@ -10208,7 +9245,10 @@ mpo_negotiate_obedience_interaction = { left_icon = scope:recipient # Pay what you need to pay first if = { - limit = { scope:hook = yes } + limit = { + scope:hook = yes + has_usable_hook = scope:recipient + } use_hook = scope:recipient } if = { @@ -10265,14 +9305,19 @@ join_confederation_interaction = { cooldown_against_recipient = { years = 3 } - is_shown = { - scope:actor = { - is_playable_character = yes - is_independent_ruler = yes - highest_held_title_tier <= tier_duchy - is_landed = yes - is_confederation_member = no + is_available = { + is_independent_ruler = yes + is_landed = yes + OR = { + government_has_flag = government_is_tribal + government_has_flag = government_is_nomadic } + highest_held_title_tier <= tier_duchy + is_playable_character = yes + is_confederation_member = no + } + + is_shown = { scope:recipient.confederation ?= { is_house_based = no } } @@ -10324,9 +9369,8 @@ join_confederation_interaction = { scope:recipient = { NOR = { #Of two different faiths AND the potential vassal's faith is not pluralistic. faith = scope:actor.faith - faith = { has_doctrine = doctrine_pluralism_pluralistic } - government_has_flag = government_is_nomadic - government_has_flag = government_is_true_herder + rite = { rite_has_doctrine = doctrine_pluralism_pluralistic } + government_has_flag = government_is_in_steppe } } } @@ -10363,11 +9407,10 @@ join_confederation_interaction = { scope:recipient = { NOR = { faith = scope:actor.faith - scope:actor.faith = { has_doctrine = doctrine_pluralism_pluralistic } - government_has_flag = government_is_nomadic - government_has_flag = government_is_true_herder + scope:actor.rite = { rite_has_doctrine = doctrine_pluralism_pluralistic } + government_has_flag = government_is_in_steppe } - faith = { has_doctrine = doctrine_pluralism_pluralistic } + rite = { rite_has_doctrine = doctrine_pluralism_pluralistic } } } add = { @@ -10403,11 +9446,10 @@ join_confederation_interaction = { scope:recipient = { NOR = { faith = scope:actor.faith - government_has_flag = government_is_nomadic - government_has_flag = government_is_true_herder + government_has_flag = government_is_in_steppe } - scope:actor.faith = { has_doctrine = doctrine_pluralism_pluralistic } - faith = { has_doctrine = doctrine_pluralism_pluralistic } + scope:actor.rite = { rite_has_doctrine = doctrine_pluralism_pluralistic } + rite = { rite_has_doctrine = doctrine_pluralism_pluralistic } } } add = { @@ -10794,7 +9836,7 @@ join_confederation_interaction = { AND = { has_trait = bastard scope:recipient = { - faith = { NOT = { has_doctrine = doctrine_bastardry_none } } + rite = { NOT = { rite_has_doctrine = doctrine_bastardry_none } } } } has_trait = denounced @@ -11334,3 +10376,4 @@ join_confederation_interaction = { # base = 0 #} } + diff --git a/common/character_interactions/10_tgp_test_interactions.txt b/common/character_interactions/10_tgp_test_interactions.txt index 225f1ba7b..e54b68eef 100644 --- a/common/character_interactions/10_tgp_test_interactions.txt +++ b/common/character_interactions/10_tgp_test_interactions.txt @@ -69,18 +69,18 @@ debug_impact_house_relation_interaction = { custom_tooltip = { text = action_in_debt_click NOT = { - house_has_feud_relation_with_trigger = { TARGET = scope:recipient } + scope:actor = { house_has_feud_relation_with_trigger = { TARGET = scope:recipient } } } } } } can_send = { - house_relation_is_valid_to_start_trigger = { - HOUSE = scope:actor.house - OTHER_HOUSE = scope:recipient.house + house_relation_is_valid_to_start_trigger = { + HOUSE = scope:actor.house + OTHER_HOUSE = scope:recipient.house + } } -} on_accept = { if = { limit = { scope:clear_relation = yes } diff --git a/common/character_interactions/NEOW_modified_interactions.txt b/common/character_interactions/NEOW_modified_interactions.txt index 424aad85d..628670770 100644 --- a/common/character_interactions/NEOW_modified_interactions.txt +++ b/common/character_interactions/NEOW_modified_interactions.txt @@ -6,9 +6,14 @@ ep3_hof_ask_for_influence_interaction = { category = interaction_category_religion desc = ep3_hof_ask_for_influence_interaction_desc + notification_text = ASK_FOR_INFLUENCE_TEXT ai_targets = { ai_recipients = head_of_faith + ai_recipients = realm_priest_superior + ai_recipients = superior + ai_recipients = realm_priest_top_superior + ai_recipients = councillors } ai_target_quick_trigger = { adult = yes @@ -22,51 +27,95 @@ ep3_hof_ask_for_influence_interaction = { hegemony = 24 } + redirect = { + scope:actor = { + spiritual_hof_or_realm_priest_superior_recipient_redirect_effect = yes + } + } + cooldown_against_recipient = { years = 10 } - is_shown = { - scope:recipient != scope:actor - scope:actor.faith = { - religious_head = scope:recipient - has_doctrine = doctrine_spiritual_head + is_available = { + government_has_mechanic = administrative + trigger_if = { + limit = { + is_ai = yes + } + piety >= massive_piety_value + exists = faith.religious_head + exists = house + NOT = { has_trait = excommunicated } } - scope:actor = { - is_playable_character = yes - government_allows = administrative - is_lowborn = no + is_playable_character = yes + faith ?= { + OR = { + has_doctrine = doctrine_spiritual_head + has_doctrine_parameter = has_clerical_regions + } + } + is_lowborn = no + } + + is_shown = { + scope:recipient != scope:puppet_or_actor + scope:puppet_or_actor ?= { + broader_clergy_show_hof_or_superior_interactions_trigger = yes } } is_valid_showing_failures_only = { scope:actor = { + spiritual_hof_or_realm_priest_superior_recipient_trigger = yes piety >= massive_piety_value custom_description = { - text = "hof_ask_for_gold_excommunicated" + text = hof_ask_for_gold_excommunicated NOT = { has_trait = excommunicated } } NOT = { is_at_war_with = scope:recipient } - custom_description = { - text = "hof_interaction_unreformed_faith" + custom_tooltip = { + text = HOF_INTERACTION_UNREFORMED_FAITH NOT = { faith = { has_doctrine_parameter = unreformed } } } - custom_description = { - text = "hof_interaction_has_house_modifier" + custom_tooltip = { + text = HOF_INTERACTION_STATE_FAITH + top_liege = { + government_allows = state_faith + exists = primary_title.state_rite + } + rite = { + this = scope:actor.top_liege.primary_title.state_rite + } + } + custom_tooltip = { + text = HOF_INTERACTION_HAS_HOUSE_MODIFIER house ?= { - NOT = { + NOR = { has_house_modifier = ep3_requested_faith_support_modifier + has_house_modifier = ep3_requested_faith_support_modifier_small } } } - custom_description = { - text = "hof_interaction_is_house_head" + custom_tooltip = { + text = HOF_INTERACTION_IS_HOUSE_HEAD house ?= { house_head = scope:actor } } } - + custom_tooltip = { + text = recipient_supports_3_houses_tt + NOT = { + scope:recipient = { + has_variable_list = cleric_houses_support + variable_list_size = { + name = cleric_houses_support + value >= 3 + } + } + } + } } auto_accept = { @@ -109,19 +158,14 @@ ep3_hof_ask_for_influence_interaction = { } on_decline = { + show_as_tooltip = { + scope:actor = { clerical_interaction_refusal_major_effect = yes } + } scope:actor = { trigger_event = ep3_interactions_events.0621 } } - ai_potential = { - is_playable_character = yes - piety >= massive_piety_value - NOT = { has_trait = excommunicated } - exists = faith.religious_head - exists = house - } - ai_accept = { base = -50 @@ -131,6 +175,33 @@ ep3_hof_ask_for_influence_interaction = { multiplier = 0.5 } + modifier = { + scope:recipient = { + OR = { + ai_greed > 0 + ai_greed < 0 + } + } + add = { + value = scope:recipient.ai_greed + multiply = 0.5 + } + desc = AI_GREED_REASON + } + modifier = { + scope:recipient = { + OR = { + ai_honor > 0 + ai_honor < 0 + } + } + add = { + value = scope:recipient.ai_honor + multiply = -0.5 + } + desc = AI_HONOR_REASON + } + #Doesn't like the emperor... if you're not the emperor modifier = { add = 5 @@ -270,14 +341,6 @@ ep3_hof_ask_for_influence_interaction = { } } - modifier = { # HoF wants the influence for themselves! - add = -10 - desc = THEY_ARE_GREEDY - scope:recipient = { - ai_greed >= high_positive_greed - } - } - modifier = { # I am influential already add = -10 desc = I_AM_INFLUENTIAL @@ -304,11 +367,11 @@ ep3_hof_ask_for_influence_interaction = { OR = { AND = { has_trait = fornicator - trait_is_shunned_or_criminal_in_faith_trigger = { FAITH = faith TRAIT = trait:fornicator GENDER_CHARACTER = scope:actor } + trait_is_shunned_or_criminal_in_rite_trigger = { RITE = rite TRAIT = trait:fornicator GENDER_CHARACTER = scope:actor } } AND = { has_trait = adulterer - trait_is_shunned_or_criminal_in_faith_trigger = { FAITH = faith TRAIT = trait:adulterer GENDER_CHARACTER = scope:actor } + trait_is_shunned_or_criminal_in_rite_trigger = { RITE = rite TRAIT = trait:adulterer GENDER_CHARACTER = scope:actor } } } } @@ -326,7 +389,7 @@ ep3_hof_ask_for_influence_interaction = { add = -50 desc = I_AM_INCESTOUS scope:actor = { - NOT = { scope:recipient = { faith = { has_doctrine = doctrine_consanguinity_unrestricted } } } + NOT = { scope:recipient = { rite = { rite_has_doctrine = doctrine_consanguinity_unrestricted } } } has_trait = incestuous } } @@ -338,15 +401,15 @@ ep3_hof_ask_for_influence_interaction = { OR = { AND = { has_trait = kinslayer_1 - trait_is_shunned_or_criminal_in_faith_trigger = { FAITH = faith TRAIT = trait:kinslayer_1 GENDER_CHARACTER = scope:actor } + trait_is_shunned_or_criminal_in_rite_trigger = { RITE = rite TRAIT = trait:kinslayer_1 GENDER_CHARACTER = scope:actor } } AND = { has_trait = kinslayer_2 - trait_is_shunned_or_criminal_in_faith_trigger = { FAITH = faith TRAIT = trait:kinslayer_2 GENDER_CHARACTER = scope:actor } + trait_is_shunned_or_criminal_in_rite_trigger = { RITE = rite TRAIT = trait:kinslayer_2 GENDER_CHARACTER = scope:actor } } AND = { has_trait = kinslayer_3 - trait_is_shunned_or_criminal_in_faith_trigger = { FAITH = faith TRAIT = trait:kinslayer_3 GENDER_CHARACTER = scope:actor } + trait_is_shunned_or_criminal_in_rite_trigger = { RITE = rite TRAIT = trait:kinslayer_3 GENDER_CHARACTER = scope:actor } } } } @@ -496,20 +559,20 @@ ep3_hof_ask_for_influence_interaction = { scope:actor.num_sinful_traits > 0 desc = I_AM_SINFUL } - + # Admin family attribute bonus modifier = { add = { value = 0 if = { limit = { - scope:actor.house ?= { has_house_aspiration_parameter= increased_clerical_influence_acceptance_3 } + scope:actor.house ?= { has_house_aspiration_parameter = increased_clerical_influence_acceptance_3 } } add = increased_clerical_influence_acceptance_3_value } else_if = { limit = { - scope:actor.house ?= { has_house_aspiration_parameter= increased_clerical_influence_acceptance_2 } + scope:actor.house ?= { has_house_aspiration_parameter = increased_clerical_influence_acceptance_2 } } add = increased_clerical_influence_acceptance_2_value } @@ -519,13 +582,51 @@ ep3_hof_ask_for_influence_interaction = { } scope:actor.house ?= { OR = { - has_house_aspiration_parameter= increased_clerical_influence_acceptance_1 - has_house_aspiration_parameter= increased_clerical_influence_acceptance_2 - has_house_aspiration_parameter= increased_clerical_influence_acceptance_3 + has_house_aspiration_parameter = increased_clerical_influence_acceptance_1 + has_house_aspiration_parameter = increased_clerical_influence_acceptance_2 + has_house_aspiration_parameter = increased_clerical_influence_acceptance_3 } } desc = you_have_faithful_nobles_attribute_with_value_desc } + secular_to_ecclesiastical_pam_factors_acceptance_modifier = yes + + modifier = { + add = -30 + scope:recipient = { + has_variable_list = cleric_houses_support + variable_list_size = { + name = cleric_houses_support + value < 2 + } + } + desc = supports_other_house_reason + } + modifier = { + add = -75 + scope:recipient = { + has_variable_list = cleric_houses_support + variable_list_size = { + name = cleric_houses_support + value >= 2 + } + } + desc = supports_other_houses_reason + } + modifier = { + scope:actor.house ?= { + is_powerful_family = yes + } + add = 25 + desc = YOUR_FAMILY_IS_POWERFUL + } + modifier = { + scope:actor.house ?= { + is_dominant_family = yes + } + add = 50 + desc = YOUR_FAMILY_IS_DOMINANT + } } ai_will_do = { @@ -593,5 +694,25 @@ ep3_hof_ask_for_influence_interaction = { ai_has_cautious_personality = no } } + modifier = { + add = -25 + scope:recipient = { + has_variable_list = cleric_houses_support + variable_list_size = { + name = cleric_houses_support + value < 2 + } + } + } + modifier = { + add = -75 + scope:recipient = { + has_variable_list = cleric_houses_support + variable_list_size = { + name = cleric_houses_support + value >= 2 + } + } + } } } \ No newline at end of file diff --git a/common/character_interactions/tgp_tribute_mission_interactions.txt b/common/character_interactions/tgp_tribute_mission_interactions.txt index 95a0d9137..ad3d2512a 100644 --- a/common/character_interactions/tgp_tribute_mission_interactions.txt +++ b/common/character_interactions/tgp_tribute_mission_interactions.txt @@ -13,8 +13,8 @@ tribute_mission_gold_interaction = { #Small Tribute send_option = { flag = small_gold_tribute - is_valid = { - scope:actor = { + is_valid = { + scope:actor = { gold >= { value = small_gold_tribute_value if = { @@ -29,7 +29,7 @@ tribute_mission_gold_interaction = { send_option = { flag = adequate_gold_tribute is_valid = { - scope:actor = { + scope:actor = { gold >= { value = adequate_gold_tribute_value if = { @@ -44,7 +44,7 @@ tribute_mission_gold_interaction = { send_option = { flag = excessive_gold_tribute is_valid = { - scope:actor = { + scope:actor = { gold >= { value = excessive_gold_tribute_value if = { @@ -130,9 +130,9 @@ tribute_mission_herd_interaction = { send_option = { flag = small_herd_tribute - is_valid = { + is_valid = { scope:actor = { - domicile ?= { + domicile ?= { herd >= { value = { add = small_herd_tribute_value @@ -151,9 +151,9 @@ tribute_mission_herd_interaction = { send_option = { flag = adequate_herd_tribute - is_valid = { + is_valid = { scope:actor = { - domicile ?= { + domicile ?= { herd >= { value = { add = adequate_herd_tribute_value @@ -171,9 +171,9 @@ tribute_mission_herd_interaction = { send_option = { flag = excessive_herd_tribute - is_valid = { + is_valid = { scope:actor = { - domicile ?= { + domicile ?= { herd >= { value = { add = excessive_herd_tribute_value @@ -266,6 +266,7 @@ tribute_mission_artifact_interaction = { target_type = artifact target_filter = actor_artifacts + show_all_targets = no ai_min_reply_days = 0 ai_max_reply_days = 0 @@ -305,7 +306,7 @@ tribute_mission_artifact_interaction = { scope:recipient = { is_ai = no } } } - + ai_accept = { base = 0 modifier = { @@ -326,21 +327,6 @@ tribute_mission_artifact_interaction = { } desc = ARTIFACT_NOT_BENEFIT_REASON } - modifier = { - add = -500 - scope:target = { - has_variable = unwanted_artifact - } - #No harm in reusing the wording - desc = ARTIFACT_CURSED_REASON - } - modifier = { - add = -1000 - scope:target = { - has_variable = cursed_artifact - } - desc = ARTIFACT_CURSED_REASON - } modifier = { add = 100 exists = scope:target.var:banner_dynasty @@ -365,7 +351,7 @@ tribute_mission_artifact_interaction = { desc = ARTIFACT_USELESS_BANNER_REASON } } - + ai_will_do = { base = 50 } @@ -419,6 +405,10 @@ tribute_mission_concubine_interaction = { flag = cannot_be_diarch # just enough to make sure they don't succeed to the diarchy while en route years = 2 } + set_variable = { + name = can_not_marry + years = 2 + } } custom_tooltip = tribute_mission_concubine_interaction.tooltip #Some Mandala piety @@ -431,7 +421,7 @@ tribute_mission_concubine_interaction = { ai_accept = { base = 50 - + modifier = { add = { value = 50 @@ -532,7 +522,7 @@ tribute_mission_concubine_interaction = { modifier = { # A Recipient is unwilling to take a same-sex concubine if their faith doesn't support it add = -1000 - + scope:recipient = { allowed_to_marry_same_sex_trigger = no sex_same_as = scope:secondary_recipient @@ -711,10 +701,10 @@ tribute_mission_eunuch_interaction = { populate_recipient_list = { scope:actor = { every_courtier = { - limit = { + limit = { tribute_mission_is_available_eunuch_trigger = yes NAND = { - faith = { has_doctrine = doctrine_theocracy_temporal } + rite = { rite_has_doctrine = doctrine_theocracy_temporal } this = scope:actor.cp:councillor_court_chaplain } } @@ -749,7 +739,7 @@ tribute_mission_eunuch_interaction = { value = scope:secondary_recipient } custom_tooltip = tribute_mission_eunuch_interaction.tooltip - stress_impact = { + stress_and_fulfillment_impact = { compassionate = medium_stress_impact_gain sadistic = minor_stress_impact_loss } @@ -865,6 +855,7 @@ tribute_mission_bunga_mas_interaction = { target_type = artifact target_filter = actor_artifacts + show_all_targets = no ai_min_reply_days = 0 ai_max_reply_days = 0 @@ -899,11 +890,11 @@ tribute_mission_bunga_mas_interaction = { auto_accept = { always = yes } - + ai_accept = { base = 100 } - + ai_will_do = { base = 50 } From f82f63a78080bdc548701edd25639909f255fe5d Mon Sep 17 00:00:00 2001 From: Thakia Date: Fri, 2 Oct 2026 19:08:22 -0300 Subject: [PATCH 3/5] coat_of_arms and combat_phase_events updated files --- .../dynamic_definitions/00_dynamic_coas.txt | 1 - .../dynamic_definitions/00_norman_coas.txt | 1 - common/coat_of_arms/options/atlases.txt | 51 + .../template_lists/coa_templates.txt | 196 +++- .../template_lists/colored_emblem_lists.txt | 889 +++++++++++------- .../00_knight_phase_events.txt | 28 +- 6 files changed, 815 insertions(+), 351 deletions(-) create mode 100644 common/coat_of_arms/options/atlases.txt diff --git a/common/coat_of_arms/dynamic_definitions/00_dynamic_coas.txt b/common/coat_of_arms/dynamic_definitions/00_dynamic_coas.txt index f7ba41ecd..dc56c3a5f 100644 --- a/common/coat_of_arms/dynamic_definitions/00_dynamic_coas.txt +++ b/common/coat_of_arms/dynamic_definitions/00_dynamic_coas.txt @@ -91,4 +91,3 @@ # coat_of_arms = k_dai_viet # } #} -# \ No newline at end of file diff --git a/common/coat_of_arms/dynamic_definitions/00_norman_coas.txt b/common/coat_of_arms/dynamic_definitions/00_norman_coas.txt index 148767c1b..fdd553ca0 100644 --- a/common/coat_of_arms/dynamic_definitions/00_norman_coas.txt +++ b/common/coat_of_arms/dynamic_definitions/00_norman_coas.txt @@ -178,4 +178,3 @@ # coat_of_arms = c_monmouthshire_norman # } #} -# \ No newline at end of file diff --git a/common/coat_of_arms/options/atlases.txt b/common/coat_of_arms/options/atlases.txt new file mode 100644 index 000000000..af9e80eec --- /dev/null +++ b/common/coat_of_arms/options/atlases.txt @@ -0,0 +1,51 @@ +# For 2D UI CoA +atlas = { + tile_size = { 230 230 } + nr_of_tiles = 64 + actual_size = { {115 115} {115 115} {230 230} {230 230} } +} + +atlas = { + tile_size = { 172 172 } + nr_of_tiles = 64 + fallback = { { 230 230 } {0 0} {0 0} {0 0} } +} + +atlas = { + tile_size = { 124 124 } + nr_of_tiles = 512 + fallback = { { 88 88 } {0 0} {0 0} {0 0} } +} + +atlas = { + tile_size = { 88 88 } + nr_of_tiles = 1024 + actual_size = { {44 44} {44 44} {88 88} {88 88} } +} + +atlas = { + tile_size = { 56 56 } + nr_of_tiles = 4096 + actual_size = { {28 28} {28 28} {56 56} {56 56} } +} + +# For small previews of options in CoA designer +atlas = { + tile_size = { 80 80 } + nr_of_tiles = 128 + actual_size = { {40 40} {40 40} {80 80} {80 80} } +} + +# For saving a screenshot, needs to be matched in coa_designer.gui save_to_disk +atlas = { + tile_size = { 345 345 } + nr_of_tiles = 1 + actual_size = { {345 345} {345 345} {345 345} {345 345} } +} + +# For Units +atlas = { + tile_size = { 256 256 } + nr_of_tiles = 128 + fallback = { { 88 88 } {0 0} {0 0} {0 0} } +} \ No newline at end of file diff --git a/common/coat_of_arms/template_lists/coa_templates.txt b/common/coat_of_arms/template_lists/coa_templates.txt index 335c6effa..80cfc84ef 100644 --- a/common/coat_of_arms/template_lists/coa_templates.txt +++ b/common/coat_of_arms/template_lists/coa_templates.txt @@ -185,10 +185,7 @@ } } NOT = { - OR = { - government_has_flag = government_is_nomadic - government_has_flag = government_is_herder - } + government_has_flag = government_is_in_steppe } } } @@ -696,8 +693,199 @@ } religious_title = { + # Catch-all for faiths without a dedicated pool below 100 = religious_icon_01 100 = religious_icon_01_metal + + special_selection = { + trigger = { + OR = { scope:faith.religion = religion:eastern_orthodox_religion scope:faith.religion = religion:catholic_religion scope:faith.religion = religion:protestant_religion } + } + 4000 = christian_religious_icon_01 + 4000 = christian_religious_icon_01_metal + 1500 = christian_religious_border_01 + 1500 = christian_religious_border_01_metal + 1500 = christian_religious_triple_01 + 1500 = christian_religious_triple_01_metal + 6000 = simple_cross_flag + } + + # Figurative charges, gated on non-aniconist Christianity + special_selection = { + trigger = { + coa_cross_trigger = yes + } + 2500 = christian_religious_figure_01 + } + + special_selection = { + trigger = { + scope:faith.religion = religion:islam_religion + } + 4000 = islamic_religious_icon_01 + 4000 = islamic_religious_icon_01_metal + 1500 = islamic_religious_border_01 + 1500 = islamic_religious_border_01_metal + 1500 = islamic_religious_triple_01 + 1500 = islamic_religious_triple_01_metal + 3000 = islamic_religious_circle_01 + 3000 = islamic_religious_circle_01_metal + } + + special_selection = { + trigger = { + scope:faith.religion = { + save_temporary_scope_as = religion + } + OR = { + scope:religion = religion:hinduism_religion + scope:religion = religion:buddhism_religion + scope:religion = religion:jainism_religion + scope:religion = religion:bon_religion + } + } + 4000 = dharmic_religious_icon_01 + 4000 = dharmic_religious_icon_01_metal + 1500 = dharmic_religious_border_01 + 1500 = dharmic_religious_border_01_metal + 1500 = dharmic_religious_triple_01 + 1500 = dharmic_religious_triple_01_metal + 3000 = dharmic_religious_circle_01 + 3000 = dharmic_religious_circle_01_metal + } + + special_selection = { + trigger = { + scope:faith.religion = { + save_temporary_scope_as = religion + } + OR = { + scope:religion = { is_in_family = rf_sinitic } + scope:religion = religion:shintoism_religion + scope:religion = religion:muism_religion + scope:religion = religion:moism_religion + scope:religion = religion:bimoism_religion + scope:religion = religion:dab_qhuas_religion + scope:religion = religion:kamuyism_religion + scope:religion = religion:utaki_religion + scope:religion = religion:qiangic_religion + scope:religion = religion:mundhum_religion + scope:religion = religion:kaharingan_religion + scope:religion = religion:hantuism_religion + scope:religion = religion:aluk_religion + scope:religion = religion:tolotang_religion + scope:religion = religion:dayawism_religion + scope:religion = religion:satsana_phi_religion + scope:religion = religion:biliku_religion + scope:religion = religion:tani_religion + } + } + 4000 = eastern_religious_icon_01 + 4000 = eastern_religious_icon_01_metal + 1500 = eastern_religious_border_01 + 1500 = eastern_religious_border_01_metal + 1500 = eastern_religious_triple_01 + 1500 = eastern_religious_triple_01_metal + 3000 = eastern_religious_frame_01 + 3000 = eastern_religious_frame_01_metal + } + + special_selection = { + trigger = { + scope:faith.religion = { + save_temporary_scope_as = religion + } + scope:religion = { is_in_family = rf_pagan } + # Pagan-family religions with their own selection above/below + NOR = { + scope:religion = religion:bon_religion + scope:religion = religion:shintoism_religion + scope:religion = religion:muism_religion + scope:religion = religion:moism_religion + scope:religion = religion:bimoism_religion + scope:religion = religion:dab_qhuas_religion + scope:religion = religion:kamuyism_religion + scope:religion = religion:utaki_religion + scope:religion = religion:qiangic_religion + scope:religion = religion:mundhum_religion + scope:religion = religion:kaharingan_religion + scope:religion = religion:hantuism_religion + scope:religion = religion:aluk_religion + scope:religion = religion:tolotang_religion + scope:religion = religion:dayawism_religion + scope:religion = religion:satsana_phi_religion + scope:religion = religion:biliku_religion + scope:religion = religion:tani_religion + scope:religion = religion:akom_religion + scope:religion = religion:waaqism_religion + scope:religion = religion:west_african_religion + scope:religion = religion:west_african_bori_religion + scope:religion = religion:west_african_orisha_religion + scope:religion = religion:west_african_roog_religion + } + } + 4000 = pagan_religious_icon_01 + 4000 = pagan_religious_icon_01_metal + 1500 = pagan_religious_border_01 + 1500 = pagan_religious_border_01_metal + 1500 = pagan_religious_triple_01 + 1500 = pagan_religious_triple_01_metal + 3000 = pagan_religious_circle_01 + 3000 = pagan_religious_circle_01_metal + } + + special_selection = { + trigger = { + scope:faith.religion = religion:judaism_religion + } + 4000 = jewish_religious_icon_01 + 4000 = jewish_religious_icon_01_metal + 3000 = jewish_religious_border_01 + 3000 = jewish_religious_border_01_metal + 3000 = jewish_religious_triple_01 + 3000 = jewish_religious_triple_01_metal + } + + special_selection = { + trigger = { + scope:faith.religion = { + save_temporary_scope_as = religion + } + OR = { + scope:religion = religion:zoroastrianism_religion + scope:religion = religion:dualism_religion + scope:religion = religion:yazidi_religion + } + } + 4000 = zoroastrian_religious_icon_01 + 4000 = zoroastrian_religious_icon_01_metal + 3000 = zoroastrian_religious_border_01 + 3000 = zoroastrian_religious_border_01_metal + 3000 = zoroastrian_religious_triple_01 + 3000 = zoroastrian_religious_triple_01_metal + } + + special_selection = { + trigger = { + scope:faith.religion = { + save_temporary_scope_as = religion + } + OR = { + scope:religion = religion:akom_religion + scope:religion = religion:waaqism_religion + scope:religion = religion:west_african_religion + scope:religion = religion:west_african_bori_religion + scope:religion = religion:west_african_orisha_religion + scope:religion = religion:west_african_roog_religion + } + } + 4000 = african_religious_icon_01 + 4000 = african_religious_icon_01_metal + 3000 = african_religious_border_01 + 3000 = african_religious_border_01_metal + 3000 = african_religious_triple_01 + 3000 = african_religious_triple_01_metal + } } factions = { diff --git a/common/coat_of_arms/template_lists/colored_emblem_lists.txt b/common/coat_of_arms/template_lists/colored_emblem_lists.txt index 042598088..8f5575110 100644 --- a/common/coat_of_arms/template_lists/colored_emblem_lists.txt +++ b/common/coat_of_arms/template_lists/colored_emblem_lists.txt @@ -203,7 +203,6 @@ colored_emblem_texture_lists = { 1 = "ce_lion_saint_mark.dds" 1 = "ce_angel.dds" 1 = "ce_orb.dds" - 10 = "ce_book_open.dds" } special_selection = { @@ -373,6 +372,17 @@ colored_emblem_texture_lists = { 100 = "ce_lion_rampant.dds" } + #Sugarloaf + special_selection = { + trigger = { + government_has_flag = government_is_feudal + culture = { + has_cultural_era_or_later = culture_era_late_medieval + } + } + 10 = "ce_sugarloaf_helmet.dds" + } + # Islamic special_selection = { trigger = { @@ -1009,9 +1019,228 @@ colored_emblem_texture_lists = { special_selection = { trigger = { scope:faith = { has_icon = "zunist_custom" } } 10000000 = "ce_religion_pagan_zunist.dds" } special_selection = { trigger = { scope:faith = { has_icon = "zunist_reformed" } } 10000000 = "ce_religion_pagan_zunist.dds" } - special_selection = { trigger = { scope:faith = { has_doctrine = muhammad_succession_sunni_doctrine } } 50000 = "ce_religion_islam_generic.dds" } - special_selection = { trigger = { scope:faith = { has_doctrine = muhammad_succession_shia_doctrine } } 50000 = "ce_religion_islam_asharism.dds" } - special_selection = { trigger = { scope:faith = { has_doctrine = muhammad_succession_muhakkima_doctrine } } 50000 = "ce_religion_islam_iibadi.dds" } + special_selection = { trigger = { scope:faith = { main_rite = { rite_has_doctrine = muhammad_succession_sunni_doctrine } } } 50000 = "ce_religion_islam_generic.dds" } + special_selection = { trigger = { scope:faith = { main_rite = { rite_has_doctrine = muhammad_succession_shia_doctrine } } } 50000 = "ce_religion_islam_asharism.dds" } + special_selection = { trigger = { scope:faith = { main_rite = { rite_has_doctrine = muhammad_succession_muhakkima_doctrine } } } 50000 = "ce_religion_islam_iibadi.dds" } + } + + # Symbol pools for the religious_title generator (dynamic holy orders & head of faith titles), one per religion family + + christian_religious_icons = { + 100 = "ce_annulet_cross.dds" + 100 = "ce_annulet_cross_patty.dds" + 100 = "ce_chalice.dds" + 100 = "ce_cross_03.dds" + 100 = "ce_cross_04.dds" + 100 = "ce_cross_06.dds" + 100 = "ce_cross_07.dds" + 100 = "ce_cross_08.dds" + 100 = "ce_cross_09.dds" + 100 = "ce_cross_bottony.dds" + 100 = "ce_cross_couped.dds" + 100 = "ce_cross_crosslet.dds" + 100 = "ce_cross_fleury.dds" + 100 = "ce_cross_maltese.dds" + 100 = "ce_cross_moline.dds" + 100 = "ce_cross_patonce.dds" + 100 = "ce_cross_patty.dds" + 100 = "ce_cross_pommee.dds" + 100 = "ce_cross_potent.dds" + 100 = "ce_crosslet_fitchy.dds" + + special_selection = { trigger = { scope:faith = { has_icon = "christian_faith" } } 100 = "ce_religion_christianity_generic.dds" 100 = "ce_chi_rho.dds" 100 = "ce_cross_greek.dds" 100 = "ce_keys_crossed.dds" } + special_selection = { trigger = { scope:faith = { OR = { has_icon = "catholic" has_icon = "catholic_custom" has_icon = "icon_religion_catholicism" } } } 100 = "ce_religion_christianity_catholic.dds" 100 = "ce_keys_crossed.dds" } + special_selection = { trigger = { scope:faith = { OR = { has_icon = "orthodox" has_icon = "orthodox_custom" } } } 100 = "ce_religion_christianity_orthodox.dds" 100 = "ce_cross_patriarchal.dds" 100 = "ce_chi_rho.dds" 100 = "ce_cross_greek.dds" } + special_selection = { trigger = { scope:faith = { OR = { has_icon = "miaphysite" has_icon = "coptic" has_icon = "coptic_custom" } } } 100 = "ce_religion_christianity_coptic.dds" 100 = "ce_cross_coptic.dds" } + special_selection = { trigger = { scope:faith = { OR = { has_icon = "nestorian" has_icon = "nestorian_custom" } } } 100 = "ce_religion_christianity_nestorian.dds" 100 = "ce_nestorian_cross.dds" 100 = "ce_nestorian_cross_birds.dds" 100 = "ce_nestorian_cross_lotus.dds" } + special_selection = { trigger = { scope:faith = { OR = { has_icon = "armenian" has_icon = "christianity_armenian" } } } 100 = "ce_religion_armenian.dds" 100 = "ce_cross_armenian.dds" } + special_selection = { trigger = { scope:faith = { has_icon = "christianity_cathar" } } 100 = "ce_religion_cathar.dds" } + special_selection = { trigger = { scope:faith = { has_icon = "christianity_waldensian" } } 100 = "ce_religion_waldensian.dds" } + special_selection = { trigger = { scope:faith = { has_icon = "christianity_lollard" } } 100 = "ce_religion_lollard.dds" } + special_selection = { trigger = { scope:faith = { has_icon = "christianity_iconoclasm" } } 100 = "ce_religion_iconoclasm.dds" 100 = "ce_cross_greek.dds" } + special_selection = { trigger = { scope:faith = { has_icon = "christianity_bogomilist" } } 100 = "ce_religion_bogomilist.dds" } + special_selection = { trigger = { scope:faith = { has_icon = "christianity_paulicanism" } } 100 = "ce_religion_paulicanism.dds" } + special_selection = { trigger = { scope:faith = { has_icon = "christianity_messalian" } } 100 = "ce_religion_messalian.dds" } + special_selection = { trigger = { scope:faith = { has_icon = "christianity_chalice_01" } } 100 = "ce_chalice_01.dds" } + } + + # Figurative charges have baked white detail, so they are only used by colored-field templates + christian_religious_figurative_icons = { + 100 = "ce_angel.dds" + 100 = "ce_kamon_dove.dds" + 100 = "ce_saint_george.dds" + 100 = "ce_warrior_angel.dds" + } + + islamic_religious_icons = { + 100 = "ce_chalice_mena.dds" + 100 = "ce_crescent.dds" + 100 = "ce_mena_chalice_02.dds" + 100 = "ce_mena_chalice_penbox.dds" + 100 = "ce_mena_crescent.dds" + 100 = "ce_mena_crescent_outline.dds" + 100 = "ce_mena_lamp.dds" + 100 = "ce_mena_rosette.dds" + 100 = "ce_mena_sun.dds" + 100 = "ce_star_08.dds" + + special_selection = { trigger = { scope:faith = { main_rite = { rite_has_doctrine = muhammad_succession_sunni_doctrine } } } 100 = "ce_religion_islam_generic.dds" } + special_selection = { trigger = { scope:faith = { main_rite = { rite_has_doctrine = muhammad_succession_shia_doctrine } } } 100 = "ce_religion_islam_asharism.dds" } + special_selection = { trigger = { scope:faith = { main_rite = { rite_has_doctrine = muhammad_succession_muhakkima_doctrine } } } 100 = "ce_religion_islam_iibadi.dds" 100 = "ce_star_ibadi.dds" } + special_selection = { trigger = { scope:faith = { has_icon = "islam_druze" } } 100 = "ce_religion_druze.dds" } + } + + dharmic_religious_icons = { + 100 = "ce_chakratrisula.dds" + 100 = "ce_conch_shell.dds" + 100 = "ce_dharmachakra.dds" + 100 = "ce_dharmachakra_satti.dds" + 100 = "ce_endless_knot.dds" + 100 = "ce_endless_knot_square.dds" + 100 = "ce_india_small_chakra.dds" + 100 = "ce_india_small_gammate_cross.dds" + 100 = "ce_india_small_lotus.dds" + 100 = "ce_india_small_nandipada.dds" + 100 = "ce_india_small_trisula.dds" + 100 = "ce_lotus.dds" + 100 = "ce_lotus_flower.dds" + 100 = "ce_moon_india.dds" + 100 = "ce_sun_india.dds" + + special_selection = { trigger = { scope:faith.religion = religion:buddhism_religion } 100 = "ce_religion_buddhism_generic.dds" 100 = "ce_buddhist_fishes.dds" 100 = "ce_buddhist_moon.dds" 100 = "ce_gankyil_chakra.dds" 100 = "ce_kamon_lotus.dds" } + special_selection = { trigger = { scope:faith.religion = religion:hinduism_religion } 100 = "ce_religion_hinduism_generic.dds" 100 = "ce_hindu_gammate_cross.dds" 100 = "ce_humped_bull.dds" 100 = "ce_elephant_indian.dds" } + special_selection = { trigger = { scope:faith.religion = religion:jainism_religion } 100 = "ce_religion_jain_generic.dds" } + special_selection = { trigger = { scope:faith.religion = religion:bon_religion } 100 = "ce_religion_bon.dds" 100 = "ce_bon_gammate_cross.dds" 100 = "ce_gankyil_chakra.dds" } + } + + eastern_religious_icons = { + 100 = "ce_dragon.dds" + 100 = "ce_eastern_clouds.dds" + 100 = "ce_endless_knot.dds" + 100 = "ce_kamon_bamboo.dds" + 100 = "ce_kamon_bell.dds" + 100 = "ce_kamon_crane.dds" + 100 = "ce_kamon_mountain.dds" + 100 = "ce_kamon_pine.dds" + 100 = "ce_kamon_turtle.dds" + 100 = "ce_moon.dds" + 100 = "ce_moon_sun.dds" + 100 = "ce_phoenix.dds" + 100 = "ce_sun.dds" + 100 = "ce_tree.dds" + + # Sinitic seal aesthetic + special_selection = { + trigger = { + scope:faith.religion = { + save_temporary_scope_as = religion + } + OR = { + scope:religion = religion:taoism_religion + scope:religion = religion:confucianism_religion + } + } + 100 = "ce_seal_cloud.dds" + 100 = "ce_seal_pictorial_central_dragon.dds" + 100 = "ce_seal_pictorial_central_tiger.dds" + } + special_selection = { trigger = { scope:faith.religion = religion:taoism_religion } 100 = "ce_religion_taoism.dds" 100 = "ce_kamon_gourd.dds" } + special_selection = { trigger = { scope:faith.religion = religion:shintoism_religion } 100 = "ce_kamon_commas.dds" 100 = "ce_kamon_sun.dds" 100 = "ce_kamon_chrysanthemum.dds" 100 = "ce_kamon_sakura.dds" } + special_selection = { trigger = { scope:faith.religion = religion:muism_religion } 100 = "ce_kamon_commas.dds" 100 = "ce_kamon_fan.dds" } + special_selection = { trigger = { scope:faith.religion = religion:utaki_religion } 100 = "ce_kamon_commas.dds" } + special_selection = { trigger = { scope:faith.religion = religion:kamuyism_religion } 100 = "ce_bear_head.dds" 100 = "ce_bear_passant.dds" 100 = "ce_owl.dds" } + special_selection = { trigger = { scope:faith.religion = religion:moism_religion } 100 = "ce_frog.dds" } + special_selection = { trigger = { scope:faith.religion = religion:bimoism_religion } 100 = "ce_tiger.dds" } + special_selection = { + trigger = { + scope:faith.religion = { + save_temporary_scope_as = religion + } + OR = { + scope:religion = religion:aluk_religion + scope:religion = religion:dayawism_religion + scope:religion = religion:hantuism_religion + scope:religion = religion:kaharingan_religion + scope:religion = religion:satsana_phi_religion + scope:religion = religion:tolotang_religion + } + } + 100 = "ce_khmer_boat.dds" + 100 = "ce_khmer_dragon.dds" + 100 = "ce_khmer_naga.dds" + 100 = "ce_khmer_temple.dds" + } + } + + pagan_religious_icons = { + 100 = "ce_fire.dds" + 100 = "ce_moon.dds" + 100 = "ce_moon_sun.dds" + 100 = "ce_pagan_cross_02.dds" + 100 = "ce_pagan_cross_03.dds" + 100 = "ce_pagan_cross_04.dds" + 100 = "ce_pagan_cross_05.dds" + 100 = "ce_pagan_cross_06.dds" + 100 = "ce_pagan_cross_07.dds" + 100 = "ce_pagan_cross_08.dds" + 100 = "ce_pagan_moon_cross.dds" + 100 = "ce_pagan_saltire_cross.dds" + 100 = "ce_pagan_saltire_cross_02.dds" + 100 = "ce_pagan_thunder_cross.dds" + 100 = "ce_solar_cross.dds" + 100 = "ce_sun.dds" + 100 = "ce_tree.dds" + + special_selection = { trigger = { scope:faith.religion = religion:slavic_religion } 100 = "ce_religion_pagan_slavic.dds" 100 = "ce_pagan_cross_svarog.dds" 100 = "ce_pagan_cross_svarog_02.dds" 100 = "ce_pagan_cross_mara.dds" 100 = "ce_pagan_cross_ognevitsa.dds" 100 = "ce_pagan_cross_yarovik.dds" 100 = "ce_pagan_cross_yarovrat.dds" } + special_selection = { trigger = { scope:faith.religion = religion:baltic_religion } 100 = "ce_religion_pagan_romuva.dds" 100 = "ce_cross_auskelis.dds" 100 = "ce_cross_auseklis_02.dds" 100 = "ce_cross_auseklis_03.dds" 100 = "ce_cross_auseklis_04.dds" } + special_selection = { trigger = { scope:faith.religion = religion:finno_ugric_religion } 100 = "ce_religion_pagan_suomenusko.dds" 100 = "ce_pagan_cross_tursas.dds" 100 = "ce_pagan_cross_tursas_02.dds" } + special_selection = { trigger = { scope:faith.religion = religion:germanic_religion } 100 = "ce_religion_pagan_germanic.dds" 100 = "ce_pagan_wotan_cross.dds" 100 = "ce_norse_sun_cross_getinge.dds" 100 = "ce_mjolnir.dds" 100 = "ce_walknut.dds" 100 = "ce_norse_odins_raven.dds" } + special_selection = { trigger = { scope:faith.religion = religion:tengrism_religion } 100 = "ce_religion_pagan_tengri.dds" } + special_selection = { trigger = { scope:faith.religion = religion:magyar_religion } 100 = "ce_religion_magyar.dds" } + special_selection = { trigger = { scope:faith.religion = religion:hellenism_religion } 100 = "ce_religion_pagan_hellenic.dds" 100 = "ce_laurels.dds" } + special_selection = { trigger = { scope:faith.religion = religion:zunism_religion } 100 = "ce_religion_pagan_zunist.dds" } + special_selection = { trigger = { scope:faith.religion = religion:kushitism_religion } 100 = "ce_religion_kushism.dds" 100 = "ce_great_temple.dds" } + special_selection = { trigger = { scope:faith.religion = religion:paganism_religion } 100 = "ce_religion_pagan_generic.dds" } + } + + jewish_religious_icons = { + 100 = "ce_menorah.dds" + 100 = "ce_religion_judaism_generic.dds" + 100 = "ce_star_hexagram.dds" + } + + zoroastrian_religious_icons = { + 100 = "ce_fire.dds" + 100 = "ce_moon_flame.dds" + 100 = "ce_sun.dds" + + special_selection = { trigger = { scope:faith.religion = religion:zoroastrianism_religion } 100 = "ce_religion_zoroastrianism_generic_faravahar.dds" 100 = "ce_zoroastrian_fire_altar.dds" } + special_selection = { trigger = { scope:faith.religion = religion:yazidi_religion } 100 = "ce_religion_yazidism.dds" 100 = "ce_peacock_01.dds" } + special_selection = { trigger = { scope:faith.religion = religion:dualism_religion } 100 = "ce_religion_dualism.dds" } + special_selection = { trigger = { scope:faith = { has_icon = "manichean" } } 100 = "ce_religion_manichean.dds" } + } + + african_religious_icons = { + 100 = "ce_african_crescent_star.dds" + 100 = "ce_african_cross_adiukru.dds" + 100 = "ce_african_cross_ghana.dds" + 100 = "ce_african_cross_gur.dds" + 100 = "ce_african_cross_jenne.dds" + 100 = "ce_african_cross_nu2.dds" + 100 = "ce_african_cross_yoruba.dds" + 100 = "ce_african_dwennimmen.dds" + 100 = "ce_african_omnipotence.dds" + 100 = "ce_african_star_borgu.dds" + 100 = "ce_african_star_gurma.dds" + 100 = "ce_african_star_igbo.dds" + 100 = "ce_african_star_toro.dds" + + special_selection = { trigger = { scope:faith.religion = religion:akom_religion } 100 = "ce_religion_akanism.dds" } + special_selection = { trigger = { scope:faith.religion = religion:waaqism_religion } 100 = "ce_religion_waaqism.dds" } + special_selection = { trigger = { scope:faith.religion = religion:west_african_religion } 100 = "ce_religion_pagan_westafrican.dds" 100 = "ce_religion_vodun.dds" } + special_selection = { trigger = { scope:faith.religion = religion:west_african_bori_religion } 100 = "ce_religion_west_african_bori.dds" } + special_selection = { trigger = { scope:faith.religion = religion:west_african_orisha_religion } 100 = "ce_religion_yoruba.dds" } + special_selection = { trigger = { scope:faith.religion = religion:west_african_roog_religion } 100 = "ce_religion_african_roog_sene.dds" } } ### @@ -1131,7 +1360,7 @@ colored_emblem_texture_lists = { } special_selection = { trigger = { - scope:faith.religion = religion:finnic_religion + scope:faith.religion = religion:finno_ugric_religion } 1000 = "ce_tursansydan.dds" 1000 = "ce_pagan_cross_tursas.dds" @@ -1170,7 +1399,7 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - scope:faith.religion = religion:folkgerman_religion + scope:faith.religion = religion:germanic_religion } 1000 = "ce_pagan_vehmic.dds" 1000 = "ce_pagan_wolf_triskel.dds" @@ -1188,7 +1417,7 @@ colored_emblem_texture_lists = { # Viking specific designs special_selection = { trigger = { - #scope:faith.religion = religion:folkgerman_religion + #scope:faith.religion = religion:germanic_religion coa_norse_trigger = yes } 1000 = "ce_mjolnir.dds" @@ -1230,7 +1459,7 @@ colored_emblem_texture_lists = { # Germanic counterparts special_selection = { trigger = { - #scope:faith.religion = religion:folkgerman_religion + #scope:faith.religion = religion:germanic_religion coa_germanic_trigger = no } 1000 = "ce_irminsul.dds" @@ -1272,7 +1501,7 @@ colored_emblem_texture_lists = { } special_selection = { trigger = { - scope:faith.religion = religion:folkgerman_religion + scope:faith.religion = religion:germanic_religion } 500 = "ce_piles_conjoined.dds" 500 = "ce_pile_mask.dds" @@ -1322,7 +1551,7 @@ colored_emblem_texture_lists = { # Norse - A few designs excluded due to vertical offset special_selection = { trigger = { - scope:faith.religion = religion:folkgerman_religion + scope:faith.religion = religion:germanic_religion coa_norse_trigger = yes } 10000 = "ce_mjolnir.dds" @@ -1367,7 +1596,7 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - scope:faith.religion = religion:folkgerman_religion + scope:faith.religion = religion:germanic_religion } # Circle frames using various viking styles 1000 = "ce_frame_circle_borre_double.dds" @@ -1582,7 +1811,7 @@ colored_emblem_texture_lists = { } special_selection = { trigger = { - scope:faith.religion = religion:mediterranean_religion + scope:faith.religion = religion:magyar_religion } 2000 = "ce_tamgha_magyar_01.dds" 2000 = "ce_tamgha_magyar_02.dds" @@ -1618,24 +1847,24 @@ colored_emblem_texture_lists = { 5000 = "ce_star_sassanian.dds" 5000 = "ce_triskel_sassanian.dds" } -# special_selection = { -# trigger = { -# scope:faith = faith:nestorian -# } -# 20000 = "ce_tamgha_nestorian_01.dds" -# 20000 = "ce_tamgha_nestorian_02.dds" -# 20000 = "ce_nestorian_tamgha_trinity.dds" -# 20000 = "ce_nestorian_tamgha_chalice.dds" -# 20000 = "ce_nestorian_tamgha_cross_hill.dds" -# 20000 = "ce_cross_armenian.dds" -# 20000 = "ce_cross_greek.dds" -# 20000 = "ce_cross_pisan.dds" -# 20000 = "ce_nestorian_cross.dds" -# 20000 = "ce_nestorian_cross_lotus.dds" -# 20000 = "ce_nestorian_bird.dds" -# 20000 = "ce_nestorian_gammate_cross.dds" -# 20000 = "ce_nestorian_cross_birds.dds" -# } + special_selection = { + trigger = { + scope:faith = faith:nestorian + } + 20000 = "ce_tamgha_nestorian_01.dds" + 20000 = "ce_tamgha_nestorian_02.dds" + 20000 = "ce_nestorian_tamgha_trinity.dds" + 20000 = "ce_nestorian_tamgha_chalice.dds" + 20000 = "ce_nestorian_tamgha_cross_hill.dds" + 20000 = "ce_cross_armenian.dds" + 20000 = "ce_cross_greek.dds" + 20000 = "ce_cross_pisan.dds" + 20000 = "ce_nestorian_cross.dds" + 20000 = "ce_nestorian_cross_lotus.dds" + 20000 = "ce_nestorian_bird.dds" + 20000 = "ce_nestorian_gammate_cross.dds" + 20000 = "ce_nestorian_cross_birds.dds" + } special_selection = { # Jewish Khazars trigger = { scope:faith.religion = religion:judaism_religion @@ -1713,41 +1942,41 @@ colored_emblem_texture_lists = { 1000 = "ce_african_otumfuo.dds" 1000 = "ce_african_tamfo.dds" -# special_selection = { -# trigger = { # Serere -# scope:faith.religion = religion:west_african_roog_religion -# } -# 2000 = "ce_african_jaaniw.dds" -# 2000 = "ce_religion_african_roog_sene.dds" -# 2000 = "ce_african_koh.dds" -# 2000 = "ce_african_hidoox.dds" -# 2000 = "ce_african_ja_ir.dds" -# 2000 = "ce_bull_passant.dds" -# 2000 = "ce_antelope.dds" -# 2000 = "ce_camel.dds" -# # Raampa symbols, totemic animals : camel, antelope, lion, hare etc -# } -# special_selection = { # Hausa -# trigger = { -# scope:faith.religion = religion:west_african_bori_religion -# } -# 1000 = "ce_arewa_knot.dds" -# 1000 = "ce_hausa_cross.dds" -# 1000 = "ce_hausa_knot.dds" -# } -# special_selection = { # Mandé -# trigger = { -# scope:faith.religion = religion:west_african_religion -# } -# 1000 = "ce_kanaga.dds" -# 1000 = "ce_african_munun_ti.dds" -# 1000 = "ce_african_mende.dds" -# 1000 = "ce_african_venus.dds" -# 1000 = "ce_african_fu_ti.dds" -# 1000 = "ce_african_kara.dds" -# 1000 = "ce_african_kile.dds" -# 1000 = "ce_african_karaka.dds" -# } + special_selection = { + trigger = { # Serere + scope:faith.religion = religion:west_african_roog_religion + } + 2000 = "ce_african_jaaniw.dds" + 2000 = "ce_religion_african_roog_sene.dds" + 2000 = "ce_african_koh.dds" + 2000 = "ce_african_hidoox.dds" + 2000 = "ce_african_ja_ir.dds" + 2000 = "ce_bull_passant.dds" + 2000 = "ce_antelope.dds" + 2000 = "ce_camel.dds" + # Raampa symbols, totemic animals : camel, antelope, lion, hare etc + } + special_selection = { # Hausa + trigger = { + scope:faith.religion = religion:west_african_bori_religion + } + 1000 = "ce_arewa_knot.dds" + 1000 = "ce_hausa_cross.dds" + 1000 = "ce_hausa_knot.dds" + } + special_selection = { # Mandé + trigger = { + scope:faith.religion = religion:west_african_religion + } + 1000 = "ce_kanaga.dds" + 1000 = "ce_african_munun_ti.dds" + 1000 = "ce_african_mende.dds" + 1000 = "ce_african_venus.dds" + 1000 = "ce_african_fu_ti.dds" + 1000 = "ce_african_kara.dds" + 1000 = "ce_african_kile.dds" + 1000 = "ce_african_karaka.dds" + } } african_geometrical_charge_list = { 1000 = "ce_african_pattern_dancetty.dds" @@ -3408,18 +3637,18 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { has_base_name = "dynn_Chao_671D" } + dynasty ?= { dynasty_has_base_name = "dynn_Chao_671D" } } 100 = "ce_seal_name_chao_671d.dds" } special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Wang_738B" - has_base_name = "dynn_Wang_738B_KO" - has_base_name = "dynn_Vuong_738B" + dynasty_has_base_name = "dynn_Wang_738B" + dynasty_has_base_name = "dynn_Wang_738B_KO" + dynasty_has_base_name = "dynn_Vuong_738B" } } } @@ -3428,11 +3657,11 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Li_674E" - has_base_name = "dynn_I_674E" - has_base_name = "dynn_Ly_674E" + dynasty_has_base_name = "dynn_Li_674E" + dynasty_has_base_name = "dynn_I_674E" + dynasty_has_base_name = "dynn_Ly_674E" } } } @@ -3441,11 +3670,11 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Zhang_5F35" - has_base_name = "dynn_Jang_5F35" - has_base_name = "dynn_Truong_5F35" + dynasty_has_base_name = "dynn_Zhang_5F35" + dynasty_has_base_name = "dynn_Jang_5F35" + dynasty_has_base_name = "dynn_Truong_5F35" } } } @@ -3454,11 +3683,11 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Liu_5289" - has_base_name = "dynn_Yu_5289" - has_base_name = "dynn_Luu_5289" + dynasty_has_base_name = "dynn_Liu_5289" + dynasty_has_base_name = "dynn_Yu_5289" + dynasty_has_base_name = "dynn_Luu_5289" } } } @@ -3467,10 +3696,10 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Chen_9673" - has_base_name = "dynn_Tran_9673" + dynasty_has_base_name = "dynn_Chen_9673" + dynasty_has_base_name = "dynn_Tran_9673" } } } @@ -3479,12 +3708,12 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Yang_694A" - has_base_name = "dynn_Yang_694A_KO" - has_base_name = "dynn_An_694A" - has_base_name = "dynn_Duong_694A" + dynasty_has_base_name = "dynn_Yang_694A" + dynasty_has_base_name = "dynn_Yang_694A_KO" + dynasty_has_base_name = "dynn_An_694A" + dynasty_has_base_name = "dynn_Duong_694A" } } } @@ -3493,11 +3722,11 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Huang_9EC3" - has_base_name = "dynn_Hoang_9EC3" - has_base_name = "dynn_Huang_9EC4" + dynasty_has_base_name = "dynn_Huang_9EC3" + dynasty_has_base_name = "dynn_Hoang_9EC3" + dynasty_has_base_name = "dynn_Huang_9EC4" } } } @@ -3506,11 +3735,11 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Zhao_8D99" - has_base_name = "dynn_Jo_8D99" - has_base_name = "dynn_Trieu_8D99" + dynasty_has_base_name = "dynn_Zhao_8D99" + dynasty_has_base_name = "dynn_Jo_8D99" + dynasty_has_base_name = "dynn_Trieu_8D99" } } } @@ -3519,11 +3748,11 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Wu_5433" - has_base_name = "dynn_O_5433" - has_base_name = "dynn_Ngo_5433" + dynasty_has_base_name = "dynn_Wu_5433" + dynasty_has_base_name = "dynn_O_5433" + dynasty_has_base_name = "dynn_Ngo_5433" } } } @@ -3532,10 +3761,10 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Zhou_5468" - has_base_name = "dynn_Ju_5468" + dynasty_has_base_name = "dynn_Zhou_5468" + dynasty_has_base_name = "dynn_Ju_5468" } } } @@ -3544,10 +3773,10 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Xu_5F90" - has_base_name = "dynn_Seo_5F90" + dynasty_has_base_name = "dynn_Xu_5F90" + dynasty_has_base_name = "dynn_Seo_5F90" } } } @@ -3556,10 +3785,10 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Sun_5B6B" - has_base_name = "dynn_Ton_5B6B" + dynasty_has_base_name = "dynn_Sun_5B6B" + dynasty_has_base_name = "dynn_Ton_5B6B" } } } @@ -3568,10 +3797,10 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Ma_99AC" - has_base_name = "dynn_Ma_99AC_KO" + dynasty_has_base_name = "dynn_Ma_99AC" + dynasty_has_base_name = "dynn_Ma_99AC_KO" } } } @@ -3580,11 +3809,11 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Zhu_6731" - has_base_name = "dynn_Ju_6731" - has_base_name = "dynn_Chu_6731" + dynasty_has_base_name = "dynn_Zhu_6731" + dynasty_has_base_name = "dynn_Ju_6731" + dynasty_has_base_name = "dynn_Chu_6731" } } } @@ -3593,10 +3822,10 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Hu_80E1" - has_base_name = "dynn_Ho_80E1" + dynasty_has_base_name = "dynn_Hu_80E1" + dynasty_has_base_name = "dynn_Ho_80E1" } } } @@ -3605,11 +3834,11 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Guo_90ED" - has_base_name = "dynn_Gwak_90ED" - has_base_name = "dynn_Quach_90ED" + dynasty_has_base_name = "dynn_Guo_90ED" + dynasty_has_base_name = "dynn_Gwak_90ED" + dynasty_has_base_name = "dynn_Quach_90ED" } } } @@ -3618,10 +3847,10 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_He_4F55" - has_base_name = "dynn_Ha_4F55" + dynasty_has_base_name = "dynn_He_4F55" + dynasty_has_base_name = "dynn_Ha_4F55" } } } @@ -3630,11 +3859,11 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Lin_6797" - has_base_name = "dynn_Rim_6797" - has_base_name = "dynn_Lam_6797" + dynasty_has_base_name = "dynn_Lin_6797" + dynasty_has_base_name = "dynn_Rim_6797" + dynasty_has_base_name = "dynn_Lam_6797" } } } @@ -3643,11 +3872,11 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Gao_9AD8" - has_base_name = "dynn_Go_9AD8" - has_base_name = "dynn_Cao_9AD8" + dynasty_has_base_name = "dynn_Gao_9AD8" + dynasty_has_base_name = "dynn_Go_9AD8" + dynasty_has_base_name = "dynn_Cao_9AD8" } } } @@ -3656,10 +3885,10 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Luo_7F85" - has_base_name = "dynn_Ra_7F85" + dynasty_has_base_name = "dynn_Luo_7F85" + dynasty_has_base_name = "dynn_Ra_7F85" } } } @@ -3668,11 +3897,11 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Zheng_912D" - has_base_name = "dynn_Jeong_912D" - has_base_name = "dynn_Trinh_912D" + dynasty_has_base_name = "dynn_Zheng_912D" + dynasty_has_base_name = "dynn_Jeong_912D" + dynasty_has_base_name = "dynn_Trinh_912D" } } } @@ -3681,10 +3910,10 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Liang_6881" - has_base_name = "dynn_Yang_6881" + dynasty_has_base_name = "dynn_Liang_6881" + dynasty_has_base_name = "dynn_Yang_6881" } } } @@ -3693,10 +3922,10 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Xie_8B1D" - has_base_name = "dynn_Ta_8B1D" + dynasty_has_base_name = "dynn_Xie_8B1D" + dynasty_has_base_name = "dynn_Ta_8B1D" } } } @@ -3705,11 +3934,11 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Song_5B8B" - has_base_name = "dynn_Song_5B8B_KO" - has_base_name = "dynn_Tong_5B8B" + dynasty_has_base_name = "dynn_Song_5B8B" + dynasty_has_base_name = "dynn_Song_5B8B_KO" + dynasty_has_base_name = "dynn_Tong_5B8B" } } } @@ -3718,24 +3947,24 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { has_base_name = "dynn_Tang_5510" } + dynasty ?= { dynasty_has_base_name = "dynn_Tang_5510" } } 100 = "ce_seal_name_tang_5510.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Xu_8A31" } + dynasty ?= { dynasty_has_base_name = "dynn_Xu_8A31" } } 100 = "ce_seal_name_xu_8a31.dds" } special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Deng_9127" - has_base_name = "dynn_Dang_9127" + dynasty_has_base_name = "dynn_Deng_9127" + dynasty_has_base_name = "dynn_Dang_9127" } } } @@ -3744,10 +3973,10 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Han_97D3" - has_base_name = "dynn_Han_97D3_KO" + dynasty_has_base_name = "dynn_Han_97D3" + dynasty_has_base_name = "dynn_Han_97D3_KO" } } } @@ -3756,11 +3985,11 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Feng_99AE" - has_base_name = "dynn_Pung_99AE" - has_base_name = "dynn_Phung_99AE" + dynasty_has_base_name = "dynn_Feng_99AE" + dynasty_has_base_name = "dynn_Pung_99AE" + dynasty_has_base_name = "dynn_Phung_99AE" } } } @@ -3769,45 +3998,45 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { has_base_name = "dynn_Cao_66F9" } + dynasty ?= { dynasty_has_base_name = "dynn_Cao_66F9" } } 100 = "ce_seal_name_cao_66f9.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Peng_5F6D" } + dynasty ?= { dynasty_has_base_name = "dynn_Peng_5F6D" } } 100 = "ce_seal_name_peng_5f6d.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Zeng_66FE" } + dynasty ?= { dynasty_has_base_name = "dynn_Zeng_66FE" } } 100 = "ce_seal_name_zeng_66fe.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Xiao_856D" } + dynasty ?= { dynasty_has_base_name = "dynn_Xiao_856D" } } 100 = "ce_seal_name_xiao_856d.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Tian_7530" } + dynasty ?= { dynasty_has_base_name = "dynn_Tian_7530" } } 100 = "ce_seal_name_tian_7530.dds" } special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Dong_8463" - has_base_name = "dynn_Dong_8463_VN" + dynasty_has_base_name = "dynn_Dong_8463" + dynasty_has_base_name = "dynn_Dong_8463_VN" } } } @@ -3816,10 +4045,10 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Pan_6F58" - has_base_name = "dynn_Phan_6F58" + dynasty_has_base_name = "dynn_Pan_6F58" + dynasty_has_base_name = "dynn_Phan_6F58" } } } @@ -3828,17 +4057,17 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { has_base_name = "dynn_Yuan_8881" } + dynasty ?= { dynasty_has_base_name = "dynn_Yuan_8881" } } 100 = "ce_seal_name_yuan_8881.dds" } special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Cai_8521" - has_base_name = "dynn_Chae_8521" + dynasty_has_base_name = "dynn_Cai_8521" + dynasty_has_base_name = "dynn_Chae_8521" } } } @@ -3847,24 +4076,24 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { has_base_name = "dynn_Jiang_8523" } + dynasty ?= { dynasty_has_base_name = "dynn_Jiang_8523" } } 100 = "ce_seal_name_jiang_8523.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Yu_4F59" } + dynasty ?= { dynasty_has_base_name = "dynn_Yu_4F59" } } 100 = "ce_seal_name_yu_4f59.dds" } special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Yu_4E8E" - has_base_name = "dynn_U_4E8E" + dynasty_has_base_name = "dynn_Yu_4E8E" + dynasty_has_base_name = "dynn_U_4E8E" } } } @@ -3873,11 +4102,11 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Du_675C" - has_base_name = "dynn_Du_675C_KO" - has_base_name = "dynn_Do_675C" + dynasty_has_base_name = "dynn_Du_675C" + dynasty_has_base_name = "dynn_Du_675C_KO" + dynasty_has_base_name = "dynn_Do_675C" } } } @@ -3886,32 +4115,32 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { has_base_name = "dynn_Ye_8449" } + dynasty ?= { dynasty_has_base_name = "dynn_Ye_8449" } } 100 = "ce_seal_name_ye_8449.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Cheng_7A0B" } + dynasty ?= { dynasty_has_base_name = "dynn_Cheng_7A0B" } } 100 = "ce_seal_name_cheng_7a0b.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Wei_9B4F" } + dynasty ?= { dynasty_has_base_name = "dynn_Wei_9B4F" } } 100 = "ce_seal_name_wei_9b4f.dds" } special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Su_8607" - has_base_name = "dynn_So_8607" - has_base_name = "dynn_To_8607" + dynasty_has_base_name = "dynn_Su_8607" + dynasty_has_base_name = "dynn_So_8607" + dynasty_has_base_name = "dynn_To_8607" } } } @@ -3920,10 +4149,10 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Lu_5442" - has_base_name = "dynn_Yeo_5442" + dynasty_has_base_name = "dynn_Lu_5442" + dynasty_has_base_name = "dynn_Yeo_5442" } } } @@ -3932,10 +4161,10 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Ding_4E01" - has_base_name = "dynn_Dinh_4E01" + dynasty_has_base_name = "dynn_Ding_4E01" + dynasty_has_base_name = "dynn_Dinh_4E01" } } } @@ -3944,10 +4173,10 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Ren_4EFB" - has_base_name = "dynn_Im_4EFB" + dynasty_has_base_name = "dynn_Ren_4EFB" + dynasty_has_base_name = "dynn_Im_4EFB" } } } @@ -3956,38 +4185,38 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { has_base_name = "dynn_Lu_76E7" } + dynasty ?= { dynasty_has_base_name = "dynn_Lu_76E7" } } 100 = "ce_seal_name_lu_76e7.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Yao_59DA" } + dynasty ?= { dynasty_has_base_name = "dynn_Yao_59DA" } } 100 = "ce_seal_name_yao_59da.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Shen_6C88" } + dynasty ?= { dynasty_has_base_name = "dynn_Shen_6C88" } } 100 = "ce_seal_name_shen_6c88.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Zhong_937E" } + dynasty ?= { dynasty_has_base_name = "dynn_Zhong_937E" } } 100 = "ce_seal_name_zhong_937e.dds" } special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Jiang_59DC" - has_base_name = "dynn_Gang_59DC" + dynasty_has_base_name = "dynn_Jiang_59DC" + dynasty_has_base_name = "dynn_Gang_59DC" } } } @@ -3996,10 +4225,10 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Cui_5D14" - has_base_name = "dynn_Choe_5D14" + dynasty_has_base_name = "dynn_Cui_5D14" + dynasty_has_base_name = "dynn_Choe_5D14" } } } @@ -4008,10 +4237,10 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Tan_8B5A" - has_base_name = "dynn_Dam_8B5A" + dynasty_has_base_name = "dynn_Tan_8B5A" + dynasty_has_base_name = "dynn_Dam_8B5A" } } } @@ -4020,17 +4249,17 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { has_base_name = "dynn_Lu_9678" } + dynasty ?= { dynasty_has_base_name = "dynn_Lu_9678" } } 100 = "ce_seal_name_lu_9678.dds" } special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Fan_8303" - has_base_name = "dynn_Pham_8303" + dynasty_has_base_name = "dynn_Fan_8303" + dynasty_has_base_name = "dynn_Pham_8303" } } } @@ -4039,31 +4268,31 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { has_base_name = "dynn_Wang_6C6A" } + dynasty ?= { dynasty_has_base_name = "dynn_Wang_6C6A" } } 100 = "ce_seal_name_wang_6c6a.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Liao_5ED6" } + dynasty ?= { dynasty_has_base_name = "dynn_Liao_5ED6" } } 100 = "ce_seal_name_liao_5ed6.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Shi_77F3" } + dynasty ?= { dynasty_has_base_name = "dynn_Shi_77F3" } } 100 = "ce_seal_name_shi_77f3.dds" } special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Jin_91D1" - has_base_name = "dynn_Gim_91D1" + dynasty_has_base_name = "dynn_Jin_91D1" + dynasty_has_base_name = "dynn_Gim_91D1" } } } @@ -4072,24 +4301,24 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { has_base_name = "dynn_Wei_97CB" } + dynasty ?= { dynasty_has_base_name = "dynn_Wei_97CB" } } 100 = "ce_seal_name_wei_97cb.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Jia_8CC8" } + dynasty ?= { dynasty_has_base_name = "dynn_Jia_8CC8" } } 100 = "ce_seal_name_jia_8cc8.dds" } special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Xia_590F" - has_base_name = "dynn_Ha_590F" + dynasty_has_base_name = "dynn_Xia_590F" + dynasty_has_base_name = "dynn_Ha_590F" } } } @@ -4098,39 +4327,39 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { has_base_name = "dynn_Fu_5085" } + dynasty ?= { dynasty_has_base_name = "dynn_Fu_5085" } } 100 = "ce_seal_name_fu_5085.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Fang_65B9" } + dynasty ?= { dynasty_has_base_name = "dynn_Fang_65B9" } } 100 = "ce_seal_name_fang_65b9.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Zou_9112" } + dynasty ?= { dynasty_has_base_name = "dynn_Zou_9112" } } 100 = "ce_seal_name_zou_9112.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Xiong_718A" } + dynasty ?= { dynasty_has_base_name = "dynn_Xiong_718A" } } 100 = "ce_seal_name_xiong_718a.dds" } special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Bai_767D" - has_base_name = "dynn_Baek_767D" - has_base_name = "dynn_Bach_767D" + dynasty_has_base_name = "dynn_Bai_767D" + dynasty_has_base_name = "dynn_Baek_767D" + dynasty_has_base_name = "dynn_Bach_767D" } } } @@ -4139,45 +4368,45 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { has_base_name = "dynn_Meng_5B5F" } + dynasty ?= { dynasty_has_base_name = "dynn_Meng_5B5F" } } 100 = "ce_seal_name_meng_5b5f.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Qin_79E6" } + dynasty ?= { dynasty_has_base_name = "dynn_Qin_79E6" } } 100 = "ce_seal_name_qin_79e6.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Qiu_90B1" } + dynasty ?= { dynasty_has_base_name = "dynn_Qiu_90B1" } } 100 = "ce_seal_name_qiu_90b1.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Hou_4FAF" } + dynasty ?= { dynasty_has_base_name = "dynn_Hou_4FAF" } } 100 = "ce_seal_name_hou_4faf.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Jiang_6C5F" } + dynasty ?= { dynasty_has_base_name = "dynn_Jiang_6C5F" } } 100 = "ce_seal_name_jiang_6c5f.dds" } special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Yin_5C39" - has_base_name = "dynn_Yun_5C39" + dynasty_has_base_name = "dynn_Yin_5C39" + dynasty_has_base_name = "dynn_Yun_5C39" } } } @@ -4186,24 +4415,24 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { has_base_name = "dynn_Xue_859B" } + dynasty ?= { dynasty_has_base_name = "dynn_Xue_859B" } } 100 = "ce_seal_name_xue_859b.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Yan_95BB" } + dynasty ?= { dynasty_has_base_name = "dynn_Yan_95BB" } } 100 = "ce_seal_name_yan_95bb.dds" } special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Duan_6BB5" - has_base_name = "dynn_Doan_6BB5" + dynasty_has_base_name = "dynn_Duan_6BB5" + dynasty_has_base_name = "dynn_Doan_6BB5" } } } @@ -4212,10 +4441,10 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Lei_96F7" - has_base_name = "dynn_Loi_96F7" + dynasty_has_base_name = "dynn_Lei_96F7" + dynasty_has_base_name = "dynn_Loi_96F7" } } } @@ -4224,17 +4453,17 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { has_base_name = "dynn_Long_9F8D" } + dynasty ?= { dynasty_has_base_name = "dynn_Long_9F8D" } } 100 = "ce_seal_name_long_9f8d.dds" } special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Li_9ECE" - has_base_name = "dynn_Le_9ECE" + dynasty_has_base_name = "dynn_Li_9ECE" + dynasty_has_base_name = "dynn_Le_9ECE" } } } @@ -4243,10 +4472,10 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Shi_53F2" - has_base_name = "dynn_Sa_53F2" + dynasty_has_base_name = "dynn_Shi_53F2" + dynasty_has_base_name = "dynn_Sa_53F2" } } } @@ -4255,10 +4484,10 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Tao_9676" - has_base_name = "dynn_Dao_9676" + dynasty_has_base_name = "dynn_Tao_9676" + dynasty_has_base_name = "dynn_Dao_9676" } } } @@ -4267,10 +4496,10 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_He_8CC0" - has_base_name = "dynn_Ha_8CC0" + dynasty_has_base_name = "dynn_He_8CC0" + dynasty_has_base_name = "dynn_Ha_8CC0" } } } @@ -4279,59 +4508,59 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { has_base_name = "dynn_Mao_6BDB" } + dynasty ?= { dynasty_has_base_name = "dynn_Mao_6BDB" } } 100 = "ce_seal_name_mao_6bdb.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Hao_90DD" } + dynasty ?= { dynasty_has_base_name = "dynn_Hao_90DD" } } 100 = "ce_seal_name_hao_90dd.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Gu_9867" } + dynasty ?= { dynasty_has_base_name = "dynn_Gu_9867" } } 100 = "ce_seal_name_gu_9867.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Gong_9F94" } + dynasty ?= { dynasty_has_base_name = "dynn_Gong_9F94" } } 100 = "ce_seal_name_gong_9f94.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Shao_90B5" } + dynasty ?= { dynasty_has_base_name = "dynn_Shao_90B5" } } 100 = "ce_seal_name_shao_90b5.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Wan_842C" } + dynasty ?= { dynasty_has_base_name = "dynn_Wan_842C" } } 100 = "ce_seal_name_wan_842c.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Tan_8983" } + dynasty ?= { dynasty_has_base_name = "dynn_Tan_8983" } } 100 = "ce_seal_name_tan_8983.dds" } special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Wu_6B66" - has_base_name = "dynn_Vu_6B66" + dynasty_has_base_name = "dynn_Wu_6B66" + dynasty_has_base_name = "dynn_Vu_6B66" } } } @@ -4340,24 +4569,24 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { has_base_name = "dynn_Qian_9322" } + dynasty ?= { dynasty_has_base_name = "dynn_Qian_9322" } } 100 = "ce_seal_name_qian_9322.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Dai_6234" } + dynasty ?= { dynasty_has_base_name = "dynn_Dai_6234" } } 100 = "ce_seal_name_dai_6234.dds" } special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Yan_56B4" - has_base_name = "dynn_Nghiem_56B4" + dynasty_has_base_name = "dynn_Yan_56B4" + dynasty_has_base_name = "dynn_Nghiem_56B4" } } } @@ -4366,17 +4595,17 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { has_base_name = "dynn_Ou_6B50" } + dynasty ?= { dynasty_has_base_name = "dynn_Ou_6B50" } } 100 = "ce_seal_name_ou_6b50.dds" } special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Mo_83AB" - has_base_name = "dynn_Mac_83AB" + dynasty_has_base_name = "dynn_Mo_83AB" + dynasty_has_base_name = "dynn_Mac_83AB" } } } @@ -4385,24 +4614,24 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { has_base_name = "dynn_Kong_5B54" } + dynasty ?= { dynasty_has_base_name = "dynn_Kong_5B54" } } 100 = "ce_seal_name_kong_5b54.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Xiang_5411" } + dynasty ?= { dynasty_has_base_name = "dynn_Xiang_5411" } } 100 = "ce_seal_name_xiang_5411.dds" } special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Sin_8F9B" - has_base_name = "dynn_Xin_8F9B" + dynasty_has_base_name = "dynn_Sin_8F9B" + dynasty_has_base_name = "dynn_Xin_8F9B" } } } @@ -4411,38 +4640,38 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { has_base_name = "dynn_Xie_90aa" } + dynasty ?= { dynasty_has_base_name = "dynn_Xie_90aa" } } 100 = "ce_seal_name_xie_90aa.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Ximen_897F" } + dynasty ?= { dynasty_has_base_name = "dynn_Xi_897F" } } 100 = "ce_seal_name_xi_897f.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Situ_53F8" } + dynasty ?= { dynasty_has_base_name = "dynn_Situ_53F8_5F92" } } 100 = "ce_seal_name_si_53f8.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Shan_55AE" } + dynasty ?= { dynasty_has_base_name = "dynn_Shan_55AE" } } 100 = "ce_seal_name_dan_55ae.dds" } special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Da_5927" - has_base_name = "dynn_Dae_5927" + dynasty_has_base_name = "dynn_Da_5927" + dynasty_has_base_name = "dynn_Dae_5927" } } } @@ -4451,18 +4680,18 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { has_base_name = "dynn_Bak_6734" } + dynasty ?= { dynasty_has_base_name = "dynn_Bak_6734" } } 100 = "ce_seal_name_po_6734.dds" } special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Quan_6B0A" - has_base_name = "dynn_Gwon_6B0A" - has_base_name = "dynn_Quyen_6B0A" + dynasty_has_base_name = "dynn_Quan_6B0A" + dynasty_has_base_name = "dynn_Gwon_6B0A" + dynasty_has_base_name = "dynn_Quyen_6B0A" } } } @@ -4471,11 +4700,11 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { + dynasty ?= { OR = { - has_base_name = "dynn_Wen_6587" - has_base_name = "dynn_Mun_6587" - has_base_name = "dynn_Van_6587" + dynasty_has_base_name = "dynn_Wen_6587" + dynasty_has_base_name = "dynn_Mun_6587" + dynasty_has_base_name = "dynn_Van_6587" } } } @@ -4484,140 +4713,140 @@ colored_emblem_texture_lists = { special_selection = { trigger = { - house ?= { has_base_name = "dynn_Liao_907C" } + dynasty ?= { dynasty_has_base_name = "dynn_Liao_907C" } } 100 = "ce_seal_name_liao_907c.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Yue_8D8A" } + dynasty ?= { dynasty_has_base_name = "dynn_Yue_8D8A" } } 100 = "ce_seal_name_yue_8d8a.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Zhao_8A54" } + dynasty ?= { dynasty_has_base_name = "dynn_Zhao_8A54" } } 100 = "ce_seal_name_zhao_8a54.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Meng_8499" } + dynasty ?= { dynasty_has_base_name = "dynn_Meng_8499" } } 100 = "ce_seal_name_meng_8499.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Chu_695A" } + dynasty ?= { dynasty_has_base_name = "dynn_Chu_695A" } } 100 = "ce_seal_name_chu_695a.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Yan_71D5" } + dynasty ?= { dynasty_has_base_name = "dynn_Yan_71D5" } } 100 = "ce_seal_name_yan_71d5.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Lu_9B6F" } + dynasty ?= { dynasty_has_base_name = "dynn_Lu_9B6F" } } 100 = "ce_seal_name_lu_9b6f.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Wei_885E" } + dynasty ?= { dynasty_has_base_name = "dynn_Wei_885E" } } 100 = "ce_seal_name_wei_885e.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_You_5E7D" } + dynasty ?= { dynasty_has_base_name = "dynn_You_5E7D" } } 100 = "ce_seal_name_you_5e7d.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Qi_7941" } + dynasty ?= { dynasty_has_base_name = "dynn_Qi_7941" } } 100 = "ce_seal_name_qi_7941.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Shang_5546" } + dynasty ?= { dynasty_has_base_name = "dynn_Shang_5546" } } 100 = "ce_seal_name_shang_5546.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Feng_4E30" } + dynasty ?= { dynasty_has_base_name = "dynn_Feng_4E30" } } 100 = "ce_seal_name_feng_4e30.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Gan_7518" } + dynasty ?= { dynasty_has_base_name = "dynn_Gan_7518" } } 100 = "ce_seal_name_gan_7518.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Hei_9ED1" } + dynasty ?= { dynasty_has_base_name = "dynn_Hei_9ED1" } } 100 = "ce_seal_name_hei_9ed1.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Tu_5C60" } + dynasty ?= { dynasty_has_base_name = "dynn_Tu_5C60" } } 100 = "ce_seal_name_tu_5c60.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Yang_63DA" } + dynasty ?= { dynasty_has_base_name = "dynn_Yang_63DA" } } 100 = "ce_seal_name_yang_63da.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Xuan_5BA3" } + dynasty ?= { dynasty_has_base_name = "dynn_Xuan_5BA3" } } 100 = "ce_seal_name_xuan_5ba3.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Jing_8346" } + dynasty ?= { dynasty_has_base_name = "dynn_Jing_8346" } } 100 = "ce_seal_name_jing_8346.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Hui_60E0" } + dynasty ?= { dynasty_has_base_name = "dynn_Hui_60E0" } } 100 = "ce_seal_name_hui_60e0.dds" } special_selection = { trigger = { - house ?= { has_base_name = "dynn_Murong_6155_5BB9" } + dynasty ?= { dynasty_has_base_name = "dynn_Murong_6155_5BB9" } } 100 = "ce_seal_name_rong_5bb9.dds" } diff --git a/common/combat_phase_events/00_knight_phase_events.txt b/common/combat_phase_events/00_knight_phase_events.txt index b2739f991..b972a5139 100644 --- a/common/combat_phase_events/00_knight_phase_events.txt +++ b/common/combat_phase_events/00_knight_phase_events.txt @@ -174,7 +174,7 @@ knight_berserker_attack = { knight_increase_prowess_chance_effect = yes berserker_kill_version_randomization_effect = yes scope:enemy_knight = { - accolade = { add_glory = minimal_glory_gain } + accolade ?= { add_glory = minimal_glory_gain } } } } @@ -185,8 +185,8 @@ knight_become_berserker = { type = knight is_valid = { - faith = { - has_doctrine = tenet_warmonger + rite = { + rite_has_tenet = tenet_warmonger } OR = { culture = { has_cultural_pillar = heritage_north_germanic } @@ -588,8 +588,8 @@ knight_wounded = { } modifier = { factor = 1.1 - faith = { - has_doctrine_parameter = death_is_glory + rite = { + rite_has_parameter = death_is_glory } } modifier = { @@ -804,8 +804,8 @@ knight_maimed = { } modifier = { factor = 1.1 - faith = { - has_doctrine_parameter = death_is_glory + rite = { + rite_has_parameter = death_is_glory } } modifier = { @@ -1005,8 +1005,8 @@ knight_killed = { } modifier = { factor = 1.1 - faith = { - has_doctrine_parameter = death_is_glory + rite = { + rite_has_parameter = death_is_glory } } modifier = { @@ -1305,9 +1305,7 @@ knight_killed = { if = { limit = { scope:enemy_knight = { - faith = { - has_doctrine = tenet_cranial_trophies - } + tgp_cranial_trophies_collection_trigger = yes } } tgp_cranial_trophies_beheading_effect = { @@ -1359,9 +1357,9 @@ knight_killed = { has_relation_blood_brother = liege } liege = { - NOR = { - has_variable = beheaded_warrior - has_character_flag = beheaded_warrior_cooldown + has_none_of_variables = { + name = beheaded_warrior + name = beheaded_warrior_cooldown } OR = { faith.religion = faith:tengri_pagan.religion From 7be1d9b7e0c5609eceb4393e49197965b67f300d Mon Sep 17 00:00:00 2001 From: Greekman Date: Sat, 3 Oct 2026 02:28:45 +0100 Subject: [PATCH 4/5] a lot of shit mostly orthodox and shit like that --- .../00_divinity_custom_loc.txt | 2928 +++- common/flavorization/00_title_holders.txt | 682 +- common/flavorization/20_pam_flavorization.txt | 53 +- common/governments/00_government_types.txt | 53 - .../02_theocratic_government_types.txt | 161 + common/on_action/dlc/pam/pam_on_actions.txt | 544 + .../faith_types/NEOW_faiths_orthodox.txt | 4 - common/scripted_effects/pam_effects.txt | 14582 ++++++++++++++++ .../characters/NEOW_byzantine_emperors.txt | 36 +- history/characters/NEOW_e_greece.txt | 48 +- history/characters/NEOW_e_nistrenia.txt | 2 +- .../characters/NEOW_ecumenical_patriarchs.txt | 126 +- .../titles/ce3/00_ecclesiastical_titles.txt | 4477 +++++ .../english/replace/council_l_english.yml | 85 +- .../culture/culture_titles_l_english.yml | 1560 ++ .../dlc/pam/pam_flavorization_l_english.yml | 12 + 16 files changed, 24635 insertions(+), 718 deletions(-) create mode 100644 common/governments/02_theocratic_government_types.txt create mode 100644 common/on_action/dlc/pam/pam_on_actions.txt create mode 100644 common/scripted_effects/pam_effects.txt create mode 100644 history/titles/ce3/00_ecclesiastical_titles.txt create mode 100644 localization/english/replace/culture/culture_titles_l_english.yml create mode 100644 localization/english/replace/dlc/pam/pam_flavorization_l_english.yml diff --git a/common/customizable_localization/00_divinity_custom_loc.txt b/common/customizable_localization/00_divinity_custom_loc.txt index 413f073b5..4b8b85c68 100644 --- a/common/customizable_localization/00_divinity_custom_loc.txt +++ b/common/customizable_localization/00_divinity_custom_loc.txt @@ -38,18 +38,18 @@ ToleranceValue = { } } } -# text = { -# localization_key = tolerance_evil -# -# trigger = { -# faith = { -# faith_hostility_level = { -# target = scope:second.faith -# value = faith_evil_level -# } -# } -# } -# } + text = { + localization_key = tolerance_evil + + trigger = { + faith = { + faith_hostility_level = { + target = scope:second.faith + value = faith_evil_level + } + } + } + } } ToleranceValueConcept = { @@ -159,12 +159,12 @@ DefaultPriestTitle = { text = { trigger = { - faith = { + rite = { OR = { - has_doctrine = doctrine_clerical_gender_male_only + rite_has_doctrine = doctrine_clerical_gender_male_only AND = { - has_doctrine = doctrine_clerical_gender_either - has_doctrine = doctrine_gender_male_dominated + rite_has_doctrine = doctrine_clerical_gender_either + rite_has_doctrine = doctrine_gender_male_dominated } } } @@ -174,12 +174,12 @@ DefaultPriestTitle = { text = { trigger = { - faith = { + rite = { OR = { - has_doctrine = doctrine_clerical_gender_female_only + rite_has_doctrine = doctrine_clerical_gender_female_only AND = { - has_doctrine = doctrine_clerical_gender_either - has_doctrine = doctrine_gender_female_dominated + rite_has_doctrine = doctrine_clerical_gender_either + rite_has_doctrine = doctrine_gender_female_dominated } } } @@ -189,9 +189,9 @@ DefaultPriestTitle = { text = { trigger = { - faith = { - has_doctrine = doctrine_clerical_gender_either - has_doctrine = doctrine_gender_equal + rite = { + rite_has_doctrine = doctrine_clerical_gender_either + rite_has_doctrine = doctrine_gender_equal } } localization_key = neuter_priest_title @@ -204,12 +204,12 @@ DefaultPriestTitlePlural = { text = { trigger = { - faith = { + rite = { OR = { - has_doctrine = doctrine_clerical_gender_male_only + rite_has_doctrine = doctrine_clerical_gender_male_only AND = { - has_doctrine = doctrine_clerical_gender_either - has_doctrine = doctrine_gender_male_dominated + rite_has_doctrine = doctrine_clerical_gender_either + rite_has_doctrine = doctrine_gender_male_dominated } } } @@ -219,12 +219,12 @@ DefaultPriestTitlePlural = { text = { trigger = { - faith = { + rite = { OR = { - has_doctrine = doctrine_clerical_gender_female_only + rite_has_doctrine = doctrine_clerical_gender_female_only AND = { - has_doctrine = doctrine_clerical_gender_either - has_doctrine = doctrine_gender_female_dominated + rite_has_doctrine = doctrine_clerical_gender_either + rite_has_doctrine = doctrine_gender_female_dominated } } } @@ -234,9 +234,9 @@ DefaultPriestTitlePlural = { text = { trigger = { - faith = { - has_doctrine = doctrine_clerical_gender_either - has_doctrine = doctrine_gender_equal + rite = { + rite_has_doctrine = doctrine_clerical_gender_either + rite_has_doctrine = doctrine_gender_equal } } localization_key = neuter_priest_title_plural @@ -250,12 +250,12 @@ DefaultPriestWomenMen = { text = { trigger = { - faith = { + rite = { OR = { - has_doctrine = doctrine_clerical_gender_male_only + rite_has_doctrine = doctrine_clerical_gender_male_only AND = { - has_doctrine = doctrine_clerical_gender_either - has_doctrine = doctrine_gender_male_dominated + rite_has_doctrine = doctrine_clerical_gender_either + rite_has_doctrine = doctrine_gender_male_dominated } } } @@ -265,12 +265,12 @@ DefaultPriestWomenMen = { text = { trigger = { - faith = { + rite = { OR = { - has_doctrine = doctrine_clerical_gender_female_only + rite_has_doctrine = doctrine_clerical_gender_female_only AND = { - has_doctrine = doctrine_clerical_gender_either - has_doctrine = doctrine_gender_female_dominated + rite_has_doctrine = doctrine_clerical_gender_either + rite_has_doctrine = doctrine_gender_female_dominated } } } @@ -280,9 +280,9 @@ DefaultPriestWomenMen = { text = { trigger = { - faith = { - has_doctrine = doctrine_clerical_gender_either - has_doctrine = doctrine_gender_equal + rite = { + rite_has_doctrine = doctrine_clerical_gender_either + rite_has_doctrine = doctrine_gender_equal } } localization_key = CHARACTER_MEN @@ -295,12 +295,12 @@ DefaultBishopTitle = { text = { trigger = { - faith = { + rite = { OR = { - has_doctrine = doctrine_clerical_gender_male_only + rite_has_doctrine = doctrine_clerical_gender_male_only AND = { - has_doctrine = doctrine_clerical_gender_either - has_doctrine = doctrine_gender_male_dominated + rite_has_doctrine = doctrine_clerical_gender_either + rite_has_doctrine = doctrine_gender_male_dominated } } } @@ -310,12 +310,12 @@ DefaultBishopTitle = { text = { trigger = { - faith = { + rite = { OR = { - has_doctrine = doctrine_clerical_gender_female_only + rite_has_doctrine = doctrine_clerical_gender_female_only AND = { - has_doctrine = doctrine_clerical_gender_either - has_doctrine = doctrine_gender_female_dominated + rite_has_doctrine = doctrine_clerical_gender_either + rite_has_doctrine = doctrine_gender_female_dominated } } } @@ -325,9 +325,9 @@ DefaultBishopTitle = { text = { trigger = { - faith = { - has_doctrine = doctrine_clerical_gender_either - has_doctrine = doctrine_gender_equal + rite = { + rite_has_doctrine = doctrine_clerical_gender_either + rite_has_doctrine = doctrine_gender_equal } } localization_key = neuter_bishop_title @@ -340,12 +340,12 @@ DefaultBishopTitlePlural = { text = { trigger = { - faith = { + rite = { OR = { - has_doctrine = doctrine_clerical_gender_male_only + rite_has_doctrine = doctrine_clerical_gender_male_only AND = { - has_doctrine = doctrine_clerical_gender_either - has_doctrine = doctrine_gender_male_dominated + rite_has_doctrine = doctrine_clerical_gender_either + rite_has_doctrine = doctrine_gender_male_dominated } } } @@ -355,12 +355,12 @@ DefaultBishopTitlePlural = { text = { trigger = { - faith = { + rite = { OR = { - has_doctrine = doctrine_clerical_gender_female_only + rite_has_doctrine = doctrine_clerical_gender_female_only AND = { - has_doctrine = doctrine_clerical_gender_either - has_doctrine = doctrine_gender_female_dominated + rite_has_doctrine = doctrine_clerical_gender_either + rite_has_doctrine = doctrine_gender_female_dominated } } } @@ -370,9 +370,9 @@ DefaultBishopTitlePlural = { text = { trigger = { - faith = { - has_doctrine = doctrine_clerical_gender_either - has_doctrine = doctrine_gender_equal + rite = { + rite_has_doctrine = doctrine_clerical_gender_either + rite_has_doctrine = doctrine_gender_equal } } localization_key = neuter_bishop_title_plural @@ -406,8 +406,23 @@ GetUnbelieverName = { #Returns Heathens for Pagans and Infidels for other Faiths. GetUnbelieverNamePlural = { type = character - parent = GetUnbelieverName - suffix = _plural + + text = { + trigger = { + faith = { + has_doctrine = pagan_hostility_doctrine + } + } + localization_key = unbeliever_heathen_plural + } + text = { + trigger = { + faith = { + NOT = { has_doctrine = pagan_hostility_doctrine } + } + } + localization_key = unbeliever_infidel_plural + } } GetUnbelieverTerm = { @@ -445,8 +460,29 @@ GetUnbelieverTermPlural = { GetUnbelieverTermAdjective = { type = character - parent = GetUnbelieverTerm - suffix = _adj + + text = { + trigger = { + is_infidel_trigger = { WHO = scope:second TARGET = root} + } + localization_key = unbeliever_infidel_adj + } + text = { + trigger = { + is_heathen_trigger = { WHO = scope:second TARGET = root} + } + localization_key = unbeliever_heathen_adj + } + text = { + trigger = { + is_heretic_trigger = { WHO = scope:second TARGET = root} + } + localization_key = unbeliever_heretic_adj + } + text = { + trigger = { always = yes } + localization_key = unbeliever_unbeliever_adj + } } GetUnbelieverAndForeignerTerm = { @@ -600,8 +636,8 @@ GetAfterLifeDestination = { text = { trigger = { - faith = { - has_doctrine_parameter = reincarnation_resistance_to_conversion + rite = { + rite_has_parameter = reincarnation_resistance_to_conversion } } localization_key = character_afterlife_reincarnation @@ -624,6 +660,45 @@ GetActualBishopTitle = { type = character # 'Early Out' keys for Head of Faith/Landed Rulers. + text = { + trigger = { + pam_is_antipope_trigger = yes + is_female = yes + } + localization_key = anti_religious_head_name_female + } + + text = { + trigger = { + pam_is_antipope_trigger = yes + } + localization_key = anti_religious_head_name + } + + text = { + trigger = { + pam_is_ecumenical_patriarch_trigger = yes + is_female = yes + } + localization_key = ecumenical_matriarch + } + + text = { + trigger = { + pam_is_ecumenical_patriarch_trigger = yes + } + localization_key = ecumenical_patriarch + } + + text = { + trigger = { + exists = faith.religious_head + this = faith.religious_head + is_female = yes + } + localization_key = religious_head_name_female + } + text = { trigger = { exists = faith.religious_head @@ -632,154 +707,149 @@ GetActualBishopTitle = { localization_key = religious_head_name } +# text = { # No longer relevant now that we scope directly to the court owner +# trigger = { +# is_playable_character = yes +# } +# localization_key = ruler_title_name +# } + # Religion-By-Religion Titles for Bishops based on Liege's Tier. - #Thelema + # Zunism text = { trigger = { - highest_held_title_tier >= tier_empire - OR = { - faith.religion = faith:victorian.religion + highest_held_title_tier >= tier_kingdom + faith.religion = faith:zun_pagan.religion + NOT = { # Required formatting to include male/female check as well as vacancy + cp:councillor_court_chaplain ?= { + is_female = yes + } } } - localization_key = councillor_court_chaplain_thelema_religion_empire + localization_key = councillor_court_chaplain_zunism_religion_kingdom + } + text = { + trigger = { + highest_held_title_tier < tier_kingdom + faith.religion = faith:zun_pagan.religion + NOT = { # Required formatting to include male/female check as well as vacancy + cp:councillor_court_chaplain ?= { + is_female = yes + } + } + } + localization_key = councillor_court_chaplain_zunism_religion_duchy + } + + # Zoroastrianism + text = { + trigger = { + highest_held_title_tier >= tier_kingdom + NOT = { # Required formatting to include male/female check as well as vacancy + cp:councillor_court_chaplain ?= { + is_female = yes + } + } + fp3_custom_divinity_for_zoroastrianism_faiths = yes + } + localization_key = councillor_court_chaplain_zoroastrianism_religion_kingdom } text = { trigger = { highest_held_title_tier >= tier_kingdom - OR = { - faith.religion = faith:victorian.religion + NOT = { # Required formatting to include male/female check as well as vacancy + cp:councillor_court_chaplain ?= { + is_female = no + } } + fp3_custom_divinity_for_zoroastrianism_faiths = yes } - localization_key = councillor_court_chaplain_thelema_religion_kingdom + localization_key = councillor_court_chaplain_zoroastrianism_religion_kingdom_female } text = { trigger = { highest_held_title_tier >= tier_duchy - OR = { - faith.religion = faith:victorian.religion + NOT = { # Required formatting to include male/female check as well as vacancy + cp:councillor_court_chaplain ?= { + is_female = yes + } } + fp3_custom_divinity_for_zoroastrianism_faiths = yes } - localization_key = councillor_court_chaplain_thelema_religion_duchy + localization_key = councillor_court_chaplain_zoroastrianism_religion_duchy + } + text = { + trigger = { + highest_held_title_tier >= tier_duchy + NOT = { # Required formatting to include male/female check as well as vacancy + cp:councillor_court_chaplain ?= { + is_female = no + } + } + fp3_custom_divinity_for_zoroastrianism_faiths = yes + } + localization_key = councillor_court_chaplain_zoroastrianism_religion_duchy_female } text = { trigger = { highest_held_title_tier < tier_duchy - OR = { - faith.religion = faith:victorian.religion + fp3_custom_divinity_for_zoroastrianism_faiths = yes + } + localization_key = councillor_court_chaplain_zoroastrianism_religion_county + } + # African Roog + text = { + trigger = { + faith.religion = faith:west_african_roog_pagan.religion + } + localization_key = councillor_court_chaplain_west_african_roog_religion_duchy + } + # African Bori + text = { + trigger = { + faith.religion = faith:west_african_bori_pagan.religion + NOT = { # Required formatting to include male/female check as well as vacancy + cp:councillor_court_chaplain ?= { + is_female = yes + } } } - localization_key = councillor_court_chaplain_thelema_religion_county + localization_key = councillor_court_chaplain_west_african_bori_religion_duchy + } + text = { + trigger = { + faith.religion = faith:west_african_bori_pagan.religion + NOT = { # Required formatting to include male/female check as well as vacancy + cp:councillor_court_chaplain ?= { + is_female = yes + } + } + } + localization_key = councillor_court_chaplain_west_african_bori_religion_duchy_female + } + # African + text = { + trigger = { + faith.religion = faith:west_african_pagan.religion + } + localization_key = councillor_court_chaplain_west_african_religion_duchy + } + + # Tengrism + text = { + trigger = { + highest_held_title_tier >= tier_duchy + faith.religion = faith:tengri_pagan.religion + } + localization_key = councillor_court_chaplain_tengrism_religion_kingdom + } + text = { + trigger = { + highest_held_title_tier < tier_duchy + faith.religion = faith:tengri_pagan.religion + } + localization_key = councillor_court_chaplain_tengrism_religion_duchy } - -# # Zoroastrianism -# text = { -# trigger = { -# highest_held_title_tier >= tier_kingdom -# NOT = { # Required formatting to include male/female check as well as vacancy -# cp:councillor_court_chaplain ?= { -# is_female = yes -# } -# } -# #fp3_custom_divinity_for_zoroastrianism_faiths = yes -# } -# localization_key = councillor_court_chaplain_zoroastrianism_religion_kingdom -# } -# text = { -# trigger = { -# highest_held_title_tier >= tier_kingdom -# NOT = { # Required formatting to include male/female check as well as vacancy -# cp:councillor_court_chaplain ?= { -# is_female = no -# } -# } -# #fp3_custom_divinity_for_zoroastrianism_faiths = yes -# } -# localization_key = councillor_court_chaplain_zoroastrianism_religion_kingdom_female -# } -# text = { -# trigger = { -# highest_held_title_tier >= tier_duchy -# NOT = { # Required formatting to include male/female check as well as vacancy -# cp:councillor_court_chaplain ?= { -# is_female = yes -# } -# } -# #fp3_custom_divinity_for_zoroastrianism_faiths = yes -# } -# localization_key = councillor_court_chaplain_zoroastrianism_religion_duchy -# } -# text = { -# trigger = { -# highest_held_title_tier >= tier_duchy -# NOT = { # Required formatting to include male/female check as well as vacancy -# cp:councillor_court_chaplain ?= { -# is_female = no -# } -# } -# #fp3_custom_divinity_for_zoroastrianism_faiths = yes -# } -# localization_key = councillor_court_chaplain_zoroastrianism_religion_duchy_female -# } -# text = { -# trigger = { -# highest_held_title_tier < tier_duchy -# fp3_custom_divinity_for_zoroastrianism_faiths = yes -# } -# localization_key = councillor_court_chaplain_zoroastrianism_religion_county -# } -# # African Roog -# text = { -# trigger = { -# faith.religion = faith:west_african_roog_pagan.religion -# } -# localization_key = councillor_court_chaplain_west_african_roog_religion_duchy -# } -# # African Bori -# text = { -# trigger = { -# faith.religion = faith:west_african_bori_pagan.religion -# NOT = { # Required formatting to include male/female check as well as vacancy -# cp:councillor_court_chaplain ?= { -# is_female = yes -# } -# } -# } -# localization_key = councillor_court_chaplain_west_african_bori_religion_duchy -# } -# text = { -# trigger = { -# faith.religion = faith:west_african_bori_pagan.religion -# NOT = { # Required formatting to include male/female check as well as vacancy -# cp:councillor_court_chaplain ?= { -# is_female = yes -# } -# } -# } -# localization_key = councillor_court_chaplain_west_african_bori_religion_duchy_female -# } -# # African -# text = { -# trigger = { -# faith.religion = faith:west_african_pagan.religion -# } -# localization_key = councillor_court_chaplain_west_african_religion_duchy -# } -# -# # Tengrism -# text = { -# trigger = { -# highest_held_title_tier >= tier_duchy -# faith.religion = faith:tengri_pagan.religion -# } -# localization_key = councillor_court_chaplain_tengrism_religion_kingdom -# } -# text = { -# trigger = { -# highest_held_title_tier < tier_duchy -# faith.religion = faith:tengri_pagan.religion -# } -# localization_key = councillor_court_chaplain_tengrism_religion_duchy -# } #Taoism text = { @@ -826,14 +896,14 @@ GetActualBishopTitle = { trigger = { faith.religion = faith:finnish_pagan.religion } - localization_key = councillor_court_chaplain_finnic_religion_duchy + localization_key = councillor_court_chaplain_finno_ugric_religion_duchy } #Slavic text = { trigger = { highest_held_title_tier >= tier_duchy - faith.religion = faith:chernobozhye.religion + faith.religion = faith:slavic_pagan.religion NOT = { # Required formatting to include male/female check as well as vacancy cp:councillor_court_chaplain ?= { is_female = yes @@ -845,7 +915,7 @@ GetActualBishopTitle = { text = { trigger = { highest_held_title_tier >= tier_duchy - faith.religion = faith:chernobozhye.religion + faith.religion = faith:slavic_pagan.religion NOT = { # Required formatting to include male/female check as well as vacancy cp:councillor_court_chaplain ?= { is_female = no @@ -857,7 +927,7 @@ GetActualBishopTitle = { text = { trigger = { highest_held_title_tier < tier_duchy - faith.religion = faith:chernobozhye.religion + faith.religion = faith:slavic_pagan.religion NOT = { # Required formatting to include male/female check as well as vacancy cp:councillor_court_chaplain ?= { is_female = yes @@ -869,7 +939,7 @@ GetActualBishopTitle = { text = { trigger = { highest_held_title_tier < tier_duchy - faith.religion = faith:chernobozhye.religion + faith.religion = faith:slavic_pagan.religion NOT = { # Required formatting to include male/female check as well as vacancy cp:councillor_court_chaplain ?= { is_female = no @@ -914,8 +984,9 @@ GetActualBishopTitle = { } OR = { faith.religion = faith:baltic_pagan.religion - faith.religion = faith:chernobozhye.religion + faith.religion = faith:slavic_pagan.religion faith.religion = faith:finnish_pagan.religion + faith.religion = faith:zun_pagan.religion } } localization_key = councillor_court_chaplain_baltic_religion_county @@ -930,8 +1001,9 @@ GetActualBishopTitle = { } OR = { faith.religion = faith:baltic_pagan.religion - faith.religion = faith:chernobozhye.religion + faith.religion = faith:slavic_pagan.religion faith.religion = faith:finnish_pagan.religion + faith.religion = faith:zun_pagan.religion } } localization_key = councillor_court_chaplain_baltic_religion_county_female @@ -949,28 +1021,28 @@ GetActualBishopTitle = { text = { trigger = { highest_held_title_tier >= tier_empire - faith.religion = faith:kabbalist.religion + faith.religion = faith:rabbinic_faith.religion } localization_key = councillor_court_chaplain_judaism_religion_empire } text = { trigger = { highest_held_title_tier >= tier_kingdom - faith.religion = faith:kabbalist.religion + faith.religion = faith:rabbinic_faith.religion } localization_key = councillor_court_chaplain_judaism_religion_kingdom } text = { trigger = { highest_held_title_tier >= tier_duchy - faith.religion = faith:kabbalist.religion + faith.religion = faith:rabbinic_faith.religion } localization_key = councillor_court_chaplain_judaism_religion_duchy } text = { trigger = { highest_held_title_tier < tier_duchy - faith.religion = faith:kabbalist.religion + faith.religion = faith:rabbinic_faith.religion } localization_key = councillor_court_chaplain_judaism_religion_county } @@ -979,78 +1051,78 @@ GetActualBishopTitle = { text = { trigger = { highest_held_title_tier >= tier_kingdom - faith.religion = faith:megalocratic.religion + faith.religion = faith:hellenic_pagan.religion NOT = { # Required formatting to include male/female check as well as vacancy cp:councillor_court_chaplain ?= { is_female = yes } } } - localization_key = councillor_court_chaplain_theomach_religion_kingdom + localization_key = councillor_court_chaplain_hellenism_religion_kingdom } text = { trigger = { highest_held_title_tier >= tier_kingdom - faith.religion = faith:megalocratic.religion + faith.religion = faith:hellenic_pagan.religion NOT = { # Required formatting to include male/female check as well as vacancy cp:councillor_court_chaplain ?= { is_female = no } } } - localization_key = councillor_court_chaplain_theomach_religion_kingdom_female + localization_key = councillor_court_chaplain_hellenism_religion_kingdom_female } text = { trigger = { highest_held_title_tier >= tier_duchy - faith.religion = faith:megalocratic.religion + faith.religion = faith:hellenic_pagan.religion } - localization_key = councillor_court_chaplain_theomach_religion_duchy + localization_key = councillor_court_chaplain_hellenism_religion_duchy } text = { trigger = { highest_held_title_tier < tier_duchy - faith.religion = faith:megalocratic.religion + faith.religion = faith:hellenic_pagan.religion NOT = { # Required formatting to include male/female check as well as vacancy cp:councillor_court_chaplain ?= { is_female = yes } } } - localization_key = councillor_court_chaplain_theomach_religion_county + localization_key = councillor_court_chaplain_hellenism_religion_county } text = { trigger = { highest_held_title_tier < tier_duchy - faith.religion = faith:megalocratic.religion + faith.religion = faith:hellenic_pagan.religion NOT = { # Required formatting to include male/female check as well as vacancy cp:councillor_court_chaplain ?= { is_female = no } } } - localization_key = councillor_court_chaplain_theomach_religion_county_female + localization_key = councillor_court_chaplain_hellenism_religion_county_female } #Norse text = { trigger = { highest_held_title_tier >= tier_kingdom - faith.religion = faith:folketro.religion + faith.religion = faith:norse_pagan.religion } localization_key = councillor_court_chaplain_germanic_religion_kingdom } text = { trigger = { highest_held_title_tier >= tier_duchy - faith.religion = faith:folketro.religion + faith.religion = faith:norse_pagan.religion } localization_key = councillor_court_chaplain_germanic_religion_duchy } text = { trigger = { highest_held_title_tier < tier_duchy - faith.religion = faith:folketro.religion + faith.religion = faith:norse_pagan.religion NOT = { # Required formatting to include male/female check as well as vacancy cp:councillor_court_chaplain ?= { is_female = yes @@ -1062,7 +1134,7 @@ GetActualBishopTitle = { text = { trigger = { highest_held_title_tier < tier_duchy - faith.religion = faith:folketro.religion + faith.religion = faith:norse_pagan.religion NOT = { # Required formatting to include male/female check as well as vacancy cp:councillor_court_chaplain ?= { is_female = no @@ -1072,23 +1144,23 @@ GetActualBishopTitle = { localization_key = councillor_court_chaplain_germanic_religion_county_female } -# #Dualism -# text = { -# trigger = { -# highest_held_title_tier < tier_duchy -# faith.religion = faith:manichean.religion -# } -# localization_key = councillor_court_chaplain_dualism_religion_county -# } -# -# #Bon -# text = { -# trigger = { -# highest_held_title_tier >= tier_kingdom -# faith.religion = faith:bon.religion -# } -# localization_key = councillor_court_chaplain_bon_religion_kingdom -# } + #Dualism + text = { + trigger = { + highest_held_title_tier < tier_duchy + faith.religion = faith:manichaean_faith.religion + } + localization_key = councillor_court_chaplain_dualism_religion_county + } + + #Bon + text = { + trigger = { + highest_held_title_tier >= tier_kingdom + faith.religion = faith:bon_faith.religion + } + localization_key = councillor_court_chaplain_bon_religion_kingdom + } # Japanese Buddhism text = { @@ -1136,9 +1208,9 @@ GetActualBishopTitle = { } } OR = { - faith = faith:dhyana + faith = faith:mahayana_faith AND = { - faith = { has_doctrine = tenet_no_mind } + rite = { rite_has_tenet = tenet_no_mind } religion = religion:buddhism_religion } } @@ -1168,9 +1240,9 @@ GetActualBishopTitle = { } } OR = { - faith = faith:dhyana + faith = faith:mahayana_faith AND = { - faith = { has_doctrine = tenet_no_mind } + rite = { rite_has_tenet = tenet_no_mind } religion = religion:buddhism_religion } } @@ -1191,14 +1263,23 @@ GetActualBishopTitle = { localization_key = councillor_court_chaplain_buddhist_korean_empire } + # Viet Buddhism + text = { + trigger = { + culture = { has_cultural_pillar = language_vietnamese } + religion = religion:buddhism_religion + } + localization_key = councillor_court_chaplain_buddhist_viet + } + #Buddhism/Hinduism/Jainism text = { trigger = { highest_held_title_tier >= tier_empire OR = { - faith.religion = faith:osvicenist.religion - faith.religion = faith:vaishnavism.religion - faith.religion = faith:digambara.religion + faith.religion = faith:theravada_faith.religion + faith.religion = faith:vaishnava_faith.religion + faith.religion = faith:jain_faith.religion } } localization_key = councillor_court_chaplain_buddhism_religion_empire @@ -1207,9 +1288,9 @@ GetActualBishopTitle = { trigger = { highest_held_title_tier >= tier_kingdom OR = { - faith.religion = faith:osvicenist.religion - faith.religion = faith:vaishnavism.religion - faith.religion = faith:digambara.religion + faith.religion = faith:theravada_faith.religion + faith.religion = faith:vaishnava_faith.religion + faith.religion = faith:jain_faith.religion } } localization_key = councillor_court_chaplain_buddhism_religion_kingdom @@ -1218,9 +1299,10 @@ GetActualBishopTitle = { trigger = { highest_held_title_tier >= tier_duchy OR = { - faith.religion = faith:osvicenist.religion - faith.religion = faith:vaishnavism.religion - faith.religion = faith:digambara.religion + faith.religion = faith:theravada_faith.religion + faith.religion = faith:vaishnava_faith.religion + faith.religion = faith:jain_faith.religion + faith.religion = faith:bon_faith.religion } } localization_key = councillor_court_chaplain_buddhism_religion_duchy @@ -1229,9 +1311,10 @@ GetActualBishopTitle = { trigger = { highest_held_title_tier < tier_duchy OR = { - faith.religion = faith:osvicenist.religion - faith.religion = faith:vaishnavism.religion - faith.religion = faith:digambara.religion + faith.religion = faith:theravada_faith.religion + faith.religion = faith:vaishnava_faith.religion + faith.religion = faith:jain_faith.religion + faith.religion = faith:bon_faith.religion } } localization_key = councillor_court_chaplain_buddhism_religion_county @@ -1239,119 +1322,690 @@ GetActualBishopTitle = { #Shia text = { - trigger = { highest_held_title_tier >= tier_empire faith = faith:ismaili } + trigger = { highest_held_title_tier >= tier_empire rite = rite:ismaili } localization_key = councillor_court_chaplain_ismaili_empire } text = { - trigger = { highest_held_title_tier >= tier_kingdom faith = faith:ismaili } + trigger = { highest_held_title_tier >= tier_kingdom rite = rite:ismaili } localization_key = councillor_court_chaplain_ismaili_kingdom } text = { - trigger = { highest_held_title_tier < tier_duchy faith = faith:ismaili } + trigger = { highest_held_title_tier < tier_duchy rite = rite:ismaili } localization_key = councillor_court_chaplain_ismaili_county } #Islam text = { - trigger = { highest_held_title_tier >= tier_empire faith.religion = faith:aqlani.religion } + trigger = { highest_held_title_tier >= tier_empire faith.religion = faith:sunni.religion } localization_key = councillor_court_chaplain_islam_empire } text = { - trigger = { highest_held_title_tier >= tier_kingdom faith.religion = faith:aqlani.religion } + trigger = { highest_held_title_tier >= tier_kingdom faith.religion = faith:sunni.religion } localization_key = councillor_court_chaplain_islam_kingdom } text = { - trigger = { highest_held_title_tier >= tier_duchy faith.religion = faith:aqlani.religion } + trigger = { highest_held_title_tier >= tier_duchy faith.religion = faith:sunni.religion } localization_key = councillor_court_chaplain_islam_duchy } text = { - trigger = { highest_held_title_tier < tier_duchy faith.religion = faith:aqlani.religion } + trigger = { highest_held_title_tier < tier_duchy faith.religion = faith:sunni.religion } localization_key = councillor_court_chaplain_islam_county } #Yazidi text = { - trigger = { highest_held_title_tier >= tier_empire faith.religion = faith:yazidi.religion } + trigger = { highest_held_title_tier >= tier_empire faith.religion = faith:yazidi_faith.religion } localization_key = councillor_court_chaplain_yazidi_empire } text = { - trigger = { highest_held_title_tier >= tier_kingdom faith.religion = faith:yazidi.religion } + trigger = { highest_held_title_tier >= tier_kingdom faith.religion = faith:yazidi_faith.religion } localization_key = councillor_court_chaplain_yazidi_kingdom } text = { - trigger = { highest_held_title_tier >= tier_duchy faith.religion = faith:yazidi.religion } + trigger = { highest_held_title_tier >= tier_duchy faith.religion = faith:yazidi_faith.religion } localization_key = councillor_court_chaplain_yazidi_duchy } text = { - trigger = { highest_held_title_tier < tier_duchy faith.religion = faith:yazidi.religion } + trigger = { highest_held_title_tier < tier_duchy faith.religion = faith:yazidi_faith.religion } localization_key = councillor_court_chaplain_yazidi_county } + + # Cyprus: autocephalous Archbishopric. This must come before the holy-site Patriarch check. + text = { + trigger = { + is_female = yes + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } + has_title = title:d_et_cyprus + } + localization_key = councillor_court_chaplain_orthodox_clerical_region_archbishop_female + } + text = { + trigger = { + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } + has_title = title:d_et_cyprus + } + localization_key = councillor_court_chaplain_orthodox_clerical_region_archbishop + } + + # NEOW Kyiv/Nistrenia/Rus' Exarchate: checked before Orthodox holy-site Patriarch logic. + text = { + trigger = { + is_female = yes + faith.religion = religion:eastern_orthodox_religion + has_title = title:d_et_kyiv + title:d_et_kyiv = { NOT = { has_variable = neow_kyiv_autocephalous } } + } + localization_key = councillor_court_chaplain_orthodox_clerical_region_exarch_female + } + text = { + trigger = { + faith.religion = religion:eastern_orthodox_religion + has_title = title:d_et_kyiv + title:d_et_kyiv = { NOT = { has_variable = neow_kyiv_autocephalous } } + } + localization_key = councillor_court_chaplain_orthodox_clerical_region_exarch + } + + # Patriarch exception + text = { + trigger = { + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } + OR = { + primary_title ?= title:d_et_alexandria + primary_title ?= title:d_et_antioch + primary_title ?= title:d_et_aquileia + primary_title ?= title:d_et_jerusalem + cp:councillor_court_chaplain ?= { + OR = { + primary_title ?= title:d_et_alexandria + primary_title ?= title:d_et_antioch + primary_title ?= title:d_et_aquileia + primary_title ?= title:d_et_jerusalem + } + } + } + } + localization_key = councillor_court_chaplain_orthodox_clerical_region_holy_site + } + + text = { + trigger = { + is_female = yes + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + NOR = { faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + OR = { + primary_title ?= { + tier = tier_duchy + has_clerical_region = yes + any_county_in_clerical_region = { + any_county_province = { + barony = { + is_holy_site_of = root.faith + } + } + } + } + any_held_title = { + tier = tier_duchy + has_clerical_region = yes + any_county_in_clerical_region = { + any_county_province = { + barony = { + is_holy_site_of = root.faith + } + } + } + } + cp:councillor_court_chaplain ?= { + primary_title ?= { + tier = tier_duchy + has_clerical_region = yes + any_county_in_clerical_region = { + any_county_province = { + barony = { + is_holy_site_of = root.faith + } + } + } + } + } + } + } + localization_key = councillor_court_chaplain_orthodox_clerical_region_holy_site_female + } + + text = { + trigger = { + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + NOR = { faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + OR = { + primary_title ?= { + tier = tier_duchy + has_clerical_region = yes + any_county_in_clerical_region = { + any_county_province = { + barony = { + is_holy_site_of = root.faith + } + } + } + } + any_held_title = { + tier = tier_duchy + has_clerical_region = yes + any_county_in_clerical_region = { + any_county_province = { + barony = { + is_holy_site_of = root.faith + } + } + } + } + cp:councillor_court_chaplain ?= { + primary_title ?= { + tier = tier_duchy + has_clerical_region = yes + any_county_in_clerical_region = { + any_county_province = { + barony = { + is_holy_site_of = root.faith + } + } + } + } + } + } + } + localization_key = councillor_court_chaplain_orthodox_clerical_region_holy_site + } + #Orthodox text = { trigger = { - highest_held_title_tier >= tier_empire - NOT = { # Required formatting to include male/female check as well as vacancy + is_female = yes + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } + OR = { + primary_title ?= { + tier = tier_duchy + has_clerical_region = yes + any_county_in_clerical_region = { + any_county_province = { + barony = { + is_holy_site_of = root.faith + } + } + } + } + any_held_title = { + tier = tier_duchy + has_clerical_region = yes + any_county_in_clerical_region = { + any_county_province = { + barony = { + is_holy_site_of = root.faith + } + } + } + } cp:councillor_court_chaplain ?= { - is_female = yes + primary_title ?= { + tier = tier_duchy + has_clerical_region = yes + any_county_in_clerical_region = { + any_county_province = { + barony = { + is_holy_site_of = root.faith + } + } + } + } } } - faith.religion = faith:orthodox.religion } - localization_key = councillor_court_chaplain_orthodox_empire + localization_key = councillor_court_chaplain_orthodox_clerical_region_holy_site_female } text = { trigger = { - highest_held_title_tier >= tier_empire - NOT = { # Required formatting to include male/female check as well as vacancy + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } + OR = { + primary_title ?= { + tier = tier_duchy + has_clerical_region = yes + any_county_in_clerical_region = { + any_county_province = { + barony = { + is_holy_site_of = root.faith + } + } + } + } + any_held_title = { + tier = tier_duchy + has_clerical_region = yes + any_county_in_clerical_region = { + any_county_province = { + barony = { + is_holy_site_of = root.faith + } + } + } + } cp:councillor_court_chaplain ?= { - is_female = no + primary_title ?= { + tier = tier_duchy + has_clerical_region = yes + any_county_in_clerical_region = { + any_county_province = { + barony = { + is_holy_site_of = root.faith + } + } + } + } } } - faith.religion = faith:orthodox.religion } - localization_key = councillor_court_chaplain_orthodox_empire_female + localization_key = councillor_court_chaplain_orthodox_clerical_region_holy_site } text = { trigger = { - highest_held_title_tier >= tier_kingdom - NOT = { # Required formatting to include male/female check as well as vacancy + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } + OR = { + primary_title ?= { + tier = tier_duchy + has_clerical_region = yes + } + any_held_title = { + tier = tier_duchy + has_clerical_region = yes + } cp:councillor_court_chaplain ?= { - is_female = yes + primary_title ?= { + tier = tier_duchy + has_clerical_region = yes + } } } - faith.religion = faith:orthodox.religion } - localization_key = councillor_court_chaplain_orthodox_kingdom + localization_key = councillor_court_chaplain_orthodox_clerical_region } text = { trigger = { - highest_held_title_tier >= tier_kingdom - NOT = { # Required formatting to include male/female check as well as vacancy - cp:councillor_court_chaplain ?= { - is_female = no - } + is_female = yes + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } + has_council_position = councillor_court_chaplain + liege ?= { + highest_held_title_tier >= tier_duchy } - faith.religion = faith:orthodox.religion } - localization_key = councillor_court_chaplain_orthodox_kingdom_female + localization_key = councillor_court_chaplain_orthodox_duchy_female } text = { trigger = { - highest_held_title_tier >= tier_duchy - faith.religion = faith:orthodox.religion + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } + has_council_position = councillor_court_chaplain + liege ?= { + highest_held_title_tier >= tier_duchy + } } localization_key = councillor_court_chaplain_orthodox_duchy } text = { trigger = { + is_female = yes + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } + has_council_position = councillor_court_chaplain + } + localization_key = councillor_court_chaplain_orthodox_county_female + } + text = { + trigger = { + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } + has_council_position = councillor_court_chaplain + } + localization_key = councillor_court_chaplain_orthodox_county + } + text = { + trigger = { + is_female = yes + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } + highest_held_title_tier >= tier_duchy + } + localization_key = councillor_court_chaplain_orthodox_duchy_female + } + text = { + trigger = { + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } + highest_held_title_tier >= tier_duchy + } + localization_key = councillor_court_chaplain_orthodox_duchy + } + text = { + trigger = { + is_female = yes + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } highest_held_title_tier < tier_duchy - faith.religion = faith:orthodox.religion + } + localization_key = councillor_court_chaplain_orthodox_county_female + } + text = { + trigger = { + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } + highest_held_title_tier < tier_duchy + } + localization_key = councillor_court_chaplain_orthodox_county + } + text = { + trigger = { + is_female = yes + highest_held_title_tier >= tier_duchy + OR = { + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } + faith.religion = faith:manichaean_faith.religion + } + } + localization_key = councillor_court_chaplain_orthodox_duchy_female + } + text = { + trigger = { + highest_held_title_tier >= tier_empire + NOT = { # Required formatting to include male/female check as well as vacancy + cp:councillor_court_chaplain ?= { + is_female = yes + } + } + OR = { + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } + faith.religion = faith:manichaean_faith.religion + } + } + localization_key = councillor_court_chaplain_orthodox_duchy + } + text = { + trigger = { + highest_held_title_tier >= tier_empire + NOT = { # Required formatting to include male/female check as well as vacancy + cp:councillor_court_chaplain ?= { + is_female = no + } + } + OR = { + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } + faith.religion = faith:manichaean_faith.religion + } + } + localization_key = councillor_court_chaplain_orthodox_duchy + } + text = { + trigger = { + highest_held_title_tier >= tier_kingdom + NOT = { # Required formatting to include male/female check as well as vacancy + cp:councillor_court_chaplain ?= { + is_female = yes + } + } + OR = { + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } + faith.religion = faith:manichaean_faith.religion + } + } + localization_key = councillor_court_chaplain_orthodox_duchy + } + text = { + trigger = { + highest_held_title_tier >= tier_kingdom + NOT = { # Required formatting to include male/female check as well as vacancy + cp:councillor_court_chaplain ?= { + is_female = no + } + } + OR = { + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } + faith.religion = faith:manichaean_faith.religion + } + } + localization_key = councillor_court_chaplain_orthodox_duchy + } + text = { + trigger = { + highest_held_title_tier >= tier_duchy + OR = { + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } + faith.religion = faith:manichaean_faith.religion + } + } + localization_key = councillor_court_chaplain_orthodox_duchy + } + text = { + trigger = { + is_female = yes + highest_held_title_tier < tier_duchy + OR = { + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } + faith.religion = faith:manichaean_faith.religion + } + } + localization_key = councillor_court_chaplain_orthodox_county_female + } + text = { + trigger = { + highest_held_title_tier < tier_duchy + OR = { + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } + faith.religion = faith:manichaean_faith.religion + } } localization_key = councillor_court_chaplain_orthodox_county } #Christian + text = { + trigger = { + is_female = yes + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + any_held_title = { + tier = tier_duchy + has_clerical_region = yes + } + any_held_title = { + tier = tier_duchy + is_landless_type_title = no + } + } + localization_key = duke_theocracy_female_christianity_religion_archbishop_holder + } + text = { + trigger = { + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + any_held_title = { + tier = tier_duchy + has_clerical_region = yes + } + any_held_title = { + tier = tier_duchy + is_landless_type_title = no + } + } + localization_key = duke_theocracy_male_christianity_religion_archbishop_holder + } + text = { + trigger = { + is_female = yes + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + any_held_title = { + tier = tier_duchy + has_clerical_region = yes + } + any_held_title = { + tier = tier_county + is_landless_type_title = no + } + } + localization_key = count_theocracy_female_christianity_religion_archbishop_holder + } + text = { + trigger = { + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + any_held_title = { + tier = tier_duchy + has_clerical_region = yes + } + any_held_title = { + tier = tier_county + is_landless_type_title = no + } + } + localization_key = count_theocracy_male_christianity_religion_archbishop_holder + } + text = { + trigger = { + is_female = yes + OR = { faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + OR = { + primary_title ?= { + tier = tier_duchy + has_clerical_region = yes + } + any_held_title = { + tier = tier_duchy + has_clerical_region = yes + } + cp:councillor_court_chaplain ?= { + primary_title ?= { + tier = tier_duchy + has_clerical_region = yes + } + } + } + } + localization_key = councillor_court_chaplain_catholic_clerical_region_female + } + text = { + trigger = { + OR = { faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + OR = { + primary_title ?= { + tier = tier_duchy + has_clerical_region = yes + } + any_held_title = { + tier = tier_duchy + has_clerical_region = yes + } + cp:councillor_court_chaplain ?= { + primary_title ?= { + tier = tier_duchy + has_clerical_region = yes + } + } + } + } + localization_key = councillor_court_chaplain_catholic_clerical_region + } + text = { + trigger = { + is_female = yes + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + OR = { + primary_title ?= { + tier = tier_duchy + has_clerical_region = yes + } + any_held_title = { + tier = tier_duchy + has_clerical_region = yes + } + cp:councillor_court_chaplain ?= { + primary_title ?= { + tier = tier_duchy + has_clerical_region = yes + } + } + } + } + localization_key = councillor_court_chaplain_catholic_clerical_region_female + } + text = { + trigger = { + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + OR = { + primary_title ?= { + tier = tier_duchy + has_clerical_region = yes + } + any_held_title = { + tier = tier_duchy + has_clerical_region = yes + } + cp:councillor_court_chaplain ?= { + primary_title ?= { + tier = tier_duchy + has_clerical_region = yes + } + } + } + } + localization_key = councillor_court_chaplain_catholic_clerical_region + } + text = { + trigger = { + is_female = yes + OR = { faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + has_council_position = councillor_court_chaplain + liege ?= { + highest_held_title_tier >= tier_duchy + } + } + localization_key = councillor_court_chaplain_catholic_duchy_female + } + text = { + trigger = { + OR = { faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + has_council_position = councillor_court_chaplain + liege ?= { + highest_held_title_tier >= tier_duchy + } + } + localization_key = councillor_court_chaplain_catholic_duchy + } + text = { + trigger = { + OR = { faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + has_council_position = councillor_court_chaplain + } + localization_key = councillor_court_chaplain_catholic_county + } + text = { + trigger = { + is_female = yes + OR = { faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + highest_held_title_tier >= tier_duchy + } + localization_key = councillor_court_chaplain_catholic_duchy_female + } + text = { + trigger = { + OR = { faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + highest_held_title_tier >= tier_duchy + } + localization_key = councillor_court_chaplain_catholic_duchy + } + text = { + trigger = { + OR = { faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + highest_held_title_tier < tier_duchy + } + localization_key = councillor_court_chaplain_catholic_county + } + text = { + trigger = { + is_female = yes + highest_held_title_tier >= tier_duchy + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + } + localization_key = councillor_court_chaplain_christian_duchy_female + } text = { trigger = { highest_held_title_tier >= tier_empire @@ -1360,12 +2014,9 @@ GetActualBishopTitle = { is_female = yes } } - OR = { - faith.religion = faith:lutheran_faith.religion - faith.religion = faith:roman_catholic.religion - } + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } } - localization_key = councillor_court_chaplain_christian_empire + localization_key = councillor_court_chaplain_christian_duchy } text = { trigger = { @@ -1375,40 +2026,38 @@ GetActualBishopTitle = { is_female = no } } - OR = { - faith.religion = faith:lutheran_faith.religion - faith.religion = faith:roman_catholic.religion - } - } - localization_key = councillor_court_chaplain_christian_empire_female - } - text = { - trigger = { highest_held_title_tier >= tier_kingdom - OR = { - faith.religion = faith:lutheran_faith.religion - faith.religion = faith:roman_catholic.religion - } - } - localization_key = councillor_court_chaplain_christian_kingdom - } - text = { - trigger = { highest_held_title_tier >= tier_duchy - OR = { - faith.religion = faith:lutheran_faith.religion - faith.religion = faith:roman_catholic.religion - } + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } } localization_key = councillor_court_chaplain_christian_duchy } text = { - trigger = { highest_held_title_tier < tier_duchy - OR = { - faith.religion = faith:lutheran_faith.religion - faith.religion = faith:roman_catholic.religion - } + trigger = { highest_held_title_tier >= tier_kingdom OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } } + localization_key = councillor_court_chaplain_christian_duchy + } + text = { + trigger = { highest_held_title_tier >= tier_duchy OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } } + localization_key = councillor_court_chaplain_christian_duchy + } + text = { + trigger = { + is_female = yes + highest_held_title_tier < tier_duchy + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } } + localization_key = councillor_court_chaplain_christian_county_female + } + text = { + trigger = { highest_held_title_tier < tier_duchy OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } } localization_key = councillor_court_chaplain_christian_county } + + #Basque Paganism + text = { + trigger = { + religion = religion:basque_religion + } + localization_key = council_basque_priest + } # Shinto text = { @@ -1457,7 +2106,15 @@ GetActualBishopTitle = { } localization_key = councillor_court_chaplain_paganism_religion_county } + #Fallback + text = { + trigger = { + is_female = yes + highest_held_title_tier >= tier_empire + } + localization_key = councillor_court_chaplain_theocrat_empire_female + } text = { trigger = { highest_held_title_tier >= tier_empire @@ -1480,25 +2137,1614 @@ GetActualBishopTitle = { } localization_key = councillor_court_chaplain_theocrat_empire_female } + text = { + trigger = { + is_female = yes + highest_held_title_tier >= tier_kingdom + } + localization_key = councillor_court_chaplain_theocrat_kingdom_female + } text = { trigger = { highest_held_title_tier >= tier_kingdom } localization_key = councillor_court_chaplain_theocrat_kingdom } + text = { + trigger = { + is_female = yes + highest_held_title_tier >= tier_duchy + } + localization_key = councillor_court_chaplain_theocrat_duchy_female + } text = { trigger = { highest_held_title_tier >= tier_duchy } localization_key = councillor_court_chaplain_theocrat_duchy } + text = { + trigger = { + is_female = yes + highest_held_title_tier < tier_duchy + } + localization_key = councillor_court_chaplain_theocrat_county_female + } text = { trigger = { highest_held_title_tier < tier_duchy } localization_key = councillor_court_chaplain_theocrat_county } } +GetActualCountTheocracyTitle = { + type = character + + text = { + trigger = { + exists = clerical_elector_title + } + localization_key = count_theocracy_male_christianity_religion_cardinal + } + text = { + trigger = { + is_female = yes + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + NOR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } + any_held_title = { + tier = tier_duchy + has_clerical_region = yes + } + } + localization_key = count_theocracy_female_christianity_religion_archbishop_holder + } + text = { + trigger = { + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + NOR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } + any_held_title = { + tier = tier_duchy + has_clerical_region = yes + } + } + localization_key = count_theocracy_male_christianity_religion_archbishop_holder + } + text = { + trigger = { is_female = yes } + localization_key = count_theocracy_female_christianity_religion_default + } + text = { + localization_key = count_theocracy_male_christianity_religion_default + } +} + +GetActualDukeTheocracyTitle = { + type = character + + # 'Early Out' keys for the Eastern Christian sees that keep their own head titles rather than Patriarch. + text = { + trigger = { + has_title = title:d_coptic_papacy + is_female = yes + } + localization_key = coptic_religious_head_title_female + } + + text = { + trigger = { + has_title = title:d_coptic_papacy + } + localization_key = coptic_religious_head_title + } + + text = { + trigger = { + has_title = title:d_apostolic_church + } + localization_key = apostolic_religious_head_title + } + + text = { + trigger = { + exists = clerical_elector_title + } + localization_key = duke_theocracy_male_christianity_religion_cardinal + } + text = { + trigger = { + is_female = yes + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + NOR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } + any_held_title = { + tier = tier_duchy + has_clerical_region = yes + } + } + localization_key = duke_theocracy_female_christianity_religion_archbishop_holder + } + text = { + trigger = { + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + NOR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } + any_held_title = { + tier = tier_duchy + has_clerical_region = yes + } + } + localization_key = duke_theocracy_male_christianity_religion_archbishop_holder + } + text = { + trigger = { + is_female = yes + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + NOR = { faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + any_held_title = { + tier = tier_duchy + has_clerical_region = yes + any_county_in_clerical_region = { + any_county_province = { + barony = { + is_holy_site_of = root.faith + } + } + } + } + } + localization_key = councillor_court_chaplain_orthodox_clerical_region_holy_site_female + } + text = { + trigger = { + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + NOR = { faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + any_held_title = { + tier = tier_duchy + has_clerical_region = yes + any_county_in_clerical_region = { + any_county_province = { + barony = { + is_holy_site_of = root.faith + } + } + } + } + } + localization_key = councillor_court_chaplain_orthodox_clerical_region_holy_site + } + text = { + trigger = { + is_female = yes + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } + any_held_title = { + tier = tier_duchy + has_clerical_region = yes + any_county_in_clerical_region = { + any_county_province = { + barony = { + is_holy_site_of = root.faith + } + } + } + } + } + localization_key = councillor_court_chaplain_orthodox_clerical_region_holy_site_female + } + text = { + trigger = { + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } + any_held_title = { + tier = tier_duchy + has_clerical_region = yes + any_county_in_clerical_region = { + any_county_province = { + barony = { + is_holy_site_of = root.faith + } + } + } + } + } + localization_key = councillor_court_chaplain_orthodox_clerical_region_holy_site + } + text = { + trigger = { + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } + any_held_title = { + tier = tier_duchy + has_clerical_region = yes + } + } + localization_key = councillor_court_chaplain_orthodox_clerical_region + } + text = { + trigger = { + is_female = yes + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + any_held_title = { + tier = tier_duchy + has_clerical_region = yes + } + } + localization_key = councillor_court_chaplain_catholic_clerical_region_female + } + text = { + trigger = { + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + any_held_title = { + tier = tier_duchy + has_clerical_region = yes + } + } + localization_key = councillor_court_chaplain_catholic_clerical_region + } + text = { + trigger = { is_female = yes } + localization_key = duke_theocracy_female_christianity_religion_default + } + text = { + localization_key = duke_theocracy_male_christianity_religion_default + } +} + # GetActualBishopTitle should be updated synchronously with this GetActualBishopTitlePossessive = { type = character - parent = GetActualBishopTitle - suffix = _possessive + + text = { + trigger = { + pam_is_antipope_trigger = yes + is_female = yes + } + localization_key = anti_religious_head_name_female_possessive + } + + text = { + trigger = { + pam_is_antipope_trigger = yes + } + localization_key = anti_religious_head_name_possessive + } + + text = { + trigger = { + pam_is_ecumenical_patriarch_trigger = yes + is_female = yes + } + localization_key = ecumenical_matriarch_possessive + } + + text = { + trigger = { + pam_is_ecumenical_patriarch_trigger = yes + } + localization_key = ecumenical_patriarch_possessive + } + + text = { + trigger = { + exists = faith.religious_head + this = faith.religious_head + is_female = yes + } + localization_key = religious_head_name_female_possessive + } + + text = { + trigger = { + exists = faith.religious_head + this = faith.religious_head + } + localization_key = religious_head_name_possessive + } + + # Religion-By-Religion Titles for Bishops based on Liege's Tier. + # Zunism + text = { + trigger = { + highest_held_title_tier >= tier_kingdom + faith.religion = faith:zun_pagan.religion + NOT = { # Required formatting to include male/female check as well as vacancy + cp:councillor_court_chaplain ?= { + is_female = yes + } + } + } + localization_key = councillor_court_chaplain_zunism_religion_kingdom_possessive + } + text = { + trigger = { + highest_held_title_tier < tier_kingdom + faith.religion = faith:zun_pagan.religion + NOT = { # Required formatting to include male/female check as well as vacancy + cp:councillor_court_chaplain ?= { + is_female = yes + } + } + } + localization_key = councillor_court_chaplain_zunism_religion_duchy_possessive + } + + # Zoroastrianism + text = { + trigger = { + highest_held_title_tier >= tier_kingdom + faith.religion = faith:mazdayasna.religion + NOT = { # Required formatting to include male/female check as well as vacancy + cp:councillor_court_chaplain ?= { + is_female = yes + } + } + } + localization_key = councillor_court_chaplain_zoroastrianism_religion_kingdom_possessive + } + text = { + trigger = { + highest_held_title_tier >= tier_kingdom + faith.religion = faith:mazdayasna.religion + NOT = { # Required formatting to include male/female check as well as vacancy + cp:councillor_court_chaplain ?= { + is_female = no + } + } + } + localization_key = councillor_court_chaplain_zoroastrianism_religion_kingdom_female_possessive + } + text = { + trigger = { + highest_held_title_tier >= tier_duchy + faith.religion = faith:mazdayasna.religion + NOT = { # Required formatting to include male/female check as well as vacancy + cp:councillor_court_chaplain ?= { + is_female = yes + } + } + } + localization_key = councillor_court_chaplain_zoroastrianism_religion_duchy_possessive + } + text = { + trigger = { + highest_held_title_tier >= tier_duchy + faith.religion = faith:mazdayasna.religion + NOT = { # Required formatting to include male/female check as well as vacancy + cp:councillor_court_chaplain ?= { + is_female = no + } + } + } + localization_key = councillor_court_chaplain_zoroastrianism_religion_duchy_female_possessive + } + text = { + trigger = { + highest_held_title_tier < tier_duchy + faith.religion = faith:mazdayasna.religion + } + localization_key = councillor_court_chaplain_zoroastrianism_religion_county_possessive + } + # African Roog + text = { + trigger = { + faith.religion = faith:west_african_roog_pagan.religion + } + localization_key = councillor_court_chaplain_west_african_roog_religion_duchy_possessive + } + # African Bori + text = { + trigger = { + faith.religion = faith:west_african_bori_pagan.religion + NOT = { # Required formatting to include male/female check as well as vacancy + cp:councillor_court_chaplain ?= { + is_female = yes + } + } + } + localization_key = councillor_court_chaplain_west_african_bori_religion_duchy_possessive + } + text = { + trigger = { + faith.religion = faith:west_african_bori_pagan.religion + NOT = { # Required formatting to include male/female check as well as vacancy + cp:councillor_court_chaplain ?= { + is_female = no + } + } + } + localization_key = councillor_court_chaplain_west_african_bori_religion_duchy_female_possessive + } + # African + text = { + trigger = { + faith.religion = faith:west_african_pagan.religion + } + localization_key = councillor_court_chaplain_west_african_religion_duchy_possessive + } + + # Tengrism + text = { + trigger = { + highest_held_title_tier >= tier_duchy + faith.religion = faith:tengri_pagan.religion + } + localization_key = councillor_court_chaplain_tengrism_religion_kingdom_possessive + } + text = { + trigger = { + highest_held_title_tier < tier_duchy + faith.religion = faith:tengri_pagan.religion + } + localization_key = councillor_court_chaplain_tengrism_religion_duchy_possessive + } + + #Taoism + text = { + trigger = { + highest_held_title_tier >= tier_kingdom + faith.religion = religion:taoism_religion + } + localization_key = councillor_court_chaplain_taoism_religion_kingdom_possessive + } + text = { + trigger = { + highest_held_title_tier >= tier_duchy + faith.religion = religion:taoism_religion + } + localization_key = councillor_court_chaplain_taoism_religion_duchy_possessive + } + text = { + trigger = { + highest_held_title_tier < tier_duchy + faith.religion = religion:taoism_religion + NOT = { # Required formatting to include male/female check as well as vacancy + cp:councillor_court_chaplain ?= { + is_female = yes + } + } + } + localization_key = councillor_court_chaplain_taoism_religion_county_possessive + } + text = { + trigger = { + highest_held_title_tier < tier_duchy + faith.religion = religion:taoism_religion + NOT = { # Required formatting to include male/female check as well as vacancy + cp:councillor_court_chaplain ?= { + is_female = no + } + } + } + localization_key = councillor_court_chaplain_taoism_religion_county_female_possessive + } + + #Finno-Ugric + text = { + trigger = { + faith.religion = faith:finnish_pagan.religion + } + localization_key = councillor_court_chaplain_finno_ugric_religion_duchy_possessive + } + + #Slavic + text = { + trigger = { + highest_held_title_tier >= tier_duchy + faith.religion = faith:slavic_pagan.religion + NOT = { # Required formatting to include male/female check as well as vacancy + cp:councillor_court_chaplain ?= { + is_female = yes + } + } + } + localization_key = councillor_court_chaplain_slavic_religion_kingdom_possessive + } + text = { + trigger = { + highest_held_title_tier >= tier_duchy + faith.religion = faith:slavic_pagan.religion + NOT = { # Required formatting to include male/female check as well as vacancy + cp:councillor_court_chaplain ?= { + is_female = no + } + } + } + localization_key = councillor_court_chaplain_slavic_religion_kingdom_female_possessive + } + text = { + trigger = { + highest_held_title_tier < tier_duchy + faith.religion = faith:slavic_pagan.religion + NOT = { # Required formatting to include male/female check as well as vacancy + cp:councillor_court_chaplain ?= { + is_female = yes + } + } + } + localization_key = councillor_court_chaplain_slavic_religion_duchy_possessive + } + text = { + trigger = { + highest_held_title_tier < tier_duchy + faith.religion = faith:slavic_pagan.religion + NOT = { # Required formatting to include male/female check as well as vacancy + cp:councillor_court_chaplain ?= { + is_female = no + } + } + } + localization_key = councillor_court_chaplain_slavic_religion_duchy_female_possessive + } + + #Baltic + text = { + trigger = { + highest_held_title_tier >= tier_duchy + faith.religion = faith:baltic_pagan.religion + NOT = { # Required formatting to include male/female check as well as vacancy + cp:councillor_court_chaplain ?= { + is_female = yes + } + } + } + localization_key = councillor_court_chaplain_baltic_religion_duchy_possessive + } + text = { + trigger = { + highest_held_title_tier >= tier_duchy + faith.religion = faith:baltic_pagan.religion + NOT = { # Required formatting to include male/female check as well as vacancy + cp:councillor_court_chaplain ?= { + is_female = no + } + } + } + localization_key = councillor_court_chaplain_baltic_religion_duchy_female_possessive + } + text = { + trigger = { + highest_held_title_tier < tier_duchy + NOT = { # Required formatting to include male/female check as well as vacancy + cp:councillor_court_chaplain ?= { + is_female = yes + } + } + OR = { + faith.religion = faith:baltic_pagan.religion + faith.religion = faith:slavic_pagan.religion + faith.religion = faith:finnish_pagan.religion + faith.religion = faith:zun_pagan.religion + } + } + localization_key = councillor_court_chaplain_baltic_religion_county_possessive + } + text = { + trigger = { + highest_held_title_tier < tier_duchy + NOT = { # Required formatting to include male/female check as well as vacancy + cp:councillor_court_chaplain ?= { + is_female = no + } + } + OR = { + faith.religion = faith:baltic_pagan.religion + faith.religion = faith:slavic_pagan.religion + faith.religion = faith:finnish_pagan.religion + faith.religion = faith:zun_pagan.religion + } + } + localization_key = councillor_court_chaplain_baltic_religion_county_female_possessive + } + + #Magyarism + text = { + trigger = { + faith.religion = faith:magyar_pagan.religion + } + localization_key = councillor_court_chaplain_magyarism_religion_county_possessive + } + + #Judaism + text = { + trigger = { + highest_held_title_tier >= tier_empire + faith.religion = faith:rabbinic_faith.religion + } + localization_key = councillor_court_chaplain_judaism_religion_empire_possessive + } + text = { + trigger = { + highest_held_title_tier >= tier_kingdom + faith.religion = faith:rabbinic_faith.religion + } + localization_key = councillor_court_chaplain_judaism_religion_kingdom_possessive + } + text = { + trigger = { + highest_held_title_tier >= tier_duchy + faith.religion = faith:rabbinic_faith.religion + } + localization_key = councillor_court_chaplain_judaism_religion_duchy_possessive + } + text = { + trigger = { + highest_held_title_tier < tier_duchy + faith.religion = faith:rabbinic_faith.religion + } + localization_key = councillor_court_chaplain_judaism_religion_county_possessive + } + + #Hellenic + text = { + trigger = { + highest_held_title_tier >= tier_kingdom + faith.religion = faith:hellenic_pagan.religion + NOT = { # Required formatting to include male/female check as well as vacancy + cp:councillor_court_chaplain ?= { + is_female = yes + } + } + } + localization_key = councillor_court_chaplain_hellenism_religion_kingdom_possessive + } + text = { + trigger = { + highest_held_title_tier >= tier_kingdom + faith.religion = faith:hellenic_pagan.religion + NOT = { # Required formatting to include male/female check as well as vacancy + cp:councillor_court_chaplain ?= { + is_female = no + } + } + } + localization_key = councillor_court_chaplain_hellenism_religion_kingdom_female_possessive + } + text = { + trigger = { + highest_held_title_tier >= tier_duchy + faith.religion = faith:hellenic_pagan.religion + } + localization_key = councillor_court_chaplain_hellenism_religion_duchy_possessive + } + text = { + trigger = { + highest_held_title_tier < tier_duchy + faith.religion = faith:hellenic_pagan.religion + NOT = { # Required formatting to include male/female check as well as vacancy + cp:councillor_court_chaplain ?= { + is_female = yes + } + } + } + localization_key = councillor_court_chaplain_hellenism_religion_county_possessive + } + text = { + trigger = { + highest_held_title_tier < tier_duchy + faith.religion = faith:hellenic_pagan.religion + NOT = { # Required formatting to include male/female check as well as vacancy + cp:councillor_court_chaplain ?= { + is_female = no + } + } + } + localization_key = councillor_court_chaplain_hellenism_religion_county_female_possessive + } + + #Norse + text = { + trigger = { + highest_held_title_tier >= tier_kingdom + faith.religion = faith:norse_pagan.religion + } + localization_key = councillor_court_chaplain_germanic_religion_kingdom_possessive + } + text = { + trigger = { + highest_held_title_tier >= tier_duchy + faith.religion = faith:norse_pagan.religion + } + localization_key = councillor_court_chaplain_germanic_religion_duchy_possessive + } + text = { + trigger = { + highest_held_title_tier < tier_duchy + faith.religion = faith:norse_pagan.religion + NOT = { # Required formatting to include male/female check as well as vacancy + cp:councillor_court_chaplain ?= { + is_female = yes + } + } + } + localization_key = councillor_court_chaplain_germanic_religion_county_possessive + } + text = { + trigger = { + highest_held_title_tier < tier_duchy + faith.religion = faith:norse_pagan.religion + NOT = { # Required formatting to include male/female check as well as vacancy + cp:councillor_court_chaplain ?= { + is_female = no + } + } + } + localization_key = councillor_court_chaplain_germanic_religion_county_female_possessive + } + + #Dualism + text = { + trigger = { + highest_held_title_tier < tier_duchy + faith.religion = faith:manichaean_faith.religion + } + localization_key = councillor_court_chaplain_dualism_religion_county_possessive + } + + #Bon + text = { + trigger = { + highest_held_title_tier >= tier_kingdom + faith.religion = faith:bon_faith.religion + } + localization_key = councillor_court_chaplain_bon_religion_kingdom_possessive + } + + #Buddhism/Hinduism/Jainism + text = { + trigger = { + highest_held_title_tier >= tier_empire + OR = { + faith.religion = faith:theravada_faith.religion + faith.religion = faith:vaishnava_faith.religion + faith.religion = faith:jain_faith.religion + } + } + localization_key = councillor_court_chaplain_buddhism_religion_empire_possessive + } + text = { + trigger = { + highest_held_title_tier >= tier_kingdom + OR = { + faith.religion = faith:theravada_faith.religion + faith.religion = faith:vaishnava_faith.religion + faith.religion = faith:jain_faith.religion + } + } + localization_key = councillor_court_chaplain_buddhism_religion_kingdom_possessive + } + text = { + trigger = { + highest_held_title_tier >= tier_duchy + OR = { + faith.religion = faith:theravada_faith.religion + faith.religion = faith:vaishnava_faith.religion + faith.religion = faith:jain_faith.religion + faith.religion = faith:bon_faith.religion + } + } + localization_key = councillor_court_chaplain_buddhism_religion_duchy_possessive + } + text = { + trigger = { + highest_held_title_tier < tier_duchy + OR = { + faith.religion = faith:theravada_faith.religion + faith.religion = faith:vaishnava_faith.religion + faith.religion = faith:jain_faith.religion + faith.religion = faith:bon_faith.religion + } + } + localization_key = councillor_court_chaplain_buddhism_religion_county_possessive + } + + #Shia + text = { + trigger = { highest_held_title_tier >= tier_empire rite = rite:ismaili } + localization_key = councillor_court_chaplain_ismaili_empire_possessive + } + text = { + trigger = { highest_held_title_tier >= tier_kingdom rite = rite:ismaili } + localization_key = councillor_court_chaplain_ismaili_kingdom_possessive + } + text = { + trigger = { highest_held_title_tier < tier_duchy rite = rite:ismaili } + localization_key = councillor_court_chaplain_ismaili_county_possessive + } + + #Islam + text = { + trigger = { highest_held_title_tier >= tier_empire faith.religion = faith:sunni.religion } + localization_key = councillor_court_chaplain_islam_empire_possessive + } + text = { + trigger = { highest_held_title_tier >= tier_kingdom faith.religion = faith:sunni.religion } + localization_key = councillor_court_chaplain_islam_kingdom_possessive + } + text = { + trigger = { highest_held_title_tier >= tier_duchy faith.religion = faith:sunni.religion } + localization_key = councillor_court_chaplain_islam_duchy_possessive + } + text = { + trigger = { highest_held_title_tier < tier_duchy faith.religion = faith:sunni.religion } + localization_key = councillor_court_chaplain_islam_county_possessive + } + + #Yazidi + text = { + trigger = { highest_held_title_tier >= tier_empire faith.religion = faith:yazidi_faith.religion } + localization_key = councillor_court_chaplain_yazidi_empire_possessive + } + text = { + trigger = { highest_held_title_tier >= tier_kingdom faith.religion = faith:yazidi_faith.religion } + localization_key = councillor_court_chaplain_yazidi_kingdom_possessive + } + text = { + trigger = { highest_held_title_tier >= tier_duchy faith.religion = faith:yazidi_faith.religion } + localization_key = councillor_court_chaplain_yazidi_duchy_possessive + } + text = { + trigger = { highest_held_title_tier < tier_duchy faith.religion = faith:yazidi_faith.religion } + localization_key = councillor_court_chaplain_yazidi_county_possessive + } + + + # Cyprus: autocephalous Archbishopric. Possessive form must use the same priority as GetActualBishopTitle. + text = { + trigger = { + is_female = yes + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } + has_title = title:d_et_cyprus + } + localization_key = councillor_court_chaplain_orthodox_clerical_region_archbishop_female_possessive + } + text = { + trigger = { + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } + has_title = title:d_et_cyprus + } + localization_key = councillor_court_chaplain_orthodox_clerical_region_archbishop_possessive + } + + # NEOW Kyiv/Nistrenia/Rus' Exarchate possessive. + text = { + trigger = { + is_female = yes + faith.religion = religion:eastern_orthodox_religion + has_title = title:d_et_kyiv + title:d_et_kyiv = { NOT = { has_variable = neow_kyiv_autocephalous } } + } + localization_key = councillor_court_chaplain_orthodox_clerical_region_exarch_female_possessive + } + text = { + trigger = { + faith.religion = religion:eastern_orthodox_religion + has_title = title:d_et_kyiv + title:d_et_kyiv = { NOT = { has_variable = neow_kyiv_autocephalous } } + } + localization_key = councillor_court_chaplain_orthodox_clerical_region_exarch_possessive + } + + text = { + trigger = { + is_female = yes + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + NOR = { faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + OR = { + primary_title ?= { + tier = tier_duchy + has_clerical_region = yes + any_county_in_clerical_region = { + any_county_province = { + barony = { + is_holy_site_of = root.faith + } + } + } + } + any_held_title = { + tier = tier_duchy + has_clerical_region = yes + any_county_in_clerical_region = { + any_county_province = { + barony = { + is_holy_site_of = root.faith + } + } + } + } + cp:councillor_court_chaplain ?= { + primary_title ?= { + tier = tier_duchy + has_clerical_region = yes + any_county_in_clerical_region = { + any_county_province = { + barony = { + is_holy_site_of = root.faith + } + } + } + } + } + } + } + localization_key = councillor_court_chaplain_orthodox_clerical_region_holy_site_female_possessive + } + text = { + trigger = { + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + NOR = { faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + OR = { + primary_title ?= { + tier = tier_duchy + has_clerical_region = yes + any_county_in_clerical_region = { + any_county_province = { + barony = { + is_holy_site_of = root.faith + } + } + } + } + any_held_title = { + tier = tier_duchy + has_clerical_region = yes + any_county_in_clerical_region = { + any_county_province = { + barony = { + is_holy_site_of = root.faith + } + } + } + } + cp:councillor_court_chaplain ?= { + primary_title ?= { + tier = tier_duchy + has_clerical_region = yes + any_county_in_clerical_region = { + any_county_province = { + barony = { + is_holy_site_of = root.faith + } + } + } + } + } + } + } + localization_key = councillor_court_chaplain_orthodox_clerical_region_holy_site_possessive + } + + #Orthodox + text = { + trigger = { + is_female = yes + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } + OR = { + primary_title ?= { + tier = tier_duchy + has_clerical_region = yes + any_county_in_clerical_region = { + any_county_province = { + barony = { + is_holy_site_of = root.faith + } + } + } + } + any_held_title = { + tier = tier_duchy + has_clerical_region = yes + any_county_in_clerical_region = { + any_county_province = { + barony = { + is_holy_site_of = root.faith + } + } + } + } + cp:councillor_court_chaplain ?= { + primary_title ?= { + tier = tier_duchy + has_clerical_region = yes + any_county_in_clerical_region = { + any_county_province = { + barony = { + is_holy_site_of = root.faith + } + } + } + } + } + } + } + localization_key = councillor_court_chaplain_orthodox_clerical_region_holy_site_female_possessive + } + text = { + trigger = { + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } + OR = { + primary_title ?= { + tier = tier_duchy + has_clerical_region = yes + any_county_in_clerical_region = { + any_county_province = { + barony = { + is_holy_site_of = root.faith + } + } + } + } + any_held_title = { + tier = tier_duchy + has_clerical_region = yes + any_county_in_clerical_region = { + any_county_province = { + barony = { + is_holy_site_of = root.faith + } + } + } + } + cp:councillor_court_chaplain ?= { + primary_title ?= { + tier = tier_duchy + has_clerical_region = yes + any_county_in_clerical_region = { + any_county_province = { + barony = { + is_holy_site_of = root.faith + } + } + } + } + } + } + } + localization_key = councillor_court_chaplain_orthodox_clerical_region_holy_site_possessive + } + text = { + trigger = { + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } + OR = { + primary_title ?= { + tier = tier_duchy + has_clerical_region = yes + } + any_held_title = { + tier = tier_duchy + has_clerical_region = yes + } + cp:councillor_court_chaplain ?= { + primary_title ?= { + tier = tier_duchy + has_clerical_region = yes + } + } + } + } + localization_key = councillor_court_chaplain_orthodox_clerical_region_possessive + } + text = { + trigger = { + is_female = yes + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } + has_council_position = councillor_court_chaplain + liege ?= { + highest_held_title_tier >= tier_duchy + } + } + localization_key = councillor_court_chaplain_orthodox_duchy_female_possessive + } + text = { + trigger = { + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } + has_council_position = councillor_court_chaplain + liege ?= { + highest_held_title_tier >= tier_duchy + } + } + localization_key = councillor_court_chaplain_orthodox_duchy_possessive + } + text = { + trigger = { + is_female = yes + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } + has_council_position = councillor_court_chaplain + } + localization_key = councillor_court_chaplain_orthodox_county_female_possessive + } + text = { + trigger = { + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } + has_council_position = councillor_court_chaplain + } + localization_key = councillor_court_chaplain_orthodox_county_possessive + } + text = { + trigger = { + is_female = yes + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } + highest_held_title_tier >= tier_duchy + } + localization_key = councillor_court_chaplain_orthodox_duchy_female_possessive + } + text = { + trigger = { + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } + highest_held_title_tier >= tier_duchy + } + localization_key = councillor_court_chaplain_orthodox_duchy_possessive + } + text = { + trigger = { + is_female = yes + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } + highest_held_title_tier < tier_duchy + } + localization_key = councillor_court_chaplain_orthodox_county_female_possessive + } + text = { + trigger = { + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } + highest_held_title_tier < tier_duchy + } + localization_key = councillor_court_chaplain_orthodox_county_possessive + } + text = { + trigger = { + is_female = yes + highest_held_title_tier >= tier_duchy + OR = { + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } + faith.religion = faith:manichaean_faith.religion + } + } + localization_key = councillor_court_chaplain_orthodox_duchy_female_possessive + } + text = { + trigger = { + highest_held_title_tier >= tier_empire + NOT = { # Required formatting to include male/female check as well as vacancy + cp:councillor_court_chaplain ?= { + is_female = yes + } + } + OR = { + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } + faith.religion = faith:manichaean_faith.religion + } + } + localization_key = councillor_court_chaplain_orthodox_duchy_possessive + } + text = { + trigger = { + highest_held_title_tier >= tier_empire + NOT = { # Required formatting to include male/female check as well as vacancy + cp:councillor_court_chaplain ?= { + is_female = no + } + } + OR = { + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } + faith.religion = faith:manichaean_faith.religion + } + } + localization_key = councillor_court_chaplain_orthodox_duchy_possessive + } + text = { + trigger = { + highest_held_title_tier >= tier_kingdom + NOT = { # Required formatting to include male/female check as well as vacancy + cp:councillor_court_chaplain ?= { + is_female = yes + } + } + OR = { + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } + faith.religion = faith:manichaean_faith.religion + } + } + localization_key = councillor_court_chaplain_orthodox_duchy_possessive + } + text = { + trigger = { + highest_held_title_tier >= tier_kingdom + NOT = { # Required formatting to include male/female check as well as vacancy + cp:councillor_court_chaplain ?= { + is_female = no + } + } + OR = { + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } + faith.religion = faith:manichaean_faith.religion + } + } + localization_key = councillor_court_chaplain_orthodox_duchy_possessive + } + text = { + trigger = { + highest_held_title_tier >= tier_duchy + OR = { + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } + faith.religion = faith:manichaean_faith.religion + } + } + localization_key = councillor_court_chaplain_orthodox_duchy_possessive + } + text = { + trigger = { + is_female = yes + highest_held_title_tier < tier_duchy + OR = { + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } + faith.religion = faith:manichaean_faith.religion + } + } + localization_key = councillor_court_chaplain_orthodox_county_female_possessive + } + text = { + trigger = { + highest_held_title_tier < tier_duchy + OR = { + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion } + faith.religion = faith:manichaean_faith.religion + } + } + localization_key = councillor_court_chaplain_orthodox_county_possessive + } + + #Christian + text = { + trigger = { + is_female = yes + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + any_held_title = { + tier = tier_duchy + has_clerical_region = yes + } + any_held_title = { + tier = tier_duchy + is_landless_type_title = no + } + } + localization_key = duke_theocracy_female_christianity_religion_archbishop_holder_possessive + } + text = { + trigger = { + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + any_held_title = { + tier = tier_duchy + has_clerical_region = yes + } + any_held_title = { + tier = tier_duchy + is_landless_type_title = no + } + } + localization_key = duke_theocracy_male_christianity_religion_archbishop_holder_possessive + } + text = { + trigger = { + is_female = yes + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + any_held_title = { + tier = tier_duchy + has_clerical_region = yes + } + any_held_title = { + tier = tier_county + is_landless_type_title = no + } + } + localization_key = count_theocracy_female_christianity_religion_archbishop_holder_possessive + } + text = { + trigger = { + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + any_held_title = { + tier = tier_duchy + has_clerical_region = yes + } + any_held_title = { + tier = tier_county + is_landless_type_title = no + } + } + localization_key = count_theocracy_male_christianity_religion_archbishop_holder_possessive + } + text = { + trigger = { + is_female = yes + OR = { faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + OR = { + primary_title ?= { + tier = tier_duchy + has_clerical_region = yes + } + any_held_title = { + tier = tier_duchy + has_clerical_region = yes + } + cp:councillor_court_chaplain ?= { + primary_title ?= { + tier = tier_duchy + has_clerical_region = yes + } + } + } + } + localization_key = councillor_court_chaplain_catholic_clerical_region_female_possessive + } + text = { + trigger = { + OR = { faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + OR = { + primary_title ?= { + tier = tier_duchy + has_clerical_region = yes + } + any_held_title = { + tier = tier_duchy + has_clerical_region = yes + } + cp:councillor_court_chaplain ?= { + primary_title ?= { + tier = tier_duchy + has_clerical_region = yes + } + } + } + } + localization_key = councillor_court_chaplain_catholic_clerical_region_possessive + } + text = { + trigger = { + is_female = yes + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + OR = { + primary_title ?= { + tier = tier_duchy + has_clerical_region = yes + } + any_held_title = { + tier = tier_duchy + has_clerical_region = yes + } + cp:councillor_court_chaplain ?= { + primary_title ?= { + tier = tier_duchy + has_clerical_region = yes + } + } + } + } + localization_key = councillor_court_chaplain_catholic_clerical_region_female_possessive + } + text = { + trigger = { + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + OR = { + primary_title ?= { + tier = tier_duchy + has_clerical_region = yes + } + any_held_title = { + tier = tier_duchy + has_clerical_region = yes + } + cp:councillor_court_chaplain ?= { + primary_title ?= { + tier = tier_duchy + has_clerical_region = yes + } + } + } + } + localization_key = councillor_court_chaplain_catholic_clerical_region_possessive + } + text = { + trigger = { + is_female = yes + OR = { faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + has_council_position = councillor_court_chaplain + liege ?= { + highest_held_title_tier >= tier_duchy + } + } + localization_key = councillor_court_chaplain_catholic_duchy_female_possessive + } + text = { + trigger = { + OR = { faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + has_council_position = councillor_court_chaplain + liege ?= { + highest_held_title_tier >= tier_duchy + } + } + localization_key = councillor_court_chaplain_catholic_duchy_possessive + } + text = { + trigger = { + OR = { faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + has_council_position = councillor_court_chaplain + } + localization_key = councillor_court_chaplain_catholic_county_possessive + } + text = { + trigger = { + is_female = yes + OR = { faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + highest_held_title_tier >= tier_duchy + } + localization_key = councillor_court_chaplain_catholic_duchy_female_possessive + } + text = { + trigger = { + OR = { faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + highest_held_title_tier >= tier_duchy + } + localization_key = councillor_court_chaplain_catholic_duchy_possessive + } + text = { + trigger = { + OR = { faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + highest_held_title_tier < tier_duchy + } + localization_key = councillor_court_chaplain_catholic_county_possessive + } + text = { + trigger = { + is_female = yes + highest_held_title_tier >= tier_duchy + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + } + localization_key = councillor_court_chaplain_christian_duchy_female_possessive + } + text = { + trigger = { + highest_held_title_tier >= tier_empire + NOT = { # Required formatting to include male/female check as well as vacancy + cp:councillor_court_chaplain ?= { + is_female = yes + } + } + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + } + localization_key = councillor_court_chaplain_christian_duchy_possessive + } + text = { + trigger = { + highest_held_title_tier >= tier_empire + NOT = { # Required formatting to include male/female check as well as vacancy + cp:councillor_court_chaplain ?= { + is_female = no + } + } + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + } + localization_key = councillor_court_chaplain_christian_duchy_possessive + } + text = { + trigger = { highest_held_title_tier >= tier_kingdom OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } } + localization_key = councillor_court_chaplain_christian_duchy_possessive + } + text = { + trigger = { highest_held_title_tier >= tier_duchy OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } } + localization_key = councillor_court_chaplain_christian_duchy_possessive + } + text = { + trigger = { + is_female = yes + highest_held_title_tier < tier_duchy + OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } + } + localization_key = councillor_court_chaplain_christian_county_female_possessive + } + text = { + trigger = { highest_held_title_tier < tier_duchy OR = { faith.religion = religion:eastern_orthodox_religion faith.religion = religion:oriental_orthodox_religion faith.religion = religion:catholic_religion faith.religion = religion:protestant_religion } } + localization_key = councillor_court_chaplain_christian_county_possessive + } + # Shinto + text = { + trigger = { + religion = religion:shintoism_religion + } + localization_key = councillor_court_chaplain_shintoism_religion_possessive + } + + #Paganism + text = { + trigger = { + faith = { has_doctrine = pagan_hostility_doctrine } + highest_held_title_tier >= tier_kingdom + NOT = { # Required formatting to include male/female check as well as vacancy + cp:councillor_court_chaplain ?= { + is_female = yes + } + } + } + localization_key = councillor_court_chaplain_paganism_religion_kingdom_possessive + } + text = { + trigger = { + faith = { has_doctrine = pagan_hostility_doctrine } + highest_held_title_tier >= tier_kingdom + NOT = { # Required formatting to include male/female check as well as vacancy + cp:councillor_court_chaplain ?= { + is_female = no + } + } + } + localization_key = councillor_court_chaplain_paganism_religion_kingdom_female_possessive + } + text = { + trigger = { + faith = { has_doctrine = pagan_hostility_doctrine } + highest_held_title_tier >= tier_duchy + } + localization_key = councillor_court_chaplain_paganism_religion_duchy_possessive + } + text = { + trigger = { + faith = { has_doctrine = pagan_hostility_doctrine } + highest_held_title_tier < tier_duchy + } + localization_key = councillor_court_chaplain_paganism_religion_county_possessive + } + + #Fallback + text = { + trigger = { + is_female = yes + highest_held_title_tier >= tier_empire + } + localization_key = councillor_court_chaplain_theocrat_empire_female_possessive + } + text = { + trigger = { + highest_held_title_tier >= tier_empire + NOT = { # Required formatting to include male/female check as well as vacancy + cp:councillor_court_chaplain ?= { + is_female = yes + } + } + } + localization_key = councillor_court_chaplain_theocrat_empire_possessive + } + text = { + trigger = { + highest_held_title_tier >= tier_empire + NOT = { # Required formatting to include male/female check as well as vacancy + cp:councillor_court_chaplain ?= { + is_female = no + } + } + } + localization_key = councillor_court_chaplain_theocrat_empire_female_possessive + } + text = { + trigger = { + is_female = yes + highest_held_title_tier >= tier_kingdom + } + localization_key = councillor_court_chaplain_theocrat_kingdom_female_possessive + } + text = { + trigger = { highest_held_title_tier >= tier_kingdom } + localization_key = councillor_court_chaplain_theocrat_kingdom_possessive + } + text = { + trigger = { + is_female = yes + highest_held_title_tier >= tier_duchy + } + localization_key = councillor_court_chaplain_theocrat_duchy_female_possessive + } + text = { + trigger = { highest_held_title_tier >= tier_duchy } + localization_key = councillor_court_chaplain_theocrat_duchy_possessive + } + text = { + trigger = { + is_female = yes + highest_held_title_tier < tier_duchy + } + localization_key = councillor_court_chaplain_theocrat_county_female_possessive + } + text = { + trigger = { highest_held_title_tier < tier_duchy } + localization_key = councillor_court_chaplain_theocrat_county_possessive + } } GetBirthOmen = { @@ -1520,7 +3766,7 @@ GetTaltosTerm = { type = character text = { - trigger = { religion = religion:mediterranean_religion } + trigger = { religion = religion:magyar_religion } localization_key = chosen_one_taltos } text = { @@ -1537,12 +3783,7 @@ GetReligiousRite = { text = { localization_key = rite_mass - trigger = { OR = { - religion = religion:eastern_orthodox_religion - religion = religion:catholic_religion - religion = religion:protestant_religion - } - } + trigger = { faith = { religion = religion:christianity_religion } } } text = { localization_key = rite_prayer @@ -1580,8 +3821,17 @@ GetRiteEcumenismFullOrEmpty = { } text = { trigger = { - NOT = { - faith = { has_doctrine = special_doctrine_ecumenical_christian } + faith = { has_doctrine = special_doctrine_ecumenical_miaphysite } + } + localization_key = GetRiteEcumenismMiaphysiteFullOrEmpty_full + } + text = { + trigger = { + faith = { + NOR = { + has_doctrine = special_doctrine_ecumenical_christian + has_doctrine = special_doctrine_ecumenical_miaphysite + } } } localization_key = GetRiteEcumenismFullOrEmpty_empty @@ -1594,21 +3844,21 @@ ghw_from_which_tenet = { text = { trigger = { - faith = { has_doctrine = tenet_armed_pilgrimages } + rite = { rite_has_tenet = tenet_armed_pilgrimages } } localization_key = ghw_from_which_tenet_armed_pilgrimages } text = { trigger = { - faith = { has_doctrine = tenet_struggle_submission } + rite = { rite_has_tenet = tenet_struggle_submission } } localization_key = ghw_from_which_tenet_struggle_submission } text = { trigger = { - faith = { has_doctrine = tenet_warmonger } + rite = { rite_has_tenet = tenet_warmonger } } localization_key = ghw_from_which_tenet_warmonger } @@ -1621,7 +3871,7 @@ GetFaithTaxExemptInstitution = { # Theocratic clergy faiths exempt the Church. text = { trigger = { - faith = { has_doctrine_parameter = theocracy_temple_lease } + rite = { rite_has_parameter = theocracy_temple_lease } } localization_key = faithtaxexemption_the_church } @@ -1629,7 +3879,7 @@ GetFaithTaxExemptInstitution = { # Lay clergy faiths exempt charities. text = { trigger = { - faith = { has_doctrine_parameter = lay_clergy } + rite = { rite_has_parameter = lay_clergy } } fallback = yes localization_key = faithtaxexemption_charities diff --git a/common/flavorization/00_title_holders.txt b/common/flavorization/00_title_holders.txt index 0b165c3d8..57114cabb 100644 --- a/common/flavorization/00_title_holders.txt +++ b/common/flavorization/00_title_holders.txt @@ -694,178 +694,7 @@ king_theocracy_female_buddhism_religion = { } # Christianity -baron_theocracy_male_christianity_religion = { - type = character - gender = male - special = holder - tier = barony - priority = 7 - governments = { theocracy_government } - religions = { eastern_orthodox_religion catholic_religion protestant_religion } - flavourization_rules = { - top_liege = no - } -} -baron_theocracy_female_christianity_religion = { - type = character - gender = female - special = holder - tier = barony - priority = 7 - governments = { theocracy_government } - religions = { eastern_orthodox_religion catholic_religion protestant_religion } - flavourization_rules = { - top_liege = no - } -} -barony_theocracy_christianity_religion = { - type = title - tier = barony - priority = 7 - holding = church_holding - religions = { eastern_orthodox_religion catholic_religion protestant_religion } - flavourization_rules = { - top_liege = no - } -} -count_theocracy_male_christianity_religion = { - type = character - gender = male - special = holder - tier = county - priority = 18 - governments = { theocracy_government } - religions = { eastern_orthodox_religion catholic_religion protestant_religion } - flavourization_rules = { - top_liege = no - } -} -count_theocracy_female_christianity_religion = { - type = character - gender = female - special = holder - tier = county - priority = 18 - governments = { theocracy_government } - religions = { eastern_orthodox_religion catholic_religion protestant_religion } - flavourization_rules = { - top_liege = no - } -} -county_theocracy_christianity_religion = { - type = title - tier = county - priority = 18 - governments = { theocracy_government } - religions = { eastern_orthodox_religion catholic_religion protestant_religion } - flavourization_rules = { - top_liege = no - } -} -duke_theocracy_male_christianity_religion = { - type = character - gender = male - special = holder - tier = duchy - priority = 27 - governments = { theocracy_government } - religions = { eastern_orthodox_religion catholic_religion protestant_religion } - flavourization_rules = { - top_liege = no - } -} -duke_theocracy_female_christianity_religion = { - type = character - gender = female - special = holder - tier = duchy - priority = 27 - governments = { theocracy_government } - religions = { eastern_orthodox_religion catholic_religion protestant_religion } - flavourization_rules = { - top_liege = no - } -} -duchy_theocracy_christianity_religion = { - type = title - tier = duchy - priority = 27 - governments = { theocracy_government } - religions = { eastern_orthodox_religion catholic_religion protestant_religion } - flavourization_rules = { - top_liege = no - } -} -king_theocracy_male_christianity_religion = { - type = character - gender = male - special = holder - tier = kingdom - priority = 47 - flavourization_rules = { - top_liege = no - } - governments = { theocracy_government } - religions = { eastern_orthodox_religion catholic_religion protestant_religion } -} -king_theocracy_female_christianity_religion = { - type = character - gender = female - special = holder - tier = kingdom - priority = 47 - flavourization_rules = { - top_liege = no - } - governments = { theocracy_government } - religions = { eastern_orthodox_religion catholic_religion protestant_religion } -} -kingdom_theocracy_christianity_religion = { - type = title - tier = kingdom - flavourization_rules = { - top_liege = no - } - priority = 47 - governments = { theocracy_government } - religions = { eastern_orthodox_religion catholic_religion protestant_religion } -} -emperor_theocracy_male_christianity_religion = { - type = character - gender = male - special = holder - tier = empire - priority = 102 - flavourization_rules = { - top_liege = no - } - governments = { theocracy_government } - religions = { eastern_orthodox_religion catholic_religion protestant_religion } -} -emperor_theocracy_female_christianity_religion = { - type = character - gender = female - special = holder - tier = empire - priority = 102 - flavourization_rules = { - top_liege = no - } - governments = { theocracy_government } - religions = { eastern_orthodox_religion catholic_religion protestant_religion } -} -empire_theocracy_christianity_religion = { - type = title - tier = empire - priority = 102 - flavourization_rules = { - top_liege = no - } - governments = { theocracy_government } - religions = { eastern_orthodox_religion catholic_religion protestant_religion } -} -#Eastern Christians baron_orthodox = { type = character gender = male @@ -875,7 +704,7 @@ baron_orthodox = { flavourization_rules = { top_liege = no } - governments = { theocracy_government } + governments = { theocracy_government ecclesiastical_government } religions = { eastern_orthodox_religion oriental_orthodox_religion } } barony_orthodox = { @@ -885,7 +714,7 @@ barony_orthodox = { flavourization_rules = { top_liege = no } - governments = { theocracy_government } + governments = { theocracy_government ecclesiastical_government } religions = { eastern_orthodox_religion oriental_orthodox_religion } } count_orthodox = { @@ -897,7 +726,7 @@ count_orthodox = { flavourization_rules = { top_liege = no } - governments = { theocracy_government } + governments = { theocracy_government ecclesiastical_government } religions = { eastern_orthodox_religion oriental_orthodox_religion } } county_orthodox = { @@ -907,7 +736,7 @@ county_orthodox = { flavourization_rules = { top_liege = no } - governments = { theocracy_government } + governments = { theocracy_government ecclesiastical_government } religions = { eastern_orthodox_religion oriental_orthodox_religion } } duke_orthodox = { @@ -919,7 +748,7 @@ duke_orthodox = { flavourization_rules = { top_liege = no } - governments = { theocracy_government } + governments = { theocracy_government ecclesiastical_government } religions = { eastern_orthodox_religion oriental_orthodox_religion } } duchy_orthodox = { @@ -929,7 +758,7 @@ duchy_orthodox = { flavourization_rules = { top_liege = no } - governments = { theocracy_government } + governments = { theocracy_government ecclesiastical_government } religions = { eastern_orthodox_religion oriental_orthodox_religion } } king_orthodox = { @@ -941,7 +770,7 @@ king_orthodox = { flavourization_rules = { top_liege = no } - governments = { theocracy_government } + governments = { theocracy_government ecclesiastical_government } religions = { eastern_orthodox_religion oriental_orthodox_religion } } kingdom_orthodox = { @@ -951,7 +780,7 @@ kingdom_orthodox = { flavourization_rules = { top_liege = no } - governments = { theocracy_government } + governments = { theocracy_government ecclesiastical_government } religions = { eastern_orthodox_religion oriental_orthodox_religion } } emperor_orthodox = { @@ -963,7 +792,7 @@ emperor_orthodox = { flavourization_rules = { top_liege = no } - governments = { theocracy_government } + governments = { theocracy_government ecclesiastical_government } religions = { eastern_orthodox_religion oriental_orthodox_religion } } empire_orthodox = { @@ -973,7 +802,7 @@ empire_orthodox = { flavourization_rules = { top_liege = no } - governments = { theocracy_government } + governments = { theocracy_government ecclesiastical_government } religions = { eastern_orthodox_religion oriental_orthodox_religion } } # girlboss for mostly wives presbytera @@ -986,7 +815,7 @@ baron_orthodox_female = { flavourization_rules = { top_liege = no } - governments = { theocracy_government } + governments = { theocracy_government ecclesiastical_government } religions = { eastern_orthodox_religion oriental_orthodox_religion } } count_orthodox_female = { @@ -998,7 +827,7 @@ count_orthodox_female = { flavourization_rules = { top_liege = no } - governments = { theocracy_government } + governments = { theocracy_government ecclesiastical_government } religions = { eastern_orthodox_religion oriental_orthodox_religion } } duke_orthodox_female = { @@ -1010,7 +839,7 @@ duke_orthodox_female = { flavourization_rules = { top_liege = no } - governments = { theocracy_government } + governments = { theocracy_government ecclesiastical_government } religions = { eastern_orthodox_religion oriental_orthodox_religion } } king_orthodox_female = { @@ -1022,7 +851,7 @@ king_orthodox_female = { flavourization_rules = { top_liege = no } - governments = { theocracy_government } + governments = { theocracy_government ecclesiastical_government } religions = { eastern_orthodox_religion oriental_orthodox_religion } } emperor_orthodox_female = { @@ -1034,9 +863,490 @@ emperor_orthodox_female = { flavourization_rules = { top_liege = no } - governments = { theocracy_government } + governments = { theocracy_government ecclesiastical_government } religions = { eastern_orthodox_religion oriental_orthodox_religion } } +# Christianity +baron_theocracy_male_christianity_religion = { + type = character + gender = male + special = holder + tier = barony + priority = 7 + governments = { theocracy_government ecclesiastical_government } + religions = { eastern_orthodox_religion oriental_orthodox_religion catholic_religion protestant_religion dualism_religion } + flavourization_rules = { + top_liege = no + spouse_takes_title = no + } +} +baron_theocracy_female_christianity_religion = { + type = character + gender = female + special = holder + tier = barony + priority = 7 + governments = { theocracy_government ecclesiastical_government } + religions = { eastern_orthodox_religion oriental_orthodox_religion catholic_religion protestant_religion dualism_religion } + flavourization_rules = { + top_liege = no + spouse_takes_title = no + } +} +barony_theocracy_christianity_religion = { + type = title + tier = barony + priority = 7 + holding = church_holding + religions = { eastern_orthodox_religion oriental_orthodox_religion catholic_religion protestant_religion dualism_religion } + flavourization_rules = { + top_liege = no + spouse_takes_title = no + } +} +count_theocracy_male_christianity_religion = { + type = character + gender = male + special = holder + tier = county + priority = 18 + governments = { theocracy_government ecclesiastical_government } + religions = { eastern_orthodox_religion oriental_orthodox_religion catholic_religion protestant_religion dualism_religion } + flavourization_rules = { + top_liege = no + spouse_takes_title = no + } +} +count_theocracy_female_christianity_religion = { + type = character + gender = female + special = holder + tier = county + priority = 18 + governments = { theocracy_government ecclesiastical_government } + religions = { eastern_orthodox_religion oriental_orthodox_religion catholic_religion protestant_religion dualism_religion } + flavourization_rules = { + top_liege = no + spouse_takes_title = no + } +} +count_theocracy_male_christianity_religion_cardinal = { + type = character + gender = male + special = holder + tier = county + priority = 19 + governments = { theocracy_government ecclesiastical_government } + religions = { eastern_orthodox_religion oriental_orthodox_religion catholic_religion protestant_religion dualism_religion } + flavourization_rules = { + top_liege = no + spouse_takes_title = no + } + flag = cardinal_flag +} +count_theocracy_female_christianity_religion_cardinal = { + type = character + gender = female + special = holder + tier = county + priority = 19 + governments = { theocracy_government ecclesiastical_government } + religions = { eastern_orthodox_religion oriental_orthodox_religion catholic_religion protestant_religion dualism_religion } + flavourization_rules = { + top_liege = no + spouse_takes_title = no + } + flag = cardinal_flag +} +county_theocracy_christianity_religion = { + type = title + tier = county + priority = 18 + governments = { theocracy_government ecclesiastical_government } + religions = { eastern_orthodox_religion oriental_orthodox_religion catholic_religion protestant_religion dualism_religion } + flavourization_rules = { + top_liege = no + spouse_takes_title = no + } +} +duke_theocracy_male_christianity_religion = { + type = character + gender = male + special = holder + tier = duchy + priority = 27 + governments = { theocracy_government ecclesiastical_government } + religions = { eastern_orthodox_religion oriental_orthodox_religion catholic_religion protestant_religion dualism_religion } + flavourization_rules = { + top_liege = no + spouse_takes_title = no + } +} +duke_theocracy_female_christianity_religion = { + type = character + gender = female + special = holder + tier = duchy + priority = 27 + governments = { theocracy_government ecclesiastical_government } + religions = { eastern_orthodox_religion oriental_orthodox_religion catholic_religion protestant_religion dualism_religion } + flavourization_rules = { + top_liege = no + spouse_takes_title = no + } +} +duke_theocracy_male_christianity_religion_archbishop = { + type = character + gender = male + special = clerical_region_holder + tier = duchy + priority = 27 + governments = { theocracy_government ecclesiastical_government } + religions = { eastern_orthodox_religion oriental_orthodox_religion catholic_religion protestant_religion dualism_religion } + flavourization_rules = { + top_liege = no + spouse_takes_title = no + } +} +duke_theocracy_female_christianity_religion_archbishop = { + type = character + gender = female + special = clerical_region_holder + tier = duchy + priority = 27 + governments = { theocracy_government ecclesiastical_government } + religions = { eastern_orthodox_religion oriental_orthodox_religion catholic_religion protestant_religion dualism_religion } + flavourization_rules = { + top_liege = no + spouse_takes_title = no + } +} +duke_theocracy_male_christianity_religion_clerical_region = { + type = character + gender = male + special = clerical_region_holder + tier = duchy + priority = 28 + governments = { theocracy_government ecclesiastical_government } + religions = { eastern_orthodox_religion oriental_orthodox_religion catholic_religion protestant_religion } + flavourization_rules = { + top_liege = no + spouse_takes_title = no + } +} +duke_theocracy_female_christianity_religion_clerical_region = { + type = character + gender = female + special = clerical_region_holder + tier = duchy + priority = 28 + governments = { theocracy_government ecclesiastical_government } + religions = { eastern_orthodox_religion oriental_orthodox_religion catholic_religion protestant_religion } + flavourization_rules = { + top_liege = no + spouse_takes_title = no + } +} +duke_theocracy_male_catholic_clerical_region_archbishop = { + type = character + gender = male + special = clerical_region_holder + tier = duchy + priority = 29 + governments = { theocracy_government ecclesiastical_government } + religions = { catholic_religion protestant_religion } + flavourization_rules = { + top_liege = no + spouse_takes_title = no + } +} +duke_theocracy_female_catholic_clerical_region_archbishop = { + type = character + gender = female + special = clerical_region_holder + tier = duchy + priority = 29 + governments = { theocracy_government ecclesiastical_government } + religions = { catholic_religion protestant_religion } + flavourization_rules = { + top_liege = no + spouse_takes_title = no + } +} +duke_theocracy_male_christian_faith_clerical_region = { + type = character + gender = male + special = clerical_region_holder + tier = duchy + priority = 29 + governments = { theocracy_government ecclesiastical_government } + faiths = { christian_faith } + flavourization_rules = { + top_liege = no + spouse_takes_title = no + } +} +duke_theocracy_female_christian_faith_clerical_region = { + type = character + gender = female + special = clerical_region_holder + tier = duchy + priority = 29 + governments = { theocracy_government ecclesiastical_government } + faiths = { christian_faith } + flavourization_rules = { + top_liege = no + spouse_takes_title = no + } +} +duke_theocracy_male_orthodox_clerical_region_metropolitan = { + type = character + gender = male + special = clerical_region_holder + tier = duchy + priority = 29 + governments = { theocracy_government ecclesiastical_government } + religions = { eastern_orthodox_religion oriental_orthodox_religion } + flavourization_rules = { + top_liege = no + spouse_takes_title = no + } +} +duke_theocracy_female_orthodox_clerical_region_metropolitan = { + type = character + gender = female + special = clerical_region_holder + tier = duchy + priority = 29 + governments = { theocracy_government ecclesiastical_government } + religions = { eastern_orthodox_religion oriental_orthodox_religion } + flavourization_rules = { + top_liege = no + spouse_takes_title = no + } +} +duke_theocracy_male_orthodox_clerical_region_archbishopric = { + type = character + gender = male + special = clerical_region_holder + tier = duchy + priority = 31 + governments = { theocracy_government ecclesiastical_government } + religions = { eastern_orthodox_religion oriental_orthodox_religion } + titles = { d_et_cyprus } + flavourization_rules = { + top_liege = no + spouse_takes_title = no + } +} +duke_theocracy_female_orthodox_clerical_region_archbishopric = { + type = character + gender = female + special = clerical_region_holder + tier = duchy + priority = 31 + governments = { theocracy_government ecclesiastical_government } + religions = { eastern_orthodox_religion oriental_orthodox_religion } + titles = { d_et_cyprus } + flavourization_rules = { + top_liege = no + spouse_takes_title = no + } +} +duke_theocracy_male_christianity_religion_cardinal = { + type = character + gender = male + special = holder + tier = duchy + priority = 28 + governments = { theocracy_government ecclesiastical_government } + religions = { eastern_orthodox_religion oriental_orthodox_religion catholic_religion protestant_religion dualism_religion } + flavourization_rules = { + top_liege = no + spouse_takes_title = no + } + flag = cardinal_flag +} +duke_theocracy_female_christianity_religion_cardinal = { + type = character + gender = female + special = holder + tier = duchy + priority = 28 + governments = { theocracy_government ecclesiastical_government } + religions = { eastern_orthodox_religion oriental_orthodox_religion catholic_religion protestant_religion dualism_religion } + flavourization_rules = { + top_liege = no + spouse_takes_title = no + } + flag = cardinal_flag +} +duke_theocracy_male_christianity_religion_archbishop_cardinal = { + type = character + gender = male + special = clerical_region_holder + tier = duchy + priority = 28 + governments = { theocracy_government ecclesiastical_government } + religions = { eastern_orthodox_religion oriental_orthodox_religion catholic_religion protestant_religion dualism_religion } + flavourization_rules = { + top_liege = no + spouse_takes_title = no + } + special_title = clerical_elector +} +duke_theocracy_female_christianity_religion_archbishop_cardinal = { + type = character + gender = female + special = clerical_region_holder + tier = duchy + priority = 28 + governments = { theocracy_government ecclesiastical_government } + religions = { eastern_orthodox_religion oriental_orthodox_religion catholic_religion protestant_religion dualism_religion } + flavourization_rules = { + top_liege = no + spouse_takes_title = no + } + special_title = clerical_elector +} +duchy_theocracy_christianity_religion = { + type = title + tier = duchy + priority = 27 + governments = { theocracy_government ecclesiastical_government } + religions = { eastern_orthodox_religion oriental_orthodox_religion catholic_religion protestant_religion dualism_religion } + flavourization_rules = { + top_liege = no + } +} +king_theocracy_male_christianity_religion = { + type = character + gender = male + special = holder + tier = kingdom + priority = 47 + flavourization_rules = { + top_liege = no + spouse_takes_title = no + } + governments = { theocracy_government ecclesiastical_government } + religions = { eastern_orthodox_religion oriental_orthodox_religion catholic_religion protestant_religion dualism_religion } +} +king_theocracy_female_christianity_religion = { + type = character + gender = female + special = holder + tier = kingdom + priority = 47 + flavourization_rules = { + top_liege = no + spouse_takes_title = no + } + governments = { theocracy_government ecclesiastical_government } + religions = { eastern_orthodox_religion oriental_orthodox_religion catholic_religion protestant_religion dualism_religion } +} +king_theocracy_male_christianity_religion_cardinal = { + type = character + gender = male + special = holder + tier = kingdom + priority = 48 + flavourization_rules = { + top_liege = no + spouse_takes_title = no + } + governments = { theocracy_government ecclesiastical_government } + religions = { eastern_orthodox_religion oriental_orthodox_religion catholic_religion protestant_religion dualism_religion } + flag = cardinal_flag +} +king_theocracy_female_christianity_religion_cardinal = { + type = character + gender = female + special = holder + tier = kingdom + priority = 48 + flavourization_rules = { + top_liege = no + spouse_takes_title = no + } + governments = { theocracy_government ecclesiastical_government } + religions = { eastern_orthodox_religion oriental_orthodox_religion catholic_religion protestant_religion dualism_religion } + flag = cardinal_flag +} +kingdom_theocracy_christianity_religion = { + type = title + tier = kingdom + flavourization_rules = { + top_liege = no + } + priority = 47 + governments = { theocracy_government ecclesiastical_government } + religions = { eastern_orthodox_religion oriental_orthodox_religion catholic_religion protestant_religion dualism_religion } +} +emperor_theocracy_male_christianity_religion = { + type = character + gender = male + special = holder + tier = empire + priority = 102 + flavourization_rules = { + top_liege = no + spouse_takes_title = no + } + governments = { theocracy_government ecclesiastical_government } + religions = { eastern_orthodox_religion oriental_orthodox_religion catholic_religion protestant_religion dualism_religion } +} +emperor_theocracy_female_christianity_religion = { + type = character + gender = female + special = holder + tier = empire + priority = 102 + flavourization_rules = { + top_liege = no + spouse_takes_title = no + } + governments = { theocracy_government ecclesiastical_government } + religions = { eastern_orthodox_religion oriental_orthodox_religion catholic_religion protestant_religion dualism_religion } +} +emperor_theocracy_male_christianity_religion_cardinal = { + type = character + gender = male + special = holder + tier = empire + priority = 103 + flavourization_rules = { + top_liege = no + spouse_takes_title = no + } + governments = { theocracy_government ecclesiastical_government } + religions = { eastern_orthodox_religion oriental_orthodox_religion catholic_religion protestant_religion dualism_religion } + flag = cardinal_flag +} +emperor_theocracy_female_christianity_religion_cardinal = { + type = character + gender = female + special = holder + tier = empire + priority = 103 + flavourization_rules = { + top_liege = no + spouse_takes_title = no + } + governments = { theocracy_government ecclesiastical_government } + religions = { eastern_orthodox_religion oriental_orthodox_religion catholic_religion protestant_religion dualism_religion } + flag = cardinal_flag +} +empire_theocracy_christianity_religion = { + type = title + tier = empire + priority = 102 + flavourization_rules = { + top_liege = no + } + governments = { theocracy_government ecclesiastical_government } + religions = { eastern_orthodox_religion oriental_orthodox_religion catholic_religion protestant_religion dualism_religion } +} # john holy order holy_order_orthodox = { type = character diff --git a/common/flavorization/20_pam_flavorization.txt b/common/flavorization/20_pam_flavorization.txt index 74e4b54aa..3f77de465 100644 --- a/common/flavorization/20_pam_flavorization.txt +++ b/common/flavorization/20_pam_flavorization.txt @@ -1,11 +1,39 @@ ### Clerical Regions ### +duke_theocracy_male_orthodox_clerical_region_exarch = { + type = character + gender = male + special = clerical_region_holder + tier = duchy + priority = 32 + governments = { theocracy_government ecclesiastical_government } + religions = { eastern_orthodox_religion oriental_orthodox_religion } + flag = neow_orthodox_exarch_flag + flavourization_rules = { + top_liege = no + spouse_takes_title = no + } +} +duke_theocracy_female_orthodox_clerical_region_exarch = { + type = character + gender = female + special = clerical_region_holder + tier = duchy + priority = 32 + governments = { theocracy_government ecclesiastical_government } + religions = { eastern_orthodox_religion oriental_orthodox_religion } + flag = neow_orthodox_exarch_flag + flavourization_rules = { + top_liege = no + spouse_takes_title = no + } +} clerical_region_duchy_fallback = { type = title tier = duchy priority = 30 governments = { ecclesiastical_government } - religion = { christianity_religion } + religions = { christianity_religion eastern_orthodox_religion oriental_orthodox_religion catholic_religion protestant_religion } flavourization_rules = { target_character = yes @@ -22,8 +50,7 @@ clerical_region_duchy_east_christian = { priority = 110 governments = { ecclesiastical_government } - rites = { byzantine_rite georgian_rite } - faiths = { christian_faith } + religions = { eastern_orthodox_religion oriental_orthodox_religion } flavourization_rules = { target_character = yes @@ -40,7 +67,7 @@ clerical_region_duchy_west_christian = { priority = 100 governments = { ecclesiastical_government } - faiths = { christian_faith } + religions = { catholic_religion protestant_religion } flavourization_rules = { target_character = yes @@ -57,7 +84,7 @@ clerical_region_duchy_catholic = { priority = 100 governments = { ecclesiastical_government } - faiths = { catholic } + religions = { catholic_religion protestant_religion } flavourization_rules = { target_character = yes @@ -74,7 +101,7 @@ clerical_region_duchy_orthodox = { priority = 100 governments = { ecclesiastical_government } - faiths = { orthodox } + religions = { eastern_orthodox_religion oriental_orthodox_religion } flavourization_rules = { target_character = yes @@ -91,8 +118,8 @@ clerical_region_duchy_patriarchate = { # exceptions to normal rules, including P priority = 101 governments = { ecclesiastical_government } - faiths = { orthodox } - titles = { d_et_roma d_et_constantinople d_et_alexandria d_et_antioch d_et_jerusalem } + religions = { eastern_orthodox_religion oriental_orthodox_religion } + titles = { d_et_roma d_et_constantinople d_et_alexandria d_et_antioch d_et_jerusalem d_et_kartli } flavourization_rules = { target_character = yes @@ -109,8 +136,8 @@ clerical_region_duchy_metropolitanate = { # sees held by a metropolitan rather t priority = 101 governments = { ecclesiastical_government } - religions = { christianity_religion } - titles = { d_et_axum d_et_kyiv } + religions = { eastern_orthodox_religion oriental_orthodox_religion } + titles = { d_et_axum } flavourization_rules = { target_character = yes @@ -121,13 +148,15 @@ clerical_region_duchy_metropolitanate = { # sees held by a metropolitan rather t special_title = clerical_region } + + clerical_region_duchy_archbishopric = { # exceptional autocephalous archbishopric type = title tier = duchy priority = 101 governments = { ecclesiastical_government } - religions = { christianity_religion } + religions = { eastern_orthodox_religion oriental_orthodox_religion } titles = { d_et_cyprus } flavourization_rules = { @@ -200,7 +229,7 @@ clerical_elector_duchy_cardinalate = { tier = duchy priority = 75 governments = { ecclesiastical_government } - religions = { christianity_religion dualism_religion } + religions = { catholic_religion protestant_religion dualism_religion } flavourization_rules = { only_holder = yes top_liege = no diff --git a/common/governments/00_government_types.txt b/common/governments/00_government_types.txt index 765bd732a..096a60141 100644 --- a/common/governments/00_government_types.txt +++ b/common/governments/00_government_types.txt @@ -293,59 +293,6 @@ republic_government = { realm_mask_scale = { 1 1 } } -### Brief: theocracy_government -# Head of faith will always get this if possible -# -# This is referenced in code -# -theocracy_government = { - government_rules = { - religious = yes - inherit_from_dynastic_government = no - } - - primary_holding = church_holding - valid_holdings = { castle_holding tribal_holding nomad_holding herder_holding temple_citadel_holding } - required_county_holdings = { church_holding castle_holding city_holding } - - ai = { - use_legends = no - } - - can_get_government = { - NOT = { - faith = { has_doctrine = doctrine_theocracy_lay_clergy } - } - #The LAAMP Construct Holding decision - trigger_if = { - limit = { - OR = { - has_variable = city_construction_is_temple_citadel - has_variable = city_construction_is_castle - } - } - always = no - } - } - - vassal_contract_group = theocracy_vassal - - # Use flags instead of has_government for moddability if possible (i.e., wherever not visible to the player). - flags = { - government_is_theocracy - government_is_settled - government_uses_domain_limit - gov_uses_non_crown_coa - } - - mechanic_type = theocracy - is_mechanic_type_default = yes - - color = hsv{ 0.00 0.00 0.78 } - realm_mask_offset = { 0.0 0.02 } - realm_mask_scale = { 0.95 0.95 } -} - ### Brief: clan_government clan_government = { government_rules = { diff --git a/common/governments/02_theocratic_government_types.txt b/common/governments/02_theocratic_government_types.txt new file mode 100644 index 000000000..302d47403 --- /dev/null +++ b/common/governments/02_theocratic_government_types.txt @@ -0,0 +1,161 @@ +### Brief: theocracy_government +# Head of faith will always get this if possible +# +# This is referenced in code +# +theocracy_government = { + government_rules = { + inherit_from_dynastic_government = no + disable_regnal_numbers = yes + sticky_government = yes + } + + primary_holding = church_holding + valid_holdings = { castle_holding tribal_holding nomad_holding herder_holding temple_citadel_holding } + required_county_holdings = { church_holding castle_holding city_holding } + + ai = { + use_legends = no + } + + royal_court = landed + + can_get_government = { + theocratic_lay_clergy_trigger = yes + #The LAAMP Construct Holding decision + trigger_if = { + limit = { + has_variable = { + name = city_construction_is_temple_citadel + name = city_construction_is_castle + } + } + always = no + } + } + + vassal_contract_group = theocracy_vassal + + # Use flags instead of has_government for moddability if possible (i.e., wherever not visible to the player). + flags = { + government_is_theocracy + government_is_settled + government_uses_church_authority + government_uses_domain_limit + } + + mechanic_type = theocracy + min_appointment_tier = county + is_mechanic_type_default = yes + + # Any positive weight is enough + grant_vassal_ai_will_do = { + value = 0 + if = { + limit = { + scope:title = { tier = tier_county } + NOT = { has_variable = grant_vassal_government_cooldown } + ai_zeal >= medium_positive_ai_value + rite = { + NOT = { rite_has_doctrine = doctrine_theocracy_lay_clergy } + rite_has_doctrine = doctrine_theocracy_temporal + } + realm_theocratic_county_share_ai_below_cap_trigger = yes + } + add = 10 + } + } + + color = hsv{ 0.00 0.00 0.78 } + realm_mask_offset = { 0.0 0.02 } + realm_mask_scale = { 0.95 0.95 } +} + +### Brief: ecclesiastical_government +# This is a theocratic government type that is Christian centered +# +ecclesiastical_government = { + government_rules = { + inherit_from_dynastic_government = no + treasury = yes + replace_gold_cost_by_treasury = yes + add_religious_subordinates_for_treasury = yes + use_as_base_on_landed = yes + disable_regnal_numbers = yes + sticky_government = yes + allow_accolades = yes + landless_playable = yes + } + + royal_court = landed + + primary_holding = church_holding + valid_holdings = { castle_holding tribal_holding nomad_holding herder_holding temple_citadel_holding } + required_county_holdings = { church_holding castle_holding city_holding } + + ai = { + use_legends = no + } + + can_get_government = { + theocratic_lay_clergy_trigger = yes + #The LAAMP Construct Holding decision + trigger_if = { + limit = { + has_variable = { + name = city_construction_is_temple_citadel + name = city_construction_is_castle + } + } + always = no + } + } + + vassal_contract_group = theocracy_vassal + + character_modifier = { + monthly_treasury_from_vassals = 0.85 + monthly_treasury_from_non_vassals = 0.85 + monthly_piety = 0.25 + accolades = -1 + knight_limit = -3 + men_at_arms_cap = -3 + men_at_arms_limit = -3 + mercenary_hire_cost_mult = 2 + } + + # Use flags instead of has_government for moddability if possible (i.e., wherever not visible to the player). + flags = { + government_is_ecclesiastical + government_is_theocracy + government_is_settled + government_uses_domicile_but_not_adventurer + government_uses_church_authority + government_uses_domain_limit + government_has_treasury + government_uses_cardinal_budget + } + + mechanic_type = theocracy + min_appointment_tier = county + domicile_type = ecclesiastical_domicile + + # is_grant_government_shown already limits this to ecclesiastical theocracy faiths + grant_vassal_ai_will_do = { + value = 0 + if = { + limit = { + scope:title = { tier = tier_county } + NOT = { has_variable = grant_vassal_government_cooldown } + ai_zeal >= medium_positive_ai_value + rite = { rite_has_doctrine = doctrine_theocracy_temporal } + realm_theocratic_county_share_ai_below_cap_trigger = yes + } + add = 10 + } + } + + color = hsv{ 0.00 0.00 0.38 } + realm_mask_offset = { 0.0 0.02 } + realm_mask_scale = { 0.95 0.95 } +} diff --git a/common/on_action/dlc/pam/pam_on_actions.txt b/common/on_action/dlc/pam/pam_on_actions.txt new file mode 100644 index 000000000..db409067f --- /dev/null +++ b/common/on_action/dlc/pam/pam_on_actions.txt @@ -0,0 +1,544 @@ +# referenced by code. Fired yearly on every rite +# root = rite +on_rite_yearly = { + effect = { + rite_yearly_hor_passive_learning_effect = yes + rite_yearly_hor_divergence_drift_effect = yes + } +} + +pam_the_christian_church_yearly_on_action = { + effect = { + # Non Christian presence in Europe + pam_the_christian_church_non_christian_kingdom_in_europe_catalyst_effect = yes + # Non-Catholic ruler controls the Papal State's de jure capital + pam_the_christian_church_catholic_hof_weak_papal_state_control_catalyst_effect = yes + # Byzantine emperor is not Christian + pam_the_christian_church_byzantine_emperor_non_christian_catalyst_effect = yes + } +} +# Tier 1 is paced once from pam_cathedral_01 on_start_build (years = 2). +pam_cathedral_great_project_yearly_on_action = { + effect = { + every_great_project = { + limit = { + OR = { + great_project_type = pam_cathedral_02 + great_project_type = pam_cathedral_03 + } + } + great_project_founder = { + save_scope_as = founder + trigger_event = { + on_action = pam_cathedral_great_project_yearly_founder_events_on_action + years = 5 + } + } + great_project_owner = { + if = { + limit = { + this = scope:founder + } + trigger_event = { + on_action = pam_cathedral_great_project_yearly_owner_events_on_action + years = 10 + } + } + else = { + trigger_event = { + on_action = pam_cathedral_great_project_yearly_owner_events_on_action + years = 5 + } + } + } + } + } +} +pam_cathedral_great_project_yearly_founder_events_on_action = { + random_events = { + 1 = pam_great_projects_events.0007 + 1 = pam_great_projects_events.0008 + 1 = pam_great_projects_events.0011 + 1 = pam_great_projects_events.0013 + } +} +pam_cathedral_great_project_yearly_owner_events_on_action = { + random_events = { + 1 = pam_great_projects_events.0012 + } +} + +study_faith_success = { + on_actions = { + pam_study_faith_personal_tenet_on_action + } +} + +on_travel_plan_movement = { + on_actions = { + pam_mountain_travel_personal_tenet_on_action + sun_worship_desert_travel_personal_tenet_on_action + pam_sanctity_of_nature_travel_on_action + } +} + +on_building_completed = { + on_actions = { + pam_sanctity_of_nature_building_completed_on_action + } +} + +on_faith_conversion = { + on_actions = { + pam_tax_nonbelievers_faith_conversion_on_action + } +} + +on_birth_child = { + on_actions = { + pam_auspicious_birthright_birth_on_action + } +} + +pam_study_faith_personal_tenet_on_action = { + effect = { + if = { + limit = { + scope:owner = { + has_personal_tenet_flag = adaptive_study_rite_cultural_acceptance + culture != scope:target.culture + } + } + scope:owner = { + culture = { + change_cultural_acceptance = { + target = scope:target.culture + value = minor_cultural_acceptance_gain + desc = pam_adaptive_study_rite_cultural_acceptance + } + } + send_interface_toast = { + type = event_toast_effect_good + title = pam_adaptive_study_rite_cultural_acceptance_toast + left_icon = scope:owner + right_icon = scope:target + } + } + } + } +} + +pam_mountain_travel_personal_tenet_on_action = { + effect = { + if = { + limit = { + has_personal_tenet_flag = cthonic_redoubts_mountain_travel_fulfillment + current_travel_plan.current_location = { + OR = { + terrain = mountains + terrain = desert_mountains + } + } + current_travel_plan = { + NOT = { has_variable = pam_mountain_travel_fulfillment_awarded } + } + } + current_travel_plan = { + set_variable = pam_mountain_travel_fulfillment_awarded + } + send_interface_toast = { + type = event_toast_effect_good + title = pam_cthonic_redoubts_mountain_travel_toast + left_icon = root + add_piety = minor_piety_gain + change_spiritual_fulfillment = minor_spiritual_fulfillment_value + } + } + } +} + +sun_worship_desert_travel_personal_tenet_on_action = { + effect = { + if = { + limit = { + has_personal_tenet_flag = tenet_sun_worship_desert_pilgrim + current_travel_plan.current_location = { + OR = { + terrain = desert + terrain = desert_mountains + terrain = oasis + } + } + current_travel_plan = { + NOT = { has_variable = sun_worship_desert_fulfillment_awarded } + } + } + current_travel_plan = { + set_variable = sun_worship_desert_fulfillment_awarded + } + send_interface_toast = { + type = event_toast_effect_good + title = sun_worship_desert_travel_toast + left_icon = root + add_piety = minor_piety_gain + change_spiritual_fulfillment = minor_spiritual_fulfillment_value + } + } + } +} + +pam_sanctity_of_nature_travel_on_action = { + effect = { + if = { + limit = { + current_travel_plan.current_location = { + has_province_modifier = preserved_wilderness_modifier + } + } + current_travel_plan = { + if = { + limit = { + NOT = { has_travel_plan_modifier = preserved_wilderness_travel_modifier } + } + add_travel_plan_modifier = preserved_wilderness_travel_modifier + } + } + } + else_if = { + limit = { + current_travel_plan = { + has_travel_plan_modifier = preserved_wilderness_travel_modifier + } + } + current_travel_plan = { + remove_travel_plan_modifier = preserved_wilderness_travel_modifier + } + } + + if = { + limit = { + has_personal_tenet_flag = tenet_sanctity_of_nature_wilderness_fulfillment + current_travel_plan.current_location = { + has_holding = no + is_sea_province = no + } + current_travel_plan = { + OR = { + NOT = { has_variable_list = pam_sanctity_of_nature_visited_wilderness } + AND = { + has_variable_list = pam_sanctity_of_nature_visited_wilderness + NOT = { + is_target_in_variable_list = { + name = pam_sanctity_of_nature_visited_wilderness + target = root.current_travel_plan.current_location + } + } + } + } + } + } + change_spiritual_fulfillment = miniscule_spiritual_fulfillment_value + current_travel_plan = { + add_to_variable_list = { + name = pam_sanctity_of_nature_visited_wilderness + target = root.current_travel_plan.current_location + } + } + } + } +} + +pam_sanctity_of_nature_building_completed_on_action = { + # add_great_building fires on_building_completed during history setup. + trigger = { + has_global_variable = game_has_started + } + + effect = { + if = { + limit = { + has_holding = yes + has_province_modifier = preserved_wilderness_modifier + } + remove_province_modifier = preserved_wilderness_modifier + } + } +} + +pam_tax_nonbelievers_faith_conversion_on_action = { + trigger = { + exists = scope:actor + root != scope:actor + scope:actor = { + has_personal_tenet_flag = tax_nonbelievers_fulfillment_from_conversion + } + } + effect = { + scope:actor = { + pam_tax_nonbelievers_conversion_fulfillment_effect = yes + } + } +} + +pam_auspicious_birthright_birth_on_action = { + effect = { + if = { + limit = { + OR = { + scope:mother = { + has_personal_tenet_flag = mystical_birthright_spiritual_leader + } + scope:real_father ?= { + has_personal_tenet_flag = mystical_birthright_spiritual_leader + } + } + } + # Base 5% chance for later children; the first-child modifiers shift the chance to 20%. + random_list = { + 95 = { + modifier = { + add = -15 + OR = { + scope:mother = { + has_personal_tenet_flag = mystical_birthright_spiritual_leader + NOR = { + any_child = { + even_if_dead = yes + this != scope:child + } + } + } + scope:real_father ?= { + has_personal_tenet_flag = mystical_birthright_spiritual_leader + NOR = { + any_child = { + even_if_dead = yes + this != scope:child + } + } + } + } + } + } + 5 = { + modifier = { + add = 15 + OR = { + scope:mother = { + has_personal_tenet_flag = mystical_birthright_spiritual_leader + NOR = { + any_child = { + even_if_dead = yes + this != scope:child + } + } + } + scope:real_father ?= { + has_personal_tenet_flag = mystical_birthright_spiritual_leader + NOR = { + any_child = { + even_if_dead = yes + this != scope:child + } + } + } + } + } + random_list = { + 1 = { + trigger = { + NOR = { + has_trait = dwarf + has_trait = giant + } + } + add_trait = dwarf + } + 1 = { + trigger = { + NOR = { + has_trait = giant + has_trait = dwarf + } + } + add_trait = giant + } + 1 = { + trigger = { + NOT = { has_trait = albino } + } + add_trait = albino + } + 1 = { + trigger = { + NOT = { has_trait = clubfooted } + } + add_trait = clubfooted + } + 1 = { + trigger = { + NOT = { has_trait = bleeder } + } + add_trait = bleeder + } + 1 = { + trigger = { + NOT = { has_trait = hunchbacked } + } + add_trait = hunchbacked + } + 1 = { + trigger = { + NOT = { has_trait = lisping } + } + add_trait = lisping + } + 1 = { + trigger = { + NOT = { has_trait = stuttering } + } + add_trait = stuttering + } + 1 = { + trigger = { + NOR = { + has_trait = spindly + has_trait = physique_good + } + } + add_trait = spindly + } + 1 = { + trigger = { + NOT = { has_trait = scaly } + } + add_trait = scaly + } + 1 = { + trigger = { + NOT = { has_trait = wheezing } + } + add_trait = wheezing + } + 1 = { + trigger = { + NOR = { + has_trait = beauty_bad + has_trait = beauty_good + } + } + add_trait = beauty_bad_2 + } + } + } + } + } + if = { + limit = { + scope:child = { + OR = { + has_trait = dwarf + has_trait = albino + has_trait = clubfooted + has_trait = bleeder + has_trait = scaly + has_trait = giant + has_trait = hunchbacked + has_trait = spindly + has_trait = wheezing + has_trait = lisping + has_trait = stuttering + has_trait = beauty_bad + } + } + OR = { + scope:mother = { + has_personal_tenet_flag = mystical_birthright_spiritual_leader + } + scope:real_father ?= { + has_personal_tenet_flag = mystical_birthright_spiritual_leader + } + } + } + scope:child = { + add_character_modifier = { + modifier = pam_mystical_birthright_spiritual_leader_modifier + } + } + if = { + limit = { + scope:mother = { + is_ai = no + } + } + scope:mother = { + send_interface_toast = { + type = event_toast_effect_good + title = pam_mystical_birthright_spiritual_leader_toast + left_icon = scope:child + custom_tooltip = { + text = pam_mystical_birthright_spiritual_leader_toast_tt + } + } + } + } + if = { + limit = { + scope:real_father ?= { + is_ai = no + } + } + scope:real_father = { + send_interface_toast = { + type = event_toast_effect_good + title = pam_mystical_birthright_spiritual_leader_toast + left_icon = scope:child + custom_tooltip = { + text = pam_mystical_birthright_spiritual_leader_toast_tt + } + } + } + } + } + } +} + +# used by code, do not rename or remove. +# root = clerical region holder +# scope:title = clerical region title +# scope:county = capital county +# scope:reason = reason that triggered this mismatch. flag can be: +# - county_converted (county is now of different faith, holder stayed old faith) +# - character_converted (character converted away from county faith) +# - changed_tenets_or_doctrines (county and character are still matching faith but the faith doesn't support clerical regions anymore) +on_clerical_region_faith_mismatch = { + # TIT-75963 player choice when capital converts; TIT-75964 other succession cases + events = { + # Capital converted; both Faiths have Clerical Regions (player) + pam_clergy_events.0051 + # AI / other mismatch reasons / new Faith lacks Clerical Regions + pam_clergy_events.0052 + } +} + +# used by code, do not rename or remove. +# root = challenger character +# scope:sponsor = former sponsor title +# scope:title = challenger title +on_challenger_removed = { + effect = { + if = { + limit = { + is_alive = yes + has_character_flag = antipope_flag + } + remove_character_flag = antipope_flag + } + # TODO_PAM move antipope removal cleanup effects here + #if = { + # limit = { root = scope:title.holder } + # destroy_title = scope:title + #} + } + +} diff --git a/common/religion/faith_types/NEOW_faiths_orthodox.txt b/common/religion/faith_types/NEOW_faiths_orthodox.txt index 8621755a5..9d8f450d6 100644 --- a/common/religion/faith_types/NEOW_faiths_orthodox.txt +++ b/common/religion/faith_types/NEOW_faiths_orthodox.txt @@ -8,8 +8,6 @@ orthodox = { religious_head = k_orthodox } - origin = christian_faith - eminent_holy_sites = { constantinople jerusalem @@ -38,8 +36,6 @@ russian_orthodox = { #religious_head = k_orthodox } - origin = christian_faith - eminent_holy_sites = { constantinople jerusalem diff --git a/common/scripted_effects/pam_effects.txt b/common/scripted_effects/pam_effects.txt new file mode 100644 index 000000000..14a8ef256 --- /dev/null +++ b/common/scripted_effects/pam_effects.txt @@ -0,0 +1,14582 @@ +#create_appropriate_relic_artifact_effect +#create_artifact_pedestal_bible_effect +#create_artifact_pedestal_thurible_effect +#create_artifact_pedestal_situla_effect +#create_artifact_pedestal_crozier_effect +#create_christian_religious_artifact_effect +#pam_miles_christi_white_peace_effect +#pam_miles_christi_fulfillment_from_combat_effect +#pam_miles_christi_holy_weapon_victory_effect +#pam_miles_christi_holy_weapon_gain_victory_effect +#pam_miles_christi_holy_weapon_blessing_effect +#pam_tenet_scholasticism_university_bonus_effect +#pam_tenet_scholasticism_yearly_effect +#pam_tenet_scholasticism_studium_effect +#pam_harmonious_society_five_bonds_effect +#pam_harmonious_society_apply_five_bonds_effect +#pam_tenet_purgatory_sin_penalty_effect +#pam_tenet_apostolic_succession_episcopate_effect +#pam_tenet_divine_liturgy_choirs_effect +#pam_tenet_divine_liturgy_officiant_effect +#pam_pentarchy_circuit_entourage_effect +#pam_pentarchy_pilgrim_circuit_effect +#add_scholar_trait_or_xp_effect +#pam_remove_forbidden_personal_tenet_secret_if_invalid_effect +#pam_faith_cleanup_forbidden_personal_tenet_secrets_effect +#pam_faith_grant_forbidden_personal_tenet_secrets_effect +#on_personal_tenet_gain_secret_gain_effect +#pam_ai_personal_tenet_pulse_effect +#conversion_tenet_acts_of_the_apostles_legitimacy_effect +#ora_et_labora_gardener_gain_effect +#hedonistic_reveler_gain_effect +#hedonistic_obesity_modifier_sync_effect +#hedonistic_feast_gout_risk_effect +#pam_tenet_mountain_worship_rough_terrain_expert_gain_effect +#pam_tenet_mountain_worship_hike_spiritual_fulfillment_effect +#asceticism_inappetetic_gain_effect +#literalism_scholar_gain_effect +#scholasticism_scholar_gain_effect +#pam_levy_the_tithes_decision_effects +#unrelenting_faith_blademaster_gain_effect +#pam_kingdom_of_heaven_declaration_effect +#pam_create_theocratic_dynasty_extra_effects +#pam_the_christian_church_clergy_embezzled_treasury_catalyst_effect +#pam_the_christian_church_non_christian_kingdom_in_europe_catalyst_effect +#pam_the_christian_church_county_converted_to_faith_catalyst_effect +#pam_the_christian_church_county_conversion_catalysts_effect +#pam_the_christian_church_excommunication_war_catalyst_effect +#pam_the_christian_church_humiliation_war_catalyst_effect +#pam_the_christian_church_clergy_has_child_catalyst_effect +#pam_determine_ghw_target_character_from_kingdom_effect +#pam_use_bull_selected_ghw_target_effect +#pam_start_bull_great_holy_war_effect +#pam_bull_notify_faith_rulers_effect +#pam_declare_rite_heresy_effect +#pam_secure_pilgrim_routes_effect +#request_white_peace_interaction_effect +#request_victory_interaction_effect +#request_enforce_succession_interaction_effect +#pam_enforce_title_succession_effect +#pam_increase_papabile_score_effect +#pam_on_conversion_effect +#pam_cardinal_vacancy_on_death_effect +#pam_evangelize_personal_tenet_effect +#pam_evangelize_personal_tenet_decline_effect + +create_appropriate_relic_artifact_effect = { + hidden_effect_new_object = { + if = { + limit = { religion = religion:christianity_religion } + create_artifact_pedestal_reliquary_christian_effect = { OWNER = $OWNER$ } + } + else_if = { + limit = { religion = religion:islam_religion } + create_artifact_pedestal_reliquary_islam_effect = { OWNER = $OWNER$ } + } + else_if = { + limit = { religion = religion:buddhism_religion } + create_artifact_pedestal_reliquary_buddhism_effect = { OWNER = $OWNER$ } + } + else_if = { + limit = { religion = religion:judaism_religion } + create_artifact_pedestal_reliquary_judaism_effect = { OWNER = $OWNER$ } + } + else = { + create_artifact_sculpture_religious_effect = { OWNER = $OWNER$ CREATOR = $CREATOR$ } + } + scope:newly_created_artifact = { + set_variable = relic # Adds the Relic flag + } + if = { # Makes a regular character artifact if you don't have a Royal Court + limit = { + has_royal_court = no + } + scope:newly_created_artifact = { + reforge_artifact = { type = miscellaneous } + } + } + } +} + +create_artifact_pedestal_bible_effect = { + $OWNER$ = { save_scope_as = owner } + $CREATOR$ = { save_scope_as = creator } + + get_artifact_quality_effect = yes + get_artifact_wealth_effect = yes + + scope:owner = { + create_artifact = { + name = artifact_pedestal_bible_name + creator = scope:creator + description = artifact_pedestal_bible_description + visuals = pam_bible + type = pedestal + template = cross_template + modifier = artifact_placeholder_modifier + save_scope_as = newly_created_artifact + wealth = scope:wealth + quality = scope:quality + } + } + + scope:newly_created_artifact = { + add_scaled_artifact_modifier_devotion_effect = yes + add_scaled_artifact_modifier_grandeur_small_effect = yes + if = { + limit = { + OR = { + rarity = famed + rarity = illustrious + } + } + add_scaled_artifact_modifier_piety_effect = yes + } + remove_artifact_modifier = artifact_placeholder_modifier + } +} + +create_artifact_pedestal_thurible_effect = { + $OWNER$ = { save_scope_as = owner } + $CREATOR$ = { save_scope_as = creator } + + get_artifact_quality_effect = yes + get_artifact_wealth_effect = yes + + scope:owner = { + create_artifact = { + name = artifact_pedestal_thurible_name + creator = scope:creator + description = artifact_pedestal_thurible_description + visuals = pam_thurible + type = pedestal + template = cross_template + modifier = artifact_placeholder_modifier + save_scope_as = newly_created_artifact + wealth = scope:wealth + quality = scope:quality + } + } + + scope:newly_created_artifact = { + add_scaled_artifact_modifier_devotion_effect = yes + add_scaled_artifact_modifier_grandeur_small_effect = yes + if = { + limit = { + OR = { + rarity = famed + rarity = illustrious + } + } + add_scaled_artifact_modifier_piety_effect = yes + } + remove_artifact_modifier = artifact_placeholder_modifier + } +} + +create_artifact_pedestal_situla_effect = { + $OWNER$ = { save_scope_as = owner } + $CREATOR$ = { save_scope_as = creator } + + get_artifact_quality_effect = yes + get_artifact_wealth_effect = yes + + scope:owner = { + create_artifact = { + name = artifact_pedestal_situla_name + creator = scope:creator + description = artifact_pedestal_situla_description + visuals = pam_situla + type = pedestal + template = cross_template + modifier = artifact_placeholder_modifier + save_scope_as = newly_created_artifact + wealth = scope:wealth + quality = scope:quality + } + } + + scope:newly_created_artifact = { + add_scaled_artifact_modifier_devotion_effect = yes + add_scaled_artifact_modifier_grandeur_small_effect = yes + if = { + limit = { + OR = { + rarity = famed + rarity = illustrious + } + } + add_scaled_artifact_modifier_piety_effect = yes + } + remove_artifact_modifier = artifact_placeholder_modifier + } +} + +create_artifact_pedestal_crozier_effect = { + $OWNER$ = { save_scope_as = owner } + $CREATOR$ = { save_scope_as = creator } + + get_artifact_quality_effect = yes + get_artifact_wealth_effect = yes + + scope:owner = { + create_artifact = { + name = artifact_pedestal_crozier_name + creator = scope:creator + description = artifact_pedestal_crozier_description + visuals = pam_crozier + type = pedestal + template = cross_template + modifier = artifact_placeholder_modifier + save_scope_as = newly_created_artifact + wealth = scope:wealth + quality = scope:quality + } + } + + scope:newly_created_artifact = { + add_scaled_artifact_modifier_devotion_effect = yes + add_scaled_artifact_modifier_grandeur_small_effect = yes + if = { + limit = { + OR = { + rarity = famed + rarity = illustrious + } + } + add_scaled_artifact_modifier_piety_effect = yes + } + remove_artifact_modifier = artifact_placeholder_modifier + } +} + +create_christian_religious_artifact_effect = { + hidden_effect_new_object = { + random_list = { + 1 = { + create_artifact_pedestal_cross_effect = { OWNER = $OWNER$ CREATOR = $CREATOR$ } + } + 1 = { + trigger = { + rite = { + NOT = { rite_has_tenet = tenet_aniconism } + } + } + create_artifact_pedestal_crucifix_effect = { OWNER = $OWNER$ CREATOR = $CREATOR$ } + } + 1 = { + create_artifact_sculpture_religious_effect = { OWNER = $OWNER$ CREATOR = $CREATOR$ } + } + 1 = { + create_artifact_pedestal_bible_effect = { OWNER = $OWNER$ CREATOR = $CREATOR$ } + } + 1 = { + create_artifact_pedestal_thurible_effect = { OWNER = $OWNER$ CREATOR = $CREATOR$ } + } + 1 = { + create_artifact_pedestal_situla_effect = { OWNER = $OWNER$ CREATOR = $CREATOR$ } + } + 1 = { + create_artifact_pedestal_crozier_effect = { OWNER = $OWNER$ CREATOR = $CREATOR$ } + } + } + if = { # Makes a regular character artifact if you don't have a Royal Court + limit = { + has_royal_court = no + } + scope:newly_created_artifact = { reforge_artifact = { type = miscellaneous } } + } + } +} + +# Called from wars on_white_peace +pam_miles_christi_white_peace_effect = { + scope:defender = { + if = { + limit = { + rite = { rite_has_parameter = tenet_miles_christi_white_peace_defender_bonus } + scope:attacker = { + faith = scope:defender.faith + } + } + add_piety = { + value = medium_piety_gain + multiply = scope:attacker.primary_title.tier + multiply = scope:defender.primary_title.tier + } + change_spiritual_fulfillment = medium_spiritual_fulfillment_value + add_legitimacy = { + value = medium_legitimacy_gain + multiply = scope:attacker.primary_title.tier + multiply = scope:defender.primary_title.tier + } + } + } +} +# Both on_combat_end_loser and on_combat_end_winner fire this +pam_miles_christi_fulfillment_from_combat_effect = { + if = { + limit = { + rite = { rite_has_parameter = tenet_miles_christi_combat_fulfillment } + } + send_interface_toast = { + title = successful_battles_and_sieges_give_sp_toast + left_icon = root + change_spiritual_fulfillment = minor_spiritual_fulfillment_value + } + } +} + +# Called from on_combat_end_winner in the scope of the winning combat side. +pam_miles_christi_holy_weapon_victory_effect = { + if = { + limit = { + exists = enemy_side.side_primary_participant + } + enemy_side.side_primary_participant = { + save_temporary_scope_as = pam_holy_weapon_enemy + } + every_side_commander = { + limit = { + rite = { rite_has_parameter = tenet_miles_christi_holy_weapon_blessing } + NOT = { faith.religion = scope:pam_holy_weapon_enemy.faith.religion } + } + every_character_artifact = { + limit = { pam_holy_weapon_trigger = yes } + pam_miles_christi_holy_weapon_gain_victory_effect = yes + } + } + } +} + +# Artifact scope. Tallies one holy victory and steps up the blessing when a threshold is crossed. +pam_miles_christi_holy_weapon_gain_victory_effect = { + if = { + limit = { NOT = { has_variable = pam_holy_weapon_victories_var } } + set_variable = { + name = pam_holy_weapon_victories_var + value = 1 + } + } + else = { + change_variable = { + name = pam_holy_weapon_victories_var + add = 1 + } + } + + if = { + limit = { + NOT = { has_variable = pam_holy_weapon_blessing_var } + var:pam_holy_weapon_victories_var >= 5 + } + set_variable = { + name = pam_holy_weapon_blessing_var + value = 1 + } + pam_miles_christi_holy_weapon_blessing_effect = { MODIFIER = pam_holy_weapon_1_artifact_modifier } + } + else_if = { + limit = { + has_variable = pam_holy_weapon_blessing_var + var:pam_holy_weapon_blessing_var = 1 + var:pam_holy_weapon_victories_var >= 15 + } + change_variable = { + name = pam_holy_weapon_blessing_var + add = 1 + } + pam_miles_christi_holy_weapon_blessing_effect = { MODIFIER = pam_holy_weapon_2_artifact_modifier } + } + else_if = { + limit = { + has_variable = pam_holy_weapon_blessing_var + var:pam_holy_weapon_blessing_var = 2 + var:pam_holy_weapon_victories_var >= 30 + } + change_variable = { + name = pam_holy_weapon_blessing_var + add = 1 + } + pam_miles_christi_holy_weapon_blessing_effect = { MODIFIER = pam_holy_weapon_3_artifact_modifier } + } + else_if = { + limit = { + has_variable = pam_holy_weapon_blessing_var + var:pam_holy_weapon_blessing_var = 3 + var:pam_holy_weapon_victories_var >= 50 + } + change_variable = { + name = pam_holy_weapon_blessing_var + add = 1 + } + pam_miles_christi_holy_weapon_blessing_effect = { MODIFIER = pam_holy_weapon_4_artifact_modifier } + } +} + +# Artifact scope +# MODIFIER = the artifact modifier for the tier being reached +pam_miles_christi_holy_weapon_blessing_effect = { + save_temporary_scope_as = pam_holy_weapon + add_artifact_modifier = $MODIFIER$ + artifact_owner ?= { + send_interface_toast = { + type = event_toast_effect_good + title = pam_holy_weapon_blessing_toast + desc = pam_holy_weapon_blessing_toast_desc + left_icon = this + right_icon = scope:pam_holy_weapon + show_as_tooltip = { + scope:pam_holy_weapon = { + add_artifact_modifier = $MODIFIER$ + } + } + } + } +} + +pam_pursuit_of_power_war_victory_fulfillment_effect = { + scope:winner = { + if = { + limit = { + has_personal_tenet_flag = tenet_pursuit_of_power_war_victory_fulfillment + scope:war.casus_belli = { + any_target_title = { is_landless_type_title = no } + } + } + send_interface_toast = { + title = pam_pursuit_of_power_war_victory_toast + left_icon = root + change_spiritual_fulfillment = medium_spiritual_fulfillment_value + } + } + } +} + +# Only rewards paying for someone else's freedom in gold; self-ransoms and favour settlements do not count. +pam_philanthropia_ransom_payer_effect = { + scope:payer = { + if = { + limit = { + has_personal_tenet_flag = tenet_philanthropia_ransom_captives + this != scope:prisoner + pam_philanthropia_ransom_gold_value > 0 + } + send_interface_toast = { + title = pam_philanthropia_ransom_toast + left_icon = scope:prisoner + add_piety = pam_philanthropia_ransom_piety_value + change_spiritual_fulfillment = pam_philanthropia_ransom_fulfillment_value + } + } + } +} + +# Rewards releasing or exiling a prisoner outright; anything extracted from them first makes it a bargain. +tenet_benevolent_governance_clemency_effect = { + scope:puppet_or_actor = { + if = { + limit = { + has_personal_tenet_flag = tenet_benevolent_governance_clemency_fulfillment + OR = { + tenet_benevolent_governance_unconditional_release_trigger = yes + AND = { + scope:banish = yes + has_execute_reason = scope:recipient + } + } + } + if = { + limit = { is_ai = no } + send_interface_toast = { + type = event_generic_good + title = benevolent_governance_clemency_fulfillment_toast + left_icon = scope:puppet_or_actor + right_icon = scope:recipient + change_spiritual_fulfillment = tenet_benevolent_governance_clemency_fulfillment_value + } + } + else = { + change_spiritual_fulfillment = tenet_benevolent_governance_clemency_fulfillment_value + } + } + } +} + +pam_be_fruitful_fruitful_upbringing_effect = { + if = { + limit = { + exists = scope:father + OR = { + scope:mother ?= { has_personal_tenet_flag = tenet_be_fruitful_and_multiply_fruitful_upbringing } + scope:father ?= { has_personal_tenet_flag = tenet_be_fruitful_and_multiply_fruitful_upbringing } + } + } + scope:child = { + if = { + limit = { + scope:mother ?= { has_relation_soulmate = scope:father } + } + add_character_modifier = { + modifier = tenet_be_fruitful_and_multiply_fruitful_upbringing_devoted + years = 16 + } + } + else_if = { + limit = { + scope:mother ?= { + OR = { + has_relation_lover = scope:father + has_relation_best_friend = scope:father + } + } + } + add_character_modifier = { + modifier = tenet_be_fruitful_and_multiply_fruitful_upbringing_close + years = 16 + } + } + else_if = { + limit = { + scope:mother ?= { + OR = { + has_relation_friend = scope:father + opinion = { + target = scope:father + value >= medium_positive_opinion + } + } + } + } + add_character_modifier = { + modifier = tenet_be_fruitful_and_multiply_fruitful_upbringing_fond + years = 16 + } + } + } + } +} + +# PAM Scholasticism tenet effect +pam_tenet_scholasticism_university_bonus_effect = { + if = { + limit = { + rite = { rite_has_parameter = tenet_scholasticism_university_bonus } + } + add_character_modifier = { + modifier = tenet_scholasticism_modifier + years = 20 + } + } +} + +pam_pentarchy_circuit_entourage_effect = { + if = { + limit = { exists = involved_activity } + save_temporary_scope_as = pam_pentarchy_circuit_pilgrim + involved_activity = { + every_attending_character = { + limit = { this != scope:pam_pentarchy_circuit_pilgrim } + custom = pam_pentarchy_circuit_entourage_tt + hidden_effect = { + local_court_type_skill_point_effect = { + PROVINCE = scope:pam_pentarchy_circuit_pilgrim.location + } + } + } + } + } +} + +# Pentarchy tenet is already checked when pilgrimage_additional_reward_effect fires this +pam_pentarchy_pilgrim_circuit_effect = { + save_temporary_scope_as = pam_pentarchy_pilgrim + if = { + limit = { + NOT = { has_character_flag = pam_pentarchy_circuit_completed } + exists = scope:pam_pentarchy_pilgrim.location.barony + faith = { + any_holy_site_barony = { this = scope:pam_pentarchy_pilgrim.location.barony } + } + } + scope:pam_pentarchy_pilgrim.location.barony = { + save_temporary_scope_as = pam_pentarchy_see + } + if = { + limit = { + OR = { + NOT = { has_variable_list = pam_pentarchy_sees_visited } + NOT = { + is_target_in_variable_list = { + name = pam_pentarchy_sees_visited + target = scope:pam_pentarchy_see + } + } + } + } + add_to_variable_list = { + name = pam_pentarchy_sees_visited + target = scope:pam_pentarchy_see + } + + # Recount vs current holy sites so a conversion since visiting self-corrects + set_variable = { + name = pam_pentarchy_sees_total + value = 0 + } + set_variable = { + name = pam_pentarchy_sees_count + value = 0 + } + faith = { + every_holy_site = { + limit = { exists = holy_site_barony } + holy_site_barony = { save_temporary_scope_as = pam_pentarchy_counted_see } + scope:pam_pentarchy_pilgrim = { + change_variable = { + name = pam_pentarchy_sees_total + add = 1 + } + if = { + limit = { + is_target_in_variable_list = { + name = pam_pentarchy_sees_visited + target = scope:pam_pentarchy_counted_see + } + } + change_variable = { + name = pam_pentarchy_sees_count + add = 1 + } + } + } + } + } + + if = { + limit = { + # The log entry's description is drawn before the counters above are set + has_variable = pam_pentarchy_sees_total + var:pam_pentarchy_sees_total > 0 + var:pam_pentarchy_sees_count >= var:pam_pentarchy_sees_total + } + add_character_flag = pam_pentarchy_circuit_completed + send_interface_toast = { + type = event_toast_text_and_effect_good + title = pam_pentarchy_circuit_completed_toast + desc = pam_pentarchy_circuit_completed_toast_desc + left_icon = scope:pam_pentarchy_pilgrim + add_character_modifier = { + modifier = pam_pilgrim_of_every_holy_site_modifier + } + add_piety = massive_piety_gain + change_spiritual_fulfillment = major_spiritual_fulfillment_value + if = { + limit = { has_personal_tenet_flag = tenet_pentarchy_pilgrim_circuit_companions } + pam_pentarchy_circuit_entourage_effect = yes + } + } + } + else = { + send_interface_message = { + type = event_generic_good_with_text + title = pam_pentarchy_see_visited_message + desc = pam_pentarchy_see_visited_message_desc + left_icon = scope:pam_pentarchy_pilgrim + add_piety = medium_piety_gain + change_spiritual_fulfillment = minor_spiritual_fulfillment_value + if = { + limit = { has_personal_tenet_flag = tenet_pentarchy_pilgrim_circuit_companions } + pam_pentarchy_circuit_entourage_effect = yes + } + } + } + } + } +} + +pam_tenet_scholasticism_yearly_effect = { + random = { + chance = { + value = 5 + if = { + limit = { + is_ai = no + } + add = 5 + } + if = { + limit = { + learning >= 30 + } + add = 2 + } + if = { + limit = { + learning >= 40 + } + add = 3 + } + if = { + limit = { + piety_level >= 4 + } + add = 2 + } + if = { + limit = { + piety_level >= 5 + } + add = 3 + } + if = { + limit = { + num_of_known_languages >= 3 + } + add = 2 + } + if = { + limit = { + num_of_known_languages >= 5 + } + add = 3 + } + } + send_interface_toast = { + type = event_toast_effect_good + title = pam_tenet_scholasticism_toast_title + left_icon = root + add_character_modifier = { + modifier = tenet_scholasticism_modifier + years = 20 + } + } + } +} + +pam_tenet_scholasticism_studium_effect = { + save_scope_as = studium_master + current_travel_plan ?= { + random_entourage_character = { + limit = { + NOT = { this = scope:studium_master } + is_physically_able_ai_adult = yes + ep1_is_valid_character_for_inspiration_trigger = yes + } + random = { + chance = pam_scholasticism_studium_inspiration_chance_value + create_inspiration = book_inspiration + save_scope_as = pam_studium_scholar + scope:studium_master = { + send_interface_toast = { + type = event_toast_effect_good + title = pam_tenet_scholasticism_studium_toast_title + desc = pam_tenet_scholasticism_studium_toast_desc + left_icon = scope:pam_studium_scholar + } + } + } + } + } +} +add_scholar_trait_or_xp_effect = { + if = { + limit = { + NOT = { has_trait = lifestyle_scholar } + } + add_trait = lifestyle_scholar + } + else = { + add_trait_xp = { + trait = lifestyle_scholar + value = $VALUE$ + } + } +} + +save_most_suitable_monastic_leader_effect = { + #Patronized by puppet_or_actor + random_faith_holy_order = { + limit = { + take_the_vows_valid_monastic_order_trigger = { CHARACTER = scope:puppet_or_actor } + holy_order_patron = scope:puppet_or_actor + } + leader = { + save_scope_as = archabbot + } + } + #leases from puppet_or_actor + if = { + limit = { + NOT = { + exists = scope:archabbot + } + } + random_faith_holy_order = { + limit = { + take_the_vows_valid_monastic_order_trigger = { CHARACTER = scope:puppet_or_actor } + any_leased_title = { + county.holder ?= scope:puppet_or_actor + } + } + leader = { + save_scope_as = archabbot + } + } + } + #patronized by puppet_or_actor's superior + if = { + limit = { + NOT = { + exists = scope:archabbot + } + } + random_faith_holy_order = { + limit = { + take_the_vows_valid_monastic_order_trigger = { CHARACTER = scope:puppet_or_actor } + holy_order_patron = { + is_liege_or_above_of = scope:puppet_or_actor + } + } + leader = { + save_scope_as = archabbot + } + } + } + #in same realm as puppet_or_actor + if = { + limit = { + NOT = { + exists = scope:archabbot + } + } + random_faith_holy_order = { + limit = { + take_the_vows_valid_monastic_order_trigger = { CHARACTER = scope:puppet_or_actor } + any_leased_title = { + county.holder.top_liege ?= scope:puppet_or_actor.top_liege + } + } + leader = { + save_scope_as = archabbot + } + } + } + #in diplo range of puppet_or_actor + if = { + limit = { + NOT = { + exists = scope:archabbot + } + } + random_faith_holy_order = { + limit = { + take_the_vows_valid_monastic_order_trigger = { CHARACTER = scope:puppet_or_actor } + leader = { + in_diplomatic_range = scope:puppet_or_actor + } + } + leader = { + save_scope_as = archabbot + } + } + } + #any order + if = { + limit = { + NOT = { + exists = scope:archabbot + } + } + random_faith_holy_order = { + limit = { + take_the_vows_valid_monastic_order_trigger = { CHARACTER = scope:puppet_or_actor } + } + leader = { + save_scope_as = archabbot + } + } + } +} + +# Saeculum Obscurum ends - time to get divorced +pam_the_christian_church_saeculum_obscurum_end_clergy_divorce_effect = { + every_situation_participant = { + limit = { + is_clergy = yes + rite = { rite_has_doctrine = doctrine_clerical_marriage_disallowed } + } + hidden_effect = { + if = { + limit = { + is_married = yes + is_ai = yes + } + every_spouse = { + limit = { is_ai = yes } + save_temporary_scope_as = saeculum_clergy_divorcee + less_verbose_divorce_effect = { + DIVORCER = prev + DIVORCEE = scope:saeculum_clergy_divorcee + } + } + } + if = { + limit = { exists = betrothed } + break_betrothal = betrothed + } + } + } +} + +#The Christian Church phase start effect - +# Phase on_start runs with situation as root; every_player does not iterate players from that context. Iterate situation participants instead (cf. the_great_steppe phase on_start). +the_christian_church_fire_event_for_participant_players_effect = { + if = { + limit = { + NOT = { has_global_variable = pam_skip_tcc_phase_start_event } + } + every_player = { + limit = { + # Saeculum Obscurum on_start fires the schism start event + trigger_if = { + limit = { + situation:the_christian_church ?= { situation_current_phase = saeculum_obscurum } + } + situation:the_christian_church ?= { + NOT = { has_variable = pam_great_schism_status } + } + } + OR = { + government_has_flag = government_is_theocracy + years_from_game_start >= 1 + } + any_character_situation = { + this = situation:the_christian_church + } + } + trigger_event = $EVENT$ + } + } +} + +#The Christian Church situation effects +the_christian_church_fire_correct_phase_start_event_for_player_effect = { + if = { + limit = { + is_ai = no + is_player_tutorial_character = no + NOT = { has_global_variable = pam_skip_tcc_phase_start_event } + OR = { + government_has_flag = government_is_theocracy + years_from_game_start >= 1 + } + } + save_scope_as = situation_participant + situation:the_christian_church = { + switch = { + trigger = situation_current_phase + fragile_unity = { + scope:situation_participant = { + trigger_event = pam_the_christian_church.0051 + } + } + saeculum_obscurum = { + scope:situation_participant = { + trigger_event = pam_the_christian_church.0052 + } + } + conversion_phase = { + scope:situation_participant = { + trigger_event = pam_the_christian_church.0053 + } + } + reform_phase = { + scope:situation_participant = { + trigger_event = pam_the_christian_church.0054 + } + } + investiture_crisis = { + scope:situation_participant = { + trigger_event = pam_the_christian_church.0055 + } + } + crusade_phase = { + scope:situation_participant = { + trigger_event = pam_the_christian_church.0056 + } + } + concord = { + scope:situation_participant = { + trigger_event = pam_the_christian_church.0057 + } + } + } + } + } +} + +pam_remove_forbidden_personal_tenet_secret_if_invalid_effect = { + if = { + limit = { + any_secret = { type = secret_forbidden_personal_tenet } + NOT = { pam_has_forbidden_personal_tenet_trigger = yes } + } + every_secret = { + type = secret_forbidden_personal_tenet + remove_secret = yes + } + } +} + +# Faith scope +pam_faith_cleanup_forbidden_personal_tenet_secrets_effect = { + hidden_effect = { + every_faith_character = { + pam_remove_forbidden_personal_tenet_secret_if_invalid_effect = yes + } + } +} + +# Faith scope. TENET is the tenet just prohibited +pam_faith_grant_forbidden_personal_tenet_secrets_effect = { + hidden_effect = { + every_faith_character = { + limit = { + has_personal_tenet = $TENET$ + NOT = { any_secret = { type = secret_forbidden_personal_tenet } } + } + on_personal_tenet_gain_secret_gain_effect = yes + } + } +} + +on_personal_tenet_gain_secret_gain_effect = { + # AI on_personal_tenet_gain is delayed, so the prohibited tenet may already be gone + if = { + limit = { pam_has_forbidden_personal_tenet_trigger = yes } + send_interface_toast = { + title = on_personal_tenet_gain_secret_gain_effect_tt + left_icon = root + add_secret = { + type = secret_forbidden_personal_tenet + target = this + } + if = { + limit = { exists = var:tenet_evangelized_by } + var:tenet_evangelized_by = { save_temporary_scope_as = tenet_evangelizer } + every_secret = { + type = secret_forbidden_personal_tenet + reveal_to = scope:tenet_evangelizer + } + remove_variable = tenet_evangelized_by + } + } + } +} + +# Called from five_year_playable_pulse. Root is the character. +pam_ai_personal_tenet_pulse_effect = { + if = { + limit = { + is_physically_able_ai = yes + } + + # Phase 0: cardinals may hold beliefs their rite prohibits, so a new pontiff can arrive carrying one + # Ahead of Phase 1 so the freed slot refills this pulse; on_personal_tenet_loss clears the secret + if = { + limit = { + pam_holds_college_elected_church_seat_trigger = yes + pam_has_forbidden_personal_tenet_trigger = yes + } + faith.main_rite = { save_temporary_scope_as = pam_pontiff_rite } + while = { + count = 8 + limit = { pam_has_forbidden_personal_tenet_trigger = yes } + random_personal_tenet = { + limit = { + scope:pam_pontiff_rite = { + has_tenet_status = { + tenet = prev + status = prohibited + } + } + } + root = { remove_personal_tenet = prev } + } + } + } + + # Phase 1: fill every empty personal tenet slot. No chance gate - empty slots are wasted SF and immersion. + # 8 = safety upper bound on slot cap (base 1 + up to ~5 from piety levels, with headroom). + while = { + count = 8 + limit = { + free_personal_tenet_slots > 0 + any_desired_tenet = { + only_positive = yes + threshold = 1 + selection_count = 97 + save_temporary_scope_as = pam_personal_tenet_candidate + NOT = { + root = { + any_personal_tenet = { + this = scope:pam_personal_tenet_candidate + } + } + } + OR = { + NOT = { + root.faith.main_rite = { + has_tenet_status = { + tenet = scope:pam_personal_tenet_candidate + status = prohibited + } + } + } + root = { pam_ai_can_consider_forbidden_personal_tenet_trigger = yes } + } + } + } + + random_desired_tenet = { + only_positive = yes + threshold = 1 + selection_count = 97 + limit = { + save_temporary_scope_as = pam_personal_tenet_candidate + NOT = { + root = { + any_personal_tenet = { + this = scope:pam_personal_tenet_candidate + } + } + } + OR = { + NOT = { + root.faith.main_rite = { + has_tenet_status = { + tenet = scope:pam_personal_tenet_candidate + status = prohibited + } + } + } + root = { pam_ai_can_consider_forbidden_personal_tenet_trigger = yes } + } + } + root = { set_personal_tenet = prev } + } + } + + # Phase 2: chance-gated swap, only when there are no free slots left to fill. + if = { + limit = { + free_personal_tenet_slots <= 0 + any_desired_tenet = { + only_positive = yes + threshold = 1 + selection_count = 97 + save_temporary_scope_as = pam_personal_tenet_candidate + NOT = { + root = { + any_personal_tenet = { + this = scope:pam_personal_tenet_candidate + } + } + } + OR = { + NOT = { + root.faith.main_rite = { + has_tenet_status = { + tenet = scope:pam_personal_tenet_candidate + status = prohibited + } + } + } + root = { pam_ai_can_consider_forbidden_personal_tenet_trigger = yes } + } + } + } + + random = { + chance = 30 + modifier = { + add = 15 + has_trait = zealous + } + modifier = { + add = -15 + has_trait = cynical + } + modifier = { + add = { + value = ai_zeal + divide = 5 + } + } + modifier = { + add = { + value = ai_boldness + divide = 5 + } + } + + # Pick the new tenet - Random of any positive-SF known tenet, not strictly the best. + random_desired_tenet = { + only_positive = yes + threshold = 1 + selection_count = 97 + limit = { + save_temporary_scope_as = pam_personal_tenet_candidate + NOT = { + root = { + any_personal_tenet = { + this = scope:pam_personal_tenet_candidate + } + } + } + OR = { + NOT = { + root.faith.main_rite = { + has_tenet_status = { + tenet = scope:pam_personal_tenet_candidate + status = prohibited + } + } + } + root = { pam_ai_can_consider_forbidden_personal_tenet_trigger = yes } + } + } + root = { force_set_personal_tenet = prev } + } + } + } + } +} + +conversion_tenet_acts_of_the_apostles_effect = { + scope:puppet_or_actor = { + if = { + limit = { # Legitimacy if core to the faith + rite = { + rite_has_parameter = tenet_acts_of_apostles_legitimacy_from_converts + } + is_valid_for_legitimacy_change = yes + } + send_interface_toast = { + title = conversion_tenet_acts_of_the_apostles_effect_legitimacy_tt + left_icon = scope:puppet_or_actor + add_legitimacy = minor_legitimacy_gain + } + } + if = { + limit = { # SP if personal tenet - converting the mighty pays more + has_personal_tenet_flag = tenet_acts_of_apostles_fulfillment_from_converts + scope:recipient ?= { is_landed = yes } + } + send_interface_toast = { + title = conversion_tenet_acts_of_the_apostles_effect_sp_tt + left_icon = scope:puppet_or_actor + change_spiritual_fulfillment = major_spiritual_fulfillment_value + } + } + else_if = { + limit = { + has_personal_tenet_flag = tenet_acts_of_apostles_fulfillment_from_converts + } + send_interface_toast = { + title = conversion_tenet_acts_of_the_apostles_effect_sp_tt + left_icon = scope:puppet_or_actor + change_spiritual_fulfillment = minor_spiritual_fulfillment_value + } + } + if = { + limit = { # Piety if core to the faith, scaled steeply by the convert's rank + rite = { rite_has_parameter = tenet_acts_of_apostles_piety_from_converts } + scope:recipient ?= { highest_held_title_tier >= tier_barony } + } + send_interface_toast = { + title = conversion_tenet_acts_of_the_apostles_effect_piety_tt + left_icon = scope:puppet_or_actor + add_piety = pam_acts_conversion_piety_value + } + } + } + if = { + limit = { + scope:is_puppet_action ?= yes + scope:puppet_or_actor = { + rite = { rite_has_parameter = tenet_acts_of_apostles_legitimacy_from_converts } + is_valid_for_legitimacy_change = yes + } + } + scope:actor = { + send_interface_toast = { + title = conversion_tenet_acts_of_the_apostles_effect_legitimacy_tt_puppeteer + left_icon = scope:puppet_or_actor + } + } + } + if = { + limit = { + scope:is_puppet_action ?= yes + scope:puppet_or_actor = { has_personal_tenet_flag = tenet_acts_of_apostles_fulfillment_from_converts } + } + scope:actor = { + send_interface_toast = { + title = conversion_tenet_acts_of_the_apostles_effect_sp_tt_puppeteer + left_icon = scope:puppet_or_actor + } + } + } +} + +pam_tax_nonbelievers_conversion_concession_effect = { + if = { + limit = { + scope:tax_nonbelievers_conversion_concession = yes + } + scope:puppet_or_actor = { + pay_short_term_gold = { + target = scope:recipient + gold = medium_gold_value + } + send_interface_toast = { + type = event_toast_effect_good + title = pam_tax_nonbelievers_conversion_concession_toast + left_icon = scope:recipient + right_icon = scope:puppet_or_actor + } + } + } +} + +conversion_tenet_mendicant_preachers_effect = { + scope:puppet_or_actor = { + if = { + limit = { + has_personal_tenet_flag = tenet_mendicant_preachers_conversion_fulfillment + } + send_interface_toast = { + title = conversion_tenet_mendicant_preachers_effect_sp_tt + left_icon = scope:puppet_or_actor + change_spiritual_fulfillment = minor_spiritual_fulfillment_value + } + } + } + if = { + limit = { + scope:is_puppet_action ?= yes + scope:puppet_or_actor = { has_personal_tenet_flag = tenet_mendicant_preachers_conversion_fulfillment } + } + scope:actor = { + send_interface_toast = { + title = conversion_tenet_mendicant_preachers_effect_sp_tt_puppeteer + left_icon = scope:puppet_or_actor + } + } + } +} + +pam_tax_nonbelievers_conversion_fulfillment_effect = { + if = { + limit = { + has_personal_tenet_flag = tax_nonbelievers_fulfillment_from_conversion + } + change_spiritual_fulfillment = minor_spiritual_fulfillment_value + } +} + +ora_et_labora_gardener_gain_effect = { + if = { + limit = { + has_personal_tenet_flag = tenet_ora_et_labora_gardener_trait + NOT = { has_trait = lifestyle_gardener } + } + add_trait = lifestyle_gardener + } +} + +pam_tenet_takamin_hunter_gain_effect = { + if = { + limit = { + has_personal_tenet_flag = tenet_takamin_hunter_trait + NOT = { has_trait = lifestyle_hunter } + } + add_trait = lifestyle_hunter + } +} + +pam_tenet_religious_law_scholar_gain_effect = { + if = { + limit = { + scope:tenet = tenet:tenet_religious_legal_pronouncements + has_personal_tenet_flag = tenet_religious_law_scholar_trait + } + if = { + limit = { + NOT = { has_trait = lifestyle_scholar } + } + add_stress = medium_stress_gain + add_trait = lifestyle_scholar + } + } +} + +pam_tenet_filial_piety_education_completion_reward_effect = { + if = { + limit = { + NOT = { has_character_flag = pam_filial_piety_education_rewarded } + exists = scope:educator + scope:educator = { + is_parent_of = root + has_personal_tenet_flag = tenet_filial_piety_education_completion_reward + } + } + add_character_flag = pam_filial_piety_education_rewarded + scope:educator = { + send_interface_toast = { + type = event_toast_effect_good + title = pam_filial_piety_education_completion_parent_toast + left_icon = scope:educator + right_icon = root + add_piety = major_piety_value + change_spiritual_fulfillment = major_spiritual_fulfillment_value + } + } + send_interface_toast = { + type = event_toast_effect_good + title = pam_filial_piety_education_completion_child_toast + left_icon = root + right_icon = scope:educator + add_piety = major_piety_value + if = { + limit = { is_playable_character = yes } + change_spiritual_fulfillment = major_spiritual_fulfillment_value + } + } + } +} + +# An activity already under way was planned without the vow, so its reward is forfeit +pam_vows_of_poverty_block_ongoing_activity_effect = { + if = { + limit = { + has_personal_tenet_flag = tenet_vows_of_poverty_humble_host + exists = involved_activity + involved_activity.activity_host = root + } + involved_activity = { + set_variable = pam_vows_of_poverty_completion_piety_paid + } + } +} + +pam_vows_of_poverty_host_completion_piety_effect = { + if = { + limit = { + this = scope:host + scope:host = { + has_personal_tenet_flag = tenet_vows_of_poverty_humble_host + } + scope:activity = { + NOT = { has_variable = pam_vows_of_poverty_completion_piety_paid } + } + } + scope:activity = { + set_variable = pam_vows_of_poverty_completion_piety_paid + scope:host = { + send_interface_toast = { + type = event_toast_effect_good + title = pam_vows_of_poverty_activity_completion_piety_toast + left_icon = scope:host + add_piety = pam_vows_of_poverty_host_piety_value + } + } + } + } +} + +hedonistic_reveler_gain_effect = { + if = { + limit = { + has_personal_tenet_flag = tenet_hedonistic_reveler_trait + NOT = { has_trait = lifestyle_reveler } + } + add_trait = lifestyle_reveler + } +} + +pam_tenet_mountain_worship_rough_terrain_expert_gain_effect = { + if = { + limit = { + has_personal_tenet_flag = tenet_mountain_worship_rough_terrain_expert_trait + NOT = { has_trait = rough_terrain_expert } + } + add_trait = rough_terrain_expert + } +} + +pam_tenet_mountain_worship_hike_spiritual_fulfillment_effect = { + if = { + limit = { + has_personal_tenet_flag = tenet_mountain_worship_hike + location = { + OR = { + terrain = mountains + terrain = desert_mountains + } + } + } + custom_tooltip = pam_tenet_mountain_worship_hike_spiritual_fulfillment_tt + change_spiritual_fulfillment = medium_spiritual_fulfillment_value + } +} + +hedonistic_obesity_modifier_sync_effect = { + if = { + limit = { + current_weight >= overweight_value + has_personal_tenet_flag = tenet_hedonistic_obesity_fulfillment + } + if = { + limit = { + NOT = { has_character_modifier = tenet_hedonistic_obese_modifier } + } + add_character_modifier = { + modifier = tenet_hedonistic_obese_modifier + } + } + } + else_if = { + limit = { + has_character_modifier = tenet_hedonistic_obese_modifier + } + remove_character_modifier = tenet_hedonistic_obese_modifier + } +} + +hedonistic_feast_gout_risk_effect = { + if = { + limit = { + has_personal_tenet_flag = tenet_hedonistic_feast_gout_risk + current_weight >= overweight_value + can_contract_disease_trigger = { DISEASE = gout_ridden } + } + random_list = { + 75 = {} + 25 = { + send_interface_toast = { + type = event_toast_effect_bad + title = hedonistic_feast_gout_risk_toast + left_icon = root + show_as_tooltip = { add_trait_force_tooltip = gout_ridden } + hidden_effect = { + contract_disease_effect = { DISEASE = gout_ridden TREATMENT_EVENT = no } + } + } + } + } + } +} + +asceticism_inappetetic_gain_effect = { + if = { + limit = { + has_personal_tenet_flag = tenet_asceticism_inappetetic_trait + NOT = { has_trait = inappetetic } + } + add_trait = inappetetic + } +} + +# Traits granted by a personal tenet are permanent +mortification_holy_scars_gain_effect = { + if = { + limit = { + has_personal_tenet_flag = tenet_mortification_holy_scars + NOT = { has_trait = scarred } + } + add_trait = scarred + } +} + +# Revel in Pain belongs to Exaltation of Pain +pam_mortify_flesh_scourge_effect = { + if = { + limit = { has_personal_tenet_flag = tenet_mortification_revel_bonus } + send_interface_toast = { + type = event_generic_good + title = pam_mortification_revel_toast + left_icon = root + if = { # If you don't have the trait, it's guaranteed + limit = { + NOT = { has_trait = flagellant } + } + add_trait = flagellant + } + change_spiritual_fulfillment = medium_spiritual_fulfillment_value + } + } + + if = { + limit = { has_personal_tenet_flag = tenet_mortification_holy_scars } + send_interface_toast = { + type = event_generic_good + title = pam_mortification_holy_scars_toast + left_icon = root + add_trait = scarred + add_trait_xp = { + trait = scarred + value = { integer_range = { min = 10 max = 25 } } + } + } + } +} + +# Wounds cannot kill here: the player chose this from a decision. +pam_mortify_flesh_offering_effect = { + add_piety = massive_piety_value + change_spiritual_fulfillment = major_spiritual_fulfillment_value + stress_and_fulfillment_impact = { + flagellant = medium_stress_impact_loss + zealous = minor_stress_impact_loss + craven = medium_stress_impact_gain + content = medium_stress_impact_gain + } + increase_wounds_no_death_effect = { REASON = treatment } +} + +literalism_scholar_gain_effect = { + if = { + limit = { + has_personal_tenet_flag = tenet_literalism_scholar_trait + NOT = { has_trait = lifestyle_scholar } + } + add_trait = lifestyle_scholar + } +} + +scholasticism_scholar_gain_effect = { + if = { + limit = { + has_personal_tenet_flag = tenet_scholasticism_scholar_trait + NOT = { has_trait = lifestyle_scholar } + } + add_trait = lifestyle_scholar + } + else_if = { + limit = { + has_personal_tenet_flag = tenet_scholasticism_scholar_trait + } + add_trait_xp = { + trait = lifestyle_scholar + value = pam_scholasticism_scholar_xp_value + } + } +} + +unrelenting_faith_blademaster_gain_effect = { + if = { + limit = { + has_personal_tenet_flag = tenet_unrelenting_faith_blademaster_trait + NOT = { has_trait = lifestyle_blademaster } + } + add_trait = lifestyle_blademaster + } +} + +astrology_mystic_gain_effect = { + if = { + limit = { + has_personal_tenet_flag = tenet_astrology_mystic_trait + NOT = { has_trait = lifestyle_mystic } + } + add_trait = lifestyle_mystic + } +} + +anachoresis_mystic_gain_effect = { + if = { + limit = { + scope:tenet = tenet:tenet_anachoresis + has_personal_tenet_flag = tenet_anachoresis_mystic_trait + NOT = { has_trait = lifestyle_mystic } + } + add_trait = lifestyle_mystic + } +} + +pure_land_aggressive_attacker_gain_effect = { + if = { + limit = { + scope:tenet = tenet:tenet_pure_land + has_personal_tenet_flag = tenet_pure_land_aggressive_attacker_trait + NOT = { has_trait = aggressive_attacker } + } + add_trait = aggressive_attacker + } +} + +pure_land_prestige_level_loss_effect = { + if = { + limit = { + scope:tenet = tenet:tenet_pure_land + has_personal_tenet_flag = tenet_pure_land_prestige_level_loss + } + add_prestige_level = -1 + } +} + +# Miles Christi personal tenet: the soldier of Christ takes up the mantle of a Holy Warrior +miles_christi_holy_warrior_gain_effect = { + if = { + limit = { + has_personal_tenet_flag = tenet_miles_christi_holy_warrior_trait + NOT = { has_trait = holy_warrior } + } + add_trait = holy_warrior + } +} + +# PAM - Reincarnation: claim a forebear's personality trait. +# Opposing traits are replaced first; otherwise the least-fulfilling personality trait is replaced. +pam_claim_remembered_personality_trait_effect = { + if = { + limit = { + $TRAIT$ = { + any_opposite_trait = { + root = { has_trait = prev } + } + } + } + $TRAIT$ = { + every_opposite_trait = { + limit = { + root = { has_trait = prev } + } + root = { remove_trait = prev } + } + } + } + else_if = { + limit = { number_of_personality_traits >= 1 } + ordered_character_trait = { + limit = { has_trait_category = personality } + order_by = pam_recall_worst_personality_order_value + save_scope_as = pam_recall_replaced_personality + } + remove_trait = scope:pam_recall_replaced_personality + } + add_trait = $TRAIT$ + change_spiritual_fulfillment = medium_spiritual_fulfillment_value +} + +pam_great_project_contribution_catalyst_effect = { + if = { + limit = { + this != scope:owner + this != scope:founder + scope:owner ?= { + any_character_situation = { + situation_type = the_christian_church + } + } + OR = { + scope:great_project.great_project_type = great_project_type:pam_cathedral_01 + scope:great_project.great_project_type = great_project_type:pam_cathedral_02 + scope:great_project.great_project_type = great_project_type:pam_cathedral_03 + scope:great_project.great_project_type = great_project_type:pam_mass_rite_conversion + } + } + random_character_situation = { + limit = { situation_type = the_christian_church } + switch = { + trigger = scope:great_project.great_project_type + great_project_type:pam_cathedral_01 = { + if = { + limit = { situation_top_has_catalyst = catalyst_great_project_cathedral_contribution } + trigger_situation_catalyst = catalyst_great_project_cathedral_contribution + } + } + great_project_type:pam_cathedral_02 = { + if = { + limit = { situation_top_has_catalyst = catalyst_great_project_cathedral_contribution } + trigger_situation_catalyst = catalyst_great_project_cathedral_contribution + } + } + great_project_type:pam_cathedral_03 = { + if = { + limit = { situation_top_has_catalyst = catalyst_great_project_cathedral_contribution } + trigger_situation_catalyst = catalyst_great_project_cathedral_contribution + } + } + great_project_type:pam_mass_rite_conversion = { + if = { + limit = { situation_top_has_catalyst = catalyst_great_project_mass_rite_conversion_contribution } + trigger_situation_catalyst = catalyst_great_project_mass_rite_conversion_contribution + } + } + } + } + } +} + +pam_levy_the_tithes_decision_effects = { + every_vassal = { + limit = { + OR = { + government_has_flag = government_is_theocracy + government_has_flag = government_is_ecclesiastical + } + } + custom = every_theocratic_vassal_tt + pay_short_term_gold = { + target = root + gold = minor_gold_value + } + } + if = { + limit = { exists = cp:councillor_court_chaplain } + cp:councillor_court_chaplain = { + progress_towards_rival_effect = { + CHARACTER = root + REASON = rival_levied_tithes + OPINION = default_rival_opinion + } + } + } +} + +#The flag is set in give_cardinal_order_interaction this provides the appropriate event option to accept or deny, along with communicating to players (via toast) who rule the county(s) affected by the below modifiers that a change has taken place +pam_choose_cardinal_order_switch_scripted_effect = { + switch = { + trigger = yes + scope:cardinal_improve_development ?= { + capital_county.clerical_region_title = { + every_county_in_clerical_region = { + custom = cardinal_order_improve_development + limit = { + faith = scope:recipient.faith + } + add_county_modifier = { + modifier = pam_cardinal_order_improve_development_modifier + years = 10 + } + holder = { + if = { + limit = { + is_ai = no + } + add_to_list = county_holders + } + } + } + } + } + + scope:cardinal_convert_faith ?= { + capital_county ?= { + clerical_region_title ?= { + every_county_in_clerical_region = { + custom = cardinal_order_convert_faith + limit = { + pam_cardinal_order_convert_faith_in_region_county_trigger = { CARDINAL = scope:recipient } + } + add_county_modifier = { + modifier = pam_cardinal_order_convert_faith_modifier + years = 10 + } + holder = { + if = { + limit = { + is_ai = no + } + add_to_list = county_holders + } + } + } + if = { + limit = { + any_county_in_clerical_region = { + any_neighboring_county = { + pam_cardinal_order_convert_faith_neighboring_county_trigger = { CARDINAL = scope:recipient } + } + } + } + custom_tooltip = { + text = cardinal_order_convert_faith_neighboring + every_county_in_clerical_region = { + every_neighboring_county = { + limit = { + pam_cardinal_order_convert_faith_neighboring_county_trigger = { CARDINAL = scope:recipient } + NOT = { has_county_modifier = pam_cardinal_order_convert_faith_modifier } + } + add_county_modifier = { + modifier = pam_cardinal_order_convert_faith_modifier + years = 10 + } + holder = { + if = { + limit = { + is_ai = no + } + add_to_list = county_holders + } + } + } + } + } + } + } + } + } + + scope:cardinal_increase_control ?= { + capital_county.clerical_region_title = { + every_county_in_clerical_region = { + custom = cardinal_order_increase_control + limit = { + holder.top_liege.faith = scope:recipient.faith + } + add_county_modifier = { + modifier = pam_cardinal_order_increase_control_modifier + years = 10 + } + holder = { + if = { + limit = { + is_ai = no + } + add_to_list = county_holders + } + } + } + } + } + + scope:cardinal_accelerate_cultural_fascination ?= { + scope:puppet_or_actor.culture.culture_head = { + custom_tooltip = cardinal_order_accelerate_cultural_fascination + add_character_modifier = { + modifier = pam_cardinal_order_accelerate_cultural_fascination_modifier + years = 10 + } + if = { + limit = { + is_ai = no + } + add_to_list = county_holders + } + } + } + + scope:cardinal_improve_epidemic_resistance ?= { + capital_county.clerical_region_title = { + every_county_in_clerical_region = { + custom = cardinal_order_improve_epidemic_resistance + limit = { + NOT = { + has_county_modifier = pam_cardinal_order_improve_epidemic_resistance_modifier + } + faith = scope:recipient.faith + } + add_county_modifier = { + modifier = pam_cardinal_order_improve_epidemic_resistance_modifier + years = 10 + } + holder = { + if = { + limit = { + is_ai = no + } + add_to_list = county_holders + } + } + } + } + } + + scope:cardinal_improve_legitimacy ?= { + capital_county.clerical_region_title = { + every_county_in_clerical_region = { + custom = cardinal_order_improve_legitimacy + limit = { + holder.top_liege = { + has_legitimacy = yes + NOT = { + has_character_modifier = pam_cardinal_order_improve_legitimacy_modifier + } + faith = scope:recipient.faith + } + } + holder.top_liege = { + add_character_modifier = { + modifier = pam_cardinal_order_improve_legitimacy_modifier + years = 10 + } + if = { + limit = { + is_ai = no + } + add_to_list = county_holders + } + } + } + } + } + + scope:cardinal_undermine_legitimacy ?= { + capital_county.clerical_region_title = { + every_county_in_clerical_region = { + custom = cardinal_order_undermine_legitimacy + limit = { + holder.top_liege = { + has_legitimacy = yes + NOT = { + has_character_modifier = pam_cardinal_order_undermine_legitimacy_modifier + } + faith = scope:recipient.faith + } + } + holder.top_liege = { + add_character_modifier = { + modifier = pam_cardinal_order_undermine_legitimacy_modifier + years = 10 + } + if = { + limit = { + is_ai = no + } + add_to_list = county_holders + } + } + } + } + } + } +} + +pam_cardinal_order_accept_notify_players_effect = { + $HOF$ = { + if = { + limit = { is_ai = no } + hidden_effect = { + send_interface_toast = { + type = event_toast_effect_neutral + title = give_cardinal_order_interaction_toast + left_icon = $HOF$ + right_icon = scope:recipient + scope:recipient = { + show_as_tooltip = { + pam_choose_cardinal_order_switch_scripted_effect = yes + } + } + } + } + } + } + if = { + limit = { + scope:actor != $HOF$ + scope:actor = { is_ai = no } + } + scope:actor = { + send_interface_toast = { + type = event_toast_effect_neutral + title = give_cardinal_order_interaction_toast + left_icon = $HOF$ + right_icon = scope:recipient + scope:recipient = { + show_as_tooltip = { + pam_choose_cardinal_order_switch_scripted_effect = yes + } + } + } + } + } + every_in_list = { + list = county_holders + limit = { + NOT = { this = $HOF$ } + NOT = { this = scope:actor } + } + hidden_effect = { + send_interface_toast = { + type = event_toast_effect_neutral + title = give_cardinal_order_interaction_toast + left_icon = $HOF$ + right_icon = scope:recipient + scope:recipient = { + show_as_tooltip = { + pam_choose_cardinal_order_switch_scripted_effect = yes + } + } + } + } + } +} + +pam_cardinal_order_decline_effect = { + $CARDINAL$ = { + add_prestige = medium_prestige_gain + add_piety = medium_piety_loss + if = { + limit = { + $HOF$ = { is_alive = yes } + can_set_relation_rival_trigger = { CHARACTER = $HOF$ } + } + progress_towards_rival_effect = { + REASON = rival_ignored_orders + CHARACTER = $HOF$ + OPINION = default_rival_opinion + } + } + else_if = { + limit = { + $HOF$ = { is_alive = yes } + } + add_opinion = { + target = $HOF$ + modifier = disrespect_opinion + opinion = -60 + } + } + } +} + +# Shared handler for the offer_pilgrimage send option: ACTOR promises the pilgrimage, CLERIC is rewarded +pam_offer_pilgrimage_effect = { + if = { + limit = { + scope:offer_pilgrimage ?= yes + } + $ACTOR$ = { + add_character_modifier = { + modifier = promised_pilgrimage_to_clergy_modifier + years = 10 + } + custom_tooltip = actor_promised_pilgrimage_tt + } + $CLERIC$ = { + add_piety_experience = { + value = minor_piety_gain + add = { + value = $ACTOR$.highest_held_title_tier + subtract = 1.5 + multiply = 20 + } + } + } + } +} + +request_legitimacy_interaction_effect = { + add_legitimacy = { + value = medium_legitimacy_gain + multiply = 1.5 + if = { + limit = { + scope:monastic_support = yes + } + scope:puppet_or_actor = { + every_patroned_holy_order = { + limit = { + leader = { + government_has_flag = government_is_monastic_holy_order + } + } + add = minor_legitimacy_gain + } + } + } + if = { + limit = { + scope:puppet_or_actor ?= { + has_personal_tenet_flag = tenet_apostolic_succession_papal_legitimacy + faith.religious_head ?= scope:recipient + } + } + add = medium_legitimacy_gain + } + max = massive_legitimacy_gain + } + if = { + limit = { + rite = { + has_tenet_status = { + tenet = tenet_simony + status = prohibited + } + } + } + change_spiritual_fulfillment = medium_spiritual_fulfillment_loss + } + if = { + limit = { + any_vassal = { + NOT = { + faith = scope:puppet_or_actor.faith + } + } + } + every_vassal = { + custom = custom.every_astray_faith_vassal + limit = { + NOT = { + faith = scope:puppet_or_actor.faith + } + faith = { + faith_hostility_level = { + target = scope:puppet_or_actor.faith + value >= faith_astray_level + } + } + } + add_opinion = { + target = scope:puppet_or_actor + modifier = heathen_mandate_opinion + opinion = -20 + } + } + } + if = { + limit = { + any_held_title = { + tier = tier_county + NOT = { + faith = scope:puppet_or_actor.faith + } + faith = { + faith_hostility_level = { + target = scope:puppet_or_actor.faith + value >= faith_astray_level + } + } + } + } + every_held_title = { + custom = custom.every_astray_faith_domain_county + limit = { + tier = tier_county + NOT = { + faith = scope:puppet_or_actor.faith + } + faith = { + faith_hostility_level = { + target = scope:puppet_or_actor.faith + value >= faith_astray_level + } + } + } + add_county_modifier = { + modifier = heathen_mandate_modifier + years = 5 + } + } + } + if = { + limit = { + scope:monastic_support = yes + } + every_patroned_holy_order = { + limit = { + leader = { + government_has_flag = government_is_monastic_holy_order + } + } + scope:puppet_or_actor = { + pay_short_term_gold = { + target = prev.leader + gold = minor_gold_value + } + } + } + } + if = { + limit = { + scope:tithe = yes + } + every_held_title = { + limit = { + tier = tier_county + NOT = { + any_county_province = { + is_occupied = yes + } + } + development_level >= 1 + } + add_to_list = tithed_counties + } + scope:recipient = { + add_gold = { + value = 0 + every_in_list = { + list = tithed_counties + add = scope:recipient.miniscule_gold_value + add = { + value = development_level + } + } + max = monumental_gold_value + } + } + every_in_list = { + list = tithed_counties + custom = custom.every_domain_county_1_plus_development + if = { + limit = { + scope:recipient.culture = { + has_cultural_era_or_later = culture_era_late_medieval + } + } + change_development_progress = massive_development_progress_loss + } + else_if = { + limit = { + scope:recipient.culture = { + has_cultural_era_or_later = culture_era_high_medieval + } + } + change_development_progress = major_development_progress_loss + } + else = { + change_development_progress = medium_development_progress_loss + } + } + #Secretly take gold from wealthy-ass barons + hidden_effect = { + every_in_list = { + list = tithed_counties + every_county_province = { + limit = { + barony.holder ?= { + highest_held_title_tier = tier_barony + is_ai = yes + gold > medium_gold_value + } + } + barony.holder ?= { + remove_short_term_gold = medium_gold_value + } + } + } + } + if = { + limit = { + any_vassal = { + has_vassal_stance = barons_and_minor_landholders + } + } + every_vassal = { + custom = custom.every_barons_and_minor_landholders_vassal + limit = { + has_vassal_stance = barons_and_minor_landholders + } + add_opinion = { + modifier = tithed_opinion + target = scope:puppet_or_actor + opinion = -25 + } + } + custom_tooltip = tithe_takes_baron_gold_tt + } + } + if = { + limit = { + scope:donate_faith = yes + } + pay_short_term_gold = { + target = scope:recipient + gold = scope:puppet_or_actor.major_gold_value + } + } + if = { + limit = { + scope:use_hook = yes + has_usable_hook = scope:recipient + } + use_hook = scope:recipient + } + if = { + limit = { + scope:offer_hook = yes + } + scope:recipient = { + add_hook = { + type = favor_hook + target = scope:puppet_or_actor + } + } + } + if = { + limit = { + is_ai = yes + } + add_opinion = { + target = scope:recipient + modifier = grateful_opinion + opinion = 30 + } + } + pam_offer_pilgrimage_effect = { + ACTOR = scope:puppet_or_actor + CLERIC = scope:recipient + } + #The cleric should lose spiritual fulfillment if they agree to supporting a wicked king or a tyrant + if = { + limit = { + OR = { + character_considered_wicked_trigger = { RITE = scope:recipient.rite } + scope:recipient = { + has_relation_rival = scope:puppet_or_actor + } + tyranny > medium_tyranny + has_trait = excommunicated + } + } + scope:recipient = { + # We never take more piety than the cleric has, or the Church goes into debt + add_piety = { + value = major_piety_value + multiply = { + value = scope:puppet_or_actor.highest_held_title_tier + subtract = 1 + } + max = piety + min = 0 + multiply = -1 + } + change_spiritual_fulfillment = massive_spiritual_fulfillment_loss + if = { + limit = { + scope:puppet_or_actor = { has_trait = excommunicated } + } + custom_tooltip = sp_ful_loss_due_to_excommunicated + } + else_if = { + limit = { + has_relation_rival = scope:puppet_or_actor + } + custom_tooltip = sp_ful_loss_due_to_rival + } + else_if = { + limit = { + scope:puppet_or_actor = { tyranny > medium_tyranny } + } + custom_tooltip = sp_ful_loss_due_to_tyranny + } + else_if = { + custom_tooltip = sp_ful_loss_due_to_wicked + } + } + } + else_if = { + limit = { + OR = { + character_considered_morally_dubious_trigger = { RITE = scope:recipient.rite } + tyranny >= low_tyranny + } + } + scope:recipient = { + add_piety = { + value = minor_piety_value + multiply = { + value = scope:puppet_or_actor.highest_held_title_tier + subtract = 1 + } + max = piety + min = 0 + multiply = -1 + } + change_spiritual_fulfillment = medium_spiritual_fulfillment_loss + if = { + limit = { + scope:puppet_or_actor = { tyranny >= low_tyranny } + } + custom_tooltip = sp_ful_loss_due_to_tyranny + } + else = { + custom_tooltip = sp_ful_loss_due_to_immoral + } + } + } + else = { + scope:recipient = { + add_piety = { + value = miniscule_piety_value + multiply = { + value = scope:puppet_or_actor.highest_held_title_tier + subtract = 1 + } + max = piety + min = 0 + multiply = -1 + } + } + } + # Catalysts + if = { + limit = { + scope:puppet_or_actor.religion = religion:christianity_religion + situation:the_christian_church ?= { situation_top_has_catalyst = catalyst_the_christian_church_requested_legitimacy } + } + situation:the_christian_church = { trigger_situation_catalyst = catalyst_the_christian_church_requested_legitimacy } + } +} +#Add variable that makes title grant recipient (who is claimant) satisfied with claim-granting for a bit +claimant_jealousy_immunity_effect = { + custom_tooltip = satisfied_claim_granting_tt + if = { + limit = { + scope:highest_claim.tier = tier_hegemony + } + add_to_variable_list = { + name = hegemony_grant + target = scope:puppet_or_actor + years = 3 + } + } + else_if = { + limit = { + scope:highest_claim.tier = tier_empire + } + add_to_variable_list = { + name = empire_grant + target = scope:puppet_or_actor + years = 3 + } + } + else_if = { + limit = { + scope:highest_claim.tier = tier_kingdom + } + add_to_variable_list = { + name = kingdom_grant + target = scope:puppet_or_actor + years = 3 + } + } + else_if = { + limit = { + scope:highest_claim.tier = tier_duchy + } + add_to_variable_list = { + name = duchy_grant + target = scope:puppet_or_actor + years = 3 + } + } + else_if = { + limit = { + scope:highest_claim.tier = tier_county + } + add_to_variable_list = { + name = county_grant + target = scope:puppet_or_actor + years = 3 + } + } +} +claimant_rivalry_mercy_effect = { + custom_tooltip = strong_claim_given_away_rivalry_tt + if = { + limit = { + scope:highest_denied_claim = { + tier >= tier_hegemony + } + } + add_to_variable_list = { + name = denied_hegemony + target = scope:puppet_or_actor + days = 31 + } + } + else_if = { + limit = { + scope:highest_denied_claim = { + tier >= tier_empire + } + } + add_to_variable_list = { + name = denied_empire + target = scope:puppet_or_actor + days = 31 + } + } + else_if = { + limit = { + scope:highest_denied_claim = { + tier >= tier_kingdom + } + } + add_to_variable_list = { + name = denied_kingdom + target = scope:puppet_or_actor + days = 31 + } + } + else_if = { + limit = { + scope:highest_denied_claim = { + tier >= tier_duchy + } + } + add_to_variable_list = { + name = denied_duchy + target = scope:puppet_or_actor + days = 31 + } + } + else_if = { + limit = { + scope:highest_denied_claim = { + tier >= tier_county + } + } + add_to_variable_list = { + name = denied_county + target = scope:puppet_or_actor + days = 31 + } + } + trigger_event = { + id = pam_interactions_events.0040 + days = 30 + } +} +#Opinion loss with underlings who think they should get the title you're granting +title_granting_controversy_effect = { + #populate vassal list + every_vassal_or_below = { + limit = { + NOR = { + this = scope:recipient + this = $TITLE$.holder + is_in_list = eligible_vassals + } + highest_held_title_tier > tier_barony + #Vassal granting should only annoy people who could actually receive vassal + trigger_if = { + limit = { + exists = scope:secondary_actor + } + highest_held_title_tier > $TITLE$.tier + } + #Children can't hold titles in admin govs + trigger_if = { + limit = { + government_has_mechanic = administrative + } + is_adult = yes + #Admin de jure/neighboring thing is a pain in the butt but should be acknowledged + trigger_if = { + limit = { + is_ruler = yes + } + any_held_title = { + OR = { + # The target title is part of your de jure structure + is_de_jure_liege_or_above_target = $TITLE$ + target_is_de_jure_liege_or_above = $TITLE$ + } + } + } + } + scope:puppet_or_actor = { + is_character_interaction_valid = { + recipient = prev + interaction = $INTERACTION$ + } + } + #Shouldn't lose opinion when giving title to their child or parent + NOR = { + AND = { + is_child_of = scope:recipient + is_heir_of = scope:recipient + } + AND = { + is_parent_of = scope:recipient + exists = scope:recipient.house + house ?= scope:recipient.house + } + } + } + add_to_list = eligible_vassals + } + #Also show effect on courtier claimants you actually care about (IE your family members) + $TITLE$ = { + every_claimant = { + limit = { + NOT = { this = scope:recipient } + NOT = { + is_in_list = eligible_vassals + } + #Vassal granting should only annoy people who could actually receive vassal + trigger_if = { + limit = { + exists = scope:secondary_actor + } + highest_held_title_tier > $TITLE$.tier + } + trigger_if = { + limit = { + is_ruler = no + } + OR = { + rite = { + rite_has_parameter = gender_equal_law + } + AND = { + is_male = yes + rite = { + rite_has_parameter = male_dominated_law + } + } + AND = { + is_female = yes + rite = { + rite_has_parameter = female_dominated_law + } + } + } + } + in_diplomatic_range = scope:puppet_or_actor + NOT = { has_strong_implicit_claim_on = $TITLE$ } + any_claim = { + pressed = yes + this = $TITLE$ + } + any_liege_or_above = { + this = scope:puppet_or_actor + } + OR = { + any_close_family_member = { + this = scope:puppet_or_actor + } + AND = { + exists = scope:puppet_or_actor.house + house ?= scope:puppet_or_actor.house + } + any_spouse = { + this = scope:puppet_or_actor + } + has_any_good_relationship_with_character_trigger = { CHARACTER = scope:puppet_or_actor } + } + #Children can't hold titles in admin govs + trigger_if = { + limit = { + government_has_mechanic = administrative + } + is_adult = yes + #Admin de jure/neighboring thing is a pain in the butt but should be acknowledged + trigger_if = { + limit = { + is_ruler = yes + } + any_held_title = { + OR = { + # The target title is part of your de jure structure + is_de_jure_liege_or_above_target = $TITLE$ + target_is_de_jure_liege_or_above = $TITLE$ + } + } + } + } + scope:puppet_or_actor = { + is_character_interaction_valid = { + recipient = prev + interaction = $INTERACTION$ + } + } + #Shouldn't lose opinion when giving title to their child or parent + NOR = { + AND = { + is_child_of = scope:recipient + is_heir_of = scope:recipient + } + AND = { + is_parent_of = scope:recipient + exists = scope:recipient.house + house ?= scope:recipient.house + } + } + } + add_to_list = eligible_vassals + } + } + + #Higher repercussions for higher tier + #Higher repercussions for pressed claims than unpressed + if = { + limit = { + $TITLE$ = { + tier >= tier_kingdom + } + } + every_in_list = { + list = eligible_vassals + limit = { + NOT = { has_strong_implicit_claim_on = $TITLE$ } + has_claim_on = $TITLE$ + #Wasn't granted a claim of same tier or better in recent memory + NOR = { + any_in_list = { + variable = hegemony_grant + this = scope:puppet_or_actor + } + AND = { + $TITLE$.tier <= tier_empire + any_in_list = { + variable = empire_grant + this = scope:puppet_or_actor + } + } + AND = { + $TITLE$.tier <= tier_kingdom + any_in_list = { + variable = kingdom_grant + this = scope:puppet_or_actor + } + } + AND = { + $TITLE$.tier <= tier_duchy + any_in_list = { + variable = duchy_grant + this = scope:puppet_or_actor + } + } + AND = { + $TITLE$.tier <= tier_county + any_in_list = { + variable = county_grant + this = scope:puppet_or_actor + } + } + } + } + #pressed claim + if = { + limit = { + has_strong_claim_on = $TITLE$ + } + add_to_list = strong_claimants + add_opinion = { + target = scope:puppet_or_actor + modifier = gave_away_my_pressed_claim_opinion + opinion = -50 + } + } + #unpressed claim + else = { + add_opinion = { + target = scope:puppet_or_actor + modifier = gave_away_my_unpressed_claim_opinion + opinion = -30 + } + } + } + #Upset they didn't get de jure vassal title + every_in_list = { + list = eligible_vassals + limit = { + any_held_title = { + any_in_de_jure_hierarchy = { + this = $TITLE$ + } + } + } + #Less opinion loss if you're giving it to one of their vassals + if = { + limit = { + OR = { + exists = scope:secondary_actor + any_vassal_or_below = { + this = scope:recipient + } + } + } + add_opinion = { + target = scope:puppet_or_actor + modifier = gave_away_de_jure_vassal_title_opinion + opinion = -25 + } + } + else = { + add_opinion = { + target = scope:puppet_or_actor + modifier = gave_away_de_jure_vassal_title_opinion + opinion = -40 + } + } + } + #De Jure vassals upset they didn't get the title + every_in_list = { + list = eligible_vassals + limit = { + any_held_title = { + tier >= $TITLE$.tier_minus_1 + any_this_title_or_de_jure_above = { + this = $TITLE$ + } + } + } + #Less opinion loss if you're giving it to their liege or above + if = { + limit = { + any_liege_or_above = { + this = scope:recipient + } + } + add_opinion = { + target = scope:puppet_or_actor + modifier = gave_away_de_jure_liege_title_opinion + opinion = -20 + } + } + else = { + add_opinion = { + target = scope:puppet_or_actor + modifier = gave_away_de_jure_liege_title_opinion + opinion = -30 + } + } + } + } + else_if = { + limit = { + #Either title is a duchy or we're doing vassal transfer, not title granting + OR = { + $TITLE$ = { + tier >= tier_duchy + } + exists = scope:secondary_actor + } + } + every_in_list = { + list = eligible_vassals + limit = { + NOT = { has_strong_implicit_claim_on = $TITLE$ } + any_claim = { + this = $TITLE$ + pressed = yes + } + } + add_opinion = { + target = scope:puppet_or_actor + modifier = gave_away_my_pressed_claim_opinion + opinion = -40 + } + } + every_in_list = { + list = eligible_vassals + limit = { + NOT = { has_strong_implicit_claim_on = $TITLE$ } + any_claim = { + this = $TITLE$ + pressed = no + } + } + add_opinion = { + target = scope:puppet_or_actor + modifier = gave_away_my_unpressed_claim_opinion + opinion = -20 + } + } + #Upset they didn't get de jure vassal title + every_in_list = { + list = eligible_vassals + limit = { + any_held_title = { + any_in_de_jure_hierarchy = { + this = $TITLE$ + } + } + } + #Less opinion loss if you're giving it to one of their vassals or it's a vassal transfer + if = { + limit = { + OR = { + exists = scope:secondary_actor + any_vassal_or_below = { + this = scope:recipient + } + } + } + add_opinion = { + target = scope:puppet_or_actor + modifier = gave_away_de_jure_vassal_title_opinion + opinion = -20 + } + } + else = { + add_opinion = { + target = scope:puppet_or_actor + modifier = gave_away_de_jure_vassal_title_opinion + opinion = -30 + } + } + } + #De Jure vassals upset they didn't get the title + every_in_list = { + list = eligible_vassals + limit = { + any_held_title = { + tier >= $TITLE$.tier_minus_1 + any_this_title_or_de_jure_above = { + this = $TITLE$ + } + } + } + #Less opinion loss if you're giving it to their liege or above + if = { + limit = { + any_liege_or_above = { + this = scope:recipient + } + } + add_opinion = { + target = scope:puppet_or_actor + modifier = gave_away_de_jure_liege_title_opinion + opinion = -15 + } + } + else = { + add_opinion = { + target = scope:puppet_or_actor + modifier = gave_away_de_jure_liege_title_opinion + opinion = -20 + } + } + } + } + #Don't want to impose much mental load on giving away counties + #PLUS you can give them away with the "give to random noble" button without repercussions + #So we'll only do de jure lieges getting mad you are purposefully favoring another lord or courtier over them + else_if = { + limit = { + $TITLE$ = { tier >= tier_county } + } + #Upset they didn't get de jure vassal title + every_in_list = { + list = eligible_vassals + limit = { + any_held_title = { + any_in_de_jure_hierarchy = { + this = $TITLE$ + } + } + NOT = { + any_vassal_or_below = { + this = scope:recipient + } + } + } + add_opinion = { + target = scope:puppet_or_actor + modifier = gave_away_de_jure_vassal_title_opinion + opinion = -15 + } + } + } +} +strengthen_claim_interaction_effect = { + scope:puppet_or_actor = { add_pressed_claim = scope:target } + scope:recipient = { save_scope_as = cleric } + scope:target.holder ?= { save_scope_as = owner } + #Let's figure out how morally wrong the cleric feels this is + #Either your shittiness or target's coolness has given the clergyman pause + if = { + limit = { + clerical_hesitation_claim_interaction_value >= 9 + } + scope:recipient = { + if = { + limit = { + is_ai = yes + piety <= 0 + } + show_as_tooltip = { + add_piety = { + value = major_piety_loss + multiply = { + value = scope:puppet_or_actor.highest_held_title_tier + subtract = 1 + } + } + } + } + else = { + add_piety = { + value = major_piety_loss + multiply = { + value = scope:puppet_or_actor.highest_held_title_tier + subtract = 1 + } + } + } + change_spiritual_fulfillment = massive_spiritual_fulfillment_loss + if = { + limit = { + root ?= scope:cleric + } + custom_tooltip = clerical_hesitation_high_player_tt + } + else = { + custom_tooltip = clerical_hesitation_high_tt + } + } + } + else_if = { + limit = { + clerical_hesitation_claim_interaction_value >= 6 + } + scope:recipient = { + if = { + limit = { + is_ai = yes + piety <= 0 + } + show_as_tooltip = { + add_piety = { + value = medium_piety_loss + multiply = { + value = scope:puppet_or_actor.highest_held_title_tier + subtract = 1 + } + } + } + } + else = { + add_piety = { + value = medium_piety_loss + multiply = { + value = scope:puppet_or_actor.highest_held_title_tier + subtract = 1 + } + } + } + change_spiritual_fulfillment = major_spiritual_fulfillment_loss + if = { + limit = { + root ?= scope:cleric + } + custom_tooltip = clerical_hesitation_high_player_tt + } + else = { + custom_tooltip = clerical_hesitation_high_tt + } + } + } + else_if = { + limit = { + clerical_hesitation_claim_interaction_value >= 3 + } + scope:recipient = { + if = { + limit = { + is_ai = yes + piety <= 0 + } + show_as_tooltip = { + add_piety = { + value = minor_piety_loss + multiply = { + value = scope:puppet_or_actor.highest_held_title_tier + subtract = 1 + } + } + } + } + else = { + add_piety = { + value = minor_piety_loss + multiply = { + value = scope:puppet_or_actor.highest_held_title_tier + subtract = 1 + } + } + } + change_spiritual_fulfillment = medium_spiritual_fulfillment_loss + if = { + limit = { + root ?= scope:cleric + } + custom_tooltip = clerical_hesitation_high_player_tt + } + else = { + custom_tooltip = clerical_hesitation_high_tt + } + } + } + else_if = { + limit = { + clerical_hesitation_claim_interaction_value < 3 + clerical_hesitation_claim_interaction_value >= -2 + } + scope:recipient = { + add_piety = { + value = miniscule_piety_loss + multiply = { + value = scope:puppet_or_actor.highest_held_title_tier + subtract = 1 + } + } + } + } + else_if = { + limit = { + clerical_hesitation_claim_interaction_value < -2 + } + scope:recipient = { + if = { + limit = { + is_ai = yes + piety <= 0 + } + show_as_tooltip = { + add_piety = { + value = miniscule_piety_loss + multiply = { + value = scope:puppet_or_actor.highest_held_title_tier + subtract = 1 + } + } + } + } + else = { + add_piety = { + value = miniscule_piety_loss + multiply = { + value = scope:puppet_or_actor.highest_held_title_tier + subtract = 1 + } + } + } + change_spiritual_fulfillment = miniscule_spiritual_fulfillment_value + if = { + limit = { + root ?= scope:cleric + } + custom_tooltip = clerical_hesitation_low_player_tt + } + else = { + custom_tooltip = clerical_hesitation_low_tt + } + } + } + else_if = { + limit = { + clerical_hesitation_claim_interaction_value >= -5 + } + scope:recipient = { + if = { + limit = { + is_ai = yes + piety <= 0 + } + show_as_tooltip = { + add_piety = { + value = miniscule_piety_loss + multiply = { + value = scope:puppet_or_actor.highest_held_title_tier + subtract = 1 + } + } + } + } + else = { + add_piety = { + value = miniscule_piety_loss + multiply = { + value = scope:puppet_or_actor.highest_held_title_tier + subtract = 1 + } + } + } + change_spiritual_fulfillment = minor_spiritual_fulfillment_value + if = { + limit = { + root ?= scope:cleric + } + custom_tooltip = clerical_hesitation_low_player_tt + } + else = { + custom_tooltip = clerical_hesitation_low_tt + } + } + } + else_if = { + limit = { + clerical_hesitation_claim_interaction_value >= -8 + } + scope:recipient = { + if = { + limit = { + is_ai = yes + piety <= 0 + } + show_as_tooltip = { + add_piety = { + value = miniscule_piety_loss + multiply = { + value = scope:puppet_or_actor.highest_held_title_tier + subtract = 1 + } + } + } + } + else = { + add_piety = { + value = miniscule_piety_loss + multiply = { + value = scope:puppet_or_actor.highest_held_title_tier + subtract = 1 + } + } + } + change_spiritual_fulfillment = medium_spiritual_fulfillment_value + if = { + limit = { + root ?= scope:cleric + } + custom_tooltip = clerical_hesitation_low_player_tt + } + else = { + custom_tooltip = clerical_hesitation_low_tt + } + } + } + else = { + scope:recipient = { + if = { + limit = { + is_ai = yes + piety <= 0 + } + show_as_tooltip = { + add_piety = { + value = miniscule_piety_loss + multiply = { + value = scope:puppet_or_actor.highest_held_title_tier + subtract = 1 + } + } + } + } + else = { + add_piety = { + value = miniscule_piety_loss + multiply = { + value = scope:puppet_or_actor.highest_held_title_tier + subtract = 1 + } + } + } + change_spiritual_fulfillment = major_spiritual_fulfillment_value + if = { + limit = { + root ?= scope:cleric + } + custom_tooltip = clerical_hesitation_low_player_tt + } + else = { + custom_tooltip = clerical_hesitation_low_tt + } + } + } + scope:target.holder ?= { + add_opinion = { + target = scope:puppet_or_actor + modifier = church_claim_modifier + opinion = -40 + } + if = { + limit = { + scope:recipient = { + is_ai = yes + } + } + hidden_effect = { + add_opinion = { + target = scope:recipient + modifier = church_claim_modifier + opinion = -30 + } + } + } + else = { + add_opinion = { + target = scope:recipient + modifier = church_claim_modifier + opinion = -30 + } + } + } + #Opinion loss with title's de jure liege - why you trying to steal this when it should be under me? + scope:target = { + every_this_title_or_de_jure_above = { + limit = { + exists = holder + NOR = { + this = scope:target + holder = { + OR = { + this = scope:puppet_or_actor + this = scope:recipient + this = scope:target.holder + #actor's liege being mad at them for contesting other vassals is kinda wrong + is_liege_or_above_of = scope:puppet_or_actor + } + } + } + } + if = { + limit = { + any_direct_de_jure_vassal_title = { + this = scope:target + } + } + holder = { add_to_list = de_jure_direct_lieges } + } + else = { + holder = { add_to_list = de_jure_higher_lieges } + } + } + every_in_list = { + list = de_jure_direct_lieges + #More loss for direct liege + add_opinion = { + target = scope:puppet_or_actor + modifier = pressed_church_claim_de_jure_liege_modifier + opinion = -25 + } + if = { + limit = { + scope:recipient = { + is_ai = yes + } + } + hidden_effect = { + add_opinion = { + target = scope:recipient + modifier = pressed_church_claim_de_jure_liege_modifier + opinion = -10 + } + } + } + else = { + add_opinion = { + target = scope:recipient + modifier = pressed_church_claim_de_jure_liege_modifier + opinion = -10 + } + } + } + every_in_list = { + list = de_jure_higher_lieges + limit = { + NOT = { is_in_list = de_jure_direct_lieges } + } + add_opinion = { + target = scope:puppet_or_actor + modifier = pressed_church_claim_de_jure_liege_modifier + opinion = -15 + } + if = { + limit = { + scope:recipient = { + is_ai = yes + } + } + hidden_effect = { + add_opinion = { + target = scope:recipient + modifier = pressed_church_claim_de_jure_liege_modifier + opinion = -5 + } + } + } + else = { + add_opinion = { + target = scope:recipient + modifier = pressed_church_claim_de_jure_liege_modifier + opinion = -5 + } + } + } + } + if = { + limit = { + is_ai = yes + } + add_opinion = { + target = scope:recipient + modifier = pressed_my_claim + opinion = { + value = 10 + if = { + limit = { + highest_held_title_tier < scope:target.tier + } + multiply = 4 + } + else_if = { + limit = { + highest_held_title_tier = scope:target.tier + } + multiply = 3 + } + else_if = { + limit = { + highest_held_title_tier_minus_one = scope:target.tier + } + multiply = 2 + } + else_if = { + limit = { + highest_held_title_tier_minus_two = scope:target.tier + } + multiply = 1.5 + } + } + } + } + if = { + limit = { + scope:donate_faith = yes + } + pay_short_term_gold = { + target = scope:recipient + gold = scope:puppet_or_actor.medium_gold_value + } + } + if = { + limit = { + scope:use_hook = yes + has_usable_hook = scope:recipient + } + use_hook = scope:recipient + } + if = { + limit = { + scope:offer_hook = yes + } + scope:recipient = { + add_hook = { + type = favor_hook + target = scope:puppet_or_actor + } + } + } + pam_offer_pilgrimage_effect = { + ACTOR = scope:puppet_or_actor + CLERIC = scope:recipient + } + if = { + limit = { + scope:threaten_priest = yes + } + if = { + limit = { + scope:secondary_recipient = { + this = scope:puppet_or_actor.faith.religious_head + } + } + change_spiritual_fulfillment = massive_spiritual_fulfillment_loss + add_piety_experience = massive_piety_loss + custom_tooltip = hof_increase_piety_sp_fulfillment_loss_tt + } + else = { + change_spiritual_fulfillment = major_spiritual_fulfillment_loss + add_piety_experience = major_piety_loss + } + scope:secondary_recipient = { + add_opinion = { + modifier = threatened_church_opinion + target = scope:puppet_or_actor + opinion = -50 + } + } + } + # Catalysts + if = { + limit = { # If you are strenghtening a claim against a Christian ruler + scope:puppet_or_actor.religion = religion:christianity_religion + scope:target.holder.religion ?= religion:christianity_religion + situation:the_christian_church ?= { situation_top_has_catalyst = catalyst_the_christian_church_strenghtened_claim } + } + situation:the_christian_church = { trigger_situation_catalyst = catalyst_the_christian_church_strenghtened_claim } + } +} + +sell_claim_interaction_effect = { + scope:recipient = { add_unpressed_claim = scope:target } + # cost = { piety } is only charged to scope:actor, so a puppeteer's cleric pays here instead + if = { + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + add_piety = { + value = { + add = pam_sell_claim_piety_cost_value + max = piety + multiply = -1 + } + } + } + } + if = { + limit = { scope:sell_claim_gold_and_hook = yes } + send_interface_toast = { + title = sell_claim_interaction_effect_tt + left_icon = scope:target + right_icon = scope:recipient + scope:recipient = { + pay_short_term_gold = { + target = scope:puppet_or_actor + gold = minor_gold_value + } + } + } + scope:puppet_or_actor = { # Generates its own toast + if = { + limit = { has_hook = scope:recipient } + custom_tooltip = already_has_hook_on_recipient + } + add_hook = { + type = favor_hook + target = scope:recipient + } + } + } + else = { + scope:puppet_or_actor = { + send_interface_toast = { + title = sell_claim_interaction_effect_tt + left_icon = scope:target + right_icon = scope:recipient + scope:recipient = { + pay_short_term_gold = { + target = scope:puppet_or_actor + gold = pam_sell_claim_gold_cost_value + } + } + } + } + } + if = { + limit = { + scope:is_puppet_action ?= yes + scope:actor != scope:recipient + } + scope:actor = { + send_interface_toast = { + title = sell_claim_interaction_effect_tt_puppeteer + left_icon = scope:puppet_or_actor + right_icon = scope:recipient + } + } + } + if = { + limit = { + scope:puppet_or_actor = { has_pam_dlc_trigger = yes } + situation:the_christian_church ?= { + situation_top_has_catalyst = catalyst_clergy_sold_claim + } + scope:puppet_or_actor = { + any_character_situation = { + this = situation:the_christian_church + } + } + } + situation:the_christian_church = { + trigger_situation_catalyst = catalyst_clergy_sold_claim + } + } +} + +gift_claim_interaction_effect = { + send_interface_toast = { + type = event_toast_effect_neutral + title = gift_claim_interaction_effect_tt + left_icon = scope:target + right_icon = scope:recipient + remove_claim = scope:target + scope:recipient = { + add_unpressed_claim = scope:target + } + } + if = { + limit = { + scope:actor != scope:puppet_or_actor + scope:actor != scope:recipient + } + scope:actor = { + send_interface_toast = { + type = event_toast_effect_neutral + title = gift_claim_interaction_effect_tt_puppeteer + left_icon = scope:puppet_or_actor + right_icon = scope:recipient + } + } + } +} + +ecclesiastic_grant_claim_interaction_effect = { + add_pressed_claim = scope:target + scope:secondary_recipient = { save_scope_as = cleric } + scope:recipient = { save_scope_as = owner } + #Either your shittiness or target's coolness has given the clergyman pause + if = { + limit = { + clerical_hesitation_claim_interaction_value >= 9 + } + scope:secondary_recipient = { + if = { + limit = { + is_ai = yes + piety <= 0 + } + show_as_tooltip = { + add_piety = { + value = major_piety_loss + multiply = { + value = scope:puppet_or_actor.highest_held_title_tier + subtract = 1 + } + } + } + } + else = { + add_piety = { + value = major_piety_loss + multiply = { + value = scope:puppet_or_actor.highest_held_title_tier + subtract = 1 + } + } + } + change_spiritual_fulfillment = massive_spiritual_fulfillment_loss + if = { + limit = { + root ?= scope:cleric + } + custom_tooltip = clerical_hesitation_high_player_tt + } + else = { + custom_tooltip = clerical_hesitation_high_tt + } + } + } + else_if = { + limit = { + clerical_hesitation_claim_interaction_value >= 6 + } + scope:secondary_recipient = { + if = { + limit = { + is_ai = yes + piety <= 0 + } + show_as_tooltip = { + add_piety = { + value = medium_piety_loss + multiply = { + value = scope:puppet_or_actor.highest_held_title_tier + subtract = 1 + } + } + } + } + else = { + add_piety = { + value = medium_piety_loss + multiply = { + value = scope:puppet_or_actor.highest_held_title_tier + subtract = 1 + } + } + } + change_spiritual_fulfillment = major_spiritual_fulfillment_loss + if = { + limit = { + root ?= scope:cleric + } + custom_tooltip = clerical_hesitation_high_player_tt + } + else = { + custom_tooltip = clerical_hesitation_high_tt + } + } + } + else_if = { + limit = { + clerical_hesitation_claim_interaction_value >= 3 + } + scope:secondary_recipient = { + if = { + limit = { + is_ai = yes + piety <= 0 + } + show_as_tooltip = { + add_piety = { + value = minor_piety_loss + multiply = { + value = scope:puppet_or_actor.highest_held_title_tier + subtract = 1 + } + } + } + } + else = { + add_piety = { + value = minor_piety_loss + multiply = { + value = scope:puppet_or_actor.highest_held_title_tier + subtract = 1 + } + } + } + change_spiritual_fulfillment = medium_spiritual_fulfillment_loss + if = { + limit = { + root ?= scope:cleric + } + custom_tooltip = clerical_hesitation_high_player_tt + } + else = { + custom_tooltip = clerical_hesitation_high_tt + } + } + } + else_if = { + limit = { + clerical_hesitation_claim_interaction_value < 3 + clerical_hesitation_claim_interaction_value >= -2 + } + scope:secondary_recipient = { + if = { + limit = { + is_ai = yes + piety <= 0 + } + show_as_tooltip = { + add_piety = { + value = miniscule_piety_loss + multiply = { + value = scope:puppet_or_actor.highest_held_title_tier + subtract = 1 + } + } + } + } + else = { + add_piety = { + value = miniscule_piety_loss + multiply = { + value = scope:puppet_or_actor.highest_held_title_tier + subtract = 1 + } + } + } + } + } + else_if = { + limit = { + clerical_hesitation_claim_interaction_value < -2 + } + scope:secondary_recipient = { + if = { + limit = { + is_ai = yes + piety <= 0 + } + show_as_tooltip = { + add_piety = { + value = miniscule_piety_loss + multiply = { + value = scope:puppet_or_actor.highest_held_title_tier + subtract = 1 + } + } + } + } + else = { + add_piety = { + value = miniscule_piety_loss + multiply = { + value = scope:puppet_or_actor.highest_held_title_tier + subtract = 1 + } + } + } + change_spiritual_fulfillment = miniscule_spiritual_fulfillment_value + if = { + limit = { + root ?= scope:cleric + } + custom_tooltip = clerical_hesitation_low_player_tt + } + else = { + custom_tooltip = clerical_hesitation_low_tt + } + } + } + else_if = { + limit = { + clerical_hesitation_claim_interaction_value >= -5 + } + scope:secondary_recipient = { + if = { + limit = { + is_ai = yes + piety <= 0 + } + show_as_tooltip = { + add_piety = { + value = miniscule_piety_loss + multiply = { + value = scope:puppet_or_actor.highest_held_title_tier + subtract = 1 + } + } + } + } + else = { + add_piety = { + value = miniscule_piety_loss + multiply = { + value = scope:puppet_or_actor.highest_held_title_tier + subtract = 1 + } + } + } + change_spiritual_fulfillment = minor_spiritual_fulfillment_value + if = { + limit = { + root ?= scope:cleric + } + custom_tooltip = clerical_hesitation_low_player_tt + } + else = { + custom_tooltip = clerical_hesitation_low_tt + } + } + } + else_if = { + limit = { + clerical_hesitation_claim_interaction_value >= -8 + } + scope:secondary_recipient = { + if = { + limit = { + is_ai = yes + piety <= 0 + } + show_as_tooltip = { + add_piety = { + value = miniscule_piety_loss + multiply = { + value = scope:puppet_or_actor.highest_held_title_tier + subtract = 1 + } + } + } + } + else = { + add_piety = { + value = miniscule_piety_loss + multiply = { + value = scope:puppet_or_actor.highest_held_title_tier + subtract = 1 + } + } + } + change_spiritual_fulfillment = medium_spiritual_fulfillment_value + if = { + limit = { + root ?= scope:cleric + } + custom_tooltip = clerical_hesitation_low_player_tt + } + else = { + custom_tooltip = clerical_hesitation_low_tt + } + } + } + else = { + scope:secondary_recipient = { + if = { + limit = { + is_ai = yes + piety <= 0 + } + show_as_tooltip = { + add_piety = { + value = miniscule_piety_loss + multiply = { + value = scope:puppet_or_actor.highest_held_title_tier + subtract = 1 + } + } + } + } + else = { + add_piety = { + value = miniscule_piety_loss + multiply = { + value = scope:puppet_or_actor.highest_held_title_tier + subtract = 1 + } + } + } + change_spiritual_fulfillment = major_spiritual_fulfillment_value + if = { + limit = { + root ?= scope:cleric + } + custom_tooltip = clerical_hesitation_low_player_tt + } + else = { + custom_tooltip = clerical_hesitation_low_tt + } + } + } + scope:recipient ?= { + add_opinion = { + target = scope:puppet_or_actor + modifier = claimed_my_title_opinion + opinion = -60 + } + progress_towards_rival_effect = { + CHARACTER = scope:puppet_or_actor + OPINION = 0 + REASON = rival_claimed_my_title + } + hidden_effect = { + add_opinion = { + target = scope:secondary_recipient + modifier = claimed_my_title_opinion + opinion = -35 + } + } + } + #Opinion loss with title's de jure liege - why you trying to steal this when it should be under me? + scope:target = { + every_this_title_or_de_jure_above = { + limit = { + exists = holder + NOR = { + this = scope:target + holder = { + OR = { + this = scope:puppet_or_actor + this = scope:recipient + this = scope:target.holder + #actor's liege being mad at them for contesting other vassals is kinda wrong + is_liege_or_above_of = scope:puppet_or_actor + } + } + } + } + if = { + limit = { + any_direct_de_jure_vassal_title = { + this = scope:target + } + } + holder = { add_to_list = de_jure_direct_lieges } + } + else = { + holder = { add_to_list = de_jure_higher_lieges } + } + } + every_in_list = { + list = de_jure_direct_lieges + #More loss for direct liege + add_opinion = { + target = scope:puppet_or_actor + modifier = church_claim_de_jure_liege_modifier + opinion = -25 + } + if = { + limit = { + scope:secondary_recipient = { is_ai = yes } + } + hidden_effect = { + add_opinion = { + target = scope:secondary_recipient + modifier = church_claim_de_jure_liege_modifier + opinion = -10 + } + } + } + else = { + add_opinion = { + target = scope:secondary_recipient + modifier = church_claim_de_jure_liege_modifier + opinion = -10 + } + } + } + every_in_list = { + list = de_jure_higher_lieges + limit = { + NOT = { is_in_list = de_jure_direct_lieges } + } + add_opinion = { + target = scope:puppet_or_actor + modifier = church_claim_de_jure_liege_modifier + opinion = -15 + } + if = { + limit = { + scope:secondary_recipient = { is_ai = yes } + } + hidden_effect = { + add_opinion = { + target = scope:secondary_recipient + modifier = church_claim_de_jure_liege_modifier + opinion = -5 + } + } + } + else = { + add_opinion = { + target = scope:secondary_recipient + modifier = church_claim_de_jure_liege_modifier + opinion = -5 + } + } + } + } + if = { + limit = { + is_ai = yes + } + add_opinion = { + target = scope:secondary_recipient + modifier = granted_claim_opinion + opinion = { + value = 10 + if = { + limit = { + highest_held_title_tier < scope:target.tier + } + multiply = 5 + } + else_if = { + limit = { + highest_held_title_tier = scope:target.tier + } + multiply = 4 + } + else_if = { + limit = { + highest_held_title_tier_minus_one = scope:target.tier + } + multiply = 3 + } + else_if = { + limit = { + highest_held_title_tier_minus_two = scope:target.tier + } + multiply = 2 + } + } + } + } + if = { + limit = { + scope:donate_faith = yes + } + pay_short_term_gold = { + target = scope:secondary_recipient + gold = scope:puppet_or_actor.medium_gold_value + } + } + if = { + limit = { + scope:use_hook = yes + has_usable_hook = scope:secondary_recipient + } + use_hook = scope:secondary_recipient + } + if = { + limit = { + scope:offer_hook = yes + } + scope:secondary_recipient = { + add_hook = { + type = favor_hook + target = scope:puppet_or_actor + } + } + } + pam_offer_pilgrimage_effect = { + ACTOR = scope:puppet_or_actor + CLERIC = scope:secondary_recipient + } + if = { + limit = { + scope:threaten_priest = yes + } + if = { + limit = { + scope:secondary_recipient = { + this = scope:puppet_or_actor.faith.religious_head + } + } + change_spiritual_fulfillment = massive_spiritual_fulfillment_loss + add_piety_experience = massive_piety_loss + custom_tooltip = hof_increase_piety_sp_fulfillment_loss_secondary_tt + } + else = { + change_spiritual_fulfillment = major_spiritual_fulfillment_loss + add_piety_experience = major_piety_loss + } + scope:secondary_recipient = { + add_opinion = { + modifier = threatened_church_opinion + target = scope:puppet_or_actor + opinion = -50 + } + } + } + # Catalysts + if = { + limit = { + scope:puppet_or_actor.religion = religion:christianity_religion + scope:recipient.religion = religion:christianity_religion + situation:the_christian_church ?= { situation_top_has_catalyst = catalyst_the_christian_church_ecclesiastical_grant_claim } + } + if = { + limit = { scope:threaten_priest = yes } + situation:the_christian_church = { trigger_situation_catalyst = catalyst_the_christian_church_threatened_ecclesiastical_grant_claim } + } + else = { + situation:the_christian_church = { trigger_situation_catalyst = catalyst_the_christian_church_ecclesiastical_grant_claim } + } + } +} + +# Called from on_personal_tenet_gain and on_piety_level_gain +reincarnation_piety_courage_gain_effect = { + if = { + limit = { + has_personal_tenet_flag = tenet_reincarnation_piety_level_courage + piety_level >= high_piety_level + } + if = { + limit = { has_trait = craven } + send_interface_toast = { + type = event_toast_effect_good + title = pam_reincarnation_courage_toast + left_icon = root + remove_trait = craven + } + } + else_if = { + limit = { NOT = { has_trait = brave } } + send_interface_toast = { + type = event_toast_effect_good + title = pam_reincarnation_courage_toast + left_icon = root + add_trait = brave + } + } + } +} + +exaltation_of_pain_flagellant_gain_effect = { + if = { + limit = { + has_personal_tenet_flag = tenet_exaltation_of_pain_flagellant_trait + NOT = { has_trait = flagellant } + } + add_trait = flagellant + } +} + +pam_kingdom_of_heaven_declaration_effect = { + save_scope_as = kingdom_of_heaven_founder + get_title = title:h_kingdom_of_heaven + set_primary_title_to = title:h_kingdom_of_heaven + set_realm_capital = title:c_jerusalem + hidden_effect = { + domicile ?= { move_domicile = root.capital_province } + } + dynasty ?= { + add_dynasty_prestige = 10000 + add_dynasty_modifier = pam_founded_kingdom_of_heaven_modifier + } + if = { + limit = { NOT = { exists = dynasty } } + add_character_modifier = pam_founded_kingdom_of_heaven_modifier + } + custom_tooltip = { + text = pam_kingdom_of_heaven_decision_subjugation_effect_tt + set_variable = koh_subjugation_cb_allowed + } + set_global_variable = { + name = created_kingdom_of_heaven + value = yes + } + root.faith = { + every_faith_ruler = { + limit = { + this != root + is_independent_ruler = yes + is_available_quick = { + landed = yes + ai = yes + advanced_ruler = yes + } + is_playable_character = yes + highest_held_title_tier >= tier_county + highest_held_title_tier < tier_hegemony + NOR = { + has_relation_rival = root + is_at_war_with = root + government_has_flag = cannot_be_vassal_or_liege + } + } + random = { + chance = { + value = 20 + if = { + limit = { piety_level >= 1 } + add = 5 + } + if = { + limit = { piety_level >= 2 } + add = 8 + } + if = { + limit = { piety_level >= 3 } + add = 10 + } + if = { + limit = { piety_level >= 4 } + add = 15 + } + if = { + limit = { + opinion = { + target = root + value >= 30 + } + } + add = 10 + } + if = { + limit = { + opinion = { + target = root + value >= 60 + } + } + add = 15 + } + if = { + limit = { + exists = rite + scope:kingdom_of_heaven_founder = { exists = rite } + rite = scope:kingdom_of_heaven_founder.rite + } + add = 40 + } + } + add_to_list = new_vassals + hidden_effect = { + create_title_and_vassal_change = { + type = swear_fealty + save_scope_as = koh_fealty_change + add_claim_on_loss = no + } + change_liege = { + liege = root + change = scope:koh_fealty_change + } + resolve_title_and_vassal_change = scope:koh_fealty_change + } + if = { + limit = { highest_held_title_tier >= tier_kingdom } + show_as_tooltip = { + change_liege = { + liege = root + change = scope:koh_fealty_change + } + } + } + } + } + } + custom_tooltip = kingdom_of_heaven_lower_vassals_gained_tt + custom_tooltip = { + text = kingdom_of_heaven_lower_de_jure_gained_tt + every_empire = { + limit = { + is_landless_type_title = no + trigger_if = { + limit = { exists = holder.top_liege } + holder.top_liege = root + } + # really not landless + any_in_de_jure_hierarchy = { + tier = tier_kingdom + is_landless_type_title = no + any_in_de_jure_hierarchy = { + tier = tier_duchy + is_landless_type_title = no + } + } + save_temporary_scope_as = empire_temp + OR = { + holder ?= scope:kingdom_of_heaven_founder + scope:kingdom_of_heaven_founder = { completely_controls = scope:empire_temp } + } + } + set_de_jure_liege_title = title:h_kingdom_of_heaven + } + } +} + +pam_create_theocratic_dynasty_extra_effects = { + if = { # HoF doesn't like this + limit = { + exists = faith.religious_head + root != faith.religious_head + faith = { has_doctrine = doctrine_clerical_marriage_disallowed } + } + faith.religious_head = { + add_opinion = { + target = root + modifier = impious_opinion + opinion = -40 + } + } + add_piety = major_piety_loss + situation:the_christian_church ?= { + if = { + limit = { + situation_top_has_catalyst = catalyst_the_christian_church_established_theocratic_dynasty + } + trigger_situation_catalyst = catalyst_the_christian_church_established_theocratic_dynasty + } + } + } +} + +pam_boost_clerical_appointment_score_effect = { + $CHARACTER$.superior.primary_title ?= { + change_appointment_investment = { + target = $CHARACTER$ + value = $VALUE$ + } + } +} + +# Successful Siphon Treasury +pam_the_christian_church_clergy_embezzled_treasury_catalyst_effect = { + if = { + limit = { + is_clergy = yes + any_character_situation = { + situation_type = the_christian_church + } + situation:the_christian_church ?= { + situation_top_has_catalyst = catalyst_clergy_embezzled_treasury + } + } + situation:the_christian_church = { + trigger_situation_catalyst = { + catalyst = catalyst_clergy_embezzled_treasury + character = root + } + } + } +} + +# Withdraw Funds from Treasury decision +pam_the_christian_church_clergy_withdrew_funds_from_treasury_catalyst_effect = { + if = { + limit = { + is_clergy = yes + any_character_situation = { + situation_type = the_christian_church + } + situation:the_christian_church ?= { + situation_top_has_catalyst = catalyst_clergy_withdrew_funds_from_treasury + } + } + situation:the_christian_church = { + trigger_situation_catalyst = catalyst_clergy_withdrew_funds_from_treasury + } + } +} + +# Needs POPE (appointer), CARDINAL (new cardinal) and OTHERWISE (non-nepotistic catalyst), any scope +# Both branches guard their catalyst, so a phase listing neither books nothing +pam_the_christian_church_appointed_cardinal_catalyst_effect = { + situation:the_christian_church ?= { + if = { + limit = { + $CARDINAL$ = { pam_cardinal_is_nepotistic_appointment_trigger = { POPE = $POPE$ } } + } + if = { + limit = { + situation_top_has_catalyst = catalyst_the_christian_church_appointed_nepotistic_cardinal + } + trigger_situation_catalyst = catalyst_the_christian_church_appointed_nepotistic_cardinal + } + } + else = { + if = { + limit = { + situation_top_has_catalyst = $OTHERWISE$ + } + trigger_situation_catalyst = $OTHERWISE$ + } + } + } +} + +# A non-Catholic ruler holds the de jure capital county of k_papal_state +pam_the_christian_church_catholic_hof_weak_papal_state_control_catalyst_effect = { + if = { + limit = { + has_pam_dlc_trigger = yes + pam_catholic_hof_weak_papal_state_control_trigger = yes + situation:the_christian_church ?= { + situation_top_has_catalyst = catalyst_catholic_hof_weak_papal_state_control + } + } + situation:the_christian_church = { + trigger_situation_catalyst = catalyst_catholic_hof_weak_papal_state_control + } + } +} + +@pam_papal_dynasty_capture_reigns = 3 +pam_the_christian_church_papal_dynasty_capture_catalyst_effect = { + if = { + limit = { + has_pam_dlc_trigger = yes + current_date_is_start_date_trigger = no + religion = religion:christianity_religion + } + if = { + limit = { exists = dynasty } + dynasty = { save_scope_as = pam_new_papal_dynasty } + } + situation:the_christian_church ?= { + if = { + limit = { + exists = scope:pam_new_papal_dynasty + has_variable = pam_papal_dynasty + var:pam_papal_dynasty = scope:pam_new_papal_dynasty + } + change_variable = { + name = pam_papal_dynasty_reigns + add = 1 + } + } + else_if = { + limit = { exists = scope:pam_new_papal_dynasty } + set_variable = { + name = pam_papal_dynasty + value = scope:pam_new_papal_dynasty + } + set_variable = { + name = pam_papal_dynasty_reigns + value = 1 + } + remove_variable = pam_papal_dynasty_capture_catalyst_fired + } + else = { + remove_variable = pam_papal_dynasty + remove_variable = pam_papal_dynasty_reigns + remove_variable = pam_papal_dynasty_capture_catalyst_fired + } + if = { + limit = { + has_variable = pam_papal_dynasty_reigns + var:pam_papal_dynasty_reigns >= @pam_papal_dynasty_capture_reigns + NOT = { has_variable = pam_papal_dynasty_capture_catalyst_fired } + situation_top_has_catalyst = catalyst_the_christian_church_papal_dynasty_capture + } + set_variable = pam_papal_dynasty_capture_catalyst_fired + trigger_situation_catalyst = catalyst_the_christian_church_papal_dynasty_capture + } + } + } +} + +# A different Christian faith becomes Main Power +pam_the_christian_church_main_power_faith_changed_catalyst_effect = { + situation:the_christian_church ?= { + if = { + limit = { + has_variable = pam_main_power_faith_changed_catalyst_faith + NOT = { var:tcc_main_power_faith = var:pam_main_power_faith_changed_catalyst_faith } + } + remove_variable = pam_the_christian_church_main_power_faith_changed_catalyst_fired + remove_variable = pam_main_power_faith_changed_catalyst_faith + } + if = { + limit = { + exists = scope:tcc_old_main_power_faith + has_variable = tcc_main_power_faith + var:tcc_main_power_faith != scope:tcc_old_main_power_faith + NOT = { has_variable = pam_the_christian_church_main_power_faith_changed_catalyst_fired } + situation_top_has_catalyst = catalyst_the_christian_church_main_power_faith_changed + } + set_variable = pam_the_christian_church_main_power_faith_changed_catalyst_fired + set_variable = { + name = pam_main_power_faith_changed_catalyst_faith + value = var:tcc_main_power_faith + } + trigger_situation_catalyst = catalyst_the_christian_church_main_power_faith_changed + } + } +} + +# Byzantine emperor is not Christian +pam_the_christian_church_byzantine_emperor_non_christian_catalyst_effect = { + situation:the_christian_church ?= { + if = { + limit = { + pam_byzantine_emperor_non_christian_trigger = no + } + remove_variable = pam_byzantine_emperor_non_christian_catalyst_fired + } + else_if = { + limit = { + pam_byzantine_emperor_non_christian_trigger = yes + NOT = { has_variable = pam_byzantine_emperor_non_christian_catalyst_fired } + situation_top_has_catalyst = catalyst_byzantine_emperor_non_christian + } + set_variable = pam_byzantine_emperor_non_christian_catalyst_fired + trigger_situation_catalyst = catalyst_byzantine_emperor_non_christian + } + } +} + +# Non Christian presence in Europe +pam_the_christian_church_non_christian_kingdom_in_europe_catalyst_effect = { + if = { + limit = { + pam_non_christian_kingdom_holder_in_europe_trigger = yes + situation:the_christian_church ?= { + situation_top_has_catalyst = catalyst_non_christian_kingdom_in_europe + } + } + situation:the_christian_church = { + trigger_situation_catalyst = catalyst_non_christian_kingdom_in_europe + } + random_ruler = { + limit = { pam_non_christian_kingdom_holder_in_europe_trigger = yes } + set_variable = pam_non_christian_kingdom_holder_in_europe_trigger_var + } + } +} + +# County conversion Catalysts +pam_the_christian_church_county_conversion_catalysts_effect = { + if = { # PAM - Catalysts if non-Christian county is converted to Christianity + limit = { + faith != scope:old_faith + scope:old_faith = { + religion != religion:christianity_religion + } + faith.religion = religion:christianity_religion + situation:the_christian_church ?= { + situation_top_has_catalyst = catalyst_county_converted_to_faith + } + } + situation:the_christian_church = { + trigger_situation_catalyst = catalyst_county_converted_to_faith + } + } + if = { # PAM - Catalyst when Christian county is converted away from Christianity + limit = { + faith != scope:old_faith + scope:old_faith = { + religion = religion:christianity_religion + } + faith.religion != religion:christianity_religion + situation:the_christian_church ?= { + situation_top_has_catalyst = catalyst_county_converted_from_faith + } + } + situation:the_christian_church = { + trigger_situation_catalyst = catalyst_county_converted_from_faith + } + } + if = { # PAM - Jerusalem county is no longer Christian + limit = { + this = title:c_jerusalem + scope:old_faith = { + religion = religion:christianity_religion + } + faith.religion != religion:christianity_religion + situation:the_christian_church ?= { + situation_top_has_catalyst = catalyst_lose_jerusalem + } + } + situation:the_christian_church = { + trigger_situation_catalyst = catalyst_lose_jerusalem + } + } + if = { # PAM - Other Christian holy site county is no longer Christian + limit = { + NOT = { this = title:c_jerusalem } + scope:old_faith = { + religion = religion:christianity_religion + } + faith.religion != religion:christianity_religion + any_county_province = { + barony = { is_holy_site_of = scope:old_faith } + } + situation:the_christian_church ?= { + situation_top_has_catalyst = catalyst_lose_holy_site + } + } + situation:the_christian_church = { + trigger_situation_catalyst = catalyst_lose_holy_site + } + } +} + +# Clergy member exposed as adhering to a prohibited personal tenet +pam_the_christian_church_clergy_exposed_forbidden_personal_tenet_catalyst_effect = { + if = { + limit = { + is_clergy = yes + situation:the_christian_church ?= { + situation_top_has_catalyst = catalyst_clergy_exposed_forbidden_personal_tenet + } + } + situation:the_christian_church = { + trigger_situation_catalyst = catalyst_clergy_exposed_forbidden_personal_tenet + } + } +} + +# Secular ruler exposed as adhering to a prohibited personal tenet +pam_the_christian_church_exposed_forbidden_personal_tenet_catalyst_effect = { + if = { + limit = { + is_clergy = no + situation:the_christian_church ?= { + situation_top_has_catalyst = catalyst_exposed_forbidden_personal_tenet + } + } + situation:the_christian_church = { + trigger_situation_catalyst = catalyst_exposed_forbidden_personal_tenet + } + } +} + +# Christian ruler wins a Great Holy War +pam_the_christian_church_great_holy_war_won_catalyst_effect = { + if = { + limit = { + scope:attacker = { + has_pam_dlc_trigger = yes + religion = religion:christianity_religion + } + situation:the_christian_church ?= { + situation_top_has_catalyst = catalyst_the_christian_church_great_holy_war_won + } + } + situation:the_christian_church = { + trigger_situation_catalyst = catalyst_the_christian_church_great_holy_war_won + } + } +} + +# Christian ruler loses a Great Holy War +pam_the_christian_church_great_holy_war_lost_catalyst_effect = { + if = { + limit = { + scope:attacker = { + has_pam_dlc_trigger = yes + religion = religion:christianity_religion + } + situation:the_christian_church ?= { + situation_top_has_catalyst = catalyst_the_christian_church_great_holy_war_lost + } + } + situation:the_christian_church = { + trigger_situation_catalyst = catalyst_the_christian_church_great_holy_war_lost + } + } +} + +# Christian prelate hires a Military Order (on_holy_order_hired) +pam_the_christian_church_clergy_hired_holy_order_catalyst_effect = { + if = { + limit = { + scope:actor = { + has_pam_dlc_trigger = yes + is_clergy = yes + religion = religion:christianity_religion + } + situation:the_christian_church ?= { + situation_top_has_catalyst = catalyst_clergy_hired_holy_order + } + } + situation:the_christian_church = { + trigger_situation_catalyst = catalyst_clergy_hired_holy_order + } + } +} + +# Christian prelate hires mercenaries while at war with a non-Christian (on_mercenary_company_hired) +pam_the_christian_church_clergy_hired_mercenaries_catalyst_effect = { + if = { + limit = { + scope:employer = { + has_pam_dlc_trigger = yes + is_clergy = yes + religion = religion:christianity_religion + any_primary_war_enemy = { + religion != religion:christianity_religion + } + } + situation:the_christian_church ?= { + situation_top_has_catalyst = catalyst_clergy_hired_mercenaries + } + } + situation:the_christian_church = { + trigger_situation_catalyst = catalyst_clergy_hired_mercenaries + } + } +} + +pam_the_christian_church_clergy_gained_landed_title_catalyst_effect = { + if = { + limit = { + has_global_variable = game_has_started # Don't fire for the clerical title holders placed during setup + has_pam_dlc_trigger = yes + is_clergy = yes + religion = religion:christianity_religion + scope:title = { + tier >= tier_county + has_clerical_region = no + } + situation:the_christian_church ?= { + situation_top_has_catalyst = catalyst_clergy_gained_landed_title + } + } + situation:the_christian_church = { + trigger_situation_catalyst = { + catalyst = catalyst_clergy_gained_landed_title + character = root + } + } + } +} + +# Excommunication war declared between two Christian rulers (excommunication_war on_declaration) +pam_the_christian_church_excommunication_war_catalyst_effect = { + if = { + limit = { + scope:attacker = { has_pam_dlc_trigger = yes } + scope:attacker = { religion = religion:christianity_religion } + scope:defender = { religion = religion:christianity_religion } + situation:the_christian_church ?= { + situation_top_has_catalyst = catalyst_the_christian_church_excommunication_war_declared + } + } + situation:the_christian_church = { + trigger_situation_catalyst = catalyst_the_christian_church_excommunication_war_declared + } + } +} + +# Humiliation war declared against a Christian ecclesiastical ruler +pam_the_christian_church_humiliation_war_catalyst_effect = { + if = { + limit = { + scope:attacker = { has_pam_dlc_trigger = yes } + scope:defender = { + religion = religion:christianity_religion + government_has_flag = government_is_theocracy # Accounts for Ecclesiastical + } + situation:the_christian_church ?= { + situation_top_has_catalyst = catalyst_the_christian_church_humiliation_war_declared + } + } + situation:the_christian_church = { + trigger_situation_catalyst = catalyst_the_christian_church_humiliation_war_declared + } + } +} + +# Clergy has a child +pam_the_christian_church_clergy_has_child_catalyst_effect = { + $CHARACTER$ = { + if = { + limit = { + has_pam_dlc_trigger = yes + is_clergy = yes + rite = { rite_has_doctrine = doctrine_clerical_marriage_disallowed } + any_character_situation = { + situation_type = the_christian_church + situation_top_has_catalyst = catalyst_clergy_has_child + } + } + if = { + limit = { + any_held_title = { is_head_of_faith = yes } + } + situation:the_christian_church = { + trigger_situation_catalyst = { + catalyst = catalyst_the_christian_church_head_of_faith_has_child + character = $CHARACTER$ + } + } + } + else = { + situation:the_christian_church = { + trigger_situation_catalyst = { + catalyst = catalyst_clergy_has_child + character = $CHARACTER$ + } + } + } + } + } +} + +pam_buy_ecclesiastical_title_interaction_effect = { + scope:actor = { + if = { + limit = { government_has_flag = government_is_theocracy } + save_scope_as = new_holder + } + else = { + scope:secondary_recipient = { save_scope_as = new_holder } + } + } + scope:actor = { + pay_short_term_gold = { + target = scope:recipient + gold = pam_buy_ecclesiastical_title_gold_cost_value + } + } + create_title_and_vassal_change = { + type = granted + save_scope_as = change + } + scope:target = { + change_title_holder_include_vassals = { + holder = scope:new_holder + change = scope:change + government_base = scope:recipient + } + } + resolve_title_and_vassal_change = scope:change + scope:new_holder = { + if = { + limit = { + NOT = { government_has_flag = government_is_ecclesiastical } + } + change_government = ecclesiastical_government + } + } + if = { + limit = { + scope:actor = { has_pam_dlc_trigger = yes } + situation:the_christian_church ?= { + situation_top_has_catalyst = catalyst_clergy_simony + } + scope:actor = { + any_character_situation = { + this = situation:the_christian_church + } + } + } + situation:the_christian_church = { + trigger_situation_catalyst = catalyst_clergy_simony + } + } +} + +ecclesiastic_transfer_land_interaction_immediate_effect = { + scope:secondary_recipient = { save_scope_as = cleric } + scope:recipient = { save_scope_as = owner } + #Either your shittiness or target's coolness has given the clergyman pause + if = { + limit = { + clerical_hesitation_claim_interaction_value >= 9 + } + scope:secondary_recipient = { + if = { + limit = { + is_ai = yes + piety <= 0 + } + show_as_tooltip = { + add_piety = { + value = major_piety_loss + multiply = { + value = scope:actor.highest_held_title_tier + subtract = 1 + } + } + } + } + else = { + add_piety = { + value = major_piety_loss + multiply = { + value = scope:actor.highest_held_title_tier + subtract = 1 + } + } + } + change_spiritual_fulfillment = massive_spiritual_fulfillment_loss + if = { + limit = { + root ?= scope:cleric + } + custom_tooltip = clerical_hesitation_high_player_tt + } + else = { + custom_tooltip = clerical_hesitation_high_tt + } + } + } + else_if = { + limit = { + clerical_hesitation_claim_interaction_value >= 6 + } + scope:secondary_recipient = { + if = { + limit = { + is_ai = yes + piety <= 0 + } + show_as_tooltip = { + add_piety = { + value = medium_piety_loss + multiply = { + value = scope:actor.highest_held_title_tier + subtract = 1 + } + } + } + } + else = { + add_piety = { + value = medium_piety_loss + multiply = { + value = scope:actor.highest_held_title_tier + subtract = 1 + } + } + } + change_spiritual_fulfillment = major_spiritual_fulfillment_loss + if = { + limit = { + root ?= scope:cleric + } + custom_tooltip = clerical_hesitation_high_player_tt + } + else = { + custom_tooltip = clerical_hesitation_high_tt + } + } + } + else_if = { + limit = { + clerical_hesitation_claim_interaction_value >= 3 + } + scope:secondary_recipient = { + if = { + limit = { + is_ai = yes + piety <= 0 + } + show_as_tooltip = { + add_piety = { + value = minor_piety_loss + multiply = { + value = scope:actor.highest_held_title_tier + subtract = 1 + } + } + } + } + else = { + add_piety = { + value = minor_piety_loss + multiply = { + value = scope:actor.highest_held_title_tier + subtract = 1 + } + } + } + change_spiritual_fulfillment = medium_spiritual_fulfillment_loss + if = { + limit = { + root ?= scope:cleric + } + custom_tooltip = clerical_hesitation_high_player_tt + } + else = { + custom_tooltip = clerical_hesitation_high_tt + } + } + } + else_if = { + limit = { + clerical_hesitation_claim_interaction_value < 3 + clerical_hesitation_claim_interaction_value >= -2 + } + scope:secondary_recipient = { + if = { + limit = { + is_ai = yes + piety <= 0 + } + show_as_tooltip = { + add_piety = { + value = miniscule_piety_loss + multiply = { + value = scope:actor.highest_held_title_tier + subtract = 1 + } + } + } + } + else = { + add_piety = { + value = miniscule_piety_loss + multiply = { + value = scope:actor.highest_held_title_tier + subtract = 1 + } + } + } + } + } + else_if = { + limit = { + clerical_hesitation_claim_interaction_value < -2 + } + scope:secondary_recipient = { + if = { + limit = { + is_ai = yes + piety <= 0 + } + show_as_tooltip = { + add_piety = { + value = miniscule_piety_loss + multiply = { + value = scope:actor.highest_held_title_tier + subtract = 1 + } + } + } + } + else = { + add_piety = { + value = miniscule_piety_loss + multiply = { + value = scope:actor.highest_held_title_tier + subtract = 1 + } + } + } + change_spiritual_fulfillment = miniscule_spiritual_fulfillment_value + if = { + limit = { + root ?= scope:cleric + } + custom_tooltip = clerical_hesitation_low_player_tt + } + else = { + custom_tooltip = clerical_hesitation_low_tt + } + } + } + else_if = { + limit = { + clerical_hesitation_claim_interaction_value >= -5 + } + scope:secondary_recipient = { + if = { + limit = { + is_ai = yes + piety <= 0 + } + show_as_tooltip = { + add_piety = { + value = miniscule_piety_loss + multiply = { + value = scope:actor.highest_held_title_tier + subtract = 1 + } + } + } + } + else = { + add_piety = { + value = miniscule_piety_loss + multiply = { + value = scope:actor.highest_held_title_tier + subtract = 1 + } + } + } + change_spiritual_fulfillment = minor_spiritual_fulfillment_value + if = { + limit = { + root ?= scope:cleric + } + custom_tooltip = clerical_hesitation_low_player_tt + } + else = { + custom_tooltip = clerical_hesitation_low_tt + } + } + } + else_if = { + limit = { + clerical_hesitation_claim_interaction_value >= -8 + } + scope:secondary_recipient = { + if = { + limit = { + is_ai = yes + piety <= 0 + } + show_as_tooltip = { + add_piety = { + value = miniscule_piety_loss + multiply = { + value = scope:actor.highest_held_title_tier + subtract = 1 + } + } + } + } + else = { + add_piety = { + value = miniscule_piety_loss + multiply = { + value = scope:actor.highest_held_title_tier + subtract = 1 + } + } + } + change_spiritual_fulfillment = medium_spiritual_fulfillment_value + if = { + limit = { + root ?= scope:cleric + } + custom_tooltip = clerical_hesitation_low_player_tt + } + else = { + custom_tooltip = clerical_hesitation_low_tt + } + } + } + else = { + scope:secondary_recipient = { + if = { + limit = { + is_ai = yes + piety <= 0 + } + show_as_tooltip = { + add_piety = { + value = miniscule_piety_loss + multiply = { + value = scope:actor.highest_held_title_tier + subtract = 1 + } + } + } + } + else = { + add_piety = { + value = miniscule_piety_loss + multiply = { + value = scope:actor.highest_held_title_tier + subtract = 1 + } + } + } + change_spiritual_fulfillment = major_spiritual_fulfillment_value + if = { + limit = { + root ?= scope:cleric + } + custom_tooltip = clerical_hesitation_low_player_tt + } + else = { + custom_tooltip = clerical_hesitation_low_tt + } + } + } + #Opinion effects + scope:target.holder ?= { + #Hide this info from the cleric secondary_recipient + if = { + limit = { + root ?= scope:secondary_recipient + } + hidden_effect = { + add_opinion = { + target = scope:actor + modifier = demanded_my_title_opinion + opinion = -50 + } + } + } + else = { + add_opinion = { + target = scope:actor + modifier = demanded_my_title_opinion + opinion = -50 + } + } + if = { + limit = { + scope:secondary_recipient = { + is_ai = yes + } + } + hidden_effect = { + add_opinion = { + target = scope:secondary_recipient + modifier = demanded_my_title_opinion + opinion = -30 + } + } + } + } + if = { + limit = { + scope:recipient = { + NOT = { + this = scope:target.holder + } + } + } + scope:recipient ?= { + #Hide this info from the cleric secondary_recipient + if = { + limit = { + root ?= scope:secondary_recipient + } + hidden_effect = { + add_opinion = { + target = scope:actor + modifier = demanded_my_title_opinion + opinion = -25 + } + } + } + else = { + add_opinion = { + target = scope:actor + modifier = demanded_my_title_opinion + opinion = -25 + } + } + + + if = { + limit = { + scope:secondary_recipient = { + is_ai = yes + } + } + hidden_effect = { + add_opinion = { + target = scope:secondary_recipient + modifier = demanded_my_title_opinion + opinion = -20 + } + } + } + } + } + if = { + limit = { + is_ai = yes + } + add_opinion = { + target = scope:secondary_recipient + modifier = clerical_transfer_title_opinion + opinion = { + value = 10 + if = { + limit = { + highest_held_title_tier < scope:target.tier + } + multiply = 8 + } + else_if = { + limit = { + highest_held_title_tier = scope:target.tier + } + multiply = 5 + } + else_if = { + limit = { + highest_held_title_tier_minus_one = scope:target.tier + } + multiply = 3 + } + else_if = { + limit = { + highest_held_title_tier_minus_two = scope:target.tier + } + multiply = 2 + } + } + } + } + #Send toast to actor to confirm that interaction option costs have been applied + if = { + limit = { + OR = { + scope:promise_church_succession = yes + scope:donate_faith = yes + AND = { + scope:use_hook = yes + has_usable_hook = scope:secondary_recipient + } + scope:offer_pilgrimage = yes + scope:threaten_priest = yes + } + } + trigger_event = pam_interactions_events.0038 + #You promised the church could inherit this title if it is ever without heirs + if = { + limit = { + scope:promise_church_succession = yes + } + scope:actor = { + set_fallback_succession_title = scope:secondary_recipient.primary_title + } + scope:actor = { + custom_tooltip = church_fallback_succession_promise_tt + } + } + if = { + limit = { + scope:donate_faith = yes + } + pay_short_term_gold = { + target = scope:secondary_recipient + gold = scope:actor.medium_gold_value + } + } + if = { + limit = { + scope:use_hook = yes + has_usable_hook = scope:secondary_recipient + } + use_hook = scope:secondary_recipient + } + if = { + limit = { + scope:offer_hook = yes + } + scope:secondary_recipient = { + add_hook = { + type = strong_obligation_hook + target = scope:actor + } + } + } + pam_offer_pilgrimage_effect = { + ACTOR = scope:actor + CLERIC = scope:secondary_recipient + } + if = { + limit = { + scope:threaten_priest = yes + } + if = { + limit = { + scope:secondary_recipient = { + this = scope:actor.faith.religious_head + } + } + change_spiritual_fulfillment = massive_spiritual_fulfillment_loss + add_piety_experience = massive_piety_loss + custom_tooltip = hof_increase_piety_sp_fulfillment_loss_secondary_tt + } + else = { + change_spiritual_fulfillment = major_spiritual_fulfillment_loss + add_piety_experience = major_piety_loss + } + scope:secondary_recipient = { + add_opinion = { + modifier = threatened_church_opinion + target = scope:actor + opinion = -50 + } + } + } + } + #Catalyst towards saeculum_obscurum + if = { + limit = { + #Only fire catalyst if clergyman is choosing a more immoral holder (has decently high hesitation) + clerical_hesitation_claim_interaction_value >= -2 + any_character_situation = { + this = situation:the_christian_church + } + situation:the_christian_church = { + OR = { + situation_top_has_catalyst = catalyst_ecclesiastical_transfer_land_interaction + situation_top_has_catalyst = catalyst_ecclesiastical_transfer_land_interaction_major + } + } + } + situation:the_christian_church = { + if = { + limit = { + scope:target.tier >= tier_kingdom + } + trigger_situation_catalyst = catalyst_ecclesiastical_transfer_land_interaction_major + } + else = { + trigger_situation_catalyst = catalyst_ecclesiastical_transfer_land_interaction + } + } + + } +} + +ecclesiastic_transfer_land_interaction_transfer_effect = { + #Transfer vassal + #Need to inform player of why they were just transferred + #Players are only valid if it is their primary title being transfered + if = { + limit = { + scope:target.holder ?= { + NOT = { + this = scope:recipient + } + is_ai = no + } + } + #transfer vassal + if = { + limit = { + scope:target.holder = { is_governor_or_admin_count = no } + } + scope:target.holder = { + add_to_list = already_transfered + every_vassal_or_below = { + limit = { + highest_held_title_tier >= tier_county + } + add_to_list = already_transfered + } + } + create_title_and_vassal_change = { + type = granted + save_scope_as = change + add_claim_on_loss = no + } + scope:target.holder = { + change_liege = { + liege = scope:actor + change = scope:change + } + } + resolve_title_and_vassal_change = scope:change + + scope:target.holder = { + #Notification event they're being transferred + trigger_event = pam_interactions_events.0037 + } + } + #Admin - needs title revoked + else = { + every_held_title = { + limit = { + any_this_title_or_de_jure_above = { + this = scope:target + } + } + add_to_list = admin_target_transfer + } + hidden_effect = { + create_title_and_vassal_change = { + type = revoked + save_scope_as = change + add_claim_on_loss = yes + } + every_in_list = { + list = admin_target_transfer + change_title_holder = { + holder = scope:recipient + change = scope:change + } + } + resolve_title_and_vassal_change = scope:change + } + scope:target.holder = { + #Notification event to dispossessed admin + trigger_event = pam_interactions_events.0039 + } + } + } + #Transfer vassal if it is primary title of its holder + else_if = { + limit = { + scope:target.holder.primary_title ?= scope:target + scope:target.holder = { + highest_held_title_tier = scope:target.tier + is_governor_or_admin_count = no + } + OR = { + #already low enough tier to transfer + scope:target.holder.highest_held_title_tier < scope:actor.highest_held_title_tier + #Will be low enough tier to transfer + scope:target.holder = { + NOT = { + any_held_title = { + NOT = { + this = scope:target + } + tier = scope:target.tier + } + } + } + } + } + scope:target.holder = { save_scope_as = old_holder } + #Need to transfer vassals if getting taken down a tier + if = { + limit = { + #Will be low enough tier to transfer + scope:target.holder = { + NOT = { + any_held_title = { + NOT = { + this = scope:target + } + tier >= scope:target.tier + } + } + } + } + scope:old_holder = { + every_vassal = { + limit = { + highest_held_title_tier >= tier_county + primary_title = { + any_this_title_or_de_jure_above = { + this = scope:target + } + } + highest_held_title_tier >= scope:target.tier_minus_one + is_governor_or_admin_count = no + } + add_to_list = transfer_vassals + } + } + } + #Transferring title still if needed to vassalize recipient + if = { + limit = { + scope:target.tier >= scope:actor.highest_held_title_tier + } + create_title_and_vassal_change = { + type = granted + save_scope_as = change + add_claim_on_loss = yes + } + scope:target = { + change_title_holder = { + holder = scope:actor + change = scope:change + } + } + resolve_title_and_vassal_change = scope:change + } + scope:old_holder = { + add_to_list = already_transfered + every_vassal_or_below = { + limit = { + + } + add_to_list = already_transfered + } + } + custom_tooltip = clergy_transfer_vassal_tt + hidden_effect = { + create_title_and_vassal_change = { + type = granted + save_scope_as = change + add_claim_on_loss = no + } + scope:old_holder = { + change_liege = { + liege = scope:actor + change = scope:change + } + } + resolve_title_and_vassal_change = scope:change + } + } + #transfer the title without the holder + else = { + scope:target ?= { + add_to_list = titles_to_grant + } + } + scope:target ?= { + #Revoke titles from admins in the transfer zone + every_in_de_jure_hierarchy = { + limit = { + tier >= tier_county + holder ?= { + is_vassal_or_below_of = scope:recipient + is_governor_or_admin_count = yes + } + NOT = { is_in_list = titles_to_grant } + } + add_to_list = admin_title_losses + } + hidden_effect = { + create_title_and_vassal_change = { + type = revoked + save_scope_as = change + add_claim_on_loss = yes + } + every_in_list = { + list = admin_title_losses + change_title_holder = { + holder = scope:recipient + change = scope:change + } + } + resolve_title_and_vassal_change = scope:change + } + + #Transfer vassals + every_in_de_jure_hierarchy = { + limit = { + exists = holder + holder = { + is_governor_or_admin_count = no + } + } + #Transfer vassals/sub-vassals of recipient that belong under target title + #At this point, target holder may be transfered and thus their vassals would not be included in this + if = { + limit = { + holder = { + highest_held_title_tier >= tier_county + any_liege_or_above = { + this = scope:recipient + } + primary_title = { + any_this_title_or_de_jure_above = { + this = scope:target + } + } + #Liege is also being transferred + NOT = { + any_liege_or_above = { + NOT = { + this = scope:target.holder + } + primary_title = { + any_this_title_or_de_jure_above = { + this = scope:target + } + } + } + } + NOR = { + is_in_list = transfer_vassals + is_in_list = already_transfered + } + highest_held_title_tier < scope:actor.highest_held_title_tier + } + } + holder = { add_to_list = transfer_vassals } + } + } + } + #transfer title(s) + if = { + limit = { + any_in_list = { + list = titles_to_grant + count >= 1 + } + } + create_title_and_vassal_change = { + type = granted + save_scope_as = change + add_claim_on_loss = yes + } + every_in_list = { + list = titles_to_grant + limit = { + tier >= tier_county + } + change_title_holder = { + holder = scope:actor + change = scope:change + } + } + resolve_title_and_vassal_change = scope:change + } + #transfer vassals + if = { + limit = { + any_in_list = { + list = transfer_vassals + count >= 1 + any_held_title = { + is_landless_type_title = no + NOT = { + is_in_list = titles_to_grant + } + } + } + } + if = { + limit = { + any_in_list = { + list = transfer_vassals + this = scope:target.holder + } + } + custom_tooltip = clergy_transfer_vassal_tt + } + hidden_effect = { + create_title_and_vassal_change = { + type = granted + save_scope_as = change + add_claim_on_loss = yes + } + every_in_list = { + list = transfer_vassals + change_liege = { + liege = scope:actor + change = scope:change + } + } + resolve_title_and_vassal_change = scope:change + } + } + #Make sure recipient isn't sneakily holding onto titles beneath the target title + if = { + limit = { + scope:recipient = { + NOT = { + is_vassal_of = scope:actor + } + } + } + scope:recipient = { + every_held_title = { + limit = { + tier >= tier_county + any_this_title_or_de_jure_above = { + this = scope:target + } + } + add_to_list = recipient_mop_up + } + } + hidden_effect = { + create_title_and_vassal_change = { + type = granted + save_scope_as = change + add_claim_on_loss = yes + } + every_in_list = { + list = recipient_mop_up + limit = { + tier >= tier_county + } + change_title_holder = { + holder = scope:actor + change = scope:change + } + } + resolve_title_and_vassal_change = scope:change + } + } + if = { + limit = { + scope:target.tier >= highest_held_title_tier_minus_one + } + create_character_memory = { + type = negotiated_for_land_memory + participants = { + recipient = scope:recipient + } + } + scope:new_memory = { + set_variable = { + name = target_title + value = scope:target + } + } + } + if = { + limit = { + scope:target.tier >= scope:recipient.highest_held_title_tier_minus_one + } + scope:recipient = { + create_character_memory = { + type = gave_away_land_memory + participants = { + actor = scope:actor + } + } + scope:new_memory = { + set_variable = { + name = target_title + value = scope:target + } + } + } + } +} + +pam_negotiate_land_possible_refusal_notificaton_effect = { + if = { + limit = { + scope:target.tier >= scope:recipient.highest_held_title_tier_minus_one + scope:recipient = { + has_legitimacy = no + } + } + scope:recipient = { custom_tooltip = refuse_ecclesiastic_land_transfer_penalty_no_legit_tt } + } + else_if = { + limit = { + scope:recipient = { + has_legitimacy = no + } + } + scope:recipient = { custom_tooltip = refuse_ecclesiastic_land_transfer_penalty_minor_no_legit_tt } + } + else_if = { + limit = { + scope:target.tier >= scope:recipient.highest_held_title_tier_minus_one + } + scope:recipient = { custom_tooltip = refuse_ecclesiastic_land_transfer_penalty_tt } + } + else = { + scope:recipient = { custom_tooltip = refuse_ecclesiastic_land_transfer_penalty_minor_tt } + } +} +clergy_land_refusal_legitimacy_piety_effect = { + if = { + limit = { + scope:target.tier >= scope:recipient.highest_held_title_tier_minus_one + } + scope:recipient = { + add_piety = clergy_land_refusal_large_piety_value + if = { + limit = { + has_legitimacy = yes + } + add_legitimacy = clergy_land_refusal_large_legitimacy_value + } + else = { + add_prestige = clergy_land_refusal_large_prestige_value + } + } + } + else = { + scope:recipient = { + add_piety = clergy_land_refusal_small_piety_value + if = { + limit = { + has_legitimacy = yes + } + add_legitimacy = clergy_land_refusal_small_legitimacy_value + } + else = { + add_prestige = clergy_land_refusal_small_prestige_value + } + } + } +} + +pam_available_negotiation_methods_tooltip_effect = { + #show tooltips + if = { + limit = { + pam_forced_negotiate_land_success_trigger = yes + } + #Do not show AI behaviour tooltips if this is recipient viewing + if = { + limit = { + NOT = { exists = scope:recipient_event } + } + custom_tooltip = pam_clergy_land_forced_success_tt + custom_tooltip = pam_negotiate_land_force_by_tt + } + #FORCED FIRST + if = { + limit = { + pam_negotiate_land_forced_hook_trigger = yes + } + custom_tooltip = pam_forced_negotiate_land_hook_tt + } + if = { + limit = { + pam_negotiate_land_forced_relation_trigger = yes + } + custom_tooltip = pam_forced_negotiate_land_relation_tt + } + if = { + limit = { + pam_negotiate_land_forced_piety_level_trigger = yes + } + if = { + limit = { + scope:recipient.piety_level = 0 + } + custom_tooltip = pam_forced_negotiate_land_piety_level_1_tt + } + else = { + custom_tooltip = pam_forced_negotiate_land_piety_level_2_tt + } + } + if = { + limit = { + pam_negotiate_land_forced_legitimacy_level_trigger = yes + } + if = { + limit = { + scope:recipient.legitimacy_level = 0 + } + custom_tooltip = pam_forced_negotiate_land_legitimacy_level_1_tt + } + else = { + custom_tooltip = pam_forced_negotiate_land_legitimacy_level_2_tt + } + } + if = { + limit = { + pam_negotiate_land_forced_gold_trigger = yes + } + show_as_tooltip = { + if = { + limit = { + has_treasury = yes + } + pay_short_term_treasury = { + target = scope:recipient + gold = scope:recipient.pam_transfer_land_gold_value + } + } + else = { + pay_short_term_gold = { + target = scope:recipient + gold = scope:recipient.pam_transfer_land_gold_value + } + } + } + } + } + else = { + #Do not show AI behaviour tooltips if this is recipient viewing + if = { + limit = { + NOT = { exists = scope:recipient_event } + } + custom_tooltip = pam_clergy_land_possible_success_tt + } + } + + if = { + limit = { + pam_possible_negotiate_land_success_trigger = yes + } + #Do not show AI behaviour tooltips if this is recipient viewing + if = { + limit = { + NOT = { exists = scope:recipient_event } + } + custom_tooltip = pam_negotiate_land_possible_by_tt + } + #POSSIBLE NEXT + if = { + limit = { + pam_negotiate_land_possible_hook_trigger = yes + pam_negotiate_land_forced_hook_trigger = no + } + custom_tooltip = pam_possible_negotiate_land_hook_tt + } + if = { + limit = { + pam_negotiate_land_possible_relation_trigger = yes + pam_negotiate_land_forced_relation_trigger = no + } + custom_tooltip = pam_possible_negotiate_land_relation_tt + } + if = { + limit = { + pam_negotiate_land_possible_piety_level_trigger = yes + pam_negotiate_land_forced_piety_level_trigger = no + } + custom_tooltip = pam_possible_negotiate_land_piety_level_tt + } + if = { + limit = { + pam_negotiate_land_possible_legitimacy_level_trigger = yes + pam_negotiate_land_forced_legitimacy_level_trigger = no + } + custom_tooltip = pam_possible_negotiate_land_legitimacy_level_tt + } + if = { + limit = { + pam_negotiate_land_possible_gold_trigger = yes + pam_negotiate_land_forced_gold_trigger = no + } + show_as_tooltip = { + pam_negotiate_land_gold_effect = yes + } + } + } +} +pam_negotiate_land_hook_effect = { + use_hook = scope:recipient +} +pam_negotiate_land_relation_accept_effect = { + if = { + limit = { + has_relation_best_friend = scope:recipient + } + remove_relation_best_friend = scope:recipient + } + else_if = { + limit = { + has_relation_friend = scope:recipient + } + remove_relation_friend = scope:recipient + } + if = { + limit = { + has_relation_soulmate = scope:recipient + } + remove_relation_soulmate = scope:recipient + } + if = { + limit = { + has_relation_lover = scope:recipient + } + remove_relation_lover = scope:recipient + } + if = { + limit = { + has_relation_crush = scope:recipient + } + remove_relation_crush = scope:recipient + } + if = { + limit = { + has_relation_student = scope:recipient + } + remove_relation_student = scope:recipient + } + if = { + limit = { + has_relation_mentor = scope:recipient + } + remove_relation_mentor = scope:recipient + } + if = { + limit = { + has_relation_guardian = scope:recipient + } + remove_relation_guardian = scope:recipient + } + if = { + limit = { + has_relation_ward = scope:recipient + } + remove_relation_ward = scope:recipient + } + if = { + limit = { + has_relation_potential_friend = scope:recipient + } + remove_relation_potential_friend = scope:recipient + } + if = { + limit = { + has_relation_potential_lover = scope:recipient + } + remove_relation_potential_lover = scope:recipient + } + if = { + limit = { + has_relation_blood_brother = scope:recipient + } + remove_relation_blood_brother = scope:recipient + } + if = { + limit = { + has_relation_disciple = scope:recipient + } + remove_relation_disciple = scope:recipient + } + if = { + limit = { + has_relation_elder = scope:recipient + } + remove_relation_elder = scope:recipient + } +} +pam_negotiate_land_relation_effect = { + pam_negotiate_land_relation_accept_effect = yes + if = { + limit = { + exists = scope:forceable_relation + } + custom_tooltip = recipient_becomes_potential_rival_tt + hidden_effect = { + set_relation_potential_rival = { + target = scope:recipient + reason = rival_quarreled_over_land + } + } + change_spiritual_fulfillment = medium_spiritual_fulfillment_loss + scope:recipient = { + change_spiritual_fulfillment = massive_spiritual_fulfillment_loss + } + } + else = { + custom_tooltip = recipient_becomes_rival_tt + hidden_effect = { + set_relation_rival = { + target = scope:recipient + reason = rival_quarreled_over_land + } + } + change_spiritual_fulfillment = massive_spiritual_fulfillment_loss + scope:recipient = { + change_spiritual_fulfillment = massive_spiritual_fulfillment_loss + } + } +} +pam_negotiate_land_piety_effect = { + if = { + limit = { + pam_negotiate_land_forced_piety_level_trigger = yes + } + if = { + limit = { + scope:recipient.piety_level = 0 + } + add_piety_experience = major_piety_loss + scope:recipient = { add_piety_experience = massive_piety_loss } + } + else = { + add_piety_experience = massive_piety_loss + scope:recipient = { add_piety_level = -1 } + } + } + else = { + add_piety_level = -1 + scope:recipient = { add_piety_level = -2 } + } +} +pam_negotiate_land_legitimacy_effect = { + if = { + limit = { + pam_negotiate_land_forced_legitimacy_level_trigger = yes + } + if = { + limit = { + scope:recipient.legitimacy_level = 0 + } + add_legitimacy = medium_legitimacy_loss + scope:recipient = { add_legitimacy = major_legitimacy_loss } + } + else = { + add_legitimacy = major_legitimacy_loss + scope:recipient = { add_legitimacy_level = -1 } + } + } + else = { + add_legitimacy_level = -1 + scope:recipient = { add_legitimacy_level = -2 } + } +} +pam_negotiate_land_gold_effect = { + if = { + limit = { + has_treasury = yes + } + pay_short_term_treasury = { + target = scope:recipient + gold = scope:recipient.pam_transfer_land_gold_value + } + } + else = { + pay_short_term_gold = { + target = scope:recipient + gold = scope:recipient.pam_transfer_land_gold_value + } + } +} +pam_negotiate_land_tracking_variable_effect = { + scope:recipient = { + if = { + limit = { + has_variable = clergy_land_granted + var:clergy_land_granted <= scope:target.tier + } + remove_variable = clergy_land_granted + custom_tooltip = clergy_land_request_reduction_tt + set_variable = { + name = clergy_land_granted + value = scope:target.tier + years = 5 + } + } + else_if = { + limit = { + NOT = { + has_variable = clergy_land_granted + } + } + custom_tooltip = clergy_land_request_reduction_tt + set_variable = { + name = clergy_land_granted + value = scope:target.tier + years = 5 + } + } + } +} + +###################### +### RITE DIVERGENCE DRIFT +###################### + + +@hor_drift_forward_cap = 40 +@hor_drift_backward_floor = 5 + +@hor_drift_step_high = 20 +@hor_drift_step_normal = 10 +@hor_drift_step_low = 5 + +@hor_drift_step_high_neg = -20 +@hor_drift_step_normal_neg = -10 +@hor_drift_step_low_neg = -5 + +@hor_drift_low_fervor = 40 +@hor_drift_high_fervor = 70 + +rite_yearly_hor_divergence_drift_effect = { + if = { + limit = { + this != faith.main_rite + # We leave rites that are already heretical alone, since heresy already covers that range + "divergence(faith.main_rite)" < faith.heresy_threshold + head_of_rite ?= { + is_available_ai_adult = yes + NOT = { has_character_flag = hor_already_drifted_rite_flag } + } + } + random = { + chance = { + value = 4 + # Low fervor: lots of room for reinterpretation + if = { + limit = { faith.fervor <= @hor_drift_low_fervor } + add = 6 + } + # Stable faith: rare drift + if = { + limit = { faith.fervor >= @hor_drift_high_fervor } + add = -2 + } + # Unfulfilled HoR's do changes more often + if = { + limit = { + head_of_rite ?= { + spiritual_fulfillment <= 0 + } + } + add = 4 + } + if = { + limit = { head_of_rite ?= { has_trait = heresiarch } } + add = 25 + } + min = 1 + } + + rite_yearly_hor_divergence_drift_apply_effect = yes + } + } +} + +rite_yearly_hor_divergence_drift_apply_effect = { + save_scope_as = diverged_rite + head_of_rite = { save_scope_as = diverged_hor } + + # Snapshot the rite's current tenets and (HoR-known) doctrines so we can identify what change_rite_divergence swapped in. + every_rite_tenet = { + add_to_list = drift_tenets_before + } + scope:diverged_hor = { + every_character_doctrine = { + rite_filter = scope:diverged_rite + add_to_list = drift_doctrines_before + } + } + + random_list = { + 100 = { + trigger = { + "divergence(faith.main_rite)" <= 40 + } + modifier = { + factor = 0.5 + "divergence(faith.main_rite)" >= 30 + } + modifier = { + # Low fervor faiths drift outward more readily. + factor = 1.5 + faith.fervor <= @hor_drift_low_fervor + } + modifier = { + factor = 0.6 + faith.fervor >= @hor_drift_high_fervor + } + + save_scope_value_as = { name = diverged_change value = 1 } + rite_yearly_hor_divergence_drift_forward_pick_effect = yes + } + 100 = { + trigger = { + "divergence(faith.main_rite)" >= 10 + faith.rite_growth_rites_needed <= 0 + trigger_if = { + limit = { + exists = faith.religious_head + } + scope:diverged_hor = { + OR = { + opinion = { + target = scope:diverged_rite.faith.religious_head + value >= 50 + } + has_dread_level_towards = { + target = scope:diverged_rite.faith.religious_head + level >= 1 + } + } + } + } + trigger_else = { + always = yes + } + } + modifier = { + # Mirror the forward throttle: when divergence is small there's less room to walk it back. + factor = 0.5 + "divergence(faith.main_rite)" < 20 + } + modifier = { + factor = 1.3 + faith.fervor >= @hor_drift_high_fervor + } + modifier = { + # Consolidation belongs to high-fervor faiths; sub-70 fervor is the divergence regime. + factor = 0.2 + faith.fervor < @hor_drift_high_fervor + } + modifier = { + # Without a HoF to anchor consolidation, backward drift is much rarer. + factor = 0.2 + NOT = { exists = faith.religious_head } + } + save_scope_value_as = { name = diverged_change value = -1 } + rite_yearly_hor_divergence_drift_backward_pick_effect = yes + } + } +} + +rite_yearly_hor_divergence_drift_forward_pick_effect = { + random_list = { + 1 = { + # Only allow a +20 jump if we're far below the cap. + trigger = { + "divergence(faith.main_rite)" <= 20 + } + modifier = { + factor = 0.4 + "divergence(faith.main_rite)" >= 15 + } + save_scope_value_as = { name = diverged_change value = @hor_drift_step_high } + change_rite_divergence = { + value = @hor_drift_step_high + override_tenets_first = no + } + } + 1 = { + trigger = { + "divergence(faith.main_rite)" <= 20 + } + modifier = { + factor = 0.4 + "divergence(faith.main_rite)" >= 15 + } + save_scope_value_as = { name = diverged_change value = @hor_drift_step_high } + change_rite_divergence = { + value = @hor_drift_step_high + override_tenets_first = yes + } + } + 3 = { + trigger = { + "divergence(faith.main_rite)" <= 30 + } + modifier = { + factor = 0.5 + "divergence(faith.main_rite)" >= 25 + } + save_scope_value_as = { name = diverged_change value = @hor_drift_step_normal } + change_rite_divergence = { + value = @hor_drift_step_normal + override_tenets_first = no + } + } + 3 = { + trigger = { + "divergence(faith.main_rite)" <= 30 + } + modifier = { + factor = 0.5 + "divergence(faith.main_rite)" >= 25 + } + save_scope_value_as = { name = diverged_change value = @hor_drift_step_normal } + change_rite_divergence = { + value = @hor_drift_step_normal + override_tenets_first = yes + } + } + 8 = { + trigger = { + "divergence(faith.main_rite)" <= 40 + } + save_scope_value_as = { name = diverged_change value = @hor_drift_step_low } + change_rite_divergence = { + value = @hor_drift_step_low + override_tenets_first = no + } + } + 8 = { + trigger = { + "divergence(faith.main_rite)" <= 40 + } + save_scope_value_as = { name = diverged_change value = @hor_drift_step_low } + change_rite_divergence = { + value = @hor_drift_step_low + override_tenets_first = yes + } + } + } + rite_yearly_hor_divergence_drift_commit_effect = yes +} + +rite_yearly_hor_divergence_drift_backward_pick_effect = { + random_list = { + 1 = { + trigger = { + "divergence(faith.main_rite)" >= 25 + } + save_scope_value_as = { name = diverged_change value = @hor_drift_step_high_neg } + change_rite_divergence = { + value = @hor_drift_step_high_neg + override_tenets_first = no + } + } + 1 = { + trigger = { + "divergence(faith.main_rite)" >= 25 + } + save_scope_value_as = { name = diverged_change value = @hor_drift_step_high_neg } + change_rite_divergence = { + value = @hor_drift_step_high_neg + override_tenets_first = yes + } + } + 3 = { + trigger = { + "divergence(faith.main_rite)" >= 15 + } + save_scope_value_as = { name = diverged_change value = @hor_drift_step_normal_neg } + change_rite_divergence = { + value = @hor_drift_step_normal_neg + override_tenets_first = no + } + } + 3 = { + trigger = { + "divergence(faith.main_rite)" >= 15 + } + save_scope_value_as = { name = diverged_change value = @hor_drift_step_normal_neg } + change_rite_divergence = { + value = @hor_drift_step_normal_neg + override_tenets_first = yes + } + } + 8 = { + trigger = { + "divergence(faith.main_rite)" >= 10 + } + save_scope_value_as = { name = diverged_change value = @hor_drift_step_low_neg } + change_rite_divergence = { + value = @hor_drift_step_low_neg + override_tenets_first = no + } + } + 8 = { + trigger = { + "divergence(faith.main_rite)" >= 10 + } + save_scope_value_as = { name = diverged_change value = @hor_drift_step_low_neg } + change_rite_divergence = { + value = @hor_drift_step_low_neg + override_tenets_first = yes + } + } + } + rite_yearly_hor_divergence_drift_commit_effect = yes +} + +rite_yearly_hor_divergence_drift_commit_effect = { + random_rite_tenet = { + limit = { + NOT = { is_in_list = drift_tenets_before } + } + save_scope_as = diverged_added_tenet + } + scope:diverged_hor = { + random_character_doctrine = { + rite_filter = scope:diverged_rite + limit = { + NOT = { is_in_list = drift_doctrines_before } + } + save_scope_as = diverged_added_doctrine + } + } + + if = { + limit = { + OR = { + exists = scope:diverged_added_tenet + exists = scope:diverged_added_doctrine + } + } + scope:diverged_hor = { + add_character_flag = hor_already_drifted_rite_flag + } + if = { + limit = { scope:diverged_change <= -1 } + scope:diverged_rite.faith = { + change_fervor = { + value = notable_fervor_value + desc = fervor_gain_pam_rite_consolidated + } + } + } + else_if = { + limit = { scope:diverged_change >= 1 } + scope:diverged_rite.faith = { + change_fervor = { + value = significant_fervor_loss + desc = fervor_loss_pam_rite_diverged + } + } + } + rite_yearly_hor_divergence_drift_notify_effect = yes + } +} + +# Notify every ruler of the rite + the religious head, via letter event. +rite_yearly_hor_divergence_drift_notify_effect = { + faith = { + every_faith_ruler = { + limit = { + rite = scope:diverged_rite + this != scope:diverged_hor + } + trigger_event = pam_tenet_events.0004 + } + } + # Religious head (if any) gets the letter too, even if they aren't iterated above. + faith.religious_head ?= { + if = { + limit = { + NOT = { rite = scope:diverged_rite } + this != scope:diverged_hor + } + trigger_event = pam_tenet_events.0004 + } + } +} + +pam_declare_rite_heresy_effect = { + custom_tooltip = { + text = pam_declare_rite_heresy_effect_tt + detach_rite_to_new_faith = { + target = scope:heresy_rite + } + } + # Heresy rite types ship convert = no so they cannot be joined before the bull; branding has to flip it or nothing can convert in. + scope:heresy_rite = { + set_can_convert_to_rite = yes + } + faith = { + change_fervor = { + value = notable_fervor_value + desc = fervor_gain_pam_rite_declared_heresy + } + set_variable = { + name = rite_growth_recent_heresy + value = yes + days = rite_growth_heresy_cooldown_days + } + } + # The declaring faith repudiates the now-heretical rite, so its core tenets lose standing there. + if = { + limit = { faith = { has_tenet_popularity_trigger = yes } } + faith = { save_scope_as = heresy_declaring_faith } + scope:heresy_rite = { + every_rite_tenet = { + status = core + save_scope_as = heresy_rite_tenet + scope:heresy_declaring_faith = { + change_tenet_popularity = { + target = scope:heresy_rite_tenet + change = major_tenet_popularity_loss + } + } + } + } + } + if = { + limit = { + exists = scope:heresy_rite + NOT = { scope:heresy_rite.faith = faith } + } + scope:heresy_rite.faith = { + every_faith_character = { + limit = { + is_ruler = yes + this != scope:bull_issuer + } + trigger_event = { id = pam_decision_events.0013 days = 1 } + } + } + } +} + +#This is only for use in pam_cathedral_01, pam_cathedral_02, and pam_cathedral_03 +pam_cathedral_art_contribution_subject_event_effect = { + save_scope_as = contributor + scope:contributor = { + trigger_event = { + id = $EVENT$ + days = { 5 20 } + } + } +} + +#This is only for use in pam_cathedral_01, pam_cathedral_02, and pam_cathedral_03 +cathedral_great_project_funded_started_event_sender_effect = { + scope:founder = { + trigger_event = pam_great_projects_events.0005 + } + scope:owner = { + if = { + limit = { + this != scope:founder + } + trigger_event = pam_great_projects_events.0005 + } + } + every_contribution = { + limit = { + contribution_is_funded = yes + } + contributor ?= { + if = { + limit = { + this != scope:owner + this != scope:founder + } + save_scope_as = contributor + trigger_event = pam_great_projects_events.0005 + } + } + } +} + +cathedral_great_project_completed_event_sender_effect = { + scope:founder = { + trigger_event = pam_great_projects_events.0020 + } + scope:owner = { + if = { + limit = { + this != scope:founder + } + trigger_event = pam_great_projects_events.0020 + } + } + scope:founder_heir ?= { + if = { + limit = { + is_alive = yes + this != scope:founder + this != scope:owner + } + trigger_event = pam_great_projects_events.0020 + } + } + every_contribution = { + limit = { + contribution_is_funded = yes + } + contributor ?= { + if = { + limit = { + this != scope:owner + this != scope:founder + NOT = { this ?= scope:founder_heir } + } + save_scope_as = contributor + trigger_event = pam_great_projects_events.0020 + } + } + } +} + +# Create a New Ecclesiastical Title as HoF - on_accept +pam_create_new_ecclesiastical_title_interaction_effect = { + scope:secondary_recipient = { + save_scope_as = new_ecclesiastical_holder + } + scope:recipient = { + save_scope_as = kingdom_holder + if = { + limit = { + scope:new_ecclesiastical_holder = { + NOT = { + is_courtier_of = scope:kingdom_holder + } + is_ruler = no + } + } + add_courtier = scope:new_ecclesiastical_holder + } + if = { + limit = { + scope:new_ecclesiastical_holder = { + NOT = { is_councillor_of = scope:kingdom_holder } + } + } + assign_councillor_type = { + type = councillor_court_chaplain + remove_existing_councillor = yes + target = scope:new_ecclesiastical_holder + } + } + } + scope:target = { + save_scope_as = target_kingdom + } + scope:actor = { + if = { + limit = { + any_character_situation = { + situation_type = the_christian_church + situation_top_has_catalyst = catalyst_the_christian_church_clerical_region_created + } + } + situation:the_christian_church = { + trigger_situation_catalyst = catalyst_the_christian_church_clerical_region_created + } + } + send_interface_toast = { + type = event_toast_effect_good + title = create_new_ecclesiastical_title_toast + left_icon = scope:actor + right_icon = scope:new_ecclesiastical_holder + custom_tooltip = { + text = create_new_ecclesiastical_title_effect_tt + create_title_and_vassal_change = { + type = created + save_scope_as = change + add_claim_on_loss = no + } + scope:target_kingdom = { + title_capital_county = { + save_scope_as = clerical_region_anchor_county + random_county_province = { + limit = { + is_county_capital = yes + } + save_scope_as = region_capital + create_clerical_region = { + domicile_type = ecclesiastical_domicile + name = NEW_ECCLESIASTICAL_TITLE + save_scope_as = new_title + } + scope:new_title ?= { + set_coa = scope:target_kingdom + set_color_from_title = scope:target_kingdom + set_capital_county = scope:clerical_region_anchor_county + set_landless_title = yes + set_no_automatic_claims = yes + set_definitive_form = yes + change_title_holder = { + holder = scope:new_ecclesiastical_holder + change = scope:change + } + resolve_title_and_vassal_change = scope:change + } + } + } + } + } + } + reverse_add_opinion = { + target = scope:new_ecclesiastical_holder + modifier = grateful_opinion + opinion = 50 + } + } + scope:new_ecclesiastical_holder = { + if = { + limit = { + NOT = { government_has_flag = government_is_ecclesiastical } + } + change_government = ecclesiastical_government + } + faith = { + change_fervor = { + value = notable_fervor_gain + desc = fervor_gain_clerical_title_created + } + } + situation:the_christian_church ?= { + add_manual_participant = prev + } + } +} + +# Expects scope:target and scope:pam_new_archbishop, and the caller must save pam_old_archbishop first +pam_grant_ecclesiastical_title_interaction_effect = { + scope:actor = { + send_interface_toast = { + type = event_toast_effect_good + title = pam_grant_ecclesiastical_title_toast + left_icon = scope:actor + right_icon = scope:pam_new_archbishop + if = { + limit = { exists = scope:pam_old_archbishop } + custom_tooltip = { + text = pam_grant_ecclesiastical_title_deposed_effect_tt + create_title_and_vassal_change = { + type = granted + save_scope_as = change + add_claim_on_loss = no + } + scope:pam_old_archbishop = { + every_held_title = { + limit = { + OR = { + has_clerical_region = yes + is_landless_type_title = no + } + } + change_title_holder_include_vassals = { + holder = scope:pam_new_archbishop + change = scope:change + government_base = scope:pam_old_archbishop + } + } + } + resolve_title_and_vassal_change = scope:change + } + } + else = { + custom_tooltip = { + text = pam_grant_ecclesiastical_title_vacant_effect_tt + create_title_and_vassal_change = { + type = granted + save_scope_as = change + } + scope:target = { + change_title_holder_include_vassals = { + holder = scope:pam_new_archbishop + change = scope:change + } + } + resolve_title_and_vassal_change = scope:change + } + } + add_hook = { + type = granted_clerical_title_hook + target = scope:pam_new_archbishop + } + } + reverse_add_opinion = { + target = scope:pam_new_archbishop + modifier = grateful_opinion + opinion = 50 + } + } + scope:pam_old_archbishop ?= { + add_opinion = { + target = scope:actor + modifier = fp3_resentful_opinion + opinion = -40 + } + } + if = { + limit = { + scope:pam_old_archbishop ?= { rite != scope:actor.rite } + } + scope:actor.faith = { + change_fervor = { + value = significant_fervor_loss + desc = fervor_loss_pam_archbishop_deposed + } + } + } + scope:pam_new_archbishop = { + if = { + limit = { + NOT = { government_has_flag = government_is_ecclesiastical } + } + change_government = ecclesiastical_government + } + situation:the_christian_church ?= { + add_manual_participant = prev + } + } + if = { + limit = { + situation:the_christian_church ?= { + situation_top_has_catalyst = catalyst_clergy_elevated_to_archbishopric + } + } + situation:the_christian_church = { + trigger_situation_catalyst = catalyst_clergy_elevated_to_archbishopric + } + } +} + +# Picks scope:target_character for a GHW after scope:target_kingdom is already set (e.g. bull kingdom selection). +pam_determine_ghw_target_character_from_kingdom_effect = { + scope:target_kingdom = { + random_in_de_jure_hierarchy = { + continue = { tier > tier_county } + limit = { + tier = tier_county + $FAITH$.main_rite = { + is_hostile_enough_for_holy_war_trigger = { RITE = prev.holder.rite } + } + holder = { + highest_held_title_tier >= 4 + any_realm_county = { count >= 5 } + } + } + alternative_limit = { + tier = tier_county + $FAITH$.main_rite = { + is_hostile_enough_for_holy_war_trigger = { RITE = prev.holder.rite } + } + holder = { + highest_held_title_tier >= 3 + any_realm_county = { count >= 5 } + } + } + alternative_limit = { + tier = tier_county + $FAITH$.main_rite = { + is_hostile_enough_for_holy_war_trigger = { RITE = prev.holder.rite } + } + holder = { + highest_held_title_tier >= 2 + any_realm_county = { count >= 5 } + } + } + alternative_limit = { + tier = tier_county + $FAITH$.main_rite = { + is_hostile_enough_for_holy_war_trigger = { RITE = prev.holder.rite } + } + } + alternative_limit = { + tier = tier_kingdom + $FAITH$.main_rite = { + is_hostile_enough_for_holy_war_trigger = { RITE = prev.holder.rite } + } + } + holder = { + save_scope_as = target_character + } + } + } +} + +pam_use_bull_selected_ghw_target_effect = { + $GHW_SPONSOR$ = { + var:pam_bull_ghw_target_kingdom = { save_scope_as = target_kingdom } + remove_variable = pam_bull_ghw_target_kingdom + } + pam_determine_ghw_target_character_from_kingdom_effect = { FAITH = $FAITH$ } +} + +# Starts an undirected GHW using the kingdom stored on the HoF by pick_crusade_target_decision. +pam_start_bull_great_holy_war_effect = { + $GHW_SPONSOR$ = { + if = { + limit = { has_variable = pam_bull_ghw_target_kingdom } + religion = { set_variable = variable_ghw_unlocked } + $FAITH$ = { trigger_event = great_holy_war.0001 } + } + } +} + +pam_bull_notify_faith_rulers_effect = { + scope:bull_issuer = { + faith = { + every_faith_character = { + limit = { + is_ruler = yes + this != scope:bull_issuer + } + trigger_event = { id = pam_bull_events.0004 days = 1 } + } + } + } +} + +pam_apply_great_schism_creation_effect = { + if = { + limit = { NOT = { has_global_variable = pam_great_schism_happened } } + set_global_variable = { + name = pam_great_schism_happened + value = current_year + } + } + situation:the_christian_church.var:schism_mainline_rite = { save_scope_as = schism_mainline_rite } + if = { + limit = { scope:schism_mainline_rite = rite:roman_rite } + faith:catholic = { save_scope_as = schism_mainline_faith } + faith:orthodox = { save_scope_as = schism_competitor_faith } + } + else = { + faith:orthodox = { save_scope_as = schism_mainline_faith } + faith:catholic = { save_scope_as = schism_competitor_faith } + } + custom_tooltip = { + text = pam_create_great_schism_effect_tt + faith:christian_faith = { + save_scope_as = old_rite + every_faith_rite = { + limit = { rite_has_doctrine = doctrine_no_head } + change_rite_doctrine = doctrine_spiritual_head + } + } + faith:catholic = { + set_religious_head_title = title:k_papal_state + } + faith:orthodox = { + set_religious_head_title = title:k_orthodox + } + rite:roman_rite = { + save_scope_as = roman_rite + set_can_convert_to_rite = yes + set_parent_faith = { + target = faith:catholic + main = yes + } + } + rite:insular_celtic = { + set_can_convert_to_rite = yes + set_parent_faith = { + target = faith:catholic + main = no + } + } + rite:mozarabic_church = { + set_can_convert_to_rite = yes + set_parent_faith = { + target = faith:catholic + main = no + } + } + rite:ambrosian_rite = { + set_can_convert_to_rite = yes + set_parent_faith = { + target = faith:catholic + main = no + } + } + rite:byzantine_rite = { + save_scope_as = byzantine_rite + set_can_convert_to_rite = yes + set_parent_faith = { + target = faith:orthodox + main = yes + } + } + rite:georgian_rite = { + set_can_convert_to_rite = yes + set_parent_faith = { + target = faith:orthodox + main = no + } + } + rite:slavic_rite = { + set_can_convert_to_rite = yes + set_parent_faith = { + target = faith:orthodox + main = no + } + } + rite:carolingian_christianity = { + set_can_convert_to_rite = no + set_rite_enabled = no + set_parent_faith = { + target = faith:catholic + main = no + } + } + rite:beneventan_rite = { + set_can_convert_to_rite = no + set_rite_enabled = no + set_parent_faith = { + target = faith:catholic + main = no + } + } + struggle:iberian_struggle ?= { + set_faith_as_involved = rite:mozarabic_church.faith + set_faith_as_uninvolved = faith:christian_faith + } + } + show_as_tooltip = { + faith:catholic = { set_religious_head_title = title:k_papal_state } + } + hidden_effect = { + situation:the_christian_church ?= { + every_situation_participant = { + limit = { + OR = { + var:pam_schism_stance ?= flag:mainline + var:pam_schism_stance ?= flag:competitor + } + OR = { + faith = faith:christian_faith + faith = scope:schism_mainline_faith + faith = scope:schism_competitor_faith + } + NOR = { + any_held_title = { is_head_of_faith = yes } + primary_title ?= { is_holy_order = yes } + } + } + if = { + limit = { + var:pam_schism_stance ?= flag:mainline + NOT = { faith = scope:schism_mainline_faith } + } + set_character_faith = scope:schism_mainline_faith + } + else_if = { + limit = { + var:pam_schism_stance ?= flag:competitor + NOT = { faith = scope:schism_competitor_faith } + } + set_character_faith = scope:schism_competitor_faith + } + } + } + faith:christian_faith = { + every_clerical_elector_title = { + add_to_list = pam_schism_cardinalates + } + } + every_in_list = { + list = pam_schism_cardinalates + save_temporary_scope_as = pam_schism_cardinalate + if = { + limit = { + holder ?= { + OR = { + faith = faith:catholic + AND = { + faith = faith:christian_faith + OR = { + rite = rite:roman_rite + rite = rite:insular_celtic + rite = rite:mozarabic_church + rite = rite:ambrosian_rite + } + } + } + } + } + holder = { + if = { + limit = { NOT = { faith = faith:catholic } } + set_character_faith = faith:catholic + } + } + add_clerical_elector = faith:catholic + } + else_if = { + limit = { exists = holder } + holder = { + pam_destroy_cardinal_title_effect = { CARDINALATE = scope:pam_schism_cardinalate } + } + } + } + faith:christian_faith = { remove_doctrine = special_doctrine_has_clerical_electors } + # Catholicism starts with a College so AI clergy do not spam the Pope to fill vacancies + faith:catholic = { pam_seed_cardinals_effect = yes } + if = { + limit = { exists = situation:the_christian_church } + the_christian_church_set_main_power_faith_effect = yes + the_christian_church_recalculate_participant_groups_effect = yes + } + } +} + +# Rite followers move with their rites +pam_unite_miaphysite_churches_effect = { + save_scope_as = unifier + if = { + limit = { faith = faith:miaphysitism } + custom_tooltip = { + text = pam_unite_miaphysite_churches_effect_tt + faith = { save_scope_as = uniting_faith } + faith:armenian_apostolic = { + save_scope_as = absorbed_faith + remove_religious_head_title = yes + every_faith_rite = { + limit = { faith != scope:uniting_faith } + set_parent_faith = { + target = faith:miaphysitism + main = no + include_derived = no + } + } + } + } + } + else = { + custom_tooltip = { + text = pam_unite_miaphysite_churches_effect_tt + faith = { save_scope_as = uniting_faith } + faith:miaphysitism = { + save_scope_as = absorbed_faith + remove_religious_head_title = yes + every_faith_rite = { + limit = { faith != scope:uniting_faith } + set_parent_faith = { + target = faith:armenian_apostolic + main = no + include_derived = no + } + } + } + } + } + faith = { + change_fervor = { + value = medium_fervor_gain + desc = fervor_gain_mended_schism + } + } + hidden_effect = { + every_player = { + limit = { + this != root + faith = scope:uniting_faith + } + send_interface_message = { + type = event_generic_good_with_text + title = pam_unite_miaphysite_churches_message + desc = pam_unite_miaphysite_churches_message_desc + left_icon = scope:unifier + } + } + } + set_nickname_effect = { NICKNAME = nick_the_ecumenist } +} + +pam_great_schismat_effect = { + give_nickname = nick_the_schismat + dynasty ?= { + add_dynasty_modifier = { modifier = pam_caused_great_schism_dynasty_modifier } + } + if = { + limit = { NOT = { exists = dynasty } } + add_character_modifier = pam_caused_great_schism_character_modifier + } + # 0061 already announces the Schism + set_global_variable = { + name = pam_skip_tcc_phase_start_event + days = 30 + } + situation:the_christian_church = { + change_top_phase = { phase = concord } + } + save_scope_as = schismat +} + +pam_create_great_schism_effect = { + set_global_variable = { + name = pam_skip_tcc_phase_start_event + days = 30 + } + pam_apply_great_schism_creation_effect = yes + set_global_variable = pam_great_schism_decision_taken + faith:catholic = { save_scope_as = schism_western_faith } + faith:orthodox = { save_scope_as = schism_eastern_faith } + if = { + limit = { NOT = { exists = scope:schismat } } + situation:the_christian_church = { + change_top_phase = { phase = reform_phase } + } + } + situation:the_christian_church ?= { + every_situation_participant = { + limit = { + is_ruler = yes + faith.religion = religion:christianity_religion + } + trigger_event = pam_the_christian_church.0061 + } + } +} + +pam_prevent_great_schism_effect = { + custom_tooltip = pam_prevent_great_schism_aftermath_tt + give_nickname = nick_the_concordant + dynasty ?= { + add_dynasty_modifier = { modifier = pam_prevented_great_schism_dynasty_modifier } + } + if = { + limit = { NOT = { exists = dynasty } } + add_character_modifier = pam_prevented_great_schism_character_modifier + } + # 0062 already announces the Schism + set_global_variable = { + name = pam_skip_tcc_phase_start_event + days = 30 + } + situation:the_christian_church = { + change_top_phase = { phase = concord } + } +} + +# Run from either Mend the Great Schism decision, which pass the modifier pair matching their route. +# MODIFIER - dynasty modifier for the mender's dynasty. +# CHARACTER_MODIFIER - equivalent for a lowborn mender, who has no dynasty to mark. +pam_mend_great_schism_reward_effect = { + dynasty ?= { + add_dynasty_prestige = 10000 + add_dynasty_modifier = { modifier = $MODIFIER$ } + } + if = { + limit = { NOT = { exists = dynasty } } + add_character_modifier = $CHARACTER_MODIFIER$ + } + add_piety = monumental_piety_gain + add_prestige = monumental_prestige_gain + set_nickname_effect = { NICKNAME = nick_the_reconciler } +} + +# Character scope, saved so the decision tooltip, 0062 option, and seating all name the same see +# Falls back to Rome so an unheld Constantinople does not leave the faith headless +pam_save_schism_head_of_faith_effect = { + if = { + limit = { + rite = rite:byzantine_rite + exists = title:d_et_constantinople.holder + } + title:d_et_constantinople = { save_scope_as = new_head_of_faith_title } + } + else_if = { + limit = { + rite = rite:byzantine_rite + exists = title:k_orthodox.holder + } + title:k_orthodox = { save_scope_as = new_head_of_faith_title } + } + else_if = { + limit = { exists = title:k_papal_state.holder } + title:k_papal_state = { save_scope_as = new_head_of_faith_title } + } + scope:new_head_of_faith_title.holder ?= { save_scope_as = new_head_of_faith } +} + +# Needs pam_save_schism_head_of_faith_effect +pam_schism_seat_head_of_faith_effect = { + if = { + limit = { exists = scope:new_head_of_faith_title } + custom_tooltip = { + text = pam_schism_seat_head_of_faith_tt + faith:christian_faith = { + if = { + limit = { NOT = { has_doctrine = doctrine_spiritual_head } } + change_doctrine = doctrine_spiritual_head + } + set_religious_head_title = scope:new_head_of_faith_title + # Carolingian Christianity has doctrine_no_head; leave it behind once the faith has a head + hidden_effect = { + every_faith_rite = { + if = { + limit = { rite_has_doctrine = doctrine_no_head } + change_rite_doctrine = doctrine_spiritual_head + } + force_refresh_head_of_rite = yes + } + } + } + } + } +} + +# The seat kept vacant. Chalcedonianism is already headless and keeps doctrine_spiritual_head, so +# there is nothing to change - doctrine_no_head would bar Establish a Head of Faith for good. +pam_schism_leave_faith_headless_effect = { + custom_tooltip = pam_schism_leave_faith_headless_tt +} + +# Apply an ancestral Khachkar in the chosen county (for decision confirmation event). +pam_apply_ancestral_khachkar_effects = { + $LOCATION$ = { + save_scope_as = khachkar_location + set_variable = { + name = pam_khachkar_ancestor + value = $ANCESTOR$ + } + set_variable = { + name = pam_khachkar_commissioner + value = root + } + add_county_modifier = { + modifier = pam_khachkar_ancestral_county + desc = pam_khachkar_ancestral_county_custom_desc + } + } + add_prestige = medium_prestige_value + add_piety = medium_piety_value + add_legitimacy = 100 + remove_variable = pam_khachkar_ancestral_ancestor +} + +# Remember a same-faith expansion outside the see's home kingdom so later petitions are harder to accept +pam_mark_recent_same_faith_clerical_expansion_effect = { + if = { + limit = { + exists = $TITLE$ + pam_expand_target_is_same_faith_outside_home_kingdom_trigger = { + TITLE = $TITLE$ + ARCHBISHOP = $ARCHBISHOP$ + } + } + $ARCHBISHOP$ = { + hidden_effect = { + add_character_flag = { + flag = pam_recently_expanded_same_faith + years = pam_expand_same_faith_recent_years + } + } + } + } +} + +# Expand an Ecclesiastical Title as HoF - on_accept +pam_expand_ecclesiastical_title_interaction_effect = { + scope:recipient = { + save_scope_as = clerical_region_holder + # We use the picker's region and skip alternative_limit, so we do not land on a non-bordering see + if = { + limit = { + capital_province.county.clerical_region_title ?= { + has_clerical_region = yes + holder ?= scope:clerical_region_holder + } + } + capital_province.county.clerical_region_title = { + save_scope_as = clerical_region_title + } + } + } + scope:target = { + save_scope_as = target_duchy + } + # is_adjacent_to_clerical_region matches the counties expand_clerical_region would take + if = { + limit = { + exists = scope:clerical_region_title + scope:clerical_region_title = { is_adjacent_to_clerical_region = scope:target_duchy } + } + scope:actor = { + if = { + limit = { + any_character_situation = { + situation_type = the_christian_church + situation_top_has_catalyst = catalyst_the_christian_church_clerical_region_expanded + } + } + situation:the_christian_church = { + trigger_situation_catalyst = catalyst_the_christian_church_clerical_region_expanded + } + } + hidden_effect = { + send_interface_toast = { + type = event_toast_effect_good + title = expand_ecclesiastical_title_toast + left_icon = scope:clerical_region_holder + right_icon = scope:clerical_region_title + custom_tooltip = { + text = expand_ecclesiastical_title_effect_tt + scope:clerical_region_title = { + expand_clerical_region = scope:target_duchy + } + } + } + } + faith = { + change_fervor = { + value = notable_fervor_gain + desc = fervor_gain_clerical_title_expanded + } + } + } + scope:clerical_region_holder = { + if = { + limit = { + NOT = { this = scope:actor } + } + add_opinion = { + target = scope:actor + modifier = grateful_opinion + opinion = 50 + } + } + send_interface_toast = { + type = event_toast_effect_good + title = expand_ecclesiastical_title_toast + left_icon = scope:actor + right_icon = scope:clerical_region_title + custom_tooltip = expand_ecclesiastical_title_effect_tt + } + pam_mark_recent_same_faith_clerical_expansion_effect = { + TITLE = scope:target_duchy + ARCHBISHOP = this + } + } + } +} + +# Split an Ecclesiastical Title as HoF - on_accept +pam_split_ecclesiastical_title_interaction_effect = { + scope:secondary_recipient = { + save_scope_as = new_ecclesiastical_holder + } + scope:secondary_actor = { + save_scope_as = secular_ruler + } + scope:recipient = { + save_scope_as = clerical_region_holder + } + scope:secular_ruler.capital_county.clerical_region_title ?= { + save_scope_as = clerical_region_title + } + # Interaction tooltip reads on_accept before the split + show_as_tooltip = { + pam_split_ecclesiastical_title_outcome_effect = yes + } + hidden_effect = { + scope:secular_ruler = { + capital_province = { save_scope_as = region_capital } + split_clerical_region = { + name = CLERICAL_REGION_PROVINCE_TITLE_NAME + save_scope_as = new_title + } + } + # A failed split leaves scope:new_title unset + if = { + limit = { exists = scope:new_title } + pam_split_ecclesiastical_title_outcome_effect = yes + } + } +} + +# Runs twice, once for the interaction window tooltip and once for real after a successful split +pam_split_ecclesiastical_title_outcome_effect = { + scope:secular_ruler = { + if = { + limit = { + scope:new_ecclesiastical_holder = { + NOT = { + is_courtier_of = scope:secular_ruler + } + is_ruler = no + } + } + add_courtier = scope:new_ecclesiastical_holder + } + if = { + limit = { + scope:new_ecclesiastical_holder = { + NOT = { is_councillor_of = scope:secular_ruler } + } + } + assign_councillor_type = { + type = councillor_court_chaplain + remove_existing_councillor = yes + target = scope:new_ecclesiastical_holder + } + } + } + hidden_effect = { + create_title_and_vassal_change = { + type = created + save_scope_as = change + add_claim_on_loss = no + } + scope:new_title ?= { + set_coa = scope:secular_ruler.primary_title + set_color_from_title = scope:secular_ruler.primary_title + set_capital_county = scope:secular_ruler.capital_county + set_landless_title = yes + set_no_automatic_claims = yes + + change_title_holder = { + holder = scope:new_ecclesiastical_holder + change = scope:change + } + resolve_title_and_vassal_change = scope:change + } + } + scope:actor = { + if = { + limit = { + any_character_situation = { + situation_type = the_christian_church + situation_top_has_catalyst = catalyst_the_christian_church_clerical_region_split + } + } + situation:the_christian_church = { + trigger_situation_catalyst = catalyst_the_christian_church_clerical_region_split + } + } + hidden_effect = { + send_interface_toast = { + type = event_toast_effect_good + title = split_ecclesiastical_title_toast + left_icon = scope:actor + right_icon = scope:new_ecclesiastical_holder + custom_tooltip = { + text = split_ecclesiastical_title_effect_tt + } + } + } + reverse_add_opinion = { + target = scope:new_ecclesiastical_holder + modifier = grateful_opinion + opinion = 50 + } + reverse_add_opinion = { + target = scope:secondary_actor + modifier = pleased_opinion + opinion = 25 + } + if = { + # On a self-split the HoF reorganises their own region, so there is no aggrieved superior to anger + limit = { scope:recipient != scope:actor } + reverse_add_opinion = { + target = scope:recipient + modifier = angry_opinion + opinion = -50 + } + } + add_hook = { + type = favor_hook + target = scope:new_ecclesiastical_holder + } + } + if = { + # Skip the "your region was split" notification when the HoF split their own region + limit = { scope:recipient != scope:actor } + scope:recipient = { + send_interface_toast = { + type = event_toast_effect_bad + title = split_ecclesiastical_title_toast + left_icon = scope:actor + right_icon = scope:new_ecclesiastical_holder + custom_tooltip = split_ecclesiastical_title_effect_tt + } + } + } + scope:new_ecclesiastical_holder = { + if = { + limit = { + NOT = { government_has_flag = government_is_ecclesiastical } + } + change_government = ecclesiastical_government + } + } +} + +# Merge an Ecclesiastical Title as HoF - on_accept +pam_merge_new_ecclesiastical_title_interaction_effect = { + $ABSORBING_TITLE$ ?= { + save_scope_as = absorbing_title + holder ?= { save_scope_as = absorbing_holder } + } + $ABSORBED_TITLE$ = { + save_scope_as = absorbed_title + holder = { + save_scope_as = absorbed_holder + scope:absorbed_holder = { + send_interface_toast = { + type = event_toast_effect_bad + title = request_ecclesiastical_title_merger_absorbed_tt + left_icon = scope:absorbing_holder + right_icon = scope:absorbed_title + if = { + limit = { is_ai = yes } + # Absorbed region holder is angry at the initiator + add_opinion = { + target = $SENDER$ + modifier = angry_opinion + opinion = -75 + } + progress_towards_rival_effect = { + CHARACTER = $SENDER$ + OPINION = 0 + REASON = rival_ecclesiastical_title_merged + } + } + } + } + } + } + # Toast to the initiator + $SENDER$ = { + hidden_effect = { + send_interface_toast = { + type = event_toast_effect_good + title = merge_new_ecclesiastical_title_toast + left_icon = scope:absorbing_holder + right_icon = scope:absorbed_title + # Perform the region merge + custom_tooltip = { + text = merge_new_ecclesiastical_title_effect_tt + scope:absorbing_title = { + grow_clerical_region_from = scope:absorbed_title + set_variable = { + name = merge_clerical_region_cooldown + years = merge_clerical_region_cooldown_years_value + } + } + } + } + } + } + scope:absorbing_holder = { + send_interface_toast = { + type = event_toast_effect_good + title = merge_new_ecclesiastical_title_toast + left_icon = $SENDER$ + right_icon = scope:absorbed_title + custom_tooltip = merge_new_ecclesiastical_title_effect_tt + # The puppet variant sends on its own behalf, so there is no favour owed. + if = { + limit = { NOT = { this = $SENDER$ } } + if = { + limit = { is_ai = yes } + add_opinion = { + target = $SENDER$ + modifier = grateful_opinion + opinion = 50 + } + } + $SENDER$ = { + add_hook = { + type = favor_hook + target = scope:absorbing_holder + } + } + } + } + } +} + +pam_secure_pilgrim_routes_effect = { + faith = { + set_variable = { + name = pam_secured_pilgrim_routes + years = 25 + } + main_rite = { + remove_rite_tenet = scope:removed_tenet + add_rite_tenet = tenet_armed_pilgrimages + } + # The removed tenet loses, and the new core tenet gains popularity. + if = { + limit = { has_tenet_popularity_trigger = yes } + change_tenet_popularity = { + target = scope:removed_tenet + change = major_tenet_popularity_loss + } + change_tenet_popularity = { + target = tenet:tenet_armed_pilgrimages + change = major_tenet_popularity_gain + } + } + } + add_character_modifier = { + modifier = pam_protector_of_pilgrims_modifier + years = 25 + } + custom_tooltip = pam_secure_pilgrim_routes_pilgrim_xp_tt + custom_tooltip = pam_secure_pilgrim_routes_ai_pilgrimage_tt +} + +spiritual_hof_or_realm_priest_superior_recipient_redirect_effect = { + #redirect low tiers targeting HoF to archbishops + if = { + limit = { + highest_held_title_tier < tier_kingdom + faith.religious_head ?= scope:recipient + OR = { + exists = cp:councillor_court_chaplain.superior + AND = { + government_has_flag = government_is_theocracy + exists = superior + } + } + } + #Actor is a priest themselves + if = { + limit = { + AND = { + government_has_flag = government_is_theocracy + exists = superior + } + } + superior = { save_scope_as = recipient } + } + #Actor is secular + else = { + cp:councillor_court_chaplain.superior = { + save_scope_as = recipient + } + } + } + #redirect high tiers targeting archbishops to HoF + else_if = { + limit = { + highest_held_title_tier >= tier_kingdom + OR = { + superior ?= scope:recipient + cp:councillor_court_chaplain.superior ?= scope:recipient + } + faith = { + has_doctrine = doctrine_spiritual_head + religious_head ?= { + NOR = { + this = scope:recipient + this = scope:puppet_or_actor + } + } + } + } + faith.religious_head = { + save_scope_as = recipient + } + } +} +non_pope_lifting_excommunication_penalty_effect = { + if = { + limit = { + scope:puppet_or_actor = { + has_character_flag = pope_excom + } + NOT = { + scope:puppet_or_actor.faith.religious_head ?= scope:recipient + } + } + scope:recipient = { + add_piety = massive_piety_loss + add_piety_level = -2 + } + scope:puppet_or_actor.faith.religious_head = { + add_opinion = { + target = scope:recipient + opinion = -80 + modifier = betrayal_opinion + } + } + } +} + +seek_indulgences_refusal_effect = { + scope:recipient = { + add_prestige = { + value = minor_prestige_value + multiply = { + value = scope:actor.highest_held_title_tier + subtract = 1 + } + } + } + scope:actor = { + clerical_interaction_refusal_minor_effect = yes + if = { + limit = { + scope:recipient = { + is_ai = yes + } + } + if = { + limit = { + scope:actor = { + is_ai = yes + } + } + add_character_modifier = { + modifier = pam_refused_indulgences_modifier_small + years = 5 + desc = refused_indulgences_effect_tt + } + custom_tooltip = refused_indulgences_ai_personality_effect_tt + custom_tooltip = refused_indulgences_ai_war_effect_tt + custom_tooltip = refused_indulgences_ai_amenity_effect_tt + } + else = { + add_character_modifier = { + modifier = pam_refused_indulgences_modifier_small + years = 5 + } + } + change_spiritual_fulfillment = minor_spiritual_fulfillment_loss + } + else = { + change_spiritual_fulfillment = medium_spiritual_fulfillment_loss + if = { + limit = { + scope:actor = { + is_ai = yes + } + } + add_character_modifier = { + modifier = pam_refused_indulgences_modifier + years = 5 + desc = refused_indulgences_effect_tt + } + custom_tooltip = refused_indulgences_ai_personality_effect_tt + custom_tooltip = refused_indulgences_ai_war_effect_tt + custom_tooltip = refused_indulgences_ai_amenity_effect_tt + } + else = { + add_character_modifier = { + modifier = pam_refused_indulgences_modifier + years = 5 + } + } + } + } +} +divorce_house_feud_effect = { + house_feud_start_effect = { + # Feuding House Head + ACTOR = scope:divorcer.house.house_head + # Target House Head + TARGET = scope:secondary_recipient.house.house_head + # Feud Reason + REASON = divorce + # House Member attacker if relevant + ATTACKER = scope:divorcer + # House Member victim if relevant + VICTIM = scope:secondary_recipient + } + scope:secondary_recipient = { + add_prestige_level = -1 + } +} +divorce_holy_order_lease_effect = { + scope:barony_to_lease = { lease_out_to_holy_order = scope:lease_order } +} +divorce_get_hook_effect = { + if = { + limit = { + exists = scope:forcing_divorce + } + add_hook = { + type = favor_hook + target = scope:forcing_divorce + } + } + else = { + add_hook = { + type = favor_hook + target = scope:divorcer + } + } + +} +divorce_put_spouse_in_monastery_effect = { + scope:secondary_recipient = { + add_trait = devoted + scope:recipient = { + add_courtier = scope:secondary_recipient + } + } +} + +############################# +# Tenet popularity # +############################# + +# on_personal_tenet_gain fires this, with root as the character and scope:tenet the gained tenet +# Popularity gain is the lowest possible value, scaled by title tier +pam_tenet_popularity_on_personal_tenet_gain_effect = { + save_scope_as = tp_personal_tenet_changer + faith = { + if = { + limit = { has_tenet_popularity_trigger = yes } + change_tenet_popularity = { + target = scope:tenet + change = scope:tp_personal_tenet_changer.pam_personal_tenet_popularity_gain + } + } + } +} + +# on_personal_tenet_loss runs this with root as the character and scope:tenet as the dropped tenet +pam_tenet_popularity_on_personal_tenet_loss_effect = { + save_scope_as = tp_personal_tenet_changer + faith = { + if = { + limit = { has_tenet_popularity_trigger = yes } + change_tenet_popularity = { + target = scope:tenet + change = scope:tp_personal_tenet_changer.pam_personal_tenet_popularity_loss + } + } + } +} + +# The newly elected pope is root +pam_tenet_popularity_on_new_pope_effect = { + if = { + limit = { faith = { has_tenet_popularity_trigger = yes } } + faith = { save_scope_as = tp_new_pope_faith } + every_personal_tenet = { + save_scope_as = tp_new_pope_tenet + scope:tp_new_pope_faith = { + change_tenet_popularity = { + target = scope:tp_new_pope_tenet + change = medium_tenet_popularity_gain + } + } + } + rite = { + every_rite_tenet = { + status = core + save_scope_as = tp_new_pope_tenet + scope:tp_new_pope_faith = { + change_tenet_popularity = { + target = scope:tp_new_pope_tenet + change = medium_tenet_popularity_gain + } + } + } + } + } +} + +pam_set_pope_rite_mainline_effect = { + if = { + limit = { + exists = rite + rite != faith.main_rite + } + rite = { + set_main_rite = yes + } + } +} + +pam_pope_core_tenet_popularity_catalyst_effect = { + if = { + limit = { + has_pam_dlc_trigger = yes + exists = scope:tenet_to_add + religion = religion:christianity_religion + exists = situation:the_christian_church + } + if = { + limit = { + "faith.tenet_popularity(scope:tenet_to_add)" >= tenet_popularity_popular_threshold + situation:the_christian_church = { + situation_top_has_catalyst = catalyst_pope_declared_popular_core_tenet + } + } + situation:the_christian_church = { + trigger_situation_catalyst = { + catalyst = catalyst_pope_declared_popular_core_tenet + character = root + } + } + } + else_if = { + limit = { + "faith.tenet_popularity(scope:tenet_to_add)" < tenet_popularity_popular_threshold + situation:the_christian_church = { + situation_top_has_catalyst = catalyst_pope_declared_unpopular_core_tenet + } + } + situation:the_christian_church = { + trigger_situation_catalyst = { + catalyst = catalyst_pope_declared_unpopular_core_tenet + character = root + } + } + } + } +} + +# Head of Faith enacts a papal bull. Called from the after block of each bull event, where root is the issuer. +pam_the_christian_church_papal_bull_enacted_catalyst_effect = { + if = { + limit = { + has_pam_dlc_trigger = yes + religion = religion:christianity_religion + situation:the_christian_church ?= { + situation_top_has_catalyst = catalyst_the_christian_church_papal_bull_enacted + } + } + situation:the_christian_church = { + trigger_situation_catalyst = { + catalyst = catalyst_the_christian_church_papal_bull_enacted + character = root + } + } + } +} + +pam_react_to_new_pope_effect = { + if = { + limit = { + has_pam_dlc_trigger = yes + current_date_is_start_date_trigger = no + is_alive = yes + is_ruler = yes + } + save_scope_as = new_pope + faith = { + every_faith_character = { + limit = { + is_ruler = yes + this != scope:new_pope + } + hidden_effect = { remove_character_modifier = pam_denied_new_pope_modifier } + if = { + limit = { has_variable = pam_new_pope_events_as_feed_message } + send_interface_message = { + type = msg_pam_new_pope_elected + title = { + first_valid = { + triggered_desc = { + trigger = { scope:new_pope = { is_female = yes } } + desc = pam_clergy_events.0030.t.female + } + desc = pam_clergy_events.0030.t + } + } + desc = pam_clergy_events.0030.feed + left_icon = scope:new_pope + } + } + else = { + trigger_event = pam_clergy_events.0030 + } + } + } + } +} + +# Root = the kinsman who just took the office. $TITLE$ = the office title, $KIND$ = flag:head_of_faith / flag:antipope / flag:archbishop +pam_family_becomes_prelate_effect = { + if = { + limit = { + has_pam_dlc_trigger = yes + current_date_is_start_date_trigger = no + is_alive = yes + religion = religion:christianity_religion + # Every string in 0060 names the dynasty, so a lowborn prelate has no story to tell here + exists = dynasty + } + save_scope_as = new_prelate + $TITLE$ = { save_scope_as = prelate_title } + save_scope_value_as = { + name = prelate_office + value = $KIND$ + } + every_player = { + limit = { + this != scope:new_prelate + OR = { + is_close_or_extended_family_of = scope:new_prelate + house ?= scope:new_prelate.house + } + # Archdioceses change hands far more often than the great offices do + trigger_if = { + limit = { scope:prelate_office = flag:archbishop } + NOT = { has_character_flag = pam_family_prelate_cooldown } + } + } + if = { + limit = { scope:prelate_office = flag:archbishop } + add_character_flag = { + flag = pam_family_prelate_cooldown + years = 10 + } + } + trigger_event = { + id = pam_clergy_events.0060 + days = { 3 5 } + } + } + } +} + +# Root = the new archbishop. $TITLE$ = the clerical region title that changed hands. +pam_react_to_new_archbishop_effect = { + if = { + limit = { + has_pam_dlc_trigger = yes + current_date_is_start_date_trigger = no + is_alive = yes + } + save_scope_as = new_archbishop + $TITLE$ = { save_scope_as = archdiocese } + every_player = { + limit = { + this != scope:new_archbishop + is_ruler = yes + # The clerical_region_title is geographic, so a non-Christian holder would be told they answer to it + religion = religion:christianity_religion + capital_county.clerical_region_title ?= scope:archdiocese + } + send_interface_message = { + type = msg_pam_new_archbishop + left_icon = scope:new_archbishop + right_icon = scope:archdiocese + } + } + } +} + +pam_tenet_popularity_on_evangelized_tenet_effect = { + save_temporary_scope_as = pam_evangelizer + faith = { + if = { + limit = { has_tenet_popularity_trigger = yes } + change_tenet_popularity = { + target = $TENET$ + change = { + value = $CHANGE$ + # A Faithful Flock dynasty legacy: evangelizing dynasty members spread their tenets further + if = { + limit = { + scope:pam_evangelizer = { + dynasty ?= { has_dynasty_perk = pam_legacy_3 } + } + } + multiply = 1.5 + } + } + } + } + } +} + +# Root = preacher, $TENET$ = the tenet +# Once per preacher per activity, and we keep the record on the activity so it cannot leak +pam_spread_tenet_flat_popularity_once_effect = { + save_temporary_scope_as = pam_spread_flat_preacher + if = { + limit = { + involved_activity ?= { + NAND = { + has_variable_list = pam_spread_tenet_flat_paid + is_target_in_variable_list = { + name = pam_spread_tenet_flat_paid + target = scope:pam_spread_flat_preacher + } + } + } + } + involved_activity = { + add_to_variable_list = { + name = pam_spread_tenet_flat_paid + target = scope:pam_spread_flat_preacher + } + } + pam_tenet_popularity_on_evangelized_tenet_effect = { + TENET = $TENET$ + CHANGE = medium_tenet_popularity_gain + } + } +} + +# A converting character is root, scope:old_rite the previous rite +pam_tenet_popularity_on_rite_change_effect = { + if = { + limit = { is_landed = yes } + faith = { save_scope_as = tp_new_faith } + rite = { save_scope_as = tp_new_rite } + if = { + limit = { + exists = scope:old_rite + scope:old_rite != scope:tp_new_rite + } + scope:old_rite.faith = { save_scope_as = tp_old_faith } + if = { + limit = { scope:tp_old_faith = { has_tenet_popularity_trigger = yes } } + scope:old_rite = { + every_rite_tenet = { + status = core + save_scope_as = tp_tenet + scope:tp_old_faith = { + change_tenet_popularity = { + target = scope:tp_tenet + change = miniscule_tenet_popularity_loss + } + } + } + } + } + } + if = { + limit = { scope:tp_new_faith = { has_tenet_popularity_trigger = yes } } + scope:tp_new_rite = { + every_rite_tenet = { + status = core + save_scope_as = tp_tenet + scope:tp_new_faith = { + change_tenet_popularity = { + target = scope:tp_tenet + change = miniscule_tenet_popularity_gain + } + } + } + } + } + } +} + +# on_county_faith_change sets root as the county and scope:old_faith as the previous faith +# var:tp_popularity_rite remembers the last credited rite so the old faith can be uncredited +pam_tenet_popularity_on_county_faith_change_effect = { + faith = { save_scope_as = tp_new_faith } + rite = { save_scope_as = tp_new_rite } + if = { + limit = { exists = var:tp_popularity_rite } + var:tp_popularity_rite = { save_scope_as = tp_old_rite } + if = { + limit = { scope:old_faith = { has_tenet_popularity_trigger = yes } } + scope:tp_old_rite = { + every_rite_tenet = { + status = core + save_scope_as = tp_tenet + scope:old_faith = { + change_tenet_popularity = { + target = scope:tp_tenet + change = miniscule_tenet_popularity_loss + } + } + } + } + } + } + if = { + limit = { scope:tp_new_faith = { has_tenet_popularity_trigger = yes } } + scope:tp_new_rite = { + every_rite_tenet = { + status = core + save_scope_as = tp_tenet + scope:tp_new_faith = { + change_tenet_popularity = { + target = scope:tp_tenet + change = miniscule_tenet_popularity_gain + } + } + } + } + } + set_variable = { + name = tp_popularity_rite + value = rite + } +} + +# Study Rite: scope:discovered_tenet learned by root (a character). +pam_study_rite_tenet_popularity_effect = { + if = { + limit = { + exists = scope:discovered_tenet + faith = { has_tenet_popularity_trigger = yes } + } + faith = { + change_tenet_popularity = { + target = scope:discovered_tenet + change = minor_tenet_popularity_gain + } + } + } +} + +# on_rite_created. scope:new_rite must exist; root is founder. +pam_tenet_popularity_on_rite_created_effect = { + if = { + limit = { + scope:new_rite.faith ?= { has_tenet_popularity_trigger = yes } + } + root = { save_scope_as = rite_founder } + scope:new_rite = { + save_scope_as = created_rite + every_rite_tenet = { + status = core + save_scope_as = tenet + scope:created_rite.faith = { + change_tenet_popularity = { + target = scope:tenet + change = scope:created_rite.tenet_popularity_rite_created_gain + } + } + } + } + } +} + +# Bump one tenet across all Christian faiths with map presence. +pam_tenet_popularity_christian_faiths_tenet_delta_effect = { + religion:christianity_religion = { + every_faith = { + limit = { + num_county_followers >= 1 + has_tenet_popularity_trigger = yes + } + change_tenet_popularity = { + target = tenet:$TENET$ + change = $VALUE$ + } + } + } +} + +# Situation phase on_start hooks (The Christian Church). +pam_tenet_popularity_situation_fragile_unity_start_effect = { + pam_tenet_popularity_christian_faiths_tenet_delta_effect = { + TENET = tenet_peace_of_god + VALUE = miniscule_tenet_popularity_gain + } +} + +pam_tenet_popularity_situation_saeculum_obscurum_start_effect = { + pam_tenet_popularity_christian_faiths_tenet_delta_effect = { + TENET = tenet_simony + VALUE = medium_tenet_popularity_gain + } +} + +pam_tenet_popularity_situation_conversion_phase_start_effect = { + pam_tenet_popularity_christian_faiths_tenet_delta_effect = { + TENET = tenet_ora_et_labora + VALUE = medium_tenet_popularity_gain + } +} + +pam_tenet_popularity_situation_reform_phase_start_effect = { + pam_tenet_popularity_christian_faiths_tenet_delta_effect = { + TENET = tenet_ora_et_labora + VALUE = medium_tenet_popularity_gain + } + pam_tenet_popularity_christian_faiths_tenet_delta_effect = { + TENET = tenet_simony + VALUE = medium_tenet_popularity_loss + } +} + +pam_tenet_popularity_situation_investiture_crisis_start_effect = { + pam_tenet_popularity_christian_faiths_tenet_delta_effect = { + TENET = tenet_apostolic_succession + VALUE = medium_tenet_popularity_loss + } +} + +pam_tenet_popularity_situation_crusade_phase_start_effect = { + pam_tenet_popularity_christian_faiths_tenet_delta_effect = { + TENET = tenet_miles_christi + VALUE = medium_tenet_popularity_gain + } + pam_tenet_popularity_christian_faiths_tenet_delta_effect = { + TENET = tenet_armed_pilgrimages + VALUE = medium_tenet_popularity_gain + } +} + +pam_tenet_popularity_situation_concord_start_effect = { + pam_tenet_popularity_christian_faiths_tenet_delta_effect = { + TENET = tenet_love_thy_neighbour + VALUE = medium_tenet_popularity_gain + } +} + +# Without this, clerical courts fill from generic pool templates and feel secular +pam_seed_monk_courtiers_effect = { + if = { + limit = { pam_court_wants_monk_courtiers_trigger = yes } + save_temporary_scope_as = monk_employer + while = { + count = 4 # Hard bound matching the highest quota; the limit below is what actually ends the loop + limit = { + any_courtier = { + count < pam_monk_courtier_target_value + OR = { + has_trait = devoted + has_trait = cleric + } + } + } + random_list = { + 50 = { + create_character = { # No location: create_character rejects location and employer together + employer = scope:monk_employer + template = pam_monk_courtier_template + } + } + 50 = { + create_character = { + employer = scope:monk_employer + template = pam_cleric_courtier_template + } + } + } + } + } +} + +# Game start only, because if the three-year pulse ran this the split would creep toward all courts +pam_seed_nun_courtier_effect = { + if = { + limit = { + pam_court_wants_monk_courtiers_trigger = yes + NOT = { + any_courtier = { + is_female = yes + has_trait = devoted + } + } + } + save_temporary_scope_as = monk_employer + random = { + chance = 50 + create_character = { + employer = scope:monk_employer + template = pam_nun_courtier_template + } + } + } +} + +# Here we run this on the courtier, and it expects scope:pam_clerical_patron +pam_clerical_court_ordain_effect = { + save_scope_as = pam_clerical_ordained + scope:pam_clerical_patron = { + send_interface_toast = { + type = event_toast_effect_good + title = pam_clerical_court_ordain_toast + left_icon = scope:pam_clerical_ordained + scope:pam_clerical_ordained = { + add_trait = cleric + if = { + limit = { learning < scope:pam_clerical_patron.pam_clerical_court_learning_cap_value } + add_learning_skill = pam_clerical_court_learning_gain_value + } + add_opinion = { + target = scope:pam_clerical_patron + modifier = grateful_for_calling_opinion + } + } + add_piety = pam_clerical_court_piety_gain_value + } + } +} + +# scope:pam_clerical_patron is required here, and we run this on the courtier +pam_clerical_court_instruct_effect = { + save_scope_as = pam_clerical_instructed + scope:pam_clerical_patron = { + send_interface_toast = { + type = event_toast_effect_good + title = pam_clerical_court_instruct_toast + left_icon = scope:pam_clerical_instructed + scope:pam_clerical_instructed = { + if = { + limit = { learning < scope:pam_clerical_patron.pam_clerical_court_learning_cap_value } + add_learning_skill = pam_clerical_court_learning_gain_value + } + if = { + limit = { NOT = { has_trait = lifestyle_scholar } } + add_trait = lifestyle_scholar + } + else_if = { + limit = { + has_trait_xp = { trait = lifestyle_scholar value < 100 } + } + add_trait_xp = { + trait = lifestyle_scholar + value = 20 + } + } + else_if = { + limit = { NOT = { has_trait = lifestyle_mystic } } + add_trait = lifestyle_mystic + } + else_if = { + limit = { + has_trait_xp = { trait = lifestyle_mystic value < 100 } + } + add_trait_xp = { + trait = lifestyle_mystic + value = 25 + } + } + } + } + } +} + +# Recruiting rulers run this, and it expects scope:pam_clerical_patron +pam_clerical_court_recruit_effect = { + if = { + limit = { exists = scope:pam_clerical_novice_current } + clear_saved_scope = pam_clerical_novice_current + } + if = { + limit = { + exists = scope:pam_clerical_novice + # Can cease to be in the pool between the event firing and the option executing + scope:pam_clerical_novice = { is_pool_character = yes } + } + scope:pam_clerical_novice = { save_scope_as = pam_clerical_novice_current } + } + else_if = { + limit = { + any_pool_character = { + province = scope:pam_clerical_patron.location + pam_clerical_court_novice_trigger = { RULER = scope:pam_clerical_patron } + faith = scope:pam_clerical_patron.faith + } + } + random_pool_character = { + province = scope:pam_clerical_patron.location + limit = { + pam_clerical_court_novice_trigger = { RULER = scope:pam_clerical_patron } + faith = scope:pam_clerical_patron.faith + } + save_scope_as = pam_clerical_novice_current + } + } + else_if = { + limit = { + any_pool_character = { + province = scope:pam_clerical_patron.location + pam_clerical_court_novice_trigger = { RULER = scope:pam_clerical_patron } + } + } + random_pool_character = { + province = scope:pam_clerical_patron.location + limit = { pam_clerical_court_novice_trigger = { RULER = scope:pam_clerical_patron } } + save_scope_as = pam_clerical_novice_current + } + } + if = { + limit = { exists = scope:pam_clerical_novice_current } + add_courtier = scope:pam_clerical_novice_current + send_interface_toast = { + type = event_toast_effect_good + title = pam_clerical_court_recruit_toast + left_icon = scope:pam_clerical_novice_current + if = { + limit = { + NOT = { scope:pam_clerical_novice_current.faith = scope:pam_clerical_patron.faith } + } + scope:pam_clerical_novice_current = { + set_character_faith = scope:pam_clerical_patron.faith + } + } + if = { + limit = { scope:pam_clerical_novice_current = { NOT = { rite = scope:pam_clerical_patron.rite } } } + scope:pam_clerical_novice_current = { + set_character_rite = scope:pam_clerical_patron.rite + } + } + if = { + limit = { scope:pam_clerical_novice_current = { NOT = { has_trait = cleric } } } + scope:pam_clerical_novice_current = { + add_trait = cleric + } + } + } + } +} + +# At game start we leave prohibited tenets at zero +pam_tenet_popularity_on_game_start_effect = { + if = { + limit = { has_pam_dlc_trigger = yes } + religion:christianity_religion = { + every_faith = { + limit = { num_county_followers >= 1 } + save_scope_as = tp_faith + main_rite = { save_scope_as = tp_rite } + # Any follower works as the host scope for the tenet iterator; rite_filter drives the list. + random_faith_county = { + limit = { exists = holder } + holder = { + pam_tenet_popularity_seed_status_effect = { RITE = scope:tp_rite FAITH = scope:tp_faith STATUS = core VALUE = massive_tenet_popularity_value } + pam_tenet_popularity_seed_status_effect = { RITE = scope:tp_rite FAITH = scope:tp_faith STATUS = permitted VALUE = major_tenet_popularity_value } + pam_tenet_popularity_seed_status_effect = { RITE = scope:tp_rite FAITH = scope:tp_faith STATUS = known VALUE = medium_tenet_popularity_value } + } + } + } + } + } +} + +# $RITE$ is the rite scope, run after a title adopts a new state rite +pam_tenet_popularity_boost_rite_effect = { + $RITE$ = { + if = { + limit = { + has_pam_dlc_trigger = yes + faith.religion = religion:christianity_religion + faith = { num_county_followers >= 1 } + } + save_scope_as = tp_boost_rite + faith = { + save_scope_as = tp_boost_faith + # Any follower works as the host scope for the tenet iterator; rite_filter drives the list. + random_faith_county = { + limit = { exists = holder } + holder = { + pam_tenet_popularity_seed_status_effect = { RITE = scope:tp_boost_rite FAITH = scope:tp_boost_faith STATUS = core VALUE = massive_tenet_popularity_value } + pam_tenet_popularity_seed_status_effect = { RITE = scope:tp_boost_rite FAITH = scope:tp_boost_faith STATUS = permitted VALUE = major_tenet_popularity_value } + pam_tenet_popularity_seed_status_effect = { RITE = scope:tp_boost_rite FAITH = scope:tp_boost_faith STATUS = known VALUE = medium_tenet_popularity_value } + } + } + } + } + } +} + +# Credits every $RITE$ tenet at $STATUS$ with $VALUE$ popularity for $FAITH$ +# Root is only a host for the tenet iterator, and its own knowledge is ignored +pam_tenet_popularity_seed_status_effect = { + if = { + limit = { $FAITH$ = { has_tenet_popularity_trigger = yes } } + every_character_tenet = { + rite_filter = $RITE$ + status = $STATUS$ + save_scope_as = tp_seed_tenet + $FAITH$ = { + change_tenet_popularity = { + target = scope:tp_seed_tenet + change = $VALUE$ + } + } + } + } +} + +pam_save_selected_interaction_tenet_effect = { + # Set the tenet based on selected send_options + switch = { + trigger = yes + scope:tenet_aniconism = { + tenet:tenet_aniconism = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_alexandrian_catechism = { + tenet:tenet_alexandrian_catechism = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_armed_pilgrimages = { + tenet:tenet_armed_pilgrimages = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_carnal_exaltation = { + tenet:tenet_carnal_exaltation = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_communal_identity = { + tenet:tenet_communal_identity = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_communion = { + tenet:tenet_communion = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_consolamentum = { + tenet:tenet_consolamentum = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_divine_marriage = { + tenet:tenet_divine_marriage = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_gnosticism = { + tenet:tenet_gnosticism = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_mendicant_preachers = { + tenet:tenet_mendicant_preachers = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_pacifism = { + tenet:tenet_pacifism = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_pentarchy = { + tenet:tenet_pentarchy = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_unrelenting_faith = { + tenet:tenet_unrelenting_faith = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_vows_of_poverty = { + tenet:tenet_vows_of_poverty = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_pastoral_isolation = { + tenet:tenet_pastoral_isolation = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_adaptive = { + tenet:tenet_adaptive = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_esotericism = { + tenet:tenet_esotericism = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_legalism = { + tenet:tenet_legalism = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_literalism = { + tenet:tenet_literalism = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_reincarnation = { + tenet:tenet_reincarnation = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_religious_legal_pronouncements = { + tenet:tenet_religious_legal_pronouncements = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_struggle_submission = { + tenet:tenet_struggle_submission = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_false_conversion_sanction = { + tenet:tenet_false_conversion_sanction = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_tax_nonbelievers = { + tenet:tenet_tax_nonbelievers = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_asceticism = { + tenet:tenet_asceticism = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_bhakti = { + tenet:tenet_bhakti = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_dharmic_pacifism = { + tenet:tenet_dharmic_pacifism = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_inner_journey = { + tenet:tenet_inner_journey = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_ritual_hospitality = { + tenet:tenet_ritual_hospitality = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_adorcism = { + tenet:tenet_adorcism = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_ancestor_worship = { + tenet:tenet_ancestor_worship = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_astrology = { + tenet:tenet_astrology = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_hedonistic = { + tenet:tenet_hedonistic = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_human_sacrifice = { + tenet:tenet_human_sacrifice = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_mystical_birthright = { + tenet:tenet_mystical_birthright = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_ritual_celebrations = { + tenet:tenet_ritual_celebrations = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_sacred_childbirth = { + tenet:tenet_sacred_childbirth = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_sanctity_of_nature = { + tenet:tenet_sanctity_of_nature = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_sun_worship = { + tenet:tenet_sun_worship = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_warmonger = { + tenet:tenet_warmonger = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_gruesome_festivals = { + tenet:tenet_gruesome_festivals = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_cthonic_redoubts = { + tenet:tenet_cthonic_redoubts = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_household_gods = { + tenet:tenet_household_gods = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_sinitic_syncretism = { + tenet:tenet_sinitic_syncretism = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_eastern_syncretism = { + tenet:tenet_eastern_syncretism = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_unreformed_syncretism = { + tenet:tenet_unreformed_syncretism = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_christian_syncretism = { + tenet:tenet_christian_syncretism = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_islamic_syncretism = { + tenet:tenet_islamic_syncretism = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_jewish_syncretism = { + tenet:tenet_jewish_syncretism = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_exaltation_of_pain = { + tenet:tenet_exaltation_of_pain = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_natural_primitivism = { + tenet:tenet_natural_primitivism = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_pursuit_of_power = { + tenet:tenet_pursuit_of_power = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_ritual_cannibalism = { + tenet:tenet_ritual_cannibalism = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_sacred_shadows = { + tenet:tenet_sacred_shadows = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_polyamory = { + tenet:tenet_polyamory = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_sacrificial_ceremonies = { + tenet:tenet_sacrificial_ceremonies = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_megaliths = { + tenet:tenet_megaliths = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_fp3_fedayeen = { + tenet:tenet_fp3_fedayeen = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_communal_possessions = { + tenet:tenet_communal_possessions = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_pure_land = { + tenet:tenet_pure_land = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_no_mind = { + tenet:tenet_no_mind = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_mountain_worship = { + tenet:tenet_mountain_worship = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_extinction_of_dharma = { + tenet:tenet_extinction_of_dharma = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_cranial_trophies = { + tenet:tenet_cranial_trophies = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_pursuit_of_knowledge = { + tenet:tenet_pursuit_of_knowledge = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_benevolent_governance = { + tenet:tenet_benevolent_governance = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_filial_piety = { + tenet:tenet_filial_piety = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_harmonious_society = { + tenet:tenet_harmonious_society = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_sacred_destruction = { + tenet:tenet_sacred_destruction = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_preservation = { + tenet:tenet_preservation = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_takamin = { + tenet:tenet_takamin = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_peace_of_god = { + tenet:tenet_peace_of_god = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_dulia = { + tenet:tenet_dulia = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_transubstantiation = { + tenet:tenet_transubstantiation = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_ora_et_labora = { + tenet:tenet_ora_et_labora = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_hyperdulia = { + tenet:tenet_hyperdulia = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_simony = { + tenet:tenet_simony = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_monophysitism = { + tenet:tenet_monophysitism = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_acts_of_apostles = { + tenet:tenet_acts_of_apostles = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_purgatory = { + tenet:tenet_purgatory = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_be_fruitful_and_multiply = { + tenet:tenet_be_fruitful_and_multiply = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_apostolic_succession = { + tenet:tenet_apostolic_succession = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_confession = { + tenet:tenet_confession = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_original_sin = { + tenet:tenet_original_sin = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_celestial_hierarchy = { + tenet:tenet_celestial_hierarchy = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_miles_christi = { + tenet:tenet_miles_christi = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_philanthropia = { + tenet:tenet_philanthropia = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_scholasticism = { + tenet:tenet_scholasticism = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_adoptionism = { + tenet:tenet_adoptionism = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_love_thy_neighbour = { + tenet:tenet_love_thy_neighbour = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_divine_liturgy = { + tenet:tenet_divine_liturgy = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_miaphysitism = { + tenet:tenet_miaphysitism = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_hesychasm = { + tenet:tenet_hesychasm = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_anachoresis = { + tenet:tenet_anachoresis = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_mortification_of_the_flesh = { + tenet:tenet_mortification_of_the_flesh = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_holy_myron = { + tenet:tenet_holy_myron = { + save_scope_as = pam_selected_interaction_tenet + } + } + scope:tenet_khachkar = { + tenet:tenet_khachkar = { + save_scope_as = pam_selected_interaction_tenet + } + } + } +} + +# Root is character that will have their personal tenet replaced with TENET +pam_replace_personal_tenet_effect = { + save_temporary_scope_as = tenet_char + if = { + limit = { + free_personal_tenet_slots = 0 + } + random_personal_tenet = { + weight = { + base = 10 + modifier = { + add = pam_tenet_popularity_impact_value + } + } + scope:tenet_char = { + remove_personal_tenet = prev + } + } + } + set_personal_tenet = $TENET$ +} + +pam_notify_holy_war_instigator_effect_win = { + if = { + limit = { + scope:war ?= { + has_variable = holy_instigator + var:holy_instigator = { + is_alive = yes + save_temporary_scope_as = instigator_temp + } + NOT = { + any_war_participant = { + this = scope:instigator_temp + } + } + } + } + every_in_list = { + list = target_titles + save_scope_as = target + } + + scope:war = { + var:holy_instigator = { + save_scope_as = cleric + send_interface_message = { + type = event_generic_good + title = pam_instigated_holy_war_won.t + left_icon = scope:attacker + right_icon = scope:defender + + if = { + limit = { + is_ai = no + } + add_prestige = pam_holy_war_inciter_prestige_value + } + else = { + hidden_effect = { + add_prestige = pam_holy_war_inciter_prestige_value + } + } + + custom_tooltip = pam_instigated_holy_war_won_tt + if = { + limit = { + pam_can_expand_clerical_region_after_war_trigger = { HEATHEN = scope:defender } + } + if = { + limit = { + any_in_list = { + list = target_titles + tier = tier_county + } + } + every_in_list = { + list = target_titles + duchy = { + scope:cleric = { + add_to_variable_list = { + name = clergy_expands + target = prev + } + } + } + } + } + else_if = { + limit = { + any_in_list = { + list = target_titles + tier = tier_duchy + } + } + every_in_list = { + list = target_titles + scope:cleric = { + add_to_variable_list = { + name = clergy_expands + target = prev + } + } + } + } + else = { + every_in_list = { + list = target_titles + every_direct_de_jure_vassal_title = { + limit = { + any_de_jure_county = { + holder = { + target_is_same_character_or_above = scope:defender + } + } + } + scope:cleric = { + add_to_variable_list = { + name = clergy_expands + target = prev + } + } + } + } + } + } + } + } + } + } +} +pam_notify_holy_war_instigator_effect_draw = { + if = { + limit = { + scope:war ?= { + has_variable = holy_instigator + var:holy_instigator = { + is_alive = yes + save_temporary_scope_as = instigator_temp + } + NOT = { + any_war_participant = { + this = scope:instigator_temp + } + } + } + } + every_in_list = { + list = target_titles + save_scope_as = target + } + scope:war = { + var:holy_instigator = { + send_interface_message = { + type = event_generic_bad + title = pam_instigated_holy_war_draw.t + left_icon = scope:attacker + right_icon = scope:defender + custom_tooltip = pam_instigated_holy_war_draw_tt + } + } + } + } +} +pam_notify_holy_war_instigator_effect_loss = { + if = { + limit = { + scope:war ?= { + has_variable = holy_instigator + var:holy_instigator = { + is_alive = yes + save_temporary_scope_as = instigator_temp + } + NOT = { + any_war_participant = { + this = scope:instigator_temp + } + } + } + } + every_in_list = { + list = target_titles + save_scope_as = target + } + scope:war = { + if = { + limit = { + has_variable = holy_joiner + } + var:holy_joiner = { + send_interface_message = { + type = event_generic_bad + title = pam_instigated_holy_war_lost.t + left_icon = scope:attacker + right_icon = scope:defender + + add_prestige_level = -2 + } + } + } + else = { + var:holy_instigator = { + send_interface_message = { + type = event_generic_bad + title = pam_instigated_holy_war_lost.t + left_icon = scope:attacker + right_icon = scope:defender + + custom_tooltip = pam_instigated_holy_war_lost_tt + } + } + } + } + } +} +pam_incite_holy_war_effect = { + scope:puppet_or_actor = { + if = { + limit = { + top_participant_group:the_christian_church ?= { + has_participant_group_parameter = the_christian_church_incite_holy_war_interaction + } + NOR = { + has_trait = forgiving + has_trait = compassionate + } + } + change_spiritual_fulfillment = { + value = miniscule_spiritual_fulfillment_value + multiply = { + value = scope:target.tier + subtract = 1 + } + } + } + } + + scope:secondary_recipient = { + save_scope_as = sponsored_holy_war_attacker + add_piety = { + value = medium_piety_value + multiply = { + value = scope:target.tier + subtract = 1 + } + } + if = { + limit = { + scope:puppet_or_actor = { + top_participant_group:the_christian_church ?= { + has_participant_group_parameter = the_christian_church_incite_holy_war_interaction + } + } + NOR = { + has_trait = forgiving + has_trait = compassionate + } + } + change_spiritual_fulfillment = { + value = minor_spiritual_fulfillment_value + multiply = { + value = scope:target.tier + subtract = 1 + } + } + } + } + scope:recipient = { + save_scope_as = sponsored_holy_war_defender + if = { + limit = { + NOT = { + root ?= scope:secondary_recipient + } + } + add_opinion = { + target = scope:puppet_or_actor + modifier = incited_holy_war_opinion + opinion = -50 + } + } + } + if = { + limit = { + root ?= scope:secondary_recipient + } + custom_tooltip = interaction_holy_war_attacker_tt + show_as_tooltip = { + scope:recipient = { + add_opinion = { + modifier = declared_war + target = scope:secondary_recipient + } + } + } + } + else = { + scope:recipient = { + custom_tooltip = interaction_holy_war_attacked_tt + } + } + + scope:sponsored_holy_war_attacker = { + add_character_flag = { + flag = holy_war_incited + days = 10 + } + if = { + limit = { + scope:sponsored_holy_war_target.tier = tier_kingdom + } + hidden_effect = { + start_war = { + casus_belli = major_religious_war + target = scope:sponsored_holy_war_defender + target_title = scope:sponsored_holy_war_target + } + } + } + else_if = { + limit = { + scope:sponsored_holy_war_target.tier = tier_duchy + } + hidden_effect = { + start_war = { + casus_belli = religious_war + target = scope:sponsored_holy_war_defender + target_title = scope:sponsored_holy_war_target + } + } + } + else = { + hidden_effect = { + start_war = { + casus_belli = minor_religious_war + target = scope:sponsored_holy_war_defender + target_title = scope:sponsored_holy_war_target + } + } + } + random_character_war = { + limit = { + OR = { + using_cb = major_religious_war + using_cb = religious_war + using_cb = minor_religious_war + } + primary_defender = scope:recipient + } + save_scope_as = holy_war + set_variable = { + name = holy_instigator + value = scope:puppet_or_actor + } + } + } + scope:puppet_or_actor = { + custom_tooltip = inciter_gain_prestige_if_holy_war_won_tt + if = { + limit = { + scope:fund_war ?= yes + } + pay_treasury_or_gold = { + target = scope:secondary_recipient + value = scope:puppet_or_actor.major_gold_value + } + } + if = { + limit = { + scope:join_war ?= yes + } + custom_tooltip = holy_war_interaction_join_war_tt + custom_tooltip = holy_war_cleric_loss_penalty_tt + scope:holy_war ?= { + hidden_effect = { add_attacker = scope:puppet_or_actor } + set_variable = { + name = holy_joiner + value = scope:puppet_or_actor + } + } + } + if = { + limit = { + scope:use_hook ?= yes + has_usable_hook = scope:secondary_recipient + } + use_hook = scope:secondary_recipient + } + if = { + limit = { + scope:rally_crusaders ?= yes + } + scope:secondary_recipient = { + if = { + limit = { + highest_held_title_tier < scope:puppet_or_actor.highest_held_title_tier + current_military_strength < scope:puppet_or_actor.current_military_strength + } + if = { + limit = { + is_ai = yes + } + add_character_modifier = { + modifier = crusader_momentum_modifier_large + years = 10 + desc = crusader_momentum_ai_behavior_large_tt + } + custom_tooltip = crusader_momentum_ai_behavior_large_tt + } + else = { + add_character_modifier = { + modifier = crusader_momentum_modifier_large + years = 10 + } + } + } + else = { + if = { + limit = { + is_ai = yes + } + add_character_modifier = { + modifier = crusader_momentum_modifier + years = 10 + desc = crusader_momentum_ai_behavior_tt + } + custom_tooltip = crusader_momentum_ai_behavior_tt + } + else = { + add_character_modifier = { + modifier = crusader_momentum_modifier + years = 10 + } + } + } + } + if = { + limit = { + exists = scope:target + } + add_prestige = { + value = minor_prestige_loss + multiply = { + value = scope:target.tier + subtract = 1 + } + } + } + else = { + add_prestige = medium_prestige_loss + } + } + if = { + limit = { + scope:inspire_realm ?= yes + } + scope:secondary_recipient = { + add_character_modifier = { + modifier = holy_war_incited_throughout_realm_modifier + years = 15 + } + } + } + #Discount to expanding archbishopric into the area + if = { + limit = { + pam_can_expand_clerical_region_after_war_trigger = { HEATHEN = scope:recipient } + } + custom_tooltip = can_expand_clerical_region_into_target_tt + } + } + scope:recipient = { + trigger_event = { + id = pam_interactions_events.0072 + days = 3 + } + } + scope:puppet_or_actor = { + if = { + limit = { + exists = scope:target + scope:target.tier >= tier_kingdom + any_character_situation = { + situation_type = the_christian_church + } + situation:the_christian_church ?= { + situation_top_has_catalyst = catalyst_major_holy_war_incited + } + } + trigger_situation_catalyst = catalyst_major_holy_war_incited + } + else_if = { + limit = { + exists = scope:target + scope:target.tier >= tier_duchy + any_character_situation = { + situation_type = the_christian_church + } + situation:the_christian_church ?= { + situation_top_has_catalyst = catalyst_holy_war_incited + } + } + trigger_situation_catalyst = catalyst_holy_war_incited + } + else = { + limit = { + any_character_situation = { + situation_type = the_christian_church + } + situation:the_christian_church ?= { + situation_top_has_catalyst = catalyst_minor_holy_war_incited + } + } + trigger_situation_catalyst = catalyst_minor_holy_war_incited + } + } +} +pam_incite_war_refusal_effect = { + if = { + limit = { + scope:target.tier >= tier_kingdom + } + add_piety_level = -1 + } + else = { + add_piety_experience = { + value = major_piety_loss + multiply = { + value = scope:target.tier + subtract = 1 + } + } + } + +} +pam_redirect_request_excommunication_ruler_effect = { + #Is the secondary recipient a theocrat? Only their superior can excommunicate them + if = { + limit = { + scope:secondary_recipient = { + government_has_flag = government_is_theocracy + exists = superior + NOR = { + superior = scope:secondary_recipient + superior = scope:actor + } + } + } + scope:secondary_recipient.superior = { + save_scope_as = recipient + } + } + #Redirect to bishop superior of court chaplain + else_if = { + limit = { + scope:secondary_recipient.cp:councillor_court_chaplain ?= { + highest_held_title_tier < tier_duchy + superior ?= { + highest_held_title_tier >= tier_duchy + is_clergy = yes + NOT = { + this = scope:actor + } + } + } + } + scope:secondary_recipient.cp:councillor_court_chaplain.superior = { + save_scope_as = recipient + } + } + #Redirect to ecclesiastical/theocratic liege or above + else_if = { + limit = { + scope:secondary_recipient = { + any_liege_or_above = { + highest_held_title_tier >= tier_duchy + government_has_flag = government_is_theocracy + faith ?= scope:secondary_recipient.faith + NOT = { + this = scope:actor + } + } + } + } + scope:secondary_recipient = { + ordered_liege_or_above = { + order_by = highest_held_title_tier + limit = { + highest_held_title_tier >= tier_duchy + government_has_flag = government_is_theocracy + faith ?= scope:secondary_recipient.faith + NOT = { + this = scope:actor + } + } + save_scope_as = recipient + } + } + } + #Redirect to court chaplain of liege or above + else_if = { + limit = { + scope:secondary_recipient = { + any_liege_or_above = { + cp:councillor_court_chaplain ?= { + highest_held_title_tier < tier_duchy + is_clergy = yes + NOT = { + this = scope:actor + } + } + } + } + } + scope:secondary_recipient = { + ordered_liege_or_above = { + order_by = { + value = highest_held_title_tier + multiply = -1 + } + limit = { + cp:councillor_court_chaplain ?= { + highest_held_title_tier < tier_duchy + is_clergy = yes + NOT = { + this = scope:actor + } + } + } + cp:councillor_court_chaplain = { + save_scope_as = recipient + } + } + } + } + #Redirect to bishop + else_if = { + limit = { + scope:secondary_recipient.cp:councillor_court_chaplain ?= { + highest_held_title_tier >= tier_duchy + is_clergy = yes + NOT = { + this = scope:actor + } + } + } + scope:secondary_recipient.cp:councillor_court_chaplain = { + save_scope_as = recipient + } + } + #Redirect to clerical region_holder + else_if = { + limit = { + scope:secondary_recipient.capital_county = { + clerical_region_title ?= { + holder ?= { + highest_held_title_tier >= tier_duchy + faith ?= scope:secondary_recipient.faith + NOT = { + this = scope:actor + } + } + } + } + } + scope:secondary_recipient.capital_county.clerical_region_title.holder = { + save_scope_as = recipient + } + } + #Redirect to neighboring clerical region_holder + else_if = { + limit = { + scope:secondary_recipient = { + any_character_to_title_neighboring_county = { + clerical_region_title ?= { + holder ?= { + highest_held_title_tier >= tier_duchy + faith ?= scope:secondary_recipient.faith + NOT = { + this = scope:actor + } + } + } + } + } + } + scope:secondary_recipient = { + random_character_to_title_neighboring_county = { + limit = { + clerical_region_title ?= { + holder ?= { + highest_held_title_tier >= tier_duchy + faith ?= scope:secondary_recipient.faith + NOT = { + this = scope:actor + } + } + } + } + clerical_region_title.holder = { + save_scope_as = recipient + } + } + } + } +} +pam_redirect_request_excommunication_courtier_effect = { + #liege + if = { + limit = { + scope:secondary_recipient = { + liege = { + highest_held_title_tier >= tier_duchy + government_has_flag = government_is_theocracy + faith ?= scope:secondary_recipient.faith + NOT = { + this = scope:actor + } + } + } + } + scope:secondary_recipient.liege = { + save_scope_as = recipient + } + } + #Redirect to court chaplain of liege or above + else_if = { + limit = { + scope:secondary_recipient = { + any_liege_or_above = { + cp:councillor_court_chaplain ?= { + highest_held_title_tier < tier_duchy + is_clergy = yes + NOT = { + this = scope:actor + } + } + } + } + } + scope:secondary_recipient = { + ordered_liege_or_above = { + order_by = { + value = highest_held_title_tier + multiply = -1 + } + limit = { + cp:councillor_court_chaplain ?= { + highest_held_title_tier < tier_duchy + is_clergy = yes + NOT = { + this = scope:actor + } + } + } + cp:councillor_court_chaplain = { + save_scope_as = recipient + } + } + } + } + #Redirect to clerical region_holder + else_if = { + limit = { + scope:secondary_recipient.liege.capital_county = { + clerical_region_title ?= { + holder ?= { + highest_held_title_tier >= tier_duchy + faith ?= scope:secondary_recipient.faith + NOT = { + this = scope:actor + } + } + } + } + } + scope:secondary_recipient.liege.capital_county.clerical_region_title.holder = { + save_scope_as = recipient + } + } + #Redirect to ecclesiastical/theocratic liege or above + else_if = { + limit = { + scope:secondary_recipient = { + any_liege_or_above = { + highest_held_title_tier >= tier_duchy + government_has_flag = government_is_theocracy + faith ?= scope:secondary_recipient.faith + NOT = { + this = scope:actor + } + } + } + } + scope:secondary_recipient = { + ordered_liege_or_above = { + order_by = { + value = highest_held_title_tier + multiply = -1 + } + limit = { + highest_held_title_tier >= tier_duchy + government_has_flag = government_is_theocracy + faith ?= scope:secondary_recipient.faith + NOT = { + this = scope:actor + } + } + save_scope_as = recipient + } + } + } + #Redirect to bishop superior of court chaplain + else_if = { + limit = { + scope:secondary_recipient.liege.cp:councillor_court_chaplain ?= { + highest_held_title_tier < tier_duchy + superior ?= { + highest_held_title_tier >= tier_duchy + is_clergy = yes + NOT = { + this = scope:actor + } + } + } + } + scope:secondary_recipient.liege.cp:councillor_court_chaplain.superior = { + save_scope_as = recipient + } + } + #Redirect to neighboring clerical region_holder + else_if = { + limit = { + scope:secondary_recipient.liege = { + any_character_to_title_neighboring_county = { + clerical_region_title ?= { + holder ?= { + highest_held_title_tier >= tier_duchy + faith ?= scope:secondary_recipient.faith + NOT = { + this = scope:actor + } + } + } + } + } + } + scope:secondary_recipient.liege = { + random_character_to_title_neighboring_county = { + limit = { + clerical_region_title ?= { + holder ?= { + highest_held_title_tier >= tier_duchy + faith ?= scope:secondary_recipient.faith + NOT = { + this = scope:actor + } + } + } + } + clerical_region_title.holder = { + save_scope_as = recipient + } + } + } + } +} +pam_redirect_request_excommunication_wanderer_effect = { + #Location holder + if = { + limit = { + scope:secondary_recipient.location.county.holder ?= { + highest_held_title_tier >= tier_duchy + government_has_flag = government_is_theocracy + faith ?= scope:secondary_recipient.faith + NOT = { + this = scope:actor + } + } + } + scope:secondary_recipient.location.county.holder ?= { + save_scope_as = recipient + } + } + #Location holder + if = { + limit = { + scope:secondary_recipient.location.county.holder.cp:councillor_court_chaplain ?= { + highest_held_title_tier >= tier_duchy + is_clergy = yes + faith ?= scope:secondary_recipient.faith + NOT = { + this = scope:actor + } + } + } + scope:secondary_recipient.location.county.holder.cp:councillor_court_chaplain ?= { + save_scope_as = recipient + } + } + #Redirect to court chaplain of holder's liege or above + else_if = { + limit = { + scope:secondary_recipient.location.county.holder ?= { + any_liege_or_above = { + cp:councillor_court_chaplain ?= { + highest_held_title_tier < tier_duchy + is_clergy = yes + NOT = { + this = scope:actor + } + } + } + } + } + scope:secondary_recipient.location.county.holder ?= { + ordered_liege_or_above = { + order_by = { + value = highest_held_title_tier + multiply = -1 + } + limit = { + cp:councillor_court_chaplain ?= { + highest_held_title_tier < tier_duchy + is_clergy = yes + NOT = { + this = scope:actor + } + } + } + cp:councillor_court_chaplain = { + save_scope_as = recipient + } + } + } + } + #Redirect to ecclesiastical/theocratic liege or above + else_if = { + limit = { + scope:secondary_recipient.location.county.holder ?= { + any_liege_or_above = { + highest_held_title_tier >= tier_duchy + government_has_flag = government_is_theocracy + faith ?= scope:secondary_recipient.faith + NOT = { + this = scope:actor + } + } + } + } + scope:secondary_recipient.location.county.holder ?= { + ordered_liege_or_above = { + order_by = { + value = highest_held_title_tier + multiply = -1 + } + limit = { + highest_held_title_tier >= tier_duchy + government_has_flag = government_is_theocracy + faith ?= scope:secondary_recipient.faith + NOT = { + this = scope:actor + } + } + save_scope_as = recipient + } + } + } + #Redirect to clerical region_holder + else_if = { + limit = { + scope:secondary_recipient.location.county ?= { + clerical_region_title ?= { + holder ?= { + highest_held_title_tier >= tier_duchy + faith ?= scope:secondary_recipient.faith + NOT = { + this = scope:actor + } + } + } + } + } + scope:secondary_recipient.location.county.clerical_region_title.holder = { + save_scope_as = recipient + } + } + #Redirect to neighboring clerical region_holder + else_if = { + limit = { + scope:secondary_recipient.location.county ?= { + any_neighboring_county = { + clerical_region_title ?= { + holder ?= { + highest_held_title_tier >= tier_duchy + faith ?= scope:secondary_recipient.faith + NOT = { + this = scope:actor + } + } + } + } + } + } + scope:secondary_recipient.location.county = { + random_neighboring_county = { + limit = { + clerical_region_title ?= { + holder ?= { + highest_held_title_tier >= tier_duchy + faith ?= scope:secondary_recipient.faith + NOT = { + this = scope:actor + } + } + } + } + clerical_region_title.holder = { + save_scope_as = recipient + } + } + } + } +} +pam_christian_situation_hof_incite_holy_war_effect = { + if = { + limit = { + faith.religious_head ?= root + is_ai = yes + top_participant_group:the_christian_church ?= { + has_participant_group_parameter = the_christian_church_incite_holy_war_interaction + } + piety >= 100 + piety_level >= 2 + is_available_quick = { + adult = yes + alive = yes + imprisoned = no + incapable = no + } + actor_incite_holy_war_shown_trigger = yes + } + save_scope_as = puppet_or_actor + situation:the_christian_church = { + situation_participant_group:christian_regular_main_power_rulers = { + random_situation_group_participant = { + limit = { + faith = scope:puppet_or_actor.faith + highest_held_title_tier >= tier_county + is_at_war = no + save_temporary_scope_as = secondary_temp + #First need to find a neighbor who works... + any_neighboring_top_liege_realm_owner = { + save_temporary_scope_as = recipient_temp + NOT = { + faith = scope:secondary_temp.faith + } + scope:secondary_temp.faith = { + faith_hostility_level = { + target = scope:recipient_temp.faith + value >= religious_cb_enabled_hostility_level + } + } + NOR = { + is_at_war_with = scope:puppet_or_actor + is_at_war_with = scope:secondary_temp + } + current_military_strength < scope:secondary_temp.eighty_percent_of_current_military_strength + scope:secondary_temp = { + valid_holy_war_incited_attacker_trigger = { RECIPIENT = scope:recipient_temp } + } + incite_holy_war_ai_invalidation_trigger = { RECIPIENT = scope:recipient_temp SECONDARY = scope:secondary_temp } + trigger_if = { + limit = { + scope:puppet_or_actor.piety_level >= 3 + highest_held_title_tier >= tier_duchy + realm_size >= 8 + } + any_realm_de_jure_kingdom = { + incite_holy_war_title_can_be_picked_trigger = { RECIPIENT = scope:recipient_temp SECONDARY = scope:secondary_temp } + } + } + trigger_else_if = { + limit = { + scope:puppet_or_actor.piety_level >= 2 + realm_size >= 2 + } + any_realm_de_jure_duchy = { + incite_holy_war_title_can_be_picked_trigger = { RECIPIENT = scope:recipient_temp SECONDARY = scope:secondary_temp } + } + } + trigger_else = { + any_realm_county = { + incite_holy_war_title_can_be_picked_trigger = { RECIPIENT = scope:recipient_temp SECONDARY = scope:secondary_temp } + } + } + } + } + save_scope_as = secondary_recipient + ordered_neighboring_top_liege_realm_owner = { + order_by = { + value = current_military_strength + multiply = -1 + } + limit = { + save_temporary_scope_as = recipient_temp + NOT = { + faith = scope:secondary_recipient.faith + } + scope:secondary_recipient.faith = { + faith_hostility_level = { + target = scope:recipient_temp.faith + value >= religious_cb_enabled_hostility_level + } + } + NOR = { + is_at_war_with = scope:puppet_or_actor + is_at_war_with = scope:secondary_recipient + } + current_military_strength < scope:secondary_recipient.eighty_percent_of_current_military_strength + scope:secondary_recipient = { + valid_holy_war_incited_attacker_trigger = { RECIPIENT = scope:recipient_temp } + } + incite_holy_war_ai_invalidation_trigger = { RECIPIENT = scope:recipient_temp SECONDARY = scope:secondary_recipient } + trigger_if = { + limit = { + scope:puppet_or_actor.piety_level >= 3 + highest_held_title_tier >= tier_duchy + realm_size >= 8 + } + any_realm_de_jure_kingdom = { + incite_holy_war_title_can_be_picked_trigger = { RECIPIENT = scope:recipient_temp SECONDARY = scope:secondary_recipient } + } + } + trigger_else_if = { + limit = { + scope:puppet_or_actor.piety_level >= 2 + realm_size >= 2 + } + any_realm_de_jure_duchy = { + incite_holy_war_title_can_be_picked_trigger = { RECIPIENT = scope:recipient_temp SECONDARY = scope:secondary_recipient } + } + } + trigger_else = { + any_realm_county = { + incite_holy_war_title_can_be_picked_trigger = { RECIPIENT = scope:recipient_temp SECONDARY = scope:secondary_recipient } + } + } + } + save_scope_as = recipient + #Save target + if = { + limit = { + scope:puppet_or_actor.piety_level >= 3 + highest_held_title_tier >= tier_duchy + realm_size >= 8 + } + ordered_realm_de_jure_kingdom = { + order_by = de_jure_counties_held_by_recipient_value + limit = { + incite_holy_war_title_can_be_picked_trigger = { RECIPIENT = scope:recipient SECONDARY = scope:secondary_recipient } + } + save_scope_as = target + } + } + else_if = { + limit = { + scope:puppet_or_actor.piety_level >= 2 + realm_size >= 2 + } + ordered_realm_de_jure_duchy = { + order_by = de_jure_counties_held_by_recipient_value + limit = { + incite_holy_war_title_can_be_picked_trigger = { RECIPIENT = scope:recipient SECONDARY = scope:secondary_recipient } + } + save_scope_as = target + } + } + else = { + random_realm_county = { + limit = { + incite_holy_war_title_can_be_picked_trigger = { RECIPIENT = scope:recipient SECONDARY = scope:secondary_recipient } + } + save_scope_as = target + } + } + } + } + } + } + save_scope_as = actor + if = { + limit = { + exists = scope:secondary_recipient + exists = scope:recipient + } + ecclesiastic_incite_holy_war_interaction_effect = yes + } + } +} +ecclesiastic_incite_holy_war_interaction_effect = { + scope:target = { + save_scope_as = sponsored_holy_war_target + } + show_as_tooltip = { + pam_incite_holy_war_effect = yes + scope:recipient = { custom_tooltip = holy_war_joining_interaction_warning_tt } + } + #Secondary recipient gets to call this off if player + if = { + limit = { + scope:secondary_recipient = { + is_ai = no + } + } + scope:secondary_recipient = { + trigger_event = pam_interactions_events.0070 + } + } + else = { + scope:actor = { + trigger_event = pam_interactions_events.0071 + } + } +} + +pam_notify_claim_war_instigator_effect_win = { + if = { + limit = { + scope:war ?= { + has_variable = claim_instigator + var:claim_instigator = { + is_alive = yes + save_temporary_scope_as = instigator_temp + } + OR = { + has_variable = claim_joiner + NOT = { + any_war_participant = { + this = scope:instigator_temp + } + } + } + } + } + every_in_list = { + list = target_titles + save_scope_as = target + } + scope:war = { + var:claim_instigator = { + send_interface_message = { + type = event_generic_good + title = pam_instigated_claim_war_won.t + left_icon = scope:attacker + right_icon = scope:defender + if = { + limit = { + is_ai = no + } + add_prestige = pam_holy_war_inciter_prestige_value + } + else = { + hidden_effect = { + add_prestige = pam_holy_war_inciter_prestige_value + } + } + custom_tooltip = pam_instigated_claim_war_won_tt + } + } + } + } +} +pam_notify_claim_war_instigator_effect_draw = { + if = { + limit = { + scope:war ?= { + has_variable = claim_instigator + var:claim_instigator = { + is_alive = yes + save_temporary_scope_as = instigator_temp + } + OR = { + has_variable = claim_joiner + NOT = { + any_war_participant = { + this = scope:instigator_temp + } + } + } + } + } + every_in_list = { + list = target_titles + save_scope_as = target + } + scope:war = { + var:claim_instigator = { + send_interface_message = { + type = event_generic_bad + title = pam_instigated_claim_war_draw.t + left_icon = scope:attacker + right_icon = scope:defender + custom_tooltip = pam_instigated_claim_war_draw_tt + } + } + } + } +} +pam_notify_claim_war_instigator_effect_loss = { + if = { + limit = { + scope:war ?= { + has_variable = claim_instigator + var:claim_instigator = { + is_alive = yes + save_temporary_scope_as = instigator_temp + } + OR = { + has_variable = claim_joiner + NOT = { + any_war_participant = { + this = scope:instigator_temp + } + } + } + } + } + every_in_list = { + list = target_titles + save_scope_as = target + } + scope:war = { + if = { + limit = { + has_variable = claim_joiner + } + var:claim_joiner = { + send_interface_message = { + type = event_generic_bad + title = pam_instigated_claim_war_lost.t + left_icon = scope:attacker + right_icon = scope:defender + add_prestige_level = -2 + } + } + } + else = { + var:claim_instigator = { + send_interface_message = { + type = event_generic_bad + title = pam_instigated_claim_war_lost.t + left_icon = scope:attacker + right_icon = scope:defender + custom_tooltip = pam_instigated_claim_war_lost_tt + } + } + } + } + } +} +pam_incite_claim_war_effect = { + scope:secondary_recipient = { + save_scope_as = sponsored_claim_war_attacker + add_piety = { + value = medium_piety_value + multiply = { + value = scope:target.tier + subtract = 1 + } + } + } + scope:recipient = { + save_scope_as = sponsored_claim_war_defender + if = { + limit = { + NOT = { + root ?= scope:secondary_recipient + } + } + add_opinion = { + target = scope:puppet_or_actor + modifier = incited_claim_war_opinion + opinion = -50 + } + } + } + if = { + limit = { + root ?= scope:secondary_recipient + } + custom_tooltip = interaction_claim_war_attacker_tt + show_as_tooltip = { + scope:recipient = { + add_opinion = { + modifier = declared_war + target = scope:secondary_recipient + } + } + } + } + else = { + scope:recipient = { + custom_tooltip = interaction_claim_war_attacked_tt + } + } + + scope:sponsored_claim_war_attacker = { + add_character_flag = { + flag = temp_no_claim_war_cost + days = 10 + } + hidden_effect = { + start_war = { + casus_belli = claim_cb + target = scope:sponsored_claim_war_defender + claimant = scope:sponsored_claim_war_attacker + target_title = scope:sponsored_claim_war_target + } + remove_character_flag = temp_no_claim_war_cost + } + random_character_war = { + limit = { + using_cb = claim_cb + primary_defender = scope:recipient + } + save_scope_as = claim_war + set_variable = { + name = claim_instigator + value = scope:puppet_or_actor + } + } + } + scope:puppet_or_actor = { + custom_tooltip = inciter_gain_prestige_if_claim_war_won_tt + if = { + limit = { + scope:fund_war ?= yes + } + pay_treasury_or_gold = { + target = scope:secondary_recipient + value = scope:puppet_or_actor.major_gold_value + } + } + if = { + limit = { + scope:join_war ?= yes + } + custom_tooltip = claim_war_interaction_join_war_tt + custom_tooltip = holy_war_cleric_loss_penalty_tt + scope:claim_war ?= { + hidden_effect = { add_attacker = scope:puppet_or_actor } + set_variable = { + name = claim_joiner + value = scope:puppet_or_actor + } + } + } + if = { + limit = { + scope:use_hook ?= yes + has_usable_hook = scope:secondary_recipient + } + use_hook = scope:secondary_recipient + } + } +} +ecclesiastic_incite_claim_war_interaction_effect = { + scope:target = { + save_scope_as = sponsored_claim_war_target + } + show_as_tooltip = { + pam_incite_claim_war_effect = yes + } + hidden_effect = { + scope:actor = { + send_interface_toast = { + type = event_toast_effect_good + title = ecclesiastic_incite_claim_war_interaction_toast + desc = incite_claim_war_past_tense_tt + left_icon = scope:secondary_recipient + right_icon = scope:recipient + pam_incite_claim_war_effect = yes + } + } + if = { + limit = { + scope:secondary_recipient = { + is_ai = no + this != scope:actor + } + } + scope:secondary_recipient = { + send_interface_toast = { + type = event_toast_effect_neutral + title = ecclesiastic_incite_claim_war_interaction_attacker_toast + desc = incite_claim_war_past_tense_tt + left_icon = scope:puppet_or_actor + right_icon = scope:recipient + if = { + limit = { scope:join_war ?= yes } + custom_tooltip = incite_claim_war_joined_tt + } + else_if = { + limit = { scope:fund_war ?= yes } + custom_tooltip = incite_claim_war_funded_tt + } + } + } + } + if = { + limit = { + scope:recipient = { + is_ai = no + this != scope:actor + this != scope:secondary_recipient + } + } + scope:recipient = { + send_interface_toast = { + type = event_toast_effect_bad + title = ecclesiastic_incite_claim_war_interaction_defender_toast + desc = incite_claim_war_past_tense_tt + left_icon = scope:secondary_recipient + right_icon = scope:puppet_or_actor + if = { + limit = { scope:join_war ?= yes } + custom_tooltip = incite_claim_war_joined_tt + } + } + } + } + } +} + +request_white_peace_interaction_effect = { + scope:puppet_or_actor = { + random_character_war = { + limit = { + pam_request_white_peace_war_with_enemy_trigger = { ENEMY = scope:secondary_recipient } + } + save_scope_as = white_peace_war + save_scope_as = war #release_prisoners_of_war_effect resolves the war through scope:war + } + } + scope:white_peace_war = { + casus_belli = { + primary_attacker = { + save_scope_as = attacker + } + primary_defender = { + save_scope_as = defender + } + } + release_prisoners_of_war_effect = yes + end_war = white_peace + } + scope:recipient = { + send_interface_toast = { + type = event_toast_effect_good + title = request_white_peace_interaction_recipient_toast + left_icon = scope:puppet_or_actor + right_icon = scope:secondary_recipient + if = { + limit = { + OR = { + rite = { + OR = { + has_tenet_status = { tenet = tenet_peace_of_god status = core } + has_tenet_status = { tenet = tenet_pacifism status = core } + has_tenet_status = { tenet = tenet_dharmic_pacifism status = core } + } + } + any_personal_tenet = { + OR = { + this = tenet:tenet_peace_of_god + this = tenet:tenet_pacifism + this = tenet:tenet_dharmic_pacifism + } + } + } + } + change_spiritual_fulfillment = minor_spiritual_fulfillment_value + } + else_if = { + limit = { + NOT = { has_character_modifier = pam_white_peace_enforcer_modifier } + } + add_character_modifier = { + modifier = pam_white_peace_enforcer_modifier + years = 10 + } + } + if = { + limit = { has_any_nickname = no } + hidden_effect = { + random = { + chance = { + value = 1 + if = { + limit = { is_ai = no } + add = 9 + } + } + give_nickname = nick_the_peacemaker + } + } + } + } + } + scope:secondary_recipient = { + if = { + limit = { is_ai = yes } + add_opinion = { + target = scope:recipient + modifier = pam_enforced_white_peace_opinion + } + } + trigger_event = pam_interactions_events.0080 + } + if = { + limit = { + situation:the_christian_church ?= { + situation_top_has_catalyst = catalyst_the_christian_church_white_peace_enforced + } + } + situation:the_christian_church = { + trigger_situation_catalyst = catalyst_the_christian_church_white_peace_enforced + } + } + scope:puppet_or_actor = { + if = { + limit = { + scope:donate_faith = yes + } + pay_treasury_or_gold = { + target = scope:recipient + value = major_gold_value + } + } + if = { + limit = { + scope:offer_piety = yes + } + add_piety = major_piety_loss + scope:recipient = { + add_piety = major_piety_gain + } + } + if = { + limit = { + scope:offer_hook = yes + } + scope:recipient = { + add_hook = { + type = favor_hook + target = scope:puppet_or_actor + } + } + } + pam_offer_pilgrimage_effect = { + ACTOR = scope:puppet_or_actor + CLERIC = scope:recipient + } + send_interface_toast = { + type = event_toast_effect_neutral + title = request_white_peace_interaction_toast_title + custom_tooltip = request_white_peace_interaction_toast + left_icon = scope:recipient + right_icon = scope:secondary_recipient + } + } + if = { + limit = { + scope:is_puppet_action ?= yes + scope:actor != scope:recipient + } + scope:actor = { + send_interface_toast = { + type = event_toast_effect_neutral + title = request_white_peace_interaction_toast_title + custom_tooltip = request_white_peace_interaction_toast_puppeteer + left_icon = scope:puppet_or_actor + right_icon = scope:recipient + } + } + } +} + +request_victory_interaction_effect = { + scope:puppet_or_actor = { + random_character_war = { + limit = { + pam_request_victory_war_with_enemy_trigger = { ENEMY = scope:secondary_recipient } + } + save_scope_as = requested_victory_war + save_scope_as = war #release_prisoners_of_war_effect resolves the war through scope:war + } + } + if = { + #The war can end during the reply window, leaving nothing to rule on + limit = { exists = scope:requested_victory_war } + scope:requested_victory_war = { + casus_belli = { + primary_attacker = { + save_scope_as = attacker + } + primary_defender = { + save_scope_as = defender + } + } + release_prisoners_of_war_effect = yes + if = { + limit = { + casus_belli = { + primary_attacker = scope:puppet_or_actor + } + } + end_war = attacker + } + else = { + end_war = defender + } + } + scope:recipient = { + send_interface_toast = { + type = event_toast_effect_neutral + title = request_victory_interaction_recipient_toast + left_icon = scope:puppet_or_actor + right_icon = scope:secondary_recipient + } + } + #The Church makes it worth the loser's while, so that obeying a ruling is not simply a defeat + scope:secondary_recipient = { + if = { + limit = { + NOT = { has_character_modifier = pam_church_compensation_modifier } + } + add_character_modifier = { + modifier = pam_church_compensation_modifier + years = 10 + } + } + if = { + limit = { is_ai = yes } + add_opinion = { + target = scope:recipient + modifier = pam_enforced_victory_opinion + } + } + trigger_event = pam_interactions_events.0083 + } + if = { + limit = { + situation:the_christian_church ?= { + situation_top_has_catalyst = catalyst_the_christian_church_victory_enforced + } + } + situation:the_christian_church = { + trigger_situation_catalyst = catalyst_the_christian_church_victory_enforced + } + } + scope:puppet_or_actor = { + if = { + limit = { + scope:donate_faith = yes + } + pay_treasury_or_gold = { + target = scope:recipient + value = major_gold_value + } + } + if = { + limit = { + scope:offer_piety = yes + } + add_piety = major_piety_loss + scope:recipient = { + add_piety = major_piety_gain + } + } + if = { + limit = { + scope:offer_hook = yes + } + scope:recipient = { + add_hook = { + type = favor_hook + target = scope:puppet_or_actor + } + } + } + pam_offer_pilgrimage_effect = { + ACTOR = scope:puppet_or_actor + CLERIC = scope:recipient + } + send_interface_toast = { + type = event_toast_effect_neutral + title = request_victory_interaction_toast_title + custom_tooltip = request_victory_interaction_toast + left_icon = scope:recipient + right_icon = scope:secondary_recipient + } + } + if = { + limit = { + scope:is_puppet_action ?= yes + scope:actor != scope:recipient + } + scope:actor = { + send_interface_toast = { + type = event_toast_effect_neutral + title = request_victory_interaction_toast_title + custom_tooltip = request_victory_interaction_toast_puppeteer + left_icon = scope:puppet_or_actor + right_icon = scope:recipient + } + } + } + } +} + +pam_enforce_title_succession_effect = { + scope:target = { save_scope_as = succession_title } + scope:target.holder = { save_scope_as = succession_holder } + scope:succession_title = { + current_heir = { save_scope_as = enforced_heir } + } + if = { + limit = { + exists = scope:enforced_heir + NOT = { scope:enforced_heir = scope:succession_holder } + } + create_title_and_vassal_change = { + type = stepped_down + save_scope_as = succession_title_change + add_claim_on_loss = no + } + scope:succession_title = { + change_title_holder_include_vassals = { + holder = scope:enforced_heir + change = scope:succession_title_change + } + } + resolve_title_and_vassal_change = scope:succession_title_change + } + if = { + limit = { scope:succession_holder = { is_ai = yes } } + scope:succession_holder = { + add_opinion = { + target = scope:actor + modifier = meddling_church_opinion + } + } + } +} + +pam_increase_papabile_score_effect = { + if = { + limit = { scope:pam_papabile_gold_option = yes } + custom_tooltip = { + text = pam_increase_papabile_score_effect_20_tt + if = { + limit = { exists = var:pam_papabile_score } + change_variable = { + name = pam_papabile_score + add = $VALUE$ + } + } + else = { + set_variable = { + name = pam_papabile_score + value = $VALUE$ + } + } + } + if = { + limit = { this != scope:actor } + add_opinion = { + target = scope:actor + modifier = grateful_opinion + opinion = 30 + } + } + } + else = { + custom_tooltip = { + text = pam_increase_papabile_score_effect_10_tt + if = { + limit = { exists = var:pam_papabile_score } + change_variable = { + name = pam_papabile_score + add = $VALUE$ + } + } + else = { + set_variable = { + name = pam_papabile_score + value = $VALUE$ + } + } + } + if = { + limit = { this != scope:actor } + add_opinion = { + target = scope:actor + modifier = grateful_opinion + opinion = 15 + } + } + } + # Both branches above have already created the variable + if = { + limit = { + scope:actor ?= { + has_personal_tenet_flag = tenet_apostolic_succession_papabile_influence + } + } + custom_tooltip = { + text = pam_increase_papabile_score_apostolic_succession_tt + change_variable = { + name = pam_papabile_score + add = pam_apostolic_succession_papabile_bonus_value + } + } + } + if = { + limit = { exists = scope:actor } + custom_tooltip = { + text = pam_papabile_leaning_tt + pam_spread_papabile_leaning_effect = { VALUE = $VALUE$ } + } + } +} + +pam_spread_papabile_leaning_effect = { + save_scope_as = pam_papabile_candidate + faith = { + every_clerical_elector_title = { + limit = { + holder ?= { + this != scope:pam_papabile_candidate + OR = { + this = scope:actor + is_vassal_or_below_of = scope:actor + top_liege ?= scope:actor.top_liege + is_close_or_extended_family_of = scope:actor + scope:actor.puppet:theological_agent_puppet ?= this + scope:actor.puppet:external_theological_agent_puppet ?= this + opinion = { + target = scope:actor + value >= medium_positive_opinion + } + } + } + } + holder ?= { + pam_apply_papabile_leaning_effect = { VALUE = $VALUE$ } + } + } + } +} + +pam_apply_papabile_leaning_effect = { + set_variable = { + name = pam_papabile_leaning_target + value = scope:pam_papabile_candidate + years = 20 + } + set_variable = { + name = pam_papabile_leaning_value + value = $VALUE$ + years = 20 + } +} + +# We declare the cardinal for that seat, otherwise a holy candidate is listed as The Pious +pam_place_first_as_powerful_effect = { + custom_tooltip = { + text = pam_place_first_as_powerful_tt + if = { + limit = { exists = var:pam_papabile_score } + change_variable = { + name = pam_papabile_score + add = $VALUE$ + } + } + else = { + set_variable = { + name = pam_papabile_score + value = $VALUE$ + } + } + } + custom_tooltip = { + text = pam_campaign_as_powerful_tt + remove_variable = pam_campaign_as_populist + set_variable = { + name = pam_campaign_as_powerful + years = 20 + } + } + # Deliberately the flat nudge rather than the purchased score: buying the seat should not also buy the vote. + if = { + limit = { exists = scope:actor } + custom_tooltip = { + text = pam_papabile_leaning_tt + pam_spread_papabile_leaning_effect = { VALUE = 10 } + } + } +} + +pam_place_first_as_populist_effect = { + # Own variable, and the elector vote modifier also reads pam_propagate_word_of_my_piety the same way + custom_tooltip = { + text = pam_place_first_as_populist_tt + if = { + limit = { exists = var:pam_papabile_populist_score } + change_variable = { + name = pam_papabile_populist_score + add = $VALUE$ + } + } + else = { + set_variable = { + name = pam_papabile_populist_score + value = $VALUE$ + } + } + } + custom_tooltip = { + text = pam_campaign_as_populist_tt + remove_variable = pam_campaign_as_powerful + set_variable = { + name = pam_campaign_as_populist + years = 20 + } + } + # Deliberately the flat nudge rather than the purchased score, matching the Powerful path. + if = { + limit = { exists = scope:actor } + custom_tooltip = { + text = pam_papabile_leaning_tt + pam_spread_papabile_leaning_effect = { VALUE = 10 } + } + } +} + +# $TT$ localizes the papabile loss for the losing side (defender on victory, attacker on defeat) +pam_humiliation_war_church_standing_loss_effect = { + if = { + limit = { + OR = { + exists = clerical_elector_title + exists = var:pam_papabile_score + } + } + custom_tooltip = { + text = $TT$ + if = { + limit = { exists = var:pam_papabile_score } + change_variable = { + name = pam_papabile_score + subtract = 25 + } + } + else = { + set_variable = { + name = pam_papabile_score + value = -25 + } + } + } + } + # Only clerical rulers carry standing the disgrace can bite into; it feeds clerical appointment scoring + if = { + limit = { government_has_flag = government_uses_church_authority } + add_character_modifier = { + modifier = pam_clerical_disgrace_modifier + years = 20 + } + } +} + +pam_on_conversion_effect = { + if = { + limit = { is_ai = no } + add_character_flag = { + flag = faith_conversion_recently_converted + years = pam_ui_conversion_cooldown + } + } +} + +remove_personal_tenet_if_has = { + if = { + limit = { has_personal_tenet = $TENET$ } + remove_personal_tenet = $TENET$ + } +} + +add_known_tenet_if_not = { + if = { + limit = { NOT = { knows_tenet = $TENET$ } } + add_known_tenet = $TENET$ + } +} + +update_syncretism_personal_tenet_effect = { + if = { + limit = { + is_available_quick = { advanced_ruler = yes } + scope:old_faith.religion != faith.religion + } + scope:old_faith = { + if = { + limit = { has_doctrine = sinitic_hostility_doctrine } + prev = { add_known_tenet_if_not = { TENET = tenet_sinitic_syncretism } } + } + else_if = { + limit = { has_doctrine = eastern_hostility_doctrine } + prev = { add_known_tenet_if_not = { TENET = tenet_eastern_syncretism } } + } + else_if = { + limit = { has_doctrine = pagan_hostility_doctrine } + prev = { add_known_tenet_if_not = { TENET = tenet_unreformed_syncretism } } + } + else_if = { + limit = { religion_tag = christianity_religion } + prev = { add_known_tenet_if_not = { TENET = tenet_christian_syncretism } } + } + else_if = { + limit = { religion_tag = islam_religion } + prev = { add_known_tenet_if_not = { TENET = tenet_islamic_syncretism } } + } + else_if = { + limit = { religion_tag = judaism_religion } + prev = { add_known_tenet_if_not = { TENET = tenet_jewish_syncretism } } + } + } + faith = { + if = { + limit = { has_doctrine = sinitic_hostility_doctrine } + prev = { remove_personal_tenet_if_has = { TENET = tenet_sinitic_syncretism } } + } + else_if = { + limit = { has_doctrine = eastern_hostility_doctrine } + prev = { remove_personal_tenet_if_has = { TENET = tenet_eastern_syncretism } } + } + else_if = { + limit = { has_doctrine = pagan_hostility_doctrine } + prev = { remove_personal_tenet_if_has = { TENET = tenet_unreformed_syncretism } } + } + else_if = { + limit = { religion_tag = christianity_religion } + prev = { remove_personal_tenet_if_has = { TENET = tenet_christian_syncretism } } + } + else_if = { + limit = { religion_tag = islam_religion } + prev = { remove_personal_tenet_if_has = { TENET = tenet_islamic_syncretism } } + } + else_if = { + limit = { religion_tag = judaism_religion } + prev = { remove_personal_tenet_if_has = { TENET = tenet_jewish_syncretism } } + } + } + } +} + +# Keep branches in sync with pam_sway_to_rite_variant_can_send_trigger +pam_open_sway_to_rite_variant_effect = { + if = { + limit = { scope:recipient = { is_courtier_of = scope:actor } } + open_interaction_window = { + interaction = sway_courtier_to_my_rite_interaction + actor = scope:actor + recipient = scope:recipient + } + } + else_if = { + limit = { + scope:recipient = { + OR = { + target_is_liege_or_above = scope:actor + is_tributary_of = scope:actor + pam_rite_sway_house_lane_trigger = { + ACTOR = scope:actor + RECIPIENT = scope:recipient + } + } + } + } + open_interaction_window = { + interaction = sway_vassal_to_my_rite_interaction + actor = scope:actor + recipient = scope:recipient + } + } + else = { + open_interaction_window = { + interaction = sway_ruler_to_my_rite_interaction + actor = scope:actor + recipient = scope:recipient + } + } +} + +# Shared on_accept for the three Sway to Rite interactions +# Option flags exist only on outreach, so the ?= checks do nothing elsewhere +pam_sway_to_rite_on_accept_effect = { + if = { + limit = { scope:is_puppet_action ?= yes } + scope:puppet_or_actor = { + if = { + limit = { pam_sway_ruler_to_my_rite_cost_value > 0 } + add_piety = { + value = { + add = pam_sway_ruler_to_my_rite_cost_value + max = piety + multiply = -1 + } + } + } + } + } + scope:puppet_or_actor = { + send_interface_toast = { + type = event_toast_effect_good + title = sway_ruler_to_my_rite_interaction_toast + left_icon = scope:puppet_or_actor + right_icon = scope:recipient + scope:recipient = { + set_character_rite = scope:puppet_or_actor.rite + if = { + limit = { is_ai = yes } + add_opinion = { + target = scope:puppet_or_actor + modifier = pious_opinion + opinion = 10 + } + } + if = { # Accepting the founding wave of a freshly created rite pulls the whole domain and court along, but only if they are actually tied to us + limit = { + is_ruler = yes + is_landed = yes + scope:puppet_or_actor.rite ?= { + has_variable = pam_rite_founding_window + } + pam_rite_sway_connected_recipient_trigger = { ACTOR = scope:puppet_or_actor } + } + pam_convert_domain_counties_to_rite_effect = { RITE = scope:puppet_or_actor.rite } + pam_convert_court_to_rite_effect = { RITE = scope:puppet_or_actor.rite } + } + else_if = { # We also convert their capital county + limit = { + is_ruler = yes + is_landed = yes + capital_county = { + this.faith = scope:puppet_or_actor.faith # set_county_rite would drag a foreign-faith capital across faiths + this.rite != scope:puppet_or_actor.rite + any_neighboring_county = { # only if a neighbor shares the same liege or IS the liege, aka I'm not surrounded by complete strangers + OR = { + this.holder.liege = prev.holder.liege + this.holder = prev.holder.liege + } + } + } + } + capital_county = { set_county_rite = scope:puppet_or_actor.rite } + } + if = { + limit = { scope:pam_sway_pledge_favor ?= yes } + add_hook = { + target = scope:puppet_or_actor + type = favor_hook + } + } + } + if = { + limit = { scope:pam_sway_endowment ?= yes } + scope:puppet_or_actor = { + pay_treasury_or_gold = { + target = scope:recipient + value = pam_sway_to_rite_endowment_cost_value + } + } + } + } + # Catalysts + if = { + limit = { + scope:puppet_or_actor.religion = religion:christianity_religion + situation:the_christian_church ?= { situation_top_has_catalyst = catalyst_the_christian_church_swayed_to_rite } + } + situation:the_christian_church = { trigger_situation_catalyst = catalyst_the_christian_church_swayed_to_rite } + } + } + if = { + limit = { + scope:is_puppet_action ?= yes + scope:actor != scope:recipient + } + scope:actor = { + send_interface_toast = { + type = event_toast_effect_good + title = sway_ruler_to_my_rite_interaction_toast_puppeteer + left_icon = scope:puppet_or_actor + right_icon = scope:recipient + } + } + } + scope:puppet_or_actor = { + pam_tax_nonbelievers_conversion_fulfillment_effect = yes + } +} + +# Shared on_decline for the three Sway to Rite interactions. +pam_sway_to_rite_on_decline_effect = { + scope:puppet_or_actor = { + send_interface_toast = { + type = event_toast_effect_bad + title = sway_ruler_to_my_rite_interaction_decline_toast + right_icon = scope:recipient + scope:recipient = { + if = { + limit = { is_ai = yes } + add_opinion = { + target = scope:puppet_or_actor + modifier = annoyed_opinion + opinion = -10 + } + } + } + } + } + if = { + limit = { + scope:is_puppet_action ?= yes + scope:actor != scope:recipient + } + scope:actor = { + send_interface_toast = { + type = event_toast_effect_bad + title = sway_ruler_to_my_rite_interaction_decline_toast_puppeteer + left_icon = scope:puppet_or_actor + right_icon = scope:recipient + } + } + } +} + +# PAM - Converts every county in a ruler's domain that shares their faith to $RITE$ +# The capital is skipped while a different-rite clerical region holder is seated in it, unless that holder is our puppet +pam_convert_domain_counties_to_rite_effect = { + save_temporary_scope_as = domain_rite_converter + every_held_title = { + limit = { + tier = tier_county + faith = scope:domain_rite_converter.faith + rite != $RITE$ + trigger_if = { + limit = { scope:domain_rite_converter.capital_county ?= this } + NOT = { + clerical_region_title ?= { + holder ?= { + capital_county = scope:domain_rite_converter.capital_county + faith = scope:domain_rite_converter.faith + rite != $RITE$ + NOR = { + scope:domain_rite_converter.puppet:theological_agent_puppet ?= this + scope:domain_rite_converter.puppet:external_theological_agent_puppet ?= this + } + } + } + } + } + } + set_county_rite = $RITE$ + } +} + +# PAM - Converts a ruler's court (present, away, and guests) that shares their faith to $RITE$, mirroring rite growth's court conversion +pam_convert_court_to_rite_effect = { + every_courtier_or_guest = { + limit = { + is_physically_able_ai = yes + faith = $RITE$.faith + rite != $RITE$ + NOT = { has_character_flag = ai_will_not_convert } + } + set_character_rite = $RITE$ + } + every_courtier_away = { + limit = { + is_physically_able_ai = yes + faith = $RITE$.faith + rite != $RITE$ + NOT = { has_character_flag = ai_will_not_convert } + } + set_character_rite = $RITE$ + } +} + +# PAM - Faith counterpart of pam_convert_court_to_rite_effect: converts a ruler's court still on $OLD_FAITH$ to $FAITH$ +pam_convert_court_to_faith_effect = { + every_courtier_or_guest = { + limit = { + is_physically_able_ai = yes + faith = $OLD_FAITH$ + NOT = { has_character_flag = ai_will_not_convert } + } + set_character_faith = $FAITH$ + } + every_courtier_away = { + limit = { + is_physically_able_ai = yes + faith = $OLD_FAITH$ + NOT = { has_character_flag = ai_will_not_convert } + } + set_character_faith = $FAITH$ + } +} + +# PAM Great Schism: shows $TT$, and $VALUE$ goes up when positive (zero still shows the tooltip) +# Progress only goes up, and we do nothing once the schism has happened or been prevented +pam_change_great_schism_progress_effect = { + custom_tooltip = $TT$ + hidden_effect = { + if = { + limit = { pam_great_schism_progress_can_change_trigger = yes } + if = { + limit = { $VALUE$ > 0 } + situation:the_christian_church = { + if = { + limit = { NOT = { has_variable = pam_progress_towards_great_schism } } + set_variable = { name = pam_progress_towards_great_schism value = 0 } + } + change_variable = { + name = pam_progress_towards_great_schism + add = $VALUE$ + } + } + every_player = { + limit = { + faith.religion = religion:christianity_religion + exists = top_participant_group:the_christian_church + } + send_interface_message = { + type = msg_pam_great_schism_progress + desc = $TT$ + } + } + } + if = { + limit = { + situation:the_christian_church = { + NOT = { has_variable = pam_great_schism_status } + pam_great_schism_progress_value >= pam_great_schism_progress_threshold_value + } + } + situation:the_christian_church = { + pam_update_schism_rite_variables_effect = yes + var:schism_mainline_rite ?= { save_scope_as = schism_mainline_rite } + var:schism_competitor_rite ?= { save_scope_as = schism_competitor_rite } + set_variable = { + name = pam_great_schism_status + value = flag:threshold_reached + } + } + scope:schism_mainline_rite.head_of_rite ?= { save_scope_as = schism_mainline_head } + scope:schism_competitor_rite.head_of_rite ?= { save_scope_as = schism_competitor_head } + every_player = { + limit = { + faith.religion = religion:christianity_religion + any_character_situation = { this = situation:the_christian_church } + } + trigger_event = pam_the_christian_church.0064 + } + } + } + } +} + +# Situation scope, and a third rite as mainline keeps the existing Rome and Constantinople order +pam_update_schism_rite_variables_effect = { + if = { + limit = { + #stop updating it if the schism is going to happen + situation:the_christian_church ?= { + NOT = { has_variable = pam_great_schism_status } + } + } + if = { + limit = { faith:christian_faith.main_rite ?= rite:roman_rite } + set_variable = { name = schism_mainline_rite value = rite:roman_rite } + set_variable = { name = schism_competitor_rite value = rite:byzantine_rite } + } + else_if = { + limit = { faith:christian_faith.main_rite ?= rite:byzantine_rite } + set_variable = { name = schism_mainline_rite value = rite:byzantine_rite } + set_variable = { name = schism_competitor_rite value = rite:roman_rite } + } + else_if = { + limit = { NOT = { has_variable = schism_mainline_rite } } + set_variable = { name = schism_mainline_rite value = rite:roman_rite } + set_variable = { name = schism_competitor_rite value = rite:byzantine_rite } + } + } +} + +# Converters are root, with scope:old_rite the rite they left, when on_rite_change fires +# Flag spaces repeats and stops the event's own conversion from chaining +pam_schism_rite_conversion_dissent_effect = { + if = { + limit = { + is_landed = yes + exists = scope:old_rite + scope:old_rite != rite + OR = { + highest_held_title_tier >= tier_kingdom + pam_is_investiture_clergy_trigger = yes + } + pam_schism_rite_in_pair_trigger = { RITE = scope:old_rite } + pam_schism_rite_in_pair_trigger = { RITE = root.rite } + pam_great_schism_progress_can_change_trigger = yes + NOT = { has_character_flag = pam_schism_rite_conversion_dissent_recently } + } + random = { + chance = pam_schism_rite_conversion_dissent_chance_value + scope:old_rite = { save_scope_as = pam_dissent_rite } + add_character_flag = { + flag = pam_schism_rite_conversion_dissent_recently + years = 10 + } + trigger_event = { + id = pam_the_christian_church.0063 + days = { 3 10 } + } + } + } +} + +# $RITE$ is the rite they stayed with, evaluated on the character +# Shares pam_schism_rite_dissenter_valid_trigger with pam_the_christian_church.0063 +pam_save_schism_rite_dissenter_effect = { + every_courtier = { + limit = { pam_schism_rite_dissenter_valid_trigger = { RITE = $RITE$ } } + add_to_list = pam_schism_dissenter_candidates + } + every_vassal_or_below = { + limit = { pam_schism_rite_dissenter_valid_trigger = { RITE = $RITE$ } } + add_to_list = pam_schism_dissenter_candidates + } + every_pool_character = { + province = root.location + limit = { pam_schism_rite_dissenter_valid_trigger = { RITE = $RITE$ } } + add_to_list = pam_schism_dissenter_candidates + } + random_in_list = { + list = pam_schism_dissenter_candidates + weight = { + base = 1 + modifier = { + add = 10 + pam_is_investiture_clergy_trigger = yes + } + modifier = { + add = 5 + highest_held_title_tier >= tier_county + } + modifier = { + add = 5 + is_close_family_of = root + } + } + save_scope_as = schism_dissenter + } + if = { + limit = { + NOT = { exists = scope:schism_dissenter } + } + create_character = { + template = priest_character_template + employer = root + faith = root.faith + rite = $RITE$ + culture = root.culture + save_scope_as = schism_dissenter + after_creation = { + add_character_flag = created + } + } + } +} + +# A county is root when on_county_rite_change runs this, with scope:old_rite the rite it used to have +# A faith swap books nothing, because the schism is a quarrel within Christianity +pam_schism_county_conversion_progress_effect = { + if = { + limit = { + exists = scope:old_rite + rite != scope:old_rite + pam_schism_rite_in_pair_trigger = { RITE = scope:old_rite } + any_county_holy_site = { + any_holy_site_faith = { this = faith:christian_faith } + } + } + if = { + limit = { pam_schism_county_rite_in_pair_trigger = { COUNTY = root } } + pam_change_great_schism_progress_effect = { + VALUE = pam_great_schism_progress_county_conversion_value + TT = pam_great_schism_progress_county_conversion_tt + } + } + else = { # Attribute to the pair rite losing the county (gainer is outside the pair) + pam_change_great_schism_progress_effect = { + VALUE = pam_great_schism_progress_county_conversion_edge_value + TT = pam_great_schism_progress_county_conversion_edge_tt + } + } + } +} + +# Fire the Great Schism catalyst again on phase change to make sure Saeculum Obscurum happens +pam_refire_great_schism_catalyst_effect = { + if = { + limit = { + pam_great_schism_progress_can_change_trigger = yes + var:pam_great_schism_status ?= flag:threshold_reached + pam_great_schism_progress_value >= pam_great_schism_progress_threshold_value + situation_top_has_catalyst = catalyst_the_christian_church_great_schism + } + trigger_situation_catalyst = catalyst_the_christian_church_great_schism + } +} + +# PAM - Great Schism: fire the schism start event for Chalcedonian rulers once conditions hold +pam_fire_great_schism_start_event_effect = { + if = { + limit = { var:pam_great_schism_status ?= flag:threshold_reached } + var:schism_mainline_rite = { save_scope_as = schism_mainline_rite } + var:schism_competitor_rite = { save_scope_as = schism_competitor_rite } + scope:schism_mainline_rite.head_of_rite ?= { save_scope_as = schism_mainline_head } + scope:schism_competitor_rite.head_of_rite ?= { save_scope_as = schism_competitor_head } + set_variable = { + name = pam_great_schism_status + value = flag:ongoing + } + every_situation_participant = { + limit = { + is_ruler = yes + faith = faith:christian_faith + } + trigger_event = pam_the_christian_church.0060 + } + } +} + +pam_offer_great_schism_stance_effect = { + if = { + limit = { + pam_can_pick_great_schism_stance_trigger = yes + NOR = { + has_variable = pam_schism_stance + has_character_flag = pam_offered_great_schism_stance + } + } + pam_send_great_schism_stance_offer_effect = yes + } +} + +pam_offer_great_schism_stance_to_new_player_effect = { + if = { + limit = { pam_can_pick_great_schism_stance_trigger = yes } + pam_send_great_schism_stance_offer_effect = yes + } +} + +pam_send_great_schism_stance_offer_effect = { + add_character_flag = pam_offered_great_schism_stance + situation:the_christian_church = { + var:schism_mainline_rite = { save_scope_as = schism_mainline_rite } + var:schism_competitor_rite = { save_scope_as = schism_competitor_rite } + } + trigger_event = pam_the_christian_church.0060 +} + +# PAM - Sacred Childbirth: scaled piety (regular tenet) for a live birth. Also triggers spiritual fulfillment and stress loss rewards (personal tenet), shown in birth events +pam_childbirth_piety_reward_effect = { + if = { + limit = { rite = { rite_has_parameter = piety_from_childbirth_active } } + if = { + limit = { scope:child = { has_any_negative_bastard_trait_trigger = no } } + add_piety = { + value = major_piety_gain + if = { limit = { any_child = { is_twin_of = scope:child } } add = major_piety_gain } + if = { limit = { any_child = { count >= 3 is_twin_of = scope:child } } add = major_piety_gain } + } + } + else = { + add_piety = { + value = minor_piety_gain + if = { limit = { any_child = { is_twin_of = scope:child } } add = minor_piety_gain } + if = { limit = { any_child = { count >= 3 is_twin_of = scope:child } } add = minor_piety_gain } + } + } + } + pam_childbirth_spiritual_fulfillment_reward_effect = yes +} + +# PAM - Carnal Exaltation: piety for a successful seduce scheme +pam_seduction_piety_reward_effect = { + if = { + limit = { rite = { rite_has_parameter = piety_from_seduction_active } } + add_piety = medium_piety_gain + } +} + +# PAM - Sacred Childbirth: scaled spiritual fulfillment + stress loss (personal tenet) for a live birth; called on its own for children conceived in secret. shown in birth events +pam_childbirth_spiritual_fulfillment_reward_effect = { + if = { + limit = { + has_personal_tenet_flag = spiritual_fulfillment_from_childbirth_personal_active + has_pam_dlc_trigger = yes + } + if = { + limit = { scope:child = { has_any_negative_bastard_trait_trigger = no } } + change_spiritual_fulfillment = { + value = medium_spiritual_fulfillment_value + if = { limit = { any_child = { is_twin_of = scope:child } } add = medium_spiritual_fulfillment_value } + if = { limit = { any_child = { count >= 3 is_twin_of = scope:child } } add = medium_spiritual_fulfillment_value } + } + } + else = { + change_spiritual_fulfillment = { + value = minor_spiritual_fulfillment_value + if = { limit = { any_child = { is_twin_of = scope:child } } add = minor_spiritual_fulfillment_value } + if = { limit = { any_child = { count >= 3 is_twin_of = scope:child } } add = minor_spiritual_fulfillment_value } + } + } + } + if = { + limit = { + has_personal_tenet_flag = stress_loss_from_childbirth_personal_active + has_pam_dlc_trigger = yes + } + if = { + limit = { scope:child = { has_any_negative_bastard_trait_trigger = no } } + add_stress = { + value = medium_stress_loss + if = { limit = { any_child = { is_twin_of = scope:child } } add = medium_stress_loss } + if = { limit = { any_child = { count >= 3 is_twin_of = scope:child } } add = medium_stress_loss } + } + } + else = { + add_stress = { + value = minor_stress_loss + if = { limit = { any_child = { is_twin_of = scope:child } } add = minor_stress_loss } + if = { limit = { any_child = { count >= 3 is_twin_of = scope:child } } add = minor_stress_loss } + } + } + } +} + +# PAM - Sacred Childbirth: spiritual fulfillment loss for a child-death birth, shown in birth events +pam_childbirth_spiritual_fulfillment_penalty_effect = { + if = { + limit = { has_personal_tenet_flag = spiritual_fulfillment_from_childbirth_personal_active } + if = { + limit = { has_pam_dlc_trigger = yes } + change_spiritual_fulfillment = major_spiritual_fulfillment_loss + } + } +} + +# PAM - Epidemics: spiritual fulfillment loss from pestilence as divine wrath. Exaltation of Pain (faith or personal tenet) exempts the character. Needs argument AMOUNT (spiritual fulfillment script value) +pam_epidemic_spiritual_fulfillment_loss_effect = { + if = { + limit = { + is_playable_character = yes + NOR = { + rite = { rite_has_parameter = no_epidemic_fulfillment_loss_active } + has_personal_tenet_flag = no_epidemic_fulfillment_loss_personal_active + } + } + change_spiritual_fulfillment = $AMOUNT$ + } +} + +# PAM Epidemics: expects scope:epidemic, shown in epidemic arrival events +pam_epidemic_arrival_spiritual_fulfillment_loss_effect = { + if = { + limit = { scope:epidemic = { outbreak_intensity = apocalyptic } } + pam_epidemic_spiritual_fulfillment_loss_effect = { AMOUNT = massive_spiritual_fulfillment_loss } + } + else_if = { + limit = { scope:epidemic = { outbreak_intensity = major } } + pam_epidemic_spiritual_fulfillment_loss_effect = { AMOUNT = major_spiritual_fulfillment_loss } + } + else = { + pam_epidemic_spiritual_fulfillment_loss_effect = { AMOUNT = medium_spiritual_fulfillment_loss } + } +} + +# PAM - Epidemics: spiritual fulfillment loss when your court physician treats you for an epidemic disease (chronic diseases are exempt). Expects scope:disease_type, shown in disease treatment events +pam_epidemic_disease_treatment_spiritual_fulfillment_loss_effect = { + if = { + limit = { + OR = { + scope:disease_type = flag:bubonic_plague + scope:disease_type = flag:smallpox + scope:disease_type = flag:typhus + scope:disease_type = flag:measles + scope:disease_type = flag:dysentery + scope:disease_type = flag:consumption + scope:disease_type = flag:ergotism + } + } + pam_epidemic_spiritual_fulfillment_loss_effect = { AMOUNT = medium_spiritual_fulfillment_loss } + } +} + +consecrate_kingdom_effect = { + #If you don't have sway over the pope... they get sway over you + if = { + limit = { + NOT = { + this = scope:religious_authority + } + } + if = { + limit = { + NOR = { + has_hook = scope:religious_authority + scope:king_aspirant.puppet:theological_agent_puppet ?= scope:religious_authority + scope:king_aspirant.puppet:external_theological_agent_puppet ?= scope:religious_authority + } + } + scope:religious_authority = { + add_hook = { + type = strong_obligation_hook + target = scope:king_aspirant + } + } + } + else = { + scope:religious_authority = { + add_hook = { + type = obligation_hook + target = scope:king_aspirant + } + } + } + } + if = { + limit = { + scope:religious_authority = { + this = scope:king_aspirant + } + } + every_held_title = { + limit = { + tier = tier_county + } + empire = { + every_de_jure_county = { + limit = { + holder ?= { + faith = scope:king_aspirant.faith + NOT = { + government_has_flag = government_is_theocracy + } + } + } + holder = { + add_to_list = angry_seculars + every_liege_or_above = { + limit = { + faith = scope:king_aspirant.faith + NOT = { + government_has_flag = government_is_theocracy + } + } + add_to_list = angry_seculars + } + } + } + } + } + every_in_list = { + custom = custom.every_empire_secular_ruler + list = angry_seculars + + add_opinion = { + modifier = power_hungry_priest_opinion + target = scope:king_aspirant + opinion = -30 + } + } + } + create_custom_kingdom_effect = yes + if = { + limit = { + NOT = { + this = scope:religious_authority + } + top_participant_group:the_christian_church ?= { + OR = { + participant_group_type = christian_clerical_main_power_rulers + participant_group_type = christian_regular_main_power_rulers + } + } + situation:the_christian_church ?= { + situation_top_has_catalyst = catalyst_consecrated_kingdom_for_ruler + } + NOT = { + scope:king_aspirant = { government_has_flag = government_is_theocracy } + } + } + situation:the_christian_church = { + trigger_situation_catalyst = catalyst_consecrated_kingdom_for_ruler + } + } + else_if = { + limit = { + this = scope:religious_authority + situation:the_christian_church ?= { + situation_top_has_catalyst = catalyst_prelate_empowered_self_with_kingdom + } + } + situation:the_christian_church = { + trigger_situation_catalyst = catalyst_prelate_empowered_self_with_kingdom + } + } + else_if = { + limit = { + top_participant_group:the_christian_church ?= { + OR = { + participant_group_type = christian_clerical_main_power_rulers + participant_group_type = christian_regular_main_power_rulers + } + } + situation:the_christian_church ?= { + situation_top_has_catalyst = catalyst_consecrated_kingdom_for_theocrat + } + government_has_flag = government_is_theocracy + } + situation:the_christian_church = { + trigger_situation_catalyst = catalyst_consecrated_kingdom_for_theocrat + } + } + if = { + limit = { + is_ai = no + NOT = { exists = global_var:found_kingdom_decision } + } + set_global_variable = { + name = found_kingdom_decision + value = root + } + set_global_variable = { + name = found_kingdom_decision_kingdom + value = root.primary_title + } + } +} +consecrate_kingdom_player_cleric_effect = { + if = { + limit = { + is_ai = yes + } + if = { + limit = { + NOT = { + exists = scope:interaction + } + } + add_opinion = { + target = scope:religious_authority + modifier = support_opinion + opinion = 50 + } + } + else = { + add_opinion = { + target = scope:religious_authority + modifier = support_opinion + opinion = 25 + } + } + add_character_modifier = { + modifier = consecrated_king_modifier + desc = consecrated_king_ai_behavior_large_tt + years = 20 + } + custom_tooltip = consecrated_king_ai_behavior_large_tt + } + else = { + add_character_modifier = { + modifier = consecrated_king_modifier_small + years = 20 + } + } + scope:religious_authority = { save_scope_as = cleric } + ecclesiastical_title_bestowing_clerical_hesitation_effect = yes +} +grant_title_populate_concerned_de_jure_list_effect = { + if = { + limit = { + $TITLE_GAINER$ = { + any_held_title = { + tier = tier_duchy + kingdom.holder ?= { + religion = scope:puppet_or_actor.religion + NOT = { + this = scope:puppet_or_actor + } + } + } + } + } + $TITLE_GAINER$ = { + every_held_title = { + limit = { + tier = tier_duchy + kingdom.holder ?= { + religion = scope:puppet_or_actor.religion + NOT = { + this = scope:puppet_or_actor + } + } + } + kingdom.holder = { + add_to_list = grateful_refusal_chars + } + } + } + } +} +bestow_title_effect = { + if = { + limit = { + scope:use_hook ?= yes + scope:puppet_or_actor ?= { has_usable_hook = scope:recipient } + } + scope:puppet_or_actor = { use_hook = scope:recipient } + } + if = { + limit = { + scope:gain_weak_hook ?= yes + } + scope:puppet_or_actor = { + add_hook = { + type = obligation_hook + target = scope:recipient + } + } + } + else_if = { + limit = { + scope:gain_strong_hook ?= yes + } + scope:puppet_or_actor = { + add_hook = { + type = strong_obligation_hook + target = scope:recipient + } + } + } + else = { + if = { + limit = { + exists = scope:target + } + scope:puppet_or_actor = { + add_prestige = { + value = minor_prestige_gain + multiply = { + value = scope:target.tier + subtract = 2 + } + } + } + + } + else = { + scope:puppet_or_actor = { + add_prestige = minor_prestige_gain + } + } + } + + scope:recipient = { save_scope_as = bestowed_title_holder } + scope:puppet_or_actor = { save_scope_as = bestowing_cleric } + bestow_title_shared_effect = yes +} +# Creates the unheld title and hands it to its new holder. Runs in the new holder's scope; callers must save scope:bestowed_title_holder and scope:bestowing_cleric first, since the clergy and the ruler swap roles between the bestowal and the petition. +bestow_title_shared_effect = { + create_title_and_vassal_change = { + type = created + save_scope_as = ecclesiastical_bestow_title_change + add_claim_on_loss = no + } + scope:target = { + change_title_holder = { + holder = scope:bestowed_title_holder + change = scope:ecclesiastical_bestow_title_change + } + } + resolve_title_and_vassal_change = scope:ecclesiastical_bestow_title_change + + scope:target ?= { + if = { + limit = { tier = tier_empire } + scope:bestowed_title_holder = { + add_opinion = { + modifier = received_title_empire + target = scope:bestowing_cleric + opinion = 50 + } + } + } + else_if = { + limit = { tier = tier_kingdom } + scope:bestowed_title_holder = { + add_opinion = { + modifier = received_title_kingdom + target = scope:bestowing_cleric + opinion = 25 + } + } + } + else_if = { + limit = { tier = tier_duchy } + scope:bestowed_title_holder = { + add_opinion = { + modifier = received_title_duchy + target = scope:bestowing_cleric + opinion = 15 + } + } + } + } + if = { + limit = { + NOT = { government_has_flag = government_is_theocracy } + top_participant_group:the_christian_church ?= { + OR = { + participant_group_type = christian_clerical_main_power_rulers + participant_group_type = christian_regular_main_power_rulers + } + } + situation:the_christian_church ?= { + situation_top_has_catalyst = catalyst_hof_bestowed_title + } + scope:target.tier >= tier_kingdom + } + if = { + limit = { + exists = scope:target + scope:target.tier >= tier_empire + } + situation:the_christian_church = { + trigger_situation_catalyst = catalyst_hof_bestowed_title_major + } + } + else = { + situation:the_christian_church = { + trigger_situation_catalyst = catalyst_hof_bestowed_title + } + } + } + else_if = { + limit = { + government_has_flag = government_is_theocracy + top_participant_group:the_christian_church ?= { + OR = { + participant_group_type = christian_clerical_main_power_rulers + participant_group_type = christian_regular_main_power_rulers + } + } + situation:the_christian_church ?= { + situation_top_has_catalyst = catalyst_hof_bestowed_title_clergy + } + } + if = { + limit = { + exists = scope:target + scope:target.tier >= tier_empire + } + situation:the_christian_church = { + trigger_situation_catalyst = catalyst_hof_bestowed_title_clergy_major + } + } + else_if = { + limit = { + exists = scope:target + scope:target.tier >= tier_kingdom + } + situation:the_christian_church = { + trigger_situation_catalyst = catalyst_hof_bestowed_title_clergy + } + } + else = { + situation:the_christian_church = { + trigger_situation_catalyst = catalyst_hof_bestowed_title_clergy_minor + } + } + } + scope:bestowing_cleric = { save_scope_as = cleric } + if = { + limit = { + scope:bestowing_cleric = { + is_ai = no + } + } + ecclesiastical_title_bestowing_clerical_hesitation_effect = yes + } + else = { + hidden_effect = { + ecclesiastical_title_bestowing_clerical_hesitation_effect = yes + } + } +} +# The petition counterpart to bestow_title_effect: the clergy proclaim the unheld title and crown the petitioner. Runs in the petitioner's scope. +request_unformed_title_effect = { + custom_tooltip = request_unformed_title_gain_tt + if = { + limit = { + scope:donate_faith ?= yes + } + pay_short_term_gold = { + target = scope:recipient + gold = major_gold_value + } + } + if = { + limit = { + scope:use_hook ?= yes + has_usable_hook = scope:recipient + } + use_hook = scope:recipient + } + if = { + limit = { + scope:offer_hook ?= yes + } + scope:recipient = { + add_hook = { + type = favor_hook + target = scope:puppet_or_actor + } + } + } + pam_offer_pilgrimage_effect = { + ACTOR = scope:puppet_or_actor + CLERIC = scope:recipient + } + + scope:puppet_or_actor = { save_scope_as = bestowed_title_holder } + scope:recipient = { save_scope_as = bestowing_cleric } + bestow_title_shared_effect = yes + + #The clergy publicly stand behind the new crown, and their flock is expected to respect it + if = { + limit = { + is_ai = yes + } + add_character_modifier = { + modifier = consecrated_king_modifier + desc = consecrated_king_ai_behavior_large_tt + years = 20 + } + custom_tooltip = consecrated_king_ai_behavior_large_tt + } + else = { + add_character_modifier = { + modifier = consecrated_king_modifier_small + years = 20 + } + } + if = { + limit = { + scope:promise_holy_war ?= yes + } + faith = { save_scope_as = promised_holy_war_faith } + custom_tooltip = { + text = bonus_holy_war_tt + add_character_flag = { + flag = bonus_major_holy_war + years = 5 + } + } + custom_tooltip = request_unformed_title_holy_war_deadline_tt + #The clergy come looking for results; pam_interactions_events.0098 judges the vow + trigger_event = { + id = pam_interactions_events.0098 + years = 5 + } + } +} + +# Runs in the scope of the ruler being judged; the cleric weighing the act must be saved as scope:cleric by the caller. +ecclesiastical_title_bestowing_clerical_hesitation_effect = { + save_scope_as = only_consideration + if = { + limit = { + clerical_hesitation_claim_interaction_value >= 9 + } + scope:cleric = { + if = { + limit = { + exists = scope:target + } + change_spiritual_fulfillment = { + value = major_spiritual_fulfillment_loss + multiply = { + value = scope:target.tier + subtract = 2 + } + } + } + else = { + change_spiritual_fulfillment = massive_spiritual_fulfillment_loss + } + custom_tooltip = clerical_hesitation_high_bestowing_tt + } + } + else_if = { + limit = { + clerical_hesitation_claim_interaction_value >= 6 + } + scope:cleric = { + if = { + limit = { + exists = scope:target + } + change_spiritual_fulfillment = { + value = medium_spiritual_fulfillment_loss + multiply = { + value = scope:target.tier + subtract = 2 + } + } + } + else = { + change_spiritual_fulfillment = major_spiritual_fulfillment_loss + } + custom_tooltip = clerical_hesitation_high_bestowing_tt + } + } + else_if = { + limit = { + clerical_hesitation_claim_interaction_value >= 3 + } + scope:cleric = { + if = { + limit = { + exists = scope:target + } + change_spiritual_fulfillment = { + value = minor_spiritual_fulfillment_loss + multiply = { + value = scope:target.tier + subtract = 2 + } + } + } + else = { + change_spiritual_fulfillment = medium_spiritual_fulfillment_loss + } + custom_tooltip = clerical_hesitation_high_bestowing_tt + } + } + else_if = { + limit = { + clerical_hesitation_claim_interaction_value >= 1 + } + scope:cleric = { + if = { + limit = { + exists = scope:target + } + change_spiritual_fulfillment = { + value = miniscule_spiritual_fulfillment_loss + multiply = { + value = scope:target.tier + subtract = 2 + } + } + } + else = { + change_spiritual_fulfillment = minor_spiritual_fulfillment_loss + } + custom_tooltip = clerical_hesitation_high_bestowing_tt + } + } + else_if = { + limit = { + clerical_hesitation_claim_interaction_value < 1 + clerical_hesitation_claim_interaction_value >= -2 + } + } + else_if = { + limit = { + clerical_hesitation_claim_interaction_value >= -3 + } + scope:cleric = { + if = { + limit = { + exists = scope:target + } + change_spiritual_fulfillment = { + value = miniscule_spiritual_fulfillment_value + divide = 2 + multiply = { + value = scope:target.tier + subtract = 2 + } + } + } + else = { + change_spiritual_fulfillment = miniscule_spiritual_fulfillment_value + } + custom_tooltip = clerical_hesitation_low_bestowing_tt + } + } + else_if = { + limit = { + clerical_hesitation_claim_interaction_value >= -5 + } + scope:cleric = { + if = { + limit = { + exists = scope:target + } + change_spiritual_fulfillment = { + value = miniscule_spiritual_fulfillment_value + multiply = { + value = scope:target.tier + subtract = 2 + } + } + } + else = { + change_spiritual_fulfillment = minor_spiritual_fulfillment_value + } + custom_tooltip = clerical_hesitation_low_bestowing_tt + } + } + else_if = { + limit = { + clerical_hesitation_claim_interaction_value >= -8 + } + scope:cleric = { + if = { + limit = { + exists = scope:target + } + change_spiritual_fulfillment = { + value = minor_spiritual_fulfillment_value + multiply = { + value = scope:target.tier + subtract = 2 + } + } + } + else = { + change_spiritual_fulfillment = medium_spiritual_fulfillment_value + } + custom_tooltip = clerical_hesitation_low_bestowing_tt + } + } + else = { + scope:cleric = { + if = { + limit = { + exists = scope:target + } + change_spiritual_fulfillment = { + value = medium_spiritual_fulfillment_value + multiply = { + value = scope:target.tier + subtract = 2 + } + } + } + else = { + change_spiritual_fulfillment = major_spiritual_fulfillment_value + } + custom_tooltip = clerical_hesitation_low_bestowing_tt + } + } +} + +# Never pair with a firing stress_and_fulfillment_impact on the same option +# Punishing/executing a proven witch +pam_witch_justice_fulfillment_effect = { + if = { + limit = { rite = { rite_has_parameter = witchcraft_illegal } } + change_spiritual_fulfillment = medium_spiritual_fulfillment_value + } + else_if = { + limit = { rite = { rite_has_parameter = witchcraft_accepted } } + change_spiritual_fulfillment = major_spiritual_fulfillment_loss + } + # witchcraft_shunned: no SF either way +} + +# Knowingly sparing/releasing a proven witch. +pam_witch_leniency_fulfillment_effect = { + if = { + limit = { rite = { rite_has_parameter = witchcraft_illegal } } + change_spiritual_fulfillment = medium_spiritual_fulfillment_loss + } + else_if = { + limit = { rite = { rite_has_parameter = witchcraft_accepted } } + change_spiritual_fulfillment = minor_spiritual_fulfillment_value + } +} + +# Recruiting/protecting/allying with a witch. +pam_witch_embrace_fulfillment_effect = { + if = { + limit = { rite = { rite_has_parameter = witchcraft_illegal } } + change_spiritual_fulfillment = major_spiritual_fulfillment_loss + } + else_if = { + limit = { rite = { rite_has_doctrine = doctrine_witchcraft_virtuous } } + change_spiritual_fulfillment = medium_spiritual_fulfillment_value + } + else_if = { + limit = { rite = { rite_has_parameter = witchcraft_accepted } } + change_spiritual_fulfillment = minor_spiritual_fulfillment_value + } +} + +add_clerical_region_with_non_christian_capital_effect = { + $REGION_TITLE$ ?= { + if = { + limit = { + holder.religion ?= religion:christianity_religion + NOT = { title_province.religion ?= religion:christianity_religion } + } + scope:core_region = { add_clerical_realm_to_sub_region = prev } + } + } +} + +ecclesiastical_de_jure_shifting_effect = { + custom_tooltip = gain_de_jure_target_title_tt + if = { + limit = { + scope:promise_domination ?= yes + } + if = { + limit = { + has_legitimacy = yes + } + custom_tooltip = domination_promise_tt + } + else = { + custom_tooltip = domination_promise_no_legitimacy_tt + } + trigger_event = { + id = pam_interactions_events.0093 + years = 5 + } + } + if = { + limit = { + scope:donate_faith ?= yes + } + pay_short_term_gold = { + target = $CLERIC$ + gold = major_gold_value + } + } + if = { + limit = { + scope:use_hook ?= yes + has_usable_hook = $CLERIC$ + } + use_hook = $CLERIC$ + } + pam_offer_pilgrimage_effect = { + ACTOR = $DE_JURE_MASTER$ + CLERIC = $CLERIC$ + } + if = { + limit = { + scope:promise_conversion ?= yes + } + remove_treasury_or_gold = { + value = { + value = $DE_JURE_MASTER$.miniscule_gold_value + if = { + limit = { + exists = scope:target + } + scope:target = { + every_de_jure_county = { + limit = { + OR = { + NOT = { + faith = $DE_JURE_MASTER$.faith + } + trigger_if = { + limit = { + $DE_JURE_MASTER$.rite = $CLERIC$.rite + } + AND = { + NOT = { + rite = $DE_JURE_MASTER$.rite + } + rite = { + "divergence(scope:de_jure_master.rite)" >= medium_rite_divergence_value + } + } + } + } + } + add = $DE_JURE_MASTER$.miniscule_gold_value + } + } + } + divide = 2 + } + } + add_piety_experience = { + value = { + value = $DE_JURE_MASTER$.miniscule_piety_gain + if = { + limit = { + exists = scope:target + } + scope:target = { + every_de_jure_county = { + limit = { + OR = { + NOT = { + faith = $DE_JURE_MASTER$.faith + } + trigger_if = { + limit = { + $DE_JURE_MASTER$.rite = $CLERIC$.rite + } + AND = { + NOT = { + rite = $DE_JURE_MASTER$.rite + } + rite = { + "divergence(scope:de_jure_master.rite)" >= medium_rite_divergence_value + } + } + } + } + } + add = $DE_JURE_MASTER$.miniscule_piety_gain + } + } + } + divide = 2 + } + } + scope:target = { + if = { + limit = { + $DE_JURE_MASTER$.rite = $CLERIC$.rite + scope:target ?= { + any_de_jure_county = { + faith = $DE_JURE_MASTER$.faith + NOR = { + rite = $DE_JURE_MASTER$.rite + holder = { + is_ai = no + NOR = { + this = $DE_JURE_MASTER$ + this = $CLERIC$ + } + } + } + rite = { + "divergence(scope:de_jure_master.rite)" >= medium_rite_divergence_value + # Freshly founded rites get a grace period before missionaries convert their counties back + NOT = { has_variable = pam_rite_grace_period } + } + } + } + } + every_de_jure_county = { + custom = custom.every_non_recipient_rite_county_in_target + limit = { + faith = $DE_JURE_MASTER$.faith + NOR = { + rite = $DE_JURE_MASTER$.rite + holder = { + is_ai = no + NOR = { + this = $DE_JURE_MASTER$ + this = $CLERIC$ + } + } + } + rite = { + "divergence(scope:de_jure_master.rite)" >= medium_rite_divergence_value + # Freshly founded rites get a grace period before missionaries convert their counties back + NOT = { has_variable = pam_rite_grace_period } + } + } + custom_tooltip = dispatch_missionaries_random_chance_of_counties_converting_rite_tt + hidden_effect = { + random = { + chance = 20 + set_county_rite = $DE_JURE_MASTER$.rite + } + } + } + } + if = { + limit = { + scope:target ?= { + any_de_jure_county = { + NOR = { + faith = $DE_JURE_MASTER$.faith + holder = { + is_ai = no + NOR = { + this = $DE_JURE_MASTER$ + this = $CLERIC$ + } + } + } + } + } + } + every_de_jure_county = { + custom = custom.every_non_actor_faith_county_in_target + limit = { + NOR = { + faith = $DE_JURE_MASTER$.faith + holder = { + is_ai = no + NOR = { + this = $DE_JURE_MASTER$ + this = $CLERIC$ + } + } + } + } + custom_tooltip = dispatch_missionaries_random_chance_of_counties_converting_faith_tt + hidden_effect = { + random = { + chance = 10 + set_county_faith = $DE_JURE_MASTER$.faith + } + } + } + } + } + } + if = { + limit = { + scope:offer_hook ?= yes + } + $CLERIC$ = { + add_hook = { + type = favor_hook + target = $DE_JURE_MASTER$ + } + } + } + + scope:target = { + hidden_effect = { set_de_jure_liege_title = $DE_JURE_MASTER$.primary_title } + if = { + limit = { + scope:recipient = $CLERIC$ + } + every_de_jure_county = { + custom = custom.every_non_actor_faith_county_controlled_in_target + limit = { + NOT = { faith = $DE_JURE_MASTER$.faith } + holder = { + target_is_same_character_or_above = $DE_JURE_MASTER$ + } + } + change_county_control = extreme_county_control_loss + } + } + else = { + every_de_jure_county = { + custom = custom.every_non_recipient_faith_county_controlled_in_target + limit = { + NOT = { faith = $DE_JURE_MASTER$.faith } + holder = { + target_is_same_character_or_above = $DE_JURE_MASTER$ + } + } + change_county_control = extreme_county_control_loss + } + } + if = { + limit = { + scope:recipient = $CLERIC$ + } + every_de_jure_county = { + custom = custom.every_non_recipient_rite_county_controlled_in_target + limit = { + faith = $DE_JURE_MASTER$.faith + NOT = { + rite = $CLERIC$.rite + } + holder = { + target_is_same_character_or_above = $DE_JURE_MASTER$ + } + } + change_county_control = medium_county_control_loss + } + } + else = { + every_de_jure_county = { + custom = custom.every_non_actor_rite_county_controlled_in_target + limit = { + faith = $DE_JURE_MASTER$.faith + NOT = { + rite = $CLERIC$.rite + } + holder = { + target_is_same_character_or_above = $DE_JURE_MASTER$ + } + } + change_county_control = medium_county_control_loss + } + } + } + scope:puppet_or_actor ?= { + if = { + limit = { + has_legitimacy = yes + exists = scope:target + } + add_legitimacy = { + value = medium_legitimacy_loss + multiply = { + value = scope:target.tier + subtract = 2 + } + } + } + } +} + +pam_cardinal_vacancy_on_death_effect = { + if = { + limit = { + has_pam_dlc_trigger = yes + OR = { + exists = clerical_elector_title + has_character_flag = cardinal_flag + } + OR = { + exists = faith.religious_head + exists = title:k_papal_state.holder + } + faith = { + has_doctrine_parameter = has_clerical_electors + any_clerical_elector_title = { count < 10 } + } + } + if = { + limit = { exists = faith.religious_head } + faith.religious_head = { save_scope_as = head_of_faith } + } + else = { + title:k_papal_state.holder = { save_scope_as = head_of_faith } + } + if = { + limit = { + scope:head_of_faith = { is_ai = yes } + } + faith = { + ordered_clerical_region_title = { + limit = { + holder ?= { + is_alive = yes + is_adult = yes + is_incapable = no + NOT = { has_trait = excommunicated } + NOT = { exists = clerical_elector_title } + this != scope:head_of_faith + pam_can_hold_cardinalate_trigger = yes + pam_pope_is_head_of_faith_or_rite_trigger = yes + } + } + order_by = holder.piety_level + max = 1 + check_range_bounds = no + holder = { + save_scope_as = cardinal_candidate + trigger_event = { + id = pam_clergy_events.0040 + days = 3 + } + } + } + } + } + else = { + faith = { + ordered_clerical_region_title = { + limit = { + holder ?= { + is_ai = yes + is_alive = yes + is_adult = yes + is_incapable = no + NOT = { has_trait = excommunicated } + NOT = { exists = clerical_elector_title } + this != scope:head_of_faith + pam_can_hold_cardinalate_trigger = yes + pam_pope_is_head_of_faith_or_rite_trigger = yes + } + } + order_by = holder.piety_level + max = 1 + check_range_bounds = no + holder = { + save_scope_as = cardinal_candidate + } + } + } + if = { + limit = { + exists = scope:cardinal_candidate + } + scope:head_of_faith = { + trigger_event = { + id = pam_clergy_events.0041 + days = 3 + } + } + } + } + } +} +demand_church_succession_side_effects = { + primary_title = { + every_title_heir = { + limit = { + NOR = { + this = scope:actor + this = scope:puppet_or_actor + } + prev = { + place_in_line_of_succession = { + target = prev + value <= 3 + } + } + } + add_opinion = { + target = scope:puppet_or_actor + modifier = meddling_church_opinion + } + } + } +} +# A Realm Priest Puppet who has grown into a titled cleric belongs in the Clerical Ruler Puppet slot, +# which also frees the Realm Priest slot for whoever takes over the council seat. +# ROOT = the puppet, $PUPPETEER$ = the ruler holding them. +# No-op if the target slot is taken, or if they still hold the court chaplain seat. +pam_make_clerical_ruler_puppet_effect = { + # Both scopes are saved up front because clear_puppet_status severs the puppeteer link + save_temporary_scope_as = pam_clerical_ruler_puppet + $PUPPETEER$ = { save_temporary_scope_as = pam_clerical_puppeteer } + if = { + limit = { + scope:pam_clerical_puppeteer = { + NOR = { + exists = puppet:external_theological_agent_puppet + cp:councillor_court_chaplain ?= scope:pam_clerical_ruler_puppet + } + } + } + # Silent: the slot they move into is what the player is told about, not the one they leave + hidden_effect = { clear_puppet_status = yes } + scope:pam_clerical_puppeteer = { + send_interface_toast = { + type = event_toast_effect_good + title = make_external_clerical_puppet_on_action_notification + left_icon = scope:pam_clerical_puppeteer + right_icon = scope:pam_clerical_ruler_puppet + set_puppet = { + target = scope:pam_clerical_ruler_puppet + type = external_theological_agent_puppet + } + } + } + } +} + +pam_generic_set_puppet_interaction_side_effects = { + if = { + limit = { scope:hook ?= yes } + use_hook = scope:recipient + } + if = { + limit = { + scope:skill_support ?= yes + } + scope:recipient = { + if = { + limit = { + scope:actor = { + highest_skill = diplomacy + } + } + add_character_modifier = { + modifier = skilled_puppeteer_modifier_diplomacy + desc = skilled_puppeteer_behavior_tt + } + } + else_if = { + limit = { + scope:actor = { + highest_skill = martial + } + } + add_character_modifier = { + modifier = skilled_puppeteer_modifier_martial + desc = skilled_puppeteer_behavior_tt + } + } + else_if = { + limit = { + scope:actor = { + highest_skill = stewardship + } + } + add_character_modifier = { + modifier = skilled_puppeteer_modifier_stewardship + desc = skilled_puppeteer_behavior_tt + } + } + else_if = { + limit = { + scope:actor = { + highest_skill = intrigue + } + } + add_character_modifier = { + modifier = skilled_puppeteer_modifier_intrigue + desc = skilled_puppeteer_behavior_tt + } + } + else_if = { + limit = { + scope:actor = { + highest_skill = learning + } + } + add_character_modifier = { + modifier = skilled_puppeteer_modifier_learning + desc = skilled_puppeteer_behavior_tt + } + } + else = { + add_character_modifier = { + modifier = skilled_puppeteer_modifier_general + desc = skilled_puppeteer_behavior_tt + } + } + custom_tooltip = skilled_puppeteer_behavior_tt + } + } + if = { + limit = { + scope:piety_support ?= yes + } + scope:recipient = { + if = { + limit = { is_playable_character = yes } # Only playable characters have spiritual fulfillment + change_spiritual_fulfillment = medium_spiritual_fulfillment_value + } + if = { + limit = { + is_clergy = yes + } + add_character_modifier = { + modifier = spiritual_puppeteer_modifier_cleric + desc = spiritual_puppeteer_behavior_tt + } + } + else = { + add_character_modifier = { + modifier = spiritual_puppeteer_modifier_secular + desc = spiritual_puppeteer_behavior_tt + } + } + custom_tooltip = spiritual_puppeteer_behavior_tt + } + } + if = { + limit = { + scope:dread_support ?= yes + } + scope:recipient = { + if = { + limit = { + OR = { + has_trait = compassionate + has_trait = forgiving + has_trait = generous + has_trait = just + } + } + add_stress = medium_stress_gain + } + add_character_modifier = { + modifier = dreadful_puppeteer_modifier + desc = dreadful_puppeteer_behavior_tt + } + custom_tooltip = dreadful_puppeteer_behavior_tt + } + } + if = { + limit = { + scope:friendly_support ?= yes + } + scope:recipient = { + if = { + limit = { + scope:actor = { + is_ai = no + } + OR = { + has_trait = trusting + has_trait = compassionate + has_trait = generous + has_trait = forgiving + has_trait = just + has_trait = humble + } + } + add_trait = loyal + } + else = { + random = { + chance = { + value = 25 + if = { + limit = { + OR = { + has_trait = trusting + has_trait = compassionate + has_trait = generous + has_trait = forgiving + has_trait = just + has_trait = humble + } + } + add = 25 + } + if = { + limit = { + scope:actor = { + is_ai = no + } + } + add = 25 + } + } + add_trait = loyal + } + } + add_character_modifier = { + modifier = beloved_puppeteer_modifier + desc = beloved_puppeteer_behavior_tt + } + custom_tooltip = beloved_puppeteer_behavior_tt + } + stress_impact = { + sadistic = medium_stress_impact_gain + arbitrary = medium_stress_impact_gain + } + } + if = { + limit = { + scope:lunacy_support ?= yes + } + scope:recipient = { + if = { + limit = { + is_adult = yes + } + add_stress = massive_stress_gain + change_spiritual_fulfillment = massive_spiritual_fulfillment_loss + } + else = { + add_stress = major_stress_gain + change_spiritual_fulfillment = major_spiritual_fulfillment_loss + } + add_character_modifier = { + modifier = deranging_puppeteer_modifier + desc = deranging_puppeteer_behavior_tt + } + custom_tooltip = deranging_puppeteer_behavior_tt + } + } + if = { + limit = { + OR = { + scope:lunacy_support ?= yes + scope:dread_support ?= yes + } + } + stress_impact = { + compassionate = major_stress_impact_gain + just = major_stress_impact_gain + humble = major_stress_impact_gain + } + } + if = { + limit = { + scope:friendly_support ?= yes + } + stress_impact = { + compassionate = minor_stress_impact_gain + trusting = minor_stress_impact_gain + humble = minor_stress_impact_gain + generous = minor_stress_impact_gain + forgiving = minor_stress_impact_gain + honest = minor_stress_impact_gain + just = minor_stress_impact_gain + } + } + if = { + limit = { + OR = { + scope:skill_support ?= yes + scope:piety_support ?= yes + scope:dread_support ?= yes + scope:friendly_support ?= yes + scope:lunacy_support ?= yes + } + } + scope:recipient = { + custom_tooltip = modifier_removed_when_puppeting_ends_tt + } + } + #Tracking variable that makes it easier to re-puppet former puppets + scope:recipient = { + add_to_variable_list = { + name = puppeteers + target = scope:actor + } + } +} +remove_puppet_modifiers_effect = { + if = { + limit = { + OR = { + has_character_modifier = skilled_puppeteer_modifier_diplomacy + has_character_modifier = skilled_puppeteer_modifier_martial + has_character_modifier = skilled_puppeteer_modifier_stewardship + has_character_modifier = skilled_puppeteer_modifier_intrigue + has_character_modifier = skilled_puppeteer_modifier_learning + has_character_modifier = skilled_puppeteer_modifier_general + has_character_modifier = spiritual_puppeteer_modifier_cleric + has_character_modifier = spiritual_puppeteer_modifier_secular + has_character_modifier = dreadful_puppeteer_modifier + has_character_modifier = beloved_puppeteer_modifier + has_character_modifier = deranging_puppeteer_modifier + } + } + send_interface_toast = { + type = event_toast_effect_neutral + title = puppet_modifier_removal.t + if = { + limit = { + has_character_modifier = skilled_puppeteer_modifier_diplomacy + } + remove_character_modifier = skilled_puppeteer_modifier_diplomacy + } + if = { + limit = { + has_character_modifier = skilled_puppeteer_modifier_martial + } + remove_character_modifier = skilled_puppeteer_modifier_martial + } + if = { + limit = { + has_character_modifier = skilled_puppeteer_modifier_stewardship + } + remove_character_modifier = skilled_puppeteer_modifier_stewardship + } + if = { + limit = { + has_character_modifier = skilled_puppeteer_modifier_intrigue + } + remove_character_modifier = skilled_puppeteer_modifier_intrigue + } + if = { + limit = { + has_character_modifier = skilled_puppeteer_modifier_learning + } + remove_character_modifier = skilled_puppeteer_modifier_learning + } + if = { + limit = { + has_character_modifier = skilled_puppeteer_modifier_general + } + remove_character_modifier = skilled_puppeteer_modifier_general + } + if = { + limit = { + has_character_modifier = spiritual_puppeteer_modifier_cleric + } + remove_character_modifier = spiritual_puppeteer_modifier_cleric + } + if = { + limit = { + has_character_modifier = spiritual_puppeteer_modifier_secular + } + remove_character_modifier = spiritual_puppeteer_modifier_secular + } + if = { + limit = { + has_character_modifier = dreadful_puppeteer_modifier + } + remove_character_modifier = dreadful_puppeteer_modifier + } + if = { + limit = { + has_character_modifier = beloved_puppeteer_modifier + } + remove_character_modifier = beloved_puppeteer_modifier + } + if = { + limit = { + has_character_modifier = deranging_puppeteer_modifier + } + remove_character_modifier = deranging_puppeteer_modifier + } + } + } +} +gnostic_tenet_learning_effect = { + if = { + limit = { + has_personal_tenet_flag = gnosticism_other_tenets + NAND = { + knows_tenet = tenet_astrology + knows_tenet = tenet_inner_journey + knows_tenet = tenet_esotericism + knows_tenet = tenet_miaphysitism + knows_tenet = tenet_asceticism + knows_tenet = tenet_vows_of_poverty + knows_tenet = tenet_pacifism + knows_tenet = tenet_mortification_of_the_flesh + knows_tenet = tenet_aniconism + knows_tenet = tenet_natural_primitivism + knows_tenet = tenet_false_conversion_sanction + knows_tenet = tenet_consolamentum + knows_tenet = tenet_scholasticism + knows_tenet = tenet_pursuit_of_knowledge + knows_tenet = tenet_alexandrian_catechism + knows_tenet = tenet_mendicant_preachers + knows_tenet = tenet_reincarnation + } + } + random = { + chance = { + value = 10 + if = { + limit = { + has_trait_xp = { + trait = lifestyle_scholar + value >= 60 + } + } + add = 10 + } + if = { + limit = { + has_trait_xp = { + trait = lifestyle_scholar + value >= 80 + } + } + add = 15 + } + if = { + limit = { + has_trait_xp = { + trait = lifestyle_scholar + value >= 100 + } + } + add = 15 + } + } + random_list = { + 1 = { + trigger = { + NOT = { + knows_tenet = tenet_astrology + } + } + tenet:tenet_astrology = { save_scope_as = gnostic_tenet } + } + 1 = { + trigger = { + NOT = { + knows_tenet = tenet_inner_journey + } + } + tenet:tenet_inner_journey = { save_scope_as = gnostic_tenet } + } + 1 = { + trigger = { + NOT = { + knows_tenet = tenet_esotericism + } + } + tenet:tenet_esotericism = { save_scope_as = gnostic_tenet } + } + 1 = { + trigger = { + NOT = { + knows_tenet = tenet_miaphysitism + } + } + tenet:tenet_miaphysitism = { save_scope_as = gnostic_tenet } + } + 1 = { + trigger = { + NOT = { + knows_tenet = tenet_asceticism + } + } + tenet:tenet_asceticism = { save_scope_as = gnostic_tenet } + } + 1 = { + trigger = { + NOT = { + knows_tenet = tenet_vows_of_poverty + } + } + tenet:tenet_vows_of_poverty = { save_scope_as = gnostic_tenet } + } + 1 = { + trigger = { + NOT = { + knows_tenet = tenet_pacifism + } + } + tenet:tenet_pacifism = { save_scope_as = gnostic_tenet } + } + 1 = { + trigger = { + NOT = { + knows_tenet = tenet_mortification_of_the_flesh + } + } + tenet:tenet_mortification_of_the_flesh = { save_scope_as = gnostic_tenet } + } + 1 = { + trigger = { + NOT = { + knows_tenet = tenet_aniconism + } + } + tenet:tenet_aniconism = { save_scope_as = gnostic_tenet } + } + 1 = { + trigger = { + NOT = { + knows_tenet = tenet_natural_primitivism + } + } + tenet:tenet_natural_primitivism = { save_scope_as = gnostic_tenet } + } + 1 = { + trigger = { + NOT = { + knows_tenet = tenet_false_conversion_sanction + } + } + tenet:tenet_false_conversion_sanction = { save_scope_as = gnostic_tenet } + } + 1 = { + trigger = { + NOT = { + knows_tenet = tenet_consolamentum + } + } + tenet:tenet_consolamentum = { save_scope_as = gnostic_tenet } + } + 1 = { + trigger = { + NOT = { + knows_tenet = tenet_scholasticism + } + } + tenet:tenet_scholasticism = { save_scope_as = gnostic_tenet } + } + 1 = { + trigger = { + NOT = { + knows_tenet = tenet_pursuit_of_knowledge + } + } + tenet:tenet_pursuit_of_knowledge = { save_scope_as = gnostic_tenet } + } + 1 = { + trigger = { + NOT = { + knows_tenet = tenet_alexandrian_catechism + } + } + tenet:tenet_alexandrian_catechism = { save_scope_as = gnostic_tenet } + } + 1 = { + trigger = { + NOT = { + knows_tenet = tenet_mendicant_preachers + } + } + tenet:tenet_mendicant_preachers = { save_scope_as = gnostic_tenet } + } + 1 = { + trigger = { + NOT = { + knows_tenet = tenet_reincarnation + } + } + tenet:tenet_reincarnation = { save_scope_as = gnostic_tenet } + } + } + send_interface_message = { + type = msg_passive_learned_tenet_special + desc = gnostic_tenet_learning.t + left_icon = root + right_icon = scope:gnostic_tenet + + hidden_effect = { add_known_tenet = scope:gnostic_tenet } + change_spiritual_fulfillment = minor_spiritual_fulfillment_value + } + } + } +} + +# Character scope. Runs from yearly_playable_pulse +# The modifier stacks, so remove-all first +pam_harmonious_society_five_bonds_effect = { + remove_all_character_modifier_instances = tenet_harmonious_society_five_bonds_modifier + + set_local_variable = { + name = five_bonds_tally + value = pam_five_bonds_tally_value + } + + set_local_variable = { + name = five_bonds_change + value = local_var:five_bonds_tally + } + if = { + limit = { has_variable = pam_five_bonds_tally_var } + change_local_variable = { + name = five_bonds_change + subtract = var:pam_five_bonds_tally_var + } + } + + # The pulse runs every year; only say something when the tally has actually moved. + if = { + limit = { local_var:five_bonds_change > 0 } + send_interface_toast = { + type = event_toast_effect_good + title = pam_harmonious_society_five_bonds_toast + desc = pam_harmonious_society_five_bonds_toast_desc + left_icon = root + pam_harmonious_society_apply_five_bonds_effect = yes + } + } + else_if = { + limit = { local_var:five_bonds_change < 0 } + send_interface_toast = { + type = event_toast_effect_bad + title = pam_harmonious_society_five_bonds_toast + desc = pam_harmonious_society_five_bonds_toast_desc + left_icon = root + pam_harmonious_society_apply_five_bonds_effect = yes + } + } + else = { + hidden_effect = { + pam_harmonious_society_apply_five_bonds_effect = yes + } + } + + set_variable = { + name = pam_five_bonds_tally_var + value = local_var:five_bonds_tally + } +} + +# Character scope. One stack for each bond kept, named individually so the toast reads as a tally. +pam_harmonious_society_apply_five_bonds_effect = { + if = { + limit = { pam_five_bonds_ruler_subject_trigger = yes } + custom_tooltip = pam_five_bonds_ruler_subject_tt + add_character_modifier = tenet_harmonious_society_five_bonds_modifier + } + if = { + limit = { pam_five_bonds_parent_child_trigger = yes } + custom_tooltip = pam_five_bonds_parent_child_tt + add_character_modifier = tenet_harmonious_society_five_bonds_modifier + } + if = { + limit = { pam_five_bonds_spouse_trigger = yes } + custom_tooltip = pam_five_bonds_spouse_tt + add_character_modifier = tenet_harmonious_society_five_bonds_modifier + } + if = { + limit = { pam_five_bonds_sibling_trigger = yes } + custom_tooltip = pam_five_bonds_sibling_tt + add_character_modifier = tenet_harmonious_society_five_bonds_modifier + } + if = { + limit = { pam_five_bonds_friend_trigger = yes } + custom_tooltip = pam_five_bonds_friend_tt + add_character_modifier = tenet_harmonious_society_five_bonds_modifier + } +} + +# One stack of $MODIFIER$ per trait the rite counts as a sin +pam_add_modifier_per_sin_trait_effect = { + remove_all_character_modifier_instances = $MODIFIER$ + + every_character_trait = { + limit = { + root.rite = { trait_is_sin_rite = prev } + } + root = { + add_character_modifier = $MODIFIER$ + } + } +} + +pam_tenet_purgatory_sin_penalty_effect = { + pam_add_modifier_per_sin_trait_effect = { MODIFIER = tenet_purgatory_sin_penalty_modifier } +} + +pam_tenet_original_sin_insight_effect = { + pam_add_modifier_per_sin_trait_effect = { MODIFIER = tenet_original_sin_sinners_insight_modifier } +} + +# New lover or soulmate; one payout a year +pam_tenet_polyamory_new_beloved_effect = { + if = { + limit = { + has_personal_tenet_flag = tenet_polyamory_new_beloved + NOT = { has_character_flag = pam_polyamory_new_beloved_cooldown } + } + send_interface_toast = { + type = event_toast_effect_good + title = tenet_polyamory_new_beloved_toast + left_icon = root + change_spiritual_fulfillment = minor_spiritual_fulfillment_value + add_stress = medium_stress_loss + add_character_modifier = { + modifier = tenet_polyamory_new_beloved_modifier + years = 5 + } + } + add_character_flag = { + flag = pam_polyamory_new_beloved_cooldown + days = 365 + } + } +} + +pam_tenet_apostolic_succession_episcopate_effect = { + remove_character_modifier = tenet_apostolic_succession_episcopate_modifier + + if = { + limit = { + is_valid_for_legitimacy_change = yes + pam_apostolic_succession_bishop_count_value > 0 + } + add_character_modifier = tenet_apostolic_succession_episcopate_modifier + } +} + +pam_tenet_divine_liturgy_choirs_effect = { + remove_character_modifier = tenet_divine_liturgy_choirs_modifier + + if = { + limit = { + pam_divine_liturgy_temple_count_value > 0 + } + add_character_modifier = tenet_divine_liturgy_choirs_modifier + } +} + +pam_tenet_divine_liturgy_officiant_effect = { + remove_character_modifier = tenet_divine_liturgy_officiant_modifier + + if = { + limit = { + pam_divine_liturgy_chaplain_learning_value > 0 + } + add_character_modifier = tenet_divine_liturgy_officiant_modifier + } + + # Timed past yearly retally so a lapsed chaplain ages out + if = { + limit = { + has_personal_tenet_flag = tenet_divine_liturgy_schola_cantorum + cp:councillor_court_chaplain ?= { faith = root.faith } + } + cp:councillor_court_chaplain = { + add_character_modifier = { + modifier = tenet_divine_liturgy_schola_cantorum_modifier + months = 13 + } + } + } +} + +############################################### +# Holy Myron + +# OWNER - character receiving the ampulla (artifact is created in their scope) +# CREATOR - the cleric who gathered the balsams and consecrated the oil +# RARITY - common | masterwork | famed | illustrious +pam_create_holy_myron_artifact_effect = { + get_artifact_quality_effect = yes + get_artifact_wealth_effect = yes + + $OWNER$ = { + create_artifact = { + name = pam_holy_myron_artifact_name + description = pam_holy_myron_artifact_desc_$RARITY$ + creator = $CREATOR$ + visuals = flask + type = miscellaneous + template = pam_holy_myron_template + rarity = $RARITY$ + modifier = artifact_placeholder_modifier + decaying = no + save_scope_as = newly_created_artifact + wealth = scope:wealth + quality = scope:quality + } + } + scope:newly_created_artifact = { + save_scope_as = pam_myron_vessel + if = { + limit = { rarity = common } + set_variable = { + name = pam_holy_myron_charges + value = 1 + } + add_artifact_modifier = pam_holy_myron_vessel_modifier + } + else_if = { + limit = { rarity = masterwork } + set_variable = { + name = pam_holy_myron_charges + value = 2 + } + add_artifact_modifier = pam_holy_myron_vessel_modifier + } + else_if = { + limit = { rarity = famed } + set_variable = { + name = pam_holy_myron_charges + value = 3 + } + add_artifact_modifier = pam_holy_myron_vessel_potent_modifier + } + else = { + set_variable = { + name = pam_holy_myron_charges + value = 4 + } + add_artifact_modifier = pam_holy_myron_vessel_potent_modifier + } + # We set the description again once the charge variable exists, reading it through scope:pam_myron_vessel + set_artifact_description = pam_holy_myron_artifact_desc_charged_$RARITY$ + remove_artifact_modifier = artifact_placeholder_modifier + } +} + +# Character scope: saves the owned ampulla as scope:pam_holy_myron_artifact. +pam_save_holy_myron_artifact_effect = { + random_character_artifact = { + limit = { pam_is_holy_myron_artifact_trigger = yes } + save_scope_as = pam_holy_myron_artifact + } +} + +# $ARTIFACT$ = the ampulla +# trigger_event with no delay runs after this script, so destroy (0002) never leaves a live empty vessel +pam_holy_myron_consume_charge_effect = { + if = { + limit = { exists = $ARTIFACT$ } + $ARTIFACT$ = { + change_variable = { + name = pam_holy_myron_charges + subtract = 1 + } + } + if = { + limit = { + $ARTIFACT$ = { var:pam_holy_myron_charges <= 0 } + } + $ARTIFACT$ = { save_scope_as = pam_holy_myron_spent_vessel } + $ARTIFACT$.artifact_owner ?= { + trigger_event = pam_holy_myron.0002 + } + } + else = { + $ARTIFACT$ = { + save_scope_as = pam_myron_vessel + if = { + limit = { rarity = masterwork } + set_artifact_description = pam_holy_myron_artifact_desc_charged_masterwork + } + else_if = { + limit = { rarity = famed } + set_artifact_description = pam_holy_myron_artifact_desc_charged_famed + } + else_if = { + limit = { rarity = illustrious } + set_artifact_description = pam_holy_myron_artifact_desc_charged_illustrious + } + else = { + set_artifact_description = pam_holy_myron_artifact_desc_charged_common + } + } + } + } +} + +# Character scope on the owner, run alongside pam_holy_myron_consume_charge_effect at every spend site +pam_holy_myron_spend_warning_effect = { + if = { + limit = { + any_character_artifact = { + pam_is_holy_myron_artifact_trigger = yes + trigger_if = { + limit = { has_variable = pam_holy_myron_charges } + var:pam_holy_myron_charges <= 1 + } + trigger_else = { + always = no + } + } + } + custom_tooltip = pam_holy_myron_spend_last_tt + } + else = { + custom_tooltip = pam_holy_myron_spend_tt + } +} + +# $PARENT$ is the devoted parent, and the child is sealed once by whichever parent we reach first +pam_holy_myron_chrismation_effect = { + if = { + limit = { + scope:child = { + is_alive = yes + NOT = { has_variable = pam_holy_myron_chrismated } + } + } + # Twins are one ceremony, and later paths cover the sibling through scope:pam_myron_twin + scope:child = { + set_variable = pam_holy_myron_chrismated + if = { + limit = { has_trait = twin } + random_sibling = { + limit = { + is_twin_of = scope:child + is_alive = yes + NOT = { has_variable = pam_holy_myron_chrismated } + } + save_scope_as = pam_myron_twin + } + } + } + scope:pam_myron_twin ?= { + set_variable = pam_holy_myron_chrismated + } + if = { + limit = { + $PARENT$ = { + pam_has_usable_holy_myron_trigger = yes + is_available = yes + exists = cp:councillor_court_chaplain + } + } + $PARENT$ = { + trigger_event = { + id = pam_holy_myron.0300 + days = 3 + } + } + } + else = { + $PARENT$ = { + send_interface_toast = { + type = event_generic_good + title = pam_holy_myron_chrismation_toast + left_icon = scope:child + right_icon = $PARENT$ + scope:child = { + if = { + limit = { + NOR = { + has_character_modifier = pam_chrismated_child_modifier + has_character_modifier = pam_myron_chrismated_child_modifier + } + } + add_character_modifier = { + modifier = pam_chrismated_child_modifier + years = 16 + } + } + } + scope:pam_myron_twin ?= { + if = { + limit = { + is_alive = yes + NOR = { + has_character_modifier = pam_chrismated_child_modifier + has_character_modifier = pam_myron_chrismated_child_modifier + } + } + add_character_modifier = { + modifier = pam_chrismated_child_modifier + years = 16 + } + } + } + } + } + } + } +} + +# Chaplain scope: clears all Holy Myron journey bookkeeping (journey end, death, or abort). +pam_holy_myron_journey_cleanup_effect = { + var:pam_holy_myron_liege ?= { + remove_variable = pam_holy_myron_journey_active + } + remove_variable = pam_holy_myron_journey_tier + remove_variable = pam_holy_myron_legs + remove_variable = pam_holy_myron_expected_legs + remove_variable = pam_holy_myron_robbed + remove_variable = pam_holy_myron_ransom_fired + remove_variable = pam_holy_myron_fever_fired + remove_variable = pam_holy_myron_liege + remove_character_modifier = pam_holy_myron_pilgrim_modifier +} + +# Artifact scope: rarity-scaled Religious Study phase-speed modifier for devotional books +add_scaled_artifact_modifier_study_scripture_scheme_phase_duration_add_effect = { + if = { + limit = { rarity = common } + add_artifact_modifier = artifact_study_scripture_scheme_phase_duration_add_1_modifier + } + else_if = { + limit = { rarity = masterwork } + add_artifact_modifier = artifact_study_scripture_scheme_phase_duration_add_2_modifier + } + else_if = { + limit = { rarity = famed } + add_artifact_modifier = artifact_study_scripture_scheme_phase_duration_add_3_modifier + } + else_if = { + limit = { rarity = illustrious } + add_artifact_modifier = artifact_study_scripture_scheme_phase_duration_add_4_modifier + } +} + +pam_evangelize_personal_tenet_effect = { + scope:recipient = { + pam_replace_personal_tenet_effect = { TENET = scope:pam_evangelize_tenet } + } + if = { + limit = { + scope:hook = yes + has_usable_hook = scope:recipient + } + use_hook = scope:recipient + } + change_spiritual_fulfillment = miniscule_spiritual_fulfillment_value + pam_tenet_popularity_on_evangelized_tenet_effect = { + TENET = scope:pam_evangelize_tenet + CHANGE = scope:recipient.pam_evangelize_tenet_popularity_gain + } + if = { + limit = { + faith.main_rite = { + has_tenet_status = { + tenet = scope:pam_evangelize_tenet + status = prohibited + } + } + } + every_secret = { + type = secret_forbidden_personal_tenet + limit = { NOT = { is_known_by = scope:recipient } } + reveal_to = scope:recipient + } + show_as_tooltip = { + scope:recipient = { + add_secret = { type = secret_forbidden_personal_tenet } + every_secret = { + type = secret_forbidden_personal_tenet + reveal_to = scope:actor + } + } + } + scope:recipient = { + set_variable = { + name = tenet_evangelized_by + value = scope:actor + days = 1 + } + } + } +} + +pam_evangelize_personal_tenet_decline_effect = { + change_spiritual_fulfillment = miniscule_spiritual_fulfillment_loss + if = { + limit = { + faith.main_rite = { + has_tenet_status = { + tenet = scope:pam_evangelize_tenet + status = prohibited + } + } + } + every_secret = { + type = secret_forbidden_personal_tenet + limit = { NOT = { is_known_by = scope:recipient } } + reveal_to = scope:recipient + } + } +} + +pam_reform_order_effect = { + pam_save_selected_interaction_tenet_effect = yes + + scope:actor.rite = { save_scope_as = pam_reform_order_rite } + scope:recipient = { + holy_order = { + save_scope_as = pam_reform_order + title = { save_scope_as = pam_reform_order_title } + if = { + limit = { exists = scope:pam_selected_interaction_tenet } + custom_tooltip = { # Order adopts the tenet + text = pam_reform_order_adopt_tenet_tt + hidden_effect = { + scope:pam_reform_order = { set_order_tenet = scope:pam_selected_interaction_tenet } + } + } + } + if = { # Order adopts rite + limit = { + NOT = { order_rite = scope:pam_reform_order_rite } + } + custom_tooltip = { + text = pam_reform_order_adopt_rite_tt + hidden_effect = { + scope:pam_reform_order = { + set_order_rite = scope:pam_reform_order_rite + } + } + } + } + } + if = { # Adopt the PT + limit = { exists = scope:pam_selected_interaction_tenet } + if = { + limit = { + NOT = { has_personal_tenet = scope:pam_selected_interaction_tenet } + } + pam_replace_personal_tenet_effect = { TENET = scope:pam_selected_interaction_tenet } + } + custom_tooltip = { + text = pam_reform_order_courtiers_adopt_tenet_tt + every_courtier = { + limit = { + OR = { + pam_is_monastic_order_member_trigger = yes + pam_is_military_order_member_trigger = yes + } + NOT = { has_personal_tenet = scope:pam_selected_interaction_tenet } + } + pam_replace_personal_tenet_effect = { TENET = scope:pam_selected_interaction_tenet } + } + } + } + if = { # Adopt the rite + limit = { exists = scope:pam_reform_order_rite } + if = { + limit = { + NOT = { rite = scope:pam_reform_order_rite } + } + set_character_rite = scope:pam_reform_order_rite + } + custom_tooltip = { + text = pam_reform_order_courtiers_adopt_rite_tt + every_courtier = { + limit = { + OR = { + pam_is_monastic_order_member_trigger = yes + pam_is_military_order_member_trigger = yes + } + NOT = { rite = scope:pam_reform_order_rite } + } + set_character_rite = scope:pam_reform_order_rite + } + } + } + } + + hidden_effect = { + scope:actor = { + send_interface_toast = { + type = event_toast_effect_good + title = pam_reform_order_interaction_toast + right_icon = scope:recipient + custom_tooltip = pam_reform_order_interaction_toast_tt + } + } + } +} + diff --git a/history/characters/NEOW_byzantine_emperors.txt b/history/characters/NEOW_byzantine_emperors.txt index 1696684be..609d91fb4 100644 --- a/history/characters/NEOW_byzantine_emperors.txt +++ b/history/characters/NEOW_byzantine_emperors.txt @@ -34,7 +34,7 @@ CONSECRATION_PROVINCE = province:496 # Constantinople - Church of the Holy Apostles (matches vanilla Constantine) PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -238,7 +238,7 @@ byz_theodosius_i = { CONSECRATION_PROVINCE = province:496 # Constantinople - Church of the Holy Apostles PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -348,7 +348,7 @@ byz_marcian = { CONSECRATION_PROVINCE = province:496 # Constantinople - Church of the Holy Apostles PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -582,7 +582,7 @@ byz_justinian_i = { CONSECRATION_PROVINCE = province:496 # Constantinople - Church of the Holy Apostles PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -2464,7 +2464,7 @@ byz_john_iii = { CONSECRATION_PROVINCE = province:745 # Smyrna - nearest base-game province to Magnesia/Sosandra PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -2817,7 +2817,7 @@ byz_helena_dragas = { # St Helena Dragaš, Empress Helena; monastic name Hypomon CONSECRATION_PROVINCE = province:496 # Constantinople - Pantokrator monastery area PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -2983,28 +2983,8 @@ byz_constantine_xi = { name="Konstant_i_act_nos" } 1453.5.29 = { - death = { death_reason = death_taken_by_god } - - effect_even_if_dead = { - pam_canonize_saint_effect = { - CANONIZER = root - CANDIDATE = root - CONSECRATION_PROVINCE = province:496 # Constantinople - death site; exact grave is unknown - PRESET = yes - } - religion:christianity_religion = { - every_faith = { - limit = { - main_rite = { - is_rite_enabled = yes - NOT = { rite_has_doctrine = special_doctrine_is_western_christian_faith } - } - NOT = { has_saint_character = root } - } - add_saint = { character = root } - } - } - } + death = { + death_reason = death_taken_by_god } } diff --git a/history/characters/NEOW_e_greece.txt b/history/characters/NEOW_e_greece.txt index 4fc2f2ba4..7e5aea189 100644 --- a/history/characters/NEOW_e_greece.txt +++ b/history/characters/NEOW_e_greece.txt @@ -1190,6 +1190,48 @@ albania0005 = { #Kastriota death = yes } } +cyprus0001_bishop = { + name = "Varn_a_act_vas" + dynasty = kinyraou_dynasty + rite = byzantine_rite + culture = NEOW_cypriot + father = cyprus0020 + dna = dna_cypriot + trait = education_learning_3 + trait = zealous + trait = devoted + trait = brave + trait = humble + trait = stubborn + sexuality = asexual + prowess = 5 + diplomacy = 5 + stewardship = 3 + intrigue = 1 + learning = 10 + martial = 1 + portrait_override={ + portrait_modifier_overrides={ + custom_beards=male_beard_western_06 + custom_hair=m_hair_fp3_iranian_03 + } + } + 2519.1.1 = { + birth = yes + } + 2536.12.1 = { + effect = { set_relation_friend = character:cyprus0020 } + } + 2536.12.1 = { + effect = { set_relation_friend = character:cyprus0001 } + } + 2554.12.1 = { + effect = { set_relation_friend = character:cyprus0003 } + } + 2600.1.1 = { + death = yes + } +} cyprus0001 = { # Kinýras named for a cypriot greek thing name = "Kinýras" @@ -1442,7 +1484,7 @@ cyprus0007 = { # We IZ kangz CONSECRATION_PROVINCE = province:5681 # Nicosia PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -2246,8 +2288,6 @@ protos_constantine = { death = { death_reason = death_crucified killer = greece0061 - } - effect_even_if_dead = { pam_canonize_saint_effect = { CANONIZER = root @@ -2255,7 +2295,7 @@ protos_constantine = { CONSECRATION_PROVINCE = province:3776 # Ierissos / Mount Athos PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { diff --git a/history/characters/NEOW_e_nistrenia.txt b/history/characters/NEOW_e_nistrenia.txt index 4024b3023..f546d1219 100644 --- a/history/characters/NEOW_e_nistrenia.txt +++ b/history/characters/NEOW_e_nistrenia.txt @@ -1342,7 +1342,7 @@ nistria1000 = { #The Founder of the Empire, Saint and suspiciously of Hungarian CONSECRATION_PROVINCE = province:5018 # Chisinau - Moldavian/Nistrian capital-region shrine PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { diff --git a/history/characters/NEOW_ecumenical_patriarchs.txt b/history/characters/NEOW_ecumenical_patriarchs.txt index cd43dcbdc..0f424290f 100644 --- a/history/characters/NEOW_ecumenical_patriarchs.txt +++ b/history/characters/NEOW_ecumenical_patriarchs.txt @@ -34,7 +34,7 @@ CONSECRATION_PROVINCE = province:476 # Patras - traditional tomb of St Andrew PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -78,7 +78,7 @@ stachys_the_apostle = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -121,7 +121,7 @@ onesimus_of_byzantium = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -600,7 +600,7 @@ castinus_of_byzantium = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -784,7 +784,7 @@ metrophanes_i_of_byzantium = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -832,7 +832,7 @@ alexander_of_constantinople = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -881,7 +881,7 @@ paul_i_of_constantinople = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -1098,7 +1098,7 @@ gregory_of_nazianzus = { CONSECRATION_PROVINCE = province:5631 # Nazianzus PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -1146,7 +1146,7 @@ nectarius_of_constantinople = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -1199,7 +1199,7 @@ john_chrysostom = { CONSECRATION_PROVINCE = province:496 # Constantinople - relics translated to the Church of the Holy Apostles PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -1246,7 +1246,7 @@ arsacius_of_tarsus = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -1293,7 +1293,7 @@ atticus_of_constantinople = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -1340,7 +1340,7 @@ sisinnius_i_of_constantinople = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -1415,7 +1415,7 @@ maximianus_of_constantinople = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -1462,7 +1462,7 @@ proclus_of_constantinople = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -1510,7 +1510,7 @@ flavian_of_constantinople = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -1557,7 +1557,7 @@ anatolius_i_of_constantinople = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -1605,7 +1605,7 @@ gennadius_i_of_constantinople = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -1736,7 +1736,7 @@ macedonius_ii_of_constantinople = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -1813,7 +1813,7 @@ john_ii_of_constantinople = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -1916,7 +1916,7 @@ menas_of_constantinople = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -1964,7 +1964,7 @@ eutychius_of_constantinople = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -2012,7 +2012,7 @@ john_scholasticus = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -2062,7 +2062,7 @@ john_iv_of_constantinople = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -2109,7 +2109,7 @@ cyriacus_ii_of_constantinople = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -2156,7 +2156,7 @@ thomas_i_of_constantinople = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -2368,7 +2368,7 @@ constantine_i_of_constantinople = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -2442,7 +2442,7 @@ george_i_of_constantinople = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -2517,7 +2517,7 @@ callinicus_i_of_constantinople = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -2619,7 +2619,7 @@ germanus_i_of_constantinople = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -2753,7 +2753,7 @@ paul_iv_of_constantinople = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -2800,7 +2800,7 @@ tarasios_of_constantinople = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -2847,7 +2847,7 @@ nikephoros_i_of_constantinople = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -2983,7 +2983,7 @@ methodius_of_constantinople = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -3033,7 +3033,7 @@ ignatios_of_constantinople = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -3085,7 +3085,7 @@ photios_i_of_constantinople = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -3134,7 +3134,7 @@ stephen_i_of_constantinople = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -3182,7 +3182,7 @@ antony_ii_of_constantinople = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -3230,7 +3230,7 @@ nicholas_mystikos = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -3279,7 +3279,7 @@ euthymius_i_of_constantinople = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -3326,7 +3326,7 @@ stephen_ii_of_constantinople = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -3373,7 +3373,7 @@ tryphon_of_constantinople = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -3530,7 +3530,7 @@ nicholas_ii_of_constantinople = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -3632,7 +3632,7 @@ eustathius_of_constantinople = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -3736,7 +3736,7 @@ portrait_override={ CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -3784,7 +3784,7 @@ john_viii_of_constantinople = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -3832,7 +3832,7 @@ cosmas_i_of_constantinople = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -3994,7 +3994,7 @@ michael_ii_of_constantinople = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -4658,7 +4658,7 @@ ecpat_133_arsenius = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -4764,7 +4764,7 @@ ecpat_136_joseph_i = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -4871,7 +4871,7 @@ ecpat_139_athanasius_i = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -5119,7 +5119,7 @@ ecpat_147_callistus_i = { CONSECRATION_PROVINCE = province:3771 # Serres - place of death and burial tradition PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -5283,7 +5283,7 @@ ecpat_152_callistus_ii = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -5512,7 +5512,7 @@ ecpat_159_gennadius_ii = { CONSECRATION_PROVINCE = province:3771 # Serres - Monastery of St John the Baptist PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -5703,7 +5703,7 @@ ecpat_165_dionysius_i = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -5780,7 +5780,7 @@ ecpat_167_maximus_iii = { CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -5829,7 +5829,7 @@ ecpat_168_nephon_ii = { CONSECRATION_PROVINCE = province:3776 # Ierissos / Mount Athos - Dionysiou Monastery PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -5990,7 +5990,7 @@ custom_clothes=male_clothes_religious_orthodox_head_01_common CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -6406,7 +6406,7 @@ custom_clothes=male_clothes_religious_orthodox_head_01_common CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -6767,7 +6767,7 @@ custom_clothes=male_clothes_religious_orthodox_head_01_common CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -7768,7 +7768,7 @@ custom_clothes=male_clothes_religious_orthodox_head_01_common CONSECRATION_PROVINCE = province:482 # Athens - present shrine/relics at the Metropolitan Cathedral PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -7873,7 +7873,7 @@ custom_clothes=male_clothes_religious_orthodox_head_01_common CONSECRATION_PROVINCE = province:494 # Adrianopolis - martyrdom/burial region PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { @@ -8826,7 +8826,7 @@ orthodoxpeps0001 = { #him pre-event man cool dude #my pope CONSECRATION_PROVINCE = province:496 # Constantinople - patriarchal shrine/burial location PRESET = yes } - religion:christianity_religion = { + religion:eastern_orthodox_religion = { every_faith = { limit = { main_rite = { diff --git a/history/titles/ce3/00_ecclesiastical_titles.txt b/history/titles/ce3/00_ecclesiastical_titles.txt new file mode 100644 index 000000000..5c9aaf7c0 --- /dev/null +++ b/history/titles/ce3/00_ecclesiastical_titles.txt @@ -0,0 +1,4477 @@ +# Cardinal Titles + +# 867 +d_cd_ostia = { # Ostia (later also Velletri) + 1058.1.1 = { + government = ecclesiastical_government + holder = ce3_cardinal_peter_damian # Pietro, Cardinal-Bishop of Ostia + effect = { + set_variable = { + name = named_after + value = title:b_ostia + } + } + } + 1059.1.24 = { + effect = { + set_title_name = "d_cd_ostia_velletri" + } + } + 1159.1.1 = { + holder = 71811 # Ubaldo, Cardinal-Bishop of Ostia e Velletri, later Pope Lucius III + } +} + +d_cd_porto = { # Porto (Santa Rufina) + 1061.1.1 = { + holder = ce3_cardinal_mainard_of_silva_candida # Mainard, Bishop cardinalis of Porto (most plausible) + government = ecclesiastical_government + effect = { + set_variable = { + name = named_after + value = title:b_roma + } + } + } + #1099.1.1 = { + # holder = et_jerusalem_1066_17 # Maurizio + #} + + 1102.1.1 = { + effect = { + set_title_name = "d_cd_porto_santa_rufina" + } + } + 1178.1.18 = { + holder = ce3_cardinal_teodino_degli_atti # Teodino, Bishop cardinalis of Porto (most plausible) + } +} + +d_cd_velletri = { # Velletri + 1050.1.1 = { + holder = 7939 # Giovanni Mincius, Cardinal-Bishop of Velletri + government = ecclesiastical_government + effect = { + set_variable = { + name = named_after + value = title:b_velletri + } + } + } + 1059.1.24 = { + holder = 0 # Later date error prevention + effect = { + set_variable = suppressed_cardinalate # combined with Ostia + } + } +} + +d_cd_frascati = { # Frascati + 1065.1.1 = { + holder = ce3_cardinal_giovanni_of_frascati # Giovanni, Cardinal-Bishop of Frascati + government = ecclesiastical_government + effect = { + set_variable = { + name = named_after + value = title:b_roma + } + } + } + 1178.10.1 = { # actually 1178.12.1 + holder = ce3_cardinal_pietro_da_pavia # Pietro, Cardinal-Bishop of Frascati + } +} + +d_cd_albano = { # Albano + 1049.1.1 = { + holder = ce3_cardinal_bonifazio_of_albano # Bonifazio, Cardinal-Bishop of Albano + government = ecclesiastical_government + effect = { + set_variable = { + name = named_after + value = title:b_roma + } + } + } + 1054.7.16 = { + effect = { + add_clerical_elector = faith:catholic + } + } + 1159.2.1 = { + holder = ce3_cardinal_gualtiero_of_albano # Gualtiero, Cardinal-Bishop of Albano + } +} + +d_cd_palestrina = { # Palestrina + 1065.12.5 = { + holder = ce3_cardinal_loperto_of_palestrina # Loperto, Cardinal-Bishop of Palestrina + government = ecclesiastical_government + effect = { + set_variable = { + name = named_after + value = title:c_roma + } + } + } + 1178.1.17 = { + holder = ce3_cardinal_bernardo_of_palestrina # Giovanni Conti, Cardinal-Bishop of Palestrina + } +} + +d_cd_sabina = { # Sabina (Viscovio/Poggio Mirteto) + 1062.1.1 = { + holder = ce3_cardinal_ubaldo_of_sabina # Ubaldo, Cardinal-Bishop of Sabina + government = ecclesiastical_government + effect = { + set_variable = { + name = named_after + value = title:b_roma + } + } + } + 1163.1.1 = { + holder = 7557 # Konrad, Cardinal-Priest of S. Marcello, celebrated in Sens + liege = e_hre + } +} + +d_cd_san_ciriaco = { # San Ciriaco (alle Terme Diocleziane) + 1066.1.1 = { + holder = ce3_cardinal_giovanni_of_san_ciriaco # Giovanni, Cardinal-Priest of San Ciriaco + government = ecclesiastical_government + effect = { + set_variable = { + name = named_after + value = title:b_roma + } + } + } + 1171.1.1 = { + holder = et_benevento_1178_1 # Lombardo, Cardinal-Priest of San Ciriaco, Archbishop of Benevento + } +} + +d_cd_san_lorenzo = { # San Lorenzo (in Lucina) + 1049.1.1 = { + holder = ce3_cardinal_leone_ii_of_san_lorenzo # Leone, Presbyter cardinalis of San Lorenzo in Lucina (most plausible) + government = ecclesiastical_government + effect = { + set_variable = { + name = named_after + value = title:b_roma + } + } + } + 1158.1.1 = { + holder = 71812 # Alberto, Cardinal-Priest of San Lorenzo in Lucina (most plausible), later Pope Gregory VIII + } + 1182.8.1 = { + holder = 223754 # Uberto, Cardinal-Priest of San Lorenzo in Lucina (most plausible), later Pope Urban III + } +} + +d_cd_santa_cecilia = { # Santa Cecilia (in Trastevere) + 1059.1.1 = { + holder = 2012 # Dauferio, Cardinal-Priest of S. Cecilia, later Pope Victor III + government = ecclesiastical_government + effect = { + set_variable = { + name = named_after + value = title:b_roma + } + } + } + 1178.3.1 = { + holder = ce3_cardinal_cinzio_papareschi # Cinzio, Cardinal-Priest of S. Cecilia, Nephew of Pope Innocent II + } +} + +d_cd_santa_balbina = { # Santa Balbina (all'Aventino) + 1178.1.1 = { + holder = 0 + effect = { + set_variable = { + name = named_after + value = title:b_roma + } + } + } +} + +d_cd_san_pietro = { # San Pietro (in Vincoli) + 1176.1.1 = { + holder = ce3_cardinal_eguillino_of_san_pietro # Eguillino, Cardinal-Priest of S. Pietro in Vincoli + government = ecclesiastical_government + effect = { + set_variable = { + name = named_after + value = title:b_roma + } + } + } +} + +d_cd_santa_anastasia = { # Sant'Anastasia (al Palatino) + 1063.1.1 = { + holder = ce3_cardinal_penno_of_santa_anastasia # Penno, Cardinal-Priest of Sant'Anastasia + government = ecclesiastical_government + effect = { + set_variable = { + name = named_after + value = title:b_roma + } + } + } + 1158.3.1 = { + holder = ce3_cardinal_giovanni_pizzuti # Giovanni Pizutti, Cardinal-Priest of Sant'Anastasia + } +} + +d_cd_damaso = { # Damaso (San Lorenzo) + 1065.1.1 = { + holder = ce3_cardinal_leone_ii_of_damaso # Leone, Cardinal-Priest of San Lorenzo in Damaso + government = ecclesiastical_government + effect = { + set_variable = { + name = named_after + value = title:b_roma + } + } + } + 1165.1.1 = { + holder = ce3_cardinal_pietro_di_miso # Pietro, Cardinal-Priest of San Lorenzo in Damaso + } +} + +d_cd_santa_rufina = { # Santa Rufina (Silva Candida) + 1049.1.1 = { + holder = ce3_cardinal_mainardo_of_pomposa # Mainardo di Pomposa, Cardinal-Bishop of S. Rufina (Silva Candida) + government = ecclesiastical_government + effect = { + set_variable = { + name = named_after + value = title:b_roma + } + } + } + 1074.1.1 = { + holder = 0 # Later date error prevention + } + 1102.1.1 = { + effect = { + set_variable = suppressed_cardinalate # combined with Porto + } + } +} + +# 1066 +d_cd_santa_sabina = { # Santa Sabina (all'Aventino) + 1058.1.1 = { + holder = ce3_cardinal_bruno_of_st_sabina # Bruno, Cardinal Arch-Priest of S. Sabina + government = ecclesiastical_government + effect = { + set_variable = { + name = named_after + value = title:b_roma + } + } + } + 1163.1.1 = { + holder = ce3_cardinal_pietro_of_santa_sabina # Pietro, Cardinal-Priest of S. Sabina + } +} + +d_cd_santa_maria = { # Santa Maria (in Domnica) + 1059.1.1 = { + holder = 2010 # Ildebrando, Santa Maria in Domnica + government = ecclesiastical_government + effect = { + set_variable = { + name = named_after + value = title:b_terracina + } + } + } + 1165.12.15 = { + holder = ce3_cardinal_pietro_de_bono # Pietro, Cardinal-Deacon of S. Maria in Aquiro + } +} + +d_cd_santa_prassede = { # Santa Prassede (all'Esquilino) + 1062.1.1 = { + holder = ce3_cardinal_adimaro_of_capua # Adimaro, Cardinal-Priest of S. Prassede + government = ecclesiastical_government + effect = { + set_variable = { + name = named_after + value = title:b_segni + } + } + } + 1173.9.1 = { + holder = ce3_cardinal_william_of_santa_prassede # William, Cardinal-Priest of S. Prassede + } +} + +d_cd_santi_cosma_e_damiano = { # Santi Cosma e Damiano + 1062.1.1 = { + holder = ce3_cardinal_anselmo_da_baggio # Anselmo, Nephew of Pope Alexander II, Bishop of Lucca, unspecified Cardinalate + government = ecclesiastical_government + liege = e_hre + effect = { + set_variable = { + name = named_after + value = title:b_roma + } + } + } + 1178.3.1 = { + holder = ce3_cardinal_graziano_of_ss_cosma_damiano # Graziano, Cardinal-Deacon of Ss. Cosma e Damiano + } +} + +d_cd_san_clemente = { # San Clemente (al Laterano) + 1049.1.1 = { + holder = ce3_cardinal_hughes_blancus # Hughes, Cardinal-Priest of S. Clemente + government = ecclesiastical_government + effect = { + set_variable = { + name = named_after + value = title:b_roma + } + } + } + 1170.1.1 = { + holder = ce3_cardinal_vernavero_of_san_clemente # Vernavero, Cardinal-Priest of S. Clemente + } +} + +d_cd_trastevere = { # Trastevere (Santa Maria) + 1061.1.1 = { + holder = ce3_cardinal_giovanni_minuzzo # Giovanni Minuzzo, Cardinal-Priest of S. Maria in Trastevere + government = ecclesiastical_government + effect = { + set_variable = { + name = named_after + value = title:b_roma + } + } + } + 1178.1.1 = { + holder = 0 + } +} + +d_cd_santi_silvestro_e_martino = { # Santi Silvestro e Martino + 1066.1.1 = { + holder = ce3_cardinal_guido_of_santi_silvestro_e_martino # Guido, Cardinal-Priest of Santi Silvestro e Martino + government = ecclesiastical_government + effect = { + set_variable = { + name = named_after + value = title:b_roma + } + } + } + 1178.1.1 = { # 1189.5.1 + holder = ce3_cardinal_alessandro_of_santi_silvestro_e_martino # Alessandro, Cardinal-Priest of Santi Silvestro e Martino + } +} + +# 1178 +d_cd_santi_nereo_ed_achilleo = { # Santi Nereo ed Achilleo + 1150.1.1 = { + holder = ce3_cardinal_errico_moricotti # Errico, Cardinal-Priest of Ss. Nereo ed Achilleo + government = ecclesiastical_government + effect = { + set_variable = { + name = named_after + value = title:b_ascoli_piceno + } + } + } +} + +d_cd_san_eustachio = { # Sant'Eustachio (in Campo Marzio) + 1163.1.1 = { + holder = ce3_cardinal_ugo_ricasoli # Ugo Ricasoli, Cardinal-Deacon of S. Eustachio + government = ecclesiastical_government + effect = { + set_variable = { + name = named_after + value = title:b_roma + } + } + } +} + +d_cd_santa_maria_nuova = { # Santa Maria Nuova + 1155.12.1 = { + holder = ce3_cardinal_matteo_of_santa_maria_nuova # Matteo, Cardinal-Deacon of S. Maria Nuova + government = ecclesiastical_government + effect = { + set_variable = { + name = named_after + value = title:b_civitavecchia + } + } + } +} + +d_cd_san_teodoro = { # San Teodoro (al Palatino) + 1155.12.1 = { + holder = ce3_cardinal_ardicio_rivoltella # Ardicio, Cardinal-Deacon of S. Teodoro + government = ecclesiastical_government + effect = { + set_variable = { + name = named_after + value = title:b_roma + } + } + } +} + +d_cd_san_adriano = { # Sant'Adriano (al Foro) + 1178.9.22 = { + holder = ce3_cardinal_rainier_of_sant_adriano # Rainier, Cardinal-Priest of S. Adriano + government = ecclesiastical_government + effect = { + set_variable = { + name = named_after + value = title:b_atri + } + } + } +} + +d_cd_san_marcello = { # San Marcello (al Corso) + 1178.1.1 = { # (1178.12.1) + holder = ce3_cardinal_mathieu_of_anjou # Mathieu d'Anjou + government = ecclesiastical_government + effect = { + set_variable = { + name = named_after + value = title:b_roma + } + } + } +} + +d_cd_san_vitale = { # San Vitale (Valeria, Gervasio, e Protasio) + 867.1.1 = { + holder = ce3_cardinal_hadrian_of_san_vitale + government = ecclesiastical_government + effect = { + set_variable = { + name = named_after + value = title:b_imola + } + } + } + 1066.1.1 = { + holder = 0 + } + 1166.1.1 = { + holder = ce3_cardinal_theodinus_di_arrone # Cardinal-Priest of S. Vitale + } +} + +d_cd_san_angelo = { # Sant'Angelo (in Pescheria) + 1071.1.1 = { + holder = ce3_cardinal_ugo_pierleoni # Cardinal-Deacon of S. Angelo in Pescheria, Grand-nephew of Antipope Anacletus II + government = ecclesiastical_government + effect = { + set_variable = { + name = named_after + value = title:b_ariano + } + } + } +} + +d_cd_santa_croce = { # Santa Croce (in Gerusalemme) + 1178.9.22 = { + holder = ce3_cardinal_ardoino_of_st_croce # Ardoino, Cardinal-Priest of S. Croce in Gerusalemme + government = ecclesiastical_government + effect = { + set_variable = { + name = named_after + value = title:b_roma + } + } + } +} + +d_cd_portico_octaviae = { # Portico Octaviae (Santa Maria) + 1071.1.1 = { + holder = ce3_cardinal_laborante_of_st_maria # Cardinal-Deacon of S. Maria in Portico Octaviae + government = ecclesiastical_government + effect = { + set_variable = { + name = named_after + value = title:b_paterno + } + } + } +} + +d_cd_san_crisogono = { # San Crisogono (in Trastevere) + 1066.1.1 = { + holder = ce3_cardinal_gregorio_of_san_crisogono # Gregorio, Cardinal-Priest of S. Crisogono + government = ecclesiastical_government + effect = { + set_variable = { + name = named_after + value = title:b_palo + } + } + } + 1173.9.1 = { + holder = ce3_cardinal_pietro_of_st_crisogono # Pietro, Cardinal-Priest of S. Crisogono + } +} + +d_cd_san_giorgio = { # San Giorgio (in Velabro) + 1173.9.1 = { + holder = ce3_cardinal_raniero_of_st_giorgio # Cardinal-Deacon of S. Giorgio in Velabro + government = ecclesiastical_government + effect = { + set_variable = { + name = named_after + value = title:b_gubbio + } + } + } +} + +d_cd_cosmedin = { # Cosmedin (Santa Maria) + 1144.1.1 = { + holder = 70841 # Giacinto, Cardinal-Priest of Santa Maria, later Pope Caelestinus + government = ecclesiastical_government + effect = { + set_variable = { + name = named_after + value = title:b_roma + } + } + } +} + +d_cd_san_stefano = { # Santo Stefano (Monte Celio) + 1175.3.7 = { + holder = ce3_cardinal_vibiano_of_santo_stefano # Vibiano, Cardinal-Priest of Santo Stefano (Monte Celio) + government = ecclesiastical_government + effect = { + set_variable = { + name = named_after + value = title:b_roma + } + } + } +} + +d_cd_san_marco = { # San Marco (Evangelista al Campidoglio) + 1167.1.1 = { + holder = ce3_cardinal_giovanni_of_san_marco # Giovanni Conti, Cardinal-Priest of San Marco + government = ecclesiastical_government + effect = { + set_variable = { + name = named_after + value = title:c_roma + } + } + } +} + +d_cd_santi_apostoli = { # Santi Dodici Apostoli + 1157.1.1 = { + holder = ce3_cardinal_ildebrando_grassi # Ildebrando, Cardinal-Deacon of S. XII Apostoli, former bishop of Modena from 1148 to 1156 + government = ecclesiastical_government + effect = { + set_variable = { + name = named_after + value = title:b_roma + } + } + } +} + +d_cd_santa_pudenziana = { # Santa Pudenziana (al Viminale) + 1165.1.1 = { + holder = ce3_cardinal_boso_breakspear # Boso Breakspear, Cardinal-Deacon of Ss. Cosma e Damiano, nephew of Pope Adrian IV? + government = ecclesiastical_government + effect = { + set_variable = { + name = named_after + value = title:b_roma + } + } + } +} + +d_cd_san_eusebio = { # Sant'Eusebio (all'Esquilino) + 1165.12.15 = { + holder = ce3_cardinal_raniero_of_san_eusebio # Raniero, Cardinal-Priest of S. Eusebio + government = ecclesiastical_government + effect = { + set_variable = { + name = named_after + value = title:b_roma + } + } + } +} + +d_cd_santi_sergio_e_bacco = { # Santi Sergio e Bacco + 1178.9.22 = { + holder = ce3_cardinal_paolo_of_santi_sergio_e_bacco # Paolo, Cardinal-Deacon of Ss. Sergio e Bacco + government = ecclesiastical_government + effect = { + set_variable = { + name = named_after + value = title:b_roma + } + } + } +} + +d_cd_san_nicola = { # San Nicola (in Carcere) + 1178.9.22 = { + holder = ce3_cardinal_bernardo_of_san_nicola # Cardinal-Deacon of S. Nicola in Carcere + government = ecclesiastical_government + effect = { + set_variable = { + name = named_after + value = title:b_paterno + } + } + } +} + +d_cd_santa_prisca = { # Santa Prisca + 1159.2.1 = { + holder = ce3_cardinal_uberto_of_santa_prisca # Uberto, Cardinal-Priest of S. Prisca + government = ecclesiastical_government + effect = { + set_variable = { + name = named_after + value = title:b_paterno + } + } + } +} + +d_cd_santi_giovanni_e_paolo = { # Santi Giovanni e Paolo + 1150.1.1 = { + holder = ce3_cardinal_giovanni_conti # Giovanni, Cardinal-Priest of Santi Giovanni e Paolo + government = ecclesiastical_government + effect = { + set_variable = { + name = named_after + value = title:b_roma + } + } + } +} + +### Ecclesiastical Titles + +# Hispania + +d_et_toledo = { # Toledo + 325.1.1 = { + liege = k_castille + holder = et_toledo_867_18 # Patruino + government = ecclesiastical_government + clerical_region = et_867_toledo_region + } + 385.1.1 = { holder = et_toledo_867_17 } # Audencio + 395.1.1 = { holder = et_toledo_867_16 } # Asturian + 523.1.1 = { holder = et_toledo_867_15 } # Montano + 603.1.1 = { holder = et_toledo_867_14 } # Aurasio + 615.1.1 = { holder = et_toledo_867_13 } # Eladio + 633.1.1 = { holder = et_toledo_867_12 } # Justo + 636.1.1 = { holder = et_toledo_867_11 } # Eugene + 646.1.1 = { holder = et_toledo_867_10 } # Eugene + 657.12.1 = { holder = et_toledo_867_9 } # Ildefonso + 667.2.1 = { holder = et_toledo_867_8 } # Quirico + 680.1.1 = { holder = et_toledo_867_7 } # Julián + 690.1.1 = { holder = et_toledo_867_6 } # Sisbert + 693.5.2 = { holder = et_toledo_867_5 } # Félix + 700.1.1 = { holder = et_toledo_867_4 } # Gunderic + 711.1.1 = { holder = et_toledo_867_3 } # Sindered + 774.1.1 = { holder = et_toledo_867_2 } # Cixila + 783.1.1 = { holder = et_toledo_867_1 } # Ellipando + 808.1.1 = { holder = et_toledo_867_0 } # Bonito + # 1066 + 892.1.1 = { holder = et_toledo_1066_3 } # Juan + 962.1.1 = { holder = et_toledo_1066_2 } # Ubayd-Allah + 1058.1.1 = { holder = toledo_archbishop_3 } # Pascual + # 1178 + 1086.1.1 = { holder = toledo_archbishop_2 } # Bernardo + 1124.1.1 = { holder = toledo_archbishop_4 } # Raimundo + 1152.1.1 = { holder = toledo_archbishop_1 } # Juan + 1167.1.1 = { holder = cerebruno_1 } # Cerebruno + 1178.1.1 = { clerical_region = et_1178_toledo_region } +} + +d_et_santiago = { # Santiago + 1120.2.27 = { + liege = k_leon + holder = 232021 # Diego + government = ecclesiastical_government + } + 1140.1.1 = { holder = 458004 } # Berenguel + 1142.1.1 = { holder = 210510 } # Pedro + 1149.1.1 = { holder = 72939 } # Bernardo + 1152.1.1 = { holder = 72940 } # Pelayo + 1156.1.1 = { holder = 72941 } # Martín + 1167.1.1 = { holder = 72942 } # Pedro + 1173.1.1 = { holder = 208520 } # Pedro + 1178.1.1 = { + government = ecclesiastical_government + clerical_region = et_1178_santiago_region + } +} + +d_et_tarragona = { # Tarragona + 470.1.1 = { + holder = et_tarragona_867_12 # Joan + government = ecclesiastical_government + clerical_region = et_867_tarragona_region + } + 520.1.1 = { holder = et_tarragona_867_11 } # Sergi + 560.1.1 = { holder = et_tarragona_867_10 } # Tranquilli + 589.1.1 = { holder = et_tarragona_867_9 } # Artemio + 599.1.1 = { holder = et_tarragona_867_8 } # Asiatic + 610.1.1 = { holder = et_tarragona_867_7 } # Eusebio + 632.1.1 = { holder = et_tarragona_867_6 } # Audax + 633.1.1 = { holder = et_tarragona_867_5 } # Selva + 637.1.1 = { holder = et_tarragona_867_4 } # Protasio + 645.1.1 = { holder = et_tarragona_867_3 } # Faluax + 668.1.1 = { holder = et_tarragona_867_2 } # Cebrian + 693.1.1 = { holder = et_tarragona_867_1 } # Vera + 694.1.1 = { holder = 0 } + # 1066 + 927.1.1 = { + holder = et_tarragona_1066_3 # Aimeric + } + 958.1.1 = { holder = et_tarragona_1066_5 } # Cesareo + 970.1.1 = { holder = et_tarragona_1066_4 } # Ató + 971.1.1 = { holder = et_tarragona_1066_3 } # Aimeric + 977.1.1 = { holder = et_tarragona_1066_2 } # Ermengol + 1019.1.1 = { holder = et_tarragona_1066_1 } # Guifred + # 1178 + 1079.1.1 = { holder = et_tarragona_1178_8 } # Dalmau + 1090.1.1 = { holder = et_tarragona_1178_7 } # Sunifred + 1117.1.1 = { holder = et_tarragona_1178_6 } # Oleguer + 1136.1.1 = { liege = k_aragon } + 1139.1.1 = { holder = et_tarragona_1178_5 } # Gregori + 1146.1.1 = { holder = et_tarragona_1178_4 } # Bernat + 1163.1.1 = { holder = et_tarragona_1178_3 } # Hug + 1171.1.1 = { holder = et_tarragona_1178_2 } # Guillem + 1174.1.1 = { holder = 210550 } # Berenguer +} + +d_et_sevilla = { # Sevilla + 522.1.1 = { + holder = et_sevilla_867_10 # Laureano + government = ecclesiastical_government + clerical_region = et_867_sevilla_region + } + 579.1.1 = { holder = et_sevilla_867_9 } # Leandro + 600.1.1 = { holder = et_sevilla_867_8 } # Isidoro + 636.5.12 = { holder = et_sevilla_867_7 } # Honorato + 641.1.1 = { holder = et_sevilla_867_6 } # Antonio + 656.1.1 = { holder = et_sevilla_867_5 } # Fugitivo + 682.1.1 = { holder = et_sevilla_867_4 } # Floresindo + 688.1.1 = { holder = et_sevilla_867_3 } # Felix + 710.1.1 = { holder = et_sevilla_867_2 } # Oppas + 850.1.1 = { holder = et_sevilla_867_1 } # Recafredo + 860.1.1 = { holder = 0 } +} + +d_et_braga = { # Braga + 440.1.1 = { + holder = et_braga_867_37 # Balconio + government = ecclesiastical_government + clerical_region = et_867_braga_region + } + 456.1.1 = { holder = et_braga_867_36 } # Valerio + 494.1.1 = { holder = et_braga_867_35 } # Idacio + 518.1.1 = { holder = et_braga_867_34 } # Apolinario + 524.1.1 = { holder = et_braga_867_33 } # Castino + 525.1.1 = { holder = et_braga_867_32 } # Valerio + 527.1.1 = { holder = et_braga_867_31 } # Ausberto + 537.1.1 = { holder = et_braga_867_30 } # Juliao + 538.1.1 = { holder = et_braga_867_29 } # Profuturo + 550.1.1 = { holder = et_braga_867_28 } # Eleuterio + 561.1.1 = { holder = et_braga_867_27 } # Lucrecio + 562.1.1 = { holder = et_braga_867_26 } # Martinho + 580.1.1 = { holder = et_braga_867_25 } # Pantardo + 589.1.1 = { holder = et_braga_867_24 } # Benigno + 612.1.1 = { holder = et_braga_867_23 } # Tolobeu + 633.1.1 = { holder = et_braga_867_22 } # Juliao + 653.1.1 = { holder = et_braga_867_21 } # Potamio + 656.1.1 = { holder = et_braga_867_20 } # Frutuoso + 660.1.1 = { holder = et_braga_867_19 } # Manucino + 661.1.1 = { holder = et_braga_867_18 } # Pancracio + 675.1.1 = { holder = et_braga_867_17 } # Leodegisio + 678.1.1 = { holder = et_braga_867_16 } # Liuva + 681.1.1 = { holder = et_braga_867_15 } # Quirico + 687.1.1 = { holder = et_braga_867_14 } # Faustino + 693.1.1 = { holder = et_braga_867_13 } # Felix + 734.1.1 = { holder = et_braga_867_12 } # Vitor + 736.1.1 = { holder = et_braga_867_11 } # Eronio + 737.1.1 = { holder = et_braga_867_10 } # Hermenegildo + 738.1.1 = { holder = et_braga_867_9 } # Tiago + 740.1.1 = { holder = et_braga_867_8 } # Odoario + 780.1.1 = { holder = et_braga_867_7 } # Ascarico + 821.1.1 = { holder = et_braga_867_6 } # Argimundo + 832.1.1 = { holder = et_braga_867_5 } # Nostiano + 832.1.2 = { holder = et_braga_867_4 } # Ataulfo + 840.1.1 = { holder = et_braga_867_3 } # Ferdizendo + 842.1.1 = { holder = et_braga_867_2 } # Dulcidio + 850.1.1 = { holder = et_braga_867_1 } # Gladila + 867.1.1 = { holder = et_braga_867_0 } # Gomado + # 1066 + 875.1.1 = { holder = et_braga_1066_15 } # Flaviano + 881.1.1 = { holder = et_braga_1066_14 } # Flaiano + 889.1.1 = { holder = et_braga_1066_13 } # Argimiro + 910.1.1 = { holder = et_braga_1066_12 } # Teodomiro + 924.1.1 = { holder = et_braga_1066_11 } # Hero + 930.1.1 = { holder = et_braga_1066_10 } # Silvatano + 942.1.1 = { holder = et_braga_1066_9 } # Gundisalvo + 951.1.1 = { holder = et_braga_1066_8 } # Hermenegildo + 986.1.1 = { holder = et_braga_1066_7 } # Pelágio + 1003.1.1 = { holder = et_braga_1066_6 } # Diogo + 1004.1.1 = { holder = et_braga_1066_5 } # Flaviano + 1017.1.2 = { holder = et_braga_1066_4 } # Pedro + 1058.1.1 = { holder = et_braga_1066_3 } # Maurelo + 1060.1.1 = { holder = et_braga_1066_2 } # Sigefredo + 1060.6.1 = { holder = et_braga_1066_1 } # Vistrário + # 1178 + 1071.1.1 = { holder = et_braga_1178_6 } # Pedro + 1095.7.3 = { holder = et_braga_1178_5 } # Geraldo + 1111.2.5 = { holder = et_braga_1178_4 } # Mauricio + 1118.1.1 = { holder = et_braga_1178_3 } # Paio + 1138.1.1 = { holder = et_braga_1178_2 } # João + 1175.12.1 = { holder = et_braga_1178_1 } # Godinho + 1178.1.1 = { clerical_region = et_1178_braga_region } +} + +d_et_merida = { # Merida + 408.1.1 = { + holder = et_merida_867_13 # Gregorio + government = ecclesiastical_government + clerical_region = et_867_merida_region + } + 445.1.1 = { holder = et_merida_867_12 } # Antonino + 483.1.1 = { holder = et_merida_867_11 } # Zenone + 530.1.1 = { holder = et_merida_867_10 } # Paolo + 560.1.1 = { holder = et_merida_867_9 } # Fedele + 573.1.1 = { holder = et_merida_867_8 } # Masona + 610.1.1 = { holder = et_merida_867_7 } # Innocenzo + 633.1.1 = { holder = et_merida_867_6 } # Stefano + 638.1.1 = { holder = et_merida_867_5 } # Oronzo + 666.1.1 = { holder = et_merida_867_4 } # Proficio + 672.1.1 = { holder = et_merida_867_3 } # Festo + 688.1.1 = { holder = et_merida_867_2 } # Massimo + 839.1.1 = { holder = et_merida_867_1 } # Arnulfo + 862.1.1 = { holder = 0 } + 904.1.1 = { holder = et_merida_1066_3 } # Thedocutus + 932.1.1 = { holder = et_merida_1066_2 } # Julio + 1000.1.1 = { holder = et_merida_1066_1 } # Daniel + 1010.1.1 = { holder = 0 } + 1177.1.1 = { clerical_region = none } # Integrated to Santiago for 1178 +} + +d_et_tingitana = { # Tingitana + 867.1.1 = { + government = ecclesiastical_government + clerical_region = et_867_tingitana_region + } +} + +# Britain + +d_et_york = { # York + 735.11.19 = { + holder = et_york_867_7 # Ecgbert + government = ecclesiastical_government + clerical_region = et_867_york_region + } + 761.11.8 = { holder = et_york_867_6 } # Æthelbert + 765.8.10 = { holder = et_york_867_5 } # Eanbald + 792.1.1 = { holder = et_york_867_4 } # Eanbald + 808.1.1 = { holder = et_york_867_3 } # Wulfsige + 837.1.1 = { holder = et_york_867_2 } # Wigmund + 854.1.1 = { holder = et_york_867_1 } # Wulfhere + # 1066 + 900.1.1 = { holder = et_york_1066_11 } # Æthelbald + 916.1.1 = { holder = et_york_1066_10 } # Hrotheweard + 931.1.1 = { holder = et_york_1066_9 } # Wulfstan + 958.1.1 = { holder = et_york_1066_8 } # Oskytel + 971.1.1 = { holder = et_york_1066_7 } # Edwald + 972.1.1 = { holder = et_york_1066_6 } # Oswald + 995.1.1 = { holder = et_york_1066_5 } # Ealdwulf + 1002.1.1 = { holder = et_york_1066_4 } # Wulfstan + 1023.1.1 = { holder = et_york_1066_3 } # Ælfric Puttoc + 1051.1.1 = { holder = et_york_1066_2 } # Cynesige + 1061.1.1 = { holder = et_york_1066_1 } # Ealdred + # 1178 + 1070.5.23 = { holder = et_york_1178_7 } # Thomas + 1100.12.1 = { holder = et_york_1178_6 } # Gerard + 1114.1.1 = { holder = et_york_1178_5 } # Thurstan + 1141.1.1 = { holder = et_york_1178_4 } # William + 1147.1.1 = { holder = et_york_1178_3 } # Henry + 1153.12.20 = { holder = et_york_1178_2 } # William + 1154.1.1 = { + holder = et_york_1178_1 # Roger + clerical_region = et_1178_york_region + } +} + +d_et_canterbury = { # Canterbury + 597.1.1 = { + holder = 180660 # Augustine + government = ecclesiastical_government + clerical_region = et_867_canterbury_region + } + 604.5.25 = { holder = 180661 } # Laurence + 619.2.2 = { holder = 180662 } # Mellitus + 624.4.24 = { holder = 180663 } # Justus + 629.11.10 = { holder = 180664 } # Honorius + 653.9.30 = { holder = 180665 } # Deusdedit + 664.7.14 = { holder = 180666 } # Theodore + 690.9.19 = { holder = 180667 } # Berhtwald + 731.1.13 = { holder = 180668 } # Tatwine + 734.7.30 = { holder = 180669 } # Nothhelm + 739.10.17 = { holder = 180670 } # Cuthbert + 760.10.26 = { holder = 180671 } # Bregowine + 765.8.1 = { holder = 180672 } # Jaenbert + 792.8.12 = { holder = 180673 } # Aethelhard + 805.5.12 = { holder = 180674 } # Wulfred + 832.3.24 = { holder = 180675 } # Ceolnoth + 870.2.4 = { holder = 180676 } # Aethelred + 888.6.30 = { holder = 180677 } # Plegmund + 923.8.2 = { holder = 180678 } # Athelm + 926.1.8 = { holder = 180679 } # Wulfhelm + 941.2.12 = { holder = 180680 } # Oda + 958.6.2 = { holder = 180681 } # Aelfsige + 959.1.1 = { holder = 180682 } # Byrhthelm + 973.5.15 = { holder = 180683 } # Dunstan + 988.5.19 = { holder = 180684 } # Aethelgar + 990.2.13 = { holder = 180685 } # Sigeric + 994.10.28 = { holder = 180686 } # Aelfric + 1005.11.16 = { holder = 180687 } # Aelfheath + 1012.4.19 = { holder = 180688 } # Lyfing + 1020.6.12 = { holder = 168608 } # Aethelnoth of Wessex + 1038.10.30 = { holder = 180690 } # Eadsige + 1050.10.29 = { holder = 180691 } # Robert of Jumièges + 1052.9.1 = { + holder = 5604 # Stigand + liege = k_england + } + 1070.4.11 = { holder = 5606 } + 1089.5.24 = { holder = 5608 } + 1109.4.21 = { holder = 161329 } + 1122.10.2 = { holder = 161330 } + 1136.11.21 = { holder = 161331 } + 1161.4.18 = { holder = 161332 } # Thomas Becket + 1170.12.29 = { + holder = 161333 + liege = k_england + } + 1184.2.16 = { holder = 161334 } + 1190.11.19 = { holder = 232680 } + 1205.7.13 = { holder = 161335 } + 1228.7.9 = { holder = 161336 } + 1231.8.3 = { holder = 161337 } + 1240.11.16 = { holder = 70912 } # Boniface of Savoy + 1270.7.14 = { holder = 161338 } + 1279.9.11 = { holder = 161339 } + 1292.12.8 = { holder = 161340 } + 1313.5.11 = { holder = 161341 } + 1327.11.16 = { holder = 161342 } + 1333.10.12 = { holder = 161343 } # John de Stratford +} + +d_et_dublin = { # Dublin + 1152.1.1 = { + holder = et_dublin_1178_2 # Gregory + government = ecclesiastical_government + clerical_region = et_1178_dublin_region + } + 1162.1.1 = { holder = et_dublin_1178_1 } # Laurence +} + +d_et_cashel = { # Cashel + 1152.1.1 = { + holder = et_cashel_1178_2 # Domnall Ua Lonngargáin + government = ecclesiastical_government + clerical_region = et_1178_cashel_region + } + 1172.1.1 = { holder = et_cashel_1178_1 } # Domnall Ua hUallacháin +} + +d_et_armagh = { # Armagh + 1152.1.1 = { + holder = et_armagh_1178_3 # Meic Liac + government = ecclesiastical_government + clerical_region = et_1178_armagh_region + } + 1174.1.1 = { holder = et_armagh_1178_2 } # Conchobar + 1175.1.1 = { holder = et_armagh_1178_1 } # Gilla +} + +d_et_tuam = { # Tuam + 1152.1.1 = { + holder = et_tuam_1178_2 # Áed + government = ecclesiastical_government + clerical_region = et_1178_tuam_region + } + 1161.1.1 = { holder = et_tuam_1178_1 } # Cadla +} + +# Gaul +d_et_rouen = { # Rouen + 488.1.1 = { + holder = et_rouen_867_23 # Godard + government = ecclesiastical_government + clerical_region = et_867_rouen_region + } + 525.1.1 = { holder = et_rouen_867_22 } # Filleul + 542.1.1 = { holder = et_rouen_867_21 } # Evod + 550.1.1 = { holder = et_rouen_867_20 } # Pretextat + 589.1.1 = { holder = et_rouen_867_19 } # Melantius + 602.1.1 = { holder = et_rouen_867_18 } # Hydulphe + 631.1.1 = { holder = et_rouen_867_17 } # Romain + 639.1.1 = { holder = et_rouen_867_16 } # Audoin + 689.1.1 = { holder = et_rouen_867_15 } # Ansbert + 695.1.1 = { holder = et_rouen_867_14 } # Grippo + 719.1.1 = { holder = et_rouen_867_13 } # Roland + 732.1.1 = { holder = et_rouen_867_12 } # Hugh + 740.1.1 = { holder = et_rouen_867_11 } # Robert + 744.1.1 = { holder = et_rouen_867_10 } # Grimo + 748.1.1 = { holder = et_rouen_867_9 } # Ragenfred + 753.1.1 = { holder = et_rouen_867_8 } # Remi + 762.1.1 = { holder = et_rouen_867_7 } # Hugh + 769.1.1 = { holder = et_rouen_867_6 } # Meinhard + 800.1.1 = { holder = et_rouen_867_5 } # Gilbert + 828.1.1 = { holder = et_rouen_867_4 } # Ragnoard + 836.1.1 = { holder = et_rouen_867_3 } # Gombaud + 849.1.1 = { holder = et_rouen_867_2 } # Paul + 855.1.1 = { holder = et_rouen_867_1 } # Wenilo + # 1066 + 869.1.1 = { holder = et_rouen_1066_10 } # Adalard + 872.1.1 = { holder = et_rouen_1066_9 } # Riculf + 876.1.1 = { holder = et_rouen_1066_8 } # Jean + 888.1.1 = { holder = et_rouen_1066_7 } # Léon + 889.1.1 = { holder = et_rouen_1066_6 } # Gui + 911.1.1 = { holder = et_rouen_1066_5 } # Francon + 919.1.1 = { holder = et_rouen_1066_4 } # Gonthard + 942.1.1 = { holder = et_rouen_1066_3 } # Hugues + 990.1.1 = { holder = et_rouen_1066_2 } # Roberto + 1055.1.1 = { holder = et_rouen_1066_1 } # Maurille + # 1178 + 1183.11.26 = { holder = et_rouen_1178_5 } # Jean + 1110.2.9 = { holder = et_rouen_1178_4 } # Guillaume + 1128.11.28 = { holder = et_rouen_1178_3 } # Geoffrey + 1164.11.11 = { holder = et_rouen_1178_2 } # Hugues + 1165.1.1 = { holder = et_rouen_1178_1 } # Rotrou +} + +d_et_reims = { # Reims + 400.1.1 = { + liege = k_france + holder = et_reims_867_23 # Nicaise + government = ecclesiastical_government + clerical_region = et_867_reims_region + } + 407.1.1 = { holder = et_reims_867_22 } # Baruche + 420.1.1 = { holder = et_reims_867_21 } # Barnabas + 440.1.1 = { holder = et_reims_867_20 } # Bennage + 459.1.1 = { holder = et_reims_867_19 } # Remi + 533.1.1 = { holder = et_reims_867_18 } # Romain + 535.1.1 = { holder = et_reims_867_17 } # Flavius + 549.1.1 = { holder = et_reims_867_16 } # Mappinus + 550.1.1 = { holder = et_reims_867_15 } # Egidius + 590.1.1 = { holder = et_reims_867_14 } # Romulphe + 593.1.1 = { holder = et_reims_867_13 } # Sonnace + 631.1.1 = { holder = et_reims_867_12 } # Leudegisil + 641.1.1 = { holder = et_reims_867_11 } # Anglebert + 646.1.1 = { holder = et_reims_867_10 } # Lando + 649.1.1 = { holder = et_reims_867_9 } # Nivard + 673.1.1 = { holder = et_reims_867_8 } # Rieul + 695.1.1 = { holder = et_reims_867_7 } # Rigobert + 717.1.1 = { holder = et_reims_867_6 } # Milo + 744.1.1 = { holder = et_reims_867_5 } # Abel + 748.1.1 = { holder = 91506 } # Tilpin + 812.1.1 = { holder = et_reims_867_3 } # Wulfar + 817.1.1 = { holder = et_reims_867_2 } # Ebbo + 840.1.1 = { holder = et_reims_867_2 } # Ebbo (2nd term after vacancy) + 845.4.1 = { holder = 163049 } # Hincmar + # 1066 + 883.3.7 = { holder = 167927 } # Folco + 900.7.6 = { holder = et_reims_1066_11 } # Erveo + 922.1.1 = { holder = et_reims_1066_10 } # Seulfo + 931.1.1 = { holder = 144976 } # Artaldo + 962.4.1 = { holder = et_reims_1066_8 } # Odelrico + 969.1.1 = { holder = 165026 } # Adalbero + 989.1.23 = { holder = 144978 } # Arnulf + 991.1.1 = { holder = 7824 } # Gerberto + 998.4.1 = { holder = 144978 } # Arnulf + 1021.1.1 = { holder = et_reims_1066_3 } # Ebles + 1033.7.1 = { holder = et_reims_1066_2 } # Guy + 1055.10.15 = { holder = 91173 } # Gervais + # 1178 + 1070.7.4 = { holder = 20132 } # Manassès I + 1081.12.27 = { holder = 91174 } # Renauld I + 1096.1.1 = { holder = 91175 } # Manassès II + 1106.9.17 = { holder = 232013 } # Gervais + 1107.5.23 = { holder = 91176 } # Raoul + 1124.1.1 = { holder = 91177 } # Raymond + 1138.1.1 = { holder = 91178 } # Samson + 1161.1.1 = { holder = 91033 } # Henri + 1176.1.1 = { holder = 91160 } # Guillaume +} + +d_et_sens = { # Sens + 346.1.1 = { + holder = et_sens_867_29 # Savinien + government = ecclesiastical_government + clerical_region = et_867_sens_region + } + 356.1.1 = { holder = et_sens_867_28 } # Ursicin + 487.1.1 = { holder = et_sens_867_27 } # Héracle + 515.1.1 = { holder = et_sens_867_26 } # Paul + 533.1.1 = { holder = et_sens_867_25 } # Leo + 549.1.1 = { holder = et_sens_867_24 } # Constitut + 579.1.1 = { holder = et_sens_867_23 } # Arthème + 614.1.1 = { holder = et_sens_867_22 } # Loup + 632.1.1 = { holder = et_sens_867_21 } # Hidegaire + 639.1.1 = { holder = et_sens_867_20 } # Richer + 642.1.1 = { holder = et_sens_867_19 } # Gondelbert + 650.1.1 = { holder = et_sens_867_18 } # Armentaire + 654.1.1 = { holder = et_sens_867_17 } # Arnoul + 660.1.1 = { holder = et_sens_867_16 } # Emmon + 669.1.1 = { holder = et_sens_867_15 } # Amé + 673.1.1 = { holder = et_sens_867_14 } # Gombert + 680.1.1 = { holder = et_sens_867_13 } # Lambert + 683.1.1 = { holder = et_sens_867_12 } # Wulfram + 697.1.1 = { holder = et_sens_867_11 } # Géry + 711.1.1 = { holder = et_sens_867_10 } # Ebbo + 744.1.1 = { holder = et_sens_867_9 } # Honulphe + 757.1.1 = { holder = et_sens_867_8 } # Loup + 769.1.1 = { holder = et_sens_867_7 } # Wilchar + 797.1.1 = { holder = et_sens_867_6 } # Bérard + 802.1.1 = { holder = et_sens_867_5 } # Magnus + 822.1.1 = { holder = et_sens_867_4 } # Jeremias + 829.1.1 = { holder = et_sens_867_3 } # Alderic + 837.1.1 = { holder = et_sens_867_2 } # Wenilo + 865.1.1 = { holder = et_sens_867_1 } # Eigil + # 1066 + 871.6.27 = { holder = et_sens_1066_15 } # Anségise + 884.1.1 = { holder = et_sens_1066_14 } # Evrard + 887.1.1 = { holder = et_sens_1066_13 } # Gauthier + 924.1.1 = { holder = et_sens_1066_12 } # Gauthier + 927.1.1 = { holder = et_sens_1066_11 } # Audald + 932.1.1 = { holder = et_sens_1066_10 } # Guillaume + 938.1.1 = { holder = et_sens_1066_9 } # Gerlair + 954.9.12 = { holder = et_sens_1066_8 } # Hildeman + 959.1.1 = { holder = et_sens_1066_7 } # Archambaud + 967.1.1 = { holder = et_sens_1066_6 } # Anastase + 977.6.10 = { holder = et_sens_1066_5 } # Sevin + 1000.1.1 = { holder = et_sens_1066_4 } # Léotheric + 1032.10.18 = { holder = et_sens_1066_3 } # Gelduin + 1049.11.1 = { holder = et_sens_1066_2 } # Mainard + 1062.4.1 = { holder = et_sens_1066_1 } # Richer + # 1178 + 1097.3.1 = { holder = et_sens_1178_5 } # Daimbert + 1123.1.1 = { holder = et_sens_1178_4 } # Henri + 1142.1.1 = { holder = et_sens_1178_3 } # Hugues + 1168.12.22 = { holder = 91160 } # Guillaume + 1176.1.1 = { holder = et_sens_1178_1 } # Guy +} + +d_et_tours = { # Tours + 442.1.1 = { + holder = et_tours_867_36 # Eustoche + government = ecclesiastical_government + clerical_region = et_867_tours_region + } + 458.1.1 = { holder = et_tours_867_35 } # Perpet + 489.1.1 = { holder = et_tours_867_34 } # Volusien + 496.1.1 = { holder = et_tours_867_33 } # Vére + 546.1.1 = { holder = et_tours_867_32 } # Baud + 552.1.1 = { holder = et_tours_867_31 } # Gonthaire + 556.1.1 = { holder = et_tours_867_30 } # Euphore + 573.1.1 = { holder = et_tours_867_29 } # Gregoire + 602.1.1 = { holder = et_tours_867_28 } # Lupare + 614.1.1 = { holder = et_tours_867_27 } # Agiric + 617.1.1 = { holder = et_tours_867_26 } # Ginaldus + 619.1.1 = { holder = et_tours_867_25 } # Sigilaicus + 622.1.1 = { holder = et_tours_867_24 } # Leobald + 625.1.1 = { holder = et_tours_867_23 } # Médegaud + 638.1.1 = { holder = et_tours_867_22 } # Latinus + 650.1.1 = { holder = et_tours_867_21 } # Carégisile + 652.1.1 = { holder = et_tours_867_20 } # Rigobert + 654.1.1 = { holder = et_tours_867_19 } # Papolene + 660.1.1 = { holder = et_tours_867_18 } # Chrotbert + 695.1.1 = { holder = et_tours_867_17 } # Pelagius + 700.1.1 = { holder = et_tours_867_16 } # Evartius + 709.1.1 = { holder = et_tours_867_15 } # Ibbon + 724.1.1 = { holder = et_tours_867_14 } # Gontran + 732.1.1 = { holder = et_tours_867_13 } # Didon + 733.1.1 = { holder = et_tours_867_12 } # Rimbert + 752.1.1 = { holder = et_tours_867_11 } # Aubert + 754.1.1 = { holder = et_tours_867_10 } # Ostald + 760.1.1 = { holder = et_tours_867_9 } # Gravien + 765.1.1 = { holder = et_tours_867_8 } # Eusebe + 771.1.1 = { holder = et_tours_867_7 } # Herling + 792.1.1 = { holder = et_tours_867_6 } # Joseph + 815.1.1 = { holder = et_tours_867_5 } # Landran + 836.1.1 = { holder = et_tours_867_4 } # Ursmarus + 846.1.1 = { holder = et_tours_867_3 } # Landran + 852.1.1 = { holder = et_tours_867_2 } # Amaury + 856.1.1 = { holder = et_tours_867_1 } # Hérard + # 1066 + 872.1.1 = { holder = et_tours_1066_12 } # Actard + 875.1.1 = { holder = et_tours_1066_11 } # Adalard + 890.1.1 = { holder = et_tours_1066_10 } # Herbernes + 916.1.1 = { holder = et_tours_1066_9 } # Robert + 932.1.1 = { holder = et_tours_1066_8 } # Theotolo + 946.1.1 = { holder = et_tours_1066_7 } # Joseph + 957.1.1 = { holder = et_tours_1066_6 } # Frotaire + 960.1.1 = { holder = et_tours_1066_5 } # Hardouin + 981.1.1 = { holder = et_tours_1066_4 } # Archambault + 1008.1.1 = { holder = et_tours_1066_3 } # Hugues + 1023.1.1 = { holder = et_tours_1066_2 } # Arnoul + 1053.1.1 = { holder = et_tours_1066_1 } # Barthelemy + # 1178 + 1072.1.1 = { holder = et_tours_1178_8 } # Raoul + 1087.1.1 = { holder = et_tours_1178_7 } # Raoul + 1118.1.1 = { holder = et_tours_1178_6 } # Gilbert + 1125.1.1 = { holder = et_tours_1178_5 } # Hildebert + 1133.1.1 = { holder = et_tours_1178_4 } # Hugues + 1147.1.1 = { holder = et_tours_1178_3 } # Engebault + 1157.1.1 = { holder = et_tours_1178_2 } # Joscion + 1174.1.1 = { holder = et_tours_1178_1 } # Barthelemy +} + +d_et_bourges = { # Bourges + 251.1.1 = { + holder = et_bourges_867_16 # Ursin + government = ecclesiastical_government + clerical_region = et_867_bourges_region + } + 280.1.1 = { holder = et_bourges_867_15 } # Sénitien + 296.1.1 = { holder = et_bourges_867_14 } # Oethère + 330.1.1 = { holder = et_bourges_867_13 } # Marcel + 337.1.1 = { holder = et_bourges_867_12 } # Viator + 549.1.1 = { holder = et_bourges_867_11 } # Didier + 584.1.1 = { holder = et_bourges_867_10 } # Sulpice + 591.1.1 = { holder = et_bourges_867_9 } # Eustase + 591.1.1 = { holder = et_bourges_867_8 } # Apollinaris + 612.1.1 = { holder = et_bourges_867_7 } # Austrégésile + 627.1.1 = { holder = et_bourges_867_6 } # Sulpice + 788.1.1 = { holder = et_bourges_867_5 } # Ermembert + 810.1.1 = { holder = et_bourges_867_4 } # Ebroin + 829.1.1 = { holder = et_bourges_867_3 } # Août + 839.1.1 = { holder = et_bourges_867_2 } # Rodulf + 866.1.1 = { holder = et_bourges_867_1 } # Wulfad + # 1066 + 876.10.28 = { holder = et_bourges_1066_10 } # Frotaire + 890.1.1 = { holder = et_bourges_1066_9 } # Adace + 900.1.1 = { holder = et_bourges_1066_8 } # Madalbert + 910.1.1 = { holder = et_bourges_1066_7 } # Géronce + 948.1.1 = { holder = et_bourges_1066_6 } # Laune + 955.1.1 = { holder = et_bourges_1066_5 } # Richard + 969.1.1 = { holder = et_bourges_1066_4 } # Hugues + 987.1.1 = { holder = et_bourges_1066_3 } # Dagbert + 1013.1.1 = { holder = et_bourges_1066_2 } # Gauzlin + 1030.1.1 = { holder = 40168 } # Aymon + # 1178 + 1071.1.1 = { holder = et_bourges_1178_8 } # Richard + 1092.1.1 = { holder = et_bourges_1178_7 } # Audebert + 1097.1.1 = { holder = et_bourges_1178_6 } # Leger + 1120.1.1 = { holder = et_bourges_1178_5 } # Vulgrin + 1137.1.1 = { holder = et_bourges_1178_4 } # Alberic + 1141.1.1 = { holder = et_bourges_1178_3 } # Pierre + 1171.1.1 = { holder = et_bourges_1178_2 } # Étienne + 1174.1.1 = { holder = et_bourges_1178_1 } # Guarin +} + +d_et_bordeaux = { # Bordeaux + 314.1.1 = { + holder = et_bordeaux_867_11 # Orientalis + government = ecclesiastical_government + clerical_region = et_867_bordeaux_region + } + 380.1.1 = { holder = et_bordeaux_867_10 } # Delphin + 404.1.1 = { holder = et_bordeaux_867_8 } # Amand + 410.1.1 = { holder = et_bordeaux_867_9 } # Seurin + 420.1.1 = { holder = et_bordeaux_867_8 } # Amand + 520.1.1 = { holder = et_bordeaux_867_7 } # Léonce + 542.1.1 = { holder = et_bordeaux_867_6 } # Léonce + 566.1.1 = { holder = et_bordeaux_867_5 } # Bertram + 589.1.1 = { holder = et_bordeaux_867_4 } # Gundigisil + 814.1.1 = { holder = et_bordeaux_867_3 } # Sicaire + 829.1.1 = { holder = et_bordeaux_867_2 } # Adelelme + 860.1.1 = { holder = et_bordeaux_867_1 } # Frothar + # 1066 + 940.1.1 = { holder = et_bordeaux_1066_9 } # Adalberto + 989.1.1 = { holder = et_bordeaux_1066_8 } # Gombaud + 1000.1.1 = { holder = et_bordeaux_1066_7 } # Séguin + 1016.1.1 = { holder = et_bordeaux_1066_6 } # Arnaud + 1022.1.1 = { holder = et_bordeaux_1066_5 } # Islon + 1027.1.1 = { holder = et_bordeaux_1066_4 } # Geoffroi + 1047.1.1 = { holder = et_bordeaux_1066_3 } # Archambaud + 1059.1.1 = { holder = et_bordeaux_1066_2 } # Andron + 1059.2.1 = { holder = et_bordeaux_1066_1 } # Joscelin + # 1178 + 1088.1.1 = { holder = et_bordeaux_1178_8 } # Amat + 1103.1.1 = { holder = et_bordeaux_1178_7 } # Arnaud + 1131.1.1 = { holder = et_bordeaux_1178_6 } # Gérard + 1135.1.1 = { holder = et_bordeaux_1178_5 } # Geoffroi + 1158.1.1 = { holder = et_bordeaux_1178_4 } # Raimond + 1160.1.1 = { holder = et_bordeaux_1178_3 } # Hardouin + 1162.8.1 = { holder = et_bordeaux_1178_2 } # Bertrand + 1174.1.1 = { holder = et_bordeaux_1178_1 } # Guillaume +} + +d_et_lyon = { # Lyon + 374.1.1 = { + holder = et_lyon_867_27 # Just + government = ecclesiastical_government + clerical_region = et_867_lyon_region + } + 390.1.1 = { holder = et_lyon_867_26 } # Albin + 397.1.1 = { holder = et_lyon_867_25 } # Martin + 400.1.1 = { holder = et_lyon_867_24 } # Antioche + 410.1.1 = { holder = et_lyon_867_23 } # Élpide + 422.1.1 = { holder = et_lyon_867_22 } # Sicaire + 432.1.1 = { holder = et_lyon_867_21 } # Eucher + 451.1.1 = { holder = et_lyon_867_20 } # Patiens + 491.1.1 = { holder = et_lyon_867_19 } # Lupicin + 494.1.1 = { holder = et_lyon_867_18 } # Rustique + 501.1.1 = { holder = et_lyon_867_17 } # Etienne + 514.1.1 = { holder = et_lyon_867_16 } # Viventiole + 538.1.1 = { holder = et_lyon_867_15 } # Loup + 549.1.1 = { holder = et_lyon_867_14 } # Sacerdos + 552.1.1 = { holder = et_lyon_867_13 } # Nizier + 573.1.1 = { holder = et_lyon_867_12 } # Prisque + 589.1.1 = { holder = et_lyon_867_11 } # Ethère + 602.1.1 = { holder = et_lyon_867_10 } # Arige + 626.1.1 = { holder = et_lyon_867_9 } # Tétrice + 637.1.1 = { holder = et_lyon_867_8 } # Canderic + 654.1.1 = { holder = et_lyon_867_7 } # Annemund + 664.1.1 = { holder = et_lyon_867_6 } # Genès + 678.1.1 = { holder = et_lyon_867_5 } # Lambert + 798.1.1 = { holder = et_lyon_867_4 } # Leidrad + 814.1.1 = { holder = et_lyon_867_3 } # Agobard + 840.1.1 = { holder = et_lyon_867_2 } # Amulo + 852.1.1 = { holder = et_lyon_867_1 } # Rémi + # 1066 + 875.1.1 = { holder = et_lyon_1066_15 } # Aurélien + 895.1.1 = { holder = et_lyon_1066_14 } # Alwala + 906.1.1 = { holder = et_lyon_1066_13 } # Bernard + 906.2.1 = { holder = et_lyon_1066_12 } # Austère + 916.1.1 = { holder = et_lyon_1066_11 } # Remi + 922.1.1 = { holder = et_lyon_1066_10 } # Anscheric + 928.1.1 = { holder = et_lyon_1066_9 } # Guy + 949.1.1 = { holder = et_lyon_1066_8 } # Burchard + 963.1.1 = { holder = et_lyon_1066_7 } # Amblard + 978.1.1 = { holder = et_lyon_1066_6 } # Burchard + 1041.1.1 = { holder = et_lyon_1066_5 } # Odolric + 1046.1.1 = { holder = et_lyon_1066_4 } # Halinard + 1052.1.1 = { holder = et_lyon_1066_3 } # Philippe + 1054.1.1 = { holder = et_lyon_1066_2 } # Geoffroy + 1065.1.1 = { holder = et_lyon_1066_1 } # Humbert + # 1178 + 1077.1.1 = { holder = et_lyon_1178_12 } # Jubin + 1083.1.1 = { holder = et_lyon_1178_11 } # Hugues + 1110.1.1 = { holder = et_lyon_1178_10 } # Gaucerand + 1118.1.1 = { holder = et_lyon_1178_9 } # Humbaud + 1128.1.1 = { holder = et_lyon_1178_8 } # Renaud + 1131.1.1 = { holder = et_lyon_1178_7 } # Pierre + 1139.1.1 = { holder = et_lyon_1178_6 } # Foulque + 1142.1.1 = { holder = et_lyon_1178_5 } # Amédée + 1148.1.1 = { holder = et_lyon_1178_4 } # Humbert + 1153.1.1 = { holder = et_lyon_1178_3 } # Héraclée + 1163.1.1 = { holder = et_lyon_1178_2 } # Dreux + 1165.1.1 = { holder = et_lyon_1178_1 } # Guichard +} + +d_et_tarentaise = { # Tarentaise + 426.1.1 = { + holder = et_tarentaise_867_10 # Jacques + government = ecclesiastical_government + clerical_region = et_867_tarentaise_region + } + 429.1.1 = { holder = et_tarentaise_867_9 } # Marcel + 460.1.1 = { holder = et_tarentaise_867_8 } # Thomas + 517.1.1 = { holder = et_tarentaise_867_7 } # Sanctius + 580.1.1 = { holder = et_tarentaise_867_6 } # Marcien + 650.1.1 = { holder = et_tarentaise_867_5 } # Baudoméris + 775.1.1 = { holder = et_tarentaise_867_4 } # Possessor + 824.1.1 = { holder = et_tarentaise_867_3 } # Andréas + 840.1.1 = { holder = et_tarentaise_867_2 } # Audax + 858.1.1 = { holder = et_tarentaise_867_1 } # Teutrand + # 1066 + 900.1.1 = { holder = et_tarentaise_1066_8 } # Anizo + 994.1.1 = { holder = et_tarentaise_1066_7 } # Anizo + 996.1.1 = { holder = et_tarentaise_1066_6 } # Aymon + 1000.1.1 = { holder = et_tarentaise_1066_5 } # Cuno + 1006.1.1 = { holder = et_tarentaise_1066_4 } # Baldoph + 1020.1.1 = { holder = et_tarentaise_1066_3 } # Luzo + 1025.1.1 = { holder = et_tarentaise_1066_2 } # Aymon + 1058.1.1 = { holder = et_tarentaise_1066_1 } # Ebbon + # 1178 + 1077.1.1 = { holder = et_tarentaise_1178_7 } # Annuzio + 1082.1.1 = { holder = et_tarentaise_1178_6 } # Héraclée + 1090.1.1 = { holder = et_tarentaise_1178_5 } # Bozon + 1124.1.1 = { holder = et_tarentaise_1178_4 } # Pierre + 1140.1.1 = { holder = et_tarentaise_1178_3 } # Isdrael + 1142.1.1 = { holder = et_tarentaise_1178_2 } # Pierre + 1178.1.1 = { holder = et_tarentaise_1178_1 } # Aymon +} + +d_et_vienne = { # Vienne + 449.1.1 = { + holder = et_vienne_867_23 # Nicétas + government = ecclesiastical_government + clerical_region = et_867_vienne_region + } + 463.1.1 = { holder = et_vienne_867_22 } # Mamert + 490.1.1 = { holder = et_vienne_867_21 } # Avit + 520.1.1 = { holder = et_vienne_867_20 } # Julian + 534.1.1 = { holder = et_vienne_867_19 } # Domnin + 540.1.1 = { holder = et_vienne_867_18 } # Pantagathe + 549.1.1 = { holder = et_vienne_867_17 } # Isice + 555.1.1 = { holder = et_vienne_867_16 } # Namat + 596.1.1 = { holder = et_vienne_867_15 } # Didier + 620.1.1 = { holder = et_vienne_867_14 } # Éthère + 625.1.1 = { holder = et_vienne_867_13 } # Clarent + 625.1.1 = { holder = et_vienne_867_12 } # Syndulphe + 680.1.1 = { holder = et_vienne_867_11 } # Georges + 700.1.1 = { holder = et_vienne_867_10 } # Éoalde + 718.1.1 = { holder = et_vienne_867_9 } # Bobolin + 719.1.1 = { holder = et_vienne_867_8 } # Austrebert + 742.1.1 = { holder = et_vienne_867_7 } # Wilchar + 767.1.1 = { holder = et_vienne_867_6 } # Bertéric + 790.1.1 = { holder = et_vienne_867_5 } # Ursio + 797.1.1 = { holder = et_vienne_867_4 } # Wulfar + 810.1.1 = { holder = et_vienne_867_3 } # Bernard + 841.1.1 = { holder = et_vienne_867_2 } # Agilmar + 860.1.1 = { holder = et_vienne_867_1 } # Ado + # 1066 + 878.1.1 = { holder = et_vienne_1066_8 } # Ottramne + 886.1.1 = { holder = et_vienne_1066_7 } # Bernoin + 899.1.1 = { holder = et_vienne_1066_6 } # Raginfred + 908.1.1 = { holder = et_vienne_1066_5 } # Alexander + 927.1.1 = { holder = et_vienne_1066_4 } # Sobon + 957.1.1 = { holder = et_vienne_1066_3 } # Teobaldo + 1011.1.1 = { holder = et_vienne_1066_2 } # Burchard + 1030.1.1 = { holder = et_vienne_1066_1 } # Léger + # 1178 + 1070.1.1 = { holder = et_vienne_1178_11 } # Armand + 1077.1.1 = { holder = et_vienne_1178_10 } # Warmond + 1082.1.1 = { holder = et_vienne_1178_9 } # Gontard + 1088.1.1 = { holder = et_vienne_1178_8 } # Guido + 1121.1.1 = { holder = et_vienne_1178_7 } # Pierre + 1129.1.1 = { holder = et_vienne_1178_6 } # Étienne + 1146.1.1 = { holder = et_vienne_1178_5 } # Humbert + 1148.1.1 = { holder = et_vienne_1178_4 } # Hugues + 1155.1.1 = { holder = et_vienne_1178_3 } # Étienne + 1163.1.1 = { holder = et_vienne_1178_2 } # Guillaume + 1173.1.1 = { holder = et_vienne_1178_1 } # Robert +} + +d_et_eauze = { # Eauze + 300.1.1 = { + holder = et_eauze_867_7 # Mammertin + government = ecclesiastical_government + clerical_region = et_867_eauze_region + } + 585.1.1 = { holder = et_eauze_867_6 } # Désidère + 614.1.1 = { holder = et_eauze_867_5 } # Leodomundus + 626.1.1 = { holder = et_eauze_867_4 } # Palladius + 627.1.1 = { holder = et_eauze_867_3 } # Senoc + 675.1.1 = { holder = et_eauze_867_2 } # Scupilio + 867.1.1 = { holder = et_eauze_867_1 } # Ayrard + 879.1.1 = { + holder = 0 + clerical_region = none + } +} + +d_et_auch = { # Auch, replacees Eauze in 1066 + 879.1.1 = { + holder = et_auch_1066_6 # Ayrard + government = ecclesiastical_government + clerical_region = et_1066_auch_region + } + 980.1.1 = { holder = et_auch_1066_5 } # Garsias + 988.1.1 = { holder = et_auch_1066_4 } # Odo + 1025.1.1 = { holder = et_auch_1066_3 } # Garsias + 1036.1.1 = { holder = et_auch_1066_2 } # Raymond + 1042.1.1 = { holder = et_auch_1066_1 } # Austinde + # 1178 + 1068.1.1 = { holder = et_auch_1178_5 } # Guillaume + 1096.1.1 = { holder = et_auch_1178_4 } # Raymond + 1118.1.1 = { holder = et_auch_1178_3 } # Bernard + 1126.1.1 = { holder = et_auch_1178_2 } # Guillaume + 1170.1.1 = { holder = et_auch_1178_1 } # Gérault +} + +d_et_narbonne = { # Narbonne + 427.1.1 = { + holder = et_narbonne_867_15 # Rusticus + government = ecclesiastical_government + clerical_region = et_867_narbonne_region + } + 462.1.1 = { holder = et_narbonne_867_14 } # Hermes + 506.1.1 = { holder = et_narbonne_867_13 } # Caprarius + 560.1.1 = { holder = et_narbonne_867_12 } # Aquilin + 580.1.1 = { holder = et_narbonne_867_11 } # Athaloc + 589.1.1 = { holder = et_narbonne_867_10 } # Mégace + 610.1.1 = { holder = et_narbonne_867_9 } # Sergius + 633.1.1 = { holder = et_narbonne_867_8 } # Selva + 672.1.1 = { holder = et_narbonne_867_7 } # Argebaud + 683.1.1 = { holder = et_narbonne_867_6 } # Sunifred + 769.1.1 = { holder = et_narbonne_867_5 } # Daniel + 798.1.1 = { holder = et_narbonne_867_4 } # Nimfridius + 827.1.1 = { holder = et_narbonne_867_3 } # Barthélemy + 842.1.1 = { holder = et_narbonne_867_2 } # Berarius + 850.1.1 = { holder = et_narbonne_867_1 } # Frédold + # 1066 + 885.1.1 = { holder = et_narbonne_1066_6 } # Théodard + 893.1.1 = { holder = et_narbonne_1066_5 } # Arnuste + 914.1.1 = { holder = et_narbonne_1066_4 } # Agio + 926.1.1 = { holder = et_narbonne_1066_3 } # Aimery + 977.1.1 = { holder = et_narbonne_1066_2 } # Ermengaud + 1019.10.6 = { holder = 70169 } # Guifred + # 1178 + 1079.1.1 = { holder = et_narbonne_1178_8 } # Pierre + 1081.1.1 = { holder = et_narbonne_1178_7 } # Dalmas + 1096.1.1 = { holder = et_narbonne_1178_6 } # Bertrand + 1106.11.5 = { holder = et_narbonne_1178_5 } # Richard + 1121.5.17 = { holder = et_narbonne_1178_4 } # Arnaud + 1150.1.1 = { holder = et_narbonne_1178_3 } # Pierre + 1156.1.1 = { holder = et_narbonne_1178_2 } # Bérenger + 1162.4.1 = { holder = et_narbonne_1178_1 } # Pons +} + +d_et_besancon = { # Besançon + 627.1.1 = { + holder = et_besancon_867_7 # Donat + government = ecclesiastical_government + clerical_region = et_867_besancon_region + } + 680.1.1 = { holder = et_besancon_867_6 } # Gervase + 685.1.1 = { holder = et_besancon_867_5 } # Claude + 757.1.1 = { holder = et_besancon_867_4 } # Gervais + 811.1.1 = { holder = et_besancon_867_3 } # Bernoin + 838.1.1 = { holder = et_besancon_867_2 } # Amalwin + 843.1.1 = { holder = et_besancon_867_1 } # Arduic + # 1066 + 872.1.1 = { holder = et_besancon_1066_10 } # Thierry + 895.1.1 = { holder = et_besancon_1066_9 } # Berengarius + 915.1.1 = { holder = et_besancon_1066_8 } # Aymin + 927.1.1 = { holder = et_besancon_1066_7 } # Gontier + 944.1.1 = { holder = et_besancon_1066_6 } # Gottfried + 983.1.1 = { holder = et_besancon_1066_5 } # Guichard + 993.1.1 = { holder = et_besancon_1066_4 } # Leutald + 1002.1.1 = { holder = et_besancon_1066_3 } # Hektor + 1016.1.1 = { holder = et_besancon_1066_2 } # Gauthier + 1031.1.1 = { holder = et_besancon_1066_1 } # Hugues + # 1178 + 1085.1.1 = { holder = et_besancon_1178_9 } # Hugues + 1102.1.1 = { holder = et_besancon_1178_8 } # Ponce + 1108.1.1 = { holder = et_besancon_1178_7 } # Hugues + 1109.1.1 = { holder = et_besancon_1178_6 } # Guillaume + 1117.1.1 = { holder = et_besancon_1178_5 } # Anseric + 1134.1.1 = { holder = et_besancon_1178_4 } # Humbert + 1162.1.1 = { holder = et_besancon_1178_3 } # Gauthier + 1163.1.1 = { holder = et_besancon_1178_2 } # Herbert + 1171.1.1 = { holder = et_besancon_1178_1 } # Eberard +} + +d_et_arles = { # Arles + 412.1.1 = { + holder = et_arles_867_14 # Patrocle + government = ecclesiastical_government + clerical_region = et_867_arles_region + } + 426.1.1 = { holder = et_arles_867_13 } # Hellade + 427.1.1 = { holder = et_arles_867_12 } # Honorat + 430.1.1 = { holder = et_arles_867_11 } # Hilaire + 503.1.1 = { holder = et_arles_867_10 } # Césaire + 542.1.1 = { holder = et_arles_867_9 } # Auxianus + 546.1.1 = { holder = et_arles_867_8 } # Aurélien + 588.1.1 = { holder = et_arles_867_7 } # Virgile + 613.1.1 = { holder = et_arles_867_6 } # Florien + 632.1.1 = { holder = et_arles_867_5 } # Theodose + 659.1.1 = { holder = et_arles_867_4 } # Jean + 811.1.1 = { holder = et_arles_867_3 } # Jean + 824.1.1 = { holder = et_arles_867_2 } # Notho + 852.1.1 = { holder = et_arles_867_1 } # Rotland + # 1066 + 871.1.1 = { holder = et_arles_1066_6 } # Rostang + 920.1.1 = { holder = et_arles_1066_5 } # Manasses + 963.1.1 = { holder = et_arles_1066_4 } # Ithier + 980.1.1 = { holder = et_arles_1066_3 } # Anno + 1005.1.1 = { holder = et_arles_1066_2 } # Pons + 1030.5.1 = { holder = et_arles_1066_1 } # Raimbaud + # 1178 + 1070.1.1 = { holder = et_arles_1178_7 } # Aicard + 1080.1.1 = { holder = et_arles_1178_6 } # Gibelin + 1115.1.1 = { holder = et_arles_1178_5 } # Atton + 1129.8.1 = { holder = et_arles_1178_4 } # Bernard + 1138.1.1 = { holder = et_arles_1178_3 } # Guillaume + 1142.1.1 = { holder = et_arles_1178_2 } # Raimond + 1163.1.1 = { holder = et_arles_1178_1 } # Raimon +} + +d_et_aix = { # Aix + 524.1.1 = { + holder = et_aix_867_8 # Maxime + government = ecclesiastical_government + clerical_region = et_867_aix_region + } + 549.1.1 = { holder = et_aix_867_7 } # Avole + 566.1.1 = { holder = et_aix_867_6 } # Francon + 581.1.1 = { holder = et_aix_867_5 } # Pientius + 596.1.1 = { holder = et_aix_867_4 } # Protais + 794.1.1 = { holder = et_aix_867_3 } # Ignotus + 828.1.1 = { holder = et_aix_867_2 } # Benoît + 867.1.1 = { holder = et_aix_867_1 } # Honorat + # 1066 + 878.1.1 = { holder = et_aix_1066_10 } # Robert + 887.1.1 = { holder = et_aix_1066_9 } # Matfrid + 928.1.1 = { holder = et_aix_1066_8 } # Odolric + 949.1.1 = { holder = et_aix_1066_7 } # Israel + 966.1.1 = { holder = et_aix_1066_6 } # Silvestre + 991.1.1 = { holder = et_aix_1066_5 } # Amalric + 1019.1.1 = { holder = et_aix_1066_4 } # Pons + 1032.1.1 = { holder = et_aix_1066_3 } # Pierre + 1050.1.1 = { holder = et_aix_1066_2 } # Pons + 1056.1.1 = { holder = et_aix_1066_1 } # Rostan + # 1178 + 1082.1.1 = { holder = et_aix_1178_7 } # Pierre + 1101.1.1 = { holder = et_aix_1178_6 } # Pierre + 1115.1.1 = { holder = et_aix_1178_5 } # Fouques + 1132.1.1 = { holder = et_aix_1178_4 } # Pons + 1162.1.1 = { holder = et_aix_1178_3 } # Pierre + 1165.1.1 = { holder = et_aix_1178_2 } # Hugues + 1178.1.1 = { holder = et_aix_1178_1 } # Bertrand +} + +d_et_embrun = { # Embrun + 794.1.1 = { + holder = et_embrun_867_3 # Bernardus + government = ecclesiastical_government + clerical_region = et_867_embrun_region + } + 829.1.1 = { holder = et_embrun_867_2 } # Agéric + 853.1.1 = { holder = et_embrun_867_1 } # Aribert + # 1066 + 876.1.1 = { holder = et_embrun_1066_17 } # Bermond + 878.1.1 = { holder = et_embrun_1066_16 } # Aribert + 886.1.1 = { holder = et_embrun_1066_15 } # Ermold + 890.1.1 = { holder = et_embrun_1066_14 } # Arnaud + 900.1.1 = { holder = et_embrun_1066_13 } # Benoît + 920.1.1 = { holder = et_embrun_1066_12 } # Libéral + 943.1.1 = { holder = et_embrun_1066_11 } # Boso + 970.1.1 = { holder = et_embrun_1066_10 } # Amédée + 992.1.1 = { holder = et_embrun_1066_9 } # Ponce + 1007.1.1 = { holder = et_embrun_1066_8 } # Ismidias + 1016.1.1 = { holder = et_embrun_1066_7 } # Radon + 1033.1.1 = { holder = et_embrun_1066_6 } # Hismidon + 1048.1.1 = { holder = et_embrun_1066_5 } # Vivemne + 1050.1.1 = { holder = et_embrun_1066_4 } # Guinervinaire + 1054.1.1 = { holder = et_embrun_1066_3 } # Hugues + 1055.1.1 = { holder = et_embrun_1066_2 } # Viminien + 1066.1.1 = { holder = et_embrun_1066_1 } # Guillaume + # 1178.1.1 + 1077.1.1 = { holder = et_embrun_1178_7 } # Pierre + 1080.1.1 = { holder = et_embrun_1178_6 } # Lantelme + 1105.1.1 = { holder = et_embrun_1178_5 } # Benoît + 1120.1.1 = { holder = et_embrun_1178_4 } # Guillaume + 1135.1.1 = { holder = et_embrun_1178_3 } # Guillaume + 1170.1.9 = { holder = et_embrun_1178_2 } # Raimond + 1177.1.1 = { holder = et_embrun_1178_1 } # Pierre +} + +# Italy +d_et_milano = { # Milano + 374.1.1 = { + holder = saint_0007 # Ambrose + government = ecclesiastical_government + clerical_region = et_867_milano_region + } + 397.1.1 = { holder = et_milano_867_43 } # Simplician + 400.1.1 = { holder = et_milano_867_42 } # Venerius + 408.1.1 = { holder = et_milano_867_41 } # Marolus + 423.1.1 = { holder = et_milano_867_40 } # Martinianus + 436.1.1 = { holder = et_milano_867_39 } # Glycerius + 438.1.1 = { holder = et_milano_867_38 } # Lazarus + 449.1.1 = { holder = et_milano_867_37 } # Eusebius + 462.1.1 = { holder = et_milano_867_36 } # Gerontius + 465.1.1 = { holder = et_milano_867_35 } # Benignus + 472.1.1 = { holder = et_milano_867_34 } # Senator + 475.1.1 = { holder = et_milano_867_33 } # Theodorus I + 490.1.1 = { holder = et_milano_867_32 } # Lawrence I + 512.1.1 = { holder = et_milano_867_31 } # Eustorgius II + 518.1.1 = { holder = et_milano_867_30 } # Magnus + 530.1.1 = { holder = et_milano_867_29 } # Dacius + 552.1.1 = { holder = et_milano_867_28 } # Vitale + 556.1.1 = { holder = et_milano_867_27 } # Ausanus + 560.1.1 = { holder = et_milano_867_26 } # Honoratus + 571.1.1 = { holder = et_milano_867_25 } # Frontone + 573.1.1 = { holder = et_milano_867_24 } # Lawrence II + 593.1.1 = { holder = et_milano_867_23 } # Constantius + 601.1.1 = { holder = et_milano_867_22 } # Deodatus + 629.1.1 = { holder = et_milano_867_21 } # Asterius + 639.1.1 = { holder = et_milano_867_20 } # Forte + 641.1.1 = { holder = et_milano_867_19 } # John the Good + 669.1.1 = { holder = et_milano_867_18 } # Antoninus + 671.1.1 = { holder = et_milano_867_17 } # Maurilius + 671.1.2 = { holder = et_milano_867_16 } # Ampelius + 676.1.1 = { holder = et_milano_867_15 } # Mansuetus + 685.1.1 = { holder = et_milano_867_14 } # Benedict + 732.1.1 = { holder = et_milano_867_13 } # Theodorus II + 746.1.1 = { holder = et_milano_867_12 } # Natalis + 747.1.1 = { holder = et_milano_867_11 } # Arifred + 748.1.1 = { holder = et_milano_867_10 } # Stabile + 751.1.1 = { holder = et_milano_867_9 } # Leto + 755.1.1 = { holder = et_milano_867_8 } # Tomaso + 783.1.1 = { holder = et_milano_867_7 } # Pietro + 803.1.1 = { holder = et_milano_867_6 } # Odelperto + 813.1.1 = { holder = et_milano_867_5 } # Anselmo I + 818.1.1 = { holder = et_milano_867_4 } # Bono + 822.1.1 = { holder = et_milano_867_3 } # Angilberto I + 824.1.1 = { holder = et_milano_867_2 } # Angilberto II Pusterla + 860.1.1 = { holder = et_milano_867_1 } # Tadone + # 1066 + 868.1.1 = { holder = et_milano_1066_18 } # Ansperto + 882.1.1 = { holder = et_milano_1066_17 } # Anselmo II + 896.1.1 = { holder = et_milano_1066_16 } # Landolfo I + 899.1.1 = { holder = et_milano_1066_15 } # Andrea + 906.1.1 = { holder = et_milano_1066_14 } # Aicone + 918.1.1 = { holder = et_milano_1066_13 } # Garimberto + 921.1.1 = { holder = et_milano_1066_12 } # Lamperto + 931.1.1 = { holder = et_milano_1066_11 } # Ilduino + 936.1.1 = { holder = et_milano_1066_10 } # Arderico + 948.10.15 = { holder = et_milano_1066_9 } # Manasse + 948.12.1 = { holder = et_milano_1066_8 } # Adelmano + 953.1.1 = { holder = et_milano_1066_7 } # Valperto + 970.1.1 = { holder = et_milano_1066_6 } # Arnolfo I + 974.7.27 = { holder = et_milano_1066_5 } # Gotofredo + 979.12.23 = { holder = et_milano_1066_4 } # Landolfo II + 998.5.19 = { holder = cisalpine0658 } # Arnolfo II + 1018.3.16 = { holder = et_milano_1066_2 } # Ariberto + 1045.1.1 = { holder = et_milano_1066_1 } # Guido + # 1178 + 1071.8.23 = { holder = et_milano_1178_13 } # Attone + 1075.1.1 = { holder = et_milano_1178_12 } # Tebaldo + 1086.7.1 = { holder = et_milano_1178_11 } # Anselmo + 1093.12.6 = { holder = et_milano_1178_10 } # Arnolfo + 1097.11.3 = { holder = et_milano_1178_9 } # Anselmo + 1102.1.1 = { holder = et_milano_1178_8 } # Pietro + 1112.1.1 = { holder = et_milano_1178_7 } # Giordano + 1120.11.17 = { holder = et_milano_1178_6 } # Olrico + 1126.6.30 = { holder = et_milano_1178_5 } # Anselmo + 1135.8.2 = { holder = et_milano_1178_4 } # Robaldo + 1146.1.18 = { holder = et_milano_1178_3 } # Umberto + 1166.1.1 = { holder = et_milano_1178_2 } # Galdino + 1176.7.2 = { holder = et_milano_1178_1 } # Algisio + 1178.1.1 = { clerical_region = et_1178_milano_region } +} + +d_et_genoa = { # Genoa + 1133.3.20 = { + holder = et_genoa_1178_2 # Siro + government = ecclesiastical_government + clerical_region = et_1178_genoa_region + } + 1163.10.1 = { holder = et_genoa_1178_1 } # Ugone +} + +d_et_cagliari = { # Cagliari + 484.1.1 = { + holder = et_cagliari_867_9 # Lucifero + government = ecclesiastical_government + clerical_region = et_867_cagliari_region + } + 517.1.1 = { holder = et_cagliari_867_8 } # Gianuario + 591.1.1 = { holder = et_cagliari_867_7 } # Gianuario + 649.1.1 = { holder = et_cagliari_867_6 } # Guistino + 680.1.1 = { holder = et_cagliari_867_5 } # Citonato + 692.1.1 = { holder = et_cagliari_867_4 } # Anonimo + 787.1.1 = { holder = et_cagliari_867_3 } # Tomaso + 847.1.1 = { holder = et_cagliari_867_2 } # Giovanni + 855.1.1 = { holder = et_cagliari_867_1 } # Arsenio + # 1066 + 964.1.1 = { holder = et_cagliari_1066_3 } # Citonato + 1017.1.1 = { holder = et_cagliari_1066_2 } # Umberto + 1066.1.1 = { + holder = et_cagliari_1066_1 # Alfredo + clerical_region = et_1066_cagliari_region + } + # 1178 + 1073.1.1 = { holder = et_cagliari_1178_9 } # Giacomo + 1089.1.1 = { holder = et_cagliari_1178_8 } # Lamberto + 1089.1.2 = { holder = et_cagliari_1178_7 } # Ugo + 1090.1.1 = { holder = et_cagliari_1178_6 } # Benedetto + 1112.1.1 = { holder = et_cagliari_1178_5 } # Gualfredo + 1118.1.1 = { holder = et_cagliari_1178_4 } # Guglielmo + 1126.1.1 = { holder = et_cagliari_1178_3 } # Pietro + 1141.1.1 = { holder = et_cagliari_1178_2 } # Costantino + 1163.1.1 = { holder = et_cagliari_1178_1 } # Bonato + 1178.1.1 = { clerical_region = et_1178_cagliari_region } +} + +d_et_torres = { # Torres + 1073.1.1 = { + holder = et_torres_1178_8 # Costantino + government = ecclesiastical_government + clerical_region = et_1178_torres_region + } + 1120.1.1 = { holder = et_torres_1178_7 } # Vitale + 1127.1.1 = { holder = et_torres_1178_6 } # Costantino + 1133.1.1 = { holder = et_torres_1178_5 } # Attone + 1134.1.1 = { holder = et_torres_1178_4 } # Pietro + 1139.1.1 = { holder = et_torres_1178_3 } # Attone + 1153.1.1 = { holder = et_torres_1178_2 } # Pietro + 1170.1.1 = { holder = et_torres_1178_1 } # Alberto +} + +d_et_oristano = { # Oristano + 1178.1.1 = { + government = ecclesiastical_government + clerical_region = et_1178_oristano_region + } +} + +d_et_reggio_calabria = { # Reggio Calabria + 590.1.1 = { + holder = et_reggio_867_8 # Lucio + government = ecclesiastical_government + clerical_region = et_867_reggio_calabria_region + } + 590.1.2 = { holder = et_reggio_867_7 } # Bonifacio + 604.1.1 = { holder = et_reggio_867_6 } # Cristoforo + 646.1.1 = { holder = et_reggio_867_5 } # Giovanni + 679.1.1 = { holder = et_reggio_867_4 } # Giovanni + 787.1.1 = { holder = et_reggio_867_3 } # Costantino + 800.1.1 = { holder = et_reggio_867_2 } # Ipazio + 821.1.1 = { holder = et_reggio_867_1 } # Giovanni + 840.1.1 = { holder = 0 } + # 1066 + 976.1.1 = { holder = et_reggio_1066_9 } # Teofilatto + 982.1.1 = { holder = et_reggio_1066_8 } # Eusebio + 1001.1.1 = { holder = et_reggio_1066_7 } # Anonimo + 1004.1.1 = { holder = et_reggio_1066_6 } # Nicomede + 1013.1.1 = { holder = et_reggio_1066_5 } # Leone + 1030.1.1 = { holder = et_reggio_1066_4 } # Nicola + 1044.1.1 = { holder = et_reggio_1066_3 } # Stefano + 1052.1.1 = { holder = et_reggio_1066_2 } # Giovanni + 1059.1.1 = { holder = et_reggio_1066_1 } # Basilio + 1066.1.1 = { clerical_region = et_1066_reggio_calabria_region } + # 1178 + 1078.1.1 = { holder = et_reggio_1178_10 } # Arnolfo + 1082.1.1 = { holder = et_reggio_1178_9 } # Guglielmo + 1090.1.1 = { holder = et_reggio_1178_8 } # Bruno + 1092.1.1 = { holder = et_reggio_1178_7 } # Rangier + 1111.1.1 = { holder = et_reggio_1178_6 } # Henricus + 1118.1.1 = { holder = et_reggio_1178_5 } # Rodolfo + 1122.1.1 = { holder = et_reggio_1178_4 } # Bernardo + 1124.1.1 = { holder = et_reggio_1178_3 } # Guglielmo + 1146.1.1 = { holder = et_reggio_1178_2 } # Ruggero + 1170.1.1 = { holder = et_reggio_1178_1 } # Tommaso + 1178.1.1 = { clerical_region = et_1178_reggio_calabria_region } +} + +d_et_cosenza = { # Cosenza + 1177.1.1 = { + holder = et_cosenza_1178_1 # Ruffus + government = ecclesiastical_government + clerical_region = et_1178_cosenza_region + } +} + +d_et_messina = { # Messina + 1166.1.1 = { + holder = et_cosenza_1178_1 # Nicolò + government = ecclesiastical_government + clerical_region = et_1178_messina_region + } +} + +d_et_palermo = { # Palermo + 1065.1.1 = { + holder = et_palermo_1066_1 # Nicodemo + government = ecclesiastical_government + clerical_region = et_1066_palermo_region + } + # 1178 + 1083.1.1 = { holder = et_palermo_1178_8 } # Algherio + 1111.1.1 = { holder = et_palermo_1178_7 } # Gualtiero + 1123.1.1 = { holder = et_palermo_1178_6 } # Pietro + 1141.1.1 = { holder = et_palermo_1178_5 } # Ugo + 1150.1.1 = { holder = et_palermo_1178_4 } # Ugo + 1156.1.1 = { clerical_region = et_1178_palermo_region } + 1161.1.1 = { holder = et_palermo_1178_3 } # Romualdo + 1167.1.1 = { holder = et_palermo_1178_2 } # Stefan + 1169.2.1 = { holder = et_palermo_1178_1 } # Gualtiero +} + +d_et_santa_severina = { # Santa Severina + 895.1.1 = { + holder = et_santa_severina_1066_6 # Giovanni + government = ecclesiastical_government + clerical_region = et_1066_santa_severina_region + } + 970.1.1 = { holder = et_santa_severina_1066_5 } # Stefano + 980.1.1 = { holder = et_santa_severina_1066_4 } # Blattone + 997.1.1 = { holder = et_santa_severina_1066_3 } # Basilio + 1032.1.1 = { holder = et_santa_severina_1066_2 } # Giovanni + 1036.1.1 = { holder = et_santa_severina_1066_1 } # Ambrogio + # 1178 + 1089.1.1 = { holder = et_santa_severina_1178_7 } # Stefano + 1099.1.1 = { holder = et_santa_severina_1178_6 } # Costantino + 1115.1.1 = { holder = et_santa_severina_1178_5 } # Severo + 1118.1.1 = { holder = et_santa_severina_1178_4 } # Gregorio + 1130.1.1 = { holder = et_santa_severina_1178_3 } # Giovanni + 1132.1.1 = { holder = et_santa_severina_1178_2 } # Romano + 1178.1.1 = { holder = et_santa_severina_1178_1 } # Andrea +} + +d_et_ravenna = { # Ravenna + 430.1.1 = { + holder = et_ravenna_867_26 # John + government = ecclesiastical_government + clerical_region = et_867_ravenna_region + } + 477.1.1 = { holder = et_ravenna_867_25 } # John II + 546.1.1 = { holder = et_ravenna_867_24 } # Maximianus + 556.1.1 = { holder = et_ravenna_867_23 } # Agnellus + 569.1.1 = { holder = et_ravenna_867_22 } # Peter III the Elder + 578.1.1 = { holder = et_ravenna_867_21 } # John III + 595.1.1 = { holder = et_ravenna_867_20 } # Mariniano + 607.1.1 = { holder = et_ravenna_867_19 } # John IV + 625.1.1 = { holder = et_ravenna_867_18 } # John V + 631.1.1 = { holder = et_ravenna_867_17 } # Bonus + 644.1.1 = { holder = et_ravenna_867_16 } # Maurus + 671.1.1 = { holder = et_ravenna_867_15 } # Reparatus + 677.1.1 = { holder = et_ravenna_867_14 } # Theodorus + 692.1.1 = { holder = et_ravenna_867_13 } # Damian + 709.1.1 = { holder = et_ravenna_867_12 } # Felix + 726.1.1 = { holder = et_ravenna_867_11 } # John VI + 744.1.1 = { holder = et_ravenna_867_10 } # Sergius + 770.1.1 = { holder = et_ravenna_867_9 } # Leo I + 777.1.1 = { holder = et_ravenna_867_8 } # John VII + 785.1.1 = { holder = et_ravenna_867_7 } # Gratiosus + 789.1.1 = { holder = et_ravenna_867_6 } # Valerius + 810.1.1 = { holder = et_ravenna_867_5 } # Martin + 818.1.1 = { holder = et_ravenna_867_4 } # Petronax + 837.1.1 = { holder = et_ravenna_867_3 } # George + 847.1.1 = { holder = et_ravenna_867_2 } # Deusdedit + 850.1.1 = { holder = et_ravenna_867_1 } # John VIII + # 1066 + 878.1.1 = { holder = et_ravenna_1066_18 } # Romano + 889.1.1 = { holder = et_ravenna_1066_17 } # Deusdedit + 898.1.1 = { holder = et_ravenna_1066_16 } # John IX + 905.1.1 = { holder = 7837 } # Pope John X + 914.3.1 = { holder = et_ravenna_1066_14 } # Constantine + 927.1.1 = { holder = et_ravenna_1066_13 } # Peter IV + 971.1.1 = { holder = et_ravenna_1066_12 } # Onestus + 983.1.1 = { holder = et_ravenna_1066_11 } # Giovanni + 998.1.1 = { holder = 7824 } # Gerbert (Pope Silvester II) + 999.2.18 = { holder = et_ravenna_1066_9 } # Leo II + 1001.1.1 = { holder = et_ravenna_1066_8 } # Federico + 1004.1.1 = { holder = et_ravenna_1066_7 } # Ethelbert + 1014.1.1 = { holder = et_ravenna_1066_6 } # Arnoldo + 1019.1.1 = { holder = et_ravenna_1066_5 } # Eriberto + 1027.1.1 = { holder = et_ravenna_1066_4 } # Gebeardo + 1044.1.1 = { holder = et_ravenna_1066_3 } # Witgero + 1046.1.1 = { holder = et_ravenna_1066_2 } # Hunfredus + 1051.1.1 = { + liege = e_hre + holder = 7740 # Enrico + } + # 1178 + 1072.1.1 = { holder = 73529 } # Riccardo + 1119.1.1 = { holder = 73534 } # Gualtiero + 1144.1.1 = { holder = 73535 } # Mosè + 1155.1.1 = { holder = 73537 } # Anselmo + 1159.1.1 = { holder = 73538 } # Guido + 1169.1.1 = { holder = 73539 } # Gerardo +} + +d_et_roma = { # Roma + 30.1.1 = { + holder = 145292 + government = ecclesiastical_government + clerical_region = et_867_roma_region + } + 64.10.13 = { + holder = 145291 + } + 79.1.1 = { + holder = 7615 + } + 92.1.1 = { + holder = 7614 + } + 99.1.1 = { + holder = 7613 + } + 107.1.1 = { + holder = 7612 + } + 115.1.1 = { + holder = 7611 + } + 125.1.1 = { + holder = 7610 + } + 137.1.1 = { + holder = 7609 + } + 140.1.1 = { + holder = 7608 + } + 154.1.1 = { + holder = 7607 + } + 167.4.20 = { + holder = 7606 + } + 174.1.1 = { + holder = 7605 + } + 189.1.1 = { + holder = 7604 + } + 199.1.1 = { + holder = 7603 + } + 217.12.20 = { + holder = 7602 + } + 222.10.14 = { + holder = 7601 + } + 230.1.1 = { + holder = 7600 + } + 235.9.29 = { + holder = 7799 + } + 236.1.3 = { + holder = 7798 + } + 250.1.20 = { + holder = 7797 + } + 253.6.1 = { + holder = 7796 + } + 254.3.5 = { + holder = 7795 + } + 257.8.2 = { + holder = 7794 + } + 258.8.6 = { + holder = 7793 + } + 268.12.26 = { + holder = 7792 + } + 274.12.30 = { + holder = 7791 + } + 283.7.12 = { + holder = 7790 + } + 296.4.22 = { + holder = 7789 + } + 304.4.1 = { + holder = 7787 + } + 309.1.16 = { + holder = 7786 + } + 310.8.17 = { + holder = 7785 + } + 314.1.10 = { + holder = 7784 + } + 335.12.31 = { + holder = 7783 + } + 336.10.7 = { + holder = 7782 + } + 352.4.12 = { + holder = 7781 + } + 366.9.24 = { + holder = 7780 + } + 384.12.11 = { + holder = 7779 + } + 399.11.26 = { + holder = 7778 + } + 401.11.27 = { + holder = 7777 + } + 417.3.12 = { + holder = 7776 + } + 418.12.26 = { + holder = 7775 + } + 422.9.4 = { + holder = 7774 + } + 432.4.6 = { + holder = 7773 + } + 440.8.18 = { + holder = 7772 + } + 461.11.10 = { + holder = 7771 + } + 468.2.28 = { + holder = 7770 + } + 483.3.10 = { + holder = 7769 + } + 492.1.1 = { + holder = 7768 + } + 496.11.21 = { + holder = 7767 + } + 498.11.19 = { + holder = 7766 + } + 514.7.19 = { + holder = 7765 + } + 523.8.6 = { + holder = 7763 + } + 526.5.18 = { + holder = 7762 + } + 530.1.1 = { + holder = 7761 + } + 532.1.1 = { + holder = 7760 + } + 535.5.13 = { + holder = 7759 + } + 536.6.8 = { + holder = 7764 + } + 537.3.29 = { + holder = 7900 + } + 555.6.7 = { + holder = 7899 + } + 561.3.4 = { + holder = 7898 + } + 574.7.13 = { + holder = 7897 + } + 579.7.20 = { + holder = 7896 + } + 590.1.1 = { + holder = 7893 + } + 604.3.15 = { + holder = 7892 + } + 606.2.22 = { + holder = 7891 + } + 607.11.12 = { + holder = 7890 + } + 615.5.25 = { + holder = 7889 + } + 618.11.8 = { + holder = 7888 + } + 625.10.25 = { + holder = 7887 + } + 638.10.12 = { + holder = 7886 + } + 640.8.2 = { + holder = 7885 + } + 642.10.12 = { + holder = 7884 + } + 649.5.14 = { + holder = 7883 + } + 653.7.17 = { + holder = 7882 + } + 657.6.1 = { + holder = 7881 + } + 672.1.27 = { + holder = 7880 + } + 676.6.17 = { + holder = 7879 + } + 678.4.11 = { + holder = 7878 + } + 681.1.10 = { + holder = 7877 + } + 683.7.3 = { + holder = 7876 + } + 685.5.8 = { + holder = 7875 + } + 686.8.2 = { + holder = 7874 + } + 687.9.21 = { + holder = 7873 + } + 701.9.8 = { + holder = 7872 + } + 705.1.11 = { + holder = 7871 + } + 707.10.18 = { + holder = 7870 + } + 708.2.4 = { + holder = 7869 + } + 715.4.9 = { + holder = 7868 + } + 731.2.11 = { + holder = 7867 + } + 741.11.28 = { + holder = 7866 + } + 752.3.22 = { + holder = 7895 + } + 757.4.29 = { + holder = 7865 + } + 767.6.28 = { + holder = 7864 + } + 772.1.24 = { + holder = 7863 + } + 795.12.25 = { + holder = 7862 + } + 816.6.12 = { + holder = 7861 + } + 817.1.24 = { + holder = 7860 + } + 824.2.11 = { + holder = 7859 + } + 827.8.27 = { + holder = 7858 + } + 827.9.16 = { + holder = 7857 + } + 844.1.11 = { + holder = 7856 + } + 847.1.24 = { + holder = 7855 + } + 855.7.17 = { + holder = 7854 + } + 858.4.17 = { + holder = 7853 # Nicolaus + } + 867.11.13 = { + holder = 7852 + } + 872.12.14 = { + holder = 7851 + } + 882.12.16 = { + holder = 7850 + } + 884.5.15 = { + holder = 7849 + } + 885.9.1 = { + holder = 7848 + } + 891.9.14 = { + holder = 7847 + } + 896.4.4 = { + holder = 7846 + } + 896.5.1 = { + holder = 7845 + } + 897.8.1 = { + holder = 7844 + } + 897.11.1 = { + holder = 7843 + } + 897.12.1 = { + holder = 7842 + } + 900.1.1 = { + holder = 7841 + } + 903.7.1 = { + holder = 7840 + } + 903.9.1 = { + holder = 7916 + } + 911.4.14 = { + holder = 7839 + } + 913.7.1 = { + holder = 7838 + } + 914.3.1 = { + holder = 7837 + } + 928.5.1 = { + holder = 7836 + } + 929.1.1 = { + holder = 7835 + } + 931.3.15 = { + holder = 7917 + } + 935.12.20 = { + holder = 7834 + } + 939.7.13 = { + holder = 7833 + } + 942.10.1 = { + holder = 7832 + } + 946.5.1 = { + holder = 7831 + } + 955.12.16 = { + holder = 7931 + } + 964.5.14 = { + holder = 7830 + } + 964.6.23 = { + holder = 7829 + } + 965.3.1 = { + holder = 7828 + } + 972.9.6 = { + holder = 7827 + } + 974.7.1 = { + holder = 7930 + } + 983.7.10 = { + holder = 7826 + } + 984.8.20 = { + holder = 7825 + } + 996.5.3 = { + holder = 1318 + } + 999.2.18 = { + holder = 7824 + } + 1003.5.12 = { + holder = 7823 + } + 1003.12.6 = { + holder = 7822 + } + 1009.7.1 = { + holder = 7821 + } + 1012.5.12 = { + holder = 7933 + } + 1024.8.9 = { + holder = 7934 + } + 1032.10.1 = { + holder = 7937 + } + 1045.1.20 = { + holder = 7820 + } + 1045.3.10 = { + holder = 7937 + } + 1045.5.1 = { + holder = 7819 + } + 1046.12.20 = { + holder = 7818 + } + 1047.10.9 = { + holder = 7937 + } + 1048.7.17 = { + holder = 7817 + } + 1048.8.9 = { + holder = 1338 + } + 1054.4.19 = { + holder = 7894 + } + 1057.8.3 = { + holder = 11034 + } + 1058.3.29 = { + holder = 7940 + } + 1061.7.27 = { + holder = 2008 + } + 1066.1.1 = { clerical_region = et_1066_roma_region } + 1073.4.21 = { + holder = 2010 + } + 1085.5.25 = { + holder = 2012 + } + 1087.9.16 = { + holder = 2013 + } + 1095.1.1 = { + } + 1099.1.1 = { + } + 1099.7.29 = { + holder = 2014 + } + 1118.1.21 = { + holder = 2017 + } + 1119.1.28 = { + holder = 294 + } + 1124.12.13 = { + holder = 2021 + } + 1130.2.13 = { + holder = 71800 + } + 1143.9.24 = { + holder = 71805 + } + 1144.3.8 = { + holder = 71806 + } + 1145.2.15 = { + holder = 71807 + } + 1153.7.8 = { + holder = 71808 + } + 1154.12.3 = { + holder = 71809 + } + 1159.9.1 = { + holder = 71810 + } + 1178.1.1 = { clerical_region = et_1178_roma_region } + 1181.8.30 = { + holder = 71811 + } + 1185.5.25 = { + holder = 223754 + } + 1187.10.20 = { + holder = 71812 + } + 1187.12.17 = { + holder = 71813 + } + 1191.3.20 = { + holder = 70841 + } + 1198.1.8 = { + holder = 71814 + } + 1216.7.16 = { + holder = 71820 + } + 1227.3.18 = { + holder = 71821 + } + 1241.8.22 = { + holder = 71822 + } + 1241.11.10 = { + holder = 71823 + } + 1254.12.7 = { + holder = 71824 + } + 1261.5.25 = { + holder = 71825 + } + 1264.10.2 = { + holder = 71826 + } + 1268.11.29 = { + holder = 70785 + } + 1276.1.10 = { + holder = 71827 + } + 1276.6.22 = { + holder = 71829 + } + 1276.8.18 = { + holder = 71830 + } + 1277.5.20 = { + holder = 70851 + } + 1280.8.22 = { + holder = 71831 + } + 1285.3.28 = { + holder = 71832 + } + 1287.4.3 = { + holder = 71833 + } + 1292.4.4 = { + holder = 71834 + } + 1294.12.13 = { + holder = 71835 + } + 1303.10.11 = { + holder = 71836 + } + 1304.7.7 = { + holder = 71837 + } + 1314.4.20 = { + holder = 71838 + } + 1334.12.20 = { + holder = 478501 + } +} + +d_et_pisa = { # Pisa + 1092.4.21 = { + holder = et_pisa_1178_8 # Dagoberto + government = ecclesiastical_government + clerical_region = et_1178_pisa_region + } + 1104.12.1 = { holder = et_pisa_1178_7 } # Pietro + 1119.1.1 = { holder = et_pisa_1178_6 } # Azzone + 1123.3.24 = { holder = et_pisa_1178_5 } # Rogerio + 1132.1.1 = { holder = et_pisa_1178_4 } # Uberto + 1137.1.1 = { holder = et_pisa_1178_3 } # Balduino + 1146.5.29 = { holder = et_pisa_1178_2 } # Villano + 1176.4.1 = { holder = et_pisa_1178_1 } # Ubaldo +} + +d_et_capua = { # Capua + 966.1.1 = { + holder = et_capua_1066_9 # Giovanni + government = ecclesiastical_government + clerical_region = et_1066_capua_region + } + 974.1.1 = { holder = et_capua_1066_8 } # Leone + 978.1.1 = { holder = et_capua_1066_7 } # Gerberto + 981.1.1 = { holder = et_capua_1066_6 } # Atenolfo + 993.1.1 = { holder = et_capua_1066_5 } # Aione + 993.2.1 = { holder = et_capua_1066_4 } # Isembardo + 1007.1.1 = { holder = et_capua_1066_3 } # Pandolfo + 1022.1.1 = { holder = et_capua_1066_2 } # Atenolfo + 1066.1.1 = { holder = et_capua_1066_1 } # Ildebrando + # 1178 + 1078.1.1 = { holder = et_capua_1178_9 } # Erveo + 1088.1.1 = { holder = et_capua_1178_8 } # Roberto + 1098.1.1 = { holder = et_capua_1178_7 } # Senne + 1118.1.1 = { holder = et_capua_1178_6 } # Ottone + 1129.1.1 = { holder = et_capua_1178_5 } # Filippo + 1129.1.1 = { holder = et_capua_1178_4 } # Ugone + 1135.1.1 = { holder = et_capua_1178_3 } # Gugliemo + 1137.1.1 = { holder = et_capua_1178_2 } # Goffredo + 1157.1.1 = { holder = et_capua_1178_1 } # Alfano +} + +d_et_napoli = { # Napoli + 1005.1.1 = { + holder = et_napoli_1066_5 # Sergio + government = ecclesiastical_government + clerical_region = et_1066_napoli_region + } + 1033.1.1 = { holder = et_napoli_1066_4 } # Giovanni + 1045.1.1 = { holder = et_napoli_1066_3 } # Vittore + 1059.1.1 = { holder = et_napoli_1066_2 } # Sergio + 1065.1.1 = { holder = et_napoli_1066_1 } # Giovanni + # 1178 + 1094.1.1 = { holder = et_napoli_1178_4 } # Pietro + 1116.1.1 = { holder = et_napoli_1178_3 } # Gregorio + 1118.1.1 = { holder = et_napoli_1178_2 } # Marino + 1168.1.1 = { holder = et_napoli_1178_1 } # Sergio +} + +d_et_salerno = { # Salerno + 983.1.1 = { + holder = et_salerno_1066_9 # Amato + government = ecclesiastical_government + clerical_region = et_1066_salerno_region + } + 993.1.1 = { holder = et_salerno_1066_8 } # Dauferio + 994.1.1 = { holder = et_salerno_1066_7 } # Grimoaldo + 1012.1.1 = { holder = et_salerno_1066_6 } # Michele + 1016.1.1 = { holder = et_salerno_1066_5 } # Benedetto + 1019.12.27 = { holder = et_salerno_1066_4 } # Amato + 1032.3.1 = { holder = et_salerno_1066_3 } # Amato + 1047.2.18 = { holder = et_salerno_1066_2 } # Giovanni + 1058.3.15 = { holder = et_salerno_1066_1 } # Alfano + # 1178 + 1085.1.1 = { holder = et_salerno_1178_4 } # Alfano + 1121.9.15 = { holder = et_salerno_1178_3 } # Romualdo + 1130.12.25 = { liege = k_sicily } + 1137.1.1 = { holder = et_salerno_1178_2 } # Guglielmo + 1153.1.1 = { holder = guarna_8 } # Romualdo +} + +d_et_benevento = { # Benevento + 969.5.26 = { + holder = et_benevento_1066_6 # Landolfo + government = ecclesiastical_government + clerical_region = et_1066_benevento_region + } + 983.1.1 = { holder = et_benevento_1066_5 } # Alone + 985.1.1 = { holder = et_benevento_1066_4 } # Alfano + 1001.1.1 = { holder = et_benevento_1066_3 } # Alfano + 1045.1.1 = { holder = et_benevento_1066_2 } # Maldefrido + 1053.1.1 = { holder = et_benevento_1066_1 } # Ouldarico + # 1178.1.1 + 1074.1.1 = { holder = et_benevento_1178_11 } # Milone + 1076.1.1 = { holder = et_benevento_1178_10 } # Roffredo + 1108.1.1 = { holder = et_benevento_1178_9 } # Landolfo + 1108.11.8 = { holder = et_benevento_1178_8 } # Landolfo + 1120.1.1 = { holder = et_benevento_1178_7 } # Roffredo + 1130.1.1 = { holder = et_benevento_1178_6 } # Landolfo + 1132.1.1 = { holder = et_benevento_1178_5 } # Gregorio + 1145.1.1 = { holder = et_benevento_1178_4 } # Roseola + 1146.1.1 = { holder = et_benevento_1178_3 } # Pietro + 1156.1.1 = { holder = et_benevento_1178_2 } # Enrico + 1171.1.1 = { holder = et_benevento_1178_1 } # Lombardo +} + +d_et_bari = { # Bari + 530.1.1 = { + holder = et_bari_867_15 # Pietro I + government = ecclesiastical_government + clerical_region = et_867_bari_region + } + 596.1.1 = { holder = et_bari_867_14 } # Marco + 610.1.1 = { holder = et_bari_867_13 } # Giulio + 634.1.1 = { holder = et_bari_867_12 } # Stefano + 653.1.1 = { holder = et_bari_867_11 } # Ursone + 681.1.1 = { holder = et_bari_867_10 } # Trasmondo + 688.1.1 = { holder = et_bari_867_9 } # Rodecauto + 694.1.1 = { holder = et_bari_867_8 } # Bursa + 753.1.1 = { holder = et_bari_867_7 } # Maurenziano + 759.1.1 = { holder = et_bari_867_6 } # Andrea + 762.1.1 = { holder = et_bari_867_5 } # Rodoaldo I + 781.1.1 = { holder = et_bari_867_4 } # Leone + 821.1.1 = { holder = et_bari_867_3 } # Sebastiano + 828.1.1 = { holder = et_bari_867_2 } # Giacomo + 843.1.1 = { holder = et_bari_867_1 } # Rodoaldo II + 855.1.1 = { holder = et_bari_867_0 } # Angelario + # 1066 + 877.1.1 = { holder = et_bari_1066_15 } # Domenico + 892.1.1 = { holder = et_bari_1066_14 } # Giovanni + 906.1.1 = { holder = et_bari_1066_13 } # Guitpardo + 912.1.1 = { holder = et_bari_1066_12 } # Rodrigo + 920.1.1 = { holder = et_bari_1066_11 } # Giovanni + 924.1.1 = { holder = et_bari_1066_10 } # Alsario + 931.1.1 = { holder = et_bari_1066_9 } # Pietro + 952.1.1 = { holder = et_bari_1066_8 } # Giovanni + 978.1.1 = { holder = et_bari_1066_7 } # Paolo + 988.1.1 = { holder = et_bari_1066_6 } # Crisostomo + 1006.1.1 = { holder = et_bari_1066_5 } # Giovanni + 1025.1.1 = { holder = et_bari_1066_4 } # Bisanzio + 1035.1.1 = { holder = et_bari_1066_3 } # Romoaldo + 1035.2.1 = { holder = et_bari_1066_2 } # Nicola + 1062.1.1 = { holder = et_bari_1066_1 } # Andrea + 1066.1.1 = { clerical_region = et_1066_bari_region } + # 1178 + 1078.6.1 = { holder = et_bari_1178_10 } # Ursone + 1089.2.1 = { holder = et_bari_1178_9 } # Elia + 1101.8.7 = { holder = et_bari_1178_8 } # Elia + 1112.4.2 = { holder = et_bari_1178_7 } # Riso + 1118.1.1 = { holder = et_bari_1178_6 } # Gualtieri + 1126.1.1 = { holder = et_bari_1178_5 } # Matteo + 1128.1.1 = { holder = et_bari_1178_4 } # Angelo + 1137.1.1 = { holder = et_bari_1178_3 } # Giovanni + 1151.1.1 = { holder = et_bari_1178_2 } # Giovanni + 1171.1.1 = { holder = et_bari_1178_1 } # Rainaldo +} + +d_et_trani = { # Trani + 1063.1.1 = { + holder = et_trani_1066_1 + government = ecclesiastical_government + clerical_region = et_1066_trani_region + } + # 1178 + 1129.1.1 = { holder = et_trani_1178_4 } # Veterandus + 1130.1.1 = { holder = et_trani_1178_3 } # Hubaldus + 1150.1.1 = { holder = et_trani_1178_2 } # Bisantius + 1157.1.1 = { holder = et_trani_1178_1 } # Bertrandus +} + +d_et_brindisi = { # Brindisi + 996.1.1 = { + holder = et_brindisi_1066_3 # Giovanni + government = ecclesiastical_government + clerical_region = et_1066_brindisi_region + } + 1040.1.1 = { holder = et_brindisi_1066_2 } # Nardo + 1050.1.1 = { holder = et_brindisi_1066_1 } # Eustachio + # 1178 + 1074.1.1 = { holder = et_brindisi_1178_8 } # Gregorio + 1085.1.1 = { holder = et_brindisi_1178_7 } # Godino + 1100.1.1 = { holder = et_brindisi_1178_6 } # Badovino + 1101.1.1 = { holder = et_brindisi_1178_5 } # Nicola + 1105.1.1 = { holder = et_brindisi_1178_4 } # Guglielmo + 1122.2.22 = { holder = et_brindisi_1178_3 } # Baialardo + 1144.1.1 = { holder = et_brindisi_1178_2 } # Lupo + 1173.1.1 = { holder = et_brindisi_1178_1 } # Guglielmo + +} + +d_et_aquileia = { # Aquileia + 369.1.1 = { + holder = et_aquileia_867_34 # Valerianus + government = ecclesiastical_government + clerical_region = et_867_aquileia_region + } + 388.1.1 = { holder = et_aquileia_867_33 } # Chromatius + 407.1.1 = { holder = et_aquileia_867_32 } # Augustinus + 434.1.1 = { holder = et_aquileia_867_31 } # Adelphus + 442.1.1 = { holder = et_aquileia_867_30 } # Maximus I + 444.1.1 = { holder = et_aquileia_867_29 } # Januarius + 451.1.1 = { holder = et_aquileia_867_28 } # Secundus + 454.1.1 = { holder = et_aquileia_867_27 } # Nicetas + 485.1.1 = { holder = et_aquileia_867_26 } # Marcellianus + 500.1.1 = { holder = et_aquileia_867_25 } # Marcellinus + 515.1.1 = { holder = et_aquileia_867_24 } # Stephen I + 534.1.1 = { holder = et_aquileia_867_23 } # Laurentius + 539.1.1 = { holder = et_aquileia_867_22 } # Macedonius + 557.1.1 = { holder = et_aquileia_867_21 } # Paulinus I + 569.1.1 = { + liege = k_italy + holder = et_aquileia_867_20 # Probinus + } + 571.1.1 = { holder = et_aquileia_867_19 } # Elia + 586.1.1 = { holder = et_aquileia_867_18 } # Severus + 606.1.1 = { holder = et_aquileia_867_17 } # John I + 623.1.1 = { holder = et_aquileia_867_16 } # Marcianus + 628.1.1 = { holder = et_aquileia_867_15 } # Fortunatus + 649.1.1 = { holder = et_aquileia_867_14 } # Felix + 663.1.1 = { holder = et_aquileia_867_13 } # John II + 679.1.1 = { holder = et_aquileia_867_12 } # Agathon + 680.1.1 = { holder = et_aquileia_867_11 } # John III + 698.1.1 = { holder = et_aquileia_867_10 } # Petrus I + 711.1.1 = { holder = et_aquileia_867_9 } # Serenus + 726.1.1 = { holder = et_aquileia_867_8 } # Calixtus + 772.1.1 = { holder = et_aquileia_867_7 } # Siguald + 776.1.1 = { holder = et_aquileia_867_6 } # Paulinus II + 802.1.1 = { holder = et_aquileia_867_5 } # Ursus I + 811.1.1 = { holder = et_aquileia_867_4 } # Maxentius + 834.1.1 = { holder = et_aquileia_867_3 } # Andreas + 850.1.1 = { holder = et_aquileia_867_2 } # Venantius + 855.1.1 = { holder = 167804 } # Lupus I + # 1066 + 875.1.1 = { holder = et_aquileia_1066_12 } # Valpert + 901.1.1 = { holder = et_aquileia_1066_11 } # Frederick I + 922.1.1 = { holder = et_aquileia_1066_10 } # Leo + 928.1.1 = { holder = et_aquileia_1066_9 } # Ursus II + 932.1.1 = { holder = et_aquileia_1066_8 } # Lupus II + 944.1.1 = { holder = et_aquileia_1066_7 } # Engelfred + 963.1.1 = { holder = et_aquileia_1066_6 } # Rodoald + 984.1.1 = { holder = et_aquileia_1066_5 } # John IV + 1019.1.1 = { holder = et_aquileia_1066_4 } # Poppo + 1045.1.1 = { holder = et_aquileia_1066_3 } # Eberhard + 1049.1.1 = { holder = et_aquileia_1066_2 } # Gotebald + 1063.1.1 = { + liege = e_hre + holder = 7700 # Ravengerius + } + # 1178 + 1068.1.1 = { holder = 70825 } # Sieghard + 1077.8.12 = { holder = 70826 } # Heinrich + 1084.3.28 = { holder = 534 } # Federico + 1086.2.23 = { holder = 70827 } # Ulrich + 1121.1.1 = { holder = 70828 } # Gerardo + 1144.1.1 = { holder = 70829 } # Pilgrim + 1161.1.1 = { holder = 70830 } # Ulrich +} + +d_et_esztergom = { # Esztergom + 1000.1.1 = { + holder = et_esztergom_1066_7 # Dominic + government = ecclesiastical_government + clerical_region = et_1066_esztergom_region + } + 1001.1.1 = { holder = et_esztergom_1066_6 } # Sebestyén + 1002.1.1 = { holder = et_esztergom_1066_5 } # Radia + 1007.1.1 = { holder = et_esztergom_1066_4 } # Anastaz-Astrik + 1012.1.1 = { holder = et_esztergom_1066_3 } # Sebestyén + 1046.1.1 = { holder = et_esztergom_1066_2 } # Benedict + 1055.1.1 = { holder = 0 } # vacancy + # 1178 + 1067.1.1 = { + liege = k_hungary + holder = et_esztergom_1178_12 # Dezső + } + 1075.1.1 = { holder = et_esztergom_1178_11 } # Nehemiás + 1093.1.1 = { holder = et_esztergom_1178_10 } # István + 1094.1.1 = { holder = et_esztergom_1178_9 } # Acha + 1095.1.1 = { holder = et_esztergom_1178_8 } # Szerafin + 1105.1.1 = { holder = et_esztergom_1178_7 } # Lőrinc + 1119.1.1 = { holder = et_esztergom_1178_6 } # Marcello + 1127.1.1 = { holder = et_esztergom_1178_5 } # Felicián + 1142.1.1 = { holder = et_esztergom_1178_4 } # Makár + 1146.1.1 = { holder = et_esztergom_1178_3 } # Kökényes + 1151.1.1 = { holder = et_esztergom_1178_2 } # Martyrius + 1161.1.1 = { holder = esztergom_archbishop_1 } # Lukács + 1178.1.1 = { clerical_region = et_1178_esztergom_region } +} + +d_et_kalocsa = { # Kalocsa + 1135.1.1 = { + holder = et_kalocsa_1178_6 # Simon + government = ecclesiastical_government + clerical_region = et_1178_kalocsa_region + } + 1142.1.1 = { holder = et_kalocsa_1178_5 } # Muchia + 1149.1.1 = { holder = et_kalocsa_1178_4 } # Miko + 1167.1.1 = { holder = et_kalocsa_1178_3 } # Sayna + 1169.1.1 = { holder = et_kalocsa_1178_2 } # Kosma + 1176.1.1 = { holder = et_kalocsa_1178_1 } # Endre +} + +d_et_split = { # Split + 500.1.1 = { + government = ecclesiastical_government + clerical_region = et_867_split_region + } + # 867 + 840.1.1 = { holder = et_split_867_2 } # Petar + 860.1.1 = { holder = et_split_867_1 } # Justin + # 1066 + 876.1.1 = { holder = et_split_1066_13 } # Ivan + 881.1.1 = { holder = et_split_1066_12 } # Marino + 887.1.1 = { holder = et_split_1066_11 } # Teodozije + 893.1.1 = { holder = et_split_1066_10 } # Petar + 914.1.1 = { holder = et_split_1066_9 } # Ivan + 928.1.1 = { holder = et_split_1066_8 } # Januarije + 940.1.1 = { holder = et_split_1066_7 } # Frontinijan + 970.1.1 = { holder = et_split_1066_6 } # Martin + 1000.1.1 = { holder = et_split_1066_5 } # Pavao + 1030.1.1 = { holder = et_split_1066_4 } # Martin + 1030.2.1 = { holder = et_split_1066_3 } # Dobralj + 1050.1.1 = { holder = et_split_1066_2 } # Ivan + 1059.1.1 = { holder = et_split_1066_1 } # Lovro + # 1178 + 1110.1.1 = { holder = et_split_1178_9 } # Krescencij + 1112.1.1 = { holder = et_split_1178_8 } # Manasses + 1135.1.1 = { holder = et_split_1178_7 } # Grgur + 1136.1.1 = { holder = et_split_1178_6 } # Gandino + 1159.1.1 = { holder = et_split_1178_5 } # Absalom + 1161.7.2 = { holder = et_split_1178_4 } # Petar + 1166.1.1 = { holder = et_split_1178_3 } # Albert + 1167.1.1 = { holder = et_split_1178_2 } # Gerardo + 1175.1.1 = { holder = et_split_1178_1 } # Ranieri + 1178.1.1 = { clerical_region = et_1178_split_region } +} + +d_et_ohrid = { # Ohrid + 1018.1.1 = { + holder = et_ohrid_1066_4 + government = ecclesiastical_government + clerical_region = et_1066_ohrid_region + } + 1037.1.1 = { holder = et_ohrid_1066_3 } # Leon + 1056.1.1 = { holder = et_ohrid_1066_2 } # Theodulus + 1065.1.1 = { holder = et_ohrid_1066_1 } # Ioannes + # 1178 + 1078.1.1 = { holder = et_ohrid_1178_6 } # Ioannes + 1079.1.1 = { holder = et_ohrid_1178_5 } # Theophylact + 1108.1.1 = { holder = et_ohrid_1178_4 } # Leon + 1120.1.1 = { holder = et_ohrid_1178_3 } # Michael + 1141.1.1 = { holder = et_ohrid_1178_2 } # Ioannes + 1160.1.1 = { holder = et_ohrid_1178_1 } # Constantine +} + +d_et_ragusa = { # Ragusa + 1120.1.1 = { + holder = et_ragusa_1178_3 # Geraldo + government = ecclesiastical_government + clerical_region = et_1178_ragusa_region + } + 1142.1.1 = { holder = et_ragusa_1178_2 } # Andrea + 1153.1.1 = { holder = et_ragusa_1178_1 } # Tribunio + 1178.1.1 = { + government = ecclesiastical_government + } +} + +# Germany +d_et_salzburg = { # Salzburg + 785.1.1 = { + liege = k_east_francia + holder = et_salzburg_867_4 # Arno + government = ecclesiastical_government + clerical_region = et_867_salzburg_region + } + 821.1.1 = { holder = et_salzburg_867_3 } # Adalram + 836.1.1 = { holder = et_salzburg_867_2 } # Liupram + 859.1.1 = { holder = 163056 } # Adalwin + # 1066 + 873.5.14 = { holder = et_salzburg_1066_12 } # Adalbert + 874.7.30 = { holder = et_salzburg_1066_11 } # Dietmar + 907.7.4 = { holder = et_salzburg_1066_10 } # Pilgrim + 923.1.1 = { holder = et_salzburg_1066_9 } # Adalbert + 935.1.1 = { holder = et_salzburg_1066_8 } # Egilholf + 939.1.1 = { holder = 168305 } # Herhold + 958.1.1 = { holder = et_salzburg_1066_6 } # Friedrich + 991.1.1 = { holder = hartwiger_4 } # Hartwig + 1023.1.1 = { holder = et_salzburg_1066_4 } # Günther + 1025.1.1 = { holder = et_salzburg_1066_3 } # Dietmar + 1041.1.1 = { holder = et_salzburg_1066_2 } # Baldwin + 1060.1.1 = { holder = 20259 } # Gebhard + 1066.1.1 = { liege = e_hre } + # 1178 + 1090.1.1 = { holder = 33410 } # Thiemo + 1101.9.28 = { holder = 93833 } # Konrad + 1147.4.9 = { holder = 93834 } # Eberhard + 1164.6.22 = { holder = 144190 } # Konrad + 1168.11.1 = { holder = 212858 } # Vojtěch + 1177.8.9 = { + holder = 7557 # Konrad + liege = e_hre + } +} + +d_et_trier = { # Trier + 791.1.1 = { + holder = et_trier_867_5 # Richbod + government = ecclesiastical_government + clerical_region = et_867_trier_region + liege = k_lotharingia + } + 804.10.1 = { holder = et_trier_867_4 } # Waso + 809.1.1 = { holder = et_trier_867_3 } # Amalhar + 814.1.1 = { holder = et_trier_867_2 } # Hetto + 847.1.1 = { holder = et_trier_867_1 } # Theutgaud + # 1066 + 869.1.1 = { holder = 163051 } # Bertolf + 883.2.10 = { holder = et_trier_1066_12 } # Radbod + 915.1.1 = { holder = et_trier_1066_11 } # Rudgar + 930.1.1 = { holder = et_trier_1066_10 } # Rotbert + 956.1.1 = { holder = et_trier_1066_9 } # Heinrich + 965.1.1 = { holder = et_trier_1066_8 } # Dietrich + 977.1.1 = { holder = et_trier_1066_7 } # Egbert + 994.1.1 = { holder = et_trier_1066_6 } # Ludolf + 1008.1.1 = { holder = et_trier_1066_5 } # Adalbero + 1016.1.1 = { holder = 183189 } # Poppo + 1047.6.16 = { holder = et_trier_1066_3 } # Eberhard + 1066.1.1 = { holder = et_trier_1066_2 } # Kuno + 1066.2.1 = { + liege = e_hre + holder = 33109 # Udo + } + # 1178 + 1078.11.1 = { holder = 33112 } # Egilbert + 1101.1.1 = { holder = 33113 } # Bruno + 1124.4.25 = { holder = 33112 } # Gottfried + 1127.1.1 = { holder = 33113 } # Meginher + 1130.10.1 = { holder = 33114 } # Adelbero + 1152.1.18 = { holder = 33115 } # Hillin + 1169.10.23 = { holder = 33116 } # Arnold + +} + +d_et_gniezno = { # Gniezno + 999.1.1 = { + holder = et_gniezno_1066_5 # Radzym + government = ecclesiastical_government + clerical_region = et_1066_gniezno_region + } + 1006.1.1 = { holder = et_gniezno_1066_4 } # Hipolit + 1025.4.18 = { liege = k_poland } + 1027.1.1 = { holder = et_gniezno_1066_3 } # Bossuta + 1039.1.1 = { holder = et_gniezno_1066_2 } # Stefan + 1059.1.1 = { holder = et_gniezno_1066_1 } # Piotr I + # 1178 + 1092.1.1 = { holder = 96075 } # Marcin + 1112.1.1 = { holder = 302014 } # Heinrich + 1119.1.1 = { holder = 96076 } # Jakub + 1149.1.1 = { holder = 96077 } # Janik + 1167.1.1 = { holder = et_gniezno_1178_2 } # Bogumił + 1170.1.1 = { holder = 302015 } # Zdzislaw + 1178.1.1 = { + clerical_region = et_1178_gniezno_region + } +} + +d_et_mainz = { # Mainz + 745.1.1 = { + liege = k_east_francia + holder = walpurga_6 # Saint Boniface + government = ecclesiastical_government + clerical_region = et_867_mainz_region + } + 754.6.5 = { holder = 190565 } # Lullus + 787.1.1 = { holder = et_mainz_867_6 } # Richholf + 813.1.1 = { holder = et_mainz_867_5 } # Adolf + 826.1.1 = { holder = et_mainz_867_4 } # Odgar + 848.1.1 = { holder = et_mainz_867_3 } # Maurus + 856.2.4 = { holder = 90098 } # Karl + 863.11.30 = { holder = 168593 } # Liutbert + # 1066 + 889.2.17 = { holder = et_mainz_1066_14 } # Sunderhold + 891.1.1 = { holder = et_mainz_1066_13 } # Hatto + 913.1.1 = { holder = et_mainz_1066_12 } # Herigar + 927.1.1 = { holder = et_mainz_1066_11 } # Hildebert + 937.1.1 = { holder = 163046 } # Frederick + 954.10.1 = { holder = 163047 } # William + 968.3.2 = { holder = et_mainz_1066_8 } # Hatto + 970.1.1 = { holder = et_mainz_1066_7 } # Rudbrecht + 975.1.1 = { holder = et_mainz_1066_6 } # Willigis + 1011.1.1 = { holder = et_mainz_1066_5 } # Erkanbald + 1021.1.1 = { holder = aribonen_5 } # Aribo + 1031.4.6 = { holder = et_mainz_1066_3 } # Bardo + 1051.1.1 = { holder = 163048 } # Luitpold + 1060.1.1 = { holder = 20256 } # Siegfried + 1066.1.1 = { + liege = e_hre + clerical_region = et_1066_mainz_region + } + # 1178 + 1084.2.16 = { holder = 7530 } # Wezilo + 1088.1.1 = { holder = 7531 } # Ruthard + 1109.1.1 = { holder = 7532 } # Adelbert + 1137.1.1 = { holder = 7533 } # Adelbert + 1141.1.1 = { holder = 7534 } # Markholf + 1142.1.1 = { holder = 7535 } # Henrich + 1153.1.1 = { holder = 7536 } # Arnold + 1160.6.24 = { holder = 7537 } # Christian + 1161.6.20 = { holder = 7557 } # Konrad + 1165.1.1 = { holder = 7537 } # Christian + 1178.1.1 = { + clerical_region = et_1178_mainz_region + } +} + +d_et_magdeburg = { # Magdeburg + 968.10.1 = { + holder = et_magdeburg_1066_8 # Adalberto + government = ecclesiastical_government + clerical_region = et_1066_magdeburg_region + } + 981.6.21 = { holder = et_magdeburg_1066_7 } # Giselher + 1004.2.4 = { holder = et_magdeburg_1066_6 } # Tagino + 1012.6.15 = { holder = et_magdeburg_1066_5 } # Waltaro + 1012.9.22 = { holder = et_magdeburg_1066_4 } # Gero + 1023.10.22 = { holder = et_magdeburg_1066_3 } # Humfrid + 1052.1.1 = { holder = et_magdeburg_1066_2 } # Engelhard + 1063.9.1 = { holder = 20263 } # Werner + 1066.1.1 = { liege = e_hre } + # 1178 + 1079.8.7 = { holder = 30238 } # Hartwig + 1102.6.1 = { holder = et_magdeburg_1178_7 } # Heinrich + 1107.5.1 = { holder = et_magdeburg_1178_6 } # Adalgod + 1119.1.1 = { holder = et_magdeburg_1178_5 } # Rudigar + 1126.7.18 = { holder = et_magdeburg_1178_4 } # Norbert + 1134.7.1 = { holder = et_magdeburg_1178_3 } # Konrad + 1142.5.7 = { holder = et_magdeburg_1178_2 } # Friedrich + 1152.11.1 = { + holder = 144205 # Wichmann + clerical_region = et_1178_magdeburg_region + } +} + +d_et_cologne = { # Cologne + 784.1.1 = { + liege = k_lotharingia + holder = et_cologne_867_6 # Hildebold + government = ecclesiastical_government + clerical_region = et_867_cologne_region + } + 818.1.1 = { holder = et_cologne_867_5 } # Hadbold + 842.1.1 = { holder = et_cologne_867_4 } # Hildwin + 850.1.1 = { holder = et_cologne_867_3 } # Günther + 864.1.1 = { holder = et_cologne_867_2 } # Hugo + 867.1.1 = { holder = 163052 } # Wilibert + # 1066 + 890.1.1 = { holder = et_cologne_1066_11 } # Hermann + 924.4.11 = { holder = 161539 } # Wigfried + 953.7.9 = { holder = 1290 } # Bruno + 965.1.1 = { holder = et_cologne_1066_8 } # Volkmar + 969.1.1 = { holder = 168572 } # Gero + 976.6.29 = { holder = et_cologne_1066_6 } # Warin + 984.1.1 = { holder = et_cologne_1066_5 } # Ebergar + 999.1.1 = { holder = et_cologne_1066_4 } # Heribert + 1021.1.1 = { holder = aribonen_7 } # Pilgrim + 1036.8.25 = { holder = ezzonen_1 } # Hermann + 1056.2.11 = { holder = 20228 } # Anno + 1063.1.1 = { liege = e_hre } + # 1178 + 1075.12.4 = { holder = 33157 } # Hildolf + 1078.7.21 = { holder = 33158 } # Sigewin + 1089.5.31 = { holder = 33159 } # Hermann + 1099.11.21 = { holder = 33160 } # Friedrich + 1131.10.5 = { holder = 33161 } # Bruno + 1137.5.29 = { holder = 33162 } # Hugo + 1137.7.1 = { holder = 33163 } # Arnold + 1151.4.3 = { holder = 33164 } # Arnold + 1156.5.4 = { holder = 30344 } # Friedrich + 1158.12.15 = { holder = 33165 } # Reinald + 1167.8.14 = { holder = 213181 } # Filip +} + +d_et_hamburg = { # Hamburg + 834.1.1 = { + liege = k_east_francia + holder = et_hamburg_867_2 # Ansgar + government = ecclesiastical_government + clerical_region = et_867_hamburg_region + } + 867.1.1 = { holder = 163117 } # Wilibert + # 1066 + 888.1.1 = { holder = et_hamburg_1066_11 } # Adalgar + 909.1.1 = { holder = et_hamburg_1066_10 } # Hoger + 915.1.1 = { holder = et_hamburg_1066_9 } # Reginwart + 917.1.1 = { holder = et_hamburg_1066_8 } # Unni + 936.1.1 = { holder = et_hamburg_1066_7 } # Adaldago + 988.1.1 = { holder = et_hamburg_1066_6 } # Libentius + 1013.1.1 = { holder = et_hamburg_1066_5 } # Unwan + 1029.1.1 = { holder = et_hamburg_1066_4 } # Libentius + 1032.9.28 = { holder = et_hamburg_1066_3 } # Hermann + 1035.12.21 = { holder = et_hamburg_1066_2 } # Adalbrand + 1043.7.15 = { holder = 20251 } # Adalberto + 1066.1.1 = { + liege = e_hre + clerical_region = et_1066_hamburg_region + } + # 1178 + 1072.1.1 = { + name = d_et_hamburg_bremen + effect = { + set_capital_county = title:c_bremen + title_domicile ?= { + move_domicile = title:c_bremen.title_province + } + } + } + 1072.3.16 = { holder = 30300 } # Liemar + 1101.5.16 = { holder = 30301 } # Humbert + 1104.1.1 = { holder = 30302 } # Friedrich + 1123.1.29 = { holder = 30303 } # Adalbero + 1148.8.25 = { holder = 30241 } # Hartwig + 1168.3.15 = { holder = 30304 } # Baldewin + 1178.1.1 = { clerical_region = et_1178_hamburg_bremen_region } + 1178.6.18 = { holder = 30305 } # Bertram +} + +d_et_lund = { # Lund + 1104.1.1 = { + liege = k_denmark + holder = 34158 + government = ecclesiastical_government + clerical_region = et_1178_lund_region + } + 1137.5.1 = { holder = 34159 } + 1177.1.1 = { holder = 201520 } +} + +d_et_uppsala = { # Uppsala + 1164.1.1 = { + holder = et_uppsala_1178_1 + government = ecclesiastical_government + clerical_region = et_1178_uppsala_region + } +} + +d_et_nidaros = { # Nidaros + 1152.1.1 = { + liege = k_norway + holder = et_nidaros_1178_2 # Jon + government = ecclesiastical_government + clerical_region = et_1178_nidaros_region + } + 1157.1.1 = { holder = nidaros_bishop_1 } # Øystein +} + +# Balkans +d_et_kyiv = { # Kyiv + 988.1.1 = { + holder = et_kyiv_1066_6 + government = ecclesiastical_government + clerical_region = et_1066_kyiv_region + } + 1004.1.1 = { holder = et_kyiv_1066_5 } # Theophylact + 1008.1.1 = { holder = et_kyiv_1066_4 } # John + 1037.1.1 = { holder = et_kyiv_1066_3 } # Teopempt + 1051.1.1 = { holder = et_kyiv_1066_2 } # Hilarion + 1055.1.1 = { holder = et_kyiv_1066_1 } # Ephraim + # 1178 + 1076.1.1 = { holder = et_kyiv_1178_12 } # John + 1090.1.1 = { holder = et_kyiv_1178_11 } # John + 1093.1.1 = { holder = et_kyiv_1178_10 } # Nicholas + 1104.12.18 = { holder = et_kyiv_1178_9 } # Nicephorus + 1122.10.15 = { holder = et_kyiv_1178_8 } # Nicetas + 1130.1.1 = { holder = et_kyiv_1178_7 } # Michael + 1147.7.27 = { holder = et_kyiv_1178_6 } # Klim + 1156.1.1 = { holder = et_kyiv_1178_5 } # Constantine + 1160.8.1 = { holder = et_kyiv_1178_4 } # Theodore + 1164.1.1 = { holder = et_kyiv_1178_3 } # John + 1167.1.1 = { holder = et_kyiv_1178_2 } # Constantine + 1171.1.1 = { holder = et_kyiv_1178_1 } # Michael + 1178.1.1 = { clerical_region = et_1178_kyiv_region } +} + +d_et_constantinople = { # Constantinople + 10.1.1 = { + government = ecclesiastical_government + clerical_region = et_867_constantinople_region + } + 36.1.1 = {holder = andrew_the_apostle} + 38.1.1 = {holder = stachys_the_apostle} + 54.10.31 = {holder = onesimus_of_byzantium} + 69.1.1 = {holder = polycarpus_of_byzantium} + 89.1.1 = {holder = plutarch_of_byzantium} + 105.1.1 = {holder = sedecion_of_byzantium} + 114.1.1 = {holder = diogenes_of_byzantium} + 129.1.1 = {holder = eleutherius_of_byzantium} + 136.1.1 = {holder = felix_of_byzantium} + 141.1.1 = {holder = polycarpus_ii_of_byzantium} + 144.1.1 = {holder = athenodorus_of_byzantium} + 148.1.1 = {holder = euzois_of_byzantium} + 154.1.1 = {holder = laurence_of_byzantium} + 166.1.1 = {holder = alypius_of_byzantium} + 169.1.1 = {holder = pertinax_of_byzantium} + 187.1.1 = {holder = olympianus_of_byzantium} + 198.1.1 = {holder = marcus_i_of_byzantium} + 211.1.1 = {holder = philadelphus_of_byzantium} + 217.1.1 = {holder = cyriacus_i_of_byzantium} + 230.1.1 = {holder = castinus_of_byzantium} + 237.1.25 = {holder = eugenius_i_of_byzantium} + 242.1.1 = {holder = titus_of_byzantium} + 272.1.1 = {holder = dometius_of_byzantium} + 284.1.1 = {holder = rufinus_of_byzantium} + 293.1.1 = {holder = probus_of_byzantium} + 306.1.1 = {holder = metrophanes_i_of_byzantium} + 314.6.4 = {holder = alexander_of_constantinople} + 337.1.1 = {holder = paul_i_of_constantinople} # year only in the detailed chronology + 339.1.1 = {holder = eusebius_of_nicomedia} + 341.1.1 = {holder = paul_i_of_constantinople} + 342.1.1 = {holder = macedonius_i_of_constantinople} + 346.1.1 = {holder = paul_i_of_constantinople} + 351.9.1 = {holder = macedonius_i_of_constantinople} # c. September 351 + 360.1.27 = {holder = eudoxius_of_antioch} + 370.1.1 = {holder = evagrius_of_constantinople} # early 370; opposed Demophilus + 370.1.2 = {holder = demophilus_of_constantinople} # early 370; CK3 sequencing placeholder + 379.5.1 = {holder = gregory_of_nazianzus} # c. May 379 + 380.1.1 = {holder = maximus_i_of_constantinople} + 381.6.1 = {holder = nectarius_of_constantinople} + 398.9.26 = {holder = john_chrysostom} + 404.6.27 = {holder = arsacius_of_tarsus} + 406.3.1 = {holder = atticus_of_constantinople} + 426.2.28 = {holder = sisinnius_i_of_constantinople} + 428.4.10 = {holder = nestorius_of_constantinople} + 431.10.25 = {holder = maximianus_of_constantinople} + 434.4.13 = {holder = proclus_of_constantinople} + 446.7.12 = {holder = flavian_of_constantinople} + 449.11.1 = {holder = anatolius_i_of_constantinople} + 458.8.1 = {holder = gennadius_i_of_constantinople} + 472.2.1 = {holder = acacius_of_constantinople} + 488.12.1 = {holder = fravitta_of_constantinople} + 489.3.1 = {holder = 0} + 490.4.1 = {holder = euphemius_of_constantinople} + 496.6.1 = {holder = macedonius_ii_of_constantinople} + 511.8.1 = {holder = timothy_i_of_constantinople} + 518.4.17 = {holder = john_ii_of_constantinople} + 520.2.25 = {holder = epiphanius_of_constantinople} + 535.6.5 = {holder = anthimus_i_of_constantinople} + 536.3.13 = {holder = menas_of_constantinople} + 552.8.24 = {holder = eutychius_of_constantinople} + 565.1.31 = {holder = john_scholasticus} + 577.10.3 = {holder = eutychius_of_constantinople} + 582.4.12 = {holder = john_iv_of_constantinople} + 596.2.1 = {holder = cyriacus_ii_of_constantinople} + 607.1.23 = {holder = thomas_i_of_constantinople} + 610.4.18 = {holder = sergius_i_of_constantinople} + 638.12.20 = {holder = pyrrhus_of_constantinople} + 641.10.1 = {holder = paul_ii_of_constantinople} + 654.1.9 = {holder = pyrrhus_of_constantinople} + 654.6.9 = {holder = peter_of_constantinople} + 667.4.17 = {holder = thomas_ii_of_constantinople} + 669.11.15 = {holder = john_v_of_constantinople} + 675.9.2 = {holder = constantine_i_of_constantinople} + 677.8.9 = {holder = theodore_i_of_constantinople} + 679.11.1 = {holder = george_i_of_constantinople} + 686.1.1 = {holder = theodore_i_of_constantinople} + 688.1.1 = {holder = paul_iii_of_constantinople} + 693.8.20 = {holder = callinicus_i_of_constantinople} + 705.9.1 = {holder = kyros_of_constantinople} + 711.12.1 = {holder = 0} + 712.12.1 = {holder = john_vi_of_constantinople} + 715.8.11 = {holder = germanus_i_of_constantinople} + 730.1.22 = {holder = anastasius_of_constantinople} + 754.8.8 = {holder = constantine_ii_of_constantinople} + 766.11.16 = {holder = nicetas_i_of_constantinople} + 780.2.20 = {holder = paul_iv_of_constantinople} + 784.12.25 = {holder = tarasios_of_constantinople} + 806.4.12 = {holder = nikephoros_i_of_constantinople} + 815.4.1 = {holder = theodotus_i_of_constantinople} + 821.1.1 = {holder = antony_i_of_constantinople} + 836.1.21 = {holder = john_grammatikos} + 843.3.11 = {holder = methodius_of_constantinople} + 847.7.4 = {holder = ignatios_of_constantinople} + 858.12.25 = {holder = photios_i_of_constantinople} + 867.11.23 = {holder = ignatios_of_constantinople} + 877.10.26 = {holder = photios_i_of_constantinople} + 886.12.18 = {holder = stephen_i_of_constantinople} + 893.8.1 = {holder = antony_ii_of_constantinople} + 901.3.1 = {holder = nicholas_mystikos} + 907.2.1 = {holder = euthymius_i_of_constantinople} + 912.5.15 = {holder = nicholas_mystikos} + 925.6.29 = {holder = stephen_ii_of_constantinople} + 927.12.14 = {holder = tryphon_of_constantinople} + 928.12.14 = {holder = tryphon_of_constantinople} + 933.2.2 = {holder = theophylact_of_constantinople} + 956.4.3 = {holder = polyeuctus_of_constantinople} + 970.2.13 = {holder = basil_i_of_constantinople} + 973.12.1 = {holder = antony_iii_of_constantinople} + 978.6.1 = {holder = 0} + 980.4.1 = {holder = nicholas_ii_of_constantinople} + 991.12.16 = {holder = 0} + 996.4.12 = {holder = sisinnius_ii_of_constantinople} + 998.8.24 = {holder = 0} + 1001.6.1 = {holder = sergius_ii_of_constantinople} + 1019.7.1 = {holder = eustathius_of_constantinople} + 1025.11.1 = {holder = alexius_of_constantinople} + 1043.2.20 = {holder = michael_i_cerularius} + 1058.11.2 = {holder = 0} + 1059.2.2 = {holder = constantine_iii_of_constantinople} + 1063.8.9 = {holder = 0} + 1064.1.1 = {holder = john_viii_of_constantinople} + 1075.8.2 = {holder = cosmas_i_of_constantinople} + 1081.5.8 = {holder = eustratius_garidas} + 1084.7.1 = {holder = nicholas_iii_of_constantinople} + 1111.5.24 = {holder = john_ix_of_constantinople} + 1134.5.1 = {holder = leo_of_constantinople} + 1143.7.1 = {holder = michael_ii_of_constantinople} + 1146.3.1 = {holder = cosmas_ii_of_constantinople} + 1147.12.1 = {holder = nicholas_iv_of_constantinople} + 1151.3.1 = {holder = theodotus_ii_of_constantinople} + 1153.1.1 = {holder = 0} + 1154.9.1 = {holder = neophytus_i_of_constantinople} + 1154.11.1 = {holder = constantine_iv_of_constantinople} + 1157.8.1 = {holder = luke_chrysoberges} + 1170.1.1 = {holder = michael_iii_of_constantinople} + 1178.3.1 = {holder = chariton_of_constantinople} + 1179.2.1 = {holder = theodosius_i_of_constantinople} + 1183.8.1 = {holder = basil_ii_of_constantinople} + 1186.2.1 = {holder = nicetas_ii_of_constantinople} + 1189.2.1 = {holder = dositheus_of_constantinople} + 1189.2.10 = {holder = leontius_of_constantinople} + 1189.10.1 = {holder = dositheus_of_constantinople} + 1191.9.10 = {holder = george_ii_of_constantinople} + 1198.8.5 = {holder = john_x_of_constantinople} + 1204.4.12 = {holder = 0} # Fourth Crusade; Orthodox throne displaced from Constantinople + 1208.4.20 = {holder = ecpat_126_michael_iv} # Michael IV in Nicaea + 1213.9.28 = {holder = ecpat_127_theodore_ii} + 1216.6.3 = {holder = ecpat_128_maximus_ii} + 1217.5.1 = {holder = ecpat_129_manuel_i} # May 1217; exact day unclear + 1223.1.4 = {holder = ecpat_130_germanus_ii} + 1240.7.1 = {holder = ecpat_131_methodius_ii} # mid/late 1240 + 1243.9.1 = {holder = ecpat_132_manuel_ii} # c. September 1243 + 1254.11.1 = {holder = ecpat_133_arsenius} # November 1254 + 1260.3.1 = {holder = ecpat_134_nicephorus_ii} # c. March 1260 + 1261.3.1 = {holder = ecpat_133_arsenius} + 1265.5.28 = {holder = ecpat_135_germanus_iii} + 1266.12.28 = {holder = ecpat_136_joseph_i} + 1275.6.2 = {holder = ecpat_137_john_xi} + 1282.12.31 = {holder = ecpat_136_joseph_i} + 1283.4.11 = {holder = ecpat_138_gregory_ii} + 1289.10.14 = {holder = ecpat_139_athanasius_i} + 1294.1.1 = {holder = ecpat_140_john_xii} + 1303.6.23 = {holder = ecpat_139_athanasius_i} + 1310.5.9 = {holder = ecpat_141_nephon_i} + 1315.5.12 = {holder = ecpat_142_john_xiii} + 1320.3.21 = {holder = ecpat_143_gerasimus_i} + 1323.11.11 = {holder = ecpat_144_isaias} + 1334.2.1 = {holder = ecpat_145_john_xiv} # February 1334 + 1347.5.17 = {holder = ecpat_146_isidore_i} + 1350.6.10 = {holder = ecpat_147_callistus_i} + 1353.8.1 = {holder = ecpat_148_philotheus_i} # August 1353 + 1355.1.1 = {holder = ecpat_147_callistus_i} + 1364.2.8 = {holder = ecpat_148_philotheus_i} + 1377.6.1 = {holder = ecpat_149_macarius} # c. June 1377 + 1380.3.1 = {holder = ecpat_150_nilus} # March/April 1380 + 1389.1.1 = {holder = ecpat_151_antony_iv} # January 1389 + 1390.7.30 = {holder = ecpat_149_macarius} + 1390.9.1 = {holder = ecpat_151_antony_iv} # c. September 1390 + 1397.5.17 = {holder = ecpat_152_callistus_ii} + 1397.10.1 = {holder = ecpat_153_matthew_i} + 1410.10.26 = {holder = ecpat_154_euthymius_ii} + 1416.5.21 = {holder = ecpat_155_joseph_ii} + 1440.5.4 = {holder = ecpat_156_metrophanes_ii} + 1443.1.1 = {holder = ecpat_157_gregory_iii} # 1443; exact accession date unclear + 1450.1.1 = {holder = ecpat_158_athanasius_ii} # 1450; exact accession date unclear + 1453.5.29 = {holder = 0} # Fall of Constantinople / exceptional interregnum + 1454.1.6 = {holder = ecpat_159_gennadius_ii} + 1456.1.1 = {holder = ecpat_160_isidore_ii} # January 1456 + 1462.4.1 = {holder = ecpat_161_joasaph_i} + 1463.4.10 = {holder = ecpat_159_gennadius_ii} + 1463.6.1 = {holder = ecpat_162_sophronius_i} + 1464.8.1 = {holder = ecpat_159_gennadius_ii} + 1465.9.1 = {holder = ecpat_163_mark_ii} # autumn 1465 (Kiminas chronology) + 1466.9.1 = {holder = ecpat_164_symeon_i} # autumn 1466 (Kiminas chronology) + 1466.12.1 = {holder = ecpat_165_dionysius_i} # late 1466 + 1471.12.1 = {holder = ecpat_164_symeon_i} + 1475.1.1 = {holder = ecpat_166_raphael_i} + 1476.1.1 = {holder = ecpat_167_maximus_iii} + 1482.4.3 = {holder = ecpat_164_symeon_i} + 1486.1.1 = {holder = ecpat_168_nephon_ii} + 1488.7.1 = {holder = ecpat_165_dionysius_i} + 1491.1.1 = {holder = ecpat_169_maximus_iv} + 1497.1.1 = {holder = ecpat_168_nephon_ii} + 1498.1.1 = {holder = ecpat_170_joachim_i} + 1502.1.1 = {holder = ecpat_168_nephon_ii} + 1503.1.1 = {holder = ecpat_171_pachomius_i} + 1504.1.1 = {holder = ecpat_170_joachim_i} + 1504.2.1 = {holder = ecpat_171_pachomius_i} + 1513.6.1 = {holder = ecpat_172_theoleptus_i} + 1522.12.31 = {holder = ecpat_173_jeremias_i} + 1524.5.1 = {holder = ecpat_174_joannicius_i} # April/May 1524 + 1525.9.24 = {holder = ecpat_173_jeremias_i} + 1546.4.17 = {holder = ecpat_175_dionysius_ii} + 1556.7.1 = {holder = ecpat_176_joasaph_ii} + 1565.1.1 = {holder = ecpat_177_metrophanes_iii} + 1572.5.5 = {holder = ecpat_178_jeremias_ii} + 1579.11.25 = {holder = ecpat_177_metrophanes_iii} + 1580.8.1 = {holder = ecpat_178_jeremias_ii} + 1584.2.22 = {holder = ecpat_179_pachomius_ii} + 1585.2.16 = {holder = ecpat_180_theoleptus_ii} + 1587.4.1 = {holder = ecpat_178_jeremias_ii} + 1596.2.1 = {holder = ecpat_181_matthew_ii} + 1596.3.1 = {holder = ecpat_182_gabriel_i} + 1596.8.1 = {holder = ecpat_183_theophanes_i} + 1597.3.30 = {holder = ecpat_184_meletius_i} + 1598.4.1 = {holder = ecpat_181_matthew_ii} + 1602.2.1 = {holder = ecpat_185_neophytus_ii} + 1603.1.1 = {holder = ecpat_181_matthew_ii} + 1603.2.1 = {holder = ecpat_186_raphael_ii} + 1607.10.15 = {holder = ecpat_185_neophytus_ii} + 1612.10.1 = {holder = ecpat_187_cyril_i} # 21-day 1612 term; official Patriarchate describes him as overseer/locum tenens + 1612.11.1 = {holder = ecpat_188_timothy_ii} + 1620.11.4 = {holder = ecpat_187_cyril_i} + 1623.4.12 = {holder = ecpat_189_gregory_iv} + 1623.6.18 = {holder = ecpat_190_anthimus_ii} + 1623.9.22 = {holder = ecpat_187_cyril_i} + 1633.10.4 = {holder = ecpat_191_cyril_ii} + 1633.10.11 = {holder = ecpat_187_cyril_i} + 1634.2.25 = {holder = ecpat_192_athanasius_iii} + 1634.4.1 = {holder = ecpat_187_cyril_i} + 1635.3.1 = {holder = ecpat_191_cyril_ii} + 1636.6.1 = {holder = ecpat_193_neophytus_iii} + 1637.3.1 = {holder = ecpat_187_cyril_i} + 1638.6.20 = {holder = ecpat_191_cyril_ii} + 1639.7.1 = {holder = ecpat_194_parthenius_i} + 1644.9.8 = {holder = ecpat_195_parthenius_ii} + 1646.11.16 = {holder = ecpat_196_joannicius_ii} + 1648.10.29 = {holder = ecpat_195_parthenius_ii} + 1651.6.1 = {holder = ecpat_196_joannicius_ii} + 1652.6.1 = {holder = ecpat_197_cyril_iii} + 1652.6.9 = {holder = ecpat_192_athanasius_iii} + 1652.7.1 = {holder = ecpat_198_paisius_i} + 1653.4.1 = {holder = ecpat_196_joannicius_ii} + 1654.3.1 = {holder = ecpat_197_cyril_iii} + 1654.3.15 = {holder = ecpat_198_paisius_i} + 1655.3.1 = {holder = ecpat_196_joannicius_ii} + 1656.7.26 = {holder = ecpat_199_parthenius_iii} + 1657.4.23 = {holder = ecpat_200_gabriel_ii} + 1657.5.1 = {holder = ecpat_201_parthenius_iv} + 1662.6.29 = {holder = ecpat_202_dionysius_iii} + 1665.10.21 = {holder = ecpat_201_parthenius_iv} + 1667.9.9 = {holder = ecpat_203_clement} + 1668.1.5 = {holder = ecpat_204_methodius_iii} + 1671.3.1 = {holder = ecpat_201_parthenius_iv} + 1671.11.8 = {holder = ecpat_205_dionysius_iv} + 1673.7.25 = {holder = ecpat_206_gerasimus_ii} + 1675.1.1 = {holder = ecpat_201_parthenius_iv} + 1676.7.29 = {holder = ecpat_205_dionysius_iv} + 1679.7.30 = {holder = ecpat_207_athanasius_iv} + 1679.8.10 = {holder = ecpat_208_james} + 1682.7.10 = {holder = ecpat_205_dionysius_iv} + 1684.3.10 = {holder = ecpat_201_parthenius_iv} + 1685.3.20 = {holder = ecpat_208_james} + 1686.3.1 = {holder = ecpat_205_dionysius_iv} + 1687.10.12 = {holder = ecpat_208_james} + 1688.3.3 = {holder = ecpat_209_callinicus_ii} + 1688.11.27 = {holder = ecpat_210_neophytus_iv} + 1689.3.7 = {holder = ecpat_209_callinicus_ii} + 1693.8.1 = {holder = ecpat_205_dionysius_iv} + 1694.4.1 = {holder = ecpat_209_callinicus_ii} + 1702.8.29 = {holder = ecpat_211_gabriel_iii} + 1707.10.20 = {holder = ecpat_212_neophytus_v} + 1707.10.25 = {holder = ecpat_213_cyprianus} + 1709.5.1 = {holder = ecpat_214_athanasius_v} + 1711.12.1 = {holder = ecpat_215_cyril_iv} + 1713.11.1 = {holder = ecpat_213_cyprianus} + 1714.2.28 = {holder = ecpat_216_cosmas_iii} + 1716.3.23 = {holder = ecpat_217_jeremias_iii} + 1726.11.19 = {holder = ecpat_218_callinicus_iii} + 1726.11.20 = {holder = ecpat_219_paisius_ii} + 1732.9.15 = {holder = ecpat_217_jeremias_iii} + 1733.3.1 = {holder = ecpat_220_seraphim_i} + 1734.9.27 = {holder = ecpat_221_neophytus_vi} + 1740.8.1 = {holder = ecpat_219_paisius_ii} + 1743.5.1 = {holder = ecpat_221_neophytus_vi} + 1744.3.1 = {holder = ecpat_219_paisius_ii} + 1748.9.28 = {holder = ecpat_222_cyril_v} + 1751.5.1 = {holder = ecpat_219_paisius_ii} + 1752.9.7 = {holder = ecpat_222_cyril_v} + 1757.1.16 = {holder = ecpat_223_callinicus_iv} + 1757.7.22 = {holder = ecpat_224_seraphim_ii} + 1761.3.26 = {holder = ecpat_225_joannicius_iii} + 1763.5.24 = {holder = ecpat_226_samuel} + 1768.11.5 = {holder = ecpat_227_meletius_ii} + 1769.4.11 = {holder = ecpat_228_theodosius_ii} + 1773.11.17 = {holder = ecpat_226_samuel} + 1774.12.24 = {holder = ecpat_229_sophronius_ii} + 1780.10.8 = {holder = ecpat_230_gabriel_iv} + 1785.6.29 = {holder = ecpat_231_procopius} + 1789.5.1 = {holder = ecpat_232_neophytus_vii} + 1794.3.3 = {holder = ecpat_233_gerasimus_iii} + 1797.4.19 = {holder = ecpat_234_gregory_v} + 1798.12.19 = {holder = ecpat_232_neophytus_vii} + 1801.6.17 = {holder = ecpat_235_callinicus_v} + 1806.9.23 = {holder = ecpat_234_gregory_v} + 1808.9.10 = {holder = ecpat_235_callinicus_v} + 1809.4.23 = {holder = ecpat_236_jeremias_iv} + 1813.3.4 = {holder = ecpat_237_cyril_vi} + 1818.12.14 = {holder = ecpat_234_gregory_v} + 1821.4.10 = {holder = ecpat_238_eugenius_ii} + 1822.7.28 = {holder = ecpat_239_anthimus_iii} + 1824.7.9 = {holder = ecpat_240_chrysanthus} + 1826.9.26 = {holder = ecpat_241_agathangelus} + 1830.7.6 = {holder = ecpat_242_constantius_i} + 1834.8.18 = {holder = ecpat_243_constantius_ii} + 1835.9.27 = {holder = ecpat_244_gregory_vi} + 1840.2.20 = {holder = ecpat_245_anthimus_iv} + 1841.5.6 = {holder = ecpat_246_anthimus_v} + 1842.6.14 = {holder = ecpat_247_germanus_iv} + 1845.4.18 = {holder = ecpat_248_meletius_iii} + 1845.12.4 = {holder = ecpat_249_anthimus_vi} + 1848.10.18 = {holder = ecpat_245_anthimus_iv} + 1852.11.1 = {holder = ecpat_247_germanus_iv} + 1853.9.24 = {holder = ecpat_249_anthimus_vi} + 1855.9.21 = {holder = ecpat_250_cyril_vii} + 1860.10.4 = {holder = ecpat_251_joachim_ii} + 1863.9.20 = {holder = ecpat_252_sophronius_iii} + 1867.2.10 = {holder = ecpat_244_gregory_vi} + 1871.9.5 = {holder = ecpat_249_anthimus_vi} + 1873.11.23 = {holder = ecpat_251_joachim_ii} + 1878.10.4 = {holder = ecpat_253_joachim_iii} + 1884.10.1 = {holder = ecpat_254_joachim_iv} + 1887.2.4 = {holder = ecpat_255_dionysius_v} + 1891.11.8 = {holder = ecpat_256_neophytus_viii} + 1895.2.1 = {holder = ecpat_257_anthimus_vii} + 1897.4.14 = {holder = ecpat_258_constantine_v} + 1901.5.25 = {holder = ecpat_253_joachim_iii} + 1913.2.10 = {holder = ecpat_259_germanus_v} + 1918.12.8 = {holder = ecpat_260_meletius_iv} + 1923.12.6 = {holder = ecpat_261_gregory_vii} + 1924.12.17 = {holder = ecpat_262_constantine_vi} + 1925.7.13 = {holder = ecpat_263_basil_iii} + 1929.10.7 = {holder = ecpat_264_photius_ii} + 1936.1.18 = {holder = ecpat_265_benjamin_i} + 1946.2.20 = {holder = ecpat_266_maximus_v} + 1948.11.1 = {holder = ecpat_267_athenagoras_i} + 1972.7.16 = {holder = ecpat_268_demetrios_i} + 1991.10.22 = { + holder = orthodoxpeps0001 + } + 2091.12.2 = { + holder = orthodoxpeps0002 + } + 2120.5.7 = { + holder = orthodoxpeps0003 + } + 2161.5.21 = { + holder = orthodoxpeps0004 + } + 2196.6.2 = { + holder = orthodoxpeps0005 + } + 2215.2.9 = { + holder = orthodoxpeps0006 + } + 2300.2.6={ + holder = orthodoxpeps0007 + } + 2309.1.1={ + holder = orthodoxpeps0008 + } + 2317.1.1={ + holder = orthodoxpeps0009 + } + 2335.1.1={ + holder = orthodoxpeps0010 + } + 2349.1.1={ + holder = orthodoxpeps0011 + } + 2360.1.1={ + holder = orthodoxpeps0012 + } + 2368.1.1={ + holder = orthodoxpeps0013 + } + 2376.1.1={ + holder = orthodoxpeps0014 + } + 2379.1.1={ + holder = orthodoxpeps0015 + } + 2384.1.1={ + holder = orthodoxpeps0016 + } + 2391.1.1={ + holder = orthodoxpeps0017 + } + 2400.1.1={ + holder = orthodoxpeps0018 + } + 2434.1.1={ + holder = orthodoxpeps0019 + } + 2437.1.1={ + holder = orthodoxpeps0020 + } + 2450.1.1={ + holder = orthodoxpeps0021 + } + 2459.1.1={ + holder = orthodoxpeps0022 + } + 2467.1.1={ + holder = orthodoxpeps0023 + } + 2475.1.1={ + holder = orthodoxpeps0024 + } + 2490.1.1={ + holder = orthodoxpeps0025 + } + 2502.1.1={ + holder = orthodoxpeps0026 + } + 2517.1.1={ + holder = orthodoxpeps0027 + } + 2530.1.10={ + holder = nistria1030 + liege = e_nistrenia + } +} + +# Asia +d_et_jerusalem = { # Jerusalem + 62.1.1 = { + holder = et_jerusalem_867_40 # Simeon + government = ecclesiastical_government + clerical_region = et_867_jerusalem_region + } + 107.1.1 = { holder = et_jerusalem_867_39 } # Justus + 113.1.1 = { holder = et_jerusalem_867_38 } # Zaccheus + 117.1.1 = { holder = et_jerusalem_867_37 } # John + 185.1.1 = { holder = et_jerusalem_867_36 } # Narcissus + 211.1.1 = { holder = et_jerusalem_867_35 } # Narcissus + 231.1.1 = { holder = et_jerusalem_867_34 } # Alexander + 276.1.1 = { holder = et_jerusalem_867_33 } # Zamudas + 314.1.1 = { holder = et_jerusalem_867_32 } # Macarius + 325.1.1 = { holder = et_jerusalem_867_31 } # Macarius + 333.1.1 = { holder = et_jerusalem_867_30 } # Maximus + 350.1.1 = { holder = et_jerusalem_867_29 } # Cyril + 386.1.1 = { holder = et_jerusalem_867_28 } # John II + 417.1.1 = { holder = et_jerusalem_867_27 } # Praulius + 422.1.1 = { holder = et_jerusalem_867_26 } # Juvenal + 451.1.1 = { holder = et_jerusalem_867_25 } # Juvenal + 458.1.1 = { holder = et_jerusalem_867_24 } # Anastasius I + 478.1.1 = { holder = et_jerusalem_867_23 } # Martyrius + 486.1.1 = { holder = et_jerusalem_867_22 } # Sallustius + 494.1.1 = { holder = et_jerusalem_867_21 } # Elias I + 516.1.1 = { holder = et_jerusalem_867_20 } # John III + 524.1.1 = { holder = et_jerusalem_867_19 } # Peter + 544.1.1 = { holder = et_jerusalem_867_18 } # Macarius II + 575.1.1 = { holder = et_jerusalem_867_17 } # Eustochius + 575.6.1 = { holder = et_jerusalem_867_16 } # John IV + 594.1.1 = { holder = et_jerusalem_867_15 } # Amos + 601.1.1 = { holder = et_jerusalem_867_14 } # Isaac + 609.1.1 = { holder = et_jerusalem_867_13 } # Zacharias + 632.1.1 = { holder = et_jerusalem_867_12 } # Modestus + 634.1.1 = { holder = et_jerusalem_867_11 } # Sophronius I + 681.1.1 = { holder = et_jerusalem_867_10 } # Anastasius II + 706.1.1 = { holder = et_jerusalem_867_9 } # John V + 745.1.1 = { holder = et_jerusalem_867_8 } # Theodore + 770.1.1 = { holder = et_jerusalem_867_7 } # Elias II + 797.1.1 = { holder = et_jerusalem_867_6 } # George + 807.1.1 = { holder = et_jerusalem_867_5 } # Thomas I + 820.1.1 = { holder = et_jerusalem_867_4 } # Basileus + 838.1.1 = { holder = et_jerusalem_867_3 } # John VI + 842.1.1 = { holder = et_jerusalem_867_2 } # Sergius I + 855.1.1 = { holder = et_jerusalem_867_1 } # Solomon + 864.1.1 = { holder = et_jerusalem_867_0 } # Theodosius + # 1066 + 878.1.1 = { holder = et_jerusalem_1066_14 } # Elias III + 908.1.1 = { holder = et_jerusalem_1066_13 } # Sergius II + 912.1.1 = { holder = et_jerusalem_1066_12 } # Leontius I + 929.1.1 = { holder = et_jerusalem_1066_11 } # Athanasius I + 937.1.1 = { holder = et_jerusalem_1066_10 } # Christodolus + 950.1.1 = { holder = et_jerusalem_1066_9 } # Agathon + 964.1.1 = { holder = et_jerusalem_1066_8 } # John VII + 966.1.1 = { holder = et_jerusalem_1066_7 } # Christodolus II + 969.1.1 = { holder = et_jerusalem_1066_6 } # Thomas II + 980.1.1 = { holder = et_jerusalem_1066_5 } # Joseph II + 983.1.1 = { holder = et_jerusalem_1066_4 } # Orestes + 1012.1.1 = { holder = et_jerusalem_1066_3 } # Theophilus I + 1020.1.1 = { holder = et_jerusalem_1066_2 } # Nicephorus IV + 1048.1.1 = { holder = et_jerusalem_1066_1 } # Joannichius + # 1178 + 1076.1.1 = { holder = et_jerusalem_1178_5 } # Sophronius II + 1084.1.1 = { holder = et_jerusalem_1178_4 } # Euthemios + 1086.1.1 = { holder = et_jerusalem_1178_3 } # Simeon II + 1098.1.1 = { holder = 0 } + 1099.1.1 = { holder = 32265 } # Arnulf + 1100.1.1 = { holder = et_pisa_1178_8 } # Dagoberto + 1101.1.1 = { holder = et_jerusalem_1178_2 } # Maurizio + 1102.1.1 = { holder = 32267 } # Ebremar + 1105.1.1 = { holder = et_pisa_1178_8 } # Dagoberto + 1107.1.1 = { holder = 32268 } # Ghibbelin + 1112.1.1 = { holder = 32265 } # Arnulf + 1118.1.1 = { + holder = 32269 # Garmond + clerical_region = et_1178_jerusalem_region + } + 1128.1.1 = { holder = 32270 } # Stephen + 1130.1.1 = { holder = 32271 } # William + 1145.1.1 = { holder = 32272 } # Folquet + 1157.1.1 = { holder = 32273 } # Amaury + 1180.1.1 = { holder = et_jerusalem_1178_1 } # Heraclius + 1191.1.1 = { holder = 0 } +} + +d_et_antioch = { # Antioch + ### Chalcedonian (Greek) + 325.1.1 = { + holder = et_antioch_867_62 # Eustathius + government = ecclesiastical_government + clerical_region = et_867_antioch_region + } + 332.1.1 = { holder = et_antioch_867_61 } # Paulinus of Tyre + 332.6.1 = { holder = et_antioch_867_60 } # Eulalios + 333.1.1 = { holder = et_antioch_867_59 } # Euphronios + 334.1.1 = { holder = et_antioch_867_58 } # Philaclus + 341.1.1 = { holder = et_antioch_867_57 } # Stephen I + 345.1.1 = { holder = et_antioch_867_56 } # Leontius + 350.1.1 = { holder = et_antioch_867_53 } # Eudoxius (FIRST) + 354.1.1 = { holder = et_antioch_867_54 } # Meletius + 354.6.1 = { holder = et_antioch_867_53 } # Eudoxius (SECOND) + 357.1.1 = { holder = et_antioch_867_52 } # Annias or Ammianus + 360.1.1 = { holder = et_antioch_867_51 } # Euzoios + 370.1.1 = { holder = et_antioch_867_50 } # Dorotheus + 371.1.1 = { holder = et_antioch_867_49 } # Paulinus + 376.1.1 = { holder = et_antioch_867_48 } # Vitalius + 384.1.1 = { holder = et_antioch_867_47 } # Flavian I + 404.1.1 = { holder = et_antioch_867_46 } # Porphyrus + 408.1.1 = { holder = et_antioch_867_45 } # Alexander + 418.1.1 = { holder = et_antioch_867_44 } # Theodotus + 427.1.1 = { holder = et_antioch_867_43 } # John I + 443.1.1 = { holder = et_antioch_867_42 } # Domnus II + 450.1.1 = { holder = et_antioch_867_41 } # Maximus II + 455.1.1 = { holder = et_antioch_867_40 } # Basil + 459.1.1 = { holder = et_antioch_867_39 } # Acacius + 461.1.1 = { holder = et_antioch_867_38 } # Martyrius + 465.1.1 = { holder = et_antioch_867_37 } # Peter the Fuller (FIRST) + 466.1.1 = { holder = et_antioch_867_36 } # Julian + 474.1.1 = { holder = et_antioch_867_37 } # Peter the Fuller (SECOND) + 475.1.1 = { holder = et_antioch_867_34 } # John II + 490.1.1 = { holder = et_antioch_867_33 } # Stephen II + 493.1.1 = { holder = et_antioch_867_32 } # Stephen III + 495.1.1 = { holder = et_antioch_867_31 } # Callandion + 495.6.1 = { holder = et_antioch_867_30 } # John III (Codonatus) + 497.1.1 = { holder = et_antioch_867_29 } # Palladius + 505.1.1 = { holder = et_antioch_867_28 } # Flavian II + 513.1.1 = { holder = et_antioch_867_27 } # Severus + 518.1.1 = { holder = et_antioch_867_26 } # Paul II + 521.1.1 = { holder = et_antioch_867_25 } # Euphrasius + 526.1.1 = { holder = et_antioch_867_24 } # Ephraim + 546.1.1 = { holder = et_antioch_867_23 } # Domnus III + 561.1.1 = { holder = et_antioch_867_22 } # Anastasius the Sinaite (1) + 571.1.1 = { holder = et_antioch_867_21 } # Gregory (571–594) + 594.1.1 = { holder = et_antioch_867_22 } # Anastasius the Sinaite () + 599.1.1 = { holder = et_antioch_867_19 } # Anastasius II + 610.1.1 = { holder = et_antioch_867_18 } # Gregory II + 620.1.1 = { holder = et_antioch_867_17 } # Anastasius III + 628.1.1 = { holder = et_antioch_867_16 } # Macedonius + # 637 Rashidun conquest from Byzantium + 637.1.1 = { holder = 0 } + #640.1.1 = { holder = et_antioch_867_15 } # George I + #656.1.1 = { holder = et_antioch_867_14 } # Macarius + #681.1.1 = { holder = et_antioch_867_13 } # Theophanes + #687.1.1 = { holder = et_antioch_867_12 } # Sebastian + #690.1.1 = { holder = et_antioch_867_11 } # George II + #695.1.1 = { holder = et_antioch_867_10 } # Alexander II + #742.1.1 = { holder = et_antioch_867_9 } # Stephen IV + #748.1.1 = { holder = et_antioch_867_8 } # Theophylact + #767.1.1 = { holder = et_antioch_867_7 } # Theodore I + #797.1.1 = { holder = et_antioch_867_6 } # John IV + #810.1.1 = { holder = et_antioch_867_5 } # Job I + #826.1.1 = { holder = et_antioch_867_4 } # Nicholas + #834.1.1 = { holder = et_antioch_867_3 } # Simeon + #840.1.1 = { holder = et_antioch_867_2 } # Elias + ### Miaphysite (Antiochian) + 846.1.1 = { holder = et_antioch_867_63 } # Yohannan IV (Mor Yuhanon) + 873.1.1 = { holder = 0 } + ### Orthodox (Greek) + #852.1.1 = { holder = et_antioch_867_1 } # Theodosius I + #860.1.1 = { holder = et_antioch_867_0 } # Nicholas + # 1066 + #879.1.1 = { holder = et_antioch_1066_17 } # Michael + #890.1.1 = { holder = et_antioch_1066_16 } # Zacharias + #902.1.1 = { holder = et_antioch_1066_15 } # George III + #917.1.1 = { holder = et_antioch_1066_14 } # Job II + #939.1.1 = { holder = et_antioch_1066_13 } # Eustratius + #960.1.1 = { holder = et_antioch_1066_12 } # Christopher + #966.1.1 = { holder = et_antioch_1066_11 } # Theodorus II + # 969 Byzantine reconquest + 969.1.1 = { holder = et_antioch_1066_11 } # Theodorus II + 977.1.1 = { holder = et_antioch_1066_10 } # Agapius + 995.1.1 = { holder = et_antioch_1066_9 } # John IV + 1000.1.1 = { holder = et_antioch_1066_8 } # Nicholas III + 1003.1.1 = { holder = et_antioch_1066_7 } # Elias II + 1010.1.1 = { holder = et_antioch_1066_6 } # George + 1015.1.1 = { holder = et_antioch_1066_5 } # Macarius + 1023.1.1 = { holder = et_antioch_1066_4 } # Eleutherius + 1028.1.1 = { holder = et_antioch_1066_3 } # Peter III + ### Orthodox (Greek) + 1051.1.1 = { holder = et_antioch_1066_2 } # John V + 1062.1.1 = { holder = et_antioch_1066_1 } # Aemilian + # 1178 + 1075.1.1 = { holder = et_antioch_1178_7 } # Theodosius II + 1084.1.1 = { holder = et_antioch_1178_6 } # Nicephorus + 1090.1.1 = { holder = et_antioch_1178_5 } # John VII the Oxite + 1118.1.1 = { + clerical_region = et_1178_antioch_region + } + 1155.1.1 = { holder = et_antioch_1178_4 } # John IX + 1159.1.1 = { holder = et_antioch_1178_3 } # Euthymius + 1164.1.1 = { holder = et_antioch_1178_2 } # Macarius II + 1166.1.1 = { holder = et_antioch_1178_1 } # Athanasius I + ### Catholic (Roman) + 1170.6.29 = { holder = et_antioch_1178_8 } # Aimery +} + +d_et_cyprus = { # Cyprus + 325.1.1 = { + holder = et_cyprus_867_18 # Gelasios + government = ecclesiastical_government + clerical_region = et_867_cyprus_region + } + 368.1.1 = { holder = et_cyprus_867_17 } # Epiphanius + 403.1.1 = { holder = et_cyprus_867_16 } # Stavrinos + 431.1.1 = { holder = et_cyprus_867_15 } # Reginos + 431.6.2 = { holder = et_cyprus_867_14 } # Troilos + 449.1.1 = { holder = et_cyprus_867_13 } # Olympios + 457.1.1 = { holder = et_cyprus_867_12 } # Stavrinos + 470.1.1 = { holder = et_cyprus_867_11 } # Anthemios + 620.1.1 = { holder = et_cyprus_867_10 } # Plutarch + 630.1.1 = { holder = et_cyprus_867_9 } # Arkadios + 643.1.1 = { holder = et_cyprus_867_8 } # Serghios + 681.1.1 = { holder = et_cyprus_867_7 } # Epiphanios + 681.6.2 = { holder = et_cyprus_867_6 } # Epiphanios + 691.1.1 = { holder = et_cyprus_867_5 } # John + 754.1.1 = { holder = et_cyprus_867_4 } # George + 783.1.1 = { holder = et_cyprus_867_3 } # Constantine + 787.1.1 = { holder = et_cyprus_867_2 } # Akakios + 850.1.1 = { holder = et_cyprus_867_1 } # Theodore + # 1066 + 1057.1.1 = { holder = 70602 } # Nikolaos + # 1178 + 1151.1.1 = { holder = et_cyprus_1178_2 } # John + 1175.1.1 = { holder = et_cyprus_1178_1 } # Barnabas + 2555.1.1 = { + holder = cyprus0001_bishop # Varnavas - Archbishop and head of the autocephalous Church of Cyprus + government = ecclesiastical_government + } +} + +d_et_armenia = { # Armenia + 288.1.1 = { + holder = armenian_000011 #St. Gregory I the Illuminator (288–325) + liege = k_armenia + government = ecclesiastical_government + clerical_region = et_867_armenia_region + } + 325.1.1 = { + holder = armenian_000013 #St. Aristaces I (325–333) + } + 333.1.1 = { + holder = armenian_000014 #St. Vrtanes I (333–341) + } + 341.1.1 = { + holder = armenian_000015 #St. Husik I (341–347) + } + 347.1.1 = { + holder = armenian_000016 #Daniel I of Armenia (347) + } + 348.1.1 = { + holder = armenian_000017 #Pharen I of Armenia (348–352) + } + 353.1.1 = { + holder = 0 + } + 352.1.1 = { + holder = armenian_000018 #St. Nerses I the Great (353–373) + } + 373.1.1 = { + holder = armenian_000019 #Sahak I (373–377) + } + 377.1.1 = { + holder = armenian_000020 #Zaven I (377–381) + } + 381.1.1 = { + holder = armenian_000021 #Aspuraces I (381–386) + } + 386.1.1 = { + holder = armenian_000022 #St. Sahak II (387–428) + } + 428.1.1 = { + holder = armenian_000023 #Brkisho of Armenia (428–432) + } + 432.1.1 = { + holder = armenian_000024 #Samuel of Armenia (432–437) + } + 437.1.1 = { + holder = armenian_000025 #St. Hovsep I (437–452) + } + 452.1.1 = { + holder = armenian_000027 #Melitus I (452–456) + } + 456.1.1 = { + holder = armenian_000028 #Moses I (456–461) + } + 461.1.1 = { + holder = armenian_000029 #St. Kyud I (461–478) + } + 478.1.1 = { + holder = armenian_000030 #St. John I (478–490) + } + 490.1.1 = { + holder = armenian_000031 #Babken I (490–516) + } + 516.1.1 = { + holder = armenian_000032 #Samuel I (516–526) + } + 526.1.1 = { + holder = armenian_000033 #Mushe I (526–534) + } + 534.1.1 = { + holder = armenian_000034 #Sahak II (534–539) + } + 539.1.1 = { + holder = armenian_000035 #Christopher I (539–545) + } + 545.1.1 = { + holder = armenian_000036 #Ghevond I (545–548) + } + 548.1.1 = { + holder = armenian_000037 #Nerses II (548–557) + } + 557.1.1 = { + holder = armenian_000038 #John II (557–574 + } + 574.1.1 = { + holder = armenian_000039 #Moses II (574–604) + } + 604.1.1 = { + holder = 0 + } + 607.1.1 = { + holder = armenian_000041 #Abraham I (607–615) + } + 615.1.1 = { + holder = armenian_000042 #Komitas I (615–628) + } + 628.1.1 = { + holder = armenian_000043 #Christopher II (628–630) + } + 630.1.1 = { + holder = armenian_000044 #Ezra I (630–641) + } + 641.1.1 = { + holder = armenian_000045 #Nerses III the Builder (641–661) + } + 661.1.1 = { + holder = armenian_000046 #Anastasius I (661–667) + } + 667.1.1 = { + holder = armenian_000047 #Israel I (667–677) + } + 677.1.1 = { + holder = armenian_000048 #Sahak III (677–703) + } + 703.1.1 = { + holder = armenian_000049 #Elias I (703–717) + } + 717.1.1 = { + holder = armenian_000050 #St. John III the Philosopher (717–728) + } + 728.1.1 = { + holder = armenian_000051 #David I (728–741) + } + 741.1.1 = { + holder = armenian_000052 #Dertad I (741–764) + } + 764.1.1 = { + holder = armenian_000053 #Dertad II (764–767) + } + 767.1.1 = { + holder = armenian_000054 #Sion I (767–775) + } + 775.1.1 = { + holder = armenian_000055 #Isaiah I (775–788) + } + 788.1.1 = { + holder = armenian_000056 #Stephen I (788–790) + } + 790.1.1 = { + holder = armenian_000057 #Joab I (790–791) + } + 791.1.1 = { + holder = armenian_000058 #Solomon I (791–792) + } + 792.1.1 = { + holder = armenian_000059 #George I (792–795) + } + 795.1.1 = { + holder = armenian_000060 #Joseph I (795–806) + } + 806.1.1 = { + holder = armenian_000061 #David II (806–833) + } + 833.1.1 = { + holder = armenian_000062 #John IV (833–855) + } + 855.1.1 = { + holder = armenian_000063 #Zacharias I (855–876) + } + 876.1.1 = { + holder = armenian_000064 #George II (877–897) + } + 897.1.1 = { + holder = armenian_000065 #Mashdotz I (897–898) + } + 898.1.1 = { + holder = armenian_000067 #John V the Historian (898–929) + } + 929.1.1 = { + holder = armenian_000068 #Stephen II (929–930) + } + 930.1.1 = { + holder = armenian_000069 #Theodore I (930–941) + } + 941.1.1 = { + holder = armenian_000070 #Yeghishe I (941–946) + } + 946.1.1 = { + holder = armenian_000072 #Ananias I (949–968) + } + 968.1.1 = { + holder = armenian_000073 #Vahan I (968–969) + } + 969.1.1 = { + holder = armenian_000074 #Stephen III (969–972) + } + 972.1.1 = { + holder = armenian_000075 #Khachig I (973–992) + } + 992.1.1 = { + holder = armenian_000077 #Sarkis I (992–1019) + } + 1019.1.1 = { + holder = armenian_000078 #Peter I (1019–1058) + } + 1058.1.1 = { + holder = armenian_000079 #Khachik II of Armenia, Khachik II ofAni, Khachik II of Cilicia (1058–1065) + } + 1065.1.1 = { + holder = armenian_000080 #Gregory the Martyrophile (1066–1116) + clerical_region = et_1066_armenia_region + } + 1105.2.23 = { + holder = armenian_catholicos_1 # Barsegh + } + 1113.11.13 = { + holder = 232583 # Grigor III Pahlavuni + } + 1166.8.17 = { + holder = 232584 # Nerses IV the Gracious + } + 1173.8.13 = { + holder = 232580 # Gregory IV the Young + } +} + +# Kartli +d_et_kartli = { # Kartli + 326.1.1 = { + holder = et_kartli_867_53 # Ioane + government = ecclesiastical_government + clerical_region = et_867_kartli_region + } + 363.1.1 = { holder = et_kartli_867_62 } # Iakobi + 375.1.1 = { holder = et_kartli_867_61 } # Iobi + 390.1.1 = { holder = et_kartli_867_60 } # Elia + 400.1.1 = { holder = et_kartli_867_59 } # Svimeon + 410.1.1 = { holder = et_kartli_867_58 } # Mose + 425.1.1 = { holder = et_kartli_867_57 } # Iona + 429.1.1 = { holder = et_kartli_867_56 } # Ieremia + 433.1.1 = { holder = et_kartli_867_55 } # Grigol + 434.1.1 = { holder = et_kartli_867_54 } # Vasili + 436.1.1 = { holder = et_kartli_867_53 } # Glonakor + 448.1.1 = { holder = et_kartli_867_52 } # Iovel + 452.1.1 = { holder = et_kartli_867_51 } # Mikael + 467.1.1 = { holder = et_kartli_867_50 } # Petre + 474.1.1 = { holder = et_kartli_867_49 } # Samoel + 502.1.1 = { holder = et_kartli_867_48 } # Gabriel + 510.1.1 = { holder = et_kartli_867_47 } # Tavfechag + 516.1.1 = { holder = et_kartli_867_46 } # Chirmagi-Chigirmane + 523.1.1 = { holder = et_kartli_867_45 } # Saba + 532.1.1 = { holder = et_kartli_867_44 } # Evlavi + 544.1.1 = { holder = et_kartli_867_43 } # Samoel + 553.1.1 = { holder = et_kartli_867_42 } # Makari + 569.1.1 = { holder = et_kartli_867_41 } # Svimeon + 575.1.1 = { holder = et_kartli_867_40 } # Samoel + 582.1.1 = { holder = et_kartli_867_39 } # Samoel + 591.1.1 = { holder = et_kartli_867_38 } # Bartlome + 595.1.1 = { holder = et_kartli_867_37 } # Kirion + 610.1.1 = { holder = et_kartli_867_36 } # Ioane + 619.1.1 = { holder = et_kartli_867_35 } # Babila + 629.1.1 = { holder = et_kartli_867_34 } # Tabor + 634.1.1 = { holder = et_kartli_867_33 } # Samoel + 640.1.1 = { holder = et_kartli_867_32 } # Evnon + 649.1.1 = { holder = et_kartli_867_31 } # Tavfechag + 664.1.1 = { holder = et_kartli_867_30 } # Evlale + 668.1.1 = { holder = et_kartli_867_29 } # Iovel + 670.1.1 = { holder = et_kartli_867_28 } # Samoel + 677.1.1 = { holder = et_kartli_867_27 } # Giorgi + 678.1.1 = { holder = et_kartli_867_26 } # Kirion + 683.1.1 = { holder = et_kartli_867_25 } # Izid-Bozidi + 685.1.1 = { holder = et_kartli_867_24 } # Teodore + 689.1.1 = { holder = et_kartli_867_23 } # Petre + 720.1.1 = { holder = et_kartli_867_22 } # Talale + 731.1.1 = { holder = et_kartli_867_21 } # Mamai + 744.1.1 = { holder = et_kartli_867_20 } # Ioane + 760.1.1 = { holder = et_kartli_867_19 } # Grigol + 767.1.1 = { holder = et_kartli_867_18 } # Sarmeane + 774.1.1 = { holder = et_kartli_867_17 } # Mikael + 780.1.1 = { holder = et_kartli_867_16 } # Samoel + 791.1.1 = { holder = et_kartli_867_15 } # Kirile + 802.1.1 = { holder = et_kartli_867_14 } # Grigol + 814.1.1 = { holder = et_kartli_867_13 } # Samoel + 826.1.1 = { holder = et_kartli_867_12 } # Giorgi + 838.1.1 = { holder = et_kartli_867_11 } # Gabriel + 850.1.1 = { holder = et_kartli_867_10 } # Ilarion + 860.1.1 = { holder = et_kartli_867_9 } # Arsen + 887.1.1 = { holder = et_kartli_867_8 } # Evsuki + 900.1.1 = { holder = et_kartli_867_7 } # Klementos + 914.1.1 = { holder = et_kartli_867_6 } # Basili + 930.1.1 = { holder = et_kartli_867_5 } # Mikael + 944.1.1 = { holder = et_kartli_867_4 } # Davit + 955.1.1 = { holder = et_kartli_867_3 } # Arseni + 980.1.1 = { holder = et_kartli_867_2 } # Okropir + 1001.1.1 = { holder = et_kartli_867_1 } # Svimeon + # Georgia transition + 1001.6.1 = { + holder = et_georgia_1066_5 # Melkisedek + clerical_region = et_1066_georgia_region + name = d_et_georgia + } + 1031.1.1 = { holder = et_georgia_1066_4 } # Okropir + 1039.1.1 = { holder = et_georgia_1066_5 } # Melkisedek + 1045.1.1 = { holder = et_georgia_1066_4 } # Okropir + 1049.1.1 = { holder = et_georgia_1066_3 } # Ekvtime + 1055.1.1 = { holder = et_georgia_1066_2 } # Girogi + 1065.1.1 = { holder = et_georgia_1066_1 } # Gabriel + #1178 + 1080.1.1 = { holder = et_georgia_1178_7 } # Dimitri + 1090.1.1 = { holder = et_georgia_1178_6 } # Basili + 1100.1.1 = { holder = et_georgia_1178_5 } # Ioane + 1142.1.1 = { holder = et_georgia_1178_4 } # Svimeon + 1146.1.1 = { holder = et_georgia_1178_3 } # Saba + 1150.1.1 = { holder = et_georgia_1178_2 } # Nikoloz + 1178.1.1 = { holder = et_georgia_1178_1 } # Girogi +} + +d_et_seleucia_ctesiphon = { # Seleucia-Ctesiphon + 415.1.1 = { + holder = 166254 + government = ecclesiastical_government + clerical_region = et_867_seleucia_ctesiphon_region + } + 420.1.1 = { holder = 166255 } + 420.6.1 = { holder = 166256 } + 421.1.1 = { holder = 166257 } + 457.1.1 = { holder = 166258 } + 484.1.1 = { holder = 166259 } + 485.1.1 = { holder = 166260 } + 497.1.1 = { holder = 166261 } + 503.1.1 = { holder = 166262 } + 524.1.1 = { holder = 166263 } + 530.1.1 = { holder = 166264 } + 536.1.1 = { holder = 166263 } + 538.1.1 = { holder = 166265 } + 540.1.1 = { holder = 166266 } + 552.1.1 = { holder = 166267 } + 567.1.1 = { holder = 166268 } + 582.1.1 = { holder = 166269 } + 596.1.1 = { holder = 166270 } + 605.1.1 = { holder = 166271 } + 609.1.1 = { holder = 166272 } + 611.1.1 = { holder = 166273 } #coadjutor with Aba 166274 in the North (Assyria region) + 628.1.1 = { holder = 166275 } + 646.1.1 = { holder = 166276 } + 649.1.1 = { holder = 166277 } + 661.1.1 = { holder = 166278 } + 680.1.1 = { holder = 166279 } + 686.1.1 = { holder = 166280 } + 691.1.1 = { holder = 166281 } + 693.1.1 = { holder = 166280 } + 714.1.1 = { holder = 166282 } + 731.1.1 = { holder = 166283 } + 741.1.1 = { holder = 166284 } + 753.1.1 = { holder = 166285 } + 753.6.1 = { holder = 166286 } + 773.1.1 = { holder = 166287 } + 780.1.1 = { holder = 166288 } + 823.1.1 = { holder = 166289 } + 828.1.1 = { holder = 166290 } + 831.1.1 = { holder = 166291 } + 837.1.1 = { holder = 166292 } + 853.1.1 = { holder = 166293 } + 860.1.1 = { holder = 166294 } + 877.1.1 = { holder = 166295 } + 877.6.1 = { holder = 166296 } + 884.1.1 = { holder = 166297 } + 893.1.1 = { holder = 166298 } + 900.1.1 = { holder = 166299 } + 906.1.1 = { holder = 166300 } + 937.1.1 = { holder = 166301 } + 961.1.1 = { holder = 166302 } + 963.1.1 = { holder = 166303 } + 987.1.1 = { holder = 166304 } + 1000.1.1 = { holder = 166305 } + 1012.1.1 = { holder = 166306 } + 1020.1.1 = { holder = 166307 } + 1028.1.1 = { holder = 166308 } + 1049.1.1 = { holder = 166309 } + 1064.1.1 = { holder = 166310 } + 1072.1.1 = { holder = patriarch_in_the_east_70 } # Abdisho II + 1090.1.1 = { holder = patriarch_in_the_east_71 } # Makkikha + 1110.1.1 = { holder = patriarch_in_the_east_72 } # Eliya II + 1132.1.1 = { holder = patriarch_in_the_east_73 } # Bar Sawma + 1136.1.1 = { holder = patriarch_in_the_east_74 } # Abdisho III + 1148.1.1 = { holder = patriarch_in_the_east_75 } # Isho'yahb V + 1175.5.25 = { holder = patriarch_in_the_east_76 } # Eliya III +} + +d_et_tyre = { # Tyre + 1122.1.1 = { + holder = et_tyre_1178_6 # Odo + government = ecclesiastical_government + clerical_region = et_1178_tyre_region + } + 1124.1.1 = { holder = 0 } # vacancy + 1127.1.1 = { holder = et_tyre_1178_5 } # William I + 1135.1.1 = { holder = 32272 } # Folquet + 1146.1.1 = { holder = et_tyre_1178_4 } # Ralph, not consecrated + 1151.1.1 = { holder = et_tyre_1178_3 } # Peter + 1164.1.1 = { holder = et_tyre_1178_2 } # Frederick + 1174.6.6 = { holder = et_tyre_1178_1 } # William II +} + +# Africa +d_et_alexandria = { # Alexandria + 43.1.1 = { holder = 161518 } #Markos I + 230.11.18 = { + holder = et_alexandria_867_41 # Heraclas + government = ecclesiastical_government + clerical_region = et_867_alexandria_region + } + 246.12.28 = { holder = et_alexandria_867_40 } # Dionysius the Great + 264.11.9 = { holder = et_alexandria_867_39 } # Maximus + 282.12.11 = { holder = et_alexandria_867_38 } # Theonas + 302.2.8 = { holder = et_alexandria_867_37 } # Peter (the Seal of the Martyrs) + 311.12.24 = { holder = et_alexandria_867_36 } # Achillas + 312.7.10 = { holder = et_alexandria_867_35 } # Alexander I + 328.5.5 = { holder = 161520 } # Athanasius (the Apostolic) + 373.5.27 = { holder = et_alexandria_867_33 } # Peter II + 379.3.14 = { holder = et_alexandria_867_32 } # Timothy I + 385.8.28 = { holder = et_alexandria_867_31 } # Theophilus I + 412.10.17 = { holder = 161508 } # Cyril + 444.8.8 = { holder = et_alexandria_867_29 } # Dioscorus (the Champion of Orthodoxy) + 455.10.13 = { holder = et_alexandria_867_28 } # Timothy II + 477.9.14 = { holder = et_alexandria_867_27 } # Peter III + 489.12.11 = { holder = 161521 } # Athanasius II + 496.9.29 = { holder = 161514 } # John I + 505.5.29 = { holder = 161515 } # John II + 516.6.10 = { holder = et_alexandria_867_23 } # Dioscorus II + 518.11.10 = { holder = et_alexandria_867_22 } # Timothy III + 536.2.22 = { holder = 161522 } # Theodosius I + 567.7.25 = { holder = et_alexandria_867_20 } # Peter IV + 569.6.26 = { holder = et_alexandria_867_19 } # Damian + 605.7.9 = { holder = et_alexandria_867_18 } # Anastasius + 617.1.2 = { holder = et_alexandria_867_17 } # Andronicus + 623.9.17 = { holder = 161524 } # Benjamin I + 662.9.22 = { holder = et_alexandria_867_15 } # Agathon + 680.12.10 = { holder = 161516 } # John III + 690.1.16 = { holder = et_alexandria_867_13 } # Isaac + 692.12.19 = { holder = et_alexandria_867_12 } # Simeon I + 704.5.8 = { holder = et_alexandria_867_11 } # Alexander II + 729.3.26 = { holder = et_alexandria_867_10 } # Cosmas I + 730.7.8 = { holder = 161523 } # Theodore I + 743.9.14 = { holder = 161509 } # Michael I + 767.4.9 = { holder = et_alexandria_867_7 } # Mina I + 777.1.24 = { holder = 161517 } # John IV + 819.5.12 = { holder = et_alexandria_867_5 } # James + 830.2.28 = { holder = et_alexandria_867_4 } # Simeon II + 831.11.30 = { holder = et_alexandria_867_3 } # Joseph + 849.11.20 = { holder = 161510 } # Michael II + 851.7.21 = { holder = et_alexandria_867_1 } # Cosmas II + 859.1.8 = { holder = 168592 } # Shenouda + # 1066 + 880.4.25 = { holder = 161511 } # Michael III + 909.5.29 = { holder = 161513 } # Gabriel I + 920.2.28 = { holder = et_alexandria_1066_9 } # Cosmas III + 932.4.9 = { holder = 161512 } # Macarius I + 952.8.1 = { holder = et_alexandria_1066_7 } # Theophilus II + 956.12.20 = { holder = et_alexandria_1066_6 } # Mina II + 975.11.28 = { holder = et_alexandria_1066_5 } # Abraham + 979.4.10 = { holder = et_alexandria_1066_4 } # Philotheos + 1004.9.28 = { holder = et_alexandria_1066_3 } # Zacharias + 1032.12.13 = { holder = et_alexandria_1066_2 } # Shenouda II + 1046.12.24 = { holder = 35001 } # Christodoulos + # 1178 + 1077.1.1 = { holder = 161491 } # Kyril II + 1092.6.6 = { holder = 161492 } # Khail IV + 1102.5.25 = { holder = 161493 } # Makarios II + 1131.1.1 = { holder = 161494 } # Gabriel II + 1145.1.1 = { holder = 161495 } # Khail V + 1146.1.1 = { holder = 161496 } # Yohannes V + 1166.4.29 = { + holder = 161497 # Markos III + clerical_region = et_1178_alexandria_region + } +} + +d_et_axum = { # Axum + 620.1.1 = { + holder = et_axum_867_3 # Qerellos + government = ecclesiastical_government + clerical_region = et_867_axum_region + } + 820.1.1 = { holder = et_axum_867_2 } # Yohannes + 860.1.1 = { holder = et_axum_867_1 } # Yaqob I + #1066 + 875.1.1 = { holder = et_axum_1066_5 } # Salama + 905.1.1 = { holder = et_axum_1066_4 } # Bartalomewos + 920.1.1 = { holder = et_axum_1066_3 } # Peter + 985.1.1 = { holder = et_axum_1066_2 } # Daniel + 1050.1.1 = { holder = et_axum_1066_1 } # Fiqtor + # 1178 + 1076.1.1 = { holder = et_axum_1178_5 } # Sawiros + 1102.1.1 = { holder = et_axum_1178_4 } # Giyorgis + 1124.1.1 = { holder = et_axum_1178_3 } # Mikael + 1151.1.1 = { holder = et_axum_1178_2 } # Yaqob + 1178.1.1 = { holder = et_axum_1178_1 } # Gabra +} + +d_et_africa = { # Carthage + 867.1.1 = { + government = ecclesiastical_government + clerical_region = et_867_africa_region + } +} diff --git a/localization/english/replace/council_l_english.yml b/localization/english/replace/council_l_english.yml index 7e2c73bbd..24f98aac4 100644 --- a/localization/english/replace/council_l_english.yml +++ b/localization/english/replace/council_l_english.yml @@ -80,11 +80,17 @@ #Fallback councillor_court_chaplain_theocrat_county:1 "Suffragan Bishop" + councillor_court_chaplain_theocrat_county_female: "Suffragan Bishopess" councillor_court_chaplain_theocrat_county_possessive:1 "Suffragan Bishop's" + councillor_court_chaplain_theocrat_county_female_possessive: "Suffragan Bishopess'" councillor_court_chaplain_theocrat_duchy:1 "Bishop" + councillor_court_chaplain_theocrat_duchy_female: "Bishopess" councillor_court_chaplain_theocrat_duchy_possessive:1 "Bishop's" + councillor_court_chaplain_theocrat_duchy_female_possessive: "Bishopess'" councillor_court_chaplain_theocrat_kingdom:1 "Archbishop" + councillor_court_chaplain_theocrat_kingdom_female: "Archbishopess" councillor_court_chaplain_theocrat_kingdom_possessive:1 "Archbishop's" + councillor_court_chaplain_theocrat_kingdom_female_possessive: "Archbishopess'" councillor_court_chaplain_theocrat_empire:0 "Patriarch" councillor_court_chaplain_theocrat_empire_female:0 "Matriarch" councillor_court_chaplain_theocrat_empire_possessive:0 "Patriarch's" @@ -92,21 +98,55 @@ #Christian councillor_court_chaplain_christian_county:1 "Suffragan Bishop" + councillor_court_chaplain_christian_county_female: "Suffragan Bishopess" councillor_court_chaplain_christian_county_possessive:1 "Suffragan Bishop's" + councillor_court_chaplain_christian_county_female_possessive: "Suffragan Bishopess'" councillor_court_chaplain_christian_duchy:1 "Bishop" + councillor_court_chaplain_christian_duchy_female: "Bishopess" councillor_court_chaplain_christian_duchy_possessive:1 "Bishop's" + councillor_court_chaplain_christian_duchy_female_possessive: "Bishopess'" councillor_court_chaplain_christian_kingdom:1 "Archbishop" + councillor_court_chaplain_christian_kingdom_female: "Archbishopess" councillor_court_chaplain_christian_kingdom_possessive:1 "Archbishop's" + councillor_court_chaplain_christian_kingdom_female_possessive: "Archbishopess'" councillor_court_chaplain_christian_empire:0 "Patriarch" councillor_court_chaplain_christian_empire_female:0 "Matriarch" councillor_court_chaplain_christian_empire_possessive:0 "Patriarch's" councillor_court_chaplain_christian_empire_female_possessive:0 "Matriarch's" + councillor_court_chaplain_catholic_county: "Court Chaplain" + councillor_court_chaplain_catholic_county_possessive: "Court Chaplain's" + councillor_court_chaplain_catholic_duchy: "Bishop" + councillor_court_chaplain_catholic_duchy_female: "Bishopess" + councillor_court_chaplain_catholic_duchy_possessive: "Bishop's" + councillor_court_chaplain_catholic_duchy_female_possessive: "Bishopess'" + councillor_court_chaplain_catholic_clerical_region: "Archbishop" + councillor_court_chaplain_catholic_clerical_region_female: "Archbishopess" + councillor_court_chaplain_catholic_clerical_region_possessive: "Archbishop's" + councillor_court_chaplain_catholic_clerical_region_female_possessive: "Archbishopess'" #Orthodox - councillor_court_chaplain_orthodox_county:1 "Suffragan Bishop" - councillor_court_chaplain_orthodox_county_possessive:1 "Suffragan Bishop's" - councillor_court_chaplain_orthodox_duchy:1 "Bishop" - councillor_court_chaplain_orthodox_duchy_possessive:1 "Bishop's" + councillor_court_chaplain_orthodox_county:1 "Priest" + councillor_court_chaplain_orthodox_county_female: "Priestess" + councillor_court_chaplain_orthodox_county_possessive:1 "Priest's" + councillor_court_chaplain_orthodox_county_female_possessive: "Priestess'" + councillor_court_chaplain_orthodox_duchy:1 "Episcopus" + councillor_court_chaplain_orthodox_duchy_female: "Episcopa" + councillor_court_chaplain_orthodox_duchy_possessive:1 "Episcopus'" + councillor_court_chaplain_orthodox_duchy_female_possessive: "Episcopa's" + councillor_court_chaplain_orthodox_clerical_region_archbishop: "Archbishop" + councillor_court_chaplain_orthodox_clerical_region_archbishop_female: "Archbishop" + councillor_court_chaplain_orthodox_clerical_region_archbishop_possessive: "Archbishop's" + councillor_court_chaplain_orthodox_clerical_region_archbishop_female_possessive: "Archbishop's" + councillor_court_chaplain_orthodox_clerical_region_exarch: "Exarch" + councillor_court_chaplain_orthodox_clerical_region_exarch_female: "Exarch" + councillor_court_chaplain_orthodox_clerical_region_exarch_possessive: "Exarch's" + councillor_court_chaplain_orthodox_clerical_region_exarch_female_possessive: "Exarch's" + councillor_court_chaplain_orthodox_clerical_region: "Metropolitan" + councillor_court_chaplain_orthodox_clerical_region_possessive: "Metropolitan's" + councillor_court_chaplain_orthodox_clerical_region_holy_site: "Patriarch" + councillor_court_chaplain_orthodox_clerical_region_holy_site_female: "Matriarch" + councillor_court_chaplain_orthodox_clerical_region_holy_site_possessive: "Patriarch's" + councillor_court_chaplain_orthodox_clerical_region_holy_site_female_possessive: "Matriarch's" councillor_court_chaplain_orthodox_kingdom:0 "Patriarch" councillor_court_chaplain_orthodox_kingdom_female:0 "Matriarch" councillor_court_chaplain_orthodox_kingdom_possessive:0 "Patriarch's" @@ -159,18 +199,6 @@ councillor_court_chaplain_buddhism_religion_kingdom_possessive:0 "Rajpurohit's" councillor_court_chaplain_buddhism_religion_empire:0 "Marajpurohit" councillor_court_chaplain_buddhism_religion_empire_possessive:0 "Marajpurohit's" - -# Thelema - councillor_court_chaplain_thelema_religion_county:0 "Court Magus" - councillor_court_chaplain_thelema_religion_county_female:0 "Court Magus" - councillor_court_chaplain_thelema_religion_county_possessive:0 "Court Magi's" - councillor_court_chaplain_thelema_religion_county_female_possessive:0 "Magi's" - councillor_court_chaplain_thelema_religion_duchy:0 "Magus" - councillor_court_chaplain_thelema_religion_duchy_possessive:0 "Magus's" - councillor_court_chaplain_thelema_religion_kingdom:0 "Archmagus" - councillor_court_chaplain_thelema_religion_kingdom_possessive:0 "Archmagus's" - councillor_court_chaplain_thelema_religion_empire:0 "Grandmagus" - councillor_court_chaplain_thelema_religion_empire_possessive:0 "Grandmagus'" # Dualism (Didaskalos) (Ecclesiarch) (Patriarch/Matriarch) councillor_court_chaplain_dualism_religion_county:0 "Didaskalos" @@ -191,16 +219,16 @@ councillor_court_chaplain_germanic_religion_empire_possessive:0 "Kjárrgoði's" # Hellenism (Augur/Seeress) (Flamen/Vestal) (Pontifex) (Oracle/Sybil) - councillor_court_chaplain_theomach_religion_county:0 "Flamen" - councillor_court_chaplain_theomach_religion_county_female:0 "Vestal" - councillor_court_chaplain_theomach_religion_county_possessive:0 "Flamen's" - councillor_court_chaplain_theomach_religion_county_female_possessive:0 "Vestal's" - councillor_court_chaplain_theomach_religion_duchy:0 "Pontifex" - councillor_court_chaplain_theomach_religion_duchy_possessive:0 "Pontifex's" - councillor_court_chaplain_theomach_religion_kingdom:0 "Oracle" - councillor_court_chaplain_theomach_religion_kingdom_female:0 "Sybil" - councillor_court_chaplain_theomach_religion_kingdom_possessive:0 "Oracle's" - councillor_court_chaplain_theomach_religion_kingdom_female_possessive:0 "Sybil's" + councillor_court_chaplain_hellenism_religion_county:0 "Flamen" + councillor_court_chaplain_hellenism_religion_county_female:0 "Vestal" + councillor_court_chaplain_hellenism_religion_county_possessive:0 "Flamen's" + councillor_court_chaplain_hellenism_religion_county_female_possessive:0 "Vestal's" + councillor_court_chaplain_hellenism_religion_duchy:0 "Pontifex" + councillor_court_chaplain_hellenism_religion_duchy_possessive:0 "Pontifex's" + councillor_court_chaplain_hellenism_religion_kingdom:0 "Oracle" + councillor_court_chaplain_hellenism_religion_kingdom_female:0 "Sybil" + councillor_court_chaplain_hellenism_religion_kingdom_possessive:0 "Oracle's" + councillor_court_chaplain_hellenism_religion_kingdom_female_possessive:0 "Sybil's" # Judaism (Court Rabbi) (Kohen) (Rabban) (Nasi) (Gadol) councillor_court_chaplain_judaism_religion_county:0 "Kohen" @@ -335,8 +363,8 @@ councillor_spymaster_celestial_government_non_imperial_possessive: "Investigating Censor's" councillor_court_chaplain_celestial_government_non_imperial: "Ritualist" councillor_court_chaplain_celestial_government_non_imperial_possessive: "Ritualist's" - councillor_court_chaplain_buddhist_chinese: "Hé Shang" - councillor_court_chaplain_buddhist_chinese_possessive: "Hé Shang's" + councillor_court_chaplain_buddhist_chinese: "Héshàng" + councillor_court_chaplain_buddhist_chinese_possessive: "Héshàng's" councillor_court_chaplain_daoist_chinese: "Taozhang" councillor_court_chaplain_daoist_chinese_possessive: "Taozhang's" councillor_court_chaplain_confucian_chinese: "Lisheng" @@ -368,6 +396,7 @@ councillor_spouse_duke:0 "Duke" councillor_spouse_count:0 "Count" councillor_spouse_baron:0 "Baron" + councillor_spouse_consort: "Consort" councillor_spouse_possessive:0 "Spouse's" councillor_spouse_prince_consort_possessive:0 "Prince Consort's" diff --git a/localization/english/replace/culture/culture_titles_l_english.yml b/localization/english/replace/culture/culture_titles_l_english.yml new file mode 100644 index 000000000..0427f722a --- /dev/null +++ b/localization/english/replace/culture/culture_titles_l_english.yml @@ -0,0 +1,1560 @@ +l_english: + + ############################################# +#General names: + baron: "Baron" + baron_female: "Baroness" + count: "Count" + count_female: "Countess" + duke: "Duke" + duke_female: "Duchess" + king: "King" + king_female: "Queen" + emperor: "Emperor" + emperor_female: "Empress" + hegemon: "Hegemon" + hegemon_female: "Hegemoness" + + baron_plural: "Barons" + count_plural: "Counts" + duke_plural: "Dukes" + king_plural: "Kings" + emperor_plural: "Emperors" + + #Default Feudal tiers + #Default Republic tiers + #Default Theocracy tiers + #Default Clan tiers + #Default Tribal tiers + #Default Imperial tiers + #Default Nomadic Clan tiers + #Default Mercenary tiers + #Default Military Order tiers + #Default Viceroyalty tiers + + + #Default Feudal tiers + baron_feudal_male:0 "Baron" + baron_feudal_female:0 "Baroness" + barony_feudal:0 "Barony" + count_feudal_male:0 "Count" + count_feudal_female:0 "Countess" + county_feudal:0 "County" + duke_feudal_male:0 "Duke" + duke_feudal_female:0 "Duchess" + duchy_feudal:0 "Duchy" + duke_feudal_independent:0 "Petty King" + duke_feudal_independent_female:0 "Petty Queen" + duchy_feudal_independent:0 "Petty Kingdom" + king_feudal_male:0 "King" + king_feudal_female:0 "Queen" + kingdom_feudal:0 "Kingdom" + emperor_feudal_male:0 "Emperor" + emperor_feudal_female:0 "Empress" + empire_feudal:0 "Empire" + + #Default Republic tiers + baron_republic_male:0 "Mayor" + baron_republic_female:0 "Mayor" + barony_republic:0 "City" + count_republic_male:0 "Lord-Mayor" + count_republic_female:0 "Lady-Mayor" + county_republic:0 "Grand City" + duke_republic_male:0 "Grand Mayor" + duke_republic_female:0 "Grand Mayor" + duchy_republic:0 "Republic" + king_republic_male:0 "High Prince" + king_republic_female:0 "High Princess" + kingdom_republic:0 "Most Serene Republic" + emperor_republic_male:0 "Grand Prince" + emperor_republic_female:0 "Grand Princess" + empire_republic:0 "Grand Principality" + + #Default Theocracy tiers + baron_theocracy_male:0 "Priest" + baron_theocracy_female:0 "Priestess" + barony_theocracy:0 "Temple" + count_theocracy_male:0 "High Priest" + count_theocracy_female:0 "High Priestess" + county_theocracy:0 "Great Temple" + duke_theocracy_male:0 "Archpriest" + duke_theocracy_female:0 "Archpriestess" + duchy_theocracy:0 "Theocracy" + king_theocracy_male:0 "Grand Priest" + king_theocracy_female:0 "Grand Priestess" + kingdom_theocracy:0 "Grand Theocracy" + emperor_theocracy_male:0 "Divine Emperor" + emperor_theocracy_female:0 "Divine Empress" + empire_theocracy:0 "Holy Empire" + + #Default Clan tiers + baron_clan_male:0 "Headman" + baron_clan_female:0 "Headwoman" + barony_clan:0 "Tribe" + count_clan_male:0 "Chieftain" + count_clan_female:0 "Chieftess" + county_clan:0 "Chiefdom" + duke_clan_male:0 "High Chief" + duke_clan_female:0 "High Chieftess" + duchy_clan:0 "High Chiefdom" + king_clan_male:0 "Patriarch" + king_clan_female:0 "Matriarch" + kingdom_clan:0 "Clan" + emperor_clan_male:0 "Grand Patriarch" + emperor_clan_female:0 "Grand Matriarch" + empire_clan:0 "Grand Clan" + + #Default Tribal/Nomadic tiers + baron_tribal_male:0 "Headman" + baron_tribal_female:0 "Headwoman" + barony_tribal:0 "Tribe" + barony_nomadic: "Settlement" + barony_herder: "Hamlets" + count_tribal_male:0 "Chieftain" + count_tribal_female:0 "Chieftess" + county_tribal:0 "Chiefdom" + duke_tribal_male:0 "High Chieftain" + duke_tribal_female:0 "High Chieftess" + duchy_tribal:0 "High Chiefdom" + king_tribal_male:0 "King" + king_tribal_female:0 "Queen" + kingdom_tribal:0 "Kingdom" + emperor_tribal_male:0 "High King" + emperor_tribal_female:0 "High Queen" + empire_tribal:0 "High Kingdom" + county_herder: "[Character.GetCapitalLocation.GetTerrain.GetNameNoTooltip]" + + #Default Mercenary tiers + baron_mercenary_male:0 "Lieutenant" + baron_mercenary_female:0 "Lieutenant" + barony_mercenary:0 "Band" + count_mercenary_male:0 "Constable" + count_mercenary_female:0 "Constable" + county_mercenary:0 "Host" + duke_mercenary_male:0 "Captain" + duke_mercenary_female:0 "Captain" + duchy_mercenary:0 "Company" + king_mercenary_male:0 "General" + king_mercenary_female:0 "Generaless" + kingdom_mercenary:0 "Army" + emperor_mercenary_male:0 "Grand General" + emperor_mercenary_female:0 "Grand Generaless" + empire_mercenary:0 "Grand Armada" + + #Default Military Order tiers + baron_holy_order_male:0 "Sergeant" + baron_holy_order_female:0 "Sergeant" + barony_holy_order:0 "Chapter" + count_holy_order_male:0 "Master" + count_holy_order_female:0 "Mistress" + county_holy_order:0 "Host" + duke_holy_order_monastic_male: "Abbot General" + duke_holy_order_monastic_female: "Abbess General" + duke_holy_order_male:0 "Grandmaster" + duke_holy_order_female:0 "Grandmistress" + duchy_holy_order:0 "Order" + king_holy_order_male:0 "Grandmaster" + king_holy_order_female:0 "Grandmistress" + kingdom_holy_order:0 "Sacred Order" + emperor_holy_order_male:0 "Grand Master" + emperor_holy_order_female:0 "Grand Mistress" + empire_holy_order:0 "Most Sacred Order" + + muslim_holy_order_male: "Ghazi" + muslim_holy_order_female: "Ghaziah" + byzantine_holy_order_male: "Katepano" + byzantine_holy_order_female: "Katepanissa" + + # Default Monastic Order tiers + # Christian/Buddhist monastic order tiers + baron_monastic_order_abbot_type_male: "Abbot" + baron_monastic_order_abbot_type_female: "Abbess" + barony_monastic_order: "Monastery" + count_monastic_order_abbot_type_male: "Abbot" + count_monastic_order_abbot_type_female: "Abbess" + county_monastic_order: "Abbey" + duke_monastic_order_abbot_type_male: "Abbot" + duke_monastic_order_abbot_type_female: "Abbess" + duchy_monastic_order: "Order" + king_monastic_order_abbot_type_male: "Archabbot" + king_monastic_order_abbot_type_female: "Archabbess" + kingdom_monastic_order: "Sacred Order" + emperor_monastic_order_abbot_type_male: "Abbot General" + emperor_monastic_order_abbot_type_female: "Abbess General" + empire_monastic_order: "Most Sacred Order" + + # default monastic order tiers + baron_monastic_order_male: "Master" + baron_monastic_order_female: "Mistress" + count_monastic_order_male: "Master" + count_monastic_order_female: "Mistress" + duke_monastic_order_male: "Sage" + duke_monastic_order_female: "Sage" + king_monastic_order_male: "Sage" + king_monastic_order_female: "Sage" + emperor_monastic_order_male: "Great Sage" + emperor_monastic_order_female: "Great Sage" + +# Default Faction Leader + faction_leader_male:0 "Leader" + faction_leader_female:0 "Leader" + +############################################## +#Theocracy titles, religious (group) localization. + +# Bon +# Buddhism +# Christianity +# Dualism +# Germanic +# Hellenism +# Hinduism +# Islam +# Jainism +# Judaism +# Magyarism +# Paganism +# Baltic +# Slavic +# Finno-Ugric +# Taoism +# Tengrism +# West African +# West African Bori +# West African Roog +# Zoroastrianism +# Zunism + +# Bon + baron_theocracy_male_bon_religion:0 "Priest" + baron_theocracy_female_bon_religion:0 "Priestess" + barony_theocracy_bon_religion:0 "Vihara" + count_theocracy_male_bon_religion:0 "High Priest" + count_theocracy_female_bon_religion:0 "High Priestess" + county_theocracy_bon_religion:0 "Great Vihara" + duchy_theocracy_bon_religion:0 "Theocracy" + king_theocracy_male_bon_religion:0 "Grand Priest" + king_theocracy_female_bon_religion:0 "Grand Priestess" + kingdom_theocracy_bon_religion:0 "Grand Theocracy" + emperor_theocracy_male_bon_religion:0 "Samrat" + emperor_theocracy_female_bon_religion:0 "Samrajni" + empire_theocracy_bon_religion:0 "Holy Concord" + +# Buddhism + baron_theocracy_male_buddhism_religion:0 "Bhikkhu" + baron_theocracy_female_buddhism_religion:0 "Bhikkhu" + barony_theocracy_buddhism_religion: "Vihara" + count_theocracy_male_buddhism_religion:0 "Bhikkhu" + count_theocracy_female_buddhism_religion:0 "Bhikkhu" + duke_theocracy_male_buddhism_religion:0 "Bhikkhu" + duke_theocracy_female_buddhism_religion:0 "Bhikkhu" + king_theocracy_male_buddhism_religion:0 "Bhikkhu" + king_theocracy_female_buddhism_religion:0 "Bhikkhu" + +# Christianity + baron_theocracy_male_christianity_religion:0 "Bishop" + baron_theocracy_female_christianity_religion:0 "Bishopess" + barony_theocracy_christianity_religion:0 "Bishopric" + count_theocracy_male_christianity_religion:0 "[CHARACTER.Custom('GetActualCountTheocracyTitle')]" + count_theocracy_female_christianity_religion:0 "[CHARACTER.Custom('GetActualCountTheocracyTitle')]" + count_theocracy_male_christianity_religion_default: "Prince-Bishop" + count_theocracy_female_christianity_religion_default: "Princess-Bishop" + count_theocracy_male_christianity_religion_archbishop_holder: "Prince-Archbishop" + count_theocracy_female_christianity_religion_archbishop_holder: "Princess-Archbishop" + count_theocracy_male_christianity_religion_archbishop_holder_possessive: "Prince-Archbishop's" + count_theocracy_female_christianity_religion_archbishop_holder_possessive: "Princess-Archbishop's" + count_theocracy_male_christianity_religion_cardinal: "Cardinal" + count_theocracy_female_christianity_religion_cardinal: "Cardinal" + county_theocracy_christianity_religion:0 "Prince-Bishopric" + duke_theocracy_male_christianity_religion_cardinal:0 "Cardinal" + duke_theocracy_female_christianity_religion_cardinal:0 "Cardinal" + duke_theocracy_male_christianity_religion_archbishop_cardinal:0 "Cardinal" + duke_theocracy_female_christianity_religion_archbishop_cardinal:0 "Cardinal" + duke_theocracy_male_christianity_religion:0 "[CHARACTER.Custom('GetActualDukeTheocracyTitle')]" + duke_theocracy_female_christianity_religion:0 "[CHARACTER.Custom('GetActualDukeTheocracyTitle')]" + duke_theocracy_male_christianity_religion_default: "Duke-Bishop" + duke_theocracy_female_christianity_religion_default: "Duchess-Bishop" + duke_theocracy_male_christianity_religion_archbishop_holder: "Duke-Archbishop" + duke_theocracy_female_christianity_religion_archbishop_holder: "Duchess-Archbishop" + duke_theocracy_male_christianity_religion_archbishop_holder_possessive: "Duke-Archbishop's" + duke_theocracy_female_christianity_religion_archbishop_holder_possessive: "Duchess-Archbishop's" + duke_theocracy_male_christianity_religion_archbishop:0 "Prince-Archbishop" + duke_theocracy_female_christianity_religion_archbishop:0 "Princess-Archbishop" + duke_theocracy_male_christianity_religion_clerical_region: "[CHARACTER.Custom('GetActualBishopTitle')]" + duke_theocracy_female_christianity_religion_clerical_region: "[CHARACTER.Custom('GetActualBishopTitle')]" + duke_theocracy_male_catholic_clerical_region_archbishop: "[CHARACTER.Custom('GetActualBishopTitle')]" + duke_theocracy_female_catholic_clerical_region_archbishop: "[CHARACTER.Custom('GetActualBishopTitle')]" + duke_theocracy_male_christian_faith_clerical_region: "[CHARACTER.Custom('GetActualBishopTitle')]" + duke_theocracy_female_christian_faith_clerical_region: "[CHARACTER.Custom('GetActualBishopTitle')]" + duke_theocracy_male_orthodox_clerical_region_metropolitan: "[CHARACTER.Custom('GetActualBishopTitle')]" + duke_theocracy_female_orthodox_clerical_region_metropolitan: "[CHARACTER.Custom('GetActualBishopTitle')]" + duke_theocracy_male_orthodox_clerical_region_archbishopric: "[CHARACTER.Custom('GetActualBishopTitle')]" + duke_theocracy_female_orthodox_clerical_region_archbishopric: "[CHARACTER.Custom('GetActualBishopTitle')]" + duke_theocracy_male_orthodox_clerical_region_exarch: "Exarch" + duke_theocracy_female_orthodox_clerical_region_exarch: "Exarchessa" + duchy_theocracy_christianity_religion: "Duke-Bishopric" + king_theocracy_male_christianity_religion_cardinal: "King-Cardinal" + king_theocracy_female_christianity_religion_cardinal: "Queen-Cardinal" + king_theocracy_male_christianity_religion: "King-Bishop" + king_theocracy_female_christianity_religion: "Queen-Bishop" + kingdom_theocracy_christianity_religion: "Anointed Kingdom" + emperor_theocracy_male_christianity_religion_cardinal: "Emperor-Cardinal" + emperor_theocracy_female_christianity_religion_cardinal: "Empress-Cardinal" + emperor_theocracy_male_christianity_religion:0 "Emperor-Bishop" + emperor_theocracy_female_christianity_religion:0 "Empress-Bishop" + empire_theocracy_christianity_religion:0 "Imperial Church" + + baron_orthodox: "Bishop" + barony_orthodox: "Bishopric" + count_orthodox: "Archbishop" + county_orthodox: "Archbishopric" + duke_orthodox: "Metropolitan" + duchy_orthodox: "Metropolitanate" + king_orthodox: "Patriarch" + kingdom_orthodox: "Patriarchate" + emperor_orthodox: "Ecumenical Patriarch" + empire_orthodox: "Ecumenical Patriarchate" + baron_orthodox_female: "Presbytera" + count_orthodox_female: "Archpresbytera" + duke_orthodox_female: "Protopresbytera" + king_orthodox_female: "Protopresbytera" + emperor_orthodox_female: "Archprotopresbytera" + +# Dualism +#Same as Christianity + +# Germanic + baron_theocracy_male_germanic_religion:0 "Godi" + baron_theocracy_female_germanic_religion:0 "Gydja" + barony_theocracy_germanic_religion:0 "Temple" + count_theocracy_male_germanic_religion:0 "Hofgoði" + count_theocracy_female_germanic_religion:0 "Hofgoði" + county_theocracy_germanic_religion:0 "Great Temple" + king_theocracy_male_germanic_religion:0 "Riksgoði" + king_theocracy_female_germanic_religion:0 "Riksgoði" + emperor_theocracy_male_germanic_religion:0 "Kjárrgoði" + emperor_theocracy_female_germanic_religion:0 "Kjárrgoði" + +# Hellenism + baron_theocracy_male_hellenism_religion:0 "Flamen" + baron_theocracy_female_hellenism_religion:0 "Vestal" + count_theocracy_male_hellenism_religion:0 "High Fetial" + count_theocracy_female_hellenism_religion:0 "High Vestal" + duke_theocracy_male_hellenism_religion:0 "Pontifex" + duke_theocracy_female_hellenism_religion:0 "Pontifex" + duchy_theocracy_hellenism_religion:0 "Pontificium" + king_theocracy_male_hellenism_religion:0 "Oracle" + king_theocracy_female_hellenism_religion:0 "Sybil" + emperor_theocracy_male_hellenism_religion:0 "Grand Oracle" + emperor_theocracy_female_hellenism_religion:0 "Grand Sybil" + +# Hinduism + baron_theocracy_male_hinduism_religion:0 "Pujari" + baron_theocracy_female_hinduism_religion:0 "Pujari" + barony_theocracy_hinduism_religion:0 "Mandir" + count_theocracy_male_hinduism_religion:0 "Pujari" + count_theocracy_female_hinduism_religion:0 "Pujari" + county_theocracy_hinduism_religion:0 "Great Mandir" + duke_theocracy_male_hinduism_religion:0 "Pujari" + duke_theocracy_female_hinduism_religion:0 "Pujari" + king_theocracy_male_hinduism_religion:0 "Pujari" + king_theocracy_female_hinduism_religion:0 "Pujari" + +# Islam + baron_theocracy_male_islam_religion:0 "Mufti" + baron_theocracy_female_islam_religion:0 "Mufti" + barony_theocracy_islam_religion:0 "Mosque" + count_theocracy_male_islam_religion:0 "Sheikh" + count_theocracy_female_islam_religion:0 "Shaykhah" + county_theocracy_islam_religion:0 "Sheikhdom" + duke_theocracy_male_islam_religion:0 "Grand Mufti" + duke_theocracy_female_islam_religion:0 "Grand Mufti" + duchy_theocracy_islam_religion:0 "Grand Mosque" + king_theocracy_male_islam_religion:0 "Caliph" + king_theocracy_female_islam_religion:0 "Calipha" + kingdom_theocracy_islam_religion:0 "Caliphate" + emperor_theocracy_male_islam_religion:0 "Grand Caliph" + emperor_theocracy_female_islam_religion:0 "Grand Calipha" + empire_theocracy_islam_religion:0 "Grand Caliphate" + +# Yazidi + baron_theocracy_male_yazidi_religion:0 "Kochek" + baron_theocracy_female_yazidi_religion:0 "$baron_theocracy_male_yazidi_religion$" + barony_theocracy_yazidi_religion:0 "Shrine" + count_theocracy_male_yazidi_religion:0 "Peshimam" + count_theocracy_female_yazidi_religion:0 "$count_theocracy_male_yazidi_religion$" + county_theocracy_yazidi_religion:0 "Temple" + duke_theocracy_male_yazidi_religion:0 "Pîr" + duke_theocracy_female_yazidi_religion:0 "$duke_theocracy_male_yazidi_religion$" + duchy_theocracy_yazidi_religion:0 "Grand Temple" + king_theocracy_male_yazidi_religion:0 "Sheikh" + king_theocracy_female_yazidi_religion:0 "$king_theocracy_male_yazidi_religion$" + kingdom_theocracy_yazidi_religion:0 "Sheikhdom" + emperor_theocracy_male_yazidi_religion:0 "Baba Sheikh" + emperor_theocracy_female_yazidi_religion:0 "$emperor_theocracy_male_yazidi_religion$" + empire_theocracy_yazidi_religion:0 "Baba Sheikhdom" + +# Jainism + baron_theocracy_male_jainism_religion:0 "Nirgrantha" + baron_theocracy_female_jainism_religion:0 "Nirgrantha" + barony_theocracy_jainism_religion:0 "Derasar" + count_theocracy_male_jainism_religion:0 "Nirgrantha" + count_theocracy_female_jainism_religion:0 "Nirgrantha" + county_theocracy_jainism_religion:0 "Great Derasar" + duke_theocracy_male_jainism_religion:0 "Nirgrantha" + duke_theocracy_female_jainism_religion:0 "Nirgrantha" + king_theocracy_male_jainism_religion:0 "Nirgrantha" + king_theocracy_female_jainism_religion:0 "Nirgrantha" + +# Judaism + baron_theocracy_male_judaism_religion:0 "Rabbi" + baron_theocracy_female_judaism_religion:0 "Rabbi" + barony_theocracy_judaism_religion:0 "Temple" + count_theocracy_male_judaism_religion:0 "Kohen" + count_theocracy_female_judaism_religion:0 "Kohen" + county_theocracy_judaism_religion:0 "Great Temple" + duke_theocracy_male_judaism_religion:0 "Rabban" + duke_theocracy_female_judaism_religion:0 "Rabban" + duchy_theocracy_judaism_religion:0 "Theocracy" + king_theocracy_male_judaism_religion:0 "Nasi" + king_theocracy_female_judaism_religion:0 "Nasi" + kingdom_theocracy_judaism_religion:0 "Grand Theocracy" + emperor_theocracy_male_judaism_religion:0 "Grand Judge" + emperor_theocracy_female_judaism_religion:0 "Grand Judge" + empire_theocracy_judaism_religion:0 "Holy Empire" + +# Magyarism + count_theocracy_male_magyarism_religion:0 "Táltos" + count_theocracy_female_magyarism_religion:0 "Táltos" + duke_theocracy_male_magyarism_religion:0 "High Táltos" + duke_theocracy_female_magyarism_religion:0 "High Táltos" + king_theocracy_male_magyarism_religion:0 "Grand Táltos" + king_theocracy_female_magyarism_religion:0 "Grand Táltos" + emperor_theocracy_male_magyarism_religion:0 "Divine Emperor" + emperor_theocracy_female_magyarism_religion:0 "Divine Empress" + +# Paganism + baron_theocracy_male_paganism_religion:0 "Shaman" + baron_theocracy_female_paganism_religion:0 "Shaman" + barony_theocracy_paganism_religion:0 "Shrine" + count_theocracy_male_paganism_religion:0 "High Shaman" + count_theocracy_female_paganism_religion:0 "High Shaman" + county_theocracy_paganism_religion:0 "Great Shrine" + duke_theocracy_male_paganism_religion:0 "Archpriest" + duke_theocracy_female_paganism_religion:0 "Archpriestess" + duchy_theocracy_paganism_religion:0 "Theocracy" + king_theocracy_male_paganism_religion:0 "Grand Priest" + king_theocracy_female_paganism_religion:0 "Grand Priestess" + kingdom_theocracy_paganism_religion:0 "Grand Theocracy" + emperor_theocracy_male_paganism_religion:0 "Divine Emperor" + emperor_theocracy_female_paganism_religion:0 "Divine Empress" + empire_theocracy_paganism_religion:0 "Holy Empire" + +# Baltic + count_theocracy_male_baltic_religion:0 "Vaidilė" + count_theocracy_female_baltic_religion:0 "Vaidilutė" + duke_theocracy_male_baltic_religion:0 "High Vaidilė" + duke_theocracy_female_baltic_religion:0 "High Vaidilutė" + king_theocracy_male_baltic_religion:0 "Witch-King" + king_theocracy_female_baltic_religion:0 "Witch-Queen" + +# Slavic + count_theocracy_male_slavic_religion:0 "Zhrets" + count_theocracy_female_slavic_religion:0 "Zhritsa" + duke_theocracy_male_slavic_religion:0 "Volkhv" + duke_theocracy_female_slavic_religion:0 "Vedunya" + +# Finno-Ugric + count_theocracy_male_finno_ugric_religion:0 "Noaidi" + count_theocracy_female_finno_ugric_religion:0 "Noaidi" + duke_theocracy_male_finno_ugric_religion:0 "High Noaidi" + duke_theocracy_female_finno_ugric_religion:0 "High Noaidi" + +# Taoism (same as Pagan/Bon) + +# Tengrism (same as Pagan) + +# West African + baron_theocracy_male_west_african_religion:0 "Hogon" + baron_theocracy_female_west_african_religion:0 "Hogon" + count_theocracy_male_west_african_religion:0 "High Hogon" + count_theocracy_female_west_african_religion:0 "High Hogon" + king_theocracy_male_west_african_religion:0 "Grand Hogon" + king_theocracy_female_west_african_religion:0 "Grand Hogon" + +# West African Bori + baron_theocracy_male_west_african_bori_religion:0 "Adjingi" + baron_theocracy_female_west_african_bori_religion:0 "Magadja" + count_theocracy_male_west_african_bori_religion:0 "High Adjingi" + count_theocracy_female_west_african_bori_religion:0 "High Magadja" + king_theocracy_male_west_african_bori_religion:0 "Grand Adjingi" + king_theocracy_female_west_african_bori_religion:0 "Grand Magadja" + +# West African Roog + baron_theocracy_male_west_african_roog_religion:0 "Saltigue" + baron_theocracy_female_west_african_roog_religion:0 "Saltigue" + count_theocracy_male_west_african_roog_religion:0 "High Saltigue" + count_theocracy_female_west_african_roog_religion:0 "High Saltigue" + king_theocracy_male_west_african_roog_religion:0 "Grand Saltigue" + king_theocracy_female_west_african_roog_religion:0 "Grand Saltigue" + +# Zoroastrianism + baron_theocracy_male_zoroastrianism_religion:0 "Herbad" + baron_theocracy_female_zoroastrianism_religion:0 "Herbad" + barony_theocracy_zoroastrianism_religion:0 "Vahram" + count_theocracy_male_zoroastrianism_religion:0 "Mobed" + count_theocracy_female_zoroastrianism_religion:0 "Mobedyar" + duke_theocracy_male_zoroastrianism_religion:0 "Dastur" + duke_theocracy_female_zoroastrianism_religion:0 "Dastuyar" + +# Zunism + baron_theocracy_male_zunism_religion:0 "Sun Guardian" + baron_theocracy_female_zunism_religion:0 "Sun Guardian" + emperor_theocracy_male_zunism_religion:0 "Sun Emperor" + emperor_theocracy_female_zunism_religion:0 "Sun Empress" + + +############################################## +# Theocracy titles, faith localization (for special cases). + +# Shia + baron_theocracy_male_ismaili:0 "Mullah" + baron_theocracy_female_ismaili:0 "Mullah" + count_theocracy_male_ismaili:0 "Ayatollah" + count_theocracy_female_ismaili:0 "Ayatollah" + duke_theocracy_male_ismaili:0 "Grand Ayatollah" + duke_theocracy_female_ismaili:0 "Grand Ayatollah" + +# Orthodox + count_theocracy_male_orthodox:0 "Metropolitan" + count_theocracy_female_orthodox:0 "Metropolitan" + +############################################## +# Special cultural titles (sorted by culture, then government type). + +### Latin ### +# Republic + duke_republic_male_latin_group:0 "Doge" + duke_republic_female_latin_group:0 "Dogaressa" + king_republic_male_latin_group:0 "Serene Doge" + king_republic_female_latin_group:0 "Serene Dogaressa" + +### Roman ### +# Feudal + baron_feudal_male_roman:1 "Baro" + baron_feudal_female_roman:1 "Baronissa" + barony_feudal_roman:1 "Castrum" + count_feudal_male_roman:0 "Comes" + count_feudal_female_roman:1 "Comitissa" + county_feudal_roman:0 "County" + duke_feudal_male_roman:1 "Dux" + duke_feudal_female_roman:1 "Ducissa" + duchy_feudal_roman:0 "Duchy" + king_feudal_male_roman:0 "Rex" + king_feudal_female_roman:0 "Regina" + kingdom_feudal_roman:0 "Regnum" + emperor_feudal_male_roman:1 "Imperator" + emperor_feudal_female_roman:1 "Imperatrix" + empire_feudal_roman:1 "Imperium" + +# Republic + baron_republic_male_roman:0 "Magister" + baron_republic_female_roman:0 "Magistra" + count_republic_male_roman:0 "Praefect" + count_republic_female_roman:0 "Praefect" + duke_republic_male_roman:0 "Tribune" + duke_republic_female_roman:0 "Tribune" + duchy_republic_roman:0 "Duchy" + king_republic_male_roman:0 "Consul" + king_republic_female_roman:0 "Consul" + kingdom_republic_roman:0 "League" + emperor_republic_male_roman:0 "Princeps" + emperor_republic_female_roman:0 "Princess" + empire_republic_roman:0 "Grand Republic" + +# Viceroyalty + baron_viceroyalty_male_roman:0 "Governor" + baron_viceroyalty_female_roman:0 "Governess" + barony_viceroyalty_roman:0 "Province" + count_viceroyalty_male_roman:0 "Governor" + count_viceroyalty_female_roman:0 "Governess" + county_viceroyalty_roman:0 "Province" + duke_viceroyalty_male_roman:0 "Governor" + duke_viceroyalty_female_roman:0 "Governess" + duchy_viceroyalty_roman:0 "Province" + king_viceroyalty_male_roman:1 "Vicar" + king_viceroyalty_female_roman:1 "Vicarissa" + kingdom_viceroyalty_roman:1 "Diocese" + emperor_viceroyalty_male_roman:0 "Princeps" + emperor_viceroyalty_female_roman:1 "Principissa" + empire_viceroyalty_roman:0 "Principate" + +### Greek ### +# Feudal / Imperial + count_feudal_male_greek:0 "Komes" + count_feudal_female_greek:0 "Komitissa" + duke_feudal_male_greek:0 "Doux" + duke_feudal_female_greek:0 "Doukissa" + king_feudal_male_greek:0 "Despot" + king_feudal_female_greek:0 "Despotissa" + kingdom_feudal_greek:0 "Despotate" + emperor_feudal_male_greek:0 "Basileus" + emperor_feudal_female_greek:0 "Basilissa" + +### Byzantine ### +# Republic + duke_republic_male_byzantine_group:1 "Eparch" + duke_republic_female_byzantine_group:1 "Eparchessa" + king_republic_male_byzantine_group:0 "Serene Doge" + king_republic_female_byzantine_group:0 "Serene Dogaressa" + +# Viceroyalty + duke_viceroyalty_male_byzantine_group:0 "Strategos" + duke_viceroyalty_female_byzantine_group: "Strategissa" + duchy_viceroyalty_byzantine_group:0 "Theme" + king_viceroyalty_male_byzantine_group:0 "Exarch" + king_viceroyalty_female_byzantine_group:0 "Exarchessa" + king_viceroyalty_byzantine_group:0 "Exarchate" + emperor_viceroyalty_male_byzantine_group:0 "Grand Exarch" + emperor_viceroyalty_female_byzantine_group:0 "Grand Exarchessa" + empire_viceroyalty_byzantine_group:0 "Grand Exarchate" + +### German ### +# Feudal / Tribal + emperor_feudal_male_german:0 "Kaiser" + emperor_feudal_female_german:0 "Kaiserin" + +### Norse ### +# Feudal / Tribal + baron_feudal_male_norse:0 "Þegn" + baron_feudal_female_norse:0 "Þegn" + count_feudal_male_norse:0 "Jarl" + count_feudal_female_norse:0 "Jarl" + county_feudal_norse:0 "Jarldom" + +### English ### +# Feudal / Tribal + count_feudal_male_english:0 "Earl" + count_feudal_female_english:0 "Countess" + county_feudal_english:0 "Earldom" + +### Anglo-Saxon ### +# Feudal / Tribal + baron_feudal_male_anglo_saxon:0 "Thane" + baron_feudal_female_anglo_saxon:0 "Thane" + + baron_republic_male_anglo_saxon:0 "Reeve" + baron_republic_female_anglo_saxon:0 "Reeve" + barony_republic_anglo_saxon:0 "Borough" + + count_republic_male_anglo_saxon:0 "Sheriff" + count_republic_female_anglo_saxon:0 "Sheriff" + county_republic_anglo_saxon:0 "Shire" + +### Irish ### + +### Pictish ### + count_feudal_male_pictish:0 "Mormaer" + count_feudal_female_pictish:1 "Banmormaer" + county_feudal_pictish:0 "Mormaerdom" + +### Scottish ### + baron_republic_male_scottish:0 "Provost" + baron_republic_female_scottish:0 "Provost" + barony_republic_scottish:0 "Burgh" + + count_republic_male_scottish:0 "Lord Provost" + count_republic_female_scottish:0 "Lady Provost" + +### Hausa ### + count_feudal_female_hausan_independent:0 "Petty Magajiya" + duke_feudal_female_hausan_independent:0 "Magajiya" + king_feudal_female_hausan_independent:0 "Grand Magajiya" + +### Principalities ### +# Feudal/Tribal + duke_feudal_male_prince_independent:0 "Prince" + duke_feudal_female_prince_independent:0 "Princess" + duchy_feudal_prince_independent:0 "Principality" + duke_feudal_male_prince_always:0 "$duke_feudal_male_prince_independent$" + duke_feudal_female_prince_always:0 "$duke_feudal_female_prince_independent$" + duchy_feudal_prince_always:0 "$duchy_feudal_prince_independent$" + +### Grand Principalities ### +# Feudal + king_feudal_male_grand_prince_independent:0 "Grand Prince" + king_feudal_female_grand_prince_independent:0 "Grand Princess" + kingdom_feudal_grand_prince_independent:0 "Grand Principality" + +### Grand Duchies ### +# Feudal + king_feudal_male_grand_duke_independent:0 "Grand Duke" + king_feudal_female_grand_duke_independent:0 "Grand Duchess" + kingdom_feudal_grand_duke_independent:0 "Grand Duchy" + +### Taifas ### +# Feudal / Clan + duke_feudal_male_andalusian_independent:0 "Emir" + duke_feudal_female_andalusian_independent:0 "Emira" + duchy_feudal_andalusian_independent:0 "Taifa" + +### Lombard ### +# Feudal + duke_feudal_male_lombard_independent:0 "Prince" + duke_feudal_female_lombard_independent:0 "Princess" + duchy_feudal_lombard_independent:0 "Principality" + +### Banates ### +# Feudal + duke_feudal_male_ban:0 "Ban" + duke_feudal_female_ban:0 "Ban" + duchy_feudal_ban:0 "Banate" + +### Sardinian ### +# Feudal + barony_feudal_sardinian:0 "Curadoria" + baron_feudal_male_sardinian:0 "Curadore" + baron_feudal_female_sardinian:0 "Curadora" + county_feudal_sardinian:0 "Judicadu" + count_feudal_male_sardinian:0 "Judike" + count_feudal_female_sardinian:0 "Judesa" + duchy_feudal_sardinian:0 "Archonate" + duke_feudal_male_sardinian:0 "Archon" + duke_feudal_female_sardinian:0 "Archonesa" + +### Russian ### +# Feudal + duke_feudal_male_russian:0 "Grand Prince" + duke_feudal_female_russian:0 "Grand Princess" + duchy_feudal_russian:0 "Grand Principality" + emperor_feudal_male_russian:0 "Tsar" + emperor_feudal_female_russian:0 "Tsaritsa" + empire_feudal_russian:0 "Tsardom" + +### Arabic ### +# Feudal / Clan / Tribal + baron_feudal_male_arabic_group:1 "Wālī" + baron_feudal_female_arabic_group:1 "Wālīa" + barony_feudal_arabic_group:1 "Wilāyah" + count_feudal_male_arabic_group:0 "Sheikh" + count_feudal_female_arabic_group:0 "Shaykhah" + county_feudal_arabic_group:0 "Sheikhdom" + duke_feudal_male_arabic_group:0 "Emir" + duke_feudal_female_arabic_group:0 "Emira" + duchy_feudal_arabic_group:0 "Emirate" + king_feudal_male_arabic_group:1 "Malik" + king_feudal_female_arabic_group:1 "Malika" + kingdom_feudal_arabic_group:1 "Malikate" + king_feudal_muslim_male_arabic_group:0 "Sultan" + king_feudal_muslim_female_arabic_group:0 "Sultana" + kingdom_feudal_muslim_arabic_group:0 "Sultanate" + emperor_feudal_male_arabic_group:1 "Malik al-Muazzam" + emperor_feudal_female_arabic_group:1 "Malika al-Muazzama" + empire_feudal_arabic_group:0 "Empire" + +# Republic + baron_republic_male_arabic_group: "Ra'īs" + baron_republic_female_arabic_group: "Ra'īsa" + baron_republic_male_islamic_group: "$baron_republic_male_arabic_group$" + baron_republic_female_islamic_group: "$baron_republic_female_arabic_group$" + count_republic_male_arabic_group: "$baron_republic_male_arabic_group$" + count_republic_female_arabic_group: "$baron_republic_female_arabic_group$" + duke_republic_male_arabic_group: "Emir" + duke_republic_female_arabic_group: "Emir" + king_republic_male_arabic_group: "Malik" + king_republic_female_arabic_group: "Malik" + +### Turkish ### +# Feudal / Clan + baron_feudal_male_turkish:1 "Agha" + baron_feudal_female_turkish:1 "Hanim" + barony_feudal_turkish:1 "Timariot" + count_feudal_male_turkish:1 "Beg" + count_feudal_female_turkish:1 "Begum" + county_feudal_turkish:0 "Beylik" + duke_feudal_male_turkish:1 "Atabeg" + duke_feudal_female_turkish:1 "Atabegum" + duchy_feudal_turkish:1 "Atabegate" + king_feudal_male_turkish:0 "Sultan" + king_feudal_female_turkish:0 "Sultana" + kingdom_feudal_turkish:0 "Sultanate" + emperor_feudal_male_turkish:1 "Sultan al-Muazzam" + emperor_feudal_female_turkish:1 "Sultana al-Muazzama" + empire_feudal_turkish:0 "Empire" + +# Nomadic + count_nomad_male_turkish: "$count_feudal_male_turkish$" + count_nomad_female_turkish: "$count_feudal_female_turkish$" + county_nomad_turkish: "$county_feudal_turkish$" + duke_nomad_male_turkish: "Iltabar" + duke_nomad_female_turkish: "$duke_nomad_male_turkish$" + duchy_nomad_turkish: "Eli" + duke_independent_nomad_male_turkish: "Yabghu" + duke_independent_nomad_female_turkish: "$duke_independent_nomad_male_turkish$" + duchy_independent_nomad_turkish: "Bodun" + +### Iranian ### + duke_khorezm_male_iranian_group: "Khwarezmshah" + duke_khorezm_female_iranian_group: "Khwarezmbanebshen" + duchy_khorezm_iranian_group: "Khwarezmshahdom" +# Feudal / Clan + baron_feudal_male_iranian_group:0 "Argbadh" + baron_feudal_female_iranian_group:1 "$baron_feudal_male_iranian_group$" + barony_feudal_iranian_group:0 "Arg" + count_feudal_male_iranian_group:0 "Marzoban" + count_feudal_female_iranian_group:1 "$count_feudal_male_iranian_group$" + county_feudal_iranian_group:0 "Marzpanate" + duke_feudal_male_iranian_group:0 "Satrap" + duke_feudal_female_iranian_group:1 "$duke_feudal_male_iranian_group$" + duchy_feudal_iranian_group:0 "Satrapy" + duke_feudal_independent_male_iranian_group:2 "[SelectLocalization( CHARACTER.HasLandedTitles, 'PRIMARY_TITLE_BASE_NAME', 'SPOUSE_PRIMARY_TITLE_BASE_NAME' )]shah" + duke_feudal_independent_female_iranian_group:2 "[SelectLocalization( CHARACTER.HasLandedTitles, 'PRIMARY_TITLE_BASE_NAME', 'SPOUSE_PRIMARY_TITLE_BASE_NAME' )]banebshen" + PRIMARY_TITLE_BASE_NAME: "[Character.GetPrimaryTitle.GetBaseNameNoTierNoTooltip]" + SPOUSE_PRIMARY_TITLE_BASE_NAME: "[Character.GetPrimarySpouse.GetPrimaryTitle.GetBaseNameNoTierNoTooltip]" + duchy_feudal_independent_iranian_group:1 "Shahdom" + king_feudal_male_iranian_group:0 "Shah" + king_feudal_female_iranian_group:0 "Banebshen" + kingdom_feudal_iranian_group:1 "Shahdom" + emperor_feudal_male_iranian_group:0 "Shahanshah" + emperor_feudal_female_iranian_group:0 "Banebshenan Banebshen" + empire_feudal_iranian_group:0 "Empire" + + # Muslim Feudal/Clan + baron_feudal_muslim_male_iranian_group:0 "Nā'ib" + baron_feudal_muslim_female_iranian_group:0 "Nā'iba" + barony_feudal_muslim_iranian_group:0 "$barony_feudal_iranian_group$" + count_feudal_muslim_male_iranian_group:0 "Vālī" + count_feudal_muslim_female_iranian_group:0 "Vālīa" + county_feudal_muslim_iranian_group:0 "Vilāyah" + duke_feudal_muslim_male_iranian_group:0 "Amir" + duke_feudal_muslim_female_iranian_group:0 "Amira" + duchy_feudal_muslim_iranian_group:0 "Amirate" + king_feudal_muslim_male_iranian_group:0 "Amir-e Amiran" + king_feudal_muslim_female_iranian_group:0 "Amira-e Amiran" + kingdom_feudal_muslim_iranian_group:0 "Grand Amirate" + # Muslim Iranian Empire titles are the same as non-Muslim Iranian Imperial titles + + ### Islamic Clan Generic ### + #Default Clan tiers + baron_islamic_clan_male:0 "$baron_feudal_male_arabic_group$" + baron_islamic_clan_female:0 "$baron_feudal_female_arabic_group$" + barony_islamic_clan:0 "$barony_feudal_arabic_group$" + count_islamic_clan_male:0 "$count_feudal_male_arabic_group$" + count_islamic_clan_female:0 "$count_feudal_female_arabic_group$" + county_islamic_clan:0 "$county_feudal_arabic_group$" + duke_islamic_clan_male:0 "$duke_feudal_male_arabic_group$" + duke_islamic_clan_female:0 "$duke_feudal_female_arabic_group$" + duchy_islamic_clan:0 "$duchy_feudal_arabic_group$" + king_islamic_clan_male:0 "$king_feudal_muslim_male_arabic_group$" + king_islamic_clan_female:0 "$king_feudal_muslim_female_arabic_group$" + kingdom_islamic_clan:0 "$kingdom_feudal_muslim_arabic_group$" + emperor_islamic_clan_male:0 "$emperor_feudal_male_arabic_group$" + emperor_islamic_clan_female:0 "$emperor_feudal_female_arabic_group$" + empire_islamic_clan:0 "$empire_feudal_arabic_group$" + +### Sogdian ### +# Feudal / Clan + duke_feudal_male_sogdian:0 "Ikhshid" + +### Mongol ### +# Feudal / Clan / Tribal / Nomadic + baron_feudal_male_mongol:0 "Taishi" + +### Uyghur ### +# Feudal / Clan / Tribal / Nomadic + king_feudal_male_uyghur:0 "Idiqut" + king_feudal_female_uyghur:0 "Idiqut" + +### Altaic ### +# Feudal / Tribal / Clan / Nomadic + king_feudal_male_altaic_group:0 "Khan" + king_feudal_female_altaic_group:0 "Khanum" + kingdom_feudal_altaic_group:0 "Khanate" + emperor_feudal_male_altaic_group:0 "Khagan" + emperor_feudal_female_altaic_group:0 "Khatun" + empire_feudal_altaic_group:0 "Khaganate" + +### Dravidian / Indo-Aryan ### +# Feudal / Clan / Tribal + baron_republic_male_indo_aryan: "Nagarapati" + baron_republic_female_indo_aryan: "Nagarapati" + baron_republic_male_dravidian: "Talāra" + baron_republic_female_dravidian: "Talāra" + baron_feudal_male_dravidian_group:0 "Damapati" + baron_feudal_female_dravidian_group:0 "Damapatni" + barony_feudal_dravidian_group:0 "Dama" + count_feudal_male_dravidian_group:0 "Thakur" + count_feudal_female_dravidian_group:0 "Thakurani" + county_feudal_dravidian_group:0 "Thikana" + duke_feudal_male_dravidian_group:0 "Raja" + duke_feudal_female_dravidian_group:0 "Rani" + duchy_feudal_dravidian_group:0 "Raj" + king_feudal_male_dravidian_group:0 "Maharaja" + king_feudal_female_dravidian_group:0 "Maharani" + emperor_feudal_male_dravidian_group:0 "Samrat" + emperor_feudal_female_dravidian_group:0 "Samrajni" + hegemon_male_indic: "Chakravartin" + hegemon_female_indic: "Chakravartini" + samanta:0 "Samanta" + samanta_female:0 "Samanta" + mahasamanta:0 "Mahasamanta" + mahasamanta_female:0 "Mahasamanta" + mahasamantadhipati:0 "Mahasamantadhipati" + mahasamantadhipati_female:0 "Mahasamantadhipati" + + ###Muslim Dravidian / Indo-Aryan ### + # Feudal / Clan / Tribal + count_feudal_male_muslim_dravidian_group:0 "$count_feudal_male_dravidian_group$" + count_feudal_female_muslim_dravidian_group:0 "$count_feudal_female_dravidian_group$" + duke_feudal_muslim_male_dravidian_group:0 "$duke_feudal_muslim_male_iranian_group$" + duke_feudal_muslim_female_dravidian_group:0 "$duke_feudal_muslim_female_iranian_group$" + duchy_feudal_muslim_dravidian_group:0 "$duchy_feudal_muslim_iranian_group$" + kingdom_feudal_muslim_dravidian_group:0 "$kingdom_feudal_muslim_arabic_group$" + king_feudal_muslim_male_dravidian_group:0 "$king_feudal_muslim_male_arabic_group$" + king_feudal_muslim_female_dravidian_group:0 "$king_feudal_muslim_female_arabic_group$" + emperor_feudal_muslim_male_dravidian_group:0 "Padishah" + emperor_feudal_muslim_female_dravidian_group:1 "Shahbanu" + empire_feudal_muslim_dravidian_group:0 "$empire_feudal_arabic_group$" + + #Special Titles: Devaraja + devaraja: "Devaraja" + devarani: "Devarani" + + ## Tai Group ### + baron_feudal_male_tai_group: "Khun" + baron_feudal_female_tai_group: "Khun" + baron_republican_male_tai_group: "Chao" + baron_republican_female_tai_group: "Nang Chao" + baron_theocracy_male_tai_group: "Bhikkhu" + baron_theocracy_female_tai_group: "Bhikkhuni" + barony_feudal_tai_group: "Mueang" + count_feudal_male_tai_group: "Phraya" + count_feudal_female_tai_group: "Nang Phraya" + county_feudal_tai_group: "Phray" + duke_feudal_male_tai_group: "Ratcha" + duke_feudal_female_tai_group: "Ratchinee" + duchy_feudal_tai_group: "Ratch" + king_feudal_female_tai_group: "Maharatchinee" + king_feudal_male_tai_group: "Maharat" + emperor_feudal_male_tai_group: "Devaraja" + emperor_feudal_female_tai_group: "Devarani" + + ## Khmer Group ### + baron_feudal_male_khmer_group: "Khlon" + baron_feudal_female_khmer_group: "Khlon" + barony_feudal_khmer_group: "Sruk" + count_feudal_male_khmer_group: "Khlon" + count_feudal_female_khmer_group: "Khlon" + county_feudal_khmer_group: "Visaya" + duke_feudal_male_khmer_group: "Sdach" + duke_feudal_female_khmer_group: "Sdach" + duchy_feudal_khmer_group: "Nokor" + king_feudal_female_khmer_group: "Maharani" + king_feudal_male_khmer_group: "Maharaja" + emperor_feudal_male_khmer_group: "Samdach" + emperor_feudal_female_khmer_group: "Samdach" + + ## Austronesian Group ### + baron_feudal_male_austronesian_group: "Khlon Sruk" + baron_feudal_female_austronesian_group: "Khlon Sruk" + barony_feudal_austronesian_group: "Sruk" + count_feudal_male_austronesian_group: "Praya" + count_feudal_female_austronesian_group: "Praya" + bhupati: "Bhupati" + bhupati_female: "Bhupati" + county_feudal_austronesian_group: "Pray" + duke_feudal_male_austronesian_group: "Raja" + duke_feudal_female_austronesian_group: "Raja" + duchy_feudal_austronesian_group: "Raj" + king_feudal_female_austronesian_group: "Maharani" + king_feudal_male_austronesian_group: "Maharaja" + emperor_feudal_male_austronesian_group: "Devaraja" + emperor_feudal_female_austronesian_group: "Devarani" + + ###Austronesian Muslim### + baron_feudal_male_austronesian_muslim_group: "$baron_feudal_male_arabic_group$" + baron_feudal_female_austronesian_muslim_group: "$baron_feudal_female_arabic_group$" + barony_feudal_austronesian_muslim_group: "$barony_feudal_arabic_group$" + count_feudal_male_austronesian_muslim_group: "$count_feudal_male_arabic_group$" + count_feudal_female_austronesian_muslim_group: "$count_feudal_female_arabic_group$" + county_feudal_austronesian_muslim_group: "$county_feudal_arabic_group$" + duke_feudal_male_austronesian_muslim_group: "$duke_feudal_male_arabic_group$" + duke_feudal_female_austronesian_muslim_group: "$duke_feudal_female_arabic_group$" + duchy_feudal_austronesian_muslim_group: "$duchy_feudal_arabic_group$" + king_feudal_male_austronesian_muslim_group: "$king_feudal_muslim_male_arabic_group$" + king_feudal_female_austronesian_muslim_group: "$king_feudal_muslim_female_arabic_group$" + kingdom_feudal_austronesian_muslim_group: "$kingdom_feudal_muslim_arabic_group$" + emperor_feudal_male_austronesian_muslim_group: "$emperor_feudal_male_arabic_group$" + emperor_feudal_female_austronesian_muslim_group: "$emperor_feudal_female_arabic_group$" + empire_feudal_austronesian_muslim_group: "$empire_feudal_arabic_group$" + +### GUANCHE (Canary Islands) ### + duchy_guanche:0 "Menceyo" + kingdom_guanche:0 "High Menceyo" + count_male_guanche:0 "Coran" + duke_male_guanche:0 "Menceyato" + king_male_guanche:0 "High Menceyato" + emperor_male_guanche:0 "Petut Menceyato" + count_female_guanche:0 "Chamato" + duke_female_guanche:0 "Menceyata" + king_female_guanche:0 "High Menceyata" + emperor_female_guanche:0 "Mayec Menceyata" + +### OBSOLETE with new division ### West-African ### +# Feudal / Clan / Tribal + baron_feudal_male_west_african_group:0 "Tigui" + baron_feudal_female_west_african_group:0 "Tigua" + count_feudal_male_west_african_group_independent:0 "Jamanatigi" + count_feudal_female_west_african_group_independent:0 "Jamanatiga" + county_feudal_west_african_group:1 "Jamana" + count_feudal_male_west_african_group:0 "Farin" + count_feudal_female_west_african_group:0 "Farina" + duke_feudal_male_west_african_group:0 "Farbas" + duke_feudal_female_west_african_group:0 "Farba" + duchy_feudal_west_african_group:1 "Duchy" + king_feudal_male_west_african_group:1 "Faama" + king_feudal_female_west_african_group:1 "Malika" + kingdom_feudal_west_african_group:1 "Kingdom" + emperor_feudal_male_west_african_group:0 "Mansa" + emperor_feudal_female_west_african_group:0 "Sultana" + empire_feudal_west_african_group:0 "Kurufaba" + + +### Tibetan Group ### +# Feudal / Clan + baron_feudal_male_tibetan_group: "Rtsis Pa" + baron_feudal_female_tibetan_group: "Rtsis Pa" + count_feudal_male_tibetan_group:0 "Ngapo" + count_feudal_female_tibetan_group:0 "Ngamo" + county_feudal_tibetan_group:0 "County" + duke_feudal_male_tibetan_group:0 "Prabhu" + duke_feudal_female_tibetan_group:0 "Mahila" + duchy_feudal_tibetan_group:0 "Duchy" + king_feudal_male_tibetan_group:0 "Gyalpo" + king_feudal_female_tibetan_group:0 "Gyelmo" + kingdom_feudal_tibetan_group:0 "Gyalpo" + emperor_feudal_male_tibetan_group:0 "Tsenpo" + emperor_feudal_female_tibetan_group:0 "Maharani" + empire_feudal_tibetan_group:0 "Empire" + + ### Iberian ### + # Clan + baron_clan_male_iberian_group:0 "$baron_feudal_male_arabic_group$" + baron_clan_female_iberian_group:0 "$baron_feudal_female_arabic_group$" + barony_clan_iberian_group:0 "$barony_feudal_arabic_group$" + count_clan_male_iberian_group:0 "$count_feudal_male_arabic_group$" + count_clan_female_iberian_group:0 "$count_feudal_female_arabic_group$" + county_clan_iberian_group:0 "$county_feudal_arabic_group$" + duke_clan_male_iberian_group:0 "$duke_feudal_male_arabic_group$" + duke_clan_female_iberian_group:0 "$duke_feudal_female_arabic_group$" + duchy_clan_iberian_group:0 "$duchy_feudal_arabic_group$" + king_clan_male_iberian_group:0 "$king_feudal_male_arabic_group$" + king_clan_female_iberian_group:0 "$king_feudal_female_arabic_group$" + kingdom_clan_iberian_group:0 "$kingdom_feudal_arabic_group$" + emperor_clan_male_iberian_group:0 "$emperor_feudal_male_arabic_group$" + emperor_clan_female_iberian_group:0 "$emperor_feudal_female_arabic_group$" + empire_clan_iberian_group:0 "$empire_feudal_arabic_group$" + +#################################################### + +#Princes (children of Kings/Emperors, sorted by culture) + +### Roman ### + prince_male_roman:1 "Princeps" + prince_female_roman:1 "Principissa" + prince_male_roman_empire:0 "Caesar" + prince_female_roman_empire:1 "Caesarissa" + +### Iberian ### + prince_male_iberian_group:0 "Infante" + prince_female_iberian_group:0 "Infanta" + prince_male_iberian_group_empire:0 "Infante" + prince_female_iberian_group_empire:0 "Infanta" + +### Iranian ### + prince_male_iranian_group:0 "Shahzada" + prince_female_iranian_group:0 "Shahdokht" + prince_male_iranian_group_empire:0 "Shahzada" + prince_female_iranian_group_empire:0 "Shahdokht" + +### Dravidian / Indo-Aryan ### + prince_male_dravidian_group:0 "Rajkumar" + prince_female_dravidian_group:0 "Rajkumari" + prince_male_dravidian_group_empire:0 "Rajkumar" + prince_female_dravidian_group_empire:0 "Rajkumari" + +### Southeast Asian + prince_male_southeast_asian_group:0 "$prince_male_dravidian_group$" + prince_female_southeast_asian_group:0 "$prince_female_dravidian_group$" + prince_male_southeast_asian_group_empire:0 "$prince_male_dravidian_group_empire$" + prince_female_southeast_asian_group_empire:0 "$prince_female_dravidian_group_empire$" + + ### Muslim Dravidian / Muslim Indo-Aryan ### + ### Uses Iranian Titles + prince_muslim_male_dravidian_group:0 "$prince_male_iranian_group$" + prince_muslim_female_dravidian_group:0 "$prince_female_iranian_group$" + prince_muslim_male_dravidian_group_empire:0 "$prince_male_iranian_group_empire$" + prince_muslim_female_dravidian_group_empire:0 "$prince_female_iranian_group_empire$" + +## Imperial Prince ## + prince_empire:0 "Prince" + princess_empire:0 "Princess" + + ## Carthaginian Princess and Princess ## + + banim: "Banim" + banut: "Banut" + +#################################################### +#Special titles + ecumenical_patriarch:0 "Ecumenical Patriarch" + ecumenical_matriarch:0 "Ecumenical Matriarch" + pope_male:0 "$christianity_religious_head_title$" + pope_female:0 "$christianity_religious_head_title_female$" + caliph:0 "Caliph" + archduke:0 "Archduke" + archduchess:0 "Archduchess" + archduchy:0 "Archduchy" + title_prince:0 "Prince" + title_princess:0 "Princess" + title_principality:0 "Principality" + swiss_confederation:0 "Confederation" + title_high_king:0 "High King" + title_high_queen:0 "High Queen" + title_high_kingdom:0 "High Kingdom" + count_feudal_male_e_britannia:0 "Earl" + count_feudal_female_e_britannia:0 "Countess" + county_feudal_e_britannia:0 "Earldom" + count_feudal_male_k_wales:0 "Lord" + count_feudal_female_k_wales:0 "Lady" + county_feudal_k_wales:0 "Lordship" + county_isle:0 "Isle" + duke_feudal_brittany:0 "$duke$" + duke_feudal_brittany_female:0 "$duke_female$" + duchy_feudal_brittany:0 "$duchy$" + emperor_male_carthaginian: "Shofet" + emperor_female_carthaginian: "Shofet" + king_male_carthaginian: "Adirim" + king_female_carthaginian: "Adirima" + duke_male_carthaginian: "Rab" + duke_female_carthaginian: "Raba" + count_male_carthaginian: "Baal" + count_female_carthaginian: "Baal'at" + baron_male_carthaginian: "Adonis" + baron_female_carthaginian: "Adonia" + empire_carthaginian: "Sofetut" + kingdom_carthaginian: "Adirut" + duchy_carthaginian: "Rabbut" + county_carthaginian: "Ba'alut" + barony_carthaginian: "Adon'ut" + + dauphin_male_french:0 "Dauphin" + dauphin_female_french:0 "Dauphine" + dauphinate_french:0 "Dauphinate" + + king_feudal_male_k_ireland_irish:0 "High King" + king_feudal_female_k_ireland_irish:0 "High Queen" + kingdom_feudal_k_ireland_irish:0 "High Kingdom" + realm_priest_male:0 "[CHARACTER.GetCouncilTitle]" + realm_priest_female:0 "[CHARACTER.GetCouncilTitle]" + head_of_faith_male:0 "[CHARACTER.GetFaith.ReligiousHeadName|U]" + head_of_faith_female:0 "[CHARACTER.GetFaith.ReligiousHeadNameFemale|U]" + +### Berber ### +# Feudal / Clan + baron_feudal_male_berber_group:0 "Nā'ib" + baron_feudal_female_berber_group:0 "Nā'iba" + barony_feudal_berber_group:0 "Bou" + count_feudal_male_berber_group:0 "Wālī" + count_feudal_female_berber_group:0 "Wālia" + county_feudal_berber_group:0 "Wilāyah" + count_feudal_male_berber_group_independent:0 "Sheikh" + count_feudal_female_berber_group_independent:0 "Shaykha" + county_feudal_berber_group_independent:0 "Sheikhdom" + duke_feudal_male_berber_group:0 "Emir" + duke_feudal_female_berber_group:0 "Emira" + duchy_feudal_berber_group:0 "Emirate" + king_feudal_male_berber_group:0 "Amīr al-Umarā" + king_feudal_female_berber_group:0 "Amīra al-Umarā" + kingdom_feudal_berber_group:0 "Grand Emirate" + emperor_feudal_male_berber_group:0 "Malik al-Mulūk" + emperor_feudal_female_berber_group:0 "Malika al-Mulūk" + empire_feudal_berber_group:0 "Empire" +# Tribal + baron_tribal_male_berber_group:0 "Ra'īs" + baron_tribal_female_berber_group:0 "Ra'īsa" + count_tribal_male_berber_group:0 "Sheikh" + count_tribal_female_berber_group:0 "Shaykha" + county_tribal_berber_group:0 "Sheikdom" + + +### Sahelian ### +# Feudal / Clan / Tribal + baron_feudal_male_sahelian_group:0 "Horo" + baron_feudal_female_sahelian_group:0 "Hora" + count_feudal_male_sahelian_group:0 "Debegume" + count_feudal_female_sahelian_group:0 "Debeguma" + duke_feudal_male_sahelian_group:0 "Nyanyagume" + duke_feudal_female_sahelian_group:0 "Nyanyaguma" + king_feudal_male_sahelian_group:0 "Maghan" + king_feudal_female_sahelian_group:0 "Magha" + emperor_feudal_male_sahelian_group:0 "Kaya Magha" + emperor_feudal_female_sahelian_group:0 "Kaya Magha" + +### Senegambian group ### +# Feudal / Clan / Tribal + baron_feudal_male_senegambian_group:0 "Tigui" + baron_feudal_female_senegambian_group:0 "Tigua" + count_feudal_male_senegambian_group:0 "Geer" + count_feudal_female_senegambian_group:0 "Geera" + duke_feudal_male_senegambian_group:0 "Damel" + duke_feudal_female_senegambian_group:0 "Damela" + king_feudal_male_senegambian_group:0 "Simbago" + king_feudal_female_senegambian_group:0 "Simbaga" + emperor_feudal_male_senegambian_group:0 "Soma" + emperor_feudal_female_senegambian_group:0 "Soma" + +### Yoruba group ### +# Feudal / Clan / Tribal + baron_feudal_male_yoruba_group:0 "Uzama" + baron_feudal_female_yoruba_group:0 "Uzama" + count_feudal_male_yoruba_group:0 "Nana" + count_feudal_female_yoruba_group:0 "Nana" + duke_feudal_male_yoruba_group:0 "Ajapada" + duke_feudal_female_yoruba_group:0 "Ajapada" + king_feudal_male_yoruba_group:0 "Oba" + king_feudal_female_yoruba_group:0 "Oba" + emperor_feudal_male_yoruba_group:0 "Alafin" + emperor_feudal_female_yoruba_group:0 "Alafin" + +### Somalian group ### +# Feudal / Clan / Tribal + baron_feudal_male_somalian_group:0 "Akil" + baron_feudal_female_somalian_group:0 "Akilad" + count_feudal_male_somalian_group:0 "Islan" + count_feudal_female_somalian_group:0 "Islanad" + duke_feudal_male_somalian_group:0 "Gerad" + duke_feudal_female_somalian_group:0 "Geradad" + king_tribal_male_somalian_group:0 "Ughaz" + king_tribal_female_somalian_group:0 "Ughazad" + king_feudal_male_somalian_group:0 "Suldaan" + king_feudal_female_somalian_group:0 "Suldaanad" + emperor_feudal_male_somalian_group:0 "Boqor" + emperor_feudal_female_somalian_group:0 "Boqorad" + +### Central African group ### +# Feudal / Clan / Tribal + baron_feudal_male_central_african_group:0 "Chima Chidibe" + baron_feudal_female_central_african_group:0 "Chima Chidibe" + count_feudal_male_central_african_group:0 "Chima" + count_feudal_female_central_african_group:0 "Chima" + duke_feudal_male_central_african_group:0 "Galadima" + duke_feudal_female_central_african_group:0 "Galadima" + king_feudal_male_central_african_group:0 "Mai" + king_feudal_female_central_african_group:0 "Gumsu" + emperor_feudal_male_central_african_group:0 "Sultan" + emperor_feudal_female_central_african_group:0 "Sultana" + +### Akan group ### +# Feudal / Clan / Tribal + baron_feudal_male_akan_group:0 "Obaatan" + baron_feudal_female_akan_group:0 "Obaatana" + count_feudal_male_akan_group:0 "Nana" + count_feudal_female_akan_group:0 "Nana" + duke_feudal_male_akan_group:0 "Krontihene" + duke_feudal_female_akan_group:0 "Krontihena" + king_feudal_male_akan_group:0 "Omanhene" + king_feudal_female_akan_group:0 "Omanhena" + emperor_feudal_male_akan_group:0 "Akanhene" + emperor_feudal_female_akan_group:0 "Akanhena" + +### Beja ### +# Feudal / Clan / Tribal + baron_feudal_male_beja:0 "Omda" + baron_feudal_female_beja:0 "Omda" + count_feudal_male_beja:0 "Nazir" + count_feudal_female_beja:0 "Nazira" + duke_feudal_male_beja:0 "Emir" + duke_feudal_female_beja:0 "Emira" + king_feudal_male_beja:0 "Malik" + king_feudal_female_beja:0 "Malika" + emperor_feudal_male_beja:0 "Sultan" + emperor_feudal_female_beja:0 "Sultana" + +### Ethiopian ### +# Feudal / Clan / Tribal + count_feudal_male_ethiopian:0 "Ras" + count_feudal_female_ethiopian:0 "Woyzerit" + duke_feudal_male_ethiopian:0 "Mesfin" + duke_feudal_female_ethiopian:0 "Woyzero" + king_feudal_male_ethiopian:0 "Negus" + king_feudal_female_ethiopian:0 "Nigist" + emperor_feudal_male_ethiopian:0 "Negusa Negast" + emperor_feudal_female_ethiopian:0 "Itege" + +### Hausa ### +# Feudal / Clan / Tribal + baron_feudal_male_hausan:0 "Gida" + baron_feudal_female_hausan:0 "Gida" + count_feudal_male_hausan:0 "Sarkin Gadi" + count_feudal_female_hausan:0 "Sarkina Gadi" + duke_feudal_male_hausan:0 "Galadima" + duke_feudal_female_hausan:0 "Magajiya" + king_feudal_male_hausan:1 "Sarkin" + king_feudal_female_hausan:1 "Sarauniya" + emperor_feudal_male_hausan:1 "Sarkin Sarakuna" + emperor_feudal_female_hausan:1 "Sarauniyar Sarauniya" + +### Italic +# Feudal + count_republic_latin_male:0 "Podesta" + count_republic_latin_female:0 "Podestaressa" + +### Swahili ### +# Feudal / Clan / Tribal / Admin + duke_feudal_male_swahili_sultan_independent: "Sultan" + duke_feudal_female_swahili_sultan_independent: "Sultana" + duchy_feudal_swahili_sultan_independent: "Sultanate" + baron_republic_swahili_male: "Tamim" + baron_republic_swahili_female: "Tamim" + +### Administrative + + baron_administrative_male_byzantine_group: "Archon" + baron_administrative_female_byzantine_group: "Archon" + barony_administrative_byzantine_group: "Archontia" + count_administrative_male_byzantine_group: "Tourmarchēs" + count_administrative_female_byzantine_group: "Tourmarchēs" + county_administrative_byzantine_group: "Tourma" + baron_administrative_male_indo_persian_group: "Alim" + baron_administrative_female_indo_persian_group: "Alima" + count_administrative_male_indo_persian_group: "Shiqdar" + count_administrative_female_indo_persian_group: "Shiqdara" + duke_administrative_male_indo_persian_group: "Wali" + duke_administrative_female_indo_persian_group: "Waliyya" + + count_administrative_male: "Magistrate" + count_administrative_female: "Magistrate" + county_administrative: "Magistracy" + duke_administrative_male: "Governor" + duke_administrative_female: "Governess" + duchy_administrative: "Province" + duke_administrative_male_byzantine_group: "Strategos" + duke_administrative_female_byzantine_group: "Strategitissa" + duchy_administrative_byzantine_group: "Theme" + + king_administrative_male: "Viceroy" + king_administrative_female: "Vicereine" + kingdom_administrative: "Viceroyalty" + kingdom_administrative_independent: "$kingdom_feudal$" + king_administrative_independent_male: "$king_feudal_male$" + king_administrative_independent_female: "$king_feudal_female$" + king_administrative_male_byzantine_group: "Catepan" + king_administrative_female_byzantine_group: "Catepanissa" + king_administrative_independent_male_byzantine_group: "Despot" + king_administrative_independent_female_byzantine_group: "Despotissa" + kingdom_administrative_byzantine_group: "Catepanate" + kingdom_administrative_independent_byzantine_group: "Despotate" + emperor_administrative_male_greek: "Basileus" + emperor_administrative_female_greek: "Basilissa" + emperor_of_hindustan_male_admin: "Sultan al-Salațin" + emperor_of_hindustan_female_admin: "Sultan al-Salațin" + + king_administrative_male_roman: "Prefect" + king_administrative_female_roman: "Prefect" + king_administrative_independent_male_roman: "Rex" + king_administrative_independent_female_roman: "Regina" + kingdom_administrative_roman: "Praefectura" + kingdom_administrative_independent_roman: "Regnum" + emperor_administrative_male_roman: "Imperator" + emperor_administrative_female_roman: "Imperatrix" + hegemon_administrative_male_roman: "Augustus" + hegemon_administrative_female_roman: "Augusta" + empire_administrative_roman: "Imperium" + + emperor_administrative_vassal_byzantine_group: "Exarchate" + emperor_administrative_vassal_male_byzantine_group: "Exarch" + emperor_administrative_vassal_female_byzantine_group: "Exarchessa" + + emperor_administrative_vassal_roman: "Diocese" + emperor_administrative_vassal_male_roman: "Vicar" + emperor_administrative_vassal_female_roman: "Vicarissa" + + co_ruler_male: "Co-[SelectLocalization( Character.GetLiege.IsFemale, 'co_ruler_male_gender_fallback', 'co_ruler_actual')]" + co_ruler_female: "Co-[SelectLocalization( Character.GetLiege.IsFemale, 'co_ruler_actual', 'co_ruler_female_gender_fallback')]" + co_ruler_actual: "[Character.GetLiegeEvenWhenDead.GetTitleAsNameNoTooltip]" + co_ruler_male_gender_fallback: "[Character.Custom('GetCoRulerDiffGenderBestTitle')]" + co_ruler_female_gender_fallback: "[Character.Custom('GetCoRulerDiffGenderBestTitle')]" + GetCoRulerDiffGenderBestTitle_Spouse: "[Character.GetLiege.GetPrimarySpouse.GetTitleAsNameNoTooltip]" + + custom_imperator_caesar_augustus: "Imperator Caesar Augustus" + + ### Landless Adventurer Camps + duke_landless_adventurer_male_camp: "Captain" + duke_landless_adventurer_female_camp: "Captain" + duchy_landless_adventurer_camp: "Camp" + spouse_landless_adventurer_male: "Master" + spouse_landless_adventurer_holder_female: "Mistress" + + duke_landless_adventurer_camp_mercenaries: "Captain" + duke_landless_adventurer_camp_wanderers: "[Character.Custom('MistressMaster')|U]" + duke_landless_adventurer_camp_scholars: "[Character.Custom('MistressMaster')|U]" + duke_landless_adventurer_camp_explorers: "Leader" + duke_landless_adventurer_camp_brigands: "Boss" + duke_landless_adventurer_camp_legitimists: "[Character.GetLadyLord|U]" + + duchess_landless_adventurer_camp_mercenaries: "Captain" + duchess_landless_adventurer_camp_wanderers: "[Character.Custom('MistressMaster')|U]" + duchess_landless_adventurer_camp_scholars: "[Character.Custom('MistressMaster')|U]" + duchess_landless_adventurer_camp_explorers: "Leader" + duchess_landless_adventurer_camp_brigands: "Boss" + duchess_landless_adventurer_camp_legitimists: "[Character.GetLadyLord|U]" + + ### Estates + spouse_estate_holder_male: "Lord" + spouse_estate_holder_female: "Lady" + ### Ecclesiastical + spouse_theocracy_female: "Mistress" + spouse_theocracy_male: "Master" + + ### Easter Eggs + lady_in_shadows: "Lady in Shadows" + + ### Additional Flavor Titles + # Margraves + feudal_margrave_male: "Marquess" + feudal_margrave_male_german_group: "Margrave" + feudal_margrave_female: "Marchioness" + feudal_margrave_female_german_group: "Margravine" + feudal_margrave_title: "March" + feudal_margrave_title_german_group: "Margravate" + # Palatins + feudal_palatinate_county_male: "Count Palatine" + feudal_palatinate_county_female: "Countess Palatine" + feudal_palatinate_county_title: "Count Palatinate" + feudal_palatinate_duchy_male: "Palatine" + feudal_palatinate_duchy_female: "Palatine" + feudal_palatinate_duchy_title: "Palatinate" + # Burgraves + feudal_castellan_male: "Castellan" + feudal_castellan_male_german_group: "Burgrave" + feudal_castellan_female: "Castellan" + feudal_castellan_female_german_group: "Burgravine" + feudal_castellan_title: "Castellany" + feudal_castellan_title_german_group: "Burgravate" + + ### Herders + count_herder_male: "Shepherd" + count_herder_female: "Shepherdess" + + # Celestial Admin + hegemon_celestial_male_chinese: "Huángdì" + hegemon_celestial_female_chinese: "$hegemon_celestial_male_chinese$" + spouse_hegemon_celestial_male_chinese: "Húangfū" + spouse_hegemon_celestial_female_chinese: "Húanghòu" + + hegemon_male_chinese: "$hegemon_celestial_male_chinese$" + hegemon_female_chinese: "$hegemon_celestial_male_chinese$" + spouse_hegemon_male_chinese: "$spouse_hegemon_celestial_male_chinese$" + spouse_hegemon_female_chinese: "$spouse_hegemon_celestial_female_chinese$" + emperor_male_chinese_independent: "$hegemon_celestial_male_chinese$" # 皇帝 + emperor_female_chinese_independent: "$hegemon_celestial_male_chinese$" + spouse_emperor_male_chinese_independent: "$spouse_hegemon_celestial_male_chinese$" # 皇夫 + spouse_emperor_female_chinese_independent: "$spouse_hegemon_celestial_female_chinese$" # 皇后 + + emperor_celestial_male_chinese_civilian_governor: "Coordinator" + emperor_celestial_male_chinese_military_governor: "Supreme Commander" + emperor_celestial_male_chinese_protectorate_governor: "Grand Protector-General" + king_celestial_male_chinese_civilian_governor: "Intendant" + king_celestial_male_chinese_military_governor: "Commandant" + king_celestial_male_chinese_protectorate_governor: "Protector-General" + duke_celestial_male_chinese_governor: "Governor" + count_celestial_male_chinese_governor: "Prefect" + baron_celestial_male_chinese_governor: "Magistrate" + + emperor_celestial_female_chinese_civilian_governor: "$spouse_celestial_governor_female$" + emperor_celestial_female_chinese_military_governor: "$spouse_celestial_governor_female$" + king_celestial_female_chinese_civilian_governor: "$spouse_celestial_governor_female$" + king_celestial_female_chinese_military_governor: "$spouse_celestial_governor_female$" + duke_celestial_female_chinese_governor: "$spouse_celestial_governor_female$" + count_celestial_female_chinese_governor: "$spouse_celestial_governor_female$" + baron_celestial_female_chinese_governor: "$spouse_celestial_governor_female$" + + emperor_celestial_female_chinese_civilian_governess: "$emperor_celestial_male_chinese_civilian_governor$" + emperor_celestial_female_chinese_military_governess: "$emperor_celestial_male_chinese_military_governor$" + emperor_celestial_female_chinese_protectorate_governess: "$emperor_celestial_male_chinese_protectorate_governor$" + king_celestial_female_chinese_civilian_governess: "$king_celestial_male_chinese_civilian_governor$" + king_celestial_female_chinese_military_governess: "$king_celestial_male_chinese_military_governor$" + king_celestial_female_chinese_protectorate_governess: "$king_celestial_male_chinese_protectorate_governor$" + duke_celestial_female_chinese_governess: "$duke_celestial_male_chinese_governor$" + count_celestial_female_chinese_governess: "$count_celestial_male_chinese_governor$" + baron_celestial_female_chinese_governess: "$baron_celestial_male_chinese_governor$" + + emperor_celestial_male_chinese_civilian_governess: "$spouse_celestial_governor_male$" + emperor_celestial_male_chinese_military_governess: "$spouse_celestial_governor_male$" + king_celestial_male_chinese_civilian_governess: "$spouse_celestial_governor_male$" + king_celestial_male_chinese_military_governess: "$spouse_celestial_governor_male$" + duke_celestial_male_chinese_governess: "$spouse_celestial_governor_male$" + count_celestial_male_chinese_governess: "$spouse_celestial_governor_male$" + baron_celestial_male_chinese_governess: "$spouse_celestial_governor_male$" + + hegemony_celestial_chinese: "Hegemony" + empire_celestial_chinese_vassal: "Secretariat" + empire_celestial_chinese_protectorate_vassal: "Grand Protectorate" + kingdom_celestial_chinese_vassal: "Circuit" + kingdom_celestial_chinese_protectorate_vassal: "Protectorate" + duchy_celestial_chinese_vassal: "Province" + county_celestial_chinese_vassal: "Prefecture" + barony_celestial_chinese_vassal: "District" + + spouse_celestial_governor_female: "Lady" + spouse_celestial_governor_male: "Gentleman" + + prince_male_celestial_chinese: "Imperial Prince" + princess_female_celestial_chinese: "Imperial Princess" + + celestial_estate_holder_male: "Gentleman" + celestial_estate_holder_female: "Lady" + + celestial_empress_dowager: "Empress Dowager" + + baron_republic_male_chinese: "Ward Head" + + # Ministers + minister_chancellor_male: "Grand Chancellor" + minister_chancellor_female: "Grand Chancellor" + minister_censor_male: "Imperial Censor" + minister_censor_female: "Imperial Censor" + minister_grand_marshal_male: "Grand Marshal" + minister_grand_marshal_female: "Grand Marshal" + minister_any_male: "Minister" + minister_any_female: "Minister" + + jiedushi: "Jiédùshǐ" # Military Commissioner + dudu: "Dūdū" # Commander-in-Chief + cishi: "Cìshǐ" # Regional Prefect + jinglueshi: "Jīnglüèshǐ" # Pacification Commissioner + + emperor_celestial_male_chinese_independent: "Huángdì" # 皇帝 + emperor_celestial_female_chinese_independent: "$hegemon_celestial_male_chinese$" + spouse_emperor_celestial_male_chinese_independent: "Húangfū" # 皇夫 + spouse_emperor_celestial_female_chinese_independent: "Húanghòu" # 皇后 + + clerical_elector_duchy_cardinalate: "Cardinalate" + + christian_saint: "St." + christian_female_saint: "St." + muslim_saint: "Wali" + muslim_female_saint: "Waliyya" + hellenic_saint: "Divus" + hellenic_female_saint: "Diva" + jain_saint: "Siddha" + shinto_saint: "Kami" + confucian_saint: "Xianru" # 先儒 + buddhist_saint: "Ārya" + taoist_saint: "Zhenren" # 真人 + jewish_saint: "Tzadik" + jewish_female_saint: "Tzadeket" + venerated_ancestor: "Venerated Ancestor" + cardinal_male: "Cardinal" + cardinal_female: "Cardinal" diff --git a/localization/english/replace/dlc/pam/pam_flavorization_l_english.yml b/localization/english/replace/dlc/pam/pam_flavorization_l_english.yml new file mode 100644 index 000000000..b7ccd22a9 --- /dev/null +++ b/localization/english/replace/dlc/pam/pam_flavorization_l_english.yml @@ -0,0 +1,12 @@ +l_english: + clerical_region_duchy_fallback: "$clerical_region_duchy_catholic$" + clerical_region_duchy_catholic: "Archdiocese" + clerical_region_duchy_west_christian: "$clerical_region_duchy_catholic$" + clerical_region_duchy_orthodox: "$d_et_metropolitanate_prefix$" + clerical_region_duchy_east_christian: "$d_et_metropolitanate_prefix$" + clerical_region_duchy_patriarchate: "Patriarchate" + clerical_region_duchy_metropolitanate: "$d_et_metropolitanate_prefix$" + clerical_region_duchy_archbishopric: "Archbishopric" + clerical_region_duchy_exarchate: "Exarchate" + clerical_elector_cardinalate: "Cardinalate" + monastery_christian: "Monastery" From ac857e9959f34298d5c5461acdee0f467b8c57ff Mon Sep 17 00:00:00 2001 From: Thakia Date: Fri, 2 Oct 2026 22:46:17 -0300 Subject: [PATCH 5/5] council_positions updated files --- .../00_council_positions.txt | 446 ++++++++++-------- .../01_ministry_positions.txt | 44 +- 2 files changed, 268 insertions(+), 222 deletions(-) diff --git a/common/council_positions/00_council_positions.txt b/common/council_positions/00_council_positions.txt index 0767195fc..dda52d9e1 100644 --- a/common/council_positions/00_council_positions.txt +++ b/common/council_positions/00_council_positions.txt @@ -1,6 +1,6 @@ councillor_chancellor = { skill = diplomacy - + name = { first_valid = { triggered_desc = { @@ -51,8 +51,8 @@ } valid_position = { - NOR = { - government_has_flag = government_is_landless_adventurer + NOR = { + government_has_flag = government_is_landless_adventurer government_has_flag = government_is_nomadic } } @@ -124,11 +124,8 @@ } on_fired_from_position = { - fired_from_council_position_effect = yes - } - - on_lose_position = { fired_minister_position_effect = yes + fired_from_council_position_effect = yes } portrait_animation = chancellor @@ -141,7 +138,7 @@ councillor_steward = { skill = stewardship - + name = { first_valid = { triggered_desc = { @@ -202,13 +199,10 @@ councillor_steward = { desc = game_concept_steward_desc } } - - auto_fill = { - } - + valid_position = { - NOR = { - government_has_flag = government_is_landless_adventurer + NOR = { + government_has_flag = government_is_landless_adventurer government_has_flag = government_is_nomadic } } @@ -266,11 +260,8 @@ councillor_steward = { } on_fired_from_position = { - fired_from_council_position_effect = yes - } - - on_lose_position = { fired_minister_position_effect = yes + fired_from_council_position_effect = yes } portrait_animation = steward @@ -283,7 +274,7 @@ councillor_steward = { councillor_marshal = { skill = martial - + name = { first_valid = { triggered_desc = { @@ -344,13 +335,10 @@ councillor_marshal = { desc = game_concept_marshal_desc } } - - auto_fill = { - } valid_position = { - NOR = { - government_has_flag = government_is_landless_adventurer + NOR = { + government_has_flag = government_is_landless_adventurer government_has_flag = government_is_nomadic } } @@ -414,11 +402,8 @@ councillor_marshal = { } on_fired_from_position = { - fired_from_council_position_effect = yes - } - - on_lose_position = { fired_minister_position_effect = yes + fired_from_council_position_effect = yes } portrait_animation = marshal @@ -431,7 +416,7 @@ councillor_marshal = { councillor_spymaster = { skill = intrigue - + name = { first_valid = { triggered_desc = { @@ -492,9 +477,6 @@ councillor_spymaster = { desc = game_concept_spymaster_desc } } - - auto_fill = { - } valid_position = { NOT = { government_has_flag = government_is_landless_adventurer } @@ -554,13 +536,10 @@ councillor_spymaster = { } on_fired_from_position = { + fired_minister_position_effect = yes fired_from_council_position_effect = yes } - on_lose_position = { - fired_minister_position_effect = yes - } - use_for_scheme_phase_duration = yes use_for_scheme_resistance = yes @@ -590,8 +569,8 @@ councillor_court_chaplain = { always = no } trigger_else = { - faith = { - NOT = { has_doctrine_parameter = clerical_appointment_ruler } + rite = { + NOT = { rite_has_parameter = clerical_appointment_ruler } } } } @@ -606,52 +585,39 @@ councillor_court_chaplain = { } custom_description = { text = "court_chaplain_cant_fire_doctrines" - faith = { - NOT = { has_doctrine_parameter = clerical_appointment_fixed } - } + can_appoint_own_court_chaplain_trigger = yes } } } - + can_reassign = { trigger_if = { limit = { - NAND = { - government_has_flag = government_has_merit - highest_held_title_tier >= tier_hegemony - } + tgp_has_access_to_ministry_trigger = no } custom_description = { text = "court_chaplain_cant_reassign_doctrines" OR = { - faith = { - NOT = { has_doctrine_parameter = clerical_appointment_fixed } - } + can_appoint_own_court_chaplain_trigger = yes NOT = { exists = cp:councillor_court_chaplain } } } } } - + can_change_once = { - faith = { - has_doctrine_parameter = clerical_appointment_fixed - } - NAND = { - government_has_flag = government_has_merit - highest_held_title_tier >= tier_hegemony - } + can_appoint_own_court_chaplain_trigger = no exists = cp:councillor_court_chaplain } - + inherit = no - + name = { first_valid = { triggered_desc = { trigger = { highest_held_title_tier >= tier_hegemony - government_has_flag = government_has_merit + government_has_flag = government_has_merit } desc = councillor_court_chaplain_celestial_government_imperial } @@ -702,21 +668,46 @@ councillor_court_chaplain = { } triggered_desc = { trigger = { - faith = { - OR = { - has_doctrine = doctrine_theocracy_temporal - religion = { is_in_family = rf_pagan } - } + OR = { + religion = religion:eastern_orthodox_religion + religion = religion:catholic_religion + religion = religion:protestant_religion + } + government_has_flag = government_is_theocracy + exists = scope:councillor + scope:councillor = { + is_ruler = no } } - desc = actual_bishop_title + desc = councillor_court_chaplain_confessor } triggered_desc = { trigger = { - faith = { + exists = scope:councillor + scope:councillor = { + faith.religion = faith:catholic.religion + } + } + desc = councillor_actual_bishop_title + } + triggered_desc = { + trigger = { + exists = scope:councillor + rite = { + OR = { + rite_has_doctrine = doctrine_theocracy_temporal + faith.religion = { is_in_family = rf_pagan } + } + } + } + desc = councillor_actual_bishop_title + } + triggered_desc = { + trigger = { + rite = { NOR = { - has_doctrine = doctrine_theocracy_temporal - religion = { is_in_family = rf_pagan } + rite_has_doctrine = doctrine_theocracy_temporal + faith.religion = { is_in_family = rf_pagan } } } } @@ -724,45 +715,45 @@ councillor_court_chaplain = { first_valid = { #Shia # triggered_desc = { -# trigger = { highest_held_title_tier >= tier_empire faith = faith:ismaili } +# trigger = { highest_held_title_tier >= tier_empire rite = rite:ismaili } # desc = councillor_court_chaplain_ismaili_empire # } # triggered_desc = { -# trigger = { highest_held_title_tier >= tier_kingdom faith = faith:ismaili } +# trigger = { highest_held_title_tier >= tier_kingdom rite = rite:ismaili } # desc = councillor_court_chaplain_ismaili_kingdom # } #Islam triggered_desc = { - trigger = { highest_held_title_tier >= tier_empire faith.religion = faith:aqlani.religion } + trigger = { highest_held_title_tier >= tier_empire faith.religion = faith:sunni.religion } desc = councillor_court_chaplain_islam_empire } triggered_desc = { - trigger = { highest_held_title_tier >= tier_kingdom faith.religion = faith:aqlani.religion } + trigger = { highest_held_title_tier >= tier_kingdom faith.religion = faith:sunni.religion } desc = councillor_court_chaplain_islam_kingdom } triggered_desc = { - trigger = { highest_held_title_tier >= tier_duchy faith.religion = faith:aqlani.religion } + trigger = { highest_held_title_tier >= tier_duchy faith.religion = faith:sunni.religion } desc = councillor_court_chaplain_islam_duchy } triggered_desc = { - trigger = { highest_held_title_tier < tier_duchy faith.religion = faith:aqlani.religion } + trigger = { highest_held_title_tier < tier_duchy faith.religion = faith:sunni.religion } desc = councillor_court_chaplain_islam_county } #Yazidi triggered_desc = { - trigger = { highest_held_title_tier >= tier_empire faith.religion = faith:yazidi.religion } + trigger = { highest_held_title_tier >= tier_empire faith.religion = faith:yazidi_faith.religion } desc = councillor_court_chaplain_yazidi_empire } triggered_desc = { - trigger = { highest_held_title_tier >= tier_kingdom faith.religion = faith:yazidi.religion } + trigger = { highest_held_title_tier >= tier_kingdom faith.religion = faith:yazidi_faith.religion } desc = councillor_court_chaplain_yazidi_kingdom } triggered_desc = { - trigger = { highest_held_title_tier >= tier_duchy faith.religion = faith:yazidi.religion } + trigger = { highest_held_title_tier >= tier_duchy faith.religion = faith:yazidi_faith.religion } desc = councillor_court_chaplain_yazidi_duchy } triggered_desc = { - trigger = { highest_held_title_tier < tier_duchy faith.religion = faith:yazidi.religion } + trigger = { highest_held_title_tier < tier_duchy faith.religion = faith:yazidi_faith.religion } desc = councillor_court_chaplain_yazidi_county } desc = councillor_court_chaplain @@ -783,7 +774,7 @@ councillor_court_chaplain = { } triggered_desc = { trigger = { - faith = { has_doctrine = doctrine_theocracy_temporal } + rite = { rite_has_doctrine = doctrine_theocracy_temporal } } desc = game_concept_realm_priest_desc } @@ -817,9 +808,10 @@ councillor_court_chaplain = { } pool_character_config = pool_court_chaplain - + valid_character = { exists = root.liege_or_court_owner + trigger_if = { # If the liege has a ministry, we check a separate minister trigger limit = { root.liege_or_court_owner = { tgp_has_access_to_ministry_trigger = yes } @@ -831,10 +823,10 @@ councillor_court_chaplain = { } tgp_is_ceremonial_liege_trigger = no } - + valid_position = { - NOR = { - government_has_flag = government_is_landless_adventurer + NOR = { + government_has_flag = government_is_landless_adventurer government_has_flag = government_is_nomadic } } @@ -842,57 +834,28 @@ councillor_court_chaplain = { on_get_position = { got_council_position_effect = yes got_minister_position_effect = { MINISTER_TITLE = e_minister_of_rites MINISTER_POSITION = councillor_court_chaplain } + christian_clergy_learn_liturgical_language_effect = yes + # Only fixes the automatic fill, since a see vacated by death has already been inherited + if = { + limit = { + is_ruler = no + liege = { + rite = { rite_has_parameter = has_clerical_regions } # As at game start. The trigger below, not the doctrine, is what exempts owners who pick their own + can_appoint_own_court_chaplain_trigger = no + } + } + liege = { + assign_landed_realm_priest_effect = yes + } + if = { + limit = { is_councillor = no } + move_to_pool = yes + } + } if = { limit = { years_from_game_start >= 1 } - if = { - limit = { - is_ruler = no - liege = { - faith = { has_doctrine = doctrine_clerical_succession_spiritual_fixed_appointment } - any_vassal = { - is_physically_able_adult = yes - is_councillor = no - government_has_flag = government_is_theocracy - can_be_court_chaplain_trigger = { COURT_OWNER = liege } - faith = liege.faith - } - } - } - liege = { - random_vassal = { - limit = { - is_physically_able_adult = yes - is_councillor = no - government_has_flag = government_is_theocracy - can_be_court_chaplain_trigger = { COURT_OWNER = liege } - faith = liege.faith - } - weight = { - base = 1 - modifier = { - add = 1000 - faith.religious_head ?= this - } - modifier = { - add = learning - } - modifier = { - add = primary_title.tier - } - } - liege = { - assign_councillor_type = { - type = councillor_court_chaplain - remove_existing_councillor = yes - target = prev - } - } - } - } - move_to_pool = yes - } if = { limit = { exists = this @@ -910,9 +873,9 @@ councillor_court_chaplain = { } 5 = { trigger = { - can_start_scheme = { - type = learn_language - target_character = liege + can_start_scheme = { + type = learn_language + target_character = liege } } start_scheme = { @@ -936,11 +899,118 @@ councillor_court_chaplain = { } on_fired_from_position = { + fired_minister_position_effect = yes fired_from_council_position_effect = yes + # We send a toast for the same petition catalyst, because the council UI shows nothing + if = { + limit = { + scope:councillor_liege ?= { + OR = { + religion = religion:eastern_orthodox_religion + religion = religion:catholic_religion + religion = religion:protestant_religion + } + government_is_religious_trigger = no + exists = top_participant_group:the_christian_church + NOT = { has_character_flag = pam_church_replacing_realm_priest } + NOT = { exists = root.clerical_elector_title } + } + situation:the_christian_church ?= { + situation_top_has_catalyst = catalyst_the_christian_church_requested_realm_priest_replacement + } + } + scope:councillor_liege = { + send_interface_toast = { + title = pam_replaced_own_realm_priest_toast + left_icon = this + right_icon = root + custom_tooltip = { + text = pam_replaced_own_realm_priest_catalyst_tt + situation:the_christian_church = { + trigger_situation_catalyst = catalyst_the_christian_church_requested_realm_priest_replacement + } + } + } + } + } + if = { + limit = { + exists = root.faith.religious_head + root.faith.religious_head != root + scope:councillor_liege ?= { + this != root.faith.religious_head + government_is_religious_trigger = no + OR = { + religion = religion:eastern_orthodox_religion + religion = religion:catholic_religion + religion = religion:protestant_religion + } + exists = top_participant_group:the_christian_church + } + } + save_scope_as = pam_dismissed_realm_priest + root.faith.religious_head = { save_scope_as = pam_slighted_religious_head } + scope:councillor_liege = { + send_interface_toast = { + title = pam_fired_realm_priest_toast + left_icon = scope:pam_slighted_religious_head + right_icon = scope:pam_dismissed_realm_priest + scope:pam_slighted_religious_head = { + add_opinion = { + target = scope:councillor_liege + modifier = pam_fired_realm_priest_opinion + } + } + } + } + } } on_lose_position = { - fired_minister_position_effect = yes + # We promote first, because clearing the Realm Priest link first made puppeteer?= fail + if = { + limit = { + is_alive = yes + is_clergy = yes + is_ai = yes + any_held_title = {} + OR = { + NOT = { liege ?= scope:councillor_liege } + puppeteer ?= scope:councillor_liege + } + scope:councillor_liege = { + can_have_theological_agent_puppet_trigger = yes + NOT = { + exists = puppet:external_theological_agent_puppet + } + } + } + if = { + limit = { puppeteer ?= scope:councillor_liege } + hidden_effect = { clear_puppet_status = yes } + } + scope:councillor_liege = { + send_interface_toast = { + type = event_toast_effect_good + title = make_external_clerical_puppet_on_action_notification + left_icon = scope:councillor_liege + right_icon = root + set_puppet = { + target = root + type = external_theological_agent_puppet + } + } + } + } + else_if = { + limit = { + is_alive = yes + is_clergy = yes + puppeteer ?= scope:councillor_liege + is_puppet_of_type = theological_agent_puppet + } + clear_puppet_status = yes + } } portrait_animation = chaplain @@ -1028,7 +1098,7 @@ councillor_spouse = { #Tibetan Feudal/Clan triggered_desc = { trigger = { - highest_held_title_tier = tier_empire + highest_held_title_tier >= tier_empire OR = { government_has_flag = government_is_feudal government_has_flag = government_is_clan @@ -1131,7 +1201,7 @@ councillor_spouse = { #Dravidian/Indo-Aryan Feudal/Clan/Tribal triggered_desc = { trigger = { - highest_held_title_tier = tier_empire + highest_held_title_tier >= tier_empire OR = { government_has_flag = government_is_feudal government_has_flag = government_is_clan @@ -1218,7 +1288,7 @@ councillor_spouse = { #Mongolic and Turkic All triggered_desc = { trigger = { - highest_held_title_tier = tier_empire + highest_held_title_tier >= tier_empire OR = { government_has_flag = government_is_feudal government_has_flag = government_is_clan @@ -1253,7 +1323,7 @@ councillor_spouse = { #Iranian Feudal/Clan triggered_desc = { trigger = { - highest_held_title_tier = tier_empire + highest_held_title_tier >= tier_empire OR = { government_has_flag = government_is_feudal government_has_flag = government_is_clan @@ -1310,7 +1380,7 @@ councillor_spouse = { #Turkish Feudal/Clan triggered_desc = { trigger = { - highest_held_title_tier = tier_empire + highest_held_title_tier >= tier_empire OR = { government_has_flag = government_is_feudal government_has_flag = government_is_clan @@ -1391,7 +1461,7 @@ councillor_spouse = { #Arabic Feudal/Clan/Tribal triggered_desc = { trigger = { - highest_held_title_tier = tier_empire + highest_held_title_tier >= tier_empire OR = { government_has_flag = government_is_feudal government_has_flag = government_is_tribal @@ -1453,7 +1523,7 @@ councillor_spouse = { #Russian Feudal triggered_desc = { trigger = { - highest_held_title_tier = tier_empire + highest_held_title_tier >= tier_empire government_has_flag = government_is_feudal culture = { has_name_list = name_list_russian } } @@ -1493,7 +1563,7 @@ councillor_spouse = { #German Feudal/Tribal triggered_desc = { trigger = { - highest_held_title_tier = tier_empire + highest_held_title_tier >= tier_empire OR = { government_has_flag = government_is_feudal government_has_flag = government_is_tribal @@ -1522,7 +1592,7 @@ councillor_spouse = { #Greek Feudal triggered_desc = { trigger = { - highest_held_title_tier = tier_empire + highest_held_title_tier >= tier_empire government_has_flag = government_is_feudal culture = { has_name_list = name_list_greek } } @@ -1547,7 +1617,7 @@ councillor_spouse = { #Roman Republic triggered_desc = { trigger = { - highest_held_title_tier = tier_empire + highest_held_title_tier >= tier_empire government_has_flag = government_is_republic culture = { has_name_list = name_list_roman } } @@ -1588,7 +1658,7 @@ councillor_spouse = { #Roman Feudal triggered_desc = { trigger = { - highest_held_title_tier = tier_empire + highest_held_title_tier >= tier_empire government_has_flag = government_is_feudal culture = { has_name_list = name_list_roman } } @@ -1646,7 +1716,7 @@ councillor_spouse = { #Tribal Default triggered_desc = { trigger = { - highest_held_title_tier = tier_empire + highest_held_title_tier >= tier_empire government_has_flag = government_is_tribal } desc = emperor_tribal_male @@ -1682,7 +1752,7 @@ councillor_spouse = { #Clan Default triggered_desc = { trigger = { - highest_held_title_tier = tier_empire + highest_held_title_tier >= tier_empire government_has_flag = government_is_clan } desc = emperor_clan_male @@ -1718,7 +1788,7 @@ councillor_spouse = { #Republic Default triggered_desc = { trigger = { - highest_held_title_tier = tier_empire + highest_held_title_tier >= tier_empire government_has_flag = government_is_republic } desc = emperor_republic_male @@ -1769,14 +1839,14 @@ councillor_spouse = { #Feudal/Default Fallback triggered_desc = { trigger = { - highest_held_title_tier = tier_empire + highest_held_title_tier >= tier_empire NOR = { #The following governments have "Spouses" government_has_flag = government_is_theocracy government_has_flag = government_is_mercenary government_has_flag = government_is_holy_order AND = { is_independent_ruler = no - government_allows = administrative + government_has_mechanic = administrative } tgp_is_any_minister = yes } @@ -1792,7 +1862,7 @@ councillor_spouse = { government_has_flag = government_is_holy_order AND = { is_independent_ruler = no - government_allows = administrative + government_has_mechanic = administrative } } } @@ -1807,7 +1877,7 @@ councillor_spouse = { government_has_flag = government_is_holy_order AND = { is_independent_ruler = no - government_allows = administrative + government_has_mechanic = administrative } } } @@ -1822,7 +1892,7 @@ councillor_spouse = { government_has_flag = government_is_holy_order AND = { is_independent_ruler = no - government_allows = administrative + government_has_mechanic = administrative } } } @@ -1837,7 +1907,7 @@ councillor_spouse = { government_has_flag = government_is_holy_order AND = { is_independent_ruler = no - government_allows = administrative + government_has_mechanic = administrative } } } @@ -1868,7 +1938,7 @@ councillor_spouse = { #Tibetan Feudal/Clan triggered_desc = { trigger = { - highest_held_title_tier = tier_empire + highest_held_title_tier >= tier_empire OR = { government_has_flag = government_is_feudal government_has_flag = government_is_clan @@ -1971,7 +2041,7 @@ councillor_spouse = { #Dravidian/Indo-Aryan Feudal/Clan/Tribal triggered_desc = { trigger = { - highest_held_title_tier = tier_empire + highest_held_title_tier >= tier_empire OR = { government_has_flag = government_is_feudal government_has_flag = government_is_clan @@ -2058,7 +2128,7 @@ councillor_spouse = { #Mongolic and Turkic All triggered_desc = { trigger = { - highest_held_title_tier = tier_empire + highest_held_title_tier >= tier_empire OR = { government_has_flag = government_is_feudal government_has_flag = government_is_clan @@ -2093,7 +2163,7 @@ councillor_spouse = { #Iranian non-Muslim Feudal/Clan triggered_desc = { trigger = { - highest_held_title_tier = tier_empire + highest_held_title_tier >= tier_empire OR = { government_has_flag = government_is_feudal government_has_flag = government_is_clan @@ -2205,7 +2275,7 @@ councillor_spouse = { #Turkish Feudal/Clan triggered_desc = { trigger = { - highest_held_title_tier = tier_empire + highest_held_title_tier >= tier_empire OR = { government_has_flag = government_is_feudal government_has_flag = government_is_clan @@ -2286,7 +2356,7 @@ councillor_spouse = { #Arabic Feudal/Clan/Tribal triggered_desc = { trigger = { - highest_held_title_tier = tier_empire + highest_held_title_tier >= tier_empire OR = { government_has_flag = government_is_feudal government_has_flag = government_is_tribal @@ -2348,7 +2418,7 @@ councillor_spouse = { #Russian Feudal triggered_desc = { trigger = { - highest_held_title_tier = tier_empire + highest_held_title_tier >= tier_empire government_has_flag = government_is_feudal culture = { has_name_list = name_list_russian } } @@ -2388,7 +2458,7 @@ councillor_spouse = { #German Feudal/Tribal triggered_desc = { trigger = { - highest_held_title_tier = tier_empire + highest_held_title_tier >= tier_empire OR = { government_has_flag = government_is_feudal government_has_flag = government_is_tribal @@ -2417,7 +2487,7 @@ councillor_spouse = { #Greek Feudal triggered_desc = { trigger = { - highest_held_title_tier = tier_empire + highest_held_title_tier >= tier_empire government_has_flag = government_is_feudal culture = { has_name_list = name_list_greek } } @@ -2434,7 +2504,7 @@ councillor_spouse = { #Roman Republic triggered_desc = { trigger = { - highest_held_title_tier = tier_empire + highest_held_title_tier >= tier_empire government_has_flag = government_is_republic culture = { has_name_list = name_list_roman } } @@ -2475,7 +2545,7 @@ councillor_spouse = { #Roman Feudal triggered_desc = { trigger = { - highest_held_title_tier = tier_empire + highest_held_title_tier >= tier_empire government_has_flag = government_is_feudal culture = { has_name_list = name_list_roman } } @@ -2533,7 +2603,7 @@ councillor_spouse = { #Tribal Default triggered_desc = { trigger = { - highest_held_title_tier = tier_empire + highest_held_title_tier >= tier_empire government_has_flag = government_is_tribal } desc = emperor_tribal_female @@ -2569,7 +2639,7 @@ councillor_spouse = { #Clan Default triggered_desc = { trigger = { - highest_held_title_tier = tier_empire + highest_held_title_tier >= tier_empire government_has_flag = government_is_clan } desc = emperor_clan_female @@ -2605,7 +2675,7 @@ councillor_spouse = { #Republic Default triggered_desc = { trigger = { - highest_held_title_tier = tier_empire + highest_held_title_tier >= tier_empire government_has_flag = government_is_republic } desc = emperor_republic_female @@ -2658,14 +2728,14 @@ councillor_spouse = { #Feudal/Default Fallback triggered_desc = { trigger = { - highest_held_title_tier = tier_empire + highest_held_title_tier >= tier_empire NOR = { #The following governments have "Spouses" government_has_flag = government_is_theocracy government_has_flag = government_is_mercenary government_has_flag = government_is_holy_order AND = { is_independent_ruler = no - government_allows = administrative + government_has_mechanic = administrative } tgp_is_any_minister = yes } @@ -2681,7 +2751,7 @@ councillor_spouse = { government_has_flag = government_is_holy_order AND = { is_independent_ruler = no - government_allows = administrative + government_has_mechanic = administrative } } } @@ -2696,7 +2766,7 @@ councillor_spouse = { government_has_flag = government_is_holy_order AND = { is_independent_ruler = no - government_allows = administrative + government_has_mechanic = administrative } } } @@ -2711,7 +2781,7 @@ councillor_spouse = { government_has_flag = government_is_holy_order AND = { is_independent_ruler = no - government_allows = administrative + government_has_mechanic = administrative } } } @@ -2726,7 +2796,7 @@ councillor_spouse = { government_has_flag = government_is_holy_order AND = { is_independent_ruler = no - government_allows = administrative + government_has_mechanic = administrative } } } @@ -2783,7 +2853,7 @@ councillor_vizier = { auto_fill = yes can_fire = yes can_reassign = yes - + name = councillor_vizier tooltip = councillor_vizier_desc @@ -2827,14 +2897,14 @@ councillor_kurultai_1 = { valid_character = { exists = root.liege_or_court_owner - can_be_kurultai_trigger = { - COURT_OWNER = root.liege_or_court_owner + can_be_kurultai_trigger = { + COURT_OWNER = root.liege_or_court_owner CP1 = councillor_kurultai_2 CP2 = councillor_kurultai_3 CP3 = councillor_kurultai_4 } } - + council_owner_modifier = { name = learn_on_the_job_modifier diplomacy = 1 @@ -2921,14 +2991,14 @@ councillor_kurultai_2 = { valid_character = { exists = root.liege_or_court_owner - can_be_kurultai_trigger = { - COURT_OWNER = root.liege_or_court_owner + can_be_kurultai_trigger = { + COURT_OWNER = root.liege_or_court_owner CP1 = councillor_kurultai_1 CP2 = councillor_kurultai_3 CP3 = councillor_kurultai_4 } } - + council_owner_modifier = { name = learn_on_the_job_modifier diplomacy = 1 @@ -3015,14 +3085,14 @@ councillor_kurultai_3 = { valid_character = { exists = root.liege_or_court_owner - can_be_kurultai_trigger = { - COURT_OWNER = root.liege_or_court_owner + can_be_kurultai_trigger = { + COURT_OWNER = root.liege_or_court_owner CP1 = councillor_kurultai_1 CP2 = councillor_kurultai_2 CP3 = councillor_kurultai_4 } } - + council_owner_modifier = { name = learn_on_the_job_modifier diplomacy = 1 @@ -3109,14 +3179,14 @@ councillor_kurultai_4 = { valid_character = { exists = root.liege_or_court_owner - can_be_kurultai_trigger = { - COURT_OWNER = root.liege_or_court_owner + can_be_kurultai_trigger = { + COURT_OWNER = root.liege_or_court_owner CP1 = councillor_kurultai_1 CP2 = councillor_kurultai_2 CP3 = councillor_kurultai_3 } } - + council_owner_modifier = { name = learn_on_the_job_modifier diplomacy = 1 diff --git a/common/council_positions/01_ministry_positions.txt b/common/council_positions/01_ministry_positions.txt index e23a84508..2761de674 100644 --- a/common/council_positions/01_ministry_positions.txt +++ b/common/council_positions/01_ministry_positions.txt @@ -1,6 +1,6 @@ minister_personnel = { skill = diplomacy - + name = minister_personnel valid_position = { @@ -8,9 +8,6 @@ } tooltip = game_concept_minister_of_personnel_desc - - auto_fill = { - } modifier = { name = minister_personnel_modifier @@ -55,11 +52,8 @@ } on_fired_from_position = { - fired_from_council_position_effect = yes - } - - on_lose_position = { fired_minister_position_effect = yes + fired_from_council_position_effect = yes } portrait_animation = happy_teacher @@ -72,7 +66,7 @@ minister_justice = { skill = learning - + name = minister_justice valid_position = { @@ -80,9 +74,6 @@ minister_justice = { } tooltip = game_concept_minister_of_justice_desc - - auto_fill = { - } modifier = { name = minister_justice_modifier @@ -127,11 +118,8 @@ minister_justice = { } on_fired_from_position = { - fired_from_council_position_effect = yes - } - - on_lose_position = { fired_minister_position_effect = yes + fired_from_council_position_effect = yes } portrait_animation = page_flipping @@ -144,14 +132,11 @@ minister_justice = { minister_works = { skill = stewardship - + name = minister_works tooltip = game_concept_minister_of_works_desc - - auto_fill = { - } - + valid_position = { tgp_has_access_to_ministry_trigger = yes } @@ -207,11 +192,8 @@ minister_works = { } on_fired_from_position = { - fired_from_council_position_effect = yes - } - - on_lose_position = { fired_minister_position_effect = yes + fired_from_council_position_effect = yes } portrait_animation = minister_works @@ -224,14 +206,11 @@ minister_works = { minister_grand_marshal = { skill = martial - + name = minister_grand_marshal tooltip = game_concept_minister_grand_marshal_desc - - auto_fill = { - } - + valid_position = { tgp_has_access_to_ministry_trigger = yes } @@ -284,11 +263,8 @@ minister_grand_marshal = { } on_fired_from_position = { - fired_from_council_position_effect = yes - } - - on_lose_position = { fired_minister_position_effect = yes + fired_from_council_position_effect = yes } portrait_animation = grand_marshal