public abstract class GUI extends Object implements org.bukkit.inventory.InventoryHolder
| Modifier and Type | Field and Description |
|---|---|
protected org.bukkit.inventory.Inventory |
inventory |
protected org.bukkit.entity.Player |
openFor |
protected @Nullable GUITemplate |
template |
| Constructor and Description |
|---|
GUI(@NotNull GUITemplate template,
@NotNull org.bukkit.entity.Player openFor) |
GUI(int rows,
String title,
org.bukkit.entity.Player openFor) |
GUI(int rows,
String title,
org.bukkit.entity.Player openFor,
org.bukkit.inventory.ItemStack[] items) |
| Modifier and Type | Method and Description |
|---|---|
void |
addClickHandler(int slot,
Consumer<org.bukkit.event.inventory.InventoryClickEvent> handler) |
protected List<Integer> |
getEmptySlots() |
@NotNull org.bukkit.inventory.Inventory |
getInventory() |
abstract void |
handleClick(org.bukkit.event.inventory.InventoryClickEvent event) |
abstract void |
handleDrag(org.bukkit.event.inventory.InventoryDragEvent event) |
void |
onClick(org.bukkit.event.inventory.InventoryClickEvent event) |
void |
onClose(org.bukkit.event.inventory.InventoryCloseEvent event) |
void |
onDrag(@NotNull org.bukkit.event.inventory.InventoryDragEvent event) |
void |
removeOnClose() |
void |
setOnClose(Consumer<org.bukkit.event.inventory.InventoryCloseEvent> onClose) |
void |
show() |
@Nullable protected @Nullable GUITemplate template
protected final org.bukkit.inventory.Inventory inventory
protected final org.bukkit.entity.Player openFor
public GUI(int rows,
String title,
org.bukkit.entity.Player openFor)
public GUI(int rows,
String title,
org.bukkit.entity.Player openFor,
org.bukkit.inventory.ItemStack[] items)
public GUI(@NotNull
@NotNull GUITemplate template,
@NotNull
@NotNull org.bukkit.entity.Player openFor)
public void addClickHandler(int slot,
Consumer<org.bukkit.event.inventory.InventoryClickEvent> handler)
public void setOnClose(Consumer<org.bukkit.event.inventory.InventoryCloseEvent> onClose)
public void removeOnClose()
public abstract void handleClick(org.bukkit.event.inventory.InventoryClickEvent event)
public abstract void handleDrag(org.bukkit.event.inventory.InventoryDragEvent event)
public final void onClick(org.bukkit.event.inventory.InventoryClickEvent event)
public final void onDrag(@NotNull
@NotNull org.bukkit.event.inventory.InventoryDragEvent event)
@NotNull public @NotNull org.bukkit.inventory.Inventory getInventory()
getInventory in interface org.bukkit.inventory.InventoryHolderpublic final void onClose(org.bukkit.event.inventory.InventoryCloseEvent event)
public void show()
Copyright © 2023. All rights reserved.