锦标赛标题优化

This commit is contained in:
hahwu 2026-04-13 19:43:57 +08:00
parent adc9988dad
commit 12efd965e9
2 changed files with 6 additions and 1 deletions

View File

@ -199,6 +199,7 @@ func (r *ActivityMgr) GetChampshipCfg(id int) *protoMsg.ChampionshipCfg {
for _, v := range data.List {
if v.Type == activity.ACT_TYPE_CHAMPION && v.Id == id {
if cfg, ok := v.cfg.(*protoMsg.ChampionshipCfg); ok {
cfg.Title = v.Title
return cfg
}
}

View File

@ -317,10 +317,14 @@ func (p *Player) BackChampship() {
res.EndTime = int32(GoUtil.ZeroTimestamp() + 86400)
if cfg != nil && GoUtil.Now()-GoUtil.ZeroTimestamp() >= int64(cfg.ClearTime) {
res.Status = 1
} else {
cfg = G_GameLogicPtr.ActivityMgr.GetChampshipCfg(yesterdayActivityId)
}
if cfg != nil {
res.Title = cfg.Title
}
if activityInfo != nil {
res.EndTime = int32(activityInfo.EndT)
res.Title = activityInfo.Title
}
res.Cfg = cfg
p.PushClientRes(res)