更新校验
This commit is contained in:
parent
589f438106
commit
575e3736d5
@ -189,7 +189,11 @@ func (this *ModelRtask) verifyRtype5(uid string, cfg *cfg.GameRdtaskCondiData) (
|
||||
}
|
||||
|
||||
if ml, y := m.(comm.IHero); y {
|
||||
var hero *pb.DBHero
|
||||
var (
|
||||
hero *pb.DBHero
|
||||
heroId string
|
||||
)
|
||||
|
||||
for _, v := range ml.GetHeroList(uid) {
|
||||
if cast.ToString(cfg.Data1) == v.HeroID {
|
||||
hero = v
|
||||
@ -199,13 +203,14 @@ func (this *ModelRtask) verifyRtype5(uid string, cfg *cfg.GameRdtaskCondiData) (
|
||||
|
||||
var count int32
|
||||
if hero != nil {
|
||||
heroId = hero.HeroID
|
||||
for _, v := range hero.EquipID {
|
||||
if v != "" {
|
||||
count++
|
||||
}
|
||||
}
|
||||
}
|
||||
if ok, err = soEqual(hero.HeroID, cast.ToString(cfg.Data1)); !ok {
|
||||
if ok, err = soEqual(heroId, cast.ToString(cfg.Data1)); !ok {
|
||||
return
|
||||
}
|
||||
return soGreatEqual(count, cfg.Data2)
|
||||
|
@ -99,7 +99,7 @@ func (this *apiComp) Create(session comm.IUserSession, req *pb.UserCreateReq) (c
|
||||
}
|
||||
|
||||
//初始化用户设置
|
||||
this.module.modelSetting.InitSetting(session.GetUserId())
|
||||
// this.module.modelSetting.InitSetting(session.GetUserId())
|
||||
|
||||
if err := session.SendMsg(string(this.module.GetType()), UserSubTypeCreate, &pb.UserCreateResp{IsSucc: true}); err != nil {
|
||||
code = pb.ErrorCode_SystemError
|
||||
|
Loading…
Reference in New Issue
Block a user