mirror of
https://github.com/ppy/osu.git
synced 2024-11-11 10:07:52 +08:00
Cleanup by using const value
This commit is contained in:
parent
7d743994bc
commit
34b9118fb3
@ -43,13 +43,6 @@ namespace osu.Game.Rulesets.Osu.Difficulty.Skills
|
||||
return currentStrain;
|
||||
}
|
||||
|
||||
public override double DifficultyValue()
|
||||
{
|
||||
double difficulty = GetCurrentStrainPeaks().Sum();
|
||||
|
||||
// 1.06 comes from the default DifficultyMultiplier field in OsuStrainSkill,
|
||||
// and it's added here to keep values the same after Flashlight was converted from OsuStrainSkill.
|
||||
return difficulty * 1.06;
|
||||
}
|
||||
public override double DifficultyValue() => GetCurrentStrainPeaks().Sum() * OsuStrainSkill.DEFAULT_DIFFICULTY_MULTIPLIER;
|
||||
}
|
||||
}
|
||||
|
@ -14,6 +14,12 @@ namespace osu.Game.Rulesets.Osu.Difficulty.Skills
|
||||
{
|
||||
public abstract class OsuStrainSkill : StrainSkill
|
||||
{
|
||||
/// <summary>
|
||||
/// The default multiplier applied by <see cref="OsuStrainSkill"/> to the final difficulty value after all other calculations.
|
||||
/// May be overridden via <see cref="DifficultyMultiplier"/>.
|
||||
/// </summary>
|
||||
public const double DEFAULT_DIFFICULTY_MULTIPLIER = 1.06;
|
||||
|
||||
/// <summary>
|
||||
/// The number of sections with the highest strains, which the peak strain reductions will apply to.
|
||||
/// This is done in order to decrease their impact on the overall difficulty of the map for this skill.
|
||||
@ -28,7 +34,7 @@ namespace osu.Game.Rulesets.Osu.Difficulty.Skills
|
||||
/// <summary>
|
||||
/// The final multiplier to be applied to <see cref="DifficultyValue"/> after all other calculations.
|
||||
/// </summary>
|
||||
protected virtual double DifficultyMultiplier => 1.06;
|
||||
protected virtual double DifficultyMultiplier => DEFAULT_DIFFICULTY_MULTIPLIER;
|
||||
|
||||
protected OsuStrainSkill(Mod[] mods)
|
||||
: base(mods)
|
||||
|
Loading…
Reference in New Issue
Block a user