#define MAP_WIDTH 150 #define MAP_HEIGHT 72 #define MAP_SIZE MAP_WIDTH*MAP_HEIGHT #define ROOM_WIDTH 15 #define ROOM_HEIGHT 12 #define MAP_RWIDTH (MAP_WIDTH/ROOM_WIDTH) #define MAP_RHEIGHT (MAP_HEIGHT/ROOM_HEIGHT) #define getMapPtr(x, y) (map+(y)*MAP_WIDTH+(x)) extern uint8_t* map; void initMap(); void initEndRoom(int rx, int ry);