Scripted effect
pick_imprisonment_effect_based_on_sexual_relation_effect
pick_imprisonment_effect_based_on_sexual_relation_effect = { IMPRISONER = … PARTNER = … TARGET = … }game/common/scripted_effects/00_prison_effects.txt, line 2434 (22 lines). Parameters: $IMPRISONER$, $PARTNER$, $TARGET$.
pick_imprisonment_effect_based_on_sexual_relation_effect is a scripted effect in Crusader Kings III, written at line 2434 of its file. A call passes 3 parameters: IMPRISONER, PARTNER and TARGET. The game's script calls it in 1 place, among them Forbidden Love (event yearly.0003). Patch 1.20.1.2, from game/common/scripted_effects/00_prison_effects.txt.
The comment above it in the file
An effect that picks imprison_character_effect or rightfully_imprison_character_effect as punishment for a sexual relationship, good to not show tyranny tooltip if imprisonment reason hasn't been set yet. But this should NEVER be used if the imprisonment reason isn't going to be set by the same piece of content.
What it does
If
$TARGET$ = { … }
Then
rightfully_imprison_character_effect = { TARGET = $TARGET$ IMPRISONER = $IMPRISONER$ }
Otherwise
imprison_character_effect = { TARGET = $TARGET$ IMPRISONER = $IMPRISONER$ }
• 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 (22 lines of game script)
pick_imprisonment_effect_based_on_sexual_relation_effect = {
if = {
limit = {
$TARGET$ = {
sexual_activity_with_partner_is_criminal_in_rite_trigger = {
PARTNER = $PARTNER$
RITE = $IMPRISONER$.rite
}
}
}
rightfully_imprison_character_effect = {
TARGET = $TARGET$
IMPRISONER = $IMPRISONER$
}
}
else = {
imprison_character_effect = {
TARGET = $TARGET$
IMPRISONER = $IMPRISONER$
}
}
}As written in game/common/scripted_effects/00_prison_effects.txt.
Where it is used
Every place in common/, events/ and history/ that calls pick_imprisonment_effect_based_on_sexual_relation_effect.
Events (1)
- Forbidden Love
yearly.0003
Source: game/common/scripted_effects/00_prison_effects.txt and every file of common/, events/ and history/ that calls it, Crusader Kings III 1.20.1.2.