Scripted effect · Roads to Power files
purchase_land_interaction_effect
purchase_land_interaction_effect = yesgame/common/scripted_effects/07_dlc_ep3_scripted_effects.txt, line 1311 (111 lines). No parameters.
purchase_land_interaction_effect is a scripted effect in Crusader Kings III, in the Roads to Power files, written at line 1311 of its file. It takes no parameters: purchase_land_interaction_effect = yes. The game's script calls it in 4 places, among them Purchase Land (interaction), Purchase Sacred Land (interaction) and A Price for Everything (event ep3_laamps.0100). Patch 1.20.1.2, from game/common/scripted_effects/07_dlc_ep3_scripted_effects.txt.
What it does
ep3_become_landed_save_liege_effect = { TITLE_GIVER = scope:recipient ALWAYS_INDEPENDENT = no TITLE_LIST = purchased_titles }scope:actor:pay_short_term_gold = { gold = scope:purchase_land_cost target = scope:recipient }
ep3_become_landed_transfer_effect = { … }- scope:actor: Stress and fulfillment impact: by trait: Greedy +20, Lazy -15
- scope:recipient: Gains … Legitimacy
create_landed_ruler_message_effect = { … }If
scope:offer_hook = yes
Then
scope:recipient:add_hook = { type = obligation_hook target = scope:actor }
• 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 (111 lines of game script)
purchase_land_interaction_effect = {
# scope:actor = adventurer
# scope:recipient = seller
# purchased_titles = titles
hidden_effect = {
scope:actor = {
if = {
limit = { character:90028 ?= this }
add_character_flag = hereward_settled_flag
}
if = {
limit = {
NOT = { has_trait = adventurer }
}
add_trait = adventurer
}
every_courtier = {
set_variable = {
name = former_camp_leader
value = scope:actor
}
add_trait = adventurer_follower
}
}
}
# Determine hierarchy
ep3_become_landed_save_liege_effect = {
TITLE_GIVER = scope:recipient
ALWAYS_INDEPENDENT = no
TITLE_LIST = purchased_titles
}
# Purchase land specific
# actual give recipient the gold
scope:actor = {
pay_short_term_gold = {
gold = scope:purchase_land_cost
target = scope:recipient
}
}
# Resolve title, liege, government changes
ep3_become_landed_transfer_effect = {
TITLE_RECEIVER = scope:actor
TITLE_LIST = purchased_titles
TYPE = granted
REASON = flag:purchased
ENNOBLED_ADVENTURER = flag:yes
}
# Extra purchase land specific
scope:actor = {
stress_and_fulfillment_impact = {
greedy = minor_stress_impact_gain
lazy = minor_stress_impact_loss
}
}
# Effects on land giver
scope:recipient = { add_legitimacy = scope:purchase_land_legitimacy_cost }
# Messages for nearby players
create_landed_ruler_message_effect = {
LANDED = scope:actor
FLAVOR_CHAR = scope:recipient
FLAVOR_TITLE = scope:target
REASON = flag:purchased
}
# Hook
if = {
limit = { scope:offer_hook = yes }
scope:recipient = {
add_hook = {
type = obligation_hook
target = scope:actor
}
}
}
#Handle the government types
if = {
limit = {
scope:recipient = { government_has_flag = government_is_mandala }
#... we're lenient
faith = { has_doctrine = doctrine_polytheist }
}
#Sort out the House shenanigans
hidden_effect = {
if = {
limit = { is_house_head = no }
house ?= {
if = {
limit = {
house_head = {
is_landed = no
is_courtier_of = root
}
}
set_house_head = root
}
}
}
else = {
house ?= {
if = {
limit = {
NOT = { has_house_aspiration_parameter = no_aspect }
}
set_house_aspiration = { type = no_aspect }
}
}
}
}
}
}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 purchase_land_interaction_effect.
Character interactions (2)
Events (2)
- A Price for Everything
ep3_laamps.0100 - ep3_laamps.0101
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.