From 12b4f785f2bfccce59eb80378a76bf36bef6ff55 Mon Sep 17 00:00:00 2001 From: P. J. McDermott Date: Sun, 17 Feb 2013 16:39:25 -0500 Subject: Add map exits to a collisions array. --- (limited to 'src/resources/map.h') diff --git a/src/resources/map.h b/src/resources/map.h index bf225de..e088161 100644 --- a/src/resources/map.h +++ b/src/resources/map.h @@ -35,6 +35,19 @@ struct layer { char *compression; char *raw_data; }; +struct map_collision { + enum { + COLLISION_NONE = 0, + COLLISION_CHAR, + COLLISION_OBJ, + COLLISION_EXIT + } type; + union { +/* struct character *c;*/ + Uint8 o; + struct map_exit *e; + } data; +}; struct map_exit { struct map *map; int x; @@ -69,7 +82,7 @@ struct map { struct map_tileset *tilesets_head; struct map_tileset *tilesets_tail; struct layer layers[LAYERS_MAX]; - Uint8 *collision; + struct map_collision *collisions; struct map_exit *map_exits_head; struct map_exit *map_exits_tail; int cur_ts_firstgid; -- cgit v0.9.1