Make JuiceStreamPath time based instead of distance based.

And remove the "slope limit" feature.
TODO: for a juice stream with a large slope, the slider velocity of the hit object should be changed.
This commit is contained in:
ekrctb
2022-05-08 18:32:01 +09:00
parent dabe295196
commit 4e0155fa4b
9 changed files with 157 additions and 178 deletions

View File

@ -12,22 +12,22 @@ namespace osu.Game.Rulesets.Catch.Objects
/// </summary>
public readonly struct JuiceStreamPathVertex : IComparable<JuiceStreamPathVertex>
{
public readonly double Distance;
public readonly double Time;
public readonly float X;
public JuiceStreamPathVertex(double distance, float x)
public JuiceStreamPathVertex(double time, float x)
{
Distance = distance;
Time = time;
X = x;
}
public int CompareTo(JuiceStreamPathVertex other)
{
int c = Distance.CompareTo(other.Distance);
int c = Time.CompareTo(other.Time);
return c != 0 ? c : X.CompareTo(other.X);
}
public override string ToString() => $"({Distance}, {X})";
public override string ToString() => $"({Time}, {X})";
}
}