Class ClientBundleTooltip
java.lang.Object
net.minecraft.client.gui.screens.inventory.tooltip.ClientBundleTooltip
- All Implemented Interfaces:
ClientTooltipComponent
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static final Componentprivate static final Componentprivate static final Componentprivate final BundleContentsprivate static final intprivate static final intprivate static final ResourceLocationprivate static final intprivate static final ResourceLocationprivate static final ResourceLocationprivate static final intprivate static final intprivate static final intprivate static final ResourceLocationprivate static final ResourceLocationprivate static final ResourceLocationprivate static final intprivate static final int -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate intprivate static voiddrawEmptyBundleDescriptionText(int pX, int pY, Font pFont, GuiGraphics pGuiGraphics) private voiddrawProgressbar(int pX, int pY, Font pFont, GuiGraphics pGuiGraphics) private voiddrawSelectedItemTooltip(Font pFont, GuiGraphics pGuiGraphics, int pX, int pY, int pWidth) private intgetAmountOfHiddenItems(List<ItemStack> pShownItems) private intgetContentXOffset(int pWidth) private static intprivate static intintprivate intprivate Componentprivate ResourceLocationgetShownItems(int pItemsToShow) intprivate intprivate intprivate voidrenderBundleWithItemsTooltip(Font pFont, int pX, int pY, int pWidth, int pHeight, GuiGraphics pGuiGraphics) private static voidrenderCount(int pSlotX, int pSlotY, int pCount, Font pFont, GuiGraphics pGuiGraphics) private voidrenderEmptyBundleTooltip(Font pFont, int pX, int pY, int pWidth, int pHeight, GuiGraphics pGuiGraphics) voidrenderImage(Font p_194042_, int p_194043_, int p_194044_, int p_368730_, int p_368543_, GuiGraphics p_282522_) private voidrenderSlot(int pSlotIndex, int pX, int pY, List<ItemStack> pShownItems, int pSeed, Font pFont, GuiGraphics pGuiGraphics) private static booleanshouldRenderItemSlot(List<ItemStack> pShownItems, int pSlotIndex) private static booleanshouldRenderSurplusText(boolean pHasEnoughItems, int pCellX, int pCellY) booleanprivate intMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface net.minecraft.client.gui.screens.inventory.tooltip.ClientTooltipComponent
renderText
-
Field Details
-
PROGRESSBAR_BORDER_SPRITE
-
PROGRESSBAR_FILL_SPRITE
-
PROGRESSBAR_FULL_SPRITE
-
SLOT_HIGHLIGHT_BACK_SPRITE
-
SLOT_HIGHLIGHT_FRONT_SPRITE
-
SLOT_BACKGROUND_SPRITE
-
SLOT_MARGIN
private static final int SLOT_MARGIN- See Also:
-
SLOT_SIZE
private static final int SLOT_SIZE- See Also:
-
GRID_WIDTH
private static final int GRID_WIDTH- See Also:
-
PROGRESSBAR_HEIGHT
private static final int PROGRESSBAR_HEIGHT- See Also:
-
PROGRESSBAR_WIDTH
private static final int PROGRESSBAR_WIDTH- See Also:
-
PROGRESSBAR_BORDER
private static final int PROGRESSBAR_BORDER- See Also:
-
PROGRESSBAR_FILL_MAX
private static final int PROGRESSBAR_FILL_MAX- See Also:
-
PROGRESSBAR_MARGIN_Y
private static final int PROGRESSBAR_MARGIN_Y- See Also:
-
BUNDLE_FULL_TEXT
-
BUNDLE_EMPTY_TEXT
-
BUNDLE_EMPTY_DESCRIPTION
-
contents
-
-
Constructor Details
-
ClientBundleTooltip
-
-
Method Details
-
getHeight
- Specified by:
getHeightin interfaceClientTooltipComponent
-
getWidth
- Specified by:
getWidthin interfaceClientTooltipComponent
-
showTooltipWithItemInHand
public boolean showTooltipWithItemInHand()- Specified by:
showTooltipWithItemInHandin interfaceClientTooltipComponent
-
getEmptyBundleBackgroundHeight
-
backgroundHeight
private int backgroundHeight() -
itemGridHeight
private int itemGridHeight() -
getContentXOffset
private int getContentXOffset(int pWidth) -
gridSizeY
private int gridSizeY() -
slotCount
private int slotCount() -
renderImage
public void renderImage(Font p_194042_, int p_194043_, int p_194044_, int p_368730_, int p_368543_, GuiGraphics p_282522_) - Specified by:
renderImagein interfaceClientTooltipComponent
-
renderEmptyBundleTooltip
private void renderEmptyBundleTooltip(Font pFont, int pX, int pY, int pWidth, int pHeight, GuiGraphics pGuiGraphics) -
renderBundleWithItemsTooltip
private void renderBundleWithItemsTooltip(Font pFont, int pX, int pY, int pWidth, int pHeight, GuiGraphics pGuiGraphics) -
getShownItems
-
shouldRenderSurplusText
private static boolean shouldRenderSurplusText(boolean pHasEnoughItems, int pCellX, int pCellY) -
shouldRenderItemSlot
-
getAmountOfHiddenItems
-
renderSlot
private void renderSlot(int pSlotIndex, int pX, int pY, List<ItemStack> pShownItems, int pSeed, Font pFont, GuiGraphics pGuiGraphics) -
renderCount
private static void renderCount(int pSlotX, int pSlotY, int pCount, Font pFont, GuiGraphics pGuiGraphics) -
drawSelectedItemTooltip
private void drawSelectedItemTooltip(Font pFont, GuiGraphics pGuiGraphics, int pX, int pY, int pWidth) -
drawProgressbar
-
drawEmptyBundleDescriptionText
private static void drawEmptyBundleDescriptionText(int pX, int pY, Font pFont, GuiGraphics pGuiGraphics) -
getEmptyBundleDescriptionTextHeight
-
getProgressBarFill
private int getProgressBarFill() -
getProgressBarTexture
-
getProgressBarFillText
-