diff --git a/modules/hunting/api_challengeover.go b/modules/hunting/api_challengeover.go index a0127fd17..4459a295e 100644 --- a/modules/hunting/api_challengeover.go +++ b/modules/hunting/api_challengeover.go @@ -78,6 +78,12 @@ func (this *apiComp) ChallengeOver(session comm.IUserSession, req *pb.HuntingCha this.module.modulerank.updatehuntingRankList(session, req.Difficulty, req.BossType, req.Report.Info.Redflist[0].Leadpos, sz, req.Report.Costtime) } } + + // check + code, _ = this.module.battle.CheckBattleReport(session, req.Report) + if code != pb.ErrorCode_Success { + return + } // 耗时校验 当前战斗胜利时间消耗小于之前刷新数据 hunting.ChallengeCount++ mapData["challengeCount"] = hunting.ChallengeCount diff --git a/modules/pagoda/api_challengeover.go b/modules/pagoda/api_challengeover.go index b916866ae..29ed751dc 100644 --- a/modules/pagoda/api_challengeover.go +++ b/modules/pagoda/api_challengeover.go @@ -65,6 +65,10 @@ func (this *apiComp) ChallengeOver(session comm.IUserSession, req *pb.PagodaChal } } // 校验通过 + code, _ = this.module.battle.CheckBattleReport(session, req.Report) + if code != pb.ErrorCode_Success { + return + } // 加经验 if req.Report != nil && req.Report.Info != nil && len(req.Report.Info.Redflist) > 0 { for _, v := range req.Report.Info.Redflist[0].Team { @@ -140,6 +144,7 @@ func (this *apiComp) ChallengeOver(session comm.IUserSession, req *pb.PagodaChal } this.module.modulerank.addPagodaRankList(session, seasonPagoda, req.Report.Info.Redflist[0].Leadpos, sz, req.Report.Costtime) } + // 挑战处理 seasonPagoda.PagodaId = conf.LayerNum mapData["pagodaId"] = conf.LayerNum diff --git a/modules/viking/api_challengeover.go b/modules/viking/api_challengeover.go index 28f0b6b68..7b20d0f0f 100644 --- a/modules/viking/api_challengeover.go +++ b/modules/viking/api_challengeover.go @@ -81,6 +81,10 @@ func (this *apiComp) ChallengeOver(session comm.IUserSession, req *pb.VikingChal } } // 耗时校验 当前战斗胜利时间消耗小于之前刷新数据 + code, _ = this.module.battle.CheckBattleReport(session, req.Report) + if code != pb.ErrorCode_Success { + return + } viking.ChallengeCount++ mapData["challengeCount"] = viking.ChallengeCount