diff options
author | Hampus <hampus@hampusmat.com> | 2022-01-04 18:55:51 +0100 |
---|---|---|
committer | Hampus <hampus@hampusmat.com> | 2022-01-05 20:09:27 +0100 |
commit | e3690eb85a9456cc1f3ccda751ae7d9fdf2d3b03 (patch) | |
tree | 2fdd32726d753495bf562102a0531101eaa1ddfd /src/maze.h | |
parent | 1bed3ac57906b26ef05b25c2bc5c1dca424dba4a (diff) |
refactor: improve even more
Diffstat (limited to 'src/maze.h')
-rw-r--r-- | src/maze.h | 28 |
1 files changed, 4 insertions, 24 deletions
@@ -2,34 +2,14 @@ #define MAZE_H #include "position_stack.h" - -typedef struct Dimensions -{ - int width; - int height; -} Dimensions; - -typedef struct Maze -{ - char ***grid; - Dimensions dimens; - Dimensions full_dimens; -} Maze; - -Maze maze_create(Dimensions dimens, char *wall); - -void maze_destroy(Maze *maze); +#include "grid.h" /** - * Excavates a maze. - * - * This is what creates the actual maze. + * Creates a maze from a grid * - * @param maze The maze to excavate + * @param grid A grid * @param start_pos Start position */ -void maze_excavate(Maze *maze, Position start_pos); - -void maze_print(Maze maze); +void grid_to_maze(Grid grid, Position start_pos); #endif |