diff options
| author | jussi | 2022-02-18 18:27:10 +0200 |
|---|---|---|
| committer | jussi | 2022-02-18 18:27:10 +0200 |
| commit | 6e4fdd3b3ae4e4656e151f098c40cfe551a36e8c (patch) | |
| tree | 37e30d371ebd44dfc8bab0d33c26f0294bda5ae4 /include/state.h | |
| parent | 345cc1d5aa3b3c97e2cce453dc65a62c3e05427b (diff) | |
| download | reilua-enhanced-6e4fdd3b3ae4e4656e151f098c40cfe551a36e8c.tar.gz reilua-enhanced-6e4fdd3b3ae4e4656e151f098c40cfe551a36e8c.tar.bz2 reilua-enhanced-6e4fdd3b3ae4e4656e151f098c40cfe551a36e8c.zip | |
Added initial files.
Diffstat (limited to 'include/state.h')
| -rw-r--r-- | include/state.h | 71 |
1 files changed, 71 insertions, 0 deletions
diff --git a/include/state.h b/include/state.h new file mode 100644 index 0000000..3fc4e8e --- /dev/null +++ b/include/state.h @@ -0,0 +1,71 @@ +#pragma once + +#define ALLOC_PAGE_SIZE 256 + +typedef struct { + ModelAnimation *animations; + unsigned int animCount; +} ModelAnimations; + +typedef struct { + char *exePath; + bool hasWindow; + bool run; + lua_State *luaState; + Vector2 resolution; + int targetFPS; + int textureSource; + /* Resources. */ + /* Images. */ + Image **images; + size_t imageCount; + size_t imageAlloc; + /* Textures. */ + Texture **textures; + size_t textureCount; + size_t textureAlloc; + /* RenderTextures. */ + RenderTexture **renderTextures; + size_t renderTextureCount; + size_t renderTextureAlloc; + /* Fonts. */ + Font **fonts; + size_t fontCount; + size_t fontAlloc; + /* Sounds. */ + Sound **sounds; + size_t soundCount; + size_t soundAlloc; + /* Music. */ + Music music; + /* Camera3D's. */ + Camera3D **camera3Ds; + size_t camera3DCount; + size_t camera3DAlloc; + /* Meshes. */ + Mesh **meshes; + size_t meshCount; + size_t meshAlloc; + /* Materials. */ + Material **materials; + size_t materialCount; + size_t materialAlloc; + /* Models. */ + Model **models; + size_t modelCount; + size_t modelAlloc; + /* ModelAnimations. */ + ModelAnimations **animations; + size_t animationCount; + size_t animationAlloc; + /* Shaders. */ + Shader **shaders; + size_t shaderCount; + size_t shaderAlloc; +} State; + +extern State *state; + +bool stateInit( const char *exePath ); +// bool stateRun(); +void stateFree(); |
