using UnityEngine;
using System.Collections;

public class Fader : MonoBehaviour {

	Animator animator;

	// Use this for initialization
	void Start () {
		animator = transform.GetChild(0).GetComponent<Animator> ();
		DontDestroyOnLoad (gameObject);
		Application.LoadLevel("Menu");
		FadeId ();
	}

	public void FadeId()
	{
		animator.SetTrigger("FadeIn");
	}

	public void FadeOut()
	{
		animator.SetTrigger("FadeOut");
	}

	// Update is called once per frame
	void Update () {
	
	}
}
