From ec54e9030c0b4dad767e9b5595a9e4f1d8e1fa4c Mon Sep 17 00:00:00 2001 From: meixiongfeng <766881921@qq.com> Date: Tue, 20 Sep 2022 21:27:18 +0800 Subject: [PATCH] =?UTF-8?q?=E6=88=98=E6=96=97=E8=83=9C=E5=88=A9=E5=8A=A0?= =?UTF-8?q?=E8=8B=B1=E9=9B=84=E7=BB=8F=E9=AA=8C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- modules/mainline/api_challengeover.go | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/modules/mainline/api_challengeover.go b/modules/mainline/api_challengeover.go index 9f55cd5ce..c4e8e6f1d 100644 --- a/modules/mainline/api_challengeover.go +++ b/modules/mainline/api_challengeover.go @@ -101,6 +101,15 @@ func (this *apiComp) ChallengeOver(session comm.IUserSession, req *pb.MainlineCh if code = this.module.DispenseRes(session, res, true); code != pb.ErrorCode_Success { this.module.Debugf("DispenseRes err:+%v", res) } + // 加经验 + if req.Report != nil && len(req.Report.Info.Redflist) > 0 { + for _, v := range req.Report.Info.Redflist[0].Team { + if node.Exp > 0 { + this.module.ModuleHero.AddHeroExp(session, v.Oid, node.Exp) + } + } + } + session.SendMsg(string(this.module.GetType()), MainlineChallengeOverResp, &pb.MainlineChallengeOverResp{Data: mainline}) return }