This commit is contained in:
azw 2023-02-19 03:17:35 +00:00
parent 9f44a2e85f
commit d733e0df7d
11 changed files with 21458 additions and 5 deletions

View File

@ -99,11 +99,11 @@ add_executable(
imserver${GAME_ID} ${SRC_LIST}
)
# add_custom_target(script_pb_protocol ALL)
# add_custom_command(TARGET script_pb_protocol
# PRE_BUILD
# COMMAND python ../../third_party/tools/scripts/construct/build_pb.py --cpp_out=. --pb_files=cs_proto,cs_msgid,ss_proto,ss_msgid)
# add_dependencies(imserver${GAME_ID} script_pb_protocol)
add_custom_target(script_pb_protocol ALL)
add_custom_command(TARGET script_pb_protocol
PRE_BUILD
COMMAND python ../../third_party/tools/scripts/construct/build_pb.py --cpp_out=. --pb_files=cs_proto,cs_msgid,ss_proto,ss_msgid)
add_dependencies(imserver${GAME_ID} script_pb_protocol)
target_link_libraries(
imserver${GAME_ID}

View File

@ -0,0 +1,148 @@
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: cs_msgid.proto
#include "cs_msgid.pb.h"
#include <algorithm>
#include <google/protobuf/stubs/common.h>
#include <google/protobuf/stubs/port.h>
#include <google/protobuf/io/coded_stream.h>
#include <google/protobuf/wire_format_lite_inl.h>
#include <google/protobuf/descriptor.h>
#include <google/protobuf/generated_message_reflection.h>
#include <google/protobuf/reflection_ops.h>
#include <google/protobuf/wire_format.h>
// This is a temporary google only hack
#ifdef GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS
#include "third_party/protobuf/version.h"
#endif
// @@protoc_insertion_point(includes)
namespace cs {
} // namespace cs
namespace protobuf_cs_5fmsgid_2eproto {
void InitDefaults() {
}
const ::google::protobuf::EnumDescriptor* file_level_enum_descriptors[2];
const ::google::protobuf::uint32 TableStruct::offsets[1] = {};
static const ::google::protobuf::internal::MigrationSchema* schemas = NULL;
static const ::google::protobuf::Message* const* file_default_instances = NULL;
void protobuf_AssignDescriptors() {
AddDescriptors();
AssignDescriptors(
"cs_msgid.proto", schemas, file_default_instances, TableStruct::offsets,
NULL, file_level_enum_descriptors, NULL);
}
void protobuf_AssignDescriptorsOnce() {
static ::google::protobuf::internal::once_flag once;
::google::protobuf::internal::call_once(once, protobuf_AssignDescriptors);
}
void protobuf_RegisterTypes(const ::std::string&) GOOGLE_PROTOBUF_ATTRIBUTE_COLD;
void protobuf_RegisterTypes(const ::std::string&) {
protobuf_AssignDescriptorsOnce();
}
void AddDescriptorsImpl() {
InitDefaults();
static const char descriptor[] GOOGLE_PROTOBUF_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = {
"\n\016cs_msgid.proto\022\002cs*\337\001\n\rCMMessageId_e\022\013"
"\n\007_CMPing\020e\022\014\n\010_CMLogin\020g\022\023\n\016_CMSendChat"
"Msg\020\227\001\022\025\n\020_CMSendCustomMsg\020\230\001\022 \n\033_CMRead"
"MsgAndOpenChatNotify\020\235\001\022\027\n\022_CMCloseChatN"
"otify\020\236\001\022 \n\033_CMSetCurrPrivateChatTarget\020"
"\237\001\022\025\n\020_CMGuildMsgBegin\020\346\001\022\023\n\016_CMGuildMsg"
"End\020\216\002*\300\003\n\rSMMessageId_e\022\013\n\007_SMPing\020e\022\017\n"
"\013_SMRpcError\020f\022\014\n\010_SMLogin\020g\022\025\n\020_SMGuild"
"MsgBegin\020\346\001\022\023\n\016_SMGuildMsgEnd\020\216\002\022\030\n\023_SMU"
"serStatusNotify\020\365\003\022\024\n\017_SMShowErrorMsg\020\374\003"
"\022\027\n\022_SMCustomMsgNotify\020\367\003\022\025\n\020_SMChatMsgN"
"otify\020\202\004\022 \n\033_SMUpdateChatRedPointNotify\020"
"\377\003\022\037\n\032_SMUpdateChatChannelLastId\020\200\004\022\'\n\"_"
"SMUpdatePrivateChatRedPointNotify\020\201\004\022\026\n\021"
"_SMUserInfoUpdate\020\366\003\022\032\n\025_SMDeleteFriendN"
"otify\020\371\003\022\034\n\027_SMUpdateRedPointNotify\020\373\003\022\032"
"\n\025_SMAddBlackListNotify\020\375\003\022\035\n\030_SMDeleteB"
"lackListNotify\020\376\003"
};
::google::protobuf::DescriptorPool::InternalAddGeneratedFile(
descriptor, 697);
::google::protobuf::MessageFactory::InternalRegisterGeneratedFile(
"cs_msgid.proto", &protobuf_RegisterTypes);
}
void AddDescriptors() {
static ::google::protobuf::internal::once_flag once;
::google::protobuf::internal::call_once(once, AddDescriptorsImpl);
}
// Force AddDescriptors() to be called at dynamic initialization time.
struct StaticDescriptorInitializer {
StaticDescriptorInitializer() {
AddDescriptors();
}
} static_descriptor_initializer;
} // namespace protobuf_cs_5fmsgid_2eproto
namespace cs {
const ::google::protobuf::EnumDescriptor* CMMessageId_e_descriptor() {
protobuf_cs_5fmsgid_2eproto::protobuf_AssignDescriptorsOnce();
return protobuf_cs_5fmsgid_2eproto::file_level_enum_descriptors[0];
}
bool CMMessageId_e_IsValid(int value) {
switch (value) {
case 101:
case 103:
case 151:
case 152:
case 157:
case 158:
case 159:
case 230:
case 270:
return true;
default:
return false;
}
}
const ::google::protobuf::EnumDescriptor* SMMessageId_e_descriptor() {
protobuf_cs_5fmsgid_2eproto::protobuf_AssignDescriptorsOnce();
return protobuf_cs_5fmsgid_2eproto::file_level_enum_descriptors[1];
}
bool SMMessageId_e_IsValid(int value) {
switch (value) {
case 101:
case 102:
case 103:
case 230:
case 270:
case 501:
case 502:
case 503:
case 505:
case 507:
case 508:
case 509:
case 510:
case 511:
case 512:
case 513:
case 514:
return true;
default:
return false;
}
}
// @@protoc_insertion_point(namespace_scope)
} // namespace cs
namespace google {
namespace protobuf {
} // namespace protobuf
} // namespace google
// @@protoc_insertion_point(global_scope)

View File

@ -0,0 +1,150 @@
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: cs_msgid.proto
#ifndef PROTOBUF_INCLUDED_cs_5fmsgid_2eproto
#define PROTOBUF_INCLUDED_cs_5fmsgid_2eproto
#include <string>
#include <google/protobuf/stubs/common.h>
#if GOOGLE_PROTOBUF_VERSION < 3006001
#error This file was generated by a newer version of protoc which is
#error incompatible with your Protocol Buffer headers. Please update
#error your headers.
#endif
#if 3006001 < GOOGLE_PROTOBUF_MIN_PROTOC_VERSION
#error This file was generated by an older version of protoc which is
#error incompatible with your Protocol Buffer headers. Please
#error regenerate this file with a newer version of protoc.
#endif
#include <google/protobuf/io/coded_stream.h>
#include <google/protobuf/arena.h>
#include <google/protobuf/arenastring.h>
#include <google/protobuf/generated_message_table_driven.h>
#include <google/protobuf/generated_message_util.h>
#include <google/protobuf/inlined_string_field.h>
#include <google/protobuf/metadata.h>
#include <google/protobuf/repeated_field.h> // IWYU pragma: export
#include <google/protobuf/extension_set.h> // IWYU pragma: export
#include <google/protobuf/generated_enum_reflection.h>
// @@protoc_insertion_point(includes)
#define PROTOBUF_INTERNAL_EXPORT_protobuf_cs_5fmsgid_2eproto
namespace protobuf_cs_5fmsgid_2eproto {
// Internal implementation detail -- do not use these members.
struct TableStruct {
static const ::google::protobuf::internal::ParseTableField entries[];
static const ::google::protobuf::internal::AuxillaryParseTableField aux[];
static const ::google::protobuf::internal::ParseTable schema[1];
static const ::google::protobuf::internal::FieldMetadata field_metadata[];
static const ::google::protobuf::internal::SerializationTable serialization_table[];
static const ::google::protobuf::uint32 offsets[];
};
void AddDescriptors();
} // namespace protobuf_cs_5fmsgid_2eproto
namespace cs {
} // namespace cs
namespace cs {
enum CMMessageId_e {
_CMPing = 101,
_CMLogin = 103,
_CMSendChatMsg = 151,
_CMSendCustomMsg = 152,
_CMReadMsgAndOpenChatNotify = 157,
_CMCloseChatNotify = 158,
_CMSetCurrPrivateChatTarget = 159,
_CMGuildMsgBegin = 230,
_CMGuildMsgEnd = 270
};
bool CMMessageId_e_IsValid(int value);
const CMMessageId_e CMMessageId_e_MIN = _CMPing;
const CMMessageId_e CMMessageId_e_MAX = _CMGuildMsgEnd;
const int CMMessageId_e_ARRAYSIZE = CMMessageId_e_MAX + 1;
const ::google::protobuf::EnumDescriptor* CMMessageId_e_descriptor();
inline const ::std::string& CMMessageId_e_Name(CMMessageId_e value) {
return ::google::protobuf::internal::NameOfEnum(
CMMessageId_e_descriptor(), value);
}
inline bool CMMessageId_e_Parse(
const ::std::string& name, CMMessageId_e* value) {
return ::google::protobuf::internal::ParseNamedEnum<CMMessageId_e>(
CMMessageId_e_descriptor(), name, value);
}
enum SMMessageId_e {
_SMPing = 101,
_SMRpcError = 102,
_SMLogin = 103,
_SMGuildMsgBegin = 230,
_SMGuildMsgEnd = 270,
_SMUserStatusNotify = 501,
_SMShowErrorMsg = 508,
_SMCustomMsgNotify = 503,
_SMChatMsgNotify = 514,
_SMUpdateChatRedPointNotify = 511,
_SMUpdateChatChannelLastId = 512,
_SMUpdatePrivateChatRedPointNotify = 513,
_SMUserInfoUpdate = 502,
_SMDeleteFriendNotify = 505,
_SMUpdateRedPointNotify = 507,
_SMAddBlackListNotify = 509,
_SMDeleteBlackListNotify = 510
};
bool SMMessageId_e_IsValid(int value);
const SMMessageId_e SMMessageId_e_MIN = _SMPing;
const SMMessageId_e SMMessageId_e_MAX = _SMChatMsgNotify;
const int SMMessageId_e_ARRAYSIZE = SMMessageId_e_MAX + 1;
const ::google::protobuf::EnumDescriptor* SMMessageId_e_descriptor();
inline const ::std::string& SMMessageId_e_Name(SMMessageId_e value) {
return ::google::protobuf::internal::NameOfEnum(
SMMessageId_e_descriptor(), value);
}
inline bool SMMessageId_e_Parse(
const ::std::string& name, SMMessageId_e* value) {
return ::google::protobuf::internal::ParseNamedEnum<SMMessageId_e>(
SMMessageId_e_descriptor(), name, value);
}
// ===================================================================
// ===================================================================
// ===================================================================
#ifdef __GNUC__
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wstrict-aliasing"
#endif // __GNUC__
#ifdef __GNUC__
#pragma GCC diagnostic pop
#endif // __GNUC__
// @@protoc_insertion_point(namespace_scope)
} // namespace cs
namespace google {
namespace protobuf {
template <> struct is_proto_enum< ::cs::CMMessageId_e> : ::std::true_type {};
template <>
inline const EnumDescriptor* GetEnumDescriptor< ::cs::CMMessageId_e>() {
return ::cs::CMMessageId_e_descriptor();
}
template <> struct is_proto_enum< ::cs::SMMessageId_e> : ::std::true_type {};
template <>
inline const EnumDescriptor* GetEnumDescriptor< ::cs::SMMessageId_e>() {
return ::cs::SMMessageId_e_descriptor();
}
} // namespace protobuf
} // namespace google
// @@protoc_insertion_point(global_scope)
#endif // PROTOBUF_INCLUDED_cs_5fmsgid_2eproto

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,80 @@
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: ss_msgid.proto
#include "ss_msgid.pb.h"
#include <algorithm>
#include <google/protobuf/stubs/common.h>
#include <google/protobuf/stubs/port.h>
#include <google/protobuf/io/coded_stream.h>
#include <google/protobuf/wire_format_lite_inl.h>
#include <google/protobuf/descriptor.h>
#include <google/protobuf/generated_message_reflection.h>
#include <google/protobuf/reflection_ops.h>
#include <google/protobuf/wire_format.h>
// This is a temporary google only hack
#ifdef GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS
#include "third_party/protobuf/version.h"
#endif
// @@protoc_insertion_point(includes)
namespace ss {
} // namespace ss
namespace protobuf_ss_5fmsgid_2eproto {
void InitDefaults() {
}
const ::google::protobuf::uint32 TableStruct::offsets[1] = {};
static const ::google::protobuf::internal::MigrationSchema* schemas = NULL;
static const ::google::protobuf::Message* const* file_default_instances = NULL;
void protobuf_AssignDescriptors() {
AddDescriptors();
AssignDescriptors(
"ss_msgid.proto", schemas, file_default_instances, TableStruct::offsets,
NULL, NULL, NULL);
}
void protobuf_AssignDescriptorsOnce() {
static ::google::protobuf::internal::once_flag once;
::google::protobuf::internal::call_once(once, protobuf_AssignDescriptors);
}
void protobuf_RegisterTypes(const ::std::string&) GOOGLE_PROTOBUF_ATTRIBUTE_COLD;
void protobuf_RegisterTypes(const ::std::string&) {
protobuf_AssignDescriptorsOnce();
}
void AddDescriptorsImpl() {
InitDefaults();
static const char descriptor[] GOOGLE_PROTOBUF_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = {
"\n\016ss_msgid.proto\022\002ss"
};
::google::protobuf::DescriptorPool::InternalAddGeneratedFile(
descriptor, 20);
::google::protobuf::MessageFactory::InternalRegisterGeneratedFile(
"ss_msgid.proto", &protobuf_RegisterTypes);
}
void AddDescriptors() {
static ::google::protobuf::internal::once_flag once;
::google::protobuf::internal::call_once(once, AddDescriptorsImpl);
}
// Force AddDescriptors() to be called at dynamic initialization time.
struct StaticDescriptorInitializer {
StaticDescriptorInitializer() {
AddDescriptors();
}
} static_descriptor_initializer;
} // namespace protobuf_ss_5fmsgid_2eproto
namespace ss {
// @@protoc_insertion_point(namespace_scope)
} // namespace ss
namespace google {
namespace protobuf {
} // namespace protobuf
} // namespace google
// @@protoc_insertion_point(global_scope)

View File

@ -0,0 +1,72 @@
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: ss_msgid.proto
#ifndef PROTOBUF_INCLUDED_ss_5fmsgid_2eproto
#define PROTOBUF_INCLUDED_ss_5fmsgid_2eproto
#include <string>
#include <google/protobuf/stubs/common.h>
#if GOOGLE_PROTOBUF_VERSION < 3006001
#error This file was generated by a newer version of protoc which is
#error incompatible with your Protocol Buffer headers. Please update
#error your headers.
#endif
#if 3006001 < GOOGLE_PROTOBUF_MIN_PROTOC_VERSION
#error This file was generated by an older version of protoc which is
#error incompatible with your Protocol Buffer headers. Please
#error regenerate this file with a newer version of protoc.
#endif
#include <google/protobuf/io/coded_stream.h>
#include <google/protobuf/arena.h>
#include <google/protobuf/arenastring.h>
#include <google/protobuf/generated_message_table_driven.h>
#include <google/protobuf/generated_message_util.h>
#include <google/protobuf/inlined_string_field.h>
#include <google/protobuf/metadata.h>
#include <google/protobuf/repeated_field.h> // IWYU pragma: export
#include <google/protobuf/extension_set.h> // IWYU pragma: export
// @@protoc_insertion_point(includes)
#define PROTOBUF_INTERNAL_EXPORT_protobuf_ss_5fmsgid_2eproto
namespace protobuf_ss_5fmsgid_2eproto {
// Internal implementation detail -- do not use these members.
struct TableStruct {
static const ::google::protobuf::internal::ParseTableField entries[];
static const ::google::protobuf::internal::AuxillaryParseTableField aux[];
static const ::google::protobuf::internal::ParseTable schema[1];
static const ::google::protobuf::internal::FieldMetadata field_metadata[];
static const ::google::protobuf::internal::SerializationTable serialization_table[];
static const ::google::protobuf::uint32 offsets[];
};
void AddDescriptors();
} // namespace protobuf_ss_5fmsgid_2eproto
namespace ss {
} // namespace ss
namespace ss {
// ===================================================================
// ===================================================================
// ===================================================================
#ifdef __GNUC__
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wstrict-aliasing"
#endif // __GNUC__
#ifdef __GNUC__
#pragma GCC diagnostic pop
#endif // __GNUC__
// @@protoc_insertion_point(namespace_scope)
} // namespace ss
// @@protoc_insertion_point(global_scope)
#endif // PROTOBUF_INCLUDED_ss_5fmsgid_2eproto

View File

@ -0,0 +1,80 @@
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: ss_proto.proto
#include "ss_proto.pb.h"
#include <algorithm>
#include <google/protobuf/stubs/common.h>
#include <google/protobuf/stubs/port.h>
#include <google/protobuf/io/coded_stream.h>
#include <google/protobuf/wire_format_lite_inl.h>
#include <google/protobuf/descriptor.h>
#include <google/protobuf/generated_message_reflection.h>
#include <google/protobuf/reflection_ops.h>
#include <google/protobuf/wire_format.h>
// This is a temporary google only hack
#ifdef GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS
#include "third_party/protobuf/version.h"
#endif
// @@protoc_insertion_point(includes)
namespace ss {
} // namespace ss
namespace protobuf_ss_5fproto_2eproto {
void InitDefaults() {
}
const ::google::protobuf::uint32 TableStruct::offsets[1] = {};
static const ::google::protobuf::internal::MigrationSchema* schemas = NULL;
static const ::google::protobuf::Message* const* file_default_instances = NULL;
void protobuf_AssignDescriptors() {
AddDescriptors();
AssignDescriptors(
"ss_proto.proto", schemas, file_default_instances, TableStruct::offsets,
NULL, NULL, NULL);
}
void protobuf_AssignDescriptorsOnce() {
static ::google::protobuf::internal::once_flag once;
::google::protobuf::internal::call_once(once, protobuf_AssignDescriptors);
}
void protobuf_RegisterTypes(const ::std::string&) GOOGLE_PROTOBUF_ATTRIBUTE_COLD;
void protobuf_RegisterTypes(const ::std::string&) {
protobuf_AssignDescriptorsOnce();
}
void AddDescriptorsImpl() {
InitDefaults();
static const char descriptor[] GOOGLE_PROTOBUF_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = {
"\n\016ss_proto.proto\022\002ss"
};
::google::protobuf::DescriptorPool::InternalAddGeneratedFile(
descriptor, 20);
::google::protobuf::MessageFactory::InternalRegisterGeneratedFile(
"ss_proto.proto", &protobuf_RegisterTypes);
}
void AddDescriptors() {
static ::google::protobuf::internal::once_flag once;
::google::protobuf::internal::call_once(once, AddDescriptorsImpl);
}
// Force AddDescriptors() to be called at dynamic initialization time.
struct StaticDescriptorInitializer {
StaticDescriptorInitializer() {
AddDescriptors();
}
} static_descriptor_initializer;
} // namespace protobuf_ss_5fproto_2eproto
namespace ss {
// @@protoc_insertion_point(namespace_scope)
} // namespace ss
namespace google {
namespace protobuf {
} // namespace protobuf
} // namespace google
// @@protoc_insertion_point(global_scope)

View File

@ -0,0 +1,72 @@
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: ss_proto.proto
#ifndef PROTOBUF_INCLUDED_ss_5fproto_2eproto
#define PROTOBUF_INCLUDED_ss_5fproto_2eproto
#include <string>
#include <google/protobuf/stubs/common.h>
#if GOOGLE_PROTOBUF_VERSION < 3006001
#error This file was generated by a newer version of protoc which is
#error incompatible with your Protocol Buffer headers. Please update
#error your headers.
#endif
#if 3006001 < GOOGLE_PROTOBUF_MIN_PROTOC_VERSION
#error This file was generated by an older version of protoc which is
#error incompatible with your Protocol Buffer headers. Please
#error regenerate this file with a newer version of protoc.
#endif
#include <google/protobuf/io/coded_stream.h>
#include <google/protobuf/arena.h>
#include <google/protobuf/arenastring.h>
#include <google/protobuf/generated_message_table_driven.h>
#include <google/protobuf/generated_message_util.h>
#include <google/protobuf/inlined_string_field.h>
#include <google/protobuf/metadata.h>
#include <google/protobuf/repeated_field.h> // IWYU pragma: export
#include <google/protobuf/extension_set.h> // IWYU pragma: export
// @@protoc_insertion_point(includes)
#define PROTOBUF_INTERNAL_EXPORT_protobuf_ss_5fproto_2eproto
namespace protobuf_ss_5fproto_2eproto {
// Internal implementation detail -- do not use these members.
struct TableStruct {
static const ::google::protobuf::internal::ParseTableField entries[];
static const ::google::protobuf::internal::AuxillaryParseTableField aux[];
static const ::google::protobuf::internal::ParseTable schema[1];
static const ::google::protobuf::internal::FieldMetadata field_metadata[];
static const ::google::protobuf::internal::SerializationTable serialization_table[];
static const ::google::protobuf::uint32 offsets[];
};
void AddDescriptors();
} // namespace protobuf_ss_5fproto_2eproto
namespace ss {
} // namespace ss
namespace ss {
// ===================================================================
// ===================================================================
// ===================================================================
#ifdef __GNUC__
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wstrict-aliasing"
#endif // __GNUC__
#ifdef __GNUC__
#pragma GCC diagnostic pop
#endif // __GNUC__
// @@protoc_insertion_point(namespace_scope)
} // namespace ss
// @@protoc_insertion_point(global_scope)
#endif // PROTOBUF_INCLUDED_ss_5fproto_2eproto

View File

@ -0,0 +1 @@
package ss;

View File

@ -0,0 +1 @@
package ss;