mirror of
https://github.com/ppy/osu.git
synced 2025-02-20 19:23:22 +08:00
Update catcher hyper-dashing colours on changing hyper-dash state only
This commit is contained in:
parent
f3bcb0628c
commit
50604dc7b2
@ -254,7 +254,10 @@ namespace osu.Game.Rulesets.Catch.UI
|
||||
hyperDashDirection = 0;
|
||||
|
||||
if (wasHyperDashing)
|
||||
{
|
||||
updateCatcherColour(false);
|
||||
Trail &= Dashing;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
@ -264,6 +267,7 @@ namespace osu.Game.Rulesets.Catch.UI
|
||||
|
||||
if (!wasHyperDashing)
|
||||
{
|
||||
updateCatcherColour(true);
|
||||
Trail = true;
|
||||
|
||||
var hyperDashEndGlow = createAdditiveSprite(endGlowSprites);
|
||||
@ -273,15 +277,13 @@ namespace osu.Game.Rulesets.Catch.UI
|
||||
hyperDashEndGlow.Expire(true);
|
||||
}
|
||||
}
|
||||
|
||||
updateCatcherColour();
|
||||
}
|
||||
|
||||
private void updateCatcherColour()
|
||||
private void updateCatcherColour(bool hyperDashing)
|
||||
{
|
||||
const float hyper_dash_transition_length = 180;
|
||||
|
||||
if (HyperDashing)
|
||||
if (hyperDashing)
|
||||
{
|
||||
this.FadeColour(hyperDashColour == DefaultHyperDashColour ? Color4.OrangeRed : hyperDashColour, hyper_dash_transition_length, Easing.OutQuint);
|
||||
this.FadeTo(0.2f, hyper_dash_transition_length, Easing.OutQuint);
|
||||
@ -389,9 +391,9 @@ namespace osu.Game.Rulesets.Catch.UI
|
||||
{
|
||||
base.SkinChanged(skin, allowFallback);
|
||||
|
||||
updateCatcherColour();
|
||||
hyperDashColour = skin.GetHyperDashCatcherColour()?.Value ?? DefaultHyperDashColour;
|
||||
hyperDashEndGlowColour = skin.GetHyperDashEndGlowColour()?.Value ?? DefaultHyperDashColour;
|
||||
updateCatcherColour(HyperDashing);
|
||||
}
|
||||
|
||||
protected override void Update()
|
||||
|
Loading…
Reference in New Issue
Block a user