diff --git a/src/main/java/com/songoda/skyblock/SkyBlock.java b/src/main/java/com/songoda/skyblock/SkyBlock.java index ab617ea7..bdf4b38f 100644 --- a/src/main/java/com/songoda/skyblock/SkyBlock.java +++ b/src/main/java/com/songoda/skyblock/SkyBlock.java @@ -65,7 +65,7 @@ public class SkyBlock extends SongodaPlugin { private static SkyBlock INSTANCE; private FileManager fileManager; - private WorldManager worldManager; + private final WorldManager worldManager = new WorldManager(this); private UserCacheManager userCacheManager; private VisitManager visitManager; private BanManager banManager; @@ -166,7 +166,7 @@ public class SkyBlock extends SongodaPlugin { permissionManager = new PermissionManager(this); localizationManager = new LocalizationManager(); - worldManager = new WorldManager(this); + worldManager.loadWorlds(); userCacheManager = new UserCacheManager(this); visitManager = new VisitManager(this); banManager = new BanManager(this); @@ -184,7 +184,6 @@ public class SkyBlock extends SongodaPlugin { structureManager = new StructureManager(this); soundManager = new SoundManager(this); - if (this.config.getBoolean("Island.Generator.Enable")) { generatorManager = new GeneratorManager(this); } @@ -206,7 +205,6 @@ public class SkyBlock extends SongodaPlugin { bankManager = new BankManager(this); - if (this.config.getBoolean("Island.Task.PlaytimeTask")) { new PlaytimeTask(playerDataManager, islandManager).runTaskTimerAsynchronously(this, 0L, 20L); } @@ -323,7 +321,6 @@ public class SkyBlock extends SongodaPlugin { return null; } - private boolean loadConfigs() { try { biomes = this.getFileManager().getConfig(new File(this.getDataFolder(), "biomes.yml")).getFileConfiguration(); @@ -500,7 +497,6 @@ public class SkyBlock extends SongodaPlugin { return economyManager; } - public FileConfiguration getBiomes() { return biomes; } @@ -556,5 +552,4 @@ public class SkyBlock extends SongodaPlugin { public FileConfiguration getScoreboard() { return scoreboard; } - } diff --git a/src/main/java/com/songoda/skyblock/world/WorldManager.java b/src/main/java/com/songoda/skyblock/world/WorldManager.java index a08d7754..85604e56 100644 --- a/src/main/java/com/songoda/skyblock/world/WorldManager.java +++ b/src/main/java/com/songoda/skyblock/world/WorldManager.java @@ -25,8 +25,6 @@ public class WorldManager { public WorldManager(SkyBlock plugin) { this.plugin = plugin; - - loadWorlds(); } public void loadWorlds() {