Preparing Config-Objects to automatically sync from Server to Client

This commit is contained in:
Frank 2021-08-05 19:07:14 +02:00
parent 589151af81
commit 16cbba6e76
6 changed files with 49 additions and 50 deletions

View file

@ -22,13 +22,13 @@ public final class ConfigKeeper {
private boolean changed = false;
public ConfigKeeper(String modID, String group) {
this(modID, group, null);
}
protected ConfigKeeper(String modID, String group, File path) {
this.writer = new ConfigWriter(modID, group, path);
this.writer = new ConfigWriter(modID, group);
this.configObject = writer.load();
}
File getConfigFile(){
return this.writer.getConfigFile();
}
public void save() {
if (!changed) return;