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

Split out into own method

This commit is contained in:
Dean Herbert 2019-12-27 11:37:05 +09:00
parent 380c3161f1
commit cfa1dfa1a4

View File

@ -25,28 +25,33 @@ namespace osu.Game.Rulesets.Mania.Skinning
switch (component) switch (component)
{ {
case GameplaySkinComponent<HitResult> resultComponent: case GameplaySkinComponent<HitResult> resultComponent:
switch (resultComponent.Component) return getResult(resultComponent);
{ }
case HitResult.Miss:
return this.GetAnimation("mania-hit0", true, true);
case HitResult.Meh: return null;
return this.GetAnimation("mania-hit50", true, true); }
case HitResult.Ok: private Drawable getResult(GameplaySkinComponent<HitResult> resultComponent)
return this.GetAnimation("mania-hit100", true, true); {
switch (resultComponent.Component)
{
case HitResult.Miss:
return this.GetAnimation("mania-hit0", true, true);
case HitResult.Good: case HitResult.Meh:
return this.GetAnimation("mania-hit200", true, true); return this.GetAnimation("mania-hit50", true, true);
case HitResult.Great: case HitResult.Ok:
return this.GetAnimation("mania-hit300", true, true); return this.GetAnimation("mania-hit100", true, true);
case HitResult.Perfect: case HitResult.Good:
return this.GetAnimation("mania-hit300g", true, true); return this.GetAnimation("mania-hit200", true, true);
}
break; case HitResult.Great:
return this.GetAnimation("mania-hit300", true, true);
case HitResult.Perfect:
return this.GetAnimation("mania-hit300g", true, true);
} }
return null; return null;