Class ConfigScreen
java.lang.Object
net.minecraft.client.gui.components.events.AbstractContainerEventHandler
net.minecraft.client.gui.screens.Screen
com.hammy275.immersivemc.client.config.screen.ConfigScreen
- All Implemented Interfaces:
net.minecraft.client.gui.components.events.ContainerEventHandler
,net.minecraft.client.gui.components.events.GuiEventListener
,net.minecraft.client.gui.components.Renderable
,net.minecraft.client.gui.components.TabOrderedElement
public class ConfigScreen
extends net.minecraft.client.gui.screens.Screen
-
Nested Class Summary
Nested classes/interfaces inherited from class net.minecraft.client.gui.screens.Screen
net.minecraft.client.gui.screens.Screen.NarratableSearchResult
-
Field Summary
Modifier and TypeFieldDescriptionprotected static int
protected static int
protected final net.minecraft.client.gui.screens.Screen
protected static final String
Fields inherited from class net.minecraft.client.gui.screens.Screen
BACKGROUND_LOCATION, font, height, minecraft, screenExecutor, title, width
Fields inherited from interface net.minecraft.client.gui.components.events.GuiEventListener
DOUBLE_CLICK_THRESHOLD_MS
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic ActiveConfig
static ConfigType
static ClientActiveConfig
Gets the client file config if it's being adjusted, or throws an exception if it's not being adjusted.protected void
init()
static void
void
onClose()
void
render
(net.minecraft.client.gui.GuiGraphics graphics, int mouseX, int mouseY, float partialTicks) static boolean
Methods inherited from class net.minecraft.client.gui.screens.Screen
added, addRenderableOnly, addRenderableWidget, addWidget, afterKeyboardAction, afterMouseAction, afterMouseMove, changeFocus, children, clearFocus, clearWidgets, findNarratableWidget, getBackgroundMusic, getNarrationMessage, getRectangle, getTitle, getTooltipFromItem, getUsageNarration, handleComponentClicked, handleDelayedNarration, hasAltDown, hasControlDown, hasShiftDown, hideWidgets, init, insertText, isCopy, isCut, isMouseOver, isPaste, isPauseScreen, isSelectAll, isValidCharacterForName, keyPressed, narrationEnabled, onFilesDrop, rebuildWidgets, removed, removeWidget, renderBackground, renderDirtBackground, renderTransparentBackground, renderWithTooltip, repositionElements, resize, setInitialFocus, setTooltipForNextRenderPass, setTooltipForNextRenderPass, setTooltipForNextRenderPass, setTooltipForNextRenderPass, shouldCloseOnEsc, shouldNarrateNavigation, tick, triggerImmediateNarration, updateNarratedWidget, updateNarrationState, wrapScreenError
Methods inherited from class net.minecraft.client.gui.components.events.AbstractContainerEventHandler
getFocused, isDragging, setDragging, setFocused
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface net.minecraft.client.gui.components.events.ContainerEventHandler
charTyped, getChildAt, getCurrentFocusPath, isFocused, keyReleased, magicalSpecialHackyFocus, mouseClicked, mouseDragged, mouseReleased, mouseScrolled, nextFocusPath, setFocused
Methods inherited from interface net.minecraft.client.gui.components.events.GuiEventListener
mouseMoved
Methods inherited from interface net.minecraft.client.gui.components.TabOrderedElement
getTabOrderGroup
-
Field Details
-
lastScreen
protected final net.minecraft.client.gui.screens.Screen lastScreen -
BUTTON_WIDTH
protected static int BUTTON_WIDTH -
BUTTON_HEIGHT
protected static int BUTTON_HEIGHT -
WIKI_URL
- See Also:
-
-
Constructor Details
-
ConfigScreen
public ConfigScreen(net.minecraft.client.gui.screens.Screen screen)
-
-
Method Details
-
init
protected void init()- Overrides:
init
in classnet.minecraft.client.gui.screens.Screen
-
render
public void render(net.minecraft.client.gui.GuiGraphics graphics, int mouseX, int mouseY, float partialTicks) - Specified by:
render
in interfacenet.minecraft.client.gui.components.Renderable
- Overrides:
render
in classnet.minecraft.client.gui.screens.Screen
-
onClose
public void onClose()- Overrides:
onClose
in classnet.minecraft.client.gui.screens.Screen
-
onClientConfigChange
public static void onClientConfigChange() -
getAdjustingConfig
- Returns:
- The current configuration being adjusted.
-
getAdjustingConfigType
- Returns:
- The current type of config being adjusted.
-
getClientConfigIfAdjusting
Gets the client file config if it's being adjusted, or throws an exception if it's not being adjusted.
Better to use this than to directly getActiveConfig.FILE_CLIENT
, so we can verify the config screens behave correctly when editing the server config.- Returns:
- The client file config.
-
writeAdjustingConfig
public static boolean writeAdjustingConfig()
-