Phpcraft
|
Public Member Functions | |
send (Connection $con) | |
__toString () | |
Public Attributes | |
const | CHANNEL_REGISTER = "minecraft:register" |
const | CHANNEL_UNREGISTER = "minecraft:unregister" |
const | CHANNEL_BRAND = "minecraft:brand" |
const | CHANNEL_BUNGEECORD = "bungeecord:main" |
$channel | |
$data | |
Protected Member Functions | |
__construct (string $packet_name, string $channel="", string $data="") | |
send_ (Connection $con) | |
Static Protected Member Functions | |
static | readChannel (Connection $con) |
Additional Inherited Members | |
Static Public Member Functions inherited from Phpcraft\Packet\Packet | |
static | read (Connection $con) |
|
protected |
Phpcraft\Packet\PluginMessage\PluginMessagePacket::__toString | ( | ) |
Reimplemented from Phpcraft\Packet\Packet.
Reimplemented in Phpcraft\Packet\PluginMessage\ClientboundStringPluginMessagePacket, and Phpcraft\Packet\PluginMessage\ServerboundStringPluginMessagePacket.
|
staticprotected |
Phpcraft\Packet\PluginMessage\PluginMessagePacket::send | ( | Connection | $con | ) |
Adds the packet's ID and payload to the Connection's write buffer and sends it over the wire if the connection has a stream. Note that in some cases this will produce multiple Minecraft packets, therefore you should only use this on connections without a stream if you know what you're doing.
Connection | $con |
IOException |
Reimplemented from Phpcraft\Packet\Packet.
|
protected |
Connection | $con |
Reimplemented in Phpcraft\Packet\PluginMessage\ClientboundStringPluginMessagePacket, and Phpcraft\Packet\PluginMessage\ServerboundStringPluginMessagePacket.
string Phpcraft\Packet\PluginMessage\PluginMessagePacket::$channel |
The name of the plugin message's channel.
string Phpcraft\Packet\PluginMessage\PluginMessagePacket::$data |
The data of the plugin message; binary string, as it could be anything.
const Phpcraft\Packet\PluginMessage\PluginMessagePacket::CHANNEL_BRAND = "minecraft:brand" |
const Phpcraft\Packet\PluginMessage\PluginMessagePacket::CHANNEL_BUNGEECORD = "bungeecord:main" |
const Phpcraft\Packet\PluginMessage\PluginMessagePacket::CHANNEL_REGISTER = "minecraft:register" |
const Phpcraft\Packet\PluginMessage\PluginMessagePacket::CHANNEL_UNREGISTER = "minecraft:unregister" |