From b291d662f79af8de95ab40de29a09f87470d0095 Mon Sep 17 00:00:00 2001 From: max-001 Date: Fri, 20 Dec 2024 12:24:59 +0100 Subject: pull 3bda25f from demo --- src/crepe/manager/SystemManager.cpp | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) (limited to 'src/crepe/manager/SystemManager.cpp') diff --git a/src/crepe/manager/SystemManager.cpp b/src/crepe/manager/SystemManager.cpp index 5ada30f..f029aa5 100644 --- a/src/crepe/manager/SystemManager.cpp +++ b/src/crepe/manager/SystemManager.cpp @@ -19,12 +19,12 @@ SystemManager::SystemManager(Mediator & mediator) : Manager(mediator) { this->load_system(); this->load_system(); this->load_system(); + this->load_system(); this->load_system(); this->load_system(); this->load_system(); this->load_system(); this->load_system(); - this->load_system(); this->load_system(); this->load_system(); @@ -32,16 +32,16 @@ SystemManager::SystemManager(Mediator & mediator) : Manager(mediator) { } void SystemManager::fixed_update() { - for (auto & [type, system] : this->systems) { - if (!system->active) continue; - system->fixed_update(); + for (System & system : this->system_order) { + if (!system.active) continue; + system.fixed_update(); } } void SystemManager::frame_update() { - for (auto & [type, system] : this->systems) { - if (!system->active) continue; - system->frame_update(); + for (System & system : this->system_order) { + if (!system.active) continue; + system.frame_update(); } } @@ -64,3 +64,4 @@ void SystemManager::disable_all() { system->active = false; } } + -- cgit v1.2.3