// Update is called once per frame void Update() { m_timer += Time.deltaTime; DragonValues.Instance.FuelAmount -= Time.deltaTime * DragonValues.Instance.FuelConsumption; needle.SetTarget(DragonValues.Instance.FuelAmount / 100.0f); if (BreakTimes.Count <= 0) { return; } if (BreakTimes[0] <= m_timer) { string _randomKey = ""; if (BreakTimes.Count == 1) { _randomKey = BreakingPoints.Shoot_Fire; } else if (BreakTimes.Count == 2) { _randomKey = BreakingPoints.Turn_Up; } else { _randomKey = GetRandomBreakingPoint(); } Condition _newCondition = GetNewConditionForKey(_randomKey); m_conditions[_randomKey] = _newCondition; if (_newCondition == Condition.Broke) { BreakingPartsKeys.Remove(_randomKey); } BreakTimes.RemoveAt(0); if (ControlPanel.Instance != null) { ControlPanel.Instance.UpdateColorForLight(_randomKey, _newCondition); } } }