private void Update() { _timer.UpdateTime(); if (_timer.IsFinished) { _timer.ResetTimer(); _action.Invoke(); } }
private void UpdateFrenzy() { FrenzyDecayTimer?.UpdateTime(); if (FrenzyDecayTimer.IsFinished) { FrenzyOut.Value = 0; FrenzyDecayTimer.StopTimer(); } }
private void UpdateHunger() { HungerDecayTimer?.UpdateTime(); if (HungerDecayTimer.IsFinished && HungerOut.Value > 0) { damageFeedback.PlayFeedbacks(); IncrementHunger(-1); HungerDecayTimer.RestartTimer(); } }
private void Update() { _spawnDelay.UpdateTime(); if (_spawnDelay.IsFinished) { var spawned = TrySpawn(); if (spawned && _spawned.Count + 1 < _count.Value) { _spawnDelay.RestartTimer(); } } }
public void UpdateTime() { targetParameter?.UpdateTime(); }