Merge branch 'dev' of http://git.legu.cc/liwei_3d/go_dreamfactory into dev
This commit is contained in:
commit
b328df88f8
@ -62,16 +62,6 @@ func (this *apiComp) DrawCard(session comm.IUserSession, req *pb.HeroDrawCardReq
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
// 每日抽卡上限校验
|
|
||||||
if cfgGlobal.DrawToplimit < heroRecord.Daycount {
|
|
||||||
errdata = &pb.ErrorData{
|
|
||||||
Code: pb.ErrorCode_HeroDrwaMax,
|
|
||||||
Title: pb.ErrorCode_HeroDrwaMax.ToString(),
|
|
||||||
Message: fmt.Sprintf("单日抽卡达到上限,抽卡次数:%d", cfgGlobal.DrawToplimit),
|
|
||||||
}
|
|
||||||
return
|
|
||||||
}
|
|
||||||
|
|
||||||
for _, v := range drawConf.RecruitmentType {
|
for _, v := range drawConf.RecruitmentType {
|
||||||
appointmap[v.K] = v.S // 指定次抽数据
|
appointmap[v.K] = v.S // 指定次抽数据
|
||||||
}
|
}
|
||||||
@ -83,6 +73,17 @@ func (this *apiComp) DrawCard(session comm.IUserSession, req *pb.HeroDrawCardReq
|
|||||||
if cfgGlobal == nil {
|
if cfgGlobal == nil {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 每日抽卡上限校验
|
||||||
|
if cfgGlobal.DrawToplimit < heroRecord.Daycount {
|
||||||
|
errdata = &pb.ErrorData{
|
||||||
|
Code: pb.ErrorCode_HeroDrwaMax,
|
||||||
|
Title: pb.ErrorCode_HeroDrwaMax.ToString(),
|
||||||
|
Message: fmt.Sprintf("单日抽卡达到上限,抽卡次数:%d", cfgGlobal.DrawToplimit),
|
||||||
|
}
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
if errdata = this.DrawCardCheck(session, req); errdata != nil {
|
if errdata = this.DrawCardCheck(session, req); errdata != nil {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user