GuiCloseEvent

class GuiCloseEvent(val player: Player, val gui: GuiBuilder, val event: InventoryCloseEvent) : EventCustom

Represents an event triggered when a GUI is closed by a player.

This event is fired when a player closes the GUI. It contains information about the player who closed the GUI, the GUI itself, and the original InventoryCloseEvent.

Parameters

player

The player who closed the GUI.

gui

The GuiBuilder that represents the GUI being closed.

event

The original InventoryCloseEvent that triggered this event.

Constructors

Link copied to clipboard
constructor(player: Player, gui: GuiBuilder, event: InventoryCloseEvent)

Types

Link copied to clipboard
object Companion

Properties

Link copied to clipboard
val event: InventoryCloseEvent
Link copied to clipboard
Link copied to clipboard
val player: Player

Functions

Link copied to clipboard
@NotNull
open fun getEventName(): String
Link copied to clipboard
open override fun getHandlers(): HandlerList

Returns the HandlerList associated with this event.

Link copied to clipboard
fun <T> getMeta(key: String): T?

Retrieves the value of the metadata for a specific key.

Link copied to clipboard

Checks if a metadata key exists.

Link copied to clipboard
Link copied to clipboard

Returns the set of all metadata keys.

Link copied to clipboard

Removes the metadata associated with a specific key.

Link copied to clipboard
fun <T> setMeta(key: String, value: T): EventCustom

Sets a value for the metadata with a specific key.