using UnityEngine;
using System.Collections;
using UnityEngine.SceneManagement;

public class Menu : MonoBehaviour {

    public GameObject[] menuButtons1;
    public GameObject[] menuButtons2;

	// Use this for initialization
	void Start () {
	
	}
	
	// Update is called once per frame
	void Update () {
	
	}

    public void LoadScene(string sceneToLoad) {
        SceneManager.LoadScene(sceneToLoad);
    }

    public void ActivateMenu(int menuToActivate) {

        switch (menuToActivate) {
            default:
                Debug.LogError("Button passed an invalid value to the switch menu method");
                break;
            case 1:
                for (int i = 0; i < menuButtons1.Length; i++) {
                    menuButtons1[i].SetActive(true);
                }
                for (int i = 0; i < menuButtons2.Length; i++) {
                    menuButtons2[i].SetActive(false);
                }
                break;
            case 2:
                for (int i = 0; i < menuButtons1.Length; i++)
                {
                    menuButtons1[i].SetActive(false);
                }
                for (int i = 0; i < menuButtons2.Length; i++)
                {
                    menuButtons2[i].SetActive(true);
                }
                break;
        }

    }
}
