from .base import Packet import gzip class Packet140TileEntityData(Packet, packet_id=140): __slots__ = ('size', 'data') FIELDS = [ ('size', 'short'), ('data', ('bytes', 'size')), ] def post_creation(self): self.data = gzip.decompress(self.data)