osu/osu.Game.Rulesets.Mania/Skinning/Legacy
Bartłomiej Dach bf0040447c
Fix legacy mania note body animation not resetting sometimes
Hopefully closes https://github.com/ppy/osu/issues/28284.

As far as I can tell this is a somewhat difficult one to reproduce
because it relies on a specific set of circumstances (at least the
reproduction case that I found does). The reset to frame 0 would
previously be called explicitly when `isHitting` changed:

    182ca145c7/osu.Game.Rulesets.Mania/Skinning/Legacy/LegacyBodyPiece.cs (L144)

However, it can be the case that `bodyAnimation` is not loaded at the
point of this call. This is significant because
`SkinnableTextureAnimation` contains this logic:

    182ca145c7/osu.Game/Skinning/LegacySkinExtensions.cs (L192-L211)

which cannot be moved any earlier (because any earlier the `Clock` may
no longer be correct), and also causes the animation to be seeked
forward while it is stopped.

I can't figure out a decent way to layer this otherwise (by scheduling
or whatever), so this commit is just applying the nuclear option of just
seeking back to frame 0 on every update frame in which the body piece is
not being hit.
2024-05-28 15:29:15 +02:00
..
HitTargetInsetContainer.cs Partial everything 2022-11-27 00:00:27 +09:00
LegacyBodyPiece.cs Fix legacy mania note body animation not resetting sometimes 2024-05-28 15:29:15 +02:00
LegacyColumnBackground.cs Fix incorrect nullability specification 2023-10-21 01:10:06 +03:00
LegacyHitExplosion.cs Remove unused usings 2023-10-09 12:22:08 +09:00
LegacyHitTarget.cs Partial everything 2022-11-27 00:00:27 +09:00
LegacyHoldNoteHeadPiece.cs Partial everything 2022-11-27 00:00:27 +09:00
LegacyHoldNoteTailPiece.cs Partial everything 2022-11-27 00:00:27 +09:00
LegacyKeyArea.cs Clamp only on horizontal sides 2024-03-06 18:40:20 +03:00
LegacyManiaColumnElement.cs Fix fallback column colors for legacy split stage mania skins 2023-12-15 22:41:55 -08:00
LegacyManiaJudgementPiece.cs Partial everything 2022-11-27 00:00:27 +09:00
LegacyNotePiece.cs Partial everything 2022-11-27 00:00:27 +09:00
LegacyStageBackground.cs Partial everything 2022-11-27 00:00:27 +09:00
LegacyStageForeground.cs Partial everything 2022-11-27 00:00:27 +09:00
ManiaClassicSkinTransformer.cs Apply nullability to osu!mania skinning classes 2022-11-09 13:58:58 +09:00
ManiaLegacySkinTransformer.cs Adjust frame length of osu!mania judgement animation 2023-10-20 23:59:03 +03:00