Exemplo n.º 1
0
    void Update()
    {
        if (activateWinPanel)
        {
            counter       += Time.deltaTime / 2;
            winPanel.color = new Color(winPanel.color.r, winPanel.color.g, winPanel.color.b, counter);
        }
        if (player.IsDead)
        {
            counter2 += Time.deltaTime;
            if (counter2 >= 0.7f)
            {
                counter        += Time.deltaTime / 2;
                losePanel.color = new Color(losePanel.color.r, losePanel.color.g, losePanel.color.b, counter);

                if (counter >= 1)
                {
                    if (Input.anyKeyDown)
                    {
                        sceneM.LoadGameplayScreen();
                        counter  = 0;
                        counter2 = 0;
                    }
                }
            }
        }
    }
Exemplo n.º 2
0
 public void PressedStart()
 {
     sceneM.LoadGameplayScreen();
 }