SCRIPTING API / Physics / RaycastCommand
RaycastCommand
Batched raycast command for high-volume query tests.
Kindstruct
NamespaceKroys.EngineScripting
Members10
Source
RaycastCommand.csDECLARATION
Declaration
Namespace Kroys.EngineScripting.
Declaration
public struct RaycastCommand
REFERENCE
Members
Constructors
#public RaycastCommand( Vector3 origin, Vector3 direction, float distance, uint gameplayLayerMask = uint.MaxValue, Entity ignoredEntity = default, bool includeTriggers = false, bool debugDraw = false, float debugDrawDurationSeconds = 0.0f)Creates a raycast command.
#public RaycastCommand( Vector3 origin, Vector3 direction, float distance, uint gameplayLayerMask, bool includeTriggers, bool debugDraw = false, float debugDrawDurationSeconds = 0.0f) : this(origin, direction, distance, gameplayLayerMask, default, includeTriggers, debugDraw, debugDrawDurationSeconds)Creates a raycast command.
Fields
#public Vector3 OriginWorld-space start of the ray.
#public Vector3 DirectionWorld-space direction of the ray (normalized by the query).
#public float DistanceMaximum ray length in metres.
#public uint GameplayLayerMaskGameplay layers the ray can hit (Physics.LayerMask).
#public uint IgnoredEntityIdId of an entity the ray ignores (for example the shooter); 0 ignores none.
#public int IncludeTriggersNonzero to hit trigger colliders too.
#public int DebugDrawNonzero to draw the ray when query debugging is on.
#public float DebugDrawDurationSecondsHow long a debug-drawn ray stays visible.
Signatures
public Vector3 Origin public Vector3 Direction public float Distance public uint GameplayLayerMask public uint IgnoredEntityId public int IncludeTriggers public int DebugDraw public float DebugDrawDurationSeconds public RaycastCommand( Vector3 origin, Vector3 direction, float distance, uint gameplayLayerMask = uint.MaxValue, Entity ignoredEntity = default, bool includeTriggers = false, bool debugDraw = false, float debugDrawDurationSeconds = 0.0f) public RaycastCommand( Vector3 origin, Vector3 direction, float distance, uint gameplayLayerMask, bool includeTriggers, bool debugDraw = false, float debugDrawDurationSeconds = 0.0f) : this(origin, direction, distance, gameplayLayerMask, default, includeTriggers, debugDraw, debugDrawDurationSeconds)
KroysEngine 0.1.0 documentation, built from the engine repository by Tools/BuildDocsSite.py.