CK3 DatabaseCrusader Kings III · 1.20.1.2 “Crozier” · unofficial
Silk & Silverout Tue, Nov 17What's free, what needs the DLC, price →

Scripted trigger

valid_laamp_contract_foe_trigger

valid_laamp_contract_foe_trigger = yes

game/common/scripted_triggers/00_laamp_triggers.txt, line 739 (43 lines). No parameters.

valid_laamp_contract_foe_trigger is a scripted trigger in Crusader Kings III, written at line 739 of its file. It takes no parameters: valid_laamp_contract_foe_trigger = yes (or no). The game's script calls it in 1 place, among them laamp_contract_grab_suitable_rival_for_disposal_effect (scripted effect). Patch 1.20.1.2, from game/common/scripted_triggers/00_laamp_triggers.txt.

What it checks

• 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 (43 lines of game script)
valid_laamp_contract_foe_trigger = {
	# Make sure they're at home if possible.
	NOR = {
		is_travelling = yes
		is_commanding_army = yes
		is_imprisoned = no
	}
	# Good sensible restrictions on mutual relationships.
	OR = {
		has_any_bad_relationship_with_character_trigger = { CHARACTER = scope:employer_ref }
		# Ensure a bit of mild dislike.
		reverse_opinion = {
			target = scope:employer_ref
			value <= -25
		}
		opinion = {
			target = scope:employer_ref
			value <= -25
		}
	}
	NOR = {
		# Filter out anything that might look odd.
		has_any_good_relationship_with_character_trigger = { CHARACTER = scope:employer_ref }
		# Plus don't include anything connected to a player.
		save_temporary_scope_as = char_temp
		any_player = {
			OR = {
				this = scope:char_temp
				is_close_or_extended_family_of = scope:char_temp
				is_consort_of = scope:char_temp
				has_any_bad_relationship_with_character_trigger = { CHARACTER = scope:char_temp }
				has_any_good_relationship_with_character_trigger = { CHARACTER = scope:char_temp }
			}
		}
	}
	# And check their location is valid.
	location = {
		# Which means making sure that they're not located too far away from our contractor.
		"squared_distance(root.task_contract_taker.location)" <= squared_distance_large
		# And that they're not located in the exact same province, else travel logic'll break.
		this != scope:employer_ref.location
	}
}

As written in game/common/scripted_triggers/00_laamp_triggers.txt.

Where it is used

Every place in common/, events/ and history/ that calls valid_laamp_contract_foe_trigger.

Source: game/common/scripted_triggers/00_laamp_triggers.txt and every file of common/, events/ and history/ that calls it, Crusader Kings III 1.20.1.2.

Spotted a mistake on this page?