diff options
| author | 0scar <qgt268@alumni.ku.dk> | 2024-02-11 11:49:56 +0000 |
|---|---|---|
| committer | 0scar <qgt268@alumni.ku.dk> | 2024-02-11 12:00:55 +0000 |
| commit | b501d40dfc59c5f68c5e0df6091dda8762035e55 (patch) | |
| tree | 76a97e9127dfe47dcf65036e1881ddaa398ab41e /src/core/include/engine | |
| parent | b04b041f61fe6f0664d5d037b8a26e43b7b99a75 (diff) | |
Purge UI
Diffstat (limited to 'src/core/include/engine')
| -rw-r--r-- | src/core/include/engine/core/platform.h | 6 | ||||
| -rw-r--r-- | src/core/include/engine/engine.h | 8 |
2 files changed, 7 insertions, 7 deletions
diff --git a/src/core/include/engine/core/platform.h b/src/core/include/engine/core/platform.h index e0d2419..2e74fbe 100644 --- a/src/core/include/engine/core/platform.h +++ b/src/core/include/engine/core/platform.h @@ -5,6 +5,7 @@ #include <engine/core/memory.h> #include <engine/ctrl/input.h> #include <engine/rendering/window.h> +#include <engine/resources.h> #include <engine/utils/vector.h> #define NUM_GLOBAL_BINDINGS 1 @@ -15,8 +16,6 @@ * not quite thread safe. */ typedef struct Platform { - void* data; /* Contains textures and such */ - u64 data_len; Window window; bool quit; @@ -36,6 +35,9 @@ typedef struct Platform { i32 camera_x; i32 camera_y; + /* Global resources that live from engine_init to engine_free */ + Resources* resources; + /* Text input/editing is currently not used/implemented */ char* edit_text; usize edit_pos; diff --git a/src/core/include/engine/engine.h b/src/core/include/engine/engine.h index 11ee096..d5b0922 100644 --- a/src/core/include/engine/engine.h +++ b/src/core/include/engine/engine.h @@ -1,5 +1,5 @@ -#ifndef ENGINE_H -#define ENGINE_H +#ifndef ENGINE_ENGINE_H +#define ENGINE_ENGINE_H #include <stdbool.h> @@ -12,7 +12,6 @@ #include <engine/core/memory.h> #include <engine/core/state.h> #include <engine/ctrl/input.h> -#include <engine/resources.h> #include <engine/utils/stack.h> #include <engine/utils/vector.h> @@ -27,8 +26,7 @@ typedef struct { /* Essential functions */ Platform* engine_init(const char* windowtitle, i32 windowWidth, i32 windowHeight, const f32 render_scale, const u32 flags, - const usize initial_memory, const Asset_FontSpec* fonts[], - const Asset_TextureSpec* textures[]); + const usize initial_memory); i32 engine_run(Platform* p, StateType initial_state, void* state_arg); |
