上传pb测试工具代码

This commit is contained in:
liwei1dao 2022-08-31 14:32:43 +08:00
parent 67a97720ef
commit b4007d4b97
8 changed files with 480 additions and 0 deletions

View File

@ -1817,6 +1817,135 @@ var $root = ($protobuf.roots["default"] || ($protobuf.roots["default"] = new $pr
}
}
},
DBHunting: {
fields: {
id: {
type: "string",
id: 1
},
uid: {
type: "string",
id: 2
},
challengeCount: {
type: "int32",
id: 3
},
boos: {
keyType: "int32",
type: "int32",
id: 4
},
buyCount: {
type: "int32",
id: 5
},
cTime: {
type: "int64",
id: 6
},
challengeTime: {
keyType: "int32",
type: "int32",
id: 7
}
}
},
DBHuntingRank: {
fields: {
id: {
type: "string",
id: 1
},
uid: {
type: "string",
id: 2
},
difficulty: {
type: "int32",
id: 3
},
bosstype: {
type: "int32",
id: 4
},
nickname: {
type: "string",
id: 5
},
icon: {
type: "string",
id: 6
},
lv: {
type: "int32",
id: 7
},
costTime: {
type: "int32",
id: 8
}
}
},
HuntingGetListReq: {
fields: {}
},
HuntingGetListResp: {
fields: {
data: {
type: "DBHunting",
id: 1
}
}
},
HuntingChallengeReq: {
fields: {
bossType: {
type: "int32",
id: 1
},
difficulty: {
type: "int32",
id: 2
}
}
},
HuntingChallengeResp: {
fields: {
data: {
type: "DBHunting",
id: 1
}
}
},
HuntingBuyReq: {
fields: {
count: {
type: "int32",
id: 1
}
}
},
HuntingBuyResp: {
fields: {
data: {
type: "DBHunting",
id: 1
}
}
},
HuntingRankListReq: {
fields: {}
},
HuntingRankListResp: {
fields: {
ranks: {
rule: "repeated",
type: "DBHuntingRank",
id: 1
}
}
},
DB_UserItemData: {
fields: {
gridId: {
@ -2290,6 +2419,82 @@ var $root = ($protobuf.roots["default"] || ($protobuf.roots["default"] = new $pr
}
}
},
DBMoonfantasy: {
fields: {
id: {
type: "string",
id: 1
},
uid: {
type: "string",
id: 2
},
monster: {
type: "int32",
id: 3
},
ctime: {
type: "int64",
id: 4
},
joinnum: {
type: "int32",
id: 5
},
numup: {
type: "int32",
id: 6
},
unitmup: {
type: "int32",
id: 7
},
record: {
keyType: "string",
type: "int32",
id: 8
}
}
},
MoonfantasyTriggerReq: {
fields: {}
},
MoonfantasyTriggerResp: {
fields: {
issucc: {
type: "bool",
id: 1
},
mid: {
type: "string",
id: 2
},
monster: {
type: "int32",
id: 3
}
}
},
MoonfantasyDareReq: {
fields: {
uid: {
type: "string",
id: 1
},
mid: {
type: "string",
id: 2
}
}
},
MoonfantasyDareResp: {
fields: {
issucc: {
type: "bool",
id: 1
}
}
},
DBSystemNotify: {
fields: {
id: {
@ -3484,6 +3689,135 @@ var $root = ($protobuf.roots["default"] || ($protobuf.roots["default"] = new $pr
id: 13
}
}
},
DBViking: {
fields: {
id: {
type: "string",
id: 1
},
uid: {
type: "string",
id: 2
},
challengeCount: {
type: "int32",
id: 3
},
boos: {
keyType: "int32",
type: "int32",
id: 4
},
buyCount: {
type: "int32",
id: 5
},
cTime: {
type: "int64",
id: 6
},
challengeTime: {
keyType: "int32",
type: "int32",
id: 7
}
}
},
DBVikingRank: {
fields: {
id: {
type: "string",
id: 1
},
uid: {
type: "string",
id: 2
},
difficulty: {
type: "int32",
id: 3
},
bosstype: {
type: "int32",
id: 4
},
nickname: {
type: "string",
id: 5
},
icon: {
type: "string",
id: 6
},
lv: {
type: "int32",
id: 7
},
costTime: {
type: "int32",
id: 8
}
}
},
VikingGetListReq: {
fields: {}
},
VikingGetListResp: {
fields: {
data: {
type: "DBViking",
id: 1
}
}
},
VikingChallengeReq: {
fields: {
bossType: {
type: "int32",
id: 1
},
difficulty: {
type: "int32",
id: 2
}
}
},
VikingChallengeResp: {
fields: {
data: {
type: "DBViking",
id: 1
}
}
},
VikingBuyReq: {
fields: {
count: {
type: "int32",
id: 1
}
}
},
VikingBuyResp: {
fields: {
data: {
type: "DBViking",
id: 1
}
}
},
VikingRankListReq: {
fields: {}
},
VikingRankListResp: {
fields: {
ranks: {
rule: "repeated",
type: "DBVikingRank",
id: 1
}
}
}
});

View File

@ -0,0 +1,25 @@
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> boos = 4; // key boos value
int32 buyCount = 5;//@go_tags(`bson:"buyCount"`)
int64 cTime = 6; //@go_tags(`bson:"cTime"`)
map<int32,int32> challengeTime = 7; //@go_tags(`bson:"challengeTime"`)
}
//
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
}

