diff options
author | HampusM <hampus@hampusmat.com> | 2022-01-09 21:47:23 +0100 |
---|---|---|
committer | HampusM <hampus@hampusmat.com> | 2022-01-09 21:47:23 +0100 |
commit | 8ceb79db1d0687bba005cef4a77bb889bf7ec3c3 (patch) | |
tree | b7c13359f652506d60c8556ea386ae8d50bfc5bc /src/grid.h | |
parent | 097aa95c1f0cb159e7d9d0a3edf9284c421ee298 (diff) |
refactor: rewrite to c++
Diffstat (limited to 'src/grid.h')
-rw-r--r-- | src/grid.h | 58 |
1 files changed, 0 insertions, 58 deletions
diff --git a/src/grid.h b/src/grid.h deleted file mode 100644 index 262035e..0000000 --- a/src/grid.h +++ /dev/null @@ -1,58 +0,0 @@ -#ifndef GRID_H -#define GRID_H - -#include "position.h" - -typedef struct Dimensions -{ - unsigned int width; - unsigned int height; -} Dimensions; - -typedef struct Grid -{ - char ***grid; - Dimensions dimens; -} Grid; - -/** - * Returns a grid. - * - * @param width The grid width - * @param height The grid height - * @param fill A string to fill the new grid with - */ -Grid grid_create(unsigned int width, unsigned int height, char *fill); - -/* - * Returns a value from a position in a grid. - * - * @param grid A grid - * @param pos A grid position - */ -char *grid_get(Grid grid, Position pos); - -/* - * Sets the value of a position in a grid. - * - * @param grid A grid - * @param pos A grid position - * @param value A new value - */ -void grid_set(Grid grid, Position pos, char *value); - -/** - * Prints a grid. - * - * @param grid A grid - */ -void grid_print(Grid grid); - -/** - * Destroys a grid. - * - * @param grid A grid - */ -void grid_destroy(Grid grid); - -#endif |