竞技场购买报错修复

This commit is contained in:
meixiongfeng 2023-04-28 13:47:12 +08:00
parent 166f969d19
commit ce2fa0c91a

View File

@ -20,7 +20,6 @@ func (this *apiComp) Buy(session comm.IUserSession, req *pb.ArenaBuyReq) (code p
var (
// global *cfg.GameGlobalData
info *pb.DBArenaUser
challenge *cfg.GameArenaBuyChallengeData
need []*cfg.Gameatn
maxbuy, vipbuy int
err error
@ -46,7 +45,7 @@ func (this *apiComp) Buy(session comm.IUserSession, req *pb.ArenaBuyReq) (code p
return
}
if res := this.module.ModuleTools.GetPriceGroupCost(comm.ArenaBuyType, info.Buynum+i+1); len(res) > 0 {
need = append(need, challenge.Need...)
need = append(need, res...)
} else {
code = pb.ErrorCode_ConfigNoFound
return