using UnityEngine;
using System.Collections;
public class ClockBaseAnimation : MonoBehaviour {
[SerializeField] private float currentAmount;
[SerializeField] private float speed;
private float timer;
Animator anim;
// Use this for initialization
void Start () {
currentAmount = 60;
anim = GetComponent<Animator>();
}
// Update is called once per frame
void Update () {
currentAmount -= speed * Time.deltaTime;
if (currentAmount <= 55 && currentAmount >= 0) {
anim.SetTrigger ("TimerBase");
}
else {
anim.SetTrigger ("idle");
}
}
}