任务埋点数据调整
This commit is contained in:
parent
8c22d48913
commit
72708679b2
@ -518,11 +518,11 @@ const (
|
|||||||
Rtype33 TaskType = 33 //xx个品质为xx以及以上英雄升到xx级
|
Rtype33 TaskType = 33 //xx个品质为xx以及以上英雄升到xx级
|
||||||
Rtype34 TaskType = 34 //xx个英雄觉醒达到xx阶段
|
Rtype34 TaskType = 34 //xx个英雄觉醒达到xx阶段
|
||||||
Rtype35 TaskType = 35 //xx英雄觉醒达到xx阶段
|
Rtype35 TaskType = 35 //xx英雄觉醒达到xx阶段
|
||||||
Rtype36 TaskType = 36 //xx位xx品质xx职业英雄(xx阵营)觉醒达到xx阶段
|
Rtype36 TaskType = 36 //xx位xx品质xx职业英雄(xx阵营)觉醒达到xx阶段(检查满级,满共鸣,满觉醒的英雄数量,每有一个进度+1)
|
||||||
Rtype37 TaskType = 37 //xx名xx品质英雄满共鸣、等级、觉醒
|
Rtype37 TaskType = 37 //xx名xx品质英雄
|
||||||
Rtype38 TaskType = 38 //xx英雄满级、共鸣、觉醒至最高状态
|
Rtype38 TaskType = 38 //xx英雄满级
|
||||||
Rtype39 TaskType = 39 //累计英雄共鸣xx次
|
Rtype39 TaskType = 39 //累计英雄共鸣xx次
|
||||||
Rtype40 TaskType = 40 //xx个英雄共鸣满xx次
|
Rtype40 TaskType = 40 //将xx个英雄共鸣xx次
|
||||||
Rtype41 TaskType = 41 //xx名英雄穿戴xx件xx星级的装备
|
Rtype41 TaskType = 41 //xx名英雄穿戴xx件xx星级的装备
|
||||||
Rtype42 TaskType = 42 //xx名英雄穿戴xx件xx等级的装备
|
Rtype42 TaskType = 42 //xx名英雄穿戴xx件xx等级的装备
|
||||||
Rtype43 TaskType = 43 //将xx件装备强化至xx级
|
Rtype43 TaskType = 43 //将xx件装备强化至xx级
|
||||||
|
@ -109,14 +109,29 @@ func (this *apiComp) Awaken(session comm.IUserSession, req *pb.HeroAwakenReq) (c
|
|||||||
cfg := this.module.configure.GetHeroConfig(_hero.HeroID)
|
cfg := this.module.configure.GetHeroConfig(_hero.HeroID)
|
||||||
if cfg != nil {
|
if cfg != nil {
|
||||||
szTask = append(szTask, comm.GettaskParam(comm.Rtype121, cfg.Race, utils.ToInt32(_hero.HeroID), _hero.JuexingLv))
|
szTask = append(szTask, comm.GettaskParam(comm.Rtype121, cfg.Race, utils.ToInt32(_hero.HeroID), _hero.JuexingLv))
|
||||||
szTask = append(szTask, comm.GettaskParam(comm.Rtype36, 1, cfg.Color, cfg.Job, cfg.Race, _hero.JuexingLv))
|
|
||||||
|
|
||||||
//xx英雄满级、共鸣、觉醒至最高状态
|
//xx英雄满级、共鸣、觉醒至最高状态
|
||||||
nextAwaken := this.module.configure.GetHeroAwakenConfig(_hero.HeroID, _hero.JuexingLv+1)
|
nextAwaken := this.module.configure.GetHeroAwakenConfig(_hero.HeroID, _hero.JuexingLv+1)
|
||||||
if nextAwaken == nil { // 达到满级觉醒
|
if nextAwaken == nil { // 达到满级觉醒
|
||||||
if _hero.Lv == this.module.configure.GetHeroMaxLv(_hero.Star) {
|
if _hero.Lv == this.module.configure.GetHeroMaxLv(_hero.Star) {
|
||||||
szTask = append(szTask, comm.GettaskParam(comm.Rtype37, 1, cfg.Color))
|
// 校验共鸣满级
|
||||||
szTask = append(szTask, comm.GettaskParam(comm.Rtype38, 1))
|
var _l int32
|
||||||
|
talent, err := this.module.modelTalent.GetHerotalent(session.GetUserId())
|
||||||
|
if err == nil {
|
||||||
|
for _, v := range talent {
|
||||||
|
if v.HeroId == _hero.HeroID {
|
||||||
|
_l = int32(len(v.Talent))
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if this.module.configure.GetHeroTalentMaxLv(_hero.HeroID) == _l {
|
||||||
|
szTask = append(szTask, comm.GettaskParam(comm.Rtype37, 1, cfg.Color))
|
||||||
|
szTask = append(szTask, comm.GettaskParam(comm.Rtype38, 1))
|
||||||
|
szTask = append(szTask, comm.GettaskParam(comm.Rtype36, 1, cfg.Color, cfg.Job, cfg.Race, _hero.JuexingLv))
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -141,11 +141,23 @@ func (this *apiComp) TalentLearn(session comm.IUserSession, req *pb.HeroTalentLe
|
|||||||
szTask = append(szTask, comm.GettaskParam(comm.Rtype123, 1, heroObj.Lv, heroObj.Star))
|
szTask = append(szTask, comm.GettaskParam(comm.Rtype123, 1, heroObj.Lv, heroObj.Star))
|
||||||
szTask = append(szTask, comm.GettaskParam(comm.Rtype124, 1))
|
szTask = append(szTask, comm.GettaskParam(comm.Rtype124, 1))
|
||||||
szTask = append(szTask, comm.GettaskParam(comm.Rtype125, 1, utils.ToInt32(heroObj.HeroID)))
|
szTask = append(szTask, comm.GettaskParam(comm.Rtype125, 1, utils.ToInt32(heroObj.HeroID)))
|
||||||
if cfg := this.module.configure.GetHeroConfig(heroObj.HeroID); cfg != nil {
|
cfg := this.module.configure.GetHeroConfig(heroObj.HeroID)
|
||||||
|
if cfg != nil {
|
||||||
szTask = append(szTask, comm.GettaskParam(comm.Rtype126, 1, cfg.Race))
|
szTask = append(szTask, comm.GettaskParam(comm.Rtype126, 1, cfg.Race))
|
||||||
}
|
}
|
||||||
szTask = append(szTask, comm.GettaskParam(comm.Rtype127, 1, heroObj.Star))
|
szTask = append(szTask, comm.GettaskParam(comm.Rtype127, 1, heroObj.Star))
|
||||||
|
|
||||||
|
nextAwaken := this.module.configure.GetHeroAwakenConfig(heroObj.HeroID, heroObj.JuexingLv+1)
|
||||||
|
if nextAwaken == nil { // 达到满级觉醒
|
||||||
|
if heroObj.Lv == this.module.configure.GetHeroMaxLv(heroObj.Star) {
|
||||||
|
|
||||||
|
if this.module.configure.GetHeroTalentMaxLv(heroObj.HeroID) == int32(len(talent.Talent)) {
|
||||||
|
szTask = append(szTask, comm.GettaskParam(comm.Rtype37, 1, cfg.Color))
|
||||||
|
szTask = append(szTask, comm.GettaskParam(comm.Rtype38, 1))
|
||||||
|
szTask = append(szTask, comm.GettaskParam(comm.Rtype36, 1, cfg.Color, cfg.Job, cfg.Race, heroObj.JuexingLv))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
go this.module.ModuleRtask.TriggerTask(session.GetUserId(), szTask...)
|
go this.module.ModuleRtask.TriggerTask(session.GetUserId(), szTask...)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -385,3 +385,13 @@ func (this *configureComp) GetHeroMaxLv(star int32) int32 {
|
|||||||
|
|
||||||
return 1
|
return 1
|
||||||
}
|
}
|
||||||
|
func (this *configureComp) GetHeroTalentMaxLv(heroid string) (maxlv int32) {
|
||||||
|
if v, err := this.GetConfigure(hero_talentbox); err == nil {
|
||||||
|
if configure, ok := v.(*cfg.GameTalentBox); ok {
|
||||||
|
|
||||||
|
return int32(len(configure.GetDataList()))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
@ -592,14 +592,26 @@ func (this *ModelHero) AddCardExp(session comm.IUserSession, hero *pb.DBHero, ex
|
|||||||
|
|
||||||
if cfg := this.moduleHero.configure.GetHeroConfig(hero.HeroID); cfg != nil {
|
if cfg := this.moduleHero.configure.GetHeroConfig(hero.HeroID); cfg != nil {
|
||||||
szTask = append(szTask, comm.GettaskParam(comm.Rtype32, 1, cfg.Color, hero.Lv))
|
szTask = append(szTask, comm.GettaskParam(comm.Rtype32, 1, cfg.Color, hero.Lv))
|
||||||
szTask = append(szTask, comm.GettaskParam(comm.Rtype36, 1, cfg.Color, cfg.Job, cfg.Race, hero.JuexingLv))
|
|
||||||
|
|
||||||
//xx英雄满级、共鸣、觉醒至最高状态
|
//xx英雄满级、共鸣、觉醒至最高状态
|
||||||
nextAwaken := this.moduleHero.configure.GetHeroAwakenConfig(hero.HeroID, hero.JuexingLv+1)
|
nextAwaken := this.moduleHero.configure.GetHeroAwakenConfig(hero.HeroID, hero.JuexingLv+1)
|
||||||
if nextAwaken == nil { // 达到满级觉醒
|
if nextAwaken == nil { // 达到满级觉醒
|
||||||
if hero.Lv == this.moduleHero.configure.GetHeroMaxLv(hero.Star) {
|
if hero.Lv == this.moduleHero.configure.GetHeroMaxLv(hero.Star) {
|
||||||
szTask = append(szTask, comm.GettaskParam(comm.Rtype37, 1, cfg.Color))
|
var _l int32
|
||||||
szTask = append(szTask, comm.GettaskParam(comm.Rtype38, 1))
|
talent, err := this.moduleHero.modelTalent.GetHerotalent(session.GetUserId())
|
||||||
|
if err == nil {
|
||||||
|
for _, v := range talent {
|
||||||
|
if v.HeroId == hero.HeroID {
|
||||||
|
_l = int32(len(v.Talent))
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if this.moduleHero.configure.GetHeroTalentMaxLv(hero.HeroID) == _l {
|
||||||
|
szTask = append(szTask, comm.GettaskParam(comm.Rtype37, 1, cfg.Color))
|
||||||
|
szTask = append(szTask, comm.GettaskParam(comm.Rtype38, 1))
|
||||||
|
szTask = append(szTask, comm.GettaskParam(comm.Rtype36, 1, cfg.Color, cfg.Job, cfg.Race, hero.JuexingLv))
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -608,6 +620,7 @@ func (this *ModelHero) AddCardExp(session comm.IUserSession, hero *pb.DBHero, ex
|
|||||||
szTask = append(szTask, comm.GettaskParam(comm.Rtype113, hero.Lv))
|
szTask = append(szTask, comm.GettaskParam(comm.Rtype113, hero.Lv))
|
||||||
szTask = append(szTask, comm.GettaskParam(comm.Rtype33, 1, 1, hero.Lv))
|
szTask = append(szTask, comm.GettaskParam(comm.Rtype33, 1, 1, hero.Lv))
|
||||||
szTask = append(szTask, comm.GettaskParam(comm.Rtype118, hero.Lv, hero.JuexingLv))
|
szTask = append(szTask, comm.GettaskParam(comm.Rtype118, hero.Lv, hero.JuexingLv))
|
||||||
|
szTask = append(szTask, comm.GettaskParam(comm.Rtype40, 1, 1))
|
||||||
go this.moduleHero.ModuleRtask.TriggerTask(session.GetUserId(), szTask...)
|
go this.moduleHero.ModuleRtask.TriggerTask(session.GetUserId(), szTask...)
|
||||||
//this.moduleHero.ModuleRtask.SendToRtask(session, comm.Rtype33, 1, 1, hero.Lv)
|
//this.moduleHero.ModuleRtask.SendToRtask(session, comm.Rtype33, 1, 1, hero.Lv)
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user