Interface ItemDialogBody
- All Superinterfaces:
DialogBody
An item body for a dialog.
Created via DialogBody.item(ItemStack, PlainMessageDialogBody, boolean, boolean, int, int)
- Since:
- 1.21.7
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic interfaceA builder for an item dialog body. -
Method Summary
Modifier and TypeMethodDescription@Nullable PlainMessageDialogBodyThe description of the body, or null if not set.@Range(from=1L,to=256L) intheight()The height of the item body.item()The item to display in the dialog.booleanWhether to show decorations around the item.booleanWhether to show a tooltip for the item.@Range(from=1L,to=256L) intwidth()The width of the item body.
-
Method Details
-
item
The item to display in the dialog.- Returns:
- the item stack
- Since:
- 1.21.7
-
description
The description of the body, or null if not set.- Returns:
- the description body
- Since:
- 1.21.7
-
showDecorations
@Contract(pure=true) boolean showDecorations()Whether to show decorations around the item.Decorations include damage, itemstack count, etc.
- Returns:
- true if decorations should be shown
- Since:
- 1.21.7
-
showTooltip
@Contract(pure=true) boolean showTooltip()Whether to show a tooltip for the item.- Returns:
- true if a tooltip should be shown
- Since:
- 1.21.7
-
width
@Contract(pure=true) @Range(from=1L,to=256L) int width()The width of the item body.- Returns:
- the width
- Since:
- 1.21.7
-
height
@Contract(pure=true) @Range(from=1L,to=256L) int height()The height of the item body.- Returns:
- the height
- Since:
- 1.21.7
-