Hands-On Usage
In career mode–related mods, when you need to temporarily move a persisted value from a career profile (such as match count or total score) into a temporary variable for subsequent complex calculations, this trigger can be used. It performs an "assignment" action within a condition block and returns true, making it commonly nested within if or custom_trigger_tooltip to handle intermediate values without polluting global variables.
trigger = {
career_profile_set_temp_playthrough_variable = {
var = temp_score_snapshot
value = career_total_score
}
check_variable = {
var = temp_score_snapshot
value > 500
}
}
Synergy
[check_variable](/wiki/trigger/check_variable) — Immediately after assignment, use check_variable to perform numerical comparisons on the temporary variable; this is the most typical usage pattern.
[career_profile_check_playthrough_value](/wiki/trigger/career_profile_check_playthrough_value) — Together, these allow you to snapshot career data into a temporary variable first, then use dedicated career value checks for multi-step conditional logic.
[multiply_temp_variable](/wiki/trigger/multiply_temp_variable) — After obtaining the temporary variable, apply multiplicative scaling to it, making it convenient to convert raw career data into percentages or weight values for subsequent evaluations.
[if](/wiki/trigger/if) — Place this trigger within the limit block of an if statement to implement branching logic: "only execute the snapshot and continue subsequent checks if certain preconditions are met."
Common Pitfalls
- Mistakenly using it as an effect: Beginners sometimes write this trigger into
immediate or regular effect blocks, causing parse errors. It can only appear within condition contexts such as trigger, limit, available, or allowed. To assign temporary variables within an effect block, use [set_temp_variable](/wiki/effect/set_temp_variable) instead.
- Confusing the direction of
var and value fields: var is the name of the target temporary variable being assigned, while value is the data source (which can be another variable name or a constant). Reversing them won't trigger an error but will produce completely incorrect data, making it extremely difficult to detect during troubleshooting.