Abstract
Constructs a new network packet.
The packet data to include in the network packet.
Deserializes the network packet from a binary stream.
The binary stream to deserialize from.
Protected
Abstract
deserializeDeserializes the payload of the network packet from a binary stream.
The binary stream to deserialize from.
Serializes the network packet into a binary stream.
The binary stream to serialize into.
The serialized network packet as a Buffer.
Protected
Abstract
serializeSerializes the payload of the network packet into a binary stream.
The binary stream to serialize into.
The packet data to serialize.
Represents the network packet (aka DataPacket). This is just a serialization layer to include the packet header and to reduce redundancy in the packet classes. https://mojang.github.io/bedrock-protocol-docs/html/packetHeader.html