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

public class PauseMenu : MonoBehaviour {

	public GameObject PauseMenuObj;

	private bool _pauseMenuEnabled;

	public void CyclePauseMenu()
	{
		if (_pauseMenuEnabled) {
			PauseMenuObj.SetActive (false);
			Time.timeScale = 1F;
			_pauseMenuEnabled = false;
		} 
		else 
		{
			PauseMenuObj.SetActive (true);
			Time.timeScale = 0F;
			_pauseMenuEnabled = true;
		}
	}

	public void Quit()
	{
	    SceneManager.LoadScene("_menu");
	}
}
