Remove old config system
This commit is contained in:
parent
fed253332b
commit
2df2a1d1ba
4 changed files with 29 additions and 308 deletions
|
@ -34,7 +34,6 @@ import techreborn.compat.ic2.RecipesIC2;
|
|||
import techreborn.compat.theoneprobe.TheOneProbeCompat;
|
||||
import techreborn.compat.tinkers.CompatModuleTinkers;
|
||||
import techreborn.compat.waila.CompatModuleWaila;
|
||||
import techreborn.config.ConfigTechReborn;
|
||||
|
||||
import java.util.ArrayList;
|
||||
|
||||
|
@ -64,12 +63,13 @@ public class CompatManager {
|
|||
|
||||
public void registerCompact(Class<? extends ICompatModule> moduleClass, boolean config, Object... objs) {
|
||||
boolean shouldLoad = true;
|
||||
if (config) {
|
||||
shouldLoad = ConfigTechReborn.config
|
||||
.get(ConfigTechReborn.CATEGORY_INTEGRATION, "Compat:" + moduleClass.getSimpleName(), true,
|
||||
"Should the " + moduleClass.getSimpleName() + " be loaded?")
|
||||
.getBoolean(true);
|
||||
}
|
||||
//TODO config
|
||||
// if (config) {
|
||||
// shouldLoad = ConfigTechReborn.config
|
||||
// .get(ConfigTechReborn.CATEGORY_INTEGRATION, "Compat:" + moduleClass.getSimpleName(), true,
|
||||
// "Should the " + moduleClass.getSimpleName() + " be loaded?")
|
||||
// .getBoolean(true);
|
||||
// }
|
||||
for (Object obj : objs) {
|
||||
if (obj instanceof String) {
|
||||
String modid = (String) obj;
|
||||
|
@ -95,13 +95,6 @@ public class CompatManager {
|
|||
return;
|
||||
}
|
||||
}
|
||||
if (config) {
|
||||
if (ConfigTechReborn.config.hasChanged())
|
||||
ConfigTechReborn.config.save();
|
||||
if (!shouldLoad) {
|
||||
return;
|
||||
}
|
||||
}
|
||||
try {
|
||||
compatModules.add(moduleClass.newInstance());
|
||||
} catch (InstantiationException e) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue