Class SmithingScreen
java.lang.Object
net.minecraft.client.gui.components.events.AbstractContainerEventHandler
net.minecraft.client.gui.screens.Screen
net.minecraft.client.gui.screens.inventory.AbstractContainerScreen<SmithingMenu>
net.minecraft.client.gui.screens.inventory.ItemCombinerScreen<SmithingMenu>
net.minecraft.client.gui.screens.inventory.SmithingScreen
- All Implemented Interfaces:
ContainerEventHandler, GuiEventListener, Renderable, TabOrderedElement, MenuAccess<SmithingMenu>, ContainerListener
-
Nested Class Summary
Nested classes/interfaces inherited from class Screen
Screen.NarratableSearchResult -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final CyclingSlotBackgroundprivate static final Quaternionfprivate static final intprivate static final intprivate static final intprivate static final intprivate static final intprivate static final Vector3fprivate static final intprivate static final intprivate final ArmorStandRenderStateprivate final CyclingSlotBackgroundprivate static final Identifierprivate static final Identifierprivate static final List<Identifier> private static final intprivate static final intprivate static final intprivate static final intprivate static final Identifierprivate static final Componentprivate static final Componentprivate final CyclingSlotBackgroundprivate static final intprivate static final intprivate static final intFields inherited from class AbstractContainerScreen
BACKGROUND_TEXTURE_HEIGHT, BACKGROUND_TEXTURE_WIDTH, DEFAULT_IMAGE_HEIGHT, DEFAULT_IMAGE_WIDTH, hoveredSlot, imageHeight, imageWidth, INVENTORY_LOCATION, inventoryLabelX, inventoryLabelY, isQuickCrafting, leftPos, menu, playerInventoryTitle, quickCraftSlots, slotColor, titleLabelX, titleLabelY, topPosFields inherited from class Screen
FADE_IN_TIME, font, FOOTER_SEPARATOR, HEADER_SEPARATOR, height, INWORLD_FOOTER_SEPARATOR, INWORLD_HEADER_SEPARATOR, MENU_BACKGROUND, minecraft, narratorButton, renderables, screenExecutor, title, width -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidprivate Optional<SmithingTemplateItem> private booleanvoidrender(GuiGraphics graphics, int mouseX, int mouseY, float a) Renders the graphical user interface (GUI) element.protected voidrenderBg(GuiGraphics graphics, float a, int xMouse, int yMouse) protected voidrenderErrorIcon(GuiGraphics graphics, int xo, int yo) private voidrenderOnboardingTooltips(GuiGraphics graphics, int mouseX, int mouseY) voidslotChanged(AbstractContainerMenu container, int slotIndex, ItemStack itemStack) Sends the contents of an inventory slot to the client-side Container.protected voidsubInit()private voidupdateArmorStandPreview(ItemStack itemStack) Methods inherited from class ItemCombinerScreen
dataChanged, init, removedMethods inherited from class AbstractContainerScreen
addItemSlotMouseAction, checkHotbarKeyPressed, clearDraggingState, getGuiLeft, getGuiTop, getMenu, getSlotColor, getSlotUnderMouse, getTooltipFromContainerItem, getXSize, getYSize, handleSlotStateChanged, hasClickedOutside, isHovering, isInGameUi, isPauseScreen, keyPressed, mouseClicked, mouseDragged, mouseReleased, mouseScrolled, onClose, onMouseClickAction, renderBackground, renderCarriedItem, renderContents, renderLabels, renderSlot, renderSlotContents, renderSlots, renderSnapbackItem, renderTooltip, slotClicked, tickMethods inherited from class Screen
added, addRenderableOnly, addRenderableWidget, addWidget, afterKeyboardAction, afterMouseAction, afterMouseMove, canInterruptWithAnotherScreen, changeFocus, children, clearFocus, clearWidgets, clickCommandAction, clickUrlAction, defaultHandleClickEvent, defaultHandleGameClickEvent, fadeWidgets, fillCrashDetails, findNarratableWidget, getBackgroundMusic, getFont, getMinecraft, getNarrationMessage, getRectangle, getTitle, getTooltipFromItem, getUsageNarration, handleDelayedNarration, init, insertText, isAllowedInPortal, isMouseOver, isValidCharacterForName, onFilesDrop, panoramaShouldSpin, rebuildWidgets, removeWidget, renderBlurredBackground, renderMenuBackground, renderMenuBackground, renderMenuBackgroundTexture, renderPanorama, renderTransparentBackground, renderWithTooltipAndSubtitles, repositionElements, resize, setInitialFocus, setInitialFocus, shouldCloseOnEsc, shouldNarrateNavigation, showsActiveEffects, triggerImmediateNarration, updateNarratedWidget, updateNarrationState, updateNarratorStatusMethods inherited from class AbstractContainerEventHandler
getFocused, isDragging, setDragging, setFocusedMethods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface ContainerEventHandler
charTyped, getBorderForArrowNavigation, getChildAt, getCurrentFocusPath, isFocused, keyReleased, nextFocusPath, setFocusedMethods inherited from interface GuiEventListener
mouseMoved, shouldTakeFocusAfterInteractionMethods inherited from interface TabOrderedElement
getTabOrderGroup
-
Field Details
-
ERROR_SPRITE
-
EMPTY_SLOT_SMITHING_TEMPLATE_ARMOR_TRIM
-
EMPTY_SLOT_SMITHING_TEMPLATE_NETHERITE_UPGRADE
-
MISSING_TEMPLATE_TOOLTIP
-
ERROR_TOOLTIP
-
EMPTY_SLOT_SMITHING_TEMPLATES
-
TITLE_LABEL_X
private static final int TITLE_LABEL_X- See Also:
-
TITLE_LABEL_Y
private static final int TITLE_LABEL_Y- See Also:
-
ERROR_ICON_WIDTH
private static final int ERROR_ICON_WIDTH- See Also:
-
ERROR_ICON_HEIGHT
private static final int ERROR_ICON_HEIGHT- See Also:
-
ERROR_ICON_X
private static final int ERROR_ICON_X- See Also:
-
ERROR_ICON_Y
private static final int ERROR_ICON_Y- See Also:
-
TOOLTIP_WIDTH
private static final int TOOLTIP_WIDTH- See Also:
-
ARMOR_STAND_Y_ROT
private static final int ARMOR_STAND_Y_ROT- See Also:
-
ARMOR_STAND_X_ROT
private static final int ARMOR_STAND_X_ROT- See Also:
-
ARMOR_STAND_TRANSLATION
-
ARMOR_STAND_ANGLE
-
ARMOR_STAND_SCALE
private static final int ARMOR_STAND_SCALE- See Also:
-
ARMOR_STAND_LEFT
private static final int ARMOR_STAND_LEFT- See Also:
-
ARMOR_STAND_TOP
private static final int ARMOR_STAND_TOP- See Also:
-
ARMOR_STAND_RIGHT
private static final int ARMOR_STAND_RIGHT- See Also:
-
ARMOR_STAND_BOTTOM
private static final int ARMOR_STAND_BOTTOM- See Also:
-
templateIcon
-
baseIcon
-
additionalIcon
-
armorStandPreview
-
-
Constructor Details
-
SmithingScreen
-
-
Method Details
-
subInit
protected void subInit()- Overrides:
subInitin classItemCombinerScreen<SmithingMenu>
-
containerTick
public void containerTick()- Overrides:
containerTickin classAbstractContainerScreen<SmithingMenu>
-
getTemplateItem
-
render
Description copied from interface:RenderableRenders the graphical user interface (GUI) element.- Specified by:
renderin interfaceRenderable- Overrides:
renderin classAbstractContainerScreen<SmithingMenu>- Parameters:
graphics- the GuiGraphics object used for rendering.mouseX- the x-coordinate of the mouse cursor.mouseY- the y-coordinate of the mouse cursor.a- the partial tick time.
-
renderBg
- Overrides:
renderBgin classItemCombinerScreen<SmithingMenu>
-
slotChanged
Description copied from class:ItemCombinerScreenSends the contents of an inventory slot to the client-side Container. This doesn't have to match the actual contents of that slot.- Specified by:
slotChangedin interfaceContainerListener- Overrides:
slotChangedin classItemCombinerScreen<SmithingMenu>
-
updateArmorStandPreview
-
renderErrorIcon
- Specified by:
renderErrorIconin classItemCombinerScreen<SmithingMenu>
-
renderOnboardingTooltips
-
hasRecipeError
private boolean hasRecipeError()
-