Packets#
Every packet in the Minecraft protocol is implemented here.
All packets inherit from one base class, Packet.
Packet#
- class minecraft.packets.Packet#
Represents a Minecraft packet.
- packet_id = The packet's ID#
- state = The state the packet is used in#
- bound_to = The direction the packet is sent in#
- classmethod from_bytes(data: BytesIO) Self#
Converts a packet’s data into a packet object.
- Parameters:
data (io.BytesIO) – The packet’s data.
- Returns:
The packet object.
- Return type: