update
This commit is contained in:
parent
ec82443fec
commit
d401f2135f
@ -50,7 +50,7 @@ func (this *apiComp) Receive(session comm.IUserSession, req *pb.AcademyReceiveRe
|
||||
}
|
||||
|
||||
this.module.DispenseRes(session, level.Award, true)
|
||||
go this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype151, 1))
|
||||
this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype151, 1))
|
||||
}
|
||||
session.SendMsg(string(this.module.GetType()), "receive", &pb.AcademyReceiveResp{Issucc: true})
|
||||
return
|
||||
|
@ -40,7 +40,7 @@ func (this *apiComp) Challenge(session comm.IUserSession, req *pb.ArenaChallenge
|
||||
Tasks: record.Tasks,
|
||||
}})
|
||||
// this.module.ModuleRtask.SendToRtask(session, comm.Rtype130, 1)
|
||||
go this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype130, 1))
|
||||
this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype130, 1))
|
||||
} else {
|
||||
session.SendMsg(string(this.module.GetType()), "challenge", &pb.ArenaChallengeResp{Code: cd, Info: nil})
|
||||
}
|
||||
|
@ -62,7 +62,7 @@ func (this *apiComp) ChallengeReward(session comm.IUserSession, req *pb.ArenaCha
|
||||
bulestate = pb.BattleRecordState_DefendLost
|
||||
}
|
||||
// this.module.ModuleRtask.SendToRtask(session, comm.Rtype131, 1)
|
||||
go this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype131, 1))
|
||||
this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype131, 1))
|
||||
} else {
|
||||
if req.Revengeid != "" {
|
||||
redstate = pb.BattleRecordState_RevengeFailed
|
||||
|
@ -139,7 +139,7 @@ func (this *Battle) CreatePveBattle(session comm.IUserSession, req *pb.BattlePVE
|
||||
for _, v := range req.Format.Friendformat {
|
||||
if v != "" {
|
||||
// this.ModuleRtask.SendToRtask(session, comm.Rtype108, 1)
|
||||
go this.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype108, 1))
|
||||
this.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype108, 1))
|
||||
break
|
||||
}
|
||||
}
|
||||
@ -249,7 +249,7 @@ func (this *Battle) CreateLPVEBattle(session comm.IUserSession, req *pb.BattleLP
|
||||
for _, v := range req.Format.Friendformat {
|
||||
if v != "" {
|
||||
// this.ModuleRtask.SendToRtask(session, comm.Rtype108, 1)
|
||||
go this.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype108, 1))
|
||||
this.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype108, 1))
|
||||
break
|
||||
}
|
||||
}
|
||||
@ -378,7 +378,7 @@ func (this *Battle) CheckBattleReport(session comm.IUserSession, report *pb.Batt
|
||||
this.moonfantasy.Trigger(session, report)
|
||||
for _, v := range report.Completetask {
|
||||
// this.ModuleRtask.SendToRtask(session, comm.Rtype157, int32(report.Info.Ptype), v)
|
||||
go this.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype157, int32(report.Info.Ptype), v))
|
||||
this.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype157, int32(report.Info.Ptype), v))
|
||||
}
|
||||
return pb.ErrorCode_Success, true
|
||||
}
|
||||
|
@ -21,6 +21,6 @@ func (this *apiComp) BuyOrSell(session comm.IUserSession, req *pb.CaravanBuyOrSe
|
||||
}
|
||||
|
||||
// this.module.ModuleRtask.SendToRtask(session, comm.Rtype153, 1)
|
||||
go this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype153, 1))
|
||||
this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype153, 1))
|
||||
return
|
||||
}
|
||||
|
@ -75,7 +75,7 @@ func (this *apiComp) Send(session comm.IUserSession, req *pb.ChatSendReq) (code
|
||||
}
|
||||
go this.module.modelChat.sendChatToWorld(msg, max_chat)
|
||||
// this.module.ModuleRtask.SendToRtask(session, comm.Rtype62, 1)
|
||||
go this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype62, 1))
|
||||
this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype62, 1))
|
||||
//随机任务
|
||||
// if _, err = this.service.AcrossClusterRpcGo(
|
||||
// context.Background(),
|
||||
@ -117,7 +117,7 @@ func (this *apiComp) Send(session comm.IUserSession, req *pb.ChatSendReq) (code
|
||||
|
||||
go this.module.modelChat.sendChatToCrossServer(msg, max_chat)
|
||||
// this.module.ModuleRtask.SendToRtask(session, comm.Rtype106, 1)
|
||||
go this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype106, 1))
|
||||
this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype106, 1))
|
||||
break
|
||||
default:
|
||||
code = pb.ErrorCode_ReqParameterError
|
||||
|
@ -91,7 +91,7 @@ func (this *apiComp) ChallengeReceive(session comm.IUserSession, req *pb.CombatC
|
||||
lv.Pass = true
|
||||
this.module.DispenseRes(session, level.Award, true)
|
||||
// this.module.ModuleRtask.SendToRtask(session, comm.Rtype140, 1, level.Id)
|
||||
go this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype140, 1))
|
||||
this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype140, 1))
|
||||
}
|
||||
lv.Progress = int32((float64(len(lv.Passmanster)+len(lv.Passdrop)) / float64(len(level.Passdroplist)+len(level.PassformatList))) * float64(100))
|
||||
if err = this.module.modelCombat.updateInfo(info); err != nil {
|
||||
|
@ -100,7 +100,7 @@ func (this *apiComp) Drop(session comm.IUserSession, req *pb.CombatDropReq) (cod
|
||||
lv.Pass = true
|
||||
this.module.DispenseRes(session, level.Award, true)
|
||||
// this.module.ModuleRtask.SendToRtask(session, comm.Rtype140, 1, level.Id)
|
||||
go this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype140, 1))
|
||||
this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype140, 1))
|
||||
}
|
||||
lv.Progress = int32((float64(len(lv.Passmanster)+len(lv.Passdrop)) / float64(len(level.Passdroplist)+len(level.PassformatList))) * float64(100))
|
||||
if err = this.module.modelCombat.updateInfo(info); err != nil {
|
||||
|
@ -90,7 +90,7 @@ func (this *apiComp) Ench(session comm.IUserSession, req *pb.EquipmentEnchReq) (
|
||||
}
|
||||
}
|
||||
// this.module.ModuleRtask.SendToRtask(session, comm.Rtype94, 1)
|
||||
go this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype94, 1))
|
||||
this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype94, 1))
|
||||
session.SendMsg(string(this.module.GetType()), "ench", &pb.EquipmentEnchResp{Issucc: true, Equipment: equip})
|
||||
return
|
||||
}
|
||||
|
@ -191,7 +191,7 @@ func (this *apiComp) Equip(session comm.IUserSession, req *pb.EquipmentEquipReq)
|
||||
}
|
||||
|
||||
if len(tasks) > 0 {
|
||||
go this.module.ModuleRtask.TriggerTask(session.GetUserId(), tasks...)
|
||||
this.module.ModuleRtask.TriggerTask(session.GetUserId(), tasks...)
|
||||
}
|
||||
|
||||
session.SendMsg(string(this.module.GetType()), "equip", &pb.EquipmentEquipResp{Equipments: updatequipment})
|
||||
|
@ -208,7 +208,7 @@ func (this *apiComp) Upgrade(session comm.IUserSession, req *pb.EquipmentUpgrade
|
||||
// this.module.ModuleRtask.SendToRtask(session, comm.Rtype96, 1)
|
||||
}
|
||||
if len(tasks) > 0 {
|
||||
go this.module.ModuleRtask.TriggerTask(session.GetUserId(), tasks...)
|
||||
this.module.ModuleRtask.TriggerTask(session.GetUserId(), tasks...)
|
||||
}
|
||||
session.SendMsg(string(this.module.GetType()), "upgrade", &pb.EquipmentUpgradeResp{IsSucc: issucc, Equipment: modifyequipments})
|
||||
return
|
||||
|
@ -67,7 +67,7 @@ func (this *apiComp) Wash(session comm.IUserSession, req *pb.EquipmentWashReq) (
|
||||
}
|
||||
}
|
||||
// this.module.ModuleRtask.SendToRtask(session, comm.Rtype95, 1)
|
||||
go this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype95, 1))
|
||||
this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype95, 1))
|
||||
session.SendMsg(string(this.module.GetType()), "wash", &pb.EquipmentWashResp{Eid: req.Eid, AdverbEntry: adverbEntry})
|
||||
return
|
||||
}
|
||||
|
@ -135,7 +135,7 @@ func (this *modelEquipmentComp) AddEquipments(session comm.IUserSession, cIds ma
|
||||
|
||||
//异步出发任务启动
|
||||
if len(tasks) > 0 {
|
||||
go this.module.ModuleRtask.TriggerTask(session.GetUserId(), tasks...)
|
||||
this.module.ModuleRtask.TriggerTask(session.GetUserId(), tasks...)
|
||||
}
|
||||
|
||||
if len(add) > 0 {
|
||||
|
@ -79,6 +79,6 @@ func (this *apiComp) CreateFood(session comm.IUserSession, req *pb.GourmetCreate
|
||||
Cid: curFood,
|
||||
FirstGet: bFirst,
|
||||
})
|
||||
go this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype150, 1))
|
||||
this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype150, 1))
|
||||
return
|
||||
}
|
||||
|
@ -117,6 +117,6 @@ func (this *apiComp) Awaken(session comm.IUserSession, req *pb.HeroAwakenReq) (c
|
||||
}
|
||||
}
|
||||
}
|
||||
go this.module.ModuleRtask.TriggerTask(session.GetUserId(), szTask...)
|
||||
this.module.ModuleRtask.TriggerTask(session.GetUserId(), szTask...)
|
||||
return
|
||||
}
|
||||
|
@ -121,7 +121,7 @@ func (this *apiComp) Buy(session comm.IUserSession, req *pb.HeroBuyReq) (code pb
|
||||
tasks = append(tasks, comm.GettaskParam(comm.Rtype67, v.N, utils.ToInt32(v.T)))
|
||||
}
|
||||
}
|
||||
go this.module.ModuleRtask.TriggerTask(session.GetUserId(), tasks...)
|
||||
this.module.ModuleRtask.TriggerTask(session.GetUserId(), tasks...)
|
||||
session.SendMsg(string(this.module.GetType()), "buy", &pb.HeroBuyResp{
|
||||
IsSucc: true,
|
||||
Onebuy: record.Onebuy + req.BuyCount,
|
||||
|
@ -86,6 +86,6 @@ func (this *apiComp) Fusion(session comm.IUserSession, req *pb.HeroFusionReq) (c
|
||||
session.SendMsg(string(this.module.GetType()), HeroFusionResp, &pb.HeroFusionResp{Heroid: conf.Hero})
|
||||
// 通过融合获得指定英雄
|
||||
// this.module.ModuleRtask.SendToRtask(session, comm.Rtype139, utils.ToInt32(conf.Hero))
|
||||
go this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype139, utils.ToInt32(conf.Hero)))
|
||||
this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype139, utils.ToInt32(conf.Hero)))
|
||||
return
|
||||
}
|
||||
|
@ -137,6 +137,6 @@ func (this *apiComp) StrengthenUpSkill(session comm.IUserSession, req *pb.HeroSt
|
||||
szTask = append(szTask, comm.GettaskParam(comm.Rtype55, 1, cfg.Color))
|
||||
szTask = append(szTask, comm.GettaskParam(comm.Rtype56, 1, 1, cfg.Job))
|
||||
}
|
||||
go this.module.ModuleRtask.TriggerTask(session.GetUserId(), szTask...)
|
||||
this.module.ModuleRtask.TriggerTask(session.GetUserId(), szTask...)
|
||||
return
|
||||
}
|
||||
|
@ -96,7 +96,7 @@ func (this *apiComp) StrengthenUpStar(session comm.IUserSession, req *pb.HeroStr
|
||||
szTask = append(szTask, comm.GettaskParam(comm.Rtype28, 1))
|
||||
}
|
||||
szTask = append(szTask, comm.GettaskParam(comm.Rtype115, utils.ToInt32(_hero.HeroID), _hero.Star))
|
||||
go this.module.ModuleRtask.TriggerTask(session.GetUserId(), szTask...)
|
||||
this.module.ModuleRtask.TriggerTask(session.GetUserId(), szTask...)
|
||||
// this.module.ModuleRtask.SendToRtask(session, comm.Rtype115, utils.ToInt32(_hero.HeroID), _hero.Star)
|
||||
return
|
||||
}
|
||||
|
@ -100,7 +100,7 @@ func (this *Hero) createRepeatHero(session comm.IUserSession, heroCfgId string,
|
||||
szTask = append(szTask, comm.GettaskParam(comm.Rtype1, 1, utils.ToInt32(heroCfgId)))
|
||||
szTask = append(szTask, comm.GettaskParam(comm.Rtype30, 1, cfg.Color))
|
||||
szTask = append(szTask, comm.GettaskParam(comm.Rtype31, 1, cfg.Color))
|
||||
go this.ModuleRtask.TriggerTask(session.GetUserId(), szTask...)
|
||||
this.ModuleRtask.TriggerTask(session.GetUserId(), szTask...)
|
||||
}
|
||||
|
||||
return
|
||||
@ -174,7 +174,7 @@ func (this *Hero) SendRdTask(session comm.IUserSession) {
|
||||
//this.ModuleRtask.SendToRtask(session, comm.Rtype46, v1, k1, k)
|
||||
}
|
||||
}
|
||||
go this.ModuleRtask.TriggerTask(session.GetUserId(), szTask...)
|
||||
this.ModuleRtask.TriggerTask(session.GetUserId(), szTask...)
|
||||
}
|
||||
|
||||
//英雄列表
|
||||
@ -759,7 +759,7 @@ func (this *Hero) SendTaskMsg(session comm.IUserSession, szStar []int32, drawCou
|
||||
}
|
||||
|
||||
szTask = append(szTask, comm.GettaskParam(comm.Rtype89, drawCount))
|
||||
go this.ModuleRtask.TriggerTask(session.GetUserId(), szTask...)
|
||||
this.ModuleRtask.TriggerTask(session.GetUserId(), szTask...)
|
||||
}
|
||||
|
||||
func (this *Hero) newCondition(heroRecord *pb.DBHeroRecord) (get bool, starIndex int32) {
|
||||
|
@ -140,6 +140,6 @@ func (this *apiComp) ChallengeOver(session comm.IUserSession, req *pb.HuntingCha
|
||||
}
|
||||
}
|
||||
}
|
||||
go this.module.ModuleRtask.TriggerTask(session.GetUserId(), tasks...)
|
||||
this.module.ModuleRtask.TriggerTask(session.GetUserId(), tasks...)
|
||||
return
|
||||
}
|
||||
|
@ -148,7 +148,7 @@ func (this *apiComp) UseGift(session comm.IUserSession, req *pb.LibraryUseGiftRe
|
||||
}
|
||||
}
|
||||
// this.module.ModuleRtask.SendToRtask(session, comm.Rtype134, utils.ToInt32(_heroObj.Heroid), upLv)
|
||||
go this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype134, utils.ToInt32(_heroObj.Heroid), upLv))
|
||||
this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype134, utils.ToInt32(_heroObj.Heroid), upLv))
|
||||
}
|
||||
|
||||
return
|
||||
|
@ -221,6 +221,6 @@ func (this *apiComp) ChallengeOver(session comm.IUserSession, req *pb.MlineChall
|
||||
}
|
||||
// this.module.ModuleRtask.SendToRtask(session, comm.Rtype160, allStar)
|
||||
tasks = append(tasks, comm.GettaskParam(comm.Rtype160, allStar))
|
||||
go this.module.ModuleRtask.TriggerTask(session.GetUserId(), tasks...)
|
||||
this.module.ModuleRtask.TriggerTask(session.GetUserId(), tasks...)
|
||||
return
|
||||
}
|
||||
|
@ -379,7 +379,7 @@ func (this *ModuleBase) ConsumeRes(session comm.IUserSession, res []*cfg.Gameatn
|
||||
this.Debug("消耗玩家资源", log.Field{Key: "uid", Value: session.GetUserId()}, log.Field{Key: "attrs", Value: attrs})
|
||||
if count, ok := attrs[comm.ResDiamond]; ok {
|
||||
// this.ModuleRtask.SendToRtask(session, comm.Rtype104, -count)
|
||||
go this.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype104, -count))
|
||||
this.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype104, -count))
|
||||
}
|
||||
}
|
||||
if len(items) > 0 {
|
||||
|
@ -47,7 +47,7 @@ func (this *apiComp) Battle(session comm.IUserSession, req *pb.MoonfantasyBattle
|
||||
},
|
||||
})
|
||||
// this.module.ModuleRtask.SendToRtask(session, comm.Rtype88, 1)
|
||||
go this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype88, 1))
|
||||
this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype88, 1))
|
||||
} else {
|
||||
session.SendMsg(string(this.module.GetType()), "battle", &pb.MoonfantasyBattleResp{Code: cd})
|
||||
}
|
||||
|
@ -135,7 +135,7 @@ func (this *modelDreamComp) trigger(session comm.IUserSession) {
|
||||
this.module.modelDream.noticeuserfriend(session, mdata.Id, chat)
|
||||
session.SendMsg(string(this.module.GetType()), "trigger", &pb.MoonfantasyTriggerPush{Issucc: true, Mid: mdata.Id, Monster: mdata.Monster})
|
||||
// this.module.ModuleRtask.SendToRtask(session, comm.Rtype87, 1)
|
||||
go this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype87, 1))
|
||||
this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype87, 1))
|
||||
return
|
||||
}
|
||||
|
||||
@ -189,7 +189,7 @@ func (this *modelDreamComp) triggerbyid(session comm.IUserSession, boosid string
|
||||
this.module.modelDream.noticeuserfriend(session, mdata.Id, chat)
|
||||
session.SendMsg(string(this.module.GetType()), "trigger", &pb.MoonfantasyTriggerPush{Issucc: true, Mid: mdata.Id, Monster: mdata.Monster})
|
||||
// this.module.ModuleRtask.SendToRtask(session, comm.Rtype87, 1)
|
||||
go this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype87, 1))
|
||||
this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype87, 1))
|
||||
return
|
||||
}
|
||||
|
||||
|
@ -155,6 +155,6 @@ func (this *apiComp) ChallengeOver(session comm.IUserSession, req *pb.PagodaChal
|
||||
|
||||
// this.module.ModuleRtask.SendToRtask(session, comm.Rtype58, 1)
|
||||
// this.module.ModuleRtask.SendToRtask(session, comm.Rtype59, pagoda.PagodaId)
|
||||
go this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype58, 1), comm.GettaskParam(comm.Rtype59, pagoda.PagodaId))
|
||||
this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype58, 1), comm.GettaskParam(comm.Rtype59, pagoda.PagodaId))
|
||||
return
|
||||
}
|
||||
|
@ -102,7 +102,7 @@ func (this *apiComp) Practice(session comm.IUserSession, req *pb.PracticePractic
|
||||
"knapsack": room.Knapsack,
|
||||
filed: pillar,
|
||||
})
|
||||
go this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype149, 1))
|
||||
this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype149, 1))
|
||||
session.SendMsg(string(this.module.GetType()), "practice", &pb.PracticePracticeResp{Pillar: pillar})
|
||||
return
|
||||
}
|
||||
|
@ -246,7 +246,7 @@ func (this *apiComp) Receive(session comm.IUserSession, req *pb.PracticeReceiveR
|
||||
this.module.PutUserSession(_session)
|
||||
}
|
||||
}
|
||||
go this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype135, minutes))
|
||||
this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype135, minutes))
|
||||
session.SendMsg(string(this.module.GetType()), "receive", &pb.PracticeReceiveResp{Pillar: pillar, Knapsack: room.Knapsack})
|
||||
return
|
||||
}
|
||||
|
@ -61,7 +61,7 @@ func (this *apiComp) UnLock(session comm.IUserSession, req *pb.PracticeUnLockReq
|
||||
filed: pillar,
|
||||
"pillarf": room.Pillarf,
|
||||
})
|
||||
go this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype152, 1))
|
||||
this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype152, 1))
|
||||
session.SendMsg(string(this.module.GetType()), "unlock", &pb.PracticeUnLockResp{Info: room})
|
||||
return
|
||||
}
|
||||
|
@ -74,7 +74,11 @@ func (this *ModelRtaskRecord) overrideUpdate(uid string, cfg *cfg.GameRdtaskCond
|
||||
update := map[string]interface{}{
|
||||
"vals": record.Vals,
|
||||
}
|
||||
|
||||
if err = this.Change(uid, update); err != nil {
|
||||
this.moduleRtask.Error("更新失败",
|
||||
log.Field{Key: "uid", Value: uid},
|
||||
log.Field{Key: "update", Value: update})
|
||||
return
|
||||
}
|
||||
}
|
||||
|
@ -133,7 +133,7 @@ func (this *apiComp) Buy(session comm.IUserSession, req *pb.ShopBuyReq) (code pb
|
||||
}
|
||||
}
|
||||
if len(tasks) > 0 {
|
||||
go this.module.ModuleRtask.TriggerTask(session.GetUserId(), tasks...)
|
||||
this.module.ModuleRtask.TriggerTask(session.GetUserId(), tasks...)
|
||||
}
|
||||
|
||||
session.SendMsg(string(this.module.GetType()), "buy", &pb.ShopBuyResp{IsSucc: true})
|
||||
|
@ -157,7 +157,7 @@ func (this *apiComp) Getlist(session comm.IUserSession, req *pb.ShopGetListReq)
|
||||
}
|
||||
}
|
||||
// this.module.ModuleRtask.SendToRtask(session, comm.Rtype105, 1)
|
||||
go this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype105, 1))
|
||||
this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype105, 1))
|
||||
this.module.modelShop.Change(session.GetUserId(), map[string]interface{}{"refreshnumgoldShop": shopData.RefreshnumgoldShop, "refreshtimegoldShop": shopData.RefreshtimegoldShop, filed: sdata})
|
||||
} else if !req.IsManualRefresh {
|
||||
// refresh := int(this.module.privilege.GetCountByPrivilegeId(session.GetUserId(), comm.PrivilegeType2))
|
||||
@ -200,7 +200,7 @@ func (this *apiComp) Getlist(session comm.IUserSession, req *pb.ShopGetListReq)
|
||||
goods = transGoods(items, sdata)
|
||||
this.module.modelShop.Change(session.GetUserId(), map[string]interface{}{filed: sdata})
|
||||
// this.module.ModuleRtask.SendToRtask(session, comm.Rtype105, 1)
|
||||
go this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype105, 1))
|
||||
this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype105, 1))
|
||||
} else { //返回以前的商品列表
|
||||
if items, err = this.module.configure.GetShopItemsConfigureByIds(sdata.Items...); err != nil {
|
||||
code = pb.ErrorCode_SystemError
|
||||
|
@ -135,5 +135,5 @@ func (this *Smithy) SendRdTask(session comm.IUserSession, Items []*pb.UserAtno)
|
||||
// this.ModuleRtask.SendToRtask(session, comm.Rtype148, v, k)
|
||||
}
|
||||
tasks = append(tasks, comm.GettaskParam(comm.Rtype148, int32(len(equip))))
|
||||
go this.ModuleRtask.TriggerTask(session.GetUserId(), tasks...)
|
||||
this.ModuleRtask.TriggerTask(session.GetUserId(), tasks...)
|
||||
}
|
||||
|
@ -55,7 +55,7 @@ func (this *apiComp) Agree(session comm.IUserSession, req *pb.SociatyAgreeReq) (
|
||||
|
||||
// 触发任务条件
|
||||
// this.module.ModuleRtask.SendToRtask(session, comm.Rtype109, 1)
|
||||
go this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype109, 1))
|
||||
this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype109, 1))
|
||||
// 发邮件
|
||||
if err := this.module.modelSociaty.sendMail("GuildApproved", []string{sociaty.Name}, []string{req.Uid}); err != nil {
|
||||
this.module.Error("发送邮件 模板ID:GuildApproved",
|
||||
|
@ -96,7 +96,7 @@ func (this *apiComp) Apply(session comm.IUserSession, req *pb.SociatyApplyReq) (
|
||||
if !isCheck {
|
||||
// 触发任务条件
|
||||
// this.module.ModuleRtask.SendToRtask(session, comm.Rtype109, 1)
|
||||
go this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype109, 1))
|
||||
this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype109, 1))
|
||||
}
|
||||
rsp := &pb.SociatyApplyResp{
|
||||
Uid: uid,
|
||||
|
@ -169,6 +169,6 @@ func (this *apiComp) BuyOrSell(session comm.IUserSession, req *pb.TrollBuyOrSell
|
||||
}
|
||||
|
||||
// this.module.ModuleRtask.SendToRtask(session, comm.Rtype153, 1)
|
||||
go this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype153, 1))
|
||||
this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype153, 1))
|
||||
return
|
||||
}
|
||||
|
@ -133,7 +133,7 @@ func (this *apiComp) Login(session comm.IUserSession, req *pb.UserLoginReq) (cod
|
||||
this.module.RecoverUserPsStart(user.Uid)
|
||||
// 日常登录任务
|
||||
// this.module.ModuleRtask.SendToRtask(session, comm.Rtype8, 1)
|
||||
go this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype8, 1))
|
||||
this.module.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype8, 1))
|
||||
this.module.ModulePrivilege.CheckDailyPrivilegeMail(session)
|
||||
|
||||
rsp.Data = user
|
||||
|
@ -418,7 +418,7 @@ func (this *User) change(session comm.IUserSession, attr string, add int32) (cha
|
||||
code = pb.ErrorCode_GoldNoEnough
|
||||
return
|
||||
}
|
||||
go this.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype68, -(add)))
|
||||
this.ModuleRtask.TriggerTask(session.GetUserId(), comm.GettaskParam(comm.Rtype68, -(add)))
|
||||
}
|
||||
change.Gold += int64(add)
|
||||
case comm.ResExp:
|
||||
|
@ -152,6 +152,6 @@ func (this *apiComp) ChallengeOver(session comm.IUserSession, req *pb.VikingChal
|
||||
}
|
||||
}
|
||||
}
|
||||
go this.module.ModuleRtask.TriggerTask(session.GetUserId(), szTask...)
|
||||
this.module.ModuleRtask.TriggerTask(session.GetUserId(), szTask...)
|
||||
return
|
||||
}
|
||||
|
@ -333,7 +333,7 @@ func (this *Viking) AutoBattleOver(session comm.IUserSession, Report *pb.BattleR
|
||||
}
|
||||
}
|
||||
|
||||
go this.ModuleRtask.TriggerTask(session.GetUserId(), tasks...)
|
||||
this.ModuleRtask.TriggerTask(session.GetUserId(), tasks...)
|
||||
return
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user