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

Scripted effect · The Royal Court files

inspired_character_seek_out_new_royal_court_effect

inspired_character_seek_out_new_royal_court_effect = yes

game/common/scripted_effects/00_ep1_inspiration_effects_sean.txt, line 829 (147 lines). No parameters.

inspired_character_seek_out_new_royal_court_effect is a scripted effect in Crusader Kings III, in the The Royal Court files, written at line 829 of its file. It takes no parameters: inspired_character_seek_out_new_royal_court_effect = yes. The game's script calls it in 1 place, among them inspiration_system.1001 (event). Patch 1.20.1.2, from game/common/scripted_effects/00_ep1_inspiration_effects_sean.txt.

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)
inspired_character_seek_out_new_royal_court_effect = {
	save_scope_as = inspired_character

	# Look to see if there is a nearby court we can visit that might fund our inspiration.
	random_character_with_royal_court = {
		limit = {
			# Do not travel outside of diplomatic range in a single 'jump'
			in_diplomatic_range = scope:inspired_character

			# Do not visit the ruler we had just left, unless at least 5 years have passed.
			trigger_if = {
				limit = { scope:inspired_character = { has_variable = last_visited_ruler } }
				scope:inspired_character.var:last_visited_ruler != this
			}

			# Only visit rulers who do not consider our faith to be hostile, if possible.
			faith = {
				faith_hostility_level = {
					target = scope:inspired_character.faith
					value <= faith_hostile_level
				}
			}
			exists = capital_province
			save_temporary_scope_as = tmp_royal_court_owner # Used in 'inspiration_kingdom_modifier' to calculate draw towards this specific court in the region.
		}
		alternative_limit = {
			in_diplomatic_range = scope:inspired_character
			trigger_if = {
				limit = { scope:inspired_character = { has_variable = last_visited_ruler } }
				scope:inspired_character.var:last_visited_ruler != this
			}
			# Failing that, if possible do not visit rulers who consider our faith to be outright evil.
			faith = {
				faith_hostility_level = {
					target = scope:inspired_character.faith
					value <= faith_evil_level
				}
			}
			exists = capital_province
			save_temporary_scope_as = tmp_royal_court_owner
		}
		alternative_limit = {
			# Failing that, we can visit anyone else in range. 
			in_diplomatic_range = scope:inspired_character
			trigger_if = {
				limit = { scope:inspired_character = { has_variable = last_visited_ruler } }
				scope:inspired_character.var:last_visited_ruler != this
			}
			exists = capital_province
			save_temporary_scope_as = tmp_royal_court_owner
		}

		weight = {
			base = 10
			inspiration_royal_court_grandeur_attraction_modifier = yes

			# Prefer visiting royal courts which are physically closer to us
			modifier = {
				factor = 0.9 # Total 90.0% weight
				capital_province = {
					squared_distance = {
						target = scope:inspired_character.location
						value >= squared_distance_small #150 map-pixels. Roughly one Wales away (top to bottom).
					}
				}
			}
			modifier = {
				factor = 0.8 # Total 72.0% weight
				capital_province = {
					squared_distance = {
						target = scope:inspired_character.location
						value >= squared_distance_medium #250 map-pixels. Roughly one Ireland away (top to bottom).
					}
				}
			}
			modifier = {
				factor = 0.6 # Total 43.2% weight
				capital_province = {			
					squared_distance = {		
						target = scope:inspired_character.location
						value >= squared_distance_large #650 map-pixels. Roughly one France away (top to bottom).
					}
				}
			}
			modifier = {
				factor = 0.3 # Total 12.9% weight
				capital_province = {			
					squared_distance = {
						target = scope:inspired_character.location
						value >= squared_distance_huge #850 map-pixels. Roughly one Holy Roman Empire away (left to right).
					}
				}
			}
			
			# Down-prioritize courts with a lot of inspired people already
			modifier = {
				factor = 0.9
				any_courtier_or_guest = {
					count >= 2
					exists = inspiration
				}
			}
			modifier = {
				factor = 0.8
				any_courtier_or_guest = {
					count >= 3
					exists = inspiration
				}
			}
			modifier = {
				factor = 0.7
				any_courtier_or_guest = {
					count >= 4
					exists = inspiration
				}
			}
			modifier = {
				factor = 0.6
				any_courtier_or_guest = {
					count >= 5

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

The first 120 of its 147 lines; the rest is in game/common/scripted_effects/00_ep1_inspiration_effects_sean.txt from line 829.

Where it is used

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

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