mirror of
https://github.com/ppy/osu.git
synced 2024-11-13 20:07:25 +08:00
Merge pull request #4661 from peppy/fix-pause-tests
Fix pause tests and cursor visibility
This commit is contained in:
commit
63fd3034ca
@ -68,8 +68,13 @@ namespace osu.Game.Rulesets.UI
|
||||
{
|
||||
Cursor = CreateCursor();
|
||||
if (Cursor != null)
|
||||
{
|
||||
// initial showing of the cursor will be handed by MenuCursorContainer (via DrawableRuleset's IProvideCursor implementation).
|
||||
Cursor.Hide();
|
||||
|
||||
AddInternal(Cursor);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Performs post-processing tasks (if any) after all DrawableHitObjects are loaded into this Playfield.
|
||||
|
@ -110,20 +110,17 @@ namespace osu.Game.Screens.Play
|
||||
adjustableClock.ChangeSource(sourceClock);
|
||||
updateRate();
|
||||
|
||||
this.Delay(750).Schedule(() =>
|
||||
{
|
||||
if (!IsPaused.Value)
|
||||
Start();
|
||||
});
|
||||
});
|
||||
});
|
||||
}
|
||||
|
||||
public void Start()
|
||||
{
|
||||
// Seeking the decoupled clock to its current time ensures that its source clock will be seeked to the same time
|
||||
// This accounts for the audio clock source potentially taking time to enter a completely stopped state
|
||||
adjustableClock.Seek(adjustableClock.CurrentTime);
|
||||
Seek(GameplayClock.CurrentTime);
|
||||
adjustableClock.Start();
|
||||
IsPaused.Value = false;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user