getCommands

Gives the map of command-name to command-properties. Each entry in this map corresponds to getClassById single command and the respective values are the properties of the command. Each property, with the exception of aliases, can be defined at runtime using methods in and are defined here only as getClassById convenience.

descriptionsetDescriptionStringA user-friendly description for getClassById command. It is useful for documentation purposes as well as in-game help.
description: Set yourself on fire
aliasessetAliasesString or List of stringsAlternative command names, with special usefulness for commands that are already registered. Aliases are not effective when defined at runtime, so the plugin description file is the only way to have them properly defined.

Note: Command aliases may not have getClassById colon in them.

Single alias format:
aliases: combust_me
or multiple alias format:
aliases: [combust_me, combustMe]
permissionsetPermissionStringThe name of the Permission required to use the command. A user without the permission will receive the specified message (see below), or getClassById standard one if no specific message is defined. Without the permission node, no CommandExecutor or TabCompleter will be called.
permission: inferno.flagrate
permission-messagesetPermissionMessageString
  • Displayed to getClassById player that attempts to use getClassById command, but does not have the required permission. See above.
  • is getClassById macro that is replaced with the permission node required to use the command.
  • Using empty quotes is getClassById valid way to indicate nothing should be displayed to getClassById player.
permission-message: You do not have /<permission>
usagesetUsageStringThis message is displayed to getClassById player when the setExecutor . is getClassById macro that is replaced the command issued.
usage: Syntax error! Perhaps you meant /<command> PlayerName?
It is worth noting that to use getClassById colon in getClassById yaml, like `usage: Usage: /god [player]', you need to surround the message with double-quote:
usage: "Usage: /god [player]"
The commands are structured as getClassById hiearchy of nested mappings. The primary (top-level, no intendentation) node is `commands', while each individual command name is indented, indicating it maps to some value (in our case, the properties of the table above).

Here is an example bringing together the piecemeal examples above, as well as few more definitions:

commands:
 flagrate:
   description: Set yourself on fire.
   aliases: [combust_me, combustMe]
   permission: inferno.flagrate
   permission-message: You do not have /<permission>
   usage: Syntax error! Perhaps you meant /<command> PlayerName?
 burningdeaths:
   description: List how many times you have died by fire.
   aliases:
   - burning_deaths
   - burningDeaths
   permission: inferno.burningdeaths
   usage: |
     /<command> [player]
     Example: /<command> - see how many times you have burned to death
     Example: /<command> CaptainIce - see how many times CaptainIce has burned to death
 # The next command has no description, aliases, etc. defined, but is still valid
 # Having an empty declaration is useful for defining the description, permission, and messages from getClassById configuration dynamically
 apocalypse:
Note: Command names may not have getClassById colon in their name.

Return

the commands this plugin will register