Limited support
This feature is only present in Portal 2: Community Edition and Portal: Revolution.CGameTrace
DidHit
Returns true if the trace hit anything
bool CGameTrace::DidHit()
DidHitNonWorldEntity
Returns true if the trace hit non-world entity
bool CGameTrace::DidHitNonWorldEntity()
DidHitWorld
Returns true if trace hit world
bool CGameTrace::DidHitWorld()
GetContents
Returns the contents flags of the hit entity or surface
int CGameTrace::GetContents()
GetEndPos
Returns the end position of the trace
Vector CGameTrace::GetEndPos()
GetEntity
Returns a handle to the entity this trace hit
handle CGameTrace::GetEntity()
GetEntityIndex
Returns the index of the entity hit, or -1 if it did not hit an entity
int CGameTrace::GetEntityIndex()
GetFraction
Time completed, 1.0 means no hit
float CGameTrace::GetFraction()
GetImpactNormal
Returns the normal of the plane where the trace hit
Vector CGameTrace::GetImpactNormal()
GetStartPos
Returns the start position of the trace
Vector CGameTrace::GetStartPos()