changed decay system to allow for customizing the currentStrain

This commit is contained in:
Xexxar
2021-08-16 22:14:29 +00:00
parent 7d46b3f9c5
commit 176b3e7533
10 changed files with 83 additions and 54 deletions

View File

@ -12,7 +12,7 @@ namespace osu.Game.Rulesets.Osu.Difficulty.Skills
/// <summary>
/// Represents the skill required to correctly aim at every object in the map with a uniform CircleSize and normalized distances.
/// </summary>
public class Aim : OsuStrainSkill
public class Aim : OsuStrainDecaySkill
{
private const double angle_bonus_begin = Math.PI / 3;
private const double timing_threshold = 107;

View File

@ -10,7 +10,7 @@ using osu.Framework.Utils;
namespace osu.Game.Rulesets.Osu.Difficulty.Skills
{
public abstract class OsuStrainSkill : StrainSkill
public abstract class OsuStrainDecaySkill : StrainDecaySkill
{
/// <summary>
/// The number of sections with the highest strains, which the peak strain reductions will apply to.
@ -28,7 +28,7 @@ namespace osu.Game.Rulesets.Osu.Difficulty.Skills
/// </summary>
protected virtual double DifficultyMultiplier => 1.06;
protected OsuStrainSkill(Mod[] mods)
protected OsuStrainDecaySkill(Mod[] mods)
: base(mods)
{
}

View File

@ -12,7 +12,7 @@ namespace osu.Game.Rulesets.Osu.Difficulty.Skills
/// <summary>
/// Represents the skill required to press keys with regards to keeping up with the speed at which objects need to be hit.
/// </summary>
public class Speed : OsuStrainSkill
public class Speed : OsuStrainDecaySkill
{
private const double single_spacing_threshold = 125;
@ -151,14 +151,5 @@ namespace osu.Game.Rulesets.Osu.Difficulty.Skills
return (1 + (speedBonus - 1) * 0.75) * angleBonus * (0.95 + speedBonus * Math.Pow(distance / single_spacing_threshold, 3.5)) / osuCurrent.StrainTime;
}
protected override double GetTotalCurrentStrain(DifficultyHitObject current)
{
return base.GetTotalCurrentStrain(current) * calculateRhythmBonus(current.StartTime);
}
protected override double GetPeakStrain(double time)
{
return base.GetPeakStrain(time);// * calculateRhythmBonus(current.StartTime);
}
}
}