Mine
public text v1 · immutable Local cameraquery:TRaySceneQuery= MainSceneManager.createRayQuery( cameraRay,Query)
Local result:TVector3 = TVector3.createempty()
Local normal:TVector4 = TVector4.Create( 0 , 0 , 0 , 0 )
cameraQuery.setRay( cameraRay )
cameraQuery.setSortByDistance(True,1)
Local entity:TEntity = mainSceneManager.polyPick( cameraquery , result , normal )
'If something is returned-
If entity.isNull() = False Then'it.isEqualTo( result.getEnd() )=False Then
DebugLog entity.getName()