Class ConfigScreen

java.lang.Object
net.minecraft.client.gui.GuiComponent
net.minecraft.client.gui.components.events.AbstractContainerEventHandler
net.minecraft.client.gui.screens.Screen
net.createmod.catnip.gui.AbstractSimiScreen
net.createmod.catnip.config.ui.ConfigScreen
All Implemented Interfaces:
net.minecraft.client.gui.components.events.ContainerEventHandler, net.minecraft.client.gui.components.events.GuiEventListener, net.minecraft.client.gui.components.Widget
Direct Known Subclasses:
BaseConfigScreen, ConfigModListScreen, SubMenuConfigScreen

public abstract class ConfigScreen extends AbstractSimiScreen
  • Nested Class Summary

    Nested classes/interfaces inherited from class net.minecraft.client.gui.screens.Screen

    net.minecraft.client.gui.screens.Screen.NarratableSearchResult
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final Map<String,org.apache.logging.log4j.util.TriConsumer<net.minecraft.client.gui.screens.Screen,com.mojang.blaze3d.vertex.PoseStack,Float>>
     
    static final PhysicalFloat
     
    static final List<UnaryOperator<String>>
     
    static final Map<String,String>
     
    static String
     
    protected final net.minecraft.client.gui.screens.Screen
     
     
    static net.minecraft.world.level.block.state.BlockState
     

    Fields inherited from class net.createmod.catnip.gui.AbstractSimiScreen

    guiLeft, guiTop, windowHeight, windowWidth, windowXOffset, windowYOffset

    Fields inherited from class net.minecraft.client.gui.screens.Screen

    font, height, itemRenderer, minecraft, passEvents, renderables, title, width

    Fields inherited from class net.minecraft.client.gui.GuiComponent

    BACKGROUND_LOCATION, GUI_ICONS_LOCATION, STATS_ICON_LOCATION

    Fields inherited from interface net.minecraft.client.gui.components.events.GuiEventListener

    DOUBLE_CLICK_THRESHOLD_MS
  • Constructor Summary

    Constructors
    Constructor
    Description
    ConfigScreen(net.minecraft.client.gui.screens.Screen parent)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    protected void
     
    This method checks some language keys to see if the mod has declared a display name via lang.
    boolean
     
    boolean
    mouseScrolled(double mouseX, double mouseY, double delta)
     
    protected void
     
    void
    renderBackground(com.mojang.blaze3d.vertex.PoseStack ms)
     
    protected static void
    renderCog(com.mojang.blaze3d.vertex.PoseStack ms)
     
    protected void
    renderMenuBackground(com.mojang.blaze3d.vertex.PoseStack ms, float partialTicks)
    By default, ConfigScreens will render the Vanilla Panorama as their background when not opened ingame.
    protected void
    renderWindow(com.mojang.blaze3d.vertex.PoseStack ms, int mouseX, int mouseY, float partialTicks)
     
    protected void
    renderWindowBackground(com.mojang.blaze3d.vertex.PoseStack ms, int mouseX, int mouseY, float partialTicks)
     
    void
     
    static String
     

    Methods inherited from class net.minecraft.client.gui.screens.Screen

    addRenderableOnly, addRenderableWidget, addWidget, afterKeyboardAction, afterMouseAction, afterMouseMove, children, clearWidgets, findNarratableWidget, getNarrationMessage, getTitle, getTooltipFromItem, handleComponentClicked, handleDelayedNarration, hasAltDown, hasControlDown, hasShiftDown, hideWidgets, init, insertText, isCopy, isCut, isMouseOver, isPaste, isSelectAll, isValidCharacterForName, narrationEnabled, onClose, onFilesDrop, rebuildWidgets, removed, removeWidget, renderBackground, renderComponentHoverEffect, renderComponentTooltip, renderDirtBackground, renderTooltip, renderTooltip, renderTooltip, renderTooltip, resize, shouldCloseOnEsc, triggerImmediateNarration, updateNarratedWidget, updateNarrationState, wrapScreenError

    Methods inherited from class net.minecraft.client.gui.components.events.AbstractContainerEventHandler

    isDragging, setDragging, setFocused

    Methods inherited from class net.minecraft.client.gui.GuiComponent

    blit, blit, blit, blit, blit, blitOutlineBlack, disableScissor, drawCenteredString, drawCenteredString, drawCenteredString, drawString, drawString, drawString, enableScissor, fill, fillGradient, fillGradient, fillGradient, getBlitOffset, hLine, setBlitOffset, vLine

    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

    changeFocus, charTyped, getChildAt, keyReleased, magicalSpecialHackyFocus, mouseClicked, mouseDragged, mouseReleased, setInitialFocus

    Methods inherited from interface net.minecraft.client.gui.components.events.GuiEventListener

    mouseMoved
  • Field Details

    • displayNameKeys

      public static final List<UnaryOperator<String>> displayNameKeys
    • knownModDisplayNames

      public static final Map<String,String> knownModDisplayNames
    • backgrounds

      public static final Map<String,org.apache.logging.log4j.util.TriConsumer<net.minecraft.client.gui.screens.Screen,com.mojang.blaze3d.vertex.PoseStack,Float>> backgrounds
    • cogSpin

      public static final PhysicalFloat cogSpin
    • modID

      @Nullable public static String modID
    • parent

      @Nullable protected final net.minecraft.client.gui.screens.Screen parent
    • shadowState

      public static net.minecraft.world.level.block.state.BlockState shadowState
    • shadowElement

      public static DelegatedStencilElement shadowElement
  • Constructor Details

    • ConfigScreen

      public ConfigScreen(@Nullable net.minecraft.client.gui.screens.Screen parent)
  • Method Details

    • tick

      public void tick()
      Overrides:
      tick in class AbstractSimiScreen
    • renderBackground

      public void renderBackground(@Nonnull com.mojang.blaze3d.vertex.PoseStack ms)
      Overrides:
      renderBackground in class net.minecraft.client.gui.screens.Screen
    • renderWindowBackground

      protected void renderWindowBackground(com.mojang.blaze3d.vertex.PoseStack ms, int mouseX, int mouseY, float partialTicks)
      Overrides:
      renderWindowBackground in class AbstractSimiScreen
    • prepareFrame

      protected void prepareFrame()
      Overrides:
      prepareFrame in class AbstractSimiScreen
    • endFrame

      protected void endFrame()
      Overrides:
      endFrame in class AbstractSimiScreen
    • renderWindow

      protected void renderWindow(com.mojang.blaze3d.vertex.PoseStack ms, int mouseX, int mouseY, float partialTicks)
      Specified by:
      renderWindow in class AbstractSimiScreen
    • mouseScrolled

      public boolean mouseScrolled(double mouseX, double mouseY, double delta)
    • isPauseScreen

      public boolean isPauseScreen()
      Overrides:
      isPauseScreen in class AbstractSimiScreen
    • getModDisplayName

      public static Optional<String> getModDisplayName(String modID)
      This method checks some language keys to see if the mod has declared a display name via lang. If none of those succeed, it checks a list of manually declared ones for compatibility.
    • toHumanReadable

      public static String toHumanReadable(String key)
    • renderMenuBackground

      protected void renderMenuBackground(com.mojang.blaze3d.vertex.PoseStack ms, float partialTicks)
      By default, ConfigScreens will render the Vanilla Panorama as their background when not opened ingame. If your mod wants to render something else, please add to the backgrounds Map in this Class with your modID as the key.
    • renderCog

      protected static void renderCog(com.mojang.blaze3d.vertex.PoseStack ms)