diff options
author | wvpm <24685035+wvpm@users.noreply.github.com> | 2024-11-02 15:20:30 +0100 |
---|---|---|
committer | wvpm <24685035+wvpm@users.noreply.github.com> | 2024-11-02 21:09:18 +0100 |
commit | 19026ff6aee8748df4777ec044065d13460e806a (patch) | |
tree | b72561d0f46f16650cdbdede18c31587e1dddb80 /src/openvic-simulation/InstanceManager.cpp | |
parent | 8defcd5daa1acd2c61aa1cd0a26478d472fed9b0 (diff) |
Cache pops by type per state and provincestate_cache_owners
Diffstat (limited to 'src/openvic-simulation/InstanceManager.cpp')
-rw-r--r-- | src/openvic-simulation/InstanceManager.cpp | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/openvic-simulation/InstanceManager.cpp b/src/openvic-simulation/InstanceManager.cpp index 670cbfc..4f388b0 100644 --- a/src/openvic-simulation/InstanceManager.cpp +++ b/src/openvic-simulation/InstanceManager.cpp @@ -61,7 +61,7 @@ void InstanceManager::tick() { Logger::info("Tick: ", today); // Tick... - map_instance.tick(today); + map_instance.map_tick(today, definition_manager.get_modifier_manager().get_modifier_effect_cache()); set_gamestate_needs_update(); } @@ -140,7 +140,11 @@ bool InstanceManager::load_bookmark(Bookmark const* new_bookmark) { if (ret) { update_modifier_sums(); - map_instance.initialise_for_new_game(definition_manager.get_modifier_manager().get_modifier_effect_cache()); + map_instance.initialise_for_new_game( + today, + definition_manager.get_define_manager(), + definition_manager.get_modifier_manager().get_modifier_effect_cache() + ); } return ret; |