Class Waypoint
A wrapper class for AdminToys.WaypointToy.
public class Waypoint : AdminToy, IWorldSpace, IPosition, IRotation, IWrapper<WaypointToy>
- Inheritance
-
Waypoint
- Implements
-
IWrapper<WaypointToy>
- Inherited Members
- Extension Methods
Properties
Base
Gets the base AdminToys.WaypointToy.
public WaypointToy Base { get; }
Property Value
- WaypointToy
Bounds
Gets or sets the bounds this waypoint encapsulates.
public Bounds Bounds { get; set; }
Property Value
- Bounds
BoundsSize
Gets or sets the bounds size this waypoint encapsulates.
public Vector3 BoundsSize { get; set; }
Property Value
- Vector3
Prefab
Gets the prefab.
public static WaypointToy Prefab { get; }
Property Value
- WaypointToy
Priority
Gets or sets the Waypoint shown.
public float Priority { get; set; }
Property Value
VisualizeBounds
Gets or sets a value indicating whether the Bounds are shown for Debug.
public bool VisualizeBounds { get; set; }
Property Value
WaypointId
Gets the id of the Waypoint used for RelativePositioning.RelativePosition.WaypointId.
public byte WaypointId { get; }
Property Value
Methods
Create(Transform, Vector3?, Quaternion?, Vector3?, float, bool, bool)
Creates a new Waypoint.
public static Waypoint Create(Transform parent = null, Vector3? position = null, Quaternion? rotation = null, Vector3? scale = null, float priority = 0, bool visualizeBounds = false, bool spawn = true)
Parameters
parentTransformThe transform to create this Waypoint on.
positionVector3?The local position of the Waypoint.
rotationQuaternion?The local rotation of the Waypoint.
scaleVector3?The size of the bounds (This is NOT localScale, it applies to NetworkBoundsSize).
priorityfloatThe priority of the waypoint.
visualizeBoundsboolWhether to visualize the bounds.
spawnboolWhether the Waypoint should be initially spawned.
Returns
Create(Transform, Vector3)
Creates a new Waypoint based on a Transform.
public static Waypoint Create(Transform transform, Vector3 size)
Parameters
transformTransformThe transform to spawn at (LocalScale is applied to Bounds).
sizeVector3The size of the bounds (Applied to NetworkBoundsSize).
Returns
Create(Vector3, Vector3)
Creates a new Waypoint with a specific position and size (bounds).
public static Waypoint Create(Vector3 position, Vector3 size)
Parameters
positionVector3The position of the Waypoint.
sizeVector3The size of the bounds (Applied to NetworkBoundsSize).