Esempio n. 1
0
 def putLong(self, l: int):
     self.buffer += Binary.writeLong(l)
Esempio n. 2
0
 def putLong(self, l: int):
     self.buffer += Binary.writeLong(l)
Esempio n. 3
0
from pyraklib.protocol.UNCONNECTED_PING import UNCONNECTED_PING
from pyraklib.protocol.UNCONNECTED_PONG import UNCONNECTED_PONG

data = Binary.writeLTriad(32)
print(Binary.readLTriad(data))

data = Binary.writeByte(32)
print(Binary.readByte(data))

data = Binary.writeShort(256)
print(Binary.readShort(data))

data = Binary.writeInt(32)
print(Binary.readInt(data))

data = Binary.writeLong(32)
print(Binary.readLong(data))

data = Binary.writeFloat(32.54)
print(Binary.readFloat(data))

data = Binary.writeDouble(32.3232)
print(Binary.readDouble(data))

print(type(Binary.writeLong(23)))

ping = UNCONNECTED_PING()
ping.pingID = 1234
ping.encode()

p = EncapsulatedPacket()