上传 pb编译工具
This commit is contained in:
parent
97d1a8f46f
commit
eec9ff068d
2
pb.bat
2
pb.bat
@ -4,7 +4,7 @@ set PROJECT_ROOT=.\
|
||||
|
||||
set PROJECT_ROOT=.
|
||||
|
||||
set SRC=%PROJECT_ROOT%\src\pb\proto
|
||||
set SRC=%PROJECT_ROOT%\src\pb\temop
|
||||
set TAR=%PROJECT_ROOT%\src\pb\js
|
||||
|
||||
@REM protoc --proto_path=%SRC% --js_out=import_style=commonjs,binary:%TAR%\. %SRC%\*.proto
|
||||
|
7086
src/pb/proto.js
7086
src/pb/proto.js
File diff suppressed because it is too large
Load Diff
9
src/pb/proto/academy/academy_db.proto
Normal file
9
src/pb/proto/academy/academy_db.proto
Normal file
@ -0,0 +1,9 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
|
||||
//训练营数据
|
||||
message DBAcademy {
|
||||
string uid = 1;
|
||||
map<int32, bool> level = 2;
|
||||
map<string,bool> hero = 3;
|
||||
}
|
44
src/pb/proto/academy/academy_msg.proto
Normal file
44
src/pb/proto/academy/academy_msg.proto
Normal file
@ -0,0 +1,44 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "academy/academy_db.proto";
|
||||
import "battle/battle_msg.proto";
|
||||
import "errorcode.proto";
|
||||
|
||||
///基础信息获取
|
||||
message AcademyInfoReq {}
|
||||
message AcademyInfoResp { DBAcademy info = 1; }
|
||||
|
||||
//挑战
|
||||
message AcademyChallengeReq { int32 level = 1; }
|
||||
message AcademyChallengeResp {
|
||||
ErrorCode code = 1; //是否成功
|
||||
int32 level = 2;
|
||||
BattleInfo info = 3;
|
||||
}
|
||||
|
||||
//领取
|
||||
message AcademyReceiveReq {
|
||||
int32 level = 1;
|
||||
int32 group = 2;
|
||||
BattleReport report = 3; //战报
|
||||
}
|
||||
message AcademyReceiveResp { bool issucc = 1; }
|
||||
|
||||
|
||||
//教学请求
|
||||
message AcademyTeachingReq {
|
||||
string heroId = 1;
|
||||
}
|
||||
message AcademyTeachingResp {
|
||||
ErrorCode code = 1; //是否成功
|
||||
string heroId = 2;
|
||||
BattleInfo info = 3;
|
||||
}
|
||||
|
||||
|
||||
//领取教学奖励
|
||||
message AcademyTeachingReceiveReq {
|
||||
string heroId = 1;
|
||||
BattleReport report = 2; //战报
|
||||
}
|
||||
message AcademyTeachingReceiveResp { bool issucc = 1; }
|
96
src/pb/proto/arena/arena_db.proto
Normal file
96
src/pb/proto/arena/arena_db.proto
Normal file
@ -0,0 +1,96 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "hero/hero_db.proto";
|
||||
//玩家战斗阵型
|
||||
message DBPlayerBattleFormt {
|
||||
int32 leadpos = 1; //队长位置
|
||||
repeated DBHero formt = 2;
|
||||
}
|
||||
|
||||
//玩家基本信息
|
||||
message ArenaPlayer {
|
||||
string uid = 1;
|
||||
string name = 2;
|
||||
string avatar = 3; //@go_tags(`bson:"avatar"`) 头像
|
||||
int32 lv = 4; //@go_tags(`bson:"lv"`) 等级
|
||||
int32 dan = 5; //段位
|
||||
int32 integral = 6;
|
||||
int32 rank = 7; //排名
|
||||
DBPlayerBattleFormt defend = 8; //防守
|
||||
bool isai = 9; //是否是ai
|
||||
int32 mformatid = 10; // AIId
|
||||
int32 changeintegral = 11; //变化积分
|
||||
}
|
||||
|
||||
enum BattleRecordState {
|
||||
AttackWin = 0;
|
||||
AttackLost = 1;
|
||||
DefendkWin = 2;
|
||||
DefendLost = 3;
|
||||
WaitingRevenge = 4;
|
||||
RevengeFailed = 5;
|
||||
RevengeSucceeded = 6;
|
||||
RevengeEnd = 7;
|
||||
}
|
||||
|
||||
message DBHeroBase {
|
||||
string oid = 1; //英雄的唯一id
|
||||
string cid = 2; //英雄配置id
|
||||
int32 star = 3; //英雄星级
|
||||
int32 lv = 4; //英雄等级
|
||||
}
|
||||
//战斗记录
|
||||
message DBArenaBattleRecord {
|
||||
string bid = 1; //战斗id
|
||||
int64 time = 2; //战斗时间
|
||||
bool iswin = 3; //是否胜利
|
||||
bool isdefend = 4; //是否防守
|
||||
string rivalid = 5; //对手id
|
||||
string rivalname = 6; //对手名称
|
||||
int32 leadpos = 7; //队长位置
|
||||
repeated DBHeroBase formt = 8; //阵营
|
||||
int32 addintegral = 9; //积分变化
|
||||
BattleRecordState State = 10; //记录状态
|
||||
}
|
||||
|
||||
//竞技场用户数据
|
||||
message DBArenaUser {
|
||||
string uid = 1; //用户id
|
||||
string name = 2; //玩家名称
|
||||
string avatar = 3; //@go_tags(`bson:"avatar"`) 头像
|
||||
int32 lv = 4; //@go_tags(`bson:"lv"`) 等级
|
||||
int32 integral = 5; //积分
|
||||
// int32 ticket = 6; //挑战券
|
||||
int32 dan = 7; //段位
|
||||
DBPlayerBattleFormt attack = 8; //进攻阵型
|
||||
DBPlayerBattleFormt defend = 9; //防守阵型
|
||||
int32 streak = 10; //连胜
|
||||
int32 attackrate = 11; //进攻胜率
|
||||
int32 defendrate = 12; //防守胜率
|
||||
int32 rank = 13; //排名
|
||||
int32 buynum = 14; //购买次数
|
||||
repeated DBArenaBattleRecord record = 15; //战斗记录
|
||||
int64 lastrtickettime = 16; //最后领劵时间
|
||||
int32 attackwinuum = 17; //进攻胜利次数
|
||||
int32 attacktotaluum = 18; //进攻总次数
|
||||
int32 defendwinuum = 19; //防守胜利
|
||||
int32 defendtotaluum = 20; //防守总
|
||||
repeated double loc = 21; //地图索引 匹配系统使用
|
||||
bool isdef = 22; //是否设置防守
|
||||
map<int32, DBNpc> npc = 23; // npc Cd
|
||||
int32 prededuction = 24; //预扣字段
|
||||
}
|
||||
|
||||
// npc数据
|
||||
message DBNpc {
|
||||
int32 id = 1;
|
||||
int64 cd = 2;
|
||||
int32 index = 3;
|
||||
}
|
||||
|
||||
|
||||
//修改用户积分
|
||||
message RPCModifyIntegralReq {
|
||||
string uid = 1;
|
||||
int32 integral = 2;
|
||||
}
|
100
src/pb/proto/arena/arena_msg.proto
Normal file
100
src/pb/proto/arena/arena_msg.proto
Normal file
@ -0,0 +1,100 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "arena/arena_db.proto";
|
||||
import "battle/battle_msg.proto";
|
||||
import "errorcode.proto";
|
||||
|
||||
//竞技场信息 请求
|
||||
message ArenaInfoReq {}
|
||||
//竞技场信息 回应
|
||||
message ArenaInfoResp { DBArenaUser info = 1; }
|
||||
//竞技场信息 请求 别人的
|
||||
message ArenaOtherInfoReq { string otherId = 1; }
|
||||
//竞技场信息 回应
|
||||
message ArenaOtherInfoResp { DBArenaUser info = 1; }
|
||||
|
||||
//设置进攻阵型
|
||||
message ArenaSetAttFormtReq {
|
||||
int32 leadpos = 1; //队长位置
|
||||
repeated string formt = 2; //进攻阵型
|
||||
}
|
||||
//设置进攻阵型
|
||||
message ArenaSetAttFormtResp { bool issucc = 1; }
|
||||
//设置防守阵型
|
||||
message ArenaSetDefFormtReq {
|
||||
int32 leadpos = 1; //队长位置
|
||||
repeated string formt = 2; //防守阵型
|
||||
}
|
||||
//设置防守阵型
|
||||
message ArenaSetDefFormtResp { bool issucc = 1; }
|
||||
|
||||
//竞技场匹配 请求
|
||||
message ArenaMatcheReq {}
|
||||
//竞技场匹配 回应
|
||||
message ArenaMatcheResp { repeated ArenaPlayer players = 1; }
|
||||
|
||||
//竞技场挑战 请求
|
||||
message ArenaChallengeReq {
|
||||
string playerid = 1;
|
||||
bool isai = 2; //是否是ai
|
||||
int32 mformatId = 3; // AIId
|
||||
BattleFormation battle = 4; //战斗类型
|
||||
}
|
||||
//竞技场挑战 回应
|
||||
message ArenaChallengeResp {
|
||||
ErrorCode code = 1; //是否成功
|
||||
BattleInfo info = 2;
|
||||
}
|
||||
//领取战斗奖励
|
||||
message ArenaChallengeRewardReq {
|
||||
bool iswin = 1; //是否胜利
|
||||
bool isai = 2; //对手是否是ai
|
||||
int32 aiintegral = 3; // ai 积分
|
||||
string ainame = 4; // ai名称
|
||||
BattleReport report = 5; //战报
|
||||
string revengeid = 6; //复仇id
|
||||
}
|
||||
message ArenaChallengeRewardResp { bool issucc = 1; }
|
||||
|
||||
//竞技场排行榜 请求
|
||||
message ArenaRankReq {}
|
||||
//竞技场排行榜 回应
|
||||
message ArenaRankResp { repeated ArenaPlayer players = 1;DBArenaUser info = 2; }
|
||||
|
||||
//购买票据
|
||||
message ArenaBuyReq { int32 buyNum = 1; }
|
||||
message ArenaBuyResp {
|
||||
bool issucc = 1; //是否成功
|
||||
int32 ticket = 2; //当前挑战次数
|
||||
}
|
||||
|
||||
//删除战斗记录
|
||||
message ArenaDelRewardReq {
|
||||
string bid = 1; //战斗id
|
||||
}
|
||||
message ArenaDelRewardResp {
|
||||
bool issucc = 1; //是否成功
|
||||
string bid = 2; //战斗id
|
||||
}
|
||||
|
||||
//剧情战斗 请求
|
||||
message ArenaPlotReq {
|
||||
int32 pid = 1; //剧情id
|
||||
BattleFormation battle = 2; //战斗类型
|
||||
}
|
||||
|
||||
message ArenaPlotResp {
|
||||
ErrorCode code = 1; //是否成功
|
||||
int32 pid = 2; //剧情id
|
||||
BattleInfo info = 3;
|
||||
}
|
||||
//剧情战斗奖励领取 请求
|
||||
message ArenaPlotRewardReq {
|
||||
int32 pid = 1; //剧情id
|
||||
BattleReport report = 2; //战报
|
||||
}
|
||||
|
||||
message ArenaPlotRewardResp {
|
||||
bool issucc = 1;
|
||||
map<int32, DBNpc> npc = 2; // npc Cd
|
||||
}
|
18
src/pb/proto/auto/auto_db.proto
Normal file
18
src/pb/proto/auto/auto_db.proto
Normal file
@ -0,0 +1,18 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "battle/battle_db.proto";
|
||||
import "battle/battle_msg.proto";
|
||||
// 自动战斗
|
||||
message DBAutoBattle {
|
||||
string id = 1; //@go_tags(`bson:"_id"`) ID
|
||||
string uid = 2; //@go_tags(`bson:"uid"`) 用户ID
|
||||
bool autoWin = 3 ; //@go_tags(`bson:"autoWin"`) 失败自动停止
|
||||
bool maxExp = 4 ; //@go_tags(`bson:"maxExp"`)雄达到满级则停止连续战斗
|
||||
bool autoBuy = 5 ; //@go_tags(`bson:"autoBuy"`) 自动购买
|
||||
int32 autoSell = 6; //@go_tags(`bson:"autoSell"`) 自动出售星级装备
|
||||
PlayType ptype = 7; // 类型
|
||||
int32 bossId = 8; //@go_tags(`bson:"bossId"`)
|
||||
int32 difficulty = 9;
|
||||
BattleFormation battle = 10; // 阵容信息
|
||||
}
|
||||
|
46
src/pb/proto/auto/auto_msg.proto
Normal file
46
src/pb/proto/auto/auto_msg.proto
Normal file
@ -0,0 +1,46 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "battle/battle_db.proto";
|
||||
import "battle/battle_msg.proto";
|
||||
import "comm.proto";
|
||||
|
||||
message AutoBattleChallengeReq {
|
||||
int32 bossId = 1; // boos 类型
|
||||
int32 difficulty = 2; // 难度
|
||||
BattleFormation battle = 3;
|
||||
bool autoWin = 4 ; // 失败自动停止
|
||||
bool maxExp = 5 ; //雄达到满级则停止连续战斗
|
||||
bool autoBuy = 6 ; // 自动购买
|
||||
int32 autoSell = 7; // 自动出售星级装备
|
||||
PlayType ptype = 8; // 类型
|
||||
}
|
||||
|
||||
message AutoBattleChallengeResp {
|
||||
BattleInfo info = 1;
|
||||
}
|
||||
|
||||
message AutoBattleOverReq {
|
||||
PlayType ptype = 1; // 类型
|
||||
BattleReport report = 2; //战报
|
||||
}
|
||||
|
||||
// 客户端通知服务器打赢了
|
||||
message AutoBattleOverResp {
|
||||
repeated UserAtno asset = 1;// GameRe // 推送atn
|
||||
BattleInfo info = 2;
|
||||
bool over = 3; // 是否结束
|
||||
}
|
||||
// 自动战斗结束
|
||||
// message AutoBattleOverEnvPush {
|
||||
// bool success = 1;
|
||||
// }
|
||||
|
||||
// 主动结束战斗
|
||||
message AutoBattleStopReq {
|
||||
PlayType ptype = 1; // 类型
|
||||
}
|
||||
|
||||
// 客户端通知服务器打赢了
|
||||
message AutoBattleStopResp {
|
||||
PlayType ptype = 1; // 类型
|
||||
}
|
@ -8,6 +8,7 @@ enum BattleType {
|
||||
pvp = 2;
|
||||
pvb = 3;
|
||||
eve = 4;
|
||||
rtpvp = 5;
|
||||
}
|
||||
|
||||
//玩法类型
|
||||
@ -21,7 +22,11 @@ enum PlayType {
|
||||
moonfantasy = 6; //月之秘境
|
||||
arena = 7; //竞技场
|
||||
academy = 8; //联盟学院
|
||||
heroteaching = 9; //英雄教学
|
||||
heroteaching =9; //英雄教学
|
||||
combat = 10; //新关卡
|
||||
enchant = 11; // 附魔副本
|
||||
sociaty = 12; //工会战
|
||||
friendsmeet = 13; //好友切磋
|
||||
}
|
||||
|
||||
//战斗状态
|
||||
@ -51,12 +56,16 @@ message BattleRole {
|
||||
repeated SkillData equipSkill = 11; //@go_tags(`bson:"normalSkill"`) 普通技能
|
||||
map<string, int32> property = 12; // 属性相关
|
||||
bool ishelp = 13; //是否是助战英雄
|
||||
int32 isboos = 14; //是否是boos
|
||||
int32 monsterid = 15; //怪物id
|
||||
}
|
||||
|
||||
//战斗阵型信息
|
||||
message DBBattleFormt {
|
||||
int32 leadpos = 1; //队长位置
|
||||
repeated BattleRole team = 2;
|
||||
repeated BattleRole team = 2; //自己的战队
|
||||
repeated BattleRole systeam = 3; //系统辅助战队
|
||||
repeated BattleRole backupteam = 4; //后援战队
|
||||
}
|
||||
|
||||
//战斗记录
|
||||
@ -73,4 +82,5 @@ message DBBattleRecord {
|
||||
repeated DBBattleFormt buleflist = 10; //红方阵型列表
|
||||
repeated DBBattleComp roundresult = 11; //战斗场次结果
|
||||
DBBattleComp result = 12; //最终结果
|
||||
repeated int32 tasks = 13; //任务列表
|
||||
}
|
178
src/pb/proto/battle/battle_msg.proto
Normal file
178
src/pb/proto/battle/battle_msg.proto
Normal file
@ -0,0 +1,178 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "battle/battle_db.proto";
|
||||
import "hero/hero_db.proto";
|
||||
import "google/protobuf/any.proto";
|
||||
|
||||
message LineUp {
|
||||
string cid = 1; // 配置表id
|
||||
int32 star = 2; // 星级
|
||||
int32 lv = 3; // 等级
|
||||
}
|
||||
|
||||
//战斗布阵请求
|
||||
message BattleFormation {
|
||||
int32 leadpos = 1; //队长位置
|
||||
repeated string format = 2; //自己英雄阵容信息 0-5
|
||||
repeated string friendformat = 3; //助战好友
|
||||
}
|
||||
// pve 战斗创建请求 (此请求 为服务端间使用 客户端可忽略)
|
||||
message BattleEVEReq {
|
||||
PlayType ptype = 1; //玩法类型
|
||||
string title = 2; //战斗标题
|
||||
BattleFormation format = 3; //布阵信息
|
||||
repeated int32 sysformat = 4; //系统辅助
|
||||
repeated int32 backupformat = 5; //后援辅助
|
||||
repeated int32 buleformat = 6; //蓝方
|
||||
}
|
||||
// pve 战斗创建请求 (此请求 为服务端间使用 客户端可忽略)
|
||||
message BattlePVEReq {
|
||||
PlayType ptype = 1; //玩法类型
|
||||
string title = 2; //战斗标题
|
||||
BattleFormation format = 4; //布阵信息
|
||||
repeated int32 mformat = 5; //敌方增容信息
|
||||
}
|
||||
|
||||
//战斗布阵请求
|
||||
message PVPFormation {
|
||||
string uid = 1; //用户id
|
||||
int32 leadpos = 2; //队长位置
|
||||
repeated DBHero format = 3; //自己英雄阵容信息 0-5
|
||||
}
|
||||
// pvp 异步 战斗创建请求 (此请求 为服务端间使用 客户端可忽略)
|
||||
message BattlePVPReq {
|
||||
PlayType ptype = 1; //玩法类型
|
||||
string title = 2; //战斗标题
|
||||
PVPFormation redformat = 4; //布阵信息
|
||||
PVPFormation buleformat = 5; //布阵信息
|
||||
}
|
||||
|
||||
// pvp 同步 战斗创建请求 (此请求 为服务端间使用 客户端可忽略)
|
||||
message BattleRTPVPReq {
|
||||
PlayType ptype = 1; //玩法类型
|
||||
string title = 2; //战斗标题
|
||||
string redCompId = 6; //红方阵营id
|
||||
repeated BattleFormation redformat = 7; //红方阵型列表
|
||||
string blueCompId = 8; //蓝方阵营id
|
||||
repeated BattleFormation bulefformat = 9; //红方阵型列表
|
||||
}
|
||||
|
||||
// pvb 战斗创建请求 (工会boos战专用)
|
||||
message BattlePVBReq {
|
||||
PlayType ptype = 1; //玩法类型
|
||||
string title = 2; //战斗标题
|
||||
repeated BattleFormation format = 4; //布阵信息
|
||||
repeated int32 mformat = 5; //敌方增容信息
|
||||
}
|
||||
|
||||
//战斗开始推送
|
||||
message BattleInfo {
|
||||
string id = 1; //战斗id
|
||||
string title = 2; //战斗标题
|
||||
string scene = 3; //战斗场景
|
||||
BattleType btype = 4; //战斗类型
|
||||
PlayType ptype = 5; //玩法类型
|
||||
string redCompId = 6; //红方阵营id
|
||||
repeated DBBattleFormt redflist = 7; //红方阵型列表
|
||||
string blueCompId = 8; //蓝方阵营id
|
||||
repeated DBBattleFormt buleflist = 9; //红方阵型列表
|
||||
repeated int32 tasks = 10; //任务列表
|
||||
}
|
||||
|
||||
message BattleCmd {
|
||||
string cmdtype = 1;
|
||||
uint32 index = 2;
|
||||
bytes value = 3;
|
||||
}
|
||||
|
||||
//战报数据
|
||||
message BattleReport {
|
||||
BattleInfo info = 1;
|
||||
int32 Costtime = 2; //战斗时长 单位ms
|
||||
repeated BattleCmd incmd = 3; //输入指令
|
||||
repeated BattleCmd outcmd = 4; //输出指令
|
||||
repeated int32 completetask = 5; //完成任务
|
||||
int32 death = 6; // 死亡人数
|
||||
int32 round = 7; // 回合数
|
||||
int32 harm = 8; //伤害积分
|
||||
}
|
||||
|
||||
//公用消息结构代码
|
||||
message BattleRpcMessage {
|
||||
uint64 rid = 1; //服务回调id
|
||||
string method = 2; //方法名
|
||||
google.protobuf.Any data = 3; //战斗消息对象
|
||||
}
|
||||
|
||||
//战斗校验结果
|
||||
message BattleCheckResults {
|
||||
bool ischeck = 1; //是否校验成功
|
||||
}
|
||||
|
||||
//创建战斗服务 请求
|
||||
message BattleGetInfoReq {
|
||||
string battleid = 1;
|
||||
}
|
||||
|
||||
//创建战斗服务 请求回应
|
||||
message BattleGetInfoResp {
|
||||
string battleid = 1;
|
||||
BattleStateInfo info = 2;
|
||||
}
|
||||
|
||||
//创建战斗服务 请求
|
||||
message BattleCreateServerReq {
|
||||
BattleInfo info= 1;
|
||||
}
|
||||
|
||||
//创建战斗服务 请求回应
|
||||
message BattleCreateServerResp {
|
||||
bool issucc= 1;
|
||||
}
|
||||
|
||||
//创建战斗服务 请求
|
||||
message BattleInCmdReq {
|
||||
string battleid = 1;
|
||||
int32 side = 2;
|
||||
BattleCmd in = 3;
|
||||
}
|
||||
|
||||
|
||||
//创建战斗服务 请求
|
||||
message BattleInCmdResp {
|
||||
string battleid = 1;
|
||||
BattleCmd in = 2;
|
||||
bool issucc = 3;
|
||||
}
|
||||
|
||||
//战斗服务 指令推送
|
||||
message BattleOutCmdPush {
|
||||
string battleid = 1;
|
||||
repeated BattleCmd cmd = 2;
|
||||
}
|
||||
|
||||
//战斗服务 结束推送
|
||||
message BattleFinishPush {
|
||||
string battleid = 1;
|
||||
}
|
||||
|
||||
|
||||
//战斗认输 请求
|
||||
message BattleConcedeReq {
|
||||
string battleid = 1;
|
||||
int32 side = 2;
|
||||
}
|
||||
|
||||
|
||||
// 战斗认输 回应
|
||||
message BattleConcedeResp {
|
||||
bool issucc = 1;
|
||||
}
|
||||
|
||||
//战斗状态数据
|
||||
message BattleStateInfo
|
||||
{
|
||||
BattleInfo info = 1;
|
||||
repeated BattleCmd outCmds = 2;
|
||||
repeated BattleCmd inputCmds = 3;
|
||||
}
|
141
src/pb/proto/battle/battle_struct.proto
Normal file
141
src/pb/proto/battle/battle_struct.proto
Normal file
@ -0,0 +1,141 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "battle/battle_db.proto";
|
||||
import "battle/battle_msg.proto";
|
||||
|
||||
//修改行动值
|
||||
message ComModifyOperate{
|
||||
int32 to = 1;
|
||||
float nv =2; //行动值
|
||||
bool reset = 3;//是否是清零
|
||||
}
|
||||
//战斗开始
|
||||
message ComStartFight{
|
||||
int32 reserve =1;
|
||||
}
|
||||
//初始化战斗角色
|
||||
message ComInitFight{
|
||||
int32 curWave =1; //波次
|
||||
int32 redEntryRid =2; // side=1
|
||||
int32 buleEntryRid =3; // side = 2;
|
||||
int32 playType = 4; //玩法类型
|
||||
repeated BattleRole roles = 5; //角色列表
|
||||
}
|
||||
// 删除角色
|
||||
message ComDeleteRole{
|
||||
int32 to = 1;
|
||||
}
|
||||
//战斗结束指令
|
||||
message ComEndFight{
|
||||
string fightId = 1;
|
||||
int32 winSide =2;
|
||||
int32 totalRound =3; //经历回合
|
||||
int32 RedDeath = 4; //红方死亡统计
|
||||
int32 buleDeath = 5; //蓝方死亡统计
|
||||
}
|
||||
//技能信息
|
||||
message ComSkillInfo{
|
||||
int32 skillId = 1;
|
||||
int32 lv = 2;
|
||||
int32 maxCd = 3;
|
||||
int32 cd = 4;
|
||||
bool showEffect = 5;//是否显示CD恢复特效
|
||||
}
|
||||
//回合开始
|
||||
message ComStartAction{
|
||||
int32 from = 1; //当前出手角色
|
||||
int32 target = 2; //预选攻击目标
|
||||
int32 curRound = 3;
|
||||
repeated ComSkillInfo skillInfo = 4;
|
||||
}
|
||||
|
||||
//角色技能CD
|
||||
message ComSkillCDAction{
|
||||
int32 from = 1;
|
||||
repeated ComSkillInfo skillInfo = 2;
|
||||
}
|
||||
//回合结束
|
||||
message ComStopAction{
|
||||
int32 from = 1; //当前结束回合角色
|
||||
}
|
||||
//等待输入技能
|
||||
message ComWaitInputSkill{
|
||||
bool auto = 1;
|
||||
int32 side = 2;
|
||||
int32 skillId = 3;
|
||||
int32 target = 4;
|
||||
int32 curRound = 5;
|
||||
}
|
||||
//主技能命令
|
||||
message ComSkillAtk{
|
||||
int32 from = 1;
|
||||
int32 skillid = 2;
|
||||
int32 lv = 3;
|
||||
int32 param = 4;
|
||||
int32 target = 5; //释放目标
|
||||
repeated ComSkillAfterAtk comList = 6;
|
||||
string aniName = 7; //预览使用
|
||||
}
|
||||
//子技能
|
||||
message ComSkillAfterAtk{
|
||||
int32 skillid = 1;
|
||||
int32 from = 2;
|
||||
repeated int32 target= 4; //子技能目标(弹道类技能会用到)
|
||||
repeated BattleCmd comList = 5;
|
||||
}
|
||||
//buff
|
||||
message ComMondifyBuff{
|
||||
int32 to = 1;
|
||||
int64 gid = 2; //唯一实体id
|
||||
int32 buffId = 3; //配置id
|
||||
int32 overlapNum = 4; //叠加层数
|
||||
float param = 5; //参数 - 护盾量
|
||||
int32 operate = 6; // 0 移除 1 添加 2 修改
|
||||
}
|
||||
//复活
|
||||
message ComRebirth{
|
||||
int32 to = 1;
|
||||
}
|
||||
//血量变化
|
||||
message ComModifyHealth{
|
||||
int32 to = 1;
|
||||
int32 from = 2;
|
||||
bool baoji = 3;
|
||||
bool hideDmg = 4;
|
||||
int32 modifyType = 5;
|
||||
float num = 6;
|
||||
int32 nhp = 7;
|
||||
int32 mhp = 8;
|
||||
}
|
||||
//教学任务更新
|
||||
message ComTeachTask{
|
||||
int32 id = 1;
|
||||
int32 count = 2;
|
||||
}
|
||||
//剧情
|
||||
message ComStory{
|
||||
int32 id = 1;
|
||||
int32 storyId = 2;
|
||||
}
|
||||
//剧情
|
||||
message ComGuide{
|
||||
int32 id = 1;
|
||||
int32 guideId = 2;
|
||||
}
|
||||
//中途创建角色
|
||||
message ComCreateRoles{
|
||||
int32 side = 1;
|
||||
int32 entryRid = 2;
|
||||
int32 playType = 3;
|
||||
repeated BattleRole roles = 4;
|
||||
}
|
||||
//播放特效
|
||||
message ComPlayEffect{
|
||||
string effectName = 1;
|
||||
int32 side = 2;
|
||||
}
|
||||
//出手倒计时
|
||||
message ComEmitCountdown
|
||||
{
|
||||
int32 reserve =1;
|
||||
}
|
@ -1,65 +0,0 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "battle_db.proto";
|
||||
import "hero_db.proto";
|
||||
|
||||
message LineUp {
|
||||
string cid = 1; // 配置表id
|
||||
int32 star = 2; // 星级
|
||||
int32 lv = 3; // 等级
|
||||
}
|
||||
|
||||
//战斗布阵请求
|
||||
message BattleFormation {
|
||||
int32 leadpos = 1; //队长位置
|
||||
repeated string format = 2; //自己英雄阵容信息 0-5
|
||||
repeated string friendformat = 3; //助战好友
|
||||
}
|
||||
// pve 战斗创建请求 (此请求 为服务端间使用 客户端可忽略)
|
||||
message BattleEVEReq {
|
||||
PlayType ptype = 1; //玩法类型
|
||||
string title = 2; //战斗标题
|
||||
repeated int32 redformat = 3; //红方
|
||||
repeated int32 buleformat = 4; //蓝方
|
||||
}
|
||||
// pve 战斗创建请求 (此请求 为服务端间使用 客户端可忽略)
|
||||
message BattlePVEReq {
|
||||
PlayType ptype = 1; //玩法类型
|
||||
string title = 2; //战斗标题
|
||||
BattleFormation format = 4; //布阵信息
|
||||
repeated int32 mformat = 5; //敌方增容信息
|
||||
}
|
||||
|
||||
//战斗布阵请求
|
||||
message PVPFormation {
|
||||
string uid = 1; //用户id
|
||||
int32 leadpos = 2; //队长位置
|
||||
repeated DBHero format = 3; //自己英雄阵容信息 0-5
|
||||
}
|
||||
// pve 战斗创建请求 (此请求 为服务端间使用 客户端可忽略)
|
||||
message BattlePVPReq {
|
||||
PlayType ptype = 1; //玩法类型
|
||||
string title = 2; //战斗标题
|
||||
PVPFormation redformat = 4; //布阵信息
|
||||
PVPFormation buleformat = 5; //布阵信息
|
||||
}
|
||||
//战斗开始推送
|
||||
message BattleInfo {
|
||||
string id = 1; //战斗id
|
||||
string title = 2; //战斗标题
|
||||
BattleType btype = 3; //战斗类型
|
||||
PlayType ptype = 4; //玩法类型
|
||||
string redCompId = 5; //红方阵营id
|
||||
repeated DBBattleFormt redflist = 6; //红方阵型列表
|
||||
string blueCompId = 7; //蓝方阵营id
|
||||
repeated DBBattleFormt buleflist = 8; //红方阵型列表
|
||||
repeated int32 tasks = 9; //任务列表
|
||||
}
|
||||
|
||||
//战报数据
|
||||
message BattleReport {
|
||||
BattleInfo info = 1;
|
||||
int32 Costtime = 2; //战斗时长 单位ms
|
||||
bytes process = 3; //战斗过程数据
|
||||
repeated int32 completetask = 4; //完成任务
|
||||
}
|
@ -26,8 +26,8 @@ message DBChat {
|
||||
string suid = 4; //发送用户id
|
||||
int32 slv = 5; //发送者等级
|
||||
string ruid = 6; //接收用户id channel == Private 有效
|
||||
int32 channelId = 7; //跨服频道 频道Id
|
||||
string unionId = 8; //工会id
|
||||
int32 channelId = 7; //@go_tags(`bson:"channelId"`) ID跨服频道 频道Id
|
||||
string unionId = 8; //@go_tags(`bson:"unionId"`)工会id
|
||||
string stag = 9; //区服id
|
||||
string avatar = 10; //用户头像
|
||||
string uname = 11; //用户名
|
||||
@ -36,5 +36,7 @@ message DBChat {
|
||||
int64 appendInt = 14; //@go_tags(`bson:"appendInt"`) 聊天附加数据
|
||||
string appendStr = 15; //@go_tags(`bson:"appendStr"`) 聊天附加数据
|
||||
string appendBool = 16; //@go_tags(`bson:"appendBool"`) 聊天附加数据
|
||||
bytes appendBytes = 17; //@go_tags(`bson:"appendInt"`) 聊天附加数据
|
||||
bytes appendBytes = 17; //@go_tags(`bson:"appendBytes"`) 聊天附加数据
|
||||
bool display = 18; //@go_tags(`bson:"display"`)是否显示到跑马灯
|
||||
repeated string appendStrs = 19; //@go_tags(`bson:"appendStrs"`) 聊天附加数据
|
||||
}
|
@ -1,6 +1,6 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "chat_db.proto";
|
||||
import "chat/chat_db.proto";
|
||||
|
||||
//聊天消息推送
|
||||
message ChatMessagePush { DBChat chat = 1; }
|
||||
@ -22,19 +22,20 @@ message ChatChanageChannelResp {
|
||||
message ChatGetListReq {
|
||||
ChatChannel channel = 1; //频道
|
||||
int32 channelId = 2; //跨服频道id
|
||||
string unionId = 3; //工会id
|
||||
}
|
||||
|
||||
//请求聊天消息 回应
|
||||
message ChatGetListResp { repeated DBChat chats = 1; }
|
||||
|
||||
//跨服请求聊天消息
|
||||
message ChatGetCrossListReq {
|
||||
ChatChannel channel = 1; //频道
|
||||
int32 channelId = 2; //跨服频道id
|
||||
}
|
||||
// //跨服请求聊天消息
|
||||
// message ChatGetCrossListReq {
|
||||
// ChatChannel channel = 1; //频道
|
||||
// int32 channelId = 2; //跨服频道id
|
||||
// }
|
||||
|
||||
//跨服请求聊天消息 回应
|
||||
message ChatGetCrossListResp { repeated DBChat chats = 1; }
|
||||
// //跨服请求聊天消息 回应
|
||||
// message ChatGetCrossListResp { repeated DBChat chats = 1; }
|
||||
|
||||
//消息发送请求
|
||||
message ChatSendReq {
|
||||
@ -56,22 +57,22 @@ message ChatSendResp {
|
||||
bool issucc = 1; //是否成功
|
||||
}
|
||||
|
||||
//跨服消息发送请求
|
||||
message ChatSendCrossReq {
|
||||
string avatar = 1; //用户头像
|
||||
string uname = 2; //用户名
|
||||
int32 ulv = 3; //用户等级
|
||||
ChatChannel channel = 4; //频道
|
||||
string targetId = 5; //目标用户id
|
||||
ChatType ctype = 6; //消息类型
|
||||
string content = 7; //内容
|
||||
int64 appendInt = 8; //@go_tags(`bson:"appendInt"`) 聊天附加数据
|
||||
string appendStr = 9; //@go_tags(`bson:"appendStr"`) 聊天附加数据
|
||||
string appendBool = 10; //@go_tags(`bson:"appendBool"`) 聊天附加数据
|
||||
bytes appendBytes = 11; //@go_tags(`bson:"appendInt"`) 聊天附加数据
|
||||
}
|
||||
// //跨服消息发送请求
|
||||
// message ChatSendCrossReq {
|
||||
// string avatar = 1; //用户头像
|
||||
// string uname = 2; //用户名
|
||||
// int32 ulv = 3; //用户等级
|
||||
// ChatChannel channel = 4; //频道
|
||||
// string targetId = 5; //目标用户id
|
||||
// ChatType ctype = 6; //消息类型
|
||||
// string content = 7; //内容
|
||||
// int64 appendInt = 8; //@go_tags(`bson:"appendInt"`) 聊天附加数据
|
||||
// string appendStr = 9; //@go_tags(`bson:"appendStr"`) 聊天附加数据
|
||||
// string appendBool = 10; //@go_tags(`bson:"appendBool"`) 聊天附加数据
|
||||
// bytes appendBytes = 11; //@go_tags(`bson:"appendInt"`) 聊天附加数据
|
||||
// }
|
||||
|
||||
//跨服消息发送请求 回应
|
||||
message ChatSendCrossResp {
|
||||
bool issucc = 1; //是否成功
|
||||
}
|
||||
// //跨服消息发送请求 回应
|
||||
// message ChatSendCrossResp {
|
||||
// bool issucc = 1; //是否成功
|
||||
// }
|
16
src/pb/proto/combat/combat_db.proto
Normal file
16
src/pb/proto/combat/combat_db.proto
Normal file
@ -0,0 +1,16 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
|
||||
message DBCombatUser {
|
||||
string uid = 1; //uid
|
||||
map<int32, DBCombatLevel> level = 2; //关卡信息
|
||||
}
|
||||
|
||||
message DBCombatLevel {
|
||||
int32 id = 1;
|
||||
map<string,string> data = 2; //管卡信息
|
||||
repeated int32 passmanster= 3; //通关怪物列表
|
||||
repeated int32 passdrop= 4; //通关宝箱列表
|
||||
bool pass = 5; //是否通关
|
||||
int32 progress = 6; //进度
|
||||
}
|
69
src/pb/proto/combat/combat_msg.proto
Normal file
69
src/pb/proto/combat/combat_msg.proto
Normal file
@ -0,0 +1,69 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "errorcode.proto";
|
||||
import "comm.proto";
|
||||
import "combat/combat_db.proto";
|
||||
import "battle/battle_msg.proto";
|
||||
|
||||
|
||||
//关卡进入请求
|
||||
message CombatInReq {
|
||||
int32 id = 1; //关卡id
|
||||
}
|
||||
|
||||
//关卡进入请求
|
||||
message CombatInResp {
|
||||
DBCombatLevel level = 2; //管卡信息
|
||||
}
|
||||
|
||||
message CombatUpdateLevelReq {
|
||||
int32 level = 1; //管卡id
|
||||
map<string,string> data = 2; //坐标
|
||||
}
|
||||
|
||||
message CombatUpdateLevelResp {
|
||||
bool succ = 1; //是否成功
|
||||
int32 level = 2; //管卡id
|
||||
}
|
||||
|
||||
//战斗请求
|
||||
message CombatChallengeReq {
|
||||
int32 level = 1; //管卡id
|
||||
int32 manster = 2; //怪物id
|
||||
BattleFormation battle = 3; //布阵信息
|
||||
}
|
||||
|
||||
//战斗请求 回应
|
||||
message CombatChallengeResp {
|
||||
ErrorCode code = 1; //是否成功
|
||||
int32 level = 2; //管卡id
|
||||
int32 manster = 3;
|
||||
BattleInfo info = 4;
|
||||
}
|
||||
|
||||
//战斗奖励领取
|
||||
message CombatChallengeReceiveReq {
|
||||
int32 level = 1; //管卡id
|
||||
int32 manster = 2;
|
||||
BattleReport report = 3; //战报
|
||||
}
|
||||
//战斗奖励领取
|
||||
message CombatChallengeReceiveResp {
|
||||
bool issucc = 1;
|
||||
int32 level = 2; //管卡id
|
||||
bool pass = 3; //是否通关
|
||||
}
|
||||
|
||||
//宝箱获取请求
|
||||
message CombatDropReq {
|
||||
int32 level = 1; //管卡id
|
||||
int32 drop = 2; //宝箱id
|
||||
}
|
||||
|
||||
//宝箱获取请求
|
||||
message CombatDropResp {
|
||||
ErrorCode code = 1; //是否成功
|
||||
repeated UserAssets atns = 2; //获取物品
|
||||
int32 level = 3; //管卡id
|
||||
bool pass = 4; //是否通关
|
||||
}
|
@ -1,9 +0,0 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
|
||||
message DBCombatUser {
|
||||
string uid = 1; //uid
|
||||
int32 currlevel = 2; //当前所在关卡
|
||||
repeated int32 passmanster= 3; //通关怪物列表
|
||||
repeated int32 passdrop= 4; //通关宝箱列表
|
||||
}
|
@ -1,57 +0,0 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "errorcode.proto";
|
||||
import "comm.proto";
|
||||
import "battle_msg.proto";
|
||||
|
||||
//关卡进入请求
|
||||
message CombatInReq {
|
||||
int32 id = 1; //关卡id
|
||||
}
|
||||
|
||||
//关卡进入请求
|
||||
message CombatInResp {
|
||||
int32 id = 1; //关卡id
|
||||
}
|
||||
|
||||
//关卡离开请求
|
||||
message CombatOutReq {
|
||||
int32 id = 1; //关卡id
|
||||
}
|
||||
|
||||
//关卡离开请求 回应
|
||||
message CombatOutResp {
|
||||
int32 id = 1; //关卡id
|
||||
}
|
||||
|
||||
//战斗请求
|
||||
message CombatChallengeReq {
|
||||
int32 manster = 1; //怪物id
|
||||
BattleFormation battle = 2; //布阵信息
|
||||
}
|
||||
|
||||
//战斗请求 回应
|
||||
message CombatChallengeResp {
|
||||
ErrorCode code = 1; //是否成功
|
||||
int32 manster = 2;
|
||||
BattleInfo info = 3;
|
||||
}
|
||||
|
||||
//战斗奖励领取
|
||||
message CombatChallengeReceiveReq {
|
||||
int32 manster = 1;
|
||||
BattleReport report = 2; //战报
|
||||
}
|
||||
//战斗奖励领取
|
||||
message CombatChallengeReceiveResp { bool issucc = 1; }
|
||||
|
||||
//宝箱获取请求
|
||||
message CombatDropReq {
|
||||
int32 drop = 1; //宝箱id
|
||||
}
|
||||
|
||||
//宝箱获取请求
|
||||
message CombatDropResp {
|
||||
ErrorCode code = 1; //是否成功
|
||||
repeated UserAssets atns = 2; //获取物品
|
||||
}
|
@ -93,6 +93,11 @@ enum HeroAttributesType {
|
||||
Crit = 4; //暴击
|
||||
}
|
||||
|
||||
message SkillData {
|
||||
int32 skillID = 1;
|
||||
int32 skillLv = 2;
|
||||
}
|
||||
|
||||
//用户资产数据 对标*cfg.Game_atn 数据结构
|
||||
message UserAssets {
|
||||
string A = 1;
|
||||
@ -100,6 +105,14 @@ message UserAssets {
|
||||
int32 N = 3;
|
||||
}
|
||||
|
||||
// ATNO 类型
|
||||
message UserAtno {
|
||||
string A = 1;
|
||||
string T = 2;
|
||||
int32 N = 3;
|
||||
string O = 4;
|
||||
}
|
||||
|
||||
message TaskParam {
|
||||
int32 first = 1; //限定条件
|
||||
int32 second = 2; //次数
|
||||
@ -110,3 +123,54 @@ message RtaskParam {
|
||||
int32 param2 = 2;
|
||||
int32 param3 = 3;
|
||||
}
|
||||
|
||||
message UIdReq { string uid = 1; }
|
||||
|
||||
message NameReq { string name = 1; }
|
||||
|
||||
message EmptyReq {}
|
||||
message EmptyResp {}
|
||||
// rpc 通用请求消息 1
|
||||
message RPCGeneralReqA1 { string param1 = 1; }
|
||||
// rpc 通用请求消息 1
|
||||
message RPCGeneralReqA2 {
|
||||
string param1 = 1;
|
||||
string param2 = 2;
|
||||
}
|
||||
// rpc 通用请求消息 1
|
||||
message RPCGeneralReqA3 {
|
||||
string param1 = 1;
|
||||
string param2 = 2;
|
||||
string param3 = 3;
|
||||
}
|
||||
// rpc 通用请求消息 1
|
||||
message RPCGeneralReqA4 {
|
||||
string param1 = 1;
|
||||
string param2 = 2;
|
||||
string param3 = 3;
|
||||
string param4 = 4;
|
||||
}
|
||||
|
||||
// rpc 通用请求消息 1
|
||||
message RPCRTaskReq {
|
||||
string uid = 1;
|
||||
int32 taskType = 2;
|
||||
repeated int32 param = 3;
|
||||
}
|
||||
|
||||
//服务列表信息
|
||||
message ServiceDBInfo{
|
||||
string serverid = 1; //@go_tags(`bson:"serverid"`)
|
||||
string serverName = 2; //@go_tags(`bson:"serverName"`)
|
||||
string owner = 3; //@go_tags(`bson:"owner"`)
|
||||
string cross = 4; //@go_tags(`bson:"cross"`)
|
||||
string crossId = 5; //@go_tags(`bson:"crossId"`)
|
||||
string singleserver = 6; //@go_tags(`bson:"singleserver"`)
|
||||
int64 opentime = 7; //@go_tags(`bson:"opentime"`)
|
||||
bool redisIsCluster = 8; //@go_tags(`bson:"redisIsCluster"`)
|
||||
repeated string redisAddr = 9; //@go_tags(`bson:"redisAddr"`)
|
||||
string redisPassword = 10; //@go_tags(`bson:"redisPassword"`)
|
||||
int32 redisDb = 11; //@go_tags(`bson:"redisDb"`)
|
||||
string MongodbUrl = 12; //@go_tags(`bson:"MongodbUrl"`)
|
||||
string mongodbDatabase = 13; //@go_tags(`bson:"mongodbDatabase"`)
|
||||
}
|
26
src/pb/proto/enchant/enchant_db.proto
Normal file
26
src/pb/proto/enchant/enchant_db.proto
Normal file
@ -0,0 +1,26 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "battle/battle_msg.proto";
|
||||
|
||||
message DBEnchant {
|
||||
string id = 1; //@go_tags(`bson:"_id"`) ID
|
||||
string uid = 2; //@go_tags(`bson:"uid"`) 用户ID
|
||||
map<int32,int64> boss = 3; // key boss 类型 value 积分
|
||||
int32 buyCount = 4;//@go_tags(`bson:"buyCount"`) 购买次数
|
||||
int64 cTime = 5; //@go_tags(`bson:"cTime"`) 修改时间
|
||||
map<int32,int32> bossTime = 6; //@go_tags(`bson:"bossTime"`)
|
||||
int64 recoveryTime = 7; //@go_tags(`bson:"recoveryTime"`) // 开始恢复的时间
|
||||
}
|
||||
|
||||
// 排行榜
|
||||
message DBEnchantRank {
|
||||
string id = 1; //@go_tags(`bson:"_id"`) ID
|
||||
string uid = 2; //@go_tags(`bson:"uid"`) 用户ID
|
||||
int32 bosstype = 3; // boss类型塔类型
|
||||
string nickname = 4;// 昵称
|
||||
int32 lv = 5; // 玩家等级
|
||||
int32 leadpos = 6; //队长位置
|
||||
repeated LineUp line = 7; // 阵容数据
|
||||
int32 costTime = 8; //@go_tags(`bson:"costTime"`) 闯关耗时 单位s
|
||||
int64 score = 9; //@go_tags(`bson:"score"`)
|
||||
}
|
52
src/pb/proto/enchant/enchant_msg.proto
Normal file
52
src/pb/proto/enchant/enchant_msg.proto
Normal file
@ -0,0 +1,52 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "enchant/enchant_db.proto";
|
||||
import "battle/battle_msg.proto";
|
||||
message EnchantGetListReq {
|
||||
|
||||
}
|
||||
|
||||
message EnchantGetListResp {
|
||||
DBEnchant data = 1;
|
||||
}
|
||||
|
||||
// 挑战
|
||||
message EnchantChallengeReq {
|
||||
int32 bossType = 1; // boos 类型
|
||||
BattleFormation battle = 2;
|
||||
}
|
||||
|
||||
message EnchantChallengeResp {
|
||||
BattleInfo info = 1;
|
||||
int32 bossType = 2; // boos 类型
|
||||
}
|
||||
|
||||
message EnchantChallengeOverReq {
|
||||
int32 bossType = 1; // boos 类型
|
||||
BattleReport report = 2; //战报
|
||||
int64 score = 3; //获得积分 或伤害
|
||||
}
|
||||
|
||||
// 客户端通知服务器打赢了
|
||||
message EnchantChallengeOverResp {
|
||||
DBEnchant data = 1;
|
||||
}
|
||||
|
||||
// 购买
|
||||
message EnchantBuyReq {
|
||||
int32 count = 1;// 购买次数
|
||||
}
|
||||
|
||||
message EnchantBuyResp {
|
||||
DBEnchant data = 1;
|
||||
}
|
||||
|
||||
// 排行榜
|
||||
message EnchantRankListReq{
|
||||
int32 boosType = 1; // boss 类型
|
||||
bool friend = 2; // 是否是好友榜
|
||||
}
|
||||
|
||||
message EnchantRankListResp{
|
||||
repeated DBEnchantRank ranks = 1; // 排行数据 有序的 注意boss类型
|
||||
}
|
@ -9,6 +9,16 @@ message EquipmentAttributeEntry {
|
||||
int32 Lv = 4; //属性等级
|
||||
int32 Value = 5; //属性值
|
||||
int32 BaseValue = 6; //基础属性
|
||||
int32 EnchValue =7; //附魔属性
|
||||
}
|
||||
|
||||
//装备技能词条 特殊装备/武器or饰品
|
||||
message EquipmentSkillEntry {
|
||||
int32 Id = 1; //属性词条主键id 唯一
|
||||
int32 libraryid = 2; //属性词条id 非唯一
|
||||
string AttrName = 3; //属性名
|
||||
int32 SkillId = 4; //技能id
|
||||
int32 Lv = 5; //属性等级
|
||||
}
|
||||
|
||||
//武器数据
|
||||
@ -26,4 +36,6 @@ message DB_Equipment {
|
||||
uint32 overlayNum = 9; //@go_tags(`bson:"overlayNum"`) 叠加数量
|
||||
bool isInitialState = 10; //@go_tags(`bson:"isInitialState"`) 是否初始状态
|
||||
bool islock = 11; //@go_tags(`bson:"islock"`) 是否锁
|
||||
repeated EquipmentSkillEntry adverbskill =
|
||||
12; //@go_tags(`bson:"adverbskill"`) 装备副技能
|
||||
}
|
@ -1,6 +1,7 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "equipment_db.proto";
|
||||
import "equipment/equipment_db.proto";
|
||||
import "comm.proto";
|
||||
|
||||
//获取装备列表请求
|
||||
message EquipmentGetListReq {}
|
||||
@ -55,3 +56,41 @@ message EquipmentSellReq { repeated string EquipIds = 1; }
|
||||
|
||||
//出售道具请求 回应
|
||||
message EquipmentSellResp { bool IsSucc = 1; }
|
||||
|
||||
//锻造请求
|
||||
message EquipmentForgReq {
|
||||
int32 forgid = 1;
|
||||
int32 num = 2;
|
||||
}
|
||||
|
||||
//锻造请求 回应
|
||||
message EquipmentForgResp {
|
||||
bool issucc = 1;
|
||||
repeated UserAssets reward = 2;
|
||||
}
|
||||
|
||||
//洗练
|
||||
message EquipmentWashReq { string eid = 1; }
|
||||
message EquipmentWashResp {
|
||||
string eid = 1;
|
||||
repeated EquipmentAttributeEntry adverbEntry = 2;
|
||||
}
|
||||
|
||||
//洗练确认
|
||||
message EquipmentWashConfirmReq {
|
||||
string eid = 1;
|
||||
repeated int32 pids = 2;
|
||||
}
|
||||
message EquipmentWashConfirmResp { bool issucc = 1; }
|
||||
|
||||
//装备附魔 请求
|
||||
message EquipmentEnchReq {
|
||||
string eid = 1;
|
||||
string itemid = 2;
|
||||
int32 index = 3;
|
||||
}
|
||||
//装备附魔 回应
|
||||
message EquipmentEnchResp {
|
||||
bool issucc = 1;
|
||||
DB_Equipment Equipment = 2;
|
||||
}
|
@ -1,6 +1,6 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
|
||||
// go:generate stringer -type ErrorCode -linecomment
|
||||
enum ErrorCode {
|
||||
Success = 0; //成功
|
||||
NoFindService = 10; //没有找到远程服务器
|
||||
@ -26,6 +26,7 @@ enum ErrorCode {
|
||||
ConfigurationException = 103; //配置异常
|
||||
ConfigNoFound = 104; //配置未找到
|
||||
UserLogined = 105; //已在其它终端登录
|
||||
NoOpened = 106; //模块未开放
|
||||
|
||||
// user
|
||||
SecKeyInvalid = 1000; //秘钥无效
|
||||
@ -43,6 +44,13 @@ enum ErrorCode {
|
||||
UserExpandNull = 1012; //扩展数据空
|
||||
UserExpNoEnough = 1013; //经验不足
|
||||
UserFriendNoEnough = 1014; //友情点不足
|
||||
UserSociatyCoinNoEnough = 1015; //公会币不足
|
||||
UserArenaCoinNoEnough = 1016; //竞技场币不足
|
||||
UserVitNoEnough = 1017; //体力不足
|
||||
UserVitLimit = 1018; //体力达到最大上限
|
||||
UserMoongoldNoEnough=1019; //纯净月髓不足
|
||||
UserOffline = 1020; //玩家不在线
|
||||
UserNofound = 1021; //未查询到玩家
|
||||
|
||||
// friend
|
||||
FriendNotSelf = 1100; //不能是自己
|
||||
@ -62,6 +70,11 @@ enum ErrorCode {
|
||||
FriendZanSelf = 1114; //不能给自己点赞
|
||||
FriendPointLimit = 1115; //友情点上线
|
||||
FriendNoreceived = 1116; //未更换助战没有可领取的奖励
|
||||
FriendQiecuoTimeout = 1117; //切磋请求超时
|
||||
FriendQiecuoRequested = 1118; //已发送切磋请求
|
||||
FriendQiecuoNoRequest = 1119; //无切磋请求
|
||||
FriendQiecuoing = 1120; //好友切磋中
|
||||
FriendQiecuoTargetPk = 1121; //目标已经在战斗
|
||||
|
||||
// item
|
||||
ItemsNoEnough = 1200; //背包物品不足
|
||||
@ -70,6 +83,7 @@ enum ErrorCode {
|
||||
ItemsGirdAmountUpper = 1203; //背包格子容量已达上限
|
||||
ItemsUseNotSupported = 1204; //暂不支持使用
|
||||
ItemsUseNoCanSell = 1205; //道具不支持出售
|
||||
ItemsBuyPsUpperLimit = 1206; //体力购买达到上限
|
||||
|
||||
// hero
|
||||
HeroNoExist = 1300; //英雄不存在
|
||||
@ -97,6 +111,7 @@ enum ErrorCode {
|
||||
DrawCardTypeNotFound = 1322; // 抽卡类型不匹配
|
||||
HeroMaxSkillLv = 1323; // 达到最大技能等级
|
||||
HeroAlreadyKongFuStatus = 1324; // 已经是练功状态
|
||||
HeroLvNoEnough = 1325; // 英雄等级不足
|
||||
|
||||
// equipment
|
||||
EquipmentOnFoundEquipment = 1400; // 未找到武器
|
||||
@ -111,6 +126,7 @@ enum ErrorCode {
|
||||
MainlinePreNotFound = 1503; // 前置关卡不匹配
|
||||
MainlineRepeatReward = 1504; // 重复领奖
|
||||
MainlineCompleteReward = 1505; // 通关才能领奖
|
||||
MainlineNoEnoughStar = 1506; // 扫荡通关星级不够
|
||||
|
||||
// task
|
||||
TaskInit = 1600; //初始化失败
|
||||
@ -174,15 +190,129 @@ enum ErrorCode {
|
||||
BattleNoFoundRecord = 2501; // 未找到记录
|
||||
|
||||
LinestoryTaskFinished = 2601; //任务已完成
|
||||
LinestorySubTaskFinished = 2602; //子任务已完成
|
||||
LinestoryNoReceive = 2602; //章节奖励不能领取
|
||||
LinestoryTaskDisabledEnter = 2603; //禁止进入
|
||||
LinestoryPreTaskNoFinished = 2604; //前置任务未完成
|
||||
LinestoryChapterNoOpen = 2604; //章节未开启
|
||||
LinestoryPreNoComplete = 2605; //前置任务未完成
|
||||
|
||||
// hunting
|
||||
HuntingLvErr = 2701; // 关卡难度不匹配
|
||||
HuntingBoosType = 2702; // BOSS 类型不对
|
||||
HuntingBuyMaxCount = 2703; // 购买达到最大次数
|
||||
HuntingMaxChallengeCount = 2704; // 挑战达到最大次数
|
||||
HuntingNoChallengeCount = 2705; // 挑战次数不足
|
||||
|
||||
// Enchant
|
||||
EnchantLvErr = 2711; // 关卡难度不匹配
|
||||
EnchantBoosType = 2712; // BOSS 类型不对
|
||||
EnchantBuyMaxCount = 2713; // 购买达到最大次数
|
||||
EnchantMaxChallengeCount = 2714; // 挑战达到最大次数
|
||||
EnchantNoChallengeCount = 2715; // 挑战达到最大次数
|
||||
// library
|
||||
LibraryMaxLv = 2801; // 达到最大等级
|
||||
LibraryNoData = 2802; // 没找到羁绊数据
|
||||
LibraryActivation = 2803; // 已经是激活状态
|
||||
LibraryReward = 2804; // 已经领取奖励
|
||||
LibraryLvReward = 2805; // 领奖等级没达到
|
||||
LibraryFetterTaskNoFound = 2806; //未找到羁绊任务数据
|
||||
LibraryPreTaskNoFinished = 2807; //前置任务未完成
|
||||
|
||||
// Battle
|
||||
BattleValidationFailed = 2901; //战斗校验失败
|
||||
BattleNoWin = 2902; //战斗失败
|
||||
BattleCreateFailed = 2903; //创建战斗失败
|
||||
BattleInCmdFailed = 2904; //战斗指令输入失败
|
||||
BattleUserOff = 2905; //由用户离线
|
||||
|
||||
// sociaty
|
||||
SociatyNoFound = 3000; //公会不存在
|
||||
SociatyAdded = 3001; //已在公会里
|
||||
SociatyDiamondNoEnough = 3002; //钻石不足
|
||||
SociatyNoMember = 3003; //不是公会成员
|
||||
SociatyNoRight = 3004; //无权限
|
||||
SociatyNoAdded = 3005; //未加入公会
|
||||
SociatyDismiss = 3006; //解散失败
|
||||
SociatyQuit = 3007; //退会失败
|
||||
SociatyAgree = 3008; //申请-同意失败
|
||||
SociatyRefuse = 3009; //申请-拒绝失败
|
||||
SociatyLogParams = 30010; //公会日志参数错误
|
||||
SociatyMasterNoDiss = 30011; //会长不能被踢出
|
||||
SociatySettingJob = 30012; //设置职位失败
|
||||
SociatySetting = 30013; //公会修改失败
|
||||
SociatyNoAccuse = 30014; //无需弹劾
|
||||
SociatySign = 30015; //签到失败
|
||||
SociatySigned = 30016; //已签到
|
||||
SociatyCDLimit = 30017; // CD时间限制
|
||||
SociatyApplyMax = 30018; //最大申请该公会人数
|
||||
SociatySelfSetting = 30019; // 不能设置自己
|
||||
SociatyMemberCountLimit = 30020; //超出人数限制
|
||||
SociatyRewardReceived = 30021; //奖励已领取
|
||||
SociatyRewardReceive = 30022; //奖励领取失败
|
||||
SociatyResource = 30023; //更新公会资源失败
|
||||
SociatyBelongTo = 30025; //已是公会成员
|
||||
SociatyApplied = 30026; //已申请
|
||||
SociatyAppyLvNoEnough = 30027; //申请等级不满足
|
||||
SociatyTaskValidation = 30028; //任务未完成
|
||||
SociatyActivityNoEnough = 30029; //活跃度不足
|
||||
SociatyAcitvityReceive = 30030; //活跃度领取失败
|
||||
SociatyDismissed = 30031; //公会已解散
|
||||
SociatyNameExist = 30032; //公会名存在
|
||||
SociatyQuitNoAllowed = 30033; //会长不允许退公会
|
||||
SociatyNoMaster = 30034; //无会长
|
||||
SociatyNoFormation = 30035; //无阵容
|
||||
SociatyTicketsNoEnough = 30036; //挑战券不足
|
||||
SociatySportsNoinit = 30037; //赛季未初始
|
||||
SociatySportsEnd = 30038; //赛季已结束
|
||||
SociatyTeamUnlock = 30039; //队伍解锁条件不满足
|
||||
SociatyTaskNoFound = 30040; //未找到boss任务
|
||||
SociatyTaskNoFinished = 30041; //任务未完成
|
||||
SociatyTaskReceived = 30042; //任务奖励已领取
|
||||
|
||||
// arena
|
||||
ArenaTicketBuyUp = 3101; //票据上限
|
||||
ArenaTicketNotEnough = 3102; //票据不足
|
||||
ArenaTicketNpcInCd = 3103; // cd中
|
||||
// talent
|
||||
TalentRepeatLearn = 3201; // 天赋已学习
|
||||
TalentErrData = 3202; /// 天赋不存在
|
||||
TalentUnLockerBefore = 3203; //先解锁前置天赋
|
||||
TalentResetState = 3204; //当前天赋已经是重置状态
|
||||
// trolltrain
|
||||
TrollBuyMax = 3301; //买入上限
|
||||
TrollSellMax = 3302; // 卖出上限
|
||||
TrollMaxSellCount = 3303; // 单日最大交易次数
|
||||
TrollMaxItemCount = 3304; //背包格子达到上限
|
||||
TrollRepeatedReward = 3305; //奖励重复领取
|
||||
// horoscope
|
||||
HoroscopeNotTurnedOn = 3401; //未开启
|
||||
HoroscopeRestCDNoEnd = 3402; //重置cd未结束
|
||||
// privileges
|
||||
PrivilegeNotFound = 3501; // 特权没激活
|
||||
PrivilegeRenewTime = 3502; // 特权续费时间没到
|
||||
VipLvError = 3503; // Vip等级不足
|
||||
VipGiftError = 3504; // Vip礼包购买失败
|
||||
VipBuyRepeat = 3505; // Vip礼包重复购买
|
||||
|
||||
// growtask
|
||||
GrowtaskReceive = 3601; //子任务奖励领取失败
|
||||
GrowtaskAdvReceive = 3602; //进阶奖励领取失败
|
||||
|
||||
// pay
|
||||
PayBuyNumNotEnough = 3701; //支付次数不足
|
||||
PayRenewTimeErr = 3702; // 续费时间没达到要求
|
||||
PayOrderCompleted = 3703; // 订单已完成
|
||||
// worldtask
|
||||
WorldtaskFinish = 3801; //任务完成失败
|
||||
WorldtaskLvNotEnough = 3802; //等级不满足
|
||||
WorldtaskNoAccept = 3803; //不能接取
|
||||
WorldtaskNoComplete = 3804; //任务条件未完成
|
||||
WorldtaskFinihed = 3805; //任务已完成
|
||||
WorldtaskLastUnFinished = 3806; //上个任务未完成
|
||||
WorldtaskGroupIdNosame = 3807; //组ID不一致
|
||||
|
||||
// academy
|
||||
AcademyTaskNoCompleteTask = 3901; //未完成任务
|
||||
// AutoBattle
|
||||
AutoBattleNoData = 4001; //没有正在自动战斗的数据
|
||||
AutoBattleStatesErr = 4002; // 自动战斗状态错误
|
||||
}
|
23
src/pb/proto/forum/forum_db.proto
Normal file
23
src/pb/proto/forum/forum_db.proto
Normal file
@ -0,0 +1,23 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
|
||||
enum CommentState {
|
||||
Release = 0; //发布
|
||||
Offline = 1; //下架
|
||||
}
|
||||
|
||||
//评论数据
|
||||
message DBComment {
|
||||
string id = 1; //@go_tags(`bson:"_id"`) ID
|
||||
string heroid = 2; //英雄id
|
||||
string heroobjid = 3; //目标英雄的实例id
|
||||
string uid = 4; //发送用户id
|
||||
string stage = 5; //区服id
|
||||
string avatar = 6; //用户头像
|
||||
string uname = 7; //用户名
|
||||
int32 ulv = 8;
|
||||
CommentState state = 9; //状态
|
||||
int64 ctime = 10; //发布时间
|
||||
string content = 11; //内容
|
||||
int32 starlist = 12; //点赞数
|
||||
}
|
53
src/pb/proto/forum/forum_msg.proto
Normal file
53
src/pb/proto/forum/forum_msg.proto
Normal file
@ -0,0 +1,53 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "forum/forum_db.proto";
|
||||
import "hero/hero_db.proto";
|
||||
import "equipment/equipment_db.proto";
|
||||
|
||||
//获取评论列表
|
||||
message ForumGetListReq {
|
||||
string herocid = 1; //英雄配置id
|
||||
}
|
||||
|
||||
//获取评论回应
|
||||
message ForumGetListResp { repeated DBComment comment = 1; }
|
||||
|
||||
//发布评论请求
|
||||
message ForumReleaseCommentReq {
|
||||
string avatar = 1; //用户头像
|
||||
string uname = 2; //用户名
|
||||
int32 ulv = 3; //用户等级
|
||||
string herocid = 4; //英雄的配置id
|
||||
string herooid = 5; //英雄的实例id
|
||||
string content = 6; //评论内容
|
||||
}
|
||||
|
||||
//发布评论回应
|
||||
message ForumReleaseCommentResp { DBComment comment = 1; }
|
||||
|
||||
//查看英雄信息请求
|
||||
message ForumWatchHeroReq {
|
||||
string uid = 1; //用户id
|
||||
string stag = 2; //区服id
|
||||
string herocId = 3; //用户cid
|
||||
string herooId = 4; //英雄实例id
|
||||
}
|
||||
//查看英雄信息回应
|
||||
message ForumWatchHeroResp {
|
||||
DBHero hero = 1;
|
||||
repeated DB_Equipment equipID = 2; // 装备详细信息
|
||||
}
|
||||
|
||||
//请求点赞 请求
|
||||
message ForumLikeReq {
|
||||
string herocid = 1; //英雄配置id
|
||||
string cid = 2; //评论id
|
||||
bool islike = 3; //是否点赞
|
||||
}
|
||||
|
||||
//请求点赞 回应
|
||||
message ForumLikeResp {
|
||||
string cid = 1; //评论id
|
||||
bool islike = 2; //是否点赞
|
||||
bool issucc = 3; //成功失败
|
||||
}
|
@ -1,22 +0,0 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
|
||||
enum CommentState {
|
||||
Release = 0; //发布
|
||||
Offline = 1; //下架
|
||||
}
|
||||
|
||||
//评论数据
|
||||
message DBComment {
|
||||
string id = 1; //@go_tags(`bson:"_id"`) ID
|
||||
string heroid = 2; //英雄id
|
||||
string heroobjid = 3; //目标英雄的实例id
|
||||
string uid = 4; //发送用户id
|
||||
string stage = 5; //区服id
|
||||
string avatar = 6; //用户头像
|
||||
string uname = 7; //用户名
|
||||
CommentState state = 8; //状态
|
||||
int64 ctime = 9; //发布时间
|
||||
string content = 10; //内容
|
||||
int32 starlist = 11; //点赞数
|
||||
}
|
@ -1,55 +0,0 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "forum_db.proto";
|
||||
import "hero_db.proto";
|
||||
|
||||
|
||||
//获取评论列表
|
||||
message ForumGetListReq {
|
||||
string herocid = 1; //英雄配置id
|
||||
}
|
||||
|
||||
//获取评论回应
|
||||
message ForumGetListResp {
|
||||
repeated DBComment comment = 1;
|
||||
}
|
||||
|
||||
//发布评论请求
|
||||
message ForumReleaseCommentReq {
|
||||
string avatar = 1; //用户头像
|
||||
string uname = 2; //用户名
|
||||
string herocid = 3; //英雄的配置id
|
||||
string herooid = 4; //英雄的实例id
|
||||
string content = 5; //评论内容
|
||||
}
|
||||
|
||||
//发布评论回应
|
||||
message ForumReleaseCommentResp {
|
||||
DBComment comment = 1;
|
||||
}
|
||||
|
||||
//查看英雄信息请求
|
||||
message ForumWatchHeroReq {
|
||||
string uid = 1; //用户id
|
||||
string stag = 2; //区服id
|
||||
string herocId = 3; //用户cid
|
||||
string herooId = 4; //英雄实例id
|
||||
}
|
||||
//查看英雄信息回应
|
||||
message ForumWatchHeroResp {
|
||||
DBHero hero = 1;
|
||||
}
|
||||
|
||||
//请求点赞 请求
|
||||
message ForumLikeReq {
|
||||
string herocid = 1; //英雄配置id
|
||||
string cid = 2; //评论id
|
||||
bool islike = 3; //是否点赞
|
||||
}
|
||||
|
||||
//请求点赞 回应
|
||||
message ForumLikeResp {
|
||||
string cid = 1; //评论id
|
||||
bool islike = 2; //是否点赞
|
||||
bool issucc = 3; //成功失败
|
||||
}
|
34
src/pb/proto/friend/friend_db.proto
Normal file
34
src/pb/proto/friend/friend_db.proto
Normal file
@ -0,0 +1,34 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "hero/hero_db.proto";
|
||||
|
||||
message DBFriend {
|
||||
string uid = 1; //@go_tags(`bson:"uid"`) 用户ID
|
||||
repeated string friendIds = 2; //@go_tags(`bson:"friendIds"`) 好友ID
|
||||
repeated string applyIds = 3; //@go_tags(`bson:"applyIds"`) 申请用户ID
|
||||
repeated string blackIds = 4; //@go_tags(`bson:"blackIds"`) 黑名单ID
|
||||
repeated string zanIds = 5; //@go_tags(`bson:"zanIds"`) 点赞好友ID
|
||||
repeated string getZandIds = 6; //@go_tags(`bson:"getZandIds"`) 已接收赞好友ID
|
||||
string assistHeroId = 7; //@go_tags(`bson:"assistHeroId"`) 助战英雄ID
|
||||
int32 received = 8; //@go_tags(`bson:"received"`) 领取奖励状态0未领1可领2已领
|
||||
int64 updateTime = 9; //@go_tags(`bson:"updateTime"`) 更新时间
|
||||
DBHero hero = 10; //@go_tags(`bson:"hero"`) 助战英雄副本
|
||||
int32 assistScore = 11; //@go_tags(`bson:"zhuzhanScore"`) 助战分数合计
|
||||
repeated AssistRecord record = 12; //@go_tags(`bson:"record"`) 助战记录
|
||||
}
|
||||
|
||||
//助战记录
|
||||
message AssistRecord {
|
||||
string uid = 1; //@go_tags(`bson:"uid"`) 好友Id
|
||||
int64 assistTime = 2; //@go_tags(`bson:"zhuzhanTime"`) 上次助战时间
|
||||
string assistHeroId = 3; //@go_tags(`bson:"assistHeroId"`) 助战英雄
|
||||
}
|
||||
|
||||
//切磋请求记录
|
||||
message QiecuoRecord{
|
||||
string uid = 1; //@go_tags(`bson:"uid"`) 切磋发起人
|
||||
string targetId = 2; //@go_tags(`bson:"targetId"`) 切磋接受人
|
||||
int32 status = 3; //@go_tags(`bson:"status"`) 0默认 1已发送 2已接收
|
||||
string matchId = 4; //@go_tags(`bson:"matchId"`) 战斗ID
|
||||
int64 timestamp = 5; //@go_tags(`bson:"timestamp"`) 切磋发起时间戳
|
||||
}
|
@ -1,6 +1,8 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
|
||||
import "friend/friend_db.proto";
|
||||
|
||||
message FriendBase {
|
||||
string userId = 1; // ID
|
||||
string NickName = 2; //昵称
|
||||
@ -8,11 +10,13 @@ message FriendBase {
|
||||
string avatar = 4; //头像
|
||||
int64 strength = 5; //战力
|
||||
string serverId = 6; //服务编号
|
||||
int64 offlineTime = 7; //最近一次下线时间 0在线
|
||||
int64 offlineTime = 7; //最近一次下线时间 -1在线
|
||||
bool isApplied = 8; //是否已申请加好友
|
||||
bool isZaned = 9; //是否已点赞
|
||||
bool isGetZaned = 10; //是否已获赞
|
||||
string heroObjId = 11; //助战英雄ID
|
||||
int32 score = 12; //助战分数
|
||||
int64 updateTime = 13; //更新时间
|
||||
}
|
||||
|
||||
//好友列表
|
||||
@ -68,7 +72,7 @@ message FriendSearchReq {
|
||||
string nickName = 1; //好友昵称
|
||||
}
|
||||
|
||||
message FriendSearchResp { FriendBase friend = 1; }
|
||||
message FriendSearchResp { repeated FriendBase friends = 1; }
|
||||
|
||||
//黑名单
|
||||
message FriendBlackListReq {}
|
||||
@ -123,10 +127,64 @@ message FriendAssistheroResp {
|
||||
//助战列表
|
||||
message FriendAssistlistReq {}
|
||||
message FriendAssistlistResp {
|
||||
repeated FriendBase list = 1;
|
||||
string heroObjId = 2;
|
||||
repeated FriendBase list = 1; //好友助战排行
|
||||
string heroObjId = 2; //助战英雄
|
||||
repeated AssistRecord record = 3; //我的助战记录
|
||||
}
|
||||
|
||||
// 助战奖励
|
||||
message FriendGetrewardReq {}
|
||||
message FriendGetrewardResp { int32 received = 1; }
|
||||
|
||||
// 助战英雄更新推送
|
||||
message FriendAssistHeroUpdatePush {
|
||||
FriendBase friend = 1; //好友
|
||||
}
|
||||
|
||||
//好友助战英雄列表
|
||||
message FriendAssistHeroListReq {}
|
||||
message FriendAssistHeroListResp { repeated FriendBase friends = 1; }
|
||||
|
||||
// 查询是否已申请目标玩家为好友或目标玩家是否已是好友
|
||||
message FriendGetRelationReq{
|
||||
string targetUid = 1; //目标玩家ID
|
||||
}
|
||||
|
||||
message FriendGetRelationResp{
|
||||
string targetUid = 1;
|
||||
bool status = 2; //已是好友或已申请返回true
|
||||
}
|
||||
|
||||
// 切磋请求
|
||||
message FriendQiecuoReq{
|
||||
string targetUid = 1; //切磋目标玩家UID
|
||||
}
|
||||
|
||||
message FriendQiecuoResp{
|
||||
string targetUid =1; //切磋目标
|
||||
string uid = 2; //发起者
|
||||
}
|
||||
|
||||
//接受切磋
|
||||
message FriendAcceptReq{
|
||||
string uid = 1; //切磋发起者
|
||||
}
|
||||
|
||||
message FriendAcceptResp{
|
||||
bool isSucc = 1;
|
||||
}
|
||||
|
||||
//拒绝切磋
|
||||
message FriendStopReq{
|
||||
string uid = 1; //切磋发起者
|
||||
}
|
||||
|
||||
message FriendStopResp{
|
||||
bool isSucc = 1;
|
||||
|
||||
}
|
||||
|
||||
message FriendQiecuonotifyPush{
|
||||
string uid = 1; //发起者(切磋)
|
||||
int32 notifyType = 2; //1发起通知 2接受通知 3拒绝通知
|
||||
}
|
@ -1,14 +0,0 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
|
||||
message DBFriend {
|
||||
string uid = 1; //@go_tags(`bson:"uid"`) 用户ID
|
||||
repeated string friendIds = 2; //@go_tags(`bson:"friendIds"`) 好友ID
|
||||
repeated string applyIds = 3; //@go_tags(`bson:"applyIds"`) 申请用户ID
|
||||
repeated string blackIds = 4; //@go_tags(`bson:"blackIds"`) 黑名单ID
|
||||
repeated string zanIds = 5; //@go_tags(`bson:"zanIds"`) 点赞好友ID
|
||||
repeated string getZandIds = 6; //@go_tags(`bson:"getZandIds"`) 已接收赞好友ID
|
||||
string assistHeroId = 7; //@go_tags(`bson:"assistHeroId"`) 助战英雄ID
|
||||
int32 received = 8; //@go_tags(`bson:"received"`) 领取奖励状态0未领1可领2已领
|
||||
int64 updateTime = 9; //@go_tags(`bson:"updateTime"`) 更新时间
|
||||
}
|
12
src/pb/proto/gateway/gateway_msg.proto
Normal file
12
src/pb/proto/gateway/gateway_msg.proto
Normal file
@ -0,0 +1,12 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
|
||||
//网关心跳 请求
|
||||
message GatewayHeartbeatReq {
|
||||
|
||||
}
|
||||
|
||||
//网关心跳 请求回应
|
||||
message GatewayHeartbeatResp {
|
||||
int64 timestamp = 1;
|
||||
}
|
@ -18,11 +18,12 @@ message OrderCook{
|
||||
message DBGourmet {
|
||||
string id = 1; //@go_tags(`bson:"_id"`) ID
|
||||
string uid = 2; //@go_tags(`bson:"uid"`) 用户ID
|
||||
Cooking cookingFood = 3; //@go_tags(`bson:"cooking"`) 正在烹饪的食品
|
||||
Cooking cookingFood = 3; //@go_tags(`bson:"cookingFood"`) 正在烹饪的食品
|
||||
repeated OrderCook foods = 4; //@go_tags(`bson:"foods"`) 等待烹饪的食品
|
||||
repeated UserAssets items = 5; //@go_tags(`bson:"items"`) 已经做好的食品
|
||||
map<int32,int32> skill = 6; //@go_tags(`bson:"skill"`) 技能ID
|
||||
map<int32,int32> specialSkill = 7; //@go_tags(`bson:"specialSkill"`) 通用技能
|
||||
int32 orderCostTime = 8; //@go_tags(`bson:"orderCostTime"`) 订单消耗的时常
|
||||
int64 ctime = 9; // 订单创建时间
|
||||
int32 totalTime = 10;//@go_tags(`bson:"totalTime"`)
|
||||
}
|
@ -1,7 +1,7 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "gourmet_db.proto";
|
||||
|
||||
import "gourmet/gourmet_db.proto";
|
||||
import "user/user_db.proto";
|
||||
// 查询塔进度
|
||||
message GourmetGetListReq {
|
||||
|
||||
@ -36,3 +36,11 @@ message GourmetSkillLvReq{
|
||||
message GourmetSkillLvResp{
|
||||
DBGourmet data = 1;
|
||||
}
|
||||
|
||||
message GourmetGetRandUserReq{
|
||||
int32 people = 1;//人数
|
||||
}
|
||||
|
||||
message GourmetGetRandUserResp{
|
||||
repeated DBUser user = 1;
|
||||
}
|
30
src/pb/proto/growtask/growtask_db.proto
Normal file
30
src/pb/proto/growtask/growtask_db.proto
Normal file
@ -0,0 +1,30 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
|
||||
message DBGrowtask {
|
||||
string uid = 1; //@go_tags(`bson:"uid"`) 用户ID
|
||||
repeated Growtask initTaskList =
|
||||
2; //@go_tags(`bson:"initTaskList"`) 初级任务列表
|
||||
repeated Growtask midTaskList =
|
||||
3; //@go_tags(`bson:"midTaskList"`) 中级任务列表
|
||||
repeated Growtask highTaskList =
|
||||
4; //@go_tags(`bson:"highTaskList"`) 高级任务列表
|
||||
int32 curTaskType = 5; //@go_tags(`bson:"curTaskType"`) 进行中的任务类型
|
||||
int32 advReceive = 6; //@go_tags(`bson:"advReceive"`) 已领取的进阶奖励ID
|
||||
}
|
||||
|
||||
//任务状态
|
||||
enum GrowtaskStatus {
|
||||
Lock = 0; //锁定
|
||||
Ongoing = 1; //进行中
|
||||
Wait = 2; //待领奖
|
||||
Finish = 3; //完成
|
||||
}
|
||||
|
||||
message Growtask {
|
||||
int32 id = 1; //@go_tags(`bson:"id"`) 配置ID
|
||||
int32 taskType = 2; //@go_tags(`bson:"taskType"`) 任务类型
|
||||
GrowtaskStatus status = 3; //@go_tags(`bson:"status"`) 任务状态
|
||||
int32 fstask = 4; //@go_tags(`bson:"fstask"`) 任务条件
|
||||
int32 preTask = 5; //@go_tags(`bson:"preTask"`) 前置任务ID
|
||||
}
|
27
src/pb/proto/growtask/growtask_msg.proto
Normal file
27
src/pb/proto/growtask/growtask_msg.proto
Normal file
@ -0,0 +1,27 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "growtask/growtask_db.proto";
|
||||
|
||||
// 成长任务列表
|
||||
message GrowtaskListReq {
|
||||
int32 taskType = 1; //任务类型1初级2中级3高级
|
||||
}
|
||||
message GrowtaskListResp {
|
||||
repeated Growtask taskList = 1;
|
||||
int32 curTaskType = 2; // 进行中的任务类型
|
||||
int32 advReceive = 3; //已领取的进阶奖励ID
|
||||
int32 curTaskId = 4; // 当前未完成的任务ID
|
||||
}
|
||||
|
||||
//子任务奖励领取
|
||||
message GrowtaskReceiveReq {
|
||||
int32 taskId = 1; //子任务ID
|
||||
}
|
||||
message GrowtaskReceiveResp { int32 taskId = 1; }
|
||||
|
||||
//进阶奖励领取
|
||||
message GrowtaskAdvReceiveReq {
|
||||
int32 taskType = 1; //任务类型
|
||||
}
|
||||
|
||||
message GrowtaskAdvReceiveResp { int32 taskType = 1; }
|
67
src/pb/proto/hero/hero_db.proto
Normal file
67
src/pb/proto/hero/hero_db.proto
Normal file
@ -0,0 +1,67 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "comm.proto";
|
||||
|
||||
enum HeroType {
|
||||
HeroTypeNil = 0;
|
||||
HeroTypeKongFu = 1;
|
||||
}
|
||||
|
||||
message DBHero {
|
||||
string id = 1; //@go_tags(`bson:"_id"`) ID
|
||||
string uid = 2;
|
||||
string heroID = 3; //@go_tags(`bson:"heroID"`) 英雄的配置表ID
|
||||
int32 star = 4; // 英雄星级
|
||||
int32 lv = 5; // 英雄等级
|
||||
int32 exp = 6; // 英雄经验
|
||||
int32 juexingLv = 7; //@go_tags(`bson:"juexingLv"`) 觉醒等级
|
||||
int32 captainSkill = 8; //@go_tags(`bson:"captainSkill"`) 队长技能
|
||||
repeated SkillData normalSkill = 9; //@go_tags(`bson:"normalSkill"`) 普通技能
|
||||
map<string, int32> property = 10; // 属性相关
|
||||
map<string, int32> addProperty = 11; //@go_tags(`bson:"addProperty"`) 附加属性相关
|
||||
int32 cardType = 12; //@go_tags(`bson:"cardType"`) 卡片类型(升星卡、经验卡、技能升级卡)
|
||||
int32 curSkin = 13; //@go_tags(`bson:"curSkin"`) 当前装备的皮肤ID
|
||||
repeated int32 skins = 14; // 所有皮肤ID
|
||||
bool block = 15; // 锁定
|
||||
repeated string equipID = 16; //@go_tags(`bson:"equipID"`) 装备 objID
|
||||
int32 sameCount = 20; // @go_tags(`bson:"sameCount"`) 卡片叠加数量
|
||||
int32 suiteId = 21; //@go_tags(`bson:"suiteId"`) 套装Id
|
||||
int32 suiteExtId = 22; // go_tags(`bson:"suiteExtId"`) 扩展套装Id
|
||||
|
||||
map<string, int32> juexProperty = 25; //@go_tags(`bson:"juexProperty"`) //hp
|
||||
HeroType status = 26; //@go_tags(`bson:"status"`) 状态 (1 练功)
|
||||
int32 suite1Star = 27; //@go_tags(`bson:"suite1Star"`)
|
||||
int32 suite2Star = 28; //@go_tags(`bson:"suite2Star"`)
|
||||
int32 suite1Lv = 29; //@go_tags(`bson:"suite1Lv"`)
|
||||
int32 suite2Lv = 30; //@go_tags(`bson:"suite2Lv"`)
|
||||
map<string, int32> talentProperty = 31; //@go_tags(`bson:"talentProperty"`) // 天赋属性
|
||||
repeated SkillData equipSkill = 32; //@go_tags(`bson:"equipSkill"`) 装备技能
|
||||
map<string, int32> horoscopeProperty = 33; //@go_tags(`bson:"horoscopeProperty"`) //星座属性加成
|
||||
}
|
||||
|
||||
|
||||
//英雄扩展数据
|
||||
message DBHeroRecord {
|
||||
string id = 1; //@go_tags(`bson:"_id"`) ID 主键id
|
||||
string uid = 2; //@go_tags(`bson:"uid"`) 用户ID
|
||||
int32 star4 = 3; // 4星保底
|
||||
int32 star5 = 4; // 5星保底
|
||||
int64 mtime = 5; // 修改时间
|
||||
int32 drawcount = 6; // 普通卡牌累计抽取次数
|
||||
map<string,int32> condition = 7; // key recharge、login 等 value 累计抽卡次数
|
||||
map<string,int32> star5Hero = 8;// 第totalcount 次抽到的5星英雄 key 英雄id
|
||||
int32 totalcount = 9;// 总的累计抽卡次数
|
||||
int32 daycount = 10; // 今天抽卡次数
|
||||
int32 onebuy = 11; // 单次购买次数
|
||||
int32 tenbuy = 12; // 十连购买次数
|
||||
int32 inevitable = 13;//第2-30次抽奖必出一个5星英雄
|
||||
int32 inevitable1 = 14;//第30-50次抽奖必出一个5星英雄
|
||||
}
|
||||
|
||||
// 英雄天赋系统
|
||||
message DBHeroTalent {
|
||||
string id = 1; //@go_tags(`bson:"_id"`) ID 主键id
|
||||
string uid = 2; //@go_tags(`bson:"uid"`) 用户ID
|
||||
string heroId = 3; // 英雄ID
|
||||
map<int32, int32> talent = 4; // 已经学习过的天赋
|
||||
}
|
@ -1,12 +1,17 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "hero_db.proto";
|
||||
import "hero/hero_db.proto";
|
||||
import "comm.proto";
|
||||
|
||||
//英雄基础信息
|
||||
message HeroInfoReq {
|
||||
string heroId = 1; //英雄唯一ID
|
||||
string uid = 1; // uid 查自己不传也可以
|
||||
repeated string heroId = 2; //英雄唯一ID
|
||||
}
|
||||
message HeroInfoResp {
|
||||
string uid = 1;
|
||||
repeated DBHero base = 2;
|
||||
}
|
||||
message HeroInfoResp { DBHero base = 1; }
|
||||
|
||||
//英雄列表
|
||||
message HeroListReq {}
|
||||
@ -17,11 +22,6 @@ message HeroListResp { repeated DBHero list = 1; }
|
||||
/// 卡牌养成: 共鸣(共鸣消耗、材料返回、能量点使用)
|
||||
/// 卡牌养成: 觉醒(英雄觉醒、材料消耗)
|
||||
|
||||
message ItemData {
|
||||
int32 itemId = 2; //物品Id
|
||||
int32 amount = 3; //数量
|
||||
}
|
||||
|
||||
message MapStringInt32 {
|
||||
string Key = 1;
|
||||
int32 Value = 2;
|
||||
@ -30,7 +30,7 @@ message MapStringInt32 {
|
||||
// 卡牌升级
|
||||
message HeroStrengthenUplvReq {
|
||||
string heroObjID = 1; // 英雄对象ID
|
||||
repeated MapStringInt32 expCards = 2;
|
||||
map<string,int32> item = 2;// key itemid value 数量
|
||||
}
|
||||
|
||||
// 卡牌升级返回
|
||||
@ -38,15 +38,9 @@ message HeroStrengthenUplvResp {
|
||||
DBHero hero = 1; // 英雄对象
|
||||
}
|
||||
|
||||
message CostCardData {
|
||||
string costCardObj = 1; // 对象ID
|
||||
int32 amount = 2; // 数量
|
||||
}
|
||||
// 卡牌升星
|
||||
message HeroStrengthenUpStarReq {
|
||||
string heroObjID = 1; // 英雄对象ID
|
||||
repeated CostCardData hero = 2; // 消耗卡牌对象ID
|
||||
repeated CostCardData heroRace = 3; // 消耗种族卡牌对象ID
|
||||
}
|
||||
|
||||
// 卡牌升星返回
|
||||
@ -57,7 +51,7 @@ message HeroStrengthenUpStarResp {
|
||||
// 卡牌技能升级
|
||||
message HeroStrengthenUpSkillReq {
|
||||
string heroObjID = 1; // 英雄对象ID
|
||||
repeated string costCardObj = 2; // 消耗技能升级卡
|
||||
repeated string item = 2;//
|
||||
}
|
||||
|
||||
// 卡牌技能升级返回
|
||||
@ -65,42 +59,6 @@ message HeroStrengthenUpSkillResp {
|
||||
DBHero hero = 1; // 英雄对象
|
||||
}
|
||||
|
||||
// 共鸣英雄
|
||||
message HeroResonanceReq {
|
||||
string heroObjID = 1; // 英雄对象ID
|
||||
repeated string costObjID = 2; // 消耗对象
|
||||
}
|
||||
|
||||
message HeroResonanceResp {
|
||||
DBHero hero = 1; // 英雄对象
|
||||
int32 energy = 2; // 共鸣成功 获得的能量点数
|
||||
DBHero upStarCard = 3; //共鸣成功 获得的升星卡
|
||||
}
|
||||
|
||||
// 重置共鸣属性
|
||||
message HeroResonanceResetReq {
|
||||
string heroObjID = 1; // 英雄对象ID
|
||||
}
|
||||
|
||||
message HeroResonanceResetResp {
|
||||
DBHero hero = 1; // 英雄对象
|
||||
int32 energy = 2; // 能量点数
|
||||
}
|
||||
|
||||
message EnergyData{
|
||||
int32 useEnergy = 1; // 使用的能量点数
|
||||
string useType = 2; // 使用的类型 (攻击、血量、防御)
|
||||
}
|
||||
// 使用能量点数
|
||||
message HeroResonanceUseEnergyReq {
|
||||
string heroObjID = 1; // 英雄对象ID
|
||||
repeated EnergyData energy = 2;
|
||||
}
|
||||
|
||||
message HeroResonanceUseEnergyResp {
|
||||
DBHero hero = 1; // 英雄对象
|
||||
}
|
||||
|
||||
// 觉醒
|
||||
message HeroAwakenReq {
|
||||
string heroObjID = 1; // 英雄对象ID
|
||||
@ -145,8 +103,11 @@ message HeroDrawCardReq {
|
||||
int32 drawCount = 2;// 抽卡次数
|
||||
}
|
||||
|
||||
message AtnoData{
|
||||
repeated UserAtno atno = 1;
|
||||
}
|
||||
message HeroDrawCardResp {
|
||||
repeated string heroes = 1; // 返回英雄的configID
|
||||
repeated AtnoData data = 1;
|
||||
}
|
||||
|
||||
// 英雄变化推送
|
||||
@ -160,5 +121,62 @@ message HeroDrawCardFloorReq {
|
||||
message HeroDrawCardFloorResp {
|
||||
int32 star4 = 1;
|
||||
int32 star5 = 2;
|
||||
int32 onebuy = 3; // 单次购买次数
|
||||
int32 tenbuy = 4; // 十连购买次数
|
||||
}
|
||||
|
||||
// 英雄融合
|
||||
message HeroFusionReq{
|
||||
string heroId = 1; // 英雄配置表id
|
||||
map<string,int32> heros= 2; // key heroObjID value 数量
|
||||
}
|
||||
|
||||
message HeroFusionResp{
|
||||
string heroid = 1; // 获得新英雄
|
||||
}
|
||||
|
||||
// 天赋学习
|
||||
message HeroTalentListReq {
|
||||
|
||||
}
|
||||
|
||||
message HeroTalentListResp {
|
||||
repeated DBHeroTalent telnet = 1;
|
||||
}
|
||||
|
||||
// 天赋学习
|
||||
message HeroTalentLearnReq {
|
||||
int32 talentID = 1; // 天赋ID
|
||||
string objId = 2; // 对象唯一id
|
||||
string heroid = 3; //配置表的英雄id
|
||||
}
|
||||
|
||||
message HeroTalentLearnResp {
|
||||
DBHeroTalent telnet = 1;
|
||||
int32 talentID = 2; // 刚学习的天赋ID
|
||||
}
|
||||
|
||||
// 重置天赋
|
||||
message HeroTalentResetReq {
|
||||
string objId = 1; // 对象唯一id
|
||||
}
|
||||
|
||||
message HeroTalentResetResp {
|
||||
DBHeroTalent telnet = 1;
|
||||
}
|
||||
|
||||
message HeroBuyReq{
|
||||
int32 buyType = 1; //类型
|
||||
int32 buyCount =2;// 购买的数量
|
||||
}
|
||||
|
||||
message HeroBuyResp{
|
||||
bool IsSucc = 1;
|
||||
int32 onebuy = 3; // 单次购买次数
|
||||
int32 tenbuy = 4; // 十连购买次数
|
||||
}
|
||||
|
||||
// 首次获得英雄
|
||||
message HeroFirstGetPush {
|
||||
repeated string heroId = 1; //英雄id
|
||||
}
|
@ -1,60 +0,0 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
|
||||
message SkillData {
|
||||
int32 skillID = 1;
|
||||
int32 skillLv = 2;
|
||||
}
|
||||
|
||||
enum HeroType {
|
||||
HeroTypeNil = 0;
|
||||
HeroTypeKongFu = 1;
|
||||
}
|
||||
|
||||
message DBHero {
|
||||
string id = 1; //@go_tags(`bson:"_id"`) ID
|
||||
string uid = 2;
|
||||
string heroID = 3; //@go_tags(`bson:"heroID"`) 英雄的配置表ID
|
||||
int32 star = 4; // 英雄星级
|
||||
int32 lv = 5; // 英雄等级
|
||||
int32 exp = 6; // 英雄经验
|
||||
int32 juexingLv = 7; //@go_tags(`bson:"juexingLv"`) 觉醒等级
|
||||
int32 captainSkill = 8; //@go_tags(`bson:"captainSkill"`) 队长技能
|
||||
repeated SkillData normalSkill = 9; //@go_tags(`bson:"normalSkill"`) 普通技能
|
||||
map<string, int32> property = 10; // 属性相关
|
||||
map<string, int32> addProperty = 11; //@go_tags(`bson:"addProperty"`) 附加属性相关
|
||||
int32 cardType = 12; //@go_tags(`bson:"cardType"`) 卡片类型(升星卡、经验卡、技能升级卡)
|
||||
int32 curSkin = 13; //@go_tags(`bson:"curSkin"`) 当前装备的皮肤ID
|
||||
repeated int32 skins = 14; // 所有皮肤ID
|
||||
bool block = 15; // 锁定
|
||||
repeated string equipID = 16; //@go_tags(`bson:"equipID"`) 装备 objID
|
||||
int32 resonateNum = 17; //@go_tags(`bson:"resonateNum"`) 共鸣次数
|
||||
int32 distributionResonate = 18; //@go_tags(`bson:"distributionResonate"`) 分配的共鸣能量
|
||||
map<string, int32> energy = 19; // @go_tags(`bson:"energy"`)能量分配到哪里[hppro:0,atkpro:0,defpro:20]
|
||||
int32 sameCount = 20; // @go_tags(`bson:"sameCount"`) 卡片叠加数量
|
||||
int32 suiteId = 21; //@go_tags(`bson:"suiteId"`) 套装Id
|
||||
int32 suiteExtId = 22; // go_tags(`bson:"suiteExtId"`) 扩展套装Id
|
||||
bool isOverlying = 23; // go_tags(`bson:"isOverlying"`) 是否允许叠加 默认true
|
||||
map<string, int32> energyProperty = 24; //@go_tags(`bson:"energyProperty"`)
|
||||
map<string, int32> juexProperty = 25; //@go_tags(`bson:"juexProperty"`) //hp
|
||||
HeroType status = 26; //@go_tags(`bson:"status"`) 状态 (1 练功)
|
||||
int32 suite1Star = 27; //@go_tags(`bson:"suite1Star"`)
|
||||
int32 suite2Star = 28; //@go_tags(`bson:"suite2Star"`)
|
||||
int32 suite1Lv = 29; //@go_tags(`bson:"suite1Lv"`)
|
||||
int32 suite2Lv = 30; //@go_tags(`bson:"suite2Lv"`)
|
||||
}
|
||||
|
||||
message Floor{ // 记录阵型保底数据
|
||||
int32 h4 = 1; // 4星次数
|
||||
int32 h5 = 2; // 5星次数
|
||||
}
|
||||
|
||||
//英雄扩展数据
|
||||
message DBHeroRecord {
|
||||
string id = 1; //@go_tags(`bson:"_id"`) ID 主键id
|
||||
string uid = 2; //@go_tags(`bson:"uid"`) 用户ID
|
||||
int32 star4 = 3; // 4星保底
|
||||
int32 star5 = 4; // 5星保底
|
||||
int64 mtime = 5; // 修改时间
|
||||
int32 drawcount = 6; // 普通卡牌累计抽取次数
|
||||
}
|
@ -1,6 +1,6 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "horoscope_db.proto";
|
||||
import "horoscope/horoscope_db.proto";
|
||||
|
||||
//获取用户星座图信息
|
||||
message HoroscopeInfoReq {}
|
||||
@ -21,4 +21,7 @@ message HoroscopeUpgradeResp {
|
||||
//重置请求
|
||||
message HoroscopeResetReq {}
|
||||
//重置请求 回应
|
||||
message HoroscopeResetResp { bool issucc = 1; }
|
||||
message HoroscopeResetResp {
|
||||
bool issucc = 1;
|
||||
DBHoroscope info = 2;
|
||||
}
|
27
src/pb/proto/hunting/hunting_db.proto
Normal file
27
src/pb/proto/hunting/hunting_db.proto
Normal file
@ -0,0 +1,27 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "battle/battle_msg.proto";
|
||||
|
||||
message DBHunting {
|
||||
string id = 1; //@go_tags(`bson:"_id"`) ID
|
||||
string uid = 2; //@go_tags(`bson:"uid"`) 用户ID
|
||||
map<int32,int32> boss = 3; // key boss 类型 value 难度
|
||||
int32 buyCount = 4;//@go_tags(`bson:"buyCount"`) 购买次数
|
||||
int64 cTime = 5; //@go_tags(`bson:"cTime"`) 修改时间
|
||||
map<string,int32> bossTime = 6; //@go_tags(`bson:"bossTime"`)
|
||||
int64 recoveryTime = 7; //@go_tags(`bson:"recoveryTime"`) // 开始恢复的时间
|
||||
}
|
||||
|
||||
// 狩猎排行榜
|
||||
message DBHuntingRank {
|
||||
string id = 1; //@go_tags(`bson:"_id"`) ID
|
||||
string uid = 2; //@go_tags(`bson:"uid"`) 用户ID
|
||||
int32 difficulty = 3; // 难度
|
||||
int32 bosstype = 4; // boss类型塔类型
|
||||
string nickname = 5;// 昵称
|
||||
string icon = 6; // 玩家头像
|
||||
int32 lv = 7; // 玩家等级
|
||||
int32 leadpos = 8; //队长位置
|
||||
repeated LineUp line = 9; // 阵容数据
|
||||
int32 costTime = 10; //@go_tags(`bson:"costTime"`) 闯关耗时 单位s
|
||||
}
|
@ -1,7 +1,7 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "hunting_db.proto";
|
||||
import "battle_msg.proto";
|
||||
import "hunting/hunting_db.proto";
|
||||
import "battle/battle_msg.proto";
|
||||
message HuntingGetListReq {
|
||||
|
||||
}
|
||||
@ -14,8 +14,7 @@ message HuntingGetListResp {
|
||||
message HuntingChallengeReq {
|
||||
int32 bossType = 1; // boos 类型
|
||||
int32 difficulty = 2; // 难度
|
||||
int32 leadpos = 3; //队长位置
|
||||
repeated string teamids = 4; //阵容信息
|
||||
BattleFormation battle = 3;
|
||||
}
|
||||
|
||||
message HuntingChallengeResp {
|
@ -1,25 +0,0 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
|
||||
|
||||
message DBHunting {
|
||||
string id = 1; //@go_tags(`bson:"_id"`) ID
|
||||
string uid = 2; //@go_tags(`bson:"uid"`) 用户ID
|
||||
int32 challengeCount = 3; //@go_tags(`bson:"challengeCount"`) 挑战次数
|
||||
map<int32,int32> boss = 4; // key boss 类型 value 难度
|
||||
int32 buyCount = 5;//@go_tags(`bson:"buyCount"`) 购买次数
|
||||
int64 cTime = 6; //@go_tags(`bson:"cTime"`) 修改时间
|
||||
map<string,int32> bossTime = 7; //@go_tags(`bson:"bossTime"`)
|
||||
}
|
||||
|
||||
// 狩猎排行榜
|
||||
message DBHuntingRank {
|
||||
string id = 1; //@go_tags(`bson:"_id"`) ID
|
||||
string uid = 2; //@go_tags(`bson:"uid"`) 用户ID
|
||||
int32 difficulty = 3; // 难度
|
||||
int32 bosstype = 4; // boss类型塔类型
|
||||
string nickname = 5;// 昵称
|
||||
string icon = 6; // 玩家头像
|
||||
int32 lv = 7; // 玩家等级
|
||||
int32 costTime = 8; //@go_tags(`bson:"costTime"`) 闯关耗时 单位s
|
||||
}
|
106
src/pb/proto/items/items_msg.proto
Normal file
106
src/pb/proto/items/items_msg.proto
Normal file
@ -0,0 +1,106 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "items/items_db.proto";
|
||||
import "comm.proto";
|
||||
|
||||
//查询用户背包请求
|
||||
message ItemsGetlistReq {
|
||||
int32 IType = 1; //道具类型
|
||||
}
|
||||
|
||||
//查询用户背包请求 回应
|
||||
message ItemsGetlistResp {
|
||||
repeated DB_UserItemData Grids = 1; //用户背包列表
|
||||
}
|
||||
|
||||
//背包变化推送
|
||||
message ItemsChangePush {
|
||||
repeated DB_UserItemData Grids = 1; //变化数据
|
||||
}
|
||||
|
||||
//使用物品请求
|
||||
message ItemsUseItemReq {
|
||||
string GridId = 1; //格子Id
|
||||
uint32 Amount = 2; //使用数量
|
||||
int32 Select = 3; //选择下标
|
||||
}
|
||||
|
||||
//使用物品请求 回应
|
||||
message ItemsUseItemResp {
|
||||
string GridId = 1; //格子Id
|
||||
uint32 Amount = 2; //使用数量
|
||||
bool issucc = 3; //是否成功
|
||||
}
|
||||
|
||||
//出售道具请求sailitem
|
||||
message ItemsSellItemReq {
|
||||
string GridId = 1; //格子Id
|
||||
string ItemId = 2; //物品Id
|
||||
uint32 Amount = 3; //使用数量
|
||||
}
|
||||
|
||||
//出售道具请求 回应
|
||||
message ItemsSellItemResp {
|
||||
string GridId = 1; //格子Id
|
||||
uint32 Amount = 2; //使用数量
|
||||
bool issucc = 3; //是否成功
|
||||
}
|
||||
|
||||
//分解道具 请求
|
||||
message ItemsDecomposeReq {
|
||||
string GridId = 1; //格子Id
|
||||
string ItemId = 2; //物品Id
|
||||
uint32 Amount = 3; //使用数量
|
||||
}
|
||||
|
||||
//分解道具 请求回应
|
||||
message ItemsDecomposeResp {
|
||||
string GridId = 1; //格子Id
|
||||
uint32 Amount = 2; //使用数量
|
||||
bool issucc = 3; //是否成功
|
||||
}
|
||||
|
||||
//购买体力
|
||||
message ItemsBuyPhysicalReq {
|
||||
uint32 Amount = 2; //购买数量
|
||||
}
|
||||
|
||||
//购买体力
|
||||
message ItemsBuyPhysicalResp {
|
||||
bool issucc = 1; //是否成功
|
||||
int32 PhysicalBuyNum = 2; //体力购买次数
|
||||
repeated UserAssets asets = 3 ; //获取资源
|
||||
}
|
||||
|
||||
//批量出售接口
|
||||
message ItemsSellinbulkReq {
|
||||
repeated string grids = 1; //格子Id
|
||||
repeated uint32 amount = 2; //出售数量
|
||||
}
|
||||
|
||||
//批量出售接口
|
||||
message ItemsSellinbulkResp {
|
||||
repeated string grids = 1; //格子Id
|
||||
repeated uint32 amount = 2; //出售数量
|
||||
repeated bool issucc = 3; //是否成功
|
||||
}
|
||||
|
||||
//购买统一入场门票请求
|
||||
message ItemsBuyUnifiedTicketReq {
|
||||
int32 BuyNum = 1;
|
||||
}
|
||||
//购买统一入场门票请求回应
|
||||
message ItemsBuyUnifiedTicketResp {
|
||||
bool issucc = 1;
|
||||
int32 buyunifiedticket = 2; //购买统一入场门票次数
|
||||
int64 recovertimeunifiedticket = 3;//同意门票恢复时间
|
||||
}
|
||||
|
||||
//刷新统一入场卷
|
||||
message ItemsRefreshUnifiedTicketReq {
|
||||
|
||||
}
|
||||
|
||||
message ItemsRefreshUnifiedTicketResp {
|
||||
|
||||
}
|
@ -1,46 +0,0 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "items_db.proto";
|
||||
|
||||
//查询用户背包请求
|
||||
message ItemsGetlistReq {
|
||||
int32 IType = 1; //道具类型
|
||||
}
|
||||
|
||||
//查询用户背包请求 回应
|
||||
message ItemsGetlistResp {
|
||||
repeated DB_UserItemData Grids = 1; //用户背包列表
|
||||
}
|
||||
|
||||
//背包变化推送
|
||||
message ItemsChangePush {
|
||||
repeated DB_UserItemData Grids = 1; //变化数据
|
||||
}
|
||||
|
||||
//使用物品请求
|
||||
message ItemsUseItemReq {
|
||||
string GridId = 1; //格子Id
|
||||
uint32 Amount = 2; //使用数量
|
||||
int32 Select = 3; //选择下标
|
||||
}
|
||||
|
||||
//使用物品请求 回应
|
||||
message ItemsUseItemResp {
|
||||
string GridId = 1; //格子Id
|
||||
uint32 Amount = 2; //使用数量
|
||||
bool issucc = 3; //是否成功
|
||||
}
|
||||
|
||||
//出售道具请求sailitem
|
||||
message ItemsSellItemReq {
|
||||
string GridId = 1; //格子Id
|
||||
string ItemId = 2; //物品Id
|
||||
uint32 Amount = 3; //使用数量
|
||||
}
|
||||
|
||||
//出售道具请求 回应
|
||||
message ItemsSellItemResp {
|
||||
string GridId = 1; //格子Id
|
||||
uint32 Amount = 2; //使用数量
|
||||
bool issucc = 3; //是否成功
|
||||
}
|
41
src/pb/proto/library/library_db.proto
Normal file
41
src/pb/proto/library/library_db.proto
Normal file
@ -0,0 +1,41 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
|
||||
message DBLibrary {
|
||||
string id = 1; //@go_tags(`bson:"_id"`) ID
|
||||
string uid = 2; //@go_tags(`bson:"uid"`) 用户ID
|
||||
int32 fid = 3; // 配置表id 羁绊id
|
||||
map<string, int32> hero = 4; // key: hid value: favorlv
|
||||
map<int32, int32> prize = 5; //是否领奖 key 好感度等级
|
||||
int32 fetterlv = 6; // 当前羁绊等级
|
||||
int32 storyid = 7; // 故事id 用来判断是否领奖
|
||||
bool activation = 8; // 是否激活
|
||||
}
|
||||
|
||||
// 羁绊英雄数据
|
||||
message DBHeroFetter {
|
||||
string id = 1; //@go_tags(`bson:"_id"`) ID
|
||||
string uid = 2; //@go_tags(`bson:"uid"`) 用户ID
|
||||
string heroid = 3; // 英雄配置表id
|
||||
repeated int32 history = 4; // 传记往事ID
|
||||
int32 favorlv = 5; // 好感度等级
|
||||
int32 favorexp = 6; // 好感度经验
|
||||
repeated int32 stroyprize = 7; // 剧情奖励
|
||||
repeated int32 lvprize = 8; // 等级奖励
|
||||
}
|
||||
|
||||
//羁绊剧情
|
||||
message DBFetterstory {
|
||||
string id = 1; //@go_tags(`bson:"_id"`) ID
|
||||
string uid = 2; //@go_tags(`bson:"uid"`) 用户ID
|
||||
map<int32, FetterTasks> feeterTask =
|
||||
3; //@go_tags(`bson:"feeterTask"`) 已开启的羁绊任务 key:羁绊ID
|
||||
}
|
||||
|
||||
message FetterTasks { repeated int32 tasks = 1; }
|
||||
|
||||
// 羁绊任务
|
||||
message FetterTask {
|
||||
int32 taskId = 1; //@go_tags(`bson:"taskId"`) 任务Id
|
||||
int32 status = 2; //@go_tags(`bson:"status"`) 状态 0锁定 1已完成
|
||||
}
|
63
src/pb/proto/library/library_msg.proto
Normal file
63
src/pb/proto/library/library_msg.proto
Normal file
@ -0,0 +1,63 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "library/library_db.proto";
|
||||
|
||||
// 获取羁绊信息
|
||||
message LibraryGetListReq {}
|
||||
|
||||
message LibraryGetListResp { repeated DBLibrary data = 1; }
|
||||
// 获取英雄详细羁绊数据
|
||||
message LibraryGetFetterListReq {}
|
||||
|
||||
message LibraryGetFetterListResp { repeated DBHeroFetter data = 1; }
|
||||
|
||||
// 领取奖励
|
||||
message LibraryGetRewardReq {
|
||||
string objId = 1;
|
||||
int32 fetterlv = 2; // 羁绊等级
|
||||
}
|
||||
|
||||
message LibraryGetRewardResp { DBLibrary data = 1; }
|
||||
// 领取剧情奖励
|
||||
message LibraryGetStoryRewardReq {
|
||||
string hid = 1; // 英雄ID
|
||||
int32 history = 2; // 传记往事id
|
||||
int32 rightend = 3; // 对应配置表 rightend
|
||||
}
|
||||
|
||||
message LibraryGetStoryRewardResp { DBHeroFetter data = 1; }
|
||||
|
||||
// 给英雄赠送礼物
|
||||
message LibraryUseGiftReq {
|
||||
string heroid = 1; // 英雄id
|
||||
map<string, int32> items = 2; // key 道具ID value 数量
|
||||
}
|
||||
|
||||
message LibraryUseGiftResp { DBHeroFetter data = 1; }
|
||||
|
||||
// 激活羁绊
|
||||
message LibraryActivationFetterReq {
|
||||
string oid = 1; //对象id
|
||||
}
|
||||
|
||||
message LibraryActivationFetterResp { DBLibrary data = 1; }
|
||||
|
||||
// 羁绊数据变化推送
|
||||
message LibraryChangePush {
|
||||
repeated DBLibrary data = 1;
|
||||
repeated DBHeroFetter fetter = 2; // 羁绊详细信息
|
||||
}
|
||||
|
||||
// 领取等级奖励
|
||||
message LibraryLvRewardReq {
|
||||
string oid = 1; // 对象唯一id
|
||||
int32 lv = 2; // 好感度等级
|
||||
}
|
||||
|
||||
message LibraryLvRewardResp { DBHeroFetter data = 1; }
|
||||
|
||||
// 羁绊剧情-我的主线任务
|
||||
message LibraryFetterstoryTaskReq {
|
||||
int32 fetterId = 1; //羁绊ID
|
||||
}
|
||||
message LibraryFetterstoryTaskResp { repeated FetterTask list = 1; }
|
@ -1,24 +0,0 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
|
||||
message DBLibrary {
|
||||
string id = 1; //@go_tags(`bson:"_id"`) ID
|
||||
string uid = 2; //@go_tags(`bson:"uid"`) 用户ID
|
||||
int32 fid = 3; // 配置表id 羁绊id
|
||||
map<string,int32> hero = 4; // key: hid value: favorlv
|
||||
map<int32,int32> prize = 5; //是否领奖 key 好感度等级
|
||||
int32 fetterlv = 6; // 当前羁绊等级
|
||||
int32 storyid = 7; // 故事id 用来判断是否领奖
|
||||
bool activation = 8; // 是否激活
|
||||
}
|
||||
|
||||
// 羁绊英雄数据
|
||||
message DBHeroFetter{
|
||||
string id = 1; //@go_tags(`bson:"_id"`) ID
|
||||
string uid = 2; //@go_tags(`bson:"uid"`) 用户ID
|
||||
string heroid = 3; // 英雄配置表id
|
||||
repeated int32 history = 4; // 传记往事ID
|
||||
int32 favorlv = 5; // 好感度等级
|
||||
int32 favorexp = 6; // 好感度经验
|
||||
int32 stroyprize = 7; // 剧情奖励
|
||||
}
|
@ -1,49 +0,0 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "library_db.proto";
|
||||
|
||||
// 获取羁绊信息
|
||||
message LibraryGetListReq {
|
||||
|
||||
}
|
||||
|
||||
message LibraryGetListResp {
|
||||
repeated DBLibrary data = 1;
|
||||
}
|
||||
// 获取英雄详细羁绊数据
|
||||
message LibraryGetFetterListReq {
|
||||
|
||||
}
|
||||
|
||||
message LibraryGetFetterListResp {
|
||||
repeated DBHeroFetter data = 1;
|
||||
}
|
||||
|
||||
// 领取奖励
|
||||
message LibraryGetRewardReq {
|
||||
string objId = 1;
|
||||
}
|
||||
|
||||
message LibraryGetRewardResp {
|
||||
DBLibrary data = 1;
|
||||
}
|
||||
// 领取剧情奖励
|
||||
message LibraryGetStoryRewardReq {
|
||||
string hid = 1; // 英雄ID
|
||||
int32 history = 2; // 传记往事id
|
||||
int32 rightend = 3; // 对应配置表 rightend
|
||||
}
|
||||
|
||||
message LibraryGetStoryRewardResp {
|
||||
DBLibrary data = 1;
|
||||
}
|
||||
|
||||
// 给英雄赠送礼物
|
||||
message LibraryUseGiftReq{
|
||||
string heroid = 1; // 英雄id
|
||||
map<string,int32> items = 2; // key 道具ID value 数量
|
||||
}
|
||||
|
||||
message LibraryUseGiftResp{
|
||||
DBHeroFetter data = 1;
|
||||
}
|
23
src/pb/proto/linestory/linestory_db.proto
Normal file
23
src/pb/proto/linestory/linestory_db.proto
Normal file
@ -0,0 +1,23 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
|
||||
message DBLinestory {
|
||||
string id = 1; //@go_tags(`bson:"_id"`) ID
|
||||
string uid = 2; //@go_tags(`bson:"uid"`) 用户ID
|
||||
map<int32, TaskChapter> taskChapter =
|
||||
3; //@go_tags(`bson:"taskChapter"`) 已开启的章节 key:章节ID
|
||||
}
|
||||
|
||||
// 章节
|
||||
message TaskChapter {
|
||||
int32 receive =
|
||||
1; //@go_tags(`bson:"receive"`) 章节奖励领取状态 0未领 1待领取 2已领取
|
||||
int32 status = 2; //@go_tags(`bson:"status"`) 完成状态 0未完成 1已完成
|
||||
repeated int32 taskIds = 3; //@go_tags(`bson:"taskIds"`) 完成的任务
|
||||
}
|
||||
|
||||
// 主线任务
|
||||
message TaskMain {
|
||||
int32 taskId = 1; //@go_tags(`bson:"taskId"`) 任务Id
|
||||
int32 status = 2; //@go_tags(`bson:"status"`) 状态 0锁定 1已完成
|
||||
}
|
22
src/pb/proto/linestory/linestory_msg.proto
Normal file
22
src/pb/proto/linestory/linestory_msg.proto
Normal file
@ -0,0 +1,22 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "linestory/linestory_db.proto";
|
||||
import "comm.proto";
|
||||
|
||||
// 支线剧情章节
|
||||
message LinestoryChapterReq {}
|
||||
|
||||
message LinestoryChapterResp { map<int32, TaskChapter> taskChapter = 1; }
|
||||
|
||||
// 支线剧情-我的主线任务
|
||||
message LinestoryMaintaskReq {
|
||||
int32 chapterId = 1; //章节ID
|
||||
}
|
||||
message LinestoryMaintaskResp { repeated TaskMain list = 1; }
|
||||
|
||||
// 章节奖励领取
|
||||
message LinestoryReceiveReq { int32 chapterId = 1; }
|
||||
message LinestoryReceiveResp {
|
||||
int32 chapterId = 1;
|
||||
repeated UserAssets userAssets = 2;
|
||||
}
|
@ -1,15 +0,0 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
|
||||
message TaskNode {
|
||||
int32 status = 1; //@go_tags(`bson:"status"`) 状态 0未做
|
||||
// 1进行中(子任务没有全部完成) 2已做 3禁止进入
|
||||
repeated int32 subtaskIds = 2; //@go_tags(`bson:"subtasks"`) 子任务
|
||||
}
|
||||
|
||||
message DBLinestory {
|
||||
string id = 1; //@go_tags(`bson:"_id"`) ID
|
||||
string uid = 2; //@go_tags(`bson:"uid"`) 用户ID
|
||||
int32 jqId = 3; //@go_tags(`bson:"jqId"`) 剧情ID
|
||||
map<int32, TaskNode> tasks = 4; //@go_tags(`bson:"tasks"`) 任务
|
||||
}
|
@ -1,23 +0,0 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
|
||||
// 剧情开始
|
||||
message LinestoryStartReq {
|
||||
int32 jqId = 1; //剧情ID
|
||||
}
|
||||
message LinestoryStartResp {
|
||||
int32 jqId = 1;
|
||||
repeated int32 taskIds = 2; //已完成的任务ID
|
||||
}
|
||||
|
||||
// 做任务
|
||||
message LinestoryDotaskReq {
|
||||
int32 taskId = 1; //任务ID
|
||||
int32 subtaskId = 2; //子任务ID
|
||||
}
|
||||
|
||||
message LinestoryDotaskResp {
|
||||
int32 taskId = 1; //任务ID
|
||||
int32 subtaskId = 2; //子任务ID
|
||||
int32 resetTaskId = 3; //重置任务起始ID
|
||||
}
|
61
src/pb/proto/mail/mail_msg.proto
Normal file
61
src/pb/proto/mail/mail_msg.proto
Normal file
@ -0,0 +1,61 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "mail/mail_db.proto";
|
||||
import "comm.proto";
|
||||
|
||||
message MailGetListReq {
|
||||
|
||||
}
|
||||
|
||||
// 查询邮件信息
|
||||
message MailGetListResp {
|
||||
repeated DBMailData Mails = 1;
|
||||
}
|
||||
|
||||
// 查看邮件
|
||||
message MailReadMailReq {
|
||||
string ObjID = 1;
|
||||
}
|
||||
|
||||
message MailReadMailResp {
|
||||
DBMailData Mail = 1;
|
||||
}
|
||||
|
||||
// 领取附件
|
||||
message MailGetUserMailAttachmentReq {
|
||||
string ObjID = 1;
|
||||
}
|
||||
|
||||
message MailGetUserMailAttachmentResp {
|
||||
DBMailData Mail = 1;
|
||||
}
|
||||
|
||||
// 删除某个邮件
|
||||
message MailDelMailReq {
|
||||
string ObjID = 1;
|
||||
}
|
||||
|
||||
message MailDelMailResp {
|
||||
string ObjID = 1; // 返回删除邮件id
|
||||
}
|
||||
|
||||
// 推送邮件
|
||||
message MailGetNewMailPush{
|
||||
DBMailData Mail = 1; // 推送新的邮件信息
|
||||
}
|
||||
// 领取所有附件
|
||||
message MailGetAllMailAttachmentReq {
|
||||
|
||||
}
|
||||
|
||||
message MailGetAllMailAttachmentResp {
|
||||
repeated UserAssets res = 1; //资源类型
|
||||
repeated string ids = 2; // 已经领取的邮件唯一id
|
||||
}
|
||||
message MailDelAllMailReq {
|
||||
|
||||
}
|
||||
|
||||
message MailDelAllMailResp {
|
||||
repeated DBMailData Mails = 1;
|
||||
}
|
@ -1,38 +0,0 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "mail_db.proto";
|
||||
import "comm.proto";
|
||||
|
||||
message MailGetListReq {}
|
||||
|
||||
// 查询邮件信息
|
||||
message MailGetListResp { repeated DBMailData Mails = 1; }
|
||||
|
||||
// 查看邮件
|
||||
message MailReadMailReq { string ObjID = 1; }
|
||||
|
||||
message MailReadMailResp { DBMailData Mail = 1; }
|
||||
|
||||
// 领取附件
|
||||
message MailGetUserMailAttachmentReq { string ObjID = 1; }
|
||||
|
||||
message MailGetUserMailAttachmentResp { DBMailData Mail = 1; }
|
||||
|
||||
// 删除某个邮件
|
||||
message MailDelMailReq { string ObjID = 1; }
|
||||
|
||||
message MailDelMailResp {
|
||||
string ObjID = 1; // 返回删除邮件id
|
||||
}
|
||||
|
||||
// 推送邮件
|
||||
message MailGetNewMailPush {
|
||||
DBMailData Mail = 1; // 推送新的邮件信息
|
||||
}
|
||||
// 领取所有附件
|
||||
message MailGetAllMailAttachmentReq {}
|
||||
|
||||
message MailGetAllMailAttachmentResp {
|
||||
repeated UserAssets res = 1; //资源类型
|
||||
repeated string ids = 2; // 已经领取的邮件唯一id
|
||||
}
|
@ -14,4 +14,5 @@ message DBMainline {
|
||||
AwaredType awaredID = 5; //@go_tags(`bson:"awaredID"`) 是否领奖(设置int是考虑后续扩展有多个宝箱情况)
|
||||
repeated int32 branchID = 6; // @go_tags(`bson:"branchID"`) 记录所有通关的关卡数据
|
||||
int32 intensity = 7; // 难度
|
||||
int32 ps = 8;// 预扣的体力
|
||||
}
|
@ -1,7 +1,7 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "mainline_db.proto";
|
||||
import "battle_msg.proto";
|
||||
import "mainline/mainline_db.proto";
|
||||
import "battle/battle_msg.proto";
|
||||
// 查询关卡进度
|
||||
message MainlineGetListReq {
|
||||
|
||||
@ -43,6 +43,8 @@ message MainlineChallengeOverReq {
|
||||
|
||||
message MainlineChallengeOverResp {
|
||||
DBMainline data = 1; //当前章节信息
|
||||
repeated string newheros = 2; //获得的新英雄
|
||||
int32 olv = 3; //以前的等级
|
||||
}
|
||||
|
||||
// 推送新章节
|
@ -1,6 +1,6 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "martialhall_db.proto";
|
||||
import "martialhall/martialhall_db.proto";
|
||||
|
||||
///信息请求
|
||||
message MartialhallInfoReq {}
|
||||
@ -21,7 +21,9 @@ message MartialhallPracticeResp {
|
||||
///领取 请求
|
||||
message MartialhallReceiveReq { int32 pillar = 1; }
|
||||
///领取 回应
|
||||
message MartialhallReceiveResp {}
|
||||
message MartialhallReceiveResp {
|
||||
int32 pillar = 1;
|
||||
}
|
||||
|
||||
///升级 请求
|
||||
message MartialhallUpgradeReq {}
|
13
src/pb/proto/mline/mline_db.proto
Normal file
13
src/pb/proto/mline/mline_db.proto
Normal file
@ -0,0 +1,13 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
|
||||
message DBMline {
|
||||
string id = 1; //@go_tags(`bson:"_id"`) ID
|
||||
string uid = 2; //@go_tags(`bson:"uid"`) 用户ID
|
||||
int32 cType = 3; //@go_tags(`bson:"cType"`) 章节类型
|
||||
int32 chapterId = 4; //@go_tags(`bson:"chapterId"`) 章节ID
|
||||
int32 stageId = 5; //@go_tags(`bson:"stageId"`) 主线关卡ID
|
||||
map<int32,int32> star = 6;// 关卡对应的星级 (key 关卡ID value 星数)
|
||||
map<int32,bool> award = 7; //@go_tags(`bson:"award"`) (key 配置表星级)
|
||||
map<int32,int32> ps = 8;// 预扣的体力
|
||||
}
|
58
src/pb/proto/mline/mline_msg.proto
Normal file
58
src/pb/proto/mline/mline_msg.proto
Normal file
@ -0,0 +1,58 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "mline/mline_db.proto";
|
||||
import "battle/battle_msg.proto";
|
||||
import "comm.proto";
|
||||
|
||||
// 查询关卡进度
|
||||
message MlineGetListReq {
|
||||
int32 cType = 1; // 章节类型
|
||||
}
|
||||
|
||||
// 返回进度信息
|
||||
message MlineGetListResp {
|
||||
repeated DBMline data = 1;
|
||||
}
|
||||
|
||||
// 领取关卡宝箱
|
||||
message MlineGetRewardReq {
|
||||
int32 cId = 1; // 章节配置表唯一ID
|
||||
int32 star = 2; // 星级奖励
|
||||
}
|
||||
|
||||
message MlineGetRewardResp {
|
||||
DBMline data = 1; //当前章节信息
|
||||
repeated UserAssets reward = 2; // 奖励
|
||||
}
|
||||
|
||||
// 挑战关卡
|
||||
message MlineChallengeReq {
|
||||
int32 stageId = 1; // 小关ID
|
||||
BattleFormation battle = 2;
|
||||
}
|
||||
|
||||
message MlineChallengeResp {
|
||||
BattleInfo info = 1;
|
||||
int32 stageId = 2; // 小关ID
|
||||
}
|
||||
|
||||
// 客户端通知服务器打赢了
|
||||
message MlineChallengeOverReq {
|
||||
int32 stageId = 1; // 小关ID
|
||||
BattleReport report = 3; //战报
|
||||
}
|
||||
|
||||
message MlineChallengeOverResp {
|
||||
DBMline data = 1; //当前章节信息
|
||||
repeated UserAssets reward = 2; // 奖励
|
||||
}
|
||||
|
||||
// 扫荡关卡
|
||||
message MlineCleanStageReq {
|
||||
int32 stageId = 1; // 小关ID
|
||||
}
|
||||
|
||||
message MlineCleanStageResp {
|
||||
int32 stageId = 1; // 小关ID
|
||||
repeated UserAssets reward = 2; // 奖励
|
||||
}
|
@ -17,16 +17,23 @@ message DBMoonFantasy {
|
||||
repeated UserInfo join = 5; //参与人数
|
||||
int32 numup = 6; //人数上限
|
||||
int32 unitmup = 7; //单人可挑战次数
|
||||
map<string, int32> record = 8; //挑战记录
|
||||
int64 expir = 8; //过期时间
|
||||
map<string, int32> record = 9; //挑战记录
|
||||
}
|
||||
|
||||
//用户参与的月之秘境列表
|
||||
message DBUserMFantasy {
|
||||
string id = 1; //@go_tags(`bson:"_id"`) ID
|
||||
string uid = 2; //用户id
|
||||
repeated string mfantasys = 3; //月之秘境列表
|
||||
int32 triggerNum = 4; //@go_tags(`bson:"triggerNum"`) 月之秘境触发次数
|
||||
int32 battleNum = 5; //@go_tags(`bson:"battleNum"`) 月之秘境挑战次数
|
||||
int32 buyNum = 6; //@go_tags(`bson:"buyNum"`) 月之秘境挑战次数
|
||||
int64 lastTrigger = 7; //@go_tags(`bson:"lastTrigger"`) 月之秘境最后触发时间
|
||||
int32 triggerNum = 3; //@go_tags(`bson:"triggerNum"`) 月之秘境触发次数
|
||||
// int32 ticket = 4; //@go_tags(`bson:"ticket"`)挑战券
|
||||
int32 buyNum = 5; //@go_tags(`bson:"buyNum"`) 月之秘境挑战次数
|
||||
int64 lastTrigger = 6; //@go_tags(`bson:"lastTrigger"`) 月之秘境最后触发时间
|
||||
int64 lastrtickettime = 7;//@go_tags(`bson:"lastrtickettime"`) 最后回复劵时间
|
||||
}
|
||||
|
||||
//RPC 触发请求
|
||||
message RPCTargetMFReq {
|
||||
string uid = 1; //用户id
|
||||
string boosid = 2; //怪物id
|
||||
}
|
@ -1,8 +1,8 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "errorcode.proto";
|
||||
import "moonfantasy_db.proto";
|
||||
import "battle_msg.proto";
|
||||
import "moonfantasy/moonfantasy_db.proto";
|
||||
import "battle/battle_msg.proto";
|
||||
|
||||
//获取秘境列表请求
|
||||
message MoonfantasyGetListReq {}
|
||||
@ -33,8 +33,7 @@ message MoonfantasyAskResp {
|
||||
///挑战秘境
|
||||
message MoonfantasyBattleReq {
|
||||
string mid = 1; //唯一id
|
||||
int32 leadpos = 2; //队长位置
|
||||
repeated string teamids = 3; //阵容信息
|
||||
BattleFormation battle = 2; //战斗类型
|
||||
}
|
||||
|
||||
message MoonfantasyBattleResp {
|
@ -1,7 +1,7 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "errorcode.proto";
|
||||
import "notify_db.proto";
|
||||
import "notify/notify_db.proto";
|
||||
import "google/protobuf/any.proto";
|
||||
|
||||
//统一错误码推送
|
@ -1,23 +1,18 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "battle_msg.proto";
|
||||
//普通塔
|
||||
import "battle/battle_msg.proto";
|
||||
|
||||
message DBPagoda {
|
||||
string id = 1; //@go_tags(`bson:"_id"`) ID
|
||||
string uid = 2; //@go_tags(`bson:"uid"`) 用户ID
|
||||
int32 pagodaId = 3; //@go_tags(`bson:"pagodaId"`) 塔层
|
||||
map<int32,bool> reward = 4; // 是否领奖
|
||||
int32 type = 5;
|
||||
bool complete = 6; // 是否通关
|
||||
int32 passCheckID = 7; // 战令领奖ID
|
||||
int32 vipPassCheckID = 8; // vip战令领奖ID
|
||||
}
|
||||
|
||||
// 赛季塔 赛季结束会清理
|
||||
message DBSeasonPagoda {
|
||||
string id = 1; //@go_tags(`bson:"_id"`) ID
|
||||
string uid = 2; //@go_tags(`bson:"uid"`) 用户ID
|
||||
int32 pagodaId = 3; //@go_tags(`bson:"pagodaId"`) 塔层
|
||||
map<int32,bool> reward = 4; // 是否领奖
|
||||
int32 type = 5;
|
||||
}
|
||||
|
||||
// 爬塔数据明细
|
||||
message DBPagodaRecord {
|
@ -1,7 +1,8 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "pagoda_db.proto";
|
||||
import "battle_msg.proto";
|
||||
import "pagoda/pagoda_db.proto";
|
||||
import "battle/battle_msg.proto";
|
||||
import "comm.proto";
|
||||
// 查询塔进度
|
||||
message PagodaGetListReq {
|
||||
|
||||
@ -23,9 +24,7 @@ message PagodaGetRewardResp {
|
||||
message PagodaChallengeReq {
|
||||
int32 levelID = 1; // 挑战层数
|
||||
int32 PagodaType = 2; // 塔类型
|
||||
|
||||
int32 leadpos = 3; //队长位置
|
||||
repeated string teamids = 4; //阵容信息
|
||||
BattleFormation battle = 3;
|
||||
}
|
||||
|
||||
message PagodaChallengeResp {
|
||||
@ -63,3 +62,21 @@ message PagodaQueryRecordReq{
|
||||
message PagodaQueryRecordResp{
|
||||
DBPagodaRecord data = 1;
|
||||
}
|
||||
|
||||
// 激活赛季塔
|
||||
message PagodaActivateReq{
|
||||
|
||||
}
|
||||
|
||||
message PagodaActivateResp{
|
||||
DBPagoda data = 1;
|
||||
}
|
||||
// 领取战令奖励
|
||||
message PagodaWarOrderReq{
|
||||
|
||||
}
|
||||
|
||||
message PagodaWarOrderResp{
|
||||
DBPagoda data = 1;
|
||||
repeated UserAssets itmes = 2;// 获得的奖励
|
||||
}
|
@ -9,7 +9,7 @@ message DBPayOrder {
|
||||
int64 ctime = 4;
|
||||
}
|
||||
|
||||
//用户每日礼包
|
||||
//
|
||||
message DBUserPay {
|
||||
string uid = 1; //用户id
|
||||
map<string, int32> record = 2; //商品购买次数
|
47
src/pb/proto/pay/pay_msg.proto
Normal file
47
src/pb/proto/pay/pay_msg.proto
Normal file
@ -0,0 +1,47 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "pay/pay_db.proto";
|
||||
import "comm.proto";
|
||||
import "errorcode.proto";
|
||||
|
||||
//充值记录
|
||||
message PayRecordReq {
|
||||
|
||||
}
|
||||
//充值记录
|
||||
message PayRecordResp{
|
||||
DBUserPay info = 1;
|
||||
}
|
||||
|
||||
|
||||
//用户重置信息获取
|
||||
message PayInfoReq {}
|
||||
message PayInfoResp { DBPayDaily info = 1; }
|
||||
|
||||
//购买每日礼包
|
||||
message PayDailyBuyReq { int32 id = 1; }
|
||||
message PayDailyBuyResp { bool isucc = 1; repeated UserAssets items = 2;}
|
||||
|
||||
|
||||
//充值完成推送
|
||||
message PayShippedPush {
|
||||
string pid = 1;
|
||||
string orderid = 2;
|
||||
repeated UserAssets items = 3;
|
||||
DBUserPay info = 4;
|
||||
}
|
||||
|
||||
///支付系统发货请求
|
||||
message PayDeliveryReq {
|
||||
string uid = 1;
|
||||
string orderid = 2;
|
||||
string productid = 3;
|
||||
int32 price = 4;
|
||||
int32 amount = 5;
|
||||
}
|
||||
///支付系统发货请求 回应
|
||||
message PayDeliveryResp {
|
||||
ErrorCode code = 1; //@go_tags(`json:"s""`) 头像
|
||||
string msg = 2;
|
||||
string data = 3;
|
||||
}
|
@ -1,24 +0,0 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "pay_db.proto";
|
||||
import "errorcode.proto";
|
||||
|
||||
//用户重置信息获取
|
||||
message PayInfoReq {}
|
||||
message PayInfoResp { DBPayDaily info = 1; }
|
||||
|
||||
//购买每日礼包
|
||||
message PayDailyBuyReq { int32 id = 1; }
|
||||
message PayDailyBuyResp { bool isucc = 1; }
|
||||
|
||||
///支付系统发货请求
|
||||
message PayDeliveryReq {
|
||||
string uid = 1;
|
||||
string orderid = 2;
|
||||
string productid = 3;
|
||||
}
|
||||
///支付系统发货请求 回应
|
||||
message PayDeliveryResp {
|
||||
ErrorCode code = 1;
|
||||
string msg = 2;
|
||||
}
|
24
src/pb/proto/privilege/privilege_db.proto
Normal file
24
src/pb/proto/privilege/privilege_db.proto
Normal file
@ -0,0 +1,24 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
// vip 月卡特权
|
||||
message DBPrivilege {
|
||||
string id = 1; //@go_tags(`bson:"_id"`) ID
|
||||
string uid = 2; //@go_tags(`bson:"uid"`) 用户ID
|
||||
string cId = 3; //@go_tags(`bson:"cId"`) 计费点数ID
|
||||
int64 cTime = 4; //@go_tags(`bson:"cTime"`) //购买时间
|
||||
int64 eTime = 5; //@go_tags(`bson:"eTime"`) //到期时间
|
||||
int64 rewardTime = 6; //@go_tags(`bson:"rewardTime"`) 每日奖励时间
|
||||
}
|
||||
|
||||
message PrivilegeList{
|
||||
repeated int32 privilegeID = 1; //@go_tags(`bson:"privilegeID"`) 特权ID
|
||||
}
|
||||
|
||||
message DBVip {
|
||||
string id = 1; //@go_tags(`bson:"_id"`) ID
|
||||
string uid = 2; //@go_tags(`bson:"uid"`) 用户ID
|
||||
map<int32,bool> reward= 3; // key vip 等级
|
||||
map<int32,PrivilegeList> privilege = 4;//@go_tags(`bson:"privilege"`) 特权ID
|
||||
int64 cTime = 5; //@go_tags(`bson:"cTime"`) //购买时间
|
||||
int64 rewardTime = 6; //@go_tags(`bson:"rewardTime"`) 每日奖励时间
|
||||
}
|
38
src/pb/proto/privilege/privilege_msg.proto
Normal file
38
src/pb/proto/privilege/privilege_msg.proto
Normal file
@ -0,0 +1,38 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "privilege/privilege_db.proto";
|
||||
// 查询特权列表
|
||||
message PrivilegeGetListReq {
|
||||
|
||||
}
|
||||
// 返回特权列表数据
|
||||
message PrivilegeGetListResp {
|
||||
repeated DBPrivilege data = 1;
|
||||
}
|
||||
|
||||
// 购买月卡
|
||||
message PrivilegeBuyYuekaReq {
|
||||
string cID = 1;
|
||||
|
||||
}
|
||||
|
||||
message PrivilegeBuyYuekaResp {
|
||||
repeated DBPrivilege data = 1;
|
||||
}
|
||||
|
||||
message PrivilegeBuyGiftReq {
|
||||
int32 vipLv = 1; // vip 等级
|
||||
|
||||
}
|
||||
|
||||
message PrivilegeBuyGiftResp {
|
||||
DBVip data = 1;
|
||||
}
|
||||
|
||||
message PrivilegeVipListReq {
|
||||
|
||||
}
|
||||
|
||||
message PrivilegeVipListResp {
|
||||
DBVip data = 1;
|
||||
}
|
BIN
src/pb/proto/protoc.exe
Normal file
BIN
src/pb/proto/protoc.exe
Normal file
Binary file not shown.
31
src/pb/proto/pvp/pvp_db.proto
Normal file
31
src/pb/proto/pvp/pvp_db.proto
Normal file
@ -0,0 +1,31 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
|
||||
//Pvp类型
|
||||
enum PvpType{
|
||||
friends = 0; //好友切磋
|
||||
}
|
||||
|
||||
enum PvpState {
|
||||
void = 0; //无效状态
|
||||
ready = 1; //准备中
|
||||
battle = 2; //战斗中
|
||||
cancel = 3; //战斗取消
|
||||
finish = 4; //战斗结束
|
||||
}
|
||||
|
||||
message PvpUserInfo {
|
||||
string uid = 1;
|
||||
string name = 2;
|
||||
string avatar = 3;
|
||||
int32 lv = 4;
|
||||
}
|
||||
|
||||
message DBPvpBattle {
|
||||
string id = 1; //战斗id
|
||||
string servicePath = 2; //战斗区服地址
|
||||
PvpType ptype = 3; //pvp类型
|
||||
PvpState state = 4; //战斗状态
|
||||
PvpUserInfo red = 5; //红方id
|
||||
PvpUserInfo blue = 6; //红方id
|
||||
}
|
81
src/pb/proto/pvp/pvp_msg.proto
Normal file
81
src/pb/proto/pvp/pvp_msg.proto
Normal file
@ -0,0 +1,81 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "pvp/pvp_db.proto";
|
||||
import "battle/battle_msg.proto";
|
||||
import "errorcode.proto";
|
||||
|
||||
|
||||
|
||||
//战斗列表 请求
|
||||
message PvpListReq {
|
||||
|
||||
}
|
||||
//战斗列表 请求回应
|
||||
message PvpListResp {
|
||||
repeated DBPvpBattle list = 1;
|
||||
}
|
||||
|
||||
//战斗列表推送
|
||||
message PvpIntoReq {
|
||||
string battleid = 1; //战斗id
|
||||
}
|
||||
|
||||
//战斗列表推送
|
||||
message PvpIntoResp {
|
||||
ErrorCode code = 1; //是否成功
|
||||
string battleid = 2; //战斗id
|
||||
BattleStateInfo info=3; //战斗状态数据
|
||||
}
|
||||
|
||||
|
||||
//Pvp 战斗准备推送
|
||||
message PvpReadyPush {
|
||||
string servicePath = 1; //战斗区服地址
|
||||
string battleid = 2; //战斗id
|
||||
PvpUserInfo red = 3; //红方用户信息
|
||||
PvpUserInfo blue = 4; //蓝方用户信息
|
||||
int32 countdown = 5; //布阵倒计时
|
||||
}
|
||||
|
||||
//Pvp 战斗准备推送
|
||||
message PvpCancelPush {
|
||||
string servicePath = 1; //战斗区服地址
|
||||
string battleid = 2; //战斗id
|
||||
}
|
||||
|
||||
|
||||
//布阵 请求
|
||||
message PvpFormationReq {
|
||||
string battleid = 1; //战斗id
|
||||
BattleFormation formation = 2; //阵型
|
||||
}
|
||||
|
||||
//布阵 请求 回应
|
||||
message PvpFormationResp {
|
||||
bool issucc = 1;
|
||||
}
|
||||
|
||||
//战斗开始推送
|
||||
message PvpStartPush{
|
||||
ErrorCode code = 1; //是否成功
|
||||
BattleInfo info = 2;
|
||||
}
|
||||
|
||||
//实时Pvp 指令推送
|
||||
message PvpOutCmdPush {
|
||||
string battleid = 1;
|
||||
repeated BattleCmd cmd = 2;
|
||||
}
|
||||
|
||||
//pvp 输入指令请求
|
||||
message PvpInCmdReq {
|
||||
string battleid = 1;
|
||||
BattleCmd cmd =2;
|
||||
}
|
||||
|
||||
//pvp 输入指令请求 回应
|
||||
message PvpInCmdResp {
|
||||
ErrorCode code = 1; //是否成功
|
||||
string battleid = 2;
|
||||
BattleCmd cmd = 3;
|
||||
}
|
16
src/pb/proto/rtask/rtask_msg.proto
Normal file
16
src/pb/proto/rtask/rtask_msg.proto
Normal file
@ -0,0 +1,16 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
|
||||
// 测试使用
|
||||
message RtaskTestReq {
|
||||
int32 rtaskType = 1; //任务类型
|
||||
repeated int32 params = 2; //参数
|
||||
int32 condiId = 3; //条件ID
|
||||
int32 groupId = 4; //分组编号
|
||||
string rtaskIds = 5; //已完成的任务ids
|
||||
}
|
||||
|
||||
message RtaskTestResp {
|
||||
bool flag = 1;
|
||||
repeated int32 rtaskIds = 2;
|
||||
}
|
@ -1,26 +0,0 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
|
||||
message frtaskIds { repeated int32 rtaskIds = 1; }
|
||||
|
||||
// 玩家任务状态
|
||||
message DBRtask {
|
||||
string id = 1; //@go_tags(`bson:"_id"`) ID
|
||||
string uid = 2; //@go_tags(`bson:"uid"`) 用户ID
|
||||
map<int32, frtaskIds> frtaskIds =
|
||||
3; //@go_tags(`bson:"frtaskIds"`) 已完成的任务Id
|
||||
int32 nextRtaskId = 4; //@go_tags(`bson:"nextRtaskId"`) 下个任务Id
|
||||
bool isReward = 5; //@go_tags(`bson:"isReward"`) 接收奖励
|
||||
}
|
||||
|
||||
message rtaskData {
|
||||
map<int32, int32> data = 1; //@go_tags(`bson:"data"`) 当前任务值
|
||||
int32 rtype = 2; //@go_tags(`bson:"rtype"`) 任务类型
|
||||
int64 timestamp = 3; //@go_tasg(`bson:"timestamp"`) 时间戳
|
||||
}
|
||||
// 玩家任务记录
|
||||
message DBRtaskRecord {
|
||||
string id = 1; //@go_tags(`bson:"_id"`) ID
|
||||
string uid = 2; //@go_tags(`bson:"uid"`) 用户ID
|
||||
map<int32, rtaskData> vals = 3; //@go_tags(`bson:"vals"`) 任务记录值
|
||||
}
|
@ -1,96 +0,0 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
|
||||
import "battle_msg.proto";
|
||||
import "rtask_db.proto";
|
||||
|
||||
// 申请做任务
|
||||
message RtaskApplyReq {
|
||||
int32 rtaskId = 1; //任务ID
|
||||
int32 rtaskSubId = 2; //支线任务ID
|
||||
}
|
||||
|
||||
message RtaskApplyResp { int32 rtaskId = 1; }
|
||||
|
||||
// 任务列表
|
||||
message RtasklistReq {
|
||||
int32 groupId = 1; //分组ID
|
||||
}
|
||||
message RtasklistResp {
|
||||
repeated int32 rtaskIds = 1;
|
||||
int32 groupId = 2;
|
||||
}
|
||||
|
||||
// 对话选项
|
||||
message RtaskChooseReq {
|
||||
int32 rtaskId = 1; //任务ID
|
||||
int32 chooseId = 2; //选项配置ID
|
||||
int32 rtaskSubId = 3; //支线任务ID
|
||||
}
|
||||
|
||||
message RtaskChooseResp {
|
||||
int32 rtaskId = 1; //任务ID
|
||||
int32 chooseId = 2; //选项配置ID
|
||||
int32 rtaskSubId = 3; //支线任务ID
|
||||
}
|
||||
|
||||
// 任务完成推送
|
||||
message RtaskFinishPush { int32 rtaskId = 1; }
|
||||
|
||||
// 当前完成的任务列表推送
|
||||
message RtaskFinishIdsPush {
|
||||
repeated int32 rtaskId = 1;
|
||||
int32 groupId = 2;
|
||||
}
|
||||
|
||||
// 领奖
|
||||
message RtaskGetRewardReq {
|
||||
int32 rtaskId = 1;
|
||||
int32 rtaskSubId = 2; //支线任务ID
|
||||
}
|
||||
message RtaskGetRewardResp {
|
||||
int32 rtaskId = 1;
|
||||
int32 rtaskSubId = 2; //支线任务ID
|
||||
}
|
||||
|
||||
// 开始战斗
|
||||
message RtaskBattleStartReq {
|
||||
int32 battleConfId = 1; //战斗配表ID
|
||||
int32 leadpos = 3; //队长位置
|
||||
repeated string teamids = 4; //阵容信息
|
||||
}
|
||||
|
||||
message RtaskBattleStartResp {
|
||||
BattleInfo info = 1; //战斗信息
|
||||
}
|
||||
|
||||
// 战斗完成
|
||||
message RtaskBattleFinishReq {
|
||||
int32 rtaskId = 1; //任务ID
|
||||
int32 rtaskSubId = 2; //支线任务ID
|
||||
int32 chooseId = 3; //选项配置ID
|
||||
}
|
||||
|
||||
message RtaskBattleFinishResp {
|
||||
int32 rtaskId = 1; //任务ID
|
||||
int32 rtaskSubId = 2; //支线任务ID
|
||||
}
|
||||
|
||||
//获取玩家任务记录
|
||||
message RtaskGetrecordReq {}
|
||||
|
||||
message RtaskGetrecordResp { DBRtaskRecord record = 1; }
|
||||
|
||||
// 测试使用
|
||||
message RtaskTestReq {
|
||||
int32 rtaskType = 1; //任务类型
|
||||
repeated int32 params = 2; //参数
|
||||
int32 condiId = 3; //条件ID
|
||||
int32 groupId = 4; //分组编号
|
||||
string rtaskIds = 5; //已完成的任务ids
|
||||
}
|
||||
|
||||
message RtaskTestResp {
|
||||
bool flag = 1;
|
||||
repeated int32 rtaskIds = 2;
|
||||
}
|
12
src/pb/proto/serverdata.proto
Normal file
12
src/pb/proto/serverdata.proto
Normal file
@ -0,0 +1,12 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
|
||||
//服务器数据
|
||||
message DBServerData {
|
||||
string id = 1; //主键id
|
||||
int32 serverState = 2;//@go_tags(`bson:"serverState"`) 服务器状态
|
||||
int32 disposableLoop = 3; //@go_tags(`bson:"disposableLoop"`) 一次性调用的塔数据索引 //
|
||||
int32 fixedLoop = 4; //@go_tags(`bson:"fixedLoop"`) 赛季塔循环调用索引
|
||||
int32 seasonType = 5;//@go_tags(`bson:"seasonType"`) 赛季塔类型
|
||||
int64 openTime = 6; //@go_tags(`bson:"openTime"`) 开服时间
|
||||
}
|
@ -1,5 +1,6 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "equipment/equipment_db.proto";
|
||||
|
||||
enum ShopType {
|
||||
Null = 0;
|
||||
@ -15,16 +16,19 @@ message UserShopData {
|
||||
int32 ManualRefreshNum = 2; //手动刷新次数
|
||||
repeated int32 Items = 3; //商品列表
|
||||
map<int32, int32> buy = 4; //购买记录
|
||||
map<int32, DB_Equipment> preview = 5; //预览数据
|
||||
}
|
||||
|
||||
message DBShop {
|
||||
string id = 1; //@go_tags(`bson:"_id"`) 装备id
|
||||
string uid = 2; //@go_tags(`bson:"uid"`) 装备id
|
||||
UserShopData goldShop = 3; //@go_tags(`bson:"goldShop"`) 金币商店数据
|
||||
UserShopData diamondShop = 4; //@go_tags(`bson:"diamondShop"`) 金币商店数据
|
||||
UserShopData pvpShop = 5; //@go_tags(`bson:"pvpShop"`) 金币商店数据
|
||||
UserShopData pveShop = 6; //@go_tags(`bson:"pveShop"`) 金币商店数据
|
||||
UserShopData allianceShop = 7; //@go_tags(`bson:"allianceShop"`) 金币商店数据
|
||||
int32 refreshnumgoldShop = 3; //@go_tags(`bson:"refresholdShop"`) 刷新金币商店次数
|
||||
int64 refreshtimegoldShop = 4; //@go_tags(`bson:"refresholdShop"`) 刷新金币商店的时间
|
||||
UserShopData goldShop = 5; //@go_tags(`bson:"goldShop"`) 金币商店数据
|
||||
UserShopData diamondShop = 6; //@go_tags(`bson:"diamondShop"`) 金币商店数据
|
||||
UserShopData pvpShop = 7; //@go_tags(`bson:"pvpShop"`) 金币商店数据
|
||||
UserShopData pveShop = 8; //@go_tags(`bson:"pveShop"`) 金币商店数据
|
||||
UserShopData allianceShop = 9; //@go_tags(`bson:"allianceShop"`) 金币商店数据
|
||||
}
|
||||
|
||||
// message DBShopItem {
|
41
src/pb/proto/shop/shop_msg.proto
Normal file
41
src/pb/proto/shop/shop_msg.proto
Normal file
@ -0,0 +1,41 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "shop/shop_db.proto";
|
||||
import "comm.proto";
|
||||
import "equipment/equipment_db.proto";
|
||||
|
||||
//商品对象数据
|
||||
message ShopItem {
|
||||
int32 GoodsId = 1; //商品Id
|
||||
repeated UserAssets Items = 2; //货物
|
||||
repeated UserAssets Consume = 3; //消耗
|
||||
int32 Sale = 4; //打折
|
||||
int32 LeftBuyNum = 5; //还可购买次数
|
||||
DB_Equipment preview = 6; //装备预览数据
|
||||
}
|
||||
|
||||
//获取装备列表请求
|
||||
message ShopGetListReq {
|
||||
ShopType sType = 1; //商城类型
|
||||
bool IsManualRefresh = 2; //是否手动刷新
|
||||
}
|
||||
|
||||
//获取装备列表请求
|
||||
message ShopGetListResp {
|
||||
ShopType sType = 1; //商城类型
|
||||
bool IsManualRefresh = 2; //是否手动刷新
|
||||
repeated ShopItem Goods = 4; //商品列表
|
||||
int32 SurplusRefreshNum = 5; //剩余手动刷新次数
|
||||
}
|
||||
|
||||
//购买商品 请求
|
||||
message ShopBuyReq {
|
||||
ShopType ShopType = 1; //商店类型
|
||||
int32 GoodsId = 2; //商品Id
|
||||
int32 BuyNum = 3; //商品购买数量
|
||||
}
|
||||
|
||||
//购买商品 回应
|
||||
message ShopBuyResp {
|
||||
bool IsSucc = 1; //是否成功
|
||||
}
|
@ -1,40 +0,0 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "shop_db.proto";
|
||||
import "comm.proto";
|
||||
|
||||
|
||||
//商品对象数据
|
||||
message ShopItem {
|
||||
int32 GoodsId = 1; //商品Id
|
||||
repeated UserAssets Items = 2; //货物
|
||||
repeated UserAssets Consume = 3; //消耗
|
||||
int32 Sale = 4; //打折
|
||||
int32 LeftBuyNum = 5; //还可购买次数
|
||||
}
|
||||
|
||||
//获取装备列表请求
|
||||
message ShopGetListReq {
|
||||
ShopType sType = 1; //商城类型
|
||||
bool IsManualRefresh = 2; //是否手动刷新
|
||||
}
|
||||
|
||||
//获取装备列表请求
|
||||
message ShopGetListResp {
|
||||
ShopType sType = 1; //商城类型
|
||||
bool IsManualRefresh = 2; //是否手动刷新
|
||||
repeated ShopItem Goods = 4; //商品列表
|
||||
int32 SurplusRefreshNum = 5; //剩余手动刷新次数
|
||||
}
|
||||
|
||||
//购买商品 请求
|
||||
message ShopBuyReq {
|
||||
ShopType ShopType = 1; //商店类型
|
||||
int32 GoodsId = 2; //商品Id
|
||||
int32 BuyNum = 3; //商品购买数量
|
||||
}
|
||||
|
||||
//购买商品 回应
|
||||
message ShopBuyResp {
|
||||
bool IsSucc = 1; //是否成功
|
||||
}
|
69
src/pb/proto/smithy/smithy_db.proto
Normal file
69
src/pb/proto/smithy/smithy_db.proto
Normal file
@ -0,0 +1,69 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "comm.proto";
|
||||
|
||||
// 炉子信息
|
||||
message DBStove{
|
||||
string id = 1; //@go_tags(`bson:"_id"`) ID
|
||||
string uid = 2; //@go_tags(`bson:"uid"`) 用户ID
|
||||
int32 lv = 3; // 炉子等级
|
||||
map<int32,int32> data = 4; // key 套装类型 value 熟练度
|
||||
map<int32,int32> skill = 5; // 台子技能
|
||||
map<int32,int32> forge = 6; // key 套装类型 value 打造次数
|
||||
int32 temperature = 7;// 炉子温度
|
||||
int64 recoveTime = 8; // 恢复满时间
|
||||
int32 business = 9; //
|
||||
}
|
||||
|
||||
// 商人信息
|
||||
message DBBusiness{
|
||||
map<int32,int32> shop = 1;
|
||||
}
|
||||
|
||||
message DBBusinessData{
|
||||
string id = 1; //@go_tags(`bson:"_id"`) ID
|
||||
string uid = 2; //@go_tags(`bson:"uid"`) 用户ID
|
||||
repeated DBBusiness data = 3;
|
||||
int32 count = 4; // 刷新次数
|
||||
int64 refreshTime = 5;//@go_tags(`bson:"refreshTime"`) 刷新开始时间
|
||||
}
|
||||
|
||||
// 装备图鉴
|
||||
message DBTujian{
|
||||
string id = 1; //@go_tags(`bson:"_id"`) ID
|
||||
string uid = 2; //@go_tags(`bson:"uid"`) 用户ID
|
||||
map<int32,ForgeData> tujian = 3; // 图鉴信息
|
||||
int32 slider = 4; // 进度
|
||||
}
|
||||
message ForgeData{
|
||||
int32 forgeCount = 1; // 打造次数
|
||||
int32 lv = 2;
|
||||
int32 quality = 3;
|
||||
}
|
||||
|
||||
////////
|
||||
message Clang{
|
||||
int32 deskType = 1; // 台子类型
|
||||
int64 eTime = 2;
|
||||
int64 sTime = 3; // 订单开始时间
|
||||
}
|
||||
|
||||
message OrderClang{
|
||||
int32 deskType = 1; // 台子类型
|
||||
int32 count = 2; // 料理数量
|
||||
int32 needTime = 3; // 需要的时间
|
||||
}
|
||||
message DBSmithy {
|
||||
string id = 1; //@go_tags(`bson:"_id"`) ID
|
||||
string uid = 2; //@go_tags(`bson:"uid"`) 用户ID
|
||||
Clang clang = 3;// 正在制作中的数据
|
||||
repeated OrderClang orders = 4; //@go_tags(`bson:"orders"`) 订单数据
|
||||
repeated UserAssets items = 5; //@go_tags(`bson:"items"`) 已经做好装备
|
||||
map<int32,int32> skill = 6;//@go_tags(`bson:"skill"`) 锻造台等级
|
||||
int32 stoveLv = 7; //@go_tags(`bson:"stoveLv"`) 炉子等级
|
||||
int32 orderCostTime = 8; //@go_tags(`bson:"orderCostTime"`) 订单消耗的时常
|
||||
int64 ctime = 9; // 订单创建时间
|
||||
map<int32,int32> deskFloor = 10;//@go_tags(`bson:"deskFloor"`)台子保底
|
||||
int32 stoveFloor = 11;//@go_tags(`bson:"stoveFloor"`) 炉子保底
|
||||
int32 totalTime = 12;//@go_tags(`bson:"totalTime"`)
|
||||
}
|
136
src/pb/proto/smithy/smithy_msg.proto
Normal file
136
src/pb/proto/smithy/smithy_msg.proto
Normal file
@ -0,0 +1,136 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "smithy/smithy_db.proto";
|
||||
import "user/user_db.proto";
|
||||
|
||||
|
||||
// 铁匠铺 获取炉子信息
|
||||
message SmithyGetStoveInfoReq {
|
||||
|
||||
}
|
||||
|
||||
message SmithyGetStoveInfoResp {
|
||||
DBStove data = 1;
|
||||
}
|
||||
|
||||
|
||||
// 打造装备
|
||||
message SmithyForgeEquipReq{
|
||||
int32 equipType = 1; // 装备类型
|
||||
int32 lava = 2;// 添加熔岩
|
||||
int32 quality = 3;// 精益制造
|
||||
}
|
||||
|
||||
message SmithyForgeEquipResp{
|
||||
int32 equip = 1; // 装备ID
|
||||
DBStove data = 2;
|
||||
}
|
||||
// 定制装备
|
||||
message SmithyOrderEquipReq{
|
||||
int32 suiteId = 1;// 套装ID
|
||||
int32 position = 2; // 装备位置
|
||||
int32 lava = 3;// 添加熔岩
|
||||
int32 quality = 4;// 精益制造
|
||||
}
|
||||
|
||||
message SmithyOrderEquipResp{
|
||||
int32 equip = 1; // 装备ID
|
||||
DBStove data = 2;
|
||||
}
|
||||
|
||||
|
||||
// 炉子升级
|
||||
message SmithyStoveUpReq{
|
||||
|
||||
}
|
||||
message SmithyStoveUpResp{
|
||||
DBStove data = 1;
|
||||
}
|
||||
|
||||
// 炉子升温
|
||||
message SmithyRiseReq{
|
||||
string itemId = 1; // 材料ID
|
||||
int32 count = 2;// 材料数量
|
||||
}
|
||||
|
||||
message SmithyRiseResp{
|
||||
DBStove data = 1;
|
||||
}
|
||||
|
||||
// 工具学习 升级 共用
|
||||
message SmithyToolsUpReq{
|
||||
int32 id = 1; // 工具配置ID
|
||||
}
|
||||
|
||||
message SmithyToolsUpResp{
|
||||
DBStove data = 1;
|
||||
}
|
||||
// 刷新商人
|
||||
message SmithyRefreshShopReq{
|
||||
|
||||
}
|
||||
message SmithyRefreshShopResp{
|
||||
DBBusiness data = 1;
|
||||
}
|
||||
|
||||
// 出售装备
|
||||
message SmithySellItemReq{
|
||||
int32 id = 1; // 装备ID
|
||||
int32 count = 2; // 数量
|
||||
}
|
||||
|
||||
message SmithySellItemResp{
|
||||
DBBusiness data = 1;
|
||||
}
|
||||
|
||||
//////////////////////////////////////////
|
||||
// 创建订单
|
||||
message SmithyCreateOrderReq {
|
||||
repeated OrderClang order = 1;// 烹饪时间不用传 后端会重新计算
|
||||
}
|
||||
|
||||
message SmithyCreateOrderResp {
|
||||
DBSmithy data = 1;
|
||||
}
|
||||
|
||||
// 领取奖励
|
||||
message SmithyGetRewardReq{
|
||||
}
|
||||
|
||||
message SmithyGetRewardResp{
|
||||
DBSmithy data = 1;
|
||||
}
|
||||
|
||||
// 技能升级
|
||||
message SmithyDeskSkillLvReq{
|
||||
int32 deskType = 1; // 台子类型
|
||||
}
|
||||
|
||||
message SmithyDeskSkillLvResp{
|
||||
DBSmithy data = 1;
|
||||
}
|
||||
|
||||
// 炉子技能升级
|
||||
message SmithyStoveSkillLvReq{
|
||||
|
||||
}
|
||||
|
||||
message SmithyStoveSkillLvResp{
|
||||
DBSmithy data = 1;
|
||||
}
|
||||
|
||||
message SmithyGetRandUserReq{
|
||||
int32 people = 1;//人数
|
||||
}
|
||||
|
||||
message SmithyGetRandUserResp{
|
||||
repeated DBUser user = 1;
|
||||
}
|
||||
|
||||
message SmithyGetListReq {
|
||||
|
||||
}
|
||||
// 返回进度信息
|
||||
message SmithyGetListResp {
|
||||
DBSmithy data = 1;
|
||||
}
|
@ -1,31 +0,0 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "comm.proto";
|
||||
|
||||
|
||||
message Clang{
|
||||
int32 deskType = 1; // 台子类型
|
||||
int64 eTime = 2;
|
||||
int64 sTime = 3; // 订单开始时间
|
||||
|
||||
}
|
||||
|
||||
// 队列里的烹饪食品
|
||||
message OrderClang{
|
||||
int32 deskType = 1; // 台子类型
|
||||
int32 count = 2; // 料理数量
|
||||
int32 needTime = 3; // 需要的时间
|
||||
}
|
||||
message DBSmithy {
|
||||
string id = 1; //@go_tags(`bson:"_id"`) ID
|
||||
string uid = 2; //@go_tags(`bson:"uid"`) 用户ID
|
||||
Clang clang = 3;// 正在制作中的数据
|
||||
repeated OrderClang orders = 4; //@go_tags(`bson:"orders"`) 订单数据
|
||||
repeated UserAssets items = 5; //@go_tags(`bson:"items"`) 已经做好装备
|
||||
map<int32,int32> skill = 6;//@go_tags(`bson:"skill"`) 锻造台等级
|
||||
int32 stoveLv = 7; //@go_tags(`bson:"stoveLv"`) 炉子等级
|
||||
int32 orderCostTime = 8; //@go_tags(`bson:"orderCostTime"`) 订单消耗的时常
|
||||
int64 ctime = 9; // 订单创建时间
|
||||
map<int32,int32> deskFloor = 10;//@go_tags(`bson:"deskFloor"`)台子保底
|
||||
int32 stoveFloor = 11;//@go_tags(`bson:"stoveFloor"`) 炉子保底
|
||||
}
|
@ -1,55 +0,0 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "smithy_db.proto";
|
||||
|
||||
// 查询塔进度
|
||||
message SmithyGetListReq {
|
||||
|
||||
}
|
||||
// 返回进度信息
|
||||
message SmithyGetListResp {
|
||||
DBSmithy data = 1;
|
||||
}
|
||||
|
||||
// 创建订单
|
||||
message SmithyCreateOrderReq {
|
||||
repeated OrderClang order = 1;// 烹饪时间不用传 后端会重新计算
|
||||
}
|
||||
|
||||
message SmithyCreateOrderResp {
|
||||
DBSmithy data = 1;
|
||||
}
|
||||
|
||||
// 领取奖励
|
||||
message SmithyGetRewardReq{
|
||||
}
|
||||
|
||||
message SmithyGetRewardResp{
|
||||
DBSmithy data = 1;
|
||||
}
|
||||
|
||||
// 技能升级
|
||||
message SmithyDeskSkillLvReq{
|
||||
int32 deskType = 1; // 台子类型
|
||||
}
|
||||
|
||||
message SmithyDeskSkillLvResp{
|
||||
DBSmithy data = 1;
|
||||
}
|
||||
|
||||
// 炉子技能升级
|
||||
message SmithyStoveSkillLvReq{
|
||||
|
||||
}
|
||||
|
||||
message SmithyStoveSkillLvResp{
|
||||
DBSmithy data = 1;
|
||||
}
|
||||
|
||||
message SmithyGetRandUserReq{
|
||||
|
||||
}
|
||||
|
||||
message SmithyGetRandUserResp{
|
||||
repeated string user = 1;
|
||||
}
|
133
src/pb/proto/sociaty/sociaty_db.proto
Normal file
133
src/pb/proto/sociaty/sociaty_db.proto
Normal file
@ -0,0 +1,133 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "battle/battle_msg.proto";
|
||||
|
||||
message DBSociaty {
|
||||
string id = 1; //@go_tags(`bson:"_id"`) ID
|
||||
string creater = 2; //@go_tags(`bson:"creater"`) 创建人
|
||||
string name = 3; //@go_tags(`bson:"name"`) 公会名称
|
||||
string icon = 4; //@go_tags(`bson:"icon"`) 公会图标
|
||||
string notice = 5; //@go_tags(`bson:"notice"`) 公告
|
||||
int32 exp = 6; //@go_tags(`bson:"exp"`) 经验
|
||||
int32 lv = 7; //@go_tags(`bson:"lv"`) 等级
|
||||
bool isApplyCheck = 8; //@go_tags(`bson:"isApplyCheck"`) 是否必须审批
|
||||
int32 applyLv = 9; //@go_tags(`bson:"applyLv"`) 等级限制
|
||||
int64 ctime = 10; //@go_tags(`bson:"ctime"`) 创建时间
|
||||
repeated ApplyRecord applyRecord =
|
||||
11; //@go_tags(`bson:"applyRecord"`) 入会申请
|
||||
repeated SociatyMember members = 12; //@go_tags(`bson:"members"`) 公会成员
|
||||
int32 activity = 13; //@go_tags(`bson:"activity"`) 活跃度
|
||||
int64 accuseTime = 14; //@go_tags(`bson:"accuseTime"`) 会长弹劾时间
|
||||
int32 lastSignCount = 15; //@go_tags(`bson:"lastSignCount"`) 昨日签到的人数
|
||||
repeated string signIds = 16; //@go_tags(`bson:"signIds"`) 今日签到的玩家IDs
|
||||
int64 dismissTime = 17; //@go_tags(`bson:"dismissTime"`) 公会解散时间
|
||||
int64 dismissCD = 18; //@go_tags(`bson:"dismissCD"`) 解散CD
|
||||
}
|
||||
|
||||
//申请记录
|
||||
message ApplyRecord {
|
||||
string uid = 1; //@go_tags(`bson:"uid"`) 申请的玩家ID
|
||||
int64 ctime = 2; //@go_tags(`bson:"ctime"`) 申请时间
|
||||
}
|
||||
|
||||
//职位
|
||||
enum SociatyJob {
|
||||
NOJOB = 0; //无职位/权限
|
||||
MEMBER = 1; //成员
|
||||
ADMIN = 2; //管理员
|
||||
VICEPRESIDENT = 3; //副会长
|
||||
PRESIDENT = 4; //会长
|
||||
}
|
||||
|
||||
// 公会成员
|
||||
message SociatyMember {
|
||||
string uid = 1; //@go_tags(`bson:"uid"`) 成员ID
|
||||
SociatyJob job = 2; //@go_tags(`bson:"job"`) 职位
|
||||
int64 ctime = 3; //@go_tags(`bson:"ctime"`) 入会时间
|
||||
int32 contribution = 4; //@go_tags(`bson:"contribution"`) 贡献值
|
||||
map<int32, ChallengeTeam> teams = 5; //@go_tags(`bson:"teams"`) 公会BOSS 队伍
|
||||
}
|
||||
|
||||
// 日志
|
||||
message SociatyLog {
|
||||
string content = 1; //@go_tags(`bson:"content"`) 日志内容
|
||||
int64 ctime = 2; //@go_tags(`bson:"ctime"`) 创建时间
|
||||
}
|
||||
|
||||
message DBSociatyLog {
|
||||
string sociatyId = 1; //@go_tags(`bson:"sociatyId") 公会ID
|
||||
repeated SociatyLog list = 2; //@go_tags(`bson:"list"`) 日志
|
||||
}
|
||||
|
||||
// 公会成员任务
|
||||
message DBSociatyTask {
|
||||
string sociatyId = 1; //@go_tags(`bson:"sociatyId") 公会ID
|
||||
string uid = 2; //@go_tags(`bson:"uid"`) 用户ID
|
||||
repeated SociatyTask taskList = 3; //@go_tags(`bson:"taskList"`) 任务列表
|
||||
repeated SociatyActivity activityList =
|
||||
4; //@go_tags(`bson:"activityList"`) 活跃度列表
|
||||
int64 lastUpdateTime = 5; //@go_tags(`bson:"lastUpdateTime"`) 上次初始时间
|
||||
}
|
||||
|
||||
// 任务
|
||||
message SociatyTask {
|
||||
int32 taskId = 1; //@go_tags(`bson:"taskId"`) 任务ID
|
||||
int32 status = 2; //@go_tags(`bson:"status"`) 领取状态:0未完成 1已完成
|
||||
int32 received = 3; //@go_tags(`bson:"received"`) 领取状态: 0未领取 1已领取
|
||||
}
|
||||
|
||||
// 活跃度
|
||||
message SociatyActivity {
|
||||
int32 id = 1; //@go_tags(`bson:"id"`) 活跃度ID
|
||||
int32 status = 2; //@go_tags(`bson:"status"`) 领取状态:0未领取 1已领取
|
||||
}
|
||||
|
||||
//任务活跃度排行榜
|
||||
message DBSociatyRank {
|
||||
string sociatyId = 1; //@go_tags(`bson:"sociatyId"`)
|
||||
string name = 2; //@go_tags(`bson:"name"`) 公会名称
|
||||
int32 lv = 3; //@go_tags(`bson:"lv"`) 等级
|
||||
int32 activity = 4; //@go_tags(`bson:"activity"`) 活跃度
|
||||
int64 ctime = 5; //@go_tags(`bson:"ctime"`) 公会创建时间
|
||||
}
|
||||
|
||||
// 阵容明细
|
||||
message ChallengeTeamInfo {
|
||||
string heroId = 1; //@go_tags(`bson:"heroId"`) 英雄ID
|
||||
}
|
||||
|
||||
// 阵容
|
||||
message ChallengeTeam {
|
||||
BattleFormation formation = 1; //@go_tags(`bson:"teamInfo"`) 阵容
|
||||
}
|
||||
|
||||
// 赛季信息
|
||||
message DBSociatyBossSports {
|
||||
int64 endTime = 1; //@go_tags(`bson:"endTime"`) 公会BOSS赛季结束时间
|
||||
int64 settlementTime = 2; //@go_tags(`bson:"settlementTime"`) 赛季结算时间
|
||||
repeated string uids = 3; //@go_tags(`bson:"uids"`) 参赛玩家
|
||||
}
|
||||
|
||||
// 玩家每次挑战的记录
|
||||
message ChallengeRecord {
|
||||
map<int32, ChallengeTeam> teams = 1; //@go_tags(`bson:"teams"`) 挑战队伍
|
||||
int64 integral = 2; //@go_tags(`bson:"integral"`) 公会BOSS挑战积分
|
||||
int32 duration = 3; //@go_tags(`bson:"duration"`) 战斗耗时
|
||||
int64 rtime = 4; //@go_tags(`bson:"rtime"`) 记录时间
|
||||
}
|
||||
|
||||
message ChallengeTask {
|
||||
int32 taskId = 1; //@go_tags(`bson:"taskId"`) 任务ID
|
||||
int32 status = 2; //@go_tags(`bson:"status"`) 任务状态 0未完成 1可领取 2已领取
|
||||
}
|
||||
|
||||
//玩家赛季记录
|
||||
message DBSociatyBossRecord {
|
||||
string uid = 1; //@go_tags(`bson:"uid"`) 玩家ID
|
||||
string sociatyId = 2; //@go_tags(`bson:"sociatyId"`) 公会ID
|
||||
repeated ChallengeRecord record = 4; //@go_tags(`bson:"record"`) 赛季挑战记录
|
||||
int64 total = 5; //@go_tags(`bson:"total"`) 赛季总积分(前三积分和)
|
||||
repeated int64 integrals = 6; //@go_tags(`bson:"integrals"`) 赛季中最高积分
|
||||
int32 status = 7; //@go_tags(`bson:"status"`)0当前赛季记录 1归档赛季记录
|
||||
repeated ChallengeTask tasks = 8; //@go_tags(`bson:"tasks"`) 积分任务
|
||||
}
|
289
src/pb/proto/sociaty/sociaty_msg.proto
Normal file
289
src/pb/proto/sociaty/sociaty_msg.proto
Normal file
@ -0,0 +1,289 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "comm.proto";
|
||||
import "sociaty/sociaty_db.proto";
|
||||
import "battle/battle_db.proto";
|
||||
import "battle/battle_msg.proto";
|
||||
|
||||
// 创建公会
|
||||
message SociatyCreateReq {
|
||||
string name = 1; //公会名称
|
||||
string icon = 2; //公会图标
|
||||
string notice = 3; //公告
|
||||
bool isApplyCheck = 4; //审批
|
||||
int32 applyLv = 5; //限制等级
|
||||
}
|
||||
|
||||
message SociatyCreateResp {
|
||||
string id = 1; //公会ID
|
||||
string uid = 2; //创建公会的玩家ID
|
||||
}
|
||||
|
||||
// 筛选条件
|
||||
enum SociatyListFilter {
|
||||
ALL = 0; //全部
|
||||
CONDI = 1; //满足条件
|
||||
NOAPPLY = 2; //无审批
|
||||
APPLYING = 3; //申请中
|
||||
}
|
||||
// 公会列表
|
||||
message SociatyListReq { SociatyListFilter filter = 1; }
|
||||
message SociatyListResp { repeated DBSociaty list = 1; }
|
||||
|
||||
// 搜索公会
|
||||
message SociatySearchReq {
|
||||
string name = 1; //公会名称
|
||||
}
|
||||
message SociatySearchResp { repeated DBSociaty list = 1; }
|
||||
|
||||
// 设置公会
|
||||
message SociatySettingReq {
|
||||
string icon = 1; //公会图标
|
||||
string notice = 2; //公告
|
||||
bool isApplyCheck = 3; //审批
|
||||
int32 applyLv = 4; //限制等级
|
||||
}
|
||||
|
||||
message SociatySettingResp {
|
||||
string sociatyId = 1; //公会ID
|
||||
}
|
||||
|
||||
// 我的公会
|
||||
message SociatyMineReq {}
|
||||
message SociatyMineResp {
|
||||
DBSociaty sociaty = 1; //公会信息
|
||||
SociatyMemberInfo master = 2; // 会长
|
||||
}
|
||||
|
||||
//成员信息
|
||||
message SociatyMemberInfo {
|
||||
string uid = 1;
|
||||
string name = 2; //昵称
|
||||
string avatar = 3; //头像
|
||||
int32 lv = 4; //等级
|
||||
SociatyJob job = 5; //职位
|
||||
int64 offlineTime = 6; //离线时间
|
||||
}
|
||||
|
||||
// 申请列表
|
||||
message SociatyApplyListReq { string sociatyId = 1; }
|
||||
message SociatyApplyListResp { repeated SociatyMemberInfo list = 1; }
|
||||
|
||||
// 申请
|
||||
message SociatyApplyReq {
|
||||
string sociatyId = 1; //公会ID
|
||||
}
|
||||
message SociatyApplyResp {
|
||||
string uid = 1;
|
||||
string scoiatyId = 2;
|
||||
}
|
||||
|
||||
// 申请撤销
|
||||
message SociatyApplyCancelReq { string sociatyId = 1; }
|
||||
message SociatyApplyCancelResp {
|
||||
string uid = 1;
|
||||
string sociatyId = 2;
|
||||
}
|
||||
|
||||
// 同意
|
||||
message SociatyAgreeReq { string uid = 1; }
|
||||
message SociatyAgreeResp {
|
||||
string uid = 1;
|
||||
string sociatyId = 2;
|
||||
}
|
||||
|
||||
// 拒绝
|
||||
message SociatyRefuseReq { string uid = 1; }
|
||||
message SociatyRefuseResp {
|
||||
string uid = 1;
|
||||
string sociatyId = 2;
|
||||
}
|
||||
|
||||
// 撤销申请
|
||||
message SociatyCancelReq {}
|
||||
message SociatyCancelResp {}
|
||||
|
||||
// 退出公会
|
||||
message SociatyQuitReq {}
|
||||
message SociatyQuitResp {
|
||||
string uid = 1;
|
||||
string sociatyId = 2;
|
||||
}
|
||||
|
||||
// 解散公会
|
||||
message SociatyDismissReq {
|
||||
int32 dismiss = 1; // 1取消解散
|
||||
}
|
||||
|
||||
message SociatyDismissResp {
|
||||
string uid = 1;
|
||||
string sociatyId = 2;
|
||||
}
|
||||
|
||||
// 员工列表
|
||||
message SociatyMembersReq {}
|
||||
message SociatyMembersResp { repeated SociatyMemberInfo list = 1; }
|
||||
|
||||
// 转让公会
|
||||
message SociatyAssignReq {
|
||||
string targetId = 1; //转让目标玩家ID
|
||||
}
|
||||
message SociatyAssignResp {
|
||||
string sociatyId = 1;
|
||||
string targetId = 2; //转让目标玩家ID
|
||||
}
|
||||
|
||||
// 踢出公会
|
||||
message SociatyDischargeReq {
|
||||
string targetId = 1; //踢出目标玩家ID
|
||||
}
|
||||
message SociatyDischargeResp {
|
||||
string sociatyId = 1;
|
||||
string targetId = 2; //转让目标玩家ID
|
||||
}
|
||||
|
||||
// 设置职位
|
||||
message SociatySettingJobReq {
|
||||
string targetId = 1; //目标玩家ID
|
||||
SociatyJob job = 2; //职位
|
||||
}
|
||||
message SociatySettingJobResp {
|
||||
string sociatyId = 1;
|
||||
string targetId = 2; //目标玩家ID
|
||||
SociatyJob job = 3; //职位
|
||||
}
|
||||
|
||||
// 弹劾
|
||||
message SociatyAccuseReq {}
|
||||
message SociatyAccuseResp { string sociatyId = 1; }
|
||||
|
||||
// 签到
|
||||
message SociatySignReq {}
|
||||
message SociatySignResp {
|
||||
string uid = 1;
|
||||
string sociatyId = 2;
|
||||
}
|
||||
|
||||
//日志列表
|
||||
message SociatyLogReq {}
|
||||
message SociatyLogResp { DBSociatyLog log = 1; }
|
||||
|
||||
// 任务列表
|
||||
message SociatyTaskListReq {}
|
||||
message SociatyTaskListResp { repeated SociatyTask list = 1; }
|
||||
|
||||
// 任务奖励领取
|
||||
message SociatyReceiveReq {
|
||||
int32 taskId = 1; //任务ID
|
||||
}
|
||||
message SociatyReceiveResp {
|
||||
int32 taskId = 1;
|
||||
string sociatyId = 2;
|
||||
}
|
||||
|
||||
// 活跃度列表
|
||||
message SociatyActivityListReq {}
|
||||
message SociatyActivityListResp { repeated SociatyActivity list = 1; }
|
||||
|
||||
//活跃度奖励领取
|
||||
message SociatyActivityReceiveReq {
|
||||
int32 id = 1; //配置ID
|
||||
}
|
||||
message SociatyActivityReceiveResp {
|
||||
int32 id = 1;
|
||||
string sociatyId = 2;
|
||||
}
|
||||
|
||||
// 公会排行榜
|
||||
message SociatyRankReq {
|
||||
int32 rankType = 1; // 1个人2公会成员3全服
|
||||
}
|
||||
message SociatyRankResp { repeated DBSociatyRank rank = 1; }
|
||||
|
||||
// 公会解散推送
|
||||
message SociatyPDismissPush { string sociatyId = 1; }
|
||||
|
||||
// 审核通过推送
|
||||
message SociatyPAgreePush {
|
||||
string uid = 1;
|
||||
string sociatyId = 2;
|
||||
}
|
||||
|
||||
// 公会BOSS入口
|
||||
message SociatyBMainReq {}
|
||||
|
||||
message SociatyBMainResp {
|
||||
map<int32, ChallengeTeam> teams = 1; //公会BOSS 队伍
|
||||
int32 ticket = 2; // 挑战券数量
|
||||
int64 endTime = 3; //赛季结束时间
|
||||
int64 settlementTime = 4; //赛季结算时间
|
||||
int64 total = 5; //总积分
|
||||
repeated int64 highIntegrals = 6; //最高的积分
|
||||
int64 personalRanking = 7; //个人排名
|
||||
int64 sociatyRanking = 8; //公会排名
|
||||
}
|
||||
|
||||
// 公会BOSS 布阵
|
||||
message SociatyBFormationReq {
|
||||
string sociatyId = 1;
|
||||
map<int32, ChallengeTeam> teams = 2; //队伍信息,队伍编号1 2 3,从1开始
|
||||
}
|
||||
|
||||
message SociatyBFormationResp {
|
||||
string sociatyId = 1;
|
||||
string uid = 2;
|
||||
}
|
||||
|
||||
// 公会BOSS挑战
|
||||
message SociatyBChallengeStartReq { string sociatyId = 1; }
|
||||
message SociatyBChallengeStartResp {
|
||||
string sociatyId = 1;
|
||||
string uid = 2;
|
||||
}
|
||||
|
||||
message SociatyBChallengeFinishReq {
|
||||
PlayType ptype = 1;
|
||||
BattleReport report = 2;
|
||||
}
|
||||
|
||||
message SociatyBChallengeFinishResp {
|
||||
int64 integral = 1; //积分
|
||||
}
|
||||
|
||||
// 公会BOSS 阵容推荐
|
||||
message SociatyRecommendReq {
|
||||
int32 cate = 1; // 1全服排行 2好友排行
|
||||
}
|
||||
|
||||
message SociatyRecommendResp { map<int32, ChallengeTeam> teams = 1; }
|
||||
|
||||
// 公会BOSS 领取奖励
|
||||
message SociatyBReceiveReq { int32 taskId = 1; }
|
||||
|
||||
message SociatyBReceiveResp {
|
||||
string sociatyId = 1;
|
||||
int32 taskId = 2;
|
||||
}
|
||||
|
||||
//公会BOSS 排名
|
||||
message SociatyBRankReq {
|
||||
int32 rankType = 1; //排名分类 1个人排名2公会成员3全服排名
|
||||
}
|
||||
|
||||
message SociatyRankInfo {
|
||||
string name = 1; //昵称
|
||||
string head = 2; //头像
|
||||
int32 lv = 3; //等级
|
||||
string sociatyName = 4; //公会名称
|
||||
int64 ranking = 5; //名次
|
||||
int64 integral = 6; //积分
|
||||
}
|
||||
message SociatyBRankResp { repeated SociatyRankInfo rank = 1; }
|
||||
|
||||
//挑战券购买
|
||||
message SociatyBuyReq {
|
||||
UserAssets atn = 1; //挑战券消耗资源及价格
|
||||
int32 buyNum = 2; //购买数量
|
||||
}
|
||||
|
||||
message SociatyBuyResp { string uid = 1; }
|
@ -1,7 +1,9 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
|
||||
message SysFuncListReq {}
|
||||
message SysFuncListReq {
|
||||
repeated string keys = 1; //功能ID
|
||||
}
|
||||
|
||||
message SysFuncListResp {
|
||||
repeated string funcIds = 1; //功能ID
|
58
src/pb/proto/task/task_db.proto
Normal file
58
src/pb/proto/task/task_db.proto
Normal file
@ -0,0 +1,58 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
|
||||
message DBTask {
|
||||
string id = 1; //@go_tags(`bson:"_id"`) ID
|
||||
string uid = 2; //@go_tags(`bson:"uid"`) 用户ID
|
||||
repeated TaskData dayList = 4; //@go_tags(`bson:"dayList"`) 日常任务列表
|
||||
repeated TaskData weekList = 5; //@go_tags(`bson:"weekList"`) 周常任务列表
|
||||
repeated TaskData achieveList =
|
||||
6; //@go_tags(`bson:"achieveList"`) 成就任务列表
|
||||
}
|
||||
|
||||
message TaskData {
|
||||
int32 taskId = 3; //@go_tags(`bson:"taskId"`) 任务Id
|
||||
int32 tag = 4; //@go_tags(`bson:"tag"`) 标签
|
||||
int32 progress = 5; //@go_tags(`bson:"progress"`) 任务进度/完成次数
|
||||
int32 active = 6; //@go_tags(`bson:"active"`) 活跃度
|
||||
int32 status = 7; //@go_tags(`bson:"status"`) 任务状态 默认0未完成 1已完成
|
||||
int32 received = 8; //@go_tags(`bson:"received"`) 领取状态 默认0未领取 1已领取
|
||||
int32 typeId = 9; //@go_tags(`bson:"typeId"`)
|
||||
int32 sort = 10; //@go_tags(`bson:"sort"`)
|
||||
}
|
||||
|
||||
message DBActivity {
|
||||
string id = 1; //@go_tags(`bson:"_id"`) ID
|
||||
string uid = 2; //@go_tags(`bson:"uid"`) 用户ID
|
||||
repeated ActivityData activityList =
|
||||
3; //@go_tags(`bson:"activityList"`) 活跃度列表
|
||||
}
|
||||
|
||||
message ActivityData {
|
||||
int32 taskId = 1; //@go_tags(`bson:"taskId"`) taskId
|
||||
int32 tag = 2; //@go_tags(`bson:"tag"`) 标签
|
||||
int32 received = 3; //@go_tags(`bson:"received"`) 领取状态 默认0未领取 1已领取
|
||||
}
|
||||
|
||||
message frtaskIds { repeated int32 rtaskIds = 1; }
|
||||
|
||||
// 玩家任务状态
|
||||
message DBRtask {
|
||||
string id = 1; //@go_tags(`bson:"_id"`) ID
|
||||
string uid = 2; //@go_tags(`bson:"uid"`) 用户ID
|
||||
map<int32, frtaskIds> frtaskIds =
|
||||
3; //@go_tags(`bson:"frtaskIds"`) 已完成的任务Id
|
||||
bool isReward = 5; //@go_tags(`bson:"isReward"`) 接收奖励
|
||||
}
|
||||
|
||||
message rtaskData {
|
||||
map<int32, int32> data = 1; //@go_tags(`bson:"data"`) 当前任务值
|
||||
int32 rtype = 2; //@go_tags(`bson:"rtype"`) 任务类型
|
||||
int64 timestamp = 3; //@go_tasg(`bson:"timestamp"`) 时间戳
|
||||
}
|
||||
// 玩家任务记录
|
||||
message DBRtaskRecord {
|
||||
string id = 1; //@go_tags(`bson:"_id"`) ID
|
||||
string uid = 2; //@go_tags(`bson:"uid"`) 用户ID
|
||||
map<int32, rtaskData> vals = 3; //@go_tags(`bson:"vals"`) 任务记录值
|
||||
}
|
@ -1,11 +1,23 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "task_db.proto";
|
||||
import "task/task_db.proto";
|
||||
|
||||
message TaskGetrecordReq {}
|
||||
message TaskGetrecordResp { DBRtaskRecord record = 1; }
|
||||
|
||||
//任务触发
|
||||
message TaskSendReq {
|
||||
int32 taskType = 1; //任务类型
|
||||
repeated int32 params = 2; //任务参数
|
||||
}
|
||||
message TaskSendResp {
|
||||
bool isSucc = 1;
|
||||
}
|
||||
|
||||
//领取
|
||||
message TaskReceiveReq {
|
||||
int32 taskTag = 1; // 1日常/2周常/3成就
|
||||
string id = 2; //任务唯一ID
|
||||
int32 id = 2; //任务唯一ID
|
||||
}
|
||||
|
||||
message TaskReceiveResp {
|
||||
@ -17,35 +29,25 @@ message TaskListReq {
|
||||
int32 taskTag = 1; //日常/周常/成就
|
||||
}
|
||||
|
||||
message TaskListResp { repeated DBTask list = 1; }
|
||||
message TaskListResp { repeated TaskData list = 1; }
|
||||
|
||||
//活跃度
|
||||
message TaskActiveListReq { int32 taskTag = 1; }
|
||||
message TaskActiveListResp {
|
||||
repeated DBTaskActive list = 1; //活跃度列表
|
||||
repeated ActivityData list = 1; //活跃度列表
|
||||
int32 active = 2; //活跃度值
|
||||
}
|
||||
|
||||
//活跃度领取
|
||||
message TaskActiveReceiveReq {
|
||||
int32 taskTag = 1; // 1日常/2周常
|
||||
string id = 2; //唯一id
|
||||
int32 id = 2; //唯一id
|
||||
}
|
||||
message TaskActiveReceiveResp {
|
||||
int32 taskTag = 1;
|
||||
string id = 2;
|
||||
int32 id = 2;
|
||||
}
|
||||
|
||||
//攻略
|
||||
message TaskDoStrategyReq {
|
||||
int32 heroCfgId = 1; //英雄ID
|
||||
}
|
||||
|
||||
message TaskDoStrategyResp {
|
||||
repeated int32 taskIds = 1; //任务ID
|
||||
}
|
||||
|
||||
//任务完成推送
|
||||
message TaskFinishedPush {
|
||||
int32 taskId = 1;
|
||||
}
|
||||
message TaskFinishedPush { int32 taskId = 1; }
|
@ -1,23 +0,0 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
|
||||
message DBTask {
|
||||
string id = 1; //@go_tags(`bson:"_id"`) ID
|
||||
string uid = 2; //@go_tags(`bson:"uid"`) 用户ID
|
||||
int32 taskId = 3; //@go_tags(`bson:"taskId"`) 任务Id
|
||||
int32 tag = 4; //@go_tags(`bson:"tag"`) 标签
|
||||
int32 progress = 5; //@go_tags(`bson:"progress"`) 任务进度/完成次数
|
||||
int32 active = 6; //@go_tags(`bson:"active"`) 活跃度
|
||||
int32 status = 7; //@go_tags(`bson:"status"`) 任务状态 默认0未完成 1已完成
|
||||
int32 received = 8; //@go_tags(`bson:"received"`) 领取状态 默认0未领取 1已领取
|
||||
int32 typeId = 9; //@go_tags(`bson:"typeId"`)
|
||||
int32 sort = 10; //@go_tags(`bson:"sort"`)
|
||||
}
|
||||
|
||||
message DBTaskActive {
|
||||
string id = 1; //@go_tags(`bson:"_id"`) ID
|
||||
string uid = 2; //@go_tags(`bson:"uid"`) 用户ID
|
||||
int32 rId = 3; //@go_tags(`bson:"taskId"`) rewardId
|
||||
int32 tag = 4; //@go_tags(`bson:"tag"`) 标签
|
||||
int32 received = 5; //@go_tags(`bson:"received"`) 领取状态 默认0未领取 1已领取
|
||||
}
|
7
src/pb/proto/taskcond/taskcond_msg.proto
Normal file
7
src/pb/proto/taskcond/taskcond_msg.proto
Normal file
@ -0,0 +1,7 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
|
||||
//任务完成条件推送
|
||||
message TaskcondFinishedPush {
|
||||
int32 condId = 1; //达成的任务条件ID
|
||||
}
|
36
src/pb/proto/troll/troll_db.proto
Normal file
36
src/pb/proto/troll/troll_db.proto
Normal file
@ -0,0 +1,36 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
|
||||
|
||||
// 巨怪列车
|
||||
message DBTrollTrain {
|
||||
string id = 1; //@go_tags(`bson:"_id"`) ID
|
||||
string uid = 2; //@go_tags(`bson:"uid"`) 用户ID
|
||||
map<int32,int32> items = 3;// 货物 key 货物ID
|
||||
map<int32,int32> price = 4;// 货物买入价格 key 货物ID
|
||||
int32 gridNum = 5; //@go_tags(`bson:"gridNum"`) 当前使用格子数量
|
||||
int32 tarinPos = 6; //@go_tags(`bson:"tarinPos"`) 火车位置 (商人位置)
|
||||
int32 rangeId = 7; //@go_tags(`bson:"rangeId"`) 增长幅度
|
||||
int32 buy = 8; // 挂机进货标准/千分比
|
||||
int32 sell = 9; //挂机卖出标准/千分比
|
||||
int32 npcLv = 10;//@go_tags(`bson:"npcLv"`) npc 等级
|
||||
map<int32,int32> npcReward = 11;//@go_tags(`bson:"npcReward"`) npc奖励
|
||||
int64 totalEarn = 12;//@go_tags(`bson:"totalEarn"`) 累计赚的钱
|
||||
int32 sellCount = 13;//@go_tags(`bson:"sellCount"`) 今天已经卖出次数
|
||||
int64 refreshTime = 14;//@go_tags(`bson:"refreshTime"`) 最后一次刷新的时间 通过这个计算下一次刷新时间
|
||||
int32 aiCount = 15;//@go_tags(`bson:"aiCount"`) AI 交易次数
|
||||
map<int32,int32> shop= 16; // 商人的限购数量
|
||||
int64 ctime = 17; // 创建时间
|
||||
int32 circle = 18; // 循环商人的次数
|
||||
map<int32,int32> surpriseID = 19; //@go_tags(`bson:"surpriseID"`) key商人id value惊喜货物ID
|
||||
int64 resetTime = 20; //@go_tags(`bson:"resetTime"`) 每日重置时间
|
||||
}
|
||||
|
||||
// 收益记录
|
||||
message DBTrollRecord{
|
||||
string id = 1; //@go_tags(`bson:"_id"`) ID
|
||||
string uid = 2; //@go_tags(`bson:"uid"`) 用户ID
|
||||
int32 gold = 3; // 收益
|
||||
int32 pos = 4; // 商人位置
|
||||
int64 time = 5; // 交易时间
|
||||
}
|
74
src/pb/proto/troll/troll_msg.proto
Normal file
74
src/pb/proto/troll/troll_msg.proto
Normal file
@ -0,0 +1,74 @@
|
||||
syntax = "proto3";
|
||||
option go_package = ".;pb";
|
||||
import "troll/troll_db.proto";
|
||||
// 查询进度
|
||||
message TrollGetListReq {
|
||||
|
||||
}
|
||||
// 返回进度信息
|
||||
message TrollGetListResp {
|
||||
DBTrollTrain data = 1;
|
||||
}
|
||||
|
||||
// 买卖货物
|
||||
message TrollBuyOrSellReq {
|
||||
map<int32,int32> items =1;//买入货物的数量(负数为卖)
|
||||
}
|
||||
|
||||
message TrollBuyOrSellResp {
|
||||
DBTrollTrain data = 1;
|
||||
}
|
||||
|
||||
// afk 设置
|
||||
message TrollAfkSetReq {
|
||||
int32 buy = 1;
|
||||
int32 sell = 2;
|
||||
int32 count = 3; // 挂机次数
|
||||
}
|
||||
|
||||
message TrollAfkSetResp {
|
||||
DBTrollTrain data = 1;
|
||||
}
|
||||
|
||||
// npv等级奖励
|
||||
message TrollNpcRewardReq {
|
||||
int32 rewardId = 1;
|
||||
}
|
||||
|
||||
message TrollNpcRewardResp {
|
||||
DBTrollTrain data = 1;
|
||||
}
|
||||
|
||||
// 获取收益排行榜
|
||||
message TrollRankListReq {
|
||||
|
||||
}
|
||||
message RankData{
|
||||
int32 rankId = 1; // 排名
|
||||
string uid = 2;
|
||||
string name = 3; // 昵称
|
||||
int64 gold = 4; // 收益金币
|
||||
int32 figure = 5; // 形象
|
||||
int32 title = 6;
|
||||
}
|
||||
message TrollRankListResp {
|
||||
repeated RankData data = 1;
|
||||
}
|
||||
|
||||
// 获取收益明细
|
||||
message TrollRecordListReq {
|
||||
|
||||
}
|
||||
|
||||
message TrollRecordListResp {
|
||||
repeated DBTrollRecord data = 1;
|
||||
}
|
||||
// 获取惊喜商品
|
||||
message TrollSurpriseIdReq {
|
||||
|
||||
}
|
||||
|
||||
// 返回进度信息
|
||||
message TrollSurpriseIdResp {
|
||||
map<int32,int32> surpriseID = 1; //@go_tags(`bson:"surpriseID"`) key商人id value惊喜货物ID
|
||||
}
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user