重置个人水池调控数据
This commit is contained in:
parent
8eea14794d
commit
aee5f99d9d
|
|
@ -89,6 +89,7 @@ type GameParam struct {
|
||||||
RankPlayerLevelMaxNum int //等级榜最大人数
|
RankPlayerLevelMaxNum int //等级榜最大人数
|
||||||
CloseChannelSwitch bool //关闭渠道开关功能
|
CloseChannelSwitch bool //关闭渠道开关功能
|
||||||
BackendTimeLocal int //后台时区
|
BackendTimeLocal int //后台时区
|
||||||
|
GameStaticsFightVersion int // 对战场游戏统计数据版本号
|
||||||
}
|
}
|
||||||
|
|
||||||
var GameParamPath = "../data/gameparam.json"
|
var GameParamPath = "../data/gameparam.json"
|
||||||
|
|
|
||||||
|
|
@ -1941,6 +1941,22 @@ func CSPlayerData(s *netlib.Session, packetid int, data interface{}, sid int64)
|
||||||
if ls.clog != nil {
|
if ls.clog != nil {
|
||||||
PlayerSubjectSign.UpdateHeadUrl(p.SnId, ls.clog.HeadUrl)
|
PlayerSubjectSign.UpdateHeadUrl(p.SnId, ls.clog.HeadUrl)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 重置对战场统计数据重置
|
||||||
|
v, ok := p.GDatas[common.GetKeyGameType(2)]
|
||||||
|
if ok && v != nil {
|
||||||
|
if int(v.Statics.Version) < model.GameParamData.GameStaticsFightVersion {
|
||||||
|
v.Statics.Version = int32(model.GameParamData.GameStaticsFightVersion)
|
||||||
|
v.Statics.TotalIn = 0
|
||||||
|
v.Statics.TotalOut = 0
|
||||||
|
v.Statics.Tax = 0
|
||||||
|
v.Statics.MaxSysOut = 0
|
||||||
|
// 个人水池
|
||||||
|
p.TotalIn = 0
|
||||||
|
p.TotalOut = 0
|
||||||
|
p.PlayerTax = 0
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// 有缓存数据
|
// 有缓存数据
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue