Scripted trigger
num_realm_holy_sites_faithful_holders
num_realm_holy_sites_faithful_holders = { CHARACTER = … COUNT = … }game/common/scripted_triggers/00_religious_triggers.txt, line 1431 (45 lines). Parameters: $CHARACTER$, $COUNT$.
num_realm_holy_sites_faithful_holders is a scripted trigger in Crusader Kings III, written at line 1431 of its file. A call passes 2 parameters: CHARACTER and COUNT. The game's script calls it in 4 places, among them can_create_rite_trigger (scripted trigger), can_create_spiritual_head_of_faith_title_trigger (scripted trigger) and can_create_temporal_head_of_faith_title_trigger (scripted trigger). Its body carries 1 text of the game's own for the player. Patch 1.20.1.2, from game/common/scripted_triggers/00_religious_triggers.txt.
The comment above it in the file
Used in faith scope, COUNT is number of faiths to at least have and CHARACTER is who must own them
What it checks
$CHARACTER$ = { save_temporary_scope_as = root_scope }- Your Realm contains … Holy Sites with … Holders (at least …)
• 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 (45 lines of game script)
num_realm_holy_sites_faithful_holders = {
$CHARACTER$ = { save_temporary_scope_as = root_scope }
trigger_if = {
limit = {
exists = $CHARACTER$.confederation
}
custom_description = {
text = direct_realm_holy_sites_held_by_faithful_confederation
subject = $CHARACTER$
object = this
value = 1
any_holy_site_barony = {
county = {
save_temporary_scope_as = current_holy_site
is_holy_site_controlled_by = $CHARACTER$
holder.faith = $CHARACTER$.faith
}
}
}
}
custom_description = {
text = number_realm_holy_sites_held_by_faithful
subject = $CHARACTER$
object = this
value = $COUNT$
any_holy_site_barony = {
count >= $COUNT$
county = {
save_temporary_scope_as = current_holy_site
OR = {
is_holy_site_controlled_by = $CHARACTER$
$CHARACTER$.confederation ?= {
is_house_based = no # any_confederation_member is not performant for house blocs
any_confederation_member = {
scope:current_holy_site = {
is_holy_site_controlled_by = prev
}
}
}
}
holder.faith = $CHARACTER$.faith
}
}
}
}As written in game/common/scripted_triggers/00_religious_triggers.txt.
Where it is used
Every place in common/, events/ and history/ that calls num_realm_holy_sites_faithful_holders.
Source: game/common/scripted_triggers/00_religious_triggers.txt and every file of common/, events/ and history/ that calls it, Crusader Kings III 1.20.1.2.