|
- cc.exports.OpcodeLoginMarkLog = 103
- cc.exports.OpcodeLoginEchoNot = 0
- --------------------------- 注册登陆 -------------------------
- cc.exports.OpcodeLoginInfoGet = 101
- cc.exports.OpcodeLoginInfoAck = 102
- cc.exports.OpcodeLoginInfoCodeGet = 105
- cc.exports.OpcodeLoginInfoCodeAck = 106
- cc.exports.OpcodeLoginInfoCodeNoti = 901
-
- cc.exports.OpcodeVerifyAnonymousReq = 1001
- cc.exports.OpcodeVerifyPhoneReq = 1002
- cc.exports.OpcodeVerifyAccountAck = 1004
- cc.exports.OpcodeUnidQueryReq = 1009
- cc.exports.OpcodeUnidQueryAck = 1010
- cc.exports.OpcodeBindPhoneReq = 1011
- cc.exports.OpcodeBindPhoneAck = 1012
- cc.exports.OpcodeGetCodeReq = 1017
- cc.exports.OpcodeGetCodeAck = 1018
- cc.exports.OpcodeBindCPAccountReq = 1023
- cc.exports.OpcodeBindCPAccountAck = 1024
- cc.exports.OpcodeQueryByCPAccountReq = 1025
- cc.exports.OpcodeQueryByCPAccountAck = 1026
- cc.exports.OpcodeQueryCPAccountByPIDReq = 1027
- cc.exports.OpcodeQueryCPAccountByPIDAck = 1028
- cc.exports.OpcodeUnbindCPAccountReq = 1029
- cc.exports.OpcodeUnbindCPAccountAck = 1030
-
- G_EapProtos[OpcodeLoginMarkLog] = {
- PID = {1, "uint32"}, --0成功
- LogType = {2, "uint32"}, --失败返回错误描述
- Message = {3, "string"}, --结果数组JSON串
- AppID = {4, "sint32"},
- }
- G_EapProtos[OpcodeLoginEchoNot] = {
-
- }
-
- -------------------------------- 新协议 ----------------------------------
- --------------------------------------------------------------------------
- -- [登陆] ----------->>
- -- 登录大厅
- G_EapProtos[OpcodeLoginInfoGet] = {
- nPID = {1, "uint32"}, -- 用户id
- strTicket = {2, "string"}, -- 用户ticket
- nPlatform = {3, "sint32"}, -- 平台, app:1, sdk:2
- StrMac = {4, "string"}, -- mac地址
- StrIP = {5, "string"}, -- 上报ip
- }
- G_EapProtos[OpcodeLoginInfoAck] = {
- nRet = {1, "sint32"}, -- 0成功, -1数据转换失败 -2平台类型错误 -3删除玩家旧记录失败
- nPID = {2, "uint32"}, -- 用户账号名
- nCurTime = {9, "uint32"}, -- 当前服务器时间
- }
- -- 验证(注册)账号
- G_EapProtos[OpcodeVerifyAnonymousReq] = {
- nSource = {1, "uint32"}, -- 渠道ID
- strDeviceId = {2, "string"}, -- 设备ID
- strIP = {3, "string"}, -- 登录IP地址
- }
-
- --手机号验证(注册)账号
- G_EapProtos[OpcodeVerifyPhoneReq] = {
- nPhone = {1, "uint64"}, -- 用户手机号
- strPassword = {2, "string"}, -- 用户密码
- nSource = {3, "uint32"}, -- 渠道ID
- strDeviceId = {4, "string"}, -- 设备ID
- strIP = {5, "string"}, -- 登录IP地址
- strCodeType = {6, "string"}, -- 验证码的用途(为空则使用密码登录)
- nCode = {7, "uint32"}, -- 短信验证码
- strPhone = {8, "string"}, -- 可选、手机号的字符串类型(兼容无法解析int64的环境)
- }
-
- G_EapProtos[OpcodeVerifyAccountAck] = {
- nRet = {1, "sint32"}, -- 0成功, 1首次验证(注册), -1失败, -6验证码错误, -7验证码失效, -8登录密码为空, -40002用户名不存在, -40004密码错误, -40012禁用IP, -40013禁用账号, -40015禁用设备
- strTicket = {2, "string"}, -- 通行证, 失败为空
- nPID = {3, "uint32"}, -- 用户ID
- ext = {4, "string"}, -- 扩展信息json格式数据
- }
- -- 通过游戏ID查询用户信息
- G_EapProtos[OpcodeQueryByCPAccountReq] = {
- nAppID = {1, "uint32"}, --第三方应用id
- strCPUserID = {2, "string"}, --第三方账号
- }
-
- G_EapProtos[OpcodeQueryByCPAccountAck] = {
- nRet = {1, "sint32"}, --0成功, -1失败, -40018 CP账号信息不存在
- nPID = {2, "uint32"}, --查询用户的ID
- strTicket = {3, "string"}, --通过请求的appid和strCPUserID查找到的pid对应的平台通行证
- }
-
- -- 绑定三方帐号
- G_EapProtos[OpcodeBindCPAccountReq] = {
- nPID = {1, "uint32"}, -- 用户的ID
- strTicket = {2, "string"}, -- 通行证
- nAppID = {3, "uint32"}, -- 第三方应用id
- strCPUserID = {4, "string"}, -- 第三方账号
- strCPUserNickname = {5, "string"}, -- 第三方名称
- }
- G_EapProtos[OpcodeBindCPAccountAck] = {
- nRet = {1, "sint32"}, -- 0:绑定成功 -1:已经绑定其他id
- -- 通过请求的appid和StrThirdID查找到的pid,可能与请求的pid不同;
- -- 此时客户端需要请求此pid详情,用于展示头像、昵称、手机号、微信号等,让用户切换账号
- nPID = {2, "uint32"},
- strTicket = {3, "string"}, -- 通过请求的appid和StrThirdID查找到的pid对应的ticket
- nAppID = {4, "uint32"}, -- nPID对应的应用id
- strCPUserID = {5, "string"}, -- 第三方账号
- strCPUserNickname = {6, "string"}, -- 第三方名称
- }
-
- G_EapProtos["ThirdInfo"] = {
- strThirdAccount = {1, "string"}, -- 第三方账号信息
- nThirdAccountType = {2, "uint32"}, -- 第三方账号类型,1:微信,2:QQ,3:新浪,4:字节,5:苹果
- }
- -- 查询电竞app账号信息
- G_EapProtos[OpcodeUnidQueryReq] = {
- nAccount = {1, "sint64"}, -- nAccount>0为手机号,nAccount<0为nPID
- strPassword = {2, "string"}, -- 是否验证密码,为空为不验证密码
- bIncludeThird = {3, "bool"}, -- 是否查询绑定的第三方账号,0:不查询, 1:查询
- }
-
- G_EapProtos[OpcodeUnidQueryAck] = {
- nRet = {1, "sint32"}, -- 0成功, -1失败, -8参数错误, -40002用户id或帐号不存在
- nPID = {2, "uint32"}, -- 用户ID
- nPhone = {3, "uint64"}, -- 用户注册的手机号
- nSource = {4, "uint32"}, -- 用户注册渠道
- Thirds = {5, "ThirdInfo", "repeated"}, -- 绑定的第三方账号 -- repeated ThirdInfo
- strPhone = {6, "string"},
- nRegTime = {7, "uint32"}, -- 账号注册时间
- strRegIP = {8, "string"}, -- 账号注册IP
- strRegDevice = {9, "string"}, -- 账号注册设备
- }
-
- -- 信息码通知
- G_EapProtos[OpcodeLoginInfoCodeGet] = {
- PID = {2, "sint32"}, --玩家账号
- strTicket = {3, "string"}, --通行证
- Code = {4, "string"}, --信息码,不为空为查询;为空则AppID、GameID不能为空
- MatchID = {5, "string"}, --要报名的赛事
- AppID = {6, "sint32"}, --平台
- GameID = {7, "sint32"}, --游戏ID
- }
-
- G_EapProtos[OpcodeLoginInfoCodeAck] = {
- nRet = {1, "sint32"},
- CodeInfo = {2, "LoginInfoCodeNoti"},
- }
-
- G_EapProtos["LoginInfoCodeNoti"] = {
- Code = {1, "string"}, --信息码
- nPID = {2, "sint32"}, --玩家账号
- strTicket = {3, "string"}, --通行证
- MatchID = {4, "string"}, --要报名的赛事
- AppID = {5, "sint32"}, --平台
- GameID = {6, "sint32"}, --游戏ID
- TimeOut = {7, "uint32"}, --信息码过期时间
- }
-
- G_EapProtos[OpcodeLoginInfoCodeNoti] = {
- Code = {1, "string"}, --信息码
- nPID = {2, "sint32"}, --玩家账号
- strTicket = {3, "string"}, --通行证
- MatchID = {4, "string"}, --要报名的赛事
- AppID = {5, "sint32"}, --平台
- GameID = {6, "sint32"}, --游戏ID
- TimeOut = {7, "uint32"}, --信息码过期时间
- }
-
- -- 获取手机验证码
- G_EapProtos[OpcodeGetCodeReq] = {
- strCodeType = {1, "string"}, -- 验证码的用途(请求方自定义标识)
- nPhoneNum = {2, "uint64"}, -- 手机号
- strPhone = {3, "string"}, -- 可选、手机号的字符串类型(兼容无法解析int64的环境)
- }
-
- G_EapProtos[OpcodeGetCodeAck] = {
- nRet = {1, "sint32"}, -- 0成功, -1失败, -4发送频率过快, -5手机号错误
- strCodeType = {2, "string"}, -- 验证码的用途
- }
-
- -- 绑定手机
- G_EapProtos[OpcodeBindPhoneReq] = {
- nPID = {1, "uint32"}, -- 用户ID
- nPhone = {2, "uint64"}, -- 手机号
- strPassword = {3, "string"}, -- 密码不为空则在绑定手机的同时修改密码(用于第三方账号登录时设定密码)
- strCodeType = {4, "string"}, -- 验证码的用途
- nCode = {5, "uint32"}, -- 短信验证码
- strPhone = {6, "string"}, -- 可选、手机号的字符串类型(兼容无法解析int64的环境)
- }
-
- G_EapProtos[OpcodeBindPhoneAck] = {
- nPID = {1, "uint32"}, -- 用户ID
- nRet = {2, "sint32"}, -- 0成功, -1失败, -6验证码错误, -7验证码失效, -40006注册账号已绑定过手机, -40007手机已被注册
- nPhone = {3, "uint64"}, -- 绑定成功后的手机号
- strPhone = {4, "string"}, -- 可选、手机号的字符串类型(兼容无法解析int64的环境)
- }
-
- -- 通过平台账号查询第三方账号信息
- G_EapProtos[OpcodeQueryCPAccountByPIDReq] = {
- nAppID = {1, "uint32"}, -- 第三方应用ID
- nPID = {2, "uint32"}, -- 用户平台ID
- }
-
- G_EapProtos[OpcodeQueryCPAccountByPIDAck] = {
- nRet = {1, "sint32"}, -- 0成功, -1失败, -40018CP账号信息不存在
- nAppID = {2, "uint32"}, -- 第三方应用ID
- strCPUserID = {3, "string"}, -- 第三方用户账号ID
- strCPName = {4, "string"}, -- 第三方用户账号昵称
- }
-
- -- 解绑第三方游戏账号
- G_EapProtos[OpcodeUnbindCPAccountReq] = {
- nPID = {1, "uint32"}, -- 用户的ID
- strTicket = {2, "string"}, -- 通行证(为空时判断nAppID和strAppSecret是否合法,代表后台操作)
- nAppID = {3, "uint32"}, -- 应用ID(系统分配)
- strAppSecret = {4, "string"}, -- 应用秘钥(系统分配)
- nCPAppID = {5, "uint32"}, -- 第三方应用ID
- strCPUserID = {6, "string"}, -- 第三方用户账号ID
- }
-
- G_EapProtos[OpcodeUnbindCPAccountAck] = {
- nRet = {1, "sint32"}, -- 0解绑成功, -1失败, -2通行证错误, -3通行证失效, -10002应用ID未注册, -10003应用秘钥错误, -10004秘钥失效, -10005未授权接口调用, -40018CP账号信息不存在
- nPID = {2, "uint32"}, -- 用户的ID
- }
|