Beispiel #1
0
        public static bool OverlapCollider <T>(ref T target, OverlapColliderInput input, out OverlapColliderHit closestHit) where T : struct, IQueryable
        {
            var collector = new ClosestHitCollector <OverlapColliderHit>(1.0f);

            if (target.OverlapCollider(input, ref collector))
            {
                closestHit = collector.ClosestHit;
                return(true);
            }

            closestHit = new OverlapColliderHit();
            return(false);
        }
Beispiel #2
0
 public bool OverlapCollider(OverlapColliderInput input, out OverlapColliderHit hit) => QueryWrappers.OverlapCollider(ref this, input, out hit);