mirror of
https://github.com/Sollace/Unicopia.git
synced 2025-02-17 10:24:23 +01:00
Fixed config loading
This commit is contained in:
parent
790a85a57c
commit
a2a1a64523
1 changed files with 5 additions and 1 deletions
|
@ -3,7 +3,9 @@ package com.minelittlepony.unicopia;
|
|||
import java.util.HashSet;
|
||||
import java.util.Set;
|
||||
|
||||
import com.google.gson.GsonBuilder;
|
||||
import com.minelittlepony.common.util.GamePaths;
|
||||
import com.minelittlepony.common.util.registry.RegistryTypeAdapter;
|
||||
import com.minelittlepony.common.util.settings.*;
|
||||
|
||||
public class Config extends com.minelittlepony.common.util.settings.Config {
|
||||
|
@ -41,6 +43,8 @@ public class Config extends com.minelittlepony.common.util.settings.Config {
|
|||
.addComment("Turn this ON if you have another mod that adds butterflies.");
|
||||
|
||||
public Config() {
|
||||
super(HEIRARCHICAL_JSON_ADAPTER, GamePaths.getConfigDirectory().resolve("unicopia.json"));
|
||||
super(new HeirarchicalJsonConfigAdapter(new GsonBuilder()
|
||||
.registerTypeAdapter(Race.class, RegistryTypeAdapter.of(Race.REGISTRY))
|
||||
), GamePaths.getConfigDirectory().resolve("unicopia.json"));
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue