Class DoorList
A list of rooms and entry/exit points of those rooms, generated/added by map generation components, that tracks what generation step created/recorded which opening.
Inherited Members
Namespace: GoRogue.MapGeneration.ContextComponents
Assembly: GoRogue.dll
Syntax
public class DoorList
Constructors
View SourceDoorList()
Creates a new door manager context component.
Declaration
public DoorList()
Properties
View SourceDoorsPerRoom
A dictionary associating rooms to their lists of doors.
Declaration
public IReadOnlyDictionary<Rectangle, RoomDoors> DoorsPerRoom { get; }
Property Value
Type | Description |
---|---|
IReadOnlyDictionary<Rectangle, RoomDoors> |
Methods
View SourceAddDoor(string, Rectangle, Point)
Records a new opening in the given room at the given position.
Declaration
public void AddDoor(string generationStepName, Rectangle room, Point doorPosition)
Parameters
Type | Name | Description |
---|---|---|
string | generationStepName | The name of the generation step recording the door position. |
Rectangle | room | The room the door is a part of. |
Point | doorPosition | The location of the door to add. |
AddDoors(string, Rectangle, params Point[])
Records new openings in the given room at the given positions.
Declaration
public void AddDoors(string generationStepName, Rectangle room, params Point[] doorPositions)
Parameters
Type | Name | Description |
---|---|---|
string | generationStepName | The name of the generation step recording the door positions. |
Rectangle | room | The room the doors are part of. |
Point[] | doorPositions | The locations of the door to add. |
AddDoors(string, Rectangle, IEnumerable<Point>)
Records new openings in the given room at the given positions.
Declaration
public void AddDoors(string generationStepName, Rectangle room, IEnumerable<Point> doorPositions)
Parameters
Type | Name | Description |
---|---|---|
string | generationStepName | The name of the generation step recording the door positions. |
Rectangle | room | The room the doors are part of. |
IEnumerable<Point> | doorPositions | The locations of the door to add. |