mirror of
https://github.com/osukey/osukey.git
synced 2025-08-03 22:56:36 +09:00
Merge pull request #9573 from smoogipoo/taiko-diffcalc-fixes-2
This commit is contained in:
@ -57,7 +57,7 @@ namespace osu.Game.Beatmaps
|
||||
|
||||
beatmap.BeatmapInfo = original.BeatmapInfo;
|
||||
beatmap.ControlPointInfo = original.ControlPointInfo;
|
||||
beatmap.HitObjects = convertHitObjects(original.HitObjects, original);
|
||||
beatmap.HitObjects = convertHitObjects(original.HitObjects, original).OrderBy(s => s.StartTime).ToList();
|
||||
beatmap.Breaks = original.Breaks;
|
||||
|
||||
return beatmap;
|
||||
|
@ -369,7 +369,9 @@ namespace osu.Game.Beatmaps.Formats
|
||||
addControlPoint(time, controlPoint, true);
|
||||
}
|
||||
|
||||
addControlPoint(time, new LegacyDifficultyControlPoint
|
||||
#pragma warning disable 618
|
||||
addControlPoint(time, new LegacyDifficultyControlPoint(beatLength)
|
||||
#pragma warning restore 618
|
||||
{
|
||||
SpeedMultiplier = speedMultiplier,
|
||||
}, timingChange);
|
||||
|
@ -159,11 +159,20 @@ namespace osu.Game.Beatmaps.Formats
|
||||
Mania,
|
||||
}
|
||||
|
||||
internal class LegacyDifficultyControlPoint : DifficultyControlPoint
|
||||
[Obsolete("Do not use unless you're a legacy ruleset and 100% sure.")]
|
||||
public class LegacyDifficultyControlPoint : DifficultyControlPoint
|
||||
{
|
||||
public LegacyDifficultyControlPoint()
|
||||
/// <summary>
|
||||
/// Legacy BPM multiplier that introduces floating-point errors for rulesets that depend on it.
|
||||
/// DO NOT USE THIS UNLESS 100% SURE.
|
||||
/// </summary>
|
||||
public readonly float BpmMultiplier;
|
||||
|
||||
public LegacyDifficultyControlPoint(double beatLength)
|
||||
{
|
||||
SpeedMultiplierBindable.Precision = double.Epsilon;
|
||||
|
||||
BpmMultiplier = beatLength < 0 ? Math.Clamp((float)-beatLength, 10, 10000) / 100f : 1;
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user