예제 #1
0
    public static void AdvancedSphereCast(Vector3 position, float radius, Vector3 direction, string[] tags, ref Transform[] output, BoolEvent callback)
    {
        int currentLength = (int)Mathf.Clamp01(output.Length);

        AdvancedSphereCast(position, radius, direction, tags, out output);

        int newLength = (int)Mathf.Clamp01(output.Length);

        if (currentLength != newLength)
        {
            callback.SafeInvoke(newLength > 0);
        }
    }