diff --git a/modules/herotask/api_receive.go b/modules/herotask/api_receive.go index c13c46ef9..a476f0777 100644 --- a/modules/herotask/api_receive.go +++ b/modules/herotask/api_receive.go @@ -96,9 +96,16 @@ func (this *apiComp) Receive(session comm.IUserSession, req *pb.HeroTaskReceiveR }) } dtask.Heros[req.Hero].Stage[req.Stage] = 1 - this.module.modeltask.Change(session.GetUserId(), map[string]interface{}{ + if err = this.module.modeltask.Change(session.GetUserId(), map[string]interface{}{ "heros": dtask.Heros, - }) + }); err != nil { + errdata = &pb.ErrorData{ + Code: pb.ErrorCode_DBError, + Title: pb.ErrorCode_DBError.ToString(), + Message: err.Error(), + } + return + } session.SendMsg(string(this.module.GetType()), "receive", &pb.HeroTaskReceiveResp{Hero: req.Hero, Stage: req.Stage, Award: award}) return } diff --git a/modules/horoscope/api_rest.go b/modules/horoscope/api_rest.go index d2ff658ce..ab9ef28b1 100644 --- a/modules/horoscope/api_rest.go +++ b/modules/horoscope/api_rest.go @@ -46,7 +46,20 @@ func (this *apiComp) Reset(session comm.IUserSession, req *pb.HoroscopeResetReq) if errdata = this.module.ConsumeRes(session, []*cfg.Gameatn{conf.HoroscopeResetCost}, true); errdata != nil { return } + res := make([]*cfg.Gameatn, 0) + for _, v := range info.Consume { + res = append(res, &cfg.Gameatn{ + A: v.A, + T: v.T, + N: v.N, + }) + } + if errdata = this.module.DispenseRes(session, res, true); errdata != nil { + return + } + consume := info.Consume info.Nodes = make(map[int32]int32) + info.Consume = make([]*pb.UserAssets, 0) info.Lastrest = configure.Now().Unix() if err = this.module.modelHoroscope.updateInfo(session, info); err != nil { errdata = &pb.ErrorData{ @@ -56,6 +69,6 @@ func (this *apiComp) Reset(session comm.IUserSession, req *pb.HoroscopeResetReq) } return } - session.SendMsg(string(this.module.GetType()), "reset", &pb.HoroscopeResetResp{Issucc: true, Info: info}) + session.SendMsg(string(this.module.GetType()), "reset", &pb.HoroscopeResetResp{Issucc: true, Info: info, Award: consume}) return } diff --git a/modules/horoscope/api_upgrade.go b/modules/horoscope/api_upgrade.go index 93f3c3f32..3127dd1db 100644 --- a/modules/horoscope/api_upgrade.go +++ b/modules/horoscope/api_upgrade.go @@ -18,6 +18,7 @@ func (this *apiComp) Upgrade(session comm.IUserSession, req *pb.HoroscopeUpgrade info *pb.DBHoroscope conf *cfg.GameHoroscopeData front *cfg.GameHoroscopeData + ok bool err error ) if errdata = this.UpgradeCheck(session, req); errdata != nil { @@ -73,6 +74,24 @@ func (this *apiComp) Upgrade(session comm.IUserSession, req *pb.HoroscopeUpgrade if info.Nodes[conf.NodeId] == 1 { //解锁 go this.module.ModuleBuried.TriggerBuried(session.Clone(), comm.GetBuriedParam(comm.Rtype173, 1)) } + + for _, v := range conf.CostItem { + ok = false + for _, v1 := range info.Consume { + if v.A == v1.A && v.T == v1.T { + v1.N += v.N + ok = true + } + } + if !ok { + info.Consume = append(info.Consume, &pb.UserAssets{ + A: v.A, + T: v.T, + N: v.N, + }) + } + } + if err = this.module.modelHoroscope.updateInfo(session, info); err != nil { errdata = &pb.ErrorData{ Code: pb.ErrorCode_DBError, @@ -81,6 +100,7 @@ func (this *apiComp) Upgrade(session comm.IUserSession, req *pb.HoroscopeUpgrade } return } + session.SendMsg(string(this.module.GetType()), "upgrade", &pb.HoroscopeUpgradeResp{Nid: conf.NodeId, Lv: conf.Lv + 1}) return } diff --git a/modules/horoscope/modelhoroscope.go b/modules/horoscope/modelhoroscope.go index fc0caab9a..68a8bbdce 100644 --- a/modules/horoscope/modelhoroscope.go +++ b/modules/horoscope/modelhoroscope.go @@ -61,6 +61,7 @@ func (this *modelHoroscope) updateInfo(session comm.IUserSession, info *pb.DBHor ) err = this.Change(info.Uid, map[string]interface{}{ "nodes": info.Nodes, + "consume": info.Consume, "lastrest": info.Lastrest, }) if model, err = this.module.GetDBModelByUid(info.Uid, this.TableName); err != nil { diff --git a/modules/robot/modulerobot_arena.go b/modules/robot/modulerobot_arena.go index 41004c8a2..c67370521 100644 --- a/modules/robot/modulerobot_arena.go +++ b/modules/robot/modulerobot_arena.go @@ -2,6 +2,7 @@ package robot import ( "errors" + "fmt" "go_dreamfactory/comm" "go_dreamfactory/pb" cfg "go_dreamfactory/sys/configure/structs" @@ -47,11 +48,11 @@ func (this *ModuleRobot_Arena) DoTask(robot IRobot, taskconf *cfg.GameWorldTaskD errdata *pb.ErrorData ) if _, errdata = robot.SendMessage("arena", "info", &pb.ArenaInfoReq{}); errdata != nil { - err = errors.New(errdata.Message) + err = errors.New(fmt.Sprintf("code:%d message:%s", errdata.Code, errdata.Message)) return } if _, errdata = robot.SendMessage("arena", "matche", &pb.ArenaMatcheReq{}); errdata != nil { - err = errors.New(errdata.Message) + err = errors.New(fmt.Sprintf("code:%d message:%s", errdata.Code, errdata.Message)) return } switch comm.TaskType(condconf.Type) { @@ -75,7 +76,7 @@ func (this *ModuleRobot_Arena) DoTask(robot IRobot, taskconf *cfg.GameWorldTaskD Battle: &pb.BattleFormation{ Format: heros, }}); errdata != nil { - err = errors.New(errdata.Message) + err = errors.New(fmt.Sprintf("code:%d message:%s", errdata.Code, errdata.Message)) return } if _, errdata = robot.SendTaskMessage(taskconf.Key, condconf.Id, "arena", "challengeover", &pb.ArenaChallengeRewardReq{ @@ -87,7 +88,7 @@ func (this *ModuleRobot_Arena) DoTask(robot IRobot, taskconf *cfg.GameWorldTaskD Info: resp.(*pb.MainlineChallengeResp).Info, WinSide: 1, }}); errdata != nil { - err = errors.New(errdata.Message) + err = errors.New(fmt.Sprintf("code:%d message:%s", errdata.Code, errdata.Message)) return } break diff --git a/modules/robot/modulerobot_equipment.go b/modules/robot/modulerobot_equipment.go index bef7d5af3..a6e1f886e 100644 --- a/modules/robot/modulerobot_equipment.go +++ b/modules/robot/modulerobot_equipment.go @@ -47,7 +47,7 @@ func (this *ModuleRobot_Equipment) DoPipeline(robot IRobot) (err error) { errdata *pb.ErrorData ) if _, errdata = robot.SendMessage("equipment", "getlist", &pb.EquipmentGetListReq{}); errdata != nil { - err = errors.New(errdata.Message) + err = errors.New(fmt.Sprintf("code:%d message:%s", errdata.Code, errdata.Message)) return } return @@ -82,7 +82,7 @@ func (this *ModuleRobot_Equipment) DoTask(robot IRobot, taskconf *cfg.GameWorldT HeroCardId: hero.Id, EquipmentId: equipments, }); errdata != nil { - err = errors.New(errdata.Message) + err = errors.New(fmt.Sprintf("code:%d message:%s", errdata.Code, errdata.Message)) return } } else { @@ -111,7 +111,7 @@ func (this *ModuleRobot_Equipment) DoTask(robot IRobot, taskconf *cfg.GameWorldT HeroCardId: hero.Id, EquipmentId: equipments, }); errdata != nil { - err = errors.New(errdata.Message) + err = errors.New(fmt.Sprintf("code:%d message:%s", errdata.Code, errdata.Message)) return } } else { @@ -127,7 +127,12 @@ func (this *ModuleRobot_Equipment) DoTask(robot IRobot, taskconf *cfg.GameWorldT if _, errdata = robot.SendTaskMessage(taskconf.Key, condconf.Id, "equipment", "upgrade", &pb.EquipmentUpgradeReq{ EquipmentId: equipment.Id, }); errdata != nil { - err = errors.New(errdata.Message) + if errdata.Code == pb.ErrorCode_EquipmentLvlimitReached { + err = nil + return + } else { + err = errors.New(fmt.Sprintf("code:%d message:%s", errdata.Code, errdata.Message)) + } return } case comm.Rtype94: //附魔 @@ -161,7 +166,7 @@ func (this *ModuleRobot_Equipment) DoTask(robot IRobot, taskconf *cfg.GameWorldT Itemid: item.GridId, Index: 0, }); errdata != nil { - err = errors.New(errdata.Message) + err = errors.New(fmt.Sprintf("code:%d message:%s", errdata.Code, errdata.Message)) return } } @@ -177,7 +182,7 @@ func (this *ModuleRobot_Equipment) DoTask(robot IRobot, taskconf *cfg.GameWorldT if resp, errdata = robot.SendTaskMessage(taskconf.Key, condconf.Id, "equipment", "wash", &pb.EquipmentWashReq{ Eid: equipment.Id, }); errdata != nil { - err = errors.New(errdata.Message) + err = errors.New(fmt.Sprintf("code:%d message:%s", errdata.Code, errdata.Message)) return } pids = make([]int32, 0) @@ -188,7 +193,7 @@ func (this *ModuleRobot_Equipment) DoTask(robot IRobot, taskconf *cfg.GameWorldT Eid: equipment.Id, Pids: pids, }); errdata != nil { - err = errors.New(errdata.Message) + err = errors.New(fmt.Sprintf("code:%d message:%s", errdata.Code, errdata.Message)) return } } @@ -234,7 +239,7 @@ func (this *ModuleRobot_Equipment) findcanupgrade() (equipment *pb.DB_Equipment, equipments = append(equipments, v) } sort.Slice(equipments, func(i, j int) bool { - return equipments[i].Lv < equipments[j].Lv + return equipments[i].Lv > equipments[j].Lv }) for _, equipment = range equipments { if conf, err = this.getGameEquipData(equipment.CId); err != nil { diff --git a/modules/robot/modulerobot_hero.go b/modules/robot/modulerobot_hero.go index 06322cd40..364ed2a1b 100644 --- a/modules/robot/modulerobot_hero.go +++ b/modules/robot/modulerobot_hero.go @@ -2,6 +2,7 @@ package robot import ( "errors" + "fmt" "go_dreamfactory/comm" "go_dreamfactory/pb" cfg "go_dreamfactory/sys/configure/structs" @@ -45,7 +46,7 @@ func (this *ModuleRobot_Hero) DoPipeline(robot IRobot) (err error) { errdata *pb.ErrorData ) if _, errdata = robot.SendMessage("hero", "list", &pb.HeroListReq{}); errdata != nil { - err = errors.New(errdata.Message) + err = errors.New(fmt.Sprintf("code:%d message:%s", errdata.Code, errdata.Message)) return } return @@ -59,7 +60,7 @@ func (this *ModuleRobot_Hero) DoTask(robot IRobot, taskconf *cfg.GameWorldTaskDa switch comm.TaskType(condconf.Type) { case comm.Rtype14: if _, errdata = robot.SendTaskMessage(taskconf.Key, condconf.Id, "hero", "drawcard", &pb.HeroDrawCardReq{DrawType: 2, DrawCount: 1, Consume: 0}); errdata != nil { - err = errors.New(errdata.Message) + err = errors.New(fmt.Sprintf("code:%d message:%s", errdata.Code, errdata.Message)) return } } diff --git a/modules/robot/modulerobot_item.go b/modules/robot/modulerobot_item.go index b84a38736..63fb85e0b 100644 --- a/modules/robot/modulerobot_item.go +++ b/modules/robot/modulerobot_item.go @@ -2,6 +2,7 @@ package robot import ( "errors" + "fmt" "go_dreamfactory/comm" "go_dreamfactory/pb" cfg "go_dreamfactory/sys/configure/structs" @@ -44,7 +45,7 @@ func (this *ModuleRobot_Item) DoPipeline(robot IRobot) (err error) { errdata *pb.ErrorData ) if _, errdata = robot.SendMessage("items", "getlist", &pb.ItemsGetlistReq{}); errdata != nil { - err = errors.New(errdata.Message) + err = errors.New(fmt.Sprintf("code:%d message:%s", errdata.Code, errdata.Message)) return } return @@ -58,7 +59,7 @@ func (this *ModuleRobot_Item) DoTask(robot IRobot, taskconf *cfg.GameWorldTaskDa switch comm.TaskType(condconf.Type) { case comm.Rtype14: if _, errdata = robot.SendTaskMessage(taskconf.Key, condconf.Id, "hero", "drawcard", &pb.HeroDrawCardReq{DrawType: 2, DrawCount: 1, Consume: 0}); errdata != nil { - err = errors.New(errdata.Message) + err = errors.New(fmt.Sprintf("code:%d message:%s", errdata.Code, errdata.Message)) return } } diff --git a/modules/robot/modulerobot_mainline.go b/modules/robot/modulerobot_mainline.go index 4bcdfc345..3a95368d3 100644 --- a/modules/robot/modulerobot_mainline.go +++ b/modules/robot/modulerobot_mainline.go @@ -61,7 +61,7 @@ func (this *ModuleRobot_MainLine) DoTask(robot IRobot, taskconf *cfg.GameWorldTa errdata *pb.ErrorData ) if _, errdata = robot.SendMessage("mainline", "info", &pb.MainlineInfoReq{}); errdata != nil { - err = errors.New(errdata.Message) + err = errors.New(fmt.Sprintf("code:%d message:%s", errdata.Code, errdata.Message)) return } switch comm.TaskType(condconf.Type) { @@ -93,20 +93,20 @@ func (this *ModuleRobot_MainLine) DoTask(robot IRobot, taskconf *cfg.GameWorldTa &pb.MainlineChallengeReq{Level: conf.Id, Battle: &pb.BattleFormation{ Format: heros, }}); errdata != nil { - err = errors.New(errdata.Message) + err = errors.New(fmt.Sprintf("code:%d message:%s", errdata.Code, errdata.Message)) return } if _, errdata = robot.SendTaskMessage(taskconf.Key, condconf.Id, "mainline", "challengeover", &pb.MainlineChallengeOverReq{Level: conf.Id, Report: &pb.BattleReport{ Info: resp.(*pb.MainlineChallengeResp).Info, WinSide: 1, }}); errdata != nil { - err = errors.New(errdata.Message) + err = errors.New(fmt.Sprintf("code:%d message:%s", errdata.Code, errdata.Message)) return } break case 3, 7: if _, errdata = robot.SendTaskMessage(taskconf.Key, condconf.Id, "mainline", "levelpass", &pb.MainlineLevelPassReq{Level: conf.Id}); errdata != nil { - err = errors.New(errdata.Message) + err = errors.New(fmt.Sprintf("code:%d message:%s", errdata.Code, errdata.Message)) return } default: diff --git a/modules/robot/modulerobot_pagoda.go b/modules/robot/modulerobot_pagoda.go index 73e390ac9..711bae217 100644 --- a/modules/robot/modulerobot_pagoda.go +++ b/modules/robot/modulerobot_pagoda.go @@ -52,7 +52,7 @@ func (this *ModuleRobot_Pagoda) DoTask(robot IRobot, taskconf *cfg.GameWorldTask ) // 获取爬塔信息 if _, errdata = robot.SendMessage("pagoda", "getlist", &pb.PagodaGetListReq{}); errdata != nil { - err = errors.New(errdata.Message) + err = errors.New(fmt.Sprintf("code:%d message:%s", errdata.Code, errdata.Message)) return } switch comm.TaskType(condconf.Type) { @@ -72,7 +72,7 @@ func (this *ModuleRobot_Pagoda) DoTask(robot IRobot, taskconf *cfg.GameWorldTask Battle: &pb.BattleFormation{ Format: heros, }}); errdata != nil { - err = errors.New(errdata.Message) + err = errors.New(fmt.Sprintf("code:%d message:%s", errdata.Code, errdata.Message)) return } if _, errdata = robot.SendTaskMessage(taskconf.Key, condconf.Id, "pagoda", "challengeover", &pb.PagodaChallengeOverReq{ @@ -81,7 +81,7 @@ func (this *ModuleRobot_Pagoda) DoTask(robot IRobot, taskconf *cfg.GameWorldTask Info: resp.(*pb.PagodaChallengeResp).Info, WinSide: 1, }}); errdata != nil { - err = errors.New(errdata.Message) + err = errors.New(fmt.Sprintf("code:%d message:%s", errdata.Code, errdata.Message)) return } break diff --git a/modules/robot/modulerobot_practice.go b/modules/robot/modulerobot_practice.go index 6f8af61bd..71d17f634 100644 --- a/modules/robot/modulerobot_practice.go +++ b/modules/robot/modulerobot_practice.go @@ -42,7 +42,7 @@ func (this *ModuleRobot_Practice) DoTask(robot IRobot, taskconf *cfg.GameWorldTa errdata *pb.ErrorData ) if _, errdata = robot.SendMessage("practice", "info", &pb.PracticeInfoReq{}); errdata != nil { - err = errors.New(errdata.Message) + err = errors.New(fmt.Sprintf("code:%d message:%s", errdata.Code, errdata.Message)) return } switch comm.TaskType(condconf.Type) { @@ -116,7 +116,7 @@ func (this *ModuleRobot_Practice) practice(tid, cid int32, robot IRobot, index i return } if _, errdata = robot.SendTaskMessage(tid, cid, "practice", "practice", &pb.PracticePracticeReq{Index: index, Hero: hero}); errdata != nil { - err = errors.New(errdata.Message) + err = errors.New(fmt.Sprintf("code:%d message:%s", errdata.Code, errdata.Message)) return } return diff --git a/modules/robot/modulerobot_sys.go b/modules/robot/modulerobot_sys.go index a9524d8ae..c9cb8fdbd 100644 --- a/modules/robot/modulerobot_sys.go +++ b/modules/robot/modulerobot_sys.go @@ -2,6 +2,7 @@ package robot import ( "errors" + "fmt" "go_dreamfactory/comm" "go_dreamfactory/pb" cfg "go_dreamfactory/sys/configure/structs" @@ -36,7 +37,7 @@ func (this *ModuleRobot_Sys) DoPipeline(robot IRobot) (err error) { errdata *pb.ErrorData ) if _, errdata = robot.SendMessage("sys", "funcgetlist", &pb.SysFuncGetListReq{}); errdata != nil { - err = errors.New(errdata.Message) + err = errors.New(fmt.Sprintf("code:%d message:%s", errdata.Code, errdata.Message)) return } return @@ -50,7 +51,7 @@ func (this *ModuleRobot_Sys) DoTask(robot IRobot, taskconf *cfg.GameWorldTaskDat switch comm.TaskType(condconf.Type) { case comm.Rtype14: if _, errdata = robot.SendMessage("hero", "drawcard", &pb.HeroDrawCardReq{DrawType: 2, DrawCount: 1, Consume: 0}); errdata != nil { - err = errors.New(errdata.Message) + err = errors.New(fmt.Sprintf("code:%d message:%s", errdata.Code, errdata.Message)) return } } @@ -68,7 +69,7 @@ func (this *ModuleRobot_Sys) funcactivate(tid, sid int32, robot IRobot, cid stri } if _, errdata = robot.SendTaskMessage(tid, sid, "sys", "funcactivate", &pb.SysFuncActivateReq{Cid: cid}); errdata != nil { - err = errors.New(errdata.Message) + err = errors.New(fmt.Sprintf("code:%d message:%s", errdata.Code, errdata.Message)) return } return diff --git a/modules/robot/modulerobot_user.go b/modules/robot/modulerobot_user.go index a84b7ed6b..534d1de15 100644 --- a/modules/robot/modulerobot_user.go +++ b/modules/robot/modulerobot_user.go @@ -2,6 +2,7 @@ package robot import ( "errors" + "fmt" "go_dreamfactory/pb" cfg "go_dreamfactory/sys/configure/structs" @@ -43,7 +44,7 @@ func (this *ModuleRobot_User) DoPipeline(robot IRobot) (err error) { Account: robot.Account(), Sid: robot.ServerId(), }); errdata != nil { - err = errors.New(errdata.Message) + err = errors.New(fmt.Sprintf("code:%d message:%s", errdata.Code, errdata.Message)) return } //创角 @@ -55,7 +56,7 @@ func (this *ModuleRobot_User) DoPipeline(robot IRobot) (err error) { if errdata.Code == pb.ErrorCode_RoleCreated { //已创角 err = nil } else { - err = errors.New(errdata.Message) + err = errors.New(fmt.Sprintf("code:%d message:%s", errdata.Code, errdata.Message)) } return diff --git a/modules/robot/modulerobot_wtask.go b/modules/robot/modulerobot_wtask.go index a0d5539b9..4f0df2ec4 100644 --- a/modules/robot/modulerobot_wtask.go +++ b/modules/robot/modulerobot_wtask.go @@ -2,6 +2,7 @@ package robot import ( "errors" + "fmt" "go_dreamfactory/comm" "go_dreamfactory/lego/core" "go_dreamfactory/lego/sys/log" @@ -91,7 +92,7 @@ func (this *ModuleRobot_WTask) DoPipeline(robot IRobot) (err error) { ) //获取任务列表 if _, errdata = robot.SendMessage("wtask", "info", &pb.WTaskInfoReq{}); errdata != nil { - err = errors.New(errdata.Message) + err = errors.New(fmt.Sprintf("code:%d message:%s", errdata.Code, errdata.Message)) return } var ( @@ -108,7 +109,7 @@ locp: } if this.checkaccept(tconf) { //是否需要接收任务 if _, errdata = robot.SendMessage("wtask", "accept", &pb.WTaskAcceptReq{Tid: tconf.Key}); errdata != nil { - err = errors.New(errdata.Message) + err = errors.New(fmt.Sprintf("code:%d message:%s", errdata.Code, errdata.Message)) return } continue @@ -148,7 +149,7 @@ locp: continue } else { //任务已完成直接完成 if _, errdata = robot.SendMessage("wtask", "finish", &pb.WTaskFinishReq{Tid: tconf.Key}); errdata != nil { - err = errors.New(errdata.Message) + err = errors.New(fmt.Sprintf("code:%d message:%s", errdata.Code, errdata.Message)) return } } @@ -164,7 +165,7 @@ func (this *ModuleRobot_WTask) DoTask(robot IRobot, taskconf *cfg.GameWorldTaskD switch comm.TaskType(condconf.Type) { case comm.Rtype20001: //完成对话 if _, errdata = robot.SendTaskMessage(taskconf.Key, condconf.Id, "wtask", "completecondi", &pb.WTaskCompleteCondiReq{TaskId: taskconf.Key, CondiId: condconf.Id}); errdata != nil { - err = errors.New(errdata.Message) + err = errors.New(fmt.Sprintf("code:%d message:%s", errdata.Code, errdata.Message)) return } break @@ -177,14 +178,14 @@ func (this *ModuleRobot_WTask) DoTask(robot IRobot, taskconf *cfg.GameWorldTaskD heromodule = robot.GetModule(comm.ModuleHero).(*ModuleRobot_Hero) heros = heromodule.getbattlehero() if resp, errdata = robot.SendTaskMessage(taskconf.Key, condconf.Id, "wtask", "battlestart", &pb.WTaskBattleStartReq{BattleConfId: condconf.Filter[0], Battle: &pb.BattleFormation{Format: heros}}); errdata != nil { - err = errors.New(errdata.Message) + err = errors.New(fmt.Sprintf("code:%d message:%s", errdata.Code, errdata.Message)) return } if _, errdata = robot.SendTaskMessage(taskconf.Key, condconf.Id, "wtask", "battlefinish", &pb.WTaskBattleFinishReq{BattleConfId: condconf.Filter[0], Report: &pb.BattleReport{ Info: resp.(*pb.WTaskBattleStartResp).Info, WinSide: 1, }}); errdata != nil { - err = errors.New(errdata.Message) + err = errors.New(fmt.Sprintf("code:%d message:%s", errdata.Code, errdata.Message)) return } break @@ -197,14 +198,14 @@ func (this *ModuleRobot_WTask) DoTask(robot IRobot, taskconf *cfg.GameWorldTaskD heromodule = robot.GetModule(comm.ModuleHero).(*ModuleRobot_Hero) heros = heromodule.getbattlehero() if resp, errdata = robot.SendTaskMessage(taskconf.Key, condconf.Id, "wtask", "battlestart", &pb.WTaskBattleStartReq{BattleConfId: condconf.Filter[0], Battle: &pb.BattleFormation{Format: heros}}); errdata != nil { - err = errors.New(errdata.Message) + err = errors.New(fmt.Sprintf("code:%d message:%s", errdata.Code, errdata.Message)) return } if _, errdata = robot.SendTaskMessage(taskconf.Key, condconf.Id, "wtask", "battlefinish", &pb.WTaskBattleFinishReq{BattleConfId: condconf.Filter[0], Report: &pb.BattleReport{ Info: resp.(*pb.WTaskBattleStartResp).Info, WinSide: 2, }}); errdata != nil { - err = errors.New(errdata.Message) + err = errors.New(fmt.Sprintf("code:%d message:%s", errdata.Code, errdata.Message)) return } break diff --git a/modules/robot/robot.go b/modules/robot/robot.go index 35e611438..3bc6be58b 100644 --- a/modules/robot/robot.go +++ b/modules/robot/robot.go @@ -168,7 +168,7 @@ func (this *Robot) SendTaskMessage(task, comdi int32, mtype, stype string, msg p messageresp = <-this.await //等待回应 resp = messageresp.resp errdata = messageresp.errdata - log.Debug("[机器人 Message]", log.Field{Key: "t", Value: time.Since(stime).Milliseconds()}, log.Field{Key: "Account", Value: this.account}, log.Field{Key: "Task", Value: fmt.Sprintf("[%d-%d]", task, comdi)}, log.Field{Key: "message", Value: fmt.Sprintf("%s.%s", mtype, stype)}, log.Field{Key: "resp", Value: errdata == nil}) + log.Debug("[机器人 Message]", log.Field{Key: "t", Value: time.Since(stime).Milliseconds()}, log.Field{Key: "Account", Value: this.account}, log.Field{Key: "Task", Value: fmt.Sprintf("[%d-%d]", task, comdi)}, log.Field{Key: "message", Value: fmt.Sprintf("%s.%s", mtype, stype)}, log.Field{Key: "errdata", Value: errdata == nil}) } return } diff --git a/pb/activity_db.pb.go b/pb/activity_db.pb.go index 2294187a9..7a741fd34 100644 --- a/pb/activity_db.pb.go +++ b/pb/activity_db.pb.go @@ -225,26 +225,13 @@ type DBHuodong struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id" bson:"_id"` //ID - Hdid int32 `protobuf:"varint,2,opt,name=hdid,proto3" json:"hdid"` // 活动ID 此字段不用 - Rtime int64 `protobuf:"varint,3,opt,name=rtime,proto3" json:"rtime"` // 客户端显示的时间 - Itype HdType `protobuf:"varint,4,opt,name=itype,proto3,enum=HdType" json:"itype"` - Name string `protobuf:"bytes,5,opt,name=name,proto3" json:"name"` - Img string `protobuf:"bytes,6,opt,name=img,proto3" json:"img"` - Showtime string `protobuf:"bytes,7,opt,name=showtime,proto3" json:"showtime"` - PressImg string `protobuf:"bytes,8,opt,name=pressImg,proto3" json:"pressImg"` - Intr string `protobuf:"bytes,9,opt,name=intr,proto3" json:"intr"` // "累计充值,限时福利", - Etime int64 `protobuf:"varint,10,opt,name=etime,proto3" json:"etime"` // 1680105599, - NormalImg string `protobuf:"bytes,11,opt,name=normalImg,proto3" json:"normalImg"` // "huodong_btn4.png", - Stime int64 `protobuf:"varint,12,opt,name=stime,proto3" json:"stime"` // 1679414400, - Tab int32 `protobuf:"varint,13,opt,name=tab,proto3" json:"tab"` - Ttype int32 `protobuf:"varint,14,opt,name=ttype,proto3" json:"ttype"` - Icon string `protobuf:"bytes,15,opt,name=icon,proto3" json:"icon"` //"ico_event_yxjl", - Open int32 `protobuf:"varint,16,opt,name=open,proto3" json:"open"` - Order int32 `protobuf:"varint,17,opt,name=order,proto3" json:"order"` - Stype int32 `protobuf:"varint,18,opt,name=stype,proto3" json:"stype"` - Htype int32 `protobuf:"varint,19,opt,name=htype,proto3" json:"htype"` - Data *ActivityInfo `protobuf:"bytes,20,opt,name=data,proto3" json:"data"` // 活动详细数据 + Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id" bson:"_id"` //ID + Rtime int64 `protobuf:"varint,2,opt,name=rtime,proto3" json:"rtime"` // 活动修改时间 + Itype HdType `protobuf:"varint,3,opt,name=itype,proto3,enum=HdType" json:"itype"` + Name string `protobuf:"bytes,4,opt,name=name,proto3" json:"name"` + Etime int64 `protobuf:"varint,5,opt,name=etime,proto3" json:"etime"` // 1680105599, + Stime int64 `protobuf:"varint,6,opt,name=stime,proto3" json:"stime"` // 1679414400, + Data *ActivityInfo `protobuf:"bytes,7,opt,name=data,proto3" json:"data"` // 活动详细数据 } func (x *DBHuodong) Reset() { @@ -286,13 +273,6 @@ func (x *DBHuodong) GetId() string { return "" } -func (x *DBHuodong) GetHdid() int32 { - if x != nil { - return x.Hdid - } - return 0 -} - func (x *DBHuodong) GetRtime() int64 { if x != nil { return x.Rtime @@ -314,34 +294,6 @@ func (x *DBHuodong) GetName() string { return "" } -func (x *DBHuodong) GetImg() string { - if x != nil { - return x.Img - } - return "" -} - -func (x *DBHuodong) GetShowtime() string { - if x != nil { - return x.Showtime - } - return "" -} - -func (x *DBHuodong) GetPressImg() string { - if x != nil { - return x.PressImg - } - return "" -} - -func (x *DBHuodong) GetIntr() string { - if x != nil { - return x.Intr - } - return "" -} - func (x *DBHuodong) GetEtime() int64 { if x != nil { return x.Etime @@ -349,13 +301,6 @@ func (x *DBHuodong) GetEtime() int64 { return 0 } -func (x *DBHuodong) GetNormalImg() string { - if x != nil { - return x.NormalImg - } - return "" -} - func (x *DBHuodong) GetStime() int64 { if x != nil { return x.Stime @@ -363,55 +308,6 @@ func (x *DBHuodong) GetStime() int64 { return 0 } -func (x *DBHuodong) GetTab() int32 { - if x != nil { - return x.Tab - } - return 0 -} - -func (x *DBHuodong) GetTtype() int32 { - if x != nil { - return x.Ttype - } - return 0 -} - -func (x *DBHuodong) GetIcon() string { - if x != nil { - return x.Icon - } - return "" -} - -func (x *DBHuodong) GetOpen() int32 { - if x != nil { - return x.Open - } - return 0 -} - -func (x *DBHuodong) GetOrder() int32 { - if x != nil { - return x.Order - } - return 0 -} - -func (x *DBHuodong) GetStype() int32 { - if x != nil { - return x.Stype - } - return 0 -} - -func (x *DBHuodong) GetHtype() int32 { - if x != nil { - return x.Htype - } - return 0 -} - func (x *DBHuodong) GetData() *ActivityInfo { if x != nil { return x.Data @@ -519,74 +415,55 @@ var file_activity_activity_db_proto_rawDesc = []byte{ 0x03, 0x76, 0x61, 0x6c, 0x22, 0x2a, 0x0a, 0x0c, 0x41, 0x63, 0x74, 0x69, 0x76, 0x69, 0x74, 0x79, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x1a, 0x0a, 0x05, 0x70, 0x72, 0x69, 0x7a, 0x65, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x04, 0x2e, 0x41, 0x72, 0x72, 0x52, 0x05, 0x70, 0x72, 0x69, 0x7a, 0x65, - 0x22, 0xd5, 0x03, 0x0a, 0x09, 0x44, 0x42, 0x48, 0x75, 0x6f, 0x64, 0x6f, 0x6e, 0x67, 0x12, 0x0e, - 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x12, - 0x0a, 0x04, 0x68, 0x64, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x04, 0x68, 0x64, - 0x69, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x72, 0x74, 0x69, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x05, 0x72, 0x74, 0x69, 0x6d, 0x65, 0x12, 0x1d, 0x0a, 0x05, 0x69, 0x74, 0x79, 0x70, - 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x07, 0x2e, 0x48, 0x64, 0x54, 0x79, 0x70, 0x65, - 0x52, 0x05, 0x69, 0x74, 0x79, 0x70, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, - 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x10, 0x0a, 0x03, 0x69, - 0x6d, 0x67, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x69, 0x6d, 0x67, 0x12, 0x1a, 0x0a, - 0x08, 0x73, 0x68, 0x6f, 0x77, 0x74, 0x69, 0x6d, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x08, 0x73, 0x68, 0x6f, 0x77, 0x74, 0x69, 0x6d, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x70, 0x72, 0x65, - 0x73, 0x73, 0x49, 0x6d, 0x67, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x72, 0x65, - 0x73, 0x73, 0x49, 0x6d, 0x67, 0x12, 0x12, 0x0a, 0x04, 0x69, 0x6e, 0x74, 0x72, 0x18, 0x09, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x04, 0x69, 0x6e, 0x74, 0x72, 0x12, 0x14, 0x0a, 0x05, 0x65, 0x74, 0x69, - 0x6d, 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x65, 0x74, 0x69, 0x6d, 0x65, 0x12, - 0x1c, 0x0a, 0x09, 0x6e, 0x6f, 0x72, 0x6d, 0x61, 0x6c, 0x49, 0x6d, 0x67, 0x18, 0x0b, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x09, 0x6e, 0x6f, 0x72, 0x6d, 0x61, 0x6c, 0x49, 0x6d, 0x67, 0x12, 0x14, 0x0a, - 0x05, 0x73, 0x74, 0x69, 0x6d, 0x65, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x73, 0x74, - 0x69, 0x6d, 0x65, 0x12, 0x10, 0x0a, 0x03, 0x74, 0x61, 0x62, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x05, - 0x52, 0x03, 0x74, 0x61, 0x62, 0x12, 0x14, 0x0a, 0x05, 0x74, 0x74, 0x79, 0x70, 0x65, 0x18, 0x0e, - 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x74, 0x74, 0x79, 0x70, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x69, - 0x63, 0x6f, 0x6e, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x69, 0x63, 0x6f, 0x6e, 0x12, - 0x12, 0x0a, 0x04, 0x6f, 0x70, 0x65, 0x6e, 0x18, 0x10, 0x20, 0x01, 0x28, 0x05, 0x52, 0x04, 0x6f, - 0x70, 0x65, 0x6e, 0x12, 0x14, 0x0a, 0x05, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x18, 0x11, 0x20, 0x01, - 0x28, 0x05, 0x52, 0x05, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x12, 0x14, 0x0a, 0x05, 0x73, 0x74, 0x79, - 0x70, 0x65, 0x18, 0x12, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x73, 0x74, 0x79, 0x70, 0x65, 0x12, - 0x14, 0x0a, 0x05, 0x68, 0x74, 0x79, 0x70, 0x65, 0x18, 0x13, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, - 0x68, 0x74, 0x79, 0x70, 0x65, 0x12, 0x21, 0x0a, 0x04, 0x64, 0x61, 0x74, 0x61, 0x18, 0x14, 0x20, - 0x01, 0x28, 0x0b, 0x32, 0x0d, 0x2e, 0x41, 0x63, 0x74, 0x69, 0x76, 0x69, 0x74, 0x79, 0x49, 0x6e, - 0x66, 0x6f, 0x52, 0x04, 0x64, 0x61, 0x74, 0x61, 0x22, 0xe6, 0x01, 0x0a, 0x0e, 0x44, 0x42, 0x41, - 0x63, 0x74, 0x69, 0x76, 0x69, 0x74, 0x79, 0x44, 0x61, 0x74, 0x61, 0x12, 0x0e, 0x0a, 0x02, 0x69, - 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x10, 0x0a, 0x03, 0x75, - 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x75, 0x69, 0x64, 0x12, 0x14, 0x0a, - 0x05, 0x68, 0x64, 0x6f, 0x69, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x68, 0x64, - 0x6f, 0x69, 0x64, 0x12, 0x33, 0x0a, 0x06, 0x67, 0x6f, 0x74, 0x61, 0x72, 0x72, 0x18, 0x04, 0x20, - 0x03, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x44, 0x42, 0x41, 0x63, 0x74, 0x69, 0x76, 0x69, 0x74, 0x79, - 0x44, 0x61, 0x74, 0x61, 0x2e, 0x47, 0x6f, 0x74, 0x61, 0x72, 0x72, 0x45, 0x6e, 0x74, 0x72, 0x79, - 0x52, 0x06, 0x67, 0x6f, 0x74, 0x61, 0x72, 0x72, 0x12, 0x1a, 0x0a, 0x08, 0x6c, 0x61, 0x73, 0x74, - 0x74, 0x69, 0x6d, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x6c, 0x61, 0x73, 0x74, - 0x74, 0x69, 0x6d, 0x65, 0x12, 0x10, 0x0a, 0x03, 0x76, 0x61, 0x6c, 0x18, 0x06, 0x20, 0x01, 0x28, - 0x05, 0x52, 0x03, 0x76, 0x61, 0x6c, 0x1a, 0x39, 0x0a, 0x0b, 0x47, 0x6f, 0x74, 0x61, 0x72, 0x72, - 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, - 0x28, 0x05, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, - 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, - 0x01, 0x2a, 0xdd, 0x02, 0x0a, 0x06, 0x48, 0x64, 0x54, 0x79, 0x70, 0x65, 0x12, 0x0e, 0x0a, 0x0a, - 0x48, 0x64, 0x54, 0x79, 0x70, 0x65, 0x4e, 0x75, 0x6c, 0x6c, 0x10, 0x00, 0x12, 0x12, 0x0a, 0x0e, - 0x48, 0x64, 0x54, 0x79, 0x70, 0x65, 0x57, 0x61, 0x72, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x10, 0x01, - 0x12, 0x0d, 0x0a, 0x09, 0x48, 0x64, 0x54, 0x79, 0x70, 0x65, 0x50, 0x61, 0x79, 0x10, 0x02, 0x12, - 0x0f, 0x0a, 0x0b, 0x4b, 0x46, 0x53, 0x65, 0x76, 0x65, 0x6e, 0x54, 0x61, 0x73, 0x6b, 0x10, 0x03, - 0x12, 0x12, 0x0a, 0x0e, 0x58, 0x53, 0x46, 0x75, 0x6e, 0x64, 0x50, 0x68, 0x79, 0x73, 0x69, 0x63, - 0x61, 0x6c, 0x10, 0x04, 0x12, 0x11, 0x0a, 0x0d, 0x58, 0x53, 0x46, 0x75, 0x6e, 0x64, 0x52, 0x65, - 0x63, 0x72, 0x75, 0x69, 0x74, 0x10, 0x05, 0x12, 0x0d, 0x0a, 0x09, 0x58, 0x53, 0x46, 0x75, 0x6e, - 0x64, 0x45, 0x78, 0x70, 0x10, 0x06, 0x12, 0x0b, 0x0a, 0x07, 0x48, 0x64, 0x4c, 0x65, 0x76, 0x65, - 0x6c, 0x10, 0x07, 0x12, 0x0e, 0x0a, 0x0a, 0x48, 0x64, 0x54, 0x79, 0x70, 0x65, 0x53, 0x69, 0x67, - 0x6e, 0x10, 0x08, 0x12, 0x0e, 0x0a, 0x0a, 0x48, 0x64, 0x54, 0x79, 0x70, 0x65, 0x44, 0x72, 0x61, - 0x77, 0x10, 0x09, 0x12, 0x11, 0x0a, 0x0d, 0x41, 0x64, 0x64, 0x55, 0x70, 0x52, 0x65, 0x63, 0x68, - 0x61, 0x72, 0x67, 0x65, 0x10, 0x0a, 0x12, 0x17, 0x0a, 0x13, 0x53, 0x68, 0x6f, 0x70, 0x43, 0x65, - 0x6e, 0x74, 0x65, 0x72, 0x50, 0x61, 0x79, 0x50, 0x61, 0x6b, 0x63, 0x67, 0x65, 0x10, 0x0b, 0x12, - 0x12, 0x0a, 0x0e, 0x53, 0x75, 0x70, 0x70, 0x6c, 0x79, 0x57, 0x61, 0x72, 0x4f, 0x72, 0x64, 0x65, - 0x72, 0x10, 0x0c, 0x12, 0x15, 0x0a, 0x11, 0x4d, 0x6f, 0x6f, 0x6e, 0x64, 0x72, 0x65, 0x61, 0x6d, - 0x57, 0x61, 0x72, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x10, 0x0d, 0x12, 0x14, 0x0a, 0x0f, 0x48, 0x64, - 0x54, 0x79, 0x70, 0x65, 0x54, 0x75, 0x72, 0x6e, 0x74, 0x61, 0x62, 0x6c, 0x65, 0x10, 0xe9, 0x07, - 0x12, 0x12, 0x0a, 0x0d, 0x48, 0x64, 0x43, 0x65, 0x6c, 0x65, 0x62, 0x72, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x10, 0xea, 0x07, 0x12, 0x0d, 0x0a, 0x08, 0x48, 0x64, 0x50, 0x75, 0x7a, 0x7a, 0x6c, 0x65, - 0x10, 0xeb, 0x07, 0x12, 0x0e, 0x0a, 0x09, 0x48, 0x64, 0x4c, 0x61, 0x74, 0x74, 0x69, 0x63, 0x65, - 0x10, 0xec, 0x07, 0x12, 0x0c, 0x0a, 0x07, 0x48, 0x64, 0x4d, 0x69, 0x6e, 0x65, 0x72, 0x10, 0xed, - 0x07, 0x42, 0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, - 0x33, + 0x22, 0xb3, 0x01, 0x0a, 0x09, 0x44, 0x42, 0x48, 0x75, 0x6f, 0x64, 0x6f, 0x6e, 0x67, 0x12, 0x0e, + 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x14, + 0x0a, 0x05, 0x72, 0x74, 0x69, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x72, + 0x74, 0x69, 0x6d, 0x65, 0x12, 0x1d, 0x0a, 0x05, 0x69, 0x74, 0x79, 0x70, 0x65, 0x18, 0x03, 0x20, + 0x01, 0x28, 0x0e, 0x32, 0x07, 0x2e, 0x48, 0x64, 0x54, 0x79, 0x70, 0x65, 0x52, 0x05, 0x69, 0x74, + 0x79, 0x70, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x65, 0x74, 0x69, 0x6d, 0x65, + 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x65, 0x74, 0x69, 0x6d, 0x65, 0x12, 0x14, 0x0a, + 0x05, 0x73, 0x74, 0x69, 0x6d, 0x65, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x73, 0x74, + 0x69, 0x6d, 0x65, 0x12, 0x21, 0x0a, 0x04, 0x64, 0x61, 0x74, 0x61, 0x18, 0x07, 0x20, 0x01, 0x28, + 0x0b, 0x32, 0x0d, 0x2e, 0x41, 0x63, 0x74, 0x69, 0x76, 0x69, 0x74, 0x79, 0x49, 0x6e, 0x66, 0x6f, + 0x52, 0x04, 0x64, 0x61, 0x74, 0x61, 0x22, 0xe6, 0x01, 0x0a, 0x0e, 0x44, 0x42, 0x41, 0x63, 0x74, + 0x69, 0x76, 0x69, 0x74, 0x79, 0x44, 0x61, 0x74, 0x61, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x10, 0x0a, 0x03, 0x75, 0x69, 0x64, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x75, 0x69, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x68, + 0x64, 0x6f, 0x69, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x68, 0x64, 0x6f, 0x69, + 0x64, 0x12, 0x33, 0x0a, 0x06, 0x67, 0x6f, 0x74, 0x61, 0x72, 0x72, 0x18, 0x04, 0x20, 0x03, 0x28, + 0x0b, 0x32, 0x1b, 0x2e, 0x44, 0x42, 0x41, 0x63, 0x74, 0x69, 0x76, 0x69, 0x74, 0x79, 0x44, 0x61, + 0x74, 0x61, 0x2e, 0x47, 0x6f, 0x74, 0x61, 0x72, 0x72, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x06, + 0x67, 0x6f, 0x74, 0x61, 0x72, 0x72, 0x12, 0x1a, 0x0a, 0x08, 0x6c, 0x61, 0x73, 0x74, 0x74, 0x69, + 0x6d, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x6c, 0x61, 0x73, 0x74, 0x74, 0x69, + 0x6d, 0x65, 0x12, 0x10, 0x0a, 0x03, 0x76, 0x61, 0x6c, 0x18, 0x06, 0x20, 0x01, 0x28, 0x05, 0x52, + 0x03, 0x76, 0x61, 0x6c, 0x1a, 0x39, 0x0a, 0x0b, 0x47, 0x6f, 0x74, 0x61, 0x72, 0x72, 0x45, 0x6e, + 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, + 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, + 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x2a, + 0xdd, 0x02, 0x0a, 0x06, 0x48, 0x64, 0x54, 0x79, 0x70, 0x65, 0x12, 0x0e, 0x0a, 0x0a, 0x48, 0x64, + 0x54, 0x79, 0x70, 0x65, 0x4e, 0x75, 0x6c, 0x6c, 0x10, 0x00, 0x12, 0x12, 0x0a, 0x0e, 0x48, 0x64, + 0x54, 0x79, 0x70, 0x65, 0x57, 0x61, 0x72, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x10, 0x01, 0x12, 0x0d, + 0x0a, 0x09, 0x48, 0x64, 0x54, 0x79, 0x70, 0x65, 0x50, 0x61, 0x79, 0x10, 0x02, 0x12, 0x0f, 0x0a, + 0x0b, 0x4b, 0x46, 0x53, 0x65, 0x76, 0x65, 0x6e, 0x54, 0x61, 0x73, 0x6b, 0x10, 0x03, 0x12, 0x12, + 0x0a, 0x0e, 0x58, 0x53, 0x46, 0x75, 0x6e, 0x64, 0x50, 0x68, 0x79, 0x73, 0x69, 0x63, 0x61, 0x6c, + 0x10, 0x04, 0x12, 0x11, 0x0a, 0x0d, 0x58, 0x53, 0x46, 0x75, 0x6e, 0x64, 0x52, 0x65, 0x63, 0x72, + 0x75, 0x69, 0x74, 0x10, 0x05, 0x12, 0x0d, 0x0a, 0x09, 0x58, 0x53, 0x46, 0x75, 0x6e, 0x64, 0x45, + 0x78, 0x70, 0x10, 0x06, 0x12, 0x0b, 0x0a, 0x07, 0x48, 0x64, 0x4c, 0x65, 0x76, 0x65, 0x6c, 0x10, + 0x07, 0x12, 0x0e, 0x0a, 0x0a, 0x48, 0x64, 0x54, 0x79, 0x70, 0x65, 0x53, 0x69, 0x67, 0x6e, 0x10, + 0x08, 0x12, 0x0e, 0x0a, 0x0a, 0x48, 0x64, 0x54, 0x79, 0x70, 0x65, 0x44, 0x72, 0x61, 0x77, 0x10, + 0x09, 0x12, 0x11, 0x0a, 0x0d, 0x41, 0x64, 0x64, 0x55, 0x70, 0x52, 0x65, 0x63, 0x68, 0x61, 0x72, + 0x67, 0x65, 0x10, 0x0a, 0x12, 0x17, 0x0a, 0x13, 0x53, 0x68, 0x6f, 0x70, 0x43, 0x65, 0x6e, 0x74, + 0x65, 0x72, 0x50, 0x61, 0x79, 0x50, 0x61, 0x6b, 0x63, 0x67, 0x65, 0x10, 0x0b, 0x12, 0x12, 0x0a, + 0x0e, 0x53, 0x75, 0x70, 0x70, 0x6c, 0x79, 0x57, 0x61, 0x72, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x10, + 0x0c, 0x12, 0x15, 0x0a, 0x11, 0x4d, 0x6f, 0x6f, 0x6e, 0x64, 0x72, 0x65, 0x61, 0x6d, 0x57, 0x61, + 0x72, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x10, 0x0d, 0x12, 0x14, 0x0a, 0x0f, 0x48, 0x64, 0x54, 0x79, + 0x70, 0x65, 0x54, 0x75, 0x72, 0x6e, 0x74, 0x61, 0x62, 0x6c, 0x65, 0x10, 0xe9, 0x07, 0x12, 0x12, + 0x0a, 0x0d, 0x48, 0x64, 0x43, 0x65, 0x6c, 0x65, 0x62, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x10, + 0xea, 0x07, 0x12, 0x0d, 0x0a, 0x08, 0x48, 0x64, 0x50, 0x75, 0x7a, 0x7a, 0x6c, 0x65, 0x10, 0xeb, + 0x07, 0x12, 0x0e, 0x0a, 0x09, 0x48, 0x64, 0x4c, 0x61, 0x74, 0x74, 0x69, 0x63, 0x65, 0x10, 0xec, + 0x07, 0x12, 0x0c, 0x0a, 0x07, 0x48, 0x64, 0x4d, 0x69, 0x6e, 0x65, 0x72, 0x10, 0xed, 0x07, 0x42, + 0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( diff --git a/pb/horoscope_db.pb.go b/pb/horoscope_db.pb.go index 971f435d5..9b04cb555 100644 --- a/pb/horoscope_db.pb.go +++ b/pb/horoscope_db.pb.go @@ -29,7 +29,8 @@ type DBHoroscope struct { Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id" bson:"_id"` //ID Uid string `protobuf:"bytes,2,opt,name=uid,proto3" json:"uid"` //uid Nodes map[int32]int32 `protobuf:"bytes,3,rep,name=nodes,proto3" json:"nodes" protobuf_key:"varint,1,opt,name=key,proto3" protobuf_val:"varint,2,opt,name=value,proto3"` //节点信息 key:是节点id value:等级 - Lastrest int64 `protobuf:"varint,4,opt,name=lastrest,proto3" json:"lastrest"` //上次重置时间 + Consume []*UserAssets `protobuf:"bytes,4,rep,name=consume,proto3" json:"consume"` //消耗 用于返还 + Lastrest int64 `protobuf:"varint,5,opt,name=lastrest,proto3" json:"lastrest"` //上次重置时间 } func (x *DBHoroscope) Reset() { @@ -85,6 +86,13 @@ func (x *DBHoroscope) GetNodes() map[int32]int32 { return nil } +func (x *DBHoroscope) GetConsume() []*UserAssets { + if x != nil { + return x.Consume + } + return nil +} + func (x *DBHoroscope) GetLastrest() int64 { if x != nil { return x.Lastrest @@ -96,20 +104,23 @@ var File_horoscope_horoscope_db_proto protoreflect.FileDescriptor var file_horoscope_horoscope_db_proto_rawDesc = []byte{ 0x0a, 0x1c, 0x68, 0x6f, 0x72, 0x6f, 0x73, 0x63, 0x6f, 0x70, 0x65, 0x2f, 0x68, 0x6f, 0x72, 0x6f, - 0x73, 0x63, 0x6f, 0x70, 0x65, 0x5f, 0x64, 0x62, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xb4, - 0x01, 0x0a, 0x0b, 0x44, 0x42, 0x48, 0x6f, 0x72, 0x6f, 0x73, 0x63, 0x6f, 0x70, 0x65, 0x12, 0x0e, - 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x10, - 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x75, 0x69, 0x64, - 0x12, 0x2d, 0x0a, 0x05, 0x6e, 0x6f, 0x64, 0x65, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, - 0x17, 0x2e, 0x44, 0x42, 0x48, 0x6f, 0x72, 0x6f, 0x73, 0x63, 0x6f, 0x70, 0x65, 0x2e, 0x4e, 0x6f, - 0x64, 0x65, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x05, 0x6e, 0x6f, 0x64, 0x65, 0x73, 0x12, - 0x1a, 0x0a, 0x08, 0x6c, 0x61, 0x73, 0x74, 0x72, 0x65, 0x73, 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x08, 0x6c, 0x61, 0x73, 0x74, 0x72, 0x65, 0x73, 0x74, 0x1a, 0x38, 0x0a, 0x0a, 0x4e, - 0x6f, 0x64, 0x65, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76, - 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, - 0x65, 0x3a, 0x02, 0x38, 0x01, 0x42, 0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70, 0x62, 0x62, 0x06, 0x70, - 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x73, 0x63, 0x6f, 0x70, 0x65, 0x5f, 0x64, 0x62, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x0a, + 0x63, 0x6f, 0x6d, 0x6d, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xdb, 0x01, 0x0a, 0x0b, 0x44, + 0x42, 0x48, 0x6f, 0x72, 0x6f, 0x73, 0x63, 0x6f, 0x70, 0x65, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x10, 0x0a, 0x03, 0x75, 0x69, + 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x75, 0x69, 0x64, 0x12, 0x2d, 0x0a, 0x05, + 0x6e, 0x6f, 0x64, 0x65, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x44, 0x42, + 0x48, 0x6f, 0x72, 0x6f, 0x73, 0x63, 0x6f, 0x70, 0x65, 0x2e, 0x4e, 0x6f, 0x64, 0x65, 0x73, 0x45, + 0x6e, 0x74, 0x72, 0x79, 0x52, 0x05, 0x6e, 0x6f, 0x64, 0x65, 0x73, 0x12, 0x25, 0x0a, 0x07, 0x63, + 0x6f, 0x6e, 0x73, 0x75, 0x6d, 0x65, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0b, 0x2e, 0x55, + 0x73, 0x65, 0x72, 0x41, 0x73, 0x73, 0x65, 0x74, 0x73, 0x52, 0x07, 0x63, 0x6f, 0x6e, 0x73, 0x75, + 0x6d, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x6c, 0x61, 0x73, 0x74, 0x72, 0x65, 0x73, 0x74, 0x18, 0x05, + 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x6c, 0x61, 0x73, 0x74, 0x72, 0x65, 0x73, 0x74, 0x1a, 0x38, + 0x0a, 0x0a, 0x4e, 0x6f, 0x64, 0x65, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, + 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, + 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x76, + 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x42, 0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70, 0x62, + 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -128,14 +139,16 @@ var file_horoscope_horoscope_db_proto_msgTypes = make([]protoimpl.MessageInfo, 2 var file_horoscope_horoscope_db_proto_goTypes = []interface{}{ (*DBHoroscope)(nil), // 0: DBHoroscope nil, // 1: DBHoroscope.NodesEntry + (*UserAssets)(nil), // 2: UserAssets } var file_horoscope_horoscope_db_proto_depIdxs = []int32{ 1, // 0: DBHoroscope.nodes:type_name -> DBHoroscope.NodesEntry - 1, // [1:1] is the sub-list for method output_type - 1, // [1:1] is the sub-list for method input_type - 1, // [1:1] is the sub-list for extension type_name - 1, // [1:1] is the sub-list for extension extendee - 0, // [0:1] is the sub-list for field type_name + 2, // 1: DBHoroscope.consume:type_name -> UserAssets + 2, // [2:2] is the sub-list for method output_type + 2, // [2:2] is the sub-list for method input_type + 2, // [2:2] is the sub-list for extension type_name + 2, // [2:2] is the sub-list for extension extendee + 0, // [0:2] is the sub-list for field type_name } func init() { file_horoscope_horoscope_db_proto_init() } @@ -143,6 +156,7 @@ func file_horoscope_horoscope_db_proto_init() { if File_horoscope_horoscope_db_proto != nil { return } + file_comm_proto_init() if !protoimpl.UnsafeEnabled { file_horoscope_horoscope_db_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*DBHoroscope); i { diff --git a/pb/horoscope_msg.pb.go b/pb/horoscope_msg.pb.go index aa686207d..3e004f74b 100644 --- a/pb/horoscope_msg.pb.go +++ b/pb/horoscope_msg.pb.go @@ -256,8 +256,9 @@ type HoroscopeResetResp struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - Issucc bool `protobuf:"varint,1,opt,name=issucc,proto3" json:"issucc"` - Info *DBHoroscope `protobuf:"bytes,2,opt,name=info,proto3" json:"info"` + Issucc bool `protobuf:"varint,1,opt,name=issucc,proto3" json:"issucc"` + Info *DBHoroscope `protobuf:"bytes,2,opt,name=info,proto3" json:"info"` + Award []*UserAssets `protobuf:"bytes,3,rep,name=award,proto3" json:"award"` } func (x *HoroscopeResetResp) Reset() { @@ -306,31 +307,41 @@ func (x *HoroscopeResetResp) GetInfo() *DBHoroscope { return nil } +func (x *HoroscopeResetResp) GetAward() []*UserAssets { + if x != nil { + return x.Award + } + return nil +} + var File_horoscope_horoscope_msg_proto protoreflect.FileDescriptor var file_horoscope_horoscope_msg_proto_rawDesc = []byte{ 0x0a, 0x1d, 0x68, 0x6f, 0x72, 0x6f, 0x73, 0x63, 0x6f, 0x70, 0x65, 0x2f, 0x68, 0x6f, 0x72, 0x6f, 0x73, 0x63, 0x6f, 0x70, 0x65, 0x5f, 0x6d, 0x73, 0x67, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x1c, 0x68, 0x6f, 0x72, 0x6f, 0x73, 0x63, 0x6f, 0x70, 0x65, 0x2f, 0x68, 0x6f, 0x72, 0x6f, 0x73, - 0x63, 0x6f, 0x70, 0x65, 0x5f, 0x64, 0x62, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x12, 0x0a, - 0x10, 0x48, 0x6f, 0x72, 0x6f, 0x73, 0x63, 0x6f, 0x70, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x65, - 0x71, 0x22, 0x35, 0x0a, 0x11, 0x48, 0x6f, 0x72, 0x6f, 0x73, 0x63, 0x6f, 0x70, 0x65, 0x49, 0x6e, - 0x66, 0x6f, 0x52, 0x65, 0x73, 0x70, 0x12, 0x20, 0x0a, 0x04, 0x69, 0x6e, 0x66, 0x6f, 0x18, 0x01, - 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0c, 0x2e, 0x44, 0x42, 0x48, 0x6f, 0x72, 0x6f, 0x73, 0x63, 0x6f, - 0x70, 0x65, 0x52, 0x04, 0x69, 0x6e, 0x66, 0x6f, 0x22, 0x27, 0x0a, 0x13, 0x48, 0x6f, 0x72, 0x6f, - 0x73, 0x63, 0x6f, 0x70, 0x65, 0x55, 0x70, 0x67, 0x72, 0x61, 0x64, 0x65, 0x52, 0x65, 0x71, 0x12, - 0x10, 0x0a, 0x03, 0x6e, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x03, 0x6e, 0x69, - 0x64, 0x22, 0x38, 0x0a, 0x14, 0x48, 0x6f, 0x72, 0x6f, 0x73, 0x63, 0x6f, 0x70, 0x65, 0x55, 0x70, - 0x67, 0x72, 0x61, 0x64, 0x65, 0x52, 0x65, 0x73, 0x70, 0x12, 0x10, 0x0a, 0x03, 0x6e, 0x69, 0x64, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x03, 0x6e, 0x69, 0x64, 0x12, 0x0e, 0x0a, 0x02, 0x6c, - 0x76, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x02, 0x6c, 0x76, 0x22, 0x13, 0x0a, 0x11, 0x48, - 0x6f, 0x72, 0x6f, 0x73, 0x63, 0x6f, 0x70, 0x65, 0x52, 0x65, 0x73, 0x65, 0x74, 0x52, 0x65, 0x71, - 0x22, 0x4e, 0x0a, 0x12, 0x48, 0x6f, 0x72, 0x6f, 0x73, 0x63, 0x6f, 0x70, 0x65, 0x52, 0x65, 0x73, - 0x65, 0x74, 0x52, 0x65, 0x73, 0x70, 0x12, 0x16, 0x0a, 0x06, 0x69, 0x73, 0x73, 0x75, 0x63, 0x63, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x08, 0x52, 0x06, 0x69, 0x73, 0x73, 0x75, 0x63, 0x63, 0x12, 0x20, - 0x0a, 0x04, 0x69, 0x6e, 0x66, 0x6f, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0c, 0x2e, 0x44, - 0x42, 0x48, 0x6f, 0x72, 0x6f, 0x73, 0x63, 0x6f, 0x70, 0x65, 0x52, 0x04, 0x69, 0x6e, 0x66, 0x6f, - 0x42, 0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x63, 0x6f, 0x70, 0x65, 0x5f, 0x64, 0x62, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x0a, 0x63, + 0x6f, 0x6d, 0x6d, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x12, 0x0a, 0x10, 0x48, 0x6f, 0x72, + 0x6f, 0x73, 0x63, 0x6f, 0x70, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x65, 0x71, 0x22, 0x35, 0x0a, + 0x11, 0x48, 0x6f, 0x72, 0x6f, 0x73, 0x63, 0x6f, 0x70, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x65, + 0x73, 0x70, 0x12, 0x20, 0x0a, 0x04, 0x69, 0x6e, 0x66, 0x6f, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, + 0x32, 0x0c, 0x2e, 0x44, 0x42, 0x48, 0x6f, 0x72, 0x6f, 0x73, 0x63, 0x6f, 0x70, 0x65, 0x52, 0x04, + 0x69, 0x6e, 0x66, 0x6f, 0x22, 0x27, 0x0a, 0x13, 0x48, 0x6f, 0x72, 0x6f, 0x73, 0x63, 0x6f, 0x70, + 0x65, 0x55, 0x70, 0x67, 0x72, 0x61, 0x64, 0x65, 0x52, 0x65, 0x71, 0x12, 0x10, 0x0a, 0x03, 0x6e, + 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x03, 0x6e, 0x69, 0x64, 0x22, 0x38, 0x0a, + 0x14, 0x48, 0x6f, 0x72, 0x6f, 0x73, 0x63, 0x6f, 0x70, 0x65, 0x55, 0x70, 0x67, 0x72, 0x61, 0x64, + 0x65, 0x52, 0x65, 0x73, 0x70, 0x12, 0x10, 0x0a, 0x03, 0x6e, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, + 0x28, 0x05, 0x52, 0x03, 0x6e, 0x69, 0x64, 0x12, 0x0e, 0x0a, 0x02, 0x6c, 0x76, 0x18, 0x02, 0x20, + 0x01, 0x28, 0x05, 0x52, 0x02, 0x6c, 0x76, 0x22, 0x13, 0x0a, 0x11, 0x48, 0x6f, 0x72, 0x6f, 0x73, + 0x63, 0x6f, 0x70, 0x65, 0x52, 0x65, 0x73, 0x65, 0x74, 0x52, 0x65, 0x71, 0x22, 0x71, 0x0a, 0x12, + 0x48, 0x6f, 0x72, 0x6f, 0x73, 0x63, 0x6f, 0x70, 0x65, 0x52, 0x65, 0x73, 0x65, 0x74, 0x52, 0x65, + 0x73, 0x70, 0x12, 0x16, 0x0a, 0x06, 0x69, 0x73, 0x73, 0x75, 0x63, 0x63, 0x18, 0x01, 0x20, 0x01, + 0x28, 0x08, 0x52, 0x06, 0x69, 0x73, 0x73, 0x75, 0x63, 0x63, 0x12, 0x20, 0x0a, 0x04, 0x69, 0x6e, + 0x66, 0x6f, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0c, 0x2e, 0x44, 0x42, 0x48, 0x6f, 0x72, + 0x6f, 0x73, 0x63, 0x6f, 0x70, 0x65, 0x52, 0x04, 0x69, 0x6e, 0x66, 0x6f, 0x12, 0x21, 0x0a, 0x05, + 0x61, 0x77, 0x61, 0x72, 0x64, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0b, 0x2e, 0x55, 0x73, + 0x65, 0x72, 0x41, 0x73, 0x73, 0x65, 0x74, 0x73, 0x52, 0x05, 0x61, 0x77, 0x61, 0x72, 0x64, 0x42, + 0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -354,15 +365,17 @@ var file_horoscope_horoscope_msg_proto_goTypes = []interface{}{ (*HoroscopeResetReq)(nil), // 4: HoroscopeResetReq (*HoroscopeResetResp)(nil), // 5: HoroscopeResetResp (*DBHoroscope)(nil), // 6: DBHoroscope + (*UserAssets)(nil), // 7: UserAssets } var file_horoscope_horoscope_msg_proto_depIdxs = []int32{ 6, // 0: HoroscopeInfoResp.info:type_name -> DBHoroscope 6, // 1: HoroscopeResetResp.info:type_name -> DBHoroscope - 2, // [2:2] is the sub-list for method output_type - 2, // [2:2] is the sub-list for method input_type - 2, // [2:2] is the sub-list for extension type_name - 2, // [2:2] is the sub-list for extension extendee - 0, // [0:2] is the sub-list for field type_name + 7, // 2: HoroscopeResetResp.award:type_name -> UserAssets + 3, // [3:3] is the sub-list for method output_type + 3, // [3:3] is the sub-list for method input_type + 3, // [3:3] is the sub-list for extension type_name + 3, // [3:3] is the sub-list for extension extendee + 0, // [0:3] is the sub-list for field type_name } func init() { file_horoscope_horoscope_msg_proto_init() } @@ -371,6 +384,7 @@ func file_horoscope_horoscope_msg_proto_init() { return } file_horoscope_horoscope_db_proto_init() + file_comm_proto_init() if !protoimpl.UnsafeEnabled { file_horoscope_horoscope_msg_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*HoroscopeInfoReq); i {