summaryrefslogtreecommitdiff
path: root/src/tiledmap.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/tiledmap.h')
-rw-r--r--src/tiledmap.h7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/tiledmap.h b/src/tiledmap.h
index 2c4cf94..972a74d 100644
--- a/src/tiledmap.h
+++ b/src/tiledmap.h
@@ -3,7 +3,8 @@
#define CHUNK_CACHE_SIZE 32
-typedef char * Chunk;
+typedef unsigned char Tile;
+typedef Tile * Chunk;
typedef struct CachedChunk {
long filePos;
@@ -24,8 +25,8 @@ typedef struct ChunkedTiledMap {
void textureFromPixels(Texture2D *texOut, Color *pixels, int width, int height);
TiledMap openTiledMap(char * filename);
CachedChunk * loadChunk(TiledMap *tiledMap, int x, int y);
-char getChunkedTile(TiledMap *tiledMap, int x, int y);
-char setChunkedTile(TiledMap * tiledMap, int x, int y, char value);
+Tile getChunkedTile(TiledMap *tiledMap, int x, int y);
+Tile setChunkedTile(TiledMap * tiledMap, int x, int y, Tile value);
CachedChunk * createChunk(TiledMap * tiledMap, int x, int y, Chunk chunk);
void writeTiledMapHeader(TiledMap tiledMap);
TiledMap openNewTiledMap(char * filename, Image atlas, int tileSize, int chunkWidth, int chunkHeight, int width, int height);