Interface ItemWidget

All Superinterfaces:
Actionable, Clickable, Identifiable, Interactable, Item, Nameable, Renderable, Validatable

public interface ItemWidget extends Item, Interactable
Items that are displayed via a widget like bank, inventory and equipment items.
  • Method Details

    • getIndex

      int getIndex()
      Gets the index of this item widget.
      Returns:
      int
    • getX

      int getX()
      Gets the x-coordinate of this item on screen.
      Returns:
      int
    • getY

      int getY()
      Gets the y-coordinate of this item on screen.
      Returns:
      int
    • getLocation

      default Point getLocation()
      Gets the x and y-coordinate of this item on screen.
      Returns:
      Point
    • getWidth

      int getWidth()
      Gets the width of this item on screen.
      Returns:
      int
    • getHeight

      int getHeight()
      Gets the height of this item on screen.
      Returns:
      int
    • getBounds

      default Rectangle getBounds()
      Gets the bounding rectangle of this item.
      Returns:
      Rectangle, if not visible, this returns a Rectangle with its properties set to -1