diff options
author | Hop311 <Hop3114@gmail.com> | 2024-07-14 17:37:10 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-07-14 17:37:10 +0200 |
commit | e8a3b33f13ebdf3a388b4996308b4db9763dc375 (patch) | |
tree | db365e5d71df41b7b35abdcc3d4c0d76f1653619 /src/openvic-simulation/military/Deployment.cpp | |
parent | b9b35ad9536cfdcd61f5208eeaad7ead4bd0418d (diff) | |
parent | e4701ebc08f57575a02bdc1777d9851a987c1cba (diff) |
Merge pull request #173 from OpenVicProject/unit-colonies
Unit and leader rework (branch based templates and colony containers)
Diffstat (limited to 'src/openvic-simulation/military/Deployment.cpp')
-rw-r--r-- | src/openvic-simulation/military/Deployment.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/openvic-simulation/military/Deployment.cpp b/src/openvic-simulation/military/Deployment.cpp index 66f656d..9c89690 100644 --- a/src/openvic-simulation/military/Deployment.cpp +++ b/src/openvic-simulation/military/Deployment.cpp @@ -22,13 +22,13 @@ NavyDeployment::NavyDeployment( Deployment::Deployment( std::string_view new_path, std::vector<ArmyDeployment>&& new_armies, std::vector<NavyDeployment>&& new_navies, - std::vector<Leader>&& new_leaders + std::vector<LeaderBase>&& new_leaders ) : HasIdentifier { new_path }, armies { std::move(new_armies) }, navies { std::move(new_navies) }, leaders { std::move(new_leaders) } {} bool DeploymentManager::add_deployment( std::string_view path, std::vector<ArmyDeployment>&& armies, std::vector<NavyDeployment>&& navies, - std::vector<Leader>&& leaders + std::vector<LeaderBase>&& leaders ) { if (path.empty()) { Logger::error("Attemped to load order of battle with no path! Something is very wrong!"); @@ -68,7 +68,7 @@ bool DeploymentManager::load_oob_file( std::vector<ArmyDeployment> armies; std::vector<NavyDeployment> navies; - std::vector<Leader> leaders; + std::vector<LeaderBase> leaders; bool ret = expect_dictionary_keys_and_default( key_value_success_callback, // TODO: load SOI information @@ -109,8 +109,8 @@ bool DeploymentManager::load_oob_file( ret = false; } - leaders.emplace_back( - leader_name, leader_branch, leader_date, leader_personality, leader_background, leader_prestige, picture + leaders.push_back( + { leader_name, leader_branch, leader_date, leader_personality, leader_background, leader_prestige, picture } ); return ret; |