Show / Hide Table of Contents

Class DoorHandlerGrid3D

Component that marks a door of a room template.

Inheritance
System.Object
DoorHandlerGrid3D
Namespace: Edgar.Unity
Assembly: cs.temp.dll.dll
Syntax
public class DoorHandlerGrid3D : MonoBehaviour
Remarks

Why this name instead of just "DoorGrid3D"? The shorter name just does not feel right to me. This handler component is referenced/store in multiple place and it would be confusing if it was named just "Door" instead of "DoorHandler".

Fields

Blockers

List of blockers that are used in place of door positions that are not used. If more than one is provided, a random one is picked.

Declaration
public List<GameObject> Blockers
Field Value
Type Description
System.Collections.Generic.List<GameObject>

Connectors

List of connectors that are used in place of door positions that are used. If more than one is provided, a random one is picked.

Declaration
public List<GameObject> Connectors
Field Value
Type Description
System.Collections.Generic.List<GameObject>

Direction

Direction of the door that is used if a level graph is configured to be directed. The direction specifies whether the door is an entrance, exit or both.

Declaration
public DoorDirection Direction
Field Value
Type Description
DoorDirection

DirectionVector

Internal direction vector of the door. The direction is clockwise on the outline of the room template.

Declaration
public Vector3Int DirectionVector
Field Value
Type Description
Vector3Int

GeneratorSettings

Generator settings.

Declaration
public GeneratorSettingsGrid3D GeneratorSettings
Field Value
Type Description
GeneratorSettingsGrid3D

Height

Height of the door (in tiles).

Declaration
public int Height
Field Value
Type Description
System.Int32

Repeat

How many times should the door be repeated to also cover neighboring tiles. This is similar to hybrid doors in the 2D version of the asset.

Declaration
public int Repeat
Field Value
Type Description
System.Int32

Socket

Door socket which control which doors can be connected together.

Declaration
public DoorSocketBase Socket
Field Value
Type Description
DoorSocketBase

Width

Width of the door (in tiles).

Declaration
public int Width
Field Value
Type Description
System.Int32

Methods

DisableConnectorsAndBlockers()

Declaration
public void DisableConnectorsAndBlockers()

GetDoorLine(Boolean)

Gets the door line that this door handler represents.

Declaration
public DoorLineGrid3D GetDoorLine(bool checkIfValid = true)
Parameters
Type Name Description
System.Boolean checkIfValid

Throws errors if true and the door is not valid.

Returns
Type Description
DoorLineGrid3D

IsDirectionValid()

Declaration
public bool IsDirectionValid()
Returns
Type Description
System.Boolean

ProcessConnectorsAndBlockers(ConnectorsAndBlockersContextGrid3D)

Declaration
public void ProcessConnectorsAndBlockers(ConnectorsAndBlockersContextGrid3D context)
Parameters
Type Name Description
ConnectorsAndBlockersContextGrid3D context

Rotate90(Boolean)

Declaration
public void Rotate90(bool clockwise)
Parameters
Type Name Description
System.Boolean clockwise

SyncRotation()

Declaration
public void SyncRotation()
In This Article
Back to top Generated by DocFX