Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(7)  |  Call(7)  |  Derive(0)  |  Import(0)

src/p/y/pyCraft-HEAD/networking/PacketListenerManager.py   pyCraft(Download)
def handle83(FileObject):
    ItemType = DataUtil.readShort(FileObject)
    ItemID = DataUtil.readShort(FileObject)
    TextLength = DataUtil.readShort(FileObject)
    Text = DataUtil.readByteArray(FileObject, TextLength)
    DataLength = DataUtil.readShort(FileObject)
    if (DataLength != -1):
        ByteArray = DataUtil.readByteArray(FileObject, DataLength)
        NBTData = NBTFile(BytesIO(ByteArray), compression=NBTFile.Compression.GZIP)
        return {'x': X,
def handleFA(FileObject):
    Channel = DataUtil.readString(FileObject)
    length = DataUtil.readShort(FileObject)
    message = DataUtil.readByteArray(FileObject, length)
    return {'Channel': Channel,
def handleFC(FileObject):
    #short - shared secret length
    secretLength = DataUtil.readShort(FileObject)
 
    sharedSecret = DataUtil.readByteArray(FileObject, secretLength) #ignore this data, it doesn't matter
 
    #short - token length
    length = DataUtil.readShort(FileObject)
 
    token = DataUtil.readByteArray(FileObject, length) #ignore this data, it doesn't matter