blob: 141f74c9485dba3c2eec41dff04fd35b9273167c (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
|
#ifndef MAP_H_
#define MAP_H_
#include "framebuffer.h"
/* Used to represent an empty tile */
#define P_EMPTY (Pixel){C_BLACK, C_BLACK, '\0'}
/* A structure representing a map. */
typedef struct Map_s {
size_t width, height;
Pixel **tiles; /* used as tiles[row][col] or tiles[y][x] */
} Map;
Map map_new(size_t width, size_t height);
void map_free(Map *map);
Map map_default(void);
#endif /* MAP_H_ */
|