This commit is contained in:
Heidesommer 2026-05-29 05:24:40 -04:00
parent ce70fe752e
commit 734d526ca9
41 changed files with 17594 additions and 1069 deletions

View file

@ -142,69 +142,69 @@
auto_accept = yes auto_accept = yes
on_accept = { on_accept = {
hidden_effect = { # hidden_effect = {
# Struggle Catalysts # # Struggle Catalysts
## We work these out first so they're not invalidated by the actual effect block. # ## We work these out first so they're not invalidated by the actual effect block.
if = { # if = {
limit = { # limit = {
catalyst_granted_powerful_diff_faith_vassal_religious_protection_preliminary_trigger = { CHAR = scope:recipient } # catalyst_granted_powerful_diff_faith_vassal_religious_protection_preliminary_trigger = { CHAR = scope:recipient }
scope:actor = { # scope:actor = {
any_character_struggle = { # any_character_struggle = {
involvement = involved # involvement = involved
activate_struggle_catalyst_secondary_character_involvement_involved_trigger = { # activate_struggle_catalyst_secondary_character_involvement_involved_trigger = {
CATALYST = catalyst_granted_powerful_diff_faith_vassal_religious_protection # CATALYST = catalyst_granted_powerful_diff_faith_vassal_religious_protection
CHAR = scope:recipient # CHAR = scope:recipient
} # }
} # }
} # }
} # }
scope:actor = { # scope:actor = {
every_character_struggle = { # every_character_struggle = {
involvement = involved # involvement = involved
limit = { # limit = {
activate_struggle_catalyst_secondary_character_involvement_involved_trigger = { # activate_struggle_catalyst_secondary_character_involvement_involved_trigger = {
CATALYST = catalyst_granted_powerful_diff_faith_vassal_religious_protection # CATALYST = catalyst_granted_powerful_diff_faith_vassal_religious_protection
CHAR = scope:recipient # CHAR = scope:recipient
} # }
} # }
activate_struggle_catalyst = { # activate_struggle_catalyst = {
catalyst = catalyst_granted_powerful_diff_faith_vassal_religious_protection # catalyst = catalyst_granted_powerful_diff_faith_vassal_religious_protection
character = scope:actor # character = scope:actor
} # }
} # }
} # }
} # }
if = { # if = {
limit = { # limit = {
catalyst_revoked_powerful_diff_faith_vassal_religious_protection_preliminary_trigger = { CHAR = scope:recipient } # catalyst_revoked_powerful_diff_faith_vassal_religious_protection_preliminary_trigger = { CHAR = scope:recipient }
scope:actor = { # scope:actor = {
any_character_struggle = { # any_character_struggle = {
involvement = involved # involvement = involved
activate_struggle_catalyst_secondary_character_involvement_involved_trigger = { # activate_struggle_catalyst_secondary_character_involvement_involved_trigger = {
CATALYST = catalyst_revoked_powerful_diff_faith_vassal_religious_protection # CATALYST = catalyst_revoked_powerful_diff_faith_vassal_religious_protection
CHAR = scope:recipient # CHAR = scope:recipient
} # }
} # }
} # }
} # }
scope:actor = { # scope:actor = {
every_character_struggle = { # every_character_struggle = {
involvement = involved # involvement = involved
limit = { # limit = {
activate_struggle_catalyst_secondary_character_involvement_involved_trigger = { # activate_struggle_catalyst_secondary_character_involvement_involved_trigger = {
CATALYST = catalyst_revoked_powerful_diff_faith_vassal_religious_protection # CATALYST = catalyst_revoked_powerful_diff_faith_vassal_religious_protection
CHAR = scope:recipient # CHAR = scope:recipient
} # }
} # }
activate_struggle_catalyst = { # activate_struggle_catalyst = {
catalyst = catalyst_revoked_powerful_diff_faith_vassal_religious_protection # catalyst = catalyst_revoked_powerful_diff_faith_vassal_religious_protection
character = scope:actor # character = scope:actor
} # }
} # }
} # }
} # }
#
# Improving contract catalyst # # Improving contract catalyst
# if = { # if = {
# limit = { # limit = {
# scope:recipient.count_obligation_improvements_for_vassal > 0 # scope:recipient.count_obligation_improvements_for_vassal > 0
@ -238,7 +238,7 @@
# } # }
# } # }
# } # }
} # }
# Enact changes. # Enact changes.
scope:actor = { scope:actor = {
@ -892,81 +892,17 @@ admin_liege_modify_vassal_contract_interaction = {
auto_accept = yes auto_accept = yes
on_accept = { on_accept = {
hidden_effect = { # hidden_effect = {
# Struggle Catalysts # # Struggle Catalysts
## We work these out first so they're not invalidated by the actual effect block. # ## We work these out first so they're not invalidated by the actual effect block.
if = { # if = {
limit = {
catalyst_granted_powerful_diff_faith_vassal_religious_protection_preliminary_trigger = { CHAR = scope:recipient }
scope:actor = {
any_character_struggle = {
involvement = involved
activate_struggle_catalyst_secondary_character_involvement_involved_trigger = {
CATALYST = catalyst_granted_powerful_diff_faith_vassal_religious_protection
CHAR = scope:recipient
}
}
}
}
scope:actor = {
every_character_struggle = {
involvement = involved
limit = {
activate_struggle_catalyst_secondary_character_involvement_involved_trigger = {
CATALYST = catalyst_granted_powerful_diff_faith_vassal_religious_protection
CHAR = scope:recipient
}
}
activate_struggle_catalyst = {
catalyst = catalyst_granted_powerful_diff_faith_vassal_religious_protection
character = scope:actor
}
}
}
}
if = {
limit = {
catalyst_revoked_powerful_diff_faith_vassal_religious_protection_preliminary_trigger = { CHAR = scope:recipient }
scope:actor = {
any_character_struggle = {
involvement = involved
activate_struggle_catalyst_secondary_character_involvement_involved_trigger = {
CATALYST = catalyst_revoked_powerful_diff_faith_vassal_religious_protection
CHAR = scope:recipient
}
}
}
}
scope:actor = {
every_character_struggle = {
involvement = involved
limit = {
activate_struggle_catalyst_secondary_character_involvement_involved_trigger = {
CATALYST = catalyst_revoked_powerful_diff_faith_vassal_religious_protection
CHAR = scope:recipient
}
}
activate_struggle_catalyst = {
catalyst = catalyst_revoked_powerful_diff_faith_vassal_religious_protection
character = scope:actor
}
}
}
}
# Improving contract catalyst
if = {
# limit = { # limit = {
# scope:recipient.count_obligation_improvements_for_vassal > 0 # catalyst_granted_powerful_diff_faith_vassal_religious_protection_preliminary_trigger = { CHAR = scope:recipient }
# scope:actor = { # scope:actor = {
# is_diff_faith_or_culture_trigger = {
# CHAR = scope:recipient
# STATUS = involved
# }
# any_character_struggle = { # any_character_struggle = {
# involvement = involved # involvement = involved
# activate_struggle_catalyst_secondary_character_involvement_involved_trigger = { # activate_struggle_catalyst_secondary_character_involvement_involved_trigger = {
# CATALYST = catalyst_grant_privilege_to_diff_faith_culture_vassal # CATALYST = catalyst_granted_powerful_diff_faith_vassal_religious_protection
# CHAR = scope:recipient # CHAR = scope:recipient
# } # }
# } # }
@ -977,18 +913,82 @@ admin_liege_modify_vassal_contract_interaction = {
# involvement = involved # involvement = involved
# limit = { # limit = {
# activate_struggle_catalyst_secondary_character_involvement_involved_trigger = { # activate_struggle_catalyst_secondary_character_involvement_involved_trigger = {
# CATALYST = catalyst_grant_privilege_to_diff_faith_culture_vassal # CATALYST = catalyst_granted_powerful_diff_faith_vassal_religious_protection
# CHAR = scope:recipient # CHAR = scope:recipient
# } # }
# } # }
# activate_struggle_catalyst = { # activate_struggle_catalyst = {
# catalyst = catalyst_grant_privilege_to_diff_faith_culture_vassal # catalyst = catalyst_granted_powerful_diff_faith_vassal_religious_protection
# character = scope:actor # character = scope:actor
# } # }
# } # }
# } # }
# } # }
} # if = {
# limit = {
# catalyst_revoked_powerful_diff_faith_vassal_religious_protection_preliminary_trigger = { CHAR = scope:recipient }
# scope:actor = {
# any_character_struggle = {
# involvement = involved
# activate_struggle_catalyst_secondary_character_involvement_involved_trigger = {
# CATALYST = catalyst_revoked_powerful_diff_faith_vassal_religious_protection
# CHAR = scope:recipient
# }
# }
# }
# }
# scope:actor = {
# every_character_struggle = {
# involvement = involved
# limit = {
# activate_struggle_catalyst_secondary_character_involvement_involved_trigger = {
# CATALYST = catalyst_revoked_powerful_diff_faith_vassal_religious_protection
# CHAR = scope:recipient
# }
# }
# activate_struggle_catalyst = {
# catalyst = catalyst_revoked_powerful_diff_faith_vassal_religious_protection
# character = scope:actor
# }
# }
# }
# }
#
# # Improving contract catalyst
# if = {
## limit = {
## scope:recipient.count_obligation_improvements_for_vassal > 0
## scope:actor = {
## is_diff_faith_or_culture_trigger = {
## CHAR = scope:recipient
## STATUS = involved
## }
## any_character_struggle = {
## involvement = involved
## activate_struggle_catalyst_secondary_character_involvement_involved_trigger = {
## CATALYST = catalyst_grant_privilege_to_diff_faith_culture_vassal
## CHAR = scope:recipient
## }
## }
## }
## }
## scope:actor = {
## every_character_struggle = {
## involvement = involved
## limit = {
## activate_struggle_catalyst_secondary_character_involvement_involved_trigger = {
## CATALYST = catalyst_grant_privilege_to_diff_faith_culture_vassal
## CHAR = scope:recipient
## }
## }
## activate_struggle_catalyst = {
## catalyst = catalyst_grant_privilege_to_diff_faith_culture_vassal
## character = scope:actor
## }
## }
## }
## }
# }
# Enact changes. # Enact changes.
scope:actor = { scope:actor = {
@ -1596,81 +1596,17 @@ nomad_liege_modify_vassal_contract_interaction = {
auto_accept = yes auto_accept = yes
on_accept = { on_accept = {
hidden_effect = { # hidden_effect = {
# Struggle Catalysts # # Struggle Catalysts
## We work these out first so they're not invalidated by the actual effect block. # ## We work these out first so they're not invalidated by the actual effect block.
if = {
limit = {
catalyst_granted_powerful_diff_faith_vassal_religious_protection_preliminary_trigger = { CHAR = scope:recipient }
scope:actor = {
any_character_struggle = {
involvement = involved
activate_struggle_catalyst_secondary_character_involvement_involved_trigger = {
CATALYST = catalyst_granted_powerful_diff_faith_vassal_religious_protection
CHAR = scope:recipient
}
}
}
}
scope:actor = {
every_character_struggle = {
involvement = involved
limit = {
activate_struggle_catalyst_secondary_character_involvement_involved_trigger = {
CATALYST = catalyst_granted_powerful_diff_faith_vassal_religious_protection
CHAR = scope:recipient
}
}
activate_struggle_catalyst = {
catalyst = catalyst_granted_powerful_diff_faith_vassal_religious_protection
character = scope:actor
}
}
}
}
if = {
limit = {
catalyst_revoked_powerful_diff_faith_vassal_religious_protection_preliminary_trigger = { CHAR = scope:recipient }
scope:actor = {
any_character_struggle = {
involvement = involved
activate_struggle_catalyst_secondary_character_involvement_involved_trigger = {
CATALYST = catalyst_revoked_powerful_diff_faith_vassal_religious_protection
CHAR = scope:recipient
}
}
}
}
scope:actor = {
every_character_struggle = {
involvement = involved
limit = {
activate_struggle_catalyst_secondary_character_involvement_involved_trigger = {
CATALYST = catalyst_revoked_powerful_diff_faith_vassal_religious_protection
CHAR = scope:recipient
}
}
activate_struggle_catalyst = {
catalyst = catalyst_revoked_powerful_diff_faith_vassal_religious_protection
character = scope:actor
}
}
}
}
# Improving contract catalyst
# if = { # if = {
# limit = { # limit = {
# scope:recipient.count_obligation_improvements_for_vassal > 0 # catalyst_granted_powerful_diff_faith_vassal_religious_protection_preliminary_trigger = { CHAR = scope:recipient }
# scope:actor = { # scope:actor = {
# is_diff_faith_or_culture_trigger = {
# CHAR = scope:recipient
# STATUS = involved
# }
# any_character_struggle = { # any_character_struggle = {
# involvement = involved # involvement = involved
# activate_struggle_catalyst_secondary_character_involvement_involved_trigger = { # activate_struggle_catalyst_secondary_character_involvement_involved_trigger = {
# CATALYST = catalyst_grant_privilege_to_diff_faith_culture_vassal # CATALYST = catalyst_granted_powerful_diff_faith_vassal_religious_protection
# CHAR = scope:recipient # CHAR = scope:recipient
# } # }
# } # }
@ -1681,18 +1617,82 @@ nomad_liege_modify_vassal_contract_interaction = {
# involvement = involved # involvement = involved
# limit = { # limit = {
# activate_struggle_catalyst_secondary_character_involvement_involved_trigger = { # activate_struggle_catalyst_secondary_character_involvement_involved_trigger = {
# CATALYST = catalyst_grant_privilege_to_diff_faith_culture_vassal # CATALYST = catalyst_granted_powerful_diff_faith_vassal_religious_protection
# CHAR = scope:recipient # CHAR = scope:recipient
# } # }
# } # }
# activate_struggle_catalyst = { # activate_struggle_catalyst = {
# catalyst = catalyst_grant_privilege_to_diff_faith_culture_vassal # catalyst = catalyst_granted_powerful_diff_faith_vassal_religious_protection
# character = scope:actor # character = scope:actor
# } # }
# } # }
# } # }
# } # }
} # if = {
# limit = {
# catalyst_revoked_powerful_diff_faith_vassal_religious_protection_preliminary_trigger = { CHAR = scope:recipient }
# scope:actor = {
# any_character_struggle = {
# involvement = involved
# activate_struggle_catalyst_secondary_character_involvement_involved_trigger = {
# CATALYST = catalyst_revoked_powerful_diff_faith_vassal_religious_protection
# CHAR = scope:recipient
# }
# }
# }
# }
# scope:actor = {
# every_character_struggle = {
# involvement = involved
# limit = {
# activate_struggle_catalyst_secondary_character_involvement_involved_trigger = {
# CATALYST = catalyst_revoked_powerful_diff_faith_vassal_religious_protection
# CHAR = scope:recipient
# }
# }
# activate_struggle_catalyst = {
# catalyst = catalyst_revoked_powerful_diff_faith_vassal_religious_protection
# character = scope:actor
# }
# }
# }
# }
#
# # Improving contract catalyst
## if = {
## limit = {
## scope:recipient.count_obligation_improvements_for_vassal > 0
## scope:actor = {
## is_diff_faith_or_culture_trigger = {
## CHAR = scope:recipient
## STATUS = involved
## }
## any_character_struggle = {
## involvement = involved
## activate_struggle_catalyst_secondary_character_involvement_involved_trigger = {
## CATALYST = catalyst_grant_privilege_to_diff_faith_culture_vassal
## CHAR = scope:recipient
## }
## }
## }
## }
## scope:actor = {
## every_character_struggle = {
## involvement = involved
## limit = {
## activate_struggle_catalyst_secondary_character_involvement_involved_trigger = {
## CATALYST = catalyst_grant_privilege_to_diff_faith_culture_vassal
## CHAR = scope:recipient
## }
## }
## activate_struggle_catalyst = {
## catalyst = catalyst_grant_privilege_to_diff_faith_culture_vassal
## character = scope:actor
## }
## }
## }
## }
# }
# Enact changes. # Enact changes.
scope:actor = { scope:actor = {

View file

@ -3214,80 +3214,80 @@ set_de_jure_capital_decision = {
base = 100 base = 100
} }
} }
#
# Restore Carthage ## Restore Carthage
#
restore_carthage_decision = { #restore_carthage_decision = {
picture = { # picture = {
reference = "gfx/interface/illustrations/decisions/decision_dynasty_house.dds" # reference = "gfx/interface/illustrations/decisions/decision_dynasty_house.dds"
} # }
decision_group_type = major # decision_group_type = major
#
ai_check_interval_by_tier = { # ai_check_interval_by_tier = {
barony = 0 # barony = 0
county = 0 # county = 0
duchy = 0 # duchy = 0
kingdom = 120 # kingdom = 120
empire = 0 # empire = 0
hegemony = 0 # hegemony = 0
} # }
#
desc = restore_carthage_decision_desc # desc = restore_carthage_decision_desc
selection_tooltip = restore_carthage_decision_tooltip # selection_tooltip = restore_carthage_decision_tooltip
#
is_shown = { # is_shown = {
is_ruler = yes # is_ruler = yes
is_playable_character = yes # is_playable_character = yes
#
OR = { # OR = {
culture = { has_cultural_pillar = heritage_syriac } # culture = { has_cultural_pillar = heritage_syriac }
culture = culture:levantine # culture = culture:levantine
} # }
#
# Not repeatable. # # Not repeatable.
NOT = { # NOT = {
is_target_in_global_variable_list = { # is_target_in_global_variable_list = {
name = unavailable_unique_decisions # name = unavailable_unique_decisions
target = flag:flag_restored_carthage # target = flag:flag_restored_carthage
} # }
} # }
} # }
#
is_valid = { # is_valid = {
is_independent_ruler = yes # is_independent_ruler = yes
highest_held_title_tier < tier_empire # highest_held_title_tier < tier_empire
#
prestige_level >= 4 # prestige_level >= 4
#
completely_controls_region = custom_carthage # completely_controls_region = custom_carthage
completely_controls_region = custom_tripolitania # completely_controls_region = custom_tripolitania
completely_controls_region = custom_mauretania # completely_controls_region = custom_mauretania
completely_controls_region = custom_carthago_nova # completely_controls_region = custom_carthago_nova
#
} # }
#
is_valid_showing_failures_only = { # is_valid_showing_failures_only = {
top_liege = this # top_liege = this
is_available_adult = yes # is_available_adult = yes
} # }
#
cost = { # cost = {
gold = { # gold = {
value = 1200 # value = 1200
} # }
} # }
#
effect = { # effect = {
save_scope_as = founder # save_scope_as = founder
show_as_tooltip = { restore_carthage_scripted_effect = yes } # show_as_tooltip = { restore_carthage_scripted_effect = yes }
#
hidden_effect = { # hidden_effect = {
add_to_global_variable_list = { # add_to_global_variable_list = {
name = unavailable_unique_decisions # name = unavailable_unique_decisions
target = flag:flag_restored_carthage # target = flag:flag_restored_carthage
} # }
} # }
#
trigger_event = major_decisions.3300 # trigger_event = major_decisions.3300
} # }
} #}

View file

@ -70,7 +70,7 @@ reforge_crown_wenceslas_decision = {
} }
} }
ai_check_interval = { 500 } ai_check_interval = 500
ai_will_do = { ai_will_do = {
value = 15 value = 15
} }

File diff suppressed because it is too large Load diff

View file

@ -279,91 +279,91 @@ on_county_occupied = {
} }
} }
# Mongol Devastation # Mongol Devastation
if = { # if = {
limit = { # limit = {
# Check that it's relevant so we don't fire it *all* the time # # Check that it's relevant so we don't fire it *all* the time
OR = { # OR = {
AND = { # AND = {
exists = global_var:mongol_empire_has_spawned # exists = global_var:mongol_empire_has_spawned
NOT = { exists = global_var:mongol_story_has_ended } # NOT = { exists = global_var:mongol_story_has_ended }
any_owned_story = { # any_owned_story = {
type = story_mongol_invasion # type = story_mongol_invasion
} # }
} # }
any_owned_story = { # any_owned_story = {
type = story_greatest_of_khans # type = story_greatest_of_khans
} # }
} # }
NOT = { exists = scope:county.var:looted_by_mongols } # NOT = { exists = scope:county.var:looted_by_mongols }
} # }
# Each County should only be devastated once # # Each County should only be devastated once
scope:county = { # scope:county = {
set_variable = { # set_variable = {
name = looted_by_mongols # name = looted_by_mongols
value = yes # value = yes
years = 25 # years = 25
} # }
} # }
# Send a message (and gold!) to the Mongol Emperor # # Send a message (and gold!) to the Mongol Emperor
send_interface_message = { # send_interface_message = {
type = event_war_good # type = event_war_good
title = mongols_sieged_county.t # title = mongols_sieged_county.t
left_icon = scope:previous_controller # left_icon = scope:previous_controller
right_icon = scope:county # right_icon = scope:county
#Herd from nomad counties if nomadic # #Herd from nomad counties if nomadic
if = { # if = {
limit = { # limit = {
scope:county = { # scope:county = {
any_county_province = { # any_county_province = {
OR = { # OR = {
has_holding_type = nomad_holding # has_holding_type = nomad_holding
has_holding_type = herder_holding # has_holding_type = herder_holding
} # }
} # }
} # }
government_has_flag = government_is_nomadic # government_has_flag = government_is_nomadic
} # }
domicile = { # domicile = {
change_herd = miniscule_herd_gain # change_herd = miniscule_herd_gain
} # }
} # }
else = { # else = {
if = { # if = {
limit = { # limit = {
scope:county.development_level >= 1 # scope:county.development_level >= 1
} # }
add_gold = { # add_gold = {
add = scope:county.development_level # add = scope:county.development_level
multiply = 5 # multiply = 5
} # }
} # }
} # }
if = { # if = {
limit = { # limit = {
dread < 150 # dread < 150
} # }
add_dread = 2 # add_dread = 2
} # }
show_as_tooltip = { # show_as_tooltip = {
scope:county = { # scope:county = {
mongols_devastate_county_effect = yes # mongols_devastate_county_effect = yes
} # }
} # }
} # }
save_scope_as = mongol_emperor # save_scope_as = mongol_emperor
# Send a message to the County's owner # # Send a message to the County's owner
scope:county.holder = { # scope:county.holder = {
send_interface_message = { # send_interface_message = {
type = event_war_bad # type = event_war_bad
title = mongols_sieged_county.t # title = mongols_sieged_county.t
left_icon = scope:mongol_emperor # left_icon = scope:mongol_emperor
right_icon = scope:county # right_icon = scope:county
scope:county = { # scope:county = {
mongols_devastate_county_effect = yes # mongols_devastate_county_effect = yes
} # }
} # }
} # }
} # }
# Admin house power bonus for getting influence # Admin house power bonus for getting influence
if = { if = {
limit = { limit = {
@ -789,7 +789,7 @@ on_raid_action_completion = {
raiding.0013 # Chance to kidnap prisoners raiding.0013 # Chance to kidnap prisoners
raiding.0014 # Chance to steal an artifact raiding.0014 # Chance to steal an artifact
bp2_yearly.8031 # Steal a doll bp2_yearly.8031 # Steal a doll
raiding.0031 # Hereward adds XP # raiding.0031 # Hereward adds XP
raiding.0040 # Raid Intent Effects raiding.0040 # Raid Intent Effects
} }
effect = { effect = {

View file

@ -0,0 +1,34 @@
######################################################
####
#### El Cid Story Cycle On-Actions
####
#### el_cid_landless_on_action
#### el_cid_landless_or_landed_on_action
####
######################################################
#
## Landless
#el_cid_landless_on_action = {
# random_events = {
# # No one opens the door to you
# 200 = cid.1000
# # You have no money to pay your men
# 100 = cid.1010
# # You have to leave your spouse/children behind
# 200 = cid.1020
# }
#}
#
## Landless or Landed
#el_cid_landless_or_landed_on_action = {
# random_events = {
# # You have some money - send gift?
# 100 = cid.1030
# # You pray for your liege
# 100 = cid.1040
# # cid.2000 triggered from the combat on_action
# # cid.2001 triggered from the combat on_action
# # Your liege offers you a favourable marriage
# 250 = cid.2010
# }
#}

View file

@ -0,0 +1,42 @@
##Events for William/Norman King of England
#ongoing_harrying_owner_events = {
# random_events = {
# chance_of_no_event = 90
# delay = { days = { 60 90 } }
#
# 100 = ep3_story_cycle_harrying.1000
# 100 = ep3_story_cycle_harrying.1005
# 100 = ep3_story_cycle_harrying.1010
# 100 = ep3_story_cycle_harrying.1015
# }
#}
#
##Events for Anglo-Saxon lords in England
#ongoing_harrying_aetheling_events = {
# random_events = {
# chance_of_no_event = 90
# delay = { days = { 60 90 } }
#
# 100 = ep3_story_cycle_harrying.2000
# 100 = ep3_story_cycle_harrying.2005
# 100 = ep3_story_cycle_harrying.2010
# 100 = ep3_story_cycle_harrying.2015
# }
#}
#
##Events specifically for Hereward the Wake
#ongoing_harrying_hereward_events = {
# random_events = {
# chance_of_no_event = 90
# delay = { days = { 60 90 } }
#
# 100 = ep3_story_cycle_harrying.3000
# 100 = ep3_story_cycle_harrying.3005
# 100 = ep3_story_cycle_harrying.3010
# 100 = ep3_story_cycle_harrying.3015
# 100 = ep3_story_cycle_harrying.3020
# 50 = ep3_story_cycle_harrying.3050
# 100 = ep3_laamps.7001
# }
#}
#

View file

@ -0,0 +1,18 @@
##Events for Violet Poet
#ongoing_violet_poet_owner_events = {
# random_events = {
# chance_of_no_event = 50
# delay = { days = { 40 80 } }
#
# 100 = ep3_story_cycle_violet_poet.1005%
# 100 = ep3_story_cycle_violet_poet.1010
# 100 = ep3_story_cycle_violet_poet.1015
# 100 = ep3_story_cycle_violet_poet.1020
# 100 = ep3_story_cycle_violet_poet.1025
# 100 = ep3_story_cycle_violet_poet.1030
#
# #Ibn Zaydun chain
# 100 = ep3_story_cycle_violet_poet.2000
# }
#}
#

View file

@ -0,0 +1,168 @@
#fp2_lyonese_monk_events_cycle = {
# effect = {
# # Should things invalidate?
# if = {
# limit = { fp2_lyonese_monk_0000_valid_for_events_trigger = no }
# # Scope:acolyte has died or is no longer your courtier or vassal.
# if = {
# limit = { fp2_lyonese_monk_0000_out_of_realm_trigger = yes }
# trigger_event = fp2_lyonese_monk.0021
# }
# # Your incarceration causes scope:acolyte to disappear - and the story along with HerHim.
# else_if = {
# limit = { fp2_lyonese_monk_0000_out_of_freedom_trigger = yes }
# trigger_event = fp2_lyonese_monk.0051
# }
# # The destruction of the Papacy leaves little room in everyone's hearts for the minutiae of doctrine.
# else_if = {
# limit = { fp2_lyonese_monk_0000_out_of_popes_trigger = yes }
# trigger_event = fp2_lyonese_monk.0041
# }
# # You or scope:acolyte are no longer the correct faith.
# else_if = {
# limit = { fp2_lyonese_monk_0000_out_of_faith_trigger = yes }
# trigger_event = fp2_lyonese_monk.0031
# }
# }
# # If not, run the usual.
# else = {
# # Phase: Private Teachings
# ## Gateway event
# if = {
# limit = { scope:story.var:lm_phase_tally = 0 }
# trigger_event = fp2_lyonese_monk.0201
# }
# ## Random events
# else_if = {
# limit = {
# scope:story.var:lm_phase_tally >= 1
# scope:story.var:lm_phase_tally <= 3
# }
# trigger_event = { on_action = fp2_lyonese_monk_events_phase_teachings_events }
# }
# ## Gateway event
# else_if = {
# limit = { scope:story.var:lm_phase_tally = 4 }
# trigger_event = fp2_lyonese_monk.0241
# }
# # Phase: Public Controversy
# ## Gateway event
# else_if = {
# limit = { scope:story.var:lm_phase_tally = 5 }
# trigger_event = fp2_lyonese_monk.0401
# }
# ## Random events
# else_if = {
# limit = {
# scope:story.var:lm_phase_tally >= 6
# scope:story.var:lm_phase_tally <= 8
# }
# trigger_event = { on_action = fp2_lyonese_monk_events_phase_controversy_events }
# }
# ## Gateway event
# else_if = {
# limit = { scope:story.var:lm_phase_tally = 9 }
# trigger_event = fp2_lyonese_monk.0441
# }
# # Phase: Schism
# ## Gateway event
# else_if = {
# limit = { scope:story.var:lm_phase_tally = 10 }
# trigger_event = fp2_lyonese_monk.0601
# }
# ## Random events
# else_if = {
# limit = {
# scope:story.var:lm_phase_tally >= 11
# scope:story.var:lm_phase_tally <= 13
# }
# trigger_event = { on_action = fp2_lyonese_monk_events_phase_schism_events }
# }
# ## Gateway event
# else = { trigger_event = fp2_lyonese_monk.0641 }
# }
# }
#}
#
#fp2_lyonese_monk_events_phase_teachings_events = {
# random_events = {
# 100 = fp2_lyonese_monk.0211
# 100 = fp2_lyonese_monk.0221
# 100 = fp2_lyonese_monk.0231
# }
# fallback = fp2_lyonese_monk_events_cycle_no_valid_events_fallback
#}
#
#fp2_lyonese_monk_events_phase_controversy_events = {
# random_events = {
# 100 = fp2_lyonese_monk.0411
# 100 = fp2_lyonese_monk.0421
# 100 = fp2_lyonese_monk.0431
# }
# fallback = fp2_lyonese_monk_events_cycle_no_valid_events_fallback
#}
#
#fp2_lyonese_monk_events_phase_schism_events = {
# random_events = {
# 100 = fp2_lyonese_monk.0611
# 100 = fp2_lyonese_monk.0621
# 100 = fp2_lyonese_monk.0631
# }
# fallback = fp2_lyonese_monk_events_cycle_no_valid_events_fallback
#}
#
#fp2_lyonese_monk_events_cycle_no_valid_events_fallback = {
# effect = {
# # Should things invalidate?
# if = {
# limit = { fp2_lyonese_monk_0000_valid_for_events_trigger = no }
# # Scope:acolyte has died or is no longer your courtier or vassal.
# if = {
# limit = { fp2_lyonese_monk_0000_out_of_realm_trigger = yes }
# trigger_event = fp2_lyonese_monk.0021
# }
# # Your incarceration causes scope:acolyte to disappear - and the story along with HerHim.
# else_if = {
# limit = { fp2_lyonese_monk_0000_out_of_freedom_trigger = yes }
# trigger_event = fp2_lyonese_monk.0051
# }
# # The destruction of the Papacy leaves little room in everyone's hearts for the minutiae of doctrine.
# else_if = {
# limit = { fp2_lyonese_monk_0000_out_of_popes_trigger = yes }
# trigger_event = fp2_lyonese_monk.0041
# }
# # You or scope:acolyte are no longer the correct faith.
# else_if = {
# limit = { fp2_lyonese_monk_0000_out_of_faith_trigger = yes }
# trigger_event = fp2_lyonese_monk.0031
# }
# }
# # If not, run the usual.
# else = {
# # Increment the incident tally by 1 if we're not at a cap event.
# if = {
# limit = {
# NOR = {
# scope:story.var:lm_phase_tally = 0
# scope:story.var:lm_phase_tally = 4
# scope:story.var:lm_phase_tally = 5
# scope:story.var:lm_phase_tally = 9
# scope:story.var:lm_phase_tally = 10
# }
# }
# scope:story = {
# change_variable = {
# name = lm_phase_tally
# add = 1
# }
# }
# }
# # Run the cycle again.
# trigger_event = {
# on_action = fp2_lyonese_monk_events_cycle
# months = { 2 5 }
# }
# }
# }
#}
#

View file

@ -0,0 +1,74 @@
# On actions for knight events, triggered automatically by the game
# Called for commanders when combat ends
# root is the commander
# scope:combat_side is the side of combat the commander is on
# scope:victory is whether the commander's side won
on_commander_combat_finished = {
trigger = {
scope:victory = no
}
events = {
# DISABLED as how this is handled is undergoing a rework.
#commanders.0011 # Commander captured after combat.
}
}
# called on every unique owner of an army on combat end
# root is the owning character
# scope:combat_side is the side of combat the commander is on
# scope:victory is whether the commander's side won
# commanders is a list of all commanders in the combat
# knights is a list of all knights in the combat
on_army_combat_finished = {
}
# Used for handling the Varangian guard
varangian_ongoing = {
trigger = {
has_character_flag = is_currently_varangian
}
effect = {
#Verify if the character became landed: in that case, remove the flag
if = {
limit = {
is_ruler = yes
}
remove_character_flag = is_currently_varangian
}
else = {
#debug_log = "Fired the varangian_ongoing pulse"
#debug_log_scopes = yes
change_variable = { # NOTE: Will *not* be relevant to non-delayed trigger evaluations for the events below
name = years_as_varangian
add = 1
}
trigger_event = {
on_action = varangian_ongoing
days = { 340 380 }
}
}
}
random_events = {
500 = 0
# 500 = varangian.1001 # Return home
# 100 = varangian.2001 # Become Best Friends with another Varangian
# 100 = varangian.2002 # Become Lover with another Varangian
# 100 = varangian.2003 # Become Friends with a local ruler
# 100 = varangian.2004 # Become Rival with a local ruler
# 300 = varangian.2005 # Marry Lover
# 100 = varangian.2008 # Get wounded
# 100 = varangian.2011 # Get local Lover
# 200 = varangian.2012 # Increase Prowess
# 200 = varangian.2013 # Increase Martial
# 200 = varangian.2014 # Increase Learning
# 200 = varangian.2015 # Increase Diplomacy
# 50 = varangian.2016 # Become Brave
# 50 = varangian.2017 # Become Ambitious
# 50 = varangian.2018 # Become Diligent
}
}

View file

@ -0,0 +1,875 @@
# root: The province in which the building was completed
# scope:character: The character that paid for the construction, if available
on_building_completed = {
effect = {
#save the county holder as the character in case the construction wasn't started through GUI or by the AI
if = {
limit = {
NOT = { exists = scope:character }
}
root.county.holder = {
save_scope_as = character
}
}
root = {
# Preservation tenet
if = {
limit = {
scope:character.faith = { has_doctrine_parameter = building_temples_gives_development }
OR = {
has_holding_type = church_holding
has_holding_type = temple_citadel_holding
}
NOT = { county = { has_variable = dev_gain_cooldown } }
}
scope:character = {
send_interface_toast = {
title = building_temples_gives_development_toast
left_icon = root
root.county = {
change_development_progress_with_overflow = minor_development_progress_gain
set_variable = {
name = dev_gain_cooldown
value = yes
days = 365
}
}
}
}
}
# Hard working Tradition
if = {
limit = {
culture = { has_cultural_parameter = development_gain_on_building_complete }
NOT = { county = { has_variable = dev_gain_cooldown } }
}
county = {
change_development_progress_with_overflow = 25
set_variable = {
name = dev_gain_cooldown
value = yes
days = 365
}
}
}
# Metal crafting Tradition
if = {
limit = {
culture = { has_cultural_parameter = prestige_gain_on_building_complete_in_mountains }
OR = {
terrain = mountains
terrain = desert_mountains
}
}
scope:character = {
if = {
limit = {
is_alive = yes
}
add_prestige = medium_prestige_value
}
}
}
# Yashima
if = {
limit = {
culture = { has_cultural_parameter = prestige_gain_on_building_complete_in_mountains_forest }
OR = {
terrain = mountains
terrain = forest
}
}
scope:character = {
if = {
limit = {
is_alive = yes
}
add_prestige = medium_prestige_value
}
}
}
# Sacred Mountains Tradition
if = {
limit = {
scope:character.culture = { has_cultural_parameter = piety_gain_on_building_complete_in_mountains }
OR = {
terrain = mountains
terrain = desert_mountains
}
}
scope:character = {
if = {
limit = {
is_alive = yes
}
add_piety = minor_piety_value
}
}
}
# Sacred Groves Tradition
if = {
limit = {
scope:character.culture = { has_cultural_parameter = piety_gain_on_building_complete_in_forest_taiga }
OR = {
terrain = forest
terrain = taiga
terrain = jungle
}
}
scope:character = {
if = {
limit = {
is_alive = yes
}
add_piety = minor_piety_value
}
}
}
# FP2 Dynasty perk
if = {
limit = {
has_holding_type = city_holding
exists = scope:character.dynasty
scope:character.dynasty = {
has_dynasty_perk = fp2_urbanism_legacy_4
}
}
county = {
holder = {
if = {
limit = {
is_alive = yes
}
send_interface_toast = {
type = event_toast_effect_good
title = prestige_gained_from_building_completion
left_icon = root.barony
add_prestige = medium_prestige_gain
}
}
}
#### Chance to add super guest!
# Set variables
random = {
chance = 10
modifier = {
add = county.development_level
}
set_variable = {
name = number_prestigious_new_guests
value = 1
}
if = {
limit = { county.development_level >= max_development_level }
set_variable = {
name = holding_quality
value = 3
}
}
else_if = {
limit = { county.development_level >= great_development_level }
set_variable = {
name = holding_quality
value = 3
}
}
else_if = {
limit = { county.development_level >= good_development_level }
set_variable = {
name = holding_quality
value = 2
}
}
else_if = {
limit = { county.development_level >= medium_development_level }
set_variable = {
name = holding_quality
value = 2
}
}
else_if = {
limit = { county.development_level >= bad_development_level }
set_variable = {
name = holding_quality
value = 1
}
}
else = {
set_variable = {
name = holding_quality
value = 1
}
}
}
holder = {
# Trigger the hidden event
if = {
limit = {
is_alive = yes
}
trigger_event = fp2_other_decisions.0001
}
}
}
}
# Struggle parameters
if = {
limit = {
has_holding_type = castle_holding
scope:character = {
any_character_struggle = {
involvement = involved
has_struggle_phase_parameter = completing_building_in_castle_gives_development
}
}
}
county = { change_development_progress_with_overflow = 10 }
}
if = {
limit = {
has_holding_type = church_holding
scope:character = {
any_character_struggle = {
involvement = involved
has_struggle_phase_parameter = completing_building_in_temple_gives_piety
}
}
}
scope:character = { add_piety = medium_piety_gain }
}
# Struggle catalysts
if = {
limit = {
has_holding_type = castle_holding
scope:character = {
any_character_struggle = {
involvement = involved
phase_has_catalyst = catalyst_new_building_in_castle
}
}
}
scope:character = {
every_character_struggle = {
involvement = involved
activate_struggle_catalyst = {
catalyst = catalyst_new_building_in_castle
character = scope:character
}
}
}
}
else_if = {
limit = {
has_holding_type = city_holding
scope:character = {
any_character_struggle = {
involvement = involved
phase_has_catalyst = catalyst_new_building_in_city
}
}
}
scope:character = {
every_character_struggle = {
involvement = involved
activate_struggle_catalyst = {
catalyst = catalyst_new_building_in_city
character = scope:character
}
}
}
}
else_if = {
limit = {
has_holding_type = church_holding
scope:character = {
any_character_struggle = {
involvement = involved
phase_has_catalyst = catalyst_new_building_in_temple
}
}
}
scope:character = {
every_character_struggle = {
involvement = involved
activate_struggle_catalyst = {
catalyst = catalyst_new_building_in_temple
character = scope:character
}
}
}
}
if = {
limit = {
has_holding_type = church_holding
county.faith.religion = religion:islam_religion
scope:character = {
any_character_struggle = {
involvement = involved
phase_has_catalyst = catalyst_new_islamic_temple_construction
}
}
}
scope:character = {
every_character_struggle = {
involvement = involved
activate_struggle_catalyst = {
catalyst = catalyst_new_islamic_temple_construction
character = scope:character
}
}
}
}
if = {
limit = {
scope:character = {
any_character_struggle = {
involvement = involved
phase_has_catalyst = catalyst_new_building_in_holdings
}
}
}
scope:character = {
every_character_struggle = {
involvement = involved
activate_struggle_catalyst = {
catalyst = catalyst_new_building_in_holdings
character = scope:character
}
}
}
}
# Points of Interest
# Apply them here directly so they are more promptly added than monthly via the POI update
if = {
limit = {
has_special_building = no
}
}
else_if = {
limit = {
OR = {
has_building_with_flag = { flag = travel_point_of_interest_martial }
has_building_with_flag = { flag = travel_point_of_interest_martial_minor }
}
NOT = { has_travel_point_of_interest = poi_special_buildings_martial }
}
add_travel_point_of_interest = poi_special_buildings_martial
}
else_if = {
limit = {
has_building_with_flag = { flag = travel_point_of_interest_learning }
NOT = { has_travel_point_of_interest = poi_special_buildings_learning }
}
add_travel_point_of_interest = poi_special_buildings_learning
}
else_if = {
limit = {
has_building_with_flag = { flag = travel_point_of_interest_religious }
NOT = { has_travel_point_of_interest = poi_special_buildings_religious }
}
add_travel_point_of_interest = poi_special_buildings_religious
}
else_if = {
limit = {
has_building_with_flag = { flag = travel_point_of_interest_diplomatic }
NOT = { has_travel_point_of_interest = poi_special_buildings_diplomatic }
}
add_travel_point_of_interest = poi_special_buildings_diplomatic
}
else_if = {
limit = {
has_building_with_flag = { flag = travel_point_of_interest_wonder }
NOT = { has_travel_point_of_interest = poi_special_buildings_wonder }
}
add_travel_point_of_interest = poi_special_buildings_wonder
}
else_if = {
limit = {
has_building_with_flag = { flag = travel_point_of_interest_economic }
NOT = { has_travel_point_of_interest = poi_special_buildings_economic }
}
add_travel_point_of_interest = poi_special_buildings_economic
}
# The Builder event chain
if = {
limit = {
has_variable = the_builder_holding
NOT = { has_variable = the_builder_finished }
}
var:the_builder_holding = { save_scope_as = holding_initiator }
#Did the Builder actually finish the holding, or was it cancelled?
scope:holding_initiator = {
if = {
limit = {
is_alive = yes
is_landed_or_landless_administrative = yes
is_available = yes
}
#Then remove the safeguard event that would clean up the Builder
if = {
limit = { has_variable = the_builder_holding_cancelled_safeguard }
remove_variable = the_builder_holding_cancelled_safeguard
}
#And trigger reward event
trigger_event = bp2_yearly.1071
}
}
set_variable = { name = the_builder_finished }
}
# Every time the Builder builds in their holding...
if = {
limit = {
scope:character ?= {
OR = {
has_character_modifier = the_city_builder_modifier
has_character_modifier = the_castle_builder_modifier
has_character_modifier = the_temple_builder_modifier
}
}
}
county = { change_development_progress = minor_development_progress_gain }
if = {
limit = {
scope:character ?= { has_character_modifier = the_city_builder_modifier }
}
scope:character = { add_gold = minor_gold_value }
}
if = {
limit = {
scope:character ?= { has_character_modifier = the_castle_builder_modifier }
}
scope:character = { add_prestige = minor_prestige_gain }
}
if = {
limit = {
scope:character ?= { has_character_modifier = the_temple_builder_modifier }
}
scope:character = { add_piety = minor_piety_gain }
}
}
#end any landless adventurer's construction task contract
if = {
limit = {
any_player = {
any_character_active_contract = {
task_contract_type = laamp_construction_contract
task_contract_employer = scope:character
save_temporary_scope_as = construction_contract
}
}
}
scope:construction_contract = {
if = {
limit = {
task_contract_taker.capital_province.county = root.county
}
complete_task_contract = success_critical
}
else = {
complete_task_contract = failure_standard
}
}
}
# Inspection - Has Holding Modifier
if = {
limit = {
has_province_modifier = inspection_empty_lands_domain_modifier
}
remove_province_modifier = inspection_empty_lands_domain_modifier
add_random_economic_building_effect = yes
}
else_if = {
limit = {
has_province_modifier = inspection_empty_lands_border_modifier
}
remove_province_modifier = inspection_empty_lands_border_modifier
add_random_fortification_building_effect = yes
}
# Admin - Governors get rewards for constructing buildings in governed counties
if = {
limit = {
scope:character = {
OR = {
is_governor = yes
AND = {
min_appointment_tier = tier_county
is_governor_or_admin_count = yes
}
tgp_is_any_minister = yes
}
}
}
scope:character = {
send_interface_message = {
type = msg_governor_duties
title = msg_governor_duties_t
desc = admin_construction_completed_desc
right_icon = root.barony
if = {
limit = {
government_allows = merit
}
change_merit = building_construction_merit_gain_value
if = {
limit = {
tgp_is_any_minister = yes
government_has_flag = government_has_influence
}
change_influence = estate_construction_influence_gain_value
}
}
else = {
change_influence = estate_construction_influence_gain_value
}
if = {
limit = {
building_construction_dynasty_prestige_gain_value > 0
}
dynasty = {
add_dynasty_prestige = building_construction_dynasty_prestige_gain_value
}
}
increase_governance_effect = { VALUE = 4 }
}
}
}
# # Harrying of the North - Pacification Gain
# if = {
# limit = {
# scope:character.culture = culture:norman
# has_global_variable = harrying_of_the_north
# exists = global_var:harrying_of_the_north.story_owner.var:pacification
# }
# global_var:harrying_of_the_north.story_owner = {
# change_variable = {
# name = pacification
# add = 2
# }
# }
# }
# Devaraja consecration event
if = {
limit = {
OR = {
has_building_with_flag = { flag = temple_citadel }
has_building_with_flag = { flag = temple }
has_building_with_flag = { flag = mandala_capital_building }
}
NOT = { has_variable = mandala_consecrated_walls }
scope:character = {
is_available_for_activity_trigger = yes
government_has_flag = government_is_mandala
has_mandala_aspect_trigger = yes
}
}
scope:character = {
trigger_event = devaraja.0005
}
set_variable = {
name = mandala_consecrated_walls
years = 30
}
}
# Brewery counter
brewery_counter_effect = yes
# Coronation Promise
if = {
limit = {
scope:character = root.province_owner.liege
scope:character = { has_character_modifier = coronation_vassal_building_modifier }
}
scope:character = {
send_interface_toast = {
title = coronation_vassal_building_tt
left_icon = root
add_prestige = medium_prestige_gain
}
}
}
}
#####################
# Mandala Government
#####################
scope:character = {
if = {
limit = { government_has_flag = government_is_mandala }
if = {
limit = {
exists = house
house = { has_house_aspiration_parameter = aspect_of_creation }
}
mandala_upgrade_creator_effect = yes
house = {
increment_variable_effect = {
VAR = num_buildings_built
VAL = 1
}
}
}
}
}
# Building Oath
scope:character = {
if = {
limit = {
is_alive = yes
has_variable = stewardship_oath_2_buildings
}
change_variable = {
name = stewardship_oath_2_buildings
add = 1
}
add_to_variable_list = {
name = stewardship_oath_2_building_list
target = root
}
}
}
}
}
# root: The province in which the building was started
# scope:character: The character that paid for the construction, if available
on_building_started = {
effect = {
#save the county holder as the character in case the construction wasn't started through GUI or by the AI
if = {
limit = {
NOT = { exists = scope:character }
}
root.county.holder = {
save_scope_as = character
}
}
if = {
limit = {
OR = {
has_construction_with_flag = temple
has_construction_with_flag = castle
has_construction_with_flag = city
}
any_player = {
has_government = landless_adventurer_government
in_diplomatic_range = scope:character
can_create_task_contract = {
type_name = laamp_construction_contract
employer = scope:character
}
save_temporary_scope_as = player_laamp
}
}
scope:player_laamp = {
create_task_contract = {
task_contract_employer = scope:character
task_contract_type = laamp_construction_contract
task_contract_tier = scope:character.task_contract_tier_value
location = scope:character.capital_province
save_scope_as = new_contract
}
scope:new_contract = {
set_variable = {
name = task_contract_employer
value = scope:character
}
set_variable = {
name = task_contract_destination
value = root
}
}
}
}
if = {
limit = {
has_province_modifier = travel_extra_building_resources_modifier
}
if = {
limit = {
has_variable = extra_building_resources
var:extra_building_resources > 1
}
change_variable = {
name = extra_building_resources
subtract = 1
}
remove_province_modifier = travel_extra_building_resources_modifier
add_province_modifier = travel_extra_building_resources_modifier
}
else = {
remove_province_modifier = travel_extra_building_resources_modifier
remove_variable = extra_building_resources
}
}
}
}
# root: The province in which the building was cancelled
# scope:character: The character that paid for the construction, if available
on_building_cancelled = {
effect = {}
}
# root: The holder of the province doing the razing
# province: The province in which the holding exists
on_holding_razed = {
effect = {
scope:province.county = { set_variable = was_razed }
send_interface_toast = {
title = province_razed_toast_title
left_icon = scope:province.barony
add_gold = {
value = minor_gold_value
add = scope:province.county.development_level
}
scope:province = {
if = {
limit = {
this = county.title_province
county.development_level >= 1
}
county = {
change_development_progress_with_overflow = {
value = scope:province.county.development_level
multiply = 10
multiply = -1
}
}
}
if = {
limit = {
this = county.title_province
county = {
uses_county_fertility = yes
}
}
county = {
change_county_fertility = medium_county_fertility_level_gain
}
}
if = {
limit = {
has_university_building_trigger = yes
}
if = {
limit = {
has_building_or_higher = generic_university
}
remove_building = generic_university
}
else_if = {
limit = {
has_building_or_higher = al_azhar_university
}
remove_building = al_azhar_university
}
else_if = {
limit = {
has_building_or_higher = sankore_university
}
remove_building = sankore_university
}
else_if = {
limit = {
has_building_or_higher = siena_university
}
remove_building = siena_university
}
else_if = {
limit = {
has_building_or_higher = nalanda_university
}
remove_building = nalanda_university
}
else_if = {
limit = {
has_building_or_higher = house_of_wisdom_01
}
remove_building = house_of_wisdom_01
}
else_if = {
limit = {
has_building_or_higher = al_qarawiyyin_university_01
}
remove_building = al_qarawiyyin_university_01
}
else_if = {
limit = {
has_building_or_higher = somapura_university_01
}
remove_building = somapura_university_01
}
else_if = {
limit = {
has_building_or_higher = cluny_abbey_01
}
remove_building = cluny_abbey_01
}
}
}
}
}
}
# root: The holder of the province doing the rebuilding
# province: The province in which the great building exists
on_great_building_rebuilt = {
effect = {
add_piety_experience = {
add = minor_piety_gain
multiply = piety_level
}
hidden_effect = {
if = {
limit = { has_character_modifier = mandala_rise_from_the_ashes_modifier }
remove_character_modifier = mandala_rise_from_the_ashes_modifier
}
if = {
limit = {
NOT = { has_character_flag = devaraja_flag }
has_mandala_aspect_trigger = yes
}
add_character_flag = devaraja_flag
}
}
add_character_modifier = {
modifier = mandala_rise_from_the_ashes_modifier
years = 10
}
#Memory
create_character_memory = { type = rebuilt_mandala_temple_memory }
scope:new_memory ?= {
set_variable = {
name = mandala_capital_rebuilt_location
value = scope:province
}
if = {
limit = { exists = var:mandala_capital_rebuilt_location }
#To prevent 'unused except in loc' errors :catto:
}
}
}
}

View file

@ -0,0 +1,53 @@
# root: is involved (or interloper) character
# Scope:struggle is the currently pulsing struggle.
yearly_struggle_playable_pulse = {
effect = {
}
}
# root: is involved (or interloper) character
# Scope:struggle is the currently pulsing struggle.
five_year_struggle_playable_pulse = {
trigger = {
basic_is_valid_for_yearly_events_trigger = yes
OR = {
fp2_character_interloper_in_struggle_trigger = yes
fp2_character_involved_in_struggle_trigger = yes
}
}
on_actions = {
fp2_iberian_struggle_random_events
}
}
fp2_iberian_struggle_random_events = {
trigger = {
alwasys = no
# fp2_character_involved_in_struggle_trigger = yes
}
random_events = {
chance_to_happen = 95
1 = 0
# 80 = fp2_struggle.1000 #Stoking the Fire
# 50 = fp2_struggle.1001 #War Widows
# 50 = fp2_struggle.1010 #Soul of Iron
# 45 = fp2_struggle.1020 #Death of a Councilman
# 70 = fp2_struggle.2001 #Desperate Villagers Seek New Lord
# #80 = fp2_struggle.2003 #Band of Lost Birds removed for FP3
# 25 = fp2_struggle.2004 #The weights inside this event are a bit high, but since the event is struggle-exclusive it will probably not be an issue
# 70 = fp2_struggle.2006 #The Borders of Faith
# 70 = fp2_struggle.2007 #Castle Worthy of Iberia
# 5 = fp2_struggle.2009 #Catching Thieves of Myth
# 90 = fp2_struggle.3001 #The Price of War Not particularly struggle related, but making it only appear during the struggle makes it more unique and special
# 50 = fp2_struggle.3011 #Order of the Hatchet
# 25 = fp2_struggle.3021 #The Wrath of Heaven Usually the lower chance is because the effects are too great, in this case it is to ensure people don't think every other iberian had discovered han powder.
}
}
fp2_iberian_struggle_starting_events = {
events = {
# neutral_struggle.0001
# fp2_struggle.0003
}
}

View file

@ -3058,7 +3058,7 @@ on_title_gain_usurpation = {
} }
} }
trigger_event = NEOW_dynamic_titles.0014 trigger_event = NEOW_dynamic_titles.0014
} }
###################################################### ######################################################
@ -3080,18 +3080,8 @@ on_title_gain_usurpation = {
} }
} }
scope:title = { scope:title = {
limit = {
is_nomad_title = no
tier = tier_county
scope:title.title_province = { scope:title.title_province = {
NOR = { set_holding_type = city_holding
has_holding_type = monotown_holding
has_holding_type = city_holding
}
}
}
scope:title.title_province = {
set_holding_type = city_holding
} }
} }
} }

View file

@ -0,0 +1,425 @@
fp1_yearly_events = {
trigger = { fp1_eligible_for_yearly_events_trigger = yes }
weight_multiplier = {
base = 1
modifier = { # Reduces frequency for characters with non-matching cultures
factor = 0.33
religion = religion:germanic_religion
NOT = {
culture = { has_cultural_pillar = heritage_north_germanic }
}
}
modifier = { # Reduces frequency for having both sets of FP events valid
factor = 0.5
OR = {
fp2_eligible_for_yearly_events_trigger = yes
fp3_eligible_for_yearly_events_trigger = yes
}
}
}
random_events = {
chance_to_happen = 65
200 = 0
# Other Events
# 100 = varangian.0001
200 = trait_specific.9001 # Become Poet
#FP1 Events
## Shieldmaidens
100 = fp1_shieldmaiden.0001 # A wrong-gender courtier wishes to fight for you.
400 = fp1_shieldmaiden.0032 # Your shieldmaiden improves their skills.
## General Yearlies
200 = fp1_yearly.0001 # Escaped Thrall - A thrall leaves your court in the night.
200 = fp1_yearly.0011 # Calls for Courtier to be Declared Nithing - Locals call for one of your courtiers to be exiled.
200 = fp1_yearly.0021 # A Matter of Life and Death - Two knights fight to the death over nothing.
200 = fp1_yearly.0031 # Tall Tales at the Table - A deceitful warrior is telling tall-tales at court.
100 = fp1_yearly.0041 # Explorers from the South - An Islamic explorer stops by for a visit.
200 = fp1_yearly.0051 # The Unquiet Dead - You are informed of a reputed-draugr.
200 = fp1_yearly.0071 # In the Deep Places of the World - locals in your Scandi capital report a troll.
200 = fp1_yearly.0091 # A Vessel fit for a Ruler - commissioning a personal longship.
200 = fp1_yearly.0101 # A Game of Riddles - a courtier challenges you to a game of riddles.
200 = fp1_yearly.0111 # Accursed - one of your courtiers is the victim of a nithing pole.
200 = fp1_yearly.2000 # A Child wants to run away to marry their beloved
300 = fp1_yearly.2100 # Two lovers duel for your love
200 = fp1_yearly.2200 # Berserker rampages though court
200 = fp1_yearly.2300 # Convince a group of soldiers to join you
200 = fp1_yearly.2400 # Invest in something that'll aid in your hunts
200 = fp1_yearly.2600 # Become a Berserker
## Flavour Yearlies
200 = fp1_yearly.0501 # Out for a Sail - you spot a ship in distress.
200 = fp1_yearly.0511 # The Stench of Success - a courtier won't let an old trophy go.
200 = fp1_yearly.0521 # Blood on the Snow - your child wishes to snowball fight.
200 = fp1_yearly.0531 # [Dynasty] on Ice - your child wants to learn how to ice skate.
200 = fp1_yearly.0541 # The Beast of [Capital] - your child is playing pranks on courtiers.
200 = fp1_yearly.0551 # Fishy Business - a courtier won't stop eating rotten fish.
200 = fp1_yearly.0561 # My Arm Against Yours - a knight challenges you to arm-wrestling.
200 = fp1_yearly.0571 # Petty Vandalism - your child has vandalised a runestone.
200 = fp1_yearly.0581 # When I Grow Up - your child wishes to be a shieldperson.
200 = fp1_yearly.0591 # Raised Voices at the Thing - two of your counties are fighting at a regional thing.
200 = fp1_yearly.0601 # The Hardest Part of Ruling - you're incredibly bored in a protracted thing session.
200 = fp1_yearly.0611 # Leading by Example - one of your children hurts another whilst imitating you.
200 = fp1_yearly.0641 # Worthy of the Ocean - your longships are in disrepair.
200 = fp1_yearly.0651 # Leviathan - you spot a whale whilst sailing.
200 = fp1_yearly.0661 # A Novel Challenge - a knight challenges you to skiing.
200 = fp1_yearly.0671 # A Slippery Slope - your child wants to go sledding.
200 = fp1_yearly.0681 # Why Can't I Come? - your child wants to come raiding.
200 = fp1_yearly.0691 # Attempted Atonement - a knight has converted after raiding a reformed faith.
## Special Yearlies
50 = fp1_yearly.1001 # You notice a stranger has been hanging around the court.
50 = fp1_yearly.1071 # Sparklingly Clean
50 = fp1_yearly.1081 # An explorer of the Atlantic wishes to share their tales with you.
5 = fp1_yearly.2500 # What's that deviant up to this time!?
1000 = fp1_major_decisions.1001 # Canute & the Tide
## Jomsvikings
# 500 = fp1_jomsvikings.0001 # FP1 - Jomsvikings offer a Retainer
# 500 = fp1_jomsvikings.0021 # FP1 - Jomsvikings send Event Troops
# 1000 = fp1_jomsvikings.0041 # FP1 - Jomsvikings move to execute a stain on the faith.
}
}
fp2_yearly_events = {
trigger = {
# has_fp2_dlc_trigger = yes
always = no
# Most events are geographical in nature
# capital_province ?= { geographical_region = world_europe_west_iberia }
}
weight_multiplier = {
base = 1
modifier = { # Reduces frequency for characters with non-matching cultures
factor = 0.33
NOT = {
culture = { has_cultural_pillar = heritage_iberian }
}
}
modifier = { # Reduces chance after recently having had an event from this pulse
factor = 0.2
has_character_flag = recently_got_fp2_event
}
modifier = { # Reduces frequency for having both sets of FP events valid
factor = 0.5
OR = {
fp1_eligible_for_yearly_events_trigger = yes
fp3_eligible_for_yearly_events_trigger = yes
}
}
}
random_events = {
200 = 0
# FP2 - Fate of Iberia Events
# 160 = fp2_yearly.1001 # Chess Two
# 10 = fp2_yearly.1002 # A Compromising Position
# 160 = fp2_yearly.1003 # Tilting at...Giants?
# 160 = fp2_yearly.1004 # The Hawk of Quraysh
# 160 = fp2_yearly.1005 # Lost Viking
# 80 = fp2_yearly.1006 # Viking Cheese?
# 180 = fp2_yearly.2020 # Horchata colonialism event
# 160 = fp2_yearly.4004 # The Wandering Master
# 160 = fp2_yearly.4005 # Establishing Enclaves
# 160 = fp2_yearly.4006 # God's Architect
# 160 = fp2_yearly.8000 # Burning the Vineyards
# 180 = fp2_yearly.8001 # Assembling the Cortes
# 160 = fp2_yearly.8002 # A Dietary Dilemma
# 160 = fp2_yearly.8003 # Flight of Fancy
# 160 = fp2_yearly.8004 # The Toledo School of Translation
# 160 = fp2_yearly.8005 # Under the Stone Pine
# 160 = fp2_yearly.8006 # Saqaliba Settlers
# 180 = fp2_struggle.1002 # Xenophilic Advancment
# 160 = fp2_struggle.1050 # Dreams of Destruction
# 150 = fp2_struggle.2000 # Disorderly Market
# 140 = fp2_struggle.2008 # Misdeeds of the Councillor
# 350 = fp2_struggle.2013 # The Secret to Freedom
# 130 = fp2_struggle.2015 # Letter on the Back
# 180 = fp2_yearly.2025 # Suffering from Success
# 150 = fp2_yearly.4001 # You fancy a little siesta
# 150 = fp2_yearly.4002 # A county is increasingly religiously intertwined
# 150 = fp2_yearly.4003 # The road to Santiago is under threat from bandits
# 150 = fp2_yearly.4007 # Finding a shell on the road to Santiago
# 150 = fp2_yearly.4008 # Folk stories around the fireside
# 300 = fp2_yearly.4009 # Visiting the Malato Tree
# 150 = fp2_yearly.4010 # Finding a Verraco
# 300 = fp2_yearly.3000 # Neighboring Muslims are growing rice, adopt the practice yourself?
# 100 = bell_special_yearly.1000 # The bell of Huesca yearly
# 150 = fp2_yearly.9000 # Thriving Jewish Community
# 150 = fp2_yearly.9001 # Suspect Conversos of secretly praciticing Judaism
# 150 = fp2_yearly.9002 # Jewish people come fleeing persecution from a nearby realm
# 150 = fp2_yearly.9005 # Toledan Nights
# 50 = fp2_yearly.9006 # Local bishop mad his church faces the wrong way
}
effect = {
root = {
add_character_flag = {
flag = recently_got_fp2_event
days = 1095 # 3 years
}
}
}
}
bp1_yearly_events = { # Disabled in yearly_on_actions
trigger = {
has_dlc_feature = friends_and_foes
OR = {
any_relation = { type = friend }
any_relation = { type = rival }
}
}
weight_multiplier = {
base = 1
modifier = { # Increase frequency the more you fit the conditions
add = 0.25
any_relation = { type = friend }
}
modifier = { # Increase frequency the more you fit the conditions
add = 0.25
any_relation = { type = rival }
}
modifier = { # Increase frequency the more you fit the conditions
add = 0.25
any_relation = { type = best_friend }
}
modifier = { # Increase frequency the more you fit the conditions
add = 0.25
any_relation = { type = nemesis }
}
}
random_events = {
200 = 0
#BP1 Events
100 = bp1_yearly.1000 # Best friend introduces you to a new hobby
200 = bp1_yearly.1010 # A friend offers to mediate with your HoF who has excommunicated you
500 = bp1_yearly.1020 # A friend visits you on your dying bed
500 = bp1_yearly.1021 # You visit a friend on their dying bed
500 = bp1_yearly.1030 # A rival visits you on your dying bed
500 = bp1_yearly.1031 # You visit a rival on their dying bed
100 = bp1_yearly.1040 # You make a new friend at the bathhouse
50 = bp1_yearly.1050 # You make a new rival at the bathhouse
100 = bp1_yearly.1060 # React to a superstitious friend
150 = bp1_yearly.1061 # Make someone superstitious - hidden
100 = bp1_yearly.1070 # Rival is superstitious - take advantage?
100 = bp1_yearly.1080 # Married off relative writes home
400 = bp1_yearly.1082 # Married off relative writes home to share a secret
100 = bp1_yearly.2000 # Spoil your partner(s), learn a secret/hook followup
400 = bp1_yearly.2010 # Two of your spouses/concubines are lovers!
100 = bp1_yearly.2020 # A consort attempts to influence you into changing your heir
100 = bp1_yearly.2030 # Mopey consort wants some guidance
100 = bp1_yearly.2040 # Consort is upset with other consort
100 = bp1_yearly.2050 # Friendly consorts wants to start a study circle
200 = bp1_yearly.2060 # Friendly consorts want to tutor other consort's child
100 = bp1_yearly.2070 # Childless older soulmate spouse ponders your relationship
100 = bp1_yearly.3001 # Friend spots you some cash
100 = bp1_yearly.3002 # You spot your friend some cash
100 = bp1_yearly.3007 # Spouse's family member wants you to sponsor their inspiration
100 = bp1_yearly.3100 # Your vassal/friend/family member offers you a skilled courtier
20 = bp1_yearly.3101 # Friend offers to sell you a county you have a claim on
100 = bp1_yearly.3201 # Fake feast invite from rival/nemesis
100 = bp1_yearly.3300 # Remembering a pilgrimage
200 = bp1_yearly.3301 # Remembering a pilgrimage w/ a friend
100 = bp1_yearly.4000 # Reflect over a family memory
100 = bp1_yearly.4010 # Spouse demands their child gets a better guardian
100 = bp1_yearly.4020 # Friend writes poetry about a war memory
250 = bp1_yearly.4030 # Rival nestles their way into marrying one of your vassals, turns them disloyal
10 = bp1_yearly.4040 # Kindly grandmother won't stop feeding you snacks; suffer the consequences of overeating, or break her heart?
50 = bp1_yearly.5301 # Your friend is concerned about your physique
150 = bp1_yearly.5100 # Chadsplaining to a plain courtier
150 = bp1_yearly.5701 # Your Friend's Spouse Is Keeping Them Away From You
100 = bp1_yearly.5702 # You ask a friend for help with skill
200 = bp1_yearly.5703 # Your lover/rival threatens you in bed
100 = bp1_yearly.5704 # Your rival seems strangely... attractive?
200 = bp1_yearly.5705 # Your friend tries to talk you out of a bad relationship
100 = bp1_yearly.5706 # You sleep with your rival's offspring
400 = bp1_yearly.5707 # Your rival catches you sleeping with their offspring
100 = bp1_yearly.5708 # You empathise with a friend's faith
100 = bp1_yearly.5709 # Tempers flare between you and your rival
70 = bp1_yearly.5713 # Your lover asks for money
100 = bp1_yearly.5715 # You and a friend argue about pronunciation
100 = bp1_yearly.5716 # Your zealous wife burns books
100 = bp1_yearly.5717 # Your rival and your friend get into a drunken brawl
100 = bp1_yearly.5719 # Your disloyal vassal is trying to embezzle
100 = bp1_yearly.5720 # You and your rival armwrestle
200 = bp1_yearly.5722 # Your nemesis launches your pet out of a catapult
100 = bp1_yearly.5725 # You search for Khutulun
50 = bp1_yearly.5728 # Rival steals and burns one of your artifacts
10 = bp1_yearly.5740 # Scrambling for Answers
80 = bp1_yearly.5800 # You make a perfume
125 = bp1_yearly.6000 # Attacked by Rival's Child / Family Feud
100 = bp1_yearly.7000 # Go on a picnic
100 = bp1_yearly.7001 # Go fishing
10 = bp1_yearly.7002 # Throw chamberpot at rival
25 = bp1_yearly.7003 # Orgy Tapestry
100 = bp1_yearly.7004 # Friend offers to talk about bad memory
100 = bp1_yearly.7010 # Loyalty test
100 = bp1_yearly.7050 # Memory of a war
100 = bp1_yearly.7051 # Memory of Battle
100 = bp1_yearly.7052 # Telling a story of a memory
100 = bp1_yearly.7053 # A memory of revenge
100 = bp1_yearly.7054 # Forgetting a memory
100 = bp1_yearly.7055 # Recording a memory
100 = bp1_yearly.7056 # Intimidating someone
150 = bp1_yearly.7057 # Yearning
100 = bp1_yearly.7058 # Friend eats all your food
100 = bp1_yearly.8000 # Claimant moving towards rivalry
200 = bp1_yearly.8010 # Best friend offers you a negotiated alliance
100 = bp1_yearly.8020 # Rival of your rival offers friendship
100 = bp1_yearly.8040 # Friend with conflicting personality falls out with you
100 = bp1_yearly.9001 # Bully/guardian destroys your favourite toy
100 = bp1_yearly.9005 # You get revenge for your destroyed toy
100 = bp1_yearly.9006 # Becoming friends over a common sin
10 = bp1_yearly.9007 # You find a peasant who looks exactly like you
50 = bp1_yearly.9016 # Uppity second-in-line wants the throne
50 = bp1_yearly.9017 # Uppity child is insecure about culture
200 = bp1_yearly.9018 # Illegitimate child feels excluded
100 = bp1_yearly.9019 # Spouse proposes a gay threesome
200 = bp1_yearly.9020 # Spouse wants to do something kinky
100 = bp1_yearly.9021 # Rival spouse is good in the bedroom
100 = bp1_yearly.9022 # Friend holds an intervention
200 = bp1_yearly.9023 # You realise you don't speak the same language
100 = bp1_yearly.9024 # A friend visits you while you're sick
150 = bp1_yearly.9025 # You realise you hate your friend
100 = bp1_yearly.9026 # You're haunted by an old friend who convinces you to make amends before you die
100 = bp1_yearly.9040 # The ghost of your dead lover wants to have sex again
100 = bp1_yearly.9042 # Your chaplain finds a dessert that looks like HealthGodName
100 = bp1_yearly.9043 # Your chaplain admits to being a deviant and a cannibal who eats babies
100 = bp1_yearly.9047 # Lover wants you to wear their hair
100 = bp1_yearly.9048 # Nemesis wants to end your rivalry by wrestling
100 = bp1_yearly.9050 # You and a friend share war stories
20 = bp1_yearly.7100 # Excreta incident, gain Nemesis
# Family Feud
5 = bp1_house_feud.0001 # Consider starting feud against own rival's house
5 = bp1_house_feud.0002 # Consider starting feud against house family member rivals
5 = bp1_house_feud.0003 # Consider starting feud against house who killed close family
5 = bp1_house_feud.0006 # Consider starting feud against house with competing claims
5 = bp1_house_feud.0007 # Consider starting feud against house who imprisoned you a while
5 = bp1_house_feud.0008 # Consider starting feud against house who imprisoned family a while
5 = bp1_house_feud.0012 # Consider starting feud against house who cuckolded you
}
}
fp3_yearly_events = {
trigger = {
has_fp3_dlc_trigger = yes
# Most events are geographical in nature
capital_province = { geographical_region = world_persian_empire }
}
weight_multiplier = {
base = 1
modifier = { # Reduces frequency for characters with non-matching cultures
factor = 0.33
NOR = {
culture = { has_cultural_pillar = heritage_iranian }
culture = { has_cultural_pillar = heritage_turkic }
culture = { has_cultural_pillar = heritage_mongolic }
culture = { has_cultural_pillar = heritage_arabic }
}
}
modifier = { # Reduces chance after recently having had an event from this pulse
factor = 0.2
has_character_flag = recently_got_fp3_event
}
modifier = { # Reduces frequency for having other sets of FP events valid
factor = 0.5
OR = {
fp1_eligible_for_yearly_events_trigger = yes
fp2_eligible_for_yearly_events_trigger = yes
}
}
}
random_events = {
200 = 0
# Frontier Events
250 = fp3_yearly.8000 # Ghazi Gone Bad
250 = fp3_yearly.8001 # Frontier Fortress Benefactor
250 = fp3_yearly.8002 # Faith at the Frontier
350 = fp3_yearly.8003 # Exotic Espand
350 = fp3_yearly.8004 # The Frontier Beckons
350 = fp3_yearly.8009 # Caliphal Concerns
250 = fp3_yearly.8010 # Abode of War
250 = fp3_yearly.8014 # Secrets of the Teapot
250 = fp3_yearly.8016 # Forgotten Stones & Hyrcanian Havoc
500 = fp3_yearly.8018 # Heavenly Horses
# The Nomads Story Cycle
100 = fp3_yearly.8888 #Grazing Grievances
# Heritage Events
250 = fp3_yearly.8019 # Refuge of Light
250 = fp3_yearly.8020 # The Lady of the Land
350 = fp3_yearly.8021 # An Acidic Accident
500 = fp3_yearly.8024 # The Return to the Sky
350 = fp3_yearly.8027 # Nine-Hundred Ninety Chapters of Gold
250 = fp3_yearly.8033 # Frozen Delights
550 = fp3_yearly.8034 # The Hephthalite Hoard
250 = fp3_yearly.8035 # The Heart and the Creator
250 = fp3_yearly.8036 # The City of the Mouthless
500 = fp3_yearly.8037 # A Cure for Acedia (the Melancholia Chain)
#FP3 - Extra Yearly Events
150 = fp3_yearly.8045 #The Mysterious Bundle (the Buzina Chain)
# Zoroastrian Events
200 = fp3_yearly.8050 #The Fate of the Dead
200 = fp3_yearly.8051 #The Purest Fire
# Guardianship Events
200 = childhood.2400 # Ward approaches guardian with theological doubts
# Clan Events
250 = fp3_clan.8000 # Usury against Unity
250 = fp3_clan.8001 # Clan Quarrel
250 = fp3_clan.8002 # Bonds of Faith
250 = fp3_clan.8003 # The Power of a Name
250 = fp3_clan.8004 # Bonds of Fear
250 = fp3_clan.8005 # A Proper Position
250 = fp3_clan.8006 # Small Spies
125 = fp3_clan.3000 # Ravaged Tulips
# Tax Collector / Clan Events
250 = fp3_clan.1000 # Worth more than Gold?
250 = fp3_clan.1010 # GetHerHis Cup Runneth Over
250 = fp3_clan.1020 # Practical Learning
250 = fp3_clan.1030 # Tax Dispute
250 = fp3_clan.1040 # Mismanaged Land
250 = fp3_clan.8008 #Bleeding them Dry
250 = fp3_clan.8009 #Popular with the People
250 = fp3_clan.8010 #Competent Qadis / More Magistrates
250 = fp3_clan.8011 #A Proper Paymaster
250 = fp3_clan.8012 #Auspicious Avarice
240 = fp3_clan.8013 #The Burden of Tax Farming
250 = fp3_clan.8015 #Scandalous Scion
250 = fp3_clan.8016 #Hammam Havoc
250 = fp3_clan.8017 #A Questionable Position
# Eren events
250 = fp3_yearly.2000 # Daylight Censors
250 = fp3_yearly.2001 # Public Intoxication
100 = fp3_yearly.2011 # Maunds of Wheat for non-royal court users
250 = fp3_yearly.2020 # Set the Scale, Vassal Version
500 = fp3_yearly.2040 # Commander of the Faithful
500 = false_conversion.2000 # A Moment of Weakness
250 = fp3_scholarship.1000 # A Second Aryabhata
}
effect = {
root = {
add_character_flag = {
flag = recently_got_fp3_event
days = 1095
}
}
}
}

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

View file

@ -1488,11 +1488,11 @@ ep3_become_landed_transfer_effect = {
$TITLE_RECEIVER$ = { laamp_clear_domicile_buildings_liquidator_effect = yes } $TITLE_RECEIVER$ = { laamp_clear_domicile_buildings_liquidator_effect = yes }
} }
$TITLE_RECEIVER$ = { $TITLE_RECEIVER$ = {
if = { # if = {
limit = { character:90028 ?= this } # limit = { character:90028 ?= this }
custom_tooltip = ep3_story_cycle_harrying.3053.b.tt # custom_tooltip = ep3_story_cycle_harrying.3053.b.tt
add_character_flag = hereward_settled_flag # add_character_flag = hereward_settled_flag
} # }
set_variable = { set_variable = {
name = ascended_throne_reason name = ascended_throne_reason
value = $REASON$ value = $REASON$
@ -7734,43 +7734,43 @@ remove_dead_charioteer_from_race = {
### END CHARIOT RACE ### END CHARIOT RACE
ep3_send_akolouthos_message_loyal = { #ep3_send_akolouthos_message_loyal = {
send_interface_message = { # send_interface_message = {
type = msg_akolouthos_steels_varangians # type = msg_akolouthos_steels_varangians
title = ep3_akolouthos_events.1000 # title = ep3_akolouthos_events.1000
desc = ep3_akolouthos_events.1000_loyal_notification_tooltip # desc = ep3_akolouthos_events.1000_loyal_notification_tooltip
#
left_icon = scope:trait_getter # left_icon = scope:trait_getter
scope:trait_getter = { # scope:trait_getter = {
add_trait = loyal # add_trait = loyal
add_opinion = { # add_opinion = {
target = root # target = root
modifier = loyalty_opinion # modifier = loyalty_opinion
opinion = 40 # opinion = 40
} # }
} # }
custom_tooltip = akolouthos_effect_tooltip # custom_tooltip = akolouthos_effect_tooltip
} # }
} #}
#
ep3_send_akolouthos_message_varangian = { #ep3_send_akolouthos_message_varangian = {
send_interface_message = { # send_interface_message = {
type = msg_akolouthos_steels_varangians # type = msg_akolouthos_steels_varangians
title = ep3_akolouthos_events.1000 # title = ep3_akolouthos_events.1000
desc = ep3_akolouthos_events.1000_varangian_notification_tooltip # desc = ep3_akolouthos_events.1000_varangian_notification_tooltip
#
left_icon = scope:trait_getter # left_icon = scope:trait_getter
scope:trait_getter = { # scope:trait_getter = {
add_trait = varangian # add_trait = varangian
add_opinion = { # add_opinion = {
target = root # target = root
modifier = loyalty_opinion # modifier = loyalty_opinion
opinion = 40 # opinion = 40
} # }
} # }
custom_tooltip = akolouthos_effect_tooltip # custom_tooltip = akolouthos_effect_tooltip
} # }
} #}
ep3_palace_looting_random_malus_effect = { ep3_palace_looting_random_malus_effect = {
if = { if = {

View file

@ -54,35 +54,35 @@ any_laamp_portion_at_sea_trigger = {
} }
} }
} }
#
character_is_valid_for_harrying_of_the_north_trigger = { #character_is_valid_for_harrying_of_the_north_trigger = {
title:k_england.holder ?= { owns_story_of_type = story_cycle_harrying_of_the_north } # title:k_england.holder ?= { owns_story_of_type = story_cycle_harrying_of_the_north }
trigger_if = { # trigger_if = {
limit = { is_ruler = yes } # limit = { is_ruler = yes }
OR = { # OR = {
this = title:k_england.holder # this = title:k_england.holder
any_liege_or_above = { this = title:k_england.holder } # any_liege_or_above = { this = title:k_england.holder }
} # }
} # }
trigger_else = { # trigger_else = {
domicile ?= { # domicile ?= {
domicile_location = { # domicile_location = {
county ?= { # county ?= {
holder = { # holder = {
OR = { # OR = {
this = title:k_england.holder # this = title:k_england.holder
any_liege_or_above = { this = title:k_england.holder } # any_liege_or_above = { this = title:k_england.holder }
} # }
} # }
} # }
} # }
} # }
} # }
OR = { # OR = {
character_is_valid_anglo_saxon_for_harrying_of_the_north_trigger = yes # character_is_valid_anglo_saxon_for_harrying_of_the_north_trigger = yes
character_is_valid_norman_for_harrying_of_the_north_trigger = yes # character_is_valid_norman_for_harrying_of_the_north_trigger = yes
} # }
} #}
#character_is_valid_anglo_saxon_for_harrying_of_the_north_trigger = { #character_is_valid_anglo_saxon_for_harrying_of_the_north_trigger = {
# culture = { # culture = {
@ -110,30 +110,30 @@ character_is_valid_for_harrying_of_the_north_trigger = {
# } # }
#} #}
disable_interaction_for_hereward_trigger = { #disable_interaction_for_hereward_trigger = {
trigger_if = { # trigger_if = {
limit = { scope:recipient = character:90028 } # limit = { scope:recipient = character:90028 }
custom_tooltip = { # custom_tooltip = {
text = owns_a_story_trigger # text = owns_a_story_trigger
scope:actor = { # scope:actor = {
NOR = { # NOR = {
owns_story_of_type = story_cycle_harrying_of_the_north # owns_story_of_type = story_cycle_harrying_of_the_north
any_liege_or_above = { owns_story_of_type = story_cycle_harrying_of_the_north } # any_liege_or_above = { owns_story_of_type = story_cycle_harrying_of_the_north }
} # }
} # }
} # }
} # }
} #}
#
disable_interaction_for_hasan_trigger = { #disable_interaction_for_hasan_trigger = {
trigger_if = { # trigger_if = {
limit = { scope:recipient = character:41702 } # limit = { scope:recipient = character:41702 }
custom_tooltip = { # custom_tooltip = {
text = owns_a_story_trigger # text = owns_a_story_trigger
scope:recipient = { owns_story_of_type = story_hasan } # scope:recipient = { owns_story_of_type = story_hasan }
} # }
} # }
} #}
laamp_request_likely_marriable_woman_trigger = { laamp_request_likely_marriable_woman_trigger = {
is_available_quick = { is_available_quick = {

View file

@ -609,118 +609,118 @@ struggle_can_access_unlocks_bargain_fealty_interaction_trigger = {
################################################## ##################################################
# Multi-File Event Triggers # Multi-File Event Triggers
#
fp2_lyonese_monk_0002_papal_hof_trigger = { #fp2_lyonese_monk_0002_papal_hof_trigger = {
OR = { religion = religion:eastern_orthodox_religion religion = religion:catholic_religion religion = religion:protestant_religion } # OR = { religion = religion:eastern_orthodox_religion religion = religion:catholic_religion religion = religion:protestant_religion }
exists = faith.religious_head # exists = faith.religious_head
faith.religious_head_title = title:k_papal_state # faith.religious_head_title = title:k_papal_state
} #}
#
fp2_lyonese_monk_0002_valid_character_configuration_trigger = { #fp2_lyonese_monk_0002_valid_character_configuration_trigger = {
OR = { # OR = {
has_trait = scholar # has_trait = scholar
has_trait = theologian # has_trait = theologian
has_trait = lifestyle_mystic # has_trait = lifestyle_mystic
AND = { # AND = {
is_ai = no # is_ai = no
learning >= very_high_skill_rating # learning >= very_high_skill_rating
has_lifestyle = learning_lifestyle # has_lifestyle = learning_lifestyle
} # }
} # }
} #}
#
fp2_lyonese_monk_0002_valid_court_trigger = { #fp2_lyonese_monk_0002_valid_court_trigger = {
# Must have the Pope as a HoF. # # Must have the Pope as a HoF.
fp2_lyonese_monk_0002_papal_hof_trigger = yes # fp2_lyonese_monk_0002_papal_hof_trigger = yes
# Filter out anyone not able to be at home when the monk comes a'knockin'. # # Filter out anyone not able to be at home when the monk comes a'knockin'.
is_physically_able = yes # is_physically_able = yes
# Must be into bookish discussions. # # Must be into bookish discussions.
## Narratively, this is what attracts them to your court. # ## Narratively, this is what attracts them to your court.
## Mechanically, this is how players can opt in for the chain so it's not completely random. # ## Mechanically, this is how players can opt in for the chain so it's not completely random.
fp2_lyonese_monk_0002_valid_character_configuration_trigger = yes # fp2_lyonese_monk_0002_valid_character_configuration_trigger = yes
# Remove non-playables. # # Remove non-playables.
NOR = { # NOR = {
government_has_flag = government_is_theocracy # government_has_flag = government_is_theocracy
government_has_flag = government_is_republic # government_has_flag = government_is_republic
} # }
# Plus, for various reasons, we don't want Lyon _itself_. # # Plus, for various reasons, we don't want Lyon _itself_.
NOT = { # NOT = {
any_held_title = { this = title:c_lyon } # any_held_title = { this = title:c_lyon }
} # }
} #}
#
fp2_lyonese_monk_0000_valid_for_events_trigger = { #fp2_lyonese_monk_0000_valid_for_events_trigger = {
fp2_lyonese_monk_0000_out_of_realm_trigger = no # fp2_lyonese_monk_0000_out_of_realm_trigger = no
fp2_lyonese_monk_0000_out_of_freedom_trigger = no # fp2_lyonese_monk_0000_out_of_freedom_trigger = no
fp2_lyonese_monk_0000_out_of_popes_trigger = no # fp2_lyonese_monk_0000_out_of_popes_trigger = no
fp2_lyonese_monk_0000_out_of_faith_trigger = no # fp2_lyonese_monk_0000_out_of_faith_trigger = no
} #}
#
fp2_lyonese_monk_0000_out_of_realm_trigger = { #fp2_lyonese_monk_0000_out_of_realm_trigger = {
scope:acolyte = { # scope:acolyte = {
OR = { # OR = {
is_alive = no # is_alive = no
is_imprisoned = yes # is_imprisoned = yes
AND = { # AND = {
is_landed_or_landless_administrative = no # is_landed_or_landless_administrative = no
NOT = { # NOT = {
host = scope:acolyte_host # host = scope:acolyte_host
# Make an exception if you're in prison, since that should give a different event. # # Make an exception if you're in prison, since that should give a different event.
scope:acolyte_host = { is_imprisoned = no } # scope:acolyte_host = { is_imprisoned = no }
} # }
} # }
AND = { # AND = {
is_landed_or_landless_administrative = yes # is_landed_or_landless_administrative = yes
NOT = { # NOT = {
any_liege_or_above = { this = scope:acolyte_host } # any_liege_or_above = { this = scope:acolyte_host }
} # }
} # }
} # }
} # }
} #}
#
fp2_lyonese_monk_0000_out_of_freedom_trigger = { is_imprisoned = yes } #fp2_lyonese_monk_0000_out_of_freedom_trigger = { is_imprisoned = yes }
#
fp2_lyonese_monk_0000_out_of_popes_trigger = { #fp2_lyonese_monk_0000_out_of_popes_trigger = {
NOT = { exists = scope:story.var:base_faith.religious_head } # NOT = { exists = scope:story.var:base_faith.religious_head }
} #}
#
fp2_lyonese_monk_0000_out_of_faith_trigger = { #fp2_lyonese_monk_0000_out_of_faith_trigger = {
OR = { # OR = {
scope:acolyte.faith.religious_head != scope:story.var:base_faith.religious_head # scope:acolyte.faith.religious_head != scope:story.var:base_faith.religious_head
scope:acolyte_host.faith.religious_head != scope:story.var:base_faith.religious_head # scope:acolyte_host.faith.religious_head != scope:story.var:base_faith.religious_head
} # }
} #}
#
fp2_does_this_player_care_about_the_fate_of_iberia = { #fp2_does_this_player_care_about_the_fate_of_iberia = {
this != root # this != root
OR = { # OR = {
location = { # location = {
OR = { # Is in region # OR = { # Is in region
geographical_region = world_europe_west # geographical_region = world_europe_west
geographical_region = world_africa_north # geographical_region = world_africa_north
geographical_region = world_europe_south_italy # geographical_region = world_europe_south_italy
} # }
} # }
struggle:iberian_struggle = { is_culture_involved_in_struggle = prev.culture } # struggle:iberian_struggle = { is_culture_involved_in_struggle = prev.culture }
} # }
} #}
#
fp2_eligible_for_yearly_events_trigger = { #fp2_eligible_for_yearly_events_trigger = {
has_fp2_dlc_trigger = yes # has_fp2_dlc_trigger = yes
OR = { # OR = {
any_character_struggle = { # any_character_struggle = {
involvement = involved # involvement = involved
is_struggle_type = iberian_struggle # is_struggle_type = iberian_struggle
} # }
culture = { # culture = {
has_cultural_pillar = heritage_iberian # has_cultural_pillar = heritage_iberian
} # }
capital_province ?= { # capital_province ?= {
geographical_region = world_europe_west_iberia # geographical_region = world_europe_west_iberia
} # }
} # }
} #}
fp2_purchase_truce_interaction_soft_requirements_trigger = { fp2_purchase_truce_interaction_soft_requirements_trigger = {
OR = { OR = {

View file

@ -0,0 +1,193 @@
story_cycle_black_death = {
# by Nick Meredith
on_setup = { #check if the plague is close enough
story_owner = {
trigger_event = {
id = epidemic_events.5998
days = { 21 37 }
}
}
}
on_end = {
debug_log = "Black Death story ended on:"
debug_log_date = yes
}
on_owner_death = {
# Should be inherited, so transfer to heir
if = {
limit = {
exists = story_owner.player_heir
}
make_story_owner = story_owner.player_heir
}
# Or destroy
else = {
end_story = yes
}
}
#check if the plague is close enough
effect_group = {
months = { 2 4 }
trigger = {
has_global_variable = black_death
story_owner = {
NOR = {
has_character_flag = black_death_nearby
has_character_flag = black_death_splash
}
}
}
first_valid = {
triggered_effect = {
trigger = { always = yes }
effect = {
story_owner = {
trigger_event = {
id = epidemic_events.5998
days = { 2 4 }
}
}
}
}
}
}
#IT IS GETTING CLOSER!
effect_group = {
months = { 4 8 }
trigger = {
has_global_variable = black_death
story_owner = {
has_character_flag = black_death_closer
NOR = {
has_character_flag = black_death_nearby
has_character_flag = black_death_splash
}
}
}
first_valid = {
triggered_effect = {
trigger = { always = yes }
effect = {
save_scope_as = story_scope
story_owner = {
trigger_event = {
on_action = ongoing_black_death_events
}
}
}
}
}
}
#ALMOST THERE!
effect_group = {
months = { 1 2 }
trigger = {
has_global_variable = black_death
story_owner = {
has_character_flag = black_death_closer
NOR = {
has_character_flag = black_death_splash
has_character_flag = black_death_nearby
}
}
}
first_valid = {
triggered_effect = {
trigger = { always = yes }
effect = {
save_scope_as = story_scope
story_owner = {
trigger_event = {
id = epidemic_events.5998
days = { 4 8 }
}
}
}
}
}
}
#YIKES, IT IS NEAR
effect_group = {
days = { 21 37 }
trigger = {
has_global_variable = black_death
story_owner = {
has_character_flag = black_death_nearby
}
}
first_valid = {
triggered_effect = {
trigger = { always = yes }
effect = {
save_scope_as = story_scope
story_owner = {
trigger_event = {
on_action = ongoing_black_death_events
}
}
}
}
}
}
# We can stop worrying about black plague coming to us, because...
effect_group = {
days = { 30 60 }
trigger = {
OR = {
NOT = { #...the black plague is gone...
has_global_variable = black_death
}
story_owner = {
has_character_flag = black_death_splash #... IT IS HERE OH GOD OH HECK
}
}
}
first_valid = {
triggered_effect = {
trigger = { always = yes }
effect = {
end_story = yes
}
}
}
}
#Maintenance group
effect_group = {
days = 1
trigger = {
story_owner = { is_landed = no }
}
triggered_effect = {
trigger = { always = yes }
effect = {
#You became a landless adventurer/administrative! Ending story prematurely.
story_owner = { save_scope_as = story_owner }
debug_log = "Black Death invalidated"
debug_log_scopes = yes
end_story = yes
}
}
}
}

View file

@ -0,0 +1,92 @@
plague_witch_hunt = {
# by James Beaumont
on_setup = {
}
on_end = {
debug_log = "Witch hunt story ended on:"
debug_log_date = yes
}
on_owner_death = {
# Should be inherited, people won't stop the witch trials just because the ruler died
}
# The plague is over, end the story
effect_group = {
days = { 40 60 }
trigger = {
NOT = {
story_owner = {
any_sub_realm_county = {
any_county_province_epidemic = {
this = root.var:plague
}
}
}
}
}
first_valid = {
triggered_effect = {
trigger = { always = yes }
effect = {
end_story = yes
}
}
}
}
# Something happens - random events
effect_group = {
days = { 365 600 }
chance = 50
trigger = {
story_owner = {
any_sub_realm_county = {
any_county_province_epidemic = {
this = root.var:plague
}
}
}
}
first_valid = {
triggered_effect = {
trigger = { always = yes }
effect = {
save_scope_as = story_scope
var:plague = { save_scope_as = epidemic_scope }
var:faith_blamed ?= { save_scope_as = faith_blamed }
var:trait_blamed ?= { save_scope_as = trait_blamed }
story_owner = {
trigger_event = {
on_action = ongoing_witch_hunt_events
}
}
}
}
}
}
#Maintenance group
effect_group = {
days = 1
trigger = {
story_owner = { is_landed = no }
}
triggered_effect = {
trigger = { always = yes }
effect = {
#You became a landless adventurer/administrative! Ending story prematurely.
story_owner = { save_scope_as = story_owner }
debug_log = "Plague Witches invalidated"
debug_log_scopes = yes
end_story = yes
}
}
}
}

View file

@ -0,0 +1,214 @@
##################################################
###
### The Song of El Cid
### by Veronica Pazos
###
##################################################
story_el_cid = {
visible = yes
icon = {
reference = "gfx/interface/icons/artifact/artefact_icons_unique_artifact_excalibur.dds"
}
background = {
reference = "gfx/interface/illustrations/event_scenes/fp2_courtyard.dds"
}
visualization = {
character = {
variable_name = "cid_liege"
label = "CID_LIEGE"
}
custom_string_key = "EL_CID_CUSTOM_STRING_KEY"
traits = {
campeador
}
tug_of_war_counter = {
label = "cid_loyalty_counter_label"
variable_name = "cid_loyalty_counter"
tooltip = EL_LOYALTY_COUNTER_TOOLTIP
min_label = CID_LOYALTY_MIN_LABEL
max_label = CID_LOYALTY_MAX_LABEL
min = -5
max = 5
}
}
on_setup = {
story_owner = {
top_liege = { save_scope_as = liege }
}
}
on_end = {
debug_log = "El Cid's story ended on:"
debug_log_date = yes
#We clean up all variables
remove_variable = cid_liege
remove_variable = cid_enemy
remove_variable = cid_loyalty_counter
story_owner = {
remove_variable = ongoing_cid_story_cycle
remove_variable = cid_title_to_give
#And you can never have this again
set_variable = had_cid_story_cycle
}
}
on_owner_death = {
end_story = yes
}
# Liege dies
effect_group = {
months = 1
first_valid = {
triggered_effect = { #If your liege dies
trigger = {
story_owner = {
OR = {
any_owned_story = {
has_variable = cid_liege
var:cid_liege = {
is_alive = no
}
}
NOT = {
any_owned_story = {
has_variable = cid_liege
}
}
}
}
}
effect = {
save_scope_as = story
story_owner = {
trigger_event = cid.5000
}
}
}
}
}
effect_group = {
months = { 6 12 }
chance = 100
random_valid = {
triggered_effect = {
trigger = { # Landless events
story_owner = {
has_government = landless_adventurer_government
}
}
effect = {
save_scope_as = story
var:cid_liege = { save_scope_as = liege }
var:cid_enemy = { save_scope_as = enemy }
story_owner = {
trigger_event = { on_action = el_cid_landless_on_action }
}
}
}
triggered_effect = {
trigger = { # Landless OR Landed events
always = yes
}
effect = {
save_scope_as = story
var:cid_liege = { save_scope_as = liege }
var:cid_enemy = { save_scope_as = enemy }
story_owner = {
trigger_event = { on_action = el_cid_landless_or_landed_on_action }
}
}
}
}
}
# Endings
effect_group = {
months = 3
first_valid = { #Your liege takes you back
triggered_effect = {
trigger = {
var:cid_loyalty_counter >= 5
story_owner = {
has_government = landless_adventurer_government
}
}
effect = {
save_scope_as = story
story_owner = {
trigger_event = cid.2020
}
}
}
triggered_effect = { #Your liege hates you
trigger = {
var:cid_loyalty_counter <= -5
story_owner = {
has_government = landless_adventurer_government
}
}
effect = {
save_scope_as = story
story_owner = {
trigger_event = cid.4010
}
}
}
triggered_effect = { #Neutral ending
trigger = {
var:cid_loyalty_counter > -5
var:cid_loyalty_counter < 5
story_owner = {
has_variable = had_cid_1000
has_variable = had_cid_1030
has_variable = had_cid_1040
trigger_if = {
limit = {
any_courtier = {
is_adult = yes
NOR = {
is_close_family_of = prev
is_spouse_of = prev
}
count >= 2
}
}
has_variable = had_cid_1010
}
trigger_if = {
limit = {
any_courtier = {
is_spouse_of = prev
}
}
has_variable = had_cid_1020
}
trigger_if = {
limit = {
any_child = {
is_betrothed = no
}
}
has_variable = had_cid_2010
}
}
}
effect = {
save_scope_as = story
story_owner = {
trigger_event = cid.4000
}
}
}
}
}
}

View file

@ -0,0 +1,581 @@
#frankokratia_story = {
# # by Jason Cantalini
# visible = yes
#
# icon = {
# trigger = {
# always = yes
# }
# reference = "gfx/interface/icons/story_cycles/story_icon_despoiler.dds"
# }
#
# visualization = {
# custom_string_key = "FRANKOKRATIA_STORY_PRACTICAL_INFORMATION_STRING"
# character = { variable_name = "byz_claimant" label = "claimant" }
# character_list = { variable_name = "frankokratia_leaders" label = "diverted_crusaders" }
# }
#
# on_setup = {
# set_variable = {
# name = crusader_kingdom
# value = story_owner.faith.great_holy_war.ghw_target_title
# }
# set_global_variable = {
# name = byz_claimant_champion
# value = story_owner
# }
# add_to_variable_list = {
# name = frankokratia_leaders
# target = story_owner
# }
# }
##
# on_end = {
# debug_log = "Frankokratia story ended on:"
# debug_log_date = yes
# remove_global_variable = byz_claimant_champion
# if = {
# limit = {
# var:byz_claimant = {
# is_alive = yes
# }
# }
# var:byz_claimant = {
# remove_character_flag = byz_claimant_flag
# }
# }
# }
##
# on_owner_death = {
# story_owner = {
# save_scope_as = dead_owner
# }
# if = {
# limit = {
# exists = story_owner.player_heir
# story_owner.player_heir = {
# faith = faith:catholic
# }
# }
# set_global_variable = {
# name = byz_claimant_champion
# value = story_owner.player_heir
# }
# remove_list_variable = {
# name = frankokratia_leaders
# target = story_owner
# }
# add_to_variable_list = {
# name = frankokratia_leaders
# target = story_owner.player_heir
# }
# make_story_owner = story_owner.player_heir
# }
# else_if = {
# limit = {
# exists = story_owner.primary_heir
# story_owner.primary_heir = {
# faith = faith:catholic
# highest_held_title_tier <= scope:dead_owner.highest_held_title_tier
# }
# }
# set_global_variable = {
# name = byz_claimant_champion
# value = story_owner.primary_heir
# }
# remove_list_variable = {
# name = frankokratia_leaders
# target = story_owner
# }
# add_to_variable_list = {
# name = frankokratia_leaders
# target = story_owner.primary_heir
# }
# make_story_owner = story_owner.primary_heir
# }
# else_if = {
# limit = {
# any_in_list = {
# variable = frankokratia_leaders
# OR = {
# exists = primary_heir
# exists = player_heir
# }
# age >= 13
# this != scope:dead_owner
# }
# }
# ordered_in_list = {
# variable = frankokratia_leaders
# order_by = current_military_strength
# limit = {
# OR = {
# exists = primary_heir
# exists = player_heir
# }
# age >= 13
# this != scope:dead_owner
# }
# save_scope_as = new_franko
#
# set_global_variable = {
# name = byz_claimant_champion
# value = scope:new_franko
# }
# }
# remove_list_variable = {
# name = frankokratia_leaders
# target = story_owner
# }
# add_to_variable_list = {
# name = frankokratia_leaders
# target = scope:new_franko
# }
# make_story_owner = scope:new_franko
# }
# # Or destroy
# else = {
# end_story = yes
# every_in_list = {
# variable = frankokratia_leaders
# limit = {
# is_ai = no
# }
# trigger_event = ep3_frankokratia_events.0005
# }
# }
# }
#
# #Claimant dies... story cycle is over
# effect_group = {
# days = { 20 40 }
#
# trigger = {
# var:byz_claimant = { is_alive = no }
# NOT = {
# has_variable = franko_war_complete
# }
# }
#
# first_valid = {
# triggered_effect = {
# trigger = {
# var:byz_claimant = { is_alive = no }
# NOT = {
# has_variable = franko_war_complete
# }
# }
# effect = {
# every_in_list = {
# variable = frankokratia_leaders
# limit = {
# is_ai = no
# }
# trigger_event = ep3_frankokratia_events.0005
# }
# }
# }
# }
# }
#
# #Owner's other wars should be wrapped up if they're not going well... by force
# effect_group = {
# days = { 20 40 }
#
# trigger = {
# #It's not post-war era
# NOT = {
# has_variable = franko_war_complete
# }
# global_var:byz_claimant_champion = {
# #Is not in frankokratia war
# any_character_war = {
# NOT = {
# using_cb = crusading_claim_cb
# }
# }
# #Is risking losing a war
# any_character_war = {
# OR = {
# AND = {
# primary_attacker = {
# this = global_var:byz_claimant_champion
# }
# attacker_war_score <= -50
# }
# AND = {
# primary_defender = {
# this = global_var:byz_claimant_champion
# }
# defender_war_score <= -50
# }
# }
# NOR = {
# any_war_defender = {
# is_ai = no
# }
# any_war_attacker = {
# is_ai = no
# }
# }
# }
# is_ai = yes
# }
# var:financier_title.holder = {
# save_temporary_scope_as = financier
# }
# any_in_list = {
# variable = frankokratia_leaders
# NOR = {
# this = global_var:byz_claimant_champion
# this = scope:financier
# }
# }
# }
#
# first_valid = {
# triggered_effect = {
# trigger = {
# #It's not post-war era
# NOT = {
# has_variable = franko_war_complete
# }
# global_var:byz_claimant_champion = {
# #Is not in frankokratia war
# any_character_war = {
# NOT = {
# using_cb = crusading_claim_cb
# }
# }
# #Is risking losing a war
# any_character_war = {
# OR = {
# AND = {
# primary_attacker = {
# this = global_var:byz_claimant_champion
# }
# attacker_war_score <= -50
# }
# AND = {
# primary_defender = {
# this = global_var:byz_claimant_champion
# }
# defender_war_score <= -50
# }
# }
# NOR = {
# any_war_defender = {
# is_ai = no
# }
# any_war_attacker = {
# is_ai = no
# }
# }
# }
# is_ai = yes
# }
# var:financier_title.holder = {
# save_temporary_scope_as = financier
# }
# any_in_list = {
# variable = frankokratia_leaders
# NOR = {
# this = global_var:byz_claimant_champion
# this = scope:financier
# }
# }
# }
# effect = {
# global_var:byz_claimant_champion = {
# every_character_war = {
# limit = {
# NOT = {
# using_cb = crusading_claim_cb
# }
# OR = {
# AND = {
# primary_attacker = {
# this = global_var:byz_claimant_champion
# }
# attacker_war_score <= -50
# }
# AND = {
# primary_defender = {
# this = global_var:byz_claimant_champion
# }
# defender_war_score <= -50
# }
# }
# NOR = {
# any_war_defender = {
# is_ai = no
# }
# any_war_attacker = {
# is_ai = no
# }
# }
# }
# end_war = white_peace
# }
# }
# }
# }
# }
# }
#
# #Re-save war attackers
# effect_group = {
# days = { 30 50 }
#
# trigger = {
# always = yes
# }
# first_valid = {
# triggered_effect = {
# trigger = { always = yes }
# effect = {
# save_scope_as = frank_story
# story_owner = {
# random_character_war = {
# limit = { using_cb = crusading_claim_cb }
# every_war_attacker = {
# limit = {
# faith = faith:catholic
# }
# scope:frank_story = {
# add_to_variable_list = {
# name = frankokratia_leaders
# target = prev
# }
# }
# }
# }
# }
# }
# }
# }
# }
#
# #Need to find successor to byz emperor
# effect_group = {
# days = { 10 20 }
#
# trigger = {
# exists = title:e_byzantium.holder
# NOR = {
# var:byz_emperor ?= title:e_byzantium.holder
# var:byz_claimant ?= title:e_byzantium.holder
# global_var:byz_claimant_champion ?= title:e_byzantium.holder
# var:financier_title.holder ?= title:e_byzantium.holder
# var:ghw_sponsor ?= title:e_byzantium.holder
# }
# }
# first_valid = {
# triggered_effect = {
# trigger = {
# exists = title:e_byzantium.holder
# NOR = {
# var:byz_emperor ?= title:e_byzantium.holder
# var:byz_claimant ?= title:e_byzantium.holder
# global_var:byz_claimant_champion ?= title:e_byzantium.holder
# var:financier_title.holder ?= title:e_byzantium.holder
# var:ghw_sponsor ?= title:e_byzantium.holder
# }
# }
# effect = {
# set_variable = {
# name = byz_emperor
# value = title:e_byzantium.holder
# }
# }
# }
# }
# }
#
# #Fire events for pledged attackers for them to commit to leaving crusade when it launches
# effect_group = {
# days = { 10 20 }
#
# trigger = {
# exists = story_owner.faith.great_holy_war
# story_owner.faith = faith:catholic
# story_owner.faith.religious_head = {
# NOT = {
# any_character_war = {
# using_cb = undirected_great_holy_war
# }
# }
# }
# story_owner.faith.great_holy_war = {
# any_pledged_attacker = {
# ep3_frankokratia_valid_joiner_trigger = yes
# }
# }
# }
#
# first_valid = {
# triggered_effect = {
# trigger = {
# exists = story_owner.faith.great_holy_war
# story_owner.faith.religious_head = {
# NOT = {
# any_character_war = {
# using_cb = undirected_great_holy_war
# }
# }
# }
# story_owner.faith.great_holy_war = {
# any_pledged_attacker = {
# ep3_frankokratia_valid_joiner_trigger = yes
# }
# }
# }
# effect = {
# story_owner.faith.great_holy_war = {
# #trigger join event for important players first
# if = {
# limit = {
# any_pledged_attacker = {
# is_ai = no
# highest_held_title_tier >= tier_kingdom
# ep3_frankokratia_valid_joiner_trigger = yes
# }
# }
# random_pledged_attacker = {
# limit = {
# is_ai = no
# highest_held_title_tier >= tier_kingdom
# ep3_frankokratia_valid_joiner_trigger = yes
# }
# trigger_event = ep3_frankokratia_events.0020
# }
# }
# #Then players
# else_if = {
# limit = {
# any_pledged_attacker = {
# is_ai = no
# ep3_frankokratia_valid_joiner_trigger = yes
# }
# }
# random_pledged_attacker = {
# limit = {
# is_ai = no
# ep3_frankokratia_valid_joiner_trigger = yes
# }
# trigger_event = ep3_frankokratia_events.0020
# }
# }
# #Then others
# else = {
# random_pledged_attacker = {
# limit = {
# ep3_frankokratia_valid_joiner_trigger = yes
# }
# trigger_event = ep3_frankokratia_events.0020
# }
# }
# }
# }
# }
# }
# }
#
# #save player war contribution to see if they get to be emp
# effect_group = {
# days = { 10 20 }
#
# trigger = {
# story_owner = {
# any_character_war = {
# using_cb = crusading_claim_cb
# any_war_attacker = {
# is_ai = no
# save_temporary_scope_as = player_temp
# }
# war_contribution = {
# target = scope:player_temp
# value > 100
# }
# }
# }
# }
# first_valid = {
# triggered_effect = {
# trigger = {
# story_owner = {
# any_character_war = {
# using_cb = crusading_claim_cb
# any_war_attacker = {
# is_ai = no
# save_temporary_scope_as = player_temp
# }
# war_contribution = {
# target = scope:player_temp
# value > 100
# }
# }
# }
# }
# effect = {
# story_owner = {
# random_character_war = {
# limit = {
# using_cb = crusading_claim_cb
# }
# save_scope_as = franko_war
# every_war_attacker = {
# limit = {
# is_ai = no
# scope:franko_war = {
# war_contribution = {
# target = prev
# value > 100
# }
# }
# }
# add_character_flag = {
# flag = frankokratia_sufficient_warscore
# years = 30
# }
# }
# every_war_attacker = {
# limit = {
# is_ai = no
# scope:franko_war = {
# war_contribution = {
# target = prev
# value > 1000
# }
# }
# }
# add_character_flag = {
# flag = frankokratia_high_warscore
# years = 30
# }
# }
# }
# }
# }
# }
# }
# }
#
# #Maintenance group
# effect_group = {
# days = 1
# trigger = {
# story_owner = { is_playable_character = no }
# }
# triggered_effect = {
# trigger = { always = yes }
# effect = {
# story_owner = { save_scope_as = story_owner }
# debug_log = "4th Crusader invalidated"
# debug_log_scopes = yes
# end_story = yes
# }
# }
# }
#}
#

View file

@ -0,0 +1,217 @@
##################################################
###
### Grand Ambitions
### by Chad Uhl
###
### The head of a Powerful Family has ambitions for the throne.
###
##################################################
grand_ambitions_story_cycle = {
on_setup = {
set_variable = {
name = eunuch
value = no
}
}
on_end = {
story_owner = {
if = {
limit = { has_character_flag = had_event_ga_0100 }
remove_character_flag = had_event_ga_0100
}
}
var:target_char ?= {
capital_county ?= {
if = {
limit = { has_county_modifier = ep3_grand_ambitions_rioting_county_modifier }
}
remove_county_modifier = ep3_grand_ambitions_rioting_county_modifier
}
}
if = {
limit = {
exists = global_var:current_grand_ambitions_counter
global_var:current_grand_ambitions_counter > 0
}
change_global_variable = {
name = current_grand_ambitions_counter
subtract = 1
}
}
}
# Maintenance Events
effect_group = {
months = 1
# Check if the old emperor is still holds the right title during the beginning
triggered_effect = {
trigger = {
exists = var:target_char
var:target_char = {
NOT = { any_held_title = { this = root.var:target_title } }
}
}
effect = {
story_owner = {
trigger_event = grand_ambitions.0500
}
}
}
# Death maintenance is handled in the death on_action
}
effect_group = {
months = 1
chance = 100
random_valid = {
triggered_effect = {
trigger = { # Claimant Faction Route
var:method = flag:coup
}
effect = {
scope:story = {
var:target_title = { save_scope_as = target_title }
var:target_char = { save_scope_as = target_char }
}
story_owner = {
scope:target_char = {
if = {
limit = {
any_targeting_faction = {
faction_type = claimant_faction
faction_leader = scope:story.story_owner
}
}
random_targeting_faction = {
faction_type = claimant_faction
limit = {
faction_leader = scope:story.story_owner
}
save_scope_as = story_faction
}
}
}
trigger_event = { on_action = grand_ambitions_powerful_family_coup_on_action }
}
}
}
triggered_effect = {
trigger = { # Scheme Route
var:method = flag:scheme
}
effect = {
story_owner = {
random_scheme = {
type = depose
save_scope_as = depose_scheme_scope
}
scope:story = {
var:target_title = { save_scope_as = target_title }
var:target_char = { save_scope_as = target_char }
}
trigger_event = { on_action = grand_ambitions_powerful_family_scheme_on_action }
}
}
}
}
}
effect_group = {
months = 1
chance = 100
random_valid = {
triggered_effect = {
trigger = {
story_owner = {
any_character_war = {
primary_attacker = scope:story.story_owner
primary_defender = scope:story.var:target_char
claimant = scope:story.story_owner
save_temporary_scope_as = story_war
}
}
var:method = flag:coup
var:promised_foreign_ruler_claim = {
NOT = { is_at_war_with = scope:story.var:target_char }
}
scope:story_war = {
NOT = {
any_war_attacker = {
this = scope:story.var:promised_foreign_ruler_claim
}
}
}
}
effect = {
story_owner = {
random_character_war = {
limit = {
primary_attacker = scope:story.story_owner
primary_defender = scope:story.var:target_char
claimant = scope:story.story_owner
}
save_scope_as = story_war
}
scope:story.var:promised_foreign_ruler_claim = { save_scope_as = joiner }
send_interface_message = {
type = event_war_good
title = grand_ambitions_ally_joins_war
right_icon = scope:joiner
scope:story_war = {
add_attacker = scope:joiner
}
}
}
}
}
triggered_effect = {
trigger = {
story_owner = {
any_character_war = {
primary_attacker = scope:story.story_owner
primary_defender = scope:story.var:target_char
claimant = scope:story.story_owner
save_temporary_scope_as = story_war
}
}
var:method = flag:coup
has_variable = powerful_family
scope:story_war = {
NOT = {
any_war_attacker = {
this = scope:story.var:powerful_family.house_head
}
}
}
}
effect = {
story_owner = {
random_character_war = {
limit = {
primary_attacker = scope:story.story_owner
primary_defender = scope:story.var:target_char
claimant = scope:story.story_owner
}
save_scope_as = story_war
}
scope:story.var:powerful_family.house_head = { save_scope_as = joiner }
send_interface_message = {
type = event_war_good
title = grand_ambitions_ally_joins_war
right_icon = scope:joiner
scope:story_war = {
add_attacker = scope:joiner
}
}
}
}
}
}
}
}

View file

@ -0,0 +1,692 @@
#story_cycle_harrying_of_the_north = {
# # by Nick Meredith
#
# on_setup = {
# set_variable = {
# name = ruler_england
# value = story_owner
# }
# set_global_variable = {
# name = ruler_england
# value = story_owner
# }
# set_variable = {
# name = pacification
# value = 0
# }
# set_variable = {
# name = resistance
# value = 5
# }
# set_global_variable = {
# name = harrying_of_the_north
# value = this
# }
# }
#
# on_end = {
# debug_log = "Harrying of the North ended on:"
# debug_log_date = yes
# }
#
# on_owner_death = {
# if = {
# limit = {
# exists = story_owner.player_heir
# }
# set_global_variable = {
# name = ruler_england
# value = story_owner.player_heir
# }
# make_story_owner = story_owner.player_heir
# }
# ## This shouldn't be needed; should be handled by the effect group below
# #else = {
# # end_story = yes
# # remove_global_variable = harrying_of_the_north
# #}
# }
#
# #End the Story Cycle if there are no longer any Anglo-Saxon lords left, or if Normans no longer rule England
# #Put it on a long timer so William player can't just kick them all out and weather the storm for a month
# effect_group = {
# months = 1
#
# trigger = {
# OR = { #Either of these can be untrue
# story_owner = {
# any_vassal = {
# NOR = {
# culture = culture:anglo_saxon
# primary_title.tier >= tier_duchy
# }
# }
# }
# NOT = {
# var:ruler_england = {
# culture = culture:norman
# }
# }
# }
# }
#
# first_valid = {
# triggered_effect = { #The Aethelings are no more - Norman victory
# trigger = {
# story_owner = {
# NOR = {
# any_vassal = {
# culture = culture:anglo_saxon
# primary_title.tier >= tier_duchy
# }
# }
# }
# }
# effect = {
# remove_global_variable = harrying_of_the_north
# every_ruler = {
# limit = {
# capital_province = {
# geographical_region = world_europe_west_britannia
# }
# }
# trigger_event = ep3_story_cycle_harrying.0001
# }
# end_story = yes
# }
# }
# triggered_effect = { #An Anglo-Saxon rules - Aetheling victory
# trigger = {
# story_owner = {
# culture = culture:anglo_saxon
# }
# }
# effect = {
# remove_global_variable = harrying_of_the_north
# every_ruler = {
# limit = {
# capital_province = {
# geographical_region = world_europe_west_britannia
# }
# }
# trigger_event = ep3_story_cycle_harrying.0002
# }
# end_story = yes
# }
# }
# triggered_effect = { #The Normans no longer rule - Aethelings avoid defeat
# trigger = {
# story_owner = {
# NOR = {
# culture = culture:norman
# culture = culture:english
# }
# }
# }
# effect = {
# remove_global_variable = harrying_of_the_north
# every_ruler = {
# limit = {
# capital_province = {
# geographical_region = world_europe_west_britannia
# }
# }
# trigger_event = ep3_story_cycle_harrying.0003
# }
# end_story = yes
# }
# }
# }
# }
#
# effect_group = {
# years = 50
#
# triggered_effect = { #The Normans still rule, but it has been generations - Norman victory by attrition
# trigger = {
# var:ruler_england = {
# culture = culture:norman
# }
# }
# effect = {
# remove_global_variable = harrying_of_the_north
# every_ruler = {
# limit = {
# capital_province = {
# geographical_region = world_europe_west_britannia
# }
# }
# trigger_event = ep3_story_cycle_harrying.0004
# }
# end_story = yes
# }
# }
# }
#
# # Events for William/King of England
# effect_group = {
# days = { 20 40 }
#
# trigger = {
# story_owner = {
# is_alive = yes
# }
# }
#
# first_valid = {
# triggered_effect = {
# trigger = { always = yes }
# effect = {
# save_scope_as = story_scope
# story_owner = {
# trigger_event = {
# on_action = ongoing_harrying_owner_events
# }
# }
# }
# }
# }
# }
#
# # Events for Aethelings
# effect_group = {
# days = { 20 40 }
#
# trigger = {
# story_owner = {
# any_vassal = {
# culture = culture:anglo_saxon
# }
# }
# }
#
# first_valid = {
# triggered_effect = {
# trigger = { always = yes }
# effect = {
# save_scope_as = story_scope
# story_owner = {
# random_vassal= {
# limit = {
# culture = culture:anglo_saxon
# }
# trigger_event = {
# on_action = ongoing_harrying_aetheling_events
# }
# }
# }
# }
# }
# }
# }
#
# # Events for Hereward the Wake
# effect_group = {
# days = { 20 40 }
#
# trigger = {
# character:90028 = {
# is_alive = yes
# NOT = {
# has_character_flag = hereward_settled_flag
# }
# }
# }
#
# first_valid = {
# triggered_effect = {
# trigger = { always = yes }
# effect = {
# save_scope_as = story_scope
# character:90028 = {
# trigger_event = {
# on_action = ongoing_harrying_hereward_events
# }
# }
# }
# }
# }
# }
#
# ### Harrying ongoing effects
# # Set the Pacification variable every month if possible
# # This checks for the Embrace English Culture decision
# effect_group = {
# months = 1
# first_valid = {
# triggered_effect = {
# trigger = {
# var:pacification > 15
# var:pacification > var:resistance
# }
# effect = {
# if = {
# limit = {
# AND = {
# NOT = {
# has_variable = embrace_culture_decision_counter
# }
# var:pacification > 15
# var:pacification > var:resistance
# }
# }
# set_variable = {
# name = embrace_culture_decision_counter
# value = 0
# }
# }
# }
# }
# triggered_effect = {
# trigger = {
# OR = {
# var:pacification < 15
# var:pacification < var:resistance
# }
# }
# effect = {
# if = {
# limit = {
# has_variable = embrace_culture_decision_counter
# }
# remove_variable = embrace_culture_decision_counter
# }
# }
# }
# }
# }
#
# # Check to see if you've had pacification over resistance for a year
# effect_group = {
# months = 1
# triggered_effect = {
# trigger = {
# var:pacification > 15
# var:pacification > var:resistance
# has_variable = embrace_culture_decision_counter
# }
# effect = {
# if = {
# limit = {
# AND = {
# has_variable = embrace_culture_decision_counter
# var:pacification > 15
# var:pacification > var:resistance
# }
# }
# change_variable = {
# name = embrace_culture_decision_counter
# add = 1
# }
# }
# }
# }
# }
#
# # Tick cultural acceptance every three months
# effect_group = {
# months = 3
#
# first_valid = {
# triggered_effect = {
# trigger = {
# var:resistance > 16
# var:resistance > var:pacification
# }
# effect = {
# story_owner = {
# culture = {
# change_cultural_acceptance = {
# target = culture:anglo_saxon
# value = major_cultural_acceptance_loss
# desc = harrying_of_the_north_tt_resistance_level_4
# }
# }
# }
# }
# }
# triggered_effect = {
# trigger = {
# var:resistance > 13
# var:resistance > var:pacification
# }
# effect = {
# story_owner = {
# culture = {
# change_cultural_acceptance = {
# target = culture:anglo_saxon
# value = medium_cultural_acceptance_loss
# desc = harrying_of_the_north_tt_resistance_level_3
# }
# }
# }
# }
# }
# triggered_effect = {
# trigger = {
# var:resistance > 10
# var:resistance > var:pacification
# }
# effect = {
# story_owner = {
# culture = {
# change_cultural_acceptance = {
# target = culture:anglo_saxon
# value = minor_cultural_acceptance_loss
# desc = harrying_of_the_north_tt_resistance_level_2
# }
# }
# }
# }
# }
# triggered_effect = {
# trigger = {
# var:resistance > 7
# var:resistance > var:pacification
# }
# effect = {
# story_owner = {
# culture = {
# change_cultural_acceptance = {
# target = culture:anglo_saxon
# value = miniscule_cultural_acceptance_loss
# desc = harrying_of_the_north_tt_resistance_level_1
# }
# }
# }
# }
# }
# triggered_effect = {
# trigger = {
# var:pacification > 14
# var:pacification > var:resistance
# }
# effect = {
# story_owner = {
# culture = {
# change_cultural_acceptance = {
# target = culture:anglo_saxon
# value = major_cultural_acceptance_gain
# desc = harrying_of_the_north_tt_pacification_level_4
# }
# }
# }
# }
# }
# triggered_effect = {
# trigger = {
# var:pacification > 11
# var:pacification > var:resistance
# }
# effect = {
# story_owner = {
# culture = {
# change_cultural_acceptance = {
# target = culture:anglo_saxon
# value = medium_cultural_acceptance_gain
# desc = harrying_of_the_north_tt_pacification_level_3
# }
# }
# }
# }
# }
# triggered_effect = {
# trigger = {
# var:pacification > 8
# var:pacification > var:resistance
# }
# effect = {
# story_owner = {
# culture = {
# change_cultural_acceptance = {
# target = culture:anglo_saxon
# value = minor_cultural_acceptance_gain
# desc = harrying_of_the_north_tt_pacification_level_2
# }
# }
# }
# }
# }
# triggered_effect = {
# trigger = {
# var:pacification > 5
# var:pacification > var:resistance
# }
# effect = {
# story_owner = {
# culture = {
# change_cultural_acceptance = {
# target = culture:anglo_saxon
# value = miniscule_cultural_acceptance_gain
# desc = harrying_of_the_north_tt_pacification_level_1
# }
# }
# }
# }
# }
# }
# }
#
# # Tick dread every month
# effect_group = {
# months = 1
#
# first_valid = {
# triggered_effect = {
# trigger = {
# var:pacification > 14
# var:pacification > var:resistance
# }
# effect = {
# story_owner = {
# add_dread = 3
# }
# }
# }
# triggered_effect = {
# trigger = {
# var:pacification > 13
# var:pacification > var:resistance
# }
# effect = {
# story_owner = {
# add_dread = 2
# }
# }
# }
# triggered_effect = {
# trigger = {
# var:pacification > 10
# var:pacification > var:resistance
# }
# effect = {
# story_owner = {
# add_dread = 1
# }
# }
# }
# }
# }
#
# # Add discontent to targeting factions every 2 months
# effect_group = {
# months = 2
#
# first_valid = {
# triggered_effect = {
# trigger = {
# var:resistance > 16
# var:resistance > var:pacification
# }
# effect = {
# story_owner = {
# if = {
# limit = {
# has_targeting_faction = yes
# }
# add_targeting_factions_discontent = 5
# }
# }
# }
# }
# triggered_effect = {
# trigger = {
# var:resistance > 13
# var:resistance > var:pacification
# }
# effect = {
# story_owner = {
# if = {
# limit = {
# has_targeting_faction = yes
# }
# add_targeting_factions_discontent = 3
# }
# }
# }
# }
# triggered_effect = {
# trigger = {
# var:resistance > 10
# var:resistance > var:pacification
# }
# effect = {
# story_owner = {
# if = {
# limit = {
# has_targeting_faction = yes
# }
# add_targeting_factions_discontent = 1
# }
# }
# }
# }
# }
# }
#
# # Erode Norman County Control every 3 months
# effect_group = {
# months = 3
#
# first_valid = {
# triggered_effect = {
# trigger = {
# var:resistance > 16
# var:resistance > var:pacification
# }
# effect = {
# story_owner = {
# every_sub_realm_county = {
# limit = {
# holder = {
# NOT = {
# culture = culture:anglo_saxon
# }
# }
# }
# change_county_control = medium_discontent_loss
# }
# }
# }
# }
# triggered_effect = {
# trigger = {
# var:resistance > 13
# var:resistance > var:pacification
# }
# effect = {
# story_owner = {
# every_sub_realm_county = {
# limit = {
# holder = {
# NOT = {
# culture = culture:anglo_saxon
# }
# }
# }
# change_county_control = minor_discontent_loss
# }
# }
# }
# }
# }
# }
#
# # Add Norman County Control every 3 months
# effect_group = {
# months = 3
#
# first_valid = {
# triggered_effect = {
# trigger = {
# var:pacification > 14
# var:pacification > var:resistance
# }
# effect = {
# story_owner = {
# every_sub_realm_county = {
# limit = {
# holder = {
# NOT = {
# culture = culture:anglo_saxon
# }
# }
# }
# change_county_control = medium_discontent_gain
# }
# }
# }
# }
# triggered_effect = {
# trigger = {
# var:pacification > 11
# var:pacification > var:resistance
# }
# effect = {
# story_owner = {
# every_sub_realm_county = {
# limit = {
# holder = {
# NOT = {
# culture = culture:anglo_saxon
# }
# }
# }
# change_county_control = minor_discontent_gain
# }
# }
# }
# }
# }
# }
#
# #Maintenance group
# effect_group = {
# days = 1
# #Give the story cycle to any Norman ruler of England if the original one sods off
# triggered_effect = {
# trigger = {
# story_owner = {
# NOT = {
# has_title = title:k_england
# }
# }
# }
# effect = {
# title:k_england.holder = {
# save_scope_as = new_ruler
# }
# make_story_owner = scope:new_ruler
# set_variable = {
# name = ruler_england
# value = story_owner
# }
# set_global_variable = {
# name = ruler_england
# value = story_owner
# }
# }
# }
# }
#}
#

View file

@ -0,0 +1,156 @@
story_hasan = {
# by James Beaumont
visible = yes
icon = {
trigger = {
always = yes
}
reference = "gfx/interface/icons/regimenttypes/mubarizun.dds"
}
visualization = {
decisions = {
hasan_evangelize_the_faith
hasan_agitate_the_populace
hasan_ignite_the_flames
hasan_found_the_assassins
hasan_expand_the_assassins
zealous_missionary_prep_decision
}
basic_counter = {
variable_name = "radical_points"
min = 0
max = 15
label = "PROGRESS_TOWARDS_ASSASSIN_PATH"
}
character = {
variable_name = "ultimate_foe"
label = "ULTIMATE_FOE"
}
}
on_setup = {
}
#
on_end = {
debug_log = "Hasan i Sabbah story ended on:"
debug_log_date = yes
}
#
on_owner_death = {
end_story = yes
}
# Progress on Assassing path Events
effect_group = {
months = 6
first_valid = {
triggered_effect = {
trigger = {
exists = var:radical_points
var:radical_points >= 5
story_owner = {
OR = {
faith = faith:ismaili
faith = faith:nizari
}
NOR = {
has_character_flag = arrived_in_egypt
has_character_flag = had_hasan_sabah_20
}
}
}
effect = {
story_owner = {
trigger_event = hasan_sabbah.1020
}
}
}
triggered_effect = {
trigger = {
exists = var:radical_points
var:radical_points >= 15
NOT = { exists = var:ultimate_foe }
}
effect = {
story_owner = {
trigger_event = hasan_sabbah.1031
}
}
}
triggered_effect = {
trigger = {
exists = var:story_phase
var:story_phase >= 2
NOT = { exists = var:ultimate_foe }
story_owner.domicile.domicile_location.county.holder ?= {
save_temporary_scope_as = county_holder
}
faith:ismaili = {
religious_head = {
save_temporary_scope_as = ismaili_hof
NOR = {
this = scope:county_holder
scope:county_holder = {
any_liege_or_above = {
this = scope:ismaili_hof
}
}
}
}
}
faith:nizari = {
religious_head = {
save_temporary_scope_as = nizari_hof
NOR = {
this = scope:county_holder
scope:county_holder = {
any_liege_or_above = {
this = scope:nizari_hof
}
}
}
}
}
}
effect = {
story_owner = {
domicile.domicile_location = {
save_scope_as = location
}
trigger_event = hasan_sabbah.1031
}
}
}
}
}
# Hasan dies or stops being muslim, end the story
effect_group = {
days = { 40 60 }
first_valid = {
triggered_effect = {
trigger = {
OR = {
# Standard checks
NOT = { exists = story_owner }
story_owner = {
is_alive = no
}
# Must be Muslim
NOT = { story_owner = { religion = religion:islam_religion } }
# Must be landless
NOT = { story_owner = { has_government = landless_adventurer_government } }
# Must not be Sunni
story_owner = { faith = { has_doctrine = muhammad_succession_sunni_doctrine } }
}
}
effect = {
end_story = yes
}
}
}
}
}

View file

@ -0,0 +1,81 @@

### Byzantine-focused Restore Rome Story Cycle
### by Chad Uhl
ep3_story_cycle_restoring_rome = {
on_setup = {
story_owner = {
trigger_event = {
id = ep3_roman_restoration.0001
days = 2
}
}
}
# We only pass on the story if the title heir is the Player
on_owner_death = {
if = {
limit = {
story_owner = { has_title = title:h_roman_empire }
title:h_roman_empire.current_heir = { is_ai = no }
}
make_story_owner = title:h_roman_empire.current_heir
}
else_if = {
limit = {
story_owner = { has_title = title:h_eastern_roman_empire }
title:h_eastern_roman_empire.current_heir = { is_ai = no }
}
make_story_owner = title:h_eastern_roman_empire.current_heir
}
else_if = {
limit = {
story_owner = { has_title = title:e_byzantium }
title:e_byzantium.current_heir = { is_ai = no }
}
make_story_owner = title:e_byzantium.current_heir
}
}
# Rome = New Game +
# aka ramp up difficulty
effect_group = {
days = 120
trigger = {
story_owner = {
is_ai = no
is_roman_emperor_excluding_byzantium_trigger = yes
}
has_variable = roman_empire_hard_mode
}
triggered_effect = {
trigger = { always = yes }
effect = {
story_owner = {
trigger_event = { on_action = ep3_restored_rome_on_action }
}
}
}
}
#Maintenance group
effect_group = {
days = 1
trigger = {
story_owner = { is_landed = no }
}
triggered_effect = {
trigger = { always = yes }
effect = {
#You became a landless adventurer with different lifestyles! Ending story prematurely.
story_owner = { save_scope_as = story_owner }
debug_log = "Roman Restoration invalidated"
debug_log_scopes = yes
end_story = yes
}
}
}
}

View file

@ -0,0 +1,78 @@
story_cycle_violet_poet = {
# by Nick Meredith
visible = yes
icon = {
trigger = {
always = yes
}
reference = "gfx/interface/icons/artifact/artifact_chronicle.dds"
}
visualization = {
traits = {
violet_poet
}
artifact = { variable_name = "artifact" label = "POETRY_BOOK_LABEL" }
}
on_setup = {
set_variable = {
name = violet_poet
value = story_owner
}
}
on_end = {
debug_log = "Violet Poet story cycle ended on:"
debug_log_date = yes
}
on_owner_death = {
if = { #Pass on to Wallada's heir but NOT past her heir
limit = {
exists = story_owner.player_heir
story_owner = {
this = character:andalusian_0003
}
}
make_story_owner = story_owner.player_heir
set_variable = {
name = violet_poet
value = story_owner
}
}
# Or destroy
else = {
end_story = yes
remove_variable = violet_poet
}
}
# Events for the Violet Poet
effect_group = {
days = { 100 200 }
trigger = {
story_owner = {
is_available = yes
is_alive = yes
is_adult = yes
}
}
first_valid = {
triggered_effect = {
trigger = { always = yes }
effect = {
save_scope_as = story_scope
story_owner = {
trigger_event = {
on_action = ongoing_violet_poet_owner_events
}
}
}
}
}
}
}

View file

@ -0,0 +1,132 @@
turkic_tribe_story = {
on_setup = {
### Scopes
save_scope_as = turkic_tribe_story
story_owner = {
add_character_flag = had_turkic_tribe_story
}
### Tracking variables
set_variable = {
name = turkic_leader
value = story_owner.var:turkic_leader
}
set_variable = {
name = upset_vassal
value = story_owner.var:upset_vassal
}
set_variable = {
name = nomads_county
value = story_owner.var:nomads_county
}
set_variable = {
name = nomads_new_county
value = story_owner.var:nomads_new_county
}
story_owner = {
remove_variable = turkic_leader
remove_variable = upset_vassal
remove_variable = nomads_county
remove_variable = nomads_new_county
}
}
on_owner_death = {
scope:story = { end_story = yes }
}
# nomad leader is dead
effect_group = {
days = 200
trigger = {
trigger_if = {
limit = { exists = var:turkic_leader }
var:turkic_leader = {
OR = {
is_alive = no
NOR = {
is_courtier_of = scope:story.story_owner
is_vassal_of = scope:story.story_owner
}
}
}
}
trigger_else = { always = yes }
}
first_valid = {
triggered_effect = {
trigger = { always = yes }
effect = { end_story = yes }
}
}
}
# Something happens - random events
effect_group = {
days = { 200 350 } #lower these values to test the story cycle
chance = 50
triggered_effect = {
trigger = { always = yes }
effect = {
story_owner = {
trigger_event = {
on_action = ongoing_turkic_tribe_events
}
}
}
}
}
effect_group = { #the nomad chain's end
years = { 5 10 } #lower these values to test the story cycle
chance = 100
trigger = {
story_owner = {
is_available = yes
}
}
triggered_effect = {
trigger = { always = yes }
effect = {
story_owner = {
add_character_flag = {
flag = turkic_tribe_story_end
days = 200
}
trigger_event = {
on_action = turkic_tribe_story_end
}
}
}
}
}
#Maintenance group
effect_group = {
days = 1
trigger = {
story_owner = { is_landed = no }
}
triggered_effect = {
trigger = { always = yes }
effect = {
#You became a landless adventurer/administrative! Ending story prematurely.
story_owner = { save_scope_as = story_owner }
debug_log = "Nomads invalidated"
debug_log_scopes = yes
end_story = yes
}
}
}
}

View file

@ -0,0 +1,34 @@
### Exists so we can track Ali or any subsequent Zanj Leaders.
story_zanj_rebellion = {
on_setup = {
story_owner = {
set_variable = {
name = zanj_rebellion_strength_score
value = 7
}
}
}
on_owner_death = {
inherit_zanj_rebellion_effect = yes
}
on_end = {}
#Maintenance group
effect_group = {
days = 1
trigger = {
story_owner = { is_landed = no }
}
triggered_effect = {
trigger = { always = yes }
effect = {
#You became a landless adventurer/administrative! Ending story prematurely.
story_owner = { save_scope_as = story_owner }
debug_log = "Zanj invalidated"
debug_log_scopes = yes
end_story = yes
}
}
}
}

View file

@ -0,0 +1,265 @@
story_greatest_of_khans = {
visible = yes
icon = {
trigger = {
always = yes
}
reference = "gfx/interface/icons/story_cycles/bow_steppe.dds"
}
background = {
reference = "gfx/interface/illustrations/event_scenes/mpo_steppe_evening.dds"
}
visualization = {
custom_string_key = "GREATEST_OF_KHANS_INFORMATION_STRING"
decisions = { mpo_gok_world_conquest_decision }
}
on_setup = {
if = {
limit = {
NOT = {
has_mpo_dlc_trigger = yes
}
}
end_story = yes
}
else = {
set_global_variable = {
name = gok_empire_crumble_date
value = {
value = current_year
add = 75
}
}
set_variable = {
name = gok_final_date
value = {
value = current_year
add = 75
}
}
set_global_variable = {
name = first_gok
value = story_owner
}
set_global_variable = {
name = greatest_of_khans_title
value = story_owner.primary_title
}
global_var:greatest_of_khans_title = {
set_variable = {
name = chaotic_succession_protection
value = yes
}
}
}
}
on_end = {
if = {
limit = {
exists = global_var:active_conquerors
}
change_global_variable = {
name = active_conquerors
add = -1
}
}
global_var:greatest_of_khans_title = {
remove_variable = chaotic_succession_protection
}
remove_global_variable = first_gok
remove_global_variable = gok_empire_crumble_date
}
on_owner_death = {
# Handle story succession
story_owner = {
save_scope_as = old_khan # for news events
if = {
limit = {
any_child = { # if the Khan has a reasonable heir...
is_primary_heir_of = scope:story.story_owner
}
}
random_child = {
limit = {
is_primary_heir_of = scope:story.story_owner
}
save_scope_as = new_khan # for news events
save_scope_as = new_story_owner # pass chain to appropriate target
add_character_flag = {
flag = gain_mongol_succession_dread
days = 2
}
add_character_modifier = {
modifier = the_great_khan_modifier
}
}
every_player = {
trigger_event = {
id = mongol_invasion.1001
days = 1
}
}
}
else_if = {
limit = {
dynasty = {
any_dynasty_member = { # if the Khan has some other heir not family?)
is_primary_heir_of = scope:story.story_owner
}
}
}
dynasty = {
random_dynasty_member = {
limit = {
is_primary_heir_of = scope:story.story_owner
}
save_scope_as = new_khan # for news events
save_scope_as = new_story_owner # pass chain toappropriate target
add_character_flag = {
flag = gain_mongol_succession_dread
days = 2
}
add_character_modifier = {
modifier = the_great_khan_modifier
}
}
}
every_player = {
trigger_event = {
id = mongol_invasion.1001
days = 1
}
}
}
else_if = {
limit = {
primary_heir = {
is_grandchild_of = scope:story.story_owner
}
}
primary_heir = {
save_scope_as = new_khan # for news events
save_scope_as = new_story_owner # pass chain to appropriate target
add_character_flag = {
flag = gain_mongol_succession_dread
days = 2
}
add_character_modifier = {
modifier = the_great_khan_modifier
}
}
every_player = {
trigger_event = {
id = mongol_invasion.1001
days = 1
}
}
}
else_if = { # If the empire passes out of the original dynasty, the story will automatically end
limit = {
NOT = {
dynasty = {
any_dynasty_member = { # if the Khan has some otherheir (not family?)
is_primary_heir_of = scope:story.story_owner
}
}
}
}
scope:story.story_owner.primary_heir = {
save_scope_as = new_khan
}
every_player = {
trigger_event = {
id = mongol_invasion.1001
days = 1
}
}
}
}
if = {
limit = { exists = scope:new_story_owner }
make_story_owner = scope:new_story_owner
}
#Story end event
else = {
if = {
limit = {
exists = story_owner.player_heir
exists = story_owner.dynasty
story_owner.player_heir = {
dynasty ?= root.story_owner.dynasty
}
}
story_owner.player_heir ?= {
trigger_event = {
id = mpo_greatest_of_khans.0040
days = 1
}
}
}
else = {
end_story = yes
}
}
}
#Invalidation end!
effect_group = {
years = 75
triggered_effect = {
trigger = {
exists = story_owner
}
effect = {
story_owner = {
save_scope_as = timed_out
trigger_event = {
id = mpo_greatest_of_khans.0040
days = 1
}
}
}
}
}
#Start a new war if none is ongoing
effect_group = {
days = { 30 60 }
trigger = {
story_owner = {
is_at_war = no
gold > 0
exists = global_var:greatest_of_khans_title
any_held_title = {
this = global_var:greatest_of_khans_title
}
}
}
triggered_effect = {
trigger = {
story_owner = {
is_ai = yes
}
}
effect = {
story_owner = {
gok_war_target_evaluation_and_declaration_effect = yes
}
debug_log = "The story started a new war for the Greatest of Khans"
debug_log_date = yes
story_owner = {
save_scope_as = owner
}
debug_log_scopes = yes
}
}
}
}

View file

@ -0,0 +1,22 @@
story_temujin_flavor = {
on_owner_death = {
end_story = yes
}
effect_group = {
days = { 180 360 }
chance = 50
triggered_effect = {
trigger = { always = yes }
effect = {
story_owner = {
trigger_event = {
on_action = ongoing_temujin_flavor_events
}
}
}
}
}
}

View file

@ -0,0 +1,168 @@

# Story for the rise of the Almohads
# by Petter Vilberg
story_almohad_invasion = {
on_setup = {
set_global_variable = {
name = spawned_almohads
value = yes
}
}
on_end = {
debug_log = "Almohad story ended on:"
debug_log_date = yes
}
on_owner_death = {
if = {
limit = { NOT = { exists = var:had_ibn_tumart_succession } }
set_variable = {
name = had_ibn_tumart_succession
value = yes
}
if = {
limit = { exists = var:ibn_tumart_triggered_death }
if = {
limit = {
var:al_mumin = {
is_alive = yes
faith = faith:masmudi
}
}
if = {
limit = { var:al_mumin = { is_imprisoned = yes } }
var:al_mumin = { release_from_prison = yes }
}
if = {
limit = {
NOT = { var:ibn_tumart.primary_heir = var:al_mumin }
}
create_title_and_vassal_change = {
type = granted
save_scope_as = change
add_claim_on_loss = no
}
var:ibn_tumart = {
save_scope_as = ibn_tumart
every_held_title = {
limit = { is_capital_barony = no }
change_title_holder = {
holder = scope:story.var:al_mumin
change = scope:change
}
}
}
resolve_title_and_vassal_change = scope:change
make_story_owner = var:al_mumin
var:almohad_county = {
save_scope_as = almohad_county
}
story_owner = {
if = { # Make sure they get back to warfare
limit = { is_at_war = no }
almohads_find_target_titles_effect = yes
almohads_declare_war_for_target_title_effect = yes
}
spawn_second_almohad_troops_effect = yes
save_scope_as = al_mumin
every_war_enemy = {
trigger_event = almohad.1003
}
}
}
}
}
}
else = {
end_story = yes
}
}
#Kill ibn Tumert if he suffers a defeat
effect_group = {
days = { 20 80 }
trigger = {
story_owner = var:ibn_tumart
story_owner = { is_alive = yes }
exists = global_var:almohads_were_defeated
}
triggered_effect = {
trigger = {
always = yes
}
effect = {
debug_log = "Trying to kill Ibn Tumert!"
set_variable = {
name = ibn_tumart_triggered_death
value = yes
}
story_owner = {
death = natural
}
}
}
}
#Rebuild Marrakesh
effect_group = {
days = 180
trigger = {
NOT = { exists = var:fired_marrakesh_event }
story_owner = {
any_sub_realm_county = {
this = title:c_marrakesh
OR = {
holder = scope:story.story_owner
holder = { is_ai = no }
}
}
}
}
triggered_effect = {
trigger = {
always = yes
}
effect = {
set_variable = {
name = fired_marrakesh_event
value = yes
}
story_owner = {
trigger_event = almohad.1004
}
}
}
}
#Maintenance group
effect_group = {
days = 1
trigger = {
story_owner = { is_landed = no }
}
triggered_effect = {
trigger = { always = yes }
effect = {
#You became a landless adventurer/administrative! Ending story prematurely.
story_owner = { save_scope_as = story_owner }
debug_log = "Almohads invalidated"
debug_log_scopes = yes
end_story = yes
}
}
}
}

View file

@ -0,0 +1,89 @@
#
###################################################
## Wandering Lyonese Monk
## by Ewan Cowhig Croft
###################################################
#
## We really just use this to contain our variables & variable lists.
#
#story_lyonese_monk = {
#
# on_setup = {
# # Start tracking how many events we've tried to fire from within our current_phase.
# set_variable = {
# name = lm_phase_tally
# value = 0
# }
# # Set our school score variables.
# set_variable = {
# name = school_elipandic
# value = 0
# }
# ## Slight edge for the Felicitous school, as scope:acolyte is an explicit Felix of Urgell fan.
# set_variable = {
# name = school_felicitous
# value = 1
# }
# set_variable = {
# name = school_radical
# value = 0
# }
# }
#
# on_owner_death = {
# if = {
# limit = { exists = story_owner.player_heir }
# story_owner = {
# # Transfer flags.
# if = {
# limit = { has_character_flag = fp2_lyonese_monk_entered_controversy_flag }
# player_heir = { add_character_flag = fp2_lyonese_monk_entered_controversy_flag }
# }
# if = {
# limit = { has_character_flag = fp2_lyonese_monk_entered_schism_flag }
# player_heir = { add_character_flag = fp2_lyonese_monk_entered_schism_flag }
# }
# save_scope_as = dead_owner
# # Transfer over scopes & prepare to optionally send the story itself.
# player_heir = {
# save_scope_as = acolyte_host
# trigger_event = {
# id = fp2_lyonese_monk.0011
# days = 7
# }
# }
# }
# }
# else = {
# var:acolyte = { silent_disappearance_effect = yes }
# end_story = yes
# }
# }
#
# on_end = {
# story_owner = {
# # Wipe them tracking flags.
# remove_character_flag ?= fp2_lyonese_monk_entered_controversy_flag
# remove_character_flag ?= fp2_lyonese_monk_entered_schism_flag
# }
# }
#
# #Maintenance group
# effect_group = {
# days = 1
# trigger = {
# story_owner = { is_landed = no }
# }
# triggered_effect = {
# trigger = { always = yes }
# effect = {
# #You became a landless adventurer/administrative! Ending story prematurely.
# story_owner = { save_scope_as = story_owner }
# debug_log = "Reformer invalidated"
# debug_log_scopes = yes
# end_story = yes
# }
# }
# }
#}
#

View file

@ -0,0 +1,537 @@
story_mongol_invasion = {
# by Petter Vilberg
on_setup = {
story_owner = { # Start conquest of all of Mongolia
start_wars_for_mongolia_effect = yes
}
set_variable = {
name = succession_counter
value = 0
}
}
#
on_end = {
debug_log = "Mongol story ended on:"
debug_log_date = yes
set_global_variable = {
name = mongol_story_has_ended
value = yes
}
}
#
on_owner_death = {
story_owner = {
set_variable = {
name = special_mongol_empire_conquest_region_prio_1_alpha_var
value = 0
}
set_variable = {
name = special_mongol_empire_conquest_region_prio_1_var
value = 0
}
set_variable = {
name = special_mongol_empire_conquest_region_prio_2_var
value = 0
}
set_variable = {
name = special_mongol_empire_conquest_region_prio_3_var
value = 0
}
set_variable = {
name = special_mongol_empire_conquest_region_prio_4_var
value = 0
}
set_variable = {
name = special_mongol_empire_conquest_region_prio_5_var
value = 0
}
set_variable = {
name = outside_conquest_region_var
value = 0
}
every_realm_county = {
if = {
limit = {
title_province = {
geographical_region = special_mongol_empire_conquest_region_prio_5
}
}
root.story_owner = {
change_variable = {
name = special_mongol_empire_conquest_region_prio_5_var
add = 1
}
}
}
else_if = {
limit = {
title_province = {
geographical_region = special_mongol_empire_conquest_region_prio_4
}
}
root.story_owner = {
change_variable = {
name = special_mongol_empire_conquest_region_prio_4_var
add = 1
}
}
}
else_if = {
limit = {
title_province = {
geographical_region = special_mongol_empire_conquest_region_prio_3
}
}
root.story_owner = {
change_variable = {
name = special_mongol_empire_conquest_region_prio_3_var
add = 1
}
}
}
else_if = {
limit = {
title_province = {
geographical_region = special_mongol_empire_conquest_region_prio_2
}
}
root.story_owner = {
change_variable = {
name = special_mongol_empire_conquest_region_prio_2_var
add = 1
}
}
}
else_if = {
limit = {
title_province = {
geographical_region = special_mongol_empire_conquest_region_prio_1
}
}
root.story_owner = {
change_variable = {
name = special_mongol_empire_conquest_region_prio_1_var
add = 1
}
}
}
else_if = {
limit = {
title_province = {
geographical_region = special_mongol_empire_conquest_region_prio_1_alpha
}
}
root.story_owner = {
change_variable = {
name = special_mongol_empire_conquest_region_prio_1_alpha_var
add = 1
}
}
}
else = {
root.story_owner = {
change_variable = {
name = outside_conquest_region_var
add = 1
}
}
}
}
}
# Weighted random chance to end the story/break up the Empire
random = {
chance = 0
#Pure realm size - Mongol empire is historical breakup size
modifier = {
add = 20
story_owner = {
realm_size >= 1087
}
}
#Pure realm size - Mongol empire is max extent size
modifier = {
add = 20
story_owner = {
realm_size >= 1474
}
}
#Pure realm size - Mongol empire is at total bonus size
modifier = {
add = 30
story_owner = {
realm_size >= 1725
}
}
modifier = { # If the empire is very successful, increase the chance
add = 10
story_owner = {
#Half of total county count
var:special_mongol_empire_conquest_region_prio_1_alpha_var >= 80
var:special_mongol_empire_conquest_region_prio_1_var >= 60
var:special_mongol_empire_conquest_region_prio_2_var >= 100
#Just a third
var:special_mongol_empire_conquest_region_prio_3_var >= 30
var:special_mongol_empire_conquest_region_prio_4_var >= 100
var:special_mongol_empire_conquest_region_prio_5_var >= 120
}
}
modifier = { # If the empire is EXTREMELY successful, increase the chance
add = 20
story_owner = {
#Three quarters of total county count
var:special_mongol_empire_conquest_region_prio_1_alpha_var >= 120
var:special_mongol_empire_conquest_region_prio_1_var >= 75
var:special_mongol_empire_conquest_region_prio_2_var >= 200
#Just half
var:special_mongol_empire_conquest_region_prio_3_var >= 45
var:special_mongol_empire_conquest_region_prio_4_var >= 150
var:special_mongol_empire_conquest_region_prio_5_var >= 180
var:outside_conquest_region_var >= 100
}
}
modifier = {
add = 20
var:succession_counter > 1
}
modifier = {
add = 30
var:succession_counter > 2
}
modifier = { # Historical point
add = 30
var:succession_counter > 3
}
modifier = { # Guaranteed if there have been five successions
add = 20
var:succession_counter > 4
}
set_variable = {
name = end_of_story
value = yes
}
}
if = {
limit = {
exists = var:end_of_story
}
# Do the breakup of the empire if possible
story_owner = {
if = {
limit = {
realm_size >= 50
}
debug_log = "Trying to break up the Mongol Empire"
break_up_mongol_empire_effect = yes
}
else = {
save_scope_as = old_khan
player_heir = {
save_scope_as = new_khan
}
every_player = {
trigger_event = mongol_invasion.1005 # Small end to story
}
}
}
end_story = yes
}
else = {
change_variable = {
name = succession_counter
add = 1
}
# Handle story succession
story_owner = {
save_scope_as = old_khan # for news events
if = {
limit = {
any_child = { # if the Khan has a reasonable heir...
is_primary_heir_of = scope:story.story_owner
}
}
random_child = {
limit = {
is_primary_heir_of = scope:story.story_owner
}
save_scope_as = new_khan # for news events
save_scope_as = new_story_owner # pass chain to appropriate target
add_character_flag = {
flag = gain_mongol_succession_dread
days = 2
}
add_character_modifier = {
modifier = the_great_khan_modifier
}
}
every_player = {
trigger_event = {
id = mongol_invasion.1001
days = 1
}
}
}
else_if = {
limit = {
dynasty = {
any_dynasty_member = { # if the Khan has some other heir (not family?)
is_primary_heir_of = scope:story.story_owner
}
}
}
dynasty = {
random_dynasty_member = {
limit = {
is_primary_heir_of = scope:story.story_owner
}
save_scope_as = new_khan # for news events
save_scope_as = new_story_owner # pass chain to appropriate target
add_character_flag = {
flag = gain_mongol_succession_dread
days = 2
}
add_character_modifier = {
modifier = the_great_khan_modifier
}
}
}
every_player = {
trigger_event = {
id = mongol_invasion.1001
days = 1
}
}
}
else_if = { # If the empire passes out of the original dynasty, the story will automatically end
limit = {
NOT = {
dynasty = {
any_dynasty_member = { # if the Khan has some other heir (not family?)
is_primary_heir_of = scope:story.story_owner
}
}
}
}
scope:story.story_owner.primary_heir = {
save_scope_as = new_khan
}
every_player = {
trigger_event = {
id = mongol_invasion.1001
days = 1
}
}
}
}
if = {
limit = { exists = scope:new_story_owner }
make_story_owner = scope:new_story_owner
scope:new_story_owner = {
# Delayed firing of spawning new event troops
trigger_event = {
id = mongol_invasion.0100
days = 1
}
}
debug_log = "Successfully replaced the Mongol Khan"
debug_log_date = yes
debug_log_scopes = yes
}
else = {
# Make sure the empire breaks up as best as possible
story_owner = {
if = {
limit = {
realm_size >= 50
}
}
debug_log = "Due to failing to replace the Khan with a Temujin successor, now trying to break up the empire"
break_up_mongol_empire_effect = yes
}
end_story = yes
debug_log = "Failed to replace the Mongol Khan"
debug_log_date = yes
debug_log_scopes = yes
}
}
story_owner = {
clear_variable_list = special_mongol_empire_conquest_region_prio_1_alpha_var
clear_variable_list = special_mongol_empire_conquest_region_prio_1_var
clear_variable_list = special_mongol_empire_conquest_region_prio_2_var
clear_variable_list = special_mongol_empire_conquest_region_prio_3_var
clear_variable_list = special_mongol_empire_conquest_region_prio_4_var
clear_variable_list = special_mongol_empire_conquest_region_prio_5_var
clear_variable_list = outside_conquest_region_var
}
}
#Start a new war if none is ongoing
effect_group = {
days = { 30 50 }
trigger = {
story_owner = {
is_at_war = no
gold > 0
any_held_title = {
this = title:e_mongol_empire
}
}
}
triggered_effect = {
trigger = {
story_owner = {
is_ai = yes
}
}
effect = {
if = {
limit = {
has_mpo_dlc_trigger = yes
}
story_owner = {
gok_war_target_evaluation_and_declaration_effect = yes
}
}
else = {
story_owner = {
mongol_war_target_evaluation_and_declaration_effect = yes
}
}
debug_log = "The story started a new war for the Mongols"
debug_log_date = yes
story_owner = {
save_scope_as = owner
}
debug_log_scopes = yes
}
}
}
# Story handling in case of succession weirdness
effect_group = {
days = 180
trigger = {
story_owner = {
NOT = {
any_held_title = {
this = title:e_mongol_empire
}
}
}
}
triggered_effect = {
trigger = { exists = title:e_mongol_empire }
effect = {
if = {
limit = {
title:e_mongol_empire.holder = {
culture = culture:mongol
}
}
make_story_owner = title:e_mongol_empire.holder
}
else = {
end_story = yes
}
}
}
triggered_effect = {
trigger = { NOT = { exists = title:e_mongol_empire } }
effect = {
end_story = yes
}
}
}
# Set up Mongol Empire de jure stuff
effect_group = {
days = 180
trigger = {
NOT = { exists = var:has_updated_mongolia_de_jure }
trigger_if = {
limit = {
title:e_mongolia = {
any_de_jure_county = {
count >= 3
}
}
}
title:e_mongolia = {
any_in_de_jure_hierarchy = {
continue = { tier > tier_county }
tier = tier_county
holder.top_liege = scope:story.story_owner
count > 3
}
}
}
story_owner.capital_county.empire = {
any_in_de_jure_hierarchy = {
continue = { tier > tier_county }
tier = tier_county
holder.top_liege = scope:story.story_owner
count > 5
}
}
}
triggered_effect = {
trigger = {
always = yes
}
effect = {
title:e_mongolia = {
every_in_de_jure_hierarchy = {
limit = {
tier = tier_kingdom
}
set_de_jure_liege_title = title:e_mongol_empire
}
}
if = {
limit = {
exists = title:e_mongolia.holder
}
title:e_mongolia.holder = {
destroy_title = title:e_mongolia
}
}
if = {
limit = {
story_owner.capital_county.empire = {
NOT = {
this = title:e_mongol_empire
}
}
}
story_owner.capital_county.empire = {
save_scope_as = new_de_jure
}
scope:new_de_jure = {
every_in_de_jure_hierarchy = {
limit = {
tier = tier_kingdom
}
set_de_jure_liege_title = title:e_mongol_empire
}
}
}
set_variable = {
name = has_updated_mongolia_de_jure
value = yes
}
}
}
}
}

View file

@ -0,0 +1,52 @@
restoring_roman_provinces_story = {
on_setup = {
}
on_end = {
}
on_owner_death = {
}
effect_group = {
days = 36 #Checked every 365 days
triggered_effect = {
trigger = {
story_owner = {
roman_restoration_is_valid_roman_empire_trigger = yes
OR = {
has_title = title:h_roman_empire #Not for Byzantium.
has_title = title:h_eastern_roman_empire #Not for Byzantium.
}
}
}
effect = {
story_owner = {
trigger_event = {
on_action = on_action_roman_restoration_pulse
}
}
}
}
}
#Maintenance group
effect_group = {
days = 1
trigger = {
story_owner = { is_landed = no }
}
triggered_effect = {
trigger = { always = yes }
effect = {
#You became a landless adventurer with different lifestyles! Ending story prematurely.
story_owner = { save_scope_as = story_owner }
debug_log = "Roman Restoration invalidated"
debug_log_scopes = yes
end_story = yes
}
}
}
}

View file

@ -0,0 +1,177 @@
story_seljuk_invasion = {
on_setup = {
story_owner = { # Find a place for the Seljuks to settle
set_variable = {
name = seljuk_invasion_nomad_strength_score
value = 10
}
try_to_settle_the_seljuk_effect = yes
}
set_variable = {
name = succession_counter
value = 0
}
}
on_end = {}
on_owner_death = {
# Breakup of the empire should not happen until at least one succession has passed
random_list = { # Weighted chance to end the story
10 = {
trigger = { var:succession_counter < 2 }
modifier = {
add = 10
var:succession_counter > 1
}
modifier = { # Historical point
add = 10
var:succession_counter > 2
}
modifier = {
add = 20
var:succession_counter > 3
}
end_story = yes
}
90 = {
if = {
limit = {
exists = story_owner.primary_heir
}
make_story_owner = story_owner.primary_heir
change_variable = {
name = seljuk_invasion_nomad_strength_score
add = -5
}
}
else = {
end_story = yes
}
}
}
}
# Start a new war if one is not ongoing
effect_group = {
days = { 30 60 }
trigger = {
story_owner = {
is_at_war = no
gold > 0
OR = {
NOT = { has_character_flag = settled_seljuk }
top_liege = this
}
}
}
triggered_effect = {
trigger = {
story_owner = {
is_ai = yes
}
}
effect = {
story_owner = {
seljuk_war_target_evaluation_and_declaration_effect = yes
save_scope_as = owner
}
}
}
}
# Ask for independence if vassals
effect_group = {
years = { 1 2 }
trigger = {
story_owner = {
has_character_flag = settled_seljuk
top_liege != this
}
}
triggered_effect = {
trigger = {
story_owner = {
is_ai = yes
}
}
effect = {
story_owner = {
seljuk_request_independence_from_liege_effect = yes
save_scope_as = owner
}
}
}
}
# Create the empire and close the story
effect_group = {
days = { 30 60 }
trigger = {
story_owner = {
save_temporary_scope_as = temp_seljuk
OR = {
any_county_in_region = {
region = world_persian_empire
percent >= 0.51
holder.top_liege = scope:temp_seljuk
}
any_held_title = {
count = 2
title_tier = kingdom
any_this_title_or_de_jure_above = {
this = title:e_persia
}
}
any_held_title = {
title_tier = empire
any_this_title_or_de_jure_above = {
this = title:e_persia
}
}
}
}
}
triggered_effect = {
trigger = {
story_owner = {
is_ai = yes
}
}
effect = {
story_owner = {
save_scope_as = owner
create_title_and_vassal_change = {
type = created
save_scope_as = title_change
add_claim_on_loss = no
}
title:e_persia = {
change_title_holder = {
holder = scope:owner
change = scope:title_change
}
save_scope_as = title_e_persia
}
resolve_title_and_vassal_change = scope:title_change
set_primary_title_to = scope:title_e_persia
}
end_story = yes
}
}
}
}

View file

@ -0,0 +1,189 @@
story_take_mandate_of_heaven = {
on_setup = {
}
on_end = {
}
on_owner_death = {
story_owner = {
if = {
limit = {
primary_heir ?= {
is_ai = yes
is_physically_able_adult = yes
}
}
primary_heir ?= {
create_story = story_take_mandate_of_heaven
}
}
else = {
every_heir = {
limit = {
is_ai = yes
is_physically_able_adult = yes
}
create_story = story_take_mandate_of_heaven
}
}
}
end_story = yes
}
effect_group = { # Handles the AI behavior
days = { 30 60 }
triggered_effect = {
trigger = {
story_owner = {
is_ai = yes
NOT = { can_execute_decision = situation_dynastic_cycle_claim_mandate_decision }
}
}
effect = {
story_owner = {
save_scope_as = root_scope
###### BUDGETING
if = {
limit = {
is_at_war = no
primary_title = { title_held_years >= 3 } # Do not go into buildup mode if there's a brother you need to destroy immediately!
OR = {
any_neighboring_and_across_water_top_liege_realm_owner = {
count = all
current_military_strength >= scope:root_scope.max_military_strength
NOR = {
is_allied_to = scope:root_scope
has_relation_friend = scope:root_scope
has_relation_lover = scope:root_scope
}
}
any_neighboring_and_across_water_top_liege_realm_owner = {
count >= 2
current_military_strength >= scope:root_scope.max_military_strength
NOR = {
is_allied_to = scope:root_scope
has_relation_friend = scope:root_scope
has_relation_lover = scope:root_scope
}
}
any_vassal = {
exists = joined_faction
joined_faction = {
faction_power >= faction_power_halfway_threshold
}
}
AND = {
NOT = { ai_should_get_conqueror_bonuses = yes } # They have a 75% discount
monthly_character_income_minus_expenses > half_monthly_character_income # Try to spend at least 50% of income on MaA!
}
}
}
move_budget_gold = { gold = long_term_gold from = budget_long_term to = budget_war_chest }
move_budget_gold = { gold = short_term_gold from = budget_short_term to = budget_war_chest }
move_budget_gold = { gold = long_term_gold from = budget_long_term to = budget_short_term }
if = {
limit = {
has_treasury = yes
}
move_budget_treasury = { treasury = long_term_treasury from = budget_long_term to = budget_war_chest }
move_budget_treasury = { treasury = short_term_treasury from = budget_short_term to = budget_war_chest }
move_budget_treasury = { treasury = long_term_treasury from = budget_long_term to = budget_short_term }
}
}
if = {
limit = {
is_at_war = no
OR = {
AND = {
has_treasury = yes
war_chest_treasury >= war_chest_treasury_maximum
}
AND = {
has_treasury = no
war_chest_gold >= war_chest_gold_maximum
}
}
}
ai_start_best_war = {
cb = {
chinese_consolidation_cb
}
is_valid = {
scope:target_character = {
current_military_strength < root.current_military_strength
OR = {
AND = {
root = { has_treasury = yes }
has_treasury = yes
treasury < root.treasury
}
AND = {
root = { has_treasury = yes }
has_treasury = no
gold < root.treasury
}
AND = {
root = { has_treasury = no }
has_treasury = yes
treasury < root.gold
}
AND = {
root = { has_treasury = no }
has_treasury = no
gold < root.gold
}
current_military_strength <= root.fifty_percent_of_current_military_strength
}
}
}
}
}
}
}
}
}
effect_group = { # Take the decision
days = { 60 120 }
triggered_effect = {
trigger = {
story_owner = {
is_ai = yes
can_execute_decision = situation_dynastic_cycle_claim_mandate_decision
}
}
effect = {
story_owner = {
execute_decision = situation_dynastic_cycle_claim_mandate_decision
}
}
}
}
effect_group = { # Various ways to end the cycle
days = { 900 1800 }
triggered_effect = {
trigger = {
story_owner = {
OR = {
is_independent_ruler = no
is_landed = no
has_trait = incapable
highest_held_title_tier <= tier_county
}
}
}
effect = {
end_story = yes
}
}
}
}

View file

@ -0,0 +1,147 @@
story_tai_migrations = {
on_setup = {
}
on_end = {
every_in_global_list = { # give all saved migration county holders the story if they don't have it already
variable = tai_migration_target_counties
holder = {
if = {
limit = {
NOT = {
any_owned_story = {
type = story_tai_migrations
}
}
any_realm_province = {
culture = {
NOT = {
has_cultural_pillar = heritage_tai
}
}
}
}
create_story = story_tai_migrations
}
}
}
}
on_owner_death = { # pass on the story
story_owner = {
primary_heir ?= {
if = {
limit = {
is_physically_able_adult = yes
is_ai = yes
}
create_story = story_tai_migrations
}
}
}
end_story = yes
}
effect_group = { # Yearly validations
days = 360
triggered_effect = { # end the story if I have no relevant provinces for migration
trigger = {
story_owner = {
NOT = {
any_realm_province = {
geographical_region = custom_tai_migration_target
culture = {
NOT = {
has_cultural_pillar = heritage_tai
}
}
}
}
}
}
effect = {
end_story = yes
}
}
triggered_effect = { # end the story if it has been 100 years from game start
trigger = {
years_from_game_start >= 100
}
effect = {
end_story = yes
}
}
triggered_effect = { # end the story if X provinces in the Tai region have already been migrated
trigger = {
any_county_in_region = {
region = custom_tai_migration_target
count >= 14
any_county_province = {
culture = { has_cultural_pillar = heritage_tai }
}
}
}
effect = {
end_story = yes
}
}
triggered_effect = { # end the story if all provinces in the migration origin are non-tai
trigger = {
any_county_in_region = {
region = custom_tai_migration_origin
count = 0
any_county_province = {
culture = { has_cultural_pillar = heritage_tai }
}
}
}
effect = {
end_story = yes
}
}
}
effect_group = { # if all validations are checked, trigger event pulses
days = 365
chance = 13
triggered_effect = {
trigger = {
}
effect = {
random_list = {
3 = {
story_owner = {
trigger_event = tgp_tai_migration_event.1000
}
}
4 = {
story_owner = {
trigger_event = tgp_tai_migration_event.2000
}
}
1 = {
story_owner = {
trigger_event = tgp_tai_migration_event.3000
}
}
4 = {
story_owner = {
trigger_event = tgp_tai_migration_event.4000
}
}
4 = {
story_owner = {
trigger_event = tgp_tai_migration_event.5000
}
}
}
}
}
}
}

View file

@ -1500,198 +1500,198 @@ major_decisions.3100 = {
} }
################### ###################
# Merge Aquitaine # ## Merge Aquitaine #
################### ####################
major_decisions.3200 = { #major_decisions.3200 = {
type = character_event # type = character_event
title = major_decisions.3200.t # title = major_decisions.3200.t
desc = major_decisions.3200.desc # desc = major_decisions.3200.desc
theme = realm # theme = realm
left_portrait = { # left_portrait = {
trigger = { # trigger = {
this != scope:rightful_liege # this != scope:rightful_liege
} # }
character = root # character = root
triggered_animation = { # triggered_animation = {
trigger = { # trigger = {
NOR = { # NOR = {
opinion = { # opinion = {
target = scope:rightful_liege # target = scope:rightful_liege
value >= 25 # value >= 25
} # }
root.culture = scope:rightful_liege.culture # root.culture = scope:rightful_liege.culture
culture = { any_parent_culture_or_above = { this = scope:rightful_liege.culture } } # culture = { any_parent_culture_or_above = { this = scope:rightful_liege.culture } }
} # }
} # }
animation = disapproval # animation = disapproval
} # }
animation = obsequious_bow # animation = obsequious_bow
} # }
#
right_portrait = { # right_portrait = {
character = scope:rightful_liege # character = scope:rightful_liege
animation = personality_honorable # animation = personality_honorable
} # }
#
immediate = { # immediate = {
show_as_tooltip = { # show_as_tooltip = {
destroy_title = scope:destroyed_title # destroy_title = scope:destroyed_title
scope:rightful_title = { # scope:rightful_title = {
if = { # if = {
limit = { # limit = {
this = title:k_aquitaine # this = title:k_aquitaine
} # }
every_in_de_jure_hierarchy = { # every_in_de_jure_hierarchy = {
custom = merge_aquitaine_decision_tooltip_alt # custom = merge_aquitaine_decision_tooltip_alt
custom_tooltip = merge_aquitaine_decision_tooltip_2_alt # custom_tooltip = merge_aquitaine_decision_tooltip_2_alt
} # }
} # }
else = { # else = {
every_in_de_jure_hierarchy = { # every_in_de_jure_hierarchy = {
custom = merge_aquitaine_decision_tooltip_original # custom = merge_aquitaine_decision_tooltip_original
custom_tooltip = merge_aquitaine_decision_tooltip_2_original # custom_tooltip = merge_aquitaine_decision_tooltip_2_original
} # }
} # }
} # }
} # }
} # }
#
option = { # option = {
name = major_decisions.3200.a # name = major_decisions.3200.a
trigger = { # trigger = {
NOR = { # NOR = {
opinion = { # opinion = {
target = scope:rightful_liege # target = scope:rightful_liege
value >= 25 # value >= 25
} # }
root.culture = scope:rightful_liege.culture # root.culture = scope:rightful_liege.culture
culture = { any_parent_culture_or_above = { this = scope:rightful_liege.culture } } # culture = { any_parent_culture_or_above = { this = scope:rightful_liege.culture } }
} # }
} # }
} # }
#
option = { # option = {
name = major_decisions.3200.b # name = major_decisions.3200.b
trigger = { # trigger = {
OR = { # OR = {
opinion = { # opinion = {
target = scope:rightful_liege # target = scope:rightful_liege
value >= 25 # value >= 25
} # }
root.culture = scope:rightful_liege.culture # root.culture = scope:rightful_liege.culture
culture = { any_parent_culture_or_above = { this = scope:rightful_liege.culture } } # culture = { any_parent_culture_or_above = { this = scope:rightful_liege.culture } }
} # }
} # }
} # }
} #}
#Restore Carthage ##Restore Carthage
major_decisions.3300 = { #major_decisions.3300 = {
type = character_event # type = character_event
title = major_decisions.3300.t # title = major_decisions.3300.t
desc = major_decisions.3300.desc # desc = major_decisions.3300.desc
theme = crown # theme = crown
#
override_effect_2d = { reference = legend_glow } # override_effect_2d = { reference = legend_glow }
#
left_portrait = { # left_portrait = {
character = root # character = root
animation = sword_coup_degrace # animation = sword_coup_degrace
camera = camera_torso_scheme_right_look_right # camera = camera_torso_scheme_right_look_right
} # }
#
immediate = { # immediate = {
restore_carthage_scripted_effect = yes # restore_carthage_scripted_effect = yes
#
culture = { save_scope_as = founder_culture } # culture = { save_scope_as = founder_culture }
} # }
#
option = { # option = {
name = major_decisions.3300.a # name = major_decisions.3300.a
#
hidden_effect = { # hidden_effect = {
culture:carthaginian = { # culture:carthaginian = {
get_all_innovations_from = scope:founder_culture # get_all_innovations_from = scope:founder_culture
} # }
} # }
#
#convert people to your new culture # #convert people to your new culture
convert_family_culture_and_notify_vassals_effect = { # convert_family_culture_and_notify_vassals_effect = {
OLD_CULTURE = root.culture # OLD_CULTURE = root.culture
NEW_CULTURE = culture:carthaginian # NEW_CULTURE = culture:carthaginian
CONVERTER = root # CONVERTER = root
} # }
#
#convert capital counties to carthaginian # #convert capital counties to carthaginian
title:c_tunis = { # title:c_tunis = {
set_county_culture = culture:carthaginian # set_county_culture = culture:carthaginian
} # }
title:c_tripolitana = { # title:c_tripolitana = {
set_county_culture = culture:carthaginian # set_county_culture = culture:carthaginian
} # }
title:c_algier = { # title:c_algier = {
set_county_culture = culture:carthaginian # set_county_culture = culture:carthaginian
} # }
title:c_murcia = { # title:c_murcia = {
set_county_culture = culture:carthaginian # set_county_culture = culture:carthaginian
} # }
} # }
#
option = { # option = {
name = major_decisions.3300.b # name = major_decisions.3300.b
} # }
} #}
#
############## ###############
# Carantania # ## Carantania #
############## ###############
major_decisions.3400 = { #major_decisions.3400 = {
type = character_event # type = character_event
title = major_decisions.3400.t # title = major_decisions.3400.t
desc = major_decisions.3400.desc # desc = major_decisions.3400.desc
theme = crown # theme = crown
override_background = ce1_legendary_spring # override_background = ce1_legendary_spring
left_portrait = { # left_portrait = {
character = root # character = root
animation = pondering # animation = pondering
} # }
window = big_event_window # window = big_event_window
#
widget = { gui = event_window_widget_vfx_godray container = foreground_shader_vfx_container } # widget = { gui = event_window_widget_vfx_godray container = foreground_shader_vfx_container }
#
immediate = { # immediate = {
decision_restore_carantania_effect = yes # decision_restore_carantania_effect = yes
} # }
#
option = { # option = {
name = major_decisions.3400.a # name = major_decisions.3400.a
} # }
} #}
#
########### ############
# Cumbria # ## Cumbria #
########### ############
major_decisions.3500 = { #major_decisions.3500 = {
type = character_event # type = character_event
title = major_decisions.3500.t # title = major_decisions.3500.t
desc = major_decisions.3500.desc # desc = major_decisions.3500.desc
theme = crown # theme = crown
override_background = council_chamber # override_background = council_chamber
left_portrait = { # left_portrait = {
character = root # character = root
animation = pondering # animation = pondering
} # }
window = big_event_window # window = big_event_window
#
widget = { gui = event_window_widget_vfx_godray container = foreground_shader_vfx_container } # widget = { gui = event_window_widget_vfx_godray container = foreground_shader_vfx_container }
#
immediate = { # immediate = {
form_cumbria_decision_scripted_effect = yes # form_cumbria_decision_scripted_effect = yes
} # }
#
option = { # option = {
name = major_decisions.3500.a # name = major_decisions.3500.a
} # }
} #}
# #
#################### ####################
## Cossack Kingdom # ## Cossack Kingdom #

View file

@ -1304,291 +1304,6 @@ ep3_laamps.1030 = {
name = ep3_laamps.1032.a name = ep3_laamps.1032.a
} }
} }
##################################################
# Become Adventurer - Revocation
# by Joe Parkin
# 0040-0041
##################################################
# Come back
scripted_trigger ep3_laamp_revoked_title_trigger = {
recent_history = { type = revoked days = 1 }
previous_holder = root
}
ep3_laamps.0040 = {
type = character_event
window = fullscreen_event
title = ep3_laamps.0040.t
desc = {
first_valid = {
triggered_desc = {
trigger = {
scope:actor = { is_close_family_of = root }
}
desc = ep3_laamps.0040.family
}
desc = ep3_laamps.0040.other
}
desc = ep3_laamps.0040.desc
}
theme = realm
left_portrait = {
character = root
animation = marshal
}
lower_left_portrait = scope:alt_1
lower_center_portrait = scope:alt_2
lower_right_portrait = scope:alt_3
override_background = { reference = ep3_fullscreen_adventurer_negative }
cooldown = { days = 5 }
# The AI was managing to get this event somehow.
trigger = {
is_ai = no
NOT = { has_character_flag = become_laamp_event_cooldown }
}
immediate = {
add_character_flag = {
flag = become_laamp_event_cooldown
days = 5
}
# Find alternative rulers to play as
find_playable_relatives_effect = yes
# Portrait scopes
if = {
limit = {
NOR = {
exists = scope:alt_3
scope:alt_1 ?= scope:actor
scope:alt_2 ?= scope:actor
}
}
scope:actor = { save_scope_as = alt_3 }
}
# Create Adventurer
hidden_effect = {
create_landless_adventurer_title_effect = {
REASON = flag:revocation
FLAVOR_CHAR = scope:actor
}
}
adventurer_prestige_reset_effect = yes
}
option = {
name = ep3_laamps.0040.a
create_landless_adventurer_title_tooltip_effect = yes
add_internal_flag = special
scope:actor = { trigger_event = ep3_laamps.0042 }
}
option = {
name = ep3_laamps.0001.b
trigger = { exists = scope:alt_1 }
laamp_switch_playable_character_effect = { NEW_CHARACTER = scope:alt_1 }
}
option = {
name = ep3_laamps.0001.c
trigger = { exists = scope:alt_2 }
laamp_switch_playable_character_effect = { NEW_CHARACTER = scope:alt_2 }
}
option = {
name = ep3_laamps.0001.d
trigger = {
exists = scope:alt_3
scope:alt_3 = { playable_relative_trigger = yes }
}
laamp_switch_playable_character_effect = { NEW_CHARACTER = scope:alt_3 }
}
option = {
name = ep3_laamps.0001.e
laamp_game_over_option_effect = yes
}
}
# Setup event
ep3_laamps.0041 = {
type = character_event
hidden = yes
trigger = {
has_ep3_dlc_trigger = yes
is_landed = no
is_valid_for_laampdom = yes
}
immediate = {
save_scope_as = adventurer
# AI chance
if = {
limit = {
is_ai = yes
ai_can_valid_to_create_laamp_trigger = yes
trigger_if = { # Don't fill the adventurer pool with revoked counts
limit = {
scope:lost_primary_title.tier <= tier_county
}
global_variable_list_size = {
name = laamps_tally
value < seventyfive_percent_of_max_desired_laamps_value
}
}
}
random = {
chance = 0
modifier = { add = ep3_laamp_chance_score_value }
create_landless_adventurer_title_effect = {
REASON = flag:revocation
FLAVOR_CHAR = scope:actor
}
scope:actor = { trigger_event = ep3_laamps.0042 }
}
}
# Player event
else = {
trigger_event = { id = ep3_laamps.0040 }
}
}
}
# Revoker event
ep3_laamps.0042 = {
type = letter_event
opening = ep3_laamps.0003.opening
desc = ep3_laamps.0042.desc
sender = scope:adventurer
trigger = { is_ai = no }
immediate = {
create_landless_adventurer_title_tooltip_effect = yes
}
option = {
name = ep3_laamps.0042.a
}
}
ep3_laamps.1030 = {
type = character_event
window = fullscreen_event
title = ep3_laamps.1030.t
desc = {
desc = ep3_laamps.1030.desc
first_valid = {
triggered_desc = {
trigger = { exists = scope:laamp_heir }
desc = ep3_laamps.1030.heir
}
triggered_desc = {
trigger = { exists = scope:laamp_liege }
desc = ep3_laamps.1030.liege
}
desc = ep3_laamps.1030.new
}
}
theme = realm
left_portrait = {
character = root
animation = marshal
}
lower_right_portrait = scope:laamp_inheritor
override_background = { reference = ep3_fullscreen_adventurer_positive }
cooldown = { days = 5 }
trigger = { exists = scope:laamp_inheritor }
immediate = {
# Save scopes for loc
primary_title = { save_scope_as = old_primary_title }
capital_province = { save_scope_as = old_capital_province }
if = {
limit = { top_liege != this }
liege = { save_scope_as = old_liege }
}
# Transfer landed titles
every_held_title = {
title_tier > barony
limit = {
OR = {
is_landless_type_title = no
is_nomad_title = yes
}
}
add_to_list = target_titles
}
create_title_and_vassal_change = {
type = conquest
save_scope_as = change
add_claim_on_loss = no
}
hidden_effect = {
every_in_list = {
list = target_titles
change_title_holder_include_vassals = {
holder = scope:laamp_inheritor
change = scope:change
}
}
resolve_title_and_vassal_change = scope:change
}
# Create Adventurer
create_landless_minority_title_effect = {
REASON = flag:voluntary
FLAVOR_CHAR = scope:laamp_inheritor
}
scope:laamp_inheritor = {
# Tooltip for player
custom_tooltip = become_landless_adventurer_decision_title_scope_tt
# Create a loving family so inheritance isn't so borked
if = {
limit = { has_character_flag = new_laamp_inheritor }
trigger_event = game_rule.1001
remove_character_flag = new_laamp_inheritor
}
}
scope:old_liege ?= { trigger_event = ep3_laamps.1032 }
adventurer_prestige_reset_effect = yes
hidden_effect = {
every_held_title = {
limit = {
is_noble_family_title = yes
}
root = { destroy_title = prev }
}
}
}
option = {
name = ep3_laamps.1030.a
create_landless_minority_title_tooltip_effect = yes
add_prestige = medium_prestige_gain
add_character_modifier = {
modifier = ep3_voluntary_laamp_character_modifier
years = 5
}
}
}
# Liege event
ep3_laamps.1032 = {
type = letter_event
opening = ep3_laamps.1032.opening
desc = ep3_laamps.1032.desc
sender = scope:minority_leader
trigger = { is_ai = no }
immediate = {
scope:minority_leader = { create_landless_minority_title_tooltip_effect = yes }
}
option = {
name = ep3_laamps.1032.a
}
}
################################################## ##################################################
# Become Adventurer - Revocation # Become Adventurer - Revocation