Exemple #1
0
        private bool onFail()
        {
            if (!CheckModsAllowFailure())
            {
                return(false);
            }

            HasFailed = true;

            // There is a chance that we could be in a paused state as the ruleset's internal clock (see FrameStabilityContainer)
            // could process an extra frame after the GameplayClock is stopped.
            // In such cases we want the fail state to precede a user triggered pause.
            if (PauseOverlay.State.Value == Visibility.Visible)
            {
                PauseOverlay.Hide();
            }

            failAnimation.Start();

            if (Mods.Value.OfType <IApplicableFailOverride>().Any(m => m.RestartOnFail))
            {
                Restart();
            }

            return(true);
        }
Exemple #2
0
 public void Resume()
 {
     lastPauseActionTime = Time.Current;
     hudOverlay.KeyCounter.IsCounting = true;
     hudOverlay.Progress.Hide();
     pauseOverlay.Hide();
     decoupledClock.Start();
 }
Exemple #3
0
 public void Resume()
 {
     lastPauseActionTime = Time.Current;
     hudOverlay.KeyCounter.IsCounting = true;
     pauseOverlay.Hide();
     sourceClock.Start();
     IsPaused = false;
 }
Exemple #4
0
 public void Resume()
 {
     lastPauseActionTime                = Time.Current;
     playerInputManager.PassThrough     = false;
     scoreOverlay.KeyCounter.IsCounting = true;
     pauseOverlay.Hide();
     sourceClock.Start();
     isPaused = false;
 }
Exemple #5
0
        private bool onFail()
        {
            if (Mods.Value.OfType <IApplicableFailOverride>().Any(m => !m.AllowFail))
            {
                return(false);
            }

            GameplayClockContainer.Stop();

            HasFailed = true;

            // There is a chance that we could be in a paused state as the ruleset's internal clock (see FrameStabilityContainer)
            // could process an extra frame after the GameplayClock is stopped.
            // In such cases we want the fail state to precede a user triggered pause.
            if (PauseOverlay.State == Visibility.Visible)
            {
                PauseOverlay.Hide();
            }

            FailOverlay.Retries = RestartCount;
            FailOverlay.Show();
            return(true);
        }