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

Scripted effect

add_achievement_variable_effect

add_achievement_variable_effect = { VALUE = … VARIABLE = … }

game/common/scripted_effects/00_achievement_effects.txt, line 12 (20 lines). Parameters: $VALUE$, $VARIABLE$.

add_achievement_variable_effect is a scripted effect in Crusader Kings III, written at line 12 of its file. A call passes 2 parameters: VALUE and VARIABLE. The game's script calls it in 1 place, among them seduce_success (on action). Patch 1.20.1.2, from game/common/scripted_effects/00_achievement_effects.txt.

The comment above it in the file

Adds $VALUE$ to the character $VARIABLE$ if a player, sets to zero first if not already a present variable

What it does

Every line of it is script with no tooltip text: the script is below.

The script as written (20 lines of game script)
add_achievement_variable_effect = {
	if = {
		limit = {
			is_ai = no
		}
		if = {
			limit = {
				NOT = { has_variable = $VARIABLE$ }
			}
			set_variable = {
				name = $VARIABLE$
				value = 0
			}
		}
		change_variable = {
			name = $VARIABLE$
			add = $VALUE$
		}
	}
}

As written in game/common/scripted_effects/00_achievement_effects.txt.

Where it is used

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

On actions (the game's own hooks) (1)

  • seduce_success

Source: game/common/scripted_effects/00_achievement_effects.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?