|
static const int | MAX_ROOMS =15 |
|
void ChunkLayer::add_item |
( |
Item * |
item | ) |
|
Adds an item to the item list for this chunk.
- Parameters
-
item | - a pointer to the item to add. |
void ChunkLayer::clear |
( |
| ) |
|
Resets the chunk layer to its default settings.
std::vector< EquipType > & ChunkLayer::get_equipment |
( |
| ) |
|
- Returns
- a vector of the equipment on this chunk.
- Todo:
- return a reference so we don't have to copy
TileMatrix & ChunkLayer::get_ground |
( |
| ) |
|
- Returns
- a reference to the matrix of tiles on this layer.
std::vector< Item * > & ChunkLayer::get_items |
( |
| ) |
|
- Returns
- a pointer to the list of item pointers on this chunk.
- Todo:
- why a pointer and not a reference? There could be a legit reason. -Seth
std::vector< Spawner > & ChunkLayer::get_spawners |
( |
| ) |
|
- Returns
- the spawners on this chunk.
Tile * ChunkLayer::get_tile_pointer |
( |
int |
row, |
|
|
int |
col |
|
) |
| |
Returns the tile at the given (row, col) location.
- Parameters
-
- Returns
- a pointer to the tile at that location
std::vector< WeaponType > & ChunkLayer::get_weapons |
( |
| ) |
|
- Returns
- a vector of the weapons on this chunk.
- Todo:
- return a reference so we don't have to copy
void ChunkLayer::layer_dump |
( |
| ) |
|
Prints an ASCII representation of the layer to stdout.
void ChunkLayer::make_spawner |
( |
int |
depth | ) |
|
- Parameters
-
depth | the depth at which to build a spawner |
Builds a monster spawner in a random room at the given depth.
- Todo:
- should go in dungeon gen
void ChunkLayer::make_stairs |
( |
bool |
has_layer_below | ) |
|
- Parameters
-
has_layer_below | a bool denoting whether or not there is a layer below this dungeon. |
Create an "up stair" in a random room and a "down stair" in a random room (if there is a chunk below).
- Todo:
- This should be in dungeon generation.
- Parameters
-
d | a reference to another dungeon |
- Returns
- a reference to this dungeon
void ChunkLayer::set_tile |
( |
int |
row, |
|
|
int |
col, |
|
|
Tile |
tile_type |
|
) |
| |
Sets the tile at the given location.
- Parameters
-
Copies over all values from the given layer to this layer.
- Parameters
-
l | - The layer from which to swap ownership. |
- Todo:
- this is weird as balls
void ChunkLayer::tile_assertions |
( |
int |
row, |
|
|
int |
col |
|
) |
| const |
|
private |
- Parameters
-
row | |
col | Run the given point in the dungeon through a series of assertions to ensure that it is valid. |
- Todo:
- these should be gone in a few commits.
std::vector<IntPoint> ChunkLayer::down_stairs |
|
private |
A vector of IntPoints representing the location of down stairs on this chunk.
A vector storing all equipment on the chunk.
TileMatrix ChunkLayer::ground |
|
private |
The central data model for the class: A two-dimensional matrix storing the layer's tiles.
bool ChunkLayer::has_layer_below |
True if there is a layer below this one.
The height of this layer.
std::vector<Item*> ChunkLayer::items |
|
private |
A vector storing pointers to each item on the chunk.
int ChunkLayer::num_rooms |
The number of rooms in this layer.
- Todo:
- figure out what to do with this.
std::vector<Room> ChunkLayer::rooms |
A vector containing data about the rooms in this dungeon.
std::vector<Spawner> ChunkLayer::spawners |
Any monster spawners that are stored on this layer.
std::vector<IntPoint> ChunkLayer::up_stairs |
|
private |
The coordinates of the stair leading to the layer above this one, if such a layer exists.
All weapons on the chunk.
The documentation for this class was generated from the following files: