mirror of
https://github.com/ppy/osu.git
synced 2025-03-28 20:47:22 +08:00
Combine methods
This commit is contained in:
parent
5073ede115
commit
e18f4cd4ba
@ -63,6 +63,8 @@ namespace osu.Game.Screens.Play
|
|||||||
if (!this.IsCurrentScreen())
|
if (!this.IsCurrentScreen())
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
bool isFirstBundle = score.Replay.Frames.Count == 0;
|
||||||
|
|
||||||
foreach (var frame in bundle.Frames)
|
foreach (var frame in bundle.Frames)
|
||||||
{
|
{
|
||||||
IConvertibleReplayFrame convertibleFrame = GameplayRuleset.CreateConvertibleReplayFrame();
|
IConvertibleReplayFrame convertibleFrame = GameplayRuleset.CreateConvertibleReplayFrame();
|
||||||
@ -74,19 +76,8 @@ namespace osu.Game.Screens.Play
|
|||||||
score.Replay.Frames.Add(convertedFrame);
|
score.Replay.Frames.Add(convertedFrame);
|
||||||
}
|
}
|
||||||
|
|
||||||
seekToGameplay();
|
if (isFirstBundle && score.Replay.Frames.Count > 0)
|
||||||
}
|
NonFrameStableSeek(score.Replay.Frames[0].Time);
|
||||||
|
|
||||||
private bool seekedToGameplay;
|
|
||||||
|
|
||||||
private void seekToGameplay()
|
|
||||||
{
|
|
||||||
if (seekedToGameplay || score.Replay.Frames.Count == 0)
|
|
||||||
return;
|
|
||||||
|
|
||||||
NonFrameStableSeek(score.Replay.Frames[0].Time);
|
|
||||||
|
|
||||||
seekedToGameplay = true;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
protected override Score CreateScore() => score;
|
protected override Score CreateScore() => score;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user