aboutsummaryrefslogtreecommitdiff
path: root/src/crepe/system/AISystem.cpp
diff options
context:
space:
mode:
authorJAROWMR <jarorutjes07@gmail.com>2024-12-11 20:21:55 +0100
committerJAROWMR <jarorutjes07@gmail.com>2024-12-11 20:21:55 +0100
commit436b0db58c7533b286ecd3ec3d3c71311e71cf9c (patch)
tree1a344b7b0a369013f8ba275be948dc0c3c721345 /src/crepe/system/AISystem.cpp
parentc90423d5c9d38ae426c168e52994a4fd63e6f266 (diff)
added fixed update
Diffstat (limited to 'src/crepe/system/AISystem.cpp')
-rw-r--r--src/crepe/system/AISystem.cpp6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/crepe/system/AISystem.cpp b/src/crepe/system/AISystem.cpp
index 1d8ffb9..1bbac69 100644
--- a/src/crepe/system/AISystem.cpp
+++ b/src/crepe/system/AISystem.cpp
@@ -13,12 +13,10 @@ using namespace std::chrono;
void AISystem::update() {
const Mediator & mediator = this->mediator;
ComponentManager & mgr = mediator.component_manager;
- LoopTimerManager & timer = mediator.loop_timer;
- RefVector<AI> ai_components = mgr.get_components_by_type<AI>();
LoopTimerManager & loop_timer = mediator.loop_timer;
+ RefVector<AI> ai_components = mgr.get_components_by_type<AI>();
- //TODO: Use fixed loop dt (this is not available at master at the moment)
- duration_t dt = loop_timer.get_delta_time();
+ duration_t dt = loop_timer.get_scaled_fixed_delta_time();
// Loop through all AI components
for (AI & ai : ai_components) {