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

Scripted effect

assign_landed_realm_priest_effect

assign_landed_realm_priest_effect = yes

game/common/scripted_effects/00_councillor_effects.txt, line 1122 (73 lines). No parameters.

assign_landed_realm_priest_effect is a scripted effect in Crusader Kings III, written at line 1122 of its file. It takes no parameters: assign_landed_realm_priest_effect = yes. The game's script calls it in 2 places, among them on_game_start_after_lobby (on action) and Court Chaplain (council positions). Patch 1.20.1.2, from game/common/scripted_effects/00_councillor_effects.txt.

The comment above it in the file

Runs on the council owner

What it does

  • If

    • scope:chosen_realm_priest:
    • NOT = { cp:councillor_court_chaplain ?= scope:chosen_realm_priest }

    Then

    • assign_councillor_type = { type = councillor_court_chaplain remove_existing_councillor = yes target = scope:chosen_realm_priest }

• 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 (73 lines of game script)
assign_landed_realm_priest_effect = {
	save_temporary_scope_as = realm_priest_liege

	if = {
		limit = {
			capital_county.clerical_region_title.holder ?= {
				can_be_landed_realm_priest_trigger = { COURT_OWNER = scope:realm_priest_liege }
			}
		}
		capital_county.clerical_region_title.holder = {
			save_temporary_scope_as = chosen_realm_priest
		}
	}
	else_if = {
		limit = {
			any_vassal = {
				can_be_landed_realm_priest_trigger = { COURT_OWNER = scope:realm_priest_liege }
				capital_county.clerical_region_title.holder ?= this
			}
		}
		ordered_vassal = {
			limit = {
				can_be_landed_realm_priest_trigger = { COURT_OWNER = scope:realm_priest_liege }
				capital_county.clerical_region_title.holder ?= this
			}
			order_by = capital_county.clerical_region_title.clerical_region_size
			position = 0
			save_temporary_scope_as = chosen_realm_priest
		}
	}
	else_if = {
		limit = {
			faith.religious_head ?= {
				can_be_landed_realm_priest_trigger = { COURT_OWNER = scope:realm_priest_liege }
			}
		}
		faith.religious_head = {
			save_temporary_scope_as = chosen_realm_priest
		}
	}
	else_if = {
		limit = {
			any_vassal = {
				can_be_landed_realm_priest_trigger = { COURT_OWNER = scope:realm_priest_liege }
			}
		}
		ordered_vassal = {
			limit = {
				can_be_landed_realm_priest_trigger = { COURT_OWNER = scope:realm_priest_liege }
			}
			order_by = learning
			position = 0
			save_temporary_scope_as = chosen_realm_priest
		}
	}

	# We check again because scope:chosen_realm_priest can still be set from an earlier council owner
	# Skip an already seated pick so repeat calls do not cycle the seat
	if = {
		limit = {
			exists = scope:chosen_realm_priest
			scope:chosen_realm_priest = {
				can_be_landed_realm_priest_trigger = { COURT_OWNER = scope:realm_priest_liege }
			}
			NOT = { cp:councillor_court_chaplain ?= scope:chosen_realm_priest }
		}
		assign_councillor_type = {
			type = councillor_court_chaplain
			remove_existing_councillor = yes
			target = scope:chosen_realm_priest
		}
	}
}

As written in game/common/scripted_effects/00_councillor_effects.txt.

Where it is used

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

On actions (the game's own hooks) (1)

  • on_game_start_after_lobby

Council positions (1)

  • Court Chaplain

Source: game/common/scripted_effects/00_councillor_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?