Move follow circle tracking to DrawableSliderHead

This commit is contained in:
smoogipoo
2021-02-05 17:33:48 +09:00
parent ee3367d7c5
commit a5855f5d28
4 changed files with 18 additions and 13 deletions

View File

@ -22,6 +22,12 @@ namespace osu.Game.Rulesets.Osu.Objects.Drawables
public override bool DisplayResult => HitObject?.JudgeAsNormalHitCircle ?? base.DisplayResult;
/// <summary>
/// Makes this <see cref="DrawableSliderHead"/> track the follow circle when the start time is reached.
/// If <c>false</c>, this <see cref="DrawableSliderHead"/> will be pinned to its initial position in the slider.
/// </summary>
public bool TrackFollowCircle = true;
private readonly IBindable<int> pathVersion = new Bindable<int>();
protected override OsuSkinComponents CirclePieceComponent => OsuSkinComponents.SliderHeadHitCircle;
@ -66,7 +72,7 @@ namespace osu.Game.Rulesets.Osu.Objects.Drawables
Debug.Assert(Slider != null);
Debug.Assert(HitObject != null);
if (HitObject.TrackFollowCircle)
if (TrackFollowCircle)
{
double completionProgress = Math.Clamp((Time.Current - Slider.StartTime) / Slider.Duration, 0, 1);