Class GuiButton

Object
GuiButton
All Implemented Interfaces:
GuiButtonInterface

public class GuiButton extends Object implements GuiButtonInterface
Represents a button in a GUI.

A GuiButton wraps an ItemStack and optional click behavior. It supports:

  • Setting item metadata (name, lore, amount, flags)
  • Adding/removing enchantments
  • A click listener
  • An optional redirect to another menu after click
  • An optional click sound
All setter-like methods return this for fluent chaining.