mirror of
https://github.com/ppy/osu
synced 2025-03-02 09:30:57 +00:00
Eagerly attempt to pause the game when the window is not focused
This commit is contained in:
parent
b016d53b85
commit
6487bf45cf
@ -224,6 +224,15 @@ namespace osu.Game.Screens.Play
|
|||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
protected override void Update()
|
||||||
|
{
|
||||||
|
// eagerly pause when we lose window focus (if we are locally playing).
|
||||||
|
if (!Game.IsActive && !HitRenderer.HasReplayLoaded)
|
||||||
|
Pause();
|
||||||
|
|
||||||
|
base.Update();
|
||||||
|
}
|
||||||
|
|
||||||
private void initializeSkipButton()
|
private void initializeSkipButton()
|
||||||
{
|
{
|
||||||
const double skip_required_cutoff = 3000;
|
const double skip_required_cutoff = 3000;
|
||||||
|
Loading…
Reference in New Issue
Block a user