diff options
author | hop311 <hop3114@gmail.com> | 2024-04-15 00:29:28 +0200 |
---|---|---|
committer | hop311 <hop3114@gmail.com> | 2024-04-15 00:38:46 +0200 |
commit | 5799836bee29024ce8a2d0fc45e06664c0110751 (patch) | |
tree | 54a0ad26ef3cec9a56644479611e8abaad62b1f7 /src/openvic-simulation/dataloader | |
parent | 109d31f147512c8d51f35f9773cd3c6bb1b8b994 (diff) |
Generate starting unit instancesunits
Diffstat (limited to 'src/openvic-simulation/dataloader')
-rw-r--r-- | src/openvic-simulation/dataloader/Dataloader.cpp | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/src/openvic-simulation/dataloader/Dataloader.cpp b/src/openvic-simulation/dataloader/Dataloader.cpp index d01f6ff..e13bc23 100644 --- a/src/openvic-simulation/dataloader/Dataloader.cpp +++ b/src/openvic-simulation/dataloader/Dataloader.cpp @@ -513,12 +513,14 @@ bool Dataloader::_load_history(GameManager& game_manager, bool unused_history_fi { /* Country History */ CountryHistoryManager& country_history_manager = game_manager.get_history_manager().get_country_manager(); + DeploymentManager& deployment_manager = game_manager.get_military_manager().get_deployment_manager(); static constexpr std::string_view country_history_directory = "history/countries"; const path_vector_t country_history_files = lookup_basic_indentifier_prefixed_files_in_dir(country_history_directory, ".txt"); country_history_manager.reserve_more_country_histories(country_history_files.size()); + deployment_manager.reserve_more_deployments(country_history_files.size()); ret &= apply_to_files( country_history_files, @@ -541,11 +543,6 @@ bool Dataloader::_load_history(GameManager& game_manager, bool unused_history_fi ); country_history_manager.lock_country_histories(); - } - - { - DeploymentManager& deployment_manager = game_manager.get_military_manager().get_deployment_manager(); - deployment_manager.lock_deployments(); if (deployment_manager.get_missing_oob_file_count() > 0) { |