1
0
mirror of https://github.com/ppy/osu.git synced 2024-12-14 13:22:55 +08:00

return to use if for casting

This commit is contained in:
mcendu 2020-02-09 14:56:47 +08:00
parent 596f4f7d2e
commit e78d94d469
No known key found for this signature in database
GPG Key ID: FBCD5D45163D6364

View File

@ -33,9 +33,7 @@ namespace osu.Game.Rulesets.Osu.Mods
spinner.Disc.Enabled = false;
spinner.Disc.OnUpdate += d =>
{
var s = d as SpinnerDisc;
if (s.Valid)
if (d is SpinnerDisc s && s.Valid)
s.Rotate(180 / MathF.PI * (float)s.Clock.ElapsedFrameTime / 40);
};
}