mirror of
https://github.com/ppy/osu.git
synced 2024-11-11 17:47:29 +08:00
Copy score during submission process to ensure it isn't modified
This commit is contained in:
parent
e507faef29
commit
caba78cb5d
@ -38,13 +38,15 @@ namespace osu.Game.Screens.Play
|
||||
|
||||
protected override APIRequest<MultiplayerScore> CreateSubmissionRequest(Score score, long token)
|
||||
{
|
||||
var beatmap = score.ScoreInfo.Beatmap;
|
||||
var scoreCopy = score.DeepClone();
|
||||
|
||||
var beatmap = scoreCopy.ScoreInfo.Beatmap;
|
||||
|
||||
Debug.Assert(beatmap.OnlineBeatmapID != null);
|
||||
|
||||
int beatmapId = beatmap.OnlineBeatmapID.Value;
|
||||
|
||||
return new SubmitSoloScoreRequest(beatmapId, token, score.ScoreInfo);
|
||||
return new SubmitSoloScoreRequest(beatmapId, token, scoreCopy.ScoreInfo);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user