mirror of https://github.com/ppy/osu
Move cloning local to editor
This commit is contained in:
parent
f054b38105
commit
4ac362ee1a
|
@ -111,8 +111,6 @@ public IBeatmap GetPlayableBeatmap(RulesetInfo ruleset, IReadOnlyList<Mod> mods
|
|||
// Convert
|
||||
IBeatmap converted = converter.Convert(cancellationSource.Token);
|
||||
|
||||
converted.ControlPointInfo = converted.ControlPointInfo.CreateCopy();
|
||||
|
||||
// Apply conversion mods to the result
|
||||
foreach (var mod in mods.OfType<IApplicableAfterBeatmapConversion>())
|
||||
{
|
||||
|
|
|
@ -131,6 +131,10 @@ private void load(OsuColour colours, GameHost host, OsuConfigManager config)
|
|||
try
|
||||
{
|
||||
playableBeatmap = Beatmap.Value.GetPlayableBeatmap(Beatmap.Value.BeatmapInfo.Ruleset);
|
||||
|
||||
// clone these locally for now to avoid incurring overhead on GetPlayableBeatmap usages.
|
||||
// eventually we will want to improve how/where this is done as there are issues with *not* cloning it in all cases.
|
||||
playableBeatmap.ControlPointInfo = playableBeatmap.ControlPointInfo.CreateCopy();
|
||||
}
|
||||
catch (Exception e)
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue