Ejemplo n.º 1
0
    public static void SetFadeValue(Fade fade, bool blockInput, float fadeValue)
    {
        if (fade == null)
        {
            fade = GetInstance();
        }

        if (fade == null)
        {
            return;
        }

        fade.m_image.color = new Color(0, 0, 0, fadeValue);
        fade.BlockInput(blockInput);
        fade.m_targetFadeValue = fadeValue;
    }
Ejemplo n.º 2
0
    public static void FadeInternal(Fade fade, float targetFadeValue, bool blockInput, System.Action callback)
    {
        if (fade == null)
        {
            fade = GetInstance();
        }

        if (fade == null)
        {
            return;
        }

        if (fade.IsDuringFading())
        {
            return;
        }

        fade.BlockInput(blockInput);
        fade.m_image.color     = new Color(0, 0, 0, 1 - targetFadeValue);
        fade.m_targetFadeValue = targetFadeValue;
        fade.m_callback        = callback;
    }