十三张阶段时间可配置

This commit is contained in:
sk 2024-11-22 16:08:34 +08:00
parent 3840ec99a2
commit 196d211fff
5 changed files with 143 additions and 95 deletions

View File

@ -33,6 +33,7 @@ const (
ThirteenWaterPlayerOpStandup = 2 //站起标记
ThirteenWaterPlayerOpTest = 3 // test
ThirteenWaterPlayerOpReset = 4 // 重新选牌
ThirteenWaterPlayerJoin = 5 // 加入游戏
)
const (
ThirteenWaterSceneWaitTimeout = time.Second * 2 //等待倒计时
@ -44,6 +45,30 @@ const (
ThirteenWaterBilledTimeout = time.Second * 5 //结算
)
const (
TimeoutStart = iota
TimeoutSendCards
TimeoutOp
TimeoutBill
)
func GetTimeout(param []int64, index int) time.Duration {
if index >= 0 && index < len(param) {
return time.Duration(param[index]) * time.Second
}
switch index {
case TimeoutStart:
return ThirteenWaterStartTimeout
case TimeoutSendCards:
return ThirteenWaterSendCardsTimeout
case TimeoutOp:
return ThirteenWaterOptCardTimeout
case TimeoutBill:
return ThirteenWaterBilledTimeout
}
return time.Duration(-1)
}
func GetMaxCard(allGroup map[int]*Group) *Group {
var ret *Group
max := -1000

View File

@ -185,6 +185,10 @@ func (this *SceneEx) ThirteenWaterCreateRoomInfoPacket(s *base.Scene, p *base.Pl
LeaveDeduct: this.GetDBGameFree().GetLeaveDeduct(),
LeaveCombat: this.GetDBGameFree().GetLeaveCombat(),
Params: common.CopySliceInt64ToInt32(s.Params),
TimeOuts: this.GetDBGameFree().GetOtherIntParams(),
}
if len(pack.TimeOuts) > rule.TimeoutOp {
pack.TimeOuts[rule.TimeoutOp] = int64(this.GetBaiPai().Seconds())
}
// 玩家信息
for _, playerEx := range this.players {
@ -386,11 +390,17 @@ func (this *SceneEx) GetBaseScore() int64 { //游戏底分
}
func (this *SceneEx) GetBaiPai() time.Duration {
s := this.GetParam(rule.ParamBaiPai)
if this.IsSceneMode(common.SceneModePublic) {
second := rule.GetTimeout(this.GetDBGameFree().GetOtherIntParams(), rule.TimeoutOp) // 后台配置摆牌时间
if second > 0 {
return second
}
}
s := this.GetParam(rule.ParamBaiPai) // 自建房,摆牌时间
if s > 0 {
return time.Duration(s) * time.Second
}
return rule.ThirteenWaterOptCardTimeout
return rule.ThirteenWaterOptCardTimeout // 默认摆牌时间
}
func (this *SceneEx) HasLaiZi() bool {

View File

@ -85,13 +85,7 @@ func (this *PolicyThirteen) OnPlayerEnter(s *base.Scene, p *base.Player) {
p.Pos = pos
p.ExtraData = playerEx
playerEx.Clear()
if sceneEx.Gaming && sceneEx.GetSceneState().GetState() != rule.ThirteenWaterSceneStateSendCards &&
sceneEx.GetSceneState().GetState() != rule.ThirteenWaterSceneStateOptCard { // 发牌,理牌阶段也可以加入本局游戏
p.MarkFlag(base.PlayerState_WaitNext)
p.UnmarkFlag(base.PlayerState_Ready)
}
if sceneEx.Gaming && sceneEx.GetSceneState().GetState() == rule.ThirteenWaterSceneStateOptCard &&
int(rule.ThirteenWaterOptCardTimeout.Seconds())-s.GetSceneState().GetTimeout(s) < 15 {
if sceneEx.Gaming {
p.MarkFlag(base.PlayerState_WaitNext)
p.UnmarkFlag(base.PlayerState_Ready)
}
@ -465,6 +459,10 @@ func (this *BaseState) OnPlayerOp(s *base.Scene, p *base.Player, opcode int, par
if !ok {
return false
}
sceneEx, ok := s.ExtraData.(*SceneEx)
if !ok {
return false
}
switch opcode {
case rule.ThirteenWaterPlayerOpStandup:
@ -488,41 +486,30 @@ func (this *BaseState) OnPlayerOp(s *base.Scene, p *base.Player, opcode int, par
if !common.Config.IsDevMode {
return false
}
sceneEx, ok := s.ExtraData.(*SceneEx)
if !ok {
return false
}
sceneEx.testPokers = make([]int64, len(params))
copy(sceneEx.testPokers, params)
return true
case rule.ThirteenWaterPlayerJoin:
// 发牌和选牌阶段,给玩家发牌
if s.GetSceneState().GetState() == rule.ThirteenWaterSceneStateSendCards ||
(s.GetSceneState().GetState() == rule.ThirteenWaterSceneStateOptCard && int(sceneEx.GetBaiPai().Seconds())-sceneEx.GetSceneState().GetTimeout(s) > 15) {
if len(sceneEx.cardsArr) > 0 && playerEx.cards[0] == -1 {
playerEx.MarkFlag(base.PlayerState_Ready)
playerEx.UnmarkFlag(base.PlayerState_WaitNext)
playerEx.cards = sceneEx.cardsArr[0]
playerEx.allGroup = sceneEx.cardsGroup[0]
sceneEx.cardsArr = sceneEx.cardsArr[1:]
sceneEx.cardsGroup = sceneEx.cardsGroup[1:]
sceneEx.SendToPlayerCardsBySnid(p.SnId)
logger.Logger.Tracef("游戏开始后给玩家发牌, sceneId=%v, player=%v, cards=%v", s.GetSceneId(), p.SnId, playerEx.cards)
}
}
}
return false
}
func (this *BaseState) OnPlayerEvent(s *base.Scene, p *base.Player, evtcode int, params []int64) {
if sceneEx, ok := s.ExtraData.(*SceneEx); ok {
switch evtcode {
case base.PlayerEventLeave:
case base.PlayerEventEnter:
// 发牌和选牌阶段,给玩家发牌
if s.GetSceneState().GetState() == rule.ThirteenWaterSceneStateSendCards ||
s.GetSceneState().GetState() == rule.ThirteenWaterSceneStateOptCard {
if p.IsGameing() {
playerEx, ok := p.ExtraData.(*PlayerEx)
if ok && len(sceneEx.cardsArr) > 0 && playerEx.cards[0] == -1 {
playerEx.cards = sceneEx.cardsArr[0]
playerEx.allGroup = sceneEx.cardsGroup[0]
sceneEx.cardsArr = sceneEx.cardsArr[1:]
sceneEx.cardsGroup = sceneEx.cardsGroup[1:]
sceneEx.SendToPlayerCardsBySnid(p.SnId)
logger.Logger.Tracef("游戏开始后给玩家发牌, sceneId=%v, player=%v, cards=%v", s.GetSceneId(), p.SnId, playerEx.cards)
}
}
}
}
}
}
func (this *BaseState) OnPlayerEvent(s *base.Scene, p *base.Player, evtcode int, params []int64) {}
//=====================================
// StateWait 匹配中
@ -632,7 +619,12 @@ func (this *StateStart) OnEnter(s *base.Scene) {
func (this *StateStart) OnTick(s *base.Scene) {
this.BaseState.OnTick(s)
if sceneEx, ok := s.ExtraData.(*SceneEx); ok {
if time.Now().Sub(sceneEx.StateStartTime) > rule.ThirteenWaterStartTimeout {
var second = rule.ThirteenWaterStartTimeout
sub := rule.GetTimeout(sceneEx.GetDBGameFree().GetOtherIntParams(), rule.TimeoutStart)
if sub > 0 {
second = sub
}
if time.Now().Sub(sceneEx.StateStartTime) > second {
if sceneEx.Creator != 0 && sceneEx.GetRealPlayerNum() == 0 {
sceneEx.Destroy(true)
return
@ -765,7 +757,12 @@ func (this *StateSendCard) OnEnter(s *base.Scene) {
func (this *StateSendCard) OnTick(s *base.Scene) {
this.BaseState.OnTick(s)
if sceneEx, ok := s.ExtraData.(*SceneEx); ok {
if time.Now().Sub(sceneEx.StateStartTime) > rule.ThirteenWaterSendCardsTimeout {
var second = rule.ThirteenWaterSendCardsTimeout
sub := rule.GetTimeout(sceneEx.GetDBGameFree().GetOtherIntParams(), rule.TimeoutSendCards)
if sub > 0 {
second = sub
}
if time.Now().Sub(sceneEx.StateStartTime) > second {
if sceneEx.CheckNeedDestroy() {
s.ChangeSceneState(rule.ThirteenWaterSceneStateWait)
} else {
@ -1531,7 +1528,12 @@ func (this *StateBilled) OnPlayerOp(s *base.Scene, p *base.Player, opcode int, p
func (this *StateBilled) OnTick(s *base.Scene) {
this.BaseState.OnTick(s)
if sceneEx, ok := s.ExtraData.(*SceneEx); ok {
if time.Now().Sub(sceneEx.StateStartTime) > rule.ThirteenWaterBilledTimeout {
var second = rule.ThirteenWaterBilledTimeout
sub := rule.GetTimeout(sceneEx.GetDBGameFree().GetOtherIntParams(), rule.TimeoutBill)
if sub > 0 {
second = sub
}
if time.Now().Sub(sceneEx.StateStartTime) > second {
if sceneEx.CanStart() {
s.ChangeSceneState(rule.ThirteenWaterSceneStateStart)
} else {

View File

@ -386,7 +386,7 @@ type CSThirteenPlayerOp struct {
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
OpCode int32 `protobuf:"varint,1,opt,name=OpCode,proto3" json:"OpCode,omitempty"` // 1:确定牌 2站起状态 3test 4重新选牌
OpCode int32 `protobuf:"varint,1,opt,name=OpCode,proto3" json:"OpCode,omitempty"` // 1:确定牌 2站起状态 3test 4重新选牌 5加入游戏
// 确定牌时,两种参数规则,都可以
// 第一种玩家从推荐牌型中选择一个把Poker.IndexType发过来减少数据传输
// 第二种:按头墩中墩尾墩顺序把牌发过来
@ -924,6 +924,7 @@ type SCThirteenRoomInfo struct {
TotalOfGames int32 `protobuf:"varint,17,opt,name=TotalOfGames,proto3" json:"TotalOfGames,omitempty"` //总局数
LeaveDeduct int32 `protobuf:"varint,18,opt,name=LeaveDeduct,proto3" json:"LeaveDeduct,omitempty"` // 离场扣分倍数;玩家在发牌,选牌状态离场扣除指定倍数的底分
LeaveCombat int32 `protobuf:"varint,19,opt,name=LeaveCombat,proto3" json:"LeaveCombat,omitempty"` // 补偿倍数;玩家在发牌,选牌状态离场其它玩家补偿底分倍数
TimeOuts []int64 `protobuf:"varint,20,rep,packed,name=TimeOuts,proto3" json:"TimeOuts,omitempty"` // 游戏阶段超时时间,秒 0开始倒计时,1发牌,2选牌,3结算
}
func (x *SCThirteenRoomInfo) Reset() {
@ -1091,6 +1092,13 @@ func (x *SCThirteenRoomInfo) GetLeaveCombat() int32 {
return 0
}
func (x *SCThirteenRoomInfo) GetTimeOuts() []int64 {
if x != nil {
return x.TimeOuts
}
return nil
}
//房间状态更新
//PACKET_SCThirteenRoomState
type SCThirteenRoomState struct {
@ -1475,7 +1483,7 @@ var file_protocol_thirteen_thirteen_proto_rawDesc = []byte{
0x44, 0x61, 0x74, 0x61, 0x22, 0x29, 0x0a, 0x15, 0x53, 0x43, 0x54, 0x68, 0x69, 0x72, 0x74, 0x65,
0x65, 0x6e, 0x50, 0x6c, 0x61, 0x79, 0x65, 0x72, 0x4c, 0x65, 0x61, 0x76, 0x65, 0x12, 0x10, 0x0a,
0x03, 0x50, 0x6f, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x03, 0x50, 0x6f, 0x73, 0x22,
0xd4, 0x04, 0x0a, 0x12, 0x53, 0x43, 0x54, 0x68, 0x69, 0x72, 0x74, 0x65, 0x65, 0x6e, 0x52, 0x6f,
0xf0, 0x04, 0x0a, 0x12, 0x53, 0x43, 0x54, 0x68, 0x69, 0x72, 0x74, 0x65, 0x65, 0x6e, 0x52, 0x6f,
0x6f, 0x6d, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x16, 0x0a, 0x06, 0x52, 0x6f, 0x6f, 0x6d, 0x49, 0x64,
0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06, 0x52, 0x6f, 0x6f, 0x6d, 0x49, 0x64, 0x12, 0x18,
0x0a, 0x07, 0x43, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52,
@ -1512,59 +1520,61 @@ var file_protocol_thirteen_thirteen_proto_rawDesc = []byte{
0x74, 0x18, 0x12, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0b, 0x4c, 0x65, 0x61, 0x76, 0x65, 0x44, 0x65,
0x64, 0x75, 0x63, 0x74, 0x12, 0x20, 0x0a, 0x0b, 0x4c, 0x65, 0x61, 0x76, 0x65, 0x43, 0x6f, 0x6d,
0x62, 0x61, 0x74, 0x18, 0x13, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0b, 0x4c, 0x65, 0x61, 0x76, 0x65,
0x43, 0x6f, 0x6d, 0x62, 0x61, 0x74, 0x22, 0x43, 0x0a, 0x13, 0x53, 0x43, 0x54, 0x68, 0x69, 0x72,
0x74, 0x65, 0x65, 0x6e, 0x52, 0x6f, 0x6f, 0x6d, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x14, 0x0a,
0x05, 0x53, 0x74, 0x61, 0x74, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x53, 0x74,
0x61, 0x74, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x18, 0x02, 0x20,
0x03, 0x28, 0x05, 0x52, 0x06, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x22, 0x5a, 0x0a, 0x13, 0x53,
0x43, 0x54, 0x68, 0x69, 0x72, 0x74, 0x65, 0x65, 0x6e, 0x53, 0x68, 0x6f, 0x77, 0x43, 0x61, 0x72,
0x64, 0x73, 0x12, 0x16, 0x0a, 0x06, 0x4f, 0x70, 0x43, 0x6f, 0x64, 0x65, 0x18, 0x01, 0x20, 0x01,
0x28, 0x05, 0x52, 0x06, 0x4f, 0x70, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x2b, 0x0a, 0x08, 0x41, 0x6c,
0x6c, 0x43, 0x61, 0x72, 0x64, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0f, 0x2e, 0x74,
0x68, 0x69, 0x72, 0x74, 0x65, 0x65, 0x6e, 0x2e, 0x50, 0x6f, 0x6b, 0x65, 0x72, 0x52, 0x08, 0x41,
0x6c, 0x6c, 0x43, 0x61, 0x72, 0x64, 0x73, 0x22, 0x68, 0x0a, 0x06, 0x42, 0x69, 0x6c, 0x6c, 0x65,
0x64, 0x12, 0x10, 0x0a, 0x03, 0x50, 0x6f, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x03,
0x50, 0x6f, 0x73, 0x12, 0x12, 0x0a, 0x04, 0x43, 0x6f, 0x69, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28,
0x03, 0x52, 0x04, 0x43, 0x6f, 0x69, 0x6e, 0x12, 0x18, 0x0a, 0x07, 0x57, 0x69, 0x6e, 0x43, 0x6f,
0x69, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x07, 0x57, 0x69, 0x6e, 0x43, 0x6f, 0x69,
0x6e, 0x12, 0x1e, 0x0a, 0x0a, 0x43, 0x6f, 0x6d, 0x62, 0x61, 0x74, 0x43, 0x6f, 0x69, 0x6e, 0x18,
0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x43, 0x6f, 0x6d, 0x62, 0x61, 0x74, 0x43, 0x6f, 0x69,
0x6e, 0x22, 0x42, 0x0a, 0x10, 0x53, 0x43, 0x54, 0x68, 0x69, 0x72, 0x74, 0x65, 0x65, 0x6e, 0x42,
0x69, 0x6c, 0x6c, 0x65, 0x64, 0x12, 0x2e, 0x0a, 0x09, 0x41, 0x6c, 0x6c, 0x42, 0x69, 0x6c, 0x6c,
0x65, 0x64, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x10, 0x2e, 0x74, 0x68, 0x69, 0x72, 0x74,
0x65, 0x65, 0x6e, 0x2e, 0x42, 0x69, 0x6c, 0x6c, 0x65, 0x64, 0x52, 0x09, 0x41, 0x6c, 0x6c, 0x42,
0x69, 0x6c, 0x6c, 0x65, 0x64, 0x22, 0x24, 0x0a, 0x0e, 0x53, 0x43, 0x54, 0x68, 0x69, 0x72, 0x74,
0x65, 0x65, 0x6e, 0x54, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x44, 0x61, 0x74, 0x61, 0x18,
0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x44, 0x61, 0x74, 0x61, 0x2a, 0xee, 0x02, 0x0a, 0x0d,
0x54, 0x57, 0x4d, 0x6d, 0x6f, 0x50, 0x61, 0x63, 0x6b, 0x65, 0x74, 0x49, 0x44, 0x12, 0x18, 0x0a,
0x14, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x54, 0x48, 0x49, 0x52, 0x54, 0x45, 0x45, 0x4e,
0x5f, 0x5a, 0x45, 0x52, 0x4f, 0x10, 0x00, 0x12, 0x1e, 0x0a, 0x19, 0x50, 0x41, 0x43, 0x4b, 0x45,
0x54, 0x5f, 0x53, 0x43, 0x54, 0x68, 0x69, 0x72, 0x74, 0x65, 0x65, 0x6e, 0x52, 0x6f, 0x6f, 0x6d,
0x49, 0x6e, 0x66, 0x6f, 0x10, 0xc2, 0x2b, 0x12, 0x1e, 0x0a, 0x19, 0x50, 0x41, 0x43, 0x4b, 0x45,
0x54, 0x5f, 0x43, 0x53, 0x54, 0x68, 0x69, 0x72, 0x74, 0x65, 0x65, 0x6e, 0x50, 0x6c, 0x61, 0x79,
0x65, 0x72, 0x4f, 0x70, 0x10, 0xc3, 0x2b, 0x12, 0x1f, 0x0a, 0x1a, 0x50, 0x41, 0x43, 0x4b, 0x45,
0x54, 0x5f, 0x53, 0x43, 0x54, 0x68, 0x69, 0x72, 0x74, 0x65, 0x65, 0x6e, 0x52, 0x6f, 0x6f, 0x6d,
0x53, 0x74, 0x61, 0x74, 0x65, 0x10, 0xc4, 0x2b, 0x12, 0x21, 0x0a, 0x1c, 0x50, 0x41, 0x43, 0x4b,
0x45, 0x54, 0x5f, 0x53, 0x43, 0x54, 0x68, 0x69, 0x72, 0x74, 0x65, 0x65, 0x6e, 0x50, 0x6c, 0x61,
0x79, 0x65, 0x72, 0x45, 0x6e, 0x74, 0x65, 0x72, 0x10, 0xc5, 0x2b, 0x12, 0x21, 0x0a, 0x1c, 0x50,
0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x53, 0x43, 0x54, 0x68, 0x69, 0x72, 0x74, 0x65, 0x65, 0x6e,
0x50, 0x6c, 0x61, 0x79, 0x65, 0x72, 0x4c, 0x65, 0x61, 0x76, 0x65, 0x10, 0xc6, 0x2b, 0x12, 0x21,
0x0a, 0x1c, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x53, 0x43, 0x54, 0x68, 0x69, 0x72, 0x74,
0x65, 0x65, 0x6e, 0x50, 0x6c, 0x61, 0x79, 0x65, 0x72, 0x43, 0x61, 0x72, 0x64, 0x73, 0x10, 0xc7,
0x2b, 0x12, 0x1e, 0x0a, 0x19, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x53, 0x43, 0x54, 0x68,
0x69, 0x72, 0x74, 0x65, 0x65, 0x6e, 0x50, 0x6c, 0x61, 0x79, 0x65, 0x72, 0x4f, 0x70, 0x10, 0xc8,
0x2b, 0x12, 0x1f, 0x0a, 0x1a, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x53, 0x43, 0x54, 0x68,
0x69, 0x72, 0x74, 0x65, 0x65, 0x6e, 0x53, 0x68, 0x6f, 0x77, 0x43, 0x61, 0x72, 0x64, 0x73, 0x10,
0xc9, 0x2b, 0x12, 0x1c, 0x0a, 0x17, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x53, 0x43, 0x54,
0x68, 0x69, 0x72, 0x74, 0x65, 0x65, 0x6e, 0x42, 0x69, 0x6c, 0x6c, 0x65, 0x64, 0x10, 0xca, 0x2b,
0x12, 0x1a, 0x0a, 0x15, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x53, 0x43, 0x54, 0x68, 0x69,
0x72, 0x74, 0x65, 0x65, 0x6e, 0x54, 0x65, 0x73, 0x74, 0x10, 0xcb, 0x2b, 0x2a, 0x2f, 0x0a, 0x0c,
0x4f, 0x70, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x0f, 0x0a, 0x0b,
0x4f, 0x50, 0x52, 0x43, 0x5f, 0x53, 0x75, 0x63, 0x65, 0x73, 0x73, 0x10, 0x00, 0x12, 0x0e, 0x0a,
0x0a, 0x4f, 0x50, 0x52, 0x43, 0x5f, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x10, 0x01, 0x42, 0x28, 0x5a,
0x26, 0x6d, 0x6f, 0x6e, 0x67, 0x6f, 0x2e, 0x67, 0x61, 0x6d, 0x65, 0x73, 0x2e, 0x63, 0x6f, 0x6d,
0x2f, 0x67, 0x61, 0x6d, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x2f, 0x74,
0x68, 0x69, 0x72, 0x74, 0x65, 0x65, 0x6e, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
0x43, 0x6f, 0x6d, 0x62, 0x61, 0x74, 0x12, 0x1a, 0x0a, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x4f, 0x75,
0x74, 0x73, 0x18, 0x14, 0x20, 0x03, 0x28, 0x03, 0x52, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x4f, 0x75,
0x74, 0x73, 0x22, 0x43, 0x0a, 0x13, 0x53, 0x43, 0x54, 0x68, 0x69, 0x72, 0x74, 0x65, 0x65, 0x6e,
0x52, 0x6f, 0x6f, 0x6d, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x53, 0x74, 0x61,
0x74, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12,
0x16, 0x0a, 0x06, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x05, 0x52,
0x06, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x22, 0x5a, 0x0a, 0x13, 0x53, 0x43, 0x54, 0x68, 0x69,
0x72, 0x74, 0x65, 0x65, 0x6e, 0x53, 0x68, 0x6f, 0x77, 0x43, 0x61, 0x72, 0x64, 0x73, 0x12, 0x16,
0x0a, 0x06, 0x4f, 0x70, 0x43, 0x6f, 0x64, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06,
0x4f, 0x70, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x2b, 0x0a, 0x08, 0x41, 0x6c, 0x6c, 0x43, 0x61, 0x72,
0x64, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0f, 0x2e, 0x74, 0x68, 0x69, 0x72, 0x74,
0x65, 0x65, 0x6e, 0x2e, 0x50, 0x6f, 0x6b, 0x65, 0x72, 0x52, 0x08, 0x41, 0x6c, 0x6c, 0x43, 0x61,
0x72, 0x64, 0x73, 0x22, 0x68, 0x0a, 0x06, 0x42, 0x69, 0x6c, 0x6c, 0x65, 0x64, 0x12, 0x10, 0x0a,
0x03, 0x50, 0x6f, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x03, 0x50, 0x6f, 0x73, 0x12,
0x12, 0x0a, 0x04, 0x43, 0x6f, 0x69, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x43,
0x6f, 0x69, 0x6e, 0x12, 0x18, 0x0a, 0x07, 0x57, 0x69, 0x6e, 0x43, 0x6f, 0x69, 0x6e, 0x18, 0x03,
0x20, 0x01, 0x28, 0x03, 0x52, 0x07, 0x57, 0x69, 0x6e, 0x43, 0x6f, 0x69, 0x6e, 0x12, 0x1e, 0x0a,
0x0a, 0x43, 0x6f, 0x6d, 0x62, 0x61, 0x74, 0x43, 0x6f, 0x69, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28,
0x03, 0x52, 0x0a, 0x43, 0x6f, 0x6d, 0x62, 0x61, 0x74, 0x43, 0x6f, 0x69, 0x6e, 0x22, 0x42, 0x0a,
0x10, 0x53, 0x43, 0x54, 0x68, 0x69, 0x72, 0x74, 0x65, 0x65, 0x6e, 0x42, 0x69, 0x6c, 0x6c, 0x65,
0x64, 0x12, 0x2e, 0x0a, 0x09, 0x41, 0x6c, 0x6c, 0x42, 0x69, 0x6c, 0x6c, 0x65, 0x64, 0x18, 0x01,
0x20, 0x03, 0x28, 0x0b, 0x32, 0x10, 0x2e, 0x74, 0x68, 0x69, 0x72, 0x74, 0x65, 0x65, 0x6e, 0x2e,
0x42, 0x69, 0x6c, 0x6c, 0x65, 0x64, 0x52, 0x09, 0x41, 0x6c, 0x6c, 0x42, 0x69, 0x6c, 0x6c, 0x65,
0x64, 0x22, 0x24, 0x0a, 0x0e, 0x53, 0x43, 0x54, 0x68, 0x69, 0x72, 0x74, 0x65, 0x65, 0x6e, 0x54,
0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28,
0x09, 0x52, 0x04, 0x44, 0x61, 0x74, 0x61, 0x2a, 0xee, 0x02, 0x0a, 0x0d, 0x54, 0x57, 0x4d, 0x6d,
0x6f, 0x50, 0x61, 0x63, 0x6b, 0x65, 0x74, 0x49, 0x44, 0x12, 0x18, 0x0a, 0x14, 0x50, 0x41, 0x43,
0x4b, 0x45, 0x54, 0x5f, 0x54, 0x48, 0x49, 0x52, 0x54, 0x45, 0x45, 0x4e, 0x5f, 0x5a, 0x45, 0x52,
0x4f, 0x10, 0x00, 0x12, 0x1e, 0x0a, 0x19, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x53, 0x43,
0x54, 0x68, 0x69, 0x72, 0x74, 0x65, 0x65, 0x6e, 0x52, 0x6f, 0x6f, 0x6d, 0x49, 0x6e, 0x66, 0x6f,
0x10, 0xc2, 0x2b, 0x12, 0x1e, 0x0a, 0x19, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x43, 0x53,
0x54, 0x68, 0x69, 0x72, 0x74, 0x65, 0x65, 0x6e, 0x50, 0x6c, 0x61, 0x79, 0x65, 0x72, 0x4f, 0x70,
0x10, 0xc3, 0x2b, 0x12, 0x1f, 0x0a, 0x1a, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x53, 0x43,
0x54, 0x68, 0x69, 0x72, 0x74, 0x65, 0x65, 0x6e, 0x52, 0x6f, 0x6f, 0x6d, 0x53, 0x74, 0x61, 0x74,
0x65, 0x10, 0xc4, 0x2b, 0x12, 0x21, 0x0a, 0x1c, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x53,
0x43, 0x54, 0x68, 0x69, 0x72, 0x74, 0x65, 0x65, 0x6e, 0x50, 0x6c, 0x61, 0x79, 0x65, 0x72, 0x45,
0x6e, 0x74, 0x65, 0x72, 0x10, 0xc5, 0x2b, 0x12, 0x21, 0x0a, 0x1c, 0x50, 0x41, 0x43, 0x4b, 0x45,
0x54, 0x5f, 0x53, 0x43, 0x54, 0x68, 0x69, 0x72, 0x74, 0x65, 0x65, 0x6e, 0x50, 0x6c, 0x61, 0x79,
0x65, 0x72, 0x4c, 0x65, 0x61, 0x76, 0x65, 0x10, 0xc6, 0x2b, 0x12, 0x21, 0x0a, 0x1c, 0x50, 0x41,
0x43, 0x4b, 0x45, 0x54, 0x5f, 0x53, 0x43, 0x54, 0x68, 0x69, 0x72, 0x74, 0x65, 0x65, 0x6e, 0x50,
0x6c, 0x61, 0x79, 0x65, 0x72, 0x43, 0x61, 0x72, 0x64, 0x73, 0x10, 0xc7, 0x2b, 0x12, 0x1e, 0x0a,
0x19, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x53, 0x43, 0x54, 0x68, 0x69, 0x72, 0x74, 0x65,
0x65, 0x6e, 0x50, 0x6c, 0x61, 0x79, 0x65, 0x72, 0x4f, 0x70, 0x10, 0xc8, 0x2b, 0x12, 0x1f, 0x0a,
0x1a, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x53, 0x43, 0x54, 0x68, 0x69, 0x72, 0x74, 0x65,
0x65, 0x6e, 0x53, 0x68, 0x6f, 0x77, 0x43, 0x61, 0x72, 0x64, 0x73, 0x10, 0xc9, 0x2b, 0x12, 0x1c,
0x0a, 0x17, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x53, 0x43, 0x54, 0x68, 0x69, 0x72, 0x74,
0x65, 0x65, 0x6e, 0x42, 0x69, 0x6c, 0x6c, 0x65, 0x64, 0x10, 0xca, 0x2b, 0x12, 0x1a, 0x0a, 0x15,
0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x53, 0x43, 0x54, 0x68, 0x69, 0x72, 0x74, 0x65, 0x65,
0x6e, 0x54, 0x65, 0x73, 0x74, 0x10, 0xcb, 0x2b, 0x2a, 0x2f, 0x0a, 0x0c, 0x4f, 0x70, 0x52, 0x65,
0x73, 0x75, 0x6c, 0x74, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x0f, 0x0a, 0x0b, 0x4f, 0x50, 0x52, 0x43,
0x5f, 0x53, 0x75, 0x63, 0x65, 0x73, 0x73, 0x10, 0x00, 0x12, 0x0e, 0x0a, 0x0a, 0x4f, 0x50, 0x52,
0x43, 0x5f, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x10, 0x01, 0x42, 0x28, 0x5a, 0x26, 0x6d, 0x6f, 0x6e,
0x67, 0x6f, 0x2e, 0x67, 0x61, 0x6d, 0x65, 0x73, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x67, 0x61, 0x6d,
0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x2f, 0x74, 0x68, 0x69, 0x72, 0x74,
0x65, 0x65, 0x6e, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
}
var (

View File

@ -73,7 +73,7 @@ message SCThirteenPlayerCards {
//
//PACKET_CSThirteenPlayerOp
message CSThirteenPlayerOp {
int32 OpCode = 1; // 1: 2 3test 4
int32 OpCode = 1; // 1: 2 3test 4 5
// ,
// Poker.IndexType发过来
@ -164,6 +164,7 @@ message SCThirteenRoomInfo {
int32 TotalOfGames = 17; //
int32 LeaveDeduct = 18; //
int32 LeaveCombat = 19; //
repeated int64 TimeOuts = 20; // , 0,1,2,3
}
//