123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166 |
- syntax = "proto3";
- option go_package = "./msg";
- //登录
- message ResLogin {
- string userId = 1;
- string nikeName = 2;
- }
- //登录 响应
- message ReqLogin {
- string nikeName = 1;
- string userId = 2;
- string gameStatus = 3;
- MsgError error = 4;
- }
- //进入大厅
- message EnterHall {
- string userId = 1;
- }
- //离开大厅
- message LeaveHall {
- string userId = 1;
- }
- //加入房间
- message ResJoinRoom {
- string userId = 1;
- string roomId = 2;
- string gameId = 3;
- }
- //加入房间
- message ReqJoinRoom {
- string userId = 1;
- string roomId = 2;
- string gameId = 3;
- int32 sitPos = 4;
- ReqRoom roomInfo = 5;
- }
- //玩法列表
- message PlayList {
- string userId = 1;
- }
- //商城
- message Shop {
- string userId = 1;
- }
- message ResGameInfo {
- string gameId = 1;
- }
- message ReqGameInfo {
- string gameId = 1;
- string gameName = 2;
- string gameStatus = 4;
- string gameType = 5;
- TeenPattiRoomList teenPattiRoomList = 6;
- }
- message TeenPattiRoomList {
- repeated TeenPattiRoom teenPattiRoom = 1;
- }
- message TeenPattiRoom {
-
- string boot = 1; //0.1
- string minBuyin = 2; // 1
- string chaalLimmit = 3; // 12.8
- string potLimit = 4; //102.40
- string totalPlayers = 5; // 3999
- string roomLevel = 6; //low - mid - high
- string roomId = 7;
- string type = 8;
- }
- // 通知客户端发牌
- message ReqDealCard {
- int32 sitPos = 1;
- }
- // 通知客户端操作
- message ReqPlayerAction {
- int32 sitPos = 1;
- PlayerOpt playerOpt = 2;
- }
- // 接到玩家操作
- message ResPlayerOptAction {
- int32 sitPos = 1;
- PlayerOpt playerOpt = 2;
- string roomId = 3;
- string gameId = 4;
- string userId = 5;
- }
- // PlayerOptType 玩家操作类型
- enum PlayerOptType {
- OPT_NONE = 0; // 无操作
- OPT_SEEN = 1; // 看牌
- OPT_PACKED = 2; // 弃牌
- OPT_CHAAL = 3; // 跟注
- OPT_BIND = 4; // 绑定
- OPT_SELECT = 5; // 选择操作
- OPT_SHOW = 6; // 亮牌
- }
- message PlayerOpt {
- PlayerOptType opt_type = 1; // 操作类型
- int32 bet_amount = 2; // 下注金额
- int64 timestamp = 3; // 操作时间戳
- repeated ReqCard seenCards = 4; // 看牌的牌
- }
- message ReqRoom {
- string Id = 1;
- repeated ReqPlayer ReqPlayers = 2;
- int32 Status = 3;
- int32 Round = 4;
- ReqGameRound GameRound = 5;
- }
- message ReqCard {
- int32 Color = 1;
- int32 Point = 2;
- }
- message ReqPlayer {
- string Id = 1;
- repeated ReqCard HandCards =2;
- optional int32 SitPos = 3;
- bool IsDealer = 4;
- }
- message ReqPlayerList {
- repeated ReqPlayer ReqPlayers = 1;
- }
- message ReqGameRound {
- repeated ReqRound Rounds = 1;
- }
- message ReqRound {
- // 回合数
- int32 round = 1;
- // 回合座位
- int32 roundSitPos = 2;
- // 回合操作
- PlayerOpt playerOpt = 3;
- // 用户id
- string userId = 4;
- }
- //error
- message MsgError {
- int32 error_code = 1;
- string error_msg = 2;
- }
- message Hello {
- string name = 1;
- }
|