Class Locker
The in-game Locker.
public class Locker : IWrapper<Locker>, IWorldSpace, IPosition, IRotation- Inheritance
- 
      
      Locker
- Implements
- 
      IWrapper<Locker>
- Inherited Members
- Extension Methods
Constructors
Locker(Locker)
Initializes a new instance of the Locker class.
public Locker(Locker locker)Parameters
- lockerLocker
- The encapsulated MapGeneration.Distributors.Locker. 
Properties
Base
Gets the base MapGeneration.Distributors.Locker that this class is wrapping.
public Locker Base { get; }Property Value
- Locker
Chambers
Gets the all Chambers in this locker.
public IReadOnlyCollection<Chamber> Chambers { get; }Property Value
GameObject
Gets the Locker UnityEngine.GameObject.
public GameObject GameObject { get; }Property Value
- GameObject
List
Gets a IEnumerable<T> of Locker which contains all the Locker instances.
public static IReadOnlyCollection<Locker> List { get; }Property Value
OpenedChambers
Gets or sets an id for manipulating opened chambers.
public ushort OpenedChambers { get; set; }Property Value
Position
Gets the position of this object.
public Vector3 Position { get; }Property Value
- Vector3
RandomChamberPosition
Gets a random position from one of the Chambers.
public Vector3 RandomChamberPosition { get; }Property Value
- Vector3
Room
public Room? Room { get; }Property Value
Rotation
Gets the rotation of this object.
public Quaternion Rotation { get; }Property Value
- Quaternion
Transform
Gets the Locker UnityEngine.Transform.
public Transform Transform { get; }Property Value
- Transform
Type
Gets the LockerType of the Locker.
public LockerType Type { get; }Property Value
Zone
Gets the ZoneType in which the locker is located.
public ZoneType Zone { get; }Property Value
Methods
AddItem(Pickup)
Adds an item to a randomly selected locker chamber.
public void AddItem(Pickup item)Parameters
AddItem(ItemType)
Spawns an item of the specified ItemType to the locker by creating a new Pickup.
public void AddItem(ItemType type)Parameters
- typeItemType
- The type of item to be added. 
Get(LockerType)
Gets an IEnumerable<T> of Locker given the specified LockerType.
public static IEnumerable<Locker> Get(LockerType lockerType)Parameters
- lockerTypeLockerType
- The LockerType to search for. 
Returns
- IEnumerable<Locker>
- An IEnumerable<T> of Locker which contains elements that satisfy the condition. 
Get(ZoneType)
Gets a IEnumerable<T> of Locker given the specified ZoneType.
public static IEnumerable<Locker> Get(ZoneType zoneType)Parameters
Returns
Get(Locker)
Gets the Locker belonging to the MapGeneration.Distributors.Locker, if any.
public static Locker? Get(Locker locker)Parameters
- lockerLocker
- The MapGeneration.Distributors.Locker to get. 
Returns
Get(Func<Locker, bool>)
Gets a IEnumerable<T> of Locker filtered based on a predicate.
public static IEnumerable<Locker> Get(Func<Locker, bool> predicate)Parameters
Returns
- IEnumerable<Locker>
- A IEnumerable<T> of Locker which contains elements that satisfy the condition. 
Random(ZoneType, LockerType)
Gets a random Locker based on the specified filters.
public static Locker? Random(ZoneType zone = ZoneType.Unspecified, LockerType lockerType = LockerType.Unknow)Parameters
- zoneZoneType
- The ZoneType to filter by. If unspecified, all zones are considered. 
- lockerTypeLockerType
- The LockerType to filter by. If unspecified, all locker types are considered.