Package-level declarations

Types

Link copied to clipboard
class CommandBuilder(val name: String)

Builder class used to define and configure commands for the plugin.

Link copied to clipboard
data class CommandContext(val sender: CommandSender, val label: String, val args: List<String>)

Represents the context of a command execution.

Link copied to clipboard

Manages command cooldowns for players or other command senders.

Link copied to clipboard

Registers commands with the Bukkit server's command map.

Functions

Link copied to clipboard
inline fun <T : Any> CommandContext.arg(index: Int): T

Inline extension function for CommandContext that retrieves and parses the argument at the specified index.

fun <T : Any> CommandContext.arg(index: Int, type: KClass<T>): T

Extension function for CommandContext that retrieves and parses the argument at the specified index.

Link copied to clipboard
inline fun <T : Any> CommandContext.argOrDefault(index: Int, default: T): T

Inline extension function for CommandContext that retrieves and parses the argument at the specified index, or returns a default value if the argument is missing.

fun <T : Any> CommandContext.argOrDefault(index: Int, type: KClass<T>, default: T): T

Extension function for CommandContext that retrieves and parses the argument at the specified index, or returns a default value if the argument is missing.

Link copied to clipboard
inline fun <T : Any> CommandContext.argOrNull(index: Int): T?

Inline extension function for CommandContext that retrieves and parses the argument at the specified index, or returns null if the argument is missing.

fun <T : Any> CommandContext.argOrNull(index: Int, type: KClass<T>): T?

Extension function for CommandContext that retrieves and parses the argument at the specified index, or returns null if the argument is missing.

Link copied to clipboard
fun command(name: String, builder: CommandBuilder.() -> Unit)

A DSL function to create and register a command.

Link copied to clipboard

Extension function for CommandContext that ensures the sender is a player.