= Iterative step towards combined config file
file shall be config.config, because config.
This commit is contained in:
+23
-4
@@ -1,9 +1,28 @@
|
||||
package core;
|
||||
import java.nio.file.Path;
|
||||
|
||||
import java.awt.Color;
|
||||
import utils.GlobalLog;
|
||||
import utils.LogFilter;
|
||||
import utils.io.MonitoredFile;
|
||||
|
||||
public final class Config
|
||||
public class Config
|
||||
{
|
||||
public static final Color ColorDefault = new Color(7*16, 8*16, 9*16); // A slate-grey
|
||||
public static final String AssetDirectory = "./assets/";
|
||||
private static final Path filepath = Constants.AssetDirectory + Constants.ConfigFilename;
|
||||
MonitoredFile configFile;
|
||||
|
||||
Config instance;
|
||||
|
||||
public Config()
|
||||
{
|
||||
if(instance == null)
|
||||
{
|
||||
configFile = new MonitoredFile(filepath);
|
||||
instance = this;
|
||||
}
|
||||
else
|
||||
{
|
||||
GlobalLog.error(LogFilter.Core, "You can't have two of the following: " + this.getClass().getSimpleName());
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user