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

Scripted effect · Roads to Power files

admin_change_government_effect

admin_change_government_effect = yes

game/common/scripted_effects/07_dlc_ep3_scripted_effects.txt, line 3900 (99 lines). No parameters.

admin_change_government_effect is a scripted effect in Crusader Kings III, in the Roads to Power files, written at line 3900 of its file. It takes no parameters: admin_change_government_effect = yes. The game's script calls it in 5 places, among them A Change of Direction (event ep3_admin_events.0001), A Realm of My Own (event ep3_admin_events.0005) and on_title_destroyed (on action). Patch 1.20.1.2, from game/common/scripted_effects/07_dlc_ep3_scripted_effects.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 (99 lines of game script)
admin_change_government_effect = {
	# Make sure you only use this effect on characters you are sure should change government! Since we don't do any extended triggers here.
	# For a consistent behaviour, this effect is based on "convert_whole_realm_to_feudalism_effect"

	# First, let's see if the character only has their noble family title - then we don't bother changing their government
	# We only destroy the family title to make sure it doesn't linger
	if = {
		limit = {
			is_landed = no
			NOT = { top_liege = { government_allows = noble_families } }
			any_held_title = {
				is_noble_family_title = yes
			}
			NOT = {
				any_held_title = {
					is_noble_family_title = no
				}
			}
		}
		every_held_title = {
			limit = {
				is_noble_family_title = yes
			}
			save_temporary_scope_as = family_title
			prev = { destroy_title = scope:family_title }
		}
	}

	# If not, let's change the government type
	# If liege has clan - Become clan!
	else_if = {
		limit = {
			top_liege != this
			OR = {
				liege = { government_has_flag = government_is_clan }
				AND = {
					liege = { government_has_flag = government_is_tribal }
					ep3_is_clan_inclined_trigger = yes
				}
			}
		}
		change_government = clan_government
	}
	# If liege has japanese feudal - Become japanese feudal!
	else_if = {
		limit = {
			is_independent_ruler = no
			OR = {
				liege = { government_has_flag = government_is_japan_feudal }
				AND = {
					liege = { government_has_flag = government_is_tribal }
					ep3_is_clan_inclined_trigger = no
				}
			}
		}
		change_government = japan_feudal_government
	}
	# If liege has feudal - Become feudal!
	else_if = {
		limit = {
			top_liege != this
			OR = {
				liege = { government_has_flag = government_is_feudal }
				AND = {
					liege = { government_has_flag = government_is_tribal }
					ep3_is_clan_inclined_trigger = no
				}
			}
		}
		change_government = feudal_government
	}
	# If you're an independent Muslim ruler - Become clan!
	else_if = {
		limit = {
			top_liege = this
			ep3_is_clan_inclined_trigger = yes
		}
		change_government = clan_government
	}
	# If you're an independent ruler with anything else - Become feudal!
	else = { change_government = feudal_government }

	# Finally, let's double-check and see if there are any remaining family titles we should destroy
	if = {
		limit = {
			NOT = { government_allows = noble_families }
			any_held_title = {
				is_noble_family_title = yes
			}
		}
		every_held_title = {
			limit = {
				is_noble_family_title = yes
			}
			save_temporary_scope_as = family_title
			prev = { destroy_title = scope:family_title }
		}
	}
}

As written in game/common/scripted_effects/07_dlc_ep3_scripted_effects.txt.

Where it is used

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

Events (2)

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

  • on_title_destroyed
  • on_vassal_change
  • yearly_playable_pulse

Source: game/common/scripted_effects/07_dlc_ep3_scripted_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?