public static bool Intersect(SphereTriggerBounds a, SphereTriggerBounds b, out float sqrDistance)
        {
            sqrDistance = Vector3.SqrMagnitude(a.offsetCenter - b.offsetCenter);
            var radius = a.scaledRadius + b.scaledRadius;

            return(sqrDistance < radius * radius);
        }
        public static bool Intersect(CylinderTriggerBounds a, SphereTriggerBounds b, out float sqrDistance)
        {
            var cylOffset = a.offsetCenter;
            var sphOffset = b.offsetCenter;
            var sphRadius = b.scaledRadius;

            sqrDistance = Vector3Extender.SqrMagnitudeXZ(cylOffset - sphOffset); // XZ check
            var heightDistance = Mathf.Abs(sphOffset.y - cylOffset.y);           // Y check

            var radius = a.scaledRadius + sphRadius;
            var height = a.scaledHeight + sphRadius;

            return((sqrDistance < radius * radius) && (heightDistance < height));
        }
 public override bool Intersect(SphereTriggerBounds bounds, out float sqrDistance) => BoundCollider.Intersect(this, bounds, out sqrDistance);
 public virtual bool Intersect(SphereTriggerBounds bounds, out float sqrDistance)
 {
     sqrDistance = float.MaxValue;
     return(false);
 }