using System.Collections;
using System.Collections.Generic;
using UnityEngine;

public class mainMenuButtons : MonoBehaviour {

    /* mainMenuButtons SCRIPT
     * 
     * Has functions for each of the
     * buttons on the main menu.
     * */

    //The panel with the instructions on.
    public GameObject howToPanel;

	// Use this for initialization
	void Start () {
		
	}
	
	// Update is called once per frame
	void Update () {
        Debug.Log(Input.GetAxis("navAxis"));
		if(Input.GetButton("P1Fret1") || Input.GetButton("P2Fret1"))
        {
            //Close down the 'how to' panel
            howToPanel.SetActive(false);
        }
	}

    //Linked to the 'play' button
    public void startGame()
    {
        UnityEngine.SceneManagement.SceneManager.LoadScene("mainScene");
    }

    //Linked to the 'how to' button
    public void displayHelp()
    {
        //Display the 'how to' panel
        howToPanel.SetActive(true);
    }

    //Linked to the 'quit' button
    public void quitGame()
    {
        Application.Quit();
    }
}
