Beispiel #1
0
    void Update()
    {
        if (Input.GetKeyUp("up") && index == 2)
        {
            index--;
            txtExit.material  = white;
            txtStart.material = orange;
        }
        else if (Input.GetKeyUp("down") && index == 1)
        {
            index++;
            txtStart.material = white;
            txtExit.material  = orange;
        }

        if (Input.GetKeyUp("x"))
        {
            if (index == 1)
            {
                sceneSwitch.SwitchScene("Map");
            }
            else
            {
                sceneSwitch.EndGame();
            }
        }
    }
Beispiel #2
0
 public void PlayGame()
 {
     sc.SwitchScene();
 }