mirror of
https://github.com/ppy/osu.git
synced 2024-12-13 08:32:57 +08:00
Make animation start at the slider's start time
This commit is contained in:
parent
683ac6f63a
commit
27e55def64
@ -1,6 +1,7 @@
|
|||||||
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
|
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
|
||||||
// See the LICENCE file in the repository root for full licence text.
|
// See the LICENCE file in the repository root for full licence text.
|
||||||
|
|
||||||
|
using System;
|
||||||
using System.Diagnostics;
|
using System.Diagnostics;
|
||||||
using osu.Framework.Allocation;
|
using osu.Framework.Allocation;
|
||||||
using osu.Framework.Graphics;
|
using osu.Framework.Graphics;
|
||||||
@ -26,13 +27,17 @@ namespace osu.Game.Rulesets.Osu.Skinning
|
|||||||
((DrawableSlider?)ParentObject)?.Tracking.BindValueChanged(tracking =>
|
((DrawableSlider?)ParentObject)?.Tracking.BindValueChanged(tracking =>
|
||||||
{
|
{
|
||||||
Debug.Assert(ParentObject != null);
|
Debug.Assert(ParentObject != null);
|
||||||
|
|
||||||
if (ParentObject.Judged)
|
if (ParentObject.Judged)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
if (tracking.NewValue)
|
using (BeginAbsoluteSequence(Math.Max(Time.Current, ParentObject.HitObject?.StartTime ?? 0)))
|
||||||
OnSliderPress();
|
{
|
||||||
else
|
if (tracking.NewValue)
|
||||||
OnSliderRelease();
|
OnSliderPress();
|
||||||
|
else
|
||||||
|
OnSliderRelease();
|
||||||
|
}
|
||||||
}, true);
|
}, true);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user