|
Zappy GUI
C++ graphic client: renderer, camera, network
|
Collaboration diagram for TileSlotMap::TileOccupancy:Public Member Functions | |
| int | acquire () |
| void | release (int slotIndex) |
Public Attributes | |
| std::array< bool, 8 > | occupied = {} |
Definition at line 50 of file TileSlotMap.hpp.
| int TileSlotMap::TileOccupancy::acquire | ( | ) |
First free slot, set it occupied and return its index. If all 8 are taken, picks rand()%8 (overlap fallback, bit already set).
Definition at line 18 of file TileSlotMap.cpp.
References occupied.
| void TileSlotMap::TileOccupancy::release | ( | int | slotIndex | ) |
Clears occupied[slotIndex].
Definition at line 32 of file TileSlotMap.cpp.
| std::array<bool, 8> TileSlotMap::TileOccupancy::occupied = {} |
Definition at line 51 of file TileSlotMap.hpp.
Referenced by acquire().