Class AlertScreen

All Implemented Interfaces:
ContainerEventHandler, GuiEventListener, Renderable, TabOrderedElement

public class AlertScreen extends Screen
  • Field Details

    • LABEL_Y

      private static final int LABEL_Y
      See Also:
    • messageText

      private final Component messageText
    • message

      private MultiLineLabel message
    • callback

      private final Runnable callback
    • okButton

      private final Component okButton
    • shouldCloseOnEsc

      private final boolean shouldCloseOnEsc
  • Constructor Details

  • Method Details

    • getNarrationMessage

      public Component getNarrationMessage()
      Overrides:
      getNarrationMessage in class Screen
    • init

      protected void init()
      Overrides:
      init in class Screen
    • render

      public void render(GuiGraphics p_281989_, int p_281583_, int p_282152_, float p_282198_)
      Description copied from interface: Renderable
      Renders the graphical user interface (GUI) element.
      Specified by:
      render in interface Renderable
      Overrides:
      render in class Screen
      Parameters:
      p_281989_ - the GuiGraphics object used for rendering.
      p_281583_ - the x-coordinate of the mouse cursor.
      p_282152_ - the y-coordinate of the mouse cursor.
      p_282198_ - the partial tick time.
    • shouldCloseOnEsc

      public boolean shouldCloseOnEsc()
      Overrides:
      shouldCloseOnEsc in class Screen