Change the way Score is initialised in Player to better lend to population of metadata

This commit is contained in:
Dean Herbert
2021-06-02 15:44:04 +09:00
parent 45984f035b
commit a15cac6f53
5 changed files with 45 additions and 76 deletions

View File

@ -18,6 +18,9 @@ namespace osu.Game.Screens.Play
{
private readonly Score score;
[Resolved]
private SpectatorClient spectatorClient { get; set; }
protected override bool CheckModsAllowFailure() => false; // todo: better support starting mid-way through beatmap
public SpectatorPlayer(Score score)
@ -25,13 +28,10 @@ namespace osu.Game.Screens.Play
this.score = score;
}
protected override ResultsScreen CreateResults(ScoreInfo score)
{
return new SpectatorResultsScreen(score);
}
protected override Score CreateScore() => score;
[Resolved]
private SpectatorClient spectatorClient { get; set; }
protected override ResultsScreen CreateResults(ScoreInfo score)
=> new SpectatorResultsScreen(score);
[BackgroundDependencyLoader]
private void load()