GUIBuilder

class GUIBuilder<T : ForInventory>(type: GUIType<T>, guiCreator: GUICreator<T>)

Functions

onClickElement
Link copied to clipboard
fun onClickElement(onClick: (GUIClickEvent<T>) -> Unit)
A callback executed when the user clicks on any GUI elements on any page in this GUI.
page
Link copied to clipboard
fun page(page: Int, builder: GUIPageBuilder<T>.() -> Unit)
Opens the builder for a new page and adds the new page to the GUI.

Properties

defaultPage
Link copied to clipboard
var defaultPage: Int = 1
The default page will be loaded first for every GUI instance.
title
Link copied to clipboard
var title: String
The title of this GUI.
transitionFrom
Link copied to clipboard
var transitionFrom: InventoryChangeEffect? = null
The transition applied, if this GUI redirects to another GUI and the other GUI has no transitionTo value defined.
transitionTo
Link copied to clipboard
var transitionTo: InventoryChangeEffect? = null
The transition applied, if another GUI redirects to this GUI.
type
Link copied to clipboard
val type: GUIType<T>