Class AnvilGUI
java.lang.Object
de.placeblock.betterinventories.gui.GUI
de.placeblock.betterinventories.gui.impl.AnvilGUI
- All Implemented Interfaces:
org.bukkit.event.Listener
- Direct Known Subclasses:
TextInputGUI
GUI for creating Anvil GUIs
If you want to receive Text from Anvils you should use
TextInputGUI-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionorg.bukkit.inventory.InventoryCreates the Bukkit Inventory for this GUIgetClickedSection(int slot) Returns the GUISection at a specific slot.intgetSlots()protected List<org.bukkit.inventory.ItemStack>Renders the GUI on a listMethods inherited from class de.placeblock.betterinventories.gui.GUI
getPlayers, getView, onClose, onInventoryClick, onInventoryClose, onInventoryDrag, registerInteractionHandler, reloadViews, render, showPlayer, unregisterInteractionHandler, update, updateViews
-
Constructor Details
-
AnvilGUI
public AnvilGUI(org.bukkit.plugin.Plugin plugin, net.kyori.adventure.text.TextComponent title) Creates a new AnvilGUI- Parameters:
plugin- The plugintitle- The title of the GUI
-
AnvilGUI
public AnvilGUI(org.bukkit.plugin.Plugin plugin, net.kyori.adventure.text.TextComponent title, boolean registerDefaultHandlers) Creates a new AnvilGUI- Parameters:
plugin- The plugintitle- The title of the GUIregisterDefaultHandlers- Wheter to register default-handlers
-
-
Method Details
-
createBukkitInventory
public org.bukkit.inventory.Inventory createBukkitInventory()Creates the Bukkit Inventory for this GUI- Specified by:
createBukkitInventoryin classGUI- Returns:
- The Bukkit Inventory
-
getSlots
public int getSlots() -
renderContent
Renders the GUI on a list- Specified by:
renderContentin classGUI- Returns:
- The List
-
getClickedSection
Returns the GUISection at a specific slot.- Specified by:
getClickedSectionin classGUI- Parameters:
slot- The slot- Returns:
- The GUISection at the slot or null
-