Class RealmsTermsScreen

All Implemented Interfaces:
ContainerEventHandler, GuiEventListener, Renderable, TabOrderedElement

public class RealmsTermsScreen extends RealmsScreen
  • Field Details

    • LOGGER

      private static final org.slf4j.Logger LOGGER
    • TITLE

      private static final Component TITLE
    • TERMS_STATIC_TEXT

      private static final Component TERMS_STATIC_TEXT
    • lastScreen

      private final Screen lastScreen
    • realmsServer

      private final RealmsServer realmsServer
      The screen to display when OK is clicked on the disconnect screen. Seems to be either null (integrated server) or an instance of either
      invalid reference
      MultiplayerScreen
      (when connecting to a server) or RealmsTermsScreen (when connecting to MCO server)
  • Constructor Details

    • RealmsTermsScreen

      public RealmsTermsScreen(Screen pLastScreen, RealmsServer pRealmsServer)
  • Method Details

    • init

      public void init()
      Overrides:
      init in class Screen
    • keyPressed

      public boolean keyPressed(int pKeyCode, int pScanCode, int pModifiers)
      Description copied from class: Screen
      Called when a keyboard key is pressed within the GUI element.

      Specified by:
      keyPressed in interface ContainerEventHandler
      Specified by:
      keyPressed in interface GuiEventListener
      Overrides:
      keyPressed in class Screen
      Parameters:
      pKeyCode - the key code of the pressed key.
      pScanCode - the scan code of the pressed key.
      pModifiers - the keyboard modifiers.
      Returns:
      true if the event is consumed, false otherwise.
    • agreedToTos

      private void agreedToTos()
    • mouseClicked

      public boolean mouseClicked(double pMouseX, double pMouseY, int pButton)
      Called when a mouse button is clicked within the GUI element.

      Parameters:
      pMouseX - the X coordinate of the mouse.
      pMouseY - the Y coordinate of the mouse.
      pButton - the button that was clicked.
      Returns:
      true if the event is consumed, false otherwise.
    • getNarrationMessage

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

      public void render(GuiGraphics pGuiGraphics, int pMouseX, int pMouseY, float pPartialTick)
      Renders the graphical user interface (GUI) element.
      Specified by:
      render in interface Renderable
      Overrides:
      render in class Screen
      Parameters:
      pGuiGraphics - the GuiGraphics object used for rendering.
      pMouseX - the x-coordinate of the mouse cursor.
      pMouseY - the y-coordinate of the mouse cursor.
      pPartialTick - the partial tick time.