Package net.minecraft.client.gui.screen
Class TitleScreen
java.lang.Object
net.minecraft.client.gui.DrawableHelper
net.minecraft.client.gui.AbstractParentElement
net.minecraft.client.gui.screen.Screen
net.minecraft.client.gui.screen.TitleScreen
- All Implemented Interfaces:
Drawable
,Element
,ParentElement
,TickableElement
@Environment(CLIENT) public class TitleScreen extends Screen
-
Field Summary
Fields Modifier and Type Field Description private static Identifier
ACCESSIBILITY_ICON_TEXTURE
private long
backgroundFadeStart
private RotatingCubeMapRenderer
backgroundRenderer
private ButtonWidget
buttonResetDemo
private int
copyrightTextWidth
private int
copyrightTextX
private boolean
doBackgroundFade
private static Identifier
EDITION_TITLE_TEXTURE
private static Logger
field_23775
private boolean
isMinceraft
private static Identifier
MINECRAFT_TITLE_TEXTURE
static CubeMapRenderer
PANORAMA_CUBE_MAP
private static Identifier
PANORAMA_OVERLAY
private Screen
realmsNotificationGui
private boolean
realmsNotificationsInitialized
private String
splashText
Fields inherited from class net.minecraft.client.gui.screen.Screen
buttons, children, client, height, itemRenderer, passEvents, textRenderer, title, width
Fields inherited from class net.minecraft.client.gui.DrawableHelper
GUI_ICONS_TEXTURE, OPTIONS_BACKGROUND_TEXTURE, STATS_ICON_TEXTURE
-
Constructor Summary
Constructors Constructor Description TitleScreen()
TitleScreen(boolean doBackgroundFade)
-
Method Summary
Modifier and Type Method Description private boolean
areRealmsNotificationsEnabled()
protected void
init()
Called when a screen should be initialized.private void
initWidgetsDemo(int y, int spacingY)
private void
initWidgetsNormal(int y, int spacingY)
boolean
isPauseScreen()
static CompletableFuture<Void>
loadTexturesAsync(TextureManager textureManager, Executor executor)
private boolean
method_31129()
boolean
mouseClicked(double mouseX, double mouseY, int button)
Callback for when a mouse button down event has been captured.private void
onDemoDeletionConfirmed(boolean delete)
void
removed()
void
render(MatrixStack matrices, int mouseX, int mouseY, float delta)
boolean
shouldCloseOnEsc()
Checks whether this screen should be closed when the escape key is pressed.private void
switchToRealms()
void
tick()
Methods inherited from class net.minecraft.client.gui.screen.Screen
addButton, addChild, children, filesDragged, getNarrationMessage, getTitle, getTooltipFromItem, handleTextClick, hasAltDown, hasControlDown, hasShiftDown, init, insertText, isCopy, isCut, isMouseOver, isPaste, isSelectAll, isValidCharacterForName, keyPressed, onClose, renderBackground, renderBackground, renderBackgroundTexture, renderOrderedTooltip, renderTextHoverEffect, renderTooltip, renderTooltip, renderTooltip, resize, sendMessage, sendMessage, wrapScreenError
Methods inherited from class net.minecraft.client.gui.AbstractParentElement
getFocused, isDragging, setDragging, setFocused
Methods inherited from class net.minecraft.client.gui.DrawableHelper
drawCenteredString, drawCenteredText, drawHorizontalLine, drawSprite, drawStringWithShadow, drawTexture, drawTexture, drawTexture, drawTexture, drawTextWithShadow, drawVerticalLine, fill, fillGradient, fillGradient, getZOffset, method_29343, setZOffset
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.Element
mouseMoved
Methods inherited from interface net.minecraft.client.gui.ParentElement
changeFocus, charTyped, focusOn, hoveredElement, keyReleased, mouseDragged, mouseReleased, mouseScrolled, setInitialFocus
-
Field Details
-
field_23775
-
PANORAMA_CUBE_MAP
-
PANORAMA_OVERLAY
-
ACCESSIBILITY_ICON_TEXTURE
-
MINECRAFT_TITLE_TEXTURE
-
EDITION_TITLE_TEXTURE
-
isMinceraft
private final boolean isMinceraft -
splashText
-
buttonResetDemo
-
realmsNotificationsInitialized
private boolean realmsNotificationsInitialized -
realmsNotificationGui
-
copyrightTextWidth
private int copyrightTextWidth -
copyrightTextX
private int copyrightTextX -
backgroundRenderer
-
doBackgroundFade
private final boolean doBackgroundFade -
backgroundFadeStart
private long backgroundFadeStart
-
-
Constructor Details
-
TitleScreen
public TitleScreen() -
TitleScreen
public TitleScreen(boolean doBackgroundFade)
-
-
Method Details
-
areRealmsNotificationsEnabled
private boolean areRealmsNotificationsEnabled() -
tick
public void tick()- Specified by:
tick
in interfaceTickableElement
- Overrides:
tick
in classScreen
-
loadTexturesAsync
public static CompletableFuture<Void> loadTexturesAsync(TextureManager textureManager, Executor executor) -
isPauseScreen
public boolean isPauseScreen()- Overrides:
isPauseScreen
in classScreen
-
shouldCloseOnEsc
public boolean shouldCloseOnEsc()Checks whether this screen should be closed when the escape key is pressed.- Overrides:
shouldCloseOnEsc
in classScreen
-
init
protected void init()Called when a screen should be initialized.This method is called when this screen is
opened
or resized. -
initWidgetsNormal
private void initWidgetsNormal(int y, int spacingY) -
initWidgetsDemo
private void initWidgetsDemo(int y, int spacingY) -
method_31129
private boolean method_31129() -
switchToRealms
private void switchToRealms() -
render
-
mouseClicked
public boolean mouseClicked(double mouseX, double mouseY, int button)Callback for when a mouse button down event has been captured. The button number is identified by the constants inGLFW
class.- Parameters:
mouseX
- the X coordinate of the mousemouseY
- the Y coordinate of the mousebutton
- the mouse button number- Returns:
true
to indicate that the event handling is successful/valid- See Also:
Mouse.onMouseButton(long, int, int, int)
,GLFW.GLFW_MOUSE_BUTTON_1
-
removed
public void removed() -
onDemoDeletionConfirmed
private void onDemoDeletionConfirmed(boolean delete)
-