1
0
mirror of https://github.com/ppy/osu.git synced 2024-12-15 04:05:35 +08:00

Fix approach rate not being transferred from OD on older beatmaps

This commit is contained in:
Dean Herbert 2022-01-28 18:53:28 +09:00
parent f021a274d2
commit 142a67e163

View File

@ -311,10 +311,13 @@ namespace osu.Game.Beatmaps.Formats
case @"OverallDifficulty": case @"OverallDifficulty":
difficulty.OverallDifficulty = Parsing.ParseFloat(pair.Value); difficulty.OverallDifficulty = Parsing.ParseFloat(pair.Value);
if (!hasApproachRate)
difficulty.ApproachRate = difficulty.OverallDifficulty;
break; break;
case @"ApproachRate": case @"ApproachRate":
difficulty.ApproachRate = Parsing.ParseFloat(pair.Value); difficulty.ApproachRate = Parsing.ParseFloat(pair.Value);
hasApproachRate = true;
break; break;
case @"SliderMultiplier": case @"SliderMultiplier":
@ -432,6 +435,7 @@ namespace osu.Game.Beatmaps.Formats
private readonly List<ControlPoint> pendingControlPoints = new List<ControlPoint>(); private readonly List<ControlPoint> pendingControlPoints = new List<ControlPoint>();
private readonly HashSet<Type> pendingControlPointTypes = new HashSet<Type>(); private readonly HashSet<Type> pendingControlPointTypes = new HashSet<Type>();
private double pendingControlPointsTime; private double pendingControlPointsTime;
private bool hasApproachRate;
private void addControlPoint(double time, ControlPoint point, bool timingChange) private void addControlPoint(double time, ControlPoint point, bool timingChange)
{ {