aboutsummaryrefslogtreecommitdiff
path: root/src/crepe/api/LoopManager.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/crepe/api/LoopManager.cpp')
-rw-r--r--src/crepe/api/LoopManager.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/crepe/api/LoopManager.cpp b/src/crepe/api/LoopManager.cpp
index 88243c4..cf8a0d0 100644
--- a/src/crepe/api/LoopManager.cpp
+++ b/src/crepe/api/LoopManager.cpp
@@ -1,3 +1,5 @@
+#include "../facade/SDLContext.h"
+#include "../system/AISystem.h"
#include "../system/AnimatorSystem.h"
#include "../system/CollisionSystem.h"
#include "../system/InputSystem.h"
@@ -20,6 +22,7 @@ LoopManager::LoopManager() {
this->load_system<RenderSystem>();
this->load_system<ScriptSystem>();
this->load_system<InputSystem>();
+ this->load_system<AISystem>();
}
void LoopManager::process_input() { this->get_system<InputSystem>().update(); }
@@ -35,6 +38,7 @@ void LoopManager::fixed_update() {
EventManager & ev = this->mediator.event_manager;
ev.dispatch_events();
this->get_system<ScriptSystem>().update();
+ this->get_system<AISystem>().update();
this->get_system<PhysicsSystem>().update();
this->get_system<CollisionSystem>().update();
}
@@ -74,4 +78,4 @@ void LoopManager::render() {
this->get_system<RenderSystem>().update();
}
-void LoopManager::update() {}
+void LoopManager::update() { this->get_system<AnimatorSystem>().update(); }