View File

@ -0,0 +1,29 @@
syntax = "proto3";
option go_package = ".;pb";
import "hunting_db.proto";
message HuntingGetListReq {}
message HuntingGetListResp { DBHunting data = 1; }
//
message HuntingChallengeReq {
int32 bossType = 1; // boos
int32 difficulty = 2; //
}
message HuntingChallengeResp { DBHunting data = 1; }
//
message HuntingBuyReq {
int32 count = 1; //
}
message HuntingBuyResp { DBHunting data = 1; }
//
message HuntingRankListReq {}
message HuntingRankListResp {
repeated DBHuntingRank ranks = 1; // boss类型
}

View File

@ -0,0 +1,13 @@
syntax = "proto3";
option go_package = ".;pb";
message DBMoonfantasy {
string id = 1; //@go_tags(`bson:"_id"`) ID
string uid = 2; //id
int32 monster = 3; //id
int64 ctime = 4; //
int32 joinnum = 5; //
int32 numup = 6; //
int32 unitmup = 7; //
map<string, int32> record = 8; //
}

View File

@ -0,0 +1,22 @@
syntax = "proto3";
option go_package = ".;pb";
///
message MoonfantasyTriggerReq {}
///
message MoonfantasyTriggerResp {
bool issucc = 1; //
string mid = 2; //id //
int32 monster = 3; //id
}
///
message MoonfantasyDareReq {
string uid = 1; //id
string mid = 2; //id
}
message MoonfantasyDareResp {
bool issucc = 1; //
}

View File

@ -0,0 +1,25 @@
syntax = "proto3";
option go_package = ".;pb";
//
message DBViking {
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> boos = 4; // key boos value
int32 buyCount = 5;//@go_tags(`bson:"buyCount"`)
int64 cTime = 6; //@go_tags(`bson:"cTime"`)
map<int32,int32> challengeTime = 7; //@go_tags(`bson:"challengeTime"`)
}
//
message DBVikingRank {
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
}

View File

@ -0,0 +1,29 @@
syntax = "proto3";
option go_package = ".;pb";
import "viking_db.proto";
message VikingGetListReq {}
message VikingGetListResp { DBViking data = 1; }
//
message VikingChallengeReq {
int32 bossType = 1; // boos
int32 difficulty = 2; //
}
message VikingChallengeResp { DBViking data = 1; }
//
message VikingBuyReq {
int32 count = 1; //
}
message VikingBuyResp { DBViking data = 1; }
//
message VikingRankListReq {}
message VikingRankListResp {
repeated DBVikingRank ranks = 1; // boss类型
}

View File

@ -220,6 +220,9 @@ export default defineComponent({
{ mainType: 'martialhall', subs: [] },
{ mainType: 'gourmet', subs: [] },
{ mainType: 'smithy', subs: [] },
{ mainType: 'moonfantasy', subs: [] },
{ mainType: 'viking', subs: [] },
{ mainType: 'hunting', subs: [] },
])
for (const v of Object.keys(proto)) {
for (const v1 of proto_models) {