mirror of
https://github.com/trainerlord/WorldSystem.git
synced 2025-01-05 18:37:48 +01:00
Implemented #51
This commit is contained in:
parent
7a3a9da15f
commit
14a5dd7657
@ -68,7 +68,7 @@ public class WorldSystem extends JavaPlugin {
|
||||
MessageConfig.checkConfig(new File(languages, "zh.yml"));
|
||||
MessageConfig.checkConfig(new File(languages, "fr.yml"));
|
||||
|
||||
// If has custom language
|
||||
// If has custom language
|
||||
MessageConfig.checkConfig(new File(languages, PluginConfig.getLanguage() + ".yml"));
|
||||
|
||||
if (!dconfig.exists()) {
|
||||
@ -164,7 +164,8 @@ public class WorldSystem extends JavaPlugin {
|
||||
|
||||
// Choose right creatoradapter for #16
|
||||
if (Bukkit.getPluginManager().getPlugin("FastAsyncWorldEdit") != null
|
||||
&& Bukkit.getPluginManager().getPlugin("WorldEdit") != null) {
|
||||
&& Bukkit.getPluginManager().getPlugin("WorldEdit") != null
|
||||
&& PluginConfig.loadWorldsASync()) {
|
||||
creator = new AsyncCreatorAdapter();
|
||||
Bukkit.getConsoleSender()
|
||||
.sendMessage(PluginConfig.getPrefix() + "Found FAWE! Try now to create worlds async");
|
||||
|
@ -36,7 +36,7 @@ public class PluginConfig {
|
||||
&& cfg.isInt("request_expires") && cfg.isBoolean("need_confirm")
|
||||
&& cfg.isBoolean("contact_authserver") && cfg.isBoolean("spawn_teleportation")
|
||||
&& cfg.isInt("delete_after") && cfg.isBoolean("worldtemplates.multi_choose")
|
||||
&& cfg.isString("worldtemplates.default") &&
|
||||
&& cfg.isString("worldtemplates.default") && cfg.isBoolean("load_worlds_async") &&
|
||||
|
||||
// Database stuff
|
||||
cfg.isString("database.type") && cfg.isString("database.worlds_table_name") && cfg.isString("database.players_table_name")
|
||||
@ -235,4 +235,8 @@ public class PluginConfig {
|
||||
public static String getMysqlDatabaseName() {
|
||||
return getConfig().getString("database.mysql_settings.database");
|
||||
}
|
||||
|
||||
public static boolean loadWorldsASync() {
|
||||
return getConfig().getBoolean("load_worlds_async");
|
||||
}
|
||||
}
|
||||
|
@ -59,6 +59,9 @@ unloadingtime: 20
|
||||
# Except for players with the permissions: ws.gamemode | ws.tp.*
|
||||
survival: false
|
||||
|
||||
# If WorldSystem should load the worlds async if possible (FAWE installed)
|
||||
load_worlds_async: true
|
||||
|
||||
# Options for the database saving player positions
|
||||
database:
|
||||
# Which type should be choosen:
|
||||
|
Loading…
Reference in New Issue
Block a user