summaryrefslogtreecommitdiffstats
path: root/src/resources/map.h
diff options
context:
space:
mode:
authorP. J. McDermott <pjm@nac.net>2013-02-16 21:35:48 (EST)
committer P. J. McDermott <pjm@nac.net>2013-02-16 21:35:48 (EST)
commit1e4407da677dd7a192c817de16583bb7199ceeb0 (patch)
treeb97d3e7e746ef91ffebb86cb654e6fc8499241e5 /src/resources/map.h
parent63349a6230304a7f1aa34a4c96e4873f86bf39c5 (diff)
downloadoverworld-rpg-1e4407da677dd7a192c817de16583bb7199ceeb0.zip
overworld-rpg-1e4407da677dd7a192c817de16583bb7199ceeb0.tar.gz
overworld-rpg-1e4407da677dd7a192c817de16583bb7199ceeb0.tar.bz2
TMX parser rewrite number one.
Diffstat (limited to 'src/resources/map.h')
-rw-r--r--src/resources/map.h27
1 files changed, 27 insertions, 0 deletions
diff --git a/src/resources/map.h b/src/resources/map.h
new file mode 100644
index 0000000..04fcf27
--- /dev/null
+++ b/src/resources/map.h
@@ -0,0 +1,27 @@
+#ifndef RESOURCE_MAP_H
+#define RESOURCE_MAP_H
+
+#include <SDL_stdinc.h>
+#include "resource.h"
+#include "tileset.h"
+#include "layer.h"
+
+struct map {
+ struct resource res;
+ int width;
+ int height;
+ int tilewidth;
+ int tileheight;
+ struct tileset *tilesets_head;
+ struct tileset *tilesets_tail;
+ struct layer *layers_head;
+ struct layer *layers_tail;
+ Uint8 *collision;
+};
+
+struct map *map_get(const char *path);
+void map_free(struct map *map);
+void map_add_layer(struct map *m, struct layer *l);
+void map_add_tileset(struct map *m, struct tileset *t);
+
+#endif