CK3 DatabaseCrusader Kings III · 1.20.1.2 “Crozier” · unofficial
Silk & Silverout Tue, Nov 17What's free, what needs the DLC, price →

Scripted effect · By God Alone files

pam_heresy_dispatch_founder_spawn_effect

pam_heresy_dispatch_founder_spawn_effect = yes

game/common/scripted_effects/pam_heresy_shared_effects.txt, line 508 (120 lines). No parameters.

pam_heresy_dispatch_founder_spawn_effect is a scripted effect in Crusader Kings III, in the By God Alone files, written at line 508 of its file. It takes no parameters: pam_heresy_dispatch_founder_spawn_effect = yes. The game's script calls it in 1 place, among them heresy_historical.0001 (event). Patch 1.20.1.2, from game/common/scripted_effects/pam_heresy_shared_effects.txt.

The comment above it in the file

--- Founder spawn dispatcher (any scope) ---
Calls the matching per-heresy founder template based on scope:heresy_faith
and the resurgence stage. Saves scope:founder at scope:birth_location.
Stage logic (named historical heresies):
  first outbreak:                spawn the primary historical figure
  second outbreak (resurgence):  spawn the named secondary historical figure
  third+ outbreak:               spawn the per-heresy anonymous resurgence
Always-anonymous heresies (Paulician, Iconoclast, Adoptionist, Messalian) always use their single anonymous template.

What it does

• 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 (120 lines of game script)
pam_heresy_dispatch_founder_spawn_effect = {
	if = {
		limit = { scope:heresy_faith = faith:lollard }
		if = {
			limit = { exists = scope:is_resurgence }
			if = {
				limit = { NOT = { exists = global_var:pam_heresy_lollard_secondary_fired } }
				pam_heresy_spawn_lollard_secondary_founder_effect = yes
				set_global_variable = { name = pam_heresy_lollard_secondary_fired value = yes }
			}
			else = {
				pam_heresy_spawn_lollard_resurgence_founder_effect = yes
			}
		}
		else = {
			pam_heresy_spawn_lollard_founder_effect = yes
		}
	}
	else_if = {
		limit = { scope:heresy_faith = faith:hussite }
		if = {
			limit = { exists = scope:is_resurgence }
			if = {
				limit = { NOT = { exists = global_var:pam_heresy_hussite_secondary_fired } }
				pam_heresy_spawn_hussite_secondary_founder_effect = yes
				set_global_variable = { name = pam_heresy_hussite_secondary_fired value = yes }
			}
			else = {
				pam_heresy_spawn_hussite_resurgence_founder_effect = yes
			}
		}
		else = {
			pam_heresy_spawn_hussite_founder_effect = yes
		}
	}
	else_if = {
		limit = { scope:heresy_faith = faith:joachimite }
		if = {
			limit = { exists = scope:is_resurgence }
			if = {
				limit = { NOT = { exists = global_var:pam_heresy_joachimite_secondary_fired } }
				pam_heresy_spawn_joachimite_secondary_founder_effect = yes
				set_global_variable = { name = pam_heresy_joachimite_secondary_fired value = yes }
			}
			else = {
				pam_heresy_spawn_joachimite_resurgence_founder_effect = yes
			}
		}
		else = {
			pam_heresy_spawn_joachimite_founder_effect = yes
		}
	}
	else_if = {
		limit = { scope:heresy_faith = faith:cathar }
		if = {
			limit = { exists = scope:is_resurgence }
			if = {
				limit = { NOT = { exists = global_var:pam_heresy_cathar_secondary_fired } }
				pam_heresy_spawn_cathar_secondary_founder_effect = yes
				set_global_variable = { name = pam_heresy_cathar_secondary_fired value = yes }
			}
			else = {
				pam_heresy_spawn_cathar_resurgence_founder_effect = yes
			}
		}
		else = {
			pam_heresy_spawn_cathar_founder_effect = yes
		}
	}
	else_if = {
		limit = { scope:heresy_faith = faith:waldensian }
		if = {
			limit = { exists = scope:is_resurgence }
			if = {
				limit = { NOT = { exists = global_var:pam_heresy_waldensian_secondary_fired } }
				pam_heresy_spawn_waldensian_secondary_founder_effect = yes
				set_global_variable = { name = pam_heresy_waldensian_secondary_fired value = yes }
			}
			else = {
				pam_heresy_spawn_waldensian_resurgence_founder_effect = yes
			}
		}
		else = {
			pam_heresy_spawn_waldensian_founder_effect = yes
		}
	}
	else_if = {
		limit = { scope:heresy_faith = faith:bogomilist }
		if = {
			limit = { exists = scope:is_resurgence }
			if = {
				limit = { NOT = { exists = global_var:pam_heresy_bogomilist_secondary_fired } }
				pam_heresy_spawn_bogomilist_secondary_founder_effect = yes
				set_global_variable = { name = pam_heresy_bogomilist_secondary_fired value = yes }
			}
			else = {
				pam_heresy_spawn_bogomilist_resurgence_founder_effect = yes
			}
		}
		else = {
			pam_heresy_spawn_bogomilist_founder_effect = yes
		}
	}
	else_if = {
		limit = { scope:heresy_faith = faith:paulician }
		pam_heresy_spawn_paulician_founder_effect = yes
	}
	else_if = {
		limit = { scope:heresy_faith = faith:iconoclast }
		pam_heresy_spawn_iconoclast_founder_effect = yes
	}
	else_if = {
		limit = { scope:heresy_faith = faith:adoptionist }
		pam_heresy_spawn_adoptionist_founder_effect = yes
	}
	else_if = {
		limit = { scope:heresy_faith = faith:messalian }
		pam_heresy_spawn_messalian_founder_effect = yes
	}
}

As written in game/common/scripted_effects/pam_heresy_shared_effects.txt.

Where it is used

Every place in common/, events/ and history/ that calls pam_heresy_dispatch_founder_spawn_effect.

Source: game/common/scripted_effects/pam_heresy_shared_effects.txt and every file of common/, events/ and history/ that calls it, Crusader Kings III 1.20.1.2.

Spotted a mistake on this page?