diff --git a/osu.Game/Screens/Play/Player.cs b/osu.Game/Screens/Play/Player.cs index 51f1dbd121..2328390d76 100644 --- a/osu.Game/Screens/Play/Player.cs +++ b/osu.Game/Screens/Play/Player.cs @@ -694,9 +694,11 @@ private void scoreCompletionChanged(ValueChangedEvent completed) /// The final score. private async Task prepareScoreForResults() { + var scoreCopy = Score.DeepClone(); + try { - await PrepareScoreForResultsAsync(Score).ConfigureAwait(false); + await PrepareScoreForResultsAsync(scoreCopy).ConfigureAwait(false); } catch (Exception ex) { @@ -705,14 +707,14 @@ private async Task prepareScoreForResults() try { - await ImportScore(Score).ConfigureAwait(false); + await ImportScore(scoreCopy).ConfigureAwait(false); } catch (Exception ex) { Logger.Error(ex, @"Score import failed!"); } - return Score.ScoreInfo; + return scoreCopy.ScoreInfo; } /// diff --git a/osu.Game/Screens/Play/SoloPlayer.cs b/osu.Game/Screens/Play/SoloPlayer.cs index 7d15fcf49f..d90e8e0168 100644 --- a/osu.Game/Screens/Play/SoloPlayer.cs +++ b/osu.Game/Screens/Play/SoloPlayer.cs @@ -38,15 +38,13 @@ protected override APIRequest CreateTokenRequest() protected override APIRequest CreateSubmissionRequest(Score score, long token) { - var scoreCopy = score.DeepClone(); - - var beatmap = scoreCopy.ScoreInfo.Beatmap; + var beatmap = score.ScoreInfo.Beatmap; Debug.Assert(beatmap.OnlineBeatmapID != null); int beatmapId = beatmap.OnlineBeatmapID.Value; - return new SubmitSoloScoreRequest(beatmapId, token, scoreCopy.ScoreInfo); + return new SubmitSoloScoreRequest(beatmapId, token, score.ScoreInfo); } } } diff --git a/osu.Game/Screens/Play/SubmittingPlayer.cs b/osu.Game/Screens/Play/SubmittingPlayer.cs index 76e9f28dae..65622a4702 100644 --- a/osu.Game/Screens/Play/SubmittingPlayer.cs +++ b/osu.Game/Screens/Play/SubmittingPlayer.cs @@ -116,7 +116,7 @@ public override bool OnExiting(IScreen next) { var exiting = base.OnExiting(next); - submitScore(Score); + submitScore(Score.DeepClone()); return exiting; }