1
0
mirror of https://github.com/ppy/osu.git synced 2025-01-12 17:23:22 +08:00

Merge pull request #18762 from peppy/timing-offset-adjust-seek-only-at-start

Fix adjusting offset via button seeking to timing point's offset unexpectedly
This commit is contained in:
Salman Ahmed 2022-06-19 02:11:49 +03:00 committed by GitHub
commit d0c9788a4a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -195,6 +195,8 @@ namespace osu.Game.Screens.Edit.Timing
private void adjustOffset(double adjust)
{
bool wasAtStart = editorClock.CurrentTimeAccurate == selectedGroup.Value.Time;
// VERY TEMPORARY
var currentGroupItems = selectedGroup.Value.ControlPoints.ToArray();
@ -208,7 +210,7 @@ namespace osu.Game.Screens.Edit.Timing
// the control point might not necessarily exist yet, if currentGroupItems was empty.
selectedGroup.Value = beatmap.ControlPointInfo.GroupAt(newOffset, true);
if (!editorClock.IsRunning)
if (!editorClock.IsRunning && wasAtStart)
editorClock.Seek(newOffset);
}