Files
Fishing2Server/Config/NetworkProtocol/Outer/OuterMessage.proto
2025-07-16 17:47:53 +08:00

114 lines
2.3 KiB
Protocol Buffer

syntax = "proto3";
package Fantasy.Network.Message;
// 协议分为:
// ProtoBuf:可以在Outer和Inner文件里使用。
// MemoryPack:可以在Outer和Inner文件里使用。
// Bson:仅支持在Inner文件里使用。
// 使用方式:
// 在message协议上方添加// Protocol+空格+协议名字
// 例如:// Protocol ProtoBuf 或 // Protocol MemoryPack
message C2A_RegisterRequest // IRequest,A2C_RegisterResponse
{
string Username = 1;
string Password = 2;
}
message A2C_RegisterResponse // IResponse
{
}
message C2A_LoginRequest // IRequest,A2C_LoginResponse
{
string Username = 1;
string Password = 2;
int32 LoginType = 3;
}
message A2C_LoginResponse // IResponse
{
string ToKen = 1;
}
/// 客户端登录到Gate服务器
message C2G_LoginRequest // IRequest,G2C_LoginResponse
{
string ToKen = 1;
}
message G2C_LoginResponse // IResponse
{
GameAccountInfo GameAccountInfo = 1;
}
/// 通知客户端重复登录
message G2C_RepeatLogin // IMessage
{
}
/// GameAccount实体类
message GameAccountInfo
{
int64 CreateTime = 1;
int64 LoginTime = 2;
}
/// 拿到当前账号的信息
message C2G_GetAccountInfoRequest // IRequest,G2C_GetAccountInfoResponse
{
}
message G2C_GetAccountInfoResponse // IResponse
{
GameAccountInfo GameAccountInfo = 1;
}
message C2G_TestMessage // IMessage
{
string Tag = 1;
}
message C2G_TestRequest // IRequest,G2C_TestResponse
{
string Tag = 1;
}
message G2C_TestResponse // IResponse
{
string Tag = 1;
}
message C2G_CreateAddressableRequest // IRequest,G2C_CreateAddressableResponse
{
}
message G2C_CreateAddressableResponse // IResponse
{
}
message C2M_TestMessage // IAddressableRouteMessage
{
string Tag = 1;
}
message C2M_TestRequest // IAddressableRouteRequest,M2C_TestResponse
{
string Tag = 1;
}
message M2C_TestResponse // IAddressableRouteResponse
{
string Tag = 1;
}
/// 通知Gate服务器创建一个Chat的Route连接
message C2G_CreateChatRouteRequest // IRequest,G2C_CreateChatRouteResponse
{
}
message G2C_CreateChatRouteResponse // IResponse
{
}
/// 发送一个Route消息给Chat
message C2Chat_TestMessage // ICustomRouteMessage,ChatRoute
{
string Tag = 1;
}
/// 发送一个RPCRoute消息给Chat
message C2Chat_TestMessageRequest // ICustomRouteRequest,Chat2C_TestMessageResponse,ChatRoute
{
string Tag = 1;
}
message Chat2C_TestMessageResponse // ICustomRouteResponse
{
string Tag = 1;
}