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

Scripted trigger · Roads to Power files

ep3_laamp_diplo_range_trigger

ep3_laamp_diplo_range_trigger = { LAAMP = … TARGET = … }

game/common/scripted_triggers/07_ep3_triggers.txt, line 1041 (43 lines). Parameters: $LAAMP$, $TARGET$.

ep3_laamp_diplo_range_trigger is a scripted trigger in Crusader Kings III, in the Roads to Power files, written at line 1041 of its file. A call passes 2 parameters: LAAMP and TARGET. The game's script calls it in 26 places, among them Abduct (Scheme) (interaction), Ask for Invasion Sponsorship (interaction) and Befriend (Scheme) (interaction). Patch 1.20.1.2, from game/common/scripted_triggers/07_ep3_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)
ep3_laamp_diplo_range_trigger = {
	custom_description = {
		text = ep3_laamp_diplo_range_trigger_tt
		subject = $LAAMP$
		object = $TARGET$
		trigger_if = {
			limit = { exists = $LAAMP$.domicile.domicile_location }
			trigger_if = {
				limit = {
					NOT = { exists = $TARGET$.capital_province }
					exists = $TARGET$.host.capital_province
				}
				$TARGET$.host.capital_province ?= {
					squared_distance = {
						target = $LAAMP$.domicile.domicile_location
						value < define:NTaskContract|ADVENTURER_DISTANCE_RESTRICTION
					}
				}
			}
			trigger_else_if = {
				limit = {
					NOT = { exists = $TARGET$.capital_province }
					exists = $TARGET$.location
				}
				$TARGET$.location ?= {
					squared_distance = {
						target = $LAAMP$.domicile.domicile_location
						value < define:NTaskContract|ADVENTURER_DISTANCE_RESTRICTION
					}
				}
			}
			trigger_else = {
				$TARGET$.capital_province ?= {
					squared_distance = {
						target = $LAAMP$.domicile.domicile_location
						value < define:NTaskContract|ADVENTURER_DISTANCE_RESTRICTION
					}
				}
			}
		}
		trigger_else = { always = no }
	}
}

As written in game/common/scripted_triggers/07_ep3_triggers.txt.

Where it is used

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

Source: game/common/scripted_triggers/07_ep3_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?