// Update is called once per frame void Update() { if (currValue == 0.0f) { controller.DespawnResource(this.gameObject); } }