mirror of
https://github.com/ppy/osu.git
synced 2024-12-14 07:42:57 +08:00
Use local clock to add consistency to skip times
This commit is contained in:
parent
db24ac28ec
commit
73bc71f8b2
@ -3,6 +3,9 @@
|
||||
|
||||
using System.Linq;
|
||||
using NUnit.Framework;
|
||||
using osu.Framework.Graphics;
|
||||
using osu.Framework.Graphics.Containers;
|
||||
using osu.Framework.Timing;
|
||||
using osu.Game.Screens.Play;
|
||||
using osuTK;
|
||||
using osuTK.Input;
|
||||
@ -19,9 +22,20 @@ namespace osu.Game.Tests.Visual.Gameplay
|
||||
public void SetUp() => Schedule(() =>
|
||||
{
|
||||
requestCount = 0;
|
||||
Child = skip = new SkipOverlay(Clock.CurrentTime + 5000)
|
||||
Child = new Container
|
||||
{
|
||||
RequestSeek = _ => requestCount++
|
||||
RelativeSizeAxes = Axes.Both,
|
||||
Clock = new FramedOffsetClock(Clock)
|
||||
{
|
||||
Offset = -Clock.CurrentTime,
|
||||
},
|
||||
Children = new Drawable[]
|
||||
{
|
||||
skip = new SkipOverlay(5000)
|
||||
{
|
||||
RequestSeek = _ => requestCount++
|
||||
}
|
||||
},
|
||||
};
|
||||
});
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user