javasweeper/Options.java
2023-05-25 19:44:14 -07:00

51 lines
1.1 KiB
Java

// Public class that stores all the global static options
public class Options {
// Directory with all the skins files
public static final String SKINS_DIR = "Skins/";
// Whether or not sound is enabled
private static boolean sound = false;
// Whether or not to force starting at 0
private static boolean protectedStart = false;
// The difficulty
private static Difficulty difficulty = Difficulty.INTERMEDIATE;
// The skin
private static String skinName = "winxpskin.bmp";
public static boolean hasSound() {
return sound;
}
public static void toggleSound() {
sound = !sound;
}
public static boolean isProtectedStart() {
return protectedStart;
}
public static void toggleProtectedStart() {
protectedStart = !protectedStart;
}
public static Difficulty getDifficulty() {
return difficulty;
}
public static void setDifficulty(Difficulty difficulty) {
Options.difficulty = difficulty;
}
public static String getSkinName() {
return skinName;
}
public static void setSkinName(String skinName) {
Options.skinName = skinName;
}
// No constructing >:(
private Options() {
}
}