Commit 5ec8cc651d22bd192e562058d701b05918a3bec9

Authored by zhangqijia
1 parent c4c4c39c

fix: 记录战斗

Showing 3 changed files with 27 additions and 3 deletions   Show diff stats
game.proto
... ... @@ -62,6 +62,24 @@ message RoleClearItemsReq {
62 62 int32 count = 2;
63 63 }
64 64  
  65 +message RoleStartBattleReq {
  66 + int32 chapter_id = 1;
  67 + int32 carbon_id = 2;
  68 +}
  69 +
  70 +message RoleEndBattleReq {
  71 + int32 chapter_id = 1;
  72 + int32 carbon_id = 2;
  73 + bool pass = 3;
  74 +}
  75 +
  76 +message RoleEndBattleRsp {
  77 + int32 role_level = 1;
  78 + int32 role_exp = 2;
  79 + models.Hero hero = 3;
  80 + string reward = 4;
  81 +}
  82 +
65 83 //ResponseCmd EquipmentDelReq
66 84 message EquipmentDelReq {
67 85 string id = 1;
... ...
models.proto
... ... @@ -18,6 +18,7 @@ message Hero {
18 18 int32 rein_count = 5;
19 19 int32 rein_point = 6;
20 20 string equipments = 7; //"id=type id1=type1"
  21 + int64 exp = 8;
21 22 }
22 23  
23 24 message Equipment {
... ... @@ -53,7 +54,7 @@ message Role {
53 54 string device = 3;
54 55 string nick = 4;
55 56 int32 level = 5;
56   - int64 exp = 6;
  57 + int32 exp = 6;
57 58  
58 59 int64 hp = 7;
59 60 int64 hp_max = 8;
... ... @@ -68,4 +69,6 @@ message Role {
68 69 uint32 otherlimit = 18;
69 70 uint32 jewelrylimit = 19;
70 71 uint32 materiallimit = 20;
  72 +
  73 + map<int32, int32> pass_chapters = 21; // 通关记录
71 74 }
... ...
protocode.proto
... ... @@ -17,7 +17,10 @@ enum ProtoCode
17 17 RoleUpdatePropertyRsp = 9;
18 18 RoleUpdateItemsRsp = 10;
19 19 RoleClearItemsReq = 11;
20   - EquipmentDelReq = 12;
21   - EquipmentAddRsp = 13;
  20 + RoleStartBattleReq = 12;
  21 + RoleEndBattleReq = 13;
  22 + RoleEndBattleRsp = 14;
  23 + EquipmentDelReq = 15;
  24 + EquipmentAddRsp = 16;
22 25  
23 26 }
24 27 \ No newline at end of file
... ...