using UnityEngine;
using System.Collections;

public class TitleScreen : MonoBehaviour
{
	public static TitleScreen instance { get; private set; }

	void Awake()
	{
		instance = this;
	}

	void Start()
	{
		toggleScreenVisibility(true);
	}

	public void toggleScreenVisibility(bool isVisible)
	{
		CanvasGroup grp = GetComponent<CanvasGroup>();
		grp.alpha = isVisible ? 1.0f : 0.0f;
		grp.interactable = grp.blocksRaycasts = isVisible;
	}

	public void StartButtonClicked()
	{
		AudioController.instance.playSFX(AudioController.audioClips.click);

		toggleScreenVisibility(false);
		SpeechBubbleController.instance.toggleScreenVisibility(true);
	}
}
