using UnityEngine;
using System.Collections;

public class ShowGameOverUI : MonoBehaviour 
{
    public Animator myAnim;

    void Start() 
    {
        myAnim = GetComponent<Animator>();
    }

    void OnEnable() 
    {
        EventManager.StartListening(Constants.GAME_OVER, ShowGameOverAnim);
    }

    void OnDisable() 
    {
        EventManager.StopListening(Constants.GAME_OVER, ShowGameOverAnim);
    }

    void ShowGameOverAnim() 
    {
        myAnim.Play("ShowGameOver");
    }
}
