diff options
-rw-r--r-- | sim/src/BaseBattle.cpp | 5 | ||||
-rw-r--r-- | sim/src/BaseBattle.h | 2 |
2 files changed, 3 insertions, 4 deletions
diff --git a/sim/src/BaseBattle.cpp b/sim/src/BaseBattle.cpp index 6182fec..fa91134 100644 --- a/sim/src/BaseBattle.cpp +++ b/sim/src/BaseBattle.cpp @@ -16,6 +16,7 @@ #include <kurator/universe/UniqueIdentifier.h> #include "Builder.h" +#include "RandomSpawner.h" namespace kurator @@ -25,9 +26,9 @@ namespace sim BaseBattle::BaseBattle(const campaign::Scenario& scenario) : - _registry {}, - spawner {scenario.last_team(), scenario.radius, 0.1} + _registry {} { + RandomSpawner spawner {scenario.last_team(), scenario.radius, 0.1}; Builder build {_registry, spawner}; for (const auto& ship : scenario.ships) { const auto entity = build(ship.loadout.type, ship.team); diff --git a/sim/src/BaseBattle.h b/sim/src/BaseBattle.h index 7532dd8..77e1d10 100644 --- a/sim/src/BaseBattle.h +++ b/sim/src/BaseBattle.h @@ -7,7 +7,6 @@ #include <kurator/campaign/Scenario.h> #include <kurator/sim/Battle.h> -#include "RandomSpawner.h" #include "TeamManager.h" @@ -27,7 +26,6 @@ public: private: entt::registry _registry; entt::dispatcher _dispatcher; - RandomSpawner spawner; TeamManager manager; void pick_random_targets(); }; |