Skip to content

Commit

Permalink
Don't draw the loader unless track loading is actually noticeably long.
Browse files Browse the repository at this point in the history
Signed-off-by: Jeffrey Han <[email protected]>
  • Loading branch information
itdelatrisu committed Jan 12, 2017
1 parent 0a22d60 commit 6733420
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/itdelatrisu/opsu/states/SongMenu.java
Original file line number Diff line number Diff line change
Expand Up @@ -621,7 +621,7 @@ public void render(GameContainer container, StateBasedGame game, Graphics g)
// music/loader icon
float marginX = width * 0.005f, marginY = height * 0.005f;
Image musicNote = GameImage.MENU_MUSICNOTE.getImage();
if (MusicController.isTrackLoading())
if (MusicController.isTrackLoading() && musicIconBounceTimer.isFinished())
loader.draw(marginX, marginY);
else {
float t = musicIconBounceTimer.getValue() * 2f;
Expand Down Expand Up @@ -826,8 +826,7 @@ else if (reloadThread.isFinished()) {

// song change timers
songChangeTimer.update(delta);
if (!MusicController.isTrackLoading())
musicIconBounceTimer.update(delta);
musicIconBounceTimer.update(delta);
}

// star stream
Expand Down

0 comments on commit 6733420

Please sign in to comment.