#include <map_dungeon.h>
Public Member Functions | |
| void | load (int mapEra, int mapType) |
| void | synchronize (Common::Serializer &s) |
| byte & | cell (int level, int x, int y) |
| DungeonTerrain | terrainAt (int level, int x, int y) const |
| bool | hasMonsterAt (int level, int x, int y) const |
Public Attributes | |
| byte | _cells [DUNGEON_LEVELS][DUNGEON_HEIGHT][DUNGEON_WIDTH] = {} |
A dungeon or tower's 16 levels, each a 16x16 grid of cells (dungeons number levels top to bottom, towers bottom to top). The high nibble of each cell byte is its terrain (see DungeonTerrain); the low 3 bits flag monster presence there, independent of the per-map MapMonsters slots, and get cleared on a kill while preserving the terrain nibble.
|
inline |
Returns the cell at the given position on a level. Addresses it the way the original does - a byte index within the level's 256-byte page - so positions just outside the 16x16 grid alias into neighbouring cells rather than being out of range