hopefully updated on actions and scripted triggers
This commit is contained in:
parent
84ac41f6ca
commit
a4d812a52c
27 changed files with 10879 additions and 4415 deletions
|
|
@ -9,7 +9,6 @@
|
|||
# scope:diverged (true/false) optional scope, true if the faith was created because of a Rite diverging too much. Notice create a 100+ divergence heresy at the start does not count.
|
||||
on_faith_created = {
|
||||
effect = {
|
||||
main_rite = { force_refresh_head_of_rite = yes }
|
||||
# Faiths created by a rite diverging too far start at 0 fervor
|
||||
if = {
|
||||
limit = {
|
||||
|
|
@ -177,26 +176,6 @@ on_faith_created = {
|
|||
}
|
||||
}
|
||||
}
|
||||
# The founding wave (founder and vassals who already accepted) brings their courts, as with a new rite
|
||||
# Listed first, since the conversions below add characters to the faith being iterated
|
||||
if = {
|
||||
limit = {
|
||||
NOT = { scope:diverged ?= yes }
|
||||
}
|
||||
root = {
|
||||
every_faith_character = {
|
||||
limit = { is_ruler = yes }
|
||||
add_to_temporary_list = pam_reform_founding_wave
|
||||
}
|
||||
}
|
||||
every_in_list = {
|
||||
list = pam_reform_founding_wave
|
||||
pam_convert_court_to_faith_effect = {
|
||||
FAITH = root
|
||||
OLD_FAITH = scope:old_faith
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
else = {
|
||||
scope:founder ?= {
|
||||
|
|
@ -292,6 +271,109 @@ on_faith_created = {
|
|||
pam_seed_cardinals_effect = yes
|
||||
}
|
||||
}
|
||||
# Achievements - evaluated on the acting character, as add_achievement_* gate on is_ai.
|
||||
scope:founder ?= {
|
||||
if = {
|
||||
limit = { faith = root }
|
||||
add_achievement_flag_effect = { FLAG = achievement_its_not_a_cult_flag }
|
||||
if = {
|
||||
limit = {
|
||||
scope:old_faith = {
|
||||
religion_tag = west_african_religion
|
||||
has_doctrine_parameter = unreformed
|
||||
}
|
||||
}
|
||||
add_achievement_global_variable_effect = {
|
||||
VARIABLE = achievement_mother_of_us_all_siguic
|
||||
VALUE = yes
|
||||
}
|
||||
}
|
||||
if = {
|
||||
limit = {
|
||||
scope:old_faith = {
|
||||
religion_tag = west_african_orisha_religion
|
||||
has_doctrine_parameter = unreformed
|
||||
}
|
||||
}
|
||||
add_achievement_global_variable_effect = {
|
||||
VARIABLE = achievement_mother_of_us_all_orisha
|
||||
VALUE = yes
|
||||
}
|
||||
}
|
||||
if = {
|
||||
limit = {
|
||||
scope:old_faith = {
|
||||
religion_tag = west_african_bori_religion
|
||||
has_doctrine_parameter = unreformed
|
||||
}
|
||||
}
|
||||
add_achievement_global_variable_effect = {
|
||||
VARIABLE = achievement_mother_of_us_all_bori
|
||||
VALUE = yes
|
||||
}
|
||||
}
|
||||
if = {
|
||||
limit = {
|
||||
scope:old_faith = {
|
||||
religion_tag = west_african_roog_religion
|
||||
has_doctrine_parameter = unreformed
|
||||
}
|
||||
}
|
||||
add_achievement_global_variable_effect = {
|
||||
VARIABLE = achievement_mother_of_us_all_roog_sene
|
||||
VALUE = yes
|
||||
}
|
||||
}
|
||||
if = {
|
||||
limit = {
|
||||
scope:old_faith = {
|
||||
religion_tag = akom_religion
|
||||
has_doctrine_parameter = unreformed
|
||||
}
|
||||
}
|
||||
add_achievement_global_variable_effect = {
|
||||
VARIABLE = achievement_mother_of_us_all_akom
|
||||
VALUE = yes
|
||||
}
|
||||
}
|
||||
if = {
|
||||
limit = {
|
||||
scope:old_faith = {
|
||||
religion_tag = kushitism_religion
|
||||
has_doctrine_parameter = unreformed
|
||||
}
|
||||
}
|
||||
add_achievement_global_variable_effect = {
|
||||
VARIABLE = achievement_mother_of_us_all_kushitism
|
||||
VALUE = yes
|
||||
}
|
||||
}
|
||||
if = {
|
||||
limit = {
|
||||
scope:old_faith = {
|
||||
religion_tag = waaqism_religion
|
||||
has_doctrine_parameter = unreformed
|
||||
}
|
||||
}
|
||||
add_achievement_global_variable_effect = {
|
||||
VARIABLE = achievement_mother_of_us_all_waaqism
|
||||
VALUE = yes
|
||||
}
|
||||
}
|
||||
if = {
|
||||
limit = {
|
||||
scope:old_faith = {
|
||||
religion_tag = north_african_religion
|
||||
has_doctrine_parameter = unreformed
|
||||
}
|
||||
}
|
||||
add_achievement_global_variable_effect = {
|
||||
VARIABLE = achievement_mother_of_us_all_achamanism
|
||||
VALUE = yes
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
# These events need a character, so they fire on the new faith's head, never a founder outside the faith
|
||||
root.main_rite.head_of_rite ?= {
|
||||
trigger_event = faith_conversion.0001 # Convert capital county
|
||||
|
|
@ -438,11 +520,13 @@ on_rite_created = {
|
|||
has_character_flag = forced_conversion_on_reform
|
||||
}
|
||||
set_character_faith = root.faith
|
||||
set_character_rite = root.rite
|
||||
every_vassal_or_below = {
|
||||
limit = { faith = scope:old_faith }
|
||||
random = {
|
||||
chance = 75
|
||||
set_character_faith = root.faith
|
||||
set_character_rite = root.rite
|
||||
}
|
||||
}
|
||||
every_sub_realm_county = {
|
||||
|
|
@ -450,6 +534,7 @@ on_rite_created = {
|
|||
random = {
|
||||
chance = 75
|
||||
set_county_faith = root.faith
|
||||
set_county_rite = root.rite
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -641,10 +726,18 @@ on_faith_conversion = {
|
|||
}
|
||||
}
|
||||
trigger_event = NEOW_dynamic_titles.1000
|
||||
}
|
||||
|
||||
######################################################
|
||||
}
|
||||
|
||||
set_variable = {
|
||||
name = old_rite
|
||||
value = scope:old_rite
|
||||
days = 30
|
||||
}
|
||||
pam_on_conversion_effect = yes
|
||||
pam_remove_forbidden_personal_tenet_secret_if_invalid_effect = yes
|
||||
update_syncretism_personal_tenet_effect = yes
|
||||
# EP3 - State Faith
|
||||
if = {
|
||||
limit = {
|
||||
|
|
@ -967,12 +1060,12 @@ on_rite_change = {
|
|||
}
|
||||
}
|
||||
random_held_title = {
|
||||
limit = {
|
||||
tier = tier_county
|
||||
limit = {
|
||||
tier = tier_county
|
||||
any_county_province = {
|
||||
has_variable = monastic_order_capital
|
||||
}
|
||||
}
|
||||
}
|
||||
random_county_province = {
|
||||
limit = {
|
||||
has_variable = monastic_order_capital
|
||||
|
|
@ -1469,7 +1562,7 @@ pagan_conversion_pulse = {
|
|||
}
|
||||
|
||||
events = {
|
||||
# global_religion.0001 #Pagan reformed by neighbor, spouse, soulmate, friend, or geographic location
|
||||
global_religion.0001 #Pagan reformed by neighbor, spouse, soulmate, friend, or geographic location
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -1862,304 +1955,3 @@ on_character_holy_site_created = {
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
on_character_faith_change = {
|
||||
effect = {
|
||||
check_for_equal_doctrine_effect = yes
|
||||
every_held_title = {
|
||||
update_dynamic_coa = yes
|
||||
}
|
||||
|
||||
# Struggles
|
||||
## Struggle Catalysts
|
||||
### Heir changes culture while under age
|
||||
if = {
|
||||
limit = {
|
||||
catalyst_very_important_child_change_culture_or_faith_preliminary_trigger = yes
|
||||
}
|
||||
random_parent = {
|
||||
limit = {
|
||||
any_character_struggle = {
|
||||
involvement = involved
|
||||
}
|
||||
}
|
||||
every_character_struggle = {
|
||||
involvement = involved
|
||||
activate_struggle_catalyst = {
|
||||
catalyst = catalyst_very_important_child_change_culture_or_faith
|
||||
character = root
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
# ## Struggle Effects
|
||||
## ### persian_struggle: switching faith to anything that isn't an orthodox Sunni creed'll flip you to detractor.
|
||||
## if = {
|
||||
## limit = {
|
||||
## # Gotta be in the appropriate struggle.
|
||||
## any_character_struggle = { this = struggle:persian_struggle }
|
||||
## # Filter out pre-existing detractors.
|
||||
## NOT = { has_trait = fp3_struggle_detractor }
|
||||
## # Now, check the new faith.
|
||||
## exists = title:d_sunni.holder
|
||||
## OR = {
|
||||
## NOT = { exists = faith.religious_head }
|
||||
## NOT = { faith.religious_head = title:d_sunni.holder }
|
||||
## }
|
||||
## }
|
||||
## send_interface_toast = {
|
||||
## type = event_toast_effect_neutral
|
||||
## title = persian_struggle.tt.converted_away_from_sunni_orthodoxy
|
||||
## left_icon = root
|
||||
## hidden_effect = { remove_trait = fp3_struggle_supporter }
|
||||
## add_trait_force_tooltip = fp3_struggle_detractor
|
||||
## }
|
||||
## }
|
||||
#
|
||||
# # Local conversion
|
||||
# if = {
|
||||
# limit = {
|
||||
# exists = root.capital_province
|
||||
# root.capital_province.faith = root.faith
|
||||
# any_character_struggle = {
|
||||
# involvement = involved
|
||||
# phase_has_catalyst = catalyst_convert_local_culture_faith
|
||||
# is_faith_involved_in_struggle = root.faith
|
||||
# }
|
||||
# }
|
||||
# every_character_struggle = {
|
||||
# involvement = involved
|
||||
# activate_struggle_catalyst = {
|
||||
# catalyst = catalyst_convert_local_culture_faith
|
||||
# character = root
|
||||
# }
|
||||
# }
|
||||
# }
|
||||
# else_if = { # Forced conversion
|
||||
# limit = {
|
||||
# any_character_struggle = {
|
||||
# involvement = involved
|
||||
# is_faith_involved_in_struggle = root.faith
|
||||
# phase_has_catalyst = catalyst_forced_conversion
|
||||
# }
|
||||
# }
|
||||
# every_character_struggle = {
|
||||
# involvement = involved
|
||||
# activate_struggle_catalyst = {
|
||||
# catalyst = catalyst_forced_conversion
|
||||
# character = root
|
||||
# }
|
||||
# }
|
||||
# }
|
||||
# else_if = {
|
||||
# limit = {
|
||||
# has_trait = fp3_struggle_supporter
|
||||
# any_character_struggle = {
|
||||
# involvement = involved
|
||||
# is_faith_involved_in_struggle = root.faith
|
||||
# phase_has_catalyst = catalyst_supporter_forced_conversion
|
||||
# }
|
||||
# }
|
||||
# every_character_struggle = {
|
||||
# involvement = involved
|
||||
# activate_struggle_catalyst = {
|
||||
# catalyst = catalyst_supporter_forced_conversion
|
||||
# character = root
|
||||
# }
|
||||
# log_debug_variable_for_persian_struggle_effect = { VAR = unrest_catalyst_supporter_forced_conversion }
|
||||
# }
|
||||
# }
|
||||
# else_if = {
|
||||
# limit = {
|
||||
# has_trait = fp3_struggle_detractor
|
||||
# any_character_struggle = {
|
||||
# involvement = involved
|
||||
# is_faith_involved_in_struggle = root.faith
|
||||
# phase_has_catalyst = catalyst_detractor_forced_conversion
|
||||
# }
|
||||
# }
|
||||
# every_character_struggle = {
|
||||
# involvement = involved
|
||||
# activate_struggle_catalyst = {
|
||||
# catalyst = catalyst_detractor_forced_conversion
|
||||
# character = root
|
||||
# }
|
||||
# log_debug_variable_for_persian_struggle_effect = { VAR = stabil_catalyst_detractor_forced_conversion }
|
||||
# }
|
||||
# }
|
||||
|
||||
|
||||
# Achievements
|
||||
if = {
|
||||
limit = { is_ai = no }
|
||||
|
||||
if = { # FP2 - Basque In My Glory
|
||||
limit = { faith = faith:basque_pagan }
|
||||
add_achievement_global_variable_effect = {
|
||||
VARIABLE = fp2_basque_in_my_glory_achievement_unlocked
|
||||
VALUE = yes
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
# Hostage story cycle
|
||||
if = {
|
||||
limit = {
|
||||
is_hostage = yes
|
||||
is_adult = no
|
||||
# Did they just change to their captor's culture
|
||||
faith = warden.faith
|
||||
}
|
||||
save_scope_as = hostage
|
||||
warden = {
|
||||
trigger_event = bp2_yearly.8050
|
||||
}
|
||||
}
|
||||
|
||||
if = {
|
||||
limit = {
|
||||
has_variable = japan_1010_discount
|
||||
var:japan_1010_discount = faith
|
||||
}
|
||||
remove_variable = japan_1010_discount
|
||||
}
|
||||
|
||||
if = {
|
||||
limit = {
|
||||
has_character_flag = tgp_japan_1040_discount
|
||||
faith.religion = religion:shintoism_religion
|
||||
}
|
||||
remove_character_flag = tgp_japan_1040_discount
|
||||
}
|
||||
|
||||
#Lose Mandala if you change to a monotheist faith
|
||||
mandala_no_longer_polytheist_effect = yes
|
||||
}
|
||||
events = {
|
||||
faith_conversion.0002 # Remove obsolete modifiers
|
||||
faith_conversion.0004 # Convert Theocracies
|
||||
faith_conversion.0005 # Update marriage opinions
|
||||
great_holy_war.0025 # Replace Recipient for ongoing GHW
|
||||
great_holy_war.0029 # Beneficiary converted, remove and replace.
|
||||
great_holy_war.0059 # Clear Crusader traits on conversion.
|
||||
great_holy_war.0084 # Replace fallback ghw recipient
|
||||
great_holy_war.0085 # Remove pledged vassals upon conversion of their liege.
|
||||
war_event.3100 # Handles invalidation of religious wars
|
||||
}
|
||||
}
|
||||
|
||||
faith_fervor_events_pulse = {
|
||||
trigger = {
|
||||
NOR = {
|
||||
has_doctrine_parameter = unreformed
|
||||
has_variable = recent_fervor_event
|
||||
}
|
||||
}
|
||||
|
||||
random_events = {
|
||||
chance_to_happen = 6 # ~53% chance of occurring within a given year. 90% chance within 3 years, 99.8% chance within 5.
|
||||
100 = fervor.1001
|
||||
100 = fervor.2001
|
||||
}
|
||||
}
|
||||
|
||||
on_rite_updated = {
|
||||
events = {
|
||||
}
|
||||
|
||||
effect = {
|
||||
root = {
|
||||
save_scope_as = rite
|
||||
}
|
||||
|
||||
if = { # slient it for EC since EC has unique evvent to inform
|
||||
limit = {
|
||||
exists = scope:changed_tenets_or_doctrines
|
||||
OR = {
|
||||
NOT = {
|
||||
faith = { has_variable = ecumenical_council_ongoing }
|
||||
}
|
||||
exists = scope:consume_rite_edit_token
|
||||
}
|
||||
}
|
||||
|
||||
# The message icon slot must never be left unset, hence the fall-through to the rite itself
|
||||
if = {
|
||||
limit = { any_in_list = { list = added_tenets count >= 1 } }
|
||||
every_in_list = {
|
||||
list = added_tenets
|
||||
save_scope_as = rite_change_icon
|
||||
}
|
||||
}
|
||||
else_if = {
|
||||
limit = { any_in_list = { list = added_doctrines count >= 1 } }
|
||||
every_in_list = {
|
||||
list = added_doctrines
|
||||
save_scope_as = rite_change_icon
|
||||
}
|
||||
}
|
||||
else_if = {
|
||||
limit = { any_in_list = { list = removed_tenets count >= 1 } }
|
||||
every_in_list = {
|
||||
list = removed_tenets
|
||||
save_scope_as = rite_change_icon
|
||||
}
|
||||
}
|
||||
else_if = {
|
||||
limit = { any_in_list = { list = removed_doctrines count >= 1 } }
|
||||
every_in_list = {
|
||||
list = removed_doctrines
|
||||
save_scope_as = rite_change_icon
|
||||
}
|
||||
}
|
||||
else = {
|
||||
root = { save_scope_as = rite_change_icon }
|
||||
}
|
||||
|
||||
every_player = {
|
||||
limit = {
|
||||
OR = {
|
||||
rite = root
|
||||
AND = {
|
||||
faith = root.faith
|
||||
root.faith.main_rite = root
|
||||
}
|
||||
}
|
||||
}
|
||||
send_interface_message = {
|
||||
type = msg_rite_updated
|
||||
title = msg_rite_updated
|
||||
left_icon = scope:rite_change_icon
|
||||
|
||||
show_as_tooltip = {
|
||||
every_in_list = {
|
||||
list = removed_doctrines
|
||||
root = { remove_rite_doctrine = prev }
|
||||
}
|
||||
every_in_list = {
|
||||
list = added_doctrines
|
||||
root = { add_rite_doctrine = prev }
|
||||
}
|
||||
every_in_list = {
|
||||
list = removed_tenets
|
||||
root = { remove_rite_tenet = prev }
|
||||
}
|
||||
every_in_list = {
|
||||
list = added_tenets
|
||||
root = { add_rite_tenet = prev }
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
head_of_rite ?= {
|
||||
trigger_event = faith_creation.0004 # Update HoF succession law
|
||||
trigger_event = faith_creation.0001 # Temporal rel head setup
|
||||
trigger_event = faith_creation.0002 # Spiritual rel head setup
|
||||
trigger_event = faith_creation.0011 # Restore Temporal rel head
|
||||
trigger_event = faith_creation.0012 # Restore Spiritual rel head
|
||||
trigger_event = faith_creation.1100 # Destroy HoF title if no longer valid
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue