mirror of
https://github.com/ppy/osu.git
synced 2024-12-17 11:12:55 +08:00
fix seeking back on control points
This commit is contained in:
parent
3bcd6b9af5
commit
3fe0791298
@ -1098,6 +1098,13 @@ namespace osu.Game.Screens.Edit
|
||||
|
||||
private void seekControlPoint(int direction)
|
||||
{
|
||||
// Gives 350 ms margin to seek back after last control point
|
||||
double seekMargin = 0;
|
||||
if (clock.IsRunning)
|
||||
{
|
||||
seekMargin = 350;
|
||||
}
|
||||
|
||||
var found = direction < 1
|
||||
? editorBeatmap.ControlPointInfo.AllControlPoints.LastOrDefault(p => p.Time < clock.CurrentTime)
|
||||
: editorBeatmap.ControlPointInfo.AllControlPoints.FirstOrDefault(p => p.Time > clock.CurrentTime);
|
||||
|
Loading…
Reference in New Issue
Block a user