2019-06-13 12:36:40 +08:00
|
|
|
|
package com.ljsd.jieling.protocols;
|
|
|
|
|
|
|
|
|
|
option optimize_for = SPEED;
|
|
|
|
|
|
|
|
|
|
import "CommonProto.proto";
|
2019-06-14 18:48:13 +08:00
|
|
|
|
message AgentInfo {
|
|
|
|
|
optional int32 playerUid = 1;
|
|
|
|
|
optional int32 curHp = 2;
|
|
|
|
|
optional int32 maxHp =3;
|
|
|
|
|
optional int32 camp =4; //阵营 区分敌我
|
|
|
|
|
optional int32 curXY =5; //所在位置
|
|
|
|
|
repeated FoodBuffer foodBuffers = 6; // buff
|
|
|
|
|
optional int32 reviveTime = 7; // 死亡复活剩余时间
|
|
|
|
|
repeated int32 dieList = 8; // 死亡计数(按顺序记录杀死自己的玩家uid)
|
|
|
|
|
repeated int32 killList = 9; // 杀人计数(按顺序记录自己杀死的玩家uid)
|
2019-06-18 19:35:03 +08:00
|
|
|
|
repeated int32 path = 10; // 路径图
|
2019-06-14 18:48:13 +08:00
|
|
|
|
}
|
|
|
|
|
|
2019-06-13 12:36:40 +08:00
|
|
|
|
//因为多个人在一个房间中战斗,需要实现实时的处理方案
|
|
|
|
|
|
|
|
|
|
//匹配进入的房间
|
|
|
|
|
message RoomMatchRequest{
|
2019-06-13 14:52:12 +08:00
|
|
|
|
optional int32 type = 1; //type 匹配游戏类型 1血战
|
2019-06-13 12:36:40 +08:00
|
|
|
|
}
|
|
|
|
|
//匹配应答
|
|
|
|
|
message RoomMatchResponse{
|
2019-06-14 10:00:04 +08:00
|
|
|
|
optional bool result = 1; //0 成功
|
2019-06-13 14:52:12 +08:00
|
|
|
|
optional int32 type = 2; //type 匹配游戏类型 1血战
|
2019-06-13 12:36:40 +08:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
//取消匹配,必须等待服务器应答成功后,客户端才能退出匹配界面,
|
|
|
|
|
//否则可能服务器端可能匹配成功,客户端退出了匹配模式
|
|
|
|
|
message RoomCancelMatchRequest{
|
2019-06-13 14:52:12 +08:00
|
|
|
|
optional int32 type = 1; //type 匹配游戏类型 1血战
|
2019-06-13 12:36:40 +08:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
message RoomCancelMatchResponse{
|
2019-06-13 13:34:54 +08:00
|
|
|
|
optional bool result = 1; //true 取消成功,false 不能取消
|
2019-06-13 14:52:12 +08:00
|
|
|
|
optional int32 type = 2; //type 匹配游戏类型 1血战
|
2019-06-13 12:36:40 +08:00
|
|
|
|
}
|
|
|
|
|
|
2019-07-16 20:57:05 +08:00
|
|
|
|
message RoomMatchSuccessIndication{
|
|
|
|
|
optional int32 type =1;
|
2019-07-16 18:29:51 +08:00
|
|
|
|
optional SceneInfo sceneInfo =2; // 场景信息
|
2019-06-14 10:00:04 +08:00
|
|
|
|
}
|
|
|
|
|
|
2019-06-13 12:36:40 +08:00
|
|
|
|
//必须有准备过程防止因为机器性能原因导致,性能好的先进入游戏
|
2019-06-13 17:28:11 +08:00
|
|
|
|
message RoomStartGameReadyRequest{
|
2019-06-13 14:52:12 +08:00
|
|
|
|
optional int32 type = 1; //type 匹配游戏类型 1血战
|
2019-06-13 12:36:40 +08:00
|
|
|
|
}
|
2019-06-14 13:38:03 +08:00
|
|
|
|
//开始游戏应答
|
2019-06-13 17:28:11 +08:00
|
|
|
|
message RoomStartGameReadyResponse{
|
2019-06-13 14:52:12 +08:00
|
|
|
|
optional int32 type = 1; //type 匹配游戏类型 1血战
|
2019-06-13 12:36:40 +08:00
|
|
|
|
}
|
|
|
|
|
|
2019-06-13 17:28:11 +08:00
|
|
|
|
message RoomStartGameIndication{
|
2019-06-13 13:34:54 +08:00
|
|
|
|
optional int32 roomId = 1;
|
2019-06-13 14:52:12 +08:00
|
|
|
|
optional int32 type = 2; //type 匹配游戏类型 1血战
|
2019-06-13 12:36:40 +08:00
|
|
|
|
}
|
2019-06-13 13:34:54 +08:00
|
|
|
|
|
2019-06-15 17:23:29 +08:00
|
|
|
|
//获取全量信息
|
|
|
|
|
message RoomGetFullInfoResponse{
|
|
|
|
|
optional RoomMatchSuccessIndication roomMatchSuccessIndication =1;
|
|
|
|
|
}
|
|
|
|
|
|
2019-06-13 12:36:40 +08:00
|
|
|
|
|