Exemplo n.º 1
0
        public List <GameObjectRayHit> RaycastAllObjectsSorted(Ray ray, SceneRaycastPrecision raycastPresicion)
        {
            List <GameObjectRayHit> allHits = RaycastAllObjects(ray, raycastPresicion);

            GameObjectRayHit.SortByHitDistance(allHits);

            return(allHits);
        }
        public bool RaycastAllObjectsSorted(Ray ray, SceneRaycastPrecision raycastPresicion, List <GameObjectRayHit> hits)
        {
            bool anyHit = RaycastAllObjects(ray, raycastPresicion, hits);

            GameObjectRayHit.SortByHitDistance(hits);

            return(anyHit);
        }