mirror of
https://github.com/osukey/osukey.git
synced 2025-08-07 00:23:59 +09:00
Fix large transform retention when adjusting accent colour of hitobject during pause
This commit is contained in:
@ -121,12 +121,16 @@ namespace osu.Game.Rulesets.Osu.Skinning.Argon
|
|||||||
innerGradient.Colour = ColourInfo.GradientVertical(colour.NewValue.Darken(0.5f), colour.NewValue.Darken(0.6f));
|
innerGradient.Colour = ColourInfo.GradientVertical(colour.NewValue.Darken(0.5f), colour.NewValue.Darken(0.6f));
|
||||||
flash.Colour = colour.NewValue;
|
flash.Colour = colour.NewValue;
|
||||||
|
|
||||||
updateStateTransforms(drawableObject, drawableObject.State.Value);
|
// Accent colour may be changed many times during a paused gameplay state.
|
||||||
|
// Schedule the change to avoid transforms piling up.
|
||||||
|
Scheduler.AddOnce(updateStateTransforms);
|
||||||
}, true);
|
}, true);
|
||||||
|
|
||||||
drawableObject.ApplyCustomUpdateState += updateStateTransforms;
|
drawableObject.ApplyCustomUpdateState += updateStateTransforms;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private void updateStateTransforms() => updateStateTransforms(drawableObject, drawableObject.State.Value);
|
||||||
|
|
||||||
private void updateStateTransforms(DrawableHitObject drawableHitObject, ArmedState state)
|
private void updateStateTransforms(DrawableHitObject drawableHitObject, ArmedState state)
|
||||||
{
|
{
|
||||||
using (BeginAbsoluteSequence(drawableObject.HitStateUpdateTime))
|
using (BeginAbsoluteSequence(drawableObject.HitStateUpdateTime))
|
||||||
|
Reference in New Issue
Block a user