Пример #1
0
    def select_character_result(uid, port):
        packet = Packet(op_code=CSendOps.LP_SelectCharacterResult)

        packet.encode_byte(0)  # world
        packet.encode_byte(0)  # selected char

        packet.encode_buffer(constants.SERVER_ADDRESS)
        packet.encode_short(port)
        packet.encode_int(uid)
        packet.encode_byte(0)
        packet.encode_int(0)

        return packet
Пример #2
0
 def user_movement(uid, move_path):
     packet = Packet(op_code=CSendOps.LP_UserMove)
     packet.encode_int(uid)
     packet.encode_buffer(move_path)
     return packet