Scripted effect · Khans of the Steppe files
form_the_greatest_khan_empire_effect
form_the_greatest_khan_empire_effect = yesgame/common/scripted_effects/09_mpo_greatest_of_khans_effects.txt, line 2 (138 lines). No parameters.
form_the_greatest_khan_empire_effect is a scripted effect in Crusader Kings III, in the Khans of the Steppe files, written at line 2 of its file. It takes no parameters: form_the_greatest_khan_empire_effect = yes. The game's script calls it in 2 places, among them My Kurultai Speaks — For All the World! (event mpo_greatest_of_khans.0001) and Rise of the … (event mpo_greatest_of_khans.0002). Patch 1.20.1.2, from game/common/scripted_effects/09_mpo_greatest_of_khans_effects.txt.
The comment above it in the file
Form the actual Mongol Empire...
What it does
Every line of it is script with no tooltip text: the script is below.
The script as written (120 lines of game script)
form_the_greatest_khan_empire_effect = {
save_scope_as = gok
hidden_effect = {
if = {
limit = {
culture = culture:mongol
}
#Create the title
create_title_and_vassal_change = {
type = created
save_scope_as = title_change
add_claim_on_loss = no
}
title:e_mongol_empire = {
change_title_holder = {
holder = scope:gok
change = scope:title_change
}
save_scope_as = gok_title
}
resolve_title_and_vassal_change = scope:title_change
assert_if = {
limit = { NOT = { exists = title:e_mongol_empire } }
text = "Mongol Empire title was not created!"
}
}
else = {
#You never know if they've switched government in the meantime just to ruin this whole thing...
if = {
limit = {
government_has_flag = government_is_nomadic
exists = domicile
}
create_dynamic_title = {
tier = empire
name = GREATEST_OF_KHANS_TITLE_DOMICILE_NAME
adj = GREATEST_OF_KHANS_TITLE_DOMICILE_NAME_ADJ
article = article_CONFEDERATION_CULTURE_NAME
}
scope:new_title = {
save_scope_as = gok_title
}
}
else = {
create_dynamic_title = {
tier = empire
name = GREATEST_OF_KHANS_TITLE_NAME
adj = GREATEST_OF_KHANS_TITLE_NAME_ADJ
article = article_CONFEDERATION_CULTURE_NAME
}
scope:new_title = {
save_scope_as = gok_title
}
}
scope:gok_title = {
set_color_from_title = root.capital_county
set_definitive_form = yes
set_can_be_named_after_dynasty = no
set_can_use_nomadic_naming = no
}
create_title_and_vassal_change = {
type = created
save_scope_as = change
add_claim_on_loss = no
}
scope:gok_title = {
change_title_holder = {
holder = root
change = scope:change
}
}
resolve_title_and_vassal_change = scope:change
scope:gok_title = {
if = {
limit = {
exists = root.house
}
set_coa = root.house
}
else = {
generate_coa = yes
}
}
assert_if = {
limit = { NOT = { exists = scope:gok_title } }
text = "Greatest of Khan's title was not created!"
}
}
if = {
limit = { NOT = { has_realm_law = single_heir_succession_kurultai_law } }
add_realm_law_skip_effects = single_heir_succession_kurultai_law
}
set_primary_title_to = scope:gok_title
every_held_title = {
limit = {
tier = tier_empire
NOT = { this = scope:gok_title }
}
scope:gok = {
destroy_title = prev
}
}
if = {
limit = {
exists = capital_county.empire
capital_county.empire = {
NOT = {
exists = holder
}
}
}
capital_county.empire = {
save_scope_as = old_gok_empireAs written in game/common/scripted_effects/09_mpo_greatest_of_khans_effects.txt.
The first 120 of its 138 lines; the rest is in game/common/scripted_effects/09_mpo_greatest_of_khans_effects.txt from line 2.
Where it is used
Every place in common/, events/ and history/ that calls form_the_greatest_khan_empire_effect.
Events (2)
- My Kurultai Speaks — For All the World!
mpo_greatest_of_khans.0001 - Rise of the …
mpo_greatest_of_khans.0002
Source: game/common/scripted_effects/09_mpo_greatest_of_khans_effects.txt and every file of common/, events/ and history/ that calls it, Crusader Kings III 1.20.1.2.