From a00c0aab1eb5a7a55bef8ca08115bdd722ab5699 Mon Sep 17 00:00:00 2001 From: Matthew Kosarek Date: Sun, 16 May 2021 19:50:15 -0400 Subject: Moved the frontend directory up so that it no longer exists --- frontend/shared_cpp/MainLoop.cpp | 31 ------------------------------- 1 file changed, 31 deletions(-) delete mode 100644 frontend/shared_cpp/MainLoop.cpp (limited to 'frontend/shared_cpp/MainLoop.cpp') diff --git a/frontend/shared_cpp/MainLoop.cpp b/frontend/shared_cpp/MainLoop.cpp deleted file mode 100644 index 09aa643..0000000 --- a/frontend/shared_cpp/MainLoop.cpp +++ /dev/null @@ -1,31 +0,0 @@ -#include "MainLoop.h" -#include -#include - -EM_BOOL loop(double time, void* loop) { - MainLoop* mainLoop = (MainLoop*) loop; - if (!mainLoop->isRunning) { - return false; - } - - if (mainLoop->lastTime == 0) { - mainLoop->lastTime = time; - return true; - } - - long deltaTime = time - mainLoop->lastTime; - mainLoop->lastTime = time; - mainLoop->elapsedTime += deltaTime; - mainLoop->numFrames++; - float deltaTimeSeconds = static_cast(deltaTime) / 1000.f; - - if (mainLoop->elapsedTime >= 1000.0) { - printf("FPS: %d\n", mainLoop->numFrames); - - mainLoop->elapsedTime = 0.0; - mainLoop->numFrames = 0; - } - - mainLoop->updateFunc(deltaTimeSeconds, NULL); - return true; -} \ No newline at end of file -- cgit v1.2.1