Scripted effect · Roads to Power files
contract_passive_spawn_effect
contract_passive_spawn_effect = { SPAWN_CONTRACTS = … }game/common/scripted_effects/07_dlc_ep3_scripted_effects.txt, line 2804 (33 lines). Parameters: $SPAWN_CONTRACTS$.
contract_passive_spawn_effect is a scripted effect in Crusader Kings III, in the Roads to Power files, written at line 2804 of its file. A call passes 1 parameter: SPAWN_CONTRACTS. The game's script calls it in 7 places, among them Administrative No More (event ep3_admin_events.0004), ep3_laamps.9981 (event) and ep3_laamps.9983 (event). Patch 1.20.1.2, from game/common/scripted_effects/07_dlc_ep3_scripted_effects.txt.
What it does
Every line of it is script with no tooltip text: the script is below.
The script as written (33 lines of game script)
contract_passive_spawn_effect = {
#count how many contracts you already have
every_character_task_contract = {
add_to_list = num_of_contracts_before
}
# G'is a contract.
populate_location_with_contracts_effect = {
AREA_CHAR = root
AMOUNT = $SPAWN_CONTRACTS$
}
#count them again to see if the effect above spawned something
every_character_task_contract = {
add_to_list = num_of_contracts_after
}
set_local_variable = {
name = current_value
value = list_size:num_of_contracts_before
}
# Make sure we don't get too many of them just sitting in one place.
while = {
limit = {
local_var:current_value < list_size:num_of_contracts_after
}
increment_variable_effect = {
VAR = contract_passive_spawn_tally
VAL = 1
}
change_local_variable = {
name = current_value
add = 1
}
}
}As written in game/common/scripted_effects/07_dlc_ep3_scripted_effects.txt.
Where it is used
Every place in common/, events/ and history/ that calls contract_passive_spawn_effect.
Events (6)
- Administrative No More
ep3_admin_events.0004 - ep3_laamps.9981
- ep3_laamps.9983
- Means to an End?
ep3_laamps.5025 - News From The Island
ep3_laamps.5999 - The Corridors of Power
ep3_laamps.5045
Scripted effects (1)
Source: game/common/scripted_effects/07_dlc_ep3_scripted_effects.txt and every file of common/, events/ and history/ that calls it, Crusader Kings III 1.20.1.2.