diff options
author | Simponic <loganhunt@simponic.xyz> | 2021-12-04 13:34:49 -0700 |
---|---|---|
committer | Simponic <loganhunt@simponic.xyz> | 2021-12-04 13:34:49 -0700 |
commit | aa1d7c6e284cc0818325614391619f3ff13d3e94 (patch) | |
tree | 8a59a6b3e5aacb7f682756d3c7751f1d72e1d940 /serial/include/game.h | |
download | gol-aa1d7c6e284cc0818325614391619f3ff13d3e94.tar.gz gol-aa1d7c6e284cc0818325614391619f3ff13d3e94.zip |
Initial commit
Diffstat (limited to 'serial/include/game.h')
-rw-r--r-- | serial/include/game.h | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/serial/include/game.h b/serial/include/game.h new file mode 100644 index 0000000..1896daa --- /dev/null +++ b/serial/include/game.h @@ -0,0 +1,20 @@ +#include <stdlib.h> +#include <stdio.h> +#include <string.h> + +#ifndef GAME_H +#define GAME_H + +struct GAME { + unsigned char** grid; + int padding; + int width; + int height; +}; + +int neighbors(struct GAME* game, int x, int y); +void next(struct GAME* game); +void update(struct GAME* game, int x1, int x2, int y1, int y2); +void randomize(struct GAME* game); + +#endif // GAME_H |