Exemple #1
0
    public static bool TestSphereCapsule(Vector3 sphereCenter, float sphereR, Vector3 capsuleStart, Vector3 capsuleEnd, float capsuleR)
    {
        float num  = MyPhysics.DistPointLine(capsuleStart, capsuleEnd, sphereCenter);
        float num2 = sphereR + capsuleR;

        return(num <= num2 * num2);
    }