Skip to content

CommandParameterType 5.46.0 ​

enum · pocketmine\command\parameter\CommandParameterType · source

Kinds of command parameters advertised to clients (for autocompletion and client-side syntax checks). Independent of the network protocol; the network layer maps them to Bedrock argument types.

Cases ​

COMMAND_NAME ​

php
case COMMAND_NAME

The name of a command (or alias) the receiving player may use (see CommandParameter::commandName()). The values are filled in per player when the command list is sent.

ENUM ​

php
case ENUM

One of a fixed list of keywords (see CommandParameter::enum()).

FLOAT ​

php
case FLOAT

INT ​

php
case INT

JSON ​

php
case JSON

MESSAGE ​

php
case MESSAGE

The rest of the line as a chat message (selectors in it are expanded).

POSITION ​

php
case POSITION

Three coordinates (x y z), each absolute or relative.

POSTFIX ​

php
case POSTFIX

An integer followed by a fixed suffix, like Bedrock's "/xp 5L" (see CommandParameter::postfixed()).

RAWTEXT ​

php
case RAWTEXT

The rest of the line, as it is.

SOFT_ENUM ​

php
case SOFT_ENUM

A word with suggested values; other values are accepted too (see CommandParameter::softEnum()).

STRING ​

php
case STRING

A single word.

TARGET ​

php
case TARGET

A target selector or a player name (the client suggests @a, @e, @n, @p, @r, @s and online players).

VALUE ​

php
case VALUE

A number that may be relative (~ or ~5), like a single coordinate.

VanillaMine is a fork of PocketMine-MP, maintained by Luxury Nodes. Not affiliated with the PMMP team or Mojang.