mirror of
https://github.com/osukey/osukey.git
synced 2025-08-01 21:58:46 +09:00
Move sett from EndTime to Duration
This commit is contained in:
@ -19,14 +19,14 @@ namespace osu.Game.Rulesets.Osu.Objects
|
||||
{
|
||||
public class Slider : OsuHitObject, IHasCurve
|
||||
{
|
||||
public double EndTime
|
||||
public double EndTime => StartTime + this.SpanCount() * Path.Distance / Velocity;
|
||||
|
||||
public double Duration
|
||||
{
|
||||
get => StartTime + this.SpanCount() * Path.Distance / Velocity;
|
||||
get => EndTime - StartTime;
|
||||
set => throw new System.NotSupportedException($"Adjust via {nameof(RepeatCount)} instead"); // can be implemented if/when needed.
|
||||
}
|
||||
|
||||
public double Duration => EndTime - StartTime;
|
||||
|
||||
private readonly Cached<Vector2> endPositionCache = new Cached<Vector2>();
|
||||
|
||||
public override Vector2 EndPosition => endPositionCache.IsValid ? endPositionCache.Value : endPositionCache.Value = Position + this.CurvePositionAt(1);
|
||||
|
Reference in New Issue
Block a user