From 9b1c5e6f0a4dd0c812c0ebf039e8a731d4b2c0a3 Mon Sep 17 00:00:00 2001 From: ALEXTANG <574809918@qq.com> Date: Wed, 17 May 2023 21:38:14 +0800 Subject: [PATCH] [+] proto [+] proto --- .../HotFix/GameProto/GameProtocol/NetMsgId.cs | 23 +++++ .../{ProtoBase.cs.meta => NetMsgId.cs.meta} | 2 +- .../GameProto/GameProtocol/ProtoBase.cs | 68 --------------- .../HotFix/GameProto/GameProtocol/proto_cs.cs | 83 +++++++++++++++++++ .../GameProto/GameProtocol/proto_cs.cs.meta | 11 +++ .../GameProto/GameProtocol/proto_cs_player.cs | 47 +++++++++++ .../GameProtocol/proto_cs_player.cs.meta | 11 +++ 7 files changed, 176 insertions(+), 69 deletions(-) create mode 100644 Assets/GameScripts/HotFix/GameProto/GameProtocol/NetMsgId.cs rename Assets/GameScripts/HotFix/GameProto/GameProtocol/{ProtoBase.cs.meta => NetMsgId.cs.meta} (83%) delete mode 100644 Assets/GameScripts/HotFix/GameProto/GameProtocol/ProtoBase.cs create mode 100644 Assets/GameScripts/HotFix/GameProto/GameProtocol/proto_cs.cs create mode 100644 Assets/GameScripts/HotFix/GameProto/GameProtocol/proto_cs.cs.meta create mode 100644 Assets/GameScripts/HotFix/GameProto/GameProtocol/proto_cs_player.cs create mode 100644 Assets/GameScripts/HotFix/GameProto/GameProtocol/proto_cs_player.cs.meta diff --git a/Assets/GameScripts/HotFix/GameProto/GameProtocol/NetMsgId.cs b/Assets/GameScripts/HotFix/GameProto/GameProtocol/NetMsgId.cs new file mode 100644 index 00000000..92d447f6 --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameProtocol/NetMsgId.cs @@ -0,0 +1,23 @@ +//------------------------------------------------------------------------------ +// +// This code was generated by a tool. +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +// +//------------------------------------------------------------------------------ + +using System; +using ProtoBuf; +using TEngine; +using System.Collections.Generic; + +namespace GameProto +{ + public partial class NetMsgId + { + //帐号登录请求 + public const int CS_CMD_ACT_LOGIN_REQ = 2001; + //帐号登录回包 + public const int CS_CMD_ACT_LOGIN_RES = 2002; + } +} \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameProto/GameProtocol/ProtoBase.cs.meta b/Assets/GameScripts/HotFix/GameProto/GameProtocol/NetMsgId.cs.meta similarity index 83% rename from Assets/GameScripts/HotFix/GameProto/GameProtocol/ProtoBase.cs.meta rename to Assets/GameScripts/HotFix/GameProto/GameProtocol/NetMsgId.cs.meta index 6c89bcdd..e50101b3 100644 --- a/Assets/GameScripts/HotFix/GameProto/GameProtocol/ProtoBase.cs.meta +++ b/Assets/GameScripts/HotFix/GameProto/GameProtocol/NetMsgId.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 6d59eaaad20d9234ba941173b39361fc +guid: 8ae1ad7ae5a3dd64986d462fb9d42d85 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Assets/GameScripts/HotFix/GameProto/GameProtocol/ProtoBase.cs b/Assets/GameScripts/HotFix/GameProto/GameProtocol/ProtoBase.cs deleted file mode 100644 index 6189efbf..00000000 --- a/Assets/GameScripts/HotFix/GameProto/GameProtocol/ProtoBase.cs +++ /dev/null @@ -1,68 +0,0 @@ -//------------------------------------------------------------------------------ -// -// This code was generated by a tool. -// Changes to this file may cause incorrect behavior and will be lost if -// the code is regenerated. -// -//------------------------------------------------------------------------------ - -using System; -using ProtoBuf; -using TEngine; -using System.Collections.Generic; - -namespace GameProto -{ - // 这个文件只放协议,和协议头 - // 消息协议 - [Serializable,global::ProtoBuf.ProtoContract(Name = @"CSPkg")] - public partial class CSPkg - { - [global::ProtoBuf.ProtoMember(1)] - public CSPkgHead Head { get; set; } - - [global::ProtoBuf.ProtoMember(2)] - public CSPkgBody Body { get; set; } - - } - - // 消息协议头 - [Serializable,global::ProtoBuf.ProtoContract(Name = @"CSPkgHead")] - public partial class CSPkgHead - { - [global::ProtoBuf.ProtoMember(1)] - public uint MsgId { get; set; } - - [global::ProtoBuf.ProtoMember(2)] - public uint MsgLength { get; set; } - - [global::ProtoBuf.ProtoMember(3)] - public uint MsgVersion { get; set; } - - [global::ProtoBuf.ProtoMember(4)] - public uint Echo { get; set; } - - [global::ProtoBuf.ProtoMember(5)] - public uint SvrTime { get; set; } - - } - - // 消息协议体 - [Serializable,global::ProtoBuf.ProtoContract(Name = @"CSPkgBody")] - public partial class CSPkgBody - { - } - - // 协议ID - [global::ProtoBuf.ProtoContract()] - public enum CSMsgID - { - CS_START = 0, - - CS_HeartBeat = 10001, - - CS_END = 10000, - - } - -} \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameProto/GameProtocol/proto_cs.cs b/Assets/GameScripts/HotFix/GameProto/GameProtocol/proto_cs.cs new file mode 100644 index 00000000..0fe8ca93 --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameProtocol/proto_cs.cs @@ -0,0 +1,83 @@ +//------------------------------------------------------------------------------ +// +// This code was generated by a tool. +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +// +//------------------------------------------------------------------------------ + +using System; +using ProtoBuf; +using TEngine; +using System.Collections.Generic; + +namespace GameProto +{ + // 这个文件只放协议,和协议头 + // 消息协议 + [Serializable,global::ProtoBuf.ProtoContract(Name = @"CSPkg")] + public partial class CSPkg + { + [global::ProtoBuf.ProtoMember(1)] + public CSPkgHead Head { get; set; } + + [global::ProtoBuf.ProtoMember(2)] + public CSPkgBody Body { get; set; } + + } + + // 消息协议头 + [Serializable,global::ProtoBuf.ProtoContract(Name = @"CSPkgHead")] + public partial class CSPkgHead + { + [global::ProtoBuf.ProtoMember(1)] + public uint MsgId { get; set; } + + [global::ProtoBuf.ProtoMember(2)] + public uint MsgLength { get; set; } + + [global::ProtoBuf.ProtoMember(3)] + public uint MsgVersion { get; set; } + + [global::ProtoBuf.ProtoMember(4)] + public uint Echo { get; set; } + + [global::ProtoBuf.ProtoMember(5)] + public uint SvrTime { get; set; } + + } + + // 消息协议体 + [Serializable,global::ProtoBuf.ProtoContract(Name = @"CSPkgBody")] + public partial class CSPkgBody + { + [global::ProtoBuf.ProtoMember(1)] + public CSActLoginReq ActLoginReq { get; set; } + + [global::ProtoBuf.ProtoMember(2)] + public CSActLoginRes ActLoginRes { get; set; } + + } + + // 消息结果 + [Serializable,global::ProtoBuf.ProtoContract(Name = @"ProtoResult")] + public partial class ProtoResult + { + [global::ProtoBuf.ProtoMember(3)] + public List Params = new List(); + + } + + // 协议ID + [global::ProtoBuf.ProtoContract()] + public enum CSMsgID + { + CS_START = 0, + + CS_HeartBeat = 10001, + + CS_END = 10000, + + } + +} diff --git a/Assets/GameScripts/HotFix/GameProto/GameProtocol/proto_cs.cs.meta b/Assets/GameScripts/HotFix/GameProto/GameProtocol/proto_cs.cs.meta new file mode 100644 index 00000000..9a3bcfcd --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameProtocol/proto_cs.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 46ee51db8f62d67429810f99c3c8effb +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/GameScripts/HotFix/GameProto/GameProtocol/proto_cs_player.cs b/Assets/GameScripts/HotFix/GameProto/GameProtocol/proto_cs_player.cs new file mode 100644 index 00000000..64f3f5db --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameProtocol/proto_cs_player.cs @@ -0,0 +1,47 @@ +//------------------------------------------------------------------------------ +// +// This code was generated by a tool. +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +// +//------------------------------------------------------------------------------ + +using System; +using ProtoBuf; +using TEngine; +using System.Collections.Generic; + +namespace GameProto +{ + // 这个文件只放协议,和协议头 + // 角色登录结果请求 + [Serializable,global::ProtoBuf.ProtoContract(Name = @"CSActLoginReq")] + public partial class CSActLoginReq + { + [global::ProtoBuf.ProtoMember(1)] + public uint Uin { get; set; } + + [global::ProtoBuf.ProtoMember(2)] + public uint SvrID { get; set; } + + [global::ProtoBuf.ProtoMember(3)] + public uint AuthTime { get; set; } + + } + + // 角色登录结果返回 + [Serializable,global::ProtoBuf.ProtoContract(Name = @"CSActLoginRes")] + public partial class CSActLoginRes + { + [global::ProtoBuf.ProtoMember(1)] + public ProtoResult Result { get; set; } + + [global::ProtoBuf.ProtoMember(2)] + public uint Uin { get; set; } + + [global::ProtoBuf.ProtoMember(3)] + public uint RoleID { get; set; } + + } + +} diff --git a/Assets/GameScripts/HotFix/GameProto/GameProtocol/proto_cs_player.cs.meta b/Assets/GameScripts/HotFix/GameProto/GameProtocol/proto_cs_player.cs.meta new file mode 100644 index 00000000..7489f5d1 --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameProtocol/proto_cs_player.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 19264ed823fc740428793e68de7437bf +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: