上传协议工具代码

This commit is contained in:
liwei1dao 2022-08-23 09:56:15 +08:00
parent 9815572c16
commit 67a97720ef
6 changed files with 243 additions and 27 deletions

BIN
dist.rar

Binary file not shown.

View File

@ -468,6 +468,7 @@ var $root = ($protobuf.roots["default"] || ($protobuf.roots["default"] = new $pr
HeroMaxStarLv: 1321, HeroMaxStarLv: 1321,
DrawCardTypeNotFound: 1322, DrawCardTypeNotFound: 1322,
HeroMaxSkillLv: 1323, HeroMaxSkillLv: 1323,
HeroAlreadyKongFuStatus: 1324,
EquipmentOnFoundEquipment: 1400, EquipmentOnFoundEquipment: 1400,
EquipmentLvlimitReached: 1401, EquipmentLvlimitReached: 1401,
EquipmentIsWorn: 1402, EquipmentIsWorn: 1402,
@ -500,7 +501,12 @@ var $root = ($protobuf.roots["default"] || ($protobuf.roots["default"] = new $pr
MartialhallInUse: 2001, MartialhallInUse: 2001,
MartialhallUnlocked: 2002, MartialhallUnlocked: 2002,
GourmetMoreOrderTime: 2101, GourmetMoreOrderTime: 2101,
GourmetSkillMaxLv: 2102 GourmetSkillMaxLv: 2102,
RtaskFinished: 2201,
RtaskUnFinished: 2202,
RtaskNoRtask: 2203,
RtaskRewarded: 2204,
RtaskPreNoFinish: 2205
} }
}, },
google: { google: {
@ -2588,6 +2594,140 @@ var $root = ($protobuf.roots["default"] || ($protobuf.roots["default"] = new $pr
} }
} }
}, },
Clang: {
fields: {
deskType: {
type: "int32",
id: 1
},
eTime: {
type: "int64",
id: 2
}
}
},
OrderClang: {
fields: {
deskType: {
type: "int32",
id: 1
},
count: {
type: "int32",
id: 2
},
needTime: {
type: "int32",
id: 3
}
}
},
DBSmithy: {
fields: {
id: {
type: "string",
id: 1
},
uid: {
type: "string",
id: 2
},
clang: {
type: "Clang",
id: 3
},
orders: {
rule: "repeated",
type: "OrderClang",
id: 4
},
items: {
rule: "repeated",
type: "UserAssets",
id: 5
},
skill: {
keyType: "int32",
type: "int32",
id: 6
},
stoveLv: {
type: "int32",
id: 7
},
orderCostTime: {
type: "int32",
id: 8
},
ctime: {
type: "int64",
id: 9
},
deskFloor: {
type: "int32",
id: 10
},
stoveFloor: {
type: "int32",
id: 11
}
}
},
SmithyGetListReq: {
fields: {}
},
SmithyGetListResp: {
fields: {
data: {
type: "DBSmithy",
id: 1
}
}
},
SmithyCreateOrderReq: {
fields: {
order: {
rule: "repeated",
type: "OrderClang",
id: 1
}
}
},
SmithyCreateOrderResp: {
fields: {
data: {
type: "DBSmithy",
id: 1
}
}
},
SmithyGetRewardReq: {
fields: {}
},
SmithyGetRewardResp: {
fields: {
data: {
type: "DBSmithy",
id: 1
}
}
},
SmithySkillLvReq: {
fields: {
skillType: {
type: "int32",
id: 1
}
}
},
SmithySkillLvResp: {
fields: {
data: {
type: "DBSmithy",
id: 1
}
}
},
DBTask: { DBTask: {
fields: { fields: {
id: { id: {

View File

@ -67,30 +67,31 @@ enum ErrorCode {
ItemsUseNotSupported = 1204; //使 ItemsUseNotSupported = 1204; //使
// hero // hero
HeroNoExist = 1300; // HeroNoExist = 1300; //
HeroNoEnough = 1301; // HeroNoEnough = 1301; //
HeroMaxLv = 1302; // HeroMaxLv = 1302; //
HeroInitCreat = 1303; // HeroInitCreat = 1303; //
HeroColorErr = 1304; // HeroColorErr = 1304; //
HeroSkillUpErr = 1305; // HeroSkillUpErr = 1305; //
HeroMaxResonate = 1306; // HeroMaxResonate = 1306; //
HeroNoResonate = 1307; // HeroNoResonate = 1307; //
HeroNotNeedResonate = 1308; // HeroNotNeedResonate = 1308; //
HeroNoEnergy = 1309; // HeroNoEnergy = 1309; //
HeroCreate = 1310; // HeroCreate = 1310; //
HeroEquipUpdate = 1311; // HeroEquipUpdate = 1311; //
HeroMaxAwaken = 1312; // HeroMaxAwaken = 1312; //
HeroIsLock = 1313; // HeroIsLock = 1313; //
HeroMaxCount = 1314; // HeroMaxCount = 1314; //
HeroCostTypeErr = 1315; // HeroCostTypeErr = 1315; //
HeroStarErr = 1316; // HeroStarErr = 1316; //
HeroTypeErr = 1317; // HeroTypeErr = 1317; //
HeroExpTypeErr = 1318; // HeroExpTypeErr = 1318; //
HeroAddMaxExp = 1319; // HeroAddMaxExp = 1319; //
HeroStarLvErr = 1320; // HeroStarLvErr = 1320; //
HeroMaxStarLv = 1321; // HeroMaxStarLv = 1321; //
DrawCardTypeNotFound = 1322; // DrawCardTypeNotFound = 1322; //
HeroMaxSkillLv = 1323; // HeroMaxSkillLv = 1323; //
HeroAlreadyKongFuStatus = 1324; //
// equipment // equipment
EquipmentOnFoundEquipment = 1400; // EquipmentOnFoundEquipment = 1400; //
@ -134,6 +135,13 @@ enum ErrorCode {
MartialhallInUse = 2001; //使 MartialhallInUse = 2001; //使
MartialhallUnlocked = 2002; // MartialhallUnlocked = 2002; //
// //
GourmetMoreOrderTime = 2101;// GourmetMoreOrderTime = 2101; //
GourmetSkillMaxLv = 2102; // GourmetSkillMaxLv = 2102; //
// rtask
RtaskFinished = 2201; //
RtaskUnFinished = 2202; //
RtaskNoRtask = 2203; //
RtaskRewarded = 2204; //
RtaskPreNoFinish = 2205; //
} }

View File

@ -0,0 +1,29 @@
syntax = "proto3";
option go_package = ".;pb";
import "comm.proto";
message Clang{
int32 deskType = 1; //
int64 eTime = 2;
}
//
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; //
int32 deskFloor = 10;//@go_tags(`bson:"deskFloor"`)
int32 stoveFloor = 11;//@go_tags(`bson:"stoveFloor"`)
}

View File

@ -0,0 +1,38 @@
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 SmithySkillLvReq{
int32 skillType = 1; // id
}
message SmithySkillLvResp{
DBSmithy data = 1;
}

View File

@ -219,6 +219,7 @@ export default defineComponent({
{ mainType: 'pagoda', subs: [] }, { mainType: 'pagoda', subs: [] },
{ mainType: 'martialhall', subs: [] }, { mainType: 'martialhall', subs: [] },
{ mainType: 'gourmet', subs: [] }, { mainType: 'gourmet', subs: [] },
{ mainType: 'smithy', subs: [] },
]) ])
for (const v of Object.keys(proto)) { for (const v of Object.keys(proto)) {
for (const v1 of proto_models) { for (const v1 of proto_models) {