Kaynağa Gözat

添加大厅派对列表 & 房间重置 协议

王虎 3 yıl önce
ebeveyn
işleme
57adb1a2b1
2 değiştirilmiş dosya ile 25 ekleme ve 1 silme
  1. 3 0
      README.md
  2. 22 1
      protos/party.proto

+ 3 - 0
README.md

@@ -79,6 +79,7 @@
 | 177 | PartyReadyResponse | s -> c | 响应已准备 |
 | 178 | PartyReadyPush | s -> c | 推送已准备 |
 | 179 | PartyFullPush | s -> c | 推送房间已满 |
+| 180 | PartyResetPush | s -> c | 推送房间重置 |
 | 181 | PartyFinishPush | s -> c | 推送房间结束 |
 | 182 | PartyStageCrossRequest | c -> s | 请求通关小关卡 |
 | 183 | PartyStageCrossResponse | s -> c | 响应通关小关卡 |
@@ -88,3 +89,5 @@
 | 187 | PartySyncRequest | c -> s | 客户端同步数据 |
 | 188 | PartySyncResponse | s -> c | 服务器响应同步结果 |
 | 189 | PartySyncPush | s -> c | 服务器通知客户端想要他人的同步数据 |
+| 190 | PartyListRequest | c -> s | 请求大厅派对列表 |
+| 191 | PartyListResponse | s -> c | 服务器响应大厅列表 |

+ 22 - 1
protos/party.proto

@@ -46,7 +46,11 @@ message PartyReadyPush {
 message PartyFullPush {
 }
 
-message PartyStartPush {
+message PartyResetPush {
+    repeated UserInfo Users = 1;
+    uint64 Step = 2;
+    map<string, bytes> state = 3;
+    string Road = 4;
 }
 
 message PartyFinishPush {
@@ -75,4 +79,21 @@ message PartyStageStartPush {
 message PartyStageFinishPush {
     uint32 StageIndex = 1; // 第几个小关
     repeated uint32 Users = 2; // 过关用户
+}
+
+message PartyInfo {
+    uint64 PartyID = 1;
+    int32 PartyType = 2; // 1 = 糖豆人; 2 = ** ; 3 = **
+    int32 GameUserCount = 3; // 游戏人数
+    int32 ObUserCount = 4; // 观战人数
+    int32 Status = 5; // 房间状态 0 = 已创建;1=已满员; 2=已开始; 3 = 已结束; 4 = 已解散
+}
+
+message PartyListRequest {
+    int32 PartyType = 1; // 0 = 不限; 1 = 糖豆人; 2 = ** ; 3 = **
+}
+
+message PartyListResponse {
+    Result Result = 1;
+    repeated PartyInfo Parties = 2;
 }