diff options
author | kartofen <mladenovnasko0@gmail.com> | 2022-08-11 21:45:03 +0300 |
---|---|---|
committer | kartofen <mladenovnasko0@gmail.com> | 2022-08-11 21:45:03 +0300 |
commit | 30d1c9b30b5642efcba66bdc7956f4d7e321fc97 (patch) | |
tree | ae3cf3aeb4b01f1cb70ae84cc84d453e08da35a5 /src/tilemap.h | |
parent | 57315da56fa3b036f8e3e2d32a5f90a11ae7c3de (diff) |
more used friendly
Diffstat (limited to 'src/tilemap.h')
-rw-r--r-- | src/tilemap.h | 23 |
1 files changed, 15 insertions, 8 deletions
diff --git a/src/tilemap.h b/src/tilemap.h index e945f06..74344dd 100644 --- a/src/tilemap.h +++ b/src/tilemap.h @@ -1,17 +1,24 @@ #ifndef TILEMAP_H #define TILEMAP_H -void set(int i, int n); -int is_set(int i, int n); +// set bit n in tile t in tilemap +void set(int t, int n); +// is bit n set in tile t in tilemap +int is_set(int t, int n); + +// self explanatory names +int has_collapsed(int t); +int get_collapsed_tile(int i); +void collapse(int t, int n); +size_t count_entropy(int t); +void init_tilemap(); -void mask(int i, int m, int r); void generate_tile_masks(small_t* tile_connections); -void init_tilemap(); +// applly a mask m, r (from tile_masks) +// to tile t in tilemap +void mask(int t, int m, int r); + -size_t count_entropy(int i); -void collapse(int i, int n); -int has_collapsed(int i); -int get_collapsed_tile(int i); #endif |