using UnityEngine;
using System.Collections;

public class Altar : MonoBehaviour {

    public delegate void UseAction();
    public static event UseAction OnUse;

    public GameObject altarArtefact;

	// Use this for initialization
	void Start () {
        RoundManager.OnRoundStart += Restart;
	}
	
	// Update is called once per frame
	void Update () {
        /**if (Input.GetButtonDown("Fire1"))
        {
            Use();
        }**/
    }

    public void Use()
    {
        if(OnUse != null)
        {
            OnUse();
        }
        altarArtefact.SetActive(true);
    }

    void Restart()
    {
        altarArtefact.SetActive(false);
    }
}
