PhysicsIntersectRayResult3D
Stores the result of a ray intersection query.
Stores the result of a ray intersection query.
This object contains the intersection information produced by PhysicsDirectSpaceState3D.IntersectRayInto.
After calling PhysicsDirectSpaceState3D.IntersectRayInto, the fields of this object will be populated with the hit information if the ray intersects a shape. If no intersection occurred, the values remain unchanged from the previous state.
Declarations checked against C# SDK 1.0.0. Expand a name to see declarations and documentation.
Constructors1
PhysicsIntersectRayResult3DConstructor
public PhysicsIntersectRayResult3D();Properties7
ColliderProperty
public ReckfellObject Collider { get; }The colliding object.
ColliderFaceIndexProperty
public int ColliderFaceIndex { get; }The face index at the intersection point.
Note: Returns a valid number only if the intersected shape is a ConcavePolygonShape3D. Otherwise, -1 is returned.
ColliderIdProperty
public ulong ColliderId { get; }The colliding object's ID.
ColliderRidProperty
public Rid ColliderRid { get; }The intersecting object's Rid.
ColliderShapeProperty
public int ColliderShape { get; }The shape index of the colliding shape.
NormalProperty
public Vector3 Normal { get; }The object's surface normal at the intersection point, or Vector3(0, 0, 0) if the ray starts inside the shape and PhysicsRayQueryParameters3D.HitFromInside is true.
PositionProperty
public Vector3 Position { get; }The intersection point.
Methods7
GetColliderReckfellObject
public ReckfellObject GetCollider();ReckfellObjectGetColliderFaceIndexint
public int GetColliderFaceIndex();intGetColliderIdulong
public ulong GetColliderId();ulongGetColliderRidRid
public Rid GetColliderRid();RidGetColliderShapeint
public int GetColliderShape();intGetNormalVector3
public Vector3 GetNormal();Vector3GetPositionVector3
public Vector3 GetPosition();Vector3