Scripted effect
expansion_cb_title_transfer
expansion_cb_title_transfer = yesgame/common/scripted_effects/00_war_effects.txt, line 751 (99 lines). No parameters.
expansion_cb_title_transfer is a scripted effect in Crusader Kings III, written at line 751 of its file. It takes no parameters: expansion_cb_title_transfer = yes. The game's script calls it in 3 places, among them Duchy Expansion (casus belli), Naval Duchy Expansion (casus belli) and Sponsored Administrative War (casus belli). Patch 1.20.1.2, from game/common/scripted_effects/00_war_effects.txt.
What it does
- Every in de jure hierarchy:
- Where:
- Title tier exactly County
- Their holder:
One of these
this = scope:defenderor
target_is_liege_or_above = scope:defender
continue = { tier > tier_county }
- Where:
- One in list, picked in order › Otherwise › Every sub realm county:
remove_from_list = titles_taken
• 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)
expansion_cb_title_transfer = {
save_scope_as = target_title # For the vassalization trigger.
# Compile a list of all counties in the target title we will take from the defender.
every_in_de_jure_hierarchy = {
continue = {
tier > tier_county
}
limit = {
tier = tier_county
# Current holder must be a (sub)vassal of the defender (no poaching titles from 3rd parties!)
holder ?= {
OR = {
this = scope:defender
target_is_liege_or_above = scope:defender
}
}
}
add_to_list = titles_taken
}
if = {
limit = {
save_temporary_scope_as = checked_title
tier >= scope:attacker.highest_held_title_tier
OR = {
AND = {
is_title_created = yes
holder = {
NOT = {
any_sub_realm_county = {
NOT = { target_is_de_jure_liege_or_above = scope:checked_title }
}
}
}
}
AND = {
is_title_created = no
any_de_jure_county = {
percent > 0.5
holder ?= {
OR = {
this = scope:defender
any_liege_or_above = { this = scope:defender }
}
}
}
}
}
}
add_to_list = target_title_taken
}
# If we can take the current holder of a title as a vassal instead of siezing their land directly, do so.
every_in_de_jure_hierarchy = {
limit = {
tier >= tier_county
conquest_cb_holder_under_target_can_be_vassalized = yes
}
# Mark this vassal as being eligible to transfer from the defender to the attacker.
holder = {
if = {
limit = {
NOT = { is_in_list = potential_vassals}
}
add_to_list = potential_vassals
}
}
}
ordered_in_list = {
list = potential_vassals
order_by = highest_held_title_tier
max = 99
check_range_bounds = no
if = {
# If a liege has already been added to the vassalization list, skip us (we will remain our liege's vassal.)
limit = {
save_temporary_scope_as = this_vassal
any_in_list = {
list = vassals_taken
target_is_vassal_or_below = scope:this_vassal
}
}
}
else = {
# Flag this character to be vassalized instead of usurped.
add_to_list = vassals_taken
# Remove the counties this vassal holds from the seized title list (the vassal gets to keep their land when switching allegiance!)
every_sub_realm_county = {
remove_from_list = titles_taken
}
}
}
}As written in game/common/scripted_effects/00_war_effects.txt.
Where it is used
Every place in common/, events/ and history/ that calls expansion_cb_title_transfer.
Source: game/common/scripted_effects/00_war_effects.txt and every file of common/, events/ and history/ that calls it, Crusader Kings III 1.20.1.2.