This commit is contained in:
meixiongfeng 2022-12-20 17:08:49 +08:00
parent f325fa1f58
commit b82bcbaf5e

View File

@ -68,18 +68,18 @@ func (this *Hero) CreateRepeatHero(session comm.IUserSession, heroCfgId string,
var err error var err error
hero, err = this.modelHero.createHeroOverlying(session.GetUserId(), heroCfgId, num) hero, err = this.modelHero.createHeroOverlying(session.GetUserId(), heroCfgId, num)
if err == nil { if err == nil {
go func(uid string, heroCfgId string) { // 携程处理 图鉴数据 //go func(uid string, heroCfgId string) { // 携程处理 图鉴数据
if db.IsCross() { if db.IsCross() {
this.moduleFetter.SendRpcAddHero(session, heroCfgId) this.moduleFetter.SendRpcAddHero(session, heroCfgId)
} else { } else {
this.moduleFetter.AddHeroFetterData(uid, heroCfgId) this.moduleFetter.AddHeroFetterData(session.GetUserId(), heroCfgId)
} }
heroConf := this.modelHero.moduleHero.configure.GetHeroConfig(heroCfgId) heroConf := this.modelHero.moduleHero.configure.GetHeroConfig(heroCfgId)
if heroConf == nil { if heroConf == nil {
return return
} }
if result, err1 := this.ModuleUser.GetUserExpand(uid); err1 == nil { if result, err1 := this.ModuleUser.GetUserExpand(session.GetUserId()); err1 == nil {
initUpdate := map[string]interface{}{} initUpdate := map[string]interface{}{}
sz := result.GetTujian() sz := result.GetTujian()
if len(sz) == 0 { if len(sz) == 0 {
@ -94,10 +94,10 @@ func (this *Hero) CreateRepeatHero(session comm.IUserSession, heroCfgId string,
} }
initUpdate["tujian"] = sz initUpdate["tujian"] = sz
this.ModuleUser.ChangeUserExpand(uid, initUpdate) this.ModuleUser.ChangeUserExpand(session.GetUserId(), initUpdate)
} }
} }
}(session.GetUserId(), heroCfgId) //}(session.GetUserId(), heroCfgId)
// 统计任务 // 统计任务
this.ModuleRtask.SendToRtask(session, comm.Rtype1, utils.ToInt32(heroCfgId)) this.ModuleRtask.SendToRtask(session, comm.Rtype1, utils.ToInt32(heroCfgId))
// 查品质 // 查品质