The Cursed Labyrinth
Loading...
Searching...
No Matches
DungeonMapIndex Class Reference

Shared container with per room indices and quick cell lookups. More...

Classes

class  RoomIndex

Public Member Functions

RoomIndex GetOrCreateRoomIndex (Room r)
void SetCellRoom (Vector2Int cell, int roomId)
void AddEntrance (Vector2Int cell, int roomId)
void AddInterior (Vector2Int cell, int roomId)
void AddCorridor (Vector2Int cell)

Properties

Dictionary< int, RoomIndexRooms = new Dictionary<int, RoomIndex>() [get]
 Map from room id to index info.
Dictionary< Vector2Int, int > CellToRoom = new Dictionary<Vector2Int, int>() [get]
 Quick lookup: which room id (or -1) a given cell belongs to.
HashSet< Vector2Int > CorridorCells = new HashSet<Vector2Int>() [get]
 Corridor cells across the map (optional but useful for placement)
HashSet< Vector2Int > EntranceCells = new HashSet<Vector2Int>() [get]
 Entrance cells (doors) across the map.

Detailed Description

Shared container with per room indices and quick cell lookups.

Member Function Documentation

◆ AddCorridor()

void DungeonMapIndex.AddCorridor ( Vector2Int cell)

◆ AddEntrance()

void DungeonMapIndex.AddEntrance ( Vector2Int cell,
int roomId )

◆ AddInterior()

void DungeonMapIndex.AddInterior ( Vector2Int cell,
int roomId )

◆ GetOrCreateRoomIndex()

RoomIndex DungeonMapIndex.GetOrCreateRoomIndex ( Room r)

◆ SetCellRoom()

void DungeonMapIndex.SetCellRoom ( Vector2Int cell,
int roomId )

Property Documentation

◆ CellToRoom

Dictionary<Vector2Int, int> DungeonMapIndex.CellToRoom = new Dictionary<Vector2Int, int>()
get

Quick lookup: which room id (or -1) a given cell belongs to.

◆ CorridorCells

HashSet<Vector2Int> DungeonMapIndex.CorridorCells = new HashSet<Vector2Int>()
get

Corridor cells across the map (optional but useful for placement)

◆ EntranceCells

HashSet<Vector2Int> DungeonMapIndex.EntranceCells = new HashSet<Vector2Int>()
get

Entrance cells (doors) across the map.

◆ Rooms

Dictionary<int, RoomIndex> DungeonMapIndex.Rooms = new Dictionary<int, RoomIndex>()
get

Map from room id to index info.


The documentation for this class was generated from the following file: