Files
2025-12-06 16:42:21 +08:00

35 lines
699 B
C++

#pragma once
#include <vector>
#include <cy_network.h>
namespace google {
namespace protobuf {
class Message;
}
};
enum
{
GAME_PACKET_HEAD_SIZE = 4
};
enum GameProto
{
GAME_PROTO_LOGIN_REQUEST = 1,
GAME_PROTO_LOGIN_REPLY = 2,
GAME_PROTO_CLIENT_PACKET = 3,
GAME_PROTO_SERVER_PACKET = 4,
GAME_PROTO_HEART_BEAT = 5,
GAME_PROTO_UGC_REQUEST = 6,
GAME_PROTO_UGC_REPLY = 7,
GAME_PROTO_REPORT_REQ = 8,
GAME_PROTO_REPORT_RES = 9,
GAME_PROTO_NETBAR_REQ = 10,
GAME_PROTO_NETBAR_RES = 11,
};
void serializeProtoMessage(uint16_t id, ::google::protobuf::Message* message, cyclone::Packet& outputPacket);
::google::protobuf::Message* parserProtoMessage(const cyclone::Packet& inputPacket);