mirror of
https://github.com/mcMMO-Dev/mcMMO.git
synced 2024-11-24 14:16:45 +01:00
Merge remote branch 'org.eclipse.jgit.transport.RemoteConfig@10a3c73/master' into pullme
This commit is contained in:
commit
6f762364f5
@ -20,7 +20,7 @@ import com.gmail.nossr50.mcMMO;
|
|||||||
import java.io.File;
|
import java.io.File;
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
|
|
||||||
import org.bukkit.configuration.file.FileConfiguration;
|
import org.bukkit.configuration.file.YamlConfiguration;
|
||||||
|
|
||||||
import com.gmail.nossr50.datatypes.HUDType;
|
import com.gmail.nossr50.datatypes.HUDType;
|
||||||
|
|
||||||
@ -60,13 +60,13 @@ public class LoadProperties
|
|||||||
protected static File configFile;
|
protected static File configFile;
|
||||||
protected static File dataFolder;
|
protected static File dataFolder;
|
||||||
protected final mcMMO plugin;
|
protected final mcMMO plugin;
|
||||||
protected static FileConfiguration config;
|
protected static YamlConfiguration config;
|
||||||
|
|
||||||
public LoadProperties(mcMMO plugin)
|
public LoadProperties(mcMMO plugin)
|
||||||
{
|
{
|
||||||
this.plugin = plugin;
|
this.plugin = plugin;
|
||||||
dataFolder = plugin.getDataFolder();
|
dataFolder = plugin.getDataFolder();
|
||||||
configFile = new File(dataFolder, "config.yml");
|
configFile = new File(dataFolder, File.separator + "config.yml");
|
||||||
}
|
}
|
||||||
|
|
||||||
public void configCheck()
|
public void configCheck()
|
||||||
@ -124,10 +124,10 @@ public class LoadProperties
|
|||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
private FileConfiguration load()
|
private YamlConfiguration load()
|
||||||
{
|
{
|
||||||
try {
|
try {
|
||||||
config.load(configFile);
|
config = YamlConfiguration.loadConfiguration(configFile);
|
||||||
return config;
|
return config;
|
||||||
|
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
|
@ -127,6 +127,7 @@ public class mcMMO extends JavaPlugin
|
|||||||
|
|
||||||
mcPermissions.initialize(getServer());
|
mcPermissions.initialize(getServer());
|
||||||
|
|
||||||
|
System.out.println("[mcMMO]Checking config file at: " + this.getDataFolder().toString() + File.separator + "config.yml");
|
||||||
config.configCheck();
|
config.configCheck();
|
||||||
|
|
||||||
Party.getInstance().loadParties();
|
Party.getInstance().loadParties();
|
||||||
|
Loading…
Reference in New Issue
Block a user