onCommand

abstract suspend fun onCommand(    sender: <Error class: unknown class>,     command: <Error class: unknown class>,     label: String,     args: Array<out String>): Boolean

Executes the given command, returning its success. If false is returned, then the "usage" plugin.yml entry for this command (if defined) will be sent to the player.

Return

True if a valid command, otherwise false.

Parameters

sender
  • Source of the command.

command
  • Command which was executed.

label
  • Alias of the command which was used.

args
  • Passed command arguments.