Scripted effect · By God Alone files
pam_grant_ecclesiastical_title_interaction_effect
pam_grant_ecclesiastical_title_interaction_effect = yesgame/common/scripted_effects/pam_effects.txt, line 7121 (101 lines). No parameters.
pam_grant_ecclesiastical_title_interaction_effect is a scripted effect in Crusader Kings III, in the By God Alone files, written at line 7121 of its file. It takes no parameters: pam_grant_ecclesiastical_title_interaction_effect = yes. The game's script calls it in 2 places, among them Grant Clerical Title (interaction) and Replace Archbishop (interaction). Its body carries 2 texts of the game's own for the player. Patch 1.20.1.2, from game/common/scripted_effects/pam_effects.txt.
The comment above it in the file
Expects scope:target and scope:pam_new_archbishop, and the caller must save pam_old_archbishop first
What it does
scope:actor:If
a check the game hides
Then
- … is deposed: … receives … and all of … lands
Otherwise
- … receives …
add_hook = { type = granted_clerical_title_hook target = scope:pam_new_archbishop }reverse_add_opinion = { target = scope:pam_new_archbishop modifier = grateful_opinion opinion = 50 }
- scope:pam_old_archbishop: Opinion: Resentful (-40)
If
scope:pam_old_archbishop:rite != scope:actor.rite
Then
- scope:actor.faith: Fervor decreases by -5
scope:pam_new_archbishop:- If their government is not Ecclesiastical: Adopts Ecclesiastical Government
- The Christian Church:
add_manual_participant = prev
If
- The Christian Church: The current phase counts “A member of the Clergy has been elevated to a Clerical Region Title”
Then
- The Christian Church: Counts toward the situation's next phase: “A member of the Clergy has been elevated to a Clerical Region Title”
• the game's own tooltip text · ◦ our reading of the script line · code the script where neither exists
“They” is whatever it runs on (the scope it is called in). The scripted triggers and effects it calls link to their own pages; $PARAMETERS$ stay as written: each call fills them in.
The script as written (101 lines of game script)
pam_grant_ecclesiastical_title_interaction_effect = {
scope:actor = {
send_interface_toast = {
type = event_toast_effect_good
title = pam_grant_ecclesiastical_title_toast
left_icon = scope:actor
right_icon = scope:pam_new_archbishop
if = {
limit = { exists = scope:pam_old_archbishop }
custom_tooltip = {
text = pam_grant_ecclesiastical_title_deposed_effect_tt
create_title_and_vassal_change = {
type = granted
save_scope_as = change
add_claim_on_loss = no
}
scope:pam_old_archbishop = {
every_held_title = {
limit = {
OR = {
has_clerical_region = yes
is_landless_type_title = no
}
}
change_title_holder_include_vassals = {
holder = scope:pam_new_archbishop
change = scope:change
government_base = scope:pam_old_archbishop
}
}
}
resolve_title_and_vassal_change = scope:change
}
}
else = {
custom_tooltip = {
text = pam_grant_ecclesiastical_title_vacant_effect_tt
create_title_and_vassal_change = {
type = granted
save_scope_as = change
}
scope:target = {
change_title_holder_include_vassals = {
holder = scope:pam_new_archbishop
change = scope:change
}
}
resolve_title_and_vassal_change = scope:change
}
}
add_hook = {
type = granted_clerical_title_hook
target = scope:pam_new_archbishop
}
}
reverse_add_opinion = {
target = scope:pam_new_archbishop
modifier = grateful_opinion
opinion = 50
}
}
scope:pam_old_archbishop ?= {
add_opinion = {
target = scope:actor
modifier = fp3_resentful_opinion
opinion = -40
}
}
if = {
limit = {
scope:pam_old_archbishop ?= { rite != scope:actor.rite }
}
scope:actor.faith = {
change_fervor = {
value = significant_fervor_loss
desc = fervor_loss_pam_archbishop_deposed
}
}
}
scope:pam_new_archbishop = {
if = {
limit = {
NOT = { government_has_flag = government_is_ecclesiastical }
}
change_government = ecclesiastical_government
}
situation:the_christian_church ?= {
add_manual_participant = prev
}
}
if = {
limit = {
situation:the_christian_church ?= {
situation_top_has_catalyst = catalyst_clergy_elevated_to_archbishopric
}
}
situation:the_christian_church = {
trigger_situation_catalyst = catalyst_clergy_elevated_to_archbishopric
}
}
}As written in game/common/scripted_effects/pam_effects.txt.
Where it is used
Every place in common/, events/ and history/ that calls pam_grant_ecclesiastical_title_interaction_effect.
Character interactions (2)
Source: game/common/scripted_effects/pam_effects.txt and every file of common/, events/ and history/ that calls it, Crusader Kings III 1.20.1.2.