diff options
Diffstat (limited to 'include/map.h')
| -rw-r--r-- | include/map.h | 37 |
1 files changed, 36 insertions, 1 deletions
diff --git a/include/map.h b/include/map.h index 8f153f8..6109c5a 100644 --- a/include/map.h +++ b/include/map.h @@ -23,7 +23,7 @@ typedef struct t_tile { } tile; #define MAP_SIZE_X 40 -#define MAP_SIZE_Y 20 +#define MAP_SIZE_Y 40 tile map_loaded[MAP_SIZE_Y][MAP_SIZE_X]; @@ -34,6 +34,21 @@ typedef struct t_map_info { float px_incline; } map_info; +typedef struct t_map_data { + int width; + int height; + int heightmap[MAP_SIZE_Y][MAP_SIZE_X]; +} map_data; + +typedef struct t_extracted_map_data { + int width; + int height; + tile heightmap[MAP_SIZE_Y][MAP_SIZE_X]; +} extracted_map_data; + +map_data map_to_load = {0}; +extracted_map_data loaded_map = {0}; + // data data that is stored on disk int map[MAP_SIZE_Y][MAP_SIZE_X] = { {0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0}, @@ -55,6 +70,26 @@ int map[MAP_SIZE_Y][MAP_SIZE_X] = { {0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0}, {0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0}, {0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0}, + {0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0}, + {0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0}, + {0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0}, + {0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0}, + {0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0}, + {0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0}, + {0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0}, + {0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0}, + {0,0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