mirror of
https://github.com/ppy/osu.git
synced 2025-03-01 11:33:03 +08:00
Merge pull request #31390 from peppy/slider-end-suppress-fix
Fix slider end circles not remaining for long enough when hit animations disabled
This commit is contained in:
commit
d2918894a0
@ -626,7 +626,7 @@ namespace osu.Game.Rulesets.Osu.Edit.Blueprints.Sliders
|
|||||||
|
|
||||||
public override bool ReceivePositionalInputAt(Vector2 screenSpacePos)
|
public override bool ReceivePositionalInputAt(Vector2 screenSpacePos)
|
||||||
{
|
{
|
||||||
if (BodyPiece.ReceivePositionalInputAt(screenSpacePos))
|
if (BodyPiece.ReceivePositionalInputAt(screenSpacePos) && DrawableObject.Body.Alpha > 0)
|
||||||
return true;
|
return true;
|
||||||
|
|
||||||
if (ControlPointVisualiser == null)
|
if (ControlPointVisualiser == null)
|
||||||
|
@ -382,6 +382,19 @@ namespace osu.Game.Rulesets.Osu.Objects.Drawables
|
|||||||
repeat.SuppressHitAnimations();
|
repeat.SuppressHitAnimations();
|
||||||
|
|
||||||
TailCircle.SuppressHitAnimations();
|
TailCircle.SuppressHitAnimations();
|
||||||
|
|
||||||
|
// This method is called every frame in editor contexts, thus the lack of need for transforms.
|
||||||
|
|
||||||
|
if (Time.Current >= HitStateUpdateTime)
|
||||||
|
{
|
||||||
|
// Apply the slider's alpha to *only* the body.
|
||||||
|
// This allows start and – more importantly – end circles to fade slower than the overall slider.
|
||||||
|
if (Alpha < 1)
|
||||||
|
Body.Alpha = Alpha;
|
||||||
|
Alpha = 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
LifetimeEnd = HitStateUpdateTime + 700;
|
||||||
}
|
}
|
||||||
|
|
||||||
internal void RestoreHitAnimations()
|
internal void RestoreHitAnimations()
|
||||||
|
Loading…
Reference in New Issue
Block a user