ServerboundContainerClickPacketUtil

Util class for attaching and working with the ServerboundContainerClickPacket for user-defined clicks in a GUI by the player.

Types

Link copied to clipboard
data class ContainerClickEvent(var containerId: Int, var stateId: Int, var slotNum: Short, var buttonNum: Byte, var clickType: ServerboundContainerClickPacketUtil.ClickType, var changedSlots: MutableList<ItemStack>, var carriedItem: ItemStack?, var selectedItem: ItemStack?)

Functions

Link copied to clipboard
fun attach(name: String, plugin: JavaPlugin, player: Player, items: MutableMap<Int, ItemStack>, callback: ServerboundContainerClickPacketUtil.ContainerClickEvent.() -> Unit): Boolean

Attach the Event to the Player.