Scripted trigger · All Under Heaven files
has_better_house_relation_with_target_house_than_other_trigger
has_better_house_relation_with_target_house_than_other_trigger = { OTHER = … TARGET = … }game/common/scripted_triggers/10_tgp_house_relation_triggers.txt, line 86 (119 lines). Parameters: $OTHER$, $TARGET$.
has_better_house_relation_with_target_house_than_other_trigger is a scripted trigger in Crusader Kings III, in the All Under Heaven files, written at line 86 of its file. A call passes 2 parameters: OTHER and TARGET. The game's script calls it in 1 place, among them Claim House Bloc Leadership (interaction). Patch 1.20.1.2, from game/common/scripted_triggers/10_tgp_house_relation_triggers.txt.
What it checks
$TARGET$ = { save_temporary_scope_as = target_temp }$OTHER$ = { save_temporary_scope_as = other_temp }If
- Any house relation: Any relation house:
None of these
- Any house relation › Any relation house:
this = scope:other_temp
- Any house relation › Any relation house:
Then
scope:target_relation_temp:One of these
has_house_relation_level = cordialor
has_house_relation_level = friendlyor
has_house_relation_level = amity
Else if
- Any house relation: Any relation house:
- Any house relation: Any relation house:
Then
scope:target_relation_temp:If
has_house_relation_level = feud
Then
scope:other_relation_temp:NOT = { has_house_relation_level = feud }
Else if
has_house_relation_level = rivalry
Then
scope:other_relation_temp:NOT = { has_house_relation_level = rivalry }NOT = { has_house_relation_level = feud }
Else if
has_house_relation_level = quarrel
Then
scope:other_relation_temp:NOT = { has_house_relation_level = quarrel }NOT = { has_house_relation_level = rivalry }NOT = { has_house_relation_level = feud }
Else if
has_house_relation_level = neutral
Then
scope:other_relation_temp:NOT = { has_house_relation_level = neutral }NOT = { has_house_relation_level = quarrel }NOT = { has_house_relation_level = rivalry }NOT = { has_house_relation_level = feud }
Else if
has_house_relation_level = cordial
Then
scope:other_relation_temp:NOT = { has_house_relation_level = cordial }NOT = { has_house_relation_level = neutral }NOT = { has_house_relation_level = quarrel }NOT = { has_house_relation_level = rivalry }NOT = { has_house_relation_level = feud }
Else if
has_house_relation_level = friendly
Then
scope:other_relation_temp:NOT = { has_house_relation_level = friendly }NOT = { has_house_relation_level = cordial }NOT = { has_house_relation_level = neutral }NOT = { has_house_relation_level = quarrel }NOT = { has_house_relation_level = rivalry }NOT = { has_house_relation_level = feud }
Else if
has_house_relation_level = amity
Then
scope:other_relation_temp:NOT = { has_house_relation_level = amity }NOT = { has_house_relation_level = friendly }NOT = { has_house_relation_level = cordial }NOT = { has_house_relation_level = neutral }NOT = { has_house_relation_level = quarrel }NOT = { has_house_relation_level = rivalry }NOT = { has_house_relation_level = feud }
Otherwise
- Never
Otherwise
- Never
• 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 (119 lines of game script)
has_better_house_relation_with_target_house_than_other_trigger = {
save_temporary_scope_as = house_temp
$TARGET$ = { save_temporary_scope_as = target_temp }
$OTHER$ = { save_temporary_scope_as = other_temp }
# If no relation with OTHER, TARGET relation must be positive
trigger_if = {
limit = {
any_house_relation = {
any_relation_house = { this = scope:target_temp }
save_temporary_scope_as = target_relation_temp
}
NOT = {
any_house_relation = {
any_relation_house = { this = scope:other_temp }
}
}
}
scope:target_relation_temp = {
OR = {
has_house_relation_level = cordial
has_house_relation_level = friendly
has_house_relation_level = amity
}
}
}
# If relation with both, TARGET relation must be better than OTHER relation
trigger_else_if = {
limit = {
any_house_relation = {
any_relation_house = { this = scope:target_temp }
save_temporary_scope_as = target_relation_temp
}
any_house_relation = {
any_relation_house = { this = scope:other_temp }
save_temporary_scope_as = other_relation_temp
}
}
scope:target_relation_temp = {
trigger_if = {
limit = { has_house_relation_level = feud }
scope:other_relation_temp = {
NOT = { has_house_relation_level = feud }
}
}
trigger_else_if = {
limit = { has_house_relation_level = rivalry }
scope:other_relation_temp = {
NOR = {
has_house_relation_level = rivalry
has_house_relation_level = feud
}
}
}
trigger_else_if = {
limit = { has_house_relation_level = quarrel }
scope:other_relation_temp = {
NOR = {
has_house_relation_level = quarrel
has_house_relation_level = rivalry
has_house_relation_level = feud
}
}
}
trigger_else_if = {
limit = { has_house_relation_level = neutral }
scope:other_relation_temp = {
NOR = {
has_house_relation_level = neutral
has_house_relation_level = quarrel
has_house_relation_level = rivalry
has_house_relation_level = feud
}
}
}
trigger_else_if = {
limit = { has_house_relation_level = cordial }
scope:other_relation_temp = {
NOR = {
has_house_relation_level = cordial
has_house_relation_level = neutral
has_house_relation_level = quarrel
has_house_relation_level = rivalry
has_house_relation_level = feud
}
}
}
trigger_else_if = {
limit = { has_house_relation_level = friendly }
scope:other_relation_temp = {
NOR = {
has_house_relation_level = friendly
has_house_relation_level = cordial
has_house_relation_level = neutral
has_house_relation_level = quarrel
has_house_relation_level = rivalry
has_house_relation_level = feud
}
}
}
trigger_else_if = {
limit = { has_house_relation_level = amity }
scope:other_relation_temp = {
NOR = {
has_house_relation_level = amity
has_house_relation_level = friendly
has_house_relation_level = cordial
has_house_relation_level = neutral
has_house_relation_level = quarrel
has_house_relation_level = rivalry
has_house_relation_level = feud
}
}
}
trigger_else = { always = no }
}
}
# Invalid
trigger_else = { always = no }
}As written in game/common/scripted_triggers/10_tgp_house_relation_triggers.txt.
Where it is used
Every place in common/, events/ and history/ that calls has_better_house_relation_with_target_house_than_other_trigger.
Character interactions (1)
Source: game/common/scripted_triggers/10_tgp_house_relation_triggers.txt and every file of common/, events/ and history/ that calls it, Crusader Kings III 1.20.1.2.