Exemplo n.º 1
0
    public void EndSong()
    {
        if (audioS.time == audioS.clip.length)
        {
            waitToEnd = false;

            if (tutComp)
            {
                song.totalMistakes += NumMistakes();
            }

            song.timesPlayed += 1;
            song.totalMoney  += salary;
            pi.IncMoney(salary);

            blocker.SetActive(false);
            songInfo.SetActive(false);
            errorInfo.SetActive(false);
            index = 0;
            gameObject.SetActive(false);
        }
    }