From aa63931a99711ad40f55c31fef9b8daa6cd28a3b Mon Sep 17 00:00:00 2001 From: Mazik_kun <84410981+sumankun@users.noreply.github.com> Date: Fri, 24 Nov 2023 22:31:44 +0300 Subject: [PATCH] events folder 1.11.1 --- .../hold_court_events_general.txt | 6 +- .../activities/hunt_activity/hunt_events.txt | 29 +- .../pilgrimage_activity/pilgrimage_events.txt | 1 + .../playdate_activity/playdate_events.txt | 29 +- .../tournaments/tournament_events.txt | 1 - .../tournaments/veronica_locale_events.txt | 7 +- .../court_chaplain_task_events.txt | 173 ++ .../court_events/sumptuary_debate_events.txt | 22 +- events/court_maintenance_events.txt | 6 +- .../death_events/death_management_events.txt | 19 + .../major_decisions_events.txt | 25 +- .../minor_decision_events.txt | 5 +- .../{ => diarchy_events}/diarchy_events.txt | 33 +- events/dlc/bp1/bp1_yearly.txt | 2 +- events/dlc/bp1/bp1_yearly_events_claudia.txt | 6 +- .../dlc/bp2/bp2_child_of_destiny_events.txt | 17 +- events/dlc/bp2/bp2_hostage_system.txt | 16 + events/dlc/bp2/bp2_yearly_7.txt | 40 +- .../dlc/ep1/ep1_fund_inspiration_events.txt | 501 +++- events/dlc/ep2/ep2_tournament_events.txt | 13 +- .../ep2/wedding_events/ep2_wedding_events.txt | 19 + .../fp1_scandinavian_adventurer_events.txt | 4 +- events/dlc/fp3/fp3_clan_events_ola.txt | 2293 +++++++++++++++ .../fp3_clan_events_persia_specific_ola.txt | 403 +++ .../dlc/fp3/fp3_dynasty_decision_events.txt | 1283 ++++++++ events/dlc/fp3/fp3_extra_flavor_events.txt | 1 + events/dlc/fp3/fp3_frontier_story_cycle.txt | 1 + events/dlc/fp3/fp3_heritage_events.txt | 1 + events/dlc/fp3/fp3_misc_decision_events.txt | 2600 +++++++++++++++++ .../dlc/fp3/fp3_religious_decision_events.txt | 1 + events/dlc/fp3/fp3_scholarship_events.txt | 1658 +++++++++++ ...p3_story_cycle_seljuks_invasion_events.txt | 1 + .../fp3_story_cycle_zanj_rebellion_events.txt | 1 + events/dlc/fp3/fp3_struggle_events.txt | 1 + .../dlc/fp3/fp3_tax_collector_events_ola.txt | 1463 ++++++++++ events/dlc/fp3/fp3_yearly_events_eren.txt | 875 ++++++ events/dlc/fp3/fp3_yearly_events_hugo.txt | 272 ++ .../dlc/fp3/fp3_yearly_events_ola_batch_1.txt | 1 + events/dlc/fp3/fp3_yearly_frontier_chains.txt | 1 + .../child_personality_events.txt | 25 +- .../childhood_education_events.txt | 66 +- events/error_suppression_events.txt | 3 + events/factions/faction_demands.txt | 64 +- events/government_events/clan_events.txt | 2 +- events/harm_events.txt | 1 + .../intrigue_scheming_events.txt | 10 +- .../learning_scholarship_events.txt | 2 +- .../martial_authority_events.txt | 3 +- .../warfare_lifestyle/warhorse_events.txt | 8 +- events/nickname_events/nickname_events.txt | 1 + .../faith_conversion_events.txt | 2 +- .../religion_events/faith_creation_events.txt | 1 + .../false_conversion_events.txt | 7 +- .../intrigue_scheme_ongoing_events.txt | 26 +- .../learn_language_outcome_events.txt | 3 +- .../assassination_ongoing_events.txt | 1249 ++++++++ .../murder_saves/murder_save_events.txt | 75 +- .../murder_scheme_maintenance_events.txt | 33 +- .../sway_scheme/sway_outcome_events.txt | 21 +- events/single_combat_events.txt | 21 +- events/test_events/debug.txt | 174 +- .../travel_danger_events_arky.txt | 8 +- .../travel_events_cultural_traditions.txt | 9 + events/travel_events/travel_events_fp3.txt | 1615 ++++++++++ events/yearly_events/yearly_events_4.txt | 6 +- 65 files changed, 14863 insertions(+), 402 deletions(-) rename events/{ => diarchy_events}/diarchy_events.txt (99%) create mode 100644 events/dlc/fp3/fp3_clan_events_ola.txt create mode 100644 events/dlc/fp3/fp3_clan_events_persia_specific_ola.txt create mode 100644 events/dlc/fp3/fp3_dynasty_decision_events.txt create mode 100644 events/dlc/fp3/fp3_extra_flavor_events.txt create mode 100644 events/dlc/fp3/fp3_frontier_story_cycle.txt create mode 100644 events/dlc/fp3/fp3_heritage_events.txt create mode 100644 events/dlc/fp3/fp3_misc_decision_events.txt create mode 100644 events/dlc/fp3/fp3_religious_decision_events.txt create mode 100644 events/dlc/fp3/fp3_scholarship_events.txt create mode 100644 events/dlc/fp3/fp3_story_cycle_seljuks_invasion_events.txt create mode 100644 events/dlc/fp3/fp3_story_cycle_zanj_rebellion_events.txt create mode 100644 events/dlc/fp3/fp3_struggle_events.txt create mode 100644 events/dlc/fp3/fp3_tax_collector_events_ola.txt create mode 100644 events/dlc/fp3/fp3_yearly_events_eren.txt create mode 100644 events/dlc/fp3/fp3_yearly_events_hugo.txt create mode 100644 events/dlc/fp3/fp3_yearly_events_ola_batch_1.txt create mode 100644 events/dlc/fp3/fp3_yearly_frontier_chains.txt create mode 100644 events/scheme_events/murder_scheme/assassination_ongoing_events.txt create mode 100644 events/travel_events/travel_events_fp3.txt diff --git a/events/activities/hold_court_activity/hold_court_events_general.txt b/events/activities/hold_court_activity/hold_court_events_general.txt index 86b91e5be4..7da590e4bb 100644 --- a/events/activities/hold_court_activity/hold_court_events_general.txt +++ b/events/activities/hold_court_activity/hold_court_events_general.txt @@ -1,7 +1,7 @@ namespace = hold_court -# Differences in namespace range down to the on-going CD civil war between whether a range starts at 0 or 1. -# It starts at 001 and goes to 000, damn it, and anyone who says otherwise is a knave and a cur. +# Differences in namespace range down to the ongoing CD civil war between whether a range starts at 0 or 1. +## It starts at 001 and goes to 000, damn it, and anyone who says otherwise is a knave and a cur. ################################################## # # RANGES @@ -265,6 +265,8 @@ hold_court.0021 = { option = { name = hold_court.0021.a + # Guaranteed small grandeur reward, in addition to any from events + change_current_court_grandeur = minor_court_grandeur_gain } } diff --git a/events/activities/hunt_activity/hunt_events.txt b/events/activities/hunt_activity/hunt_events.txt index a972fd895a..5edf7f9d4a 100644 --- a/events/activities/hunt_activity/hunt_events.txt +++ b/events/activities/hunt_activity/hunt_events.txt @@ -37,6 +37,7 @@ #hunt.4015 - You walk in (out?) on lovers #hunt.4016 - You fake a catch #hunt.4018 - You get another glimpse of the mystical white animal +#hunt.4020 - Rally your clan to fell a large beast #hunt.5001 - You get the urge to pick herbs and flowers #hunt.5002 - Someone in your hunting party gets the urge to pick herbs and #hunt.5060 - Find an eyas @@ -7525,28 +7526,28 @@ hunt.1080 = { add = 5 aptitude = { court_position = master_of_hunt_court_position - value >= 2 + value >= 1 } } modifier = { add = 5 aptitude = { court_position = master_of_hunt_court_position - value >= 3 + value >= 2 } } modifier = { add = 5 aptitude = { court_position = master_of_hunt_court_position - value >= 4 + value >= 3 } } modifier = { add = 5 aptitude = { court_position = master_of_hunt_court_position - value >= 5 + value >= 4 } } save_scope_as = bodyguard_appears @@ -8165,14 +8166,22 @@ hunt.1081 = { limit = { scope:murderer = { is_alive = yes } } - unknown_murder_effect = { VICTIM = scope:murderer MURDERER = root REASON = death_hunting_mysterious } + unknown_murder_effect = { + VICTIM = scope:murderer + MURDERER = root + REASON = death_hunting_mysterious + } } if = { limit = { exists = scope:accomplice scope:accomplice = { is_alive = yes } } - unknown_murder_effect = { VICTIM = scope:accomplice MURDERER = root REASON = death_hunting_mysterious } + unknown_murder_effect = { + VICTIM = scope:accomplice + MURDERER = root + REASON = death_hunting_mysterious + } } if = { limit = { @@ -9835,7 +9844,7 @@ hunt.2000 = { option = { # Send away name = hunt.2000.d - scope:dog_salesman = { move_to_pool = yes } + scope:dog_salesman = { select_and_move_to_pool_effect = yes } ai_chance = { base = 50 modifier = { @@ -24079,7 +24088,11 @@ hunt.7211 = { # Effect show_as_tooltip = { - unknown_murder_effect = { VICTIM = scope:murder_target MURDERER = root REASON = death_hunting_accident } + unknown_murder_effect = { + VICTIM = scope:murder_target + MURDERER = root + REASON = death_hunting_accident + } } } } diff --git a/events/activities/pilgrimage_activity/pilgrimage_events.txt b/events/activities/pilgrimage_activity/pilgrimage_events.txt index d7923367ba..86f97ac988 100644 --- a/events/activities/pilgrimage_activity/pilgrimage_events.txt +++ b/events/activities/pilgrimage_activity/pilgrimage_events.txt @@ -7001,6 +7001,7 @@ pilgrimage.6001 = { cooldown = { years = 20 } trigger = { has_bp1_dlc_trigger = yes + is_location_valid_for_travel_event_on_land = yes current_travel_plan = { next_destination_progress > 0.5 } trigger_if = { limit = { faith = { like_islam_religion_trigger = yes } } diff --git a/events/activities/playdate_activity/playdate_events.txt b/events/activities/playdate_activity/playdate_events.txt index 64cc05edca..789834d994 100644 --- a/events/activities/playdate_activity/playdate_events.txt +++ b/events/activities/playdate_activity/playdate_events.txt @@ -5083,17 +5083,22 @@ playdate.5004 = { add_stress = minor_stress_loss } - set_relation_friend = { - REASON = friend_joined_game - TARGET = scope:other_child - } - scope:activity = { - add_activity_log_entry = { - key = playdate_became_friends_watching_football_log - tags = { good } - score = 10 - character = root - target = scope:other_child + if = { + limit = { + NOT = { has_relation_friend = scope:other_child } + } + set_relation_friend = { + REASON = friend_joined_game + TARGET = scope:other_child + } + scope:activity = { + add_activity_log_entry = { + key = playdate_became_friends_watching_football_log + tags = { good } + score = 10 + character = root + target = scope:other_child + } } } @@ -6274,7 +6279,7 @@ playdate.5008 = { add_character_modifier = { modifier = bp2_disrespects_elderly_modifier - years = 25 + years = 10 } stress_impact = { diff --git a/events/activities/tournaments/tournament_events.txt b/events/activities/tournaments/tournament_events.txt index 160587bfe0..549ae5a460 100644 --- a/events/activities/tournaments/tournament_events.txt +++ b/events/activities/tournaments/tournament_events.txt @@ -3097,7 +3097,6 @@ tournament_events.1140 = { # Host Challenge - Start character = scope:pas_darmes_instigator animation = happiness } - # TODO_CD_EP2: replace with proper art override_background = { trigger = { scope:activity.activity_location = { geographical_region = graphical_western } diff --git a/events/activities/tournaments/veronica_locale_events.txt b/events/activities/tournaments/veronica_locale_events.txt index 247f4da1e9..a59212a2ad 100644 --- a/events/activities/tournaments/veronica_locale_events.txt +++ b/events/activities/tournaments/veronica_locale_events.txt @@ -424,7 +424,7 @@ ep2_locale_events.5500 = { description = ancient_stone_artifact_desc type = miscellaneous visuals = rock - modifier = artifact_monthly_prestige_4_modifier + modifier = artifact_monthly_prestige_1_modifier save_scope_as = ancient_plaque } scope:ancient_plaque = { @@ -1264,7 +1264,10 @@ ep2_locale_events.5510 = { scope:village_thug = { hidden_effect = { if = { - limit = { NOT = { is_participant_in_activity = scope:activity } } + limit = { + NOT = { is_participant_in_activity = scope:activity } + can_join_activity = scope:activity + } add_to_activity = scope:activity } } diff --git a/events/councillor_task_events/court_chaplain_task_events.txt b/events/councillor_task_events/court_chaplain_task_events.txt index aa7ac5e455..ef4efd546c 100644 --- a/events/councillor_task_events/court_chaplain_task_events.txt +++ b/events/councillor_task_events/court_chaplain_task_events.txt @@ -1526,3 +1526,176 @@ court_chaplain_task.3004 = { } } } + +# Maintenance for vassal conversion messages + +scripted_effect fetch_council_task_affected_vassal_informees_effect = { + scope:county ?= { + holder ?= { + if = { + limit = { + is_ai = no + NOT = { scope:councillor_liege ?= this } + } + add_to_list = informees + } + every_liege_or_above = { + limit = { + is_ai = no + NOT = { scope:councillor_liege ?= this } + highest_held_title_tier < scope:councillor_liege.highest_held_title_tier + } + add_to_list = informees + } + } + } +} + +court_chaplain_task.8000 = { # Started + scope = none + hidden = yes + + trigger = { + # Stop spam if target is changed a lot e.g. on a single tick + exists = scope:councillor.councillor_task_target + scope:set_county.title_province ?= scope:councillor.councillor_task_target + } + + immediate = { + scope:county.faith ?= { save_scope_as = old_faith } + fetch_council_task_affected_vassal_informees_effect = yes + every_in_list = { + list = informees + switch = { + trigger = faith + scope:councillor_liege.faith = { # Good if same faith as liege + send_interface_message = { + type = msg_council_conversion_good + title = liege_converting_county_title + desc = liege_converting_county_desc + left_icon = scope:councillor_liege + right_icon = scope:county + } + } + scope:old_faith = { + send_interface_message = { # Bad if same faith as county + type = msg_council_conversion_bad + title = liege_converting_county_title + desc = liege_converting_county_desc + left_icon = scope:councillor_liege + right_icon = scope:county + } + } + fallback = { + send_interface_message = { # Neutral otherwise + type = msg_council_conversion_neutral + title = liege_converting_county_title + desc = liege_converting_county_desc + left_icon = scope:liege_scope + right_icon = scope:county + } + } + } + } + } +} + +court_chaplain_task.8001 = { # Cancelled + scope = none + hidden = yes + cooldown = { days = 1 } + + trigger = { + NOT = { + scope:county ?= { has_variable = county_conversion_completed } + } + } + + immediate = { + # Message for vassals + scope:county.faith ?= { save_scope_as = old_faith } + fetch_council_task_affected_vassal_informees_effect = yes + every_in_list = { + list = informees + switch = { + trigger = faith + scope:old_faith = { # Good if same faith as county + send_interface_message = { + type = msg_council_conversion_good + title = liege_stopped_converting_county_title + desc = liege_stopped_converting_county_desc + left_icon = scope:councillor_liege + right_icon = scope:county + } + } + scope:councillor_liege.faith = { # Bad if same faith as liege + send_interface_message = { + type = msg_council_conversion_bad + title = liege_stopped_converting_county_title + desc = liege_stopped_converting_county_desc + left_icon = scope:councillor_liege + right_icon = scope:county + } + } + fallback = { + send_interface_message = { # Neutral otherwise + type = msg_council_conversion_neutral + title = liege_converting_county_title + desc = liege_converting_county_desc + left_icon = scope:liege_scope + right_icon = scope:county + } + } + } + } + } +} + +court_chaplain_task.8002 = { # Completed + scope = none + hidden = yes + + immediate = { + scope:county ?= { + set_variable = { + name = county_conversion_completed + weeks = 1 + } + } + fetch_council_task_affected_vassal_informees_effect = yes + every_in_list = { + list = informees + switch = { + trigger = faith + scope:councillor_liege.faith ?= { # Good if same faith as county + send_interface_message = { + type = msg_council_conversion_good + title = liege_converted_county_title + desc = liege_converted_county_desc + left_icon = scope:councillor_liege + right_icon = scope:county + } + } + scope:old_faith ?= { # Bad if same faith as liege + send_interface_message = { + type = msg_council_conversion_bad + title = liege_converted_county_title + desc = liege_converted_county_desc + left_icon = scope:councillor_liege + right_icon = scope:county + } + } + fallback = { + send_interface_message = { # Neutral otherwise + type = msg_council_conversion_neutral + title = liege_converted_county_title + desc = liege_converted_county_desc + left_icon = scope:liege_scope + right_icon = scope:county + } + } + } + } + } +} + diff --git a/events/court_events/sumptuary_debate_events.txt b/events/court_events/sumptuary_debate_events.txt index b947f1b041..6d2134bfb1 100644 --- a/events/court_events/sumptuary_debate_events.txt +++ b/events/court_events/sumptuary_debate_events.txt @@ -220,7 +220,7 @@ court_amenities_interactions.0001 = { base = 100 } } - + #I surrender, opponent gains a weak hook and prestige option = { name = court_amenities_interactions.0001.b @@ -408,6 +408,13 @@ court_amenities_interactions.0003 = { desc = { desc = court_amenities_interactions.0002.desc_intro first_valid = { + #triggered_desc = { + # trigger = { + # has_character_flag = sumptuary_debate_won + # scope:actor.faith = { has_doctrine_parameter = naked_adherents_active } + # } + # desc = court_amenities_interactions.0003.desc_won.nakey + #} triggered_desc = { trigger = { has_character_flag = sumptuary_debate_won @@ -438,6 +445,15 @@ court_amenities_interactions.0003 = { animation = disbelief } animation = schadenfreude + #triggered_outfit = { + # trigger = { + # scope:actor = { + # has_character_flag = sumptuary_debate_lost + # faith = { has_doctrine_parameter = naked_adherents_active } + # } + # } + # outfit_tags = { beggar_rags } + #} triggered_outfit = { trigger = { scope:actor = { @@ -561,7 +577,7 @@ court_amenities_interactions.0004 = { character = scope:victim animation = pain } - + option = { # Let them off with a warning name = court_amenities_interactions.0004.a add_hook = { @@ -569,7 +585,7 @@ court_amenities_interactions.0004 = { target = scope:victim } } - + option = { # Arrest them name = court_amenities_interactions.0004.b add_opinion = { diff --git a/events/court_maintenance_events.txt b/events/court_maintenance_events.txt index 69bda2e28a..5e573bfd60 100644 --- a/events/court_maintenance_events.txt +++ b/events/court_maintenance_events.txt @@ -297,9 +297,13 @@ court_maintenance.0011 = { } cp:councillor_chancellor = { save_scope_as = messenger } } - else = { + else_if = { + limit = { any_vassal = { always = yes } } random_vassal = { save_scope_as = messenger } } + else = { + random_courtier = { save_scope_as = messenger } + } #House banner if = { limit = { diff --git a/events/death_events/death_management_events.txt b/events/death_events/death_management_events.txt index bf39063e72..4aeaae1690 100644 --- a/events/death_events/death_management_events.txt +++ b/events/death_events/death_management_events.txt @@ -6003,6 +6003,25 @@ death_management.0095 = { } } +#Clan Succession Laws: delaying reducing of house unity on house head death, to prevent premature changing of succession laws +death_management.0100 = { + type = character_event + hidden = yes + + immediate = { + house = { + # Needs to be add_unity_value and not add_unity_interaction_effect because add_unity_interaction_effect does not allow only one person to affect unity + # Value and character scopes are saved in on_death effect + add_unity_value = { + value = scope:unity_change + character = scope:dead_house_head + desc = clan_unity_house_head_died.desc + } + } + } +} + + ### KNOW THYSELF PERK: Death is coming soon death_management.9998 = { type = character_event diff --git a/events/decisions_events/major_decisions_events.txt b/events/decisions_events/major_decisions_events.txt index f076d78414..f0b53ad4c6 100644 --- a/events/decisions_events/major_decisions_events.txt +++ b/events/decisions_events/major_decisions_events.txt @@ -25,8 +25,7 @@ major_decisions.0001 = { #by Mathilda Bjarnehed animation = personality_rational } - option = { - name = major_decisions.0001.a + immediate = { show_as_tooltip = { convert_whole_realm_to_feudalism_effect = yes } @@ -44,6 +43,10 @@ major_decisions.0001 = { #by Mathilda Bjarnehed } } } + + option = { + name = major_decisions.0001.a + } } major_decisions.0002 = { #by Linnéa Thimrén @@ -55,12 +58,19 @@ major_decisions.0002 = { #by Linnéa Thimrén animation = personality_rational } - option = { - name = major_decisions.0001.a + immediate = { show_as_tooltip = { - change_government = feudal_government + if = { + limit = { government_has_flag = government_is_clan } + change_government = clan_government + } + else = { change_government = feudal_government } } } + + option = { + name = major_decisions.0001.a + } } ##################################### @@ -987,6 +997,7 @@ major_decisions.3100 = { # special_succession_witengamot_trigger = yes special_succession_thing_trigger = yes special_succession_tanistry_trigger = yes + special_succession_jirga_trigger = yes } } # Warcraft @@ -1002,6 +1013,10 @@ major_decisions.3100 = { limit = { special_succession_tanistry_trigger = yes } special_succession_tanistry_effect = yes } + else_if = { + limit = { special_succession_jirga_trigger = yes } + special_succession_jirga_effect = yes + } ai_chance = { #The AI should always do this. base = 100 } diff --git a/events/decisions_events/minor_decision_events.txt b/events/decisions_events/minor_decision_events.txt index 769502c162..5f04d57840 100644 --- a/events/decisions_events/minor_decision_events.txt +++ b/events/decisions_events/minor_decision_events.txt @@ -4,7 +4,10 @@ # minor_decisions.0001 - invite the knights #invite_claimants_decision -# minor_decisions.0001 - invite the claimants +# minor_decisions.0002 - invite the claimants + +#evict_holy_order_duel +# minor_decisions.0100 - evict_holy_order_duel #Inviting knights for invite_knights_decision minor_decisions.0001 = { diff --git a/events/diarchy_events.txt b/events/diarchy_events/diarchy_events.txt similarity index 99% rename from events/diarchy_events.txt rename to events/diarchy_events/diarchy_events.txt index ec9496af72..d5cdd3f6e6 100644 --- a/events/diarchy_events.txt +++ b/events/diarchy_events/diarchy_events.txt @@ -481,9 +481,21 @@ diarchy.0101 = { } } # And loop it in a bit. - trigger_event = { - id = diarchy.0101 - days = { 365 730 } + ## Sometimes fast. + if = { + limit = { has_diarchy_active_parameter = mandate_tempo_fast } + trigger_event = { + id = diarchy.0101 + days = { 365 730 } + } + } + ## Sometimes slow. + else_if = { + limit = { has_diarchy_active_parameter = mandate_tempo_fast } + trigger_event = { + id = diarchy.0101 + days = { 730 1460 } + } } # Give out manipulation hooks to landless diarchs. diarch = { trigger_event = diarchy.0121 } @@ -879,6 +891,16 @@ diarchy.0131 = { exists = global_var:di_track_imprison_accept_recipient_list exists = global_var:di_track_entr_piety_accept_recipient_list exists = global_var:di_track_entr_piety_decline_recipient_list + exists = global_var:di_track_appviz_accept + exists = global_var:di_track_appviz_accept_actor_list + exists = global_var:di_track_appviz_accept_recipient_list + exists = global_var:di_track_dismviz_accept + exists = global_var:di_track_dismviz_accept_actor_list + exists = global_var:di_track_dismviz_accept_recipient_list + exists = global_var:di_track_vizmulct_accept + exists = global_var:di_track_vizmulct_accept_actor_list + exists = global_var:di_track_vizmulct_accept_recipient_list + #var:struggle_involvement_defender ?= flag:interloper } } } @@ -907,6 +929,11 @@ diarchy.0141 = { + + + + + ################################################## # SCHEMES diff --git a/events/dlc/bp1/bp1_yearly.txt b/events/dlc/bp1/bp1_yearly.txt index 438b81c91f..48a755cd52 100644 --- a/events/dlc/bp1/bp1_yearly.txt +++ b/events/dlc/bp1/bp1_yearly.txt @@ -3253,7 +3253,7 @@ bp1_yearly.5706 = { has_bp1_dlc_trigger = yes # Standard checks. - is_valid_for_narrow_yearly_events = yes + is_valid_for_narrow_yearly_events_adult = yes # Should have a rival with a child any_relation = { diff --git a/events/dlc/bp1/bp1_yearly_events_claudia.txt b/events/dlc/bp1/bp1_yearly_events_claudia.txt index 272a5c53a0..eec01dff77 100644 --- a/events/dlc/bp1/bp1_yearly_events_claudia.txt +++ b/events/dlc/bp1/bp1_yearly_events_claudia.txt @@ -2377,7 +2377,7 @@ bp1_yearly.1040 = { } } theme = friendly - override_background = { reference = relaxing_room } + override_background = { reference = bath_house } left_portrait = { character = root animation = toast @@ -2769,7 +2769,7 @@ bp1_yearly.1050 = { } } theme = unfriendly - override_background = { reference = relaxing_room } + override_background = { reference = bath_house } left_portrait = { character = root animation = disgust @@ -4464,4 +4464,4 @@ bp1_yearly.1082 = { base = 100 } } -} \ No newline at end of file +} diff --git a/events/dlc/bp2/bp2_child_of_destiny_events.txt b/events/dlc/bp2/bp2_child_of_destiny_events.txt index f7fdb552cf..f131ede3a0 100644 --- a/events/dlc/bp2/bp2_child_of_destiny_events.txt +++ b/events/dlc/bp2/bp2_child_of_destiny_events.txt @@ -833,15 +833,30 @@ destiny_child.1020 = { court_position:court_physician_court_position ?= { location = root.location } + } immediate = { + court_position:court_physician_court_position = { save_scope_as = physician } if = { + limit = { + any_courtier_or_guest = { + location = root.location + is_available_ai_adult = yes + has_trait = lifestyle_herbalist + NOT = { + scope:physician = this + } + } + } random_courtier_or_guest = { limit = { location = root.location is_available_ai_adult = yes has_trait = lifestyle_herbalist + NOT = { + scope:physician = this + } } save_scope_as = herbalist } @@ -858,7 +873,7 @@ destiny_child.1020 = { add_trait = lifestyle_herbalist } } - court_position:court_physician_court_position = { save_scope_as = physician } + } #Your time with the physician could be time well spent diff --git a/events/dlc/bp2/bp2_hostage_system.txt b/events/dlc/bp2/bp2_hostage_system.txt index f8a25b1733..108cdd9d0b 100644 --- a/events/dlc/bp2/bp2_hostage_system.txt +++ b/events/dlc/bp2/bp2_hostage_system.txt @@ -997,6 +997,13 @@ bp2_hostage_system.0200 = { scope:my_hostage ?= { is_adult = no } } } + custom_tooltip = { + text = halved_hostage_prestige_tt + add_character_flag = { + flag = halved_hostage_prestige_income + years = hostage_adulthood_retained_halved_prestige_duration_value + } + } scope:hostage_home_court = { show_as_tooltip = { add_opinion = { @@ -1108,6 +1115,13 @@ bp2_hostage_system.0201 = { } trigger = { exists = scope:my_hostage } scope:hostage_warden = { + custom_tooltip = { + text = halved_hostage_prestige_tt + add_character_flag = { + flag = halved_hostage_prestige_income + years = hostage_adulthood_retained_halved_prestige_duration_value + } + } show_as_tooltip = { add_opinion = { modifier = angry_opinion @@ -1146,6 +1160,7 @@ bp2_hostage_system.0202 = { lower_right_portrait = scope:hostage_warden immediate = { + scope:hostage_warden = { custom_tooltip = halved_hostage_prestige_tt } if = { limit = { is_ai = yes } add_opinion = { @@ -1213,6 +1228,7 @@ bp2_hostage_system.0204 = { lower_right_portrait = scope:hostage_home_court immediate = { + scope:hostage_home_court = { custom_tooltip = halved_hostage_prestige_tt } if = { limit = { is_ai = yes } add_opinion = { diff --git a/events/dlc/bp2/bp2_yearly_7.txt b/events/dlc/bp2/bp2_yearly_7.txt index 4b962eb94d..d2fffcdd16 100644 --- a/events/dlc/bp2/bp2_yearly_7.txt +++ b/events/dlc/bp2/bp2_yearly_7.txt @@ -998,7 +998,8 @@ bp2_yearly.7003 = { #Wet Nurse informs you about first words of your child location = root.location } any_child = { - age <= 4 + age < 5 + child_not_infant_trigger = yes is_available_ai = yes location = root.location } @@ -1030,13 +1031,15 @@ bp2_yearly.7003 = { #Wet Nurse informs you about first words of your child } random_child = { limit = { - age <= 4 + age < 5 + child_not_infant_trigger = yes this = root.player_heir is_available_ai = yes location = root.location } alternative_limit = { - age <= 4 + age < 5 + child_not_infant_trigger = yes NOT = { any_sibling = { age > prev.age @@ -1046,7 +1049,8 @@ bp2_yearly.7003 = { #Wet Nurse informs you about first words of your child location = root.location } alternative_limit = { - age <= 4 + age < 5 + child_not_infant_trigger = yes is_available_ai = yes location = root.location } @@ -1317,7 +1321,8 @@ bp2_yearly.7004 = { #Wet Nurse informs you about first steps of your child location = root.location } any_child = { - age <= 4 + age < 5 + child_not_infant_trigger = yes is_available_ai = yes location = root.location } @@ -1349,13 +1354,15 @@ bp2_yearly.7004 = { #Wet Nurse informs you about first steps of your child } random_child = { limit = { - age <= 4 + age < 5 + child_not_infant_trigger = yes this = root.player_heir is_available_ai = yes location = root.location } alternative_limit = { - age <= 4 + age < 5 + child_not_infant_trigger = yes NOT = { any_sibling = { age > prev.age @@ -1365,7 +1372,8 @@ bp2_yearly.7004 = { #Wet Nurse informs you about first steps of your child location = root.location } alternative_limit = { - age <= 4 + age < 5 + child_not_infant_trigger = yes is_available_ai = yes location = root.location } @@ -1511,7 +1519,7 @@ bp2_yearly.7005 = { #Wet Nurse informs you about first fallen teeth of your chil location = root.location } any_child = { - age <= 12 + child_not_teen_trigger = yes is_available_ai = yes location = root.location } @@ -1543,13 +1551,13 @@ bp2_yearly.7005 = { #Wet Nurse informs you about first fallen teeth of your chil } random_child = { limit = { - age <= 12 + child_not_teen_trigger = yes this = root.player_heir is_available_ai = yes location = root.location } alternative_limit = { - age <= 12 + child_not_teen_trigger = yes NOT = { any_sibling = { age > prev.age @@ -1559,7 +1567,7 @@ bp2_yearly.7005 = { #Wet Nurse informs you about first fallen teeth of your chil location = root.location } alternative_limit = { - age <= 12 + child_not_teen_trigger = yes is_available_ai = yes location = root.location } @@ -1732,7 +1740,7 @@ bp2_yearly.7006 = { #Wet Nurse informs you about first independent dress up of y location = root.location } any_child = { - age <= 7 + child_not_teen_trigger = yes is_available_ai = yes location = root.location } @@ -1764,13 +1772,13 @@ bp2_yearly.7006 = { #Wet Nurse informs you about first independent dress up of y } random_child = { limit = { - age <= 7 + child_not_teen_trigger = yes this = root.player_heir is_available_ai = yes location = root.location } alternative_limit = { - age <= 7 + child_not_teen_trigger = yes NOT = { any_sibling = { age > prev.age @@ -1780,7 +1788,7 @@ bp2_yearly.7006 = { #Wet Nurse informs you about first independent dress up of y location = root.location } alternative_limit = { - age <= 7 + child_not_teen_trigger = yes is_available_ai = yes location = root.location } diff --git a/events/dlc/ep1/ep1_fund_inspiration_events.txt b/events/dlc/ep1/ep1_fund_inspiration_events.txt index 146d42d29c..b8780f2e85 100644 --- a/events/dlc/ep1/ep1_fund_inspiration_events.txt +++ b/events/dlc/ep1/ep1_fund_inspiration_events.txt @@ -4142,6 +4142,12 @@ scripted_trigger fund_inspiration_0071_option_aquamanile_trigger = { # These occurred in other faiths too, so we don't restrict their religious usage, but were much more ubiquitous in Islam. like_islam_religion_trigger = yes } +scripted_trigger fund_inspiration_0071_option_incense_burner_sculpture_trigger = { + has_fp3_dlc_trigger = yes + NOT = { exists = scope:smith_type_incense_burner_sculpture_option } + # These occurred in other faiths too, so we don't restrict their religious usage, but were much more ubiquitous in Islam. + like_islam_religion_trigger = yes +} scripted_effect fund_inspiration_0071_pick_options_to_show_effect = { #What options do we show? hidden_effect = { @@ -4192,6 +4198,15 @@ scripted_effect fund_inspiration_0071_pick_options_to_show_effect = { value = yes } } + 50 = { + trigger = { + fund_inspiration_0071_option_incense_burner_sculpture_trigger = yes + } + save_scope_value_as = { + name = smith_type_incense_burner_sculpture_option + value = yes + } + } } } } @@ -4378,7 +4393,26 @@ fund_inspiration.0071 = { } ai_chance = { base = 10 + + } + } + #Incense Burner Sculpture + option = { + name = fund_inspiration.0071.incense_burner_sculpture + trigger = { + exists = scope:smith_type_incense_burner_sculpture_option + } + custom_tooltip = fund_inspiration.you_decide_option_tt + scope:inspiration_owner = { + set_variable = { + name = artifact_smith_type + value = flag:smith_type_incense_burner_sculpture + } + } + ai_chance = { + base = 10 + } } } @@ -4908,6 +4942,42 @@ fund_inspiration.1011 = { } desc = artifact_spear_description } + triggered_desc = { + trigger = { + AND = { + scope:newly_created_artifact = { + has_variable = replica_sassanian_sword + OR = { + rarity = famed + rarity = illustrious + } + } + } + } + desc = famed_replica_sassanian_sword_description + } + triggered_desc = { + trigger = { + AND = { + scope:newly_created_artifact = { + has_variable = replica_sassanian_sword + rarity = masterwork + } + } + } + desc = masterwork_replica_sassanian_sword_description + } + triggered_desc = { + trigger = { + AND = { + scope:newly_created_artifact = { + has_variable = replica_sassanian_sword + rarity = common + } + } + } + desc = common_replica_sassanian_sword_description + } desc = artifact_sword_description } } @@ -6725,6 +6795,12 @@ fund_inspiration.1071 = { } desc = fp2_andalusian_aquamanile_desc } + triggered_desc = { + trigger = { + exists = scope:incense_burner_sculpture + } + desc = fp3_incense_burner_sculpture_desc + } } } } @@ -6789,9 +6865,23 @@ fund_inspiration.1071 = { limit = { scope:inspiration_owner.var:artifact_smith_type = flag:smith_type_goblet } - create_artifact_goblet_effect = { - OWNER = root - SMITH = scope:inspiration_owner + random_list = { + 70 = { + trigger = { + has_fp3_dlc_trigger = yes + scope:inspiration_owner = { artifact_should_use_gfx_type_trigger = { TYPE = iranian_building } } + } + create_artifact_persian_drinking_vessel_effect = { + OWNER = root + SMITH = scope:inspiration_owner + } + } + 30 = { + create_artifact_goblet_effect = { + OWNER = root + SMITH = scope:inspiration_owner + } + } } save_scope_value_as = { name = goblet @@ -6811,6 +6901,21 @@ fund_inspiration.1071 = { value = yes } } + else_if = { + limit = { + scope:inspiration_owner.var:artifact_smith_type = flag:smith_type_incense_burner_sculpture + scope:inspiration_owner = { artifact_should_use_gfx_type_trigger = { TYPE = iranian_building } } + has_fp3_dlc_trigger = yes + } + create_artifact_fp3_incense_burner_sculpture_effect = { + OWNER = root + SMITH = scope:inspiration_owner + } + save_scope_value_as = { + name = incense_burner_sculpture + value = yes + } + } # Add a dedication to the description - fund_inspiration.7001 if = { limit = { @@ -7356,6 +7461,12 @@ fund_inspiration.9001 = { } desc = fund_inspiration.9001.desc_alchemy } + triggered_desc = { + trigger = { + exists = scope:research_inspiration + } + desc = fund_inspiration.9001.desc_research + } } } @@ -7434,6 +7545,12 @@ fund_inspiration.9002 = { } desc = fund_inspiration.9002.desc_alchemy } + triggered_desc = { + trigger = { + exists = scope:research_inspiration + } + desc = fund_inspiration.9002.desc_research + } } } theme = realm @@ -7511,6 +7628,12 @@ fund_inspiration.9003 = { } desc = fund_inspiration.9002.desc_alchemy } + triggered_desc = { + trigger = { + exists = scope:research_inspiration + } + desc = fund_inspiration.9002.desc_research + } } } theme = realm @@ -7671,6 +7794,7 @@ scripted_trigger has_no_inspiration_event_cooldown = { has_character_flag = fund_artisan_inspiration_event_cooldown has_character_flag = fund_smith_inspiration_event_cooldown has_character_flag = fund_alchemy_inspiration_event_cooldown + has_character_flag = fund_research_inspiration_event_cooldown } } @@ -7749,6 +7873,15 @@ scripted_effect add_inspiration_cooldown_flag = { days = { 30 60 } } } + else_if = { + limit = { + inspiration = { has_inspiration_type = research_inspiration } + } + add_character_flag = { + flag = fund_research_inspiration_event_cooldown + days = { 30 60 } + } + } } @@ -9202,14 +9335,10 @@ fund_inspiration.2030 = { } random_list = { 2 = { - scope:inspiration_owner = { - change_artifact_quality_effect = { AMOUNT = 2 } - } + change_artifact_quality_effect = { AMOUNT = 3 } } 2 = { - scope:inspiration_owner = { - change_artifact_quality_effect = { AMOUNT = -2 } - } + change_artifact_quality_effect = { AMOUNT = -3 } } } } @@ -9702,6 +9831,11 @@ fund_inspiration.2050 = { has_trait = education_intrigue } } + NOT = { + scope:inspiration = { + has_inspiration_type = research_inspiration + } + } } trait = education_diplomacy_1 trait = education_diplomacy_2 @@ -10858,6 +10992,7 @@ fund_inspiration.2090 = { has_inspiration_type = weaver_inspiration has_inspiration_type = artisan_inspiration has_inspiration_type = smith_inspiration + has_inspiration_type = research_inspiration trigger_if = { limit = { root.primary_spouse = { @@ -11306,6 +11441,17 @@ fund_inspiration.2110 = { title = fund_inspiration.2110.t desc = { desc = fund_inspiration.2110.desc + random_valid = { + triggered_desc = { + trigger = { + scope:inspiration = { has_inspiration_type = research_inspiration } + } + desc = fund_inspiration.2110.desc.part.2.research + } + triggered_desc = { + desc = fund_inspiration.2110.desc.part.2 + } + } random_valid = { triggered_desc = { trigger = { @@ -11322,6 +11468,9 @@ fund_inspiration.2110 = { triggered_desc = { trigger = { scope:generous_vassal = { + NOT = { + scope:inspiration = { has_inspiration_type = research_inspiration } + } OR = { has_trait = scholar has_trait = theologian @@ -11331,6 +11480,19 @@ fund_inspiration.2110 = { } desc = fund_inspiration.2110.desc.dweeb } + triggered_desc = { + trigger = { + scope:generous_vassal = { + scope:inspiration = { has_inspiration_type = research_inspiration } + OR = { + has_trait = scholar + has_trait = theologian + has_trait = diligent + } + } + } + desc = fund_inspiration.2110.desc.dweeb.research + } triggered_desc = { trigger = { scope:generous_vassal = { has_any_good_relationship_with_root_trigger = yes } @@ -12196,6 +12358,7 @@ fund_inspiration.2130 = { OR = { has_inspiration_type = book_inspiration has_inspiration_type = alchemy_inspiration + has_inspiration_type = research_inspiration } } save_scope_value_as = { @@ -12539,7 +12702,12 @@ scripted_trigger fi_2131_artifact_type_trigger = { } trigger_if = { limit = { - scope:inspiration = { has_inspiration_type = book_inspiration } + scope:inspiration = { + OR = { + has_inspiration_type = book_inspiration + has_inspiration_type = research_inspiration + } + } } artifact_type = book } @@ -16725,24 +16893,11 @@ fund_inspiration.6503 = { #Adventurer took a farmhand as a lover -scripted_trigger adventurer_pregnant_woman_trigger = { - is_male = yes - OR = { - has_sexuality = bisexual - has_sexuality = heterosexual - } -} - -scripted_trigger adventurer_female_lover_trigger = { - is_female = yes - has_sexuality = homosexual -} - fund_inspiration.6504 = { type = character_event title = fund_inspiration.6504.t theme = hunting - desc = { + desc = { desc = fund_inspiration.6500.introduction desc = fund_inspiration.6504.desc first_valid = { @@ -16784,143 +16939,24 @@ fund_inspiration.6504 = { desc = fund_inspiration.6504.lover_ultimatum } } - + override_background = { reference = farmland } - left_portrait = { + left_portrait = { character = scope:inspiration_owner animation = personality_bold } - right_portrait = { + right_portrait = { character = scope:adventurer_lover animation = love } - cooldown = { years = 15 } - - trigger = { - scope:inspiration = { - has_inspiration_type = adventure_inspiration - } - scope:inspiration_owner = { - location ?= { - terrain = farmlands - } - NOR = { - has_trait = chaste - has_trait = infertile - has_trait = celibate - } - might_cheat_on_every_partner_trigger = yes - } - } - - weight_multiplier = { - base = 1 - } immediate = { - scope:inspiration_owner = { - location = { - save_scope_as = location_template - } - if = { - limit = { - any_secret = { - secret_type = secret_homosexual - } - } - random_secret = { - limit = { secret_type = secret_homosexual } - reveal_to = root - } - } - } - if = { - limit = { - scope:inspiration_owner = { - adventurer_pregnant_woman_trigger = yes - } - } - create_character = { - location = scope:inspiration_owner.location - template = adventurer_pregnant_lover_character - faith = scope:location_template.faith - culture = scope:location_template.culture - save_scope_as = adventurer_lover - } - scope:inspiration_owner = { - add_character_flag = adventurer_pregnant_lover_flag - } - hidden_effect = { - scope:adventurer_lover = { - if = { - limit = { - NOR = { - has_sexuality = heterosexual - has_sexuality = bisexual - } - } - set_sexuality = heterosexual - } - make_pregnant = { - father = scope:inspiration_owner - } - } - } - } - else_if = { - limit = { - scope:inspiration_owner = { - adventurer_female_lover_trigger = yes - } - } - create_character = { - location = scope:inspiration_owner.location - template = adventurer_female_lover_character - faith = scope:location_template.faith - culture = scope:location_template.culture - save_scope_as = adventurer_lover - } - scope:inspiration_owner = { - if = { - limit = { - is_female = yes - NOT = { has_sexuality = homosexual } - } - set_sexuality = homosexual - hidden_effect = { - scope:adventurer_lover = { set_sexuality = homosexual } - } - } - add_character_flag = adventurer_female_lover_flag - } - } - else = { - create_character = { - location = scope:inspiration_owner.location - template = adventurer_male_lover_character - faith = scope:location_template.faith - culture = scope:location_template.culture - save_scope_as = adventurer_lover - } - scope:inspiration_owner = { - if = { - limit = { - NOT = { has_sexuality = homosexual } - } - set_sexuality = bisexual - } - add_character_flag = adventurer_male_lover_flag - } - } - hidden_effect = { - scope:inspiration_owner = { - set_random_lover_reason = { TARGET = scope:adventurer_lover } - } - } + scope:adventurer_homosexual_secret ?= { reveal_to = root } + scope:adventurer_lover_secret ?= { reveal_to = root } } option = { # tell the adventurer to begone @@ -16960,6 +16996,7 @@ fund_inspiration.6504 = { AMOUNT = 2 } } + scope:lover_homosexual_secret ?= { reveal_to = root } ai_chance = { base = 25 ai_value_modifier = { @@ -16982,6 +17019,7 @@ fund_inspiration.6504 = { AMOUNT = 2 } } + scope:lover_homosexual_secret ?= { reveal_to = root } ai_chance = { base = 25 ai_value_modifier = { @@ -17011,6 +17049,173 @@ fund_inspiration.6504 = { } } +fund_inspiration.6513 = { + type = character_event + hidden = yes + cooldown = { years = 15 } + + weight_multiplier = { + base = 1 + modifier = { + scope:inspiration_owner = { has_trait = lustful } + factor = 2 + } + modifier = { + scope:inspiration_owner = { has_trait = rakish } + factor = 2 + } + } + + trigger = { + scope:inspiration = { has_inspiration_type = adventure_inspiration } + scope:inspiration_owner = { + location = { + terrain = farmlands + } + NOR = { + has_trait = chaste + has_trait = eunuch + has_trait = celibate + has_sexuality = asexual + } + might_cheat_on_every_partner_trigger = yes + } + } + + immediate = { + scope:inspiration_owner = { + location = { save_scope_as = location_template } + } + if = { # Male adventurer impregnates someone + limit = { + scope:inspiration_owner = { # Must be male and attracted to women + is_male = yes + is_attracted_to_women = yes + can_have_children = yes + } + } + create_character = { + location = scope:inspiration_owner.location + template = adventurer_pregnant_lover_character + faith = scope:location_template.faith + culture = scope:location_template.culture + save_scope_as = adventurer_lover + } + scope:adventurer_lover = { + if = { + limit = { can_have_children = yes } + make_pregnant = { father = scope:inspiration_owner } + scope:inspiration_owner = { add_character_flag = adventurer_pregnant_lover_flag } + } + else = { + scope:inspiration_owner = { add_character_flag = adventurer_female_lover_flag } + } + } + } + else = { # Any other male or female lover combo + hidden_effect = { + random_list = { + 10 = { # Female lover + trigger = { + scope:inspiration_owner = { is_attracted_to_women = yes } + } + create_character = { + location = scope:inspiration_owner.location + template = adventurer_female_lover_character + faith = scope:location_template.faith + culture = scope:location_template.culture + save_scope_as = adventurer_lover + } + scope:inspiration_owner = { add_character_flag = adventurer_female_lover_flag } + } + 10 = { # Male lover + trigger = { + scope:inspiration_owner = { is_attracted_to_men = yes } + } + create_character = { + location = scope:inspiration_owner.location + template = adventurer_male_lover_character + faith = scope:location_template.faith + culture = scope:location_template.culture + save_scope_as = adventurer_lover + } + scope:inspiration_owner = { add_character_flag = adventurer_male_lover_flag } + } + } + } + } + scope:adventurer_lover = { # Catch bad sexuality matches + if = { + limit = { + NOT = { is_attracted_to_gender_of = scope:inspiration_owner } + } + set_sexuality = bisexual + } + } + scope:inspiration_owner = { + # Lover relation + set_random_lover_reason = { TARGET = scope:adventurer_lover } + # Lover secret + if = { + limit = { + any_secret = { + secret_type = secret_lover + secret_target = scope:adventurer_lover + } + } + random_secret = { + limit = { + secret_type = secret_lover + secret_target = scope:adventurer_lover + } + save_scope_as = adventurer_lover_secret + } + } + # Homosexual secret + if = { + limit = { + sex_same_as = scope:adventurer_lover + trait_is_shunned_or_criminal_in_my_or_lieges_faith_trigger = { TRAIT = sodomite GENDER_CHARACTER = scope:inspiration_owner } + } + if = { + limit = { + NOT = { + any_secret = { secret_type = secret_homosexual } + } + } + give_homosexual_secret_or_nothing_effect = yes + } + random_secret = { + limit = { secret_type = secret_homosexual } + save_scope_as = adventurer_homosexual_secret + } + } + } + # Other homosexual secret + scope:adventurer_lover = { + if = { + limit = { + sex_same_as = scope:inspiration_owner + trait_is_shunned_or_criminal_in_my_or_lieges_faith_trigger = { TRAIT = sodomite GENDER_CHARACTER = scope:adventurer_lover } + } + if = { + limit = { + NOT = { + any_secret = { secret_type = secret_homosexual } + } + } + give_homosexual_secret_or_nothing_effect = yes + } + random_secret = { + limit = { secret_type = secret_homosexual } + save_scope_as = lover_homosexual_secret + } + } + } + trigger_event = fund_inspiration.6504 + } +} + #Oasis event, or, should I say, the CK3 beach episode fund_inspiration.6505 = { diff --git a/events/dlc/ep2/ep2_tournament_events.txt b/events/dlc/ep2/ep2_tournament_events.txt index ef5374c546..f02f2a3680 100644 --- a/events/dlc/ep2/ep2_tournament_events.txt +++ b/events/dlc/ep2/ep2_tournament_events.txt @@ -14102,8 +14102,10 @@ ep2_tournament_events.6502 = { left_icon = root right_icon = scope:versus_contestant - scope:versus_contestant = { - increase_wounds_no_death_effect = { REASON = wounds } + reverse_add_opinion = { + target = scope:versus_contestant + modifier = grateful_opinion + opinion = 30 } } } @@ -14125,10 +14127,11 @@ ep2_tournament_events.6502 = { send_interface_toast = { title = ep2_tournament_events.6502.b.tt.failure left_icon = root - right_icon = scope:competitor + right_icon = scope:versus_contestant - scope:competitor = { + scope:versus_contestant = { add_trait = scarred + increase_wounds_no_death_effect = { REASON = wounds } } } } @@ -14141,7 +14144,7 @@ ep2_tournament_events.6502 = { reverse_add_opinion = { target = scope:versus_contestant modifier = grateful_opinion - opinion = 30 + opinion = 20 } stress_impact = { diff --git a/events/dlc/ep2/wedding_events/ep2_wedding_events.txt b/events/dlc/ep2/wedding_events/ep2_wedding_events.txt index 25510d3139..7a0c6217ce 100644 --- a/events/dlc/ep2/wedding_events/ep2_wedding_events.txt +++ b/events/dlc/ep2/wedding_events/ep2_wedding_events.txt @@ -785,6 +785,21 @@ ep2_wedding.0151 = { } } +scripted_effect ep2_wedding_cleanup_jitter_modifier_effect = { + if = { + limit = { has_character_modifier = wedding_confident_groom } + remove_character_modifier = wedding_confident_groom + } + if = { + limit = { has_character_modifier = wedding_confident_bride } + remove_character_modifier = wedding_confident_bride + } + if = { + limit = { has_character_modifier = wedding_jitters } + remove_character_modifier = wedding_jitters + } +} + # I DON'T: the consequences ep2_wedding.0152 = { type = character_event @@ -827,6 +842,10 @@ ep2_wedding.0152 = { spouse = scope:spouse_2 } } + ep2_wedding_cleanup_jitter_modifier_effect = yes + scope:spouse_2 = { + ep2_wedding_cleanup_jitter_modifier_effect = yes + } } option = { diff --git a/events/dlc/fp1/fp1_scandinavian_adventurer_events.txt b/events/dlc/fp1/fp1_scandinavian_adventurer_events.txt index 92c1dd77e3..38d4ecd0d9 100644 --- a/events/dlc/fp1/fp1_scandinavian_adventurer_events.txt +++ b/events/dlc/fp1/fp1_scandinavian_adventurer_events.txt @@ -318,8 +318,8 @@ fp1_scandinavian_adventurers.0005 = { # Drag in famous landless Norse characters if they haven't become landed after twenty years. fp1_scandinavian_adventurers.0011 = { - hidden = yes scope = none + hidden = yes trigger = { # DLC check. @@ -338,7 +338,7 @@ fp1_scandinavian_adventurers.0011 = { # Warcraft #scripted_effect scandi_adventurers_grab_famous_character_effect = { -# $CHARACTER$ = { +# $CHARACTER$ ?= { # if = { # limit = { # # Still kickin'. diff --git a/events/dlc/fp3/fp3_clan_events_ola.txt b/events/dlc/fp3/fp3_clan_events_ola.txt new file mode 100644 index 0000000000..4a5276df90 --- /dev/null +++ b/events/dlc/fp3/fp3_clan_events_ola.txt @@ -0,0 +1,2293 @@ +namespace = fp3_clan + +########EVENT INDEX############ +#fp3_clan.8000 - Usury against Unity, by Ola Jentzsch +#fp3_clan.8001 - Clan Quarrel, by Ola Jentzsch +#fp3_clan.8002 - Bonds of Faith, by Ola Jentzsch +#fp3_clan.8003 - The Power of a Name, by Ola Jentzsch +#fp3_clan.8004 - Bonds of Fear, by Ola Jentzsch +#fp3_clan.8005 - A Proper Position, by Ola Jentzsch +#fp3_clan.8006 - Small Spies, by Ola Jentzsch + +scripted_trigger fp3_usury_trigger = { + ai_compassion <= low_positive_ai_value + OR = { + has_trait = greedy + has_trait = deceitful + ai_greed > medium_positive_ai_value + } +} + +scripted_trigger concerned_character_trigger = { + fp3_usury_trigger = no + NOT = { house = root.house } + is_available_ai_adult = yes + OR = { + opinion = { + target = scope:usurer + value < 25 + } + AND = { + faith = { trait_is_sin = greedy } + ai_zeal >= medium_positive_ai_value + } + ai_greed < medium_positive_ai_value + } +} + +scripted_trigger usurer_character_trigger = { + is_available_ai_adult = yes + NOR = { + this = root + is_liege_or_above_of = root + } + fp3_usury_trigger = yes +} + +fp3_clan.8000 = { # Usury against Unity + type = character_event + title = fp3_clan.8000.t + desc = fp3_clan.8000.desc + theme = corruption + + left_portrait = { + character = root + animation = disbelief + triggered_animation = { + trigger = { + OR = { + has_trait = vengeful + has_trait = wrathful + AND = { + faith = { trait_is_sin = greedy } + has_trait = zealous + } + } + } + animation = anger + } + } + right_portrait = { + character = scope:usurer + animation = personality_greedy + triggered_animation = { + trigger = { + ai_boldness < low_positive_ai_value + } + animation = beg + } + } + lower_left_portrait = { + character = scope:concerned_one + } + + trigger = { + has_fp3_dlc_trigger = yes + government_has_flag = government_is_clan + + house ?= { + prev = house_head + house_unity_value >= critical_house_unity + + any_house_unity_member = { + usurer_character_trigger = yes + save_temporary_scope_as = usurer + } + } + + any_vassal_or_below = { + concerned_character_trigger = yes + } + + faith = { + NOT = { has_doctrine_parameter = unreformed } + } + } + + cooldown = { + years = 25 + } + + immediate = { + house = { + random_house_unity_member = { + limit = { + usurer_character_trigger = yes + } + save_scope_as = usurer + } + } + + random_vassal_or_below = { + limit = { + concerned_character_trigger = yes + } + weight = { + base = 1 + modifier = { + factor = 10 + OR = { + has_relation_friend = root + is_powerful_vassal_of = root + is_child_of = root + has_council_position = councillor_spouse + AND = { + has_council_position = councillor_steward + employer = root + } + } + } + } + save_scope_as = concerned_one + } + + hidden_effect = { + scope:usurer = { + add_gold = major_gold_value + } + } + } + + option = { + name = fp3_clan.8000.a + + scope:usurer = { + hard_imprison_character_effect = { + TARGET = this + IMPRISONER = root + } + + add_opinion = { + target = root + modifier = imprisoned_me + } + } + + custom_tooltip = fp3_relations_reaction_to_imprisonment.tt + hidden_effect = { + scope:usurer = { + every_close_family_member = { + if = { + limit = { + opinion = { + target = scope:usurer + value > 25 + } + } + add_opinion = { + target = root + modifier = imprisoned_family_member + } + } + } + } + every_vassal = { + if = { + limit = { + opinion = { + target = scope:usurer + value > 25 + } + } + add_opinion = { + target = root + modifier = fp3_wrongful_imprisonment_opinion + } + } + } + } + + scope:concerned_one = { + add_opinion = { + target = root + modifier = pleased_opinion + opinion = 20 + } + } + + hidden_effect = { #his ill-gotten gains seep back to his debtors, so the player can't cheese it and steal them by banishing him + scope:usurer = { + remove_short_term_gold = major_gold_value + } + } + + if = { + limit = { + faith = { + OR = { + trait_is_sin = greedy + trait_is_virtue = generous + } + } + } + add_piety = medium_piety_gain + } + else = { + add_dread = minor_dread_gain + } + + add_clan_unity_interaction_effect = { + CHARACTER = root + TARGET = scope:usurer + VALUE = medium_unity_loss + DESC = clan_unity_imprisoned_usurer.desc + REVERSE_NON_HOUSE_TARGET = no + } + + stress_impact = { + arbitrary = medium_stress_impact_loss + just = minor_stress_impact_gain + trusting = medium_stress_impact_gain + } + + ai_chance = { + base = 100 + ai_value_modifier = { + ai_boldness = 0.5 + ai_vengefulness = 1 + ai_zeal = 1 + ai_compassion = -1 + } + } + } + + option = { + name = fp3_clan.8000.b + + scope:usurer = { + pay_short_term_gold = { + gold = medium_gold_value + target = root + } + } + + scope:usurer = { + add_opinion = { + target = root + modifier = extorted_me_opinion + } + } + + stress_impact = { + greedy = medium_stress_impact_loss + honest = medium_stress_impact_gain + generous = medium_stress_impact_gain + } + + ai_chance = { + base = 100 + ai_value_modifier = { + ai_greed = 1 + ai_honor = -0.5 + } + } + } + + option = { + name = fp3_clan.8000.c + + add_clan_unity_interaction_effect = { + CHARACTER = root + TARGET = scope:usurer + VALUE = minor_unity_gain + DESC = clan_unity_defended_usurer.desc + REVERSE_NON_HOUSE_TARGET = no + } + + scope:concerned_one = { + add_opinion = { + target = root + modifier = disappointed_opinion + opinion = -20 + } + } + + stress_impact = { + forgiving = minor_stress_impact_loss + trusting = medium_stress_impact_loss + zealous = minor_stress_impact_gain + } + + ai_chance = { + base = 100 + ai_value_modifier = { + ai_sociability = 0.5 + ai_boldness = 0.5 + ai_vengefulness = 0.5 + ai_honor = -1 + } + } + } +} + +scripted_trigger bickerer_2_character_trigger = { + is_available_ai_adult = yes + NOT = { this ?= scope:$SCOPE$ } + opinion = { + target ?= scope:$SCOPE$ + value < $VALUE$ + } +} + +fp3_clan.8001 = { #Clan Quarrel + type = character_event + title = fp3_clan.8001.t + desc = { + desc = fp3_clan.8001_beginning + first_valid = { + triggered_desc = { + trigger = { + faith = { + NOT = { has_doctrine_parameter = unreformed } + } + OR = { + scope:bickerer_1 = { + ai_zeal >= high_positive_ai_value + NOT = { has_trait = cynical } + } + scope:bickerer_2 = { + ai_zeal >= medium_positive_ai_value + NOT = { has_trait = cynical } + } + } + } + desc = fp3_clan.8001_faith_schism + } + desc = fp3_clan.8001_generic_fallback + } + } + theme = diplomacy_family_focus + + left_portrait = { + character = scope:bickerer_1 + animation = disgust + triggered_animation = { + trigger = { + OR = { + has_trait = vengeful + has_trait = wrathful + has_trait = zealous + ai_vengefulness >= high_positive_ai_value + } + } + animation = war_over_win + } + } + right_portrait = { + character = scope:bickerer_2 + animation = disapproval + triggered_animation = { + trigger = { + OR = { + has_trait = vengeful + has_trait = wrathful + has_trait = zealous + ai_vengefulness >= high_positive_ai_value + } + } + animation = angry + } + } + lower_left_portrait = { + character = root + } + + trigger = { + has_fp3_dlc_trigger = yes + government_has_flag = government_is_clan + is_house_head = yes + + house = { + house_unity_value > critical_house_unity + + any_house_unity_member = { + is_available_ai_adult = yes + NOT = { ai_vengefulness < low_positive_ai_value } + save_temporary_scope_as = bickerer_1_temp + house = { + any_house_unity_member = { + NOT = { this = scope:bickerer_1_temp } + is_available_adult = yes + opinion = { + target = scope:bickerer_1_temp + value < 20 + } + } + } + } + + any_house_unity_member = { + bickerer_2_character_trigger = { + VALUE = 20 + SCOPE = bickerer_1_temp + } + } + } + } + + cooldown = { years = 10 } + + immediate = { + house = { + random_house_unity_member = { + limit = { + is_available_ai_adult = yes + NOT = { ai_vengefulness < low_positive_ai_value } + save_temporary_scope_as = bickerer_1_temp + house = { + any_house_unity_member = { + NOT = { this = scope:bickerer_1_temp } + is_available_adult = yes + opinion = { + target = scope:bickerer_1_temp + value < 20 + } + } + } + } + save_scope_as = bickerer_1 + } + + random_house_unity_member = { + limit = { + is_available_ai_adult = yes + NOT = { this = scope:bickerer_1} + } + weight = { + base = 1 + modifier = { + factor = 10 + OR = { + has_relation_rival = scope:bickerer_1 + bickerer_2_character_trigger = { + VALUE = 0 + SCOPE = bickerer_1 + } + } + } + } + save_scope_as = bickerer_2 + } + } + + if = { + limit = { + scope:bickerer_1 = { + NOT = { has_relation_rival = scope:bickerer_2 } + } + } + scope:bickerer_1 = { + progress_towards_rival_effect = { + CHARACTER = scope:bickerer_2 + REASON = rival_generic_history + OPINION = -25 + } + } + } + } + + option = { + name = fp3_clan.8001.a + + duel = { + skill = diplomacy + target = scope:bickerer_1 + + 50 = { + compare_modifier = { + value = scope:duel_value + multiplier = 3.5 + max = 40 + min = -40 + } + + desc = fp3_clan.8001.a.success + send_interface_toast = { + title = fp3_clan.8001.a.success.tt + left_icon = root + + add_clan_unity_interaction_effect = { + CHARACTER = root + TARGET = scope:bickerer_1 + VALUE = medium_unity_gain + DESC = clan_unity_mediated_btw_clan_members.desc + REVERSE_NON_HOUSE_TARGET = no + } + + add_prestige = minor_prestige_gain + } + } + 50 = { + compare_modifier = { + value = scope:duel_value + multiplier = -3.5 + max = 40 + min = -40 + } + + desc = fp3_clan.8001.a.failure + send_interface_toast = { + title = fp3_clan.8001.a.failure.tt + left_icon = root + + add_clan_unity_interaction_effect = { + CHARACTER = root + TARGET = scope:bickerer_1 + VALUE = minor_unity_loss + DESC = clan_unity_caused_rift.desc + REVERSE_NON_HOUSE_TARGET = no + } + } + } + } + + stress_impact = { + forgiving = medium_stress_impact_loss + callous = medium_stress_impact_gain + shy = minor_stress_impact_gain + paranoid = medium_stress_impact_gain + arbitrary = medium_stress_impact_gain + } + + ai_chance = { + base = 100 + ai_value_modifier = { + ai_sociability = 1 + ai_honor = 0.5 + ai_rationality = 0.5 + ai_energy = 0.5 + } + } + } + + option = { + name = fp3_clan.8001.b + flavor = fp3_clan_making_conflict_worse_flavor + + duel = { + skill = intrigue + target = scope:bickerer_1 + + 50 = { + compare_modifier = { + value = scope:duel_value + multiplier = 3.5 + max = 40 + min = -40 + } + + desc = fp3_clan.8001.b.success + send_interface_toast = { + title = fp3_clan.8001.b.success.tt + left_icon = root + + add_clan_unity_interaction_effect = { + CHARACTER = root + TARGET = scope:bickerer_1 + VALUE = medium_unity_loss + DESC = clan_unity_caused_rift.desc + REVERSE_NON_HOUSE_TARGET = no + } + + add_prestige = minor_prestige_gain + + if = { + limit = { + scope:bickerer_1 = { + NOT = { has_relation_rival = scope:bickerer_2 } + } + } + scope:bickerer_1 = { + progress_towards_rival_effect = { + CHARACTER = scope:bickerer_2 + REASON = rival_generic_history + OPINION = -25 + } + } + } + + if = { + limit = { has_lifestyle = intrigue_lifestyle } + add_intrigue_lifestyle_xp = minor_lifestyle_experience + } + } + } + 50 = { + compare_modifier = { + value = scope:duel_value + multiplier = -3.5 + max = 40 + min = -40 + } + + desc = fp3_clan.8001.b.failure + send_interface_toast = { + title = fp3_clan.8001.b.failure.tt + left_icon = root + + add_prestige = minor_prestige_loss + } + } + } + + stress_impact = { + compassionate = medium_stress_impact_gain + honest = major_stress_impact_gain + just = medium_stress_impact_gain + } + + ai_chance = { + base = 100 + ai_value_modifier = { + ai_greed = 1 + ai_honor = -1 + ai_vengefulness = 0.5 + } + } + } + + option = { + name = fp3_clan.8001.c + + trigger = { + OR = { + has_trait = diligent + has_trait = paranoid + } + } + + stress_impact = { + diligent = minor_stress_impact_loss + compassionate = medium_stress_impact_gain + just = medium_stress_impact_gain + paranoid = minor_stress_impact_gain + } + + ai_chance = { + base = 100 + ai_value_modifier = { + ai_energy = 1 + ai_sociability = -0.7 + ai_rationality = 0.5 + } + } + } + + option = { + name = fp3_clan.8001.d + + trigger = { + NOR = { + has_trait = diligent + has_trait = paranoid + } + } + + stress_impact = { + base = minor_stress_impact_loss + lazy = minor_stress_impact_loss + content = minor_stress_impact_loss + ambitious = medium_stress_impact_gain + } + + ai_chance = { + base = 100 + ai_value_modifier = { + ai_energy = -1 + ai_sociability = -0.5 + ai_rationality = 0.5 + } + } + } +} + +scripted_trigger fp3_vassal_8002_trigger = { + is_available_ai_adult = yes + is_powerful_vassal_of = root + faith = root.faith + opinion = { + target = root + value < 50 + } +} + +fp3_clan.8002 = { #Bonds of Faith + type = character_event + title = fp3_clan.8002.t + desc = fp3_clan.8002.desc + theme = faith + left_portrait = { + character = root + animation = stress + triggered_animation = { + trigger = { + OR = { + has_trait = cynical + has_trait = stubborn + has_trait = wrathful + has_trait = vengeful + has_trait = arrogant + } + } + animation = personality_cynical + } + } + right_portrait = { + character = scope:chaplain + animation = personality_rational + triggered_animation = { + trigger = { + OR = { + scope:chaplain = { + has_dread_level_towards = { + target = root + level >= 2 + } + } + ai_boldness <= low_negative_ai_value + } + } + animation = personality_coward + } + } + + lower_left_portrait = { + character = scope:clan_member + } + + trigger = { + has_fp3_dlc_trigger = yes + government_has_flag = government_is_clan + + OR = { + num_sinful_traits >= 1 + piety_level < 3 + } + + scriptedtests_piety_income <= 2 + + house = { + house_unity_value < very_high_house_unity + any_house_unity_member = { + fp3_vassal_8002_trigger = yes + } + } + + exists = cp:councillor_court_chaplain + + cp:councillor_court_chaplain = { + is_available_ai_adult = yes + NOR = { + has_trait = arrogant + opinion = { + target = root + value < -30 + } + } + } + } + + cooldown = { + years = 10 + } + + immediate = { + house = { + random_house_unity_member = { + limit = { + fp3_vassal_8002_trigger = yes + } + weight = { + base = 1 + modifier = { + factor = 10 + ai_zeal >= high_positive_ai_value + } + modifier = { + factor = 10 + opinion = { + target = root + value < 0 + } + } + } + save_scope_as = clan_member + } + } + + cp:councillor_court_chaplain = { save_scope_as = chaplain } + } + + option = { + name = fp3_clan.8002.a + + add_character_modifier = { + modifier = fp3_praying_too_much_modifier + years = 10 + } + + add_clan_unity_interaction_effect = { + CHARACTER = root + TARGET = scope:clan_member + VALUE = minor_unity_gain + DESC = clan_unity_proved_pious.desc + REVERSE_NON_HOUSE_TARGET = no + } + + scope:chaplain = { + add_opinion = { + target = root + modifier = took_my_advice_opinion + opinion = 20 + } + } + + stress_impact = { + zealous = minor_stress_impact_loss + humble = medium_stress_impact_loss + diligent = minor_stress_impact_gain + arrogant = massive_stress_impact_gain + cynical = major_stress_impact_gain + impatient = medium_stress_impact_gain + } + + ai_chance = { + base = 100 + ai_value_modifier = { + ai_energy = 0.3 + ai_rationality = 0.5 + ai_zeal = 0.7 + } + } + } + + option = { + name = fp3_clan.8002.b + + trigger = { #this is a bit of an arbitrary exclusion; just to make sure that noone gets more than four options + NOR = { + intrigue >= high_skill_rating + has_trait = deceitful + has_trait = cynical + } + } + + add_piety = medium_piety_gain + remove_short_term_gold = medium_gold_value + + add_clan_unity_interaction_effect = { + CHARACTER = root + TARGET = scope:clan_member + VALUE = minor_unity_gain + DESC = clan_unity_founded_worshipful_house.desc + REVERSE_NON_HOUSE_TARGET = no + } + + scope:chaplain = { + add_opinion = { + target = root + modifier = pleased_opinion + opinion = 10 + } + } + + stress_impact = { + generous = medium_stress_impact_loss + greedy = medium_stress_impact_gain + content = minor_stress_impact_gain + cynical = minor_stress_impact_gain + } + + ai_chance = { + base = 100 + ai_value_modifier = { + ai_greed = -1 + ai_rationality = 0.5 + ai_zeal = 0.2 + } + } + } + + option = { + name = fp3_clan.8002.c + flavor = fp3_pretending_to_be_pious_flavor + + trigger = { + OR = { + intrigue >= high_skill_rating + has_trait = deceitful + has_trait = cynical + } + } + + duel = { + skill = intrigue + value = average_skill_rating + + 50 = { + compare_modifier = { + value = scope:duel_value + multiplier = 3.5 + max = 40 + min = -40 + } + + desc = fp3_clan.8002.b.success + send_interface_toast = { + title = fp3_clan.8002.b.success.tt + left_icon = root + + add_clan_unity_interaction_effect = { + CHARACTER = root + TARGET = scope:clan_member + VALUE = minor_unity_gain + DESC = clan_unity_proved_pious.desc + REVERSE_NON_HOUSE_TARGET = no + } + + add_piety = minor_piety_gain + } + } + 50 = { + compare_modifier = { + value = scope:duel_value + multiplier = -3.5 + max = 40 + min = -40 + } + + desc = fp3_clan.8002.b.failure + send_interface_toast = { + title = fp3_clan.8002.b.failure.tt + left_icon = root + + add_piety = medium_piety_loss + } + } + } + + scope:chaplain = { + add_opinion = { + target = root + modifier = disappointed_opinion + opinion = -20 + } + } + + stress_impact = { + deceitful = medium_stress_impact_loss + arrogant = medium_stress_impact_loss + zealous = major_stress_impact_gain + honest = massive_stress_impact_gain + humble = medium_stress_impact_gain + just = medium_stress_impact_gain + diligent = minor_stress_impact_gain + } + + ai_chance = { + base = 100 + ai_value_modifier = { + ai_honor = -1 + ai_sociability = 0.7 + ai_rationality = 0.9 + ai_vengefulness = 0.7 + ai_zeal = -1 + } + } + } + + option = { + name = fp3_clan.8002.d + + trigger = { + scope:clan_member = { + has_dread_level_towards = { + target = root + level >= 1 + } + } + } + + add_clan_unity_interaction_effect = { + CHARACTER = root + TARGET = scope:clan_member + VALUE = minor_unity_loss + DESC = clan_unity_threatened_clan_member.desc + REVERSE_NON_HOUSE_TARGET = no + } + + scope:chaplain = { + add_opinion = { + target = root + modifier = fp3_went_too_far_opinion + } + } + + scope:clan_member = { + add_opinion = { + target = root + modifier = fp3_fearing_retribution_opinion + opinion = -30 + } + } + + stress_impact = { + vengeful = medium_stress_impact_loss + forgiving = major_stress_impact_gain + craven = minor_stress_impact_gain + paranoid = medium_stress_impact_gain + humble = medium_stress_impact_gain + compassionate = major_stress_impact_gain + } + + ai_chance = { + base = 100 + ai_value_modifier = { + ai_boldness = 0.7 + ai_vengefulness = 1 + ai_compassion = -1 + ai_honor = -0.5 + } + } + } + + option = { + name = fp3_clan.8002.e + + stress_impact = { + honest = medium_stress_impact_loss + deceitful = medium_stress_impact_gain + ambitious = medium_stress_impact_gain + paranoid = medium_stress_impact_gain + zealous = medium_stress_impact_gain + } + + ai_chance = { + base = 100 + ai_value_modifier = { + ai_energy = -1 + ai_honor = 0.5 + ai_rationality = 0.5 + } + } + } +} + +scripted_trigger clan_member_paranoia_trigger = { + is_available_healthy_ai_adult = yes + NOR = { + has_council_position = councillor_spymaster + has_court_position = master_assassin_court_position + } + OR = { + AND = { + OR = { #we're looking for someone with ambition + has_trait = ambitious + has_trait = deceitful + has_trait = greedy + } + NOT = { + opinion = { + target = root + value >= 25 + } + } + } + opinion = { #or just someone who dislikes root + target = root + value < 0 + } + } +} + +fp3_clan.8004 = { #Bonds of Fear + type = character_event + title = fp3_clan.8004.t + desc = fp3_clan.8004.desc + theme = dread + left_portrait = { + character = root + animation = personality_cynical + triggered_animation = { + trigger = { + OR = { + has_trait = callous + has_trait = vengeful + has_trait = arbitrary + has_trait = sadistic + has_trait = deceitful + } + } + animation = personality_dishonorable + } + } + right_portrait = { + character = scope:murder_enthusiast + animation = spymaster + } + + lower_left_portrait = { + character = scope:clan_member + } + + trigger = { + has_fp3_dlc_trigger = yes + government_has_flag = government_is_clan + + house = { + NOR = { + house_unity_value > very_high_house_unity + house_unity_value < critical_house_unity + } + house_head = root + + any_house_unity_member = { + clan_member_paranoia_trigger = yes + } + } + + OR = { + AND = { + exists = cp:councillor_spymaster + cp:councillor_spymaster = { + is_available_healthy_ai_adult = yes + NOT = { ai_compassion >= low_positive_ai_value } + } + } + AND = { + employs_court_position = master_assassin_court_position + any_court_position_holder = { + type = master_assassin_court_position + is_available_healthy_ai_adult = yes + NOT = { ai_compassion >= low_positive_ai_value } + } + } + } + } + + cooldown = { + years = 10 + } + + immediate = { + if = { + limit = { + employs_court_position = master_assassin_court_position + any_court_position_holder = { + has_court_position = master_assassin_court_position + is_available_healthy_ai_adult = yes + NOT = { ai_compassion >= low_positive_ai_value } + } + } + random_court_position_holder = { + limit = { + has_court_position = master_assassin_court_position + is_available_healthy_ai_adult = yes + NOT = { ai_compassion >= low_positive_ai_value } + } + save_scope_as = murder_enthusiast + } + } + else_if = { + limit = { + exists = cp:councillor_spymaster + cp:councillor_spymaster = { + is_available_healthy_ai_adult = yes + NOT = { ai_compassion >= low_positive_ai_value } + } + } + cp:councillor_spymaster = { save_scope_as = murder_enthusiast } + } + + house = { + random_house_unity_member = { + limit = { + clan_member_paranoia_trigger = yes + has_relation_rival = scope:murder_enthusiast + } + alternative_limit = { + clan_member_paranoia_trigger = yes + is_powerful_vassal_of = root + } + alternative_limit = { + clan_member_paranoia_trigger = yes + is_close_family_of = root + } + alternative_limit = { + clan_member_paranoia_trigger = yes + is_claimant = yes + } + alternative_limit = { + clan_member_paranoia_trigger = yes + can_be_knight_trigger = { + ARMY_OWNER = root + } + } + alternative_limit = { + clan_member_paranoia_trigger = yes + } + save_scope_as = clan_member + } + } + } + + option = { + name = fp3_clan.8004.a #murder some peepl + + scope:murder_enthusiast = { + duel = { + skill = intrigue + value = scope:clan_member.intrigue + + 50 = { + compare_modifier = { + value = scope:duel_value + multiplier = 3.5 + max = 40 + min = -40 + } + + desc = fp3_clan.8004.a.success + root = { + send_interface_toast = { + title = fp3_clan.8004.a.success.tt + left_icon = root + + add_clan_unity_interaction_effect = { + CHARACTER = root + TARGET = scope:clan_member + VALUE = medium_unity_gain + DESC = clan_unity_scared_into_sub.desc + REVERSE_NON_HOUSE_TARGET = no + } + + add_dread = medium_dread_gain + + add_character_modifier = { + modifier = fp3_rule_by_fear_modifier + years = 20 + } + + scope:clan_member = { + if = { + limit = { + ai_boldness < high_positive_ai_value + } + add_opinion = { + target = root + modifier = scared_opinion + opinion = -10 + } + } + else = { + add_opinion = { + target = root + modifier = fp3_murdered_my_servants_opinion + opinion = -30 + } + } + } + } + } + } + 50 = { + compare_modifier = { + value = scope:duel_value + multiplier = -3.5 + max = 40 + min = -40 + } + + desc = fp3_clan.8004.a.failure + root = { + send_interface_toast = { + title = fp3_clan.8004.a.failure.tt + left_icon = root + + add_clan_unity_interaction_effect = { + CHARACTER = root + TARGET = scope:clan_member + VALUE = minor_unity_loss + DESC = clan_unity_failed_scary.desc + REVERSE_NON_HOUSE_TARGET = no + } + + add_dread = minor_dread_gain + + if = { + limit = { + root.faith = { + NOR = { + has_doctrine_parameter = adherents_more_likely_to_join_schemes + has_doctrine = doctrine_kinslaying_accepted + } + } + } + add_piety_level = -1 + } + + scope:clan_member = { + if = { + limit = { + ai_boldness < high_positive_ai_value + NOT = { has_relation_rival = root } + } + add_opinion = { + target = root + modifier = scared_opinion + opinion = -10 + } + } + else_if = { + limit = { + NOT = { + has_relation_rival = root + } + } + root = { + progress_towards_rival_effect = { + CHARACTER = scope:clan_member + REASON = rival_murdered_servants + OPINION = -25 + } + } + } + else = { + add_opinion = { + target = root + modifier = fp3_murdered_my_servants_opinion + opinion = -30 + } + } + } + } + } + } + } + } + + scope:murder_enthusiast = { + add_opinion = { + target = root + modifier = pleased_opinion + opinion = 30 + } + } + + stress_impact = { + deceitful = minor_stress_impact_loss + callous = minor_stress_impact_loss + compassionate = massive_stress_impact_gain + just = major_stress_impact_gain + forgiving = medium_stress_impact_gain + honest = medium_stress_impact_gain + } + + ai_chance = { + base = 100 + ai_value_modifier = { + ai_vengefulness = 1 + ai_boldness = 0.5 + ai_greed = 0.5 + ai_honor = -1 + ai_compassion = -1 + } + } + } + + option = { #you know what...there's no need to be discreet. + name = fp3_clan.8004.b + + add_clan_unity_interaction_effect = { + CHARACTER = root + TARGET = scope:clan_member + VALUE = minor_unity_loss + DESC = clan_unity_murdered_servants.desc + REVERSE_NON_HOUSE_TARGET = no + } + + add_dread = major_dread_gain + + if = { + limit = { + root.faith = { + NOR = { + has_doctrine_parameter = adherents_more_likely_to_join_schemes + has_doctrine = doctrine_kinslaying_accepted + } + } + } + root = { add_piety_level = -1 } + } + + scope:clan_member = { + if = { + limit = { + ai_boldness < high_positive_ai_value + NOT = { has_relation_rival = root } + } + add_opinion = { + target = root + modifier = scared_opinion + opinion = -10 + } + } + else_if = { + limit = { + NOT = { + has_relation_rival = root + } + } + root = { + progress_towards_rival_effect = { + CHARACTER = scope:clan_member + REASON = rival_murdered_servants + OPINION = -25 + } + } + } + else = { + add_opinion = { + target = root + modifier = fp3_murdered_my_servants_opinion + opinion = -30 + } + } + } + + + stress_impact = { + compassionate = massive_stress_impact_gain + just = major_stress_impact_gain + forgiving = medium_stress_impact_gain + honest = medium_stress_impact_gain + callous = minor_stress_impact_loss + } + + ai_chance = { + base = 100 + ai_value_modifier = { + ai_vengefulness = 1 + ai_boldness = 1 + ai_rationality = -0.8 + ai_compassion = -1 + } + } + } + + option = { + name = fp3_clan.8004.c #be horrified + + scope:murder_enthusiast = { + add_opinion = { + target = root + modifier = disappointed_opinion + opinion = -20 + } + } + + stress_impact = { + sadistic = major_stress_impact_gain + callous = major_stress_impact_gain + paranoid = medium_stress_impact_gain + forgiving = minor_stress_impact_loss + } + + ai_chance = { + base = 100 + ai_value_modifier = { + ai_honor = 1 + ai_compassion = 1 + ai_rationality = 0.3 + ai_vengefulness = -1 + ai_boldness = -0.3 + } + } + } +} + +################################### +# A Proper Position, by Ola Jentzsch +################################### + +scripted_trigger clan_harem_intrigue_parent_trigger = { + is_available_adult = yes + is_courtier = yes + NOT = { + has_trait = content + has_trait = craven + } + any_child = { + count > 0 + clan_harem_intrigue_child_trigger = yes + } +} + +scripted_trigger clan_harem_intrigue_child_trigger = { + is_available_child = yes + age > 5 + NOT = { is_primary_heir_of = root } + fp3_proper_gender_for_dynastic_ambition_trigger = yes + any_heir_title = { + count < 1 + tier >= tier_county + } +} + +fp3_clan.8005 = { #A Proper Position + type = character_event + title = fp3_clan.8005.t + desc = fp3_clan.8005.desc + theme = crown + + left_portrait = { + character = scope:ambitious_consort + animation = disapproval + triggered_animation = { + trigger = { + ai_vengefulness >= medium_positive_ai_value + } + animation = schadenfreude + } + triggered_animation = { + trigger = { + ai_boldness < low_positive_ai_value + } + animation = beg + } + } + + right_portrait = { + character = root + animation = personality_cynical + } + lower_left_portrait = { character = scope:empowered_child } + + lower_center_portrait = { character = scope:heir_parent } + + lower_right_portrait = { character = scope:heir_child } + + trigger = { + has_fp3_dlc_trigger = yes + government_has_flag = government_is_clan + + NOT = { + house = { + house_unity_value > very_high_house_unity + } + } + + any_held_title = { + tier = tier_county + NOT = { this = root.capital_county } + } + + domain_size > 4 + + any_consort = { + clan_harem_intrigue_parent_trigger = yes + save_temporary_scope_as = consort_1 + any_child = { + clan_harem_intrigue_child_trigger = yes + } + NOT = { + any_child = { is_primary_heir_of = root } + } + } + + any_consort = { + NOT = { this = scope:consort_1 } + is_available_adult = yes + is_courtier = yes + any_child = { + is_child_of = root + is_primary_heir_of = root + } + } + } + + cooldown = { years = 10 } + + immediate = { + save_scope_as = special_root_scope #this is used to trigger a player-facing toast in the hidden follow-up event + + random_consort = { + limit = { + clan_harem_intrigue_parent_trigger = yes + any_child = { clan_harem_intrigue_child_trigger = yes } + NOT = { + any_child = { is_primary_heir_of = root } + } + } + random_child = { + limit = { + clan_harem_intrigue_child_trigger = yes + } + save_scope_as = empowered_child + } + save_scope_as = ambitious_consort + } + + random_consort = { + limit = { + NOT = { this = scope:ambitious_consort } + is_available_adult = yes + is_courtier = yes + any_child = { + is_child_of = root + is_primary_heir_of = root + } + } + random_child = { + limit = { + NOT = { this = scope:empowered_child } + is_child_of = root + is_primary_heir_of = root + } + save_scope_as = heir_child + } + save_scope_as = heir_parent + } + + random_held_title = { + limit = { + tier = tier_county + NOT = { this = root.capital_county } + } + save_scope_as = title_to_grant + } + + scope:ambitious_consort = { + progress_towards_rival_effect = { + CHARACTER = scope:heir_parent + REASON = rival_harem_intrigue + OPINION = -25 + } + } + } + + option = { + name = fp3_clan.8005.a + + trigger = { #if you're a certain personality, you can scare them into submission + OR = { + dread >= high_dread + has_trait = vengeful + has_trait = wrathful + has_trait = arbitrary + } + } + + add_dread = minor_dread_gain + + scope:ambitious_consort = { + if = { + limit = { + OR = { + ai_vengefulness >= medium_positive_ai_value + ai_boldness >= medium_positive_ai_value + } + } + add_opinion = { + target = root + opinion = -40 + modifier = angry_opinion + } + scope:ambitious_consort = { + progress_towards_rival_effect = { + CHARACTER = scope:heir_parent + REASON = rival_harem_intrigue + OPINION = -25 + } + } + } + else = { + add_opinion = { + target = root + opinion = -25 + modifier = scared_opinion + } + } + } + + stress_impact = { + wrathful = minor_stress_impact_loss + calm = major_stress_impact_gain + compassionate = medium_stress_impact_gain + generous = medium_stress_impact_gain + } + + ai_chance = { + base = 100 + ai_value_modifier = { + ai_vengefulness = 1 + ai_compassion = -1 + ai_greed = 0.4 + } + } + } + + option = { #Give the child the title + name = fp3_clan.8005.b + flavor = original_heir_upset_flavor + + scope:title_to_grant.current_heir = { + add_opinion = { + target = root + opinion = -30 + modifier = angry_opinion + } + } + + create_title_and_vassal_change = { + type = granted + save_scope_as = change + } + scope:title_to_grant = { + change_title_holder = { + holder = scope:empowered_child + change = scope:change + } + } + resolve_title_and_vassal_change = scope:change + + scope:empowered_child = { + hidden_effect = { + trigger_event = { + id = fp3_clan.8007 + years = { 2 4 } + } + } + custom_tooltip = fp3_empowered_child.tt + } + + scope:ambitious_consort = { + add_opinion = { + target = root + opinion = 30 + modifier = happy_opinion + } + } + + stress_impact = { + generous = medium_stress_impact_loss + greedy = medium_stress_impact_gain + ambitious = minor_stress_impact_gain + stubborn = minor_stress_impact_gain + } + + ai_chance = { + base = 100 + ai_value_modifier = { + ai_greed = -0.6 + ai_compassion = 0.4 + ai_honor = 0.4 + } + } + } + + option = { #A bit young for a court position, don't you think? + name = fp3_clan.8005.d + + trigger = { + scope:empowered_child = { age <= 10 } + } + + scope:ambitious_consort = { + progress_towards_rival_effect = { + CHARACTER = scope:heir_parent + REASON = rival_harem_intrigue + OPINION = -25 + } + + add_opinion = { + target = root + opinion = -30 + modifier = angry_opinion + } + } + + stress_impact = { + generous = minor_stress_impact_gain + craven = minor_stress_impact_gain + trusting = minor_stress_impact_gain + } + + ai_chance = { + base = 100 + ai_value_modifier = { + ai_rationality = 0.8 + ai_compassion = -0.2 + } + } + } + + option = { #Reassure her + name = fp3_clan.8005.e + + duel = { + skill = diplomacy + value = scope:ambitious_consort.diplomacy + + 50 = { + compare_modifier = { + value = scope:duel_value + multiplier = 3.5 + max = 40 + min = -40 + } + + modifier = { + add = 100 + scope:ambitious_consort = { + opinion = { + target = root + value > 50 + } + } + } + + modifier = { + add = 50 + scope:ambitious_consort = { has_trait = trusting } + } + + desc = fp3_clan.8005.e.success + send_interface_toast = { + title = fp3_clan.8005.e.success.tt + left_icon = root + + add_clan_unity_interaction_effect = { + CHARACTER = root + TARGET = scope:ambitious_consort + VALUE = minor_unity_gain + DESC = clan_unity_promise_inheritance.desc + REVERSE_NON_HOUSE_TARGET = no + } + + scope:ambitious_consort = { + add_opinion = { + target = root + opinion = 20 + modifier = trust_opinion + } + } + } + } + 50 = { + compare_modifier = { + value = scope:duel_value + multiplier = -3.5 + max = 40 + min = -40 + } + + desc = fp3_clan.8005.e.failure + send_interface_toast = { + title = fp3_clan.8005.e.failure.tt + left_icon = root + + scope:ambitious_consort = { + add_opinion = { + target = root + opinion = -30 + modifier = angry_opinion + } + } + + scope:ambitious_consort = { + progress_towards_rival_effect = { + CHARACTER = scope:heir_parent + REASON = rival_harem_intrigue + OPINION = -25 + } + } + } + } + } + + stress_impact = { + wrathful = medium_stress_impact_gain + arrogant = medium_stress_impact_gain + callous = medium_stress_impact_gain + } + + ai_chance = { + base = 100 + ai_value_modifier = { + ai_compassion = 0.7 + ai_honor = 0.4 + ai_sociability = 1 + ai_vengefulness = -1 + } + } + } +} + + +################################### +# Smaller Spies, by Ola Jentzsch +################################### + +scripted_trigger suitable_spy_child_trigger = { + is_child_of = root + is_available_child = yes + is_courtier_of = root + age >= 7 + age <= 14 + OR = { + has_trait = curious + has_trait = rowdy + has_trait = charming + has_trait = deceitful + has_trait = paranoid + has_trait = callous + } + NOT = { is_primary_heir_of = root } +} + +scripted_trigger assassin_spymaster_trigger = { + is_available_healthy_ai_adult = yes + ai_compassion <= low_positive_ai_value +} + +fp3_clan.8006 = { + type = character_event + title = fp3_clan.8006.t + desc = fp3_clan.8006.desc + theme = intrigue_skulduggery_focus + + left_portrait = { + character = scope:sneaky_child + animation = disapproval + triggered_animation = { + trigger = { + AND = { + ai_compassion < low_positive_ai_value + ai_vengefulness >= low_positive_ai_value + } + } + animation = personality_callous + } + triggered_animation = { + trigger = { + ai_compassion >= low_positive_ai_value + } + animation = paranoia + } + } + + right_portrait = { + character = scope:paranoia_enthusiast + animation = scheme + triggered_animation = { + trigger = { + ai_vengefulness >= medium_positive_ai_value + } + animation = schadenfreude + } + } + + lower_left_portrait = { character = root } + + cooldown = { years = 10 } + + trigger = { + has_fp3_dlc_trigger = yes + government_has_flag = government_is_clan + + house = { + house_unity_value <= mediocre_house_unity + any_house_unity_member = { #checking that a decent amount of other adult clan members exists, this event wouldn't make sense otherwise + is_adult = yes + count >= 4 + } + } + + any_child = { + is_available_ai = yes + suitable_spy_child_trigger = yes + } + + OR = { + AND = { + exists = cp:councillor_spymaster + cp:councillor_spymaster = { + assassin_spymaster_trigger = yes + } + } + AND = { + employs_court_position = master_assassin_court_position + any_court_position_holder = { + type = master_assassin_court_position + assassin_spymaster_trigger = yes + } + } + } + } + + immediate = { + random_child = { + limit = { + is_available_ai = yes + suitable_spy_child_trigger = yes + } + save_scope_as = sneaky_child + } + + if = { + limit = { + employs_court_position = master_assassin_court_position + any_court_position_holder = { + has_court_position = master_assassin_court_position + assassin_spymaster_trigger = yes + } + } + random_court_position_holder = { + limit = { + has_court_position = master_assassin_court_position + assassin_spymaster_trigger = yes + } + save_scope_as = paranoia_enthusiast + } + } + else = { + limit = { + exists = cp:councillor_spymaster + cp:councillor_spymaster = { + assassin_spymaster_trigger = yes + } + } + cp:councillor_spymaster = { save_scope_as = paranoia_enthusiast } + } + + scope:sneaky_child = { + if = { + limit = { + any_relation = { + type = guardian + } + } + random_relation = { + type = guardian + save_scope_as = little_sneakys_guardian + } + } + } + } + + option = { + name = fp3_clan.8006.a + + add_clan_unity_interaction_effect = { + CHARACTER = root + TARGET = scope:sneaky_child + VALUE = minor_unity_gain + DESC = clan_unity_asserted_child_status.desc + REVERSE_NON_HOUSE_TARGET = no + } + + scope:paranoia_enthusiast = { + add_opinion = { + target = root + opinion = -10 + modifier = disappointed_opinion + } + } + + scope:sneaky_child = { + add_opinion = { + target = root + opinion = -30 + modifier = fp3_denied_me_an_opportunity_opinion + } + } + + stress_impact = { + ambitious = minor_stress_impact_gain + paranoid = minor_stress_impact_gain + deceitful = minor_stress_impact_gain + } + + ai_chance = { + base = 100 + ai_value_modifier = { + ai_honor = 1 + ai_sociability = 1 + ai_vengefulness = -1 + ai_boldness = 0.5 + } + } + } + + option = { + name = fp3_clan.8006.b + + add_clan_unity_interaction_effect = { + CHARACTER = root + TARGET = scope:sneaky_child + VALUE = minor_unity_loss + DESC = clan_unity_let_child_become_spy.desc + REVERSE_NON_HOUSE_TARGET = no + } + + add_character_modifier = { + modifier = fp3_minor_child_spy_network_modifier + years = 15 + } + + if = { + limit = { + exists = scope:little_sneakys_guardian + scope:little_sneakys_guardian = { + OR = { + is_ai = yes + this = root + } + NOT = { this = scope:paranoia_enthusiast } + } + } + scope:sneaky_child = { + remove_relation_guardian = scope:little_sneakys_guardian + } + } + + scope:sneaky_child = { + if = { + limit = { + OR = { + num_of_relation_guardian < 1 + any_relation = { + type = guardian + OR = { + is_ai = yes + this = root + } + NOT = { this = scope:paranoia_enthusiast} + } + } + } + set_relation_guardian = scope:paranoia_enthusiast + add_intrigue_skill = 1 + } + else = { + add_intrigue_skill = 1 + } + } + + scope:sneaky_child = { + add_opinion = { + target = root + opinion = 20 + modifier = happy_opinion + } + } + + scope:paranoia_enthusiast = { + add_opinion = { + target = root + opinion = 15 + modifier = took_my_advice_opinion + } + } + + stress_impact = { + compassionate = medium_stress_impact_gain + honest = medium_stress_impact_gain + } + + ai_chance = { + base = 50 + ai_value_modifier = { + ai_boldness = 0.3 + ai_sociability = 0.3 + ai_vengefulness = 1 + ai_honor = -0.5 + ai_compassion = -0.8 + } + } + } + + option = { + name = fp3_clan.8006.c + + pay_short_term_gold = { + target = scope:paranoia_enthusiast + gold = minor_gold_value + } + + add_character_modifier = { + modifier = fp3_minor_child_spy_network_modifier + years = 15 + } + + scope:sneaky_child = { + add_opinion = { + target = root + opinion = -30 + modifier = fp3_denied_me_an_opportunity_opinion + } + } + + stress_impact = { + deceitful = minor_stress_impact_gain + greedy = minor_stress_impact_gain + } + + ai_chance = { + base = 100 + ai_value_modifier = { + ai_honor = 1 + ai_compassion = 1 + ai_rationality = 0.5 + ai_vengefulness = -1 + ai_boldness = -0.5 + } + } + } +} + +scripted_effect random_skill_chance_effect = { + send_interface_toast = { + title = fp3_8007_studies_pay_off_toast + left_icon = scope:empowered_child + scope:empowered_child = { + add_stewardship_skill = 1 + add_$SKILL_2$_skill = 1 + } + } +} + +fp3_clan.8007 = { #Hidden event to set up child's traits + hidden = yes + + trigger = { + has_fp3_dlc_trigger = yes + exists = scope:empowered_child + any_held_title = { + this = scope:title_to_grant + } + } + + immediate = { + random_list = { + 25 = { + random_skill_chance_effect = { SKILL_2 = martial } + } + 25 = { + random_skill_chance_effect = { SKILL_2 = diplomacy } + } + 25 = { + random_skill_chance_effect = { SKILL_2 = learning } + } + 25 = { + random_skill_chance_effect = { SKILL_2 = intrigue } + } + } + } +} + + + + + diff --git a/events/dlc/fp3/fp3_clan_events_persia_specific_ola.txt b/events/dlc/fp3/fp3_clan_events_persia_specific_ola.txt new file mode 100644 index 0000000000..9990e8cbe9 --- /dev/null +++ b/events/dlc/fp3/fp3_clan_events_persia_specific_ola.txt @@ -0,0 +1,403 @@ +namespace = fp3_clan + +########EVENT INDEX############ +#fp3_clan.8015 - Scandalous Scion +#fp3_clan.8016 - Hammam Havoc +#fp3_clan_8017 - A Questionable Position +#################### + +################################### +# Scandalous Scion +# By Ola Jentzsch +################################### +scripted_trigger fp3_scandalous_scion_trigger = { + NOT = { liege ?= root } + is_available_ai_adult = yes + is_landed = no + age_in_relation_to_humans_less_than_trigger = { age = 45 } + can_be_combatant_based_on_gender_trigger = { ARMY_OWNER = root } + ai_sociability > low_negative_ai_value + ai_compassion < low_positive_ai_value + NOR = { + is_child_of = root + this = root + } + any_parent = { + is_available_ai_adult = yes + NOT = { is_close_family_of = root } + } +} + +fp3_clan.8015 = { + type = character_event + title = fp3_clan.8015.t + desc = fp3_clan.8015.desc + + theme = martial + + left_portrait = { + character = scope:scandalous_scion + animation = dismissal + triggered_animation = { + trigger = { + OR = { + has_trait = craven + has_trait = shy + ai_boldness <= low_positive_ai_value + } + } + animation = shame + } + outfit_tags = { + military_outfit + } + } + right_portrait = { + character = scope:concerned_parent + animation = stress + } + lower_left_portrait = root + + override_background = { reference = throne_room } + + trigger = { + has_fp3_dlc_trigger = yes + government_has_flag = government_is_clan + is_available_adult = yes + is_house_head = yes + + #culture = { has_cultural_tradition = tradition_futuwaa } + + house = { + any_house_member = { + fp3_scandalous_scion_trigger = yes + } + } + } + + cooldown = { years = 10 } + + immediate = { + house = { + random_house_member = { + limit = { + fp3_scandalous_scion_trigger = yes + } + save_scope_as = scandalous_scion + random_parent = { + limit = { + is_available_ai_adult = yes + NOT = { is_close_family_of = root } + } + save_scope_as = concerned_parent + } + } + } + } + + option = { + name = fp3_clan.8015.a + + add_courtier = scope:scandalous_scion + + scope:scandalous_scion = { + add_character_modifier = { + modifier = fp3_better_company_modifier + years = 10 + } + } + + scope:concerned_parent = { + add_opinion = { + target = root + opinion = 25 + modifier = fp3_grateful_for_discretion_opinion + } + } + + add_clan_unity_interaction_effect = { + CHARACTER = root + TARGET = scope:scandalous_scion + VALUE = minor_unity_gain + DESC = clan_unity_scandalous_scion_desc + REVERSE_NON_HOUSE_TARGET = no + } + + stress_impact = { + paranoid = minor_stress_impact_gain + shy = minor_stress_impact_gain + } + + ai_chance = { + base = 50 + ai_value_modifier = { + ai_compassion = 0.5 + ai_greed = -0.5 + ai_sociability = 1 + } + } + } + + option = { + name = fp3_clan.8015.b + + scope:concerned_parent = { + add_opinion = { + target = root + opinion = -20 + modifier = disappointed_opinion + } + } + + add_clan_unity_interaction_effect = { + CHARACTER = root + TARGET = scope:scandalous_scion + VALUE = minor_unity_loss + DESC = clan_unity_scandalous_scion_ignored_problem_desc + REVERSE_NON_HOUSE_TARGET = no + } + + stress_impact = { + generous = minor_stress_impact_gain + trusting = minor_stress_impact_gain + } + + ai_chance = { + base = 50 + ai_value_modifier = { + ai_compassion = -0.5 + ai_greed = -0.5 + ai_sociability = -1 + } + } + } +} + +################################### +# Hammam Havoc +# By Ola Jentzsch +################################### +scripted_trigger fp3_scandalous_traits_trigger = { + OR = { + has_trait = deviant + has_trait = drunkard + has_trait = rakish + has_trait = hashishiyah + } +} + +scripted_trigger fp3_suitable_for_islamic_bathhouse_events_trigger = { + OR = { #checking for adherence to Islamic / Zoroastrian gender norms + AND = { + root = { is_male = yes } + is_male = yes + } + AND = { + root = { is_female = yes } + is_female = yes + } + } +} + +fp3_clan.8016 = { + type = character_event + title = fp3_clan.8016.t + desc = { + desc = fp3_clan.8016.opening_desc + first_valid = { + triggered_desc = { + trigger = { + scope:scandalous_clan_member = { + has_trait = deviant + } + } + desc = fp3_clan.8016.deviant_desc + } + triggered_desc = { + trigger = { + scope:scandalous_clan_member = { + has_trait = drunkard + } + } + desc = fp3_clan.8016.drunkard_desc + } + triggered_desc = { + trigger = { + scope:scandalous_clan_member = { + has_trait = rakish + } + } + desc = fp3_clan.8016.rakish_desc + } + triggered_desc = { + trigger = { + scope:scandalous_clan_member = { + has_trait = hashishiyah + } + } + desc = fp3_clan.8016.hashishiyah_desc + } + } + desc = fp3_clan.8016.ending_desc + } + + theme = faith + + left_portrait = { + character = root + animation = disbelief + triggered_animation = { + trigger = { + OR = { + has_trait = craven + has_trait = shy + has_trait = paranoid + stress > medium_stress + } + } + animation = worry + } + outfit_tags = { + no_clothes + } + } + right_portrait = { + character = scope:chaplain + animation = eyeroll + outfit_tags = { + no_clothes + } + } + lower_left_portrait = scope:scandalous_clan_member + + override_background = { reference = bath_house } + + trigger = { + has_fp3_dlc_trigger = yes + is_available_adult = yes + is_dynast = yes + government_has_flag = government_is_clan + + faith = { + OR = { + has_doctrine_parameter = deviancy_illegal + has_doctrine_parameter = deviancy_shunned + } + } + + house = { + any_house_unity_member = { + NOT = { this = root } + is_available_ai_adult = yes + fp3_scandalous_traits_trigger = yes + fp3_suitable_for_islamic_bathhouse_events_trigger = yes + } + } + + exists = cp:councillor_court_chaplain + cp:councillor_court_chaplain = { + is_available_healthy_ai_adult = yes + fp3_scandalous_traits_trigger = no + fp3_suitable_for_islamic_bathhouse_events_trigger = yes + } + } + + cooldown = { years = 10 } + + immediate = { + house = { + random_house_unity_member = { + limit = { + NOT = { this = root } + is_available_ai_adult = yes + fp3_scandalous_traits_trigger = yes + fp3_suitable_for_islamic_bathhouse_events_trigger = yes + } + save_scope_as = scandalous_clan_member + } + } + + cp:councillor_court_chaplain = { save_scope_as = chaplain } + + hidden_effect = { + scope:scandalous_clan_member = { + set_location = { location = root.location } + } + } + } + + option = { + name = fp3_clan.8016.a + + add_piety = medium_piety_gain + + add_clan_unity_interaction_effect = { + CHARACTER = root + TARGET = scope:scandalous_clan_member + VALUE = minor_unity_loss + DESC = clan_unity_denouncement.desc + REVERSE_NON_HOUSE_TARGET = no + } + + scope:scandalous_clan_member = { + denounce_effect = { ACTOR = root RECIPIENT = scope:scandalous_clan_member } + } + + scope:chaplain = { + add_opinion = { + target = root + opinion = 20 + modifier = pleased_opinion + } + } + + stress_impact = { + forgiving = minor_stress_impact_gain + compassionate = minor_stress_impact_gain + paranoid = medium_stress_impact_gain + } + + ai_chance = { + base = 50 + ai_value_modifier = { + ai_compassion = -0.9 + ai_vengefulness = 0.5 + ai_zeal = 1 + } + } + } + + option = { + name = fp3_clan.8016.b + + scope:chaplain = { + add_opinion = { + target = root + opinion = -20 + modifier = disappointed_opinion + } + } + + add_clan_unity_interaction_effect = { + CHARACTER = root + TARGET = scope:scandalous_clan_member + VALUE = minor_unity_gain + DESC = clan_unity_denouncement_refusal.desc + REVERSE_NON_HOUSE_TARGET = no + } + + stress_impact = { + zealous = medium_stress_impact_gain + trusting = medium_stress_impact_gain + } + + ai_chance = { + base = 50 + ai_value_modifier = { + ai_zeal = -0.5 + ai_rationality = 0.8 + ai_sociability = 0.5 + } + } + } +} diff --git a/events/dlc/fp3/fp3_dynasty_decision_events.txt b/events/dlc/fp3/fp3_dynasty_decision_events.txt new file mode 100644 index 0000000000..f98ac3f737 --- /dev/null +++ b/events/dlc/fp3/fp3_dynasty_decision_events.txt @@ -0,0 +1,1283 @@ +namespace = fp3_dynasty_decision + +######################################### +# Embellish Capital Decision Events # +# By Ola Jentzsch # +# Reworked by Chad Uhl # +######################################### + +scripted_effect fp3_dynasty_decision_0003_fire_follow_up_event_effect = { + # Fire the event based on the option selected + if = { # Royal Architect + limit = { scope:embellish_capital_royal_architect = yes } + trigger_event = { + id = fp3_dynasty_decision.0004 + days = { 3 10 } + } + } + else_if = { # Consort or Courtier + limit = { scope:embellish_capital_consort_courtier = yes } + trigger_event = { + id = fp3_dynasty_decision.0005 + days = { 3 10 } + } + } + else_if = { # Court Chaplain + limit = { scope:embellish_capital_chaplain = yes } + trigger_event = { + id = fp3_dynasty_decision.0007 + days = { 3 10 } + } + } + else_if = { # Me + limit = { scope:embellish_capital_me = yes } + trigger_event = { + id = fp3_dynasty_decision.0008 + days = { 3 10 } + } + } +} + +# If you have both the gold and the recently conquered county for the Embellish Capital decision, we let you decide how to proceed here +fp3_dynasty_decision.0003 = { + type = character_event + title = fp3_dynasty_decision.0003.t + desc = { + desc = fp3_dynasty_decision.0003.intro + triggered_desc = { + trigger = { NOT = { scope:chosen_architect = root } } + desc = fp3_dynasty_decision.0003.char + } + desc = fp3_dynasty_decision.0003.desc + } + theme = realm + + left_portrait = { + character = root + animation = personality_greedy + } + right_portrait = { + trigger = { NOT = { scope:chosen_architect = root } } + character = scope:chosen_architect + animation = personality_honorable + } + + override_background = { reference = market_east } + + option = { # Pay by plundering the target conquered county + name = fp3_dynasty_decision.0003.a + + scope:target_county = { + add_county_modifier = { + modifier = fp3_plundered_county_modifier + years = 30 + } + } + + remove_variable = embellish_capital_cost + + # Fire the event based on the option selected + fp3_dynasty_decision_0003_fire_follow_up_event_effect = yes + + if = { + limit = { NOT = { scope:chosen_architect = root } } + reverse_add_opinion = { + target = scope:chosen_architect + modifier = trusted_me_opinion + opinion = 10 + } + } + + stress_impact = { + callous = minor_stress_impact_loss + } + + ai_chance = { #social AI prefer this option + base = 50 + ai_value_modifier = { + ai_sociability = 1 + } + } + } + + option = { # Pay with gold + name = fp3_dynasty_decision.0003.b + + remove_short_term_gold = var:embellish_capital_cost + + # Fire the event based on the option selected + fp3_dynasty_decision_0003_fire_follow_up_event_effect = yes + + if = { + limit = { NOT = { scope:chosen_architect = root } } + reverse_add_opinion = { + target = scope:chosen_architect + modifier = trusted_me_opinion + opinion = 10 + } + } + + stress_impact = { + generous = minor_stress_impact_loss + } + + ai_chance = { #rational AI prefer this option + base = 50 + ai_value_modifier = { + ai_rationality = 1 + } + } + } + + option = { #I'd rather wait + name = fp3_dynasty_decision.0003.c + + # Clear the cooldown. + remove_decision_cooldown = fp3_embellish_capital_decision + + # No stress impact for opting out. + } +} + +# Royal Architect +fp3_dynasty_decision.0004 = { + type = character_event + title = fp3_dynasty_decision.0004.t + desc = { + desc = fp3_dynasty_decision.0004.intro + triggered_desc = { + trigger = { has_variable = embellish_capital_cost } + desc = fp3_dynasty_decision.0004.plunder.desc + } + desc = fp3_dynasty_decision.0004.desc + } + theme = realm + left_portrait = { + character = root + animation = happiness + } + right_portrait = { + character = scope:chosen_architect + animation = steward + } + + immediate = { + scope:capital_county = { + add_county_modifier = { + modifier = fp3_architectural_splendor_county_modifier + years = 30 + } + } + } + + option = { #New fountains and aqueducts + name = fp3_dynasty_decision.0004.a + + scope:chosen_architect = { + duel = { + skill = stewardship + value = medium_skill_rating + 50 = { + desc = splurge_above_expectations_toast + compare_modifier = { + value = scope:duel_value + multiplier = 3.5 + } + root = { + send_interface_toast = { + title = splurge_above_expectations_toast + left_icon = scope:chosen_architect + dynasty = { add_dynasty_prestige = major_dynasty_prestige_value } + house = { + every_house_member = { + custom = every_house_member + add_opinion = { + target = root + modifier = approving_opinion + } + } + } + } + } + } + 50 = { + desc = splurge_as_expected_toast + compare_modifier = { + value = scope:duel_value + multiplier = -3.5 + } + root = { + send_interface_toast = { + title = splurge_as_expected_toast + left_icon = scope:chosen_architect + dynasty = { add_dynasty_prestige = medium_dynasty_prestige_value } + } + } + } + } + } + + ai_chance = { #ambitious AI prefer this option + base = 100 + ai_value_modifier = { + ai_boldness = 1 + ai_greed = 0.5 + } + } + } + + option = { #impress the local people + name = fp3_dynasty_decision.0004.b + + scope:chosen_architect = { + duel = { + skills = { stewardship diplomacy } + value = medium_skill_rating + 50 = { + compare_modifier = { + value = scope:duel_value + multiplier = 3.5 + } + root = { + send_interface_toast = { + title = splurge_above_expectations_toast + left_icon = scope:chosen_architect + + if = { + limit = { + NOT = { scope:capital_county.culture = root.culture } + } + culture = { + change_cultural_acceptance = { + target = scope:capital_county.culture + value = medium_positive_culture_acceptance + desc = cultural_acceptance_built_magnificent_capital + } + } + } + else = { + scope:capital_county = { + change_county_control = 20 + } + } + every_vassal = { + custom = every_minority_vassal + limit = { has_vassal_stance = minority } + add_opinion = { + target = root + modifier = approving_opinion + } + } + } + } + } + 50 = { + compare_modifier = { + value = scope:duel_value + multiplier = -3.5 + } + root = { + send_interface_toast = { + title = splurge_as_expected_toast + left_icon = scope:chosen_architect + + if = { + limit = { + NOT = { scope:capital_county.culture = root.culture } + } + culture = { + change_cultural_acceptance = { + target = scope:capital_county.culture + value = low_positive_culture_acceptance + desc = cultural_acceptance_built_magnificent_capital + } + } + } + else = { + scope:capital_county = { + change_county_control = 20 + } + } + } + } + } + } + } + + ai_chance = { #moderately ambitious, patient AI prefer this option + base = 100 + ai_value_modifier = { + ai_rationality = 0.5 + ai_greed = 0.5 + ai_sociability = 0.5 + } + } + } + + option = { #New fountains and aqueducts + name = fp3_dynasty_decision.0004.c + + scope:chosen_architect = { + duel = { + skills = { stewardship learning } + value = medium_skill_rating + 50 = { + compare_modifier = { + value = scope:duel_value + multiplier = 3.5 + } + root = { + send_interface_toast = { + title = splurge_above_expectations_toast + left_icon = scope:chosen_architect + + scope:capital_county = { change_development_progress = medium_development_progress_gain } + } + } + } + 50 = { + compare_modifier = { + value = scope:duel_value + multiplier = -3.5 + } + root = { + send_interface_toast = { + title = splurge_as_expected_toast + left_icon = scope:chosen_architect + + scope:capital_county = { change_development_progress = minor_development_progress_gain } + } + } + } + } + } + + ai_chance = { #pragmatic or compassionate AI prefer this option + base = 100 + ai_value_modifier = { + ai_rationality = 1 + ai_compassion = 0.5 + } + } + } +} + +# Courtier +fp3_dynasty_decision.0005 = { + type = character_event + title = fp3_dynasty_decision.0005.t + desc = fp3_dynasty_decision.0005.desc + theme = realm + left_portrait = { + character = root + animation = personality_rational + } + right_portrait = { + character = scope:chosen_architect + animation = happiness + } + + immediate = { + scope:capital_county = { + add_county_modifier = { + modifier = fp3_architectural_splendor_county_modifier + years = 30 + } + } + } + + option = { #Magnificent bathhouse + name = fp3_dynasty_decision.0005.a + + scope:chosen_architect = { + #before the duel, we're checking for opinion gains + if = { + limit = { + OR = { + has_relation_lover = root + has_relation_soulmate = root + } + } + add_opinion = { + target = root + modifier = happy_opinion + opinion = 20 + } + } + else_if = { + limit = { is_consort_of = root } + custom_tooltip = fp3_decisons_closer_to_love.tt + hidden_effect = { + root = { + progress_towards_lover_effect = { + CHARACTER = scope:chosen_architect + REASON = lover_let_me_build_steamy_bath_house + OPINION = 20 + } + } + } + } + else = { + add_opinion = { + target = root + modifier = grateful_opinion + opinion = 20 + } + } + duel = { + skill = stewardship + value = medium_skill_rating + 50 = { + desc = splurge_above_expectations_toast + compare_modifier = { + value = scope:duel_value + multiplier = 3.5 + } + root = { + send_interface_toast = { + title = splurge_above_expectations_toast + left_icon = scope:chosen_architect + + add_character_modifier = { + modifier = fp3_luxurious_bathhouse_modifier + years = 30 + } + } + } + } + 50 = { + desc = splurge_as_expected_toast + compare_modifier = { + value = scope:duel_value + multiplier = -3.5 + } + root = { + send_interface_toast = { + title = splurge_as_expected_toast + left_icon = scope:chosen_architect + + add_character_modifier = { + modifier = fp3_less_luxurious_bathhouse_modifier + years = 30 + } + } + } + } + } + } + + ai_chance = { #decadent or compassionate AI prefer this option + base = 100 + ai_value_modifier = { + ai_compassion = 0.3 + ai_greed = 0.8 + ai_sociability = 1 + } + } + + stress_impact = { #decadent characters loves this idea + lazy = minor_stress_impact_loss + lustful = minor_stress_impact_loss + gregarious = minor_stress_impact_loss + gluttonous = minor_stress_impact_loss + shy = medium_stress_impact_gain + } + } + + option = { #A temple + name = fp3_dynasty_decision.0005.b + + scope:chosen_architect = { + add_opinion = { + target = root + modifier = disappointed_opinion + opinion = -20 + } + duel = { + skills = { stewardship learning } + value = medium_skill_rating + 50 = { + desc = splurge_above_expectations_toast + compare_modifier = { + value = scope:duel_value + multiplier = 3.5 + } + root = { + send_interface_toast = { + title = splurge_above_expectations_toast + left_icon = scope:chosen_architect + + add_piety = major_piety_gain + every_vassal = { + custom = every_zealot_vassal + limit = { + has_vassal_stance = zealot + } + add_opinion = { + target = root + modifier = approving_opinion + } + } + } + } + } + 50 = { + desc = splurge_as_expected_toast + compare_modifier = { + value = scope:duel_value + multiplier = -3.5 + } + root = { + send_interface_toast = { + title = splurge_as_expected_toast + left_icon = scope:chosen_architect + + add_piety = medium_piety_gain + } + } + } + } + } + + stress_impact = { + callous = minor_stress_impact_loss + zealous = minor_stress_impact_loss + } + + ai_chance = { #zealous antisocial AI prefer this option + base = 100 + ai_value_modifier = { + ai_zeal = 1 + ai_sociability = -1 + } + } + } + + option = { #A palace + name = fp3_dynasty_decision.0005.c + + scope:chosen_architect = { + add_opinion = { + target = root + modifier = disappointed_opinion + opinion = -20 + } + duel = { + skills = { stewardship diplomacy } + value = medium_skill_rating + 50 = { + desc = splurge_above_expectations_toast + compare_modifier = { + value = scope:duel_value + multiplier = 3.5 + } + root = { + send_interface_toast = { + title = splurge_above_expectations_toast + left_icon = scope:royal_architect + + add_prestige = major_prestige_gain + every_vassal = { + custom = every_courtly_vassal + limit = { + has_vassal_stance = courtly + } + add_opinion = { + target = root + modifier = approving_opinion + } + } + } + } + } + 50 = { + desc = splurge_as_expected_toast + compare_modifier = { + value = scope:duel_value + multiplier = -3.5 + } + root = { + send_interface_toast = { + title = splurge_as_expected_toast + left_icon = scope:royal_architect + + add_prestige = medium_prestige_gain + } + } + } + } + } + + stress_impact = { + arrogant = minor_stress_impact_loss + callous = minor_stress_impact_loss + } + + ai_chance = { #rational AI, who kinda just wanna put the courtier down, picks this option + base = 100 + ai_value_modifier = { + ai_rationality = 0.5 + ai_vengefulness = 0.7 + ai_sociability = -1 + } + } + } +} + +# Chaplain +fp3_dynasty_decision.0007 = { + type = character_event + title = fp3_dynasty_decision.0007.t + desc = { + desc = { + desc = fp3_dynasty_decision.0007_desc_beginning + first_valid = { + triggered_desc = { + trigger = { + faith = { has_doctrine = tenet_sky_burials } + } + desc = fp3_dynasty_decision.0007_dakhma + } + } + } + desc = fp3_dynasty_decision.0007_outro + } + theme = realm + left_portrait = { + character = root + animation = happiness + } + right_portrait = { + character = scope:chosen_architect + animation = reading + } + + immediate = { + scope:capital_county = { + add_county_modifier = { + modifier = fp3_spiritual_splendor_county_modifier + years = 30 + } + } + } + + option = { #A great temple + name = fp3_dynasty_decision.0007.a + + scope:chosen_architect = { + duel = { + skills = { stewardship learning } + value = medium_skill_rating + 50 = { + desc = splurge_above_expectations_toast + compare_modifier = { + value = scope:duel_value + multiplier = 3.5 + } + root = { + send_interface_toast = { + title = splurge_above_expectations_toast + left_icon = scope:chosen_architect + + add_piety = major_piety_gain + every_vassal = { + custom = every_zealot_vassal + limit = { has_vassal_stance = zealot } + add_opinion = { + target = root + modifier = approving_opinion + } + } + } + } + } + 50 = { + desc = splurge_as_expected_toast + compare_modifier = { + value = scope:duel_value + multiplier = -3.5 + } + root = { + send_interface_toast = { + title = splurge_as_expected_toast + left_icon = scope:chosen_architect + + add_piety = medium_piety_gain + } + } + } + } + } + + ai_chance = { #zealous AI prefer this option + base = 100 + ai_value_modifier = { + ai_zeal = 1 + } + } + } + + option = { #A great dakhma + name = fp3_dynasty_decision.0007.b + + trigger = { + faith = { + has_doctrine = tenet_sky_burials + } + NOR = { #fallback for future content + has_character_modifier = fp3_great_tower_of_silence_modifier + has_character_modifier = fp3_less_great_tower_of_silence_modifier + } + } + + scope:capital_county = { + add_county_modifier = { + modifier = fp3_spiritual_splendor_county_modifier + years = 30 + } + } + + scope:chosen_architect = { + duel = { + skill = stewardship + value = medium_skill_rating + 50 = { + desc = splurge_above_expectations_toast + compare_modifier = { + value = scope:duel_value + multiplier = 3.5 + } + root = { + send_interface_toast = { + title = splurge_above_expectations_toast + left_icon = scope:chosen_architect + + add_character_modifier = { + modifier = fp3_great_tower_of_silence_modifier + years = 30 + } + } + } + } + 50 = { + desc = splurge_as_expected_toast + compare_modifier = { + value = scope:duel_value + multiplier = -3.5 + } + root = { + send_interface_toast = { + title = splurge_as_expected_toast + left_icon = scope:chosen_architect + + add_character_modifier = { + modifier = fp3_less_great_tower_of_silence_modifier + years = 30 + } + } + } + } + } + } + + ai_chance = { #zealous-hubris AI prefer this option + base = 100 + ai_value_modifier = { + ai_zeal = 0.5 + ai_greed = 0.5 + } + } + } + + option = { #A sweet fresco + name = fp3_dynasty_decision.0007.d + + scope:chosen_architect = { + duel = { + skills = { stewardship diplomacy } + value = medium_skill_rating + 50 = { + desc = splurge_above_expectations_toast + compare_modifier = { + value = scope:duel_value + multiplier = 3.5 + } + root = { + send_interface_toast = { + title = splurge_above_expectations_toast + left_icon = scope:chosen_architect + + dynasty = { add_dynasty_prestige = major_dynasty_prestige_value } + house = { + every_house_member = { + custom = every_house_member + add_opinion = { + target = root + modifier = approving_opinion + } + } + } + } + } + } + 50 = { + desc = splurge_as_expected_toast + compare_modifier = { + value = scope:duel_value + multiplier = -3.5 + } + root = { + send_interface_toast = { + title = splurge_as_expected_toast + left_icon = scope:chosen_architect + + dynasty = { add_dynasty_prestige = medium_dynasty_prestige_value } + } + } + } + } + } + + ai_chance = { #ambitious AI prefer this option + base = 100 + ai_value_modifier = { + ai_rationality = 0.5 + ai_sociability = 0.5 + } + } + } +} + +# Myself +fp3_dynasty_decision.0008 = { + type = character_event + title = fp3_dynasty_decision.0008.t + desc = fp3_dynasty_decision.0008.desc + theme = realm + left_portrait = { + character = root + animation = reading + } + + override_background = { reference = relaxing_room } + + option = { #Roads and public works (Development bonus) + name = fp3_dynasty_decision.0008.a + + trigger = { has_lifestyle = stewardship_lifestyle } + + duel = { + skill = stewardship + value = medium_skill_rating + 50 = { + desc = splurge_above_expectations_toast + compare_modifier = { + value = scope:duel_value + multiplier = 3.5 + } + root = { + send_interface_toast = { + title = splurge_above_expectations_toast + left_icon = root + + scope:capital_county = { change_development_progress = medium_development_progress_gain } + add_stewardship_lifestyle_xp = massive_lifestyle_xp + } + } + } + 50 = { + desc = splurge_as_expected_toast + compare_modifier = { + value = scope:duel_value + multiplier = -3.5 + } + root = { + send_interface_toast = { + title = splurge_as_expected_toast + left_icon = root + + scope:capital_county = { change_development_progress = minor_development_progress_gain } + add_stewardship_lifestyle_xp = medium_lifestyle_xp + } + } + } + } + + ai_chance = { #compassionate-energetic AI prefer this option + base = 100 + ai_value_modifier = { + ai_compassion = 0.5 + ai_energy = 0.5 + } + } + } + + option = { #Local monuments (Acceptance or Control) + name = fp3_dynasty_decision.0008.b + + trigger = { has_lifestyle = diplomacy_lifestyle } + + duel = { + skills = { stewardship diplomacy } + value = medium_skill_rating + 50 = { + desc = splurge_above_expectations_toast + compare_modifier = { + value = scope:duel_value + multiplier = 3.5 + } + root = { + send_interface_toast = { + title = splurge_above_expectations_toast + left_icon = root + + if = { + limit = { + NOT = { scope:capital_county.culture = root.culture } + } + culture = { + change_cultural_acceptance = { + target = scope:capital_county.culture + value = medium_positive_culture_acceptance + desc = cultural_acceptance_built_magnificent_capital + } + } + } + else = { + scope:capital_county = { + change_county_control = 20 + } + } + add_diplomacy_lifestyle_xp = massive_lifestyle_xp + } + } + } + 50 = { + desc = splurge_as_expected_toast + compare_modifier = { + value = scope:duel_value + multiplier = -3.5 + } + root = { + send_interface_toast = { + title = splurge_as_expected_toast + left_icon = root + + if = { + limit = { + NOT = { scope:capital_county.culture = root.culture } + } + culture = { + change_cultural_acceptance = { + target = scope:capital_county.culture + value = low_positive_culture_acceptance + desc = cultural_acceptance_built_magnificent_capital + } + } + } + else = { + scope:capital_county = { + change_county_control = 10 + } + } + add_diplomacy_lifestyle_xp = medium_lifestyle_xp + } + } + } + } + + ai_chance = { #rational AI prefer this option + base = 100 + ai_value_modifier = { + ai_rationality = 1 + } + } + } + + option = { #Mausoleum (Renown) + name = fp3_dynasty_decision.0008.c + + trigger = { has_lifestyle = learning_lifestyle } + + duel = { + skills = { stewardship learning } + value = medium_skill_rating + 50 = { + desc = splurge_above_expectations_toast + compare_modifier = { + value = scope:duel_value + multiplier = 3.5 + } + root = { + send_interface_toast = { + title = splurge_above_expectations_toast + left_icon = root + + dynasty = { add_dynasty_prestige = major_dynasty_prestige_value } + add_learning_lifestyle_xp = massive_lifestyle_xp + } + } + } + 50 = { + desc = splurge_as_expected_toast + compare_modifier = { + value = scope:duel_value + multiplier = -3.5 + } + root = { + send_interface_toast = { + title = splurge_as_expected_toast + left_icon = root + + dynasty = { add_dynasty_prestige = medium_dynasty_prestige_value } + add_learning_lifestyle_xp = medium_lifestyle_xp + } + } + } + } + + + ai_chance = { #ambitious AI prefer this option + base = 100 + ai_value_modifier = { + ai_greed = 1 + } + } + } + + option = { #Hammam (Stress Loss) + name = fp3_dynasty_decision.0008.d + + trigger = { has_lifestyle = intrigue_lifestyle } + + duel = { + skills = { stewardship intrigue } + value = medium_skill_rating + 50 = { + desc = splurge_above_expectations_toast + compare_modifier = { + value = scope:duel_value + multiplier = 3.5 + } + root = { + send_interface_toast = { + title = splurge_above_expectations_toast + left_icon = root + + add_character_modifier = { + modifier = fp3_luxurious_bathhouse_modifier + years = 30 + } + add_intrigue_lifestyle_xp = massive_lifestyle_xp + } + } + } + 50 = { + desc = splurge_as_expected_toast + compare_modifier = { + value = scope:duel_value + multiplier = -3.5 + } + root = { + send_interface_toast = { + title = splurge_as_expected_toast + left_icon = root + + add_character_modifier = { + modifier = fp3_less_luxurious_bathhouse_modifier + years = 30 + } + add_intrigue_lifestyle_xp = medium_lifestyle_xp + } + } + } + } + + + ai_chance = { #social AI prefer this option + base = 100 + ai_value_modifier = { + ai_sociability = 1 + } + } + } + + option = { #Tower (Province improvement) + name = fp3_dynasty_decision.0008.e + + trigger = { has_lifestyle = martial_lifestyle } + + duel = { + skills = { stewardship martial } + value = medium_skill_rating + + 50 = { + desc = splurge_above_expectations_toast + compare_modifier = { + value = scope:duel_value + multiplier = 3.5 + } + root = { + send_interface_toast = { + title = splurge_above_expectations_toast + left_icon = root + + add_character_modifier = { + modifier = fp3_very_lofty_tower_modifier + years = 30 + } + add_martial_lifestyle_xp = massive_lifestyle_xp + } + } + } + 50 = { + desc = splurge_as_expected_toast + compare_modifier = { + value = scope:duel_value + multiplier = -3.5 + } + root = { + send_interface_toast = { + title = splurge_as_expected_toast + left_icon = root + + add_character_modifier = { + modifier = fp3_less_lofty_tower_modifier + years = 30 + } + add_martial_lifestyle_xp = medium_lifestyle_xp + } + } + } + } + + ai_chance = { #warlike AI prefer this option + base = 100 + ai_value_modifier = { + ai_boldness = 1 + } + } + } + + option = { #Palace (Prestige) + name = fp3_dynasty_decision.0008.f + + duel = { + skill = stewardship + value = medium_skill_rating + + 50 = { + desc = splurge_above_expectations_toast + compare_modifier = { + value = scope:duel_value + multiplier = 3.5 + } + root = { + send_interface_toast = { + title = splurge_above_expectations_toast + left_icon = root + + add_prestige = major_prestige_gain + every_vassal = { + custom = every_courtly_vassal + limit = { has_vassal_stance = courtly } + add_opinion = { + target = root + modifier = approving_opinion + } + } + } + } + } + 50 = { + desc = splurge_as_expected_toast + compare_modifier = { + value = scope:duel_value + multiplier = -3.5 + } + root = { + send_interface_toast = { + title = splurge_as_expected_toast + left_icon = root + + add_prestige = medium_prestige_gain + } + } + } + } + + ai_chance = { #honor-focused AI prefer this option + base = 100 + ai_value_modifier = { + ai_honor = 1 + } + } + } + + option = { #Temple (Piety) + name = fp3_dynasty_decision.0008.g + + duel = { + skills = { stewardship learning } + value = medium_skill_rating + + 50 = { + desc = splurge_above_expectations_toast + compare_modifier = { + value = scope:duel_value + multiplier = 3.5 + } + root = { + send_interface_toast = { + title = splurge_above_expectations_toast + left_icon = root + + add_piety = major_piety_gain + every_vassal = { + custom = every_zealot_vassal + limit = { has_vassal_stance = zealot } + add_opinion = { + target = root + modifier = approving_opinion + } + } + } + } + } + 50 = { + desc = splurge_as_expected_toast + compare_modifier = { + value = scope:duel_value + multiplier = -3.5 + } + root = { + send_interface_toast = { + title = splurge_as_expected_toast + left_icon = root + + add_piety = medium_piety_gain + } + } + } + } + + ai_chance = { #pious AI prefer this option + base = 100 + ai_value_modifier = { + ai_zeal = 1 + } + } + } + + after = { + scope:capital_county = { + add_county_modifier = { + modifier = fp3_architectural_splendor_county_modifier + years = 30 + } + } + } +} + + + diff --git a/events/dlc/fp3/fp3_extra_flavor_events.txt b/events/dlc/fp3/fp3_extra_flavor_events.txt new file mode 100644 index 0000000000..dd7e3cac6b --- /dev/null +++ b/events/dlc/fp3/fp3_extra_flavor_events.txt @@ -0,0 +1 @@ +# Warcraft \ No newline at end of file diff --git a/events/dlc/fp3/fp3_frontier_story_cycle.txt b/events/dlc/fp3/fp3_frontier_story_cycle.txt new file mode 100644 index 0000000000..dd7e3cac6b --- /dev/null +++ b/events/dlc/fp3/fp3_frontier_story_cycle.txt @@ -0,0 +1 @@ +# Warcraft \ No newline at end of file diff --git a/events/dlc/fp3/fp3_heritage_events.txt b/events/dlc/fp3/fp3_heritage_events.txt new file mode 100644 index 0000000000..dd7e3cac6b --- /dev/null +++ b/events/dlc/fp3/fp3_heritage_events.txt @@ -0,0 +1 @@ +# Warcraft \ No newline at end of file diff --git a/events/dlc/fp3/fp3_misc_decision_events.txt b/events/dlc/fp3/fp3_misc_decision_events.txt new file mode 100644 index 0000000000..8e6aac6816 --- /dev/null +++ b/events/dlc/fp3/fp3_misc_decision_events.txt @@ -0,0 +1,2600 @@ +namespace = fp3_misc_decisions + +### EVENT LIST #################################################################### +## 0005 - 0009 Request Invasion by Hugo Cortell +## 0010 - 0014 Demand Submission letter events +## 0015 - 0015 Embrace Zoroastrianism faith selection event +## 0020 - 0030 Challenge House Head Events by Hugo Cortell +## 0031 - 0040 Favor Skilled Outsiders events by Ewan Cowhig Croft +## 0041 - 0050 Extra Challenge House Head Events +################################################################################### + +################################### +# Challenge House Head Events +# By Hugo Cortell +# 0020 - 0030 + 0041 - 0050 +################################### + +scripted_trigger fp3_clan_challenge_negotiate_age_health_trigger = { + OR = { + AND = { + scope:recipient.health < fine_health + scope:recipient.health < scope:actor.health + } + AND = { + scope:recipient = { age_in_relation_to_humans_more_than_trigger = { age = 49 } } + scope:recipient.age >= root.age_plus_25 + } + OR = { + scope:recipient.age <= scope:actor.age_minus_10 + AND = { + scope:recipient = { is_sibling_of = scope:actor } + scope:recipient.age < scope:actor.age + } + } + } +} + +scripted_effect fp3_clan_challenge_negotiate_success_effect = { + save_scope_as = negotiate_success + save_scope_value_as = { + name = negotiate_reason + value = flag:$REASON$ + } + show_as_tooltip = { + scope:actor = { + add_prestige = medium_prestige_gain + house = { set_house_head = root } + } + } +} + +scripted_effect fp3_clan_challenge_negotiate_bargain_effect = { + save_scope_as = negotiate_bargain + save_scope_value_as = { + name = negotiate_reason + value = flag:$REASON$ + } + custom_tooltip = fp3_misc_decisions.0027.bargain.tt +} + +scripted_effect fp3_clan_challenge_negotiate_fail_effect = { + save_scope_as = negotiate_fail + save_scope_value_as = { + name = negotiate_reason + value = flag:$REASON$ + } + show_as_tooltip = { + scope:actor = { add_prestige = medium_prestige_loss } + scope:recipient = { + add_prestige = medium_piety_value + add_hook_no_toast = { + type = trial_by_combat_hook + target = scope:actor + } + } + } +} + +fp3_misc_decisions.0020 = { # Actor Duel Outcome(s) + type = character_event + title = fp3_misc_decisions.0020.t + desc = { + first_valid = { + triggered_desc = { + trigger = { + scope:sc_victor = scope:house_challenger + scope:sc_loser = { is_alive = no } + } + desc = fp3_misc_decisions.0020.desc.a.lethal + } + triggered_desc = { + trigger = { scope:sc_victor = scope:house_challenger } + desc = fp3_misc_decisions.0020.desc.a + } + desc = fp3_misc_decisions.0020.desc.b + } + } + + theme = dynasty + override_background = { reference = throne_room } + left_portrait = { + character = scope:house_challenger + animation = war_over_loss + + triggered_animation = { + trigger = { this = scope:sc_victor } + animation = war_over_win + } + } + right_portrait = { + character = scope:house_head + animation = war_over_loss + + triggered_animation = { + trigger = { is_alive = no } + animation = loss_1 + } + triggered_animation = { + trigger = { this = scope:sc_victor } + animation = war_over_win + } + } + + immediate = { + # Challenger lost + if = { + limit = { scope:sc_victor = scope:house_head } + show_as_tooltip = { fp3_challenge_house_head_duel_challenger_loss_effect = yes } # Prestige and hooks + } + # Challenger won + else = { + show_as_tooltip = { fp3_challenge_house_head_duel_challenger_win_prestige_effect = yes } # Prestige gain + } + } + + # OPTIONS FOR LOSER + option = { # Default option (goes on top, against design conventions) + name = fp3_misc_decisions.0020.lose.a + trigger = { scope:sc_loser = scope:house_challenger } + } + + option = { # Slay them to take the mantle + name = fp3_misc_decisions.0020.lose.b + trigger = { scope:sc_loser = root } + show_as_tooltip ={ + #Lose a ton of prestige for being so backhanded + add_prestige = massive_prestige_loss + add_prestige_level = -1 + } + duel = { + skills = { intrigue prowess } + target = scope:house_head + 1 = { + compare_modifier = { + value = scope:duel_value + multiplier = 3.5 + min = -49 + } + min = 1 + show_as_tooltip = { + known_murder_hidden_opinion_effect = { VICTIM = scope:house_head MURDERER = scope:house_challenger EXPOSER = scope:house_challenger } + house = { set_house_head = root } + } + save_scope_as = challenge_murder_success + } + 9 = { + compare_modifier = { + value = scope:duel_value + multiplier = -3.5 + min = -49 + } + scope:house_head = { + hidden_effect = { + random = { + chance = 50 + save_scope_as = challenge_wound + } + } + show_as_tooltip = { + if = { + limit = { + can_set_relation_rival_trigger = { CHARACTER = scope:house_challenger } + } + set_relation_rival = { + target = scope:house_challenger + reason = rival_tried_to_kill_me + } + } + add_opinion = { + target = scope:house_challenger + modifier = attempted_murder_me_crime + } + imprison = { + target = scope:house_challenger + type = house_arrest + } + } + } + } + } + trigger_event = fp3_misc_decisions.0041 + stress_impact = { + content = major_stress_impact_gain + just = medium_stress_impact_gain + forgiving = medium_stress_impact_gain + honest = medium_stress_impact_gain + } + ai_chance = { + base = 0 + } + } + + option = { + name = fp3_misc_decisions.0025.b + trigger = { + can_set_relation_rival_trigger = { CHARACTER = scope:recipient } + scope:recipient = { is_alive = yes } + } + progress_towards_rival_effect = { + REASON = rival_house_head_rejected_challenge + CHARACTER = scope:recipient + OPINION = default_rival_opinion + } + ai_chance = { + base = 5 + ai_value_modifier = { + ai_boldness = 0.25 + ai_vengefulness = 0.5 + } + } + } + + # OPTIONS FOR WINNER + option = { # Default option + name = fp3_misc_decisions.0020.win.a + trigger = { scope:sc_victor = scope:house_challenger } + fp3_challenge_house_head_duel_challenger_win_house_effect = yes + ai_chance = { + base = 25 + } + } + + option = { # You fought well and deserve to be house head + name = fp3_misc_decisions.0020.win.b + trigger = { + scope:sc_victor = scope:house_challenger + has_trait = gallant + scope:lethal != yes + } + add_prestige = massive_prestige_gain + reverse_add_opinion = { + target = scope:recipient + modifier = honored_opinion + } + house = { + add_clan_unity_interaction_effect = { + CHARACTER = scope:actor + TARGET = scope:recipient + VALUE = miniscule_unity_gain # recover half of what was lost by challenge itself + DESC = clan_unity_gallant_after_duel.desc + REVERSE_NON_HOUSE_TARGET = yes + } + } + stress_impact = { + greedy = major_stress_impact_gain + ambitious = medium_stress_impact_gain + } + ai_chance = { + base = 10 + ai_value_modifier = { + ai_honor = 0.5 + ai_compassion = 0.25 + ai_greed = -1 + } + opinion_modifier = { + opinion_target = scope:recipient + multiplier = 0.25 + } + } + } +} + +# Bout has ended, inform affected parties. +fp3_misc_decisions.0021 = { + hidden = yes + + immediate = { + if = { + limit = { scope:sc_victor = scope:house_challenger } + fp3_challenge_house_head_duel_challenger_win_prestige_effect = yes + } + else = { fp3_challenge_house_head_duel_challenger_loss_effect = yes } + scope:house_challenger = { + trigger_event = { + id = fp3_misc_decisions.0020 + days = 1 + } + } + scope:house_head = { + trigger_event = { + id = fp3_misc_decisions.0023 + days = 1 + } + # allow challenges again + if = { + limit = { is_alive = yes } + remove_character_flag = ongoing_house_head_challenge_flag + } + } + # If both parties are alive, and aren't good losers/don't have good reasons to forgive each other, then we mark them as potential rivals. + if = { + limit = { + scope:house_challenger = { + is_alive = yes + NOR = { + has_trait = humble + has_trait = content + has_trait = just + has_trait = forgiving + } + } + scope:house_head = { + is_alive = yes + NOR = { + has_trait = humble + has_trait = content + has_trait = just + has_trait = forgiving + } + can_set_relation_potential_rival_trigger = { CHARACTER = scope:house_challenger } + } + } + scope:house_challenger = { set_relation_potential_rival = scope:house_head } + } + } +} + +fp3_misc_decisions.0022 = { # Actor Duel opening + type = character_event + window = duel_event + title = fp3_misc_decisions.0022.t + desc = { + desc = fp3_misc_decisions.0022.desc.intro + desc = fp1_tbc.0001.desc.outro + desc = fp3_misc_decisions.0022.desc.body + } + theme = dynasty + left_portrait = { + character = scope:actor + animation = throne_room_one_handed_passive_1 + } + right_portrait = { + character = scope:recipient + animation = war_over_win + } + override_background = { reference = throne_room } + + trigger = { + # DLC check. + has_fp3_dlc_trigger = yes + # If, for any reason, scope:recipient has died or been imprisoned, then the bout is cancelled. + scope:recipient = { + is_alive = yes + is_imprisoned = no + } + } + + on_trigger_fail = { + # Inform both parties that the duel has invalidated. + scope:actor = { + send_interface_toast = { + title = fp3_misc_decisions.0022.trigger_failure.actor + left_icon = scope:recipient + } + } + scope:recipient = { + send_interface_toast = { + title = fp3_misc_decisions.0022.trigger_failure.recipient + left_icon = scope:actor + } + } + # Reset scope:actor's cooldowns against scope:recipient. + scope:actor = { + remove_interaction_cooldown = challenge_to_trial_by_combat_interaction + remove_interaction_cooldown_against = { + interaction = fp3_challenge_house_head_interaction + target = scope:recipient + } + } + scope:recipient = { + # allow challenges again + remove_character_flag = ongoing_house_head_challenge_flag + } + } + + immediate = { + play_music_cue = "mx_cue_combat_stinger" + # Nab scope:champion's location for terrain. + scope:recipient = { + # And scope:champion's location name for loc. + location.barony = { save_scope_as = duel_location } + } + } + + # Almost there. + option = { + name = fp3_misc_decisions.0022.a + + # Inform scope:actor that the bout will begin immediately. + custom_tooltip = fp3_misc_decisions.0022.a.tt + # Configure the bout. + switch = { + trigger = scope:lethal + yes = { + configure_start_single_combat_effect = { + SC_INITIATOR = scope:actor + SC_ATTACKER = scope:actor + SC_DEFENDER = scope:recipient + FATALITY = always + FIXED = no + LOCALE = throne_room + OUTPUT_EVENT = fp3_misc_decisions.0021 + INVALIDATION_EVENT = single_combat.1006 + } + } + no = { + configure_start_single_combat_effect = { + SC_INITIATOR = scope:actor + SC_ATTACKER = scope:actor + SC_DEFENDER = scope:recipient + FATALITY = no + FIXED = no + LOCALE = throne_room + OUTPUT_EVENT = fp3_misc_decisions.0021 + INVALIDATION_EVENT = single_combat.1006 + } + } + } + # No stress for single-option events. + ai_chance = { + # AI will always choose single option. + base = 100 + } + } +} + +fp3_misc_decisions.0023 = { # Recipient Duel Outcome(s) + type = character_event + title = fp3_misc_decisions.0020.t + desc = { + first_valid = { + triggered_desc = { + trigger = { + scope:sc_loser = { is_alive = no } + scope:sc_victor = scope:house_head + } + desc = fp3_misc_decisions.0023.desc.a.lethal + } + triggered_desc = { + trigger = { scope:sc_victor = scope:house_head } + desc = fp3_misc_decisions.0023.desc.a + } + desc = fp3_misc_decisions.0023.desc.b + } + } + + theme = dynasty + override_background = { reference = throne_room } + left_portrait = { + character = scope:house_head + animation = war_over_loss + + triggered_animation = { + trigger = { this = scope:sc_victor } + animation = war_over_win + } + } + right_portrait = { + character = scope:house_challenger + animation = war_over_loss + + triggered_animation = { + trigger = { is_alive = no } + animation = loss_1 + } + triggered_animation = { + trigger = { this = scope:sc_victor } + animation = war_over_win + } + } + + immediate = { + if = { + limit = { scope:sc_victor = scope:house_head } + show_as_tooltip = { fp3_challenge_house_head_duel_challenger_loss_effect = yes } # Prestige and hooks + } + else = { + show_as_tooltip = { + fp3_challenge_house_head_duel_challenger_win_prestige_effect = yes # Prestige gain + fp3_challenge_house_head_duel_challenger_win_house_effect = yes # House head change + } + } + } + + # OPTIONS FOR WINNER + option = { # Default option (goes on top, against design conventions) + name = fp3_misc_decisions.0023.win.a + trigger = { scope:sc_victor = scope:house_head } + } + + # OPTIONS FOR LOSER + option = { # Default option + name = fp3_misc_decisions.0023.lose.a + trigger = { scope:sc_victor = scope:house_challenger } + } +} + +fp3_misc_decisions.0025 = { # Interaction declined + type = letter_event + sender = scope:recipient + opening = fp3_misc_decisions.0025.t + desc = fp3_misc_decisions.0025.desc + + immediate = { + show_as_tooltip = { scope:recipient = { add_prestige = major_prestige_loss } } + } + + option = { + name = fp3_misc_decisions.0025.a + ai_chance = { + base = 25 + ai_value_modifier = { + ai_honor = 0.25 + } + } + } + + option = { + name = fp3_misc_decisions.0025.b + trigger = { + can_set_relation_rival_trigger = { CHARACTER = scope:recipient } + } + progress_towards_rival_effect = { + REASON = rival_house_head_rejected_challenge + CHARACTER = scope:recipient + OPINION = default_rival_opinion + } + ai_chance = { + base = 5 + ai_value_modifier = { + ai_boldness = 0.25 + ai_vengefulness = 0.5 + } + } + } +} + +fp3_misc_decisions.0026 = { # Actor Diplomacy opening + type = character_event + title = fp3_misc_decisions.0022.t + desc = fp3_misc_decisions.0026.desc + theme = dynasty + left_portrait = { + character = scope:actor + animation = worry + } + right_portrait = { + character = scope:recipient + animation = war_over_win + } + override_background = { reference = throne_room } + + trigger = { + # DLC check. + has_fp3_dlc_trigger = yes + # If, for any reason, scope:recipient has died or been imprisoned, then the bout is cancelled. + scope:recipient = { + is_alive = yes + is_imprisoned = no + } + } + + on_trigger_fail = { + # Inform both parties that the duel has invalidated. + scope:actor = { + send_interface_toast = { + title = fp3_misc_decisions.0022.trigger_failure.actor + left_icon = scope:recipient + } + } + scope:recipient = { + send_interface_toast = { + title = fp3_misc_decisions.0022.trigger_failure.recipient + left_icon = scope:actor + } + } + # Reset scope:actor's cooldowns against scope:recipient. + scope:actor = { + remove_interaction_cooldown = challenge_to_trial_by_combat_interaction + remove_interaction_cooldown_against = { + interaction = fp3_challenge_house_head_interaction + target = scope:recipient + } + } + scope:recipient = { + # allow challenges again + remove_character_flag = ongoing_house_head_challenge_flag + } + } + + immediate = { + play_music_cue = "mx_cue_combat_stinger" + # Nab scope:champion's location for terrain. + scope:recipient = { + # And scope:champion's location name for loc. + location.barony = { save_scope_as = duel_location } + } + } + + # Almost there. + option = { + name = fp3_misc_decisions.0026.a + custom_tooltip = fp3_misc_decisions.0026.a.tt + trigger_event = { + id = fp3_misc_decisions.0027 + days = 1 + } + # No stress for single-option events. + ai_chance = { + # AI will always choose single option. + base = 100 + } + } +} + +fp3_misc_decisions.0027 = { # Actor reason choice + type = character_event + title = fp3_misc_decisions.0022.t + desc = fp3_misc_decisions.0027.desc + theme = dynasty + left_portrait = { + character = scope:actor + animation = admiration + } + right_portrait = { + character = scope:recipient + animation = thinking + } + override_background = { reference = throne_room } + + trigger = { + # DLC check. + has_fp3_dlc_trigger = yes + # Both parties alive and well + scope:actor = { + is_alive = yes + is_imprisoned = no + } + scope:recipient = { + is_alive = yes + is_imprisoned = no + } + } + + immediate = { + save_scope_value_as = { + name = recipient_skill_sum_75 + value = { + value = scope:recipient.sum_of_all_skills_value + multiply = 0.75 + round = yes + } + } + } + + # Age/health, a rational option + option = { + name = { + trigger = { + scope:recipient.health < fine_health + scope:recipient.health < scope:actor.health + } + text = fp3_misc_decisions.0027.a.sick + } + name = { + trigger = { + scope:recipient = { age_in_relation_to_humans_more_than_trigger = { age = 49 } } + scope:recipient.age >= root.age_plus_25 + } + text = fp3_misc_decisions.0027.a.old + } + name = { + trigger = { + NOR = { + AND = { + scope:recipient.health < fine_health + scope:recipient.health < scope:actor.health + } + AND = { + scope:recipient = { age_in_relation_to_humans_more_than_trigger = { age = 49 } } + scope:recipient.age >= root.age_plus_25 + } + } + } + text = fp3_misc_decisions.0027.a.young + } + trigger = { + custom_tooltip = { + text = fp3_misc_decisions.0027.a.trigger + fp3_clan_challenge_negotiate_age_health_trigger = yes + } + } + show_as_unavailable = { always = yes } + flavor = { + first_valid = { + triggered_desc = { + trigger = { + scope:recipient.health < fine_health + scope:recipient.health < scope:actor.health + } + desc = fp3_misc_decisions.0027.a.sick.tt + } + triggered_desc = { + trigger = { scope:recipient.age > scope:actor.age } + desc = fp3_misc_decisions.0027.a.old.tt + } + triggered_desc = { + trigger = { scope:recipient.age < scope:actor.age } + desc = fp3_misc_decisions.0027.a.young.tt + } + } + } + duel = { + skills = { learning } + target = scope:recipient + 1 = { + compare_modifier = { + value = scope:duel_value + multiplier = 3.5 + min = -49 + } + min = 1 + desc = fp3_misc_decisions.0027.accept + fp3_clan_challenge_negotiate_success_effect = { REASON = age } + } + 5 = { + # Personality + fp3_challenge_house_head_negotiation_bargain_modifier = yes + compare_modifier = { + value = scope:duel_value + multiplier = 1 + min = -49 + } + min = 1 + desc = fp3_misc_decisions.0027.bargain + fp3_clan_challenge_negotiate_bargain_effect = { REASON = age } + } + 20 = { + # Personality + fp3_challenge_house_head_negotiation_reject_modifier = yes + compare_modifier = { + value = scope:duel_value + multiplier = 1 + min = -49 + } + # Age + modifier = { + scope:recipient.age <= scope:actor.age_minus_10 + scope:recipient = { has_trait = arrogant } + add = 10 + } + # Health + modifier = { + add = { + value = scope:recipient.health + multiply = 2 + } + } + min = 15 + desc = fp3_misc_decisions.0027.reject + fp3_clan_challenge_negotiate_fail_effect = { REASON = age } + } + } + ai_chance = { + base = 100 + } + } + + # Strength, might makes right + option = { + name = { + trigger = { + scope:recipient = { is_vassal_or_below_of = scope:actor } + } + text = fp3_misc_decisions.0027.b.vassal + } + name = { + trigger = { scope:recipient.highest_held_title_tier < scope:actor.highest_held_title_tier } + text = fp3_misc_decisions.0027.b.tier + } + name = { + trigger = { scope:recipient.current_military_strength < scope:actor.current_strength_seventy_five_percent_value } + text = fp3_misc_decisions.0027.b.military + } + name = { + trigger = { + NOR = { + scope:recipient = { is_vassal_or_below_of = scope:actor } + scope:recipient.highest_held_title_tier < scope:actor.highest_held_title_tier + scope:recipient.current_military_strength < scope:actor.current_strength_seventy_five_percent_value + } + } + text = fp3_misc_decisions.0027.b.dread + } + trigger = { + custom_tooltip = { + text = fp3_misc_decisions.0027.b.trigger + OR = { + scope:recipient = { is_vassal_or_below_of = scope:actor } + scope:recipient.highest_held_title_tier < scope:actor.highest_held_title_tier + scope:recipient.current_military_strength < scope:actor.current_strength_seventy_five_percent_value + scope:recipient = { + has_dread_level_towards = { + target = scope:actor + level >= 1 + } + } + } + } + } + show_as_unavailable = { always = yes } + flavor = { + first_valid = { + triggered_desc = { + trigger = { + scope:recipient = { is_vassal_or_below_of = scope:actor } + } + desc = fp3_misc_decisions.0027.b.vassal.tt + } + triggered_desc = { + trigger = { scope:recipient.highest_held_title_tier < scope:actor.highest_held_title_tier } + desc = fp3_misc_decisions.0027.b.tier.tt + } + triggered_desc = { + trigger = { scope:recipient.current_military_strength < scope:actor.current_strength_seventy_five_percent_value } + desc = fp3_misc_decisions.0027.b.military.tt + } + desc = fp3_misc_decisions.0027.b.dread.tt + } + } + duel = { + skills = { martial } + target = scope:recipient + 1 = { + compare_modifier = { + value = scope:duel_value + multiplier = 3.5 + min = -49 + } + desc = fp3_misc_decisions.0027.accept + fp3_clan_challenge_negotiate_success_effect = { REASON = strength } + } + 5 = { + # Personality + fp3_challenge_house_head_negotiation_bargain_modifier = yes + compare_modifier = { + value = scope:duel_value + multiplier = 1 + min = -49 + } + min = 1 + desc = fp3_misc_decisions.0027.bargain + fp3_clan_challenge_negotiate_bargain_effect = { REASON = strength } + } + 20 = { + fp3_challenge_house_head_negotiation_reject_modifier = yes + compare_modifier = { + value = scope:duel_value + multiplier = -3.5 + min = -49 + } + min = 15 + desc = fp3_misc_decisions.0027.reject + fp3_clan_challenge_negotiate_fail_effect = { REASON = strength } + } + } + ai_chance = { + base = 100 + } + } + + # Skill, just more qualified + option = { + name = fp3_misc_decisions.0027.c + trigger = { + custom_tooltip = { + text = fp3_misc_decisions.0027.c.trigger + scope:actor.sum_of_all_skills_value >= scope:recipient.sum_of_all_skills_value + } + } + show_as_unavailable = { always = yes } + flavor = fp3_misc_decisions.0027.c.tt + duel = { + skills = { diplomacy martial stewardship intrigue learning } + target = scope:recipient + 1 = { + compare_modifier = { + value = scope:duel_value + multiplier = 3.5 + min = -49 + } + desc = fp3_misc_decisions.0027.accept + fp3_clan_challenge_negotiate_success_effect = { REASON = strength } + } + 5 = { + # Personality + fp3_challenge_house_head_negotiation_bargain_modifier = yes + compare_modifier = { + value = scope:duel_value + multiplier = 1 + min = -49 + } + min = 1 + desc = fp3_misc_decisions.0027.bargain + fp3_clan_challenge_negotiate_bargain_effect = { REASON = strength } + } + 20 = { + fp3_challenge_house_head_negotiation_reject_modifier = yes + compare_modifier = { + value = scope:duel_value + multiplier = -3.5 + min = -49 + } + min = 15 + desc = fp3_misc_decisions.0027.reject + fp3_clan_challenge_negotiate_fail_effect = { REASON = strength } + } + } + ai_chance = { + base = 100 + } + } + + # Fallback, pure charisma + option = { + name = fp3_misc_decisions.0027.d + duel = { + skill = diplomacy + target = scope:recipient + 1 = { + compare_modifier = { + value = scope:duel_value + multiplier = 3.5 + min = -49 + } + desc = fp3_misc_decisions.0027.accept + fp3_clan_challenge_negotiate_success_effect = { REASON = fallback } + } + 5 = { + fp3_challenge_house_head_negotiation_bargain_modifier = yes + compare_modifier = { + value = scope:duel_value + multiplier = 1 + min = -49 + } + min = 1 + desc = fp3_misc_decisions.0027.bargain + fp3_clan_challenge_negotiate_bargain_effect = { REASON = fallback } + } + 20 = { + fp3_challenge_house_head_negotiation_reject_modifier = yes + compare_modifier = { + value = scope:duel_value + multiplier = -5 + min = -49 + } + min = 15 + desc = fp3_misc_decisions.0027.reject + fp3_clan_challenge_negotiate_fail_effect = { REASON = fallback } + } + } + ai_chance = { + base = 25 + } + } + + after = { + scope:recipient = { + trigger_event = { + id = fp3_misc_decisions.0028 + days = 1 + } + } + } +} + +fp3_misc_decisions.0028 = { # Recipient response + type = character_event + title = fp3_misc_decisions.0022.t + desc = { + desc = fp3_misc_decisions.0028.desc + first_valid = { + # Age + triggered_desc = { # Sick + trigger = { + scope:negotiate_reason = flag:age + scope:recipient.health < fine_health + scope:recipient.health < scope:actor.health + } + desc = fp3_misc_decisions.0028.sick + } + triggered_desc = { # Old + trigger = { + scope:negotiate_reason = flag:age + scope:recipient.age > scope:actor.age + } + desc = fp3_misc_decisions.0028.old + } + triggered_desc = { # Young + trigger = { scope:negotiate_reason = flag:age } + desc = fp3_misc_decisions.0028.young + } + # Strength + triggered_desc = { + trigger = { + scope:negotiate_reason = flag:strength + scope:recipient = { is_vassal_or_below_of = scope:actor } + } + desc = fp3_misc_decisions.0028.vassal + } + triggered_desc = { + trigger = { + scope:negotiate_reason = flag:strength + scope:recipient.highest_held_title_tier < scope:actor.highest_held_title_tier + } + desc = fp3_misc_decisions.0028.tier + } + triggered_desc = { + trigger = { + scope:negotiate_reason = flag:strength + scope:recipient.current_military_strength < scope:actor.current_strength_seventy_five_percent_value + } + desc = fp3_misc_decisions.0028.military + } + triggered_desc = { + trigger = { scope:negotiate_reason = flag:strength } + desc = fp3_misc_decisions.0028.dread + } + # Skill + triggered_desc = { + trigger = { scope:negotiate_reason = flag:skill } + desc = fp3_misc_decisions.0028.skill + } + # Fallback + triggered_desc = { + trigger = { scope:negotiate_reason = flag:fallback } + desc = fp3_misc_decisions.0028.fallback + } + } + } + theme = dynasty + left_portrait = { + character = scope:recipient + animation = thinking + } + right_portrait = { + character = scope:actor + animation = admiration + } + override_background = { reference = throne_room } + + trigger = { + # DLC check. + has_fp3_dlc_trigger = yes + # Both parties alive and well + scope:actor = { + is_alive = yes + is_imprisoned = no + } + scope:recipient = { + is_alive = yes + is_imprisoned = no + } + } + + # Accept + option = { + name = fp3_misc_decisions.0028.a + save_scope_as = negotiate_accept + show_as_tooltip = { + house = { set_house_head = scope:actor } + } + add_character_flag = { + flag = accepted_house_head_challenge_flag + years = 10 + } + ai_chance = { + base = 0 + modifier = { + exists = scope:negotiate_success + add = 100 + } + } + } + + # Bargain regent + option = { + name = fp3_misc_decisions.0028.b + trigger = { + is_diarch = no + scope:actor = { has_active_diarchy = no } + } + save_scope_as = negotiate_regent + ai_chance = { + base = 0 + modifier = { + exists = scope:negotiate_bargain + add = 100 + } + } + } + + # Bargain gold + option = { + name = fp3_misc_decisions.0028.c + save_scope_as = negotiate_gold + custom_tooltip = fp3_misc_decisions.0028.bargain.tt + show_as_tooltip = { + scope:actor = { + pay_short_term_gold = { + gold = scope:actor.medium_gold_value + target = scope:recipient + } + } + house = { set_house_head = scope:actor } + } + ai_chance = { + base = 0 + modifier = { + exists = scope:negotiate_bargain + add = 100 + } + } + } + + # Bargain hook + option = { + name = fp3_misc_decisions.0028.d + save_scope_as = negotiate_hook + custom_tooltip = fp3_misc_decisions.0028.bargain.tt + show_as_tooltip = { + scope:recipient = { + add_hook_no_toast = { + target = scope:actor + type = predecessor_loyalty_hook + } + } + house = { set_house_head = scope:actor } + } + ai_chance = { + base = 0 + modifier = { + exists = scope:negotiate_bargain + add = 100 + } + } + } + + # Reject + option = { + name = fp3_misc_decisions.0028.e + ai_chance = { + base = 0 + modifier = { + exists = scope:negotiate_fail + add = 100 + } + } + } + + after = { + scope:actor = { + trigger_event = { + id = fp3_misc_decisions.0029 + days = 1 + } + } + } +} + +fp3_misc_decisions.0029 = { # Actor response + type = character_event + title = { + desc = { + first_valid = { + triggered_desc = { + trigger = { + calc_true_if = { + amount >= 1 + exists = scope:negotiate_regent + exists = scope:negotiate_gold + exists = scope:negotiate_hook + } + } + desc = fp3_misc_decisions.0022.t + } + desc = fp3_misc_decisions.0020.t + } + } + } + desc = { + desc = fp3_misc_decisions.0029.desc + first_valid = { + triggered_desc = { + trigger = { exists = scope:negotiate_accept } + desc = fp3_misc_decisions.0029.accept + } + triggered_desc = { + trigger = { exists = scope:negotiate_regent } + desc = fp3_misc_decisions.0029.regent + } + triggered_desc = { + trigger = { exists = scope:negotiate_gold } + desc = fp3_misc_decisions.0029.gold + } + triggered_desc = { + trigger = { exists = scope:negotiate_hook } + desc = fp3_misc_decisions.0029.hook + } + desc = fp3_misc_decisions.0029.fail + } + } + theme = dynasty + left_portrait = { + character = scope:actor + animation = war_over_loss + triggered_animation = { + trigger = { + OR = { + exists = scope:negotiate_regent + exists = scope:negotiate_gold + exists = scope:negotiate_hook + } + } + animation = war_over_tie + } + triggered_animation = { + trigger = { exists = scope:negotiate_accept } + animation = war_over_win + } + animation = war_over_loss + } + right_portrait = { + character = scope:recipient + animation = thinking + } + override_background = { reference = throne_room } + + trigger = { + # DLC check. + has_fp3_dlc_trigger = yes + # Both parties alive and well + scope:actor = { + is_alive = yes + is_imprisoned = no + } + scope:recipient = { + is_alive = yes + is_imprisoned = no + } + } + + immediate = { + if = { + limit = { + calc_true_if = { + amount = 0 + exists = scope:negotiate_regent + exists = scope:negotiate_gold + exists = scope:negotiate_hook + } + } + play_music_cue = "mx_cue_negative" + } + else_if = { + limit = { exists = scope:negotiate_accept } + play_music_cue = "mx_cue_positive_effect" + } + } + + # Accepted + option = { + name = fp3_misc_decisions.0029.a + trigger = { exists = scope:negotiate_accept } + save_scope_as = negotiate_accept + house = { set_house_head = scope:actor } + } + + # Accept bargain + option = { + name = fp3_misc_decisions.0029.b + trigger = { + calc_true_if = { + amount >= 1 + exists = scope:negotiate_regent + exists = scope:negotiate_gold + exists = scope:negotiate_hook + } + } + show_as_tooltip = { + switch = { + trigger = exists + scope:negotiate_regent = { + scope:actor = { + set_diarch = scope:recipient + start_diarchy = vizierate + } + } + scope:negotiate_gold = { + scope:actor = { + pay_short_term_gold = { + gold = scope:recipient.medium_gold_value + target = scope:recipient + } + } + } + scope:negotiate_hook = { + scope:recipient = { + add_hook_no_toast = { + target = scope:actor + type = predecessor_loyalty_hook + } + } + } + } + house = { set_house_head = scope:actor } + } + save_scope_as = negotiate_bargain_accept + scope:recipient = { trigger_event = fp3_misc_decisions.0030 } + } + + # Reject bargain + option = { + name = fp3_misc_decisions.0029.c + trigger = { + calc_true_if = { + amount >= 1 + exists = scope:negotiate_regent + exists = scope:negotiate_gold + exists = scope:negotiate_hook + } + } + save_scope_as = negotiate_bargain_reject + scope:recipient = { trigger_event = fp3_misc_decisions.0030 } + } + + # Reject + option = { + name = fp3_misc_decisions.0029.d + trigger = { + calc_true_if = { + amount = 0 + exists = scope:negotiate_regent + exists = scope:negotiate_gold + exists = scope:negotiate_hook + exists = scope:negotiate_accept + } + } + ai_chance = { + base = 0 + modifier = { + exists = scope:negotiate_fail + add = 100 + } + } + } +} + +fp3_misc_decisions.0030 = { # Actor response + type = character_event + title = fp3_misc_decisions.0022.t + desc = fp3_misc_decisions.0030.desc + theme = dynasty + left_portrait = { + character = scope:recipient + animation = war_over_win + } + right_portrait = { + character = scope:actor + animation = dismissal + } + override_background = { reference = throne_room } + + trigger = { + # DLC check. + has_fp3_dlc_trigger = yes + # Both parties alive and well + scope:actor = { + is_alive = yes + is_imprisoned = no + } + scope:recipient = { + is_alive = yes + is_imprisoned = no + } + } + + immediate = { + switch = { + trigger = exists + scope:negotiate_regent = { + scope:actor = { + set_diarch = scope:recipient + start_diarchy = vizierate + } + } + scope:negotiate_gold = { + scope:actor = { + pay_short_term_gold = { + gold = scope:recipient.medium_gold_value + target = scope:recipient + } + } + } + scope:negotiate_hook = { + scope:recipient = { + add_hook_no_toast = { + target = scope:actor + type = predecessor_loyalty_hook + } + } + } + } + house = { set_house_head = scope:actor } + } + + # Accepted + option = { + name = fp3_misc_decisions.0030.a + trigger = { exists = scope:negotiate_bargain_accept } + } + + # Rejected + option = { + name = fp3_misc_decisions.0030.b + trigger = { exists = scope:negotiate_bargain_reject } + } +} + +fp3_misc_decisions.0041 = { # Murder attempt outcome + type = character_event + title = fp3_misc_decisions.0020.t + desc = { + desc = fp3_misc_decisions.0041.intro + first_valid = { + triggered_desc = { + trigger = { exists = scope:challenge_murder_success } + desc = fp3_misc_decisions.0041.desc.success + } + desc = fp3_misc_decisions.0041.desc.failure + } + } + theme = dynasty + left_portrait = { + character = scope:house_challenger + animation = loss_1 + triggered_animation = { + trigger = { exists = scope:challenge_murder_success } + animation = assassin + } + } + right_portrait = { + character = scope:house_head + animation = anger + triggered_animation = { + trigger = { exists = scope:challenge_murder_success } + animation = fear + } + } + override_background = { reference = throne_room } + + trigger = { + # DLC check. + has_fp3_dlc_trigger = yes + # Both parties alive and well + scope:actor = { + is_alive = yes + is_imprisoned = no + } + scope:recipient = { + is_alive = yes + is_imprisoned = no + } + } + + immediate = { + add_prestige = massive_prestige_loss + add_prestige_level = -1 + if = { + limit = { exists = scope:challenge_murder_success } + house = { set_house_head = root } + show_as_tooltip = { + known_murder_effect = { VICTIM = scope:house_head MURDERER = scope:house_challenger EXPOSER = scope:house_challenger } + } + scope:house_head = { trigger_event = fp3_misc_decisions.0043 } + } + else = { + scope:house_head = { + show_as_tooltip = { + if = { + limit = { + can_set_relation_rival_trigger = { CHARACTER = scope:house_challenger } + } + set_relation_rival = { + target = scope:house_challenger + reason = rival_tried_to_kill_me + } + } + } + if = { + limit = { exists = scope:challenge_wound } + show_as_tooltip = { + increase_wounds_no_death_effect = { REASON = murder } + } + } + } + show_as_tooltip = { + attempted_murder_opinion_effect = { + VICTIM = scope:house_head + MURDERER = scope:house_challenger + } + } + show_as_tooltip = { + scope:house_head = { + imprison = { + target = scope:house_challenger + type = house_arrest + } + } + } + scope:house_head = { trigger_event = fp3_misc_decisions.0042 } + } + } + + # Yay + option = { + name = fp3_misc_decisions.0041.a + trigger = { exists = scope:challenge_murder_success } + } + + # Curses + option = { + name = fp3_misc_decisions.0041.b + trigger = { + NOT = { exists = scope:challenge_murder_success } + } + } +} + +fp3_misc_decisions.0042 = { # Failed Murder ping + type = character_event + title = fp3_misc_decisions.0020.t + desc = fp3_misc_decisions.0042.desc + theme = dynasty + left_portrait = { + character = scope:house_head + animation = anger + } + right_portrait = { + character = scope:house_challenger + animation = fear + } + override_background = { reference = throne_room } + + trigger = { + # DLC check. + has_fp3_dlc_trigger = yes + # Both parties alive and well + scope:actor = { + is_alive = yes + is_imprisoned = no + } + scope:recipient = { + is_alive = yes + is_imprisoned = no + } + } + + immediate = { + if = { + limit = { exists = scope:challenge_wound } + increase_wounds_no_death_effect = { REASON = murder } + } + show_as_tooltip = { + scope:house_challenger = { + add_prestige = massive_prestige_loss + add_prestige_level = -1 + } + attempted_murder_opinion_effect = { + VICTIM = scope:house_head + MURDERER = scope:house_challenger + } + } + rightfully_imprison_character_effect = { + TARGET = scope:house_challenger + IMPRISONER = scope:house_head + } + } + + # Yay + option = { + name = fp3_misc_decisions.0042.a + trigger = { exists = scope:challenge_murder_success } + } +} + +fp3_misc_decisions.0043 = { # Succesful Murder ping + type = character_event + title = fp3_misc_decisions.0020.t + desc = fp3_misc_decisions.0043.desc + theme = dynasty + left_portrait = { + character = scope:house_head + animation = loss_1 + } + right_portrait = { + character = scope:house_challenger + animation = assassin + } + override_background = { reference = throne_room } + + trigger = { + # DLC check. + has_fp3_dlc_trigger = yes + # Both parties alive and well + scope:actor = { + is_alive = yes + is_imprisoned = no + } + scope:recipient = { + is_alive = yes + is_imprisoned = no + } + } + + immediate = { + show_as_tooltip = { + scope:house_challenger = { + add_prestige = massive_prestige_loss + add_prestige_level = -1 + } + } + known_murder_effect = { VICTIM = scope:house_head MURDERER = scope:house_challenger EXPOSER = scope:house_challenger } + } + + # Curses + option = { + name = fp3_misc_decisions.0043.a + } +} + +################################################## +# Favour Skilled Outsiders +# by Ewan Cowhig Croft +# 0031 - 0040 +################################################## + +scripted_trigger fp3_misc_decisions_0031_preferred_ethoses_trigger = { + # Eloquent Captains + trigger_if = { + limit = { scope:outsider_diplomacy_martial = yes } + # Cultures more likely to send people to this type of position. + culture = { + OR = { + has_cultural_pillar = ethos_bellicose + has_cultural_pillar = ethos_courtly + } + } + } + # Career Soldiers + trigger_if = { + limit = { scope:outsider_martial_prowess = yes } + # Cultures more likely to send people to this type of position. + culture = { + OR = { + has_cultural_pillar = ethos_bellicose + has_cultural_pillar = ethos_stoic + } + } + } + # Fringe Nobility + trigger_if = { + limit = { scope:outsider_prowess_learning = yes } + # Cultures more likely to send people to this type of position. + culture = { + OR = { + has_cultural_pillar = ethos_stoic + has_cultural_pillar = ethos_communal + } + } + } + # Dedicated Functionaries + trigger_if = { + limit = { scope:outsider_learning_intrigue = yes } + # Cultures more likely to send people to this type of position. + culture = { + OR = { + has_cultural_pillar = ethos_bureaucratic + has_cultural_pillar = ethos_spiritual + } + } + } + # Cunning Officials + trigger_if = { + limit = { scope:outsider_intrigue_stewardship = yes } + # Cultures more likely to send people to this type of position. + culture = { + OR = { + has_cultural_pillar = ethos_courtly + has_cultural_pillar = ethos_egalitarian + } + } + } + # Skilled Administrators + trigger_if = { + limit = { scope:outsider_stewardship_diplomacy = yes } + # Cultures more likely to send people to this type of position. + culture = { + OR = { + has_cultural_pillar = ethos_bureaucratic + has_cultural_pillar = ethos_spiritual + } + } + } +} + +scripted_effect fp3_misc_decisions_0031_create_char_no_dynasty_effect = { + create_character = { + template = fp3_skilled_outsider_template + location = scope:batch_$BATCH$_county.title_province + dynasty = none + culture = scope:batch_$BATCH$_county.culture + faith = scope:batch_$BATCH$_county.faith + after_creation = { + add_to_list = batch_$BATCH$_characters_list + # Set an employer if there's a valid one available. + if = { + limit = { + scope:outsider_diplomacy_martial = yes + root.cp:councillor_chancellor = { + is_ruler = yes + is_ai = yes + } + } + set_employer = root.cp:councillor_chancellor + } + else_if = { + limit = { + scope:outsider_martial_prowess = yes + root.cp:councillor_steward = { + is_ruler = yes + is_ai = yes + } + } + set_employer = root.cp:councillor_steward + } + else_if = { + limit = { + scope:outsider_stewardship_diplomacy = yes + root.cp:councillor_marshal = { + is_ruler = yes + is_ai = yes + } + } + set_employer = root.cp:councillor_marshal + } + else_if = { + limit = { + scope:outsider_intrigue_stewardship = yes + root.cp:councillor_spymaster = { + is_ruler = yes + is_ai = yes + } + } + set_employer = root.cp:councillor_spymaster + } + else_if = { + limit = { + scope:outsider_learning_intrigue = yes + root.cp:councillor_court_chaplain = { + is_ruler = yes + is_ai = yes + } + } + set_employer = root.cp:councillor_court_chaplain + } + } + } +} + +scripted_effect fp3_misc_decisions_0031_create_char_with_dynasty_effect = { + create_character = { + template = fp3_skilled_outsider_template + location = scope:batch_$BATCH$_county.title_province + culture = scope:batch_$BATCH$_county.culture + faith = scope:batch_$BATCH$_county.faith + after_creation = { + add_to_list = batch_$BATCH$_characters_list + # Set an employer if there's a valid one available. + if = { + limit = { + scope:outsider_diplomacy_martial = yes + root.cp:councillor_chancellor = { + is_ruler = yes + is_ai = yes + } + } + set_employer = root.cp:councillor_chancellor + } + else_if = { + limit = { + scope:outsider_martial_prowess = yes + root.cp:councillor_steward = { + is_ruler = yes + is_ai = yes + } + } + set_employer = root.cp:councillor_steward + } + else_if = { + limit = { + scope:outsider_stewardship_diplomacy = yes + root.cp:councillor_marshal = { + is_ruler = yes + is_ai = yes + } + } + set_employer = root.cp:councillor_marshal + } + else_if = { + limit = { + scope:outsider_intrigue_stewardship = yes + root.cp:councillor_spymaster = { + is_ruler = yes + is_ai = yes + } + } + set_employer = root.cp:councillor_spymaster + } + else_if = { + limit = { + scope:outsider_learning_intrigue = yes + root.cp:councillor_court_chaplain = { + is_ruler = yes + is_ai = yes + } + } + set_employer = root.cp:councillor_court_chaplain + } + } + } +} + +scripted_effect fp3_misc_decisions_0031_pick_best_appropriate_char_effect = { + ordered_in_list = { + list = batch_$BATCH$_characters_list + order_by = { + if = { + limit = { scope:outsider_diplomacy_martial = yes } + add = diplomacy + } + if = { + limit = { scope:outsider_martial_prowess = yes } + add = martial + } + if = { + limit = { scope:outsider_prowess_learning = yes } + add = prowess + } + if = { + limit = { scope:outsider_learning_intrigue = yes } + add = learning + } + if = { + limit = { scope:outsider_intrigue_stewardship = yes } + add = intrigue + } + if = { + limit = { scope:outsider_stewardship_diplomacy = yes } + add = stewardship + } + } + save_scope_as = batch_$BATCH$_char1 + } +} + +scripted_effect fp3_misc_decisions_0031_apply_opinion_to_batch_effect = { + every_in_list = { + list = batch_$BATCH$_characters_list + custom = fp3_misc_decisions.0031.tt.all_outsiders + add_opinion = { + target = root + modifier = grateful_opinion + opinion = 80 + } + # Since we're giving you a loyalty hook, we don't bother to take up option space with separate options for requesting their conversion - if you want it, you can always make 'em. + custom_tooltip = { + text = fp3_misc_decisions.0031.tt.all_outsiders.you_gain_hook + root = { + add_hook = { + type = loyalty_hook + target = prev + } + } + } + } +} + +# Recruit skilled outsiders from the lower ranks of your administration. +fp3_misc_decisions.0031 = { + type = character_event + title = favour_skilled_outsiders_decision + desc = { + desc = fp3_misc_decisions.0031.desc.intro + # How many cultures are we drawing from? + first_valid = { + # Are we taking all our guys from the same county? + triggered_desc = { + trigger = { scope:batch_a_county = scope:batch_b_county } + desc = fp3_misc_decisions.0031.desc.cultures.single + } + # Otherwise, use the multi-county loc. + desc = fp3_misc_decisions.0031.desc.cultures.fallback + } + } + theme = realm + left_portrait = { + character = scope:batch_a_char1 + animation = ecstasy + } + right_portrait = { + character = scope:batch_b_char1 + animation = personality_compassionate + } + lower_left_portrait = scope:batch_a_char2 + lower_center_portrait = scope:batch_a_char3 + lower_right_portrait = scope:batch_b_char2 + + immediate = { + # Finally, as we sorted ordered rankings out in the previous event, make sure that batch B is always higher quality. + hidden_effect = { + # Does scope:batch_b_char1 need elevating? + scope:batch_b_char1 = { + if = { + limit = { + scope:outsider_diplomacy_martial = yes + diplomacy < scope:batch_a_char1.fp3_skilled_outsider_minimum_main_skill_batch_b_char1_value + } + add_diplomacy_skill = { + value = scope:batch_a_char1.fp3_skilled_outsider_minimum_main_skill_batch_b_char1_value + subtract = diplomacy + } + } + if = { + limit = { + scope:outsider_martial_prowess = yes + martial < scope:batch_a_char1.fp3_skilled_outsider_minimum_main_skill_batch_b_char1_value + } + add_martial_skill = { + value = scope:batch_a_char1.fp3_skilled_outsider_minimum_main_skill_batch_b_char1_value + subtract = martial + } + } + if = { + limit = { + scope:outsider_prowess_learning = yes + prowess < scope:batch_a_char1.fp3_skilled_outsider_minimum_main_skill_batch_b_char1_value + } + add_prowess_skill = { + value = scope:batch_a_char1.fp3_skilled_outsider_minimum_main_skill_batch_b_char1_value + subtract = prowess + } + } + if = { + limit = { + scope:outsider_learning_intrigue = yes + learning < scope:batch_a_char1.fp3_skilled_outsider_minimum_main_skill_batch_b_char1_value + } + add_learning_skill = { + value = scope:batch_a_char1.fp3_skilled_outsider_minimum_main_skill_batch_b_char1_value + subtract = learning + } + } + if = { + limit = { + scope:outsider_intrigue_stewardship = yes + intrigue < scope:batch_a_char1.fp3_skilled_outsider_minimum_main_skill_batch_b_char1_value + } + add_intrigue_skill = { + value = scope:batch_a_char1.fp3_skilled_outsider_minimum_main_skill_batch_b_char1_value + subtract = intrigue + } + } + if = { + limit = { + scope:outsider_stewardship_diplomacy = yes + stewardship < scope:batch_a_char1.fp3_skilled_outsider_minimum_main_skill_batch_b_char1_value + } + add_stewardship_skill = { + value = scope:batch_a_char1.fp3_skilled_outsider_minimum_main_skill_batch_b_char1_value + subtract = stewardship + } + } + } + # Does scope:batch_b_char2 need a lil boost also? + scope:batch_b_char2 = { + if = { + limit = { + scope:outsider_diplomacy_martial = yes + diplomacy < scope:batch_a_char1.fp3_skilled_outsider_minimum_main_skill_batch_b_char2_value + } + add_diplomacy_skill = { + value = scope:batch_a_char1.fp3_skilled_outsider_minimum_main_skill_batch_b_char2_value + subtract = diplomacy + } + } + if = { + limit = { + scope:outsider_martial_prowess = yes + martial < scope:batch_a_char1.fp3_skilled_outsider_minimum_main_skill_batch_b_char2_value + } + add_martial_skill = { + value = scope:batch_a_char1.fp3_skilled_outsider_minimum_main_skill_batch_b_char2_value + subtract = martial + } + } + if = { + limit = { + scope:outsider_prowess_learning = yes + prowess < scope:batch_a_char1.fp3_skilled_outsider_minimum_main_skill_batch_b_char2_value + } + add_prowess_skill = { + value = scope:batch_a_char1.fp3_skilled_outsider_minimum_main_skill_batch_b_char2_value + subtract = prowess + } + } + if = { + limit = { + scope:outsider_learning_intrigue = yes + learning < scope:batch_a_char1.fp3_skilled_outsider_minimum_main_skill_batch_b_char2_value + } + add_learning_skill = { + value = scope:batch_a_char1.fp3_skilled_outsider_minimum_main_skill_batch_b_char2_value + subtract = learning + } + } + if = { + limit = { + scope:outsider_intrigue_stewardship = yes + intrigue < scope:batch_a_char1.fp3_skilled_outsider_minimum_main_skill_batch_b_char2_value + } + add_intrigue_skill = { + value = scope:batch_a_char1.fp3_skilled_outsider_minimum_main_skill_batch_b_char2_value + subtract = intrigue + } + } + if = { + limit = { + scope:outsider_stewardship_diplomacy = yes + stewardship < scope:batch_a_char1.fp3_skilled_outsider_minimum_main_skill_batch_b_char2_value + } + add_stewardship_skill = { + value = scope:batch_a_char1.fp3_skilled_outsider_minimum_main_skill_batch_b_char2_value + subtract = stewardship + } + } + } + # If we have a player, force a second skill recalc so that they can accurately see what they're getting. + if = { + limit = { + root = { is_ai = no } + } + scope:batch_b_char1 = { force_character_skill_recalculation = yes } + scope:batch_b_char2 = { force_character_skill_recalculation = yes } + } + } + } + + # Select batch A. + option = { + name = fp3_misc_decisions.0031.a + + # Gain the courtiers. + ## Added individually rather than through the same effect as opinion so you can easily see exactly who you get. + add_courtier = scope:batch_a_char1 + add_courtier = scope:batch_a_char2 + add_courtier = scope:batch_a_char3 + fp3_misc_decisions_0031_apply_opinion_to_batch_effect = { BATCH = a } + # Apply opinion maluses. + scope:batch_a_char1 = { save_scope_as = outsider_select } + favour_skilled_outsiders_decision_apply_opinions_effect = yes + + # No stress gain here. + ai_chance = { + base = 1 + # No AI value modifier - this is really just a pick you gut-feel as either a player or the AI. + # Though the AI is more likely to pick cultures you get on with better. + modifier = { + add = 75 + culture = { + cultural_acceptance = { + target = scope:batch_a_char1.culture + value >= 75 + } + } + } + modifier = { + add = 50 + culture = { + cultural_acceptance = { + target = scope:batch_a_char1.culture + value >= 50 + } + } + } + modifier = { + add = 25 + culture = { + cultural_acceptance = { + target = scope:batch_a_char1.culture + value >= 25 + } + } + } + } + } + + # Select batch B. + option = { + name = fp3_misc_decisions.0031.b + + # Gain the courtiers. + ## Added individually rather than through the same effect as opinion so you can easily see exactly who you get. + add_courtier = scope:batch_b_char1 + add_courtier = scope:batch_b_char2 + fp3_misc_decisions_0031_apply_opinion_to_batch_effect = { BATCH = b } + # Apply opinion maluses. + scope:batch_b_char1 = { save_scope_as = outsider_select } + favour_skilled_outsiders_decision_apply_opinions_effect = yes + + # No stress gain here. + ai_chance = { + base = 1 + # No AI value modifier - this is really just a pick you gut-feel as either a player or the AI. + # Though the AI is more likely to pick cultures you get on with better. + modifier = { + add = 75 + culture = { + cultural_acceptance = { + target = scope:batch_b_char1.culture + value >= 75 + } + } + } + modifier = { + add = 50 + culture = { + cultural_acceptance = { + target = scope:batch_b_char1.culture + value >= 50 + } + } + } + modifier = { + add = 25 + culture = { + cultural_acceptance = { + target = scope:batch_b_char1.culture + value >= 25 + } + } + } + } + } + + # Change your mind. + option = { + name = fp3_misc_decisions.0031.c + trigger = { is_ai = no } + + # RIP. + ## Job interviews suck. + custom_tooltip = fp3_misc_decisions.0031.c.tt + # Your prestige is refunded. + hidden_effect = { add_prestige_no_experience = scope:prestige_cost } + # We leave the decision on cooldown, though — otherwise you could just cycle through it repeatedly till you get the best conceivable recruits. + + # No stress gain here. + # No ai_chance; this is for the player to change their mind. If the AI gets this far, it should roll with it. + } + + after = { + # Remove the batch we didn't recruit. + hidden_effect = { + if = { + limit = { + NOT = { scope:batch_a_char1.liege ?= root } + } + every_in_list = { + list = batch_a_characters_list + silent_disappearance_effect = yes + } + } + if = { + limit = { + NOT = { scope:batch_b_char1.liege ?= root } + } + every_in_list = { + list = batch_b_characters_list + silent_disappearance_effect = yes + } + } + } + } +} + +# Laundering event to spawn the characters so that we can do some skill updating magic which'd otherwise error. +fp3_misc_decisions.0032 = { + hidden = yes + + immediate = { + # Alright, let's generate some characters! + ## First, we need to compile a list of valid cultures. + ### Sort our total possible candidates. + every_sub_realm_county = { + limit = { favour_skilled_outsiders_decision_valid_county_to_generate_trigger = yes } + # So we nab every valid county. + add_to_list = sub_realm_minority_cultures_county_pre_filter_list + # And every valid _culture_: we're gonna need to use these as a limit against the above list in a sec. + culture = { add_to_list = sub_realm_minority_cultures_tally_list } + } + ### Grab the tally of how many possible cultures we need for the final list. + #### This'll tell us how many times to iterate over the counties list total so that we end up with one county per valid culture instead of every county for every valid culture. + save_scope_value_as = { + name = while_count_value + value = { + every_in_list = { + list = sub_realm_minority_cultures_tally_list + add = 1 + } + } + } + ### Then we loop through and pick our finalists. + #### Hide the effect, because the while loop's tally will show even if nothing in it is visible to the player. + hidden_effect = { + while = { + count = scope:while_count_value + # First, nab a random culture we haven't used yet from the list of cultures to account for. + random_in_list = { + list = sub_realm_minority_cultures_tally_list + save_scope_as = current_culture + # We remove from the list so that we don't roll this culture again - effectively marking it as used. + remove_from_list = sub_realm_minority_cultures_tally_list + } + # Now, process through the complete list of counties to find the best possible fit that matches the valid culture. + ordered_in_list = { + list = sub_realm_minority_cultures_county_pre_filter_list + limit = { culture = scope:current_culture } + order_by = { + value = development_level + # Weight down for places that don't follow the same HoF. + if = { + limit = { + exists = root.faith.religious_head + faith.religious_head ?= root.faith.religious_head + } + add = { + value = development_level + multiply = -0.1 + } + } + # Weight down by root's hostility. + ## Righteous is perfect. + ## Astray, lose a little. + if = { + limit = { + root.faith = { + faith_hostility_level = { + target = prev.faith + value = faith_astray_level + } + } + } + add = { + value = development_level + multiply = -0.1 + } + } + ## Hostile, lose a little more. + if = { + limit = { + root.faith = { + faith_hostility_level = { + target = prev.faith + value = faith_hostile_level + } + } + } + add = { + value = development_level + multiply = -0.25 + } + } + ## Evil, lose a lottle more. + if = { + limit = { + root.faith = { + faith_hostility_level = { + target = prev.faith + value = faith_evil_level + } + } + } + add = { + value = development_level + multiply = -0.4 + } + } + } + add_to_list = sub_realm_minority_cultures_final_counties_list + } + } + } + ### For debug purposes: here so you can de-clog the tooltip if you need it to stop displaying _every_ valid county and just show you some selected appropriate scopes. + if = { + limit = { always = no } + every_in_list = { + list = sub_realm_minority_cultures_county_pre_filter_list + remove_from_list = sub_realm_minority_cultures_county_pre_filter_list + } + } + ## Sweet, now let's try to pick two from the list. + ### + if = { + limit = { + list_size = { + name = sub_realm_minority_cultures_final_counties_list + value >= 2 + } + } + # Try to grab a culture for batch A that matches our needs. + random_in_list = { + list = sub_realm_minority_cultures_final_counties_list + limit = { fp3_misc_decisions_0031_preferred_ethoses_trigger = yes } + alternative_limit = { always = yes } + weight = { fp3_misc_decisions_0031_preferred_cultrads_modifier = yes } + save_scope_as = batch_a_county + } + # And try to grab one for batch B that does the same whilst not being batch A. + random_in_list = { + list = sub_realm_minority_cultures_final_counties_list + limit = { + fp3_misc_decisions_0031_preferred_ethoses_trigger = yes + NOT = { this = scope:batch_a_county } + } + alternative_limit = { + NOT = { this = scope:batch_a_county } + } + weight = { fp3_misc_decisions_0031_preferred_cultrads_modifier = yes } + save_scope_as = batch_b_county + } + } + ### Otherwise, we've only got one item in the list, so just grab it twice. + else = { + random_in_list = { + list = sub_realm_minority_cultures_final_counties_list + save_scope_as = batch_a_county + } + scope:batch_a_county = { save_scope_as = batch_b_county } + } + ## Right, now let's generate batch A. + ### Slightly different parameters if we're using the fallback option. + if = { + limit = { scope:outsider_prowess_learning = yes } + fp3_misc_decisions_0031_create_char_with_dynasty_effect = { BATCH = a } + fp3_misc_decisions_0031_create_char_with_dynasty_effect = { BATCH = a } + fp3_misc_decisions_0031_create_char_with_dynasty_effect = { BATCH = a } + } + ### Otherwise, they're not nobles in any capacity, so remove their dynasties. + else = { + fp3_misc_decisions_0031_create_char_no_dynasty_effect = { BATCH = a } + fp3_misc_decisions_0031_create_char_no_dynasty_effect = { BATCH = a } + fp3_misc_decisions_0031_create_char_no_dynasty_effect = { BATCH = a } + } + ## Aaaaand batch B. + ### Slightly different parameters if we're using the fallback option. + if = { + limit = { scope:outsider_prowess_learning = yes } + fp3_misc_decisions_0031_create_char_with_dynasty_effect = { BATCH = b } + fp3_misc_decisions_0031_create_char_with_dynasty_effect = { BATCH = b } + } + ### Otherwise, they're not nobles in any capacity, so remove their dynasties. + else = { + fp3_misc_decisions_0031_create_char_no_dynasty_effect = { BATCH = b } + fp3_misc_decisions_0031_create_char_no_dynasty_effect = { BATCH = b } + } + ### Plus go over batch B & upgrade their education traits by +2. + every_in_list = { + list = batch_b_characters_list + hidden_effect = { + # Which education track are they on? + ## Diplomacy + if = { + limit = { has_trait = education_diplomacy_1 } + remove_trait = education_diplomacy_1 + add_trait = education_diplomacy_3 + # Force a skill recalc so that we can evaluate who's in the lead later. + ## Remember that only two of these'll ever be applied in total, so it's not too bad to be using them like this. + force_character_skill_recalculation = yes + } + else_if = { + limit = { has_trait = education_diplomacy_2 } + remove_trait = education_diplomacy_2 + add_trait = education_diplomacy_4 + # Force a skill recalc so that we can evaluate who's in the lead later. + ## Remember that only two of these'll ever be applied in total, so it's not too bad to be using them like this. + force_character_skill_recalculation = yes + } + ## Martial + if = { + limit = { has_trait = education_martial_1 } + remove_trait = education_martial_1 + add_trait = education_martial_3 + # Force a skill recalc so that we can evaluate who's in the lead later. + ## Remember that only two of these'll ever be applied in total, so it's not too bad to be using them like this. + force_character_skill_recalculation = yes + } + else_if = { + limit = { has_trait = education_martial_2 } + remove_trait = education_martial_2 + add_trait = education_martial_4 + # Force a skill recalc so that we can evaluate who's in the lead later. + ## Remember that only two of these'll ever be applied in total, so it's not too bad to be using them like this. + force_character_skill_recalculation = yes + } + ## Stewardship + if = { + limit = { has_trait = education_stewardship_1 } + remove_trait = education_stewardship_1 + add_trait = education_stewardship_3 + # Force a skill recalc so that we can evaluate who's in the lead later. + ## Remember that only two of these'll ever be applied in total, so it's not too bad to be using them like this. + force_character_skill_recalculation = yes + } + else_if = { + limit = { has_trait = education_stewardship_2 } + remove_trait = education_stewardship_2 + add_trait = education_stewardship_4 + # Force a skill recalc so that we can evaluate who's in the lead later. + ## Remember that only two of these'll ever be applied in total, so it's not too bad to be using them like this. + force_character_skill_recalculation = yes + } + ## Intrigue + if = { + limit = { has_trait = education_intrigue_1 } + remove_trait = education_intrigue_1 + add_trait = education_intrigue_3 + # Force a skill recalc so that we can evaluate who's in the lead later. + ## Remember that only two of these'll ever be applied in total, so it's not too bad to be using them like this. + force_character_skill_recalculation = yes + } + else_if = { + limit = { has_trait = education_intrigue_2 } + remove_trait = education_intrigue_2 + add_trait = education_intrigue_4 + # Force a skill recalc so that we can evaluate who's in the lead later. + ## Remember that only two of these'll ever be applied in total, so it's not too bad to be using them like this. + force_character_skill_recalculation = yes + } + ## Learning + if = { + limit = { has_trait = education_learning_1 } + remove_trait = education_learning_1 + add_trait = education_learning_3 + # Force a skill recalc so that we can evaluate who's in the lead later. + ## Remember that only two of these'll ever be applied in total, so it's not too bad to be using them like this. + force_character_skill_recalculation = yes + } + else_if = { + limit = { has_trait = education_learning_2 } + remove_trait = education_learning_2 + add_trait = education_learning_4 + # Force a skill recalc so that we can evaluate who's in the lead later. + ## Remember that only two of these'll ever be applied in total, so it's not too bad to be using them like this. + force_character_skill_recalculation = yes + } + } + } + ## Select our representatives. + fp3_misc_decisions_0031_pick_best_appropriate_char_effect = { BATCH = a } + fp3_misc_decisions_0031_pick_best_appropriate_char_effect = { BATCH = b } + ## And fill out our fodder. + random_in_list ={ + list = batch_a_characters_list + limit = { + NOT = { this = scope:batch_a_char1 } + } + save_scope_as = batch_a_char2 + # Plus we make the characters within each group get on, as they're sorta local allies. + hidden_effect = { set_relation_friend = scope:batch_a_char1 } + } + random_in_list = { + list = batch_a_characters_list + limit = { + NOR = { + this = scope:batch_a_char1 + this = scope:batch_a_char2 + } + } + save_scope_as = batch_a_char3 + # Plus we make the characters within each group get on, as they're sorta local allies. + hidden_effect = { + set_relation_friend = scope:batch_a_char1 + set_relation_friend = scope:batch_a_char2 + } + } + random_in_list = { + list = batch_b_characters_list + limit = { + NOT = { this = scope:batch_b_char1 } + } + save_scope_as = batch_b_char2 + # Plus we make the characters within each group get on, as they're sorta local allies. + hidden_effect = { set_relation_best_friend = scope:batch_b_char1 } + } + # Now fire the actual event! + trigger_event = fp3_misc_decisions.0031 + } +} + +################################################## +# Adopt Clan Government +# by Joe Parkin +# 0051-0060 +################################################## + +fp3_misc_decisions.0051 = { # Adopt Clan Government through House + type = character_event + title = fp3_misc_decisions.0051.t + desc = fp3_misc_decisions.0051.desc + theme = dynasty + left_portrait = { + character = root + animation = personality_rational + } + lower_right_portrait = house.house_head + + immediate = { + change_government = clan_government + # Increase unity, uses this effect since both chars are not clan when script is evaluated + house.house_head = { + apply_clan_unity_interaction_effect = { + CHARACTER = root + TARGET = root.house.house_head + DESC = clan_unity_adopt_clan.desc + VALUE = medium_unity_gain + VALUE_REVERSED = no + } + } + hidden_effect = { + house.house_head = { + send_interface_toast = { + title = fp3_become_clan_government_decision_toast + left_icon = root + right_icon = house.house_head + show_as_tooltip = { + root = { + # Change government type + change_government = clan_government + # Increase unity, uses this effect since both chars are not clan when script is evaluated + house.house_head = { + apply_clan_unity_interaction_effect = { + CHARACTER = root + TARGET = root.house.house_head + DESC = clan_unity_adopt_clan.desc + VALUE = medium_unity_gain + VALUE_REVERSED = no + } + } + } + } + } + } + } + } + + option = { + name = fp3_misc_decisions.0051.a + } +} diff --git a/events/dlc/fp3/fp3_religious_decision_events.txt b/events/dlc/fp3/fp3_religious_decision_events.txt new file mode 100644 index 0000000000..dd7e3cac6b --- /dev/null +++ b/events/dlc/fp3/fp3_religious_decision_events.txt @@ -0,0 +1 @@ +# Warcraft \ No newline at end of file diff --git a/events/dlc/fp3/fp3_scholarship_events.txt b/events/dlc/fp3/fp3_scholarship_events.txt new file mode 100644 index 0000000000..e50889789b --- /dev/null +++ b/events/dlc/fp3/fp3_scholarship_events.txt @@ -0,0 +1,1658 @@ +namespace = fp3_scholarship + +# ========================= Persian Scholarship Events ========================= +# = Events that relate to sponsoring scholars and innovation in your realm = +# ============================================================================== +# = +# 0000 – 0999: Hidden decision events = +# 1000 – 1999: Scholarship events that don't need a court scholar to trigger = +# 2000 – 2999: Events that fire when you employ a court scholar = +# 8000 – 8999: Research Project events = +# 9000 – 9999: Research Project conclusion events = +# = +# ============================================================================== + +# Sponsor Persian Scholars +fp3_scholarship.0001 = { + hidden = yes + + trigger = { + exists = var:number_of_invite_scholars_countdown + } + + immediate = { + #Set up a list of provinces, one per duchy in the realm, find all relevant pool characters there + every_realm_province = { + if = { + limit = { + save_temporary_scope_as = potential_province + NOT = { + any_in_list = { + list = pool_provinces + county.duchy = scope:potential_province.county.duchy + } + } + } + add_to_temporary_list = pool_provinces + } + } + + every_in_list = { + list = pool_provinces + save_temporary_scope_as = pool_province + + every_pool_character = { + province = scope:pool_province + limit = { + learning >= 10 + has_trait = education_learning + NOT = { has_trait = intellect_bad } + } + add_to_temporary_list = potential_scholars + } + } + + #Prioritize good scholars + random_in_list = { + list = potential_scholars + limit = { is_alive = yes } + weight = { + base = 1 + modifier = { + add = { + value = learning + subtract = 12 + multiply = 5 + } + } + } + save_scope_as = scholar + } + + #If no one was found, make a new scholar + if = { + limit = { NOT = { exists = scope:scholar } } + + # Can be either anywhere from a great to mediocre scholar + + create_character = { + location = root.capital_province + age = { 20 70 } + gender_female_chance = { + if = { + limit = { + faith = { has_doctrine = doctrine_gender_male_dominated } + } + add = 0 + } + else_if = { + limit = { + faith = { has_doctrine = doctrine_gender_female_dominated } + } + add = 100 + } + else = { + add = 50 + } + } + culture = root.culture + faith = root.faith + + random_traits = yes + diplomacy = { 2 10 } + martial = { 0 8 } + stewardship = { 2 10 } + intrigue = { 2 10 } + learning = { 10 18 } + prowess = { 0 8 } + + random_traits_list = { + count = { 0 2 } + scholar = {} + theologian = {} + lifestyle_physician = {} + } + + dynasty = none + + after_creation = { + remove_any_education_traits_effect = yes + random_list = { + 10 = { add_trait = education_learning_1 } + 35 = { add_trait = education_learning_2 } + 35 = { add_trait = education_learning_3 } + 20 = { add_trait = education_learning_4 } + } + random = { + chance = 10 + add_trait = shrewd + } + random_list = { + 85 = {} + 20 = { + trigger = { + NOR = { + has_trait = intellect_good_1 + has_trait = intellect_good_2 + has_trait = intellect_good_3 + } + } + add_trait = intellect_good_1 + } + 10 = { + trigger = { + NOR = { + has_trait = intellect_good_1 + has_trait = intellect_good_2 + has_trait = intellect_good_3 + } + } + add_trait = intellect_good_2 + } + } + add_random_tiered_trait_xp_effect = { + TRAIT = lifestyle_physician + LEVEL_1 = yes + LEVEL_3 = yes + } + random = { + chance = 2 + add_trait = depressed_1 + } + random = { + chance = 2 + add_trait = reclusive + } + random = { + chance = 2 + add_trait = journaller + } + } + + save_scope_as = scholar + } + } + + #Add scholar to court + add_visiting_courtier = scope:scholar + send_interface_message = { + title = fp3_scholarship.0001.t + desc = fp3_scholarship.0001.desc + type = event_learning_good_with_text + left_icon = scope:scholar + } + + + #Count down the number of extra scholars and either end the chain or resend this event + change_variable = { + name = number_of_invite_scholars_countdown + subtract = 1 + } + + if = { + limit = { var:number_of_invite_scholars_countdown = 0 } + remove_variable = number_of_invite_scholars_countdown + } + else = { + clear_saved_scope = scholar + trigger_event = { + id = fp3_scholarship.0001 + days = { 100 200 } + } + } + } +} + +########################################## +# 1000 - 1999: No Court Scholar Required # +########################################## + +# A Second Aryabhata +# Ask a neighboring Indo-Aryan ruler to send you some scholars + +scripted_trigger fp3_scholarship_1000_neighboring_ruler_is_valid = { + NOT = { this = root } + is_ai = yes + culture = { + OR = { + has_cultural_pillar = heritage_indo_aryan + has_cultural_pillar = heritage_dravidian + } + NOT = { has_cultural_pillar = ethos_bellicose } + } +} + +# A Second Aryabhata +# Contemplate asking a neighboring Indo-Aryan ruler for some mathematician courtiers +fp3_scholarship.1000 = { + type = character_event + title = fp3_scholarship.1000.t + desc = fp3_scholarship.1000.desc + theme = education + left_portrait = { + character = root + animation = personality_rational + } + lower_left_portrait = scope:nearby_indian_ruler + + cooldown = { years = 10 } + + trigger = { + has_fp3_dlc_trigger = yes + NOT = { employs_court_position = court_scholar_court_position } + can_employ_court_position_type = court_scholar_court_position + any_neighboring_top_liege_realm_owner = { + fp3_scholarship_1000_neighboring_ruler_is_valid = yes + } + } + + # Find an appropriate neighboring Indian ruler + immediate = { + save_scope_as = actor # Required for gift_value + random_neighboring_top_liege_realm_owner = { + limit = { + fp3_scholarship_1000_neighboring_ruler_is_valid = yes + } + save_scope_as = nearby_indian_ruler + save_scope_as = recipient # Required for gift_value + save_scope_value_as = { + name = bribe_value + value = { + value = gift_value + divide = 2 + } + } + } + } + + option = { # Ask nicely + name = fp3_scholarship.1000.a + duel = { + skill = diplomacy + target = scope:nearby_indian_ruler + 50 = { + desc = fp3_scholarship.1000.duel_success + min = 15 + compare_modifier = { + value = scope:duel_value + multiplier = 3.5 + min = -49 + } + opinion_modifier = { + who = scope:nearby_indian_ruler + opinion_target = root + multiplier = 1.5 + min = -49 + } + send_interface_toast = { + title = fp3_scholarship.1000.duel_success + left_icon = scope:nearby_indian_ruler + custom_tooltip = fp3_scholarship.1000.duel_success_tt + } + trigger_event = { + id = fp3_scholarship.1001 + days = { 7 14 } + } + hidden_effect = { + add_opinion = { + target = scope:nearby_indian_ruler + modifier = grateful_opinion + opinion = 20 + } + } + } + 50 = { + desc = fp3_scholarship.1000.duel_failure + min = 15 + compare_modifier = { + value = scope:duel_value + multiplier = -3.5 + min = -49 + } + opinion_modifier = { + who = scope:nearby_indian_ruler + opinion_target = root + multiplier = -1.5 + min = -49 + } + send_interface_toast = { + title = fp3_scholarship.1000.duel_failure + left_icon = scope:nearby_indian_ruler + reverse_add_opinion = { + target = scope:nearby_indian_ruler + modifier = fp3_disrespected_me_opinion + } + } + hidden_effect = { + add_opinion = { + target = scope:nearby_indian_ruler + modifier = disappointed_opinion + opinion = -10 + } + } + } + } + stress_impact = { + paranoid = medium_stress_impact_gain + arrogant = minor_stress_impact_gain + scholar = minor_stress_impact_loss + } + ai_chance = { + base = 10 #We don't want too many Indian mathematicians in Persia from this event + modifier = { + factor = 5 + has_trait = scholar + } + } + } + + option = { # Offer some gold + name = fp3_scholarship.1000.b + stress_impact = { + greedy = medium_stress_impact_gain + arrogant = minor_stress_impact_gain + paranoid = medium_stress_impact_gain + } + remove_short_term_gold = scope:bribe_value + custom_tooltip = fp3_scholarship.1000.duel_success_tt + reverse_add_opinion = { + target = scope:nearby_indian_ruler + modifier = grateful_opinion + opinion = 20 + } + trigger_event = { + id = fp3_scholarship.1001 + days = { 7 14 } + } + stress_impact = { + greedy = medium_stress_impact_gain + arrogant = minor_stress_impact_gain + scholar = minor_stress_impact_loss + } + ai_chance = { + base = 10 + modifier = { + factor = 0 + has_trait = greedy + } + } + } + + option = { # Focus on improving local mathematics + name = fp3_scholarship.1000.c + remove_short_term_gold = medium_gold_value + custom_tooltip = fp3_scholarship.1000.native_tt + add_character_modifier = { + modifier = fp3_promoted_persian_mathematics_modifier + years = 10 + } + hidden_effect = { + create_character = { + location = root.capital_province + template = scholar_character + save_scope_as = mathematician + } + add_courtier = scope:mathematician + send_interface_message = { + title = fp3_scholarship.1001.t + desc = fp3_scholarship.1001.native.desc + type = event_learning_good_with_text + left_icon = scope:mathematician + } + } + stress_impact = { + greedy = medium_stress_impact_gain + arrogant = minor_stress_impact_gain + scholar = minor_stress_impact_loss + } + ai_chance = { + base = 10 + modifier = { + factor = 0 + has_trait = greedy + } + } + } + option = { # Complete Opt Out + name = fp3_scholarship.1000.d + stress_impact = { + scholar = minor_stress_impact_gain + } + ai_chance = { + base = 100 + } + } +} + +scripted_effect fp3_scholarship_1001_create_indian_mathematician_effect = { + create_character = { + location = root.capital_province + age = { 20 70 } + gender_female_chance = { + if = { + limit = { + scope:nearby_indian_ruler.faith = { has_doctrine = doctrine_gender_male_dominated } + } + add = 0 + } + else_if = { + limit = { + scope:nearby_indian_ruler.faith = { has_doctrine = doctrine_gender_female_dominated } + } + add = 100 + } + else = { + add = 50 + } + } + culture = scope:nearby_indian_ruler.culture + faith = scope:nearby_indian_ruler.faith + + random_traits_list = { + count = 3 + chaste = {} + content = {} + ambitious = {} + diligent = {} + stubborn = {} + forgiving = {} + shy = {} + just = {} + patient = {} + cynical = {} + craven = {} + } + random_traits = no + diplomacy = { 2 10 } + martial = { 0 8 } + stewardship = { 2 10 } + intrigue = { 0 8 } + learning = { 8 14 } + prowess = { 0 8 } + + dynasty = none + + after_creation = { + remove_any_education_traits_effect = yes + random_list = { + 10 = { add_trait = education_learning_2 } + 30 = { add_trait = education_learning_3 } + 10 = { add_trait = education_learning_4 } + } + random = { + chance = 25 + add_trait = scholar + } + random = { + chance = 10 + add_trait = shrewd + } + random_list = { + 85 = {} + 20 = { + trigger = { + NOR = { + has_trait = intellect_good_1 + has_trait = intellect_good_2 + has_trait = intellect_good_3 + } + } + add_trait = intellect_good_1 + } + 10 = { + trigger = { + NOR = { + has_trait = intellect_good_1 + has_trait = intellect_good_2 + has_trait = intellect_good_3 + } + } + add_trait = intellect_good_2 + } + } + random = { + chance = 2 + add_trait = depressed_1 + } + random = { + chance = 2 + add_trait = reclusive + } + random = { + chance = 5 + add_trait = hashishiyah + } + random = { + chance = 2 + add_trait = journaller + } + } + + save_temporary_scope_as = mathematician + } + add_courtier = scope:mathematician + send_interface_message = { + title = fp3_scholarship.1001.t + desc = fp3_scholarship.1001.desc + type = event_learning_good_with_text + left_icon = scope:mathematician + } +} + +# 1-2 mathematician Indo-Aryan courtiers arrive +fp3_scholarship.1001 = { + hidden = yes + + trigger = { + exists = scope:nearby_indian_ruler # Sanity check + } + + immediate = { + fp3_scholarship_1001_create_indian_mathematician_effect = yes + fp3_scholarship_1001_create_indian_mathematician_effect = yes + } +} + +#scripted_trigger fp3_scholarship_1010_is_valid_magus_county + +# The Lone Magus +# You encounter an extant fire temple. Do you ignore it, destroy it, or recruit the Magus? +#Travel Event +#fp3_scholarship.1010 + +######################################## +# 2000 - 2999: Court Scholar Required # +######################################## + +# Worth Its Weight +# Requisition paper for your court scholar? +fp3_scholarship.2000 = { + type = character_event + title = fp3_scholarship.2000.t + desc = fp3_scholarship.2000.desc + theme = education + left_portrait = { + character = scope:court_scholar + animation = reading + } + + cooldown = { years = 5 } + + trigger = { + # Don't give the court scholar multiple paper surpluses + any_court_position_holder = { + type = court_scholar_court_position + NOT = { has_character_modifier = fp3_paper_surplus_modifier } + } + # Paper should be abundant by the late medieval era + culture = { NOT = { has_cultural_era_or_later = culture_era_late_medieval } } + } + + immediate = { + random_court_position_holder = { + type = court_scholar_court_position + save_scope_as = court_scholar + } + } + + option = { # Requisition the paper + name = fp3_scholarship.2000.a + capital_county = { + change_county_control = -25 + } + scope:court_scholar = { + add_character_modifier = { + modifier = fp3_paper_surplus_modifier + years = 10 + } + add_opinion = { + target = root + modifier = grateful_opinion + opinion = 10 + } + } + stress_impact = { + just = minor_stress_impact_gain + compassionate = medium_stress_impact_gain + generous = medium_stress_impact_gain + } + ai_chance = { + base = 0 + } + } + + option = { # Import the Paper + name = fp3_scholarship.2000.b + remove_short_term_gold = medium_gold_value + scope:court_scholar = { + add_character_modifier = { + modifier = fp3_paper_surplus_modifier + } + add_opinion = { + target = root + modifier = grateful_opinion + opinion = 15 + } + } + stress_impact = { + greedy = medium_stress_impact_gain + } + ai_chance = { + base = 50 + ai_value_modifier = { + ai_greed = -1 + } + } + } + + option = { # We cannot afford it + name = fp3_scholarship.2000.c + scope:court_scholar = { + add_character_modifier = { + modifier = fp3_paper_shortage_modifier + years = 10 + } + add_opinion = { + target = root + modifier = disappointed_opinion + opinion = -15 + } + } + stress_impact = { + diligent = minor_stress_impact_gain + ambitious = minor_stress_impact_gain + } + ai_chance = { + base = 50 + ai_value_modifier = { + ai_energy = -0.5 + } + } + } +} + +# Liquid Wisdom +# Your court scholar is drinking with a foreign scholar, do you stop them in the name of piety? +fp3_scholarship.2010 = { + type = character_event + title = fp3_scholarship.2010.t + desc = fp3_scholarship.2010.desc + theme = education + override_background = { + reference = tavern + } + left_portrait = { + character = scope:court_scholar + animation = thinking + } + right_portrait = { + character = scope:foreign_scholar + animation = toast + } + + cooldown = { years = 10 } + + trigger = { + faith = { trait_is_sin = drunkard } + any_court_position_holder = { + type = court_scholar_court_position + NOT = { has_trait = zealous } + } + } + + immediate = { + random_court_position_holder = { + type = court_scholar_court_position + save_scope_as = court_scholar + } + # Find a random faraway county to pull a character from + random_county_in_region = { + region = world_india + limit = { + faith = { + NOT = { trait_is_sin = drunkard } + } + } + save_scope_as = foreign_county + } + create_character = { + age = { 35 50 } + random_traits_list = { + count = 1 + education_learning_2 = {} + education_learning_3 = {} + education_learning_4 = {} + } + random_traits = yes + location = root.capital_province + faith = scope:foreign_county.faith + culture = scope:foreign_county.culture + gender_female_chance = root_faith_dominant_gender_adjusted_female_chance + learning = { + min_template_high_skill + max_template_high_skill + } + save_scope_as = foreign_scholar + } + } + + option = { # Stop court scholar + name = fp3_scholarship.2010.a + add_piety = minor_piety_gain + reverse_add_opinion = { + target = scope:court_scholar + modifier = fp3_killjoy_opinion + opinion = -15 + } + ai_chance = { + base = 50 + ai_value_modifier = { + ai_zeal = 1 + } + } + } + + option = { # Let them continue drinking + name = fp3_scholarship.2010.b + add_piety = minor_piety_loss + random = { + chance = 50 + scope:court_scholar = { + add_learning_skill = 1 + } + } + scope:court_scholar = { + add_character_modifier = { + modifier = fp3_liquid_wisdom_modifier + years = 5 + } + } + stress_impact = { + zealous = medium_stress_impact_gain + } + ai_chance = { + base = 50 + ai_value_modifier = { + ai_zeal = -1 + } + } + } + + after = { + scope:foreign_scholar = { silent_disappearance_effect = yes } + } +} + +# Morbid Insights +# Give a prisoner to your court scholar to experiment on? +fp3_scholarship.2020 = { + type = character_event + title = fp3_scholarship.2020.t + desc = fp3_scholarship.2020.desc + theme = prison + left_portrait = { + character = scope:court_scholar + animation = thinking + } + right_portrait = { + character = scope:specimen + animation = fear + } + + cooldown = { years = 10 } + + trigger = { + any_prisoner = { + is_adult = yes + } + any_court_position_holder = { + type = court_scholar_court_position + ai_compassion < very_high_positive_ai_value # A compassionate person would not endanger another's life + } + } + + immediate = { + random_court_position_holder = { + type = court_scholar_court_position + save_scope_as = court_scholar + assign_quirk_effect = yes + } + random_prisoner = { + limit = { is_adult = yes } + # Try to pull an important person; this event is more interesting if the prisoner isn't Guy McNobody + weight = { + base = 1 + modifier = { + exists = dynasty + add = dynasty.dynasty_prestige_level + } + } + save_scope_as = specimen + } + } + + option = { # Allow the experimentation + name = fp3_scholarship.2020.a + random_list = { # 40% chance of prisoner death + 3 = { add_learning_skill = 2 } + 2 = { + scope:specimen = { + override_death_killer_effect = { + death_reason = death_treatment + killer = scope:court_scholar + } + } + } + } + scope:court_scholar = { + add_character_modifier = { + modifier = fp3_morbid_insights_modifier + years = 20 + } + } + stress_impact = { + compassionate = major_stress_impact_gain + sadistic = minor_stress_impact_loss + } + ai_chance = { + base = 50 + ai_value_modifier = { + ai_compassion = -1 + } + modifier = { + NOT = { has_execute_reason = scope:specimen } + ai_honor >= high_positive_ai_value + add = -50 + } + } + } + + option = { # Forbid experimentation + name = fp3_scholarship.2020.b + reverse_add_opinion = { + target = scope:court_scholar + modifier = disappointed_opinion + opinion = -15 + } + ai_chance = { + base = 50 + ai_value_modifier = { + ai_compassion = 1 + } + } + } +} + +#Treatice Published (Your Scholar is levelling up) +#By Henrik Lohmander +fp3_scholarship.2030 = { + type = character_event + title = fp3_scholarship.2030.t + desc = fp3_scholarship.2030.desc + theme = education + left_portrait = { + character = scope:court_scholar + animation = reading + } + override_background = { + reference = bp2_study_indian + } + + cooldown = { years = 10 } #This will keep happening with regular intervals once the cooldown is over, if you keep a scholar on for long enough they will be increasingly learned + + trigger = { + any_court_position_holder = { + type = court_scholar_court_position + is_available_healthy_adult = yes + } + } + + weight_multiplier = { + base = 1 + modifier = { + add = 1 + any_realm_province = { + is_higher_studies_location = yes + } + } + } + + immediate = { + random_court_position_holder = { + type = court_scholar_court_position + save_scope_as = court_scholar + } + random_list = { + 33 = { + trigger = { + scope:court_scholar = { + NOT = { has_trait = scholar } + learning > 15 + } + } + save_scope_value_as = { + name = personal_development_time + value = flag:scholar_trait + } + } + 33 = { + trigger = { + scope:court_scholar = { + NOT = { has_trait = theologian } + learning > 20 + } + } + save_scope_value_as = { + name = personal_development_time + value = flag:theologian_trait + } + } + 33 = { + save_scope_value_as = { + name = personal_development_time + value = flag:learning + } + } + 33 = { + trigger = { + any_realm_province = { + is_higher_studies_location = yes + } + scope:court_scholar = { + has_education_learning_trigger = yes + NOT = { has_trait = education_learning_5 } + } + } + save_scope_value_as = { + name = personal_development_time + value = flag:learning_education + } + } + } + } + + option = { + name = fp3_scholarship.2030.a + switch = { + trigger = scope:personal_development_time + flag:learning = { + scope:court_scholar = { + add_learning_skill = 2 + } + } + flag:theologian_trait = { + scope:court_scholar = { + add_trait = theologian + } + } + flag:scholar_trait = { + scope:court_scholar = { + add_trait = scholar + } + } + flag:learning_education = { + custom_tooltip = fp3_scholarship.2030.tt + scope:court_scholar = { + switch = { + trigger = has_trait + education_learning_1 = { + remove_trait = education_learning_1 + add_trait_force_tooltip = education_learning_2 + } + education_learning_2 = { + remove_trait = education_learning_2 + add_trait_force_tooltip = education_learning_3 + } + education_learning_3 = { + remove_trait = education_learning_3 + add_trait_force_tooltip = education_learning_4 + } + education_learning_4 = { + remove_trait = education_learning_4 + add_trait_force_tooltip = education_learning_5 + } + } + } + } + } + } +} + +################################## +# 8000 - 8999: Innovation Events # +################################## + +# Determines whether the research project was a success or failure, given $SUCCESS_CHANCE$ +scripted_effect fp3_research_completion_effect = { + # For loc + if = { + limit = { NOT = { exists = scope:court_scholar } } + random_court_position_holder = { + type = court_scholar_court_position + save_scope_as = court_scholar + } + } + random_list = { + 65 = { # Failure + modifier = { + add = { + value = 0 + subtract = $SUCCESS_CHANCE$ + } + } + custom_tooltip = fp3_scholarship.8999.tt_failure + trigger_event = fp3_scholarship.9000 + } + 34 = { # Regular Success + modifier = { + add = { + value = $SUCCESS_CHANCE$ + multiply = 0.75 + } + } + custom_tooltip = fp3_scholarship.8999.tt_success + trigger_event = fp3_scholarship.9100 + } + 1 = { # Critical Success: Unlock Innovation + trigger = { + trigger_if = { + limit = { + NOT = { culture = { has_innovation = fp3_innovation_mural_sextant } } + } + culture = { has_cultural_era_or_later = culture_era_early_medieval } + } + trigger_if = { + limit = { + NOT = { culture = { has_innovation = fp3_innovation_fritware } } + } + culture = { has_cultural_era_or_later = culture_era_late_medieval } + } + } + modifier = { + add = { + value = $SUCCESS_CHANCE$ + multiply = 0.25 + } + } + custom_tooltip = fp3_scholarship.8999.tt_crit_success + trigger_event = fp3_scholarship.9200 + } + } +} + +scripted_effect add_research_cooldown_effect = { + add_character_flag = { + flag = fund_research_inspiration_event_cooldown + days = { 30 60 } + } +} + +scripted_trigger has_no_research_event_cooldown = { + NOT = { has_character_flag = fund_research_inspiration_event_cooldown } +} + +# Scholar announces initial plans to begin a research project +fp3_scholarship.8000 = { + type = character_event + title = fp3_scholarship.8000.t + desc = fp3_scholarship.8000.desc + left_portrait = { + character = root + animation = thinking + } + right_portrait = { + character = scope:court_scholar + animation = reading + } + theme = education + override_background = { + reference = bp2_university + } + + cooldown = { + years = 5 + } + + immediate = { + random_court_position_holder = { + type = court_scholar_court_position + limit = { + exists = inspiration + is_available_healthy_adult = yes + } + save_scope_as = court_scholar + } + } + + option = { + name = fp3_scholarship.8000.a + } +} + +# Scholar wants to begin an alchemy inspiration +fp3_scholarship.8500 = { + type = character_event + title = fp3_scholarship.8500.t + desc = fp3_scholarship.8500.desc + left_portrait = { + character = root + animation = thinking + } + right_portrait = { + character = scope:court_scholar + animation = reading + } + theme = education + override_background = { + reference = bp2_university + } + + cooldown = { + years = 5 + } + + immediate = { + random_court_position_holder = { + type = court_scholar_court_position + limit = { + NOT = { exists = inspiration } + is_available_healthy_adult = yes + } + save_scope_as = court_scholar + } + scope:court_scholar = { + save_scope_as = recipient + } + save_scope_as = actor + } + + trigger = { + has_fp3_dlc_trigger = yes + has_royal_court = yes #Yes, for this you need both fp3 and Royal Court + any_court_position_holder = { + type = court_scholar_court_position + NOT = { exists = inspiration } + is_available_healthy_adult = yes + has_completed_inspiration = no + learning > 20 + } + } + + option = { + name = fp3_scholarship.8000.a + remove_short_term_gold = fp3_research_base_cost + custom_tooltip = fp3_scholarship.8500.a.tt + hidden_effect = { + scope:court_scholar = { + create_inspiration = alchemy_inspiration + fund_inspiration_effect = yes + } + } + } + + option = { + name = fp3_scholarship.8000.b + add_prestige = minor_prestige_loss + reverse_add_opinion = { + target = scope:court_scholar + modifier = disappointed_opinion + opinion = -10 + } + } +} + +# Scholar wants to begin a book inspiration +fp3_scholarship.8600 = { + type = character_event + title = fp3_scholarship.8600.t + desc = fp3_scholarship.8600.desc + left_portrait = { + character = root + animation = thinking + } + right_portrait = { + character = scope:court_scholar + animation = throne_room_writer + } + theme = education + override_background = { + reference = study + } + + trigger = { + has_fp3_dlc_trigger = yes + has_royal_court = yes #Yes, for this you need both fp3 and Royal Court + any_court_position_holder = { + type = court_scholar_court_position + NOT = { exists = inspiration } + has_completed_inspiration = no + is_available_healthy_adult = yes + learning > 20 + } + } + + cooldown = { + years = 5 + } + + immediate = { + random_court_position_holder = { + type = court_scholar_court_position + limit = { + NOT = { exists = inspiration } + is_available_healthy_adult = yes + } + save_scope_as = court_scholar + } + scope:court_scholar = { + save_scope_as = recipient + } + save_scope_as = actor + } + + option = { + name = fp3_scholarship.8000.a + show_as_tooltip = { remove_short_term_gold = medium_gold_value } # gold is removed by sponsor_inspiration effect (inside fund_inspiration_effect) + custom_tooltip = fp3_scholarship.8600.a.tt + hidden_effect = { + scope:court_scholar = { + create_inspiration = { + type = book_inspiration + gold = root.medium_gold_value + } + fund_inspiration_effect = yes + } + } + } + + option = { + name = fp3_scholarship.8000.b + add_prestige = minor_prestige_loss + reverse_add_opinion = { + target = scope:court_scholar + modifier = disappointed_opinion + opinion = -10 + } + } +} + +# Scholar asks for more texts +fp3_scholarship.8100 = { + type = character_event + title = fp3_scholarship.8100.t + desc = fp3_scholarship.8100.desc + theme = education + left_portrait = scope:inspiration_owner + + cooldown = { years = 2 } + + trigger = { + exists = scope:inspiration + scope:inspiration_owner = { + is_available_ai_adult = yes + has_no_research_event_cooldown = yes + } + } + + weight_multiplier = { + base = 1 + modifier = { + add = 0.5 + scope:inspiration_owner = { + ai_energy >= medium_positive_ai_value + } + } + } + + immediate = { + scope:inspiration_owner = { + add_research_cooldown_effect = yes + } + } + + option = { # Furnish the library + name = fp3_scholarship.8100.a + if = { + limit = { exists = scope:inspiration } + scope:inspiration = { + invest_gold = 50 + } + } + scope:inspiration_owner = { + change_artifact_quality_effect = { AMOUNT = 6 } + } + stress_impact = { + arrogant = medium_stress_impact_gain + greedy = medium_stress_impact_gain + } + ai_chance = { + base = 50 + modifier = { + add = -50 + short_term_gold < 50 + } + } + } + + option = { # The library is fine as-is + name = fp3_scholarship.8100.b + scope:inspiration_owner = { + change_artifact_quality_effect = { AMOUNT = -2 } + add_opinion = { + target = root + modifier = refusal_opinion + opinion = -10 + } + } + stress_impact = { + arrogant = minor_stress_impact_loss + } + ai_chance = { + base = 25 + ai_value_modifier = { + ai_greed = 0.75 + } + } + } +} + +# Roll for project outcome +fp3_scholarship.8999 = { + hidden = yes + + # Roll for success + immediate = { + if = { + limit = { exists = scope:inspiration_owner } + scope:inspiration_owner = { + if = { + limit = { has_variable = research_success_chance } + scope:inspiration_sponsor = { + fp3_research_completion_effect = { SUCCESS_CHANCE = prev.var:research_success_chance } + } + } + } + } + } + } + +# Research project was a failure +fp3_scholarship.9000 = { + type = character_event + title = fp3_scholarship.9000.t + desc = fp3_scholarship.9000.desc + theme = education + left_portrait = { + character = scope:inspiration_owner + animation = worry + } + + immediate = { + scope:inspiration_owner = { + add_character_flag = { + flag = research_invalidated + days = 1 + } + } + } + + option = { # These things happen + name = fp3_scholarship.9000.a + add_prestige = minor_prestige_loss + } +} + +# Research project minor success +scripted_effect fp3_scholarship_9100_reward_effect = { + house = { + add_house_modifier = { + modifier = $MODIFIER$ + years = 30 + } + } +} + +fp3_scholarship.9100 = { + type = character_event + title = fp3_scholarship.9100.t + desc = fp3_scholarship.9100.desc + theme = education + left_portrait = { + character = scope:inspiration_owner + animation = personality_honorable + } + + immediate = { + hidden_effect = { + random_list = { + 30 = { + trigger = { + scope:inspiration_owner = { has_character_flag = civil_research } + house = { + NOT = { has_house_modifier = fp3_treatise_on_development_modifier } + } + } + save_scope_value_as = { + name = researched_house_modifier + value = flag:fp3_treatise_on_development_modifier + } + } + 30 = { + trigger = { + scope:inspiration_owner = { has_character_flag = civil_research } + house = { + NOT = { has_house_modifier = fp3_treatise_on_building_modifier } + } + } + save_scope_value_as = { + name = researched_house_modifier + value = flag:fp3_treatise_on_building_modifier + } + } + 30 = { + trigger = { + scope:inspiration_owner = { has_character_flag = civil_research } + house = { + NOT = { has_house_modifier = fp3_treatise_on_control_modifier } + } + } + save_scope_value_as = { + name = researched_house_modifier + value = flag:fp3_treatise_on_control_modifier + } + } + 30 = { + trigger = { + scope:inspiration_owner = { has_character_flag = civil_research } + house = { + NOT = { has_house_modifier = fp3_treatise_on_mathematics_modifier } + } + } + save_scope_value_as = { + name = researched_house_modifier + value = flag:fp3_treatise_on_mathematics_modifier + } + } + 30 = { + trigger = { + scope:inspiration_owner = { has_character_flag = civil_research } + house = { + NOT = { has_house_modifier = fp3_treatise_on_taxation_modifier } + } + } + save_scope_value_as = { + name = researched_house_modifier + value = flag:fp3_treatise_on_taxation_modifier + } + } + 30 = { + trigger = { + scope:inspiration_owner = { has_character_flag = military_research } + house = { + NOT = { has_house_modifier = fp3_treatise_on_light_warfare_modifier } + } + } + save_scope_value_as = { + name = researched_house_modifier + value = flag:fp3_treatise_on_light_warfare_modifier + } + } + 30 = { + trigger = { + scope:inspiration_owner = { has_character_flag = military_research } + house = { + NOT = { has_house_modifier = fp3_treatise_on_heavy_warfare_modifier } + } + } + save_scope_value_as = { + name = researched_house_modifier + value = flag:fp3_treatise_on_heavy_warfare_modifier + } + } + 30 = { + trigger = { + scope:inspiration_owner = { has_character_flag = military_research } + house = { + NOT = { has_house_modifier = fp3_treatise_on_cavalry_modifier } + } + } + save_scope_value_as = { + name = researched_house_modifier + value = flag:fp3_treatise_on_cavalry_modifier + } + } + 30 = { + trigger = { + scope:inspiration_owner = { has_character_flag = military_research } + house = { + NOT = { has_house_modifier = fp3_treatise_on_siege_modifier } + } + } + save_scope_value_as = { + name = researched_house_modifier + value = flag:fp3_treatise_on_siege_modifier + } + } + 30 = { + trigger = { + scope:inspiration_owner = { has_character_flag = military_research } + house = { + NOT = { has_house_modifier = fp3_treatise_on_strategy_modifier } + } + } + save_scope_value_as = { + name = researched_house_modifier + value = flag:fp3_treatise_on_strategy_modifier + } + } + 1 = { + save_scope_value_as = { + name = researched_house_modifier + value = flag:prestige + } + } + } + } + } + + option = { + name = fp3_scholarship.9100.a + ai_chance = { + base = 100 + } + switch = { + trigger = scope:researched_house_modifier + flag:fp3_treatise_on_development_modifier = { + fp3_scholarship_9100_reward_effect = { MODIFIER = fp3_treatise_on_development_modifier } + } + flag:fp3_treatise_on_building_modifier = { + fp3_scholarship_9100_reward_effect = { MODIFIER = fp3_treatise_on_building_modifier } + } + flag:fp3_treatise_on_control_modifier = { + fp3_scholarship_9100_reward_effect = { MODIFIER = fp3_treatise_on_control_modifier } + } + flag:fp3_treatise_on_mathematics_modifier = { + fp3_scholarship_9100_reward_effect = { MODIFIER = fp3_treatise_on_mathematics_modifier } + } + flag:fp3_treatise_on_taxation_modifier = { + fp3_scholarship_9100_reward_effect = { MODIFIER = fp3_treatise_on_taxation_modifier } + } + flag:fp3_treatise_on_light_warfare_modifier = { + fp3_scholarship_9100_reward_effect = { MODIFIER = fp3_treatise_on_light_warfare_modifier } + } + flag:fp3_treatise_on_heavy_warfare_modifier = { + fp3_scholarship_9100_reward_effect = { MODIFIER = fp3_treatise_on_heavy_warfare_modifier } + } + flag:fp3_treatise_on_cavalry_modifier = { + fp3_scholarship_9100_reward_effect = { MODIFIER = fp3_treatise_on_cavalry_modifier } + } + flag:fp3_treatise_on_siege_modifier = { + fp3_scholarship_9100_reward_effect = { MODIFIER = fp3_treatise_on_siege_modifier } + } + flag:fp3_treatise_on_strategy_modifier = { + fp3_scholarship_9100_reward_effect = { MODIFIER = fp3_treatise_on_strategy_modifier } + } + flag:prestige = { + custom_tooltip = patron_of_the_sciences + add_prestige = massive_prestige_value + } + } + } +} + +# Research project critical success! New innovation discovered +fp3_scholarship.9200 = { + type = character_event + title = fp3_scholarship.9200.t + desc = fp3_scholarship.9200.desc + theme = education + left_portrait = { + character = scope:inspiration_owner + animation = happiness + } + + immediate = { + play_music_cue = "mx_cue_epic_sacral_moment" + hidden_effect = { + random_list = { + 30 = { + trigger = { + culture = { + NOT = { has_innovation = fp3_innovation_mural_sextant } + has_cultural_era_or_later = culture_era_early_medieval + } + } + save_scope_value_as = { + name = research_cultural_innovation + value = flag:fp3_innovation_mural_sextant + } + } + 30 = { + trigger = { + culture = { + NOT = { has_innovation = fp3_innovation_fritware } + has_cultural_era_or_later = culture_era_late_medieval + } + } + save_scope_value_as = { + name = research_cultural_innovation + value = flag:fp3_innovation_fritware + } + } + } + } + } + + option = { + name = fp3_scholarship.9200.a + switch = { + trigger = scope:research_cultural_innovation + flag:fp3_innovation_mural_sextant = { + culture = { add_innovation = fp3_innovation_fritware } + } + flag:fp3_innovation_fritware = { + culture = { add_innovation = fp3_innovation_fritware } + } + } + } +} diff --git a/events/dlc/fp3/fp3_story_cycle_seljuks_invasion_events.txt b/events/dlc/fp3/fp3_story_cycle_seljuks_invasion_events.txt new file mode 100644 index 0000000000..dd7e3cac6b --- /dev/null +++ b/events/dlc/fp3/fp3_story_cycle_seljuks_invasion_events.txt @@ -0,0 +1 @@ +# Warcraft \ No newline at end of file diff --git a/events/dlc/fp3/fp3_story_cycle_zanj_rebellion_events.txt b/events/dlc/fp3/fp3_story_cycle_zanj_rebellion_events.txt new file mode 100644 index 0000000000..dd7e3cac6b --- /dev/null +++ b/events/dlc/fp3/fp3_story_cycle_zanj_rebellion_events.txt @@ -0,0 +1 @@ +# Warcraft \ No newline at end of file diff --git a/events/dlc/fp3/fp3_struggle_events.txt b/events/dlc/fp3/fp3_struggle_events.txt new file mode 100644 index 0000000000..dd7e3cac6b --- /dev/null +++ b/events/dlc/fp3/fp3_struggle_events.txt @@ -0,0 +1 @@ +# Warcraft \ No newline at end of file diff --git a/events/dlc/fp3/fp3_tax_collector_events_ola.txt b/events/dlc/fp3/fp3_tax_collector_events_ola.txt new file mode 100644 index 0000000000..562279f812 --- /dev/null +++ b/events/dlc/fp3/fp3_tax_collector_events_ola.txt @@ -0,0 +1,1463 @@ +namespace = fp3_clan + +########EVENT INDEX############ +#fp3_clan.8008 - Bleeding them Dry, by Ola Jentzsch +#fp3_clan.8009 - Popular with the People, by Ola Jentzsch +#fp3_clan.8010 - Competent Qadis / More Magistrates, by Ola Jentzsch +#fp3_clan.8011 - A Proper Paymaster, by Ola Jentzsch +#fp3_clan.8012 - Auspicious Avarice, by Ola Jentzsch +#fp3_clan.8013 - The Burden of Tax Farming, by Ola Jentzsch + + +###########fp3_clan.8008 - Bleeding them Dry, by Ola Jentzsch############### +scripted_trigger tax_collector_8008_trigger = { + is_available_ai_adult = yes + tax_collector_aptitude = { + tax_slot_type = clan_tax_slot + value >= 4 + } + ai_honor <= low_positive_ai_value +} + +scripted_trigger house_unity_8008_member_trigger = { + is_available_ai_adult = yes + is_vassal_of = root + opinion = { + target = root + value <= 75 + } + reverse_opinion = { + target = scope:$SCOPE$ + value < 0 + } +} + +fp3_clan.8008 = { + type = character_event + title = fp3_clan.8008.t + desc = fp3_clan.8008.desc + theme = intrigue_intimidation_focus + + left_portrait = { + character = root + animation = personality_cynical + triggered_animation = { + trigger = { + OR = { + has_trait = ambitious + has_trait = sadistic + has_trait = greedy + } + } + animation = personality_greedy + } + } + right_portrait = { + character = scope:ambitious_tax_collector + animation = chancellor + triggered_animation = { + trigger = { ai_greed >= high_positive_ai_value } + animation = personality_dishonorable + } + } + lower_left_portrait = { + character = scope:beleaguered_clan_member + } + + override_background = { reference = corridor_night } + + trigger = { + has_fp3_dlc_trigger = yes + is_available_healthy_adult = yes + + any_vassal = { #checking that it would be beneficial to gain the Extort Subjects decision + highest_held_title_tier >= tier_county + } + + any_tax_collector = { + tax_collector_8008_trigger = yes + save_temporary_scope_as = tax_collector_temp + } + + house = { + any_house_unity_member = { + house_unity_8008_member_trigger = { SCOPE = tax_collector_temp } + } + } + } + + cooldown = { years = 10 } + + immediate = { + random_tax_collector = { + limit = { + tax_collector_8008_trigger = yes + } + save_scope_as = ambitious_tax_collector + } + + house = { + random_house_unity_member = { + limit = { + house_unity_8008_member_trigger = { SCOPE = ambitious_tax_collector } + } + save_scope_as = beleaguered_clan_member + } + } + } + + option = { + name = fp3_clan.8008.a + + add_tyranny = medium_tyranny_value + + add_character_modifier = { + modifier = fp3_justification_for_taxation_modifier + years = 20 + } + + if = { + limit = { + NOR = { + has_perk = it_is_my_domain_perk + has_lifestyle = stewardship_lifestyle + } + } + custom_tooltip = unlock_extortion.tt + } + + add_clan_unity_interaction_effect = { + CHARACTER = root + TARGET = scope:beleaguered_clan_member + VALUE = minor_unity_loss + DESC = clan_unity_extorted_vassal.desc + REVERSE_NON_HOUSE_TARGET = no + } + + scope:ambitious_tax_collector = { + add_opinion = { + target = root + modifier = pleased_opinion + opinion = 20 + } + } + + stress_impact = { + greedy = medium_stress_impact_loss + ambitious = minor_stress_impact_loss + just = medium_stress_impact_gain + honest = medium_stress_impact_gain + generous = medium_stress_impact_gain + content = minor_stress_impact_gain + } + + ai_chance = { + base = 50 + ai_value_modifier = { + ai_greed = 1 + ai_energy = 0.5 + ai_honor = -0.7 + ai_compassion = -0.2 + } + } + } + + option = { + name = fp3_clan.8008.b + + scope:beleaguered_clan_member = { + pay_short_term_gold = { + target = root + gold = medium_gold_value + } + add_opinion = { + target = root + modifier = extorted_me_opinion + } + } + + add_clan_unity_interaction_effect = { + CHARACTER = root + TARGET = scope:beleaguered_clan_member + VALUE = minor_unity_loss + DESC = clan_unity_extorted_vassal.desc + REVERSE_NON_HOUSE_TARGET = no + } + + scope:ambitious_tax_collector = { + add_opinion = { + target = root + modifier = trusted_me_opinion + opinion = 10 + } + } + + stress_impact = { + greedy = minor_stress_impact_loss + just = minor_stress_impact_gain + generous = minor_stress_impact_gain + compassionate = minor_stress_impact_gain + } + + ai_chance = { + base = 100 + ai_value_modifier = { + ai_greed = 0.8 + ai_energy = 0.3 + ai_honor = -0.4 + ai_compassion = -0.7 + } + } + } + + option = { + name = fp3_clan.8008.c + + scope:ambitious_tax_collector = { + add_opinion = { + target = root + modifier = disappointed_opinion + opinion = -10 + } + } + + stress_impact = { + content = minor_stress_impact_loss + greedy = medium_stress_impact_gain + ambitious = minor_stress_impact_gain + deceitful = minor_stress_impact_gain + } + + ai_chance = { + base = 100 + ai_value_modifier = { + ai_greed = 0.8 + ai_energy = 0.3 + ai_honor = -0.4 + ai_compassion = -0.7 + } + } + } +} + +#############fp3_clan.8009 - Popular with the People, by Ola Jentzsch############ +scripted_trigger fp3_clan_8009_province_trigger = { + has_holding_type = city_holding + barony = { + is_under_holy_order_lease = no + holder = { fp3_clan_suitable_holder_trigger = yes } + } +} + +scripted_trigger fp3_clan_suitable_holder_trigger = { + stewardship >= average_skill_rating + NOR = { + has_trait = sadistic + has_trait = honest + has_trait = content + has_trait = lazy + has_trait = arrogant + has_trait = callous + has_relation_friend = root + has_relation_lover = root + is_close_family_of = root + + } +} + +scripted_trigger tax_collector_8009_trigger = { + is_available_ai_adult = yes + tax_collector_aptitude = { + tax_slot_type = clan_tax_slot + value >= 2 + } + OR = { + ai_honor <= low_positive_ai_value + ai_compassion < low_positive_ai_value + ai_greed >= medium_positive_ai_value + } +} + +fp3_clan.8009 = { + type = character_event + title = fp3_clan.8009.t + desc = fp3_clan.8009.desc + theme = realm + + left_portrait = { + character = root + animation = disbelief + triggered_animation = { + trigger = { + OR = { + has_trait = vengeful + has_trait = paranoid + has_trait = sadistic + } + } + animation = personality_vengeful + } + } + right_portrait = { + character = scope:righteous_tax_collector + animation = personality_rational + triggered_animation = { + trigger = { ai_compassion < low_positive_ai_value } + animation = schadenfreude + } + } + lower_left_portrait = { + character = scope:corrupt_mayor + } + + trigger = { + has_fp3_dlc_trigger = yes + is_available_healthy_adult = yes + + any_tax_collector = { + tax_collector_8009_trigger = yes + save_temporary_scope_as = tax_collector_temp + } + + any_held_county = { any_county_province = { fp3_clan_8009_province_trigger = yes } } + } + + cooldown = { years = 10 } + + immediate = { + random_tax_collector = { + limit = { + tax_collector_8009_trigger = yes + } + save_scope_as = righteous_tax_collector + } + + random_held_county = { + limit = { + any_county_province = { fp3_clan_8009_province_trigger = yes } + } + save_scope_as = fawazil_county + + random_county_province = { + limit = { fp3_clan_8009_province_trigger = yes } + barony = { + save_scope_as = fawazil_barony + + holder = { + save_scope_as = corrupt_mayor + } + } + } + } + + hidden_effect = { + scope:corrupt_mayor = { + add_gold = major_gold_value #this is the corruption money + } + } + } + + option = { + name = fp3_clan.8009.a + + scope:corrupt_mayor = { + override_death_killer_effect = { + death_reason = death_crucified + killer = root + } + } + + duel = { + skill = intrigue + value = average_skill_rating + + 50 = { + compare_modifier = { + value = scope:duel_value + multiplier = 3.5 + max = 40 + min = -40 + } + + desc = fp3_clan.8009.a.success + send_interface_toast = { + title = fp3_clan.8009.a.success.tt + left_icon = root + + add_dread = medium_dread_gain + + scope:fawazil_county = { + add_county_modifier = { + modifier = fp3_locals_intimidated_county_modifier + years = 15 + } + } + } + } + 50 = { + compare_modifier = { + value = scope:duel_value + multiplier = -3.5 + max = 40 + min = -40 + } + + desc = fp3_clan.8009.a.failure + send_interface_toast = { + title = fp3_clan.8009.a.failure.tt + left_icon = root + + add_dread = minor_dread_gain + + add_tyranny = minor_tyranny_gain + + scope:fawazil_county = { + add_county_modifier = { + modifier = fp3_locals_infuriated_county_modifier + years = 15 + } + } + } + } + } + + stress_impact = { + vengeful = major_stress_impact_loss + sadistic = minor_stress_impact_loss + honest = medium_stress_impact_gain + generous = minor_stress_impact_gain + forgiving = medium_stress_impact_gain + just = medium_stress_impact_gain + compassionate = major_stress_impact_gain + } + + ai_chance = { + base = 50 + ai_value_modifier = { + ai_vengefulness = 1 + ai_boldness = 0.9 + ai_honor = -0.5 + ai_compassion = -1 + } + } + } + + option = { + name = fp3_clan.8009.b + + rightfully_imprison_character_effect = { + TARGET = scope:corrupt_mayor + IMPRISONER = root + } + + scope:corrupt_mayor = { + pay_short_term_gold = { + target = root + gold = major_gold_value + } + } + + scope:fawazil_county = { + add_county_modifier = { + modifier = fp3_locals_infuriated_county_modifier + years = 15 + } + } + + stress_impact = { + forgiving = minor_stress_impact_gain + compassionate = minor_stress_impact_gain + } + + ai_chance = { + base = 100 + ai_value_modifier = { + ai_vengefulness = 0.6 + ai_greed = 0.5 + ai_rationality = 0.4 + ai_compassion = -0.5 + } + } + } + + option = { + name = fp3_clan.8009.c + + add_character_modifier = { + modifier = fp3_looking_the_other_way_modifier + years = 10 + } + + stress_impact = { + forgiving = medium_stress_impact_loss + trusting = minor_stress_impact_loss + paranoid = minor_stress_impact_gain + vengeful = major_stress_impact_gain + wrathful = medium_stress_impact_gain + greedy = medium_stress_impact_gain + just = minor_stress_impact_gain + } + + ai_chance = { + base = 100 + ai_value_modifier = { + ai_vengefulness = -1 + ai_boldness = -0.7 + ai_rationality = 0.6 + ai_compassion = 0.5 + } + } + } +} + +################fp3_clan.8010 - Competent Qadis / More Magistrates, by Ola Jentzsch################# +scripted_trigger fp3_suitable_magistrate_courtier_trigger = { + is_available_ai_adult = yes + NOR = { + is_close_or_extended_family_of = root + is_consort_of = root + } + any_child = { count < 1 } + any_relation = { count < 1 } + has_any_court_position = no + is_councillor = no + can_be_clergy_due_to_gender_trigger = yes + OR = { + learning >= high_skill_rating + stewardship >= high_skill_rating + } + NOT = { this = scope:$SCOPE$ } +} + +scripted_trigger tax_collector_8010_trigger = { + is_available_ai_adult = yes + tax_collector_aptitude = { + tax_slot_type = clan_tax_slot + value >= 1 + } + tax_collector_aptitude = { #since this would make the modifier redundant + tax_slot_type = clan_tax_slot + value < 4 + } +} + +fp3_clan.8010 = { #More Magistrates + type = character_event + title = { + first_valid = { + desc = fp3_clan.8010.t + } + } + desc = { + desc = fp3_clan.8010.desc_beginning + first_valid = { + desc = fp3_clan.8010_non_muslim_version + } + } + theme = corruption + + left_portrait = { + character = scope:competent_tax_collector + animation = stress + triggered_animation = { + trigger = { ai_vengefulness >= low_positive_ai_value } + animation = anger + } + } + right_portrait = { + character = root + animation = personality_rational + triggered_animation = { + trigger = { + OR = { + has_trait = lazy + has_trait = content + has_trait = greedy + has_trait = callous + } + } + animation = dismissal + } + } + + lower_left_portrait = { character = scope:capable_magistrate_candidate } + + trigger = { + has_fp3_dlc_trigger = yes + is_available_healthy_adult = yes + + any_tax_collector = { + tax_collector_8010_trigger = yes + save_temporary_scope_as = competent_tax_collector_temp + } + } + + cooldown = { years = 10 } + + immediate = { + random_tax_collector = { + limit = { + tax_collector_8010_trigger = yes + } + save_scope_as = competent_tax_collector + } + + if = { + limit = { + any_courtier = { + fp3_suitable_magistrate_courtier_trigger = { SCOPE = competent_tax_collector } + } + } + random_courtier = { + limit = { + fp3_suitable_magistrate_courtier_trigger = { SCOPE = competent_tax_collector } + } + save_scope_as = capable_magistrate_candidate + } + } + } + + option = { + name = fp3_clan.8010.a + flavor = tax_farming_capable_courtier_flavor + + trigger = { + exists = scope:capable_magistrate_candidate + } + + remove_courtier_or_guest = scope:capable_magistrate_candidate + + scope:competent_tax_collector = { + add_opinion = { + target = root + modifier = slightly_disappointed_opinion + opinion = -10 + } + add_character_modifier = { + modifier = fp3_capable_magistrates_modifier + years = 25 + } + custom_tooltip = increase_aptitude.tt + } + + ai_chance = { + base = 100 + ai_value_modifier = { + ai_rationality = 0.5 + ai_sociability = 0.7 + ai_greed = 0.2 + } + } + } + + option = { + name = fp3_clan.8010.b + + remove_short_term_gold = major_gold_value + + scope:competent_tax_collector = { + add_opinion = { + target = root + modifier = trusted_me_opinion + opinion = 20 + } + add_character_modifier = { + modifier = fp3_capable_magistrates_modifier + years = 25 + } + custom_tooltip = increase_aptitude.tt + } + + stress_impact = { + greedy = minor_stress_impact_gain + arrogant = minor_stress_impact_gain + } + + ai_chance = { + base = 100 + ai_value_modifier = { + ai_greed = -0.5 + ai_rationality = 0.6 + } + } + } + + option = { + name = fp3_clan.8010.c + + scope:competent_tax_collector = { + add_opinion = { + target = root + modifier = fp3_resentful_opinion + opinion = -15 + } + } + + stress_impact = { + diligent = minor_stress_impact_gain + ambitious = minor_stress_impact_gain + patient = minor_stress_impact_gain + } + + ai_chance = { + base = 100 + ai_value_modifier = { + ai_greed = -1 + ai_rationality = -0.6 + ai_energy = -0.3 + } + } + } +} + +##################fp3_clan.8011 - A Proper Paymaster, by Ola Jentzsch########################### +scripted_trigger fp3_suitable_extra_tax_collector_competence_traits_trigger = { + is_available_ai_adult = yes + NOT = { has_trait = content } + OR = { + tax_collector_aptitude = { + tax_slot_type = clan_tax_slot + value >= 4 + } + AND = { + tax_collector_aptitude = { + tax_slot_type = clan_tax_slot + value >= 3 + } + OR = { + has_trait = ambitious + has_trait = diligent + has_trait = organizer + has_trait = overseer + has_trait = administrator + martial >= high_skill_rating + } + } + } +} + +fp3_clan.8011 = { #A Proper Paymaster + type = character_event + title = fp3_clan.8011.t + desc = fp3_clan.8011.desc + theme = stewardship_wealth_focus + + left_portrait = { + character = scope:competent_tax_collector + animation = personality_greedy + triggered_animation = { + trigger = { ai_boldness >= low_positive_ai_value } + animation = personality_honorable + } + } + right_portrait = { + character = root + animation = personality_content + triggered_animation = { + trigger = { + OR = { + has_trait = paranoid + has_trait = ambitious + has_trait = diligent + has_trait = brave + } + } + animation = dismissal + } + } + + lower_left_portrait = { character = scope:concerned_marshal } + + override_background = { reference = army_camp } + + trigger = { + has_fp3_dlc_trigger = yes + is_available_healthy_adult = yes + + number_of_maa_regiments >= 1 + + exists = cp:councillor_marshal + + any_tax_collector = { + fp3_suitable_extra_tax_collector_competence_traits_trigger = yes + NOT = { + this = root.cp:councillor_marshal + } + } + } + + cooldown = { years = 10 } + + immediate = { + random_tax_collector = { + limit = { + fp3_suitable_extra_tax_collector_competence_traits_trigger = yes + } + save_scope_as = competent_tax_collector + } + + cp:councillor_marshal = { save_scope_as = concerned_marshal } + } + + option = { + name = fp3_clan.8011.a + + add_character_modifier = { + modifier = fp3_delegated_payments_modifier + years = 25 + } + + scope:competent_tax_collector = { + add_opinion = { + target = root + modifier = pleased_opinion + opinion = 15 + } + add_character_modifier = { + modifier = fp3_army_influence_modifier + years = 25 + } + } + + scope:concerned_marshal = { + add_opinion = { + target = root + modifier = fp3_meddling_in_my_privileges_opinion + opinion = -30 + } + if = { + limit = { + NOT = { has_relation_rival = scope:competent_tax_collector } + } + set_relation_rival = { + target = scope:competent_tax_collector + reason = rival_over_position + } + } + } + + stress_impact = { + diligent = minor_stress_impact_loss + ambitious = minor_stress_impact_loss + content = medium_stress_impact_gain + just = minor_stress_impact_gain + } + + ai_chance = { + base = 100 + ai_value_modifier = { + ai_rationality = 0.3 + ai_greed = 0.7 + ai_energy = -0.4 + } + } + } + + option = { + name = fp3_clan.8011.b + + duel = { + skill = diplomacy + value = average_skill_rating + + 50 = { + compare_modifier = { + value = scope:duel_value + multiplier = 3.5 + max = 40 + min = -40 + } + + modifier = { + add = 50 + scope:concerned_marshal = { + OR = { + has_trait = trusting + has_trait = humble + has_trait = content + } + } + } + + modifier = { + add = -50 + scope:concerned_marshal = { + OR = { + has_trait = paranoid + has_trait = arrogant + has_trait = ambitious + } + } + } + + modifier = { + add = -50 + scope:competent_tax_collector = { + OR = { + has_trait = greedy + has_trait = arrogant + has_trait = ambitious + } + } + } + + modifier = { + add = 50 + scope:concerned_marshal = { + OR = { + has_trait = humble + has_trait = trusting + has_trait = loyal + } + } + } + + desc = fp3_clan.8011.b.success + send_interface_toast = { + title = fp3_clan.8011.b.success.tt + left_icon = root + + add_character_modifier = { + modifier = fp3_delegated_payments_modifier + years = 10 + } + } + } + 50 = { + compare_modifier = { + value = scope:duel_value + multiplier = -3.5 + max = 40 + min = -40 + } + + desc = fp3_clan.8011.b.failure + send_interface_toast = { + title = fp3_clan.8011.b.failure.tt + left_icon = root + + add_character_modifier = { + modifier = fp3_messy_payments_modifier + years = 25 + } + + scope:concerned_marshal = { + add_opinion = { + target = root + modifier = fp3_meddling_in_my_privileges_opinion + opinion = -30 + } + if = { + limit = { + NOT = { has_relation_rival = scope:competent_tax_collector } + } + set_relation_rival = { + target = scope:competent_tax_collector + reason = rival_over_position + } + } + } + scope:competent_tax_collector = { + add_opinion = { + target = root + modifier = fp3_frustrated_opinion + opinion = -10 + } + } + } + } + } + + stress_impact = { + trusting = minor_stress_impact_loss + } + + ai_chance = { + base = 100 + ai_value_modifier = { + ai_sociability = 0.8 + ai_honor = 0.8 + ai_vengefulness = -0.4 + } + } + } + + option = { + name = fp3_clan.8011.c + + scope:competent_tax_collector = { + add_opinion = { + target = root + modifier = fp3_resentful_opinion + opinion = -15 + } + } + + stress_impact = { + diligent = minor_stress_impact_gain + ambitious = minor_stress_impact_gain + } + + ai_chance = { + base = 50 + ai_value_modifier = { + ai_energy = -0.5 + ai_compassion = 0.2 + } + } + } +} + +##############fp3_clan.8012 - Auspicious Avarice, by Ola Jentzsch################### +scripted_trigger tax_collector_8012_trigger = { + tax_collector_aptitude = { + tax_slot_type = clan_tax_slot + value >= 3 + } + is_available_ai_adult = yes + ai_honor < medium_positive_ai_value +} + +scripted_trigger vassal_check_8012_trigger = { + has_any_good_relationship_with_root_trigger = no + is_ai = yes + reverse_opinion = { + target = scope:$SCOPE$ + value < 25 + } +} + +fp3_clan.8012 = { + type = character_event + title = fp3_clan.8012.t + desc = fp3_clan.8012.desc + theme = stewardship_wealth_focus + + left_portrait = { + character = root + animation = personality_compassionate + triggered_animation = { + trigger = { + OR = { + has_trait = ambitious + has_trait = sadistic + has_trait = greedy + } + } + animation = personality_dishonorable + } + } + right_portrait = { + character = scope:greedy_tax_collector + animation = personality_greedy + triggered_animation = { + trigger = { + OR = { + ai_greed >= high_positive_ai_value + ai_honor < low_positive_ai_value + } + } + animation = schadenfreude + } + } + lower_left_portrait = { + character = scope:extorted_vassal + } + + trigger = { + has_fp3_dlc_trigger = yes + is_available_healthy_adult = yes + + any_tax_collector = { + tax_collector_8012_trigger = yes + save_temporary_scope_as = greedy_tax_collector_temp + any_tax_collector_vassal = { + vassal_check_8012_trigger = { SCOPE = greedy_tax_collector_temp } + } + } + } + + cooldown = { years = 10 } + + immediate = { + random_tax_collector = { + limit = { + tax_collector_8012_trigger = yes + save_temporary_scope_as = greedy_tax_collector_temp + any_tax_collector_vassal = { + vassal_check_8012_trigger = { SCOPE = greedy_tax_collector_temp } + } + } + save_scope_as = greedy_tax_collector + random_tax_collector_vassal = { + limit = { + vassal_check_8012_trigger = { SCOPE = greedy_tax_collector_temp } + } + save_scope_as = extorted_vassal + } + } + + hidden_effect = { + scope:extorted_vassal = { + pay_short_term_gold = { + target = scope:greedy_tax_collector + gold = medium_gold_value + } + } + } + + save_scope_value_as = { + name = vassal_medium_gold_halved + value = { + value = scope:extorted_vassal.medium_gold_value + divide = 2 + } + } + } + + option = { + name = fp3_clan.8012.a + + scope:greedy_tax_collector = { + pay_short_term_gold = { + target = root + gold = scope:extorted_vassal.medium_gold_value + } + } + + scope:extorted_vassal = { + add_opinion = { + target = root + modifier = extorted_me_opinion + } + } + + stress_impact = { + greedy = medium_stress_impact_loss + generous = medium_stress_impact_gain + } + + ai_chance = { + base = 100 + ai_value_modifier = { + ai_greed = 1 + ai_compassion = -0.4 + ai_honor = -0.4 + } + } + } + + option = { + name = fp3_clan.8012.b + + add_piety = medium_piety_gain + + scope:greedy_tax_collector = { + remove_short_term_gold = scope:extorted_vassal.medium_gold_value + } + + stress_impact = { + zealous = minor_stress_impact_loss + greedy = minor_stress_impact_gain + } + + ai_chance = { + base = 100 + ai_value_modifier = { + ai_greed = -0.5 + ai_compassion = 1 + ai_rationality = 0.6 + } + } + } + + option = { + name = fp3_clan.8012.c + + add_prestige = minor_prestige_gain + + scope:greedy_tax_collector = { + pay_short_term_gold = { + target = scope:extorted_vassal + gold = scope:vassal_medium_gold_halved + } + } + scope:greedy_tax_collector = { + pay_short_term_gold = { + target = root + gold = scope:vassal_medium_gold_halved + } + } + + scope:extorted_vassal = { + add_opinion = { + target = root + modifier = fp3_frustrated_opinion + opinion = -10 + } + } + + stress_impact = { + generous = minor_stress_impact_loss + forgiving = minor_stress_impact_loss + vengeful = minor_stress_impact_gain + greedy = minor_stress_impact_gain + + } + + ai_chance = { + base = 100 + ai_value_modifier = { + ai_greed = -1 + ai_vengefulness = -0.5 + ai_compassion = 0.5 + ai_rationality = 0.8 + } + } + } +} + +############fp3_clan.8013 - The Burden of Tax Farming, by Ola Jentzsch######### +scripted_trigger tax_collector_8013_trigger = { + tax_collector_aptitude = { + tax_slot_type = clan_tax_slot + value >= 2 + } + is_available_ai_adult = yes + has_any_bad_relationship_with_root_trigger = no +} + +fp3_clan.8013 = { + type = character_event + title = fp3_clan.8013.t + desc = fp3_clan.8013.desc + theme = learning_scholarship_focus + + left_portrait = { + character = root + animation = personality_forgiving + triggered_animation = { + trigger = { + OR = { + has_trait = callous + has_trait = sadistic + has_trait = arrogant + has_trait = vengeful + has_trait = wrathful + } + } + animation = personality_cynical + } + } + right_portrait = { + character = scope:stressed_tax_collector + animation = boredom + triggered_animation = { + trigger = { + ai_energy >= low_positive_ai_value + } + animation = stress + } + } + + trigger = { + has_fp3_dlc_trigger = yes + is_available = yes + is_healthy = yes + age > 10 + + any_tax_collector = { + tax_collector_8013_trigger = yes + } + } + + cooldown = { years = 10 } + + immediate = { + random_tax_collector = { + limit = { + tax_collector_8013_trigger = yes + } + save_scope_as = stressed_tax_collector + } + + scope:stressed_tax_collector = { + add_stress = major_stress_gain + } + } + + option = { # Assuage tax collector's stress + name = fp3_clan.8013.a + + duel = { + skill = stewardship + target = scope:stressed_tax_collector + + 50 = { + compare_modifier = { + value = scope:duel_value + multiplier = 3.5 + max = 40 + min = -40 + } + + modifier = { + add = 10 + scope:stressed_tax_collector = { + OR = { + has_trait = diligent + has_trait = ambitious + has_trait = patient + has_trait = trusting + } + } + } + + modifier = { + add = -10 + scope:stressed_tax_collector = { + OR = { + has_trait = lazy + has_trait = paranoid + has_trait = arrogant + } + } + } + + modifier = { + add = -10 + scope:stressed_tax_collector = { + opinion = { + target = root + value <= 25 + } + } + } + + desc = fp3_clan.8013.a.success + send_interface_toast = { + title = fp3_clan.8013.a.success.tt + left_icon = root + + if = { + limit = { + NOT = { has_relation_friend = scope:stressed_tax_collector } + } + progress_towards_friend_effect = { + CHARACTER = scope:stressed_tax_collector + REASON = friend_reassurance + OPINION = 25 + } + } + + scope:stressed_tax_collector = { + add_learning_skill = 1 + add_stewardship_skill = 1 + add_stress = medium_stress_impact_loss + } + } + } + 50 = { + compare_modifier = { + value = scope:duel_value + multiplier = -3.5 + max = 40 + min = -40 + } + + desc = fp3_clan.8013.a.failure + send_interface_toast = { + title = fp3_clan.8013.a.failure.tt + left_icon = root + + scope:stressed_tax_collector = { + add_character_modifier = { + modifier = fp3_cutting_corners_modifier + years = 10 + } + } + } + } + } + + stress_impact = { + compassionate = minor_stress_impact_loss + callous = minor_stress_impact_gain + arrogant = minor_stress_impact_gain + shy = minor_stress_impact_gain + } + + ai_chance = { + base = 100 + ai_value_modifier = { + ai_vengefulness = -0.5 + ai_energy = 0.3 + ai_sociability = 0.7 + ai_compassion = 0.8 + } + } + } + + option = { # Threaten tax collector with violence + name = fp3_clan.8013.b + + trigger = { + scope:stressed_tax_collector = { + NOT = { has_trait = brave } # Brave tax collectors won't be intimidated + } + } + + scope:stressed_tax_collector = { + add_stress = major_stress_gain + add_opinion = { + target = root + modifier = cruelty_opinion + opinion = -20 + } + add_learning_skill = 1 + add_stewardship_skill = 1 + } + + stress_impact = { + wrathful = minor_stress_impact_loss + compassionate = medium_stress_impact_gain + calm = medium_stress_impact_gain + forgiving = medium_stress_impact_gain + } + + ai_chance = { + base = 100 + ai_value_modifier = { + ai_vengefulness = 1 + ai_boldness = 0.4 + ai_sociability = -0.6 + ai_compassion = -0.7 + } + } + } + + option = { #Just move on + name = fp3_clan.8013.c + + stress_impact = { + compassionate = medium_stress_impact_gain + diligent = medium_stress_impact_gain + curious = minor_stress_impact_gain + } + + ai_chance = { + base = 100 + ai_value_modifier = { + ai_compassion = -1 + ai_energy = -0.5 + ai_sociability = -1 + ai_vengefulness = 0.3 + } + } + } +} + + + + + diff --git a/events/dlc/fp3/fp3_yearly_events_eren.txt b/events/dlc/fp3/fp3_yearly_events_eren.txt new file mode 100644 index 0000000000..1a6970e0f9 --- /dev/null +++ b/events/dlc/fp3/fp3_yearly_events_eren.txt @@ -0,0 +1,875 @@ +namespace = fp3_yearly + +scripted_effect fp3_yearly_2010_create_baker_effect = { + create_character = { + age = { 35 50 } + location = root.capital_province + gender_female_chance = root_faith_dominant_gender_female_chance + faith = root.capital_province.faith + culture = scope:bakers_county.culture + # Personality Traits + trait = greedy + random_traits_list = { + count = 2 + brave = {} + craven = {} + wrathful = {} + lustful = {} + ambitious = {} + diligent = {} + stubborn = {} + vengeful = {} + deceitful = {} + arrogant = {} + arbitrary = {} + impatient = {} + gluttonous = {} + } + random_traits_list = { + count = 1 + education_diplomacy_2 = {} + education_stewardship_2 = {} + education_stewardship_3 = {} + education_stewardship_4 = {} + education_learning_1 = {} + education_learning_2 = {} + } + # Flavor Traits + trait = administrator + random_traits_list = { + count = { 0 2 } + gout_ridden = {} + leper = {} + lovers_pox = {} + pneumonic = {} + dwarf = {} + giant = {} + hunchbacked = {} + weak = {} + clubfooted = {} + lisping = {} + stuttering = {} + wheezing = {} + albino = {} + scaly = {} + spindly = {} + maimed = {} + one_eyed = {} + one_legged = {} + disfigured = {} + blind = {} + } + random_traits = yes + diplomacy = { 8 13 } + martial = { 6 10 } + stewardship = { 8 13 } + intrigue = { 8 13 } + learning = { 13 18 } + prowess = { 3 8 } + after_creation = { + random_list = { + 50 = { + # Character is of average weight, nothing happens + } + 25 = { + change_current_weight = 25 + } + 25 = { + change_current_weight = 75 + } + } + add_character_flag = peasant_outfit + } + save_scope_as = greedy_baker + } + +} + +# Maunds of Wheat (The Bakers of Ghaznain) +# Your royal baker is hoarding bread, how shall you deal with them? +fp3_yearly.2010 = { + type = court_event + title = fp3_yearly.2010.t + desc = fp3_yearly.2010.desc + theme = court + cooldown = { years = 5 } + court_scene = { + button_position_character = root + roles = { + scope:greedy_baker = { + group = event_group + } + root = { + group = event_group + animation = personality_rational + } + scope:random_courtier = { + group = event_group + animation = beg + } + } + } + + trigger = { + has_fp3_dlc_trigger = yes + has_royal_court = yes + has_court_event_flag = no + is_available = yes + government_has_flag = government_is_clan + any_sub_realm_county = { + NOR = { + has_county_modifier = fp3_generous_bakers_modifier + has_county_modifier = fp3_wheat_shortage_modifier + } + } + any_courtier = { + is_available_ai_adult = yes + has_court_event_flag = no + } + } + + immediate = { + court_event_character_flag_effect = yes + random_courtier = { + limit = { + is_available_ai_adult = yes + has_court_event_flag = no + } + save_scope_as = random_courtier + court_event_character_flag_effect = yes + } + random_sub_realm_county = { + save_scope_as = bakers_county + } + fp3_yearly_2010_create_baker_effect = yes + scope:greedy_baker = { court_event_character_flag_effect = yes } + } + + option = { # Trample to death + name = { + text = { + desc = fp3_yearly.2010.a + first_valid = { + triggered_desc = { + trigger = { culture = { has_innovation = innovation_elephantry } } + desc = fp3_yearly.2010.a_elephants + } + triggered_desc = { + trigger = { culture = { has_innovation = innovation_elephantry } } + desc = fp3_yearly.2010.a_camels + } + desc = fp3_yearly.2010.a_horses + } + } + } + flavor = fp3_yearly.2010.a.tt + stress_impact = { + greedy = minor_stress_impact_gain + just = minor_stress_impact_loss + sadistic = minor_stress_impact_loss + } + scope:greedy_baker = { + override_death_effect = { death_reason = death_trampled } + } + add_prestige = minor_prestige_loss + remove_short_term_gold = minor_gold_value + scope:bakers_county = { + add_county_modifier = { + modifier = fp3_generous_bakers_modifier + years = 15 + } + } + ai_chance = { + base = 100 + modifier = { + has_trait = greedy + factor = 0 + } + } + } + + option = { # Recruit + name = fp3_yearly.2010.b + stress_impact = { + just = minor_stress_impact_gain + zealous = minor_stress_impact_gain + arbitrary = minor_stress_impact_loss + } + add_courtier = scope:greedy_baker + scope:bakers_county = { + add_county_modifier = { + modifier = fp3_wheat_shortage_modifier + years = 10 + } + } + ai_chance = { + base = 10 + modifier = { + has_trait = just + factor = 0 + } + modifier = { + has_trait = zealous + factor = 0 + } + } + } + + option = { # Take the extra money + name = fp3_yearly.2010.c + add_gold = medium_gold_value + stress_impact = { + just = medium_stress_impact_gain + generous = medium_stress_impact_gain + zealous = minor_stress_impact_gain + greedy = minor_stress_impact_loss + } + scope:bakers_county = { + add_county_modifier = { + modifier = fp3_wheat_shortage_modifier + years = 10 + } + } + ai_chance = { + base = 10 + modifier = { + has_trait = just + factor = 0 + } + modifier = { + has_trait = generous + factor = 0 + } + } + } + + after = { + clear_court_event_participation = yes + scope:greedy_baker = { clear_court_event_participation = yes } + scope:random_courtier = { clear_court_event_participation = yes } + } +} + +# Maunds of Wheat (Non-Royal Court Version) +fp3_yearly.2011 = { + type = character_event + title = fp3_yearly.2010.t + desc = fp3_yearly.2010.desc + theme = crown + left_portrait = { + character = root + animation = thinking + } + right_portrait = { + character = scope:random_courtier + animation = beg + } + lower_left_portrait = scope:greedy_baker + cooldown = { years = 10 } + + trigger = { + has_fp3_dlc_trigger = yes + government_has_flag = government_is_clan + highest_held_title_tier >= tier_kingdom + any_courtier = { + is_available_ai_adult = yes + } + any_sub_realm_county = { + NOR = { + has_county_modifier = fp3_generous_bakers_modifier + has_county_modifier = fp3_wheat_shortage_modifier + } + } + } + + immediate = { + random_courtier = { + limit = { + is_available_ai_adult = yes + } + save_scope_as = random_courtier + } + random_sub_realm_county = { + save_scope_as = bakers_county + } + fp3_yearly_2010_create_baker_effect = yes + } + + option = { # Trample to death + name = { + text = { + desc = fp3_yearly.2010.a + first_valid = { + triggered_desc = { + trigger = { culture = { has_innovation = innovation_elephantry } } + desc = fp3_yearly.2010.a_elephants + } + triggered_desc = { + trigger = { culture = { has_innovation = innovation_elephantry } } + desc = fp3_yearly.2010.a_camels + } + desc = fp3_yearly.2010.a_horses + } + } + } + flavor = fp3_yearly.2010.a.tt + stress_impact = { + greedy = minor_stress_impact_gain + just = minor_stress_impact_loss + sadistic = minor_stress_impact_loss + } + scope:greedy_baker = { + override_death_effect = { death_reason = death_trampled } + } + add_prestige = minor_prestige_loss + remove_short_term_gold = minor_gold_value + scope:bakers_county = { + add_county_modifier = { + modifier = fp3_generous_bakers_modifier + years = 15 + } + } + ai_chance = { + base = 100 + modifier = { + has_trait = greedy + factor = 0 + } + } + } + + option = { # Recruit + name = fp3_yearly.2010.b + add_courtier = scope:greedy_baker + scope:bakers_county = { + add_county_modifier = { + modifier = fp3_wheat_shortage_modifier + years = 10 + } + } + stress_impact = { + just = minor_stress_impact_gain + zealous = minor_stress_impact_gain + arbitrary = minor_stress_impact_loss + } + ai_chance = { + base = 10 + modifier = { + has_trait = just + factor = 0 + } + modifier = { + has_trait = zealous + factor = 0 + } + } + } + + option = { # Take the extra money + name = fp3_yearly.2010.c + add_gold = major_gold_value + stress_impact = { + just = medium_stress_impact_gain + generous = medium_stress_impact_gain + zealous = minor_stress_impact_gain + greedy = minor_stress_impact_loss + } + scope:bakers_county = { + add_county_modifier = { + modifier = fp3_wheat_shortage_modifier + years = 10 + } + } + ai_chance = { + base = 10 + modifier = { + has_trait = just + factor = 0 + } + modifier = { + has_trait = generous + factor = 0 + } + } + } +} + +# A Beautiful Rule (The Ugliness of Sultan Mahmud) +# You are ugly, but your courtier suggests your beautiful actions are more important to your rule +#Triggers shortly after succession +fp3_yearly.2030 = { + type = character_event + title = fp3_yearly.2030.t + desc = { + desc = fp3_yearly.2030.desc_intro + # Look in the mirror at your "ugly" feature + first_valid = { + triggered_desc = { + trigger = { has_character_flag = fp3_yearly_2030_beauty_bad } + desc = fp3_yearly.2030.desc_beauty_bad + } + triggered_desc = { + trigger = { has_character_flag = fp3_yearly_2030_spindly } + desc = fp3_yearly.2030.desc_spindly + } + triggered_desc = { + trigger = { has_character_flag = fp3_yearly_2030_disfigured } + desc = fp3_yearly.2030.desc_disfigured + } + triggered_desc = { + trigger = { has_character_flag = fp3_yearly_2030_scaly } + desc = fp3_yearly.2030.desc_scaly + } + triggered_desc = { + trigger = { has_character_flag = fp3_yearly_2030_albino } + desc = fp3_yearly.2030.desc_albino + } + triggered_desc = { + trigger = { has_character_flag = fp3_yearly_2030_hunchbacked } + desc = fp3_yearly.2030.desc_hunchbacked + } + triggered_desc = { + trigger = { has_character_flag = fp3_yearly_2030_inbred } + desc = fp3_yearly.2030.desc_inbred + } + } + desc = fp3_yearly.2030.desc_outro + } + theme = crown + override_background = { + reference = sitting_room + } + left_portrait = { + character = root + animation = worry + } + right_portrait = { + character = scope:reassuring_courtier + animation = personality_compassionate + } + + cooldown = { years = 100 } + + trigger = { + has_fp3_dlc_trigger = yes + is_available_adult = yes + is_landed = yes + OR = { + has_trait = beauty_bad + has_trait = spindly + has_trait = disfigured + has_trait = scaly + has_trait = albino + has_trait = hunchbacked + has_trait = inbred + } + NOR = { + has_trait = callous + has_trait = sadistic + has_trait = beauty_good + } + faith = { + trait_is_virtue = generous + } + } + + immediate = { + # Figure out which ugliness we will pick at + random_list = { + 1 = { + trigger = { has_trait = beauty_bad } + add_character_flag = { + flag = fp3_yearly_2030_beauty_bad + days = 1 + } + } + 1 = { + trigger = { has_trait = spindly } + add_character_flag = { + flag = fp3_yearly_2030_spindly + days = 1 + } + } + 1 = { + trigger = { has_trait = disfigured } + add_character_flag = { + flag = fp3_yearly_2030_disfigured + days = 1 + } + } + 1 = { + trigger = { has_trait = scaly } + add_character_flag = { + flag = fp3_yearly_2030_scaly + days = 1 + } + } + 1 = { + trigger = { has_trait = albino } + add_character_flag = { + flag = fp3_yearly_2030_albino + days = 1 + } + } + 1 = { + trigger = { has_trait = hunchbacked } + add_character_flag = { + flag = fp3_yearly_2030_hunchbacked + days = 1 + } + } + 1 = { + trigger = { has_trait = inbred } + add_character_flag = { + flag = fp3_yearly_2030_inbred + days = 1 + } + } + } + # Figure out which courtier should reassure us + # If we have a lady in waiting, then use her + if = { + limit = { + employs_court_position = lady_in_waiting_court_position + is_available_ai_adult = yes + has_contagious_deadly_disease_trigger = no + } + random_court_position_holder = { + type = lady_in_waiting_court_position + save_scope_as = reassuring_courtier + } + } + # Otherwise, pick court jester + else_if = { + limit = { + employs_court_position = court_jester_court_position + is_available_ai_adult = yes + has_contagious_deadly_disease_trigger = no + } + random_court_position_holder = { + type = court_jester_court_position + save_scope_as = reassuring_courtier + } + } + # Otherwise, pick some (weighted) rando + else = { + random_courtier = { + limit = { + is_available_ai_adult = yes + has_contagious_deadly_disease_trigger = no + } + weight = { + base = 100 + opinion_modifier = { + opinion_target = root + } + modifier = { + has_trait = zealous + add = 50 + } + modifier = { + has_trait = cynical + add = -50 + } + modifier = { + has_trait = generous + add = 50 + } + modifier = { + has_trait = greedy + add = -50 + } + } + save_scope_as = reassuring_courtier + } + } + } + + + option = { # Act generously (even if it is instrumental and not in your nature) + name = fp3_yearly.2030.a + trigger = { + NOT = { has_trait = generous } + } + remove_short_term_gold = medium_gold_value + add_character_modifier = { + modifier = generous_beauty + years = 10 + } + stress_impact = { + greedy = major_stress_impact_gain + arrogant = minor_stress_impact_gain + deceitful = minor_stress_impact_gain + callous = minor_stress_impact_gain + temperate = minor_stress_impact_loss + } + ai_chance = { + base = 100 + } + } + + option = { # Actions will speak louder than words + name = fp3_yearly.2030.d + add_prestige = minor_prestige_value + stress_impact = { + base = medium_stress_impact_gain + wrathful = medium_stress_impact_gain + impatient = minor_stress_impact_gain + temperate = minor_stress_impact_loss + trusting = minor_stress_impact_loss + humble = minor_stress_impact_loss + } + ai_chance = { + base = 100 + } + } + + option = { # Bask in your generosity + name = fp3_yearly.2030.b + trigger = { + has_trait = generous + } + trait = generous + add_prestige = medium_prestige_gain + give_nickname = nick_the_beautiful_generous + remove_short_term_gold = medium_gold_value + add_character_modifier = { + modifier = generous_beauty + years = 10 + } + stress_impact = { + generous = major_stress_impact_loss + arrogant = minor_stress_impact_loss + temperate = minor_stress_impact_loss + deceitful = minor_stress_impact_gain + callous = minor_stress_impact_gain + } + ai_chance = { + base = 100 + } + } + + option = { # Gain dread + name = fp3_yearly.2030.c + add_dread = medium_dread_gain + scope:reassuring_courtier = { + add_opinion = { + target = root + modifier = disappointed_opinion + opinion = -15 + } + } + imprison_character_effect = { #We kill the messenger, so to speak + TARGET = scope:reassuring_courtier + IMPRISONER = root + } + add_character_modifier = { + modifier = dreaded_beauty + } + stress_impact = { + compassionate = medium_stress_impact_gain + just = minor_stress_impact_gain + content = minor_stress_impact_gain + craven = minor_stress_impact_gain + humble = minor_stress_impact_gain + generous = minor_stress_impact_gain + deceitful = minor_stress_impact_loss + callous = minor_stress_impact_loss + wrathful = minor_stress_impact_loss + vengeful = minor_stress_impact_loss + } + ai_chance = { + base = 50 + modifier = { + has_trait = compassionate + factor = 0 + } + modifier = { + has_trait = content + factor = 0 + } + modifier = { + has_trait = just + factor = 0 + } + modifier = { + has_trait = humble + factor = 0 + } + } + } +} + +# Checks whether any of the character's provinces recognize the caliph as their HOF +# Madrasas: Check if root has any valid members of madrasas. If so, trigger ongoing_madrasas_events +fp3_yearly.2060 = { + hidden = yes + + immediate = { + every_courtier = { + limit = { fp3_is_valid_madrasa_pupil = { SPONSOR = root } } + add_to_list = madrasa_pupils + } + house ?= { + every_house_member = { + limit = { + fp3_is_valid_madrasa_pupil = { SPONSOR = root } + NOT = { is_courtier_of = root } + } + } + add_to_list = madrasa_pupils + } + + if = { + limit = { any_in_list = { list = madrasa_pupils } } + trigger_event = { on_action = ongoing_madrasas_events } + } + else = { + add_trait = giant + } + } +} + +# Madrasas: Learning skill increased +fp3_yearly.2061 = { + hidden = yes + + # This event is more likely to trigger if you have more madrasa pupils + weight_multiplier = { + base = 1 + modifier = { + add = { + value = list_size:madrasa_pupils + subtract = 1 + } + } + } + + immediate = { + random_in_list = { + list = madrasa_pupils + weight = { + base = 1 + # Skilled members are more likely to have their stats improved + modifier = { + add = { + value = learning + multiply = 0.1 + } + } + # Learning education members are more likely to gain more learning + modifier = { + has_focus = education_learning + add = 2 + } + # AI energy (Diligent, lazy, etc.) + modifier = { + ai_energy <= high_negative_ai_value + add = -2 + } + modifier = { + ai_energy >= high_positive_ai_value + add = 2 + } + } + save_scope_as = improved_youth + } + send_interface_message = { + type = event_learning_good + title = { + first_valid = { + # Call them madrasas if our capital is advanced enough + triggered_desc = { + trigger = { + capital_county ?= { + development_level >= bad_development_level + } + } + desc = fp3_yearly.2060.t_madrasas + } + # Otherwise just say that the youth are being educated in houses of worship + desc = fp3_yearly.2060.t_houses_of_worship + } + } + left_icon = scope:improved_youth + scope:improved_youth = { add_learning_skill = 2 } + } + } +} + +# Madrasas: Physician experience gain +fp3_yearly.2062 = { + hidden = yes + + # This event is more likely to trigger if you have more futuwaa members + weight_multiplier = { + base = 1 + modifier = { + add = { + value = list_size:madrasa_pupils + subtract = 1 + } + } + } + + immediate = { + random_in_list = { + list = madrasa_pupils + weight = { + base = 1 + # Members w/high learning are more likely to gain physician experience + modifier = { + add = { + value = learning + multiply = 0.1 + } + } + # AI energy (Diligent, lazy, etc.) + modifier = { + ai_energy <= high_negative_ai_value + add = -2` + } + modifier = { + ai_energy >= high_positive_ai_value + add = 2 + } + } + save_scope_as = improved_youth + } + send_interface_message = { + type = event_learning_good + # "Madrasas" vs "Schooling in Mosques" + title = { + first_valid = { + # Call them madrasas if our capital is advanced enough + triggered_desc = { + trigger = { + capital_county ?= { + development_level >= bad_development_level + } + } + desc = fp3_yearly.2060.t_madrasas + } + # Otherwise just say that the youth are being educated in houses of worship + desc = fp3_yearly.2060.t_houses_of_worship + } + } + left_icon = scope:improved_youth + scope:improved_youth = { + if = { + limit = { has_trait = lifestyle_physician } + add_trait_xp = { + trait = lifestyle_physician + value = { + integer_range = { + min = 5 + max = 10 + } + } + } + } + else = { add_trait = lifestyle_physician } + } + } + } +} diff --git a/events/dlc/fp3/fp3_yearly_events_hugo.txt b/events/dlc/fp3/fp3_yearly_events_hugo.txt new file mode 100644 index 0000000000..116c57413e --- /dev/null +++ b/events/dlc/fp3/fp3_yearly_events_hugo.txt @@ -0,0 +1,272 @@ +namespace = fp3_h_yearly + +################################### +# You have pissed off your ulema and you're a drunkard +# By Hugo Cortell +# Rewritten by Henrik Lohmander +################################### +fp3_h_yearly.0001 = { + type = character_event + title = fp3_h_yearly.0001.t + desc = { + triggered_desc = { + trigger = { always = yes } + desc = fp3_h_yearly.0001.desc.main + } + } + theme = feast_activity + override_background = { reference = throne_room } + left_portrait = { + character = root + animation = drink_goblet + } + right_portrait = { + character = scope:ulema_member + animation = disapproval + } + + cooldown = { years = 10 } + + weight_multiplier = { + base = 1 + + modifier = { + exists = cp:councillor_court_chaplain + cp:councillor_court_chaplain = { has_trait = drunkard } + factor = 0.4 + } + } + + trigger = { + has_fp3_dlc_trigger = yes + has_trait = drunkard + NOT = { has_character_modifier = ulema_displeased_drinking } + exists = cp:councillor_court_chaplain + NOT = { + has_hook = cp:councillor_court_chaplain + } + cp:councillor_court_chaplain = { + is_ai = yes + faith = { trait_is_sin = drunkard } + trigger_if = { + limit = { exists = house } + NOT = { house = root.house } + } + NOT = { + has_trait = lifestyle_mystic + } + OR = { + opinion = { # They will not do this unless they have reason to dislike you + target = root + value < -25 + } + has_relation_rival = root + } + } + } + + immediate = { + cp:councillor_court_chaplain = { save_scope_as = ulema_member } + save_scope_as = actor + scope:ulema_member = { save_scope_as = recipient } + } + + option = { #Deflection (They are a drunkard too) Look who is talking! + name = fp3_h_yearly.0001.a + trigger = { scope:ulema_member = { has_trait = drunkard } } + + #No duel, this deflection always succeeds. + + stress_impact = { + craven = minor_stress_gain + deceitful = minor_stress_loss + callous = minor_stress_loss + } + add_prestige = medium_prestige_gain + reverse_add_opinion = { + target = scope:ulema_member + modifier = ignored_concerns + } + } + + option = { #Deflection - Argue that drinking is healthy to the human spirit + name = fp3_h_yearly.0001.b + trigger = { + OR = { + has_trait = scholar + has_trait = theologian + has_trait = whole_of_body + has_trait = lifestyle_physician + has_trait = poet + faith = { trait_is_virtue = drunkard } + } + } + + + reverse_add_opinion = { + target = scope:ulema_member + modifier = ignored_concerns + } + + duel = { + desc = fp3_h_yearly.0001.b.desc + skill = learning + target = scope:annoying_clergy + + 35 = { #Success + desc = fp3_h_yearly.0001.b.success + compare_modifier = { + value = scope:duel_value + multiplier = 3.5 + min = -49 + } + send_interface_toast = { + type = event_toast_effect_good + title = fp3_h_yearly.0001.b.success + left_icon = root + add_prestige = minor_prestige_gain + } + } + 65 = { + desc = fp3_h_yearly.0001.b.failure + compare_modifier = { + value = scope:duel_value + multiplier = -3.5 + min = -49 + } + send_interface_toast = { + title = fp3_h_yearly.0001.b.failure + left_icon = root + add_piety = medium_piety_loss + add_character_modifier = { + modifier = ulema_displeased_drinking + years = 10 + } + } + } + } + + stress_impact = { + honest = minor_stress_gain + humble = minor_stress_gain + callous = minor_stress_loss + deceitful = minor_stress_loss + } + } + + option = { # You do not get to speak to me in this way! + name = fp3_h_yearly.0001.e + + add_dread = medium_dread_gain + imprison_court_chaplain_consequences_effect = yes + imprison_character_effect = { + TARGET = scope:recipient + IMPRISONER = scope:actor + } + + stress_impact = { + just = medium_stress_gain + zealous = medium_stress_gain + deceitful = minor_stress_loss + callous = minor_stress_loss + } + } + + option = { #Bribery - Offer a generous donation + name = fp3_h_yearly.0001.c + trigger = { NOT = { scope:ulema_member = { has_trait = drunkard } } } #If you can deflect we don't show this option + custom_tooltip = fp3_h_yearly.0001.c.tt + pay_short_term_gold = { + target = scope:ulema_member + gold = medium_gold_value + } + random_list = { + 75 = { + modifier = { + scope:ulema_member = { + has_trait = greedy + } + factor = 2 + } + modifier = { + scope:ulema_member = { + has_trait = deceitful + } + factor = 2 + } + modifier = { + scope:ulema_member = { + has_trait = ambitious + } + factor = 2 + } + desc = fp3_h_yearly.0001.c.success + send_interface_toast = { + title = fp3_h_yearly.0001.c.success + left_icon = root + add_prestige = minor_prestige_gain + } + } + 25 = { + modifier = { + scope:ulema_member = { + has_trait = zealous + } + factor = 2 + } + modifier = { + scope:ulema_member = { + has_trait = honest + } + factor = 2 + } + modifier = { + scope:ulema_member = { + has_trait = just + } + factor = 2 + } + desc = fp3_h_yearly.0001.c.failure + send_interface_toast = { + title = fp3_h_yearly.0001.c.failure + left_icon = root + add_piety = medium_piety_loss + add_character_modifier = { + modifier = ulema_displeased_drinking + years = 10 + } + reverse_add_opinion = { + target = scope:ulema_member + modifier = ignored_concerns + } + } + } + } + + + stress_impact = { + just = medium_stress_gain + greedy = minor_stress_gain + honest = minor_stress_gain + callous = minor_stress_loss + deceitful = minor_stress_loss + } + } + + option = { # There is nothing I can do! + name = fp3_h_yearly.0001.d + + add_piety = minor_piety_loss + add_character_modifier = { + modifier = ulema_displeased_drinking + years = 5 + } + stress_impact = { + arrogant = minor_stress_gain + deceitful = minor_stress_gain + drunkard = minor_stress_gain + honest = minor_stress_loss + } + } + +} diff --git a/events/dlc/fp3/fp3_yearly_events_ola_batch_1.txt b/events/dlc/fp3/fp3_yearly_events_ola_batch_1.txt new file mode 100644 index 0000000000..dd7e3cac6b --- /dev/null +++ b/events/dlc/fp3/fp3_yearly_events_ola_batch_1.txt @@ -0,0 +1 @@ +# Warcraft \ No newline at end of file diff --git a/events/dlc/fp3/fp3_yearly_frontier_chains.txt b/events/dlc/fp3/fp3_yearly_frontier_chains.txt new file mode 100644 index 0000000000..dd7e3cac6b --- /dev/null +++ b/events/dlc/fp3/fp3_yearly_frontier_chains.txt @@ -0,0 +1 @@ +# Warcraft \ No newline at end of file diff --git a/events/education_and_childhood/child_personality_events.txt b/events/education_and_childhood/child_personality_events.txt index 96a65db09b..61254e9c25 100644 --- a/events/education_and_childhood/child_personality_events.txt +++ b/events/education_and_childhood/child_personality_events.txt @@ -1123,6 +1123,16 @@ child_personality.0004 = { has_trait = greedy } } + modifier = { + add = 5 + culture = { + has_cultural_parameter = diligent_trait_more_common + } + NOR = { + has_trait = diligent + has_trait = lazy + } + } } immediate = { @@ -1224,6 +1234,12 @@ child_personality.0004 = { has_trait = lazy } } + modifier = { + add = 100 + culture = { + has_cultural_parameter = diligent_trait_more_common + } + } } add_trait = diligent if = { @@ -8806,10 +8822,11 @@ child_personality.3000 = { hidden = yes trigger = { - # Warcraft - age = age_3_value - - number_of_personality_traits < 1 + age = 3 + any_character_trait = { + has_trait_category = childhood + count = 0 + } } immediate = { diff --git a/events/education_and_childhood/childhood_education_events.txt b/events/education_and_childhood/childhood_education_events.txt index 17bf4a775a..392d982e41 100644 --- a/events/education_and_childhood/childhood_education_events.txt +++ b/events/education_and_childhood/childhood_education_events.txt @@ -1,17 +1,17 @@ -#Education events for children +# Education events for children namespace = childhood_education #################################################################### -#0002: Acquire education points -#9001: Assign education focus -#9100: Remove guardian opinions when guardian/ward relation ends +# 0002 = Acquire education points +# 1000 = Religious and Cultural Conversion +# 9001 = Assign education focus +# 9100 = Remove guardian opinions when guardian/ward relation ends ################################################################### - -#Notification event for educator about child switching focus +# Notification event for educator about child switching focus childhood_education.0004 = { type = character_event title = childhood_education.0004.t @@ -287,7 +287,6 @@ childhood_education.0007 = { # 1000+ # System by Petter Vilberg ######################## - childhood_education.1001 = { hidden = yes @@ -296,7 +295,7 @@ childhood_education.1001 = { type = guardian OR = { AND = { - has_relation_flag = { + has_relation_flag = { target = root relation = ward flag = convert_faith @@ -332,9 +331,7 @@ childhood_education.1001 = { NOT = { faith = scope:guardian.faith } } if = { - limit = { - has_variable = education_faith_conversion_chance - } + limit = { has_variable = education_faith_conversion_chance } change_variable = { name = education_faith_conversion_chance add = 20 @@ -366,9 +363,7 @@ childhood_education.1001 = { NOT = { culture = scope:guardian.culture } } if = { - limit = { - has_variable = education_culture_conversion_chance - } + limit = { has_variable = education_culture_conversion_chance } change_variable = { name = education_culture_conversion_chance add = 10 @@ -389,36 +384,34 @@ childhood_education.1001 = { } } - #Check if a conversion event should be fired + # Check if a conversion event should be fired if = { limit = { exists = scope:convert_faith exists = scope:convert_culture } - #Send event about converting both + # Send event about converting both trigger_event = { id = childhood_education.1011 days = { 1 100 } } } + else_if = { - limit = { - exists = scope:convert_faith - } + limit = { exists = scope:convert_faith } - #Send event about converting faith + # Send event about converting faith trigger_event = { id = childhood_education.1021 days = { 1 100 } } } + else_if = { - limit = { - exists = scope:convert_culture - } + limit = { exists = scope:convert_culture } - #Send event about converting culture + # Send event about converting culture trigger_event = { id = childhood_education.1031 days = { 1 100 } @@ -428,7 +421,7 @@ childhood_education.1001 = { } -#Double conversion +# Double conversion childhood_education.1011 = { type = character_event title = childhood_education.1011.t @@ -467,7 +460,7 @@ childhood_education.1011 = { } } -#Message to Guardian +# Message to Guardian childhood_education.1012 = { type = character_event title = childhood_education.1012.t @@ -553,7 +546,7 @@ childhood_education.1012 = { } -#Convert Faith +# Convert Faith childhood_education.1021 = { type = character_event title = childhood_education.1021.t @@ -584,7 +577,7 @@ childhood_education.1021 = { } } -#Message to Guardian +# Message to Guardian childhood_education.1022 = { type = character_event title = childhood_education.1022.t @@ -657,7 +650,7 @@ childhood_education.1022 = { } -#Convert Culture +# Convert Culture childhood_education.1031 = { type = character_event title = childhood_education.1031.t @@ -688,7 +681,7 @@ childhood_education.1031 = { } } -#Message to Guardian +# Message to Guardian childhood_education.1032 = { type = character_event title = childhood_education.1032.t @@ -760,7 +753,6 @@ childhood_education.1032 = { } } - ######################### ## ## EDUCATION MAINTENANCE @@ -773,9 +765,7 @@ childhood_education.9001 = { immediate = { add_character_flag = natural_education_progression if = { - limit = { - has_education_focus_trigger = no - } + limit = { has_education_focus_trigger = no } set_default_education = yes } } @@ -786,18 +776,14 @@ childhood_education.9001 = { childhood_education.9002 = { hidden = yes - immediate = { - education_point_acquisition_effect = yes - } + immediate = { education_point_acquisition_effect = yes } } #Patronage-focused / scholarly spouse may add points childhood_education.9003 = { hidden = yes - immediate = { - add_patronage_spouse_education_points_effect = yes - } + immediate = { add_patronage_spouse_education_points_effect = yes } } # Pedagogy effect diff --git a/events/error_suppression_events.txt b/events/error_suppression_events.txt index 2865660455..08cde8a6f5 100644 --- a/events/error_suppression_events.txt +++ b/events/error_suppression_events.txt @@ -17,6 +17,9 @@ error_suppression.0001 = { add_character_modifier = { modifier = matilda_of_canossa_modifier } + add_character_modifier = { + modifier = police_chief_of_baghdad_modifier + } add_character_modifier = { modifier = fel_corruption_modifier } diff --git a/events/factions/faction_demands.txt b/events/factions/faction_demands.txt index 345e51fba9..b8ef198e12 100644 --- a/events/factions/faction_demands.txt +++ b/events/factions/faction_demands.txt @@ -21,6 +21,9 @@ faction_demand.0001 = { option = { name = "FACTION_DEMAND_ACCEPT" + # This effect should always be placed here, _before_ all the other effects in the block. + trigger_event = { on_action = on_faction_demand_accepted } + root = { save_scope_as = faction_target add_dread = medium_dread_loss @@ -138,6 +141,9 @@ faction_demand.0001 = { option = { name = "FACTION_DEMAND_REFUSE" + # This effect should always be placed here, _before_ all the other effects in the block. + trigger_event = { on_action = on_faction_demand_rejected } + show_as_tooltip = { scope:faction = { faction_start_war = {} @@ -147,7 +153,26 @@ faction_demand.0001 = { root = { save_scope_as = faction_target } - + if = { + limit = { + scope:faction = { + faction_is_type = independence_faction + } + } + scope:faction = { + every_faction_member = { + custom = custom.all_faction_members_same_dynasty + save_scope_as = char_temp + add_clan_unity_interaction_effect = { + CHARACTER = scope:char_temp + TARGET = root + VALUE = medium_unity_loss + DESC = clan_unity_joined_independence_faction.desc + REVERSE_NON_HOUSE_TARGET = no + } + } + } + } scope:faction_leader = { trigger_event = faction_demand.0003 } @@ -271,6 +296,9 @@ faction_demand.0101 = { option = { name = "FACTION_DEMAND_ACCEPT" + # This effect should always be placed here, _before_ all the other effects in the block. + trigger_event = { on_action = on_faction_demand_accepted } + add_dread = medium_dread_loss # Warcraft @@ -293,6 +321,9 @@ faction_demand.0101 = { destroy_faction = yes } + # This effect should always be placed here, _after_ everything except the ai_chance. + trigger_event = { on_action = on_faction_demand_accepted } + ai_chance = { base = 10 modifier = { @@ -334,6 +365,9 @@ faction_demand.0101 = { option = { name = "FACTION_DEMAND_REFUSE" + # This effect should always be placed here, _before_ all the other effects in the block. + trigger_event = { on_action = on_faction_demand_rejected } + show_as_tooltip = { scope:faction = { faction_start_war = {} @@ -491,6 +525,9 @@ faction_demand.1001 = { option = { name = "FACTION_DEMAND_POPULIST_ACCEPT_CONVERT" + # This effect should always be placed here, _before_ all the other effects in the block. + trigger_event = { on_action = on_faction_demand_accepted } + trigger = { # If more than 30% of your realm belongs to the revolting culture or faith, you get the option to switch to it. OR = { @@ -646,6 +683,9 @@ faction_demand.1001 = { is_ai = yes } } + + # This effect should always be placed here, _before_ all the other effects in the block. + trigger_event = { on_action = on_faction_demand_accepted } add_prestige_level = -1 if = { @@ -759,6 +799,10 @@ faction_demand.1001 = { # Option C: Refuse the demand and start a war. option = { name = "FACTION_DEMAND_POPULIST_REFUSE" + + # This effect should always be placed here, _before_ all the other effects in the block. + trigger_event = { on_action = on_faction_demand_rejected } + scope:faction = { faction_start_war = { title = scope:target_title @@ -1399,6 +1443,9 @@ faction_demand.2001 = { option = { name = "FACTION_DEMAND_ACCEPT" + # This effect should always be placed here, _before_ all the other effects in the block. + trigger_event = { on_action = on_faction_demand_accepted } + add_dread = medium_dread_loss scope:faction = { @@ -1461,6 +1508,9 @@ faction_demand.2001 = { option = { name = "FACTION_DEMAND_REFUSE" + + # This effect should always be placed here, _before_ all the other effects in the block. + trigger_event = { on_action = on_faction_demand_rejected } root = { save_scope_as = faction_target @@ -1601,7 +1651,7 @@ faction_demand.2005 = { } -# Faction declares a retalitory war. +# Faction declares a retaliatory war. faction_demand.9001 = { type = character_event title = faction_demand.9001.t @@ -1653,6 +1703,9 @@ faction_demand.9001 = { option = { name = FACTION_IMPRISONMENT_RETALIATION_OPT + + # This effect should always be placed here, _before_ all the other effects in the block. + trigger_event = { on_action = on_faction_demand_rejected } } } @@ -1673,6 +1726,9 @@ faction_demand.1000 = { option = { name = "FACTION_DEMAND_ACCEPT" + # This effect should always be placed here, _before_ all the other effects in the block. + trigger_event = { on_action = on_faction_demand_accepted } + root = { save_scope_as = faction_target add_dread = medium_dread_loss @@ -1824,6 +1880,9 @@ faction_demand.1000 = { option = { name = "FACTION_DEMAND_REFUSE" + # This effect should always be placed here, _before_ all the other effects in the block. + trigger_event = { on_action = on_faction_demand_rejected } + show_as_tooltip = { scope:faction = { faction_start_war = {} @@ -1864,6 +1923,7 @@ faction_demand.1000 = { } } } + # Nation Fracturing Demand Accepted faction_demand.1002 = { type = letter_event diff --git a/events/government_events/clan_events.txt b/events/government_events/clan_events.txt index eee41bbf79..5e0e821d75 100644 --- a/events/government_events/clan_events.txt +++ b/events/government_events/clan_events.txt @@ -1142,6 +1142,6 @@ clan.1201 = { REVERSE_NON_HOUSE_TARGET = no } - hidden_effect = { scope:petitioner = { death = { death_reason = death_disappearance } } } + hidden_effect = { scope:petitioner = { override_death_effect = { death_reason = death_disappearance } } } } } diff --git a/events/harm_events.txt b/events/harm_events.txt index b483e2901d..8605a60c7b 100644 --- a/events/harm_events.txt +++ b/events/harm_events.txt @@ -7799,6 +7799,7 @@ harm.1111 = { # Alright, welcome to the world, scope:killer! ## Now you die. scope:killer = { + trigger_race_giving_no_gene_effect = yes override_death_effect = { death_reason = death_slaughtered_by_guards } log_harm_event_death_as_variable_effect = yes } diff --git a/events/lifestyles/intrigue_lifestyle/intrigue_scheming_events.txt b/events/lifestyles/intrigue_lifestyle/intrigue_scheming_events.txt index f9a20a21ae..67eb2b9294 100644 --- a/events/lifestyles/intrigue_lifestyle/intrigue_scheming_events.txt +++ b/events/lifestyles/intrigue_lifestyle/intrigue_scheming_events.txt @@ -3541,10 +3541,16 @@ intrigue_scheming.3061 = { save_scope_as = template create_character = { location = root.capital_province - template = servant_character - gender = male + culture = scope:target.culture + faith = scope:target.faith + template = servant_father_character save_scope_as = commoner_target } + hidden_effect = { + scope:commoner_target = { + change_age = scope:heir.age + } + } # Save target's Spymaster if they exist scope:target = { diff --git a/events/lifestyles/scholarship_lifestyle/learning_scholarship_events.txt b/events/lifestyles/scholarship_lifestyle/learning_scholarship_events.txt index 6596dc2542..08ba430799 100644 --- a/events/lifestyles/scholarship_lifestyle/learning_scholarship_events.txt +++ b/events/lifestyles/scholarship_lifestyle/learning_scholarship_events.txt @@ -412,7 +412,7 @@ learning_scholarship.1401 = { add_learning_lifestyle_xp = major_lifestyle_xp add_character_flag = has_reading_glasses ai_chance = { - base = 75 + base = 5 } } diff --git a/events/lifestyles/warfare_lifestyle/martial_authority_events.txt b/events/lifestyles/warfare_lifestyle/martial_authority_events.txt index 99b8c8b5a0..9b22c2147d 100644 --- a/events/lifestyles/warfare_lifestyle/martial_authority_events.txt +++ b/events/lifestyles/warfare_lifestyle/martial_authority_events.txt @@ -1142,10 +1142,11 @@ martial_authority.2054 = { immediate = { var:is_right_hand_person_of = { + var:right_hand_person = { save_scope_as = right_hand_person } send_interface_message = { type = event_generic_neutral title = martial_authority.2054.toast - left_icon = var:right_hand_person + left_icon = scope:right_hand_person add_character_modifier = { modifier = martial_authority_2050_right_hand_person_modifier } diff --git a/events/lifestyles/warfare_lifestyle/warhorse_events.txt b/events/lifestyles/warfare_lifestyle/warhorse_events.txt index 48d5626e9f..046132d6c6 100644 --- a/events/lifestyles/warfare_lifestyle/warhorse_events.txt +++ b/events/lifestyles/warfare_lifestyle/warhorse_events.txt @@ -634,19 +634,19 @@ warhorse.1001 = { random_list = { 50 = { # nothing happens modifier = { - scope:m_horse.aptitude:master_of_horse_court_position = 5 + scope:m_horse.aptitude:master_of_horse_court_position = 4 factor = 0.1 } modifier = { - scope:m_horse.aptitude:master_of_horse_court_position = 4 + scope:m_horse.aptitude:master_of_horse_court_position = 3 factor = 0.2 } modifier = { - scope:m_horse.aptitude:master_of_horse_court_position = 3 + scope:m_horse.aptitude:master_of_horse_court_position = 2 factor = 0.3 } modifier = { - scope:m_horse.aptitude:master_of_horse_court_position = 2 + scope:m_horse.aptitude:master_of_horse_court_position = 1 factor = 0.5 } send_interface_toast = { diff --git a/events/nickname_events/nickname_events.txt b/events/nickname_events/nickname_events.txt index c86b6f6590..7257fb1956 100644 --- a/events/nickname_events/nickname_events.txt +++ b/events/nickname_events/nickname_events.txt @@ -1022,6 +1022,7 @@ lifestyle_nicknames.0010 = { # Learning nickname when the character is humble has_perk = scholar_perk has_perk = theologian_perk } + exists = cp:councillor_court_chaplain } weight_multiplier = { diff --git a/events/religion_events/faith_conversion_events.txt b/events/religion_events/faith_conversion_events.txt index 81d9fa32c6..dbd2d649ce 100644 --- a/events/religion_events/faith_conversion_events.txt +++ b/events/religion_events/faith_conversion_events.txt @@ -57,7 +57,7 @@ faith_conversion.0002 = { add_character_modifier = fp2_friend_of_the_old_ways_modifier } else = { remove_character_modifier = fp2_champion_of_the_old_ways_modifier } - + # Reset patron deities. if = { limit = { faith = { diff --git a/events/religion_events/faith_creation_events.txt b/events/religion_events/faith_creation_events.txt index 84bf39c0eb..eefa985a46 100644 --- a/events/religion_events/faith_creation_events.txt +++ b/events/religion_events/faith_creation_events.txt @@ -130,6 +130,7 @@ faith_creation.0012 = { else = { create_character = { location = root.capital_province + # Warcraft age = { 30 50 } gender_female_chance = root_faith_clergy_gender_female_chance trait = education_learning_4 diff --git a/events/religion_events/false_conversion_events.txt b/events/religion_events/false_conversion_events.txt index b9070eff0d..d5b66c195c 100644 --- a/events/religion_events/false_conversion_events.txt +++ b/events/religion_events/false_conversion_events.txt @@ -24,7 +24,7 @@ # scope:old_faith = { has_doctrine_parameter = sanctioned_false_conversion } # NOR = { # any_secret = { secret_type = secret_crypto_religionist } -# has_variable = forbid_crypto_reconversion +# #has_variable = forbid_crypto_reconversion # } # } @@ -44,9 +44,9 @@ false_conversion.0002 = { trigger = { scope:old_faith = { has_doctrine_parameter = sanctioned_false_conversion } - NOR = { + NOT = { has_variable = false_convert - has_variable = forbid_crypto_reconversion + #has_variable = forbid_crypto_reconversion } } @@ -167,7 +167,6 @@ false_conversion.0020 = { } } # Fp3 Struggle Catalyst - #Warcraft stress_impact = { zealous = medium_stress_impact_gain #Damn it, I was passionate about my openly-practiced faith! diff --git a/events/scheme_events/intrigue_scheme_ongoing_events.txt b/events/scheme_events/intrigue_scheme_ongoing_events.txt index 2dddcdd7ed..716925d791 100644 --- a/events/scheme_events/intrigue_scheme_ongoing_events.txt +++ b/events/scheme_events/intrigue_scheme_ongoing_events.txt @@ -3650,18 +3650,7 @@ intrigue_scheme_ongoing.5013 = { ########################################### intrigue_scheme_ongoing.5014 = { type = character_event - title = { - first_valid = { - triggered_desc = { - trigger = { - has_fp3_dlc_trigger = yes - culture = { has_cultural_pillar = heritage_iranian } - } - desc = intrigue_scheme_ongoing.5014.t_persian - } - desc = intrigue_scheme_ongoing.5014.t - } - } + title = intrigue_scheme_ongoing.5014.t desc = intrigue_scheme_ongoing.5014.desc theme = generic_intrigue_scheme left_portrait = scope:target @@ -3737,18 +3726,7 @@ intrigue_scheme_ongoing.5014 = { #For target - Accept gift? intrigue_scheme_ongoing.5015 = { type = character_event - title = { - first_valid = { - triggered_desc = { - trigger = { - has_fp3_dlc_trigger = yes - culture = { has_cultural_pillar = heritage_iranian } - } - desc = intrigue_scheme_ongoing.5014.t_persian - } - desc = intrigue_scheme_ongoing.5014.t - } - } + title = intrigue_scheme_ongoing.5014.t desc = intrigue_scheme_ongoing.5015.desc theme = friendly left_portrait = scope:owner diff --git a/events/scheme_events/learn_language_scheme/learn_language_outcome_events.txt b/events/scheme_events/learn_language_scheme/learn_language_outcome_events.txt index 61ab82362a..8963596935 100644 --- a/events/scheme_events/learn_language_scheme/learn_language_outcome_events.txt +++ b/events/scheme_events/learn_language_scheme/learn_language_outcome_events.txt @@ -59,7 +59,6 @@ learn_language_outcome.1000 = { # limit = { # any_character_struggle = { # involvement = involved - # is_struggle_type = iberian_struggle # has_struggle_phase_parameter = learning_languages_gives_piety # } # } @@ -72,7 +71,6 @@ learn_language_outcome.1000 = { # limit = { # any_character_struggle = { # involvement = involved - # is_struggle_type = iberian_struggle # has_struggle_phase_parameter = learning_languages_gives_prestige # } # } @@ -105,6 +103,7 @@ learn_language_outcome.1000 = { # catalyst = catalyst_learned_new_language_important # character = root # } + # log_debug_variable_for_persian_struggle_effect = { VAR = stabil_catalyst_learned_new_language_important } # } #} # End of Warcraft diff --git a/events/scheme_events/murder_scheme/assassination_ongoing_events.txt b/events/scheme_events/murder_scheme/assassination_ongoing_events.txt new file mode 100644 index 0000000000..7cd0da9ddd --- /dev/null +++ b/events/scheme_events/murder_scheme/assassination_ongoing_events.txt @@ -0,0 +1,1249 @@ + +namespace = assassination_ongoing + +#Ongoing Events with Master Assassin #by Ola Jentzsch +########################## +# A Secret Sympathizer +# by Ola Jentzsch +########################## +assassination_ongoing.0001 = { + type = character_event + title = assassination_ongoing.0001.t + desc = assassination_ongoing.0001.desc + theme = generic_intrigue_scheme + left_portrait = { + character = scope:secret_sympathizer + animation = scheme + } + right_portrait = scope:assassin + widget = { + gui = "event_window_widget_scheme" + container = "custom_widgets_container" + } + + trigger = { + any_court_position_holder = { + type = master_assassin_court_position + } + + scope:target = { + any_courtier = { + is_available_ai_adult = yes + OR = { + has_trait = callous + has_trait = deceitful + has_trait = disloyal + has_trait = murderer + faith = { has_doctrine_parameter = sanctioned_assassinations } + } + opinion = { + target = scope:target + value < 0 + } + } + } + + NOT = { exists = scope:scheme.var:had_dark_blessing_event } + } + + immediate = { + + random_court_position_holder = { + type = master_assassin_court_position + save_scope_as = assassin + } + + scope:target = { + random_courtier = { + limit = { + is_available_ai_adult = yes + OR = { + has_trait = callous + has_trait = deceitful + has_trait = disloyal + has_trait = murderer + faith = { has_doctrine_parameter = sanctioned_assassinations } + } + opinion = { + target = scope:target + value < 0 + } + } + save_scope_as = secret_sympathizer + } + } + + + hidden_effect = { + scope:secret_sympathizer = { + if = { + limit = { + NOT = { + faith = { has_doctrine_parameter = sanctioned_assassinations } + } + } + make_character_crypto_religionist_effect = { CRYPTO_RELIGION = scope:owner.faith } + } + } + } + + scope:scheme = { + set_variable = { + name = had_dark_blessing_event + value = yes + days = 3650 + } + } + } + + # Bless them + option = { + name = assassination_ongoing.0001.a + + add_piety = medium_piety_loss + + scope:scheme = { + add_scheme_modifier = { + type = scheme_helpful_sympathizer_modifier + } + } + + scope:secret_sympathizer = { + add_opinion = { + target = scope:owner + opinion = 30 + modifier = fp3_blessed_me_opinion + } + } + + stress_impact = { + arrogant = minor_stress_impact_gain + } + + ai_chance = { + base = 50 + modifier = { + add = 50 + scope:secret_sympathizer = { + intrigue >= medium_skill_rating + } + } + ai_value_modifier = { + ai_zeal = 0.5 + ai_sociability = 0.3 + } + } + } + + # Refuse + option = { + name = assassination_ongoing.0001.b + + flavor = fp3_sympathizer_might_betray_you.flavor + scope:scheme = { + add_scheme_modifier = { type = scheme_untrustworthy_sympathizer_modifier } + } + stress_impact = { + zealous = minor_stress_impact_gain + generous = minor_stress_impact_gain + } + ai_chance = { + base = 50 + ai_value_modifier = { + ai_greed = -0.5 + } + } + } +} + +########################## +# Courting Fanatics +# by Ola Jentzsch +########################## + +assassination_ongoing.0002 = { + type = character_event + title = assassination_ongoing.0002.t + desc = assassination_ongoing.0002.desc + theme = generic_intrigue_scheme + left_portrait = { + character = scope:assassin + animation = personality_greedy + } + right_portrait = { + character = root + triggered_animation = { + trigger = { + OR = { + has_trait = zealous + has_trait = generous + has_trait = gregarious + } + } + animation = happiness + } + animation = dismissal + } + widget = { + gui = "event_window_widget_scheme" + container = "custom_widgets_container" + } + + override_background = { reference = wilderness } + + trigger = { + any_court_position_holder = { + type = master_assassin_court_position + } + + NOT = { exists = scope:scheme.var:had_courting_fanatics_event } + } + + immediate = { + + random_court_position_holder = { + type = master_assassin_court_position + save_scope_as = assassin + } + + scope:scheme = { + set_variable = { + name = had_courting_fanatics_event + value = yes + days = 3650 + } + } + } + + # Pay them + option = { + name = assassination_ongoing.0002.a + + remove_short_term_gold = medium_gold_value + + scope:scheme = { + add_scheme_modifier = { + type = scheme_assassin_recruits_modifier + } + } + + stress_impact = { + greedy = minor_stress_impact_gain + paranoid = medium_stress_impact_gain + } + + ai_chance = { + base = 50 + ai_value_modifier = { + ai_zeal = 0.5 + ai_sociability = 0.5 + ai_greed = -0.9 + } + } + } + + # Refuse + option = { + name = assassination_ongoing.0002.b + + stress_impact = { + zealous = minor_stress_impact_gain + generous = minor_stress_impact_gain + } + ai_chance = { + base = 50 + ai_value_modifier = { + ai_greed = 0.5 + ai_boldness = -0.2 + } + } + } +} + + +####################### +# Gold and God +# by Ola Jentzsch +####################### +# Can pay gold for scheme progress +assassination_ongoing.0003 = { + type = character_event + title = { + first_valid = { + triggered_desc = { + trigger = { faith = { trait_is_sin = greedy } } + desc = assassination_usury_event_title + } + desc = assassination_not_usury_event_title + } + } + desc = { + desc = assassination_ongoing.0003_opening + random_valid = { + desc = assassination_usury_event_scullery_maid_desc + desc = assassination_usury_event_guard_desc + desc = assassination_usury_event_gardener_desc + desc = assassination_usury_event_minor_servant_desc + } + desc = assassination_ongoing.0003.outro + } + theme = generic_intrigue_scheme + widget = { + gui = "event_window_widget_scheme" + container = "custom_widgets_container" + } + left_portrait = { + character = scope:assassin + animation = hunting_knife_start + } + right_portrait = { + character = scope:target + animation = paranoia + } + + trigger = { + any_court_position_holder = { + type = master_assassin_court_position + } + + NOT = { exists = scope:scheme.var:had_usury_assassination_event } + scope:scheme = { + is_scheme_exposed = no + } + } + + immediate = { + + scope:scheme = { + set_variable = { + name = had_usury_assassination_event + value = yes + days = 3650 + } + } + + random_court_position_holder = { + type = master_assassin_court_position + save_scope_as = assassin + } + + scope:assassin = { save_scope_as = agent } #so we can reuse some loc from the murder scheme + } + + option = { #Pay the gold + name = { + trigger = { + faith = { + trait_is_sin = greedy + } + } + text = assassination_ongoing.0003.a + } + name = { + trigger = { + NOT = { + faith = { + trait_is_sin = greedy + } + } + } + text = assassination_ongoing.0003.b + } + + remove_short_term_gold = medium_gold_value + + scope:assassin = { + duel = { + skill = intrigue + value = 10 + 20 = { + desc = intrigue_scheme_ongoing.1008.a.success + compare_modifier = { + value = scope:duel_value + multiplier = 0.75 + min = 0 + } + scope:owner = { + send_interface_toast = { + title = intrigue_scheme_ongoing.1008.a.success + left_icon = scope:agent + scope:scheme = { + add_scheme_modifier = { + type = scheme_assassin_closing_in_modifier + } + } + } + } + } + 10 = { + desc = intrigue_scheme_ongoing.1008.a.failure + compare_modifier = { + value = scope:duel_value + multiplier = -0.5 + min = -14 + } + scope:owner = { + send_interface_toast = { + title = intrigue_scheme_ongoing.1008.a.failure + left_icon = scope:agent + + scope:scheme = { + expose_scheme = yes + } + } + } + } + } + } + + if = { + limit = { + faith = { + trait_is_sin = greedy + } + } + stress_impact = { + base = minor_stress_gain + generous = minor_stress_loss + zealous = medium_stress_gain + } + } + + stress_impact = { + greedy = medium_stress_impact_gain + } + + ai_chance = { + base = 50 + modifier = { + add = 100 + has_trait = generous + } + } + } + + + + + option = { #Save it + name = { + trigger = { + faith = { + trait_is_sin = greedy + } + } + text = assassination_ongoing.0003.c + } + name = { + trigger = { + NOT = { + faith = { + trait_is_sin = greedy + } + } + } + text = intrigue_scheme_ongoing.1001.b + } + + stress_impact = { + impatient = minor_stress_impact_gain + } + ai_chance = { + base = 50 + } + } +} + + +####################### +# A Moment of Doubt +# by Ola Jentzsch +####################### +# Your master assassin is doubting themselves +assassination_ongoing.0004 = { + type = character_event + title = assassination_ongoing.0004.t + desc = { + desc = assassination_ongoing.0004_opening + first_valid = { + triggered_desc = { + trigger = { + has_trait = hashishiyah + } + desc = assassination_doubt_event_hashish_desc + } + triggered_desc = { + trigger = { + has_trait = drunkard + } + desc = assassination_doubt_event_alcohol_desc + } + triggered_desc = { + trigger = { + has_trait = comfort_eater + } + desc = assassination_doubt_event_food_desc + } + triggered_desc = { + trigger = { + has_trait = confider + } + desc = assassination_doubt_event_confide_desc + } + triggered_desc = { + trigger = { + has_trait = rakish + } + desc = assassination_doubt_event_orgy_desc + } + triggered_desc = { + trigger = { + OR = { + faith = { has_doctrine_parameter = meditation_mechanics_active } + #has_character_modifier = fp3_sufi_initiate_modifier + has_trait = calm + } + } + desc = assassination_doubt_event_meditation_desc + } + desc = assassin_doubt_event_nothing_else + } + } + theme = generic_intrigue_scheme + widget = { + gui = "event_window_widget_scheme" + container = "custom_widgets_container" + } + left_portrait = { + character = scope:assassin + animation = worry + triggered_animation = { + trigger = { + OR = { + ai_zeal >= high_positive_ai_value + ai_boldness >= high_positive_ai_value + } + } + animation = paranoia + } + } + right_portrait = { + character = scope:owner + animation = thinking + } + + trigger = { + any_court_position_holder = { + type = master_assassin_court_position + } + + NOT = { exists = scope:scheme.var:had_doubt_event } + } + + immediate = { + + random_court_position_holder = { + type = master_assassin_court_position + save_scope_as = assassin + } + + scope:scheme = { + set_variable = { + name = had_doubt_event + value = yes + days = 3650 + } + } + } + + + option = { + + name = { + trigger = { + has_trait = hashishiyah + } + text = assassination_ongoing.0003.c_hashish + } + name = { + trigger = { + has_trait = drunkard + } + text = assassination_ongoing.0003.c_alcohol + } + name = { + trigger = { + has_trait = comfort_eater + } + text = assassination_ongoing.0003.c_food + } + name = { + trigger = { + has_trait = confider + } + text = assassination_ongoing.0003.c_confide + } + name = { + trigger = { + has_trait = rakish + } + text = assassination_ongoing.0003.c_orgy + } + name = { + trigger = { + OR = { + faith = { has_doctrine_parameter = meditation_mechanics_active } + #has_character_modifier = fp3_sufi_initiate_modifier + has_trait = calm + } + } + text = assassination_ongoing.0003.c_meditation + } + + trigger = { + OR = { + has_trait = hashishiyah + has_trait = drunkard + has_trait = comfort_eater + has_trait = confider + has_trait = rakish + OR = { + faith = { has_doctrine_parameter = meditation_mechanics_active } + #has_character_modifier = fp3_sufi_initiate_modifier + has_trait = calm + } + } + } + + scope:scheme = { + add_scheme_modifier = { + type = scheme_strengthened_resolve_modifier + } + add_scheme_progress = 1 + } + custom_tooltip = high_risk_of_dying.tt + + scope:assassin = { + if = { + limit = { + NOT = { has_relation_friend = scope:owner } + } + scope:owner = { + progress_towards_friend_effect = { + CHARACTER = scope:assassin + REASON = friend_reaffirmed_assassin + OPINION = 25 + } + } + } + else = { + add_opinion = { + target = scope:owner + opinion = 40 + modifier = respect_opinion + } + } + } + + stress_impact = { + compassionate = medium_stress_impact_gain #hey, you should want to die! + } + + ai_chance = { #zealous yet social AI will do this + base = 100 + ai_value_modifier = { + ai_zeal = 1 + ai_sociability = 1 + ai_compassion = -1 + } + } + } + + option = { + name = assassination_ongoing.0004.b #skill challenge + + duel = { + skill = diplomacy + value = medium_skill_rating + + 20 = { + compare_modifier = { + value = scope:duel_value + multiplier = 2 + } + send_interface_toast = { + title = assassination_console_toast.success + left_icon = scope:assassin + + custom_tooltip = assassination_console.success + + add_piety = medium_piety_gain + + scope:scheme = { + add_scheme_modifier = { + type = scheme_strengthened_resolve_modifier + } + add_scheme_progress = 1 + } + custom_tooltip = high_risk_of_dying.tt + } + } + 20 = { + compare_modifier = { + value = scope:duel_value + multiplier = -1 + } + scope:owner = { + send_interface_toast = { + title = assassination_console_toast.failure + left_icon = root + + custom_tooltip = assassination_console.failure + + scope:scheme = { + add_scheme_modifier = { + type = scheme_weakened_resolve_modifier + } + } + } + } + } + } + + stress_impact = { + compassionate = medium_stress_impact_gain + } + + ai_chance = { #zealous yet energetic AI will do this. Plus, it's mutually exclusive with the first option anyhow. + base = 100 + ai_value_modifier = { + ai_zeal = 1 + ai_energy = 1 + ai_compassion = -1 + } + } + } + + option = { + name = assassination_ongoing.0004.c + + scope:scheme = { + end_scheme = yes + } + + stress_impact = { + compassionate = medium_stress_impact_loss + trusting = minor_stress_impact_loss + callous = minor_stress_impact_gain + zealous = medium_stress_impact_gain + ambitious = minor_stress_impact_gain + sadistic = minor_stress_impact_gain + stubborn = minor_stress_impact_gain + vengeful = medium_stress_impact_gain + } + + ai_chance = { #loving, non-zealous AI will do this + base = 50 + ai_value_modifier = { + ai_compassion = 1 + ai_zeal = -1 + ai_boldness = -0.5 + } + } + } +} + + +########################## +# Poison or Pestilence +# by Ola Jentzsch +########################## +assassination_ongoing.0005 = { + type = character_event + title = assassination_ongoing.0005.t + desc = assassination_ongoing.0005.desc + theme = medicine + + left_portrait = { + character = scope:assassin + animation = hunting_knife_start + } + right_portrait = { + character = root + animation = thinking + } + widget = { + gui = "event_window_widget_scheme" + container = "custom_widgets_container" + } + + trigger = { + any_court_position_holder = { + type = master_assassin_court_position + } + + NOT = { exists = scope:scheme.var:had_poison_event } + } + + immediate = { + + random_court_position_holder = { + type = master_assassin_court_position + save_scope_as = assassin + } + + scope:scheme = { + set_variable = { + name = had_poison_event + value = yes + days = 3650 + } + } + } + + # Herbalism! + option = { + name = { + trigger = { + has_trait = lifestyle_herbalist + } + text = assassination_ongoing.0005.a_you + } + name = { + trigger = { + scope:assassin = { has_trait = lifestyle_herbalist } + } + text = assassination_ongoing.0005.a_them + } + + trigger = { + OR = { + has_trait = lifestyle_herbalist + scope:assassin = { has_trait = lifestyle_herbalist } + } + } + + scope:scheme = { + add_scheme_modifier = { + type = scheme_poisoned_blade_modifier + } + } + + stress_impact = { + lazy = minor_stress_impact_gain + } + + ai_chance = { #AI will do this if they can + base = 100 + ai_value_modifier = { + ai_zeal = 1 + ai_energy = 2 + } + } + } + + # Gold! + option = { + name = assassination_ongoing.0005.b + + trigger = { + NOR = { + has_trait = lifestyle_herbalist + scope:assassin = { has_trait = lifestyle_herbalist } + } + } + + remove_short_term_gold = minor_gold_value + + scope:scheme = { + add_scheme_modifier = { + type = scheme_poisoned_blade_modifier + } + } + + stress_impact = { + greedy = minor_stress_impact_gain + } + + ai_chance = { #some AI are hesitant to spend money on this + base = 100 + ai_value_modifier = { + ai_zeal = 1 + ai_vengefulness = 0.9 + ai_greed = -0.9 + } + } + } + + # Cheap natural poison! + option = { + name = assassination_ongoing.0005.c + + scope:scheme = { + add_scheme_modifier = { + type = scheme_pestilent_blade_modifier + } + } + + scope:assassin = { + add_opinion = { + target = scope:owner + opinion = -20 + modifier = frustrated_opinion + } + } + + stress_impact = { + gallant = medium_stress_impact_gain + generous = minor_stress_impact_gain + arrogant = minor_stress_impact_gain + } + + ai_chance = { #this is the cheapskate option + base = 100 + ai_value_modifier = { + ai_greed = 0.8 + ai_rationality = 1 + ai_zeal = -0.3 + } + } + } + + # Beneath us! + option = { + name = assassination_ongoing.0005.d + + scope:scheme = { add_scheme_progress = scheme_progress_gain } + + scope:assassin = { + add_opinion = { + target = scope:owner + opinion = 20 + modifier = respect_opinion + } + } + + stress_impact = { + cynical = minor_stress_impact_gain + generous = minor_stress_impact_gain + vengeful = minor_stress_impact_gain + } + + ai_chance = { #this is the "honorable" option + base = 100 + ai_value_modifier = { + ai_honor = 0.8 + ai_rationality = -0.3 + ai_zeal = -0.5 + } + } + } +} + +########################## +# Runaway Assassin +# by Ola Jentzsch +########################## +assassination_ongoing.0006 = { + type = character_event + title = assassination_ongoing.0006.t + desc = assassination_ongoing.0006.desc + theme = generic_intrigue_scheme + left_portrait = { + character = scope:target + animation = paranoia + } + lower_right_portrait = { + character = scope:assassin + } + widget = { + gui = "event_window_widget_scheme" + container = "custom_widgets_container" + } + + trigger = { + any_court_position_holder = { + type = master_assassin_court_position + } + + NOT = { exists = scope:scheme.var:had_faltering_assassin_event } + } + + immediate = { + + random_court_position_holder = { + type = master_assassin_court_position + save_scope_as = assassin + } + + scope:scheme = { + set_variable = { + name = had_faltering_assassin_event + value = yes + days = 3650 + } + } + + scope:scheme = { + add_scheme_modifier = { + type = scheme_renegade_assassin_modifier + } + } + + random_dummy_gender_assassin_effect = yes #to set a gender in the loc for the unscoped assassin + } + + option = { + name = assassination_ongoing.0006.a + + duel = { + skill = intrigue + value = medium_skill_rating + + 20 = { + compare_modifier = { + value = scope:duel_value + multiplier = 2 + } + send_interface_toast = { + title = assassination_hunted_down_toast.success + left_icon = scope:assassin + + custom_tooltip = assassination_hunted_down.success + + add_dread = medium_dread_gain + + scope:scheme = { + remove_scheme_modifier = scheme_renegade_assassin_modifier + } + } + } + 20 = { + compare_modifier = { + value = scope:duel_value + multiplier = -1 + } + scope:owner = { + send_interface_toast = { + title = assassination_hunted_down_toast.failure + left_icon = root + + custom_tooltip = assassination_hunted_down.failure + + add_prestige = minor_prestige_loss + + } + } + } + } + + stress_impact = { + lazy = major_stress_impact_gain + compassionate = major_stress_impact_gain + trusting = medium_stress_impact_gain + forgiving = medium_stress_impact_gain + } + + ai_chance = { + base = 100 + ai_value_modifier = { + ai_vengefulness = 1 + ai_rationality = 0.3 + ai_compassion = -1 + } + } + } + + option = { + name = assassination_ongoing.0006.b + + stress_impact = { + vengeful = major_stress_impact_gain + paranoid = major_stress_impact_gain + callous = minor_stress_impact_gain + sadistic = minor_stress_impact_gain + } + + ai_chance = { #this is the "honorable" option + base = 100 + ai_value_modifier = { + ai_honor = 0.8 + ai_rationality = -0.7 + ai_vengefulness = -1 + } + } + } +} + +scripted_trigger righteous_target_trigger = { + has_religion = scope:temporary_assassin.religion + num_sinful_traits = 0 + OR = { + piety_level >= 3 + AND = { + piety_level >= 2 + ai_honor >= medium_positive_ai_value + } + } + OR = { + num_virtuous_traits >= 1 + reverse_opinion = { + target = scope:temporary_assassin + value > 50 + } + } +} + +########################## +# A Man/Woman of Virtue +# by Ola Jentzsch +########################## +assassination_ongoing.0007 = { + type = character_event + title = assassination_ongoing.0007.t + desc = assassination_ongoing.0007.desc + theme = generic_intrigue_scheme + + left_portrait = { + character = scope:target + triggered_animation = { + trigger = { + ai_honor >= high_positive_ai_value + } + animation = personality_honorable + } + triggered_animation = { + trigger = { + ai_zeal >= high_positive_ai_value + } + animation = personality_zealous + } + triggered_animation = { + trigger = { + ai_greed < low_positive_ai_value + } + animation = personality_compassionate + } + animation = paranoia + } + right_portrait = { + character = scope:assassin + triggered_animation = { + trigger = { + ai_vengefulness >= medium_positive_ai_value + } + animation = stress + } + animation = worry + } + widget = { + gui = "event_window_widget_scheme" + container = "custom_widgets_container" + } + + trigger = { + NOT = { exists = scope:scheme.var:had_righteous_target_event } + + any_court_position_holder = { + type = master_assassin_court_position + save_temporary_scope_as = temporary_assassin + } + + scope:temporary_assassin = { + NOR = { + ai_zeal < low_positive_ai_value + opinion = { + target = scope:target + value < -50 + } + } + } + + scope:target = { + righteous_target_trigger = yes + } + } + + immediate = { + + random_court_position_holder = { + type = master_assassin_court_position + save_scope_as = assassin + } + + scope:scheme = { + set_variable = { + name = had_righteous_target_event + value = yes + days = 3650 + } + } + } + + option = { + name = assassination_ongoing.0007.a + + scope:scheme = { add_scheme_progress = scheme_progress_gain } + + add_dread = minor_dread_gain + + scope:assassin = { + add_opinion = { + target = root + modifier = fp3_dismayed_opinion + } + } + custom_tooltip = high_risk_of_dying.tt + + stress_impact = { + craven = minor_stress_impact_loss + trusting = minor_stress_impact_loss + trusting = minor_stress_impact_gain + trusting = medium_stress_impact_gain + vengeful = medium_stress_impact_gain + } + + ai_chance = { + base = 50 + ai_value_modifier = { + ai_vengefulness = 1 + ai_boldness = 1 + ai_compassion = -0.3 + } + } + } + + option = { + name = assassination_ongoing.0007.b + + scope:scheme = { + end_scheme = yes + } + + if = { #if target is truly righteous, you'll gain some piety + limit = { + scope:target = { num_virtuous_traits >= 1 } + } + add_piety = medium_piety_gain + } + + stress_impact = { + craven = minor_stress_impact_loss + trusting = minor_stress_impact_loss + ambitious = minor_stress_impact_gain + stubborn = medium_stress_impact_gain + vengeful = medium_stress_impact_gain + } + + ai_chance = { #cautious, trusting AI will do this + base = 50 + ai_value_modifier = { + ai_sociability = 0.4 + ai_boldness = -1 + ai_vengefulness = -1 + } + } + } +} + + diff --git a/events/scheme_events/murder_scheme/murder_saves/murder_save_events.txt b/events/scheme_events/murder_scheme/murder_saves/murder_save_events.txt index 215ea7ac9d..aaed4868ed 100644 --- a/events/scheme_events/murder_scheme/murder_saves/murder_save_events.txt +++ b/events/scheme_events/murder_scheme/murder_saves/murder_save_events.txt @@ -53,7 +53,7 @@ murder_save.0001 = { } desc = murder_save.0001.end } - + theme = murder_scheme left_portrait = { character = scope:target @@ -67,7 +67,7 @@ murder_save.0001 = { gui = "event_window_widget_scheme" container = "custom_widgets_container" } - + trigger = { scope:murder_method = flag:hired_assassin scope:target = { @@ -225,7 +225,7 @@ murder_save.0002 = { } desc = murder_save.0002.end } - + theme = murder_scheme left_portrait = { character = scope:target @@ -239,7 +239,7 @@ murder_save.0002 = { gui = "event_window_widget_scheme" container = "custom_widgets_container" } - + trigger = { scope:murder_method = flag:creepy_crawly scope:target = { @@ -370,7 +370,7 @@ murder_save.0003 = { type = character_event title = murder_save.0003.t desc = murder_save.0003.desc - + theme = murder_scheme left_portrait = { character = scope:target @@ -384,7 +384,7 @@ murder_save.0003 = { gui = "event_window_widget_scheme" container = "custom_widgets_container" } - + trigger = { scope:murder_method = flag:hired_assassin scope:target = { @@ -485,7 +485,7 @@ murder_save.0004 = { type = character_event title = murder_save.0004.t desc = murder_save.0004.desc - + theme = murder_scheme left_portrait = { character = scope:target @@ -495,7 +495,7 @@ murder_save.0004 = { gui = "event_window_widget_scheme" container = "custom_widgets_container" } - + trigger = { scope:murder_method = flag:hired_thugs scope:target = { @@ -594,7 +594,7 @@ murder_save.0005 = { type = character_event title = murder_save.0005.t desc = murder_save.0005.desc - + theme = murder_scheme left_portrait = { character = scope:target @@ -604,7 +604,7 @@ murder_save.0005 = { gui = "event_window_widget_scheme" container = "custom_widgets_container" } - + trigger = { scope:murder_method = flag:beat_to_death_in_dungeon scope:target = { @@ -694,7 +694,7 @@ murder_save.0006 = { } desc = murder_save.0006.end } - + theme = murder_scheme left_portrait = { character = scope:target @@ -704,7 +704,7 @@ murder_save.0006 = { gui = "event_window_widget_scheme" container = "custom_widgets_container" } - + trigger = { scope:murder_method = flag:hired_thugs scope:target = { @@ -795,7 +795,7 @@ murder_save.0007 = { type = character_event title = murder_save.0007.t desc = murder_save.0007.desc - + theme = murder_scheme left_portrait = { character = scope:target @@ -805,7 +805,7 @@ murder_save.0007 = { gui = "event_window_widget_scheme" container = "custom_widgets_container" } - + trigger = { scope:murder_method = flag:creepy_crawly scope:target = { @@ -901,7 +901,7 @@ murder_save.0008 = { type = character_event title = murder_save.0008.t desc = murder_save.0008.desc - + theme = murder_scheme left_portrait = { character = scope:target @@ -911,7 +911,7 @@ murder_save.0008 = { gui = "event_window_widget_scheme" container = "custom_widgets_container" } - + trigger = { scope:murder_method = flag:hired_assassin scope:target = { @@ -992,7 +992,7 @@ murder_save.0009 = { gui = "event_window_widget_scheme" container = "custom_widgets_container" } - + trigger = { scope:target = { exists = dynasty @@ -1097,7 +1097,7 @@ murder_save.0010 = { gui = "event_window_widget_scheme" container = "custom_widgets_container" } - + trigger = { scope:murder_method = flag:hired_assassin scope:target = { @@ -1230,7 +1230,7 @@ murder_save.0011 = { type = character_event title = murder_save.0011.t desc = murder_save.0011.desc - + theme = murder_scheme left_portrait = { character = scope:target @@ -1240,7 +1240,7 @@ murder_save.0011 = { gui = "event_window_widget_scheme" container = "custom_widgets_container" } - + trigger = { scope:murder_method = flag:used_poison scope:target = { @@ -1325,7 +1325,7 @@ murder_save.0012 = { type = character_event title = murder_save.0012.t desc = murder_save.0012.desc - + theme = murder_scheme left_portrait = { character = scope:target @@ -1335,7 +1335,7 @@ murder_save.0012 = { gui = "event_window_widget_scheme" container = "custom_widgets_container" } - + trigger = { scope:murder_method = flag:used_poison scope:target = { @@ -1419,7 +1419,7 @@ murder_save.0013 = { type = character_event title = murder_save.0013.t desc = murder_save.0013.desc - + theme = murder_scheme left_portrait = { character = scope:target @@ -1429,7 +1429,7 @@ murder_save.0013 = { gui = "event_window_widget_scheme" container = "custom_widgets_container" } - + trigger = { scope:murder_method = flag:used_poison scope:target = { @@ -1499,7 +1499,7 @@ murder_save.0014 = { type = character_event title = murder_save.0014.t desc = murder_save.0014.desc - + theme = murder_scheme left_portrait = { character = scope:target @@ -1509,7 +1509,7 @@ murder_save.0014 = { gui = "event_window_widget_scheme" container = "custom_widgets_container" } - + trigger = { scope:murder_method = flag:hired_assassin scope:target = { @@ -1584,7 +1584,7 @@ murder_save.0015 = { type = character_event title = murder_save.0015.t desc = murder_save.0015.desc - + theme = murder_scheme left_portrait = { character = scope:target @@ -1595,11 +1595,11 @@ murder_save.0015 = { container = "custom_widgets_container" } - artifact = { - target = scope:this_artifact - position = lower_center_portrait + artifact = { + target = scope:this_artifact + position = lower_center_portrait } - + trigger = { exists = scope:murder_method scope:murder_method = flag:hired_assassin @@ -1607,7 +1607,7 @@ murder_save.0015 = { is_available_healthy_adult = yes has_any_artifact = yes any_character_artifact = { - NOT = { + NOT = { has_variable = saved_from_assassination } } @@ -1623,7 +1623,7 @@ murder_save.0015 = { scope:target = { random_character_artifact = { limit = { - NOT = { + NOT = { has_variable = saved_from_assassination } } @@ -1654,7 +1654,7 @@ murder_save.0015 = { scope:scheme = { end_scheme = yes } - + ai_chance = { base = 100 } @@ -2488,9 +2488,9 @@ murder_save.1009 = { type = event_spymaster_task_good title = murder_save.dynasty_member_used_guile_legacy_5_save desc = murder_save.dynasty_member_used_guile_legacy_5_save_desc - + left_icon = scope:target - + } } } @@ -2876,7 +2876,7 @@ murder_save.1015 = { #has_variable = christian_loincloth #has_variable = christian_girdle } - + } } desc = murder_save.1015.strangling_artifact.desc @@ -3090,6 +3090,7 @@ murder_save.1015 = { # Warcraft override_death_killer_artifact_effect = { death_reason = death_murder killer = scope:target artifact = scope:this_artifact } } + if = { limit = { scope:target = { diff --git a/events/scheme_events/murder_scheme/murder_scheme_maintenance_events.txt b/events/scheme_events/murder_scheme/murder_scheme_maintenance_events.txt index 0d09546f33..48de613708 100644 --- a/events/scheme_events/murder_scheme/murder_scheme_maintenance_events.txt +++ b/events/scheme_events/murder_scheme/murder_scheme_maintenance_events.txt @@ -375,38 +375,7 @@ murder_scheme_maintenance.1 = { } } # Agenda impact - #modifier = { - # root = { - # any_character_struggle = { - # involvement = involved - # } - # } - # is_important_or_vip_struggle_character = yes - # add = { - # value = 0 - # if = { - # limit = { - # root = { - # any_character_struggle = { - # phase_has_catalyst = catalyst_gain_claim_on_title - # } - # has_character_flag = agenda_towards_escalation - # } - # } - # add = 100 - # } - # else_if = { - # limit = { - # root = { - # any_character_struggle = { - # phase_has_catalyst = catalyst_gain_claim_on_title - # } - # } - # } - # add = -1000 - # } - # } - #} + root = { start_scheme = { type = murder diff --git a/events/scheme_events/sway_scheme/sway_outcome_events.txt b/events/scheme_events/sway_scheme/sway_outcome_events.txt index 566a4a9a8e..227f92e2ae 100644 --- a/events/scheme_events/sway_scheme/sway_outcome_events.txt +++ b/events/scheme_events/sway_scheme/sway_outcome_events.txt @@ -20,10 +20,16 @@ sway_outcome.0001 = { title = sway_sway_success_message left_icon = scope:target scope:target = { - add_opinion = { - target = scope:owner - modifier = scheme_sway_opinion - opinion = sway_opinion_increase_per_success + if = { + limit = { + is_alive = yes + scope:owner = { is_alive = yes } + } + add_opinion = { + target = scope:owner + modifier = scheme_sway_opinion + opinion = sway_opinion_increase_per_success + } } } sway_end_effect = yes @@ -106,6 +112,7 @@ sway_outcome.1001 = { title = sway_outcome.1001.a.success add_prestige = minor_prestige_gain + scope:target = { add_opinion = { target = scope:owner @@ -217,6 +224,7 @@ sway_outcome.1002 = { title = sway_outcome.1001.a.success add_prestige = minor_prestige_gain + scope:target = { add_opinion = { target = scope:owner @@ -358,7 +366,7 @@ sway_outcome.1003 = { opinion = -10 } } - } + } } } } @@ -424,7 +432,10 @@ sway_outcome.1003 = { } } +#A disloyal vassal can be compelled to reconsider during the Anarchy at Samarra Struggle + #by Ola Jentzsch +#sway_outcome.1004 ################################# diff --git a/events/single_combat_events.txt b/events/single_combat_events.txt index d400d24f6b..9ba4127141 100644 --- a/events/single_combat_events.txt +++ b/events/single_combat_events.txt @@ -1893,6 +1893,15 @@ scripted_effect work_out_wounds_or_death_effect = { # Fatality:Always = losing is always fatal. else_if = { limit = { scope:fatality = flag:always } + scope:sc_victor = { + if = { + limit = { + this = scope:sc_attacker + NOT = { has_execute_reason = scope:sc_loser } + } + add_kinslayer_trait_or_nothing_effect = { VICTIM = scope:sc_loser } + } + } scope:sc_loser = { single_combat_death_effect = yes } @@ -6616,7 +6625,14 @@ single_combat.0001 = { #Unsure Attack option = { - name = single_combat.0001.unsure_attack + name = { + trigger = { scope:fatality = flag:yes } + text = single_combat.0001.unsure_attack + } + name = { + trigger = { scope:fatality = flag:no } + text = single_combat.0001.unsure_attack_non_fatal + } trigger = { exists = local_var:combat_move_unsure_attack_flag } #Move clarification @@ -7971,9 +7987,6 @@ single_combat.0021 = { immediate = { # Check what round we're at, and reduce the threshold variables as appropriate if we're in a late enough round. ## Reduce injury thresholds for both characters. - #TODO_CD: we're getting some errors logs in the overnight about the variables here, so this debug-stuff is for error-searching! - debug_log = "single combat variable error-check" - debug_log_scopes = yes if = { limit = { scope:sc_defender.var:current_round = round_injury_bonus_lower } debug_log = "single combat variable error-check: round_injury_bonus_lower" diff --git a/events/test_events/debug.txt b/events/test_events/debug.txt index 317a924fe1..49ddba7646 100644 --- a/events/test_events/debug.txt +++ b/events/test_events/debug.txt @@ -23,25 +23,24 @@ debug.1 = { # Max Portraits in Event Window center_portrait = { character = scope:portrait_3 - animation = celebrate_sword - } - - artifact = { - position = lower_right_portrait - target = scope:newly_created_artifact + animation = loss_1 } + + + lower_right_portrait = scope:portrait_4 + lower_center_portrait = scope:portrait_5 + lower_left_portrait = scope:portrait_6 immediate = { - create_artifact_weapon_effect = { - OWNER = this - CREATOR = this - SET_WEAPON_TYPE = flag:artifact_weapon_type_sword - } + random_ruler = { save_scope_as = portrait_1 } + random_ruler = { save_scope_as = portrait_2 } + random_ruler = { save_scope_as = portrait_3 } + random_ruler = { save_scope_as = portrait_4 } + random_ruler = { save_scope_as = portrait_5 } + random_ruler = { save_scope_as = portrait_6 } } - option = { - name = LOREM_IPSUM_TITLE - } + option = { name = LOREM_IPSUM_TITLE } } debug.111 = { # Two Portraits + three Artifacts in Event Window @@ -2568,6 +2567,7 @@ debug.418 = { } } } + # Family Feud debug.501 = { # Have another house murder my close family type = character_event @@ -2730,7 +2730,81 @@ debug.504 = { # Have my house killed by a feud target member } } -debug.510 = { +debug.510 = { # Placeholder debug event - Used to mark the location of placeholders + type = character_event + title = { # My favourite movie of the original triology + desc = d_star_company_adj + desc = game_concept_wars + desc = KEY_KP_MINUS + desc = cat_revenge_modifier + } + desc = { + desc = childhood.7400_mother_dead + desc = double_line_break + desc = RELIGION_LOC_PLACEHOLDER + desc = double_line_break + desc = RELIGION_LOC_PLACEHOLDER + desc = double_line_break + desc = RELIGION_LOC_PLACEHOLDER + desc = double_line_break + desc = RELIGION_LOC_PLACEHOLDER + } + + #orphan = yes + theme = mental_break + left_portrait = root + + option = { name = debug_generic_option } # Dear debug console, quiet please. + option = { name = debug_generic_option trigger = { always = no } trigger_event = debug.510 } +} + +debug.511 = { # Set secret faith for Character + type = character_event + theme = default + orphan = yes + + title = LOREM_IPSUM_TITLE + desc = LOREM_IPSUM_DESCRIPTION + + option = { + name = debug.511.a + + trigger = { + NOT = { exists = root.secret_faith } + } + + root = { + set_character_secret_faith = faith:rabbinism + } + } + + option = { + name = debug.511.b + + trigger = { + exists = root.secret_faith + } + + root = { + remove_character_secret_faith = yes + } + } +} + +debug.512 = { + type = character_event + theme = default + orphan = yes + + title = LOREM_IPSUM_TITLE + desc = LOREM_IPSUM_DESCRIPTION + + option = { + name = debug.512.a + } +} + +debug.513 = { title = debug_main desc = debug_main theme = ep2_video_test @@ -2793,7 +2867,8 @@ debug.605 = { } } - +#steam rich presence test - update this event with your new rich presence text to see it in the desc +#debug.700 debug.9595 = { type = character_event @@ -2878,6 +2953,73 @@ debug.9601 = { option = { name = debug_9601.d } } +debug.9610 = { # Spawn a super tax collector + hidden = yes + orphan = yes + + immediate = { + create_character = { + name = "Super Tax Collector" + age = { 20 32 } + location = root.capital_province + gender_female_chance = root_faith_dominant_gender_female_chance + culture = root.culture + faith = root.faith + random_traits = yes + trait = blind + stewardship = 100 + + dynasty = none + after_creation = { add_character_flag = is_guaranteed_excellent_tax_collector } + + save_scope_as = generated_actor + } + + send_interface_message = { + type = event_stewardship_good + title = governance_1053_corrupt_tax_collectors_modifier + right_icon = scope:generated_actor + + add_courtier = scope:generated_actor + } + } +} + +debug.9611 = { # Spawn a assassin + hidden = yes + orphan = yes + + immediate = { + create_character = { + name = "Super Assassin" + age = { 20 32 } + location = root.capital_province + gender_female_chance = root_faith_dominant_gender_female_chance + culture = root.culture + faith = root.faith + random_traits = yes + intrigue = 100 + prowess = 100 + trait = schemer + trait = education_intrigue_4 + + dynasty = none + + save_scope_as = generated_actor + } + + send_interface_message = { + type = event_stewardship_good + title = { + desc = d_assassin + desc = motto_greed + } + right_icon = scope:generated_actor + + add_courtier = scope:generated_actor + } + } +} debug.9620 = { # Hunt Artifacts type = character_event diff --git a/events/travel_events/travel_danger_events_arky.txt b/events/travel_events/travel_danger_events_arky.txt index 591ea1a95a..71f81e7b09 100644 --- a/events/travel_events/travel_danger_events_arky.txt +++ b/events/travel_events/travel_danger_events_arky.txt @@ -1185,6 +1185,7 @@ scripted_effect runaway_lost_effect = { add_courtier = scope:runaway_character if = { #make sure they are knighted by the new liege limit = { + scope:runaway_character ?= { exists = liege } scope:runaway_character.var:runaway_type ?= flag:runaway_knight scope:runaway_character ?= { is_potential_knight = yes } } @@ -1202,19 +1203,20 @@ scripted_effect runaway_lost_effect = { } scripted_trigger valid_runaway_character_trigger = { - NOT = { this = root } + save_temporary_scope_as = temp_runaway + NOT = { scope:temp_runaway = root } is_ai = yes is_available_travelling = yes is_landed = no has_been_promised_grand_wedding = no OR = { - any_relation = { type = lover this = root.location.county.holder } + any_relation = { type = lover scope:temp_runaway = root.location.county.holder } any_secret = { secret_type = secret_lover secret_target = root.location.county.holder NOT = { is_known_by = root } } - any_relation = { type = rival this = root } + any_relation = { type = rival scope:temp_runaway = root } AND = { is_knight = yes NOR = { diff --git a/events/travel_events/travel_events_cultural_traditions.txt b/events/travel_events/travel_events_cultural_traditions.txt index 66bd99e14a..b1c1ca37e1 100644 --- a/events/travel_events/travel_events_cultural_traditions.txt +++ b/events/travel_events/travel_events_cultural_traditions.txt @@ -1216,6 +1216,15 @@ travel_events.1213 = { #Mendicant mystic root.location = { save_scope_as = background_terrain_scope } + if = { + limit = { + has_trait = lifestyle_mystic + } + add_trait_xp = { + trait = lifestyle_mystic + value = lifestyle_mystic_xp_gain_minor_value + } + } } option = { #We should consider adopting this diff --git a/events/travel_events/travel_events_fp3.txt b/events/travel_events/travel_events_fp3.txt new file mode 100644 index 0000000000..b6e4933f70 --- /dev/null +++ b/events/travel_events/travel_events_fp3.txt @@ -0,0 +1,1615 @@ +namespace = travel_events_fp3 +############################ +# Dying Ember Event +# by Lucas Ribeiro +############################ +travel_events_fp3.0010 = { + type = character_event + title = travel_events_fp3.0010.t + desc = travel_events_fp3.0010.desc.intro + theme = travel + left_portrait = { + character = root + animation = lantern + } + right_portrait = { + character = scope:fp3_zoroastrian_armed_pilgrim + animation = aggressive_mace + } + override_background = { + reference = fp1_runestone_circle + } + cooldown = { + years = 10 + } + trigger = { + has_dlc_feature = legacy_of_persia + is_available_travelling_adult = yes + is_landed = yes + exists = location.faith + root.location.faith = { like_zoroastrianism_religion_trigger = yes } + } + immediate = { + create_character = { + template = fp3_zoroastrian_armed_pilgrim + location = root.location + culture = root.location.county.culture + faith = root.location.county.faith + gender_female_chance = root_faith_clergy_gender_female_chance + #Set up the scope + save_scope_as = fp3_zoroastrian_armed_pilgrim + } + } + + # Put out the embers by force + option = { + name = travel_events_fp3.0010.a + flavor = travel_events_fp3.0010.a.lightning.desc + trigger = { + faith = { + faith_hostility_level = { + target = root.location.faith + value >= faith_hostile_level + } + } + } + duel = { + skill = prowess + target = scope:fp3_zoroastrian_armed_pilgrim + 50 = { + desc = travel_events_fp3.0010.a.success + compare_modifier = { + value = scope:duel_value + multiplier = 3.5 + min = -49 + } + hidden_effect = { + scope:fp3_zoroastrian_armed_pilgrim = { + increase_wounds_effect = { + REASON = fight + } + } + } + show_as_tooltip = { + send_interface_toast = { + title = travel_events_fp3.0010.a.success + left_icon = root + right_icon = scope:fp3_zoroastrian_armed_pilgrim + add_piety = medium_piety_gain + rightfully_imprison_character_effect = { + TARGET = scope:fp3_zoroastrian_armed_pilgrim + IMPRISONER = root + } + } + } + hidden_effect = { + random_list = { + 90 = { + send_interface_toast = { + title = travel_events_fp3.0010.a.success + left_icon = root + right_icon = scope:fp3_zoroastrian_armed_pilgrim + add_piety = medium_piety_gain + rightfully_imprison_character_effect = { + TARGET = scope:fp3_zoroastrian_armed_pilgrim + IMPRISONER = root + } + } + } + 5 = { + trigger_event = travel_events_fp3.0011 + } + } + } + } + 50 = { + desc = travel_events_fp3.0010.a.failure + compare_modifier = { + value = scope:duel_value + multiplier = -3.5 + min = -49 + } + hidden_effect = { + scope:fp3_zoroastrian_armed_pilgrim = { + if = { + limit = { + root = { + is_ai = yes + } + } + silent_disappearance_effect = yes + } + } + } + increase_wounds_effect = { + REASON = fight + } + show_as_tooltip = { + send_interface_toast = { + title = travel_events_fp3.0010.a.failure + left_icon = root + right_icon = scope:fp3_zoroastrian_armed_pilgrim + add_piety = minor_piety_loss + } + } + hidden_effect = { + random_list = { + 95 = { + send_interface_toast = { + title = travel_events_fp3.0010.a.failure + left_icon = root + right_icon = scope:fp3_zoroastrian_armed_pilgrim + add_piety = minor_piety_loss + } + } + 5 = { + trigger_event = travel_events_fp3.0011 + } + } + } + } + } + stress_impact = { + compassionate = medium_stress_impact_gain + forgiving = medium_stress_impact_gain + callous = medium_stress_impact_loss + sadistic = medium_stress_impact_loss + cynical = medium_stress_impact_loss + zealous = medium_stress_impact_loss + } + ai_chance = { + base = 100 + modifier = { + factor = 0 + OR = { + has_trait = compassionate + has_trait = forgiving + } + } + modifier = { + factor = 1 + OR = { + has_trait = zealous + } + } + } + } + + #Confiscate the Holy Brazier as a zoroastrian + option = { + name = travel_events_fp3.0010.b + trigger = { + root.religion = religion:zoroastrianism_religion + } + flavor = travel_events_fp3.0010.a.lightning.desc + scope:fp3_zoroastrian_armed_pilgrim = { + if = { + limit = { + root = { + is_ai = yes + } + } + silent_disappearance_effect = yes + } + } + duel = { + skill = prowess + target = scope:fp3_zoroastrian_armed_pilgrim + 50 = { + desc = travel_events_fp3.0010.b.success + compare_modifier = { + value = scope:duel_value + multiplier = 3.5 + min = -49 + } + hidden_effect = { + scope:fp3_zoroastrian_armed_pilgrim = { + increase_wounds_effect = { + REASON = fight + } + } + } + show_as_tooltip = { + send_interface_toast = { + title = travel_events_fp3.0010.b.success + left_icon = root + right_icon = scope:fp3_zoroastrian_armed_pilgrim + add_piety = minor_piety_loss + create_artifact = { + name = zoroastrian_brazier_name + creator = scope:fp3_zoroastrian_armed_pilgrim + description = zoroastrian_brazier_desc + template = fp3_zoroastrian_brazier_template + modifier = fp3_zoroastrian_brazier_modifier + type = miscellaneous + visuals = urn + wealth = 40 + quality = 40 + } + } + } + hidden_effect = { + random_list = { + 95 = { + send_interface_toast = { + title = travel_events_fp3.0010.b.success + left_icon = root + right_icon = scope:fp3_zoroastrian_armed_pilgrim + add_piety = minor_piety_loss + create_artifact = { + name = zoroastrian_brazier_name + creator = scope:fp3_zoroastrian_armed_pilgrim + description = zoroastrian_brazier_desc + template = fp3_zoroastrian_brazier_template + modifier = fp3_zoroastrian_brazier_modifier + type = miscellaneous + visuals = urn + wealth = 40 + quality = 40 + } + } + } + 5 = { + trigger_event = travel_events_fp3.0011 + } + } + } + } + 50 = { + desc = travel_events_fp3.0010.b.failure + compare_modifier = { + value = scope:duel_value + multiplier = -3.5 + min = -49 + } + increase_wounds_effect = { + REASON = fight + } + show_as_tooltip = { + send_interface_toast = { + title = travel_events_fp3.0010.b.failure + left_icon = root + right_icon = scope:fp3_zoroastrian_armed_pilgrim + add_piety = major_piety_loss + } + } + hidden_effect = { + random_list = { + 95 = { + send_interface_toast = { + title = travel_events_fp3.0010.b.failure + left_icon = root + right_icon = scope:fp3_zoroastrian_armed_pilgrim + add_piety = major_piety_loss + } + } + 5 = { + trigger_event = travel_events_fp3.0011 + } + } + } + } + } + stress_impact = { + compassionate = medium_stress_impact_gain + forgiving = medium_stress_impact_gain + zealous = medium_stress_impact_gain + sadistic = medium_stress_impact_loss + cynical = medium_stress_impact_loss + greedy = medium_stress_impact_loss + ambitious = minor_stress_impact_loss + callous = minor_stress_impact_loss + } + ai_chance = { + base = 100 + modifier = { + factor = 0 + OR = { + has_trait = compassionate + has_trait = forgiving + has_trait = zealous + } + } + } + } + + # Help shelter the embers + option = { + name = travel_events_fp3.0010.c + flavor = travel_events_fp3.0010.c.flavor + if = { + limit = { + root.religion = religion:zoroastrianism_religion + } + add_piety = medium_piety_gain + stress_impact = { + zealous = medium_stress_impact_loss + } + } + else = { + add_piety = medium_piety_loss + stress_impact = { + zealous = medium_stress_impact_gain + } + } + random_list = { + 70 = { + desc = travel_events_fp3.0010.c.success + add_prestige = minor_prestige_gain + custom_tooltip = travel_events_fp3.0010.c.success.desc + trigger_event = travel_events_fp3.0012 + } + 30 = { + desc = travel_events_fp3.0010.c.failure + send_interface_toast = { + title = travel_events_fp3.0010.c.failure + left_icon = root + right_icon = scope:fp3_zoroastrian_armed_pilgrim + add_prestige = minor_prestige_loss + scope:fp3_zoroastrian_armed_pilgrim = { + if = { + limit = { + root = { + is_ai = yes + } + } + silent_disappearance_effect = yes + } + } + } + } + } + stress_impact = { + callous = medium_stress_impact_gain + sadistic = major_stress_impact_gain + compassionate = medium_stress_impact_loss + forgiving = minor_stress_impact_loss + } + ai_chance = { + base = 0 + modifier = { + add = 100 + OR = { + has_trait = compassionate + has_trait = just + has_trait = forgiving + } + } + modifier = { + factor = 0 + OR = { + has_trait = callous + has_trait = sadistic + } + } + } + } + + # Leave them to their plight + option = { + name = travel_events_fp3.0010.d + flavor = travel_events_fp3.0010.d.flavor + scope:fp3_zoroastrian_armed_pilgrim = { + if = { + limit = { + root = { + is_ai = yes + } + } + silent_disappearance_effect = yes + } + } + stress_impact = { + compassionate = minor_stress_impact_gain + forgiving = minor_stress_impact_gain + lazy = minor_stress_impact_loss + callous = minor_stress_impact_loss + sadistic = minor_stress_impact_loss + cynical = minor_stress_impact_loss + } + ai_chance = { + base = 100 + modifier = { + factor = 0 + OR = { + has_trait = callous + has_trait = sadistic + has_trait = zealous + } + } + } + } +} + +### Brazier is relit by lightning during the fight +travel_events_fp3.0011 = { + title = travel_events_fp3.0011.t + desc = travel_events_fp3.0011.desc.intro + theme = travel + override_background = { + reference = fp1_runestone_circle + } + left_portrait = { + character = root + animation = shock + } + right_portrait = { + character = scope:fp3_zoroastrian_armed_pilgrim + animation = celebrate_mace + } + + ### Convert Openly due to the Miracle + option = { + name = travel_events_fp3.0011.a + trigger = { + is_ai = no + } + set_character_faith_with_conversion = root.location.county.faith + scope:fp3_zoroastrian_armed_pilgrim = { + if = { + limit = { + root = { + is_ai = yes + } + } + silent_disappearance_effect = yes + } + } + stress_impact = { + cynical = medium_stress_impact_gain + zealous = medium_stress_impact_gain + arbitrary = medium_stress_impact_loss + } + ai_chance = { + base = 100 + } + } + + ### Convert Secretly due to the Miracle + option = { + name = travel_events_fp3.0011.b + scope:fp3_zoroastrian_armed_pilgrim = { + if = { + limit = { + root = { + is_ai = yes + } + } + silent_disappearance_effect = yes + } + } + if = { + limit = { + has_trait = lifestyle_mystic + } + add_trait_xp = { + trait = lifestyle_mystic + value = lifestyle_mystic_xp_gain_minor_value + } + } + make_character_crypto_religionist_effect = { CRYPTO_RELIGION = root.location.faith } + stress_impact = { + base = medium_stress_impact_gain + cynical = medium_stress_impact_gain + zealous = medium_stress_impact_gain + arbitrary = minor_stress_impact_gain + } + ai_chance = { + base = 50 + modifier = { + factor = 0 + has_trait = zealous + } + } + } + + ### Refute the Miracle + option = { + name = travel_events_fp3.0011.c + scope:fp3_zoroastrian_armed_pilgrim = { + if = { + limit = { + root = { + is_ai = yes + } + } + silent_disappearance_effect = yes + } + } + stress_impact = { + base = major_stress_impact_gain + cynical = major_stress_impact_loss + zealous = medium_stress_impact_loss + } + ai_chance = { + base = 100 + modifier = { + factor = 2 + has_trait = cynical + } + } + } +} + +### Group takes shelter from the storm together +travel_events_fp3.0012 = { + title = travel_events_fp3.0012.t + desc = travel_events_fp3.0012.desc.intro + + theme = travel + override_background = { + reference = fp3_cave + } + left_portrait = { + character = root + animation = personality_content + } + right_portrait = { + character = scope:fp3_zoroastrian_armed_pilgrim + animation = happiness + } + + immediate = { + save_scope_as = owner #For the court artifact + } + + ### Steal the Brazier while they rest + option = { + name = travel_events_fp3.0012.a + duel = { + skill = intrigue + target = scope:fp3_zoroastrian_armed_pilgrim + 50 = { + # You steal the Brazier from the Magi + compare_modifier = { + value = scope:duel_value + multiplier = 3.5 + min = -49 + } + send_interface_toast = { + left_icon = root + title = travel_events_fp3.0012.a.success + if = { + limit = { + has_royal_court = no + } + create_artifact = { + name = afarganyu_name + creator = scope:fp3_zoroastrian_armed_pilgrim + description = zoroastrian_brazier_desc + template = fp3_zoroastrian_brazier_template + modifier = fp3_zoroastrian_brazier_modifier + type = miscellaneous + history = { + type = created_before_history + } + visuals = urn + wealth = 40 + quality = 40 + } + } + else = { + set_artifact_rarity_illustrious = yes + create_artifact = { + name = afarganyu_name + description = zoroastrian_brazier_desc + template = branch_zoroastr_template + type = urn + visuals = urn + wealth = scope:wealth + quality = scope:quality + history = { + type = created_before_history + } + modifier = afarganyu_modifier + save_scope_as = newly_created_artifact + } + + scope:newly_created_artifact = { + set_variable = { name = historical_unique_artifact value = yes } + set_variable = { + name = relic + value = flag:zoroastr + } + save_scope_as = epic + } + } + } + scope:fp3_zoroastrian_armed_pilgrim = { + if = { + limit = { + root = { + is_ai = yes + } + } + silent_disappearance_effect = yes + } + } + } + 50 = { + # You get caught and exposed + compare_modifier = { + value = scope:duel_value + multiplier = -3.5 + min = -49 + } + send_interface_toast = { + title = travel_events_fp3.0012.a.failure + left_icon = root + add_prestige = major_prestige_loss + add_character_modifier = { + modifier = caught_thief_modifier + years = 5 + } + } + scope:fp3_zoroastrian_armed_pilgrim = { + if = { + limit = { + root = { + is_ai = yes + } + } + silent_disappearance_effect = yes + } + } + } + } + stress_impact = { + honest = medium_stress_impact_gain + compassionate = minor_stress_impact_gain + greedy = medium_stress_impact_loss + sadistic = medium_stress_impact_loss + callous = minor_stress_impact_loss + } + ai_chance = { + base = 100 + modifier = { + factor = 0 + OR = { + has_trait = honest + has_trait = compassionate + } + } + } + } + ### Take one of the Magi in the trip with you + option = { + name = travel_events_fp3.0012.b + trigger = { + scope:fp3_zoroastrian_armed_pilgrim = { + is_landed = no + } + } + add_courtier = scope:fp3_zoroastrian_armed_pilgrim + root.current_travel_plan = { + add_companion = scope:fp3_zoroastrian_armed_pilgrim + } + if = { + limit = { + has_trait = lifestyle_mystic + } + add_trait_xp = { + trait = lifestyle_mystic + value = lifestyle_mystic_xp_gain_minor_value + } + } + if = { + limit = { + root.religion = religion:zoroastrianism_religion + } + add_piety = minor_piety_gain + stress_impact = { + zealous = medium_stress_impact_loss + } + } + else = { + add_piety = minor_piety_loss + stress_impact = { + zealous = medium_stress_impact_gain + } + } + scope:fp3_zoroastrian_armed_pilgrim = { + add_character_flag = { + flag = blocked_from_leaving + years = 5 + } + } + stress_impact = { + paranoid = medium_stress_impact_gain + shy = medium_stress_impact_gain + gregarious = medium_stress_impact_loss + trusting = minor_stress_impact_loss + } + ai_chance = { + base = 100 + modifier = { + factor = 0 + OR = { + has_trait = shy + has_trait = paranoid + } + } + } + } + + ### Part ways with the Magi + option = { + name = travel_events_fp3.0012.c + scope:fp3_zoroastrian_armed_pilgrim = { + if = { + limit = { + root = { + is_ai = yes + } + } + silent_disappearance_effect = yes + } + } + stress_impact = { + gregarious = minor_stress_impact_gain + paranoid = minor_stress_impact_loss + shy = minor_stress_impact_loss + } + ai_chance = { + base = 100 + modifier = { + factor = 0 + has_trait = gregarious + } + } + } +} + +############################ +# Qanat Diving +# by Lucas Ribeiro +############################ +travel_events_fp3.0020 = { + type = character_event + title = travel_events_fp3.0020.t + desc = travel_events_fp3.0020.desc.intro + theme = travel + left_portrait = { + character = root + animation = lantern + } + override_background = { + reference = fp3_cave + } + cooldown = { + years = 30 #It is unlikely you would be surprised by a cave like this twice. + } + trigger = { + has_dlc_feature = legacy_of_persia + is_available_travelling_adult = yes + is_landed = yes + + exists = root.current_travel_plan.travel_leader + + root.location = { + OR = { + has_building_or_higher = qanats_01 + geographical_region = world_kalimdor_central + } + NOT = { root.location = root.capital_province } #We are not at home + } + } + immediate = { + mp_delay_travel_plan = { DAYS = 90 } + create_character = { + template = fp3_young_rascal + location = root.location + culture = root.location.county.culture + faith = root.location.county.faith + #Set up the scope + save_scope_as = fp3_young_rascal + } + if = { + limit = { exists = root.current_travel_plan.travel_leader } + root.current_travel_plan.travel_leader = { save_scope_as = travel_leader } + } + } + + ### Investigate + option = { + name = travel_events_fp3.0020.a + flavor = travel_events.fp3.0020.a.flavor + + duel = { + skill = prowess + value = decent_skill_rating + 65 = { + desc = travel_events_fp3.0020.a.success + compare_modifier = { + value = scope:duel_value + multiplier = 3.5 + min = -49 + } + custom_tooltip = travel_events_fp3.0020.a.success.tooltip + traveler_danger_xp_effect = { #We learn something from this ordeal. + MIN = 1 + MAX = 3 + } + trigger_event = travel_events_fp3.0021 + } + 35 = { + desc = travel_events_fp3.0020.a.failure + compare_modifier = { + value = scope:duel_value + multiplier = -3.5 + min = -49 + } + send_interface_toast = { + title = travel_events_fp3.0020.a.failure + custom_tooltip = travel_events_fp3.0020.a.failure.title + left_icon = root + increase_wounds_effect = { REASON = fall } + current_travel_plan = { + delay_travel_plan = { days = 20 } + } + } + } + } + + stress_impact = { + craven = major_stress_impact_gain + patient = minor_stress_impact_gain + brave = medium_stress_impact_loss + impatient = minor_stress_impact_loss + } + ai_chance = { + base = 100 + modifier = { + factor = 0 + OR = { + has_trait = craven + has_trait = patient + } + } + } + } + + ### Leave these caves + option = { + name = travel_events_fp3.0020.b + flavor = travel_events.fp3.0020.b.flavor + + reverse_add_opinion = { + target = scope:travel_leader + modifier = grateful_opinion + opinion = 15 + } + + traveler_danger_xp_effect = { #We learn something from this ordeal. + MIN = 1 + MAX = 3 + } + + stress_impact = { + impatient = medium_stress_impact_gain + craven = medium_stress_impact_loss + patient = medium_stress_impact_loss + } + + ai_chance = { + base = 100 + modifier = { + factor = 0 + has_trait = impatient + } + } + } + after = { + mp_resume_travel_plan = yes + } +} + +travel_events_fp3.0021 = { + type = character_event + title = travel_events_fp3.0021.t + desc = travel_events_fp3.0021.desc + theme = travel + left_portrait = { + character = root + animation = lantern + } + right_portrait = { + character = scope:fp3_young_rascal + animation = personality_bold + } + override_background = { + reference = fp3_cave + } + + ### Dive for treasure + option = { + name = travel_events_fp3.0021.a + duel = { + skill = prowess + value = decent_skill_rating + # Success. + 60 = { + compare_modifier = { + value = scope:duel_value + multiplier = 0.5 + } + desc = travel_events_fp3.0021.a.success.desc + hidden_effect = { + random_list = { + 5 = { #Islamic Relic + trigger = { has_royal_court = yes } + create_artifact_pedestal_islamic_relic_effect_hist = { OWNER = root } + } + 5 = { #Zoroastrian Relic + trigger = { has_royal_court = yes } + random_list = { + 50 = { + create_artifact_pedestal_branch_relic_zoroastr_effect = { OWNER = root } + } + 50 = { + create_artifact_afarganyu_effect = { OWNER = root } + } + } + } + 1 = { #Shamshir-e Zomorrodnegar + trigger = { + has_royal_court = yes + any_artifact = { + count < 1 + has_variable = zomorrodnegar + } + } + create_artifact_zomorrodnegar_effect = { OWNER = root } + } + 1 = { #Cup of Jamshid + trigger = { + has_royal_court = yes + NOT = { + any_artifact = { has_variable = cup_jamshid } + } + } + create_artifact_pedestal_cup_jamshid_effect = { OWNER = root } + } + 10 = { + trigger = { + any_artifact = { + count < 10 + has_variable = sassanian_sword + } + } + create_artifact_sassanian_sword_effect = { OWNER = root } + } + 1 = { + create_artifact_oxus_bracelet_effect = { OWNER = root } + } + 3 = { + create_artifact_fp3_ancient_drinking_vessel_effect = { OWNER = root } + } + } + scope:newly_created_artifact = { + set_variable = { + name = suppress_artifact_notifications + days = 1 + } + set_owner = { + target = root + history = { + type = discovered + actor = scope:fp3_young_rascal + recipient = root + location = root.location + } + } + } + } + send_interface_toast = { + title = travel_events_fp3.0021.a.success.t + left_icon = root + right_icon = scope:newly_created_artifact + add_prestige = minor_prestige_gain + } + custom_tooltip = travel_events_fp3.0021.a.artifact + } + 40 = { + compare_modifier = { + value = scope:duel_value + multiplier = -0.5 + } + desc = travel_events_fp3.0021.a.failure.desc + send_interface_toast = { + title = travel_events_fp3.0021.a.failure.t + left_icon = root + contract_disease_effect = { DISEASE = ill TREATMENT_EVENT = yes } + add_prestige = minor_prestige_loss + } + if = { + limit = { exists = scope:newly_created_artifact } + hidden_effect = { destroy_artifact = scope:newly_created_artifact } + } + } + } + traveler_danger_xp_effect = { + MIN = 3 + MAX = 7 + } + stress_impact = { + craven = major_stress_impact_gain + patient = minor_stress_impact_gain + brave = medium_stress_impact_loss + impatient = minor_stress_impact_loss + } + ai_chance = { + base = 100 + modifier = { + factor = 0 + OR = { + has_trait = craven + has_trait = patient + } + } + } + } + + ### Study the Qanat + option = { + name = travel_events_fp3.0021.b + if = { + limit = { exists = scope:newly_created_artifact } + hidden_effect = { destroy_artifact = scope:newly_created_artifact } + } + current_travel_plan = { + delay_travel_plan = { days = 20 } + } + duel = { + skill = learning + value = decent_skill_rating + # Success. + 60 = { + desc = travel_events_fp3.0021.b.success.desc + compare_modifier = { + value = scope:duel_value + multiplier = 0.5 + } + send_interface_toast = { + title = travel_events_fp3.0021.b.success.t + left_icon = root + add_character_modifier = { + modifier = fp3_irrigation_insights_modifier + years = 25 + } + add_prestige = minor_prestige_gain + } + } + # Failure. + 40 = { + desc = travel_events_fp3.0021.b.failure.desc + compare_modifier = { + value = scope:duel_value + multiplier = -0.5 + } + send_interface_toast = { + title = travel_events_fp3.0021.b.failure.t + left_icon = root + add_prestige = minor_prestige_loss + add_stress = minor_stress_gain + } + } + } + stress_impact = { + impatient = medium_stress_impact_gain + lazy = medium_stress_impact_gain + patient = medium_stress_impact_loss + diligent = medium_stress_impact_loss + } + ai_chance = { + base = 100 + modifier = { + factor = 0 + OR = { + has_trait = lazy + has_trait = impatient + } + } + } + } + + ### Scold the rascal + option = { + name = travel_events_fp3.0021.c + if = { + limit = { exists = scope:newly_created_artifact } + hidden_effect = { destroy_artifact = scope:newly_created_artifact } + } + add_prestige = minor_prestige_gain + stress_impact = { + humble = medium_stress_impact_gain + patient = minor_stress_impact_gain + trusting = minor_stress_impact_gain + calm = minor_stress_impact_gain + compassionate = minor_stress_impact_gain + arrogant = medium_stress_impact_loss + impatient = minor_stress_impact_loss + paranoid = minor_stress_impact_loss + wrathful = minor_stress_impact_loss + callous = minor_stress_impact_loss + sadistic = minor_stress_impact_loss + } + ai_chance = { + base = 100 + modifier = { + factor = 0 + has_trait = humble + } + } + } + + after = { + if = { + limit = { is_ai = yes } + scope:fp3_young_rascal = { silent_disappearance_effect = yes } + } + } +} + +############################ +# Feast for Falcons +# by Lucas Ribeiro +############################ +travel_events_fp3.0030 = { + type = character_event + title = travel_events_fp3.0030.t + desc = travel_events_fp3.0030.desc.intro + theme = travel + left_portrait = { + character = root + animation = shock + } + right_portrait = { + character = scope:sky_burial_officiator + animation = disapproval + } + cooldown = { + years = 5 + } + trigger = { + has_dlc_feature = legacy_of_persia + is_available_travelling_adult = yes + is_landed = yes + root.location = { + geographical_region = world_kalimdor_central + } + root.location.faith = { + has_doctrine = tenet_sky_burials + } + } + + immediate = { + root.location.faith = { + save_scope_as = local_faith + } + create_character = { + template = priest_character_template + location = root.location + faith = root.location.county.faith + save_scope_as = sky_burial_officiator + } + } + + ### Bury the bodies + option = { + name = travel_events_fp3.0030.a + trigger = { + faith = { + NOT = { + has_doctrine = tenet_sky_burials + } + } + } + add_piety = medium_piety_gain + every_vassal = { + limit = { + faith = { + has_doctrine = tenet_sky_burials + } + } + custom = every_faith_vassal + add_opinion = { + target = root + modifier = disturbed_funerals #Stacks slightly with the character modifier + } + } + add_character_modifier = { + modifier = disturbed_sky_burial + years = 5 + } + + stress_impact = { + compassionate = medium_stress_impact_gain + forgiving = medium_stress_impact_gain + callous = minor_stress_impact_loss + sadistic = medium_stress_impact_loss + zealous = medium_stress_impact_loss + } + ai_chance = { + base = 100 + modifier = { + factor = 0 + OR = { + has_trait = compassionate + has_trait = forgiving + } + } + } + } + + ### Appreciate as a Zoroastrian + option = { + name = travel_events_fp3.0030.b + trigger = { + root.faith = { + has_doctrine = tenet_sky_burials + } + } + add_piety = medium_piety_gain + stress_impact = { + craven = medium_stress_impact_gain + cynical = medium_stress_impact_gain + zealous = medium_stress_impact_loss + brave = medium_stress_impact_loss + } + ai_chance = { + base = 100 + modifier = { + factor = 0 + OR = { + has_trait = cynical + has_trait = craven + } + } + } + } + + ### Secret Faith Convert as a non-zoroastrian + #Rare trait unlocked option + option = { + name = travel_events_fp3.0030.c + trigger = { + is_ai = no #Never for the ai + OR = { + has_trait = lifestyle_mystic + has_trait = theologian + } + faith = { + NOT = { + has_doctrine = tenet_sky_burials + } + } + } + make_character_crypto_religionist_effect = { CRYPTO_RELIGION = root.location.faith } + stress_impact = { + zealous = massive_stress_impact_gain + cynical = major_stress_impact_gain + fickle = medium_stress_impact_loss + } + } + + ### Opt Out + option = { + name = travel_events_fp3.0030.d + flavor = travel_events_fp3.0030.d_flavor + add_piety = minor_piety_gain + + ai_chance = { + base = 100 + } + } + + ### Get a young bird for you to train + option = { + name = travel_events_fp3.0030.e + trigger = { + has_dlc_feature = tours_and_tournaments + NOR = { + has_character_modifier = fp3_untrained_falcon + has_character_modifier = fp3_aggressive_falcon + has_character_modifier = peregrine_falcon + } + } + add_character_modifier = { + modifier = fp3_untrained_falcon + years = 7 + } + hidden_effect = { + #this sets up the falcon training event + trigger_event = { + id = travel_events_fp3.0031 + months = 1 + } + } + custom_tooltip = travel_events_fp3.0030.e.tooltip + stress_impact = { + lazy = minor_stress_impact_gain + content = minor_stress_impact_gain + paranoid = minor_stress_impact_gain + craven = minor_stress_impact_gain + zealous = minor_stress_impact_gain + ambitious = minor_stress_impact_loss + diligent = minor_stress_impact_loss + trusting = minor_stress_impact_loss + brave = minor_stress_impact_loss + cynical = minor_stress_impact_loss + } + ai_chance = { + base = 100 + modifier = { + factor = 0 + OR = { + has_trait = lazy + has_trait = content + has_trait = paranoid + has_trait = craven + } + } + } + } + after = { + scope:sky_burial_officiator = { + silent_disappearance_effect = yes + } + } +} + +### The Falcon's training starts +travel_events_fp3.0031 = { + type = character_event + title = travel_events_fp3.0031.t + desc = travel_events_fp3.0031.desc.intro + + theme = hunting + trigger = { + is_landed = yes + has_character_modifier = fp3_untrained_falcon + } + left_portrait = { + character = root + animation = hunting_falcon + } + right_portrait = { + character = scope:falcon_victim + animation = pain + } + immediate = { + if = { + limit = { + is_travelling = yes + employs_court_position = master_of_hunt_court_position + court_position:master_of_hunt_court_position = { + location = root.location + is_available_allow_travelling = yes + } + } + court_position:master_of_hunt_court_position = { + save_scope_as = falcon_victim + } + } + else_if = { + limit = { + is_travelling = yes + current_travel_plan = { + any_entourage_character = { + count > 1 + NOT = { this = root } + is_available_travelling_adult = yes + } + } + } + current_travel_plan = { + random_entourage_character = { + limit = { + NOT = { this = root } + is_available_travelling_adult = yes + } + save_scope_as = falcon_victim + } + } + } + else_if = { + limit = { + employs_court_position = master_of_hunt_court_position + } + court_position:master_of_hunt_court_position = { + save_scope_as = falcon_victim + } + } + else_if = { + limit = { + exists = cp:councillor_marshal + } + cp:councillor_marshal = { + save_scope_as = falcon_victim + } + } + else_if = { + limit = { + exists = cp:councillor_steward + } + cp:councillor_steward = { + save_scope_as = falcon_victim + } + } + else_if = { + limit = { + exists = cp:councillor_chancellor + } + cp:councillor_chancellor = { + save_scope_as = falcon_victim + } + } + else = { + random_courtier = { + save_scope_as = falcon_victim + } + } + scope:falcon_victim = { + increase_wounds_effect = { + REASON = maimed_by_wild_beast + } + } + } + + ### Train the falcon as an avid falconer + option = { + name = travel_events_fp3.0031.d + trigger = { + root.culture = { + has_cultural_tradition = tradition_ep2_avid_falconers + } + } + flavor = travel_events_fp3.0031.d.tt + + add_character_modifier = { + modifier = peregrine_falcon + years = 7 + } + remove_character_modifier = fp3_untrained_falcon + add_prestige = minor_prestige_gain + } + + ### Try to train the falcon + option = { + name = travel_events_fp3.0031.a + trigger = { + NOT = { + root.culture = { + has_cultural_tradition = tradition_ep2_avid_falconers + } + } + } + duel = { + skill = martial + value = decent_skill_rating + # Success. + 50 = { + desc = travel_events_fp3.0031.a.success.desc + compare_modifier = { + value = scope:duel_value + multiplier = 0.5 + } + send_interface_toast = { + title = travel_events_fp3.0031.a.success.t + left_icon = root + add_character_modifier = { + modifier = peregrine_falcon + years = 7 + } + remove_character_modifier = fp3_untrained_falcon + add_prestige = minor_prestige_gain + } + } + # Failure. + 50 = { + desc = travel_events_fp3.0031.a.failure.desc + compare_modifier = { + value = scope:duel_value + multiplier = -0.5 + } + send_interface_toast = { + title = travel_events_fp3.0031.a.failure.t + left_icon = root + add_prestige = minor_prestige_loss + add_stress = minor_stress_gain + } + } + } + scope:falcon_victim = { + add_opinion = { + target = root + opinion = -20 + modifier = cruelty_opinion + } + } + stress_impact = { + lazy = minor_stress_impact_gain + impatient = medium_stress_impact_gain + diligent = minor_stress_impact_loss + patient = medium_stress_impact_loss + } + ai_chance = { + base = 100 + modifier = { + factor = 0 + OR = { + has_trait = lazy + has_trait = impatient + } + } + } + } + + ### Use the falcon to intimidate your enemies + option = { + name = travel_events_fp3.0031.b + add_character_modifier = { + modifier = fp3_aggressive_falcon + years = 6 + } + remove_character_modifier = fp3_untrained_falcon + scope:falcon_victim = { + add_opinion = { + target = root + opinion = -20 + modifier = cruelty_opinion + } + } + stress_impact = { + compassionate = medium_stress_impact_gain + sadistic = minor_stress_impact_loss + callous = minor_stress_impact_loss + } + + ai_chance = { + base = 100 + modifier = { + factor = 0 + has_trait = compassionate + } + } + } + + ### Get rid of the falcon + option = { + name = travel_events_fp3.0031.c + remove_character_modifier = fp3_untrained_falcon + add_prestige = minor_prestige_loss + scope:falcon_victim = { + add_opinion = { + target = root + opinion = 20 + modifier = pleased_opinion + } + } + stress_impact = { + callous = medium_stress_impact_gain + sadistic = medium_stress_impact_gain + forgiving = minor_stress_impact_gain + ambitious = minor_stress_impact_gain + patient = minor_stress_impact_gain + compassionate = medium_stress_impact_loss + content = minor_stress_impact_loss + impatient = minor_stress_impact_loss + content = minor_stress_impact_loss + } + ai_chance = { + base = 100 + modifier = { + factor = 0 + OR = { + has_trait = callous + has_trait = sadistic + has_trait = ambitious + has_trait = patient + } + } + } + } +} \ No newline at end of file diff --git a/events/yearly_events/yearly_events_4.txt b/events/yearly_events/yearly_events_4.txt index 4d6bf317a2..c55692ab47 100644 --- a/events/yearly_events/yearly_events_4.txt +++ b/events/yearly_events/yearly_events_4.txt @@ -2109,11 +2109,7 @@ yearly.4051 = { option = { name = intrigue_scheme_ongoing.5015.a - - add_character_modifier = { - modifier = has_plush_carpet_modifier - days = 3650 - } + add_carpet_modifier_effect = yes ai_chance = { base = 1