Tidying up

This commit is contained in:
Adonais Romero González
2016-10-13 19:50:06 -05:00
parent 0deb5b4e22
commit 9ccff6ec48
9 changed files with 49 additions and 79 deletions

View File

@ -167,27 +167,15 @@ namespace osu.Game.Graphics.UserInterface
private void transformCount(float currentValue, float newValue)
{
if (currentValue < newValue)
for (int i = 0; i < MaxStars; i++)
{
for (int i = 0; i < MaxStars; i++)
{
stars[i].DelayReset();
stars[i].ClearTransformations();
if (i > currentValue)
stars[i].Delay((i - currentValue) * AnimationDelay);
transformStar(i, newValue);
}
}
else
{
for (int i = MaxStars - 1; i >= 0; i--)
{
stars[i].DelayReset();
stars[i].ClearTransformations();
if (i < (currentValue - 1))
stars[i].Delay((currentValue - 1 - i) * AnimationDelay);
transformStar(i, newValue);
}
stars[i].DelayReset();
stars[i].ClearTransformations();
if (currentValue <= newValue)
stars[i].Delay(Math.Max(i - currentValue, 0) * AnimationDelay);
else
stars[i].Delay(Math.Max(currentValue - 1 - i, 0) * AnimationDelay);
transformStar(i, newValue);
}
transformStartTime = Time;
}