]>
git.bts.cx Git - benzene.git/blob - src/bz/game/tilemap.h
1 #ifndef BZ_GAME_TILEMAP_H
2 #define BZ_GAME_TILEMAP_H
4 #include <bz/memory/arena.h>
5 #include <bz/types/common.h>
6 #include <bz/types/identifier.h>
12 typedef struct BZTilemap BZTilemap
;
13 typedef BZTilemap
* BZTilemapID
;
15 extern BZTilemapID
bzGameLoadTilemap(BZMemoryArenaID arena
, const char *identifierFmt
, ...);
17 extern uint8_t bzGameGetTilemapTile(BZTilemapID tilemap
, uint8_t mx
, uint8_t my
);
18 extern uint8_t bzGameSetTilemapTile(BZTilemapID tilemap
, uint8_t mx
, uint8_t my
, uint8_t idx
);
20 extern uint8_t bzGameGetTilemapSprite(BZTilemapID tilemap
, uint8_t mx
, uint8_t my
);
21 extern bool bzGameGetTilemapHasFlag(BZTilemapID tilemap
, uint8_t mx
, uint8_t my
, BZIdentifierHash tag
);
23 extern uint32_t bzGameCalculateTilemapFlagsMask(BZTilemapID tilemap
, size_t tagCount
, BZIdentifierHash tags
[]);