mirror of
https://github.com/osukey/osukey.git
synced 2025-08-05 07:33:55 +09:00
replace easement with easing
This commit is contained in:
@ -17,7 +17,7 @@ namespace osu.Game.Rulesets.Osu.Tests.Mods
|
||||
{
|
||||
Mod = new OsuModMagnetised
|
||||
{
|
||||
EasementStrength = { Value = strength },
|
||||
EasingStrength = { Value = strength },
|
||||
},
|
||||
PassCondition = () => true,
|
||||
Autoplay = false,
|
||||
|
@ -17,7 +17,7 @@ namespace osu.Game.Rulesets.Osu.Tests.Mods
|
||||
{
|
||||
Mod = new OsuModRepel
|
||||
{
|
||||
EasementStrength = { Value = strength },
|
||||
EasingStrength = { Value = strength },
|
||||
},
|
||||
PassCondition = () => true,
|
||||
Autoplay = false,
|
||||
|
@ -20,8 +20,8 @@ namespace osu.Game.Rulesets.Osu.Mods
|
||||
public override double ScoreMultiplier => 1;
|
||||
public override Type[] IncompatibleMods => new[] { typeof(OsuModAutopilot), typeof(OsuModWiggle), typeof(OsuModTransform), typeof(ModAutoplay) };
|
||||
|
||||
public abstract BindableFloat EasementStrength { get; }
|
||||
protected virtual float EasementStrengthMultiplier => 1.0f;
|
||||
public abstract BindableFloat EasingStrength { get; }
|
||||
protected virtual float EasingStrengthMultiplier => 1.0f;
|
||||
protected Vector2 CursorPosition;
|
||||
protected DrawableHitObject WorkingHitObject;
|
||||
protected abstract Vector2 DestinationVector { get; }
|
||||
@ -66,7 +66,7 @@ namespace osu.Game.Rulesets.Osu.Mods
|
||||
|
||||
private void easeHitObjectPositionToVector(DrawableHitObject hitObject, Vector2 destination)
|
||||
{
|
||||
double dampLength = Interpolation.Lerp(3000, 40, EasementStrength.Value * EasementStrengthMultiplier);
|
||||
double dampLength = Interpolation.Lerp(3000, 40, EasingStrength.Value * EasingStrengthMultiplier);
|
||||
|
||||
float x = (float)Interpolation.DampContinuously(hitObject.X, destination.X, dampLength, gameplayClock.ElapsedFrameTime);
|
||||
float y = (float)Interpolation.DampContinuously(hitObject.Y, destination.Y, dampLength, gameplayClock.ElapsedFrameTime);
|
||||
|
@ -21,7 +21,7 @@ namespace osu.Game.Rulesets.Osu.Mods
|
||||
protected override Vector2 DestinationVector => CursorPosition;
|
||||
|
||||
[SettingSource("Attraction strength", "How strong the pull is.", 0)]
|
||||
public override BindableFloat EasementStrength { get; } = new BindableFloat(0.5f)
|
||||
public override BindableFloat EasingStrength { get; } = new BindableFloat(0.5f)
|
||||
{
|
||||
Precision = 0.05f,
|
||||
MinValue = 0.05f,
|
||||
|
@ -20,14 +20,14 @@ namespace osu.Game.Rulesets.Osu.Mods
|
||||
public override Type[] IncompatibleMods => base.IncompatibleMods.Append(typeof(OsuModMagnetised)).ToArray();
|
||||
|
||||
[SettingSource("Repulsion strength", "How strong the repulsion is.", 0)]
|
||||
public override BindableFloat EasementStrength { get; } = new BindableFloat(0.6f)
|
||||
public override BindableFloat EasingStrength { get; } = new BindableFloat(0.6f)
|
||||
{
|
||||
Precision = 0.05f,
|
||||
MinValue = 0.05f,
|
||||
MaxValue = 1.0f,
|
||||
};
|
||||
|
||||
protected override float EasementStrengthMultiplier => 0.8f;
|
||||
protected override float EasingStrengthMultiplier => 0.8f;
|
||||
|
||||
protected override Vector2 DestinationVector
|
||||
{
|
||||
|
Reference in New Issue
Block a user