1
0
mirror of https://github.com/ppy/osu.git synced 2025-01-12 16:02:55 +08:00

Fix adding null hit explosions

This commit is contained in:
smoogipoo 2020-04-02 15:27:31 +09:00
parent fa3a449c3b
commit de7ee57100

View File

@ -32,7 +32,7 @@ namespace osu.Game.Rulesets.Mania.Skinning
float explosionScale = GetManiaSkinConfig<float>(skin, LegacyManiaSkinConfigurationLookups.ExplosionScale)?.Value
?? 1;
InternalChild = explosion = skin.GetAnimation(imageName, true, false, startAtCurrentTime: true).With(d =>
explosion = skin.GetAnimation(imageName, true, false, startAtCurrentTime: true).With(d =>
{
if (d == null)
return;
@ -48,6 +48,9 @@ namespace osu.Game.Rulesets.Mania.Skinning
texAnimation.DefaultFrameLength = Math.Max(texAnimation.DefaultFrameLength, 170.0 / texAnimation.FrameCount);
});
if (explosion != null)
InternalChild = explosion;
direction.BindTo(scrollingInfo.Direction);
direction.BindValueChanged(onDirectionChanged, true);
}