Class BackgroundScreen

java.lang.Object
net.minecraft.client.gui.components.events.AbstractContainerEventHandler
net.minecraft.client.gui.screens.Screen
fr.rodofire.ewc.client.gui.screen.BackgroundScreen
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
Direct Known Subclasses:
AbstractConfigScreen, AbstractInfoScreen

public abstract class BackgroundScreen 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

    Fields
    Modifier and Type
    Field
    Description
    protected net.minecraft.resources.ResourceLocation
     

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

    CUBE_MAP, font, FOOTER_SEPARATOR, HEADER_SEPARATOR, height, INWORLD_FOOTER_SEPARATOR, INWORLD_HEADER_SEPARATOR, MENU_BACKGROUND, minecraft, narratorButton, PANORAMA, renderables, screenExecutor, title, width

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

    DOUBLE_CLICK_THRESHOLD_MS
  • Constructor Summary

    Constructors
    Modifier
    Constructor
    Description
    protected
    BackgroundScreen(net.minecraft.network.chat.Component title)
     
    protected
    BackgroundScreen(net.minecraft.network.chat.Component title, net.minecraft.resources.ResourceLocation background, int backgroundWidth, int backgroundHeight)
     
    protected
    BackgroundScreen(net.minecraft.network.chat.Component title, net.minecraft.resources.ResourceLocation background, int backgroundWidth, int backgroundHeight, int backgroundShaderColor)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    render(@NotNull net.minecraft.client.gui.GuiGraphics context, int mouseX, int mouseY, float delta)
     
    void
    renderBackground(@NotNull net.minecraft.client.gui.GuiGraphics context, int mouseX, int mouseY, float delta)
     
    void
    renderBackgroundTexture(net.minecraft.client.gui.GuiGraphics context, int mouseX, int mouseY, float delta)
    method to render the backgound
    void
    renderDarkRectangle(net.minecraft.client.gui.GuiGraphics context, int x, int y, int x2, int y2, int color)
    method to render a dark rectangle on top of the background, used in config screen
    void
    renderOverBackground(net.minecraft.client.gui.GuiGraphics context, int mouseX, int mouseY, float delta)
     

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

    added, addRenderableOnly, addRenderableWidget, addWidget, afterKeyboardAction, afterMouseAction, afterMouseMove, changeFocus, children, clearFocus, clearTooltipForNextRenderPass, clearWidgets, findNarratableWidget, getBackgroundMusic, getMinecraft, getNarrationMessage, getRectangle, getTitle, getTooltipFromItem, getUsageNarration, handleComponentClicked, handleDelayedNarration, hasAltDown, hasControlDown, hasShiftDown, init, init, insertText, isCopy, isCut, isMouseOver, isPaste, isPauseScreen, isSelectAll, isValidCharacterForName, keyPressed, onClose, onFilesDrop, rebuildWidgets, removed, removeWidget, renderBlurredBackground, renderMenuBackground, renderMenuBackground, renderMenuBackgroundTexture, renderPanorama, renderTransparentBackground, renderWithTooltip, repositionElements, resize, setInitialFocus, setInitialFocus, setTooltipForNextRenderPass, setTooltipForNextRenderPass, setTooltipForNextRenderPass, setTooltipForNextRenderPass, shouldCloseOnEsc, shouldNarrateNavigation, tick, triggerImmediateNarration, updateNarratedWidget, updateNarrationState, updateNarratorStatus, 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, 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

    • TEXTURE

      protected net.minecraft.resources.ResourceLocation TEXTURE
  • Constructor Details

    • BackgroundScreen

      protected BackgroundScreen(net.minecraft.network.chat.Component title)
    • BackgroundScreen

      protected BackgroundScreen(net.minecraft.network.chat.Component title, net.minecraft.resources.ResourceLocation background, int backgroundWidth, int backgroundHeight)
    • BackgroundScreen

      protected BackgroundScreen(net.minecraft.network.chat.Component title, net.minecraft.resources.ResourceLocation background, int backgroundWidth, int backgroundHeight, int backgroundShaderColor)
  • Method Details

    • render

      public void render(@NotNull @NotNull net.minecraft.client.gui.GuiGraphics context, int mouseX, int mouseY, float delta)
      Specified by:
      render in interface net.minecraft.client.gui.components.Renderable
      Overrides:
      render in class net.minecraft.client.gui.screens.Screen
    • renderOverBackground

      public void renderOverBackground(net.minecraft.client.gui.GuiGraphics context, int mouseX, int mouseY, float delta)
    • renderBackground

      public void renderBackground(@NotNull @NotNull net.minecraft.client.gui.GuiGraphics context, int mouseX, int mouseY, float delta)
      Overrides:
      renderBackground in class net.minecraft.client.gui.screens.Screen
    • renderBackgroundTexture

      public void renderBackgroundTexture(net.minecraft.client.gui.GuiGraphics context, int mouseX, int mouseY, float delta)
      method to render the backgound
    • renderDarkRectangle

      public void renderDarkRectangle(net.minecraft.client.gui.GuiGraphics context, int x, int y, int x2, int y2, int color)
      method to render a dark rectangle on top of the background, used in config screen
      Parameters:
      context - draw context
      x - corner coordinates of the rectangle
      y - corner coordinates of the rectangle
      x2 - corner coordinates of the rectangle
      y2 - corner coordinates of the rectangle
      color - the color of the rectangle