Fix crash when hitting 'T' to tap timing while no timing point is selected

This commit is contained in:
Dean Herbert 2022-11-23 15:39:56 +09:00
parent 23f91ec717
commit d146f86511
2 changed files with 9 additions and 0 deletions

View File

@ -295,6 +295,9 @@ namespace osu.Game.Screens.Edit.Timing
private void handleTap()
{
if (selectedGroup?.Value == null)
return;
tapTimings.Add(Clock.CurrentTime);
if (tapTimings.Count > initial_taps_to_ignore + max_taps_to_consider)

View File

@ -183,12 +183,18 @@ namespace osu.Game.Screens.Edit.Timing
private void start()
{
if (selectedGroup.Value == null)
return;
editorClock.Seek(selectedGroup.Value.Time);
editorClock.Start();
}
private void reset()
{
if (selectedGroup.Value == null)
return;
editorClock.Stop();
editorClock.Seek(selectedGroup.Value.Time);
}