mirror of
https://github.com/MihailRis/voxelcore.git
synced 2026-10-05 02:51:49 +00:00
add test.reconfig_packs & fix world.get_total_time() & enable level controller
This commit is contained in:
parent
9e18dccbbb
commit
3c2eb30a29
5 changed files with 14 additions and 2 deletions
|
|
@ -5,6 +5,7 @@
|
|||
#include "interfaces/Process.hpp"
|
||||
#include "debug/Logger.hpp"
|
||||
#include "world/Level.hpp"
|
||||
#include "world/World.hpp"
|
||||
#include "engine.hpp"
|
||||
|
||||
static debug::Logger logger("mainloop");
|
||||
|
|
@ -33,6 +34,11 @@ void TestMainloop::run() {
|
|||
while (process->isActive()) {
|
||||
time.step(1.0f / static_cast<float>(TPS));
|
||||
process->update();
|
||||
if (controller) {
|
||||
float delta = time.getDelta();
|
||||
controller->getLevel()->getWorld()->updateTimers(delta);
|
||||
controller->update(glm::min(delta, 0.2f), false, false);
|
||||
}
|
||||
}
|
||||
logger.info() << "test finished";
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue