Compare commits

...

5 Commits

Author SHA1 Message Date
sk 699596d022 update public 2024-06-11 11:35:22 +08:00
sk ceac412a25 比赛类型列表 2024-06-11 11:23:43 +08:00
sk 4ec8d6bc22 mongodb索引优化 2024-06-11 09:13:31 +08:00
sk c72b74824e 修改邀请绑定数量 2024-06-11 09:13:31 +08:00
sk 41361621ef 比赛日志用开始比赛时备份的配置不能用最新配置 2024-06-11 09:13:31 +08:00
22 changed files with 913 additions and 563 deletions

View File

@ -22,5 +22,6 @@
"RobotInviteIntervalMax": 1,
"ClosePreCreateRoom": true,
"AgoraAddress": "http://47.105.78.29:8081",
"InviteUrl": "http://47.105.78.29:8000/"
"InviteUrl": "http://47.105.78.29:8000/",
"RankTimeout": 5
}

View File

@ -13,6 +13,7 @@ import (
"mongo.games.com/game/dbproxy/svc"
"mongo.games.com/game/model"
"mongo.games.com/game/mq"
rankproto "mongo.games.com/game/protocol/rank"
)
var InviteNumCache = cache.NewMemoryCache()
@ -44,7 +45,7 @@ func init() {
if n > 0 {
n++
} else {
n, err = svc.GetInviteNum(log.Platform, log.InviteSnId)
n, err = svc.GetInviteNum(log.Platform, log.InviteSnId, int32(rankproto.RankInvite_InviteType_Total))
if err != nil {
logger.Logger.Errorf("BindInviteSnId error:%v", err)
return err

View File

@ -30,6 +30,7 @@ func CoinLogsCollection(plt string) *mongo.Collection {
c_coinlogrec.EnsureIndex(mgo.Index{Key: []string{"seqno"}, Background: true, Sparse: true})
c_coinlogrec.EnsureIndex(mgo.Index{Key: []string{"gamefreeid"}, Background: true, Sparse: true})
c_coinlogrec.EnsureIndex(mgo.Index{Key: []string{"cointype"}, Background: true, Sparse: true})
c_coinlogrec.EnsureIndex(mgo.Index{Key: []string{"-ts"}, Background: true, Sparse: true})
c_coinlogrec.EnsureIndex(mgo.Index{Key: []string{"ts"}, Background: true, Sparse: true})
}
return c_coinlogrec

View File

@ -22,7 +22,10 @@ func GameDetailedLogsCollection(plt string) *mongo.Collection {
c_gamedetailed.EnsureIndex(mgo.Index{Key: []string{"gamefreeid"}, Background: true, Sparse: true})
c_gamedetailed.EnsureIndex(mgo.Index{Key: []string{"logid"}, Background: true, Sparse: true})
c_gamedetailed.EnsureIndex(mgo.Index{Key: []string{"time"}, Background: true, Sparse: true})
c_gamedetailed.EnsureIndex(mgo.Index{Key: []string{"-time"}, Background: true, Sparse: true})
c_gamedetailed.EnsureIndex(mgo.Index{Key: []string{"ts"}, Background: true, Sparse: true})
c_gamedetailed.EnsureIndex(mgo.Index{Key: []string{"-ts"}, Background: true, Sparse: true})
c_gamedetailed.EnsureIndex(mgo.Index{Key: []string{"matchid"}, Background: true, Sparse: true})
}
return c_gamedetailed
}

View File

@ -31,8 +31,12 @@ func GamePlayerListLogsCollection(plt string) *mongo.Collection {
c_gameplayerlistlog.EnsureIndex(mgo.Index{Key: []string{"gamefreeid"}, Background: true, Sparse: true})
c_gameplayerlistlog.EnsureIndex(mgo.Index{Key: []string{"gamedetailedlogid"}, Background: true, Sparse: true})
c_gameplayerlistlog.EnsureIndex(mgo.Index{Key: []string{"ts"}, Background: true, Sparse: true})
c_gameplayerlistlog.EnsureIndex(mgo.Index{Key: []string{"-ts"}, Background: true, Sparse: true})
c_gameplayerlistlog.EnsureIndex(mgo.Index{Key: []string{"time"}, Background: true, Sparse: true})
c_gameplayerlistlog.EnsureIndex(mgo.Index{Key: []string{"-time"}, Background: true, Sparse: true})
c_gameplayerlistlog.EnsureIndex(mgo.Index{Key: []string{"name"}, Background: true, Sparse: true})
c_gameplayerlistlog.EnsureIndex(mgo.Index{Key: []string{"matchid"}, Background: true, Sparse: true})
c_gameplayerlistlog.EnsureIndex(mgo.Index{Key: []string{"matchtype"}, Background: true, Sparse: true})
}
return c_gameplayerlistlog
}

View File

@ -14,7 +14,13 @@ func ItemLogsCollection(plt string) *mongo.Collection {
c_itemlog, first := s.DB().C(model.ItemLogCollName)
if first {
c_itemlog.EnsureIndex(mgo.Index{Key: []string{"snid"}, Background: true, Sparse: true})
c_itemlog.EnsureIndex(mgo.Index{Key: []string{"platform"}, Background: true, Sparse: true})
c_itemlog.EnsureIndex(mgo.Index{Key: []string{"logtype"}, Background: true, Sparse: true})
c_itemlog.EnsureIndex(mgo.Index{Key: []string{"itemid"}, Background: true, Sparse: true})
c_itemlog.EnsureIndex(mgo.Index{Key: []string{"createts"}, Background: true, Sparse: true})
c_itemlog.EnsureIndex(mgo.Index{Key: []string{"-createts"}, Background: true, Sparse: true})
c_itemlog.EnsureIndex(mgo.Index{Key: []string{"typeid"}, Background: true, Sparse: true})
c_itemlog.EnsureIndex(mgo.Index{Key: []string{"gameid"}, Background: true, Sparse: true})
c_itemlog.EnsureIndex(mgo.Index{Key: []string{"gamefreeid"}, Background: true, Sparse: true})
}
return c_itemlog
}

View File

@ -22,6 +22,12 @@ func MatchLogCollection(plt string) *mongo.Collection {
c, first := s.DB().C(model.MatchLogCollName)
if first {
c.EnsureIndex(mgo.Index{Key: []string{"gamefreeid"}, Background: true, Sparse: true})
c.EnsureIndex(mgo.Index{Key: []string{"matchid"}, Background: true, Sparse: true})
c.EnsureIndex(mgo.Index{Key: []string{"starttime"}, Background: true, Sparse: true})
c.EnsureIndex(mgo.Index{Key: []string{"-starttime"}, Background: true, Sparse: true})
c.EnsureIndex(mgo.Index{Key: []string{"endtime"}, Background: true, Sparse: true})
c.EnsureIndex(mgo.Index{Key: []string{"-endtime"}, Background: true, Sparse: true})
c.EnsureIndex(mgo.Index{Key: []string{"sortid"}, Background: true, Sparse: true})
}
return c
}

View File

@ -30,6 +30,7 @@ func InviteScoreCollection(plt string) *mongo.Collection {
c.EnsureIndex(mgo.Index{Key: []string{"invitesnid"}, Background: true, Sparse: true})
c.EnsureIndex(mgo.Index{Key: []string{"tp"}, Background: true, Sparse: true})
c.EnsureIndex(mgo.Index{Key: []string{"ts"}, Background: true, Sparse: true})
c.EnsureIndex(mgo.Index{Key: []string{"-ts"}, Background: true, Sparse: true})
c.EnsureIndex(mgo.Index{Key: []string{"weekindex"}, Background: true, Sparse: true})
c.EnsureIndex(mgo.Index{Key: []string{"monthindex"}, Background: true, Sparse: true})
}
@ -269,7 +270,7 @@ func (b *BindScoreSvc) GetInviteRankList(req *model.FindPlayerRankInviteListArgs
}
RankInvite.ModId = int32(roleId)
RankInvite.InviteNum, _ = GetInviteNum(req.Platform, inviteInfo.InviteSnId)
RankInvite.InviteNum, _ = GetInviteNum(req.Platform, inviteInfo.InviteSnId, req.RankType)
ret.List = append(ret.List, &RankInvite)
break
@ -282,6 +283,86 @@ func (b *BindScoreSvc) GetInviteRankList(req *model.FindPlayerRankInviteListArgs
return nil
}
func (b *BindScoreSvc) GetInviteScoreByType(req *model.FindPlayerRankInviteScoreArgs, ret *model.FindPlayerRankInviteScoreReply) error {
c := InviteScoreCollection(req.Platform)
if c == nil {
return InviteScoreColError
}
matchParam := bson.M{
"invitesnid": req.SnId,
"score": bson.M{"$gt": 0},
}
now := time.Now().Local()
startTime := now.AddDate(-100, 0, 0).UnixNano()
year, month, day := now.Date()
today := time.Date(year, month, day, 0, 0, 0, 0, time.Local)
if req.RankType == int32(rankproto.RankInvite_InviteType_Week) {
// 本周起始日期(周日)
matchParam["weekindex"] = today.AddDate(0, 0, -int(today.Weekday())).Unix()
} else if req.RankType == int32(rankproto.RankInvite_InviteType_Month) {
// 本月起始日期
matchParam["monthindex"] = time.Date(year, month, 1, 0, 0, 0, 0, time.Local).Unix()
} else {
matchParam["ts"] = bson.M{"$gte": startTime, "$lte": now.UnixNano()}
}
type M struct {
InviteSnId int32 // 邀请人id
Score int64 // 积分
}
var tc []M
err := c.Pipe([]bson.M{
{"$match": matchParam},
{"$group": bson.M{
"_id": nil,
"invitesnid": bson.M{"$first": "$invitesnid"},
"score": bson.M{"$sum": "$score"},
}},
}).AllowDiskUse().All(&tc)
if err != nil {
logger.Logger.Error("GetInviteScoreByType z AllowDiskUse is error", err)
return err
}
type PInfo struct {
SnId int32
Name string // 昵称
Roles *model.RolePetInfo
}
var retPlayer PInfo
u := PlayerDataCollection(req.Platform)
if u == nil {
return err
}
err = u.Find(bson.M{"snid": req.SnId}).Select(bson.M{"snid": 1, "name": 1, "roles": 1}).One(&retPlayer)
if err != nil {
logger.Logger.Error("svc.GetInviteScoreByType is error", err)
return nil
}
var rankInvite model.PlayerRankInvite
rankInvite.Name = retPlayer.Name
if len(tc) > 0 {
rankInvite.Score = tc[0].Score
}
rankInvite.SnId = req.SnId
// 头像模型ID
roleId := common.DefaultRoleId
if retPlayer.Roles != nil {
roleId = int(retPlayer.Roles.ModId)
}
rankInvite.ModId = int32(roleId)
rankInvite.InviteNum, _ = GetInviteNum(req.Platform, req.SnId, req.RankType)
ret.Data = rankInvite
ret.RankType = req.RankType
return nil
}
func (b *BindScoreSvc) GetInviteList(req *model.InviteLisArgs, ret *model.InviteListRet) error {
c := InviteScoreCollection(req.Platform)
if c == nil {

View File

@ -18,6 +18,10 @@ func MessageCollection(plt string) *mongo.Collection {
if first {
c.EnsureIndex(mgo.Index{Key: []string{"snid"}, Background: true, Sparse: true})
c.EnsureIndex(mgo.Index{Key: []string{"state"}, Background: true, Sparse: true})
c.EnsureIndex(mgo.Index{Key: []string{"mtype"}, Background: true, Sparse: true})
c.EnsureIndex(mgo.Index{Key: []string{"srcid"}, Background: true, Sparse: true})
c.EnsureIndex(mgo.Index{Key: []string{"-creatts"}, Background: true, Sparse: true})
c.EnsureIndex(mgo.Index{Key: []string{"creatts"}, Background: true, Sparse: true})
}
return c
}

View File

@ -12,13 +12,16 @@ import (
"time"
"mongo.games.com/goserver/core/basic"
"mongo.games.com/goserver/core/logger"
"mongo.games.com/goserver/core/task"
"github.com/globalsign/mgo"
"github.com/globalsign/mgo/bson"
"mongo.games.com/game/common"
"mongo.games.com/game/dbproxy/mongo"
"mongo.games.com/game/model"
"mongo.games.com/goserver/core/logger"
rankproto "mongo.games.com/game/protocol/rank"
)
var (
@ -37,13 +40,12 @@ func PlayerDataCollection(plt string) *mongo.Collection {
c_playerdata.EnsureIndex(mgo.Index{Key: []string{"snid"}, Unique: true, Background: true, Sparse: true})
c_playerdata.EnsureIndex(mgo.Index{Key: []string{"channel"}, Background: true, Sparse: true})
c_playerdata.EnsureIndex(mgo.Index{Key: []string{"tel"}, Background: true, Sparse: true})
c_playerdata.EnsureIndex(mgo.Index{Key: []string{"bankaccount"}, Background: true, Sparse: true})
c_playerdata.EnsureIndex(mgo.Index{Key: []string{"alipayaccount"}, Background: true, Sparse: true})
c_playerdata.EnsureIndex(mgo.Index{Key: []string{"alipayaccname"}, Background: true, Sparse: true})
c_playerdata.EnsureIndex(mgo.Index{Key: []string{"bankaccname"}, Background: true, Sparse: true})
c_playerdata.EnsureIndex(mgo.Index{Key: []string{"invitecode"}, Background: true, Sparse: true})
c_playerdata.EnsureIndex(mgo.Index{Key: []string{"invitesnid"}, Background: true, Sparse: true})
c_playerdata.EnsureIndex(mgo.Index{Key: []string{"name"}, Background: true, Sparse: true})
c_playerdata.EnsureIndex(mgo.Index{Key: []string{"createtime"}, Background: true, Sparse: true})
c_playerdata.EnsureIndex(mgo.Index{Key: []string{"-createtime"}, Background: true, Sparse: true})
c_playerdata.EnsureIndex(mgo.Index{Key: []string{"othercode"}, Background: true, Sparse: true})
}
return c_playerdata
}
@ -1509,7 +1511,7 @@ func (svc *PlayerDataSvc) GetPlayerInviteSnid(req *model.PlayerIsExistBySnIdArgs
}
func (svc *PlayerDataSvc) GetInviteNum(req *model.PlayerIsExistBySnIdArgs, resp *int32) error {
n, err := GetInviteNum(req.Plt, req.SnId)
n, err := GetInviteNum(req.Plt, req.SnId, int32(rankproto.RankInvite_InviteType_Total))
if err != nil {
return err
}
@ -1517,15 +1519,43 @@ func (svc *PlayerDataSvc) GetInviteNum(req *model.PlayerIsExistBySnIdArgs, resp
return nil
}
func GetInviteNum(platform string, snId int32) (int32, error) {
c := PlayerDataCollection(platform)
if c == nil {
return 0, PlayerColError
}
func GetInviteNum(platform string, snId int32, rankType int32) (int32, error) {
var err error
var n int
switch rankType {
case int32(rankproto.RankInvite_InviteType_Week), int32(rankproto.RankInvite_InviteType_Month):
matchParam := bson.M{
"invitesnid": snId,
"tp": common.InviteScoreTypeBind,
}
now := time.Now().Local()
year, month, day := now.Date()
today := time.Date(year, month, day, 0, 0, 0, 0, time.Local)
if rankType == int32(rankproto.RankInvite_InviteType_Week) {
// 本周起始日期(周日)
matchParam["weekindex"] = today.AddDate(0, 0, -int(today.Weekday())).Unix()
} else if rankType == int32(rankproto.RankInvite_InviteType_Month) {
// 本月起始日期
matchParam["monthindex"] = time.Date(year, month, 1, 0, 0, 0, 0, time.Local).Unix()
}
c := InviteScoreCollection(platform)
if c == nil {
return 0, InviteScoreColError
}
n, err = c.Find(matchParam).Count()
if err != nil {
return 0, err
}
n, err := c.Find(bson.M{"invitesnid": snId}).Count()
if err != nil {
return 0, err
default:
c := PlayerDataCollection(platform)
if c == nil {
return 0, PlayerColError
}
n, err = c.Find(bson.M{"invitesnid": snId}).Count()
if err != nil {
return 0, err
}
}
return int32(n), nil

View File

@ -17,6 +17,7 @@ const (
ETCDKEY_GAME_NOTICE = "/game/common_notice"
ETCDKEY_SHOP_ITEM = "/game/item_shop"
ETCDKEY_GAME_MATCH = "/game/game_match"
ETCDKEY_GAME_MATCH_TYPE = "/game/match_type"
ETCDKEY_ACT_TURNPLATE = "/game/act_turnplate"
ETCDKEY_ACT_7SIGN = "/game/act_7sign"
ETCDKEY_ACT_BLINDBOX = "/game/act_blindbox"

View File

@ -38,6 +38,7 @@ type MatchLog struct {
StartTime time.Time //开始时间
EndTime time.Time //结束时间
Players []*MatchPlayer //参赛人员数据
SortId int64 // 本场id
}
var (

View File

@ -154,6 +154,32 @@ func FindPlayerRankInviteList(args *FindPlayerRankInviteListArgs) (*FindPlayerRa
return ret, nil
}
type FindPlayerRankInviteScoreArgs struct {
Platform string
RankType int32 // 邀请榜时间类型: 总榜 周榜 月榜
SnId int32
}
type FindPlayerRankInviteScoreReply struct {
RankType int32 // 邀请榜时间类型: 总榜 周榜 月榜
Data PlayerRankInvite
}
func FindPlayerRankInviteScoreType(args *FindPlayerRankInviteScoreArgs) (*FindPlayerRankInviteScoreReply, error) {
if rpcCli == nil {
logger.Logger.Error("model.FindPlayerRankInviteScoreType rpcCli == nil")
return nil, nil
}
ret := new(FindPlayerRankInviteScoreReply)
err := rpcCli.CallWithTimeout("BindScoreSvc.GetInviteScoreByType", args, ret, time.Second*30)
if err != nil {
logger.Logger.Error("FindPlayerRankInviteScoreType error:", err)
return ret, err
}
return ret, nil
}
type WinCoinInfo struct {
SnId int32
Name string

View File

@ -586,7 +586,8 @@ type SCTMInfos struct {
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
TMInfo []*TMInfo `protobuf:"bytes,1,rep,name=TMInfo,proto3" json:"TMInfo,omitempty"` //比赛场场次信息
TMInfo []*TMInfo `protobuf:"bytes,1,rep,name=TMInfo,proto3" json:"TMInfo,omitempty"` //比赛场场次信息
TypeList []int32 `protobuf:"varint,2,rep,packed,name=TypeList,proto3" json:"TypeList,omitempty"` // 所有玩法类型 1.锦标赛 2.实物赛 3.vip比赛 4.话费赛
}
func (x *SCTMInfos) Reset() {
@ -628,6 +629,13 @@ func (x *SCTMInfos) GetTMInfo() []*TMInfo {
return nil
}
func (x *SCTMInfos) GetTypeList() []int32 {
if x != nil {
return x.TypeList
}
return nil
}
//单场次排行榜
//PACKET_TM_CSTMRankList
type CSTMRankList struct {
@ -1656,144 +1664,146 @@ var file_tournament_proto_rawDesc = []byte{
0x12, 0x16, 0x0a, 0x06, 0x53, 0x6f, 0x72, 0x74, 0x49, 0x64, 0x18, 0x14, 0x20, 0x01, 0x28, 0x05,
0x52, 0x06, 0x53, 0x6f, 0x72, 0x74, 0x49, 0x64, 0x12, 0x24, 0x0a, 0x0d, 0x4f, 0x6e, 0x43, 0x68,
0x61, 0x6e, 0x6e, 0x65, 0x6c, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x15, 0x20, 0x03, 0x28, 0x09, 0x52,
0x0d, 0x4f, 0x6e, 0x43, 0x68, 0x61, 0x6e, 0x6e, 0x65, 0x6c, 0x4e, 0x61, 0x6d, 0x65, 0x22, 0x37,
0x0d, 0x4f, 0x6e, 0x43, 0x68, 0x61, 0x6e, 0x6e, 0x65, 0x6c, 0x4e, 0x61, 0x6d, 0x65, 0x22, 0x53,
0x0a, 0x09, 0x53, 0x43, 0x54, 0x4d, 0x49, 0x6e, 0x66, 0x6f, 0x73, 0x12, 0x2a, 0x0a, 0x06, 0x54,
0x4d, 0x49, 0x6e, 0x66, 0x6f, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x12, 0x2e, 0x74, 0x6f,
0x75, 0x72, 0x6e, 0x61, 0x6d, 0x65, 0x6e, 0x74, 0x2e, 0x54, 0x4d, 0x49, 0x6e, 0x66, 0x6f, 0x52,
0x06, 0x54, 0x4d, 0x49, 0x6e, 0x66, 0x6f, 0x22, 0x22, 0x0a, 0x0c, 0x43, 0x53, 0x54, 0x4d, 0x52,
0x61, 0x6e, 0x6b, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x4d, 0x49, 0x64, 0x18,
0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x04, 0x54, 0x4d, 0x49, 0x64, 0x22, 0x5a, 0x0a, 0x06, 0x54,
0x4d, 0x52, 0x61, 0x6e, 0x6b, 0x12, 0x16, 0x0a, 0x06, 0x52, 0x61, 0x6e, 0x6b, 0x49, 0x64, 0x18,
0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06, 0x52, 0x61, 0x6e, 0x6b, 0x49, 0x64, 0x12, 0x1a, 0x0a,
0x08, 0x52, 0x61, 0x6e, 0x6b, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52,
0x08, 0x52, 0x61, 0x6e, 0x6b, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x57, 0x69, 0x6e,
0x6e, 0x65, 0x72, 0x4e, 0x75, 0x6d, 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x09, 0x57, 0x69,
0x6e, 0x6e, 0x65, 0x72, 0x4e, 0x75, 0x6d, 0x22, 0x6c, 0x0a, 0x0c, 0x53, 0x43, 0x54, 0x4d, 0x52,
0x61, 0x6e, 0x6b, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x4d, 0x49, 0x64, 0x18,
0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x04, 0x54, 0x4d, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x54,
0x69, 0x6d, 0x65, 0x52, 0x61, 0x6e, 0x67, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09,
0x54, 0x69, 0x6d, 0x65, 0x52, 0x61, 0x6e, 0x67, 0x65, 0x12, 0x2a, 0x0a, 0x06, 0x54, 0x4d, 0x52,
0x61, 0x6e, 0x6b, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x12, 0x2e, 0x74, 0x6f, 0x75, 0x72,
0x6e, 0x61, 0x6d, 0x65, 0x6e, 0x74, 0x2e, 0x54, 0x4d, 0x52, 0x61, 0x6e, 0x6b, 0x52, 0x06, 0x54,
0x4d, 0x52, 0x61, 0x6e, 0x6b, 0x22, 0x38, 0x0a, 0x0a, 0x43, 0x53, 0x53, 0x69, 0x67, 0x6e, 0x52,
0x61, 0x63, 0x65, 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, 0x12, 0x0a, 0x04, 0x54,
0x4d, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x04, 0x54, 0x4d, 0x49, 0x64, 0x22,
0x64, 0x0a, 0x0a, 0x53, 0x43, 0x53, 0x69, 0x67, 0x6e, 0x52, 0x61, 0x63, 0x65, 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, 0x18, 0x0a, 0x07, 0x52, 0x65, 0x74, 0x43, 0x6f, 0x64, 0x65,
0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x52, 0x65, 0x74, 0x43, 0x6f, 0x64, 0x65, 0x12,
0x24, 0x0a, 0x0d, 0x57, 0x61, 0x69, 0x74, 0x53, 0x74, 0x61, 0x72, 0x74, 0x54, 0x69, 0x6d, 0x65,
0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0d, 0x57, 0x61, 0x69, 0x74, 0x53, 0x74, 0x61, 0x72,
0x74, 0x54, 0x69, 0x6d, 0x65, 0x22, 0x49, 0x0a, 0x0d, 0x53, 0x43, 0x53, 0x79, 0x6e, 0x63, 0x53,
0x69, 0x67, 0x6e, 0x4e, 0x75, 0x6d, 0x12, 0x18, 0x0a, 0x07, 0x53, 0x69, 0x67, 0x6e, 0x4e, 0x75,
0x6d, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x53, 0x69, 0x67, 0x6e, 0x4e, 0x75, 0x6d,
0x12, 0x1e, 0x0a, 0x0a, 0x4d, 0x61, 0x78, 0x53, 0x69, 0x67, 0x6e, 0x4e, 0x75, 0x6d, 0x18, 0x02,
0x20, 0x01, 0x28, 0x05, 0x52, 0x0a, 0x4d, 0x61, 0x78, 0x53, 0x69, 0x67, 0x6e, 0x4e, 0x75, 0x6d,
0x22, 0x25, 0x0a, 0x09, 0x53, 0x43, 0x54, 0x4d, 0x53, 0x74, 0x61, 0x72, 0x74, 0x12, 0x18, 0x0a,
0x07, 0x4d, 0x61, 0x74, 0x63, 0x68, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07,
0x4d, 0x61, 0x74, 0x63, 0x68, 0x49, 0x64, 0x22, 0x6b, 0x0a, 0x09, 0x52, 0x61, 0x6e, 0x6b, 0x41,
0x77, 0x61, 0x72, 0x64, 0x12, 0x30, 0x0a, 0x08, 0x49, 0x74, 0x65, 0x6d, 0x49, 0x6e, 0x66, 0x6f,
0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x14, 0x2e, 0x74, 0x6f, 0x75, 0x72, 0x6e, 0x61, 0x6d,
0x65, 0x6e, 0x74, 0x2e, 0x49, 0x74, 0x65, 0x6d, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x08, 0x49, 0x74,
0x65, 0x6d, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x12, 0x0a, 0x04, 0x43, 0x6f, 0x69, 0x6e, 0x18, 0x02,
0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x43, 0x6f, 0x69, 0x6e, 0x12, 0x18, 0x0a, 0x07, 0x44, 0x69,
0x61, 0x6d, 0x6f, 0x6e, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x07, 0x44, 0x69, 0x61,
0x6d, 0x6f, 0x6e, 0x64, 0x22, 0x88, 0x03, 0x0a, 0x0f, 0x53, 0x43, 0x50, 0x72, 0x6f, 0x6d, 0x6f,
0x74, 0x69, 0x6f, 0x6e, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x18, 0x0a, 0x07, 0x52, 0x65, 0x74, 0x43,
0x6f, 0x64, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x52, 0x65, 0x74, 0x43, 0x6f,
0x64, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x6f, 0x75, 0x6e, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28,
0x05, 0x52, 0x05, 0x52, 0x6f, 0x75, 0x6e, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x52, 0x6f, 0x75, 0x6e,
0x64, 0x43, 0x6f, 0x69, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x09, 0x52, 0x6f, 0x75,
0x6e, 0x64, 0x43, 0x6f, 0x69, 0x6e, 0x12, 0x16, 0x0a, 0x06, 0x52, 0x61, 0x6e, 0x6b, 0x49, 0x64,
0x18, 0x04, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06, 0x52, 0x61, 0x6e, 0x6b, 0x49, 0x64, 0x12, 0x3f,
0x0a, 0x06, 0x52, 0x65, 0x63, 0x6f, 0x72, 0x64, 0x18, 0x05, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x27,
0x2e, 0x74, 0x6f, 0x75, 0x72, 0x6e, 0x61, 0x6d, 0x65, 0x6e, 0x74, 0x2e, 0x53, 0x43, 0x50, 0x72,
0x6f, 0x6d, 0x6f, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x6e, 0x66, 0x6f, 0x2e, 0x52, 0x65, 0x63, 0x6f,
0x72, 0x64, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x06, 0x52, 0x65, 0x63, 0x6f, 0x72, 0x64, 0x12,
0x18, 0x0a, 0x07, 0x4d, 0x61, 0x74, 0x63, 0x68, 0x49, 0x64, 0x18, 0x06, 0x20, 0x01, 0x28, 0x05,
0x52, 0x07, 0x4d, 0x61, 0x74, 0x63, 0x68, 0x49, 0x64, 0x12, 0x26, 0x0a, 0x0e, 0x4d, 0x61, 0x74,
0x63, 0x68, 0x50, 0x72, 0x6f, 0x6d, 0x6f, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x07, 0x20, 0x03, 0x28,
0x05, 0x52, 0x0e, 0x4d, 0x61, 0x74, 0x63, 0x68, 0x50, 0x72, 0x6f, 0x6d, 0x6f, 0x74, 0x69, 0x6f,
0x6e, 0x12, 0x33, 0x0a, 0x09, 0x52, 0x61, 0x6e, 0x6b, 0x41, 0x77, 0x61, 0x72, 0x64, 0x18, 0x08,
0x20, 0x01, 0x28, 0x0b, 0x32, 0x15, 0x2e, 0x74, 0x6f, 0x75, 0x72, 0x6e, 0x61, 0x6d, 0x65, 0x6e,
0x74, 0x2e, 0x52, 0x61, 0x6e, 0x6b, 0x41, 0x77, 0x61, 0x72, 0x64, 0x52, 0x09, 0x52, 0x61, 0x6e,
0x6b, 0x41, 0x77, 0x61, 0x72, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x4d, 0x61, 0x74, 0x63, 0x68, 0x4e,
0x61, 0x6d, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x4d, 0x61, 0x74, 0x63, 0x68,
0x4e, 0x61, 0x6d, 0x65, 0x1a, 0x39, 0x0a, 0x0b, 0x52, 0x65, 0x63, 0x6f, 0x72, 0x64, 0x45, 0x6e,
0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05,
0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02,
0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x22,
0x10, 0x0a, 0x0e, 0x43, 0x53, 0x54, 0x4d, 0x53, 0x65, 0x61, 0x73, 0x6f, 0x6e, 0x49, 0x6e, 0x66,
0x6f, 0x22, 0x8c, 0x01, 0x0a, 0x0e, 0x53, 0x43, 0x54, 0x4d, 0x53, 0x65, 0x61, 0x73, 0x6f, 0x6e,
0x49, 0x6e, 0x66, 0x6f, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05,
0x52, 0x02, 0x49, 0x64, 0x12, 0x28, 0x0a, 0x0f, 0x53, 0x65, 0x61, 0x73, 0x6f, 0x6e, 0x54, 0x69,
0x6d, 0x65, 0x53, 0x74, 0x61, 0x6d, 0x70, 0x18, 0x02, 0x20, 0x03, 0x28, 0x03, 0x52, 0x0f, 0x53,
0x65, 0x61, 0x73, 0x6f, 0x6e, 0x54, 0x69, 0x6d, 0x65, 0x53, 0x74, 0x61, 0x6d, 0x70, 0x12, 0x0e,
0x0a, 0x02, 0x4c, 0x76, 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x02, 0x4c, 0x76, 0x12, 0x16,
0x0a, 0x06, 0x4c, 0x61, 0x73, 0x74, 0x4c, 0x76, 0x18, 0x04, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06,
0x4c, 0x61, 0x73, 0x74, 0x4c, 0x76, 0x12, 0x18, 0x0a, 0x07, 0x49, 0x73, 0x41, 0x77, 0x61, 0x72,
0x64, 0x18, 0x05, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x49, 0x73, 0x41, 0x77, 0x61, 0x72, 0x64,
0x22, 0x58, 0x0a, 0x0a, 0x53, 0x65, 0x61, 0x73, 0x6f, 0x6e, 0x52, 0x61, 0x6e, 0x6b, 0x12, 0x12,
0x0a, 0x04, 0x53, 0x6e, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x04, 0x53, 0x6e,
0x69, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09,
0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x0e, 0x0a, 0x02, 0x4c, 0x76, 0x18, 0x03, 0x20, 0x01,
0x28, 0x05, 0x52, 0x02, 0x4c, 0x76, 0x12, 0x12, 0x0a, 0x04, 0x52, 0x61, 0x6e, 0x6b, 0x18, 0x04,
0x20, 0x01, 0x28, 0x05, 0x52, 0x04, 0x52, 0x61, 0x6e, 0x6b, 0x22, 0x10, 0x0a, 0x0e, 0x43, 0x53,
0x54, 0x4d, 0x53, 0x65, 0x61, 0x73, 0x6f, 0x6e, 0x52, 0x61, 0x6e, 0x6b, 0x22, 0x4a, 0x0a, 0x0e,
0x53, 0x43, 0x54, 0x4d, 0x53, 0x65, 0x61, 0x73, 0x6f, 0x6e, 0x52, 0x61, 0x6e, 0x6b, 0x12, 0x38,
0x0a, 0x0b, 0x52, 0x65, 0x61, 0x73, 0x6f, 0x6e, 0x52, 0x61, 0x6e, 0x6b, 0x73, 0x18, 0x06, 0x20,
0x03, 0x28, 0x0b, 0x32, 0x16, 0x2e, 0x74, 0x6f, 0x75, 0x72, 0x6e, 0x61, 0x6d, 0x65, 0x6e, 0x74,
0x2e, 0x53, 0x65, 0x61, 0x73, 0x6f, 0x6e, 0x52, 0x61, 0x6e, 0x6b, 0x52, 0x0b, 0x52, 0x65, 0x61,
0x73, 0x6f, 0x6e, 0x52, 0x61, 0x6e, 0x6b, 0x73, 0x22, 0x21, 0x0a, 0x0f, 0x43, 0x53, 0x54, 0x4d,
0x53, 0x65, 0x61, 0x73, 0x6f, 0x6e, 0x41, 0x77, 0x61, 0x72, 0x64, 0x12, 0x0e, 0x0a, 0x02, 0x4c,
0x76, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x02, 0x4c, 0x76, 0x22, 0x35, 0x0a, 0x0f, 0x53,
0x43, 0x54, 0x4d, 0x53, 0x65, 0x61, 0x73, 0x6f, 0x6e, 0x41, 0x77, 0x61, 0x72, 0x64, 0x12, 0x0e,
0x0a, 0x02, 0x4c, 0x76, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x02, 0x4c, 0x76, 0x12, 0x12,
0x0a, 0x04, 0x43, 0x6f, 0x64, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x04, 0x43, 0x6f,
0x64, 0x65, 0x2a, 0xd9, 0x03, 0x0a, 0x0c, 0x54, 0x4f, 0x55, 0x52, 0x4e, 0x41, 0x4d, 0x45, 0x4e,
0x54, 0x49, 0x44, 0x12, 0x12, 0x0a, 0x0e, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x54, 0x4d,
0x5f, 0x5a, 0x45, 0x52, 0x4f, 0x10, 0x00, 0x12, 0x17, 0x0a, 0x12, 0x50, 0x41, 0x43, 0x4b, 0x45,
0x54, 0x5f, 0x54, 0x4d, 0x5f, 0x43, 0x53, 0x54, 0x4d, 0x49, 0x6e, 0x66, 0x6f, 0x10, 0xb4, 0x15,
0x12, 0x18, 0x0a, 0x13, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x54, 0x4d, 0x5f, 0x53, 0x43,
0x54, 0x4d, 0x49, 0x6e, 0x66, 0x6f, 0x73, 0x10, 0xb5, 0x15, 0x12, 0x1b, 0x0a, 0x16, 0x50, 0x41,
0x43, 0x4b, 0x45, 0x54, 0x5f, 0x54, 0x4d, 0x5f, 0x43, 0x53, 0x54, 0x4d, 0x52, 0x61, 0x6e, 0x6b,
0x4c, 0x69, 0x73, 0x74, 0x10, 0xb6, 0x15, 0x12, 0x1b, 0x0a, 0x16, 0x50, 0x41, 0x43, 0x4b, 0x45,
0x54, 0x5f, 0x54, 0x4d, 0x5f, 0x53, 0x43, 0x54, 0x4d, 0x52, 0x61, 0x6e, 0x6b, 0x4c, 0x69, 0x73,
0x74, 0x10, 0xb7, 0x15, 0x12, 0x19, 0x0a, 0x14, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x54,
0x4d, 0x5f, 0x43, 0x53, 0x53, 0x69, 0x67, 0x6e, 0x52, 0x61, 0x63, 0x65, 0x10, 0xb8, 0x15, 0x12,
0x19, 0x0a, 0x14, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x54, 0x4d, 0x5f, 0x53, 0x43, 0x53,
0x69, 0x67, 0x6e, 0x52, 0x61, 0x63, 0x65, 0x10, 0xb9, 0x15, 0x12, 0x1c, 0x0a, 0x17, 0x50, 0x41,
0x43, 0x4b, 0x45, 0x54, 0x5f, 0x54, 0x4d, 0x5f, 0x53, 0x43, 0x53, 0x79, 0x6e, 0x63, 0x53, 0x69,
0x67, 0x6e, 0x4e, 0x75, 0x6d, 0x10, 0xba, 0x15, 0x12, 0x1e, 0x0a, 0x19, 0x50, 0x41, 0x43, 0x4b,
0x45, 0x54, 0x5f, 0x54, 0x4d, 0x5f, 0x53, 0x43, 0x50, 0x72, 0x6f, 0x6d, 0x6f, 0x74, 0x69, 0x6f,
0x6e, 0x49, 0x6e, 0x66, 0x6f, 0x10, 0xbb, 0x15, 0x12, 0x18, 0x0a, 0x13, 0x50, 0x41, 0x43, 0x4b,
0x45, 0x54, 0x5f, 0x54, 0x4d, 0x5f, 0x53, 0x43, 0x54, 0x4d, 0x53, 0x74, 0x61, 0x72, 0x74, 0x10,
0xbc, 0x15, 0x12, 0x1d, 0x0a, 0x18, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x54, 0x4d, 0x5f,
0x43, 0x53, 0x54, 0x4d, 0x53, 0x65, 0x61, 0x73, 0x6f, 0x6e, 0x49, 0x6e, 0x66, 0x6f, 0x10, 0xbf,
0x15, 0x12, 0x1d, 0x0a, 0x18, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x54, 0x4d, 0x5f, 0x53,
0x43, 0x54, 0x4d, 0x53, 0x65, 0x61, 0x73, 0x6f, 0x6e, 0x49, 0x6e, 0x66, 0x6f, 0x10, 0xc0, 0x15,
0x12, 0x1d, 0x0a, 0x18, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x54, 0x4d, 0x5f, 0x43, 0x53,
0x54, 0x4d, 0x53, 0x65, 0x61, 0x73, 0x6f, 0x6e, 0x52, 0x61, 0x6e, 0x6b, 0x10, 0xc1, 0x15, 0x12,
0x1d, 0x0a, 0x18, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x54, 0x4d, 0x5f, 0x53, 0x43, 0x54,
0x4d, 0x53, 0x65, 0x61, 0x73, 0x6f, 0x6e, 0x52, 0x61, 0x6e, 0x6b, 0x10, 0xc2, 0x15, 0x12, 0x1e,
0x0a, 0x19, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x54, 0x4d, 0x5f, 0x43, 0x53, 0x54, 0x4d,
0x53, 0x65, 0x61, 0x73, 0x6f, 0x6e, 0x41, 0x77, 0x61, 0x72, 0x64, 0x10, 0xc3, 0x15, 0x12, 0x1e,
0x0a, 0x19, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x54, 0x4d, 0x5f, 0x53, 0x43, 0x54, 0x4d,
0x53, 0x65, 0x61, 0x73, 0x6f, 0x6e, 0x41, 0x77, 0x61, 0x72, 0x64, 0x10, 0xc4, 0x15, 0x2a, 0x90,
0x01, 0x0a, 0x0c, 0x53, 0x69, 0x67, 0x6e, 0x52, 0x61, 0x63, 0x65, 0x43, 0x6f, 0x64, 0x65, 0x12,
0x0f, 0x0a, 0x0b, 0x4f, 0x50, 0x52, 0x43, 0x5f, 0x53, 0x75, 0x63, 0x65, 0x73, 0x73, 0x10, 0x00,
0x12, 0x0f, 0x0a, 0x0b, 0x4f, 0x50, 0x52, 0x43, 0x5f, 0x52, 0x65, 0x70, 0x65, 0x61, 0x74, 0x10,
0x01, 0x12, 0x0e, 0x0a, 0x0a, 0x4f, 0x50, 0x52, 0x43, 0x5f, 0x43, 0x6c, 0x6f, 0x73, 0x65, 0x10,
0x02, 0x12, 0x0f, 0x0a, 0x0b, 0x4f, 0x50, 0x52, 0x43, 0x5f, 0x4e, 0x6f, 0x49, 0x74, 0x65, 0x6d,
0x10, 0x03, 0x12, 0x0d, 0x0a, 0x09, 0x4f, 0x50, 0x52, 0x43, 0x5f, 0x54, 0x69, 0x6d, 0x65, 0x10,
0x04, 0x12, 0x0d, 0x0a, 0x09, 0x4f, 0x50, 0x52, 0x43, 0x5f, 0x43, 0x6f, 0x69, 0x6e, 0x10, 0x05,
0x12, 0x10, 0x0a, 0x0c, 0x4f, 0x50, 0x52, 0x43, 0x5f, 0x44, 0x69, 0x61, 0x6d, 0x6f, 0x6e, 0x64,
0x10, 0x06, 0x12, 0x0d, 0x0a, 0x09, 0x4f, 0x50, 0x52, 0x43, 0x5f, 0x46, 0x72, 0x65, 0x65, 0x10,
0x07, 0x42, 0x2a, 0x5a, 0x28, 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, 0x6f, 0x75, 0x72, 0x6e, 0x61, 0x6d, 0x65, 0x6e, 0x74, 0x62, 0x06, 0x70,
0x72, 0x6f, 0x74, 0x6f, 0x33,
0x06, 0x54, 0x4d, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x1a, 0x0a, 0x08, 0x54, 0x79, 0x70, 0x65, 0x4c,
0x69, 0x73, 0x74, 0x18, 0x02, 0x20, 0x03, 0x28, 0x05, 0x52, 0x08, 0x54, 0x79, 0x70, 0x65, 0x4c,
0x69, 0x73, 0x74, 0x22, 0x22, 0x0a, 0x0c, 0x43, 0x53, 0x54, 0x4d, 0x52, 0x61, 0x6e, 0x6b, 0x4c,
0x69, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x4d, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28,
0x05, 0x52, 0x04, 0x54, 0x4d, 0x49, 0x64, 0x22, 0x5a, 0x0a, 0x06, 0x54, 0x4d, 0x52, 0x61, 0x6e,
0x6b, 0x12, 0x16, 0x0a, 0x06, 0x52, 0x61, 0x6e, 0x6b, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28,
0x05, 0x52, 0x06, 0x52, 0x61, 0x6e, 0x6b, 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x52, 0x61, 0x6e,
0x6b, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x52, 0x61, 0x6e,
0x6b, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x57, 0x69, 0x6e, 0x6e, 0x65, 0x72, 0x4e,
0x75, 0x6d, 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x09, 0x57, 0x69, 0x6e, 0x6e, 0x65, 0x72,
0x4e, 0x75, 0x6d, 0x22, 0x6c, 0x0a, 0x0c, 0x53, 0x43, 0x54, 0x4d, 0x52, 0x61, 0x6e, 0x6b, 0x4c,
0x69, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x4d, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28,
0x05, 0x52, 0x04, 0x54, 0x4d, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x69, 0x6d, 0x65, 0x52,
0x61, 0x6e, 0x67, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x54, 0x69, 0x6d, 0x65,
0x52, 0x61, 0x6e, 0x67, 0x65, 0x12, 0x2a, 0x0a, 0x06, 0x54, 0x4d, 0x52, 0x61, 0x6e, 0x6b, 0x18,
0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x12, 0x2e, 0x74, 0x6f, 0x75, 0x72, 0x6e, 0x61, 0x6d, 0x65,
0x6e, 0x74, 0x2e, 0x54, 0x4d, 0x52, 0x61, 0x6e, 0x6b, 0x52, 0x06, 0x54, 0x4d, 0x52, 0x61, 0x6e,
0x6b, 0x22, 0x38, 0x0a, 0x0a, 0x43, 0x53, 0x53, 0x69, 0x67, 0x6e, 0x52, 0x61, 0x63, 0x65, 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, 0x12, 0x0a, 0x04, 0x54, 0x4d, 0x49, 0x64, 0x18,
0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x04, 0x54, 0x4d, 0x49, 0x64, 0x22, 0x64, 0x0a, 0x0a, 0x53,
0x43, 0x53, 0x69, 0x67, 0x6e, 0x52, 0x61, 0x63, 0x65, 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, 0x18, 0x0a, 0x07, 0x52, 0x65, 0x74, 0x43, 0x6f, 0x64, 0x65, 0x18, 0x02, 0x20, 0x01,
0x28, 0x05, 0x52, 0x07, 0x52, 0x65, 0x74, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x57,
0x61, 0x69, 0x74, 0x53, 0x74, 0x61, 0x72, 0x74, 0x54, 0x69, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01,
0x28, 0x03, 0x52, 0x0d, 0x57, 0x61, 0x69, 0x74, 0x53, 0x74, 0x61, 0x72, 0x74, 0x54, 0x69, 0x6d,
0x65, 0x22, 0x49, 0x0a, 0x0d, 0x53, 0x43, 0x53, 0x79, 0x6e, 0x63, 0x53, 0x69, 0x67, 0x6e, 0x4e,
0x75, 0x6d, 0x12, 0x18, 0x0a, 0x07, 0x53, 0x69, 0x67, 0x6e, 0x4e, 0x75, 0x6d, 0x18, 0x01, 0x20,
0x01, 0x28, 0x05, 0x52, 0x07, 0x53, 0x69, 0x67, 0x6e, 0x4e, 0x75, 0x6d, 0x12, 0x1e, 0x0a, 0x0a,
0x4d, 0x61, 0x78, 0x53, 0x69, 0x67, 0x6e, 0x4e, 0x75, 0x6d, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05,
0x52, 0x0a, 0x4d, 0x61, 0x78, 0x53, 0x69, 0x67, 0x6e, 0x4e, 0x75, 0x6d, 0x22, 0x25, 0x0a, 0x09,
0x53, 0x43, 0x54, 0x4d, 0x53, 0x74, 0x61, 0x72, 0x74, 0x12, 0x18, 0x0a, 0x07, 0x4d, 0x61, 0x74,
0x63, 0x68, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x4d, 0x61, 0x74, 0x63,
0x68, 0x49, 0x64, 0x22, 0x6b, 0x0a, 0x09, 0x52, 0x61, 0x6e, 0x6b, 0x41, 0x77, 0x61, 0x72, 0x64,
0x12, 0x30, 0x0a, 0x08, 0x49, 0x74, 0x65, 0x6d, 0x49, 0x6e, 0x66, 0x6f, 0x18, 0x01, 0x20, 0x03,
0x28, 0x0b, 0x32, 0x14, 0x2e, 0x74, 0x6f, 0x75, 0x72, 0x6e, 0x61, 0x6d, 0x65, 0x6e, 0x74, 0x2e,
0x49, 0x74, 0x65, 0x6d, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x08, 0x49, 0x74, 0x65, 0x6d, 0x49, 0x6e,
0x66, 0x6f, 0x12, 0x12, 0x0a, 0x04, 0x43, 0x6f, 0x69, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03,
0x52, 0x04, 0x43, 0x6f, 0x69, 0x6e, 0x12, 0x18, 0x0a, 0x07, 0x44, 0x69, 0x61, 0x6d, 0x6f, 0x6e,
0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x07, 0x44, 0x69, 0x61, 0x6d, 0x6f, 0x6e, 0x64,
0x22, 0x88, 0x03, 0x0a, 0x0f, 0x53, 0x43, 0x50, 0x72, 0x6f, 0x6d, 0x6f, 0x74, 0x69, 0x6f, 0x6e,
0x49, 0x6e, 0x66, 0x6f, 0x12, 0x18, 0x0a, 0x07, 0x52, 0x65, 0x74, 0x43, 0x6f, 0x64, 0x65, 0x18,
0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x52, 0x65, 0x74, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x14,
0x0a, 0x05, 0x52, 0x6f, 0x75, 0x6e, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x52,
0x6f, 0x75, 0x6e, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x52, 0x6f, 0x75, 0x6e, 0x64, 0x43, 0x6f, 0x69,
0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x09, 0x52, 0x6f, 0x75, 0x6e, 0x64, 0x43, 0x6f,
0x69, 0x6e, 0x12, 0x16, 0x0a, 0x06, 0x52, 0x61, 0x6e, 0x6b, 0x49, 0x64, 0x18, 0x04, 0x20, 0x01,
0x28, 0x05, 0x52, 0x06, 0x52, 0x61, 0x6e, 0x6b, 0x49, 0x64, 0x12, 0x3f, 0x0a, 0x06, 0x52, 0x65,
0x63, 0x6f, 0x72, 0x64, 0x18, 0x05, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x27, 0x2e, 0x74, 0x6f, 0x75,
0x72, 0x6e, 0x61, 0x6d, 0x65, 0x6e, 0x74, 0x2e, 0x53, 0x43, 0x50, 0x72, 0x6f, 0x6d, 0x6f, 0x74,
0x69, 0x6f, 0x6e, 0x49, 0x6e, 0x66, 0x6f, 0x2e, 0x52, 0x65, 0x63, 0x6f, 0x72, 0x64, 0x45, 0x6e,
0x74, 0x72, 0x79, 0x52, 0x06, 0x52, 0x65, 0x63, 0x6f, 0x72, 0x64, 0x12, 0x18, 0x0a, 0x07, 0x4d,
0x61, 0x74, 0x63, 0x68, 0x49, 0x64, 0x18, 0x06, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x4d, 0x61,
0x74, 0x63, 0x68, 0x49, 0x64, 0x12, 0x26, 0x0a, 0x0e, 0x4d, 0x61, 0x74, 0x63, 0x68, 0x50, 0x72,
0x6f, 0x6d, 0x6f, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x07, 0x20, 0x03, 0x28, 0x05, 0x52, 0x0e, 0x4d,
0x61, 0x74, 0x63, 0x68, 0x50, 0x72, 0x6f, 0x6d, 0x6f, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x33, 0x0a,
0x09, 0x52, 0x61, 0x6e, 0x6b, 0x41, 0x77, 0x61, 0x72, 0x64, 0x18, 0x08, 0x20, 0x01, 0x28, 0x0b,
0x32, 0x15, 0x2e, 0x74, 0x6f, 0x75, 0x72, 0x6e, 0x61, 0x6d, 0x65, 0x6e, 0x74, 0x2e, 0x52, 0x61,
0x6e, 0x6b, 0x41, 0x77, 0x61, 0x72, 0x64, 0x52, 0x09, 0x52, 0x61, 0x6e, 0x6b, 0x41, 0x77, 0x61,
0x72, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x4d, 0x61, 0x74, 0x63, 0x68, 0x4e, 0x61, 0x6d, 0x65, 0x18,
0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x4d, 0x61, 0x74, 0x63, 0x68, 0x4e, 0x61, 0x6d, 0x65,
0x1a, 0x39, 0x0a, 0x0b, 0x52, 0x65, 0x63, 0x6f, 0x72, 0x64, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12,
0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x03, 0x6b, 0x65,
0x79, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05,
0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x22, 0x10, 0x0a, 0x0e, 0x43,
0x53, 0x54, 0x4d, 0x53, 0x65, 0x61, 0x73, 0x6f, 0x6e, 0x49, 0x6e, 0x66, 0x6f, 0x22, 0x8c, 0x01,
0x0a, 0x0e, 0x53, 0x43, 0x54, 0x4d, 0x53, 0x65, 0x61, 0x73, 0x6f, 0x6e, 0x49, 0x6e, 0x66, 0x6f,
0x12, 0x0e, 0x0a, 0x02, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x02, 0x49, 0x64,
0x12, 0x28, 0x0a, 0x0f, 0x53, 0x65, 0x61, 0x73, 0x6f, 0x6e, 0x54, 0x69, 0x6d, 0x65, 0x53, 0x74,
0x61, 0x6d, 0x70, 0x18, 0x02, 0x20, 0x03, 0x28, 0x03, 0x52, 0x0f, 0x53, 0x65, 0x61, 0x73, 0x6f,
0x6e, 0x54, 0x69, 0x6d, 0x65, 0x53, 0x74, 0x61, 0x6d, 0x70, 0x12, 0x0e, 0x0a, 0x02, 0x4c, 0x76,
0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x02, 0x4c, 0x76, 0x12, 0x16, 0x0a, 0x06, 0x4c, 0x61,
0x73, 0x74, 0x4c, 0x76, 0x18, 0x04, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06, 0x4c, 0x61, 0x73, 0x74,
0x4c, 0x76, 0x12, 0x18, 0x0a, 0x07, 0x49, 0x73, 0x41, 0x77, 0x61, 0x72, 0x64, 0x18, 0x05, 0x20,
0x01, 0x28, 0x08, 0x52, 0x07, 0x49, 0x73, 0x41, 0x77, 0x61, 0x72, 0x64, 0x22, 0x58, 0x0a, 0x0a,
0x53, 0x65, 0x61, 0x73, 0x6f, 0x6e, 0x52, 0x61, 0x6e, 0x6b, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x6e,
0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x04, 0x53, 0x6e, 0x69, 0x64, 0x12, 0x12,
0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61,
0x6d, 0x65, 0x12, 0x0e, 0x0a, 0x02, 0x4c, 0x76, 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x02,
0x4c, 0x76, 0x12, 0x12, 0x0a, 0x04, 0x52, 0x61, 0x6e, 0x6b, 0x18, 0x04, 0x20, 0x01, 0x28, 0x05,
0x52, 0x04, 0x52, 0x61, 0x6e, 0x6b, 0x22, 0x10, 0x0a, 0x0e, 0x43, 0x53, 0x54, 0x4d, 0x53, 0x65,
0x61, 0x73, 0x6f, 0x6e, 0x52, 0x61, 0x6e, 0x6b, 0x22, 0x4a, 0x0a, 0x0e, 0x53, 0x43, 0x54, 0x4d,
0x53, 0x65, 0x61, 0x73, 0x6f, 0x6e, 0x52, 0x61, 0x6e, 0x6b, 0x12, 0x38, 0x0a, 0x0b, 0x52, 0x65,
0x61, 0x73, 0x6f, 0x6e, 0x52, 0x61, 0x6e, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x03, 0x28, 0x0b, 0x32,
0x16, 0x2e, 0x74, 0x6f, 0x75, 0x72, 0x6e, 0x61, 0x6d, 0x65, 0x6e, 0x74, 0x2e, 0x53, 0x65, 0x61,
0x73, 0x6f, 0x6e, 0x52, 0x61, 0x6e, 0x6b, 0x52, 0x0b, 0x52, 0x65, 0x61, 0x73, 0x6f, 0x6e, 0x52,
0x61, 0x6e, 0x6b, 0x73, 0x22, 0x21, 0x0a, 0x0f, 0x43, 0x53, 0x54, 0x4d, 0x53, 0x65, 0x61, 0x73,
0x6f, 0x6e, 0x41, 0x77, 0x61, 0x72, 0x64, 0x12, 0x0e, 0x0a, 0x02, 0x4c, 0x76, 0x18, 0x01, 0x20,
0x01, 0x28, 0x05, 0x52, 0x02, 0x4c, 0x76, 0x22, 0x35, 0x0a, 0x0f, 0x53, 0x43, 0x54, 0x4d, 0x53,
0x65, 0x61, 0x73, 0x6f, 0x6e, 0x41, 0x77, 0x61, 0x72, 0x64, 0x12, 0x0e, 0x0a, 0x02, 0x4c, 0x76,
0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x02, 0x4c, 0x76, 0x12, 0x12, 0x0a, 0x04, 0x43, 0x6f,
0x64, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x04, 0x43, 0x6f, 0x64, 0x65, 0x2a, 0xd9,
0x03, 0x0a, 0x0c, 0x54, 0x4f, 0x55, 0x52, 0x4e, 0x41, 0x4d, 0x45, 0x4e, 0x54, 0x49, 0x44, 0x12,
0x12, 0x0a, 0x0e, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x54, 0x4d, 0x5f, 0x5a, 0x45, 0x52,
0x4f, 0x10, 0x00, 0x12, 0x17, 0x0a, 0x12, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x54, 0x4d,
0x5f, 0x43, 0x53, 0x54, 0x4d, 0x49, 0x6e, 0x66, 0x6f, 0x10, 0xb4, 0x15, 0x12, 0x18, 0x0a, 0x13,
0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x54, 0x4d, 0x5f, 0x53, 0x43, 0x54, 0x4d, 0x49, 0x6e,
0x66, 0x6f, 0x73, 0x10, 0xb5, 0x15, 0x12, 0x1b, 0x0a, 0x16, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54,
0x5f, 0x54, 0x4d, 0x5f, 0x43, 0x53, 0x54, 0x4d, 0x52, 0x61, 0x6e, 0x6b, 0x4c, 0x69, 0x73, 0x74,
0x10, 0xb6, 0x15, 0x12, 0x1b, 0x0a, 0x16, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x54, 0x4d,
0x5f, 0x53, 0x43, 0x54, 0x4d, 0x52, 0x61, 0x6e, 0x6b, 0x4c, 0x69, 0x73, 0x74, 0x10, 0xb7, 0x15,
0x12, 0x19, 0x0a, 0x14, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x54, 0x4d, 0x5f, 0x43, 0x53,
0x53, 0x69, 0x67, 0x6e, 0x52, 0x61, 0x63, 0x65, 0x10, 0xb8, 0x15, 0x12, 0x19, 0x0a, 0x14, 0x50,
0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x54, 0x4d, 0x5f, 0x53, 0x43, 0x53, 0x69, 0x67, 0x6e, 0x52,
0x61, 0x63, 0x65, 0x10, 0xb9, 0x15, 0x12, 0x1c, 0x0a, 0x17, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54,
0x5f, 0x54, 0x4d, 0x5f, 0x53, 0x43, 0x53, 0x79, 0x6e, 0x63, 0x53, 0x69, 0x67, 0x6e, 0x4e, 0x75,
0x6d, 0x10, 0xba, 0x15, 0x12, 0x1e, 0x0a, 0x19, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x54,
0x4d, 0x5f, 0x53, 0x43, 0x50, 0x72, 0x6f, 0x6d, 0x6f, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x6e, 0x66,
0x6f, 0x10, 0xbb, 0x15, 0x12, 0x18, 0x0a, 0x13, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x54,
0x4d, 0x5f, 0x53, 0x43, 0x54, 0x4d, 0x53, 0x74, 0x61, 0x72, 0x74, 0x10, 0xbc, 0x15, 0x12, 0x1d,
0x0a, 0x18, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x54, 0x4d, 0x5f, 0x43, 0x53, 0x54, 0x4d,
0x53, 0x65, 0x61, 0x73, 0x6f, 0x6e, 0x49, 0x6e, 0x66, 0x6f, 0x10, 0xbf, 0x15, 0x12, 0x1d, 0x0a,
0x18, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x54, 0x4d, 0x5f, 0x53, 0x43, 0x54, 0x4d, 0x53,
0x65, 0x61, 0x73, 0x6f, 0x6e, 0x49, 0x6e, 0x66, 0x6f, 0x10, 0xc0, 0x15, 0x12, 0x1d, 0x0a, 0x18,
0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x54, 0x4d, 0x5f, 0x43, 0x53, 0x54, 0x4d, 0x53, 0x65,
0x61, 0x73, 0x6f, 0x6e, 0x52, 0x61, 0x6e, 0x6b, 0x10, 0xc1, 0x15, 0x12, 0x1d, 0x0a, 0x18, 0x50,
0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x54, 0x4d, 0x5f, 0x53, 0x43, 0x54, 0x4d, 0x53, 0x65, 0x61,
0x73, 0x6f, 0x6e, 0x52, 0x61, 0x6e, 0x6b, 0x10, 0xc2, 0x15, 0x12, 0x1e, 0x0a, 0x19, 0x50, 0x41,
0x43, 0x4b, 0x45, 0x54, 0x5f, 0x54, 0x4d, 0x5f, 0x43, 0x53, 0x54, 0x4d, 0x53, 0x65, 0x61, 0x73,
0x6f, 0x6e, 0x41, 0x77, 0x61, 0x72, 0x64, 0x10, 0xc3, 0x15, 0x12, 0x1e, 0x0a, 0x19, 0x50, 0x41,
0x43, 0x4b, 0x45, 0x54, 0x5f, 0x54, 0x4d, 0x5f, 0x53, 0x43, 0x54, 0x4d, 0x53, 0x65, 0x61, 0x73,
0x6f, 0x6e, 0x41, 0x77, 0x61, 0x72, 0x64, 0x10, 0xc4, 0x15, 0x2a, 0x90, 0x01, 0x0a, 0x0c, 0x53,
0x69, 0x67, 0x6e, 0x52, 0x61, 0x63, 0x65, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x0f, 0x0a, 0x0b, 0x4f,
0x50, 0x52, 0x43, 0x5f, 0x53, 0x75, 0x63, 0x65, 0x73, 0x73, 0x10, 0x00, 0x12, 0x0f, 0x0a, 0x0b,
0x4f, 0x50, 0x52, 0x43, 0x5f, 0x52, 0x65, 0x70, 0x65, 0x61, 0x74, 0x10, 0x01, 0x12, 0x0e, 0x0a,
0x0a, 0x4f, 0x50, 0x52, 0x43, 0x5f, 0x43, 0x6c, 0x6f, 0x73, 0x65, 0x10, 0x02, 0x12, 0x0f, 0x0a,
0x0b, 0x4f, 0x50, 0x52, 0x43, 0x5f, 0x4e, 0x6f, 0x49, 0x74, 0x65, 0x6d, 0x10, 0x03, 0x12, 0x0d,
0x0a, 0x09, 0x4f, 0x50, 0x52, 0x43, 0x5f, 0x54, 0x69, 0x6d, 0x65, 0x10, 0x04, 0x12, 0x0d, 0x0a,
0x09, 0x4f, 0x50, 0x52, 0x43, 0x5f, 0x43, 0x6f, 0x69, 0x6e, 0x10, 0x05, 0x12, 0x10, 0x0a, 0x0c,
0x4f, 0x50, 0x52, 0x43, 0x5f, 0x44, 0x69, 0x61, 0x6d, 0x6f, 0x6e, 0x64, 0x10, 0x06, 0x12, 0x0d,
0x0a, 0x09, 0x4f, 0x50, 0x52, 0x43, 0x5f, 0x46, 0x72, 0x65, 0x65, 0x10, 0x07, 0x42, 0x2a, 0x5a,
0x28, 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,
0x6f, 0x75, 0x72, 0x6e, 0x61, 0x6d, 0x65, 0x6e, 0x74, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f,
0x33,
}
var (

View File

@ -64,10 +64,11 @@ message TMInfo{
int32 SortId = 20;
repeated string OnChannelName = 21;//
}
//
//
//PACKET_TM_SCTMInfos
message SCTMInfos{
repeated TMInfo TMInfo = 1;//
repeated int32 TypeList = 2; // 1. 2. 3.vip比赛 4.
}
//
//PACKET_TM_CSTMRankList

File diff suppressed because it is too large Load Diff

View File

@ -454,6 +454,11 @@ message GameMatchDateList{
string Platform = 2;
}
// etcd /game/match_type
message GameMatchType{
string Platform = 1;
repeated int32 List = 2; // 1. 2. 3.vip比赛 4.
}
message WelfareDate {
int32 Grade = 1; //

2
public

@ -1 +1 @@
Subproject commit 549a622ad237392dddedae5d13456a06a8328fdd
Subproject commit 38b1c8928c52249a60d1340372a2d9bd6d2eee01

View File

@ -236,17 +236,47 @@ func CSInvite(s *netlib.Session, d *rankproto.GateTransmit, packetId int, data i
}
}
pack := &rankproto.SCInvite{
Id: msg.GetId(),
Ranks: ranks,
Me: me,
Skip: msg.GetSkip(),
IsEndNum: IsEndNum,
RankMaxNum: model.GameParamData.RankInviteMaxNum,
f := func() {
pack := &rankproto.SCInvite{
Id: msg.GetId(),
Ranks: ranks,
Me: me,
Skip: msg.GetSkip(),
IsEndNum: IsEndNum,
RankMaxNum: model.GameParamData.RankInviteMaxNum,
}
common.SendToGate(sid, int(rankproto.Rank_PACKET_RANK_SCInvite), pack, s)
logger.Logger.Tracef("SCInvite: %v", pack)
}
common.SendToGate(sid, int(rankproto.Rank_PACKET_RANK_SCInvite), pack, s)
logger.Logger.Tracef("SCInvite: %v", pack)
// 查询自己
if me == nil {
task.New(nil, task.CallableWrapper(func(o *basic.Object) interface{} {
r, err := model.FindPlayerRankInviteScoreType(&model.FindPlayerRankInviteScoreArgs{
Platform: d.Platform,
RankType: msg.GetId(),
SnId: d.Snid,
})
if err != nil || r == nil {
logger.Logger.Errorf("FindPlayerRankInviteScoreType error: %v", err)
return nil
}
me = &rankproto.InviteRank{
Snid: r.Data.SnId,
Name: r.Data.Name,
Rank: model.GameParamData.RankInviteMaxNum,
Score: r.Data.Score,
InviteNum: r.Data.InviteNum,
ModId: r.Data.ModId,
}
return nil
}), task.CompleteNotifyWrapper(func(i interface{}, t task.Task) {
f()
}), "rank_invite_me").Start()
} else {
f()
}
})
return nil
}

View File

@ -59,6 +59,8 @@ func CSSignRace(s *netlib.Session, packetid int, data interface{}, sid int64) er
pack.RetCode = code //0成功 1重复报名 2比赛没有开启 3道具不足 4不在报名时间段 5金币不足 6钻石不足
}
logger.Logger.Infof("player(%v) match(%v) SignUp is ok.", p.SnId, tmId)
if code == int32(tournament.SignRaceCode_OPRC_Close) ||
code == int32(tournament.SignRaceCode_OPRC_Time) {
TournamentMgr.CancelSignUpAll(platform, tmId)
@ -73,7 +75,7 @@ func CSSignRace(s *netlib.Session, packetid int, data interface{}, sid int64) er
logger.Logger.Trace("SCSignRace ", pack)
// 检查是否可以开始比赛(关闭机器人时,比赛开赛)
if code == 0 && signSucc && !TournamentMgr.IsUseRobot(platform, tmId) {
if code == 0 && signSucc && !TournamentMgr.IsUseRobot(platform, tmId, 0) {
if TournamentMgr.CanStart(platform, tmId) {
TournamentMgr.Start(platform, tmId)
}

View File

@ -30,6 +30,8 @@ func init() {
etcd.Register(etcd.ETCDKEY_GAME_NOTICE, webapi.CommonNoticeList{}, platformConfigEvent)
// 比赛配置
etcd.Register(etcd.ETCDKEY_GAME_MATCH, webapi.GameMatchDateList{}, platformConfigEvent)
// 比赛场类型
etcd.Register(etcd.ETCDKEY_GAME_MATCH_TYPE, webapi.GameMatchType{}, platformConfigEvent)
// 个人水池配置
etcd.Register(etcd.ETCDKEY_PLAYERPOOL, webapi.PlayerPool{}, platformConfigEvent)
// 商品兑换
@ -154,6 +156,12 @@ func platformConfigEvent(ctx context.Context, completeKey string, isInit bool, e
} else {
TournamentMgr.UpdateData(false, config)
}
case *webapi.GameMatchType:
if isInit {
TournamentMgr.UpdateTypeList(true, config)
} else {
TournamentMgr.UpdateTypeList(false, config)
}
case *webapi.ChannelSwitchConfig:
PlatformMgrSingleton.GetConfig(config.Platform).ChannelSwitch[config.GetTp()] = config
if !isInit {

View File

@ -30,9 +30,12 @@ func init() {
}
const (
MatchTypeNormal = 1 // 锦标赛
MatchTypeChampion = 2 // 冠军赛
MatchTypeVIP = 3 // vip比赛
// 如果这里比赛类型没有,默认是锦标赛
MatchTypeNormal = iota + 1 // 锦标赛
MatchTypeChampion // 冠军赛/实物赛
MatchTypeVIP // vip比赛
MatchTypePhone // 话费赛
MatchTypeMax // 最大比赛类型
)
const (
@ -81,6 +84,7 @@ type PlayerRoundInfo struct {
type Tournament struct {
BaseClockSinker
TypeList map[string][]int32 // 比赛类型列表 平台id比赛类型
GameMatchDateList map[string]map[int32]*webapiproto.GameMatchDate // 比赛配置platform:比赛场配置id:比赛配置
singleSignupPlayers map[int32]*SignupInfo // 开启机器人时报名的玩家玩家Id:报名信息
signupPlayers map[string]map[int32]*SignInfo // 报名的玩家 platform:比赛配置id:报名人
@ -93,6 +97,7 @@ type Tournament struct {
func NewTournament() *Tournament {
ret := &Tournament{
TypeList: make(map[string][]int32),
GameMatchDateList: make(map[string]map[int32]*webapiproto.GameMatchDate),
singleSignupPlayers: make(map[int32]*SignupInfo),
signupPlayers: make(map[string]map[int32]*SignInfo),
@ -245,8 +250,53 @@ func (this *Tournament) UpdateData(init bool, data *webapiproto.GameMatchDateLis
}
}
func (this *Tournament) UpdateTypeList(init bool, data *webapiproto.GameMatchType) {
if data.Platform == "0" {
return
}
isModify := false
d, ok := this.TypeList[data.Platform]
if !ok || len(d) != len(data.GetList()) {
this.TypeList[data.Platform] = data.GetList()
isModify = true
} else {
for k, v := range data.GetList() {
if d[k] != v {
this.TypeList[data.Platform] = data.GetList()
isModify = true
break
}
}
}
if !isModify {
return
}
if !init {
//todo 优化
for _, v := range PlayerMgrSington.playerOfPlatform[data.Platform] {
pack := TournamentMgr.GetSCTMInfosPack(data.Platform, v.AppChannel)
v.SendToClient(int(tournament.TOURNAMENTID_PACKET_TM_SCTMInfos), pack)
logger.Logger.Trace("SCTMInfos UpdateTypeList", pack)
}
}
}
// GetMatchInfo 比赛配置
func (this *Tournament) GetMatchInfo(platform string, tmId int32) *webapiproto.GameMatchDate {
// !!!没有sortId会获取最新配置
func (this *Tournament) GetMatchInfo(platform string, tmId int32, sortId int64) *webapiproto.GameMatchDate {
if sortId > 0 {
v := this.matches[tmId]
if v != nil {
vv := v[sortId]
if vv != nil {
return vv.gmd
}
}
return nil
}
if list, ok := this.GameMatchDateList[platform]; ok {
if gmd, ok1 := list[tmId]; ok1 {
return gmd
@ -257,7 +307,7 @@ func (this *Tournament) GetMatchInfo(platform string, tmId int32) *webapiproto.G
// MatchSwitch 比赛开关
func (this *Tournament) MatchSwitch(platform string, tmId int32) bool {
return this.IsMatchOn(this.GetMatchInfo(platform, tmId))
return this.IsMatchOn(this.GetMatchInfo(platform, tmId, 0))
}
// IsMatchOn 比赛开关
@ -266,8 +316,8 @@ func (this *Tournament) IsMatchOn(match *webapiproto.GameMatchDate) bool {
}
// IsUseRobot 是否用机器人
func (this *Tournament) IsUseRobot(platform string, tmId int32) bool {
return this.IsRobotOn(this.GetMatchInfo(platform, tmId))
func (this *Tournament) IsUseRobot(platform string, tmId int32, sortId int64) bool {
return this.IsRobotOn(this.GetMatchInfo(platform, tmId, sortId))
}
// IsRobotOn 是否用机器人
@ -387,7 +437,7 @@ func (this *Tournament) IsMatchWaiting(platform string, snId int32) (bool, int32
// 报名费用 0成功 3道具不足 5金币不足 6钻石不足 7免费次数不足
func (this *Tournament) signUpCost(p *Player, tmId int32, cost bool) (bool, int32) {
logger.Logger.Tracef("signUpCost 比赛id:%v 玩家:%v 报名:%v", tmId, p.SnId, cost)
gmd := this.GetMatchInfo(p.Platform, tmId)
gmd := this.GetMatchInfo(p.Platform, tmId, 0)
if gmd == nil || p.IsRob {
return true, 0
}
@ -482,7 +532,7 @@ func (this *Tournament) signUpCost(p *Player, tmId int32, cost bool) (bool, int3
func (this *Tournament) SignUp(tmId int32, p *Player) (bool, int32) {
logger.Logger.Tracef("报名 比赛id%v 玩家:%v", tmId, p.SnId)
// 开启
info := this.GetMatchInfo(p.Platform, tmId)
info := this.GetMatchInfo(p.Platform, tmId, 0)
if !this.IsMatchOn(info) {
return false, int32(tournament.SignRaceCode_OPRC_Close)
}
@ -636,7 +686,7 @@ func (this *Tournament) ForceQuit(platform string, snId int32) {
func (this *Tournament) CanStart(platform string, tmId int32) bool {
if this.signupPlayers != nil && this.signupPlayers[platform] != nil {
if signInfo, ok := this.signupPlayers[platform][tmId]; ok {
matchInfo := this.GetMatchInfo(signInfo.Platform, tmId)
matchInfo := this.GetMatchInfo(signInfo.Platform, tmId, 0)
if matchInfo != nil {
n := 0
for _, v := range signInfo.signup {
@ -669,7 +719,7 @@ func (this *Tournament) Start(platform string, tmId int32) {
this.matches[tmId] = make(map[int64]*TmMatch)
}
matchInfo := this.GetMatchInfo(platform, tmId)
matchInfo := this.GetMatchInfo(platform, tmId, 0)
signInfo := this.signupPlayers[platform][tmId]
if matchInfo == nil || signInfo == nil || len(signInfo.signup) == 0 {
@ -1404,12 +1454,17 @@ func (this *Tournament) GetSCTMInfosPack(platform, channelName string) *tourname
pack.TMInfo = append(pack.TMInfo, tMInfo)
}
}
pack.TypeList = this.TypeList[platform]
}
return pack
}
func (this *Tournament) MakeMatchLog(platform string, tmId int32, sortId int64) *model.MatchLog {
gameMatchDate := this.GetMatchInfo(platform, tmId)
gameMatchDate := this.GetMatchInfo(platform, tmId, sortId)
if gameMatchDate == nil {
logger.Logger.Errorf("MakeMatchLog gameMatchDate == nil tmId:%d sortId:%d", tmId, sortId)
return nil
}
matchLog := model.NewMatchLog()
_, ok := this.roundPlayers[sortId]
if !ok {
@ -1463,6 +1518,7 @@ func (this *Tournament) MakeMatchLog(platform string, tmId int32, sortId int64)
matchLog.GameFreeId = gameMatchDate.GameFreeId
matchLog.StartTime = time.Unix(this.matches[tmId][sortId].StartTime, 0)
matchLog.EndTime = time.Now()
matchLog.SortId = sortId
return matchLog
}
@ -1495,7 +1551,7 @@ func (this *Tournament) Update() {
if info == nil || info.Ts <= 0 {
continue
}
matchInfo := this.GetMatchInfo(info.Platform, info.TmId)
matchInfo := this.GetMatchInfo(info.Platform, info.TmId, 0)
if this.IsMatchOn(matchInfo) && !this.IsOutTime(matchInfo) && this.IsRobotOn(matchInfo) {
needTime := this.playerWaitStart[snId]
if time.Now().Unix()-info.Ts > needTime {