### start Source: https://projectunified.github.io/UniDialog/index-all.html Sets the starting value for a number range input. This is applicable for dialog inputs that involve a numerical range. ```APIDOC ## start ### Description Set the start value of the range. ### Method - `start(float startValue)` ### Parameters #### Path Parameters - **startValue** (float) - Required - The starting value for the number range. ``` -------------------------------- ### AdventureSupport Interface Methods Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/adventure/support/AdventureSupport.html Provides methods to get the component deserializer function and to deserialize a string into an Adventure Component. ```APIDOC ## getComponentDeserializer ### Description Get the deserializer function that converts a string to a `Component`. ### Method `Function` ### Returns the function that deserializes a string into a Component ## deserialize ### Description Applies the deserializer to the given input string to convert it into a `Component`. ### Method `default net.kyori.adventure.text.Component deserialize(String input)` ### Parameters #### Path Parameters - **input** (String) - Required - the input string to be deserialized ### Returns the deserialized `Component` ``` -------------------------------- ### PENumberRangeInput Configuration Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/packetevents/input/PENumberRangeInput.html This section details the methods available for configuring a number range input. These methods allow setting the start, end, initial, and step values, as well as the label and width of the input. ```APIDOC ## PENumberRangeInput Methods ### `width(int width)` Set the width of the input. **Parameters:** - `width` (int) - The desired width of the input. **Returns:** - `PENumberRangeInput` - The current instance for method chaining. ### `label(net.kyori.adventure.text.Component label)` Set the label for the input. **Parameters:** - `label` (net.kyori.adventure.text.Component) - The label text to display. **Returns:** - `PENumberRangeInput` - The current instance for method chaining. ### `labelFormat(String labelFormat)` Set the format for the label. **Parameters:** - `labelFormat` (String) - The format string for the label. **Returns:** - `PENumberRangeInput` - The current instance for method chaining. ### `start(float start)` Set the start value of the range. **Parameters:** - `start` (float) - The starting value of the range. **Returns:** - `PENumberRangeInput` - The current instance for method chaining. ### `end(float end)` Set the end value of the range. **Parameters:** - `end` (float) - The ending value of the range. **Returns:** - `PENumberRangeInput` - The current instance for method chaining. ### `initial(Float initial)` Set the initial value of the range. **Parameters:** - `initial` (Float) - The initial value, can be null. **Returns:** - `PENumberRangeInput` - The current instance for method chaining. ### `step(Float step)` Set the step value for the range. **Parameters:** - `step` (Float) - The step value, can be null. **Returns:** - `PENumberRangeInput` - The current instance for method chaining. ### `getInput()` Retrieves the input control associated with this number range. **Returns:** - `com.github.retrooper.packetevents.protocol.dialog.input.InputControl` - The InputControl object. ``` -------------------------------- ### PEItemBody Configuration Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/packetevents/body/PEItemBody.html This snippet shows how to construct and configure a PEItemBody. It demonstrates setting the item, description, dimensions, and display properties. ```APIDOC ## PEItemBody Configuration ### Description This section details the methods for configuring a `PEItemBody`, allowing you to set the item to be displayed, its description, dimensions, and visual properties. ### Constructor `PEItemBody(Function componentDeserializer)` ### Methods #### `item(com.github.retrooper.packetevents.protocol.item.ItemStack item)` Set the item for the body. #### `description(@Nullable Consumer descriptionBuilder)` Set the description for the body using a consumer to build the text. #### `showDecorations(boolean showDecorations)` Set whether to show decorations in the item body. #### `showTooltip(boolean showTooltip)` Set whether to show a tooltip for the item. #### `width(int width)` Set the width of the item body. #### `height(int height)` Set the height of the item body. #### `getDialogBody()` Retrieves the underlying `DialogBody` instance. ``` -------------------------------- ### Get Dialog Type Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/paper/dialog/PaperDialogListDialog.html Retrieves the dialog type of this dialog. ```APIDOC ## Method getDialogType ### Description Retrieves the dialog type of this dialog. ### Method `getDialogType()` ### Returns `io.papermc.paper.registry.data.dialog.type.DialogType` - The dialog type. ``` -------------------------------- ### PEBooleanInput Configuration Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/packetevents/input/PEBooleanInput.html This snippet shows how to instantiate and configure a PEBooleanInput, setting its label, initial value, and text for true/false conditions. ```APIDOC ## PEBooleanInput ### Description Represents a boolean input field within a dialog. ### Constructor `PEBooleanInput(Function componentDeserializer)` ### Methods #### `label(net.kyori.adventure.text.Component label)` Sets the label for the boolean input. #### `initial(boolean initial)` Sets the initial state of the boolean input (true or false). #### `onTrue(String onTrue)` Sets the text to be displayed or sent when the input is evaluated as true. #### `onFalse(String onFalse)` Sets the text to be displayed or sent when the input is evaluated as false. #### `getInput()` Retrieves the input control associated with this boolean input. ``` -------------------------------- ### Get Dialog Input Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/bungeecord/input/BungeeSingleOptionInput.html Retrieves the underlying DialogInput object. ```APIDOC ## getDialogInput() ### Description Returns the DialogInput representation of this input. ### Returns - `net.md_5.bungee.api.dialog.input.DialogInput` - The DialogInput object. ``` -------------------------------- ### BungeeSingleOptionInput Constructor Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/bungeecord/input/BungeeSingleOptionInput.html Initializes a new instance of the BungeeSingleOptionInput class with a specified key. ```APIDOC ## BungeeSingleOptionInput(String key) ### Description Constructs a new BungeeSingleOptionInput with the given key. ### Parameters - **key** (String) - The unique identifier for this input. ``` -------------------------------- ### BungeeDialogInputBuilder Constructor Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/bungeecord/input/BungeeDialogInputBuilder.html Initializes a new instance of the BungeeDialogInputBuilder with a specified key. ```APIDOC ## BungeeDialogInputBuilder(String key) ### Description Initializes a new instance of the BungeeDialogInputBuilder. ### Parameters #### Path Parameters - **key** (String) - Required - The key associated with this input builder. ``` -------------------------------- ### Get Dialog Body Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/packetevents/body/PEDialogBodyBuilder.html Retrieves the underlying dialog body instance. ```APIDOC ## Method ### getDialogBody ```java public com.github.retrooper.packetevents.protocol.dialog.body.DialogBody getDialogBody() ``` Specified by: `getDialogBody` in interface `PEDialogBody` ``` -------------------------------- ### Create Notice Dialog Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/paper/PaperDialogManager.html Creates and returns a new instance of a notice dialog, used for displaying informational messages or alerts to the player. ```APIDOC ## createNoticeDialog ### Description Create a notice dialog. ### Method public PaperNoticeDialog createNoticeDialog() ### Returns a new instance of NoticeDialog ``` -------------------------------- ### Get PacketEvents Dialog Instance Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/packetevents/dialog/PEDialog.html Retrieves the underlying PacketEvents Dialog object. ```java final com.github.retrooper.packetevents.protocol.dialog.Dialog getDialog() ``` -------------------------------- ### Get Component Deserializer Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/packetevents/dialog/PEDialog.html Retrieves the function used to deserialize a string into a net.kyori.adventure.text.Component. ```java Function getComponentDeserializer() ``` -------------------------------- ### showDialog Source: https://projectunified.github.io/UniDialog/index-all.html Configures the action to display a dialog. This can be done by providing a dialog instance, an opener, or a string pair for title and content. Supported across multiple platforms. ```APIDOC ## showDialog ### Description Sets the action to be a show dialog action. This can be configured in several ways: - By providing a dialog instance. - By providing a `DialogOpener`. - By providing a title and content string pair. ### Method - `showDialog(D dialog)` - `showDialog(DialogOpener opener)` - `showDialog(String title, String content)` ### Parameters #### Path Parameters - **dialog** (D) - Required - The dialog instance to show. - **opener** (DialogOpener) - Required - An object that opens the dialog. - **title** (String) - Required - The title of the dialog. - **content** (String) - Required - The content of the dialog. ``` -------------------------------- ### Get Action for Dialog Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/packetevents/dialog/PEDialog.html Retrieves an ActionButton for the dialog, configured by the provided action builder. ```java protected com.github.retrooper.packetevents.protocol.dialog.button.ActionButton getAction(Consumer action) ``` -------------------------------- ### PaperSingleOptionInput Constructor Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/paper/input/PaperSingleOptionInput.html Initializes a new instance of the PaperSingleOptionInput class. ```APIDOC ## PaperSingleOptionInput Constructor ### Description Initializes a new instance of the PaperSingleOptionInput class with a key and a component deserializer. ### Parameters - **key** (String) - The unique identifier for the input. - **componentDeserializer** (Function) - A function to deserialize component strings. ``` -------------------------------- ### Using BungeeDialogActionBuilder in Dialogs Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/bungeecord/action/class-use/BungeeDialogActionBuilder.html Examples of how BungeeDialogActionBuilder is used as a parameter in various dialog types. ```APIDOC ## Dialog Action Consumers ### `BungeeMultiActionDialog.action(Consumer action)` Adds an action to a multi-action dialog. ### `BungeeNoticeDialog.action(Consumer action)` Adds an action to a notice dialog. ### `BungeeDialogListDialog.exitAction(Consumer action)` Sets the exit action for a dialog list dialog. ### `BungeeMultiActionDialog.exitAction(Consumer action)` Sets the exit action for a multi-action dialog. ### `BungeeServerLinksDialog.exitAction(Consumer action)` Sets the exit action for a server links dialog. ### `BungeeDialog.getAction(Consumer action)` Retrieves an action builder for a dialog. ### `BungeeConfirmationDialog.noAction(Consumer action)` Sets the 'no' action for a confirmation dialog. ### `BungeeConfirmationDialog.yesAction(Consumer action)` Sets the 'yes' action for a confirmation dialog. ``` -------------------------------- ### open(User user, boolean configuration) Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/packetevents/opener/PEDialogOpener.html Opens a dialog for a specified user, with an option to designate it as a configuration dialog. ```APIDOC ## POST open(User user, boolean configuration) ### Description Open the dialog for a user, optionally specifying if it is a configuration dialog. ### Parameters * **user** (com.github.retrooper.packetevents.protocol.player.User) - The user to open the dialog for. * **configuration** (boolean) - If true, opens as a configuration dialog; if false, opens as a play dialog. ### Response #### Success Response (void) This method does not return a value. ``` -------------------------------- ### Get Dialog Component Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/paper/opener/PaperDialogOpener.html Returns the value of the 'dialog' record component. This is the io.papermc.paper.dialog.Dialog instance associated with this opener. ```java public io.papermc.paper.dialog.Dialog dialog() ``` -------------------------------- ### Get Dialog Action Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/bungeecord/dialog/BungeeDialog.html Retrieves an ActionButton configured by the provided BungeeDialogActionBuilder. This is used internally for handling dialog actions. ```java protected net.md_5.bungee.api.dialog.action.ActionButton getAction(Consumer action) ``` -------------------------------- ### AdventureSingleOptionInput Methods Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/adventure/input/AdventureSingleOptionInput.html This snippet details the methods available for setting labels and options on an AdventureSingleOptionInput. ```APIDOC ## AdventureSingleOptionInput ### Description An extension of `SingleOptionInput` that provides additional methods for handling `Component` labels and options. ### Methods #### `label` Set the label for the input using Adventure `Component`. * **Method:** `label(net.kyori.adventure.text.Component label)` * **Parameters:** * `label` (net.kyori.adventure.text.Component) - Required - The label text as an Adventure Component. * **Returns:** The current instance for method chaining. #### `label` (String overload) Set the label for the input using a String. * **Method:** `label(String label)` * **Parameters:** * `label` (String) - Required - The label text. * **Returns:** The current instance for method chaining. #### `option` Add an option to the input with an Adventure `Component` display. * **Method:** `option(String id, net.kyori.adventure.text.Component display, boolean isDefault)` * **Parameters:** * `id` (String) - Required - The identifier for the option. * `display` (net.kyori.adventure.text.Component) - Required - The display text for the option as an Adventure Component. * `isDefault` (boolean) - Required - Whether this option is the default selection. * **Returns:** The current instance for method chaining. #### `option` (String display overload) Add an option to the input with a String display. * **Method:** `option(String id, String display, boolean isDefault)` * **Parameters:** * `id` (String) - Required - The identifier for the option. * `display` (String) - Required - The display text for the option. * `isDefault` (boolean) - Required - Whether this option is the default selection. * **Returns:** The current instance for method chaining. #### `option` (Component display, no default overload) Add an option to the input with an Adventure `Component` display, not marked as default. * **Method:** `option(String id, net.kyori.adventure.text.Component display)` * **Parameters:** * `id` (String) - Required - The identifier for the option. * `display` (net.kyori.adventure.text.Component) - Required - The display text for the option as an Adventure Component. * **Returns:** The current instance for method chaining. ``` -------------------------------- ### BungeeBooleanInput Constructor Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/bungeecord/input/BungeeBooleanInput.html Initializes a new instance of the BungeeBooleanInput class with a specified key. ```APIDOC ## BungeeBooleanInput Constructor ### Description Initializes a new instance of the BungeeBooleanInput class. ### Parameters * **key** (String) - Required - The unique key for this input. ### Returns A new instance of BungeeBooleanInput. ``` -------------------------------- ### AdventureBooleanInput Methods Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/adventure/input/AdventureBooleanInput.html This section details the methods available on the AdventureBooleanInput interface, including setting labels with String or Component types. ```APIDOC ## label(Component label) ### Description Set the label for the input using an Adventure Component. ### Method ```java AdventureBooleanInput label(net.kyori.adventure.text.Component label) ``` ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body None ### Request Example ```java // Assuming 'builder' is an instance of AdventureBooleanInput builder.label(Component.text("My Label")); ``` ### Response #### Success Response (200) Returns the current instance for method chaining. #### Response Example ```java // Returns the builder instance ``` ## label(String label) ### Description Set the label for the input using a String. This method is inherited from BooleanInput. ### Method ```java default T label(String label) ``` ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body None ### Request Example ```java // Assuming 'builder' is an instance of AdventureBooleanInput builder.label("My Label"); ``` ### Response #### Success Response (200) Returns the current instance for method chaining. #### Response Example ```java // Returns the builder instance ``` ``` -------------------------------- ### Get BungeeDialog Instance Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/bungeecord/dialog/BungeeDialog.html Returns the underlying BungeeCord Dialog instance. This method is final and provides access to the core dialog object. ```java public final net.md_5.bungee.api.dialog.Dialog getDialog() ``` -------------------------------- ### SpigotDialogOpener Constructor Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/spigot/opener/SpigotDialogOpener.html Initializes a new instance of the SpigotDialogOpener class. ```APIDOC ## SpigotDialogOpener(Dialog dialog) ### Description Initializes a new instance of the SpigotDialogOpener class. ### Parameters * **dialog** (Dialog) - The dialog instance to be opened. ``` -------------------------------- ### BungeeNumberRangeInput Methods Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/bungeecord/input/BungeeNumberRangeInput.html Provides methods for configuring the number range input, including setting start, end, step, initial values, labels, and width. ```APIDOC ## BungeeNumberRangeInput Methods ### width ```java public BungeeNumberRangeInput width(int width) ``` #### Description Set the width of the input. #### Parameters - **width** (int) - Required - The width of the input. #### Returns - the current instance for method chaining. ### label (BaseComponent) ```java public BungeeNumberRangeInput label(net.md_5.bungee.api.chat.BaseComponent label) ``` #### Description Set the label for the input. #### Parameters - **label** (BaseComponent) - Required - The label text. #### Returns - the current instance for method chaining. ### label (String) ```java public BungeeNumberRangeInput label(String label) ``` #### Description Set the label for the input. #### Parameters - **label** (String) - Required - The label text. #### Returns - the current instance for method chaining. ### labelFormat ```java public BungeeNumberRangeInput labelFormat(String labelFormat) ``` #### Description Set the format for the label. #### Parameters - **labelFormat** (String) - Required - The format string for the label. #### Returns - the current instance for method chaining. ### start ```java public BungeeNumberRangeInput start(float start) ``` #### Description Set the start value of the range. #### Parameters - **start** (float) - Required - The start value. #### Returns - the current instance for method chaining. ### end ```java public BungeeNumberRangeInput end(float end) ``` #### Description Set the end value of the range. #### Parameters - **end** (float) - Required - The end value. #### Returns - the current instance for method chaining. ### initial ```java public BungeeNumberRangeInput initial(@Nullable Float initial) ``` #### Description Set the initial value of the range. #### Parameters - **initial** (Float) - Optional - The initial value, can be null. #### Returns - the current instance for method chaining. ### step ```java public BungeeNumberRangeInput step(@Nullable Float step) ``` #### Description Set the step value for the range. #### Parameters - **step** (Float) - Optional - The step value, can be null. #### Returns - the current instance for method chaining. ``` -------------------------------- ### BungeeTextInput Constructor Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/bungeecord/input/BungeeTextInput.html Initializes a new instance of the BungeeTextInput class with a specified key. ```APIDOC ## BungeeTextInput(String key) ### Description Initializes a new instance of the BungeeTextInput class. ### Parameters * **key** (String) - The unique key for this input element. ``` -------------------------------- ### DialogPayload Methods Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/core/payload/DialogPayload.html Provides methods to access data within a dialog payload. These methods allow you to retrieve specific values by key or get all values as a map. ```APIDOC ## DialogPayload Interface The payload which is sent back to the server when the player run a custom action in the dialog. ### Methods #### owner `UUID owner()` Get the owner of the payload. * **Returns**: the id of the owner. #### textValue `@Nullable String textValue(String key)` Get the text value from the payload. * **Parameters**: * `key` (String) - Required - the key to search for. * **Returns**: the text, or null if the key doesn't exist in the payload. #### booleanValue `@Nullable Boolean booleanValue(String key)` Get the boolean value from the payload. * **Parameters**: * `key` (String) - Required - the key to search for. * **Returns**: the boolean, or null if the key doesn't exist in the payload. #### numberValue `@Nullable Number numberValue(String key)` Get the number value from the payload. * **Parameters**: * `key` (String) - Required - the key to search for. * **Returns**: the number, or null if the key doesn't exist in the payload or the value is not a number. #### map `Map map()` Get the map of all values in the payload. * **Returns**: the map. ``` -------------------------------- ### PaperNumberRangeInput Configuration Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/paper/input/PaperNumberRangeInput.html This snippet outlines the methods available to configure a PaperNumberRangeInput, including setting the start, end, initial, step, label, label format, and width of the input. ```APIDOC ## PaperNumberRangeInput Methods ### Description Provides methods to configure a number range input for use in a dialog. ### Methods - **`start(float start)`** - Description: Set the start value of the range. - Returns: `PaperNumberRangeInput` for chaining. - **`end(float end)`** - Description: Set the end value of the range. - Returns: `PaperNumberRangeInput` for chaining. - **`initial(@Nullable Float initial)`** - Description: Set the initial value of the range. - Returns: `PaperNumberRangeInput` for chaining. - **`step(@Nullable Float step)`** - Description: Set the step value for the range. - Returns: `PaperNumberRangeInput` for chaining. - **`label(net.kyori.adventure.text.Component label)`** - Description: Set the label for the input. - Returns: `PaperNumberRangeInput` for chaining. - **`labelFormat(String labelFormat)`** - Description: Set the format for the label. - Returns: `PaperNumberRangeInput` for chaining. - **`width(int width)`** - Description: Set the width of the input. - Returns: `PaperNumberRangeInput` for chaining. - **`getDialogInput()`** - Description: Retrieves the underlying dialog input object. - Returns: `io.papermc.paper.registry.data.dialog.input.DialogInput` ``` -------------------------------- ### runCommand(String command) Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/bungeecord/action/BungeeDialogActionBuilder.html Configures the action to execute a given command. This method adheres to the builder pattern for fluent API usage. ```APIDOC ## runCommand(String command) ### Description Sets the action to be a run command action. ### Method public BungeeDialogActionBuilder runCommand(String command) ### Parameters #### Path Parameters - **command** (String) - The command to run. ### Returns the current instance of the builder for method chaining ``` -------------------------------- ### SingleOptionInput Configuration Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/core/input/SingleOptionInput.html This snippet demonstrates how to use the methods available in the SingleOptionInput interface to configure a single option input. It shows setting the label, adding options (including a default one), and setting the input width. ```APIDOC ## SingleOptionInput Methods ### Description Provides methods to configure a single option input for a dialog, allowing users to select one option from a list. ### Methods - **`label(String label)`**: Sets the text label for the input. - **`option(String id, String display)`**: Adds an option with a unique identifier and display text. - **`option(String id, String display, boolean isDefault)`**: Adds an option and designates it as the default selection. - **`width(int width)`**: Sets the display width of the input. ### Type Parameters - `T`: The type of the implementing class, used for method chaining. ### Example Usage ```java // Assuming 'input' is an instance of a class implementing SingleOptionInput input.label("Choose your favorite color") .option("red", "Red", true) .option("blue", "Blue") .option("green", "Green") .width(200); ``` ### Field Details - **`DEFAULT_WIDTH`**: A static final integer representing the default width for the input. ``` -------------------------------- ### open(Player player) Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/spigot/opener/SpigotDialogOpener.html Opens the dialog for the specified Bukkit Player. ```APIDOC ## open(Player player) ### Description Opens the dialog for the specified Bukkit Player. ### Method void ### Parameters * **player** (org.bukkit.entity.Player) - The player to open the dialog for. ``` -------------------------------- ### NumberRangeInput Configuration Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/core/input/NumberRangeInput.html This snippet demonstrates how to configure a number range input using the NumberRangeInput interface. It shows setting various properties like width, label, start, end, initial, and step values. ```APIDOC ## NumberRangeInput Configuration ### Description This section details the methods available for configuring a number range input. These methods allow for setting the dimensions, labels, and the numerical range itself. ### Methods - **`width(int width)`** Set the width of the input. - **Parameters**: - `width` (int) - Required - The desired width of the input. - **Returns**: - The current instance (`T`) for method chaining. - **`label(String label)`** Set the label for the input. - **Parameters**: - `label` (String) - Required - The text to be displayed as the label. - **Returns**: - The current instance (`T`) for method chaining. - **`labelFormat(String labelFormat)`** Set the format for the label. - **Parameters**: - `labelFormat` (String) - Required - The format string for the label. - **Returns**: - The current instance (`T`) for method chaining. - **`start(float start)`** Set the start value of the range. - **Parameters**: - `start` (float) - Required - The starting value of the numerical range. - **Returns**: - The current instance (`T`) for method chaining. - **`end(float end)`** Set the end value of the range. - **Parameters**: - `end` (float) - Required - The ending value of the numerical range. - **Returns**: - The current instance (`T`) for method chaining. - **`initial(@Nullable Float initial)`** Set the initial value of the range. - **Parameters**: - `initial` (Float) - Optional - The initial value, which can be null. - **Returns**: - The current instance (`T`) for method chaining. - **`step(@Nullable Float step)`** Set the step value for the range. - **Parameters**: - `step` (Float) - Optional - The step value, which can be null. - **Returns**: - The current instance (`T`) for method chaining. ### Example Usage (Conceptual) ```java // Assuming 'input' is an instance of a class implementing NumberRangeInput input.width(200) .label("Age") .start(18) .end(65) .initial(25) .step(1.0f); ``` ``` -------------------------------- ### showDialog(String namespace, String dialogId) Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/bungeecord/action/BungeeDialogActionBuilder.html Sets the action to display a dialog identified by its namespace and ID. This method facilitates the builder pattern for fluent configuration. ```APIDOC ## showDialog(String namespace, String dialogId) ### Description Sets the action to be a show dialog action with a namespace and dialog ID. ### Method public BungeeDialogActionBuilder showDialog(String namespace, String dialogId) ### Parameters #### Path Parameters - **namespace** (String) - The namespace of the dialog. - **dialogId** (String) - The identifier of the dialog to show. ### Returns the current instance of the builder for method chaining ``` -------------------------------- ### PETextInput Constructor Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/packetevents/input/PETextInput.html Initializes a new instance of the PETextInput class with a component deserializer. ```APIDOC ## PETextInput Constructor ### Description Initializes a new instance of the PETextInput class. ### Parameters * **componentDeserializer** (Function) - A function to deserialize string components into Adventure text components. ``` -------------------------------- ### suggestCommand Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/paper/action/PaperDialogActionBuilder.html Sets the action to suggest a command to the player. This method is part of the builder pattern for fluent interfaces. ```APIDOC ## suggestCommand ### Description Set the action to be a suggest command action. ### Method public PaperDialogActionBuilder suggestCommand(String command) ### Parameters #### Path Parameters - **command** (String) - Required - the command to suggest ### Returns the current instance of the builder for method chaining ``` -------------------------------- ### Constructor: BungeeDialogOpener Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/bungeecord/opener/BungeeDialogOpener.html Protected constructor for BungeeDialogOpener. It initializes the opener with a BungeeCord Dialog instance. ```APIDOC ## Constructor ### BungeeDialogOpener ```java protected BungeeDialogOpener(net.md_5.bungee.api.dialog.Dialog dialog) ``` **Description:** Protected constructor used to create an instance of BungeeDialogOpener. It requires a `net.md_5.bungee.api.dialog.Dialog` object to be passed during initialization. ``` -------------------------------- ### BooleanInput Configuration Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/core/input/BooleanInput.html This snippet demonstrates how to configure a boolean input using its available methods for setting the label, initial value, and responses for true and false selections. ```APIDOC ## BooleanInput Configuration ### Description Configures a boolean input for a dialog, allowing users to set a label, an initial value, and specific text responses for 'true' and 'false' outcomes. ### Methods #### label Sets the display label for the boolean input. - **Parameters** - `label` (String) - Required - The text to be displayed as the label for the input. #### initial Sets the initial state of the boolean input. - **Parameters** - `initial` (boolean) - Required - The default value (true or false) for the input. #### onTrue Sets the response text when the input evaluates to true. - **Parameters** - `onTrue` (String) - Required - The text to send when the user's input is considered true. #### onFalse Sets the response text when the input evaluates to false. - **Parameters** - `onFalse` (String) - Required - The text to send when the user's input is considered false. ### Example Usage ```java // Assuming BooleanInput is implemented by a class like BungeeBooleanInput BungeeBooleanInput booleanInput = new BungeeBooleanInput(); booleanInput .label("Do you agree?") .initial(true) .onTrue("Agreed!") .onFalse("Not agreed."); ``` ``` -------------------------------- ### suggestCommand Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/packetevents/action/PEDialogActionBuilder.html Sets the action to be a suggest command action, providing a command suggestion to the user. ```APIDOC ## suggestCommand ### Description Sets the action to be a suggest command action. ### Method `PEDialogActionBuilder` ### Parameters * **command** (String) - The command to suggest to the user. ``` -------------------------------- ### suggestCommand(String command) Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/bungeecord/action/BungeeDialogActionBuilder.html Sets the action to suggest a command to the user, typically for auto-completion. ```APIDOC ## suggestCommand(String command) ### Description Set the action to be a suggest command action. ### Parameters * `command` (String) - the command to suggest ### Returns * `BungeeDialogActionBuilder` - the current instance of the builder for method chaining. ``` -------------------------------- ### Configuration Methods Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/bungeecord/dialog/BungeeDialogListDialog.html Methods for configuring the appearance and behavior of the dialog list. ```APIDOC ## Method exitAction ### Description Sets the action to be performed when exiting the dialog. ### Method `exitAction(@Nullable Consumer action)` ### Parameters * **action** (Consumer) - Optional - The action to be performed when exiting the dialog. ### Returns * BungeeDialogListDialog - The dialog itself for method chaining. ``` ```APIDOC ## Method columns ### Description Sets the number of columns in the dialog. ### Method `columns(int columns)` ### Parameters * **columns** (int) - Required - The number of columns in the dialog. ### Returns * BungeeDialogListDialog - The dialog itself for method chaining. ``` ```APIDOC ## Method buttonWidth ### Description Sets the width of the buttons in the dialog. ### Method `buttonWidth(int buttonWidth)` ### Parameters * **buttonWidth** (int) - Required - The width of the buttons in the dialog. ### Returns * BungeeDialogListDialog - The dialog itself for method chaining. ``` -------------------------------- ### showDialog(DialogOpener dialogOpener) Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/bungeecord/action/BungeeDialogActionBuilder.html Sets the action to display a dialog using a DialogOpener. ```APIDOC ## showDialog(DialogOpener dialogOpener) ### Description Set the action to be a show dialog action. ### Parameters * `dialogOpener` (DialogOpener) - the dialog opener to use ### Returns * `BungeeDialogActionBuilder` - the current instance of the builder for method chaining. ``` -------------------------------- ### opener() Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/paper/dialog/PaperDialog.html Creates and returns a dialog opener for this dialog. The opener is used to initiate and manage the display of the dialog to the user. ```APIDOC ## opener() ### Description Create an opener for the dialog. ### Method public PaperDialogOpener opener ### Returns - **PaperDialogOpener** - the dialog opener ``` -------------------------------- ### Create Server Links Dialog Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/paper/PaperDialogManager.html Creates and returns a new instance of a server links dialog, typically used for displaying clickable links to server resources or information. ```APIDOC ## createServerLinksDialog ### Description Create a server links dialog. ### Method public PaperServerLinksDialog createServerLinksDialog() ### Returns a new instance of ServerLinksDialog ``` -------------------------------- ### BungeeItemBody Construction and Configuration Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/bungeecord/body/BungeeItemBody.html This section covers the methods for creating and customizing BungeeItemBody instances, including setting the item, description, dimensions, and display options. ```APIDOC ## BungeeItemBody Methods ### Description Provides methods to construct and configure an item body for BungeeCord dialogs. ### Methods #### `item(Object item)` Set the item for the body. - **item** (Object) - Required - The item to set. - Returns: The instance of the item body for method chaining. #### `description(@Nullable Consumer descriptionBuilder)` Set the description for the body. - **descriptionBuilder** (Consumer) - Optional - A consumer to build the description. - Returns: The instance of the item body for method chaining. #### `showDecorations(boolean showDecorations)` Set the option to show decorations in the body. - **showDecorations** (boolean) - Required - Whether to show decorations. - Returns: The instance of the item body for method chaining. #### `showTooltip(boolean showTooltip)` Set the option to show a tooltip in the body. - **showTooltip** (boolean) - Required - Whether to show a tooltip. - Returns: The instance of the item body for method chaining. #### `width(int width)` Set the width of the item body. - **width** (int) - Required - The width to set. - Returns: The instance of the item body for method chaining. #### `height(int height)` Set the height of the item body. - **height** (int) - Required - The height to set. - Returns: The instance of the item body for method chaining. #### `getDialogBody()` Retrieves the associated dialog body. - Returns: The `net.md_5.bungee.api.dialog.body.DialogBody` instance. ``` -------------------------------- ### SpigotDialogPayload Constructor Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/spigot/payload/SpigotDialogPayload.html Creates an instance of a SpigotDialogPayload record class. ```APIDOC ## SpigotDialogPayload Constructor ### Description Creates an instance of a `SpigotDialogPayload` record class. ### Parameters - **owner** (UUID) - The UUID of the dialog owner. - **jsonData** (@Nullable JsonElement) - The JSON data associated with the payload. ``` -------------------------------- ### ServerLinksDialog Configuration Methods Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/core/dialog/ServerLinksDialog.html This section details the methods available on the ServerLinksDialog interface for configuring its properties. These methods allow for setting the button width, the number of columns, and defining an exit action. ```APIDOC ## ServerLinksDialog Methods ### `exitAction` Sets the exit action for the dialog. - **Parameters** - `action` (Consumer) - Optional - The action to be performed when exiting the dialog. - **Returns** - `T` - The server links dialog itself for method chaining. ### `columns` Sets the number of columns for the dialog. - **Parameters** - `columns` (int) - The number of columns to set. - **Returns** - `T` - The server links dialog itself for method chaining. ### `buttonWidth` Sets the width of the buttons in the dialog. - **Parameters** - `buttonWidth` (int) - The width of the buttons. - **Returns** - `T` - The server links dialog itself for method chaining. ``` -------------------------------- ### showDialog(DialogOpener dialogOpener) Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/bungeecord/action/BungeeDialogActionBuilder.html Sets the action to display a dialog using a provided DialogOpener. This method is part of the builder pattern for flexible dialog presentation. ```APIDOC ## showDialog(DialogOpener dialogOpener) ### Description Sets the action to be a show dialog action using a DialogOpener. ### Method public BungeeDialogActionBuilder showDialog(DialogOpener dialogOpener) ### Parameters #### Path Parameters - **dialogOpener** (DialogOpener) - The dialog opener to use for showing the dialog. ### Returns the current instance of the builder for method chaining ``` -------------------------------- ### BungeeDialogActionBuilder Constructor Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/bungeecord/action/BungeeDialogActionBuilder.html Initializes a new instance of the BungeeDialogActionBuilder with a default namespace. ```APIDOC ## BungeeDialogActionBuilder(String defaultNamespace) ### Description Initializes a new instance of the BungeeDialogActionBuilder. ### Parameters * `defaultNamespace` (String) - The default namespace for the action. ``` -------------------------------- ### runCommand(String command) Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/bungeecord/action/BungeeDialogActionBuilder.html Sets the action to execute a specific command on the server. ```APIDOC ## runCommand(String command) ### Description Set the action to be a run command action. ### Parameters * `command` (String) - the command to run ### Returns * `BungeeDialogActionBuilder` - the current instance of the builder for method chaining. ``` -------------------------------- ### AdventureDialogActionBuilder Methods Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/adventure/action/AdventureDialogActionBuilder.html This section details the methods available on the AdventureDialogActionBuilder for setting labels and tooltips. ```APIDOC ## label(net.kyori.adventure.text.Component label) ### Description Set the label for the dialog action. ### Method `label` ### Parameters #### Path Parameters - **label** (net.kyori.adventure.text.Component) - Description: the label to set ### Response #### Success Response - **T** - Description: the current instance of the builder for method chaining ## label(String label) ### Description Set the label for the dialog action. This method is inherited from DialogActionBuilder. ### Method `label` ### Parameters #### Path Parameters - **label** (String) - Description: the label to set ### Response #### Success Response - **T** - Description: the current instance of the builder for method chaining ## tooltip(net.kyori.adventure.text.Component tooltip) ### Description Set the tooltip for the dialog action. ### Method `tooltip` ### Parameters #### Path Parameters - **tooltip** (net.kyori.adventure.text.Component) - Description: the tooltip to set, can be null ### Response #### Success Response - **T** - Description: the current instance of the builder for method chaining ## tooltip(String tooltip) ### Description Set the tooltip for the dialog action. This method is inherited from DialogActionBuilder. ### Method `tooltip` ### Parameters #### Path Parameters - **tooltip** (String) - Description: the tooltip to set, can be null ### Response #### Success Response - **T** - Description: the current instance of the builder for method chaining ``` -------------------------------- ### PESingleOptionInput Constructor Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/packetevents/input/PESingleOptionInput.html Initializes a new instance of the PESingleOptionInput class with a component deserializer. ```APIDOC ## Constructor PESingleOptionInput ### Description Initializes a new instance of the PESingleOptionInput class. ### Parameters * **componentDeserializer** (Function) - A function to deserialize component strings. ``` -------------------------------- ### BungeeMultiActionDialog Constructor Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/bungeecord/dialog/BungeeMultiActionDialog.html Initializes a new instance of the BungeeMultiActionDialog class. ```APIDOC ## BungeeMultiActionDialog constructor ### Description Initializes a new instance of the BungeeMultiActionDialog class. ### Parameters * **defaultNamespace** (String) - The default namespace for the dialog. * **openerFunction** (Function) - A function that maps a Dialog to the opener type O. ``` -------------------------------- ### PENoticeDialog Constructor Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/packetevents/dialog/PENoticeDialog.html Initializes a new PENoticeDialog. This constructor is used to create a notice dialog with a default namespace, a component deserializer, and a player function. ```APIDOC ## PENoticeDialog Constructor ### Description Initializes a new PENoticeDialog with the specified default namespace, component deserializer, and player function. ### Signature `public PENoticeDialog(String defaultNamespace, Function componentDeserializer, Function playerFunction)` ### Parameters * **defaultNamespace** (String) - The default namespace for the dialog. * **componentDeserializer** (Function) - A function to deserialize strings into Adventure Components. * **playerFunction** (Function) - A function to retrieve player-related information based on UUID. ``` -------------------------------- ### showDialog(BungeeDialog dialog) Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/bungeecord/action/BungeeDialogActionBuilder.html Sets the action to display another BungeeDialog. ```APIDOC ## showDialog(BungeeDialog dialog) ### Description Set the action to be a show dialog action. ### Parameters * `dialog` (BungeeDialog) - the dialog to show ### Returns * `BungeeDialogActionBuilder` - the current instance of the builder for method chaining. ``` -------------------------------- ### open(User user) Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/packetevents/opener/PEDialogOpener.html Opens a dialog for a specified user, automatically determining if it's a configuration dialog based on connection state. ```APIDOC ## POST open(User user) ### Description Open the dialog for a user, automatically determining if it is a configuration dialog based on the user's connection state. ### Parameters * **user** (com.github.retrooper.packetevents.protocol.player.User) - The user to open the dialog for. ### Response #### Success Response (void) This method does not return a value. ``` -------------------------------- ### runCommand Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/packetevents/action/PEDialogActionBuilder.html Sets the action to be a run command action, executing a specified command. ```APIDOC ## runCommand ### Description Sets the action to be a run command action. ### Method `PEDialogActionBuilder` ### Parameters * **command** (String) - The command to execute. ``` -------------------------------- ### showDialog Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/paper/action/PaperDialogActionBuilder.html Sets the action to display a dialog opened by a DialogOpener. ```APIDOC ## showDialog(DialogOpener dialogOpener) ### Description Sets the action to be a show dialog action. ### Method `PaperDialogActionBuilder` ### Parameters * `dialogOpener` (DialogOpener) - The DialogOpener that will open the dialog. ``` -------------------------------- ### showDialog Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/core/action/DialogActionBuilder.html Sets the action to be a show dialog action, allowing for the display of a dialog with a specified opener. ```APIDOC ## showDialog ### Description Sets the action to be a show dialog action, allowing for the display of a dialog with a specified opener. ### Method `T showDialog(DialogOpener dialogOpener)` ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body None ### Request Example None ### Response #### Success Response Returns the current instance of the builder for method chaining. ### Response Example None ``` -------------------------------- ### BungeeConfirmationDialog Constructor Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/bungeecord/dialog/BungeeConfirmationDialog.html Constructs a new BungeeConfirmationDialog with a default namespace and an opener function. ```APIDOC ## BungeeConfirmationDialog Constructor ### Description Constructs a new BungeeConfirmationDialog with a default namespace and an opener function. ### Parameters * **defaultNamespace** (String) - The default namespace for the dialog. * **openerFunction** (Function) - A function that maps a net.md_5.bungee.api.dialog.Dialog to the opener type O. ``` -------------------------------- ### BungeeDialogListDialog Constructor Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/bungeecord/dialog/BungeeDialogListDialog.html Initializes a new instance of the BungeeDialogListDialog class. ```APIDOC ## BungeeDialogListDialog Constructor ### Description Initializes a new instance of the BungeeDialogListDialog class with a default namespace and an opener function. ### Parameters - **defaultNamespace** (String) - Required - The default namespace for the dialog. - **openerFunction** (Function) - Required - A function that maps a Dialog to an opener of type O. ``` -------------------------------- ### BungeeDialogListDialog Constructor Source: https://projectunified.github.io/UniDialog/io/github/projectunified/unidialog/bungeecord/dialog/BungeeDialogListDialog.html Initializes a new instance of the BungeeDialogListDialog class. ```APIDOC ## Constructor BungeeDialogListDialog ### Description Initializes a new instance of the BungeeDialogListDialog class with a default namespace and an opener function. ### Parameters * **defaultNamespace** (String) - Required - The default namespace for the dialogs. * **openerFunction** (Function) - Required - A function that opens a dialog. ```