mirror of
https://github.com/ppy/osu.git
synced 2025-01-07 22:22:59 +08:00
Finish internal counter transformation regardless of the combo
This commit is contained in:
parent
deb5cc752b
commit
7ae45b29db
@ -27,7 +27,6 @@ namespace osu.Game.Rulesets.Catch.Skinning
|
|||||||
private readonly float fontOverlap;
|
private readonly float fontOverlap;
|
||||||
|
|
||||||
private readonly LegacyRollingCounter counter;
|
private readonly LegacyRollingCounter counter;
|
||||||
private LegacyRollingCounter lastExplosion;
|
|
||||||
|
|
||||||
public LegacyComboCounter(ISkin skin, string fontName, float fontOverlap)
|
public LegacyComboCounter(ISkin skin, string fontName, float fontOverlap)
|
||||||
{
|
{
|
||||||
@ -70,8 +69,14 @@ namespace osu.Game.Rulesets.Catch.Skinning
|
|||||||
public void DisplayInitialCombo(int combo) => updateCombo(combo, null, true);
|
public void DisplayInitialCombo(int combo) => updateCombo(combo, null, true);
|
||||||
public void UpdateCombo(int combo, Color4? hitObjectColour) => updateCombo(combo, hitObjectColour, false);
|
public void UpdateCombo(int combo, Color4? hitObjectColour) => updateCombo(combo, hitObjectColour, false);
|
||||||
|
|
||||||
|
private LegacyRollingCounter lastExplosion;
|
||||||
|
|
||||||
private void updateCombo(int combo, Color4? hitObjectColour, bool immediate)
|
private void updateCombo(int combo, Color4? hitObjectColour, bool immediate)
|
||||||
{
|
{
|
||||||
|
// There may still be existing transforms to the counter (including value change after 250ms),
|
||||||
|
// finish them immediately before new transforms.
|
||||||
|
counter.FinishTransforms();
|
||||||
|
|
||||||
// Combo fell to zero, roll down and fade out the counter.
|
// Combo fell to zero, roll down and fade out the counter.
|
||||||
if (combo == 0)
|
if (combo == 0)
|
||||||
{
|
{
|
||||||
@ -83,8 +88,7 @@ namespace osu.Game.Rulesets.Catch.Skinning
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
// There may still be previous transforms being applied, finish them and remove explosion.
|
// Remove last explosion to not conflict with the upcoming one.
|
||||||
FinishTransforms(true);
|
|
||||||
if (lastExplosion != null)
|
if (lastExplosion != null)
|
||||||
RemoveInternal(lastExplosion);
|
RemoveInternal(lastExplosion);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user