Class ClientConfigManager
java.lang.Object
net.ixdarklord.coolcatcore.internal.config.client.ClientConfigManager
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enumWhere a config's edits go from this client.static final recordA startup value this client has but the server doesn't. -
Method Summary
Modifier and TypeMethodDescriptionstatic ClientConfigManager.Accessstatic booleanhasServerValues(Config config) Whether the server sent its values of this config in this session.static voidinit()Called once by each loader's client setup.static voidonStartupCheck(ConfigNetwork.StartupCheckPayload payload, Consumer<net.minecraft.network.chat.Component> disconnect) static voidonSync(ConfigNetwork.SyncPayload payload) static voidstatic voidOpens a screen next tick, once whatever is closing (the chat, after a command) has closed.static voidsendUpdate(ConfigImpl config, com.google.gson.JsonObject changes) static voidsetMismatchScreen(BiFunction<net.minecraft.client.gui.screens.Screen, List<ClientConfigManager.StartupMismatch>, net.minecraft.client.gui.screens.Screen> factory) Sets the screen shown after a startup mismatch disconnected the player, over the disconnect screen.static voidtoast(net.minecraft.network.chat.Component title, @Nullable net.minecraft.network.chat.Component message) A notice in the corner: a short title (usually the config's name) over a message, which wraps so it never runs past the toast.
-
Method Details
-
init
public static void init()Called once by each loader's client setup. -
access
-
hasServerValues
Whether the server sent its values of this config in this session. -
onSync
-
onStartupCheck
public static void onStartupCheck(ConfigNetwork.StartupCheckPayload payload, Consumer<net.minecraft.network.chat.Component> disconnect) -
onUpdateResult
-
sendUpdate
-
setMismatchScreen
public static void setMismatchScreen(BiFunction<net.minecraft.client.gui.screens.Screen, List<ClientConfigManager.StartupMismatch>, net.minecraft.client.gui.screens.Screen> factory) Sets the screen shown after a startup mismatch disconnected the player, over the disconnect screen. Without one, the disconnect message (which lists the differences) is all. -
openLater
Opens a screen next tick, once whatever is closing (the chat, after a command) has closed. -
toast
public static void toast(net.minecraft.network.chat.Component title, @Nullable @Nullable net.minecraft.network.chat.Component message) A notice in the corner: a short title (usually the config's name) over a message, which wraps so it never runs past the toast. It replaces the previous one.
-