Ejemplo n.º 1
0
 def encode(self):
     packet = Packet()
     packet.write_bytes(self.__scene_rot_pos.get_bytes())
     packet.write_bytes(self.__forward.get_bytes())
     packet.write_string(self.__ani_name)
     packet.write_i16(self.__x_axis)
     return packet.encode(msg.P_REQ_SCENE_MOVE)
Ejemplo n.º 2
0
Archivo: pb.py Proyecto: mirahs/xxtools
	def encode(self):
		packet = Packet()
		packet.write_u8(self.__channel)
		packet.write_u32(self.__uid)
		packet.write_string(self.__uname)
		packet.write_string(self.__content)
		return packet.encode(msg.P_ACK_CHAT_SEND_OK)
Ejemplo n.º 3
0
 def encode(self):
     packet = Packet()
     packet.write_u8(self.__channel)
     packet.write_u32(self.__uid)
     packet.write_string(self.__uname)
     packet.write_string(self.__content)
     return packet.encode(msg.P_ACK_CHAT_SEND_OK)
Ejemplo n.º 4
0
Archivo: pb.py Proyecto: mirahs/xxtools
	def encode(self):
		packet = Packet()
		packet.write_bytes(self.__scene_rot_pos.get_bytes())
		packet.write_bytes(self.__forward.get_bytes())
		packet.write_string(self.__ani_name)
		packet.write_i16(self.__x_axis)
		return packet.encode(msg.P_REQ_SCENE_MOVE)
Ejemplo n.º 5
0
 def encode(self):
     packet = Packet()
     packet.write_u32(self.__uid)
     packet.write_u32(self.__uuid)
     packet.write_u16(self.__sid)
     packet.write_u16(self.__cid)
     packet.write_string(self.__os)
     packet.write_string(self.__version)
     packet.write_string(self.__uname)
     packet.write_string(self.__source)
     packet.write_string(self.__source_sub)
     packet.write_u32(self.__login_time)
     return packet.encode(msg.P_REQ_ROLE_CREATE)
Ejemplo n.º 6
0
 def encode(self):
     packet = Packet()
     packet.write_u64(self.__u64)
     packet.write_string(self.__strxx)
     packet.write_bytes(self.__msg_req.get_bytes())
     packet.write_u8(self.__msg_opt_flag)
     if self.__msg_opt_flag:
         packet.write_bytes(self.__msg_opt.get_bytes())
     msg_rep_count = len(self.__msg_rep)
     packet.write_u16(msg_rep_count)
     for i in range(msg_rep_count):
         packet.write_bytes(self.__msg_rep[i].get_bytes())
     return packet.encode(msg.P_REQ_TEST_PHP)
Ejemplo n.º 7
0
Archivo: pb.py Proyecto: mirahs/xxtools
	def encode(self):
		packet = Packet()
		packet.write_u32(self.__uid)
		packet.write_u32(self.__uuid)
		packet.write_u16(self.__sid)
		packet.write_u16(self.__cid)
		packet.write_string(self.__os)
		packet.write_string(self.__version)
		packet.write_string(self.__uname)
		packet.write_string(self.__source)
		packet.write_string(self.__source_sub)
		packet.write_u32(self.__login_time)
		return packet.encode(msg.P_REQ_ROLE_CREATE)
Ejemplo n.º 8
0
Archivo: pb.py Proyecto: mirahs/xxtools
	def encode(self):
		packet = Packet()
		packet.write_u64(self.__u64)
		packet.write_string(self.__strxx)
		packet.write_bytes(self.__msg_req.get_bytes())
		packet.write_u8(self.__msg_opt_flag)
		if self.__msg_opt_flag:
			packet.write_bytes(self.__msg_opt.get_bytes())
		msg_rep_count = len(self.__msg_rep)
		packet.write_u16(msg_rep_count)
		for i in range(msg_rep_count):
			packet.write_bytes(self.__msg_rep[i].get_bytes())
		return packet.encode(msg.P_REQ_TEST_PHP)
Ejemplo n.º 9
0
 def encode(self):
     packet = Packet()
     packet.write_u32(self.__uid)
     packet.write_u32(self.__uuid)
     packet.write_u16(self.__sid)
     packet.write_u16(self.__cid)
     packet.write_u32(self.__login_time)
     packet.write_string(self.__pwd)
     packet.write_u8(self.__relink)
     packet.write_u8(self.__debug)
     packet.write_string(self.__os)
     packet.write_string(self.__version)
     return packet.encode(msg.P_REQ_ROLE_LOGIN)
Ejemplo n.º 10
0
Archivo: pb.py Proyecto: mirahs/xxtools
	def encode(self):
		packet = Packet()
		packet.write_u32(self.__uid)
		packet.write_u32(self.__uuid)
		packet.write_u16(self.__sid)
		packet.write_u16(self.__cid)
		packet.write_u32(self.__login_time)
		packet.write_string(self.__pwd)
		packet.write_u8(self.__relink)
		packet.write_u8(self.__debug)
		packet.write_string(self.__os)
		packet.write_string(self.__version)
		return packet.encode(msg.P_REQ_ROLE_LOGIN)
Ejemplo n.º 11
0
 def encode(self):
     packet = Packet()
     packet.write_u8(self.__channel)
     packet.write_u32(self.__dest_uid)
     packet.write_string(self.__content)
     return packet.encode(msg.P_REQ_CHAT_SEND)
Ejemplo n.º 12
0
Archivo: pb.py Proyecto: mirahs/xxtools
	def encode(self):
		packet = Packet()
		packet.write_string(self.__content)
		return packet.encode(msg.P_REQ_CHAT_GM)
Ejemplo n.º 13
0
Archivo: pb.py Proyecto: mirahs/xxtools
	def encode(self):
		packet = Packet()
		packet.write_u32(self.__uid)
		packet.write_string(self.__uname)
		return packet.read_bytes()
Ejemplo n.º 14
0
Archivo: pb.py Proyecto: mirahs/xxtools
	def encode(self):
		packet = Packet()
		packet.write_u8(self.__channel)
		packet.write_u32(self.__dest_uid)
		packet.write_string(self.__content)
		return packet.encode(msg.P_REQ_CHAT_SEND)
Ejemplo n.º 15
0
 def encode(self):
     packet = Packet()
     packet.write_u32(self.__uid)
     packet.write_string(self.__uname)
     return packet.read_bytes()
Ejemplo n.º 16
0
 def encode(self):
     packet = Packet()
     packet.write_string(self.__uname)
     return packet.encode(msg.P_ACK_ROLE_LOGIN_OK)
Ejemplo n.º 17
0
 def encode(self):
     packet = Packet()
     packet.write_string(self.__content)
     return packet.encode(msg.P_REQ_CHAT_GM)
Ejemplo n.º 18
0
Archivo: pb.py Proyecto: mirahs/xxtools
	def encode(self):
		packet = Packet()
		packet.write_string(self.__uname)
		return packet.encode(msg.P_ACK_ROLE_LOGIN_OK)