Fix some config setup not running if the UI isn't opened
This commit is contained in:
@@ -48,7 +48,9 @@ public class LodCommonMain {
|
||||
// }
|
||||
}
|
||||
|
||||
public static void initConfig() {
|
||||
public static void initConfig()
|
||||
{
|
||||
ConfigBase.INSTANCE = new ConfigBase(ModInfo.ID, ModInfo.NAME, Config.class,1);
|
||||
}
|
||||
Config.completeDelayedSetup();
|
||||
}
|
||||
}
|
||||
|
||||
-14
@@ -28,8 +28,6 @@ public class GetConfigScreen
|
||||
// This shouldn't be here, but I need a way to test it after Minecraft inits its assets
|
||||
//System.out.println(ConfigBase.INSTANCE.generateLang(false, true));
|
||||
|
||||
runGuiOnlyConfigSetup();
|
||||
|
||||
return switch (useScreen)
|
||||
{
|
||||
case Classic -> ClassicConfigGUI.getScreen(ConfigBase.INSTANCE, parent, "client");
|
||||
@@ -39,16 +37,4 @@ public class GetConfigScreen
|
||||
default -> null;
|
||||
};
|
||||
}
|
||||
|
||||
/**
|
||||
* Updates any config values that are UI only
|
||||
* and adds any listeners that depend on multiple config values.
|
||||
*/
|
||||
private static void runGuiOnlyConfigSetup()
|
||||
{
|
||||
ThreadPresetConfigEventHandler.INSTANCE.setUiOnlyConfigValues();
|
||||
RenderQualityPresetConfigEventHandler.INSTANCE.setUiOnlyConfigValues();
|
||||
QuickRenderToggleConfigEventHandler.INSTANCE.setUiOnlyConfigValues();
|
||||
}
|
||||
|
||||
}
|
||||
+1
-1
Submodule coreSubProjects updated: ac73b52b23...773cd3aaef
Reference in New Issue
Block a user