diff --git a/comm/const.go b/comm/const.go index f41170b71..ad686c601 100644 --- a/comm/const.go +++ b/comm/const.go @@ -999,7 +999,7 @@ const ( AddUpRecharge = 10 //累计充值 - // 特殊类型活动 只受活动开启限制 + // 特殊类型活动 只受活动开启限制 具体玩法 走excel 配置 HdTypeTurntable = 1001 //大转盘 HdCelebration = 1002 // 庆典活动 ) diff --git a/modules/sys/model_sys.go b/modules/sys/model_sys.go index d5bcc552e..aa41e0792 100644 --- a/modules/sys/model_sys.go +++ b/modules/sys/model_sys.go @@ -68,13 +68,12 @@ func (this *ModelSys) validCond(uid string, condData *cfg.GameOpencondData) stri } } case 5: - module, err := this.service.GetModule(comm.ModulePagoda) - if err != nil { - this.moduleSys.Debugln(err) + if !this.moduleSys.pagoda.CheckCompletePagoda(uid) { return "" } - if v, ok := module.(comm.IPagoda); ok { - if !v.CheckCompletePagoda(uid) { + case 6: // 查询工会等级 + if s := this.moduleSys.sociaty.GetSociaty(uid); s != nil { + if s.Lv < conf.Param { return "" } } diff --git a/modules/sys/module.go b/modules/sys/module.go index f4565d098..8ef31dfdf 100644 --- a/modules/sys/module.go +++ b/modules/sys/module.go @@ -20,6 +20,10 @@ type ModuleSys struct { service base.IRPCXService modelSys *ModelSys mainline comm.IMainline + + pagoda comm.IPagoda + + sociaty comm.ISociaty } func NewModule() core.IModule { @@ -54,6 +58,18 @@ func (this *ModuleSys) Start() (err error) { return } this.mainline = module.(comm.IMainline) + + if module, err = this.service.GetModule(comm.ModulePagoda); err != nil { + + return + } + this.pagoda = module.(comm.IPagoda) + + if module, err = this.service.GetModule(comm.ModuleSociaty); err != nil { + + return + } + this.sociaty = module.(comm.ISociaty) return }