Example #1
0
    IEnumerator fadeOutGameObject(GameObject go)
    {
        CanvasGroup cg   = go.GetComponent <CanvasGroup>();
        float       time = 0.5f;

        while (cg.alpha > 0.0f)
        {
            cg.alpha -= Time.deltaTime / time;
            yield return(null);
        }
        cg.alpha = 0.0f;
        crebitosLocker.unlockMenu();
        crebitosScrollText.ResetScrolling();
        Debug.Log(crebitosLocker.isLocked());
    }