summaryrefslogtreecommitdiff
path: root/src/tiled.h
diff options
context:
space:
mode:
authordavidovski <david@davidovski.xyz>2023-07-11 01:36:53 +0100
committerdavidovski <david@davidovski.xyz>2023-07-11 01:36:53 +0100
commit86da5bd3b0b5e0a8d9e68534297ca0446d2f735d (patch)
tree09c0a666674cfdd3703ea01beff6064d09349acd /src/tiled.h
parentda40b1083161b1a53e2764ffac3a3a1f8568e24c (diff)
refactor tiled
Diffstat (limited to 'src/tiled.h')
-rw-r--r--src/tiled.h12
1 files changed, 10 insertions, 2 deletions
diff --git a/src/tiled.h b/src/tiled.h
index 5791dc0..f496dc6 100644
--- a/src/tiled.h
+++ b/src/tiled.h
@@ -1,6 +1,8 @@
#include <raylib.h>
-typedef struct TiledUniforms {
+#include "tiledfile.h"
+
+typedef struct Tiled {
float zoom;
Vector2 offset;
@@ -10,6 +12,8 @@ typedef struct TiledUniforms {
Texture2D atlasTexture;
Texture2D tilemapTexture;
+ RenderTexture2D targetTexture;
+ Shader shader;
int zoomLoc;
int offsetLoc;
@@ -20,4 +24,8 @@ typedef struct TiledUniforms {
int atlasTextureLoc;
int tilemapTextureLoc;
-} TiledUniforms;
+} Tiled;
+
+void initTiled(Tiled *tiled, TiledMap tiledMap);
+void drawTiled(Tiled *tiled);
+void unloadTiled(Tiled *tiled);