ui_faction_select.script would be a good place.
Probably anywhere inside the if (faction and faction ~= "") then
coc_treasure_manager.script in on_game_load after the caches_count check is another place.
Alternatively, and probably a much cleaner way is to use your own script. Make an on_game_start function in the script and register for on_game_load. Then you can do something like this:
Code: Select all
local m_data = alife_storage_manager.get_state()
if (m_data.custom_spawn_only_once) then
m_data.custom_spawn_only_once = true
-- your code
alife_storage_manager.get_state() returns a table that persists through saves.
"I have a dream that one day this community will rise up and live out the true meaning of its creed: "We hold these truths to be self-evident; that all mods are created equal."