CommandExecutionContext

The context of a command execution.

Functions

Link copied to clipboard
abstract fun asPlayer(): Player?

Gets the sender of the command as a player.

Link copied to clipboard
abstract fun isPlayer(): Boolean

Checks if the sender is a player entity.

Link copied to clipboard
abstract fun sendFailureMessage(message: Component)

Sends the given message as a failure message to the sender.

Link copied to clipboard
abstract fun sendSuccessMessage(message: Component)

Sends the given message as a success message to the sender.

Properties

Link copied to clipboard
@get:JvmName(name = "displayName")
abstract val displayName: Component

The display name of the sender.

Link copied to clipboard
@get:JvmName(name = "position")
abstract val position: Position

The position of the sender.

Link copied to clipboard
@get:JvmName(name = "sender")
abstract val sender: Sender

The sender of the command.

Link copied to clipboard
@get:JvmName(name = "server")
abstract val server: Server

The server the sender is on.

Link copied to clipboard
@get:JvmName(name = "textName")
abstract val textName: String

The plain text name of the sender.

Link copied to clipboard
@get:JvmName(name = "world")
abstract val world: World

The world the sender is in.