Back and Skip animation

removed minimum time before skip button is shown.
This commit is contained in:
fd
2015-02-17 22:03:11 -05:00
parent 987a406123
commit ffed4b260a
4 changed files with 60 additions and 29 deletions

View File

@@ -229,11 +229,21 @@ public class Utils {
DownloadNode.init(width, height);
// back button
Image back = GameImage.MENU_BACK.getImage();
backButton = new MenuButton(back,
back.getWidth() / 2f,
height - (back.getHeight() / 2f));
//TODO: this is annoying perhaps we can just pass in GameImage to MenuButton?
if (GameImage.MENU_BACK.getImages() != null){
Animation back = GameImage.MENU_BACK.getAnimation(200);
backButton = new MenuButton(back,
back.getWidth() / 2f,
height - (back.getHeight() / 2f));
}else{
Image back = GameImage.MENU_BACK.getImage();
backButton = new MenuButton(GameImage.MENU_BACK.getImage(),
back.getWidth() / 2f,
height - (back.getHeight() / 2f));
}
backButton.setHoverExpand(MenuButton.Expand.UP_RIGHT);
}
/**