mirror of
https://github.com/ppy/osu
synced 2024-12-15 11:25:29 +00:00
Write out DifficultyControlPoint
s into HitObject
s
This commit is contained in:
parent
cdd0262ca1
commit
b41b1e2394
@ -68,6 +68,8 @@ namespace osu.Game.Rulesets.Objects
|
|||||||
|
|
||||||
public SampleControlPoint SampleControlPoint;
|
public SampleControlPoint SampleControlPoint;
|
||||||
|
|
||||||
|
public DifficultyControlPoint DifficultyControlPoint;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Whether this <see cref="HitObject"/> is in Kiai time.
|
/// Whether this <see cref="HitObject"/> is in Kiai time.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
@ -110,10 +112,12 @@ namespace osu.Game.Rulesets.Objects
|
|||||||
{
|
{
|
||||||
// This is done here since ApplyDefaultsToSelf may be used to determine the end time
|
// This is done here since ApplyDefaultsToSelf may be used to determine the end time
|
||||||
SampleControlPoint = legacyInfo.SamplePointAt(this.GetEndTime() + control_point_leniency);
|
SampleControlPoint = legacyInfo.SamplePointAt(this.GetEndTime() + control_point_leniency);
|
||||||
|
DifficultyControlPoint = legacyInfo.DifficultyPointAt(StartTime);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
SampleControlPoint ??= SampleControlPoint.DEFAULT;
|
SampleControlPoint ??= SampleControlPoint.DEFAULT;
|
||||||
|
DifficultyControlPoint ??= DifficultyControlPoint.DEFAULT;
|
||||||
}
|
}
|
||||||
|
|
||||||
nestedHitObjects.Clear();
|
nestedHitObjects.Clear();
|
||||||
|
@ -43,9 +43,8 @@ namespace osu.Game.Rulesets.Objects.Legacy
|
|||||||
base.ApplyDefaultsToSelf(controlPointInfo, difficulty);
|
base.ApplyDefaultsToSelf(controlPointInfo, difficulty);
|
||||||
|
|
||||||
TimingControlPoint timingPoint = controlPointInfo.TimingPointAt(StartTime);
|
TimingControlPoint timingPoint = controlPointInfo.TimingPointAt(StartTime);
|
||||||
DifficultyControlPoint difficultyPoint = controlPointInfo.DifficultyPointAt(StartTime);
|
|
||||||
|
|
||||||
double scoringDistance = base_scoring_distance * difficulty.SliderMultiplier * difficultyPoint.SpeedMultiplier;
|
double scoringDistance = base_scoring_distance * difficulty.SliderMultiplier * DifficultyControlPoint.SpeedMultiplier;
|
||||||
|
|
||||||
Velocity = scoringDistance / timingPoint.BeatLength;
|
Velocity = scoringDistance / timingPoint.BeatLength;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user