using UnityEngine;
using System.Collections;
using System.Collections.Generic;

namespace RollingRockRumble {
    public class DestroyTimer : MonoBehaviour {

        public float timer = 5f;
        private float creationTime;



        void Start() {
            creationTime = Time.time;
        }



        void Update() {
            if ((creationTime + timer) < Time.time) {
                Destroy(this.gameObject);
            }
        }
    }
}