1
0
mirror of https://github.com/ppy/osu.git synced 2024-09-22 13:27:23 +08:00

Improve implementation

This commit is contained in:
BlauFx 2022-08-08 20:53:05 +02:00
parent fac2596eee
commit f6e65cf1af
No known key found for this signature in database
GPG Key ID: BB73374479D2AA97
2 changed files with 7 additions and 7 deletions

View File

@ -81,6 +81,11 @@ namespace osu.Game.Screens.Play
private bool isRestarting;
/// <summary>
/// Is set to true when pressed the via the quick retry hotkey.
/// </summary>
public Bindable<bool> IsQuickRestart = new Bindable<bool>();
private Bindable<bool> mouseWheelDisabled;
private readonly Bindable<bool> storyboardReplacesBackground = new Bindable<bool>();
@ -287,7 +292,7 @@ namespace osu.Game.Screens.Play
{
if (!this.IsCurrentScreen()) return;
Configuration.AutomaticallySkipIntro = true;
IsQuickRestart.Value = true;
fadeOut(true);
Restart();
},
@ -370,10 +375,7 @@ namespace osu.Game.Screens.Play
skipIntroOverlay.IsSkippable.ValueChanged += e =>
{
if (Configuration.AutomaticallySkipIntro && e.NewValue && RestartCount > 0)
{
Configuration.AutomaticallySkipIntro = false;
performUserRequestedSkip();
}
};
}

View File

@ -386,9 +386,7 @@ namespace osu.Game.Screens.Play
private void restartRequested()
{
if (CurrentPlayer != null)
{
isHotKeyRestart = CurrentPlayer.Configuration.AutomaticallySkipIntro;
}
isHotKeyRestart = CurrentPlayer.IsQuickRestart.Value;
hideOverlays = true;
ValidForResume = true;