接口不同 校验普通塔是否通关

This commit is contained in:
meixiongfeng 2023-07-13 15:36:59 +08:00
parent ee00954ac0
commit 4ca0fa397a
3 changed files with 21 additions and 1 deletions

View File

@ -313,7 +313,7 @@ type (
IPagoda interface {
ModifyPagodaFloor(session IUserSession, d1 int32, d2 int32) (errdata *pb.ErrorData)
CheckUserBasePagodaInfo(uid string) (data *pb.DBPagodaRecord) // 查询玩家最佳通关记录
CheckCompletePagoda(uid string) (bComplete bool) // 校验是否通关普通塔
// Check Rtype84 Rtype85 Rtype86
CheckPagodaMaxFloor(uid string, pagodaType int32) int32 // 查询塔通关难度type 1 表示普通塔 2 赛季塔
///红点

View File

@ -204,3 +204,12 @@ func (this *Pagoda) GetSeasonData() (endSeasonTime int64) {
return endSeasonTime
}
func (this *Pagoda) CheckCompletePagoda(uid string) (bComplete bool) {
if list, err := this.modelPagoda.getPagodaList(uid); err != nil {
return list.Complete
}
return false
}

View File

@ -111,6 +111,17 @@ func (this *ModelSys) validCond(uid string, condData *cfg.GameOpencondData) stri
return ""
}
}
case 5:
module, err := this.service.GetModule(comm.ModulePagoda)
if err != nil {
this.moduleSys.Debugln(err)
return ""
}
if v, ok := module.(comm.IPagoda); ok {
if !v.CheckCompletePagoda(uid) {
return ""
}
}
}
}
return condData.Id