Song sort refactoring.

- Created "SongSort" enum to handle everything related to sorting OsuGroupNode objects.

Signed-off-by: Jeffrey Han <itdelatrisu@gmail.com>
This commit is contained in:
Jeffrey Han
2014-07-18 20:33:41 -04:00
parent 717605564d
commit 64788b2832
7 changed files with 235 additions and 147 deletions

View File

@@ -59,13 +59,13 @@ public enum GameMod {
/**
* Total number of mods.
*/
private static final int size = GameMod.values().length;
private static final int SIZE = GameMod.values().length;
/**
* Returns the total number of game mods.
* @return the number of mods
*/
public static int size() { return size; }
public static int size() { return SIZE; }
/**
* Returns an array of GameMod objects in reverse order.
@@ -101,7 +101,7 @@ public enum GameMod {
// find coordinates
float offsetX = img.getWidth() * 1.5f;
float x = (width / 2f) - (offsetX * size / 2.75f);
float x = (width / 2f) - (offsetX * SIZE / 2.75f);
float y = (height * 0.8f) + (img.getHeight() / 2);
// create button