副本小怪获取
This commit is contained in:
parent
dcbc9b5490
commit
27745d5d83
@ -54,7 +54,15 @@ func (this *apiComp) Challenge(session comm.IUserSession, req *pb.EnchantChallen
|
||||
if !ok { // 类型校验
|
||||
enchant.Boss[req.BossType] = 0
|
||||
}
|
||||
|
||||
// 获取分数
|
||||
var score int32
|
||||
var format []int32
|
||||
score = int32(enchant.Boss[req.BossType])
|
||||
for _, v := range cfgData {
|
||||
if v.ScoreLow >= score && v.ScoreUp >= score {
|
||||
format = v.Boss
|
||||
}
|
||||
}
|
||||
code, record := this.module.battle.CreatePveBattle(session, &pb.BattlePVEReq{
|
||||
Ptype: pb.PlayType_enchant,
|
||||
Title: "",
|
||||
@ -62,8 +70,9 @@ func (this *apiComp) Challenge(session comm.IUserSession, req *pb.EnchantChallen
|
||||
Leadpos: req.Leadpos,
|
||||
Format: req.Teamids,
|
||||
},
|
||||
//Mformat: cfgData.Boss,
|
||||
Mformat: format,
|
||||
})
|
||||
|
||||
if code != pb.ErrorCode_Success {
|
||||
return
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user