CryEngine.OldPhysics.RaycastHit

CryEngine.OldPhysics.RaycastHit

Wrapper class for a ray cast output. More...

Public Types

enum HitType { HitType.Unknown, HitType.Terrain, HitType.Entity, HitType.Static }

Public Member Functions

RaycastHit (ray_hit ray, int hits)
bool HasHitEntity (Entity entity)
Returns True if the entity passed in was hit. More...

Properties

ray_hit NativeHandle [get]
int Hits [get]
bool Intersected [get]
Vector3 Point [get]
Vector3 Normal [get]
float Distance [get]
IEntity HitNativeEntity [get]
The native CRYENGINE entity that was hit. Returns null if nothing was hit, or the hit wasn't an Entity. More...
Entity HitBaseEntity [get]
The Entity that was hit. Returns null if nothing was hit, or the hit wasn't an Entity. More...
HitType Type [get]
The type of surface that was hit, if any. Returns 'Unknown' if nothing was hit. More...
IPhysicalEntity Collider [get]
The native entity's physical entity, if something was hit. More...

Detailed Description

Wrapper class for a ray cast output.

Member Enumeration Documentation

◆ HitType

Enumerator
Unknown
Terrain
Entity
Static

Constructor & Destructor Documentation

◆ RaycastHit()

CryEngine.OldPhysics.RaycastHit.RaycastHit ( ray_hit ray,
int hits
)
inline

Member Function Documentation

◆ HasHitEntity()

bool CryEngine.OldPhysics.RaycastHit.HasHitEntity ( Entity entity)
inline

Returns True if the entity passed in was hit.

Returns
true, if entity was hit, false otherwise.
Parameters
entityEntity.

Property Documentation

◆ Collider

IPhysicalEntity CryEngine.OldPhysics.RaycastHit.Collider
get

The native entity's physical entity, if something was hit.

◆ Distance

float CryEngine.OldPhysics.RaycastHit.Distance
get

◆ HitBaseEntity

Entity CryEngine.OldPhysics.RaycastHit.HitBaseEntity
get

The Entity that was hit. Returns null if nothing was hit, or the hit wasn't an Entity.

◆ HitNativeEntity

IEntity CryEngine.OldPhysics.RaycastHit.HitNativeEntity
get

The native CRYENGINE entity that was hit. Returns null if nothing was hit, or the hit wasn't an Entity.

◆ Hits

int CryEngine.OldPhysics.RaycastHit.Hits
get

◆ Intersected

bool CryEngine.OldPhysics.RaycastHit.Intersected
get

◆ NativeHandle

ray_hit CryEngine.OldPhysics.RaycastHit.NativeHandle
get

◆ Normal

Vector3 CryEngine.OldPhysics.RaycastHit.Normal
get

◆ Point

Vector3 CryEngine.OldPhysics.RaycastHit.Point
get

◆ Type

HitType CryEngine.OldPhysics.RaycastHit.Type
get

The type of surface that was hit, if any. Returns 'Unknown' if nothing was hit.