1
0
mirror of https://github.com/ppy/osu.git synced 2026-05-19 07:41:18 +08:00

fix seeking back on control points

This commit is contained in:
TaterToes
2024-10-17 16:26:13 -04:00
committed by GitHub
Unverified
parent 3bcd6b9af5
commit 3fe0791298
+7
View File
@@ -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);