aboutsummaryrefslogtreecommitdiff
path: root/src/crepe/api/game.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/crepe/api/game.cpp')
-rw-r--r--src/crepe/api/game.cpp30
1 files changed, 30 insertions, 0 deletions
diff --git a/src/crepe/api/game.cpp b/src/crepe/api/game.cpp
new file mode 100644
index 0000000..01920a9
--- /dev/null
+++ b/src/crepe/api/game.cpp
@@ -0,0 +1,30 @@
+
+
+
+#include "game.h"
+#include "core/renderSystem.h"
+#include "facade/SdlContext.h"
+
+
+Engine::Engine(int windowHeight, int window_with){
+ crepe::SdlContext& ctx = crepe::SdlContext::get_instance();
+}
+
+
+
+void Engine::loop() {
+
+ bool running = true;
+ crepe::SdlContext& ctx = crepe::SdlContext::get_instance();
+ RenderSystem rendering;
+
+ while (running) {
+ ctx.handleEvents(running);
+
+ ctx.clearScreen();
+
+ rendering.render();
+
+ ctx.presentScreen();
+ }
+}