|
PocketMine-MP 5.37.4 git-0c453f585430c41919390ec01ffeb1e004b5334b
|
Inheritance diagram for pocketmine\network\mcpe\protocol\AvailableCommandsPacket:
Collaboration diagram for pocketmine\network\mcpe\protocol\AvailableCommandsPacket:Public Member Functions | |
| __get ($name) | |
| __set ($name, $value) | |
| canBeSentBeforeLogin () | |
| decode (ByteBufferReader $in) | |
| encode (ByteBufferWriter $out) | |
| getName () | |
| handle (PacketHandlerInterface $handler) | |
| pid () | |
Static Public Member Functions | |
| static | create (array $enumValues, array $chainedSubCommandValues, array $postfixes, array $enums, array $chainedSubCommandData, array $commandData, array $softEnums, array $enumConstraints,) |
Public Attributes | |
| array | $chainedSubCommandData = [] |
| array | $chainedSubCommandValues = [] |
| array | $commandData = [] |
| array | $enumConstraints = [] |
| array | $enums = [] |
| array | $enumValues = [] |
| array | $postfixes = [] |
| int | $recipientSubId = 0 |
| int | $senderSubId = 0 |
| array | $softEnums = [] |
| const | ARG_FLAG_ENUM = 0x200000 |
| const | ARG_FLAG_POSTFIX = 0x1000000 |
| const | ARG_FLAG_SOFT_ENUM = 0x4000000 |
| const | ARG_FLAG_VALID = 0x100000 |
| const | ARG_TYPE_BLOCK_STATES = ArgTypes::BLOCK_STATE_ARRAY |
| const | ARG_TYPE_COMMAND = ArgTypes::CODEBUILDERARGS |
| const | ARG_TYPE_COMPARE_OPERATOR = ArgTypes::COMPAREOPERATOR |
| const | ARG_TYPE_EQUIPMENT_SLOT = ArgTypes::EQUIPMENTSLOTENUM |
| const | ARG_TYPE_FILEPATH = ArgTypes::PATHCOMMAND |
| const | ARG_TYPE_FLOAT = ArgTypes::VAL |
| const | ARG_TYPE_FULL_INTEGER_RANGE = ArgTypes::FULLINTEGERRANGE |
| const | ARG_TYPE_INT = ArgTypes::INT |
| const | ARG_TYPE_INT_POSITION = ArgTypes::POSITION |
| const | ARG_TYPE_JSON = ArgTypes::JSON_OBJECT |
| const | ARG_TYPE_MESSAGE = ArgTypes::MESSAGE_ROOT |
| const | ARG_TYPE_OPERATOR = ArgTypes::OPERATOR |
| const | ARG_TYPE_POSITION = ArgTypes::POSITION_FLOAT |
| const | ARG_TYPE_RAWTEXT = ArgTypes::RAWTEXT |
| const | ARG_TYPE_STRING = ArgTypes::ID |
| const | ARG_TYPE_TARGET = ArgTypes::SELECTION |
| const | ARG_TYPE_VALUE = ArgTypes::RVAL |
| const | ARG_TYPE_WILDCARD_INT = ArgTypes::WILDCARDINT |
| const | ARG_TYPE_WILDCARD_TARGET = ArgTypes::WILDCARDSELECTION |
| const | NETWORK_ID = ProtocolInfo::AVAILABLE_COMMANDS_PACKET |
| const | PID_MASK = 0x3ff |
Protected Member Functions | |
| decodeHeader (ByteBufferReader $in) | |
| decodePayload (ByteBufferReader $in) | |
| encodeHeader (ByteBufferWriter $out) | |
| encodePayload (ByteBufferWriter $out) | |
Note: It's not recommended to work with this packet directly. It's very complicated, and it's very easy to crash the client if the packet data is incorrect in any way.
To assemble a packet for sending from high-level structures, use AvailableCommandsPacketAssembler. To disassemble a received packet into high-level structures, use AvailableCommandsPacketDisassembler.
Definition at line 38 of file AvailableCommandsPacket.php.
|
inherited |
|
inherited |
| string | $name | |
| mixed | $value |
Definition at line 115 of file DataPacket.php.
|
inherited |
Implements pocketmine\network\mcpe\protocol\Packet.
Definition at line 44 of file DataPacket.php.
|
static |
@generate-create-func
| string[] | $enumValues | |
| string[] | $chainedSubCommandValues | |
| string[] | $postfixes | |
| CommandEnumRawData[] | $enums | |
| ChainedSubCommandRawData[] | $chainedSubCommandData | |
| CommandRawData[] | $commandData | |
| CommandSoftEnum[] | $softEnums | |
| CommandEnumConstraintRawData[] | $enumConstraints | @phpstan-param list<string> $enumValues @phpstan-param list<string> $chainedSubCommandValues @phpstan-param list<string> $postfixes @phpstan-param list<CommandEnumRawData> $enums @phpstan-param list<ChainedSubCommandRawData> $chainedSubCommandData @phpstan-param list<CommandRawData> $commandData @phpstan-param list<CommandSoftEnum> $softEnums @phpstan-param list<CommandEnumConstraintRawData> $enumConstraints |
Definition at line 152 of file AvailableCommandsPacket.php.
|
finalinherited |
| PacketDecodeException |
Implements pocketmine\network\mcpe\protocol\Packet.
Definition at line 51 of file DataPacket.php.
|
protectedinherited |
| DataDecodeException | |
| PacketDecodeException |
Definition at line 64 of file DataPacket.php.
|
protected |
Decodes the packet body, without the packet ID or other generic header fields.
| PacketDecodeException | |
| DataDecodeException |
Reimplemented from pocketmine\network\mcpe\protocol\DataPacket.
Definition at line 174 of file AvailableCommandsPacket.php.
|
finalinherited |
Implements pocketmine\network\mcpe\protocol\Packet.
Definition at line 84 of file DataPacket.php.
|
protectedinherited |
Definition at line 89 of file DataPacket.php.
|
protected |
Encodes the packet body, without the packet ID or other generic header fields.
Reimplemented from pocketmine\network\mcpe\protocol\DataPacket.
Definition at line 217 of file AvailableCommandsPacket.php.
|
inherited |
Implements pocketmine\network\mcpe\protocol\Packet.
Definition at line 40 of file DataPacket.php.
| pocketmine\network\mcpe\protocol\AvailableCommandsPacket::handle | ( | PacketHandlerInterface | $handler | ) |
Performs handling for this packet. Usually you'll want an appropriately named method in the session handler for this.
This method returns a bool to indicate whether the packet was handled or not. If the packet was unhandled, a debug message will be logged with a hexdump of the packet.
Typically this method returns the return value of the handler in the supplied PacketHandler. See other packets for examples how to implement this.
| PacketDecodeException | if broken data was found in the packet |
Implements pocketmine\network\mcpe\protocol\Packet.
Definition at line 260 of file AvailableCommandsPacket.php.
|
inherited |
Implements pocketmine\network\mcpe\protocol\Packet.
Definition at line 36 of file DataPacket.php.
| array pocketmine\network\mcpe\protocol\AvailableCommandsPacket::$chainedSubCommandData = [] |
Definition at line 116 of file AvailableCommandsPacket.php.
| array pocketmine\network\mcpe\protocol\AvailableCommandsPacket::$chainedSubCommandValues = [] |
Definition at line 101 of file AvailableCommandsPacket.php.
| array pocketmine\network\mcpe\protocol\AvailableCommandsPacket::$commandData = [] |
Definition at line 121 of file AvailableCommandsPacket.php.
| array pocketmine\network\mcpe\protocol\AvailableCommandsPacket::$enumConstraints = [] |
Definition at line 131 of file AvailableCommandsPacket.php.
| array pocketmine\network\mcpe\protocol\AvailableCommandsPacket::$enums = [] |
Definition at line 111 of file AvailableCommandsPacket.php.
| array pocketmine\network\mcpe\protocol\AvailableCommandsPacket::$enumValues = [] |
Definition at line 96 of file AvailableCommandsPacket.php.
| array pocketmine\network\mcpe\protocol\AvailableCommandsPacket::$postfixes = [] |
Definition at line 106 of file AvailableCommandsPacket.php.
|
inherited |
Definition at line 34 of file DataPacket.php.
|
inherited |
Definition at line 33 of file DataPacket.php.
| array pocketmine\network\mcpe\protocol\AvailableCommandsPacket::$softEnums = [] |
Definition at line 126 of file AvailableCommandsPacket.php.
| const pocketmine\network\mcpe\protocol\AvailableCommandsPacket::ARG_FLAG_ENUM = 0x200000 |
Enums are a little different: they are composed as follows: ARG_FLAG_ENUM | ARG_FLAG_VALID | (enum index)
Definition at line 85 of file AvailableCommandsPacket.php.
| const pocketmine\network\mcpe\protocol\AvailableCommandsPacket::ARG_FLAG_POSTFIX = 0x1000000 |
This is used for /xp <level: int>L. It can only be applied to integer parameters.
Definition at line 88 of file AvailableCommandsPacket.php.
| const pocketmine\network\mcpe\protocol\AvailableCommandsPacket::ARG_FLAG_SOFT_ENUM = 0x4000000 |
Definition at line 90 of file AvailableCommandsPacket.php.
| const pocketmine\network\mcpe\protocol\AvailableCommandsPacket::ARG_FLAG_VALID = 0x100000 |
This flag is set on all types EXCEPT the POSTFIX type. Not completely sure what this is for, but it is required for the argtype to work correctly. VALID seems as good a name as any.
Definition at line 45 of file AvailableCommandsPacket.php.
| const pocketmine\network\mcpe\protocol\AvailableCommandsPacket::ARG_TYPE_BLOCK_STATES = ArgTypes::BLOCK_STATE_ARRAY |
Definition at line 77 of file AvailableCommandsPacket.php.
| const pocketmine\network\mcpe\protocol\AvailableCommandsPacket::ARG_TYPE_COMMAND = ArgTypes::CODEBUILDERARGS |
Definition at line 79 of file AvailableCommandsPacket.php.
| const pocketmine\network\mcpe\protocol\AvailableCommandsPacket::ARG_TYPE_COMPARE_OPERATOR = ArgTypes::COMPAREOPERATOR |
Definition at line 56 of file AvailableCommandsPacket.php.
| const pocketmine\network\mcpe\protocol\AvailableCommandsPacket::ARG_TYPE_EQUIPMENT_SLOT = ArgTypes::EQUIPMENTSLOTENUM |
Definition at line 65 of file AvailableCommandsPacket.php.
| const pocketmine\network\mcpe\protocol\AvailableCommandsPacket::ARG_TYPE_FILEPATH = ArgTypes::PATHCOMMAND |
Definition at line 61 of file AvailableCommandsPacket.php.
| const pocketmine\network\mcpe\protocol\AvailableCommandsPacket::ARG_TYPE_FLOAT = ArgTypes::VAL |
Definition at line 52 of file AvailableCommandsPacket.php.
| const pocketmine\network\mcpe\protocol\AvailableCommandsPacket::ARG_TYPE_FULL_INTEGER_RANGE = ArgTypes::FULLINTEGERRANGE |
Definition at line 63 of file AvailableCommandsPacket.php.
| const pocketmine\network\mcpe\protocol\AvailableCommandsPacket::ARG_TYPE_INT = ArgTypes::INT |
Basic parameter types. These must be combined with the ARG_FLAG_VALID constant. ARG_FLAG_VALID | (type const)
Definition at line 51 of file AvailableCommandsPacket.php.
| const pocketmine\network\mcpe\protocol\AvailableCommandsPacket::ARG_TYPE_INT_POSITION = ArgTypes::POSITION |
Definition at line 68 of file AvailableCommandsPacket.php.
| const pocketmine\network\mcpe\protocol\AvailableCommandsPacket::ARG_TYPE_JSON = ArgTypes::JSON_OBJECT |
Definition at line 75 of file AvailableCommandsPacket.php.
| const pocketmine\network\mcpe\protocol\AvailableCommandsPacket::ARG_TYPE_MESSAGE = ArgTypes::MESSAGE_ROOT |
Definition at line 71 of file AvailableCommandsPacket.php.
| const pocketmine\network\mcpe\protocol\AvailableCommandsPacket::ARG_TYPE_OPERATOR = ArgTypes::OPERATOR |
Definition at line 55 of file AvailableCommandsPacket.php.
| const pocketmine\network\mcpe\protocol\AvailableCommandsPacket::ARG_TYPE_POSITION = ArgTypes::POSITION_FLOAT |
Definition at line 69 of file AvailableCommandsPacket.php.
| const pocketmine\network\mcpe\protocol\AvailableCommandsPacket::ARG_TYPE_RAWTEXT = ArgTypes::RAWTEXT |
Definition at line 73 of file AvailableCommandsPacket.php.
| const pocketmine\network\mcpe\protocol\AvailableCommandsPacket::ARG_TYPE_STRING = ArgTypes::ID |
Definition at line 66 of file AvailableCommandsPacket.php.
| const pocketmine\network\mcpe\protocol\AvailableCommandsPacket::ARG_TYPE_TARGET = ArgTypes::SELECTION |
Definition at line 57 of file AvailableCommandsPacket.php.
| const pocketmine\network\mcpe\protocol\AvailableCommandsPacket::ARG_TYPE_VALUE = ArgTypes::RVAL |
Definition at line 53 of file AvailableCommandsPacket.php.
| const pocketmine\network\mcpe\protocol\AvailableCommandsPacket::ARG_TYPE_WILDCARD_INT = ArgTypes::WILDCARDINT |
Definition at line 54 of file AvailableCommandsPacket.php.
| const pocketmine\network\mcpe\protocol\AvailableCommandsPacket::ARG_TYPE_WILDCARD_TARGET = ArgTypes::WILDCARDSELECTION |
Definition at line 59 of file AvailableCommandsPacket.php.
| const pocketmine\network\mcpe\protocol\AvailableCommandsPacket::NETWORK_ID = ProtocolInfo::AVAILABLE_COMMANDS_PACKET |
Definition at line 39 of file AvailableCommandsPacket.php.
|
inherited |
Definition at line 27 of file DataPacket.php.