T - the description typepublic class CottonInventoryScreen<T extends SyncedGuiDescription> extends net.minecraft.client.gui.screen.ingame.HandledScreen<T> implements CottonScreenImpl
SyncedGuiDescription.| Modifier and Type | Field and Description |
|---|---|
protected SyncedGuiDescription |
description |
protected @Nullable WWidget |
lastResponder |
BACKGROUND_TEXTURE, backgroundHeight, backgroundWidth, cursorDragging, cursorDragSlots, displayName, focusedSlot, handler, playerInventoryTitleX, playerInventoryTitleY, titleX, titleY, x, y| Constructor and Description |
|---|
CottonInventoryScreen(T description,
net.minecraft.entity.player.PlayerEntity player)
Constructs a new screen without a title.
|
CottonInventoryScreen(T description,
net.minecraft.entity.player.PlayerEntity player,
net.minecraft.text.Text title)
Constructs a new screen.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
changeFocus(boolean lookForwards) |
boolean |
charTyped(char ch,
int keyCode) |
protected void |
drawBackground(net.minecraft.client.util.math.MatrixStack matrices,
float partialTicks,
int mouseX,
int mouseY) |
protected void |
drawForeground(net.minecraft.client.util.math.MatrixStack matrices,
int mouseX,
int mouseY) |
@Nullable WWidget |
getLastResponder() |
void |
init() |
boolean |
isPauseScreen() |
boolean |
keyPressed(int ch,
int keyCode,
int modifiers) |
boolean |
keyReleased(int ch,
int keyCode,
int modifiers) |
boolean |
mouseClicked(double mouseX,
double mouseY,
int mouseButton) |
boolean |
mouseDragged(double mouseX,
double mouseY,
int mouseButton,
double deltaX,
double deltaY) |
void |
mouseMoved(double mouseX,
double mouseY) |
boolean |
mouseReleased(double mouseX,
double mouseY,
int mouseButton) |
boolean |
mouseScrolled(double mouseX,
double mouseY,
double amount) |
void |
removed() |
void |
render(net.minecraft.client.util.math.MatrixStack matrices,
int mouseX,
int mouseY,
float partialTicks) |
void |
renderTextHover(net.minecraft.client.util.math.MatrixStack matrices,
@Nullable net.minecraft.text.Style textStyle,
int x,
int y) |
protected void |
reposition(int screenWidth,
int screenHeight)
Repositions the root panel.
|
void |
setLastResponder(@Nullable WWidget lastResponder) |
void |
tick() |
drawMouseoverTooltip, getScreenHandler, handleHotbarKeyPressed, isClickOutsideBounds, isPointWithinBounds, method_33285, onClose, onMouseClickaddButton, addChild, children, filesDragged, getNarrationMessage, getTitle, getTooltipFromItem, handleTextClick, hasAltDown, hasControlDown, hasShiftDown, init, insertText, isCopy, isCut, isMouseOver, isPaste, isSelectAll, isValidCharacterForName, renderBackground, renderBackground, renderBackgroundTexture, renderOrderedTooltip, renderTextHoverEffect, renderTooltip, renderTooltip, renderTooltip, renderTooltip, resize, sendMessage, sendMessage, shouldCloseOnEsc, wrapScreenErrorgetFocused, isDragging, setDragging, setFocuseddrawCenteredString, drawCenteredText, drawHorizontalLine, drawSprite, drawStringWithShadow, drawTexture, drawTexture, drawTexture, drawTexture, drawTextWithShadow, drawVerticalLine, fill, fillGradient, fillGradient, getZOffset, method_29343, method_33284, setZOffsetprotected SyncedGuiDescription description
@Nullable protected @Nullable WWidget lastResponder
public CottonInventoryScreen(T description, net.minecraft.entity.player.PlayerEntity player)
description - the GUI descriptionplayer - the playerpublic CottonInventoryScreen(T description, net.minecraft.entity.player.PlayerEntity player, net.minecraft.text.Text title)
description - the GUI descriptionplayer - the playertitle - the screen titlepublic void init()
init in class net.minecraft.client.gui.screen.ingame.HandledScreen<T extends SyncedGuiDescription>public void removed()
removed in class net.minecraft.client.gui.screen.ingame.HandledScreen<T extends SyncedGuiDescription>@Nullable public @Nullable WWidget getLastResponder()
getLastResponder in interface CottonScreenImplpublic void setLastResponder(@Nullable
@Nullable WWidget lastResponder)
setLastResponder in interface CottonScreenImplprotected void reposition(int screenWidth,
int screenHeight)
screenWidth - the width of the screenscreenHeight - the height of the screenpublic boolean isPauseScreen()
isPauseScreen in class net.minecraft.client.gui.screen.ingame.HandledScreen<T extends SyncedGuiDescription>public boolean charTyped(char ch,
int keyCode)
charTyped in interface net.minecraft.client.gui.ElementcharTyped in interface net.minecraft.client.gui.ParentElementpublic boolean keyPressed(int ch,
int keyCode,
int modifiers)
keyPressed in interface net.minecraft.client.gui.ElementkeyPressed in interface net.minecraft.client.gui.ParentElementkeyPressed in class net.minecraft.client.gui.screen.ingame.HandledScreen<T extends SyncedGuiDescription>public boolean keyReleased(int ch,
int keyCode,
int modifiers)
keyReleased in interface net.minecraft.client.gui.ElementkeyReleased in interface net.minecraft.client.gui.ParentElementpublic boolean mouseClicked(double mouseX,
double mouseY,
int mouseButton)
mouseClicked in interface net.minecraft.client.gui.ElementmouseClicked in interface net.minecraft.client.gui.ParentElementmouseClicked in class net.minecraft.client.gui.screen.ingame.HandledScreen<T extends SyncedGuiDescription>public boolean mouseReleased(double mouseX,
double mouseY,
int mouseButton)
mouseReleased in interface net.minecraft.client.gui.ElementmouseReleased in interface net.minecraft.client.gui.ParentElementmouseReleased in class net.minecraft.client.gui.screen.ingame.HandledScreen<T extends SyncedGuiDescription>public boolean mouseDragged(double mouseX,
double mouseY,
int mouseButton,
double deltaX,
double deltaY)
mouseDragged in interface net.minecraft.client.gui.ElementmouseDragged in interface net.minecraft.client.gui.ParentElementmouseDragged in class net.minecraft.client.gui.screen.ingame.HandledScreen<T extends SyncedGuiDescription>public boolean mouseScrolled(double mouseX,
double mouseY,
double amount)
mouseScrolled in interface net.minecraft.client.gui.ElementmouseScrolled in interface net.minecraft.client.gui.ParentElementpublic void mouseMoved(double mouseX,
double mouseY)
mouseMoved in interface net.minecraft.client.gui.Elementprotected void drawBackground(net.minecraft.client.util.math.MatrixStack matrices,
float partialTicks,
int mouseX,
int mouseY)
drawBackground in class net.minecraft.client.gui.screen.ingame.HandledScreen<T extends SyncedGuiDescription>public void render(net.minecraft.client.util.math.MatrixStack matrices,
int mouseX,
int mouseY,
float partialTicks)
render in interface net.minecraft.client.gui.Drawablerender in class net.minecraft.client.gui.screen.ingame.HandledScreen<T extends SyncedGuiDescription>protected void drawForeground(net.minecraft.client.util.math.MatrixStack matrices,
int mouseX,
int mouseY)
drawForeground in class net.minecraft.client.gui.screen.ingame.HandledScreen<T extends SyncedGuiDescription>public void tick()
tick in interface net.minecraft.client.gui.screen.TickableElementtick in class net.minecraft.client.gui.screen.ingame.HandledScreen<T extends SyncedGuiDescription>public void renderTextHover(net.minecraft.client.util.math.MatrixStack matrices,
@Nullable
@Nullable net.minecraft.text.Style textStyle,
int x,
int y)
renderTextHover in interface CottonScreenImplpublic boolean changeFocus(boolean lookForwards)
changeFocus in interface net.minecraft.client.gui.ElementchangeFocus in interface net.minecraft.client.gui.ParentElement