Skip to content

Commit

Permalink
Skip the pause cooldown when in intro / break time
Browse files Browse the repository at this point in the history
Had a quick look at adding test coverage in `TestScenePause` but the
setup to get into either of these states seems a bit annoying..
  • Loading branch information
peppy committed Dec 16, 2024
1 parent 8a2f161 commit 85ada32
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion osu.Game/Screens/Play/Player.cs
Original file line number Diff line number Diff line change
Expand Up @@ -1032,7 +1032,7 @@ private void onFailComplete()
private double? lastPauseActionTime;

protected bool PauseCooldownActive =>
lastPauseActionTime.HasValue && GameplayClockContainer.CurrentTime < lastPauseActionTime + PauseCooldownDuration;
PlayingState.Value == LocalUserPlayingState.Playing && lastPauseActionTime.HasValue && GameplayClockContainer.CurrentTime < lastPauseActionTime + PauseCooldownDuration;

/// <summary>
/// A set of conditionals which defines whether the current game state and configuration allows for
Expand Down

0 comments on commit 85ada32

Please sign in to comment.