Interface RenderItemDecorationsCallback
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Event<RenderItemDecorationsCallback> Fires at the end ofGuiGraphics.renderItemDecorations(Font, ItemStack, int, int, String)and allows for drawing custom item stack decorations. -
Method Summary
Modifier and TypeMethodDescriptionvoidonRenderItemDecorations(net.minecraft.client.gui.GuiGraphics graphics, net.minecraft.client.gui.Font font, net.minecraft.world.item.ItemStack stack, int x, int y)
-
Field Details
-
EVENT
Fires at the end ofGuiGraphics.renderItemDecorations(Font, ItemStack, int, int, String)and allows for drawing custom item stack decorations.In vanilla these are: durability bar, cooldown overlay and stack count.
-
-
Method Details
-
onRenderItemDecorations
void onRenderItemDecorations(net.minecraft.client.gui.GuiGraphics graphics, net.minecraft.client.gui.Font font, net.minecraft.world.item.ItemStack stack, int x, int y) - Parameters:
graphics- theGuiGraphicsinstancefont- the fontstack- the item stackx- the x-position of the item stacky- the y-position of the item stack
-