mirror of
https://github.com/BentoBoxWorld/BentoBox.git
synced 2024-12-21 08:37:50 +01:00
Removed GameType in Constants (useless)
This commit is contained in:
parent
2210cdc2e8
commit
84515642bf
@ -5,13 +5,6 @@ package world.bentobox.bentobox;
|
||||
* @author tastybento
|
||||
*/
|
||||
public class Constants {
|
||||
// ----------------- Constants -----------------
|
||||
// Game Type BSKYBLOCK or ACIDISLAND
|
||||
public enum GameType {
|
||||
BSKYBLOCK, ACIDISLAND, BOTH
|
||||
}
|
||||
|
||||
public static final GameType GAMETYPE = GameType.BSKYBLOCK;
|
||||
// The spawn command (Essentials spawn for example)
|
||||
public static final String SPAWNCOMMAND = "spawn";
|
||||
}
|
@ -5,11 +5,7 @@ import java.lang.annotation.Retention;
|
||||
import java.lang.annotation.RetentionPolicy;
|
||||
import java.lang.annotation.Target;
|
||||
|
||||
import world.bentobox.bentobox.Constants.GameType;
|
||||
|
||||
/**
|
||||
*
|
||||
*
|
||||
* @author Poslovitch, tastybento
|
||||
*/
|
||||
@Retention(RetentionPolicy.RUNTIME)
|
||||
@ -21,6 +17,4 @@ public @interface ConfigEntry {
|
||||
boolean overrideOnChange() default false;
|
||||
boolean experimental() default false;
|
||||
boolean needsReset() default false;
|
||||
GameType specificTo() default GameType.BOTH;
|
||||
|
||||
}
|
@ -28,8 +28,6 @@ import org.bukkit.configuration.MemorySection;
|
||||
import org.bukkit.configuration.file.YamlConfiguration;
|
||||
|
||||
import world.bentobox.bentobox.BentoBox;
|
||||
import world.bentobox.bentobox.Constants;
|
||||
import world.bentobox.bentobox.Constants.GameType;
|
||||
import world.bentobox.bentobox.api.configuration.ConfigComment;
|
||||
import world.bentobox.bentobox.api.configuration.ConfigEntry;
|
||||
import world.bentobox.bentobox.api.configuration.StoreAt;
|
||||
@ -127,9 +125,6 @@ public class FlatFileDatabaseHandler<T> extends AbstractDatabaseHandler<T> {
|
||||
if (!configEntry.path().isEmpty()) {
|
||||
storageLocation = configEntry.path();
|
||||
}
|
||||
if (!configEntry.specificTo().equals(GameType.BOTH) && !configEntry.specificTo().equals(Constants.GAMETYPE)) {
|
||||
continue;
|
||||
}
|
||||
// TODO: Add handling of other ConfigEntry elements
|
||||
}
|
||||
Adapter adapterNotation = field.getAnnotation(Adapter.class);
|
||||
@ -286,9 +281,6 @@ public class FlatFileDatabaseHandler<T> extends AbstractDatabaseHandler<T> {
|
||||
ConfigEntry configEntry = field.getAnnotation(ConfigEntry.class);
|
||||
// If there is a config path annotation then do something
|
||||
if (configEntry != null) {
|
||||
if (!configEntry.specificTo().equals(GameType.BOTH) && !configEntry.specificTo().equals(Constants.GAMETYPE)) {
|
||||
continue;
|
||||
}
|
||||
if (!configEntry.path().isEmpty()) {
|
||||
storageLocation = configEntry.path();
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user