Avoid beatmap load call in IntroScreen

This commit is contained in:
Dean Herbert
2020-08-21 15:50:14 +09:00
parent f7e4feee34
commit 0ae460fb8f
3 changed files with 5 additions and 3 deletions

View File

@ -66,6 +66,7 @@ namespace osu.Game.Screens.Menu
/// <summary>
/// Whether the <see cref="Track"/> is provided by osu! resources, rather than a user beatmap.
/// Only valid during or after <see cref="LogoArriving"/>.
/// </summary>
protected bool UsingThemedIntro { get; private set; }
@ -115,7 +116,6 @@ namespace osu.Game.Screens.Menu
if (setInfo != null)
{
initialBeatmap = beatmaps.GetWorkingBeatmap(setInfo.Beatmaps[0]);
UsingThemedIntro = !initialBeatmap.LoadTrack().IsDummyDevice;
}
return UsingThemedIntro;
@ -169,6 +169,7 @@ namespace osu.Game.Screens.Menu
{
beatmap.Value = initialBeatmap;
Track = musicController.CurrentTrack;
UsingThemedIntro = !initialBeatmap.LoadTrack().IsDummyDevice;
logo.MoveTo(new Vector2(0.5f));
logo.ScaleTo(Vector2.One);