also animate logo shrink when a song is playing

This commit is contained in:
yugecin
2018-06-26 22:44:50 +02:00
parent 8d7b7ef567
commit fcf5fc5eaf

View File

@@ -265,12 +265,12 @@ public class MainMenu extends BaseOpsuState {
boolean renderPiece = position != null;
if (position == null) {
position = System.currentTimeMillis() % 1000 / 1000f;
}
if (position < 0.05f) {
position = 1f - AnimationEquation.IN_CUBIC.calc(position / 0.05f);
} else {
position = (position - 0.05f) / 0.95f;
}
}
logo.draw(color, 0.9726f + position * 0.0274f);
final float hoverScale = logo.getCurrentHoverExpandValue();
if (renderPiece) {