Struct FlexalonSlot
- Namespace
- Flexalon
- Assembly
- Flexalon.dll
A value snapshot of a placement location identified by its layout and index.
public struct FlexalonSlot
Constructors
FlexalonSlot(IFlexalonSlottedLayout, Vector3Int)
Creates a slot with zero position and size, and identity rotation.
public FlexalonSlot(IFlexalonSlottedLayout layout, Vector3Int index = default)
Parameters
layoutIFlexalonSlottedLayoutindexVector3Int
Fields
DelegateLayout
The child layout, such as a Flexalon Row, that the item will be added to, or null to add it to Layout directly.
public IFlexalonNode DelegateLayout
Field Value
Index
The layout-specific index. Cell layouts use column, row, and layer.
public Vector3Int Index
Field Value
- Vector3Int
Layout
The layout that owns this slot.
public IFlexalonSlottedLayout Layout
Field Value
SwapNode
The node currently occupying the slot in swap queries.
public IFlexalonNode SwapNode
Field Value
WorldPosition
The center of the slot in world space.
public Vector3 WorldPosition
Field Value
- Vector3
WorldRotation
The orientation of the slot in world space.
public Quaternion WorldRotation
Field Value
- Quaternion
WorldSize
World-space dimensions along the axes of WorldRotation.
public Vector3 WorldSize
Field Value
- Vector3
Methods
Equals(FlexalonSlot)
Compares the owning layout, index, and geometry without boxing.
public bool Equals(FlexalonSlot other)
Parameters
otherFlexalonSlot
Returns
- bool
Equals(object)
public override bool Equals(object obj)
Parameters
objobject
Returns
- bool
GetHashCode()
public override int GetHashCode()
Returns
- int
Operators
operator ==(FlexalonSlot, FlexalonSlot)
Returns true if the slots have the same layout, index, and geometry.
public static bool operator ==(FlexalonSlot left, FlexalonSlot right)
Parameters
leftFlexalonSlotrightFlexalonSlot
Returns
- bool
operator !=(FlexalonSlot, FlexalonSlot)
Returns true if the slots differ in layout, index, or geometry.
public static bool operator !=(FlexalonSlot left, FlexalonSlot right)
Parameters
leftFlexalonSlotrightFlexalonSlot
Returns
- bool