Scripted effect
change_to_administrative_effect
change_to_administrative_effect = yesgame/common/scripted_effects/00_administrative_effects.txt, line 47 (226 lines). No parameters.
change_to_administrative_effect is a scripted effect in Crusader Kings III, written at line 47 of its file. It takes no parameters: change_to_administrative_effect = yes. The game's script calls it in 12 places, among them Negotiate Release (interaction), minister_project_culture (great project) and char_interaction.0111 (event). Patch 1.20.1.2, from game/common/scripted_effects/00_administrative_effects.txt.
What it does
If
One of these
- Their government does not have the administrative mechanic
or
All of these
- scope:governor_liege: they has administrative government mechanic
government_type != scope:governor_liege.government_type
Then
If
If
a check the game hides
Then
scope:has_selected_a_government = flag:japan_administrative
- Else, if an Independent Ruler:
- Otherwise › scope:governor_liege: Government is Ritsuryō
Then
change_to_administrative_holding_effect = yestgp_domicile_conversion_when_changing_government_type = { NEW_DOMICILE_TYPE = japanese_manor NEW_GOVERNMENT_TYPE = japan_administrative_government }- Adopts Ritsuryō Government
Else if
If
a check the game hides
Then
scope:has_selected_a_government = flag:celestial
Else if
scope:governor_liege ?= this
Then
One of these
tgp_can_become_celestial_trigger = yesor
All of these
exists = scope:great_yuan_rulerthis = scope:great_yuan_ruler- Their primary title is China
Otherwise
- scope:governor_liege: Government is Celestial
Then
change_to_administrative_holding_effect = yestgp_domicile_conversion_when_changing_government_type = { NEW_DOMICILE_TYPE = east_asian_estate NEW_GOVERNMENT_TYPE = celestial_government }- Adopts Celestial Government
Else if
If
a check the game hides
Then
- Never
Otherwise
- scope:governor_liege: Government is Meritocratic Khanate
Then
change_to_administrative_holding_effect = yestgp_domicile_conversion_when_changing_government_type = { NEW_DOMICILE_TYPE = east_asian_estate NEW_GOVERNMENT_TYPE = steppe_admin_government }- Adopts Meritocratic Khanate Government
Else if
If
a check the game hides
Then
scope:has_selected_a_government = flag:meritocratic
Otherwise
- scope:governor_liege: Government is Meritocratic
Then
change_to_administrative_holding_effect = yestgp_domicile_conversion_when_changing_government_type = { NEW_DOMICILE_TYPE = east_asian_estate NEW_GOVERNMENT_TYPE = meritocratic_government }- Adopts Meritocratic Government
Otherwise
change_to_administrative_holding_effect = yestgp_domicile_conversion_when_changing_government_type = { NEW_DOMICILE_TYPE = estate NEW_GOVERNMENT_TYPE = administrative_government }- Adopts Administrative Government
If
primary_title.tier >= min_appointment_tier- Their liege:
scope:governor_liege = this- Government allows: noble families
- Their house’s house head:
top_liege = scope:governor_liegeNone of these
- Any held title: The … is a Noble Family Title
Then
create_noble_family_effect = { GOVERNMENT_GIVER = top_liege }
- If has Treasury:
add_treasury = { value = gold min = 100 }
• 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)
change_to_administrative_effect = {
save_scope_as = governor
if = {
limit = { exists = scope:new_liege }
scope:new_liege = { save_scope_as = governor_liege }
}
else = {
top_liege = { save_scope_as = governor_liege }
}
# exactly 0 treasury, i.e. newly get this feature
if = {
limit = {
OR = {
has_treasury = no
treasury = 0
}
}
save_scope_as = new_treasury
}
# Set the correct government
if = {
limit = {
OR = {
NOT = { government_has_mechanic = administrative }
AND = {
scope:governor_liege = { government_has_mechanic = administrative }
government_type != scope:governor_liege.government_type
}
}
}
# Only case where Estate type is shared between Admin and non-Admin
if = {
limit = {
NAND = {
government_has_flag = government_is_japan_feudal
scope:governor_liege = { government_has_flag = government_is_japan_administrative }
}
}
save_scope_as = new_admin
}
# If we are greek, let's ensure we become administrative
if = {
limit = {
NOT = { exists = scope:has_selected_a_government }
scope:governor_liege = {
this = scope:governor # not vassal of some other admin liege
culture = {
OR = {
this = culture:greek
any_parent_culture_or_above = { this = culture:greek }
}
}
}
}
save_scope_value_as = {
name = has_selected_a_government
value = flag:administrative
}
}
# Change government
# We first check if you have a selected government, then if you are independent, then what your liege has
if = { # Ritsuryo
limit = {
trigger_if = {
limit = {
exists = scope:has_selected_a_government
}
scope:has_selected_a_government = flag:japan_administrative
}
trigger_else_if = {
limit = {
top_liege = this
}
has_tgp_dlc_trigger = yes
tgp_can_become_japan_administrative_trigger = yes
}
trigger_else = {
scope:governor_liege = { government_has_flag = government_is_japan_administrative }
}
}
change_to_administrative_holding_effect = yes
tgp_domicile_conversion_when_changing_government_type = {
NEW_DOMICILE_TYPE = japanese_manor
NEW_GOVERNMENT_TYPE = japan_administrative_government
}
change_government = japan_administrative_government
}
else_if = { # Celestial
limit = {
trigger_if = {
limit = {
exists = scope:has_selected_a_government
}
scope:has_selected_a_government = flag:celestial
}
trigger_else_if = {
limit = {
scope:governor_liege ?= this
}
has_tgp_dlc_trigger = yes
OR = {
tgp_can_become_celestial_trigger = yes
#This is Mongol breakup and they are hegemon
AND = {
exists = scope:great_yuan_ruler
this = scope:great_yuan_ruler
primary_title = title:h_china
}
}
}
trigger_else = {
scope:governor_liege = { government_has_flag = government_is_celestial }
}
}
change_to_administrative_holding_effect = yes
tgp_domicile_conversion_when_changing_government_type = {
NEW_DOMICILE_TYPE = east_asian_estate
NEW_GOVERNMENT_TYPE = celestial_government
}
change_government = celestial_governmentAs written in game/common/scripted_effects/00_administrative_effects.txt.
The first 120 of its 226 lines; the rest is in game/common/scripted_effects/00_administrative_effects.txt from line 47.
Where it is used
Every place in common/, events/ and history/ that calls change_to_administrative_effect.
Character interactions (1)
Great projects (1)
- minister_project_culture
Events (4)
- char_interaction.0111
- char_interaction.0160
- ep3_decisions_event.4065
- The Eternal …
mpo_greatest_of_khans.0030
Source: game/common/scripted_effects/00_administrative_effects.txt and every file of common/, events/ and history/ that calls it, Crusader Kings III 1.20.1.2.