Scripted effect
camp_officer_grant_effect
camp_officer_grant_effect = { CANDIDATE = … EMPLOYER = … POS = … }game/common/scripted_effects/00_court_position_effects.txt, line 736 (63 lines). Parameters: $CANDIDATE$, $EMPLOYER$, $POS$.
camp_officer_grant_effect is a scripted effect in Crusader Kings III, written at line 736 of its file. A call passes 3 parameters: CANDIDATE, EMPLOYER and POS. The game's script calls it in 13 places, among them …: … is in Trouble! (event ep3_laamp_decision_event.1037), …: the Armorer (event ep3_laamp_decision_event.1063) and …: the Quartermaster (event ep3_laamp_decision_event.1067). Patch 1.20.1.2, from game/common/scripted_effects/00_court_position_effects.txt.
What it does
Every line of it is script with no tooltip text: the script is below.
The script as written (63 lines of game script)
camp_officer_grant_effect = { # Give position, and revoke old holder's if they exist
if = {
limit = {
$EMPLOYER$.court_position:$POS$_camp_officer ?= { has_court_position = $POS$_camp_officer }
}
$EMPLOYER$.court_position:$POS$_camp_officer = { save_scope_as = old_holder }
}
$CANDIDATE$ = {
save_scope_as = candidate
if = {
limit = {
NOR = {
is_vassal_of = $EMPLOYER$
is_courtier_of = $EMPLOYER$
employer = $EMPLOYER$
}
}
hidden_effect = { set_employer = $EMPLOYER$ }
}
}
$EMPLOYER$ = {
if = {
limit = { exists = scope:old_holder }
send_interface_toast = {
title = move_and_grant_court_position_effect_tooltip
left_icon = $CANDIDATE$
right_icon = scope:old_holder
replace_court_position = {
recipient = $CANDIDATE$
holder = scope:old_holder
court_position = $POS$_camp_officer
}
}
}
else = {
send_interface_toast = {
title = move_and_grant_court_position_effect_tooltip
left_icon = $CANDIDATE$
appoint_court_position = {
recipient = $CANDIDATE$
court_position = $POS$_camp_officer
}
}
}
}
$CANDIDATE$ = {
$EMPLOYER$ = {
save_scope_as = liege
if = {
limit = { exists = scope:old_holder }
custom_tooltip = $POS$_old_holder_aptitude_tooltip
}
else = { custom_tooltip = $POS$_aptitude_tooltip }
}
}
#LAAMPs don't pay salaries
if = {
limit = {
$EMPLOYER$ = { is_landless_adventurer = no }
}
custom_tooltip = $POS$_salary_tooltip
}
}As written in game/common/scripted_effects/00_court_position_effects.txt.
Where it is used
Every place in common/, events/ and history/ that calls camp_officer_grant_effect.
Events (8)
- …: … is in Trouble!
ep3_laamp_decision_event.1037 - …: the Armorer
ep3_laamp_decision_event.1063 - …: the Quartermaster
ep3_laamp_decision_event.1067 - …: the Training Grounds
ep3_laamp_decision_event.1051 - A Hunt Master
hunt.0540 - A Strange Sailor
ep3_laamps.8080
2 more
- Isma'ili Preachers
hasan_sabbah.1000 - The Mercenaries of …
travel_events_bp3.30
Scripted effects inside an event file (3)
- 1037_hire_thief_effect
- 1067_hire_quartermaster_effect
- ep3_laamp_flavour_ewan_2071_apply_appointment_effect
Source: game/common/scripted_effects/00_court_position_effects.txt and every file of common/, events/ and history/ that calls it, Crusader Kings III 1.20.1.2.