mirror of
https://github.com/Ellpeck/TinyLifeExampleMod.git
synced 2024-11-04 21:29:08 +01:00
3.1 KiB
3.1 KiB
Room
Namespace: TinyLife > World
Assembly: Tiny Life.dll
Summary
A room is an area on a TinyLife.World.Room.Map
that is surrounded by TinyLife.World.Wall
objects
Fields
Type | Name | Summary |
---|---|---|
Point | Center | The position that is considered to be the center of this room. This is the average of all of its covered TinyLife.World.Room.Tiles , and the TinyLife.World.MapSection that this room is on is determined by this value. |
HashSet<MapSection> | CoveredSections | A set of TinyLife.World.MapSection instances that are covered by this room |
Map | Map | The map that this room is on |
HashSet<Point> | Tiles | A set of Microsoft.Xna.Framework.Point positions on the TinyLife.World.Room.Map that are contained in this room |
Methods
Return | Name | Summary |
---|---|---|
IEnumerable<Room> | GetConnectedRooms ( ) | Returns a set of TinyLife.World.Room objects which are connected to this room. A connected room is a room that is directly adjacent, and that a TinyLife.Objects.Person can walk into through an TinyLife.World.Opening . |
Int32 | GetDecorativeRating ( ) | Returns the combined decorative rating of all of the TinyLife.Objects.Furniture in this room. This method uses the TinyLife.Objects.FurnitureType.TypeSettings.DecorativeRating function. |
IEnumerable<T> | GetObjects ( ) | Returns all of the TinyLife.Objects.MapObject instances that are contained in this room |
IEnumerable<ValueTuple<Wall, Int32>> | GetWalls ( Boolean ) |
Returns all of the TinyLife.World.Wall instances that are border walls or internal walls of this room. An internal wall is a wall for which both sides are contained in the room, rather than just one. |
Boolean | IsFullyRoofed ( ) | Returns whether or not this room has a TinyLife.World.Roof on all of its TinyLife.World.Room.Tiles |
Boolean | IsSameRoom ( ICollection <Point > ) |
Returns whether this room has the same covered TinyLife.World.Room.Tiles as the given collection |
Boolean | Validate ( ) | This method is called when this object is loaded from disk. |