Compare commits
No commits in common. "f1dee4a54ad4ee614bda4a45773579880a54941a" and "feda7fd5c11bf13c5650245519e0d029fb590358" have entirely different histories.
f1dee4a54a
...
feda7fd5c1
|
@ -68,30 +68,33 @@ func init() {
|
||||||
}))
|
}))
|
||||||
|
|
||||||
//删除场景
|
//删除场景
|
||||||
// 立刻删除,不管游戏是否结束
|
|
||||||
netlib.RegisterFactory(int(server.SSPacketID_PACKET_WG_DESTROYSCENE), netlib.PacketFactoryWrapper(func() interface{} {
|
netlib.RegisterFactory(int(server.SSPacketID_PACKET_WG_DESTROYSCENE), netlib.PacketFactoryWrapper(func() interface{} {
|
||||||
return &server.WGDestroyScene{}
|
return &server.WGDestroyScene{}
|
||||||
}))
|
}))
|
||||||
netlib.RegisterHandler(int(server.SSPacketID_PACKET_WG_DESTROYSCENE), netlib.HandlerWrapper(func(s *netlib.Session, packetid int, pack interface{}) error {
|
netlib.RegisterHandler(int(server.SSPacketID_PACKET_WG_DESTROYSCENE), netlib.HandlerWrapper(func(s *netlib.Session, packetid int, pack interface{}) error {
|
||||||
logger.Logger.Trace("receive WGDestroyScene:", pack)
|
logger.Logger.Trace("receive WGDestroyScene:", pack)
|
||||||
msg, ok := pack.(*server.WGDestroyScene)
|
if msg, ok := pack.(*server.WGDestroyScene); ok {
|
||||||
if !ok {
|
sceneId := int(msg.GetSceneId())
|
||||||
return nil
|
s := base.SceneMgrSington.GetScene(sceneId)
|
||||||
}
|
|
||||||
if !msg.IsGrace {
|
|
||||||
// 立刻删除,不管游戏是否结束
|
|
||||||
for _, v := range msg.Ids {
|
|
||||||
s := base.SceneMgrSington.GetScene(int(v))
|
|
||||||
if s != nil {
|
if s != nil {
|
||||||
if gameScene, ok := s.ExtraData.(base.GameScene); ok {
|
if gameScene, ok := s.ExtraData.(base.GameScene); ok {
|
||||||
gameScene.SceneDestroy(true)
|
gameScene.SceneDestroy(true)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else {
|
return nil
|
||||||
// 游戏结束后删除房间
|
}))
|
||||||
for _, v := range msg.Ids {
|
|
||||||
s := base.SceneMgrSington.GetScene(int(v))
|
//删除场景
|
||||||
|
netlib.RegisterFactory(int(server.SSPacketID_PACKET_WG_GRACE_DESTROYSCENE), netlib.PacketFactoryWrapper(func() interface{} {
|
||||||
|
return &server.WGGraceDestroyScene{}
|
||||||
|
}))
|
||||||
|
netlib.RegisterHandler(int(server.SSPacketID_PACKET_WG_GRACE_DESTROYSCENE), netlib.HandlerWrapper(func(s *netlib.Session, packetid int, pack interface{}) error {
|
||||||
|
logger.Logger.Trace("receive WGGraceDestroyScene:", pack)
|
||||||
|
if msg, ok := pack.(*server.WGGraceDestroyScene); ok {
|
||||||
|
ids := msg.GetIds()
|
||||||
|
for _, id := range ids {
|
||||||
|
s := base.SceneMgrSington.GetScene(int(id))
|
||||||
if s != nil {
|
if s != nil {
|
||||||
if s.IsHundredScene() || s.Gaming {
|
if s.IsHundredScene() || s.Gaming {
|
||||||
s.SetGraceDestroy(true)
|
s.SetGraceDestroy(true)
|
||||||
|
@ -106,7 +109,6 @@ func init() {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return nil
|
return nil
|
||||||
}))
|
}))
|
||||||
|
|
||||||
|
|
|
@ -1046,8 +1046,8 @@ func (this *Scene) Destroy(force bool) {
|
||||||
isCompleted := this.sp.IsCompleted(this) || this.completed
|
isCompleted := this.sp.IsCompleted(this) || this.completed
|
||||||
SceneMgrSington.DestroyScene(this.SceneId)
|
SceneMgrSington.DestroyScene(this.SceneId)
|
||||||
pack := &server.GWDestroyScene{
|
pack := &server.GWDestroyScene{
|
||||||
SceneId: int64(this.SceneId),
|
SceneId: proto.Int(this.SceneId),
|
||||||
IsCompleted: isCompleted,
|
IsCompleted: proto.Bool(isCompleted),
|
||||||
}
|
}
|
||||||
proto.SetDefaults(pack)
|
proto.SetDefaults(pack)
|
||||||
this.SendToWorld(int(server.SSPacketID_PACKET_GW_DESTROYSCENE), pack)
|
this.SendToWorld(int(server.SSPacketID_PACKET_GW_DESTROYSCENE), pack)
|
||||||
|
|
|
@ -46,8 +46,18 @@ type GameParam struct {
|
||||||
InvalidRobotAccRate int //每次更换过期机器人账号的比例,百分比
|
InvalidRobotAccRate int //每次更换过期机器人账号的比例,百分比
|
||||||
InvalidRobotDay int //机器人过期的天数
|
InvalidRobotDay int //机器人过期的天数
|
||||||
CreatePrivateSceneCnt int //每人可以创建私有房间数量
|
CreatePrivateSceneCnt int //每人可以创建私有房间数量
|
||||||
|
PrivateSceneLogLimit int //私有房间日志上限
|
||||||
|
PrivateSceneFreeDistroySec int //私有房间免费解散时间,默认600秒
|
||||||
|
PrivateSceneDestroyTax int //私有房间提前解散税收,百分比
|
||||||
|
NumOfGamesConfig []int32 //私人房间局数
|
||||||
BacklogGameHorseRaceLamp int //游戏内公告储备多少条,超出丢弃
|
BacklogGameHorseRaceLamp int //游戏内公告储备多少条,超出丢弃
|
||||||
IsRobFightTest bool //是否开启机器人自己对战功能
|
IsRobFightTest bool //是否开启机器人自己对战功能
|
||||||
|
BullFightCtrl0108 bool //牛牛是否使用新功能规则
|
||||||
|
OpenPoolRec bool //是否打开水池数据记录
|
||||||
|
CoinPoolMinOutRate int32 //水池最小出分
|
||||||
|
CoinPoolMaxOutRate int32 //水池最大出分
|
||||||
|
MaxRTP float64 //最大rtp
|
||||||
|
AddRTP float64 //附加rtp
|
||||||
PlayerWatchNum int32 //百人游戏允许围观的局数
|
PlayerWatchNum int32 //百人游戏允许围观的局数
|
||||||
NotifyPlayerWatchNum int32 //百人游戏围观多少局的时候开始提示
|
NotifyPlayerWatchNum int32 //百人游戏围观多少局的时候开始提示
|
||||||
CgAddr string //后台cg工程地址
|
CgAddr string //后台cg工程地址
|
||||||
|
@ -55,6 +65,7 @@ type GameParam struct {
|
||||||
MaxAudienceNum int //最大观战人数
|
MaxAudienceNum int //最大观战人数
|
||||||
IsFindRoomByGroup bool //查询房间列表时是否使用互通查询,默认是不使用
|
IsFindRoomByGroup bool //查询房间列表时是否使用互通查询,默认是不使用
|
||||||
NoOpTimes int32 //对战场允许托管的局数
|
NoOpTimes int32 //对战场允许托管的局数
|
||||||
|
UseBevRobot bool //是否使用行为树机器人
|
||||||
ClosePreCreateRoom bool //关闭予创建房间
|
ClosePreCreateRoom bool //关闭予创建房间
|
||||||
CloseQMThr bool //关闭全民三方流水计算
|
CloseQMThr bool //关闭全民三方流水计算
|
||||||
ErrResetMongo bool //发生主从问题,是否重置连接
|
ErrResetMongo bool //发生主从问题,是否重置连接
|
||||||
|
@ -118,6 +129,15 @@ func InitGameParam() {
|
||||||
if GameParamData.KickoutDefaultFreezeMinute == 0 {
|
if GameParamData.KickoutDefaultFreezeMinute == 0 {
|
||||||
GameParamData.KickoutDefaultFreezeMinute = 5
|
GameParamData.KickoutDefaultFreezeMinute = 5
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if GameParamData.MaxRTP <= 0.00001 {
|
||||||
|
GameParamData.MaxRTP = 0.999999
|
||||||
|
}
|
||||||
|
|
||||||
|
if GameParamData.AddRTP <= 0.00001 {
|
||||||
|
GameParamData.AddRTP = 0.1
|
||||||
|
}
|
||||||
|
|
||||||
mgo.SetDebug(GameParamData.MongoDebug)
|
mgo.SetDebug(GameParamData.MongoDebug)
|
||||||
if GameParamData.RbAutoBalance {
|
if GameParamData.RbAutoBalance {
|
||||||
if GameParamData.RbAutoBalanceRate == 0 {
|
if GameParamData.RbAutoBalanceRate == 0 {
|
||||||
|
@ -148,6 +168,26 @@ func InitGameParam() {
|
||||||
if GameParamData.CreatePrivateSceneCnt == 0 {
|
if GameParamData.CreatePrivateSceneCnt == 0 {
|
||||||
GameParamData.CreatePrivateSceneCnt = 20
|
GameParamData.CreatePrivateSceneCnt = 20
|
||||||
}
|
}
|
||||||
|
if GameParamData.PrivateSceneLogLimit == 0 {
|
||||||
|
GameParamData.PrivateSceneLogLimit = 7000
|
||||||
|
}
|
||||||
|
if GameParamData.PrivateSceneFreeDistroySec == 0 {
|
||||||
|
GameParamData.PrivateSceneFreeDistroySec = 600
|
||||||
|
}
|
||||||
|
if GameParamData.PrivateSceneDestroyTax == 0 {
|
||||||
|
GameParamData.PrivateSceneDestroyTax = 5
|
||||||
|
}
|
||||||
|
if len(GameParamData.NumOfGamesConfig) == 0 {
|
||||||
|
GameParamData.NumOfGamesConfig = []int32{5, 10, 20, 50}
|
||||||
|
}
|
||||||
|
if GameParamData.CoinPoolMinOutRate == 0 {
|
||||||
|
GameParamData.CoinPoolMinOutRate = 33
|
||||||
|
}
|
||||||
|
|
||||||
|
if GameParamData.CoinPoolMaxOutRate == 0 {
|
||||||
|
GameParamData.CoinPoolMaxOutRate = 66
|
||||||
|
}
|
||||||
|
|
||||||
if GameParamData.PlayerWatchNum <= 2 {
|
if GameParamData.PlayerWatchNum <= 2 {
|
||||||
GameParamData.PlayerWatchNum = 20
|
GameParamData.PlayerWatchNum = 20
|
||||||
}
|
}
|
||||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -42,7 +42,7 @@ enum SSPacketID {
|
||||||
PACKET_WG_AUDIENCESIT = 1123;
|
PACKET_WG_AUDIENCESIT = 1123;
|
||||||
PACKET_WG_RECHARGE = 1124;
|
PACKET_WG_RECHARGE = 1124;
|
||||||
PACKET_GW_SCENESTATE = 1125;
|
PACKET_GW_SCENESTATE = 1125;
|
||||||
PACKET_WG_GRACE_DESTROYSCENE = 1126; // 废弃
|
PACKET_WG_GRACE_DESTROYSCENE = 1126;
|
||||||
PACKET_GW_SCENEEND = 1127;
|
PACKET_GW_SCENEEND = 1127;
|
||||||
PACKET_GW_FISHRECORD = 1128;
|
PACKET_GW_FISHRECORD = 1128;
|
||||||
PACKET_GW_PLAYERFORCELEAVE = 1129;
|
PACKET_GW_PLAYERFORCELEAVE = 1129;
|
||||||
|
@ -189,16 +189,20 @@ message WGCreateScene {
|
||||||
|
|
||||||
//PACKET_WG_DESTROYSCENE
|
//PACKET_WG_DESTROYSCENE
|
||||||
message WGDestroyScene {
|
message WGDestroyScene {
|
||||||
repeated int64 Ids = 1;
|
int32 SceneId = 1;
|
||||||
bool IsGrace = 2; // 游戏结束后删除
|
bool IsCompleted = 2;
|
||||||
}
|
}
|
||||||
|
|
||||||
//PACKET_GW_DESTROYSCENE
|
//PACKET_GW_DESTROYSCENE
|
||||||
message GWDestroyScene {
|
message GWDestroyScene {
|
||||||
int64 SceneId = 1;
|
int32 SceneId = 1;
|
||||||
bool IsCompleted = 2;
|
bool IsCompleted = 2;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//PACKET_WG_GRACE_DESTROYSCENE
|
||||||
|
message WGGraceDestroyScene {
|
||||||
|
repeated int32 Ids = 1;
|
||||||
|
}
|
||||||
message RebateTask {
|
message RebateTask {
|
||||||
bool RebateSwitch = 1; //返利开关
|
bool RebateSwitch = 1; //返利开关
|
||||||
repeated string RebateGameCfg = 2; //已打开的游戏配置 gameid+gamemode
|
repeated string RebateGameCfg = 2; //已打开的游戏配置 gameid+gamemode
|
||||||
|
|
|
@ -398,7 +398,6 @@ type TMInfo struct {
|
||||||
Rule string `protobuf:"bytes,19,opt,name=Rule,proto3" json:"Rule,omitempty"`
|
Rule string `protobuf:"bytes,19,opt,name=Rule,proto3" json:"Rule,omitempty"`
|
||||||
SortId int32 `protobuf:"varint,20,opt,name=SortId,proto3" json:"SortId,omitempty"`
|
SortId int32 `protobuf:"varint,20,opt,name=SortId,proto3" json:"SortId,omitempty"`
|
||||||
OnChannelName []string `protobuf:"bytes,21,rep,name=OnChannelName,proto3" json:"OnChannelName,omitempty"` //在哪个渠道开启
|
OnChannelName []string `protobuf:"bytes,21,rep,name=OnChannelName,proto3" json:"OnChannelName,omitempty"` //在哪个渠道开启
|
||||||
ShowId int32 `protobuf:"varint,22,opt,name=ShowId,proto3" json:"ShowId,omitempty"` // 比赛区分
|
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *TMInfo) Reset() {
|
func (x *TMInfo) Reset() {
|
||||||
|
@ -580,85 +579,7 @@ func (x *TMInfo) GetOnChannelName() []string {
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *TMInfo) GetShowId() int32 {
|
//比赛场场次 激战人数刷新也走这个
|
||||||
if x != nil {
|
|
||||||
return x.ShowId
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
type MatchTypeInfo struct {
|
|
||||||
state protoimpl.MessageState
|
|
||||||
sizeCache protoimpl.SizeCache
|
|
||||||
unknownFields protoimpl.UnknownFields
|
|
||||||
|
|
||||||
Name string `protobuf:"bytes,1,opt,name=Name,proto3" json:"Name,omitempty"` // 名称
|
|
||||||
SortId int32 `protobuf:"varint,2,opt,name=SortId,proto3" json:"SortId,omitempty"` // 排序序号
|
|
||||||
On bool `protobuf:"varint,3,opt,name=On,proto3" json:"On,omitempty"` // 开关
|
|
||||||
Id int32 `protobuf:"varint,4,opt,name=Id,proto3" json:"Id,omitempty"` // 类型id
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *MatchTypeInfo) Reset() {
|
|
||||||
*x = MatchTypeInfo{}
|
|
||||||
if protoimpl.UnsafeEnabled {
|
|
||||||
mi := &file_tournament_proto_msgTypes[4]
|
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
||||||
ms.StoreMessageInfo(mi)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *MatchTypeInfo) String() string {
|
|
||||||
return protoimpl.X.MessageStringOf(x)
|
|
||||||
}
|
|
||||||
|
|
||||||
func (*MatchTypeInfo) ProtoMessage() {}
|
|
||||||
|
|
||||||
func (x *MatchTypeInfo) ProtoReflect() protoreflect.Message {
|
|
||||||
mi := &file_tournament_proto_msgTypes[4]
|
|
||||||
if protoimpl.UnsafeEnabled && x != nil {
|
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
||||||
if ms.LoadMessageInfo() == nil {
|
|
||||||
ms.StoreMessageInfo(mi)
|
|
||||||
}
|
|
||||||
return ms
|
|
||||||
}
|
|
||||||
return mi.MessageOf(x)
|
|
||||||
}
|
|
||||||
|
|
||||||
// Deprecated: Use MatchTypeInfo.ProtoReflect.Descriptor instead.
|
|
||||||
func (*MatchTypeInfo) Descriptor() ([]byte, []int) {
|
|
||||||
return file_tournament_proto_rawDescGZIP(), []int{4}
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *MatchTypeInfo) GetName() string {
|
|
||||||
if x != nil {
|
|
||||||
return x.Name
|
|
||||||
}
|
|
||||||
return ""
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *MatchTypeInfo) GetSortId() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.SortId
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *MatchTypeInfo) GetOn() bool {
|
|
||||||
if x != nil {
|
|
||||||
return x.On
|
|
||||||
}
|
|
||||||
return false
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *MatchTypeInfo) GetId() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.Id
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
//比赛场场次
|
|
||||||
//PACKET_TM_SCTMInfos
|
//PACKET_TM_SCTMInfos
|
||||||
type SCTMInfos struct {
|
type SCTMInfos struct {
|
||||||
state protoimpl.MessageState
|
state protoimpl.MessageState
|
||||||
|
@ -666,13 +587,13 @@ type SCTMInfos struct {
|
||||||
unknownFields protoimpl.UnknownFields
|
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 []*MatchTypeInfo `protobuf:"bytes,2,rep,name=TypeList,proto3" json:"TypeList,omitempty"` // 比赛类型列表
|
TypeList []int32 `protobuf:"varint,2,rep,packed,name=TypeList,proto3" json:"TypeList,omitempty"` // 所有玩法类型 1.锦标赛 2.实物赛 3.vip比赛 4.话费赛
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *SCTMInfos) Reset() {
|
func (x *SCTMInfos) Reset() {
|
||||||
*x = SCTMInfos{}
|
*x = SCTMInfos{}
|
||||||
if protoimpl.UnsafeEnabled {
|
if protoimpl.UnsafeEnabled {
|
||||||
mi := &file_tournament_proto_msgTypes[5]
|
mi := &file_tournament_proto_msgTypes[4]
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
ms.StoreMessageInfo(mi)
|
ms.StoreMessageInfo(mi)
|
||||||
}
|
}
|
||||||
|
@ -685,7 +606,7 @@ func (x *SCTMInfos) String() string {
|
||||||
func (*SCTMInfos) ProtoMessage() {}
|
func (*SCTMInfos) ProtoMessage() {}
|
||||||
|
|
||||||
func (x *SCTMInfos) ProtoReflect() protoreflect.Message {
|
func (x *SCTMInfos) ProtoReflect() protoreflect.Message {
|
||||||
mi := &file_tournament_proto_msgTypes[5]
|
mi := &file_tournament_proto_msgTypes[4]
|
||||||
if protoimpl.UnsafeEnabled && x != nil {
|
if protoimpl.UnsafeEnabled && x != nil {
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
if ms.LoadMessageInfo() == nil {
|
if ms.LoadMessageInfo() == nil {
|
||||||
|
@ -698,7 +619,7 @@ func (x *SCTMInfos) ProtoReflect() protoreflect.Message {
|
||||||
|
|
||||||
// Deprecated: Use SCTMInfos.ProtoReflect.Descriptor instead.
|
// Deprecated: Use SCTMInfos.ProtoReflect.Descriptor instead.
|
||||||
func (*SCTMInfos) Descriptor() ([]byte, []int) {
|
func (*SCTMInfos) Descriptor() ([]byte, []int) {
|
||||||
return file_tournament_proto_rawDescGZIP(), []int{5}
|
return file_tournament_proto_rawDescGZIP(), []int{4}
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *SCTMInfos) GetTMInfo() []*TMInfo {
|
func (x *SCTMInfos) GetTMInfo() []*TMInfo {
|
||||||
|
@ -708,7 +629,7 @@ func (x *SCTMInfos) GetTMInfo() []*TMInfo {
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *SCTMInfos) GetTypeList() []*MatchTypeInfo {
|
func (x *SCTMInfos) GetTypeList() []int32 {
|
||||||
if x != nil {
|
if x != nil {
|
||||||
return x.TypeList
|
return x.TypeList
|
||||||
}
|
}
|
||||||
|
@ -728,7 +649,7 @@ type CSTMRankList struct {
|
||||||
func (x *CSTMRankList) Reset() {
|
func (x *CSTMRankList) Reset() {
|
||||||
*x = CSTMRankList{}
|
*x = CSTMRankList{}
|
||||||
if protoimpl.UnsafeEnabled {
|
if protoimpl.UnsafeEnabled {
|
||||||
mi := &file_tournament_proto_msgTypes[6]
|
mi := &file_tournament_proto_msgTypes[5]
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
ms.StoreMessageInfo(mi)
|
ms.StoreMessageInfo(mi)
|
||||||
}
|
}
|
||||||
|
@ -741,7 +662,7 @@ func (x *CSTMRankList) String() string {
|
||||||
func (*CSTMRankList) ProtoMessage() {}
|
func (*CSTMRankList) ProtoMessage() {}
|
||||||
|
|
||||||
func (x *CSTMRankList) ProtoReflect() protoreflect.Message {
|
func (x *CSTMRankList) ProtoReflect() protoreflect.Message {
|
||||||
mi := &file_tournament_proto_msgTypes[6]
|
mi := &file_tournament_proto_msgTypes[5]
|
||||||
if protoimpl.UnsafeEnabled && x != nil {
|
if protoimpl.UnsafeEnabled && x != nil {
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
if ms.LoadMessageInfo() == nil {
|
if ms.LoadMessageInfo() == nil {
|
||||||
|
@ -754,7 +675,7 @@ func (x *CSTMRankList) ProtoReflect() protoreflect.Message {
|
||||||
|
|
||||||
// Deprecated: Use CSTMRankList.ProtoReflect.Descriptor instead.
|
// Deprecated: Use CSTMRankList.ProtoReflect.Descriptor instead.
|
||||||
func (*CSTMRankList) Descriptor() ([]byte, []int) {
|
func (*CSTMRankList) Descriptor() ([]byte, []int) {
|
||||||
return file_tournament_proto_rawDescGZIP(), []int{6}
|
return file_tournament_proto_rawDescGZIP(), []int{5}
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *CSTMRankList) GetTMId() int32 {
|
func (x *CSTMRankList) GetTMId() int32 {
|
||||||
|
@ -777,7 +698,7 @@ type TMRank struct {
|
||||||
func (x *TMRank) Reset() {
|
func (x *TMRank) Reset() {
|
||||||
*x = TMRank{}
|
*x = TMRank{}
|
||||||
if protoimpl.UnsafeEnabled {
|
if protoimpl.UnsafeEnabled {
|
||||||
mi := &file_tournament_proto_msgTypes[7]
|
mi := &file_tournament_proto_msgTypes[6]
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
ms.StoreMessageInfo(mi)
|
ms.StoreMessageInfo(mi)
|
||||||
}
|
}
|
||||||
|
@ -790,7 +711,7 @@ func (x *TMRank) String() string {
|
||||||
func (*TMRank) ProtoMessage() {}
|
func (*TMRank) ProtoMessage() {}
|
||||||
|
|
||||||
func (x *TMRank) ProtoReflect() protoreflect.Message {
|
func (x *TMRank) ProtoReflect() protoreflect.Message {
|
||||||
mi := &file_tournament_proto_msgTypes[7]
|
mi := &file_tournament_proto_msgTypes[6]
|
||||||
if protoimpl.UnsafeEnabled && x != nil {
|
if protoimpl.UnsafeEnabled && x != nil {
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
if ms.LoadMessageInfo() == nil {
|
if ms.LoadMessageInfo() == nil {
|
||||||
|
@ -803,7 +724,7 @@ func (x *TMRank) ProtoReflect() protoreflect.Message {
|
||||||
|
|
||||||
// Deprecated: Use TMRank.ProtoReflect.Descriptor instead.
|
// Deprecated: Use TMRank.ProtoReflect.Descriptor instead.
|
||||||
func (*TMRank) Descriptor() ([]byte, []int) {
|
func (*TMRank) Descriptor() ([]byte, []int) {
|
||||||
return file_tournament_proto_rawDescGZIP(), []int{7}
|
return file_tournament_proto_rawDescGZIP(), []int{6}
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *TMRank) GetRankId() int32 {
|
func (x *TMRank) GetRankId() int32 {
|
||||||
|
@ -841,7 +762,7 @@ type SCTMRankList struct {
|
||||||
func (x *SCTMRankList) Reset() {
|
func (x *SCTMRankList) Reset() {
|
||||||
*x = SCTMRankList{}
|
*x = SCTMRankList{}
|
||||||
if protoimpl.UnsafeEnabled {
|
if protoimpl.UnsafeEnabled {
|
||||||
mi := &file_tournament_proto_msgTypes[8]
|
mi := &file_tournament_proto_msgTypes[7]
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
ms.StoreMessageInfo(mi)
|
ms.StoreMessageInfo(mi)
|
||||||
}
|
}
|
||||||
|
@ -854,7 +775,7 @@ func (x *SCTMRankList) String() string {
|
||||||
func (*SCTMRankList) ProtoMessage() {}
|
func (*SCTMRankList) ProtoMessage() {}
|
||||||
|
|
||||||
func (x *SCTMRankList) ProtoReflect() protoreflect.Message {
|
func (x *SCTMRankList) ProtoReflect() protoreflect.Message {
|
||||||
mi := &file_tournament_proto_msgTypes[8]
|
mi := &file_tournament_proto_msgTypes[7]
|
||||||
if protoimpl.UnsafeEnabled && x != nil {
|
if protoimpl.UnsafeEnabled && x != nil {
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
if ms.LoadMessageInfo() == nil {
|
if ms.LoadMessageInfo() == nil {
|
||||||
|
@ -867,7 +788,7 @@ func (x *SCTMRankList) ProtoReflect() protoreflect.Message {
|
||||||
|
|
||||||
// Deprecated: Use SCTMRankList.ProtoReflect.Descriptor instead.
|
// Deprecated: Use SCTMRankList.ProtoReflect.Descriptor instead.
|
||||||
func (*SCTMRankList) Descriptor() ([]byte, []int) {
|
func (*SCTMRankList) Descriptor() ([]byte, []int) {
|
||||||
return file_tournament_proto_rawDescGZIP(), []int{8}
|
return file_tournament_proto_rawDescGZIP(), []int{7}
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *SCTMRankList) GetTMId() int32 {
|
func (x *SCTMRankList) GetTMId() int32 {
|
||||||
|
@ -905,7 +826,7 @@ type CSSignRace struct {
|
||||||
func (x *CSSignRace) Reset() {
|
func (x *CSSignRace) Reset() {
|
||||||
*x = CSSignRace{}
|
*x = CSSignRace{}
|
||||||
if protoimpl.UnsafeEnabled {
|
if protoimpl.UnsafeEnabled {
|
||||||
mi := &file_tournament_proto_msgTypes[9]
|
mi := &file_tournament_proto_msgTypes[8]
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
ms.StoreMessageInfo(mi)
|
ms.StoreMessageInfo(mi)
|
||||||
}
|
}
|
||||||
|
@ -918,7 +839,7 @@ func (x *CSSignRace) String() string {
|
||||||
func (*CSSignRace) ProtoMessage() {}
|
func (*CSSignRace) ProtoMessage() {}
|
||||||
|
|
||||||
func (x *CSSignRace) ProtoReflect() protoreflect.Message {
|
func (x *CSSignRace) ProtoReflect() protoreflect.Message {
|
||||||
mi := &file_tournament_proto_msgTypes[9]
|
mi := &file_tournament_proto_msgTypes[8]
|
||||||
if protoimpl.UnsafeEnabled && x != nil {
|
if protoimpl.UnsafeEnabled && x != nil {
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
if ms.LoadMessageInfo() == nil {
|
if ms.LoadMessageInfo() == nil {
|
||||||
|
@ -931,7 +852,7 @@ func (x *CSSignRace) ProtoReflect() protoreflect.Message {
|
||||||
|
|
||||||
// Deprecated: Use CSSignRace.ProtoReflect.Descriptor instead.
|
// Deprecated: Use CSSignRace.ProtoReflect.Descriptor instead.
|
||||||
func (*CSSignRace) Descriptor() ([]byte, []int) {
|
func (*CSSignRace) Descriptor() ([]byte, []int) {
|
||||||
return file_tournament_proto_rawDescGZIP(), []int{9}
|
return file_tournament_proto_rawDescGZIP(), []int{8}
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *CSSignRace) GetOpCode() int32 {
|
func (x *CSSignRace) GetOpCode() int32 {
|
||||||
|
@ -962,7 +883,7 @@ type SCSignRace struct {
|
||||||
func (x *SCSignRace) Reset() {
|
func (x *SCSignRace) Reset() {
|
||||||
*x = SCSignRace{}
|
*x = SCSignRace{}
|
||||||
if protoimpl.UnsafeEnabled {
|
if protoimpl.UnsafeEnabled {
|
||||||
mi := &file_tournament_proto_msgTypes[10]
|
mi := &file_tournament_proto_msgTypes[9]
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
ms.StoreMessageInfo(mi)
|
ms.StoreMessageInfo(mi)
|
||||||
}
|
}
|
||||||
|
@ -975,7 +896,7 @@ func (x *SCSignRace) String() string {
|
||||||
func (*SCSignRace) ProtoMessage() {}
|
func (*SCSignRace) ProtoMessage() {}
|
||||||
|
|
||||||
func (x *SCSignRace) ProtoReflect() protoreflect.Message {
|
func (x *SCSignRace) ProtoReflect() protoreflect.Message {
|
||||||
mi := &file_tournament_proto_msgTypes[10]
|
mi := &file_tournament_proto_msgTypes[9]
|
||||||
if protoimpl.UnsafeEnabled && x != nil {
|
if protoimpl.UnsafeEnabled && x != nil {
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
if ms.LoadMessageInfo() == nil {
|
if ms.LoadMessageInfo() == nil {
|
||||||
|
@ -988,7 +909,7 @@ func (x *SCSignRace) ProtoReflect() protoreflect.Message {
|
||||||
|
|
||||||
// Deprecated: Use SCSignRace.ProtoReflect.Descriptor instead.
|
// Deprecated: Use SCSignRace.ProtoReflect.Descriptor instead.
|
||||||
func (*SCSignRace) Descriptor() ([]byte, []int) {
|
func (*SCSignRace) Descriptor() ([]byte, []int) {
|
||||||
return file_tournament_proto_rawDescGZIP(), []int{10}
|
return file_tournament_proto_rawDescGZIP(), []int{9}
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *SCSignRace) GetOpCode() int32 {
|
func (x *SCSignRace) GetOpCode() int32 {
|
||||||
|
@ -1026,7 +947,7 @@ type SCSyncSignNum struct {
|
||||||
func (x *SCSyncSignNum) Reset() {
|
func (x *SCSyncSignNum) Reset() {
|
||||||
*x = SCSyncSignNum{}
|
*x = SCSyncSignNum{}
|
||||||
if protoimpl.UnsafeEnabled {
|
if protoimpl.UnsafeEnabled {
|
||||||
mi := &file_tournament_proto_msgTypes[11]
|
mi := &file_tournament_proto_msgTypes[10]
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
ms.StoreMessageInfo(mi)
|
ms.StoreMessageInfo(mi)
|
||||||
}
|
}
|
||||||
|
@ -1039,7 +960,7 @@ func (x *SCSyncSignNum) String() string {
|
||||||
func (*SCSyncSignNum) ProtoMessage() {}
|
func (*SCSyncSignNum) ProtoMessage() {}
|
||||||
|
|
||||||
func (x *SCSyncSignNum) ProtoReflect() protoreflect.Message {
|
func (x *SCSyncSignNum) ProtoReflect() protoreflect.Message {
|
||||||
mi := &file_tournament_proto_msgTypes[11]
|
mi := &file_tournament_proto_msgTypes[10]
|
||||||
if protoimpl.UnsafeEnabled && x != nil {
|
if protoimpl.UnsafeEnabled && x != nil {
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
if ms.LoadMessageInfo() == nil {
|
if ms.LoadMessageInfo() == nil {
|
||||||
|
@ -1052,7 +973,7 @@ func (x *SCSyncSignNum) ProtoReflect() protoreflect.Message {
|
||||||
|
|
||||||
// Deprecated: Use SCSyncSignNum.ProtoReflect.Descriptor instead.
|
// Deprecated: Use SCSyncSignNum.ProtoReflect.Descriptor instead.
|
||||||
func (*SCSyncSignNum) Descriptor() ([]byte, []int) {
|
func (*SCSyncSignNum) Descriptor() ([]byte, []int) {
|
||||||
return file_tournament_proto_rawDescGZIP(), []int{11}
|
return file_tournament_proto_rawDescGZIP(), []int{10}
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *SCSyncSignNum) GetSignNum() int32 {
|
func (x *SCSyncSignNum) GetSignNum() int32 {
|
||||||
|
@ -1082,7 +1003,7 @@ type SCTMStart struct {
|
||||||
func (x *SCTMStart) Reset() {
|
func (x *SCTMStart) Reset() {
|
||||||
*x = SCTMStart{}
|
*x = SCTMStart{}
|
||||||
if protoimpl.UnsafeEnabled {
|
if protoimpl.UnsafeEnabled {
|
||||||
mi := &file_tournament_proto_msgTypes[12]
|
mi := &file_tournament_proto_msgTypes[11]
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
ms.StoreMessageInfo(mi)
|
ms.StoreMessageInfo(mi)
|
||||||
}
|
}
|
||||||
|
@ -1095,7 +1016,7 @@ func (x *SCTMStart) String() string {
|
||||||
func (*SCTMStart) ProtoMessage() {}
|
func (*SCTMStart) ProtoMessage() {}
|
||||||
|
|
||||||
func (x *SCTMStart) ProtoReflect() protoreflect.Message {
|
func (x *SCTMStart) ProtoReflect() protoreflect.Message {
|
||||||
mi := &file_tournament_proto_msgTypes[12]
|
mi := &file_tournament_proto_msgTypes[11]
|
||||||
if protoimpl.UnsafeEnabled && x != nil {
|
if protoimpl.UnsafeEnabled && x != nil {
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
if ms.LoadMessageInfo() == nil {
|
if ms.LoadMessageInfo() == nil {
|
||||||
|
@ -1108,7 +1029,7 @@ func (x *SCTMStart) ProtoReflect() protoreflect.Message {
|
||||||
|
|
||||||
// Deprecated: Use SCTMStart.ProtoReflect.Descriptor instead.
|
// Deprecated: Use SCTMStart.ProtoReflect.Descriptor instead.
|
||||||
func (*SCTMStart) Descriptor() ([]byte, []int) {
|
func (*SCTMStart) Descriptor() ([]byte, []int) {
|
||||||
return file_tournament_proto_rawDescGZIP(), []int{12}
|
return file_tournament_proto_rawDescGZIP(), []int{11}
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *SCTMStart) GetMatchId() int32 {
|
func (x *SCTMStart) GetMatchId() int32 {
|
||||||
|
@ -1131,7 +1052,7 @@ type RankAward struct {
|
||||||
func (x *RankAward) Reset() {
|
func (x *RankAward) Reset() {
|
||||||
*x = RankAward{}
|
*x = RankAward{}
|
||||||
if protoimpl.UnsafeEnabled {
|
if protoimpl.UnsafeEnabled {
|
||||||
mi := &file_tournament_proto_msgTypes[13]
|
mi := &file_tournament_proto_msgTypes[12]
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
ms.StoreMessageInfo(mi)
|
ms.StoreMessageInfo(mi)
|
||||||
}
|
}
|
||||||
|
@ -1144,7 +1065,7 @@ func (x *RankAward) String() string {
|
||||||
func (*RankAward) ProtoMessage() {}
|
func (*RankAward) ProtoMessage() {}
|
||||||
|
|
||||||
func (x *RankAward) ProtoReflect() protoreflect.Message {
|
func (x *RankAward) ProtoReflect() protoreflect.Message {
|
||||||
mi := &file_tournament_proto_msgTypes[13]
|
mi := &file_tournament_proto_msgTypes[12]
|
||||||
if protoimpl.UnsafeEnabled && x != nil {
|
if protoimpl.UnsafeEnabled && x != nil {
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
if ms.LoadMessageInfo() == nil {
|
if ms.LoadMessageInfo() == nil {
|
||||||
|
@ -1157,7 +1078,7 @@ func (x *RankAward) ProtoReflect() protoreflect.Message {
|
||||||
|
|
||||||
// Deprecated: Use RankAward.ProtoReflect.Descriptor instead.
|
// Deprecated: Use RankAward.ProtoReflect.Descriptor instead.
|
||||||
func (*RankAward) Descriptor() ([]byte, []int) {
|
func (*RankAward) Descriptor() ([]byte, []int) {
|
||||||
return file_tournament_proto_rawDescGZIP(), []int{13}
|
return file_tournament_proto_rawDescGZIP(), []int{12}
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *RankAward) GetItemInfo() []*ItemInfo {
|
func (x *RankAward) GetItemInfo() []*ItemInfo {
|
||||||
|
@ -1202,7 +1123,7 @@ type SCPromotionInfo struct {
|
||||||
func (x *SCPromotionInfo) Reset() {
|
func (x *SCPromotionInfo) Reset() {
|
||||||
*x = SCPromotionInfo{}
|
*x = SCPromotionInfo{}
|
||||||
if protoimpl.UnsafeEnabled {
|
if protoimpl.UnsafeEnabled {
|
||||||
mi := &file_tournament_proto_msgTypes[14]
|
mi := &file_tournament_proto_msgTypes[13]
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
ms.StoreMessageInfo(mi)
|
ms.StoreMessageInfo(mi)
|
||||||
}
|
}
|
||||||
|
@ -1215,7 +1136,7 @@ func (x *SCPromotionInfo) String() string {
|
||||||
func (*SCPromotionInfo) ProtoMessage() {}
|
func (*SCPromotionInfo) ProtoMessage() {}
|
||||||
|
|
||||||
func (x *SCPromotionInfo) ProtoReflect() protoreflect.Message {
|
func (x *SCPromotionInfo) ProtoReflect() protoreflect.Message {
|
||||||
mi := &file_tournament_proto_msgTypes[14]
|
mi := &file_tournament_proto_msgTypes[13]
|
||||||
if protoimpl.UnsafeEnabled && x != nil {
|
if protoimpl.UnsafeEnabled && x != nil {
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
if ms.LoadMessageInfo() == nil {
|
if ms.LoadMessageInfo() == nil {
|
||||||
|
@ -1228,7 +1149,7 @@ func (x *SCPromotionInfo) ProtoReflect() protoreflect.Message {
|
||||||
|
|
||||||
// Deprecated: Use SCPromotionInfo.ProtoReflect.Descriptor instead.
|
// Deprecated: Use SCPromotionInfo.ProtoReflect.Descriptor instead.
|
||||||
func (*SCPromotionInfo) Descriptor() ([]byte, []int) {
|
func (*SCPromotionInfo) Descriptor() ([]byte, []int) {
|
||||||
return file_tournament_proto_rawDescGZIP(), []int{14}
|
return file_tournament_proto_rawDescGZIP(), []int{13}
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *SCPromotionInfo) GetRetCode() int32 {
|
func (x *SCPromotionInfo) GetRetCode() int32 {
|
||||||
|
@ -1304,7 +1225,7 @@ type CSTMSeasonInfo struct {
|
||||||
func (x *CSTMSeasonInfo) Reset() {
|
func (x *CSTMSeasonInfo) Reset() {
|
||||||
*x = CSTMSeasonInfo{}
|
*x = CSTMSeasonInfo{}
|
||||||
if protoimpl.UnsafeEnabled {
|
if protoimpl.UnsafeEnabled {
|
||||||
mi := &file_tournament_proto_msgTypes[15]
|
mi := &file_tournament_proto_msgTypes[14]
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
ms.StoreMessageInfo(mi)
|
ms.StoreMessageInfo(mi)
|
||||||
}
|
}
|
||||||
|
@ -1317,7 +1238,7 @@ func (x *CSTMSeasonInfo) String() string {
|
||||||
func (*CSTMSeasonInfo) ProtoMessage() {}
|
func (*CSTMSeasonInfo) ProtoMessage() {}
|
||||||
|
|
||||||
func (x *CSTMSeasonInfo) ProtoReflect() protoreflect.Message {
|
func (x *CSTMSeasonInfo) ProtoReflect() protoreflect.Message {
|
||||||
mi := &file_tournament_proto_msgTypes[15]
|
mi := &file_tournament_proto_msgTypes[14]
|
||||||
if protoimpl.UnsafeEnabled && x != nil {
|
if protoimpl.UnsafeEnabled && x != nil {
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
if ms.LoadMessageInfo() == nil {
|
if ms.LoadMessageInfo() == nil {
|
||||||
|
@ -1330,7 +1251,7 @@ func (x *CSTMSeasonInfo) ProtoReflect() protoreflect.Message {
|
||||||
|
|
||||||
// Deprecated: Use CSTMSeasonInfo.ProtoReflect.Descriptor instead.
|
// Deprecated: Use CSTMSeasonInfo.ProtoReflect.Descriptor instead.
|
||||||
func (*CSTMSeasonInfo) Descriptor() ([]byte, []int) {
|
func (*CSTMSeasonInfo) Descriptor() ([]byte, []int) {
|
||||||
return file_tournament_proto_rawDescGZIP(), []int{15}
|
return file_tournament_proto_rawDescGZIP(), []int{14}
|
||||||
}
|
}
|
||||||
|
|
||||||
type SCTMSeasonInfo struct {
|
type SCTMSeasonInfo struct {
|
||||||
|
@ -1348,7 +1269,7 @@ type SCTMSeasonInfo struct {
|
||||||
func (x *SCTMSeasonInfo) Reset() {
|
func (x *SCTMSeasonInfo) Reset() {
|
||||||
*x = SCTMSeasonInfo{}
|
*x = SCTMSeasonInfo{}
|
||||||
if protoimpl.UnsafeEnabled {
|
if protoimpl.UnsafeEnabled {
|
||||||
mi := &file_tournament_proto_msgTypes[16]
|
mi := &file_tournament_proto_msgTypes[15]
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
ms.StoreMessageInfo(mi)
|
ms.StoreMessageInfo(mi)
|
||||||
}
|
}
|
||||||
|
@ -1361,7 +1282,7 @@ func (x *SCTMSeasonInfo) String() string {
|
||||||
func (*SCTMSeasonInfo) ProtoMessage() {}
|
func (*SCTMSeasonInfo) ProtoMessage() {}
|
||||||
|
|
||||||
func (x *SCTMSeasonInfo) ProtoReflect() protoreflect.Message {
|
func (x *SCTMSeasonInfo) ProtoReflect() protoreflect.Message {
|
||||||
mi := &file_tournament_proto_msgTypes[16]
|
mi := &file_tournament_proto_msgTypes[15]
|
||||||
if protoimpl.UnsafeEnabled && x != nil {
|
if protoimpl.UnsafeEnabled && x != nil {
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
if ms.LoadMessageInfo() == nil {
|
if ms.LoadMessageInfo() == nil {
|
||||||
|
@ -1374,7 +1295,7 @@ func (x *SCTMSeasonInfo) ProtoReflect() protoreflect.Message {
|
||||||
|
|
||||||
// Deprecated: Use SCTMSeasonInfo.ProtoReflect.Descriptor instead.
|
// Deprecated: Use SCTMSeasonInfo.ProtoReflect.Descriptor instead.
|
||||||
func (*SCTMSeasonInfo) Descriptor() ([]byte, []int) {
|
func (*SCTMSeasonInfo) Descriptor() ([]byte, []int) {
|
||||||
return file_tournament_proto_rawDescGZIP(), []int{16}
|
return file_tournament_proto_rawDescGZIP(), []int{15}
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *SCTMSeasonInfo) GetId() int32 {
|
func (x *SCTMSeasonInfo) GetId() int32 {
|
||||||
|
@ -1427,7 +1348,7 @@ type SeasonRank struct {
|
||||||
func (x *SeasonRank) Reset() {
|
func (x *SeasonRank) Reset() {
|
||||||
*x = SeasonRank{}
|
*x = SeasonRank{}
|
||||||
if protoimpl.UnsafeEnabled {
|
if protoimpl.UnsafeEnabled {
|
||||||
mi := &file_tournament_proto_msgTypes[17]
|
mi := &file_tournament_proto_msgTypes[16]
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
ms.StoreMessageInfo(mi)
|
ms.StoreMessageInfo(mi)
|
||||||
}
|
}
|
||||||
|
@ -1440,7 +1361,7 @@ func (x *SeasonRank) String() string {
|
||||||
func (*SeasonRank) ProtoMessage() {}
|
func (*SeasonRank) ProtoMessage() {}
|
||||||
|
|
||||||
func (x *SeasonRank) ProtoReflect() protoreflect.Message {
|
func (x *SeasonRank) ProtoReflect() protoreflect.Message {
|
||||||
mi := &file_tournament_proto_msgTypes[17]
|
mi := &file_tournament_proto_msgTypes[16]
|
||||||
if protoimpl.UnsafeEnabled && x != nil {
|
if protoimpl.UnsafeEnabled && x != nil {
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
if ms.LoadMessageInfo() == nil {
|
if ms.LoadMessageInfo() == nil {
|
||||||
|
@ -1453,7 +1374,7 @@ func (x *SeasonRank) ProtoReflect() protoreflect.Message {
|
||||||
|
|
||||||
// Deprecated: Use SeasonRank.ProtoReflect.Descriptor instead.
|
// Deprecated: Use SeasonRank.ProtoReflect.Descriptor instead.
|
||||||
func (*SeasonRank) Descriptor() ([]byte, []int) {
|
func (*SeasonRank) Descriptor() ([]byte, []int) {
|
||||||
return file_tournament_proto_rawDescGZIP(), []int{17}
|
return file_tournament_proto_rawDescGZIP(), []int{16}
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *SeasonRank) GetSnid() int32 {
|
func (x *SeasonRank) GetSnid() int32 {
|
||||||
|
@ -1493,7 +1414,7 @@ type CSTMSeasonRank struct {
|
||||||
func (x *CSTMSeasonRank) Reset() {
|
func (x *CSTMSeasonRank) Reset() {
|
||||||
*x = CSTMSeasonRank{}
|
*x = CSTMSeasonRank{}
|
||||||
if protoimpl.UnsafeEnabled {
|
if protoimpl.UnsafeEnabled {
|
||||||
mi := &file_tournament_proto_msgTypes[18]
|
mi := &file_tournament_proto_msgTypes[17]
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
ms.StoreMessageInfo(mi)
|
ms.StoreMessageInfo(mi)
|
||||||
}
|
}
|
||||||
|
@ -1506,7 +1427,7 @@ func (x *CSTMSeasonRank) String() string {
|
||||||
func (*CSTMSeasonRank) ProtoMessage() {}
|
func (*CSTMSeasonRank) ProtoMessage() {}
|
||||||
|
|
||||||
func (x *CSTMSeasonRank) ProtoReflect() protoreflect.Message {
|
func (x *CSTMSeasonRank) ProtoReflect() protoreflect.Message {
|
||||||
mi := &file_tournament_proto_msgTypes[18]
|
mi := &file_tournament_proto_msgTypes[17]
|
||||||
if protoimpl.UnsafeEnabled && x != nil {
|
if protoimpl.UnsafeEnabled && x != nil {
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
if ms.LoadMessageInfo() == nil {
|
if ms.LoadMessageInfo() == nil {
|
||||||
|
@ -1519,7 +1440,7 @@ func (x *CSTMSeasonRank) ProtoReflect() protoreflect.Message {
|
||||||
|
|
||||||
// Deprecated: Use CSTMSeasonRank.ProtoReflect.Descriptor instead.
|
// Deprecated: Use CSTMSeasonRank.ProtoReflect.Descriptor instead.
|
||||||
func (*CSTMSeasonRank) Descriptor() ([]byte, []int) {
|
func (*CSTMSeasonRank) Descriptor() ([]byte, []int) {
|
||||||
return file_tournament_proto_rawDescGZIP(), []int{18}
|
return file_tournament_proto_rawDescGZIP(), []int{17}
|
||||||
}
|
}
|
||||||
|
|
||||||
type SCTMSeasonRank struct {
|
type SCTMSeasonRank struct {
|
||||||
|
@ -1533,7 +1454,7 @@ type SCTMSeasonRank struct {
|
||||||
func (x *SCTMSeasonRank) Reset() {
|
func (x *SCTMSeasonRank) Reset() {
|
||||||
*x = SCTMSeasonRank{}
|
*x = SCTMSeasonRank{}
|
||||||
if protoimpl.UnsafeEnabled {
|
if protoimpl.UnsafeEnabled {
|
||||||
mi := &file_tournament_proto_msgTypes[19]
|
mi := &file_tournament_proto_msgTypes[18]
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
ms.StoreMessageInfo(mi)
|
ms.StoreMessageInfo(mi)
|
||||||
}
|
}
|
||||||
|
@ -1546,7 +1467,7 @@ func (x *SCTMSeasonRank) String() string {
|
||||||
func (*SCTMSeasonRank) ProtoMessage() {}
|
func (*SCTMSeasonRank) ProtoMessage() {}
|
||||||
|
|
||||||
func (x *SCTMSeasonRank) ProtoReflect() protoreflect.Message {
|
func (x *SCTMSeasonRank) ProtoReflect() protoreflect.Message {
|
||||||
mi := &file_tournament_proto_msgTypes[19]
|
mi := &file_tournament_proto_msgTypes[18]
|
||||||
if protoimpl.UnsafeEnabled && x != nil {
|
if protoimpl.UnsafeEnabled && x != nil {
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
if ms.LoadMessageInfo() == nil {
|
if ms.LoadMessageInfo() == nil {
|
||||||
|
@ -1559,7 +1480,7 @@ func (x *SCTMSeasonRank) ProtoReflect() protoreflect.Message {
|
||||||
|
|
||||||
// Deprecated: Use SCTMSeasonRank.ProtoReflect.Descriptor instead.
|
// Deprecated: Use SCTMSeasonRank.ProtoReflect.Descriptor instead.
|
||||||
func (*SCTMSeasonRank) Descriptor() ([]byte, []int) {
|
func (*SCTMSeasonRank) Descriptor() ([]byte, []int) {
|
||||||
return file_tournament_proto_rawDescGZIP(), []int{19}
|
return file_tournament_proto_rawDescGZIP(), []int{18}
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *SCTMSeasonRank) GetReasonRanks() []*SeasonRank {
|
func (x *SCTMSeasonRank) GetReasonRanks() []*SeasonRank {
|
||||||
|
@ -1581,7 +1502,7 @@ type CSTMSeasonAward struct {
|
||||||
func (x *CSTMSeasonAward) Reset() {
|
func (x *CSTMSeasonAward) Reset() {
|
||||||
*x = CSTMSeasonAward{}
|
*x = CSTMSeasonAward{}
|
||||||
if protoimpl.UnsafeEnabled {
|
if protoimpl.UnsafeEnabled {
|
||||||
mi := &file_tournament_proto_msgTypes[20]
|
mi := &file_tournament_proto_msgTypes[19]
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
ms.StoreMessageInfo(mi)
|
ms.StoreMessageInfo(mi)
|
||||||
}
|
}
|
||||||
|
@ -1594,7 +1515,7 @@ func (x *CSTMSeasonAward) String() string {
|
||||||
func (*CSTMSeasonAward) ProtoMessage() {}
|
func (*CSTMSeasonAward) ProtoMessage() {}
|
||||||
|
|
||||||
func (x *CSTMSeasonAward) ProtoReflect() protoreflect.Message {
|
func (x *CSTMSeasonAward) ProtoReflect() protoreflect.Message {
|
||||||
mi := &file_tournament_proto_msgTypes[20]
|
mi := &file_tournament_proto_msgTypes[19]
|
||||||
if protoimpl.UnsafeEnabled && x != nil {
|
if protoimpl.UnsafeEnabled && x != nil {
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
if ms.LoadMessageInfo() == nil {
|
if ms.LoadMessageInfo() == nil {
|
||||||
|
@ -1607,7 +1528,7 @@ func (x *CSTMSeasonAward) ProtoReflect() protoreflect.Message {
|
||||||
|
|
||||||
// Deprecated: Use CSTMSeasonAward.ProtoReflect.Descriptor instead.
|
// Deprecated: Use CSTMSeasonAward.ProtoReflect.Descriptor instead.
|
||||||
func (*CSTMSeasonAward) Descriptor() ([]byte, []int) {
|
func (*CSTMSeasonAward) Descriptor() ([]byte, []int) {
|
||||||
return file_tournament_proto_rawDescGZIP(), []int{20}
|
return file_tournament_proto_rawDescGZIP(), []int{19}
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *CSTMSeasonAward) GetLv() int32 {
|
func (x *CSTMSeasonAward) GetLv() int32 {
|
||||||
|
@ -1629,7 +1550,7 @@ type SCTMSeasonAward struct {
|
||||||
func (x *SCTMSeasonAward) Reset() {
|
func (x *SCTMSeasonAward) Reset() {
|
||||||
*x = SCTMSeasonAward{}
|
*x = SCTMSeasonAward{}
|
||||||
if protoimpl.UnsafeEnabled {
|
if protoimpl.UnsafeEnabled {
|
||||||
mi := &file_tournament_proto_msgTypes[21]
|
mi := &file_tournament_proto_msgTypes[20]
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
ms.StoreMessageInfo(mi)
|
ms.StoreMessageInfo(mi)
|
||||||
}
|
}
|
||||||
|
@ -1642,7 +1563,7 @@ func (x *SCTMSeasonAward) String() string {
|
||||||
func (*SCTMSeasonAward) ProtoMessage() {}
|
func (*SCTMSeasonAward) ProtoMessage() {}
|
||||||
|
|
||||||
func (x *SCTMSeasonAward) ProtoReflect() protoreflect.Message {
|
func (x *SCTMSeasonAward) ProtoReflect() protoreflect.Message {
|
||||||
mi := &file_tournament_proto_msgTypes[21]
|
mi := &file_tournament_proto_msgTypes[20]
|
||||||
if protoimpl.UnsafeEnabled && x != nil {
|
if protoimpl.UnsafeEnabled && x != nil {
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
if ms.LoadMessageInfo() == nil {
|
if ms.LoadMessageInfo() == nil {
|
||||||
|
@ -1655,7 +1576,7 @@ func (x *SCTMSeasonAward) ProtoReflect() protoreflect.Message {
|
||||||
|
|
||||||
// Deprecated: Use SCTMSeasonAward.ProtoReflect.Descriptor instead.
|
// Deprecated: Use SCTMSeasonAward.ProtoReflect.Descriptor instead.
|
||||||
func (*SCTMSeasonAward) Descriptor() ([]byte, []int) {
|
func (*SCTMSeasonAward) Descriptor() ([]byte, []int) {
|
||||||
return file_tournament_proto_rawDescGZIP(), []int{21}
|
return file_tournament_proto_rawDescGZIP(), []int{20}
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *SCTMSeasonAward) GetLv() int32 {
|
func (x *SCTMSeasonAward) GetLv() int32 {
|
||||||
|
@ -1695,7 +1616,7 @@ var file_tournament_proto_rawDesc = []byte{
|
||||||
0x61, 0x6d, 0x6f, 0x6e, 0x64, 0x12, 0x18, 0x0a, 0x07, 0x55, 0x70, 0x4c, 0x69, 0x6d, 0x69, 0x74,
|
0x61, 0x6d, 0x6f, 0x6e, 0x64, 0x12, 0x18, 0x0a, 0x07, 0x55, 0x70, 0x4c, 0x69, 0x6d, 0x69, 0x74,
|
||||||
0x18, 0x04, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x55, 0x70, 0x4c, 0x69, 0x6d, 0x69, 0x74, 0x12,
|
0x18, 0x04, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x55, 0x70, 0x4c, 0x69, 0x6d, 0x69, 0x74, 0x12,
|
||||||
0x1c, 0x0a, 0x09, 0x44, 0x6f, 0x77, 0x6e, 0x4c, 0x69, 0x6d, 0x69, 0x74, 0x18, 0x05, 0x20, 0x01,
|
0x1c, 0x0a, 0x09, 0x44, 0x6f, 0x77, 0x6e, 0x4c, 0x69, 0x6d, 0x69, 0x74, 0x18, 0x05, 0x20, 0x01,
|
||||||
0x28, 0x05, 0x52, 0x09, 0x44, 0x6f, 0x77, 0x6e, 0x4c, 0x69, 0x6d, 0x69, 0x74, 0x22, 0x96, 0x06,
|
0x28, 0x05, 0x52, 0x09, 0x44, 0x6f, 0x77, 0x6e, 0x4c, 0x69, 0x6d, 0x69, 0x74, 0x22, 0xfe, 0x05,
|
||||||
0x0a, 0x06, 0x54, 0x4d, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x64, 0x18, 0x01,
|
0x0a, 0x06, 0x54, 0x4d, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x64, 0x18, 0x01,
|
||||||
0x20, 0x01, 0x28, 0x05, 0x52, 0x02, 0x49, 0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x47, 0x61, 0x6d, 0x65,
|
0x20, 0x01, 0x28, 0x05, 0x52, 0x02, 0x49, 0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x47, 0x61, 0x6d, 0x65,
|
||||||
0x46, 0x72, 0x65, 0x65, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0a, 0x47, 0x61,
|
0x46, 0x72, 0x65, 0x65, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0a, 0x47, 0x61,
|
||||||
|
@ -1743,21 +1664,12 @@ var file_tournament_proto_rawDesc = []byte{
|
||||||
0x12, 0x16, 0x0a, 0x06, 0x53, 0x6f, 0x72, 0x74, 0x49, 0x64, 0x18, 0x14, 0x20, 0x01, 0x28, 0x05,
|
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,
|
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,
|
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, 0x12, 0x16,
|
0x0d, 0x4f, 0x6e, 0x43, 0x68, 0x61, 0x6e, 0x6e, 0x65, 0x6c, 0x4e, 0x61, 0x6d, 0x65, 0x22, 0x53,
|
||||||
0x0a, 0x06, 0x53, 0x68, 0x6f, 0x77, 0x49, 0x64, 0x18, 0x16, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06,
|
0x0a, 0x09, 0x53, 0x43, 0x54, 0x4d, 0x49, 0x6e, 0x66, 0x6f, 0x73, 0x12, 0x2a, 0x0a, 0x06, 0x54,
|
||||||
0x53, 0x68, 0x6f, 0x77, 0x49, 0x64, 0x22, 0x5b, 0x0a, 0x0d, 0x4d, 0x61, 0x74, 0x63, 0x68, 0x54,
|
0x4d, 0x49, 0x6e, 0x66, 0x6f, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x12, 0x2e, 0x74, 0x6f,
|
||||||
0x79, 0x70, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18,
|
0x75, 0x72, 0x6e, 0x61, 0x6d, 0x65, 0x6e, 0x74, 0x2e, 0x54, 0x4d, 0x49, 0x6e, 0x66, 0x6f, 0x52,
|
||||||
0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x53,
|
0x06, 0x54, 0x4d, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x1a, 0x0a, 0x08, 0x54, 0x79, 0x70, 0x65, 0x4c,
|
||||||
0x6f, 0x72, 0x74, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06, 0x53, 0x6f, 0x72,
|
0x69, 0x73, 0x74, 0x18, 0x02, 0x20, 0x03, 0x28, 0x05, 0x52, 0x08, 0x54, 0x79, 0x70, 0x65, 0x4c,
|
||||||
0x74, 0x49, 0x64, 0x12, 0x0e, 0x0a, 0x02, 0x4f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x08, 0x52,
|
|
||||||
0x02, 0x4f, 0x6e, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x05, 0x52,
|
|
||||||
0x02, 0x49, 0x64, 0x22, 0x6e, 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, 0x12, 0x35, 0x0a, 0x08,
|
|
||||||
0x54, 0x79, 0x70, 0x65, 0x4c, 0x69, 0x73, 0x74, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x19,
|
|
||||||
0x2e, 0x74, 0x6f, 0x75, 0x72, 0x6e, 0x61, 0x6d, 0x65, 0x6e, 0x74, 0x2e, 0x4d, 0x61, 0x74, 0x63,
|
|
||||||
0x68, 0x54, 0x79, 0x70, 0x65, 0x49, 0x6e, 0x66, 0x6f, 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, 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,
|
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,
|
0x05, 0x52, 0x04, 0x54, 0x4d, 0x49, 0x64, 0x22, 0x5a, 0x0a, 0x06, 0x54, 0x4d, 0x52, 0x61, 0x6e,
|
||||||
|
@ -1907,7 +1819,7 @@ func file_tournament_proto_rawDescGZIP() []byte {
|
||||||
}
|
}
|
||||||
|
|
||||||
var file_tournament_proto_enumTypes = make([]protoimpl.EnumInfo, 2)
|
var file_tournament_proto_enumTypes = make([]protoimpl.EnumInfo, 2)
|
||||||
var file_tournament_proto_msgTypes = make([]protoimpl.MessageInfo, 23)
|
var file_tournament_proto_msgTypes = make([]protoimpl.MessageInfo, 22)
|
||||||
var file_tournament_proto_goTypes = []interface{}{
|
var file_tournament_proto_goTypes = []interface{}{
|
||||||
(TOURNAMENTID)(0), // 0: tournament.TOURNAMENTID
|
(TOURNAMENTID)(0), // 0: tournament.TOURNAMENTID
|
||||||
(SignRaceCode)(0), // 1: tournament.SignRaceCode
|
(SignRaceCode)(0), // 1: tournament.SignRaceCode
|
||||||
|
@ -1915,42 +1827,40 @@ var file_tournament_proto_goTypes = []interface{}{
|
||||||
(*ItemInfo)(nil), // 3: tournament.ItemInfo
|
(*ItemInfo)(nil), // 3: tournament.ItemInfo
|
||||||
(*MatchInfoAward)(nil), // 4: tournament.MatchInfoAward
|
(*MatchInfoAward)(nil), // 4: tournament.MatchInfoAward
|
||||||
(*TMInfo)(nil), // 5: tournament.TMInfo
|
(*TMInfo)(nil), // 5: tournament.TMInfo
|
||||||
(*MatchTypeInfo)(nil), // 6: tournament.MatchTypeInfo
|
(*SCTMInfos)(nil), // 6: tournament.SCTMInfos
|
||||||
(*SCTMInfos)(nil), // 7: tournament.SCTMInfos
|
(*CSTMRankList)(nil), // 7: tournament.CSTMRankList
|
||||||
(*CSTMRankList)(nil), // 8: tournament.CSTMRankList
|
(*TMRank)(nil), // 8: tournament.TMRank
|
||||||
(*TMRank)(nil), // 9: tournament.TMRank
|
(*SCTMRankList)(nil), // 9: tournament.SCTMRankList
|
||||||
(*SCTMRankList)(nil), // 10: tournament.SCTMRankList
|
(*CSSignRace)(nil), // 10: tournament.CSSignRace
|
||||||
(*CSSignRace)(nil), // 11: tournament.CSSignRace
|
(*SCSignRace)(nil), // 11: tournament.SCSignRace
|
||||||
(*SCSignRace)(nil), // 12: tournament.SCSignRace
|
(*SCSyncSignNum)(nil), // 12: tournament.SCSyncSignNum
|
||||||
(*SCSyncSignNum)(nil), // 13: tournament.SCSyncSignNum
|
(*SCTMStart)(nil), // 13: tournament.SCTMStart
|
||||||
(*SCTMStart)(nil), // 14: tournament.SCTMStart
|
(*RankAward)(nil), // 14: tournament.RankAward
|
||||||
(*RankAward)(nil), // 15: tournament.RankAward
|
(*SCPromotionInfo)(nil), // 15: tournament.SCPromotionInfo
|
||||||
(*SCPromotionInfo)(nil), // 16: tournament.SCPromotionInfo
|
(*CSTMSeasonInfo)(nil), // 16: tournament.CSTMSeasonInfo
|
||||||
(*CSTMSeasonInfo)(nil), // 17: tournament.CSTMSeasonInfo
|
(*SCTMSeasonInfo)(nil), // 17: tournament.SCTMSeasonInfo
|
||||||
(*SCTMSeasonInfo)(nil), // 18: tournament.SCTMSeasonInfo
|
(*SeasonRank)(nil), // 18: tournament.SeasonRank
|
||||||
(*SeasonRank)(nil), // 19: tournament.SeasonRank
|
(*CSTMSeasonRank)(nil), // 19: tournament.CSTMSeasonRank
|
||||||
(*CSTMSeasonRank)(nil), // 20: tournament.CSTMSeasonRank
|
(*SCTMSeasonRank)(nil), // 20: tournament.SCTMSeasonRank
|
||||||
(*SCTMSeasonRank)(nil), // 21: tournament.SCTMSeasonRank
|
(*CSTMSeasonAward)(nil), // 21: tournament.CSTMSeasonAward
|
||||||
(*CSTMSeasonAward)(nil), // 22: tournament.CSTMSeasonAward
|
(*SCTMSeasonAward)(nil), // 22: tournament.SCTMSeasonAward
|
||||||
(*SCTMSeasonAward)(nil), // 23: tournament.SCTMSeasonAward
|
nil, // 23: tournament.SCPromotionInfo.RecordEntry
|
||||||
nil, // 24: tournament.SCPromotionInfo.RecordEntry
|
|
||||||
}
|
}
|
||||||
var file_tournament_proto_depIdxs = []int32{
|
var file_tournament_proto_depIdxs = []int32{
|
||||||
3, // 0: tournament.MatchInfoAward.ItemInfo:type_name -> tournament.ItemInfo
|
3, // 0: tournament.MatchInfoAward.ItemInfo:type_name -> tournament.ItemInfo
|
||||||
4, // 1: tournament.TMInfo.Award:type_name -> tournament.MatchInfoAward
|
4, // 1: tournament.TMInfo.Award:type_name -> tournament.MatchInfoAward
|
||||||
3, // 2: tournament.TMInfo.SignupCostItem:type_name -> tournament.ItemInfo
|
3, // 2: tournament.TMInfo.SignupCostItem:type_name -> tournament.ItemInfo
|
||||||
5, // 3: tournament.SCTMInfos.TMInfo:type_name -> tournament.TMInfo
|
5, // 3: tournament.SCTMInfos.TMInfo:type_name -> tournament.TMInfo
|
||||||
6, // 4: tournament.SCTMInfos.TypeList:type_name -> tournament.MatchTypeInfo
|
8, // 4: tournament.SCTMRankList.TMRank:type_name -> tournament.TMRank
|
||||||
9, // 5: tournament.SCTMRankList.TMRank:type_name -> tournament.TMRank
|
3, // 5: tournament.RankAward.ItemInfo:type_name -> tournament.ItemInfo
|
||||||
3, // 6: tournament.RankAward.ItemInfo:type_name -> tournament.ItemInfo
|
23, // 6: tournament.SCPromotionInfo.Record:type_name -> tournament.SCPromotionInfo.RecordEntry
|
||||||
24, // 7: tournament.SCPromotionInfo.Record:type_name -> tournament.SCPromotionInfo.RecordEntry
|
14, // 7: tournament.SCPromotionInfo.RankAward:type_name -> tournament.RankAward
|
||||||
15, // 8: tournament.SCPromotionInfo.RankAward:type_name -> tournament.RankAward
|
18, // 8: tournament.SCTMSeasonRank.ReasonRanks:type_name -> tournament.SeasonRank
|
||||||
19, // 9: tournament.SCTMSeasonRank.ReasonRanks:type_name -> tournament.SeasonRank
|
9, // [9:9] is the sub-list for method output_type
|
||||||
10, // [10:10] is the sub-list for method output_type
|
9, // [9:9] is the sub-list for method input_type
|
||||||
10, // [10:10] is the sub-list for method input_type
|
9, // [9:9] is the sub-list for extension type_name
|
||||||
10, // [10:10] is the sub-list for extension type_name
|
9, // [9:9] is the sub-list for extension extendee
|
||||||
10, // [10:10] is the sub-list for extension extendee
|
0, // [0:9] is the sub-list for field type_name
|
||||||
0, // [0:10] is the sub-list for field type_name
|
|
||||||
}
|
}
|
||||||
|
|
||||||
func init() { file_tournament_proto_init() }
|
func init() { file_tournament_proto_init() }
|
||||||
|
@ -2008,18 +1918,6 @@ func file_tournament_proto_init() {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
file_tournament_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} {
|
file_tournament_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} {
|
||||||
switch v := v.(*MatchTypeInfo); i {
|
|
||||||
case 0:
|
|
||||||
return &v.state
|
|
||||||
case 1:
|
|
||||||
return &v.sizeCache
|
|
||||||
case 2:
|
|
||||||
return &v.unknownFields
|
|
||||||
default:
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
}
|
|
||||||
file_tournament_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} {
|
|
||||||
switch v := v.(*SCTMInfos); i {
|
switch v := v.(*SCTMInfos); i {
|
||||||
case 0:
|
case 0:
|
||||||
return &v.state
|
return &v.state
|
||||||
|
@ -2031,7 +1929,7 @@ func file_tournament_proto_init() {
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
file_tournament_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} {
|
file_tournament_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} {
|
||||||
switch v := v.(*CSTMRankList); i {
|
switch v := v.(*CSTMRankList); i {
|
||||||
case 0:
|
case 0:
|
||||||
return &v.state
|
return &v.state
|
||||||
|
@ -2043,7 +1941,7 @@ func file_tournament_proto_init() {
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
file_tournament_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} {
|
file_tournament_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} {
|
||||||
switch v := v.(*TMRank); i {
|
switch v := v.(*TMRank); i {
|
||||||
case 0:
|
case 0:
|
||||||
return &v.state
|
return &v.state
|
||||||
|
@ -2055,7 +1953,7 @@ func file_tournament_proto_init() {
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
file_tournament_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} {
|
file_tournament_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} {
|
||||||
switch v := v.(*SCTMRankList); i {
|
switch v := v.(*SCTMRankList); i {
|
||||||
case 0:
|
case 0:
|
||||||
return &v.state
|
return &v.state
|
||||||
|
@ -2067,7 +1965,7 @@ func file_tournament_proto_init() {
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
file_tournament_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} {
|
file_tournament_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} {
|
||||||
switch v := v.(*CSSignRace); i {
|
switch v := v.(*CSSignRace); i {
|
||||||
case 0:
|
case 0:
|
||||||
return &v.state
|
return &v.state
|
||||||
|
@ -2079,7 +1977,7 @@ func file_tournament_proto_init() {
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
file_tournament_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} {
|
file_tournament_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} {
|
||||||
switch v := v.(*SCSignRace); i {
|
switch v := v.(*SCSignRace); i {
|
||||||
case 0:
|
case 0:
|
||||||
return &v.state
|
return &v.state
|
||||||
|
@ -2091,7 +1989,7 @@ func file_tournament_proto_init() {
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
file_tournament_proto_msgTypes[11].Exporter = func(v interface{}, i int) interface{} {
|
file_tournament_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} {
|
||||||
switch v := v.(*SCSyncSignNum); i {
|
switch v := v.(*SCSyncSignNum); i {
|
||||||
case 0:
|
case 0:
|
||||||
return &v.state
|
return &v.state
|
||||||
|
@ -2103,7 +2001,7 @@ func file_tournament_proto_init() {
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
file_tournament_proto_msgTypes[12].Exporter = func(v interface{}, i int) interface{} {
|
file_tournament_proto_msgTypes[11].Exporter = func(v interface{}, i int) interface{} {
|
||||||
switch v := v.(*SCTMStart); i {
|
switch v := v.(*SCTMStart); i {
|
||||||
case 0:
|
case 0:
|
||||||
return &v.state
|
return &v.state
|
||||||
|
@ -2115,7 +2013,7 @@ func file_tournament_proto_init() {
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
file_tournament_proto_msgTypes[13].Exporter = func(v interface{}, i int) interface{} {
|
file_tournament_proto_msgTypes[12].Exporter = func(v interface{}, i int) interface{} {
|
||||||
switch v := v.(*RankAward); i {
|
switch v := v.(*RankAward); i {
|
||||||
case 0:
|
case 0:
|
||||||
return &v.state
|
return &v.state
|
||||||
|
@ -2127,7 +2025,7 @@ func file_tournament_proto_init() {
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
file_tournament_proto_msgTypes[14].Exporter = func(v interface{}, i int) interface{} {
|
file_tournament_proto_msgTypes[13].Exporter = func(v interface{}, i int) interface{} {
|
||||||
switch v := v.(*SCPromotionInfo); i {
|
switch v := v.(*SCPromotionInfo); i {
|
||||||
case 0:
|
case 0:
|
||||||
return &v.state
|
return &v.state
|
||||||
|
@ -2139,7 +2037,7 @@ func file_tournament_proto_init() {
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
file_tournament_proto_msgTypes[15].Exporter = func(v interface{}, i int) interface{} {
|
file_tournament_proto_msgTypes[14].Exporter = func(v interface{}, i int) interface{} {
|
||||||
switch v := v.(*CSTMSeasonInfo); i {
|
switch v := v.(*CSTMSeasonInfo); i {
|
||||||
case 0:
|
case 0:
|
||||||
return &v.state
|
return &v.state
|
||||||
|
@ -2151,7 +2049,7 @@ func file_tournament_proto_init() {
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
file_tournament_proto_msgTypes[16].Exporter = func(v interface{}, i int) interface{} {
|
file_tournament_proto_msgTypes[15].Exporter = func(v interface{}, i int) interface{} {
|
||||||
switch v := v.(*SCTMSeasonInfo); i {
|
switch v := v.(*SCTMSeasonInfo); i {
|
||||||
case 0:
|
case 0:
|
||||||
return &v.state
|
return &v.state
|
||||||
|
@ -2163,7 +2061,7 @@ func file_tournament_proto_init() {
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
file_tournament_proto_msgTypes[17].Exporter = func(v interface{}, i int) interface{} {
|
file_tournament_proto_msgTypes[16].Exporter = func(v interface{}, i int) interface{} {
|
||||||
switch v := v.(*SeasonRank); i {
|
switch v := v.(*SeasonRank); i {
|
||||||
case 0:
|
case 0:
|
||||||
return &v.state
|
return &v.state
|
||||||
|
@ -2175,7 +2073,7 @@ func file_tournament_proto_init() {
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
file_tournament_proto_msgTypes[18].Exporter = func(v interface{}, i int) interface{} {
|
file_tournament_proto_msgTypes[17].Exporter = func(v interface{}, i int) interface{} {
|
||||||
switch v := v.(*CSTMSeasonRank); i {
|
switch v := v.(*CSTMSeasonRank); i {
|
||||||
case 0:
|
case 0:
|
||||||
return &v.state
|
return &v.state
|
||||||
|
@ -2187,7 +2085,7 @@ func file_tournament_proto_init() {
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
file_tournament_proto_msgTypes[19].Exporter = func(v interface{}, i int) interface{} {
|
file_tournament_proto_msgTypes[18].Exporter = func(v interface{}, i int) interface{} {
|
||||||
switch v := v.(*SCTMSeasonRank); i {
|
switch v := v.(*SCTMSeasonRank); i {
|
||||||
case 0:
|
case 0:
|
||||||
return &v.state
|
return &v.state
|
||||||
|
@ -2199,7 +2097,7 @@ func file_tournament_proto_init() {
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
file_tournament_proto_msgTypes[20].Exporter = func(v interface{}, i int) interface{} {
|
file_tournament_proto_msgTypes[19].Exporter = func(v interface{}, i int) interface{} {
|
||||||
switch v := v.(*CSTMSeasonAward); i {
|
switch v := v.(*CSTMSeasonAward); i {
|
||||||
case 0:
|
case 0:
|
||||||
return &v.state
|
return &v.state
|
||||||
|
@ -2211,7 +2109,7 @@ func file_tournament_proto_init() {
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
file_tournament_proto_msgTypes[21].Exporter = func(v interface{}, i int) interface{} {
|
file_tournament_proto_msgTypes[20].Exporter = func(v interface{}, i int) interface{} {
|
||||||
switch v := v.(*SCTMSeasonAward); i {
|
switch v := v.(*SCTMSeasonAward); i {
|
||||||
case 0:
|
case 0:
|
||||||
return &v.state
|
return &v.state
|
||||||
|
@ -2230,7 +2128,7 @@ func file_tournament_proto_init() {
|
||||||
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
||||||
RawDescriptor: file_tournament_proto_rawDesc,
|
RawDescriptor: file_tournament_proto_rawDesc,
|
||||||
NumEnums: 2,
|
NumEnums: 2,
|
||||||
NumMessages: 23,
|
NumMessages: 22,
|
||||||
NumExtensions: 0,
|
NumExtensions: 0,
|
||||||
NumServices: 0,
|
NumServices: 0,
|
||||||
},
|
},
|
||||||
|
|
|
@ -63,21 +63,12 @@ message TMInfo{
|
||||||
string Rule = 19;
|
string Rule = 19;
|
||||||
int32 SortId = 20;
|
int32 SortId = 20;
|
||||||
repeated string OnChannelName = 21;//在哪个渠道开启
|
repeated string OnChannelName = 21;//在哪个渠道开启
|
||||||
int32 ShowId = 22; // 比赛区分
|
|
||||||
}
|
}
|
||||||
|
|
||||||
message MatchTypeInfo{
|
|
||||||
string Name = 1; // 名称
|
|
||||||
int32 SortId = 2; // 排序序号
|
|
||||||
bool On = 3; // 开关
|
|
||||||
int32 Id = 4; // 类型id
|
|
||||||
}
|
|
||||||
|
|
||||||
//比赛场场次
|
//比赛场场次
|
||||||
//PACKET_TM_SCTMInfos
|
//PACKET_TM_SCTMInfos
|
||||||
message SCTMInfos{
|
message SCTMInfos{
|
||||||
repeated TMInfo TMInfo = 1;//比赛场场次信息
|
repeated TMInfo TMInfo = 1;//比赛场场次信息
|
||||||
repeated MatchTypeInfo TypeList = 2; // 比赛类型列表
|
repeated int32 TypeList = 2; // 所有玩法类型 1.锦标赛 2.实物赛 3.vip比赛 4.话费赛
|
||||||
}
|
}
|
||||||
//单场次排行榜
|
//单场次排行榜
|
||||||
//PACKET_TM_CSTMRankList
|
//PACKET_TM_CSTMRankList
|
||||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -446,7 +446,6 @@ message GameMatchDate {
|
||||||
int32 MatchLevel = 22; // 难度等级
|
int32 MatchLevel = 22; // 难度等级
|
||||||
repeated string OnChannelName = 23; // 开启的渠道名称
|
repeated string OnChannelName = 23; // 开启的渠道名称
|
||||||
int32 CardType = 24; // 手机卡类型
|
int32 CardType = 24; // 手机卡类型
|
||||||
int32 ShowId = 25; // 比赛区分
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// etcd /game/game_match
|
// etcd /game/game_match
|
||||||
|
@ -455,17 +454,10 @@ message GameMatchDateList{
|
||||||
string Platform = 2;
|
string Platform = 2;
|
||||||
}
|
}
|
||||||
|
|
||||||
message MatchTypeInfo{
|
|
||||||
string Name = 1; // 名称
|
|
||||||
int32 SortId = 2; // 序号
|
|
||||||
bool On = 3; // 开关
|
|
||||||
int32 Id = 4; // 类型id
|
|
||||||
}
|
|
||||||
|
|
||||||
// etcd /game/match_type
|
// etcd /game/match_type
|
||||||
message GameMatchType{
|
message GameMatchType{
|
||||||
string Platform = 1;
|
string Platform = 1;
|
||||||
repeated MatchTypeInfo List = 2; // 比赛类型列表
|
repeated int32 List = 2; // 所有玩法类型 1.锦标赛 2.实物赛 3.vip比赛 4.话费赛
|
||||||
}
|
}
|
||||||
|
|
||||||
message WelfareDate {
|
message WelfareDate {
|
||||||
|
|
2
public
2
public
|
@ -1 +1 @@
|
||||||
Subproject commit e26134143eba5c7ced96afc84bde42705a9297be
|
Subproject commit 38b1c8928c52249a60d1340372a2d9bd6d2eee01
|
|
@ -20,13 +20,6 @@ func init() {
|
||||||
netlib.Register(int(gamehallproto.GameHallPacketID_PACKET_SC_QUITGAME), gamehallproto.SCQuitGame{}, SCQuitGame)
|
netlib.Register(int(gamehallproto.GameHallPacketID_PACKET_SC_QUITGAME), gamehallproto.SCQuitGame{}, SCQuitGame)
|
||||||
}
|
}
|
||||||
|
|
||||||
func cleanRoomState(s *netlib.Session) {
|
|
||||||
s.RemoveAttribute(SessionAttributeScene)
|
|
||||||
s.RemoveAttribute(SessionAttributeSceneId)
|
|
||||||
s.RemoveAttribute(SessionAttributeEnteringScene)
|
|
||||||
s.RemoveAttribute(SessionAttributeEnteringMatchScene)
|
|
||||||
}
|
|
||||||
|
|
||||||
func SCEnterRoom(s *netlib.Session, packid int, pack interface{}) error {
|
func SCEnterRoom(s *netlib.Session, packid int, pack interface{}) error {
|
||||||
logger.Logger.Trace("SCEnterRoom ", pack)
|
logger.Logger.Trace("SCEnterRoom ", pack)
|
||||||
msg, ok := pack.(*gamehallproto.SCEnterRoom)
|
msg, ok := pack.(*gamehallproto.SCEnterRoom)
|
||||||
|
@ -51,7 +44,10 @@ func SCDestroyRoom(s *netlib.Session, packid int, pack interface{}) error {
|
||||||
}
|
}
|
||||||
|
|
||||||
if msg.GetOpRetCode() == gamehallproto.OpResultCode_Game_OPRC_Sucess_Game {
|
if msg.GetOpRetCode() == gamehallproto.OpResultCode_Game_OPRC_Sucess_Game {
|
||||||
cleanRoomState(s)
|
s.RemoveAttribute(SessionAttributeScene)
|
||||||
|
s.RemoveAttribute(SessionAttributeSceneId)
|
||||||
|
s.RemoveAttribute(SessionAttributeEnteringScene)
|
||||||
|
s.RemoveAttribute(SessionAttributeEnteringMatchScene)
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -76,7 +72,10 @@ func SCLeaveRoom(s *netlib.Session, packid int, pack interface{}) error {
|
||||||
scene.DelPlayer(p.GetSnId())
|
scene.DelPlayer(p.GetSnId())
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
cleanRoomState(s)
|
s.RemoveAttribute(SessionAttributeScene)
|
||||||
|
s.RemoveAttribute(SessionAttributeSceneId)
|
||||||
|
s.RemoveAttribute(SessionAttributeEnteringScene)
|
||||||
|
s.RemoveAttribute(SessionAttributeEnteringMatchScene)
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -119,7 +118,10 @@ func SCQuitGame(s *netlib.Session, packid int, pack interface{}) error {
|
||||||
scene.DelPlayer(p.GetSnId())
|
scene.DelPlayer(p.GetSnId())
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
cleanRoomState(s)
|
s.RemoveAttribute(SessionAttributeScene)
|
||||||
|
s.RemoveAttribute(SessionAttributeSceneId)
|
||||||
|
s.RemoveAttribute(SessionAttributeEnteringScene)
|
||||||
|
s.RemoveAttribute(SessionAttributeEnteringMatchScene)
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1237,6 +1237,36 @@ func RefreshTransferThird2SystemTask(p *Player) {
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
type CSGetPrivateRoomHistoryPacketFactory struct {
|
||||||
|
}
|
||||||
|
type CSGetPrivateRoomHistoryHandler struct {
|
||||||
|
}
|
||||||
|
|
||||||
|
func (this *CSGetPrivateRoomHistoryPacketFactory) CreatePacket() interface{} {
|
||||||
|
pack := &gamehall.CSGetPrivateRoomHistory{}
|
||||||
|
return pack
|
||||||
|
}
|
||||||
|
|
||||||
|
func (this *CSGetPrivateRoomHistoryHandler) Process(s *netlib.Session, packetid int, data interface{}, sid int64) error {
|
||||||
|
logger.Logger.Trace("CSGetPrivateRoomHistoryHandler Process recv ", data)
|
||||||
|
if msg, ok := data.(*gamehall.CSGetPrivateRoomHistory); ok {
|
||||||
|
p := PlayerMgrSington.GetPlayer(sid)
|
||||||
|
if p == nil {
|
||||||
|
logger.Logger.Warn("CSGetPrivateRoomHistoryHandler p == nil")
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
||||||
|
pps := PrivateSceneMgrSington.GetOrCreatePlayerPrivateScene(p)
|
||||||
|
if pps == nil {
|
||||||
|
logger.Logger.Warnf("CSGetPrivateRoomHistoryHandler PrivateSceneMgrSington.GetOrCreatePlayerPrivateScene(%v)", p.SnId)
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
||||||
|
pps.LoadLogs(p, msg.GetQueryTime())
|
||||||
|
}
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
||||||
type CSQueryRoomInfoPacketFactory struct {
|
type CSQueryRoomInfoPacketFactory struct {
|
||||||
}
|
}
|
||||||
type CSQueryRoomInfoHandler struct {
|
type CSQueryRoomInfoHandler struct {
|
||||||
|
|
|
@ -260,6 +260,7 @@ func init() {
|
||||||
scene.starting = msg.GetStart()
|
scene.starting = msg.GetStart()
|
||||||
scene.currRound = msg.GetCurrRound()
|
scene.currRound = msg.GetCurrRound()
|
||||||
scene.totalRound = msg.GetMaxRound()
|
scene.totalRound = msg.GetMaxRound()
|
||||||
|
scene.lastTime = time.Now()
|
||||||
if scene.starting {
|
if scene.starting {
|
||||||
if scene.currRound == 1 {
|
if scene.currRound == 1 {
|
||||||
scene.startTime = time.Now()
|
scene.startTime = time.Now()
|
||||||
|
|
|
@ -8,11 +8,13 @@ import (
|
||||||
"mongo.games.com/goserver/core/logger"
|
"mongo.games.com/goserver/core/logger"
|
||||||
"mongo.games.com/goserver/core/module"
|
"mongo.games.com/goserver/core/module"
|
||||||
"mongo.games.com/goserver/core/transact"
|
"mongo.games.com/goserver/core/transact"
|
||||||
|
"mongo.games.com/goserver/srvlib"
|
||||||
|
|
||||||
"mongo.games.com/game/common"
|
"mongo.games.com/game/common"
|
||||||
"mongo.games.com/game/proto"
|
"mongo.games.com/game/proto"
|
||||||
hall_proto "mongo.games.com/game/protocol/gamehall"
|
hall_proto "mongo.games.com/game/protocol/gamehall"
|
||||||
"mongo.games.com/game/protocol/server"
|
"mongo.games.com/game/protocol/server"
|
||||||
|
server_proto "mongo.games.com/game/protocol/server"
|
||||||
"mongo.games.com/game/protocol/webapi"
|
"mongo.games.com/game/protocol/webapi"
|
||||||
"mongo.games.com/game/srvdata"
|
"mongo.games.com/game/srvdata"
|
||||||
)
|
)
|
||||||
|
@ -463,16 +465,17 @@ func (this *CoinSceneMgr) OnPlatformDestroy(p *Platform) {
|
||||||
if p == nil {
|
if p == nil {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
var ids []int
|
|
||||||
if v, ok := this.scenesOfPlatform[p.IdStr]; ok {
|
if v, ok := this.scenesOfPlatform[p.IdStr]; ok {
|
||||||
for _, csp := range v {
|
for _, csp := range v {
|
||||||
|
pack := &server_proto.WGGraceDestroyScene{}
|
||||||
for _, scene := range csp.scenes {
|
for _, scene := range csp.scenes {
|
||||||
ids = append(ids, scene.sceneId)
|
pack.Ids = append(pack.Ids, int32(scene.sceneId))
|
||||||
|
}
|
||||||
|
// 房间中记录的有游服连接,广播的方式也可以
|
||||||
|
srvlib.ServerSessionMgrSington.Broadcast(int(server_proto.SSPacketID_PACKET_WG_GRACE_DESTROYSCENE), pack, common.GetSelfAreaId(), srvlib.GameServerType)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
SceneMgrSingleton.DoDelete(ids, true)
|
|
||||||
}
|
|
||||||
|
|
||||||
func (this *CoinSceneMgr) OnPlatformChangeDisabled(p *Platform, disabled bool) {
|
func (this *CoinSceneMgr) OnPlatformChangeDisabled(p *Platform, disabled bool) {
|
||||||
if disabled {
|
if disabled {
|
||||||
|
@ -498,11 +501,12 @@ func (this *CoinSceneMgr) OnPlatformGameFreeUpdate(p *Platform, oldCfg, newCfg *
|
||||||
|
|
||||||
if cps, ok := ss[newCfg.DbGameFree.Id]; ok {
|
if cps, ok := ss[newCfg.DbGameFree.Id]; ok {
|
||||||
cps.dbGameFree = newCfg.DbGameFree
|
cps.dbGameFree = newCfg.DbGameFree
|
||||||
var ids []int
|
pack := &server_proto.WGGraceDestroyScene{}
|
||||||
for _, scene := range cps.scenes {
|
for _, scene := range cps.scenes {
|
||||||
ids = append(ids, scene.sceneId)
|
pack.Ids = append(pack.Ids, int32(scene.sceneId))
|
||||||
}
|
}
|
||||||
SceneMgrSingleton.DoDelete(ids, true)
|
srvlib.ServerSessionMgrSington.Broadcast(int(server_proto.SSPacketID_PACKET_WG_GRACE_DESTROYSCENE),
|
||||||
|
pack, common.GetSelfAreaId(), srvlib.GameServerType)
|
||||||
this.TouchCreateRoom(p.IdStr, newCfg.DbGameFree.Id)
|
this.TouchCreateRoom(p.IdStr, newCfg.DbGameFree.Id)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -512,15 +516,15 @@ func (this *CoinSceneMgr) OnPlatformDestroyByGameFreeId(p *Platform, gameFreeId
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
if csps, ok := this.scenesOfPlatform[p.IdStr]; ok {
|
if csps, ok := this.scenesOfPlatform[p.IdStr]; ok {
|
||||||
var ids []int
|
|
||||||
for _, csp := range csps {
|
for _, csp := range csps {
|
||||||
|
pack := &server_proto.WGGraceDestroyScene{}
|
||||||
for _, scene := range csp.scenes {
|
for _, scene := range csp.scenes {
|
||||||
if scene.dbGameFree.Id == gameFreeId {
|
if scene.dbGameFree.Id == gameFreeId {
|
||||||
ids = append(ids, scene.sceneId)
|
pack.Ids = append(pack.Ids, int32(scene.sceneId))
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
srvlib.ServerSessionMgrSington.Broadcast(int(server_proto.SSPacketID_PACKET_WG_GRACE_DESTROYSCENE), pack, common.GetSelfAreaId(), srvlib.GameServerType)
|
||||||
}
|
}
|
||||||
SceneMgrSingleton.DoDelete(ids, true)
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -546,11 +550,11 @@ func (this *CoinSceneMgr) OnGameGroupUpdate(oldCfg, newCfg *webapi.GameConfigGro
|
||||||
//TODO 预创建房间配置更新,unsupport group model
|
//TODO 预创建房间配置更新,unsupport group model
|
||||||
cps.dbGameFree = newCfg.DbGameFree
|
cps.dbGameFree = newCfg.DbGameFree
|
||||||
if needDestroy {
|
if needDestroy {
|
||||||
var ids []int
|
pack := &server_proto.WGGraceDestroyScene{}
|
||||||
for _, scene := range cps.scenes {
|
for _, scene := range cps.scenes {
|
||||||
ids = append(ids, scene.sceneId)
|
pack.Ids = append(pack.Ids, int32(scene.sceneId))
|
||||||
}
|
}
|
||||||
SceneMgrSingleton.DoDelete(ids, true)
|
srvlib.ServerSessionMgrSington.Broadcast(int(server_proto.SSPacketID_PACKET_WG_GRACE_DESTROYSCENE), pack, common.GetSelfAreaId(), srvlib.GameServerType)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -349,7 +349,7 @@ func (csp *CoinScenePool) OnPlayerLeave(s *Scene, p *Player) {
|
||||||
// 玩家离开结算空房间的私人房
|
// 玩家离开结算空房间的私人房
|
||||||
if s.IsPrivateScene() {
|
if s.IsPrivateScene() {
|
||||||
if s.IsEmpty() {
|
if s.IsEmpty() {
|
||||||
s.DoDelete(false)
|
s.ForceDelete(false)
|
||||||
}
|
}
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
@ -364,7 +364,7 @@ func (csp *CoinScenePool) OnPlayerLeave(s *Scene, p *Player) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if hasCnt > int(csp.dbGameFree.GetCreateRoomNum()) {
|
if hasCnt > int(csp.dbGameFree.GetCreateRoomNum()) {
|
||||||
s.DoDelete(false)
|
s.ForceDelete(false)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -2,18 +2,18 @@ package main
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"math/rand"
|
"math/rand"
|
||||||
|
"mongo.games.com/game/protocol/webapi"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"mongo.games.com/goserver/core/logger"
|
|
||||||
"mongo.games.com/goserver/core/module"
|
|
||||||
|
|
||||||
"mongo.games.com/game/common"
|
"mongo.games.com/game/common"
|
||||||
"mongo.games.com/game/model"
|
"mongo.games.com/game/model"
|
||||||
"mongo.games.com/game/proto"
|
"mongo.games.com/game/proto"
|
||||||
gamehall_proto "mongo.games.com/game/protocol/gamehall"
|
gamehall_proto "mongo.games.com/game/protocol/gamehall"
|
||||||
server_proto "mongo.games.com/game/protocol/server"
|
server_proto "mongo.games.com/game/protocol/server"
|
||||||
"mongo.games.com/game/protocol/webapi"
|
|
||||||
"mongo.games.com/game/srvdata"
|
"mongo.games.com/game/srvdata"
|
||||||
|
"mongo.games.com/goserver/core/logger"
|
||||||
|
"mongo.games.com/goserver/core/module"
|
||||||
|
"mongo.games.com/goserver/srvlib"
|
||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
|
@ -555,11 +555,11 @@ func (this *HundredSceneMgr) OnPlatformDestroy(p *Platform) {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
if ss, ok := this.scenesOfPlatform[p.IdStr]; ok {
|
if ss, ok := this.scenesOfPlatform[p.IdStr]; ok {
|
||||||
var ids []int
|
pack := &server_proto.WGGraceDestroyScene{}
|
||||||
for _, scene := range ss {
|
for _, scene := range ss {
|
||||||
ids = append(ids, scene.sceneId)
|
pack.Ids = append(pack.Ids, int32(scene.sceneId))
|
||||||
}
|
}
|
||||||
SceneMgrSingleton.DoDelete(ids, true)
|
srvlib.ServerSessionMgrSington.Broadcast(int(server_proto.SSPacketID_PACKET_WG_GRACE_DESTROYSCENE), pack, common.GetSelfAreaId(), srvlib.GameServerType)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -569,11 +569,11 @@ func (this *HundredSceneMgr) OnPlatformChangeIsolated(p *Platform, isolated bool
|
||||||
this.OnPlatformCreate(p) //预创建场景
|
this.OnPlatformCreate(p) //预创建场景
|
||||||
} else {
|
} else {
|
||||||
if ss, ok := this.scenesOfPlatform[p.IdStr]; ok {
|
if ss, ok := this.scenesOfPlatform[p.IdStr]; ok {
|
||||||
var ids []int
|
pack := &server_proto.WGGraceDestroyScene{}
|
||||||
for _, scene := range ss {
|
for _, scene := range ss {
|
||||||
ids = append(ids, scene.sceneId)
|
pack.Ids = append(pack.Ids, int32(scene.sceneId))
|
||||||
}
|
}
|
||||||
SceneMgrSingleton.DoDelete(ids, true)
|
srvlib.ServerSessionMgrSington.Broadcast(int(server_proto.SSPacketID_PACKET_WG_GRACE_DESTROYSCENE), pack, common.GetSelfAreaId(), srvlib.GameServerType)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -585,11 +585,11 @@ func (this *HundredSceneMgr) OnPlatformChangeDisabled(p *Platform, disabled bool
|
||||||
}
|
}
|
||||||
if disabled {
|
if disabled {
|
||||||
if ss, ok := this.scenesOfPlatform[p.IdStr]; ok {
|
if ss, ok := this.scenesOfPlatform[p.IdStr]; ok {
|
||||||
var ids []int
|
pack := &server_proto.WGGraceDestroyScene{}
|
||||||
for _, scene := range ss {
|
for _, scene := range ss {
|
||||||
ids = append(ids, scene.sceneId)
|
pack.Ids = append(pack.Ids, int32(scene.sceneId))
|
||||||
}
|
}
|
||||||
SceneMgrSingleton.DoDelete(ids, true)
|
srvlib.ServerSessionMgrSington.Broadcast(int(server_proto.SSPacketID_PACKET_WG_GRACE_DESTROYSCENE), pack, common.GetSelfAreaId(), srvlib.GameServerType)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -600,15 +600,25 @@ func (this *HundredSceneMgr) OnPlatformGameFreeUpdate(p *Platform, oldCfg, newCf
|
||||||
}
|
}
|
||||||
if oldCfg.GroupId != newCfg.GroupId || oldCfg.GroupId != 0 {
|
if oldCfg.GroupId != newCfg.GroupId || oldCfg.GroupId != 0 {
|
||||||
if scenes, exist := this.scenesOfGroup[oldCfg.GroupId]; exist {
|
if scenes, exist := this.scenesOfGroup[oldCfg.GroupId]; exist {
|
||||||
|
pack := &server_proto.WGGraceDestroyScene{}
|
||||||
if s, ok := scenes[newCfg.DbGameFree.Id]; ok {
|
if s, ok := scenes[newCfg.DbGameFree.Id]; ok {
|
||||||
s.DoDelete(false)
|
pack.Ids = append(pack.Ids, int32(s.sceneId))
|
||||||
|
}
|
||||||
|
if len(pack.Ids) > 0 {
|
||||||
|
srvlib.ServerSessionMgrSington.Broadcast(int(server_proto.SSPacketID_PACKET_WG_GRACE_DESTROYSCENE),
|
||||||
|
pack, common.GetSelfAreaId(), srvlib.GameServerType)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
if scenes, exist := this.scenesOfPlatform[p.IdStr]; exist {
|
if scenes, exist := this.scenesOfPlatform[p.IdStr]; exist {
|
||||||
|
pack := &server_proto.WGGraceDestroyScene{}
|
||||||
if s, ok := scenes[newCfg.DbGameFree.Id]; ok {
|
if s, ok := scenes[newCfg.DbGameFree.Id]; ok {
|
||||||
s.DoDelete(false)
|
pack.Ids = append(pack.Ids, int32(s.sceneId))
|
||||||
|
}
|
||||||
|
if len(pack.Ids) > 0 {
|
||||||
|
srvlib.ServerSessionMgrSington.Broadcast(int(server_proto.SSPacketID_PACKET_WG_GRACE_DESTROYSCENE),
|
||||||
|
pack, common.GetSelfAreaId(), srvlib.GameServerType)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -629,7 +639,9 @@ func (this *HundredSceneMgr) OnGameGroupUpdate(oldCfg, newCfg *webapi.GameConfig
|
||||||
needDestroy = true
|
needDestroy = true
|
||||||
}
|
}
|
||||||
if needDestroy {
|
if needDestroy {
|
||||||
SceneMgrSingleton.DoDelete([]int{s.sceneId}, true)
|
pack := &server_proto.WGGraceDestroyScene{}
|
||||||
|
pack.Ids = append(pack.Ids, int32(s.sceneId))
|
||||||
|
srvlib.ServerSessionMgrSington.Broadcast(int(server_proto.SSPacketID_PACKET_WG_GRACE_DESTROYSCENE), pack, common.GetSelfAreaId(), srvlib.GameServerType)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -714,13 +726,13 @@ func (this *HundredSceneMgr) OnPlatformDestroyByGameFreeId(p *Platform, gameFree
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
if scenes, ok := this.scenesOfPlatform[p.IdStr]; ok {
|
if scenes, ok := this.scenesOfPlatform[p.IdStr]; ok {
|
||||||
var ids []int
|
|
||||||
for _, scene := range scenes {
|
for _, scene := range scenes {
|
||||||
|
pack := &server_proto.WGGraceDestroyScene{}
|
||||||
if scene.dbGameFree.Id == gameFreeId {
|
if scene.dbGameFree.Id == gameFreeId {
|
||||||
ids = append(ids, scene.sceneId)
|
pack.Ids = append(pack.Ids, int32(scene.sceneId))
|
||||||
}
|
}
|
||||||
|
srvlib.ServerSessionMgrSington.Broadcast(int(server_proto.SSPacketID_PACKET_WG_GRACE_DESTROYSCENE), pack, common.GetSelfAreaId(), srvlib.GameServerType)
|
||||||
}
|
}
|
||||||
SceneMgrSingleton.DoDelete(ids, true)
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
func init() {
|
func init() {
|
||||||
|
|
|
@ -177,7 +177,7 @@ func (ms *MatchSceneMgr) MatchStop(tm *TmMatch) {
|
||||||
if SceneMgrSingleton.scenes != nil && tm != nil {
|
if SceneMgrSingleton.scenes != nil && tm != nil {
|
||||||
for _, scene := range SceneMgrSingleton.scenes {
|
for _, scene := range SceneMgrSingleton.scenes {
|
||||||
if scene.IsMatchScene() && scene.matchId == tm.SortId {
|
if scene.IsMatchScene() && scene.matchId == tm.SortId {
|
||||||
scene.DoDelete(false)
|
scene.ForceDelete(false)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -0,0 +1,334 @@
|
||||||
|
package main
|
||||||
|
|
||||||
|
//
|
||||||
|
//import (
|
||||||
|
// "mongo.games.com/game/common"
|
||||||
|
// "mongo.games.com/game/proto"
|
||||||
|
// "mongo.games.com/game/protocol/mngame"
|
||||||
|
// server_proto "mongo.games.com/game/protocol/server"
|
||||||
|
// webapi_proto "mongo.games.com/game/protocol/webapi"
|
||||||
|
// "mongo.games.com/game/srvdata"
|
||||||
|
// "mongo.games.com/goserver/core/logger"
|
||||||
|
// "mongo.games.com/goserver/srvlib"
|
||||||
|
// srvlibproto "mongo.games.com/goserver/srvlib/protocol"
|
||||||
|
//)
|
||||||
|
//
|
||||||
|
//var MiniGameMgrSington = &MiniGameMgr{
|
||||||
|
// //按平台管理
|
||||||
|
// scenesOfPlatform: make(map[string]map[int32]*Scene),
|
||||||
|
// //玩家当前打开的小游戏列表
|
||||||
|
// playerGaming: make(map[int32]map[int32]*Scene),
|
||||||
|
// matchAutoId: common.MiniGameSceneStartId,
|
||||||
|
//}
|
||||||
|
//
|
||||||
|
//type MiniGameMgr struct {
|
||||||
|
// BasePlayerListener
|
||||||
|
// //按平台管理
|
||||||
|
// scenesOfPlatform map[string]map[int32]*Scene
|
||||||
|
// //玩家当前打开的小游戏列表
|
||||||
|
// playerGaming map[int32]map[int32]*Scene
|
||||||
|
// matchAutoId int
|
||||||
|
//}
|
||||||
|
//
|
||||||
|
//func (this *MiniGameMgr) GenOneSceneId() int {
|
||||||
|
// this.matchAutoId++
|
||||||
|
// if this.matchAutoId > common.MiniGameSceneMaxId {
|
||||||
|
// this.matchAutoId = common.MiniGameSceneStartId
|
||||||
|
// }
|
||||||
|
// return this.matchAutoId
|
||||||
|
//}
|
||||||
|
//
|
||||||
|
//func (this *MiniGameMgr) PlayerEnter(p *Player, id int32) mngame.MNGameOpResultCode {
|
||||||
|
// plt := p.GetPlatform()
|
||||||
|
// s := this.GetScene(plt, id)
|
||||||
|
// if s == nil {
|
||||||
|
// return mngame.MNGameOpResultCode_MNGAME_OPRC_Error
|
||||||
|
// }
|
||||||
|
//
|
||||||
|
// if !s.PlayerEnterMiniGame(p) {
|
||||||
|
// return mngame.MNGameOpResultCode_MNGAME_OPRC_Error
|
||||||
|
// }
|
||||||
|
//
|
||||||
|
// gamings, ok := this.playerGaming[p.SnId]
|
||||||
|
// if !ok {
|
||||||
|
// gamings = make(map[int32]*Scene)
|
||||||
|
// this.playerGaming[p.SnId] = gamings
|
||||||
|
// }
|
||||||
|
// gamings[id] = s
|
||||||
|
//
|
||||||
|
// return mngame.MNGameOpResultCode_MNGAME_OPRC_Sucess
|
||||||
|
//}
|
||||||
|
//
|
||||||
|
//func (this *MiniGameMgr) PlayerLeave(p *Player, id int32) mngame.MNGameOpResultCode {
|
||||||
|
// plt := p.GetPlatform()
|
||||||
|
// s := this.GetScene(plt, id)
|
||||||
|
// if s == nil {
|
||||||
|
// return mngame.MNGameOpResultCode_MNGAME_OPRC_Error
|
||||||
|
// }
|
||||||
|
//
|
||||||
|
// if !s.PlayerLeaveMiniGame(p) {
|
||||||
|
// return mngame.MNGameOpResultCode_MNGAME_OPRC_Error
|
||||||
|
// }
|
||||||
|
//
|
||||||
|
// gamings, ok := this.playerGaming[p.SnId]
|
||||||
|
// if ok {
|
||||||
|
// delete(gamings, id)
|
||||||
|
// }
|
||||||
|
//
|
||||||
|
// return mngame.MNGameOpResultCode_MNGAME_OPRC_Sucess
|
||||||
|
//}
|
||||||
|
//
|
||||||
|
//func (this *MiniGameMgr) PlayerMsgDispatcher(p *Player, msg *mngame.CSMNGameDispatcher) {
|
||||||
|
// plt := p.GetPlatform()
|
||||||
|
// s := this.GetScene(plt, msg.GetId())
|
||||||
|
// if s == nil {
|
||||||
|
// logger.Logger.Errorf("MiniGameMgr.PlayerMsgDispatcher Can't find scene! plt:%v gameId:%v", plt, msg.GetId())
|
||||||
|
// return
|
||||||
|
// }
|
||||||
|
//
|
||||||
|
// //minigamesrv 重启容错
|
||||||
|
// if !s.HasPlayer(p) {
|
||||||
|
// this.PlayerEnter(p, msg.GetId())
|
||||||
|
// }
|
||||||
|
// s.RedirectMiniGameMsg(p, msg)
|
||||||
|
//}
|
||||||
|
//
|
||||||
|
//func (this *MiniGameMgr) GetScene(p *Platform, id int32) *Scene {
|
||||||
|
// scenes, ok := this.scenesOfPlatform[p.IdStr]
|
||||||
|
// if !ok {
|
||||||
|
// scenes = make(map[int32]*Scene)
|
||||||
|
// this.scenesOfPlatform[p.IdStr] = scenes
|
||||||
|
// }
|
||||||
|
//
|
||||||
|
// s, ok := scenes[id]
|
||||||
|
// if !ok {
|
||||||
|
// cfg := PlatformMgrSingleton.GetGameFree(p.IdStr, id)
|
||||||
|
// if cfg != nil && cfg.Status && cfg.DbGameFree.GetGameType() == common.GameType_Mini {
|
||||||
|
// s = this.CreateSceneByPlatform(p, cfg)
|
||||||
|
// if s != nil {
|
||||||
|
// scenes[cfg.DbGameFree.Id] = s
|
||||||
|
// } else {
|
||||||
|
// return nil
|
||||||
|
// }
|
||||||
|
// return s
|
||||||
|
// } else {
|
||||||
|
// return nil
|
||||||
|
// }
|
||||||
|
// } else {
|
||||||
|
// return s
|
||||||
|
// }
|
||||||
|
// //return nil
|
||||||
|
//}
|
||||||
|
//
|
||||||
|
//func (this *MiniGameMgr) CreateSceneByPlatform(p *Platform, cfg *webapi_proto.GameFree) *Scene {
|
||||||
|
// sceneId := this.GenOneSceneId()
|
||||||
|
// gameId := int(cfg.DbGameFree.GetGameId())
|
||||||
|
// gs := GameSessMgrSington.GetMinLoadSess(gameId)
|
||||||
|
// if gs == nil {
|
||||||
|
// logger.Logger.Errorf("MiniGameMgr.CreateSceneByPlatform Get %v game min session failed.", gameId)
|
||||||
|
// return nil
|
||||||
|
// }
|
||||||
|
// if gs != nil {
|
||||||
|
// gameMode := cfg.DbGameFree.GetGameMode()
|
||||||
|
// dbGameRule := srvdata.PBDB_GameRuleMgr.GetData(cfg.DbGameFree.GetGameRule())
|
||||||
|
// params := dbGameRule.GetParams()
|
||||||
|
// scene := SceneMgrSington.CreateScene(0, 0, sceneId, gameId, int(gameMode), common.SceneMode_Public, 1, -1, params,
|
||||||
|
// gs, p, cfg.GroupId, cfg.DbGameFree, cfg.DbGameFree.Id)
|
||||||
|
// if scene != nil {
|
||||||
|
// scene.hallId = cfg.DbGameFree.Id
|
||||||
|
// return scene
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
// return nil
|
||||||
|
//}
|
||||||
|
//
|
||||||
|
//func (this *MiniGameMgr) OnPlatformCreate(p *Platform) {
|
||||||
|
// if p == nil {
|
||||||
|
// return
|
||||||
|
// }
|
||||||
|
// scenes := make(map[int32]*Scene)
|
||||||
|
// this.scenesOfPlatform[p.IdStr] = scenes
|
||||||
|
//
|
||||||
|
// gps := PlatformMgrSingleton.GetGameFrees(p.IdStr)
|
||||||
|
// for _, v := range gps {
|
||||||
|
// if v.Status && v.DbGameFree.GetGameType() == common.GameType_Mini {
|
||||||
|
// s := this.CreateSceneByPlatform(p, v)
|
||||||
|
// if s != nil {
|
||||||
|
// scenes[v.DbGameFree.Id] = s
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
//}
|
||||||
|
//
|
||||||
|
//func (this *MiniGameMgr) OnPlatformDestroy(p *Platform) {
|
||||||
|
// if p == nil {
|
||||||
|
// return
|
||||||
|
// }
|
||||||
|
// if scenes, ok := this.scenesOfPlatform[p.IdStr]; ok {
|
||||||
|
// for _, s := range scenes {
|
||||||
|
// pack := &server_proto.WGGraceDestroyScene{}
|
||||||
|
// pack.Ids = append(pack.Ids, int32(s.sceneId))
|
||||||
|
// s.SendToGame(int(server_proto.SSPacketID_PACKET_WG_GRACE_DESTROYSCENE), pack)
|
||||||
|
// }
|
||||||
|
// delete(this.scenesOfPlatform, p.IdStr)
|
||||||
|
// }
|
||||||
|
//}
|
||||||
|
//
|
||||||
|
//func (this *MiniGameMgr) OnPlatformChangeIsolated(p *Platform, isolated bool) {
|
||||||
|
// if p == nil {
|
||||||
|
// return
|
||||||
|
// }
|
||||||
|
// if !isolated {
|
||||||
|
// this.OnPlatformDestroy(p)
|
||||||
|
// }
|
||||||
|
//}
|
||||||
|
//
|
||||||
|
//func (this *MiniGameMgr) OnPlatformChangeDisabled(p *Platform, disabled bool) {
|
||||||
|
// if p == nil {
|
||||||
|
// return
|
||||||
|
// }
|
||||||
|
// if disabled {
|
||||||
|
// this.OnPlatformDestroy(p)
|
||||||
|
// } else {
|
||||||
|
// this.OnPlatformCreate(p)
|
||||||
|
// }
|
||||||
|
//}
|
||||||
|
//
|
||||||
|
//func (this *MiniGameMgr) OnPlatformGameFreeUpdate(p *Platform, oldCfg, newCfg *webapi_proto.GameFree) {
|
||||||
|
// if p == nil {
|
||||||
|
// return
|
||||||
|
// }
|
||||||
|
// if scenes, ok := this.scenesOfPlatform[p.IdStr]; ok {
|
||||||
|
// if oldCfg != nil {
|
||||||
|
// if s, ok := scenes[oldCfg.DbGameFree.Id]; ok {
|
||||||
|
// pack := &server_proto.WGGraceDestroyScene{}
|
||||||
|
// pack.Ids = append(pack.Ids, int32(s.sceneId))
|
||||||
|
// s.SendToGame(int(server_proto.SSPacketID_PACKET_WG_GRACE_DESTROYSCENE), pack)
|
||||||
|
// delete(scenes, oldCfg.DbGameFree.Id)
|
||||||
|
// }
|
||||||
|
// } else if newCfg != nil {
|
||||||
|
// if newCfg.Status && newCfg.DbGameFree.GetGameType() == common.GameType_Mini {
|
||||||
|
// s := this.CreateSceneByPlatform(p, newCfg)
|
||||||
|
// if s != nil {
|
||||||
|
// scenes[newCfg.DbGameFree.Id] = s
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
//}
|
||||||
|
//
|
||||||
|
//func (this *MiniGameMgr) OnGameGroupUpdate(oldCfg, newCfg *webapi_proto.GameConfigGroup) {
|
||||||
|
// //donothing
|
||||||
|
//}
|
||||||
|
//
|
||||||
|
///*
|
||||||
|
//获取platform下面对应的 player SnId所在的scene
|
||||||
|
//*/
|
||||||
|
//func (this *MiniGameMgr) GetAllSceneByPlayer(p *Player) map[int32]*Scene {
|
||||||
|
// if gameingScenes, ok := this.playerGaming[p.SnId]; ok {
|
||||||
|
// return gameingScenes
|
||||||
|
// }
|
||||||
|
// return nil
|
||||||
|
//}
|
||||||
|
//
|
||||||
|
//func (this *MiniGameMgr) OnPlayerDropLine(p *Player) {
|
||||||
|
// this.BasePlayerListener.OnPlayerDropLine(p)
|
||||||
|
// if gamingScenes, ok := this.playerGaming[p.SnId]; ok {
|
||||||
|
// for _, s := range gamingScenes {
|
||||||
|
// pack := &server_proto.WGPlayerDropLine{
|
||||||
|
// Id: proto.Int32(p.SnId),
|
||||||
|
// SceneId: proto.Int(s.sceneId),
|
||||||
|
// }
|
||||||
|
// proto.SetDefaults(pack)
|
||||||
|
// s.SendToGame(int(server_proto.SSPacketID_PACKET_WG_PLAYERDROPLINE), pack)
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
//}
|
||||||
|
//
|
||||||
|
//func (this *MiniGameMgr) OnPlayerRehold(p *Player) {
|
||||||
|
// this.BasePlayerListener.OnPlayerRehold(p)
|
||||||
|
// var gateSid int64
|
||||||
|
// if p.gateSess != nil {
|
||||||
|
// if srvInfo, ok := p.gateSess.GetAttribute(srvlib.SessionAttributeServerInfo).(*srvlibproto.SSSrvRegiste); ok && srvInfo != nil {
|
||||||
|
// sessionId := srvlib.NewSessionIdEx(srvInfo.GetAreaId(), srvInfo.GetType(), srvInfo.GetId(), 0)
|
||||||
|
// gateSid = sessionId.Get()
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
// if gamingScenes, ok := this.playerGaming[p.SnId]; ok {
|
||||||
|
// for _, s := range gamingScenes {
|
||||||
|
// pack := &server_proto.WGPlayerRehold{
|
||||||
|
// Id: proto.Int32(p.SnId),
|
||||||
|
// Sid: proto.Int64(p.sid),
|
||||||
|
// SceneId: proto.Int(s.sceneId),
|
||||||
|
// GateSid: proto.Int64(gateSid),
|
||||||
|
// }
|
||||||
|
// proto.SetDefaults(pack)
|
||||||
|
// s.SendToGame(int(server_proto.SSPacketID_PACKET_WG_PLAYERREHOLD), pack)
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
//}
|
||||||
|
//func (this *MiniGameMgr) OnPlayerReturnScene(p *Player) {
|
||||||
|
// this.BasePlayerListener.OnPlayerReturnScene(p)
|
||||||
|
// if gameingScenes, ok := this.playerGaming[p.SnId]; ok {
|
||||||
|
// for _, s := range gameingScenes {
|
||||||
|
// pack := &server_proto.WGPlayerReturn{
|
||||||
|
// PlayerId: p.SnId,
|
||||||
|
// RoomId: int32(s.sceneId),
|
||||||
|
// }
|
||||||
|
// proto.SetDefaults(pack)
|
||||||
|
// s.SendToGame(int(server_proto.SSPacketID_PACKET_WG_PLAYERRETURN), pack)
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
//}
|
||||||
|
//
|
||||||
|
//func (this *MiniGameMgr) OnDestroyScene(s *Scene) {
|
||||||
|
//
|
||||||
|
// if pltScenes, ok := this.scenesOfPlatform[s.limitPlatform.IdStr]; ok {
|
||||||
|
// delete(pltScenes, s.dbGameFree.Id)
|
||||||
|
// }
|
||||||
|
//
|
||||||
|
// for snid, _ := range s.players {
|
||||||
|
// if scenes, ok := this.playerGaming[snid]; ok {
|
||||||
|
// delete(scenes, s.dbGameFree.Id)
|
||||||
|
// if len(scenes) == 0 {
|
||||||
|
// delete(this.playerGaming, snid)
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
//}
|
||||||
|
//
|
||||||
|
//func (this *MiniGameMgr) ClrPlayerWhiteBlackState(p *Player) {
|
||||||
|
// if gamings, ok := this.playerGaming[p.SnId]; ok {
|
||||||
|
// for _, s := range gamings {
|
||||||
|
// pack := &server_proto.WGSetPlayerBlackLevel{
|
||||||
|
// SnId: proto.Int32(p.SnId),
|
||||||
|
// SceneId: proto.Int32(int32(s.sceneId)),
|
||||||
|
// ResetTotalCoin: proto.Bool(true),
|
||||||
|
// }
|
||||||
|
// proto.SetDefaults(pack)
|
||||||
|
// s.SendToGame(int(server_proto.SSPacketID_PACKET_GW_AUTORELIEVEWBLEVEL), pack)
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
//}
|
||||||
|
//
|
||||||
|
//func (this *MiniGameMgr) OnPlatformDestroyByGameFreeId(p *Platform, gameFreeId int32) {
|
||||||
|
// if p == nil {
|
||||||
|
// return
|
||||||
|
// }
|
||||||
|
// if scenes, ok := this.scenesOfPlatform[p.IdStr]; ok {
|
||||||
|
// for _, s := range scenes {
|
||||||
|
// if s.dbGameFree.Id == gameFreeId {
|
||||||
|
// pack := &server_proto.WGGraceDestroyScene{}
|
||||||
|
// pack.Ids = append(pack.Ids, int32(s.sceneId))
|
||||||
|
// s.SendToGame(int(server_proto.SSPacketID_PACKET_WG_GRACE_DESTROYSCENE), pack)
|
||||||
|
// delete(scenes, gameFreeId)
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
//}
|
||||||
|
//
|
||||||
|
//func init() {
|
||||||
|
// RegistePlayerListener(MiniGameMgrSington)
|
||||||
|
// PlatformMgrSingleton.RegisterObserver(MiniGameMgrSington)
|
||||||
|
// PlatformGameGroupMgrSington.RegisterObserver(MiniGameMgrSington)
|
||||||
|
//}
|
|
@ -0,0 +1,276 @@
|
||||||
|
package main
|
||||||
|
|
||||||
|
import (
|
||||||
|
"container/list"
|
||||||
|
"fmt"
|
||||||
|
"mongo.games.com/game/common"
|
||||||
|
"mongo.games.com/game/model"
|
||||||
|
"mongo.games.com/game/proto"
|
||||||
|
hall_proto "mongo.games.com/game/protocol/gamehall"
|
||||||
|
"mongo.games.com/goserver/core/basic"
|
||||||
|
"mongo.games.com/goserver/core/task"
|
||||||
|
"strconv"
|
||||||
|
"time"
|
||||||
|
)
|
||||||
|
|
||||||
|
const (
|
||||||
|
PrivateSceneState_Deleting = iota //删除中
|
||||||
|
PrivateSceneState_Deleted //已删除
|
||||||
|
)
|
||||||
|
|
||||||
|
var PrivateSceneMgrSington = &PrivateSceneMgr{
|
||||||
|
pps: make(map[int32]*PlayerPrivateScene),
|
||||||
|
}
|
||||||
|
|
||||||
|
type PlayerPrivateScene struct {
|
||||||
|
snid int32 // 玩家id
|
||||||
|
creatorName string //创建人昵称
|
||||||
|
platform string // 平台名称
|
||||||
|
channel string // 渠道名称
|
||||||
|
promoter string // 推广员
|
||||||
|
packageTag string // 推广包标识
|
||||||
|
scenes map[int]*Scene
|
||||||
|
logsByDay map[int]*list.List
|
||||||
|
dupLog map[string]struct{}
|
||||||
|
loaded bool
|
||||||
|
}
|
||||||
|
|
||||||
|
func (pps *PlayerPrivateScene) AddScene(s *Scene) {
|
||||||
|
pps.scenes[s.sceneId] = s
|
||||||
|
}
|
||||||
|
|
||||||
|
func (pps *PlayerPrivateScene) GetScene(sceneId int) *Scene {
|
||||||
|
if s, exist := pps.scenes[sceneId]; exist {
|
||||||
|
return s
|
||||||
|
}
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
||||||
|
func (pps *PlayerPrivateScene) GetCount() int {
|
||||||
|
return len(pps.scenes)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (pps *PlayerPrivateScene) CanDelete() bool {
|
||||||
|
return !pps.loaded && len(pps.scenes) == 0
|
||||||
|
}
|
||||||
|
|
||||||
|
func (pps *PlayerPrivateScene) OnPlayerLogin(p *Player) {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
func (pps *PlayerPrivateScene) OnPlayerLogout(p *Player) {
|
||||||
|
pps.logsByDay = nil
|
||||||
|
pps.loaded = false
|
||||||
|
}
|
||||||
|
|
||||||
|
func (pps *PlayerPrivateScene) OnCreateScene(p *Player, s *Scene) {
|
||||||
|
pps.scenes[s.sceneId] = s
|
||||||
|
}
|
||||||
|
|
||||||
|
func (pps *PlayerPrivateScene) LoadLogs(p *Player, yyyymmdd int32) {
|
||||||
|
if !pps.loaded {
|
||||||
|
var logs []*model.PrivateSceneLog
|
||||||
|
var err error
|
||||||
|
task.New(nil, task.CallableWrapper(func(o *basic.Object) interface{} {
|
||||||
|
logs, err = model.GetPrivateSceneLogBySnId(p.Platform, p.SnId, model.GameParamData.PrivateSceneLogLimit)
|
||||||
|
return nil
|
||||||
|
}), task.CompleteNotifyWrapper(func(data interface{}, t task.Task) {
|
||||||
|
if err == nil {
|
||||||
|
pps.loaded = true
|
||||||
|
pps.TidyLog(logs)
|
||||||
|
pps.SendLogs(p, yyyymmdd)
|
||||||
|
}
|
||||||
|
}), "GetPrivateSceneLogBySnId").Start()
|
||||||
|
} else {
|
||||||
|
pps.SendLogs(p, yyyymmdd)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
func (pps *PlayerPrivateScene) TidyLog(logs []*model.PrivateSceneLog) {
|
||||||
|
if pps.logsByDay == nil {
|
||||||
|
pps.logsByDay = make(map[int]*list.List)
|
||||||
|
}
|
||||||
|
|
||||||
|
for _, log := range logs {
|
||||||
|
if _, exist := pps.dupLog[log.LogId.Hex()]; exist {
|
||||||
|
continue
|
||||||
|
}
|
||||||
|
y, m, d := log.CreateTime.Date()
|
||||||
|
day := y*10000 + int(m)*100 + d
|
||||||
|
if lst, exist := pps.logsByDay[day]; exist {
|
||||||
|
lst.PushBack(log)
|
||||||
|
} else {
|
||||||
|
lst = list.New()
|
||||||
|
pps.logsByDay[day] = lst
|
||||||
|
lst.PushBack(log)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
pps.dupLog = nil
|
||||||
|
}
|
||||||
|
|
||||||
|
func (pps *PlayerPrivateScene) SendLogs(p *Player, yyyymmdd int32) {
|
||||||
|
pack := &hall_proto.SCGetPrivateRoomHistory{
|
||||||
|
QueryTime: proto.Int32(yyyymmdd),
|
||||||
|
}
|
||||||
|
if logs, exist := pps.logsByDay[int(yyyymmdd)]; exist {
|
||||||
|
for e := logs.Front(); e != nil; e = e.Next() {
|
||||||
|
if log, ok := e.Value.(*model.PrivateSceneLog); ok {
|
||||||
|
data := &hall_proto.PrivateRoomHistory{
|
||||||
|
GameFreeId: proto.Int32(log.GameFreeId),
|
||||||
|
RoomId: proto.Int32(log.SceneId),
|
||||||
|
CreateTime: proto.Int32(int32(log.CreateTime.Unix())),
|
||||||
|
DestroyTime: proto.Int32(int32(log.DestroyTime.Unix())),
|
||||||
|
CreateFee: proto.Int32(log.CreateFee),
|
||||||
|
}
|
||||||
|
pack.Datas = append(pack.Datas, data)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
proto.SetDefaults(pack)
|
||||||
|
p.SendToClient(int(hall_proto.GameHallPacketID_PACKET_SC_GETPRIVATEROOMHISTORY), pack)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (pps *PlayerPrivateScene) PushLog(log *model.PrivateSceneLog) {
|
||||||
|
if log == nil {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
y, m, d := log.CreateTime.Date()
|
||||||
|
day := y*10000 + int(m)*100 + d
|
||||||
|
if lst, exist := pps.logsByDay[day]; exist {
|
||||||
|
lst.PushFront(log)
|
||||||
|
} else {
|
||||||
|
lst = list.New()
|
||||||
|
pps.logsByDay[day] = lst
|
||||||
|
lst.PushFront(log)
|
||||||
|
}
|
||||||
|
if !pps.loaded {
|
||||||
|
pps.dupLog[log.LogId.Hex()] = struct{}{}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
func (pps *PlayerPrivateScene) SendPrivateScenes(p *Player) {
|
||||||
|
pack := &hall_proto.SCGetPrivateRoomList{}
|
||||||
|
for sceneid, s := range pps.scenes {
|
||||||
|
data := &hall_proto.PrivateRoomInfo{
|
||||||
|
GameFreeId: proto.Int32(s.dbGameFree.GetId()),
|
||||||
|
RoomId: proto.Int(sceneid),
|
||||||
|
CurrRound: proto.Int32(s.currRound),
|
||||||
|
MaxRound: proto.Int32(s.totalRound),
|
||||||
|
CurrNum: proto.Int(len(s.players)),
|
||||||
|
MaxPlayer: proto.Int(s.playerNum),
|
||||||
|
CreateTs: proto.Int32(int32(s.createTime.Unix())),
|
||||||
|
}
|
||||||
|
pack.Datas = append(pack.Datas, data)
|
||||||
|
}
|
||||||
|
proto.SetDefaults(pack)
|
||||||
|
p.SendToClient(int(hall_proto.GameHallPacketID_PACKET_SC_GETPRIVATEROOMLIST), pack)
|
||||||
|
}
|
||||||
|
|
||||||
|
type PrivateSceneMgr struct {
|
||||||
|
pps map[int32]*PlayerPrivateScene
|
||||||
|
}
|
||||||
|
|
||||||
|
func (psm *PrivateSceneMgr) GetOrCreatePlayerPrivateScene(p *Player) *PlayerPrivateScene {
|
||||||
|
snid := p.SnId
|
||||||
|
if pps, exist := psm.pps[snid]; exist {
|
||||||
|
return pps
|
||||||
|
}
|
||||||
|
|
||||||
|
pps := &PlayerPrivateScene{
|
||||||
|
snid: snid,
|
||||||
|
creatorName: p.Name,
|
||||||
|
platform: p.Platform,
|
||||||
|
channel: p.Channel,
|
||||||
|
promoter: strconv.Itoa(int(p.PromoterTree)),
|
||||||
|
packageTag: p.PackageID,
|
||||||
|
scenes: make(map[int]*Scene),
|
||||||
|
logsByDay: make(map[int]*list.List),
|
||||||
|
dupLog: make(map[string]struct{}),
|
||||||
|
}
|
||||||
|
|
||||||
|
psm.pps[snid] = pps
|
||||||
|
return pps
|
||||||
|
}
|
||||||
|
|
||||||
|
func (psm *PrivateSceneMgr) GetPlayerPrivateScene(snid int32) *PlayerPrivateScene {
|
||||||
|
if pps, exist := psm.pps[snid]; exist {
|
||||||
|
return pps
|
||||||
|
}
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
||||||
|
func (psm *PrivateSceneMgr) OnDestroyScene(scene *Scene) {
|
||||||
|
if scene == nil {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
if !scene.IsPrivateScene() {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
pps := psm.GetPlayerPrivateScene(scene.creator)
|
||||||
|
if pps != nil {
|
||||||
|
if pps.GetScene(scene.sceneId) == scene {
|
||||||
|
delete(pps.scenes, scene.sceneId)
|
||||||
|
var tax int32
|
||||||
|
var returnCoin int32
|
||||||
|
p := PlayerMgrSington.GetPlayerBySnId(scene.creator)
|
||||||
|
|
||||||
|
if scene.currRound == 0 && !scene.starting && scene.createFee > 0 { //未开始
|
||||||
|
if scene.manualDelete && time.Now().Sub(scene.createTime) < time.Second*time.Duration(model.GameParamData.PrivateSceneFreeDistroySec) { //低于指定时间,要扣除部分费用
|
||||||
|
tax = scene.createFee * int32(model.GameParamData.PrivateSceneDestroyTax) / 100
|
||||||
|
returnCoin = scene.createFee - tax
|
||||||
|
} else {
|
||||||
|
returnCoin = scene.createFee
|
||||||
|
}
|
||||||
|
if returnCoin > 0 {
|
||||||
|
if p != nil {
|
||||||
|
var remark string
|
||||||
|
if tax > 0 {
|
||||||
|
remark = fmt.Sprintf("提前解散扣除费用%.02f", float32(tax)/100.0)
|
||||||
|
}
|
||||||
|
p.AddCoin(int64(returnCoin), 0, common.GainWay_PrivateSceneReturn, "", remark)
|
||||||
|
} else {
|
||||||
|
//TODO 发送邮件
|
||||||
|
//sendClubMail_ClubCreateRoomRefund(scene.creator, scene.limitPlatform.Name, int32(scene.sceneId), int64(tax), int64(returnCoin))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if p != nil {
|
||||||
|
pack := &hall_proto.SCDestroyPrivateRoom{
|
||||||
|
OpRetCode: hall_proto.OpResultCode_Game_OPRC_Sucess_Game,
|
||||||
|
RoomId: proto.Int(scene.sceneId),
|
||||||
|
State: proto.Int(PrivateSceneState_Deleted),
|
||||||
|
}
|
||||||
|
proto.SetDefaults(pack)
|
||||||
|
p.SendToClient(int(hall_proto.GameHallPacketID_PACKET_SC_DESTROYPRIVATEROOM), pack)
|
||||||
|
}
|
||||||
|
|
||||||
|
//写log
|
||||||
|
log := model.NewPrivateSceneLog()
|
||||||
|
if log != nil {
|
||||||
|
log.SnId = pps.snid
|
||||||
|
log.Platform = pps.platform
|
||||||
|
log.Channel = pps.channel
|
||||||
|
log.Promoter = pps.promoter
|
||||||
|
log.GameFreeId = scene.dbGameFree.GetId()
|
||||||
|
log.SceneId = int32(scene.sceneId)
|
||||||
|
log.CreateTime = scene.createTime
|
||||||
|
log.DestroyTime = time.Now()
|
||||||
|
if returnCoin > 0 {
|
||||||
|
log.CreateFee = tax
|
||||||
|
} else {
|
||||||
|
log.CreateFee = scene.createFee
|
||||||
|
}
|
||||||
|
//PrivateSceneLogChannelSington.Write(log)
|
||||||
|
pps.PushLog(log)
|
||||||
|
}
|
||||||
|
|
||||||
|
if pps.CanDelete() && p == nil {
|
||||||
|
delete(psm.pps, scene.creator)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
|
@ -92,6 +92,7 @@ type Scene struct {
|
||||||
clubRoomPos int32 //
|
clubRoomPos int32 //
|
||||||
clubRoomTax int32 //
|
clubRoomTax int32 //
|
||||||
createFee int32 //创建房间的费用
|
createFee int32 //创建房间的费用
|
||||||
|
manualDelete bool //是否手动解散
|
||||||
GameLog []int32 //游戏服务器同步的录单
|
GameLog []int32 //游戏服务器同步的录单
|
||||||
JackPotFund int64 //游戏服务器同步的奖池
|
JackPotFund int64 //游戏服务器同步的奖池
|
||||||
State int32 //当前游戏状态,后期放到ScenePolicy里去处理
|
State int32 //当前游戏状态,后期放到ScenePolicy里去处理
|
||||||
|
@ -502,7 +503,6 @@ func (this *Scene) PlayerEnter(p *Player, pos int, ischangeroom bool) bool {
|
||||||
enterTs: p.enterts.Unix(),
|
enterTs: p.enterts.Unix(),
|
||||||
totalConvertibleFlow: p.TotalConvertibleFlow,
|
totalConvertibleFlow: p.TotalConvertibleFlow,
|
||||||
}
|
}
|
||||||
this.lastTime = time.Now()
|
|
||||||
}
|
}
|
||||||
msg.TakeCoin = proto.Int64(takeCoin)
|
msg.TakeCoin = proto.Int64(takeCoin)
|
||||||
msg.ExpectLeaveCoin = proto.Int64(leaveCoin)
|
msg.ExpectLeaveCoin = proto.Int64(leaveCoin)
|
||||||
|
@ -552,6 +552,7 @@ func (this *Scene) PlayerEnter(p *Player, pos int, ischangeroom bool) bool {
|
||||||
proto.SetDefaults(msg)
|
proto.SetDefaults(msg)
|
||||||
this.SendToGame(int(serverproto.SSPacketID_PACKET_WG_PLAYERENTER), msg)
|
this.SendToGame(int(serverproto.SSPacketID_PACKET_WG_PLAYERENTER), msg)
|
||||||
logger.Logger.Tracef("SSPacketID_PACKET_WG_PLAYERENTER Scene:%v ;PlayerEnter(%v, %v)", this.sceneId, p.SnId, pos)
|
logger.Logger.Tracef("SSPacketID_PACKET_WG_PLAYERENTER Scene:%v ;PlayerEnter(%v, %v)", this.sceneId, p.SnId, pos)
|
||||||
|
this.lastTime = time.Now()
|
||||||
FirePlayerEnterScene(p, this)
|
FirePlayerEnterScene(p, this)
|
||||||
return true
|
return true
|
||||||
} else {
|
} else {
|
||||||
|
@ -602,10 +603,9 @@ func (this *Scene) PlayerLeave(p *Player, reason int) {
|
||||||
|
|
||||||
// 玩家最后所在游戏
|
// 玩家最后所在游戏
|
||||||
p.LastGameId = int(this.dbGameFree.GetGameId())
|
p.LastGameId = int(this.dbGameFree.GetGameId())
|
||||||
if !p.IsRob {
|
|
||||||
this.lastTime = time.Now()
|
this.lastTime = time.Now()
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
func (this *Scene) DelPlayer(p *Player) bool {
|
func (this *Scene) DelPlayer(p *Player) bool {
|
||||||
if p.scene != this {
|
if p.scene != this {
|
||||||
|
@ -701,7 +701,6 @@ func (this *Scene) AudienceEnter(p *Player, ischangeroom bool) bool {
|
||||||
enterTs: p.enterts.Unix(),
|
enterTs: p.enterts.Unix(),
|
||||||
totalConvertibleFlow: p.TotalConvertibleFlow,
|
totalConvertibleFlow: p.TotalConvertibleFlow,
|
||||||
}
|
}
|
||||||
this.lastTime = time.Now()
|
|
||||||
}
|
}
|
||||||
|
|
||||||
takeCoin := p.Coin
|
takeCoin := p.Coin
|
||||||
|
@ -710,6 +709,7 @@ func (this *Scene) AudienceEnter(p *Player, ischangeroom bool) bool {
|
||||||
proto.SetDefaults(msg)
|
proto.SetDefaults(msg)
|
||||||
this.SendToGame(int(serverproto.SSPacketID_PACKET_WG_AUDIENCEENTER), msg)
|
this.SendToGame(int(serverproto.SSPacketID_PACKET_WG_AUDIENCEENTER), msg)
|
||||||
p.enterts = time.Now()
|
p.enterts = time.Now()
|
||||||
|
this.lastTime = time.Now()
|
||||||
return true
|
return true
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -728,10 +728,8 @@ func (this *Scene) AudienceLeave(p *Player, reason int) {
|
||||||
p.SendToClient(int(hallproto.GameHallPacketID_PACKET_SC_LEAVEROOM), pack)
|
p.SendToClient(int(hallproto.GameHallPacketID_PACKET_SC_LEAVEROOM), pack)
|
||||||
//观众直接从房间退出来
|
//观众直接从房间退出来
|
||||||
this.DelAudience(p)
|
this.DelAudience(p)
|
||||||
if !p.IsRob {
|
|
||||||
this.lastTime = time.Now()
|
this.lastTime = time.Now()
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
func (this *Scene) DelAudience(p *Player) bool {
|
func (this *Scene) DelAudience(p *Player) bool {
|
||||||
logger.Logger.Infof("(this *Scene:%v) DelAudience(%v) ", this.sceneId, p.SnId)
|
logger.Logger.Infof("(this *Scene:%v) DelAudience(%v) ", this.sceneId, p.SnId)
|
||||||
|
@ -810,6 +808,12 @@ func (this *Scene) AudienceSit(p *Player, pos int) bool {
|
||||||
p.scene = this
|
p.scene = this
|
||||||
this.players[p.SnId] = p
|
this.players[p.SnId] = p
|
||||||
|
|
||||||
|
//NpcServerAgentSington.OnPlayerEnterScene(this, p)
|
||||||
|
if this.IsCoinScene() {
|
||||||
|
//CoinSceneMgrSingleton.OnPlayerEnter(p, this.dbGameFree.GetId())
|
||||||
|
} else if this.IsHallScene() {
|
||||||
|
|
||||||
|
}
|
||||||
msg := &serverproto.WGAudienceSit{
|
msg := &serverproto.WGAudienceSit{
|
||||||
SnId: proto.Int32(p.SnId),
|
SnId: proto.Int32(p.SnId),
|
||||||
SceneId: proto.Int(this.sceneId),
|
SceneId: proto.Int(this.sceneId),
|
||||||
|
@ -819,9 +823,7 @@ func (this *Scene) AudienceSit(p *Player, pos int) bool {
|
||||||
msg.TakeCoin = proto.Int64(p.Coin)
|
msg.TakeCoin = proto.Int64(p.Coin)
|
||||||
proto.SetDefaults(msg)
|
proto.SetDefaults(msg)
|
||||||
this.SendToGame(int(serverproto.SSPacketID_PACKET_WG_AUDIENCESIT), msg)
|
this.SendToGame(int(serverproto.SSPacketID_PACKET_WG_AUDIENCESIT), msg)
|
||||||
if !p.IsRob {
|
|
||||||
this.lastTime = time.Now()
|
this.lastTime = time.Now()
|
||||||
}
|
|
||||||
return true
|
return true
|
||||||
}
|
}
|
||||||
return false
|
return false
|
||||||
|
@ -933,24 +935,23 @@ func (this *Scene) BilledRoomCard(snid []int32) {
|
||||||
|
|
||||||
func (this *Scene) IsLongTimeInactive() bool {
|
func (this *Scene) IsLongTimeInactive() bool {
|
||||||
tNow := time.Now()
|
tNow := time.Now()
|
||||||
// 房间没有真人,没有观众,长时间没有真人进出房间
|
//删除超过指定不活跃时间的房间
|
||||||
if this.GetTruePlayerCnt() == 0 && this.GetAudienceCnt() == 0 && tNow.Sub(this.lastTime) > time.Second*time.Duration(model.GameParamData.SceneMaxIdle) {
|
if len(this.players) == 0 && tNow.Sub(this.lastTime) > time.Second*time.Duration(model.GameParamData.SceneMaxIdle) {
|
||||||
return true
|
return true
|
||||||
}
|
}
|
||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
|
|
||||||
func (this *Scene) DoDelete(isGrace bool) {
|
func (this *Scene) ForceDelete(isManual bool) {
|
||||||
if !isGrace {
|
this.manualDelete = isManual
|
||||||
this.deleting = true
|
this.deleting = true
|
||||||
this.force = true
|
this.force = true
|
||||||
}
|
|
||||||
pack := &serverproto.WGDestroyScene{
|
pack := &serverproto.WGDestroyScene{
|
||||||
Ids: []int64{int64(this.sceneId)},
|
SceneId: proto.Int(this.sceneId),
|
||||||
IsGrace: isGrace,
|
|
||||||
}
|
}
|
||||||
|
proto.SetDefaults(pack)
|
||||||
this.SendToGame(int(serverproto.SSPacketID_PACKET_WG_DESTROYSCENE), pack)
|
this.SendToGame(int(serverproto.SSPacketID_PACKET_WG_DESTROYSCENE), pack)
|
||||||
logger.Logger.Tracef("WG_DESTROYSCENE: %v", pack)
|
logger.Logger.Warnf("(this *Scene) ForceDelete() sceneid=%v", this.sceneId)
|
||||||
}
|
}
|
||||||
|
|
||||||
func (this *Scene) Shutdown() {
|
func (this *Scene) Shutdown() {
|
||||||
|
|
|
@ -5,7 +5,6 @@ import (
|
||||||
"sort"
|
"sort"
|
||||||
|
|
||||||
"mongo.games.com/goserver/core/logger"
|
"mongo.games.com/goserver/core/logger"
|
||||||
"mongo.games.com/goserver/srvlib"
|
|
||||||
|
|
||||||
"mongo.games.com/game/common"
|
"mongo.games.com/game/common"
|
||||||
"mongo.games.com/game/model"
|
"mongo.games.com/game/model"
|
||||||
|
@ -352,26 +351,6 @@ func (m *SceneMgr) OnPlayerLeaveScene(s *Scene, p *Player) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
func (m *SceneMgr) DoDelete(sceneId []int, isGrace bool) {
|
|
||||||
if len(sceneId) == 0 {
|
|
||||||
return
|
|
||||||
}
|
|
||||||
var ids []int64
|
|
||||||
for _, v := range sceneId {
|
|
||||||
ids = append(ids, int64(v))
|
|
||||||
s, ok := m.scenes[v]
|
|
||||||
if !isGrace && ok && s != nil {
|
|
||||||
s.deleting = true
|
|
||||||
s.force = true
|
|
||||||
}
|
|
||||||
}
|
|
||||||
pack := &serverproto.WGDestroyScene{
|
|
||||||
Ids: ids,
|
|
||||||
IsGrace: isGrace,
|
|
||||||
}
|
|
||||||
srvlib.ServerSessionMgrSington.Broadcast(int(serverproto.SSPacketID_PACKET_WG_DESTROYSCENE), pack, common.GetSelfAreaId(), srvlib.GameServerType)
|
|
||||||
}
|
|
||||||
|
|
||||||
// GetThirdScene 获取三方游戏房间
|
// GetThirdScene 获取三方游戏房间
|
||||||
//func (m *SceneMgr) GetThirdScene(i webapi.IThirdPlatform) *Scene {
|
//func (m *SceneMgr) GetThirdScene(i webapi.IThirdPlatform) *Scene {
|
||||||
// if i == nil {
|
// if i == nil {
|
||||||
|
@ -414,18 +393,18 @@ func (m *SceneMgr) OnMiniTimer() {
|
||||||
case s.IsCoinScene():
|
case s.IsCoinScene():
|
||||||
if s.IsLongTimeInactive() {
|
if s.IsLongTimeInactive() {
|
||||||
if s.dbGameFree.GetCreateRoomNum() == 0 {
|
if s.dbGameFree.GetCreateRoomNum() == 0 {
|
||||||
logger.Logger.Warnf("SceneMgr.DeleteLongTimeInactive CoinScene DoDelete scene:%v IsLongTimeInactive", s.sceneId)
|
logger.Logger.Warnf("SceneMgr.DeleteLongTimeInactive CoinScene ForceDelete scene:%v IsLongTimeInactive", s.sceneId)
|
||||||
s.DoDelete(false)
|
s.ForceDelete(false)
|
||||||
}
|
}
|
||||||
if s.dbGameFree.GetCreateRoomNum() > 0 && s.csp != nil && s.csp.GetRoomNum() > int(s.dbGameFree.GetCreateRoomNum()) {
|
if s.dbGameFree.GetCreateRoomNum() > 0 && s.csp != nil && s.csp.GetRoomNum() > int(s.dbGameFree.GetCreateRoomNum()) {
|
||||||
logger.Logger.Warnf("SceneMgr.DeleteLongTimeInactive CoinScene DoDelete scene:%v IsLongTimeInactive", s.sceneId)
|
logger.Logger.Warnf("SceneMgr.DeleteLongTimeInactive CoinScene ForceDelete scene:%v IsLongTimeInactive", s.sceneId)
|
||||||
s.DoDelete(false)
|
s.ForceDelete(false)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
case s.IsPrivateScene():
|
case s.IsPrivateScene():
|
||||||
if s.IsLongTimeInactive() {
|
if s.IsLongTimeInactive() {
|
||||||
logger.Logger.Warnf("SceneMgr.DeleteLongTimeInactive PrivateScene DoDelete scene:%v IsLongTimeInactive", s.sceneId)
|
logger.Logger.Warnf("SceneMgr.DeleteLongTimeInactive PrivateScene ForceDelete scene:%v IsLongTimeInactive", s.sceneId)
|
||||||
s.DoDelete(false)
|
s.ForceDelete(false)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -179,7 +179,9 @@ func (spd *ScenePolicyData) OnPlayerLeave(s *Scene, p *Player) {
|
||||||
|
|
||||||
// 系统维护关闭事件
|
// 系统维护关闭事件
|
||||||
func (spd *ScenePolicyData) OnShutdown(s *Scene) {
|
func (spd *ScenePolicyData) OnShutdown(s *Scene) {
|
||||||
|
if s.IsPrivateScene() {
|
||||||
|
PrivateSceneMgrSington.OnDestroyScene(s)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// 获得场景的匹配因子(值越大越优先选择)
|
// 获得场景的匹配因子(值越大越优先选择)
|
||||||
|
|
|
@ -84,7 +84,7 @@ type PlayerRoundInfo struct {
|
||||||
|
|
||||||
type Tournament struct {
|
type Tournament struct {
|
||||||
BaseClockSinker
|
BaseClockSinker
|
||||||
TypeList map[string]*webapiproto.GameMatchType // 比赛类型列表 平台id:比赛类型列表
|
TypeList map[string][]int32 // 比赛类型列表 平台id:比赛类型
|
||||||
GameMatchDateList map[string]map[int32]*webapiproto.GameMatchDate // 比赛配置,platform:比赛场配置id:比赛配置
|
GameMatchDateList map[string]map[int32]*webapiproto.GameMatchDate // 比赛配置,platform:比赛场配置id:比赛配置
|
||||||
singleSignupPlayers map[int32]*SignupInfo // 开启机器人时,报名的玩家,玩家Id:报名信息
|
singleSignupPlayers map[int32]*SignupInfo // 开启机器人时,报名的玩家,玩家Id:报名信息
|
||||||
signupPlayers map[string]map[int32]*SignInfo // 报名的玩家 platform:比赛配置id:报名人
|
signupPlayers map[string]map[int32]*SignInfo // 报名的玩家 platform:比赛配置id:报名人
|
||||||
|
@ -97,7 +97,7 @@ type Tournament struct {
|
||||||
|
|
||||||
func NewTournament() *Tournament {
|
func NewTournament() *Tournament {
|
||||||
ret := &Tournament{
|
ret := &Tournament{
|
||||||
TypeList: make(map[string]*webapiproto.GameMatchType),
|
TypeList: make(map[string][]int32),
|
||||||
GameMatchDateList: make(map[string]map[int32]*webapiproto.GameMatchDate),
|
GameMatchDateList: make(map[string]map[int32]*webapiproto.GameMatchDate),
|
||||||
singleSignupPlayers: make(map[int32]*SignupInfo),
|
singleSignupPlayers: make(map[int32]*SignupInfo),
|
||||||
signupPlayers: make(map[string]map[int32]*SignInfo),
|
signupPlayers: make(map[string]map[int32]*SignInfo),
|
||||||
|
@ -254,7 +254,26 @@ func (this *Tournament) UpdateTypeList(init bool, data *webapiproto.GameMatchTyp
|
||||||
if data.Platform == "0" {
|
if data.Platform == "0" {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
this.TypeList[data.Platform] = data
|
|
||||||
|
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 {
|
if !init {
|
||||||
//todo 优化
|
//todo 优化
|
||||||
for _, v := range PlayerMgrSington.playerOfPlatform[data.Platform] {
|
for _, v := range PlayerMgrSington.playerOfPlatform[data.Platform] {
|
||||||
|
@ -1387,7 +1406,6 @@ func (this *Tournament) GetSCTMInfosPack(platform, channelName string) *tourname
|
||||||
Rule: info.Rule,
|
Rule: info.Rule,
|
||||||
SortId: info.SortId,
|
SortId: info.SortId,
|
||||||
OnChannelName: info.OnChannelName,
|
OnChannelName: info.OnChannelName,
|
||||||
ShowId: info.ShowId,
|
|
||||||
}
|
}
|
||||||
if info.MatchTimeWeek != nil && len(info.MatchTimeWeek) > 0 {
|
if info.MatchTimeWeek != nil && len(info.MatchTimeWeek) > 0 {
|
||||||
for _, week := range info.MatchTimeWeek {
|
for _, week := range info.MatchTimeWeek {
|
||||||
|
@ -1436,16 +1454,7 @@ func (this *Tournament) GetSCTMInfosPack(platform, channelName string) *tourname
|
||||||
pack.TMInfo = append(pack.TMInfo, tMInfo)
|
pack.TMInfo = append(pack.TMInfo, tMInfo)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if l := this.TypeList[platform]; l != nil {
|
pack.TypeList = this.TypeList[platform]
|
||||||
for _, v := range l.GetList() {
|
|
||||||
pack.TypeList = append(pack.TypeList, &tournament.MatchTypeInfo{
|
|
||||||
Name: v.GetName(),
|
|
||||||
SortId: v.GetSortId(),
|
|
||||||
On: v.GetOn(),
|
|
||||||
Id: v.GetId(),
|
|
||||||
})
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
return pack
|
return pack
|
||||||
}
|
}
|
||||||
|
|
|
@ -2394,7 +2394,7 @@ func init() {
|
||||||
if s != nil && !s.deleting && len(s.players) == 0 {
|
if s != nil && !s.deleting && len(s.players) == 0 {
|
||||||
logger.Logger.Warnf("WebService SpecailEmptySceneId destroyroom scene:%v", s.sceneId)
|
logger.Logger.Warnf("WebService SpecailEmptySceneId destroyroom scene:%v", s.sceneId)
|
||||||
s.TryForceDelectMatchInfo()
|
s.TryForceDelectMatchInfo()
|
||||||
s.DoDelete(false)
|
s.ForceDelete(false)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
case 2: //删除所有未开始的房间
|
case 2: //删除所有未开始的房间
|
||||||
|
@ -2405,7 +2405,7 @@ func init() {
|
||||||
if s != nil && !s.deleting && !s.starting && !s.IsHundredScene() {
|
if s != nil && !s.deleting && !s.starting && !s.IsHundredScene() {
|
||||||
logger.Logger.Warnf("WebService SpecailUnstartSceneId destroyroom scene:%v", s.sceneId)
|
logger.Logger.Warnf("WebService SpecailUnstartSceneId destroyroom scene:%v", s.sceneId)
|
||||||
s.TryForceDelectMatchInfo()
|
s.TryForceDelectMatchInfo()
|
||||||
s.DoDelete(false)
|
s.ForceDelete(false)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
default: //删除指定房间
|
default: //删除指定房间
|
||||||
|
@ -2428,7 +2428,7 @@ func init() {
|
||||||
}
|
}
|
||||||
logger.Logger.Warnf("WebService destroyroom scene:%v", s.sceneId)
|
logger.Logger.Warnf("WebService destroyroom scene:%v", s.sceneId)
|
||||||
s.TryForceDelectMatchInfo()
|
s.TryForceDelectMatchInfo()
|
||||||
s.DoDelete(false)
|
s.ForceDelete(false)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return common.ResponseTag_Ok, pack
|
return common.ResponseTag_Ok, pack
|
||||||
|
|
Loading…
Reference in New Issue