X-Git-Url: https://git.martlubbers.net/?a=blobdiff_plain;ds=inline;f=modelchecker%2Fsokoban.h;h=414daa0c3d43cf1c739f2725e45c7c556e6f214f;hb=476b70d5c7cb978fec97c99fe462402eb38405de;hp=e69de29bb2d1d6434b8b29ae775ad8c2e48c5391;hpb=6b53be4450e3ed383740284bb2ebcacfbd861707;p=mc1516pa.git diff --git a/modelchecker/sokoban.h b/modelchecker/sokoban.h index e69de29..414daa0 100644 --- a/modelchecker/sokoban.h +++ b/modelchecker/sokoban.h @@ -0,0 +1,26 @@ +#ifndef SOKOBAN_H +#define SOKOBAN_H +#include "uthash.h" + +typedef enum {FREE, WALL, BOX, TARGET, AGENT, TARGAGENT, TARGBOX} sokoban_tile; + +typedef struct { + int x; + int y; +} record_key; + +typedef struct { + record_key coord; + sokoban_tile tile; + UT_hash_handle hh; +} sokoban_screen; + +sokoban_screen *parse_screen(FILE *stream); + +sokoban_screen *get_coord(int x, int y, sokoban_screen *screen); + +void sokoban_print(sokoban_screen *screen); + +void sokoban_clear(sokoban_screen *screen); + +#endif