From 37cc987fc9e422795cad3dcdbd7a616dbd43d91d Mon Sep 17 00:00:00 2001 From: meixiongfeng <766881921@qq.com> Date: Mon, 17 Jul 2023 19:58:56 +0800 Subject: [PATCH] =?UTF-8?q?=E5=95=86=E9=98=9F=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- comm/imodule.go | 2 + modules/activity/module.go | 88 +++++++++++------------ modules/caravan/api_buyorsell.go | 71 ++++++++++++++++--- modules/caravan/api_getlist.go | 10 +-- modules/caravan/comp_configure.go | 21 ++++++ modules/caravan/module.go | 15 ++-- modules/modulebase.go | 6 ++ modules/user/model_user.go | 34 +++++++++ modules/user/module.go | 3 + pb/caravan_db.pb.go | 111 ++++++++++++++---------------- pb/user_db.pb.go | 92 ++++++++++++++----------- 11 files changed, 289 insertions(+), 164 deletions(-) diff --git a/comm/imodule.go b/comm/imodule.go index 0e21346d8..c42d22cc8 100644 --- a/comm/imodule.go +++ b/comm/imodule.go @@ -180,6 +180,8 @@ type ( ConsumePsAddExp(session IUserSession, ps int32) (addExp int32, errdata *pb.ErrorData) // 体力差 RemainingPS(uid string) int32 + + AddUserProfit(uid string, score int64) error } //武器模块 IEquipment interface { diff --git a/modules/activity/module.go b/modules/activity/module.go index 7de25a88c..37523a760 100644 --- a/modules/activity/module.go +++ b/modules/activity/module.go @@ -1,13 +1,10 @@ package activity import ( - "fmt" "go_dreamfactory/comm" "go_dreamfactory/lego/core" "go_dreamfactory/modules" "go_dreamfactory/pb" - - "go.mongodb.org/mongo-driver/bson/primitive" ) type Activity struct { @@ -62,6 +59,7 @@ func (this *Activity) Start() (err error) { } } } + return } func (this *Activity) OnInstallComp() { @@ -73,49 +71,53 @@ func (this *Activity) OnInstallComp() { } // 创建一条活动数据 +// func (this *Activity) CreateHdData() (err error) { +// var db *pb.DBHuodong +// db = &pb.DBHuodong{ +// Id: primitive.NewObjectID().Hex(), +// Hdid: 10001, +// Rtime: 1680105599, +// Itype: 0, +// Name: "累计充值活动", +// Img: "", +// Showtime: "03月15日00:00-03月20日23:59", +// PressImg: "huodong_btn4_1.png", +// Intr: "累计充值,限时福利", +// Etime: 1680105599, +// NormalImg: "huodong_btn4.png", +// Stime: 1679414400, +// Tab: 2, +// Ttype: 0, +// Icon: "ico_event_yxjl", +// Open: 1, +// Order: 102, +// Stype: 10009, +// Htype: 9, +// Data: &pb.ActivityInfo{}, +// } +// for i := 0; i < 6; i++ { +// var p []*pb.UserAssets +// p = append(p, &pb.UserAssets{ +// A: "item", +// T: "10000001", +// N: 1, +// }) +// db.Data.Prize = append(db.Data.Prize, &pb.Arr{ +// Prize: p, +// Val: int32(i) + 1, +// }) + +// } + +// this.modelhdList.addHdInfo(db) +// fmt.Printf("%v", db) +// return +// } + func (this *Activity) CreateHdData() (err error) { - var db *pb.DBHuodong - db = &pb.DBHuodong{ - Id: primitive.NewObjectID().Hex(), - Hdid: 10001, - Rtime: 1680105599, - Itype: 0, - Name: "累计充值活动", - Img: "", - Showtime: "03月15日00:00-03月20日23:59", - PressImg: "huodong_btn4_1.png", - Intr: "累计充值,限时福利", - Etime: 1680105599, - NormalImg: "huodong_btn4.png", - Stime: 1679414400, - Tab: 2, - Ttype: 0, - Icon: "ico_event_yxjl", - Open: 1, - Order: 102, - Stype: 10009, - Htype: 9, - Data: &pb.ActivityInfo{}, - } - for i := 0; i < 6; i++ { - var p []*pb.UserAssets - p = append(p, &pb.UserAssets{ - A: "item", - T: "10000001", - N: 1, - }) - db.Data.Prize = append(db.Data.Prize, &pb.Arr{ - Prize: p, - Val: int32(i) + 1, - }) - - } - - this.modelhdList.addHdInfo(db) - fmt.Printf("%v", db) + this.modelhdList.getHdInfo() return } - func (this *Activity) GetAllHdInfo() (result []*pb.DBHuodong, err error) { result, err = this.modelhdList.getHdInfo() diff --git a/modules/caravan/api_buyorsell.go b/modules/caravan/api_buyorsell.go index 153855fa4..cf4ed01e4 100644 --- a/modules/caravan/api_buyorsell.go +++ b/modules/caravan/api_buyorsell.go @@ -2,6 +2,7 @@ package caravan import ( "go_dreamfactory/comm" + "go_dreamfactory/lego/sys/log" "go_dreamfactory/pb" cfg "go_dreamfactory/sys/configure/structs" ) @@ -50,6 +51,8 @@ func (this *apiComp) BuyOrSell(session comm.IUserSession, req *pb.CaravanBuyOrSe // special 城市卖给玩家的商品 // exspecial 城市想要玩家卖给他的商品库 if !req.IsBuy { // 卖给npc + + var cb int32 // 成本价 for k, v := range req.Items { // 校验背包数据够不够 caravan.Items[k].Count -= v @@ -62,6 +65,7 @@ func (this *apiComp) BuyOrSell(session comm.IUserSession, req *pb.CaravanBuyOrSe } items := caravan.Items[k] var price int32 + cb = items.Price // 获取成本价 price = items.Price bFound := false for _, v := range cityInfo.Special { @@ -83,7 +87,25 @@ func (this *apiComp) BuyOrSell(session comm.IUserSession, req *pb.CaravanBuyOrSe if !bFound { price = cityInfo.ExspecialPCT * price / 1000 } - addScore += price * v // 卖出收益 + if price > cb { // 赚了 + addScore = (price - cb) * v // 卖出收益 + if err := this.module.ModuleUser.AddUserProfit(session.GetUserId(), int64(addScore)); err != nil { + this.module.Error("玩家Profit更新", + log.Field{Key: "uid", Value: session.GetUserId()}, + log.Field{Key: "update", Value: update}, + ) + return + } + } + + if errdata = this.module.DispenseRes(session, []*cfg.Gameatn{{ + A: "attr", + T: "merchantmoney", + N: price * v, + }}, true); errdata != nil { + this.module.Errorf("获得虚拟币失败:%v", errdata) + } + //addScore += price * v // 卖出收益 } this.module.ArrayBag(caravan) // 统计 收益 @@ -112,7 +134,7 @@ func (this *apiComp) BuyOrSell(session comm.IUserSession, req *pb.CaravanBuyOrSe this.module.Errorf("update caravanlv error: %v", err) } } - if len(lvReward) > 0 { + if len(lvReward) > 0 { // 商队等级奖励 if reward := this.module.DispenseRes(session, lvReward, true); reward != nil { this.module.Errorf("lv reward dispenseRes err:%v", lvReward) errdata = &pb.ErrorData{ @@ -123,6 +145,32 @@ func (this *apiComp) BuyOrSell(session comm.IUserSession, req *pb.CaravanBuyOrSe return } } + + // 商队盈利收益奖励 + var old int64 // 计算之前的结果 + if u := this.module.ModuleUser.GetUser(session.GetUserId()); u != nil { + old = u.Profit + } + reward := this.configure.GetCaravanReward() + for index, v := range reward { + if v.Key == 0 || v.Key <= int32(old) { + + continue + } + if len(reward) > index+1 && reward[index+1].Key > int32(old)+addScore { + var ( + res []*pb.UserAssets + ) + for _, v := range reward[index+1].Reward { + res = append(res, &pb.UserAssets{ + A: v.A, + T: v.T, + N: v.N, + }) + } + this.module.ModuleMail.SendMailByCid(session, "CaravanProfitRewards", res) + } + } } else { // 买入 for k, v := range req.Items { if _, ok := caravan.Items[k]; !ok { @@ -182,14 +230,19 @@ func (this *apiComp) BuyOrSell(session comm.IUserSession, req *pb.CaravanBuyOrSe } return } + + // 减少虚拟币 + // caravan.Merchantmoney -= addScore + // update["merchantmoney"] = caravan.Merchantmoney + if errdata = this.module.DispenseRes(session, []*cfg.Gameatn{{ + A: "attr", + T: "merchantmoney", + N: addScore, + }}, true); errdata != nil { + this.module.Errorf("获得虚拟币失败:%v", errdata) + } } - if errdata = this.module.DispenseRes(session, []*cfg.Gameatn{{ - A: "attr", - T: "merchantmoney", - N: addScore, - }}, true); errdata != nil { - this.module.Errorf("获得虚拟币失败:%v", errdata) - } + update["items"] = caravan.Items update["baglimit"] = caravan.Baglimit this.module.modelCaravan.modifyCaravanDataByObjId(session.GetUserId(), update) diff --git a/modules/caravan/api_getlist.go b/modules/caravan/api_getlist.go index a4fb77b8d..2e90bbec9 100644 --- a/modules/caravan/api_getlist.go +++ b/modules/caravan/api_getlist.go @@ -36,13 +36,13 @@ func (this *apiComp) GetList(session comm.IUserSession, req *pb.CaravanGetListRe } if conf, _ := this.module.configure.GetCaravanLv(list.Lv); conf != nil { - if errdata = this.module.InitCaravanTicket(session, conf.Tickettop); errdata != nil { + if errdata = this.module.InitCaravanTicket(session, conf); errdata != nil { return } - list.Merchantmoney = conf.Moneynumtop.N - update := make(map[string]interface{}) - update["merchantmoney"] = list.Merchantmoney // 更新虚拟币 - this.module.modelCaravan.modifyCaravanDataByObjId(session.GetUserId(), update) + // list.Merchantmoney = conf.Moneynumtop.N + // update := make(map[string]interface{}) + // update["merchantmoney"] = list.Merchantmoney // 更新虚拟币 + // this.module.modelCaravan.modifyCaravanDataByObjId(session.GetUserId(), update) } } // 刷新城市货物信息 diff --git a/modules/caravan/comp_configure.go b/modules/caravan/comp_configure.go index 71a01dc68..fb0b862bb 100644 --- a/modules/caravan/comp_configure.go +++ b/modules/caravan/comp_configure.go @@ -52,6 +52,8 @@ func (this *configureComp) Init(service core.IService, module core.IModule, comp } this.lock.Unlock() }) + + this.FindCaravanReward(4500) return } @@ -208,6 +210,25 @@ func (this *configureComp) GetCaravanReward() (reward []*cfg.GameCaravanRewardDa return } +// 找到指定奖励区间的数据 +func (this *configureComp) FindCaravanReward(score int32) (index int32) { + score = 2500 + if v, err := this.GetConfigure(game_caravan_reward); err == nil { + if configure, ok := v.(*cfg.GameCaravanReward); ok { + reward := configure.GetDataList() + for ipos, v := range reward { + if score >= v.Key && len(reward) > ipos+1 && score <= reward[ipos+1].Key { + index = int32(ipos) + 1 + return + } + } + } + } else { + log.Errorf("get GetCaravanInitCity conf err:%v", err) + } + return +} + func (this *configureComp) GetCaravanMoreReward() (reward []*cfg.Gameatn) { if v, err := this.GetConfigure(game_caravan_reward); err == nil { if configure, ok := v.(*cfg.GameCaravanReward); ok { diff --git a/modules/caravan/module.go b/modules/caravan/module.go index b74ecc891..a64d0be2a 100644 --- a/modules/caravan/module.go +++ b/modules/caravan/module.go @@ -146,11 +146,11 @@ func (this *Caravan) InitCaravanItemData(uid string, data *pb.DBCaravan) { } // 初始化门票和虚拟币 -func (this *Caravan) InitCaravanTicket(session comm.IUserSession, tick *cfg.Gameatn) (errdata *pb.ErrorData) { +func (this *Caravan) InitCaravanTicket(session comm.IUserSession, conf *cfg.GameCaravanLvData) (errdata *pb.ErrorData) { var res []*cfg.Gameatn - res = append(res, tick) - //res = append(res, conf.Moneynumtop) + res = append(res, conf.Tickettop) + res = append(res, conf.Moneynumtop) errdata = this.DispenseRes(session, res, true) // 推送门票和虚拟币资源 return } @@ -496,9 +496,14 @@ func (this *Caravan) Rpc_ModuleCaravanSettlement(ctx context.Context, args *pb.E Query["merchantmoney"] = 0 _, err := this.modelCaravan.DB.UpdateMany(core.SqlTable(comm.TableUser), bson.M{"merchantmoney": bson.M{"$gt": 0}}, bson.M{"$set": Query}, options.MergeUpdateOptions().SetUpsert(true)) //, new(options.UpdateOptions).SetUpsert(true) if err != nil { - this.Errorf("UpdateMany error: %v", err) + this.Errorf("Update Merchantmoney Many error: %v", err) + } + Query = bson.M{} + Query["profit"] = 0 + _, err = this.modelCaravan.DB.UpdateMany(core.SqlTable(comm.TableUser), bson.M{"profit": bson.M{"$gt": 0}}, bson.M{"$set": Query}, options.MergeUpdateOptions().SetUpsert(true)) //, new(options.UpdateOptions).SetUpsert(true) + if err != nil { + this.Errorf("Update Profit Many error: %v", err) } - this.Debugf("sub time:%d", time.Now().Local().Sub(sTime).Milliseconds()) }() diff --git a/modules/modulebase.go b/modules/modulebase.go index 367023b3b..7d1b67f5a 100644 --- a/modules/modulebase.go +++ b/modules/modulebase.go @@ -42,6 +42,7 @@ type ModuleBase struct { ModuleParkour comm.IParkour //捕羊大赛 ModuleTools comm.ITools //工具类 获取一些通用配置 ModuleBuried comm.IBuried //触发埋点中心 + ModuleMail comm.Imail //邮件 } // 重构模块配置对象 @@ -139,6 +140,11 @@ func (this *ModuleBase) Start() (err error) { return } this.ModuleBuried = module.(comm.IBuried) + + if module, err = this.service.GetModule(comm.ModuleMail); err != nil { + return + } + this.ModuleMail = module.(comm.Imail) return } diff --git a/modules/user/model_user.go b/modules/user/model_user.go index a176795ac..b82d3226a 100644 --- a/modules/user/model_user.go +++ b/modules/user/model_user.go @@ -11,6 +11,7 @@ import ( "go_dreamfactory/pb" "go_dreamfactory/sys/configure" cfg "go_dreamfactory/sys/configure/structs" + "go_dreamfactory/sys/db" "go_dreamfactory/utils" "time" @@ -376,6 +377,39 @@ func (this *ModelUser) ChangeLevel(event interface{}, next func(event interface{ } +func (this *ModelUser) AddUserProfit(uid string, score int64) (err error) { + var ( + model *db.DBModel + value map[string]interface{} + ) + if score < 0 { + return + } + user := &pb.DBUser{} + value["profit"] = score + if db.IsCross() { + if model, err = this.module.GetDBModelByUid(uid, this.TableName); err == nil { + if err := this.Get(uid, user); err != nil { + this.module.Errorf("err:%v", err) + } + value["profit"] = user.Profit + score + return model.Change(uid, value) + } else { + this.module.Errorln(err) + return err + } + } else { + + if err := this.Get(uid, user); err != nil { + this.module.Errorf("err:%v", err) + } + value["profit"] = user.Profit + score + } + + return this.Change(uid, value) + +} + // 玩家信息监听 type UserListen struct { event_v2.Event diff --git a/modules/user/module.go b/modules/user/module.go index 160aa80cb..a73feac06 100644 --- a/modules/user/module.go +++ b/modules/user/module.go @@ -1164,3 +1164,6 @@ func (this *User) RemainingPS(uid string) (ps int32) { } return ggd.PsUl - user.Ps } +func (this *User) AddUserProfit(uid string, score int64) error { + return this.modelUser.AddUserProfit(uid, score) +} diff --git a/pb/caravan_db.pb.go b/pb/caravan_db.pb.go index e8ec32486..24c24f052 100644 --- a/pb/caravan_db.pb.go +++ b/pb/caravan_db.pb.go @@ -233,22 +233,21 @@ type DBCaravan 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" bson:"uid"` //用户ID //int32 useCount = 3; //@go_tags(`bson:"useCount"`) 当前背包使用的数量 - Items map[string]*BagInfo `protobuf:"bytes,4,rep,name=items,proto3" json:"items" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` // 背包数据 - Goods map[string]*Goods `protobuf:"bytes,5,rep,name=goods,proto3" json:"goods" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` // key 货物ID - City map[int32]*CityInfo `protobuf:"bytes,6,rep,name=city,proto3" json:"city" protobuf_key:"varint,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` // 城市信息 - Lv int32 `protobuf:"varint,7,opt,name=lv,proto3" json:"lv"` // 商队等级 - Profit int64 `protobuf:"varint,8,opt,name=profit,proto3" json:"profit"` // 虚拟货利润 - Resettime int64 `protobuf:"varint,9,opt,name=resettime,proto3" json:"resettime"` // 赛季结算时间 - Curcity int32 `protobuf:"varint,10,opt,name=curcity,proto3" json:"curcity"` // 当前城市 - Taskid int32 `protobuf:"varint,11,opt,name=taskid,proto3" json:"taskid"` // 对应对应世界任务组 worldtask - Eventid int32 `protobuf:"varint,12,opt,name=eventid,proto3" json:"eventid"` // 特殊事件ID(事件配置唯一id) - Tasktime int64 `protobuf:"varint,13,opt,name=tasktime,proto3" json:"tasktime"` // 任务触发时间 - Baglimit int32 `protobuf:"varint,14,opt,name=baglimit,proto3" json:"baglimit"` // 背包上限 - Citystime int64 `protobuf:"varint,15,opt,name=citystime,proto3" json:"citystime"` // 城市刷新时间 玩家身上的货物同时刷新 - Oldprice map[string]int32 `protobuf:"bytes,16,rep,name=oldprice,proto3" json:"oldprice" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"varint,2,opt,name=value,proto3"` // 上一次价格 key 货物ID - Rtime int64 `protobuf:"varint,17,opt,name=rtime,proto3" json:"rtime"` // 客户端不用这个时间 - Group map[int32]bool `protobuf:"bytes,18,rep,name=group,proto3" json:"group" protobuf_key:"varint,1,opt,name=key,proto3" protobuf_val:"varint,2,opt,name=value,proto3"` //服务器用 - Merchantmoney int32 `protobuf:"varint,19,opt,name=merchantmoney,proto3" json:"merchantmoney"` // 虚拟币(商队) + Items map[string]*BagInfo `protobuf:"bytes,4,rep,name=items,proto3" json:"items" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` // 背包数据 + Goods map[string]*Goods `protobuf:"bytes,5,rep,name=goods,proto3" json:"goods" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` // key 货物ID + City map[int32]*CityInfo `protobuf:"bytes,6,rep,name=city,proto3" json:"city" protobuf_key:"varint,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` // 城市信息 + Lv int32 `protobuf:"varint,7,opt,name=lv,proto3" json:"lv"` // 商队等级 + Profit int64 `protobuf:"varint,8,opt,name=profit,proto3" json:"profit"` // 虚拟货利润 + Resettime int64 `protobuf:"varint,9,opt,name=resettime,proto3" json:"resettime"` // 赛季结算时间 + Curcity int32 `protobuf:"varint,10,opt,name=curcity,proto3" json:"curcity"` // 当前城市 + Taskid int32 `protobuf:"varint,11,opt,name=taskid,proto3" json:"taskid"` // 对应对应世界任务组 worldtask + Eventid int32 `protobuf:"varint,12,opt,name=eventid,proto3" json:"eventid"` // 特殊事件ID(事件配置唯一id) + Tasktime int64 `protobuf:"varint,13,opt,name=tasktime,proto3" json:"tasktime"` // 任务触发时间 + Baglimit int32 `protobuf:"varint,14,opt,name=baglimit,proto3" json:"baglimit"` // 背包上限 + Citystime int64 `protobuf:"varint,15,opt,name=citystime,proto3" json:"citystime"` // 城市刷新时间 玩家身上的货物同时刷新 + Oldprice map[string]int32 `protobuf:"bytes,16,rep,name=oldprice,proto3" json:"oldprice" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"varint,2,opt,name=value,proto3"` // 上一次价格 key 货物ID + Rtime int64 `protobuf:"varint,17,opt,name=rtime,proto3" json:"rtime"` // 客户端不用这个时间 + Group map[int32]bool `protobuf:"bytes,18,rep,name=group,proto3" json:"group" protobuf_key:"varint,1,opt,name=key,proto3" protobuf_val:"varint,2,opt,name=value,proto3"` //服务器用 } func (x *DBCaravan) Reset() { @@ -402,13 +401,6 @@ func (x *DBCaravan) GetGroup() map[int32]bool { return nil } -func (x *DBCaravan) GetMerchantmoney() int32 { - if x != nil { - return x.Merchantmoney - } - return 0 -} - type CaravanRankInfo struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -535,7 +527,7 @@ var file_caravan_caravan_db_proto_rawDesc = []byte{ 0x22, 0x35, 0x0a, 0x07, 0x42, 0x61, 0x67, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x14, 0x0a, 0x05, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x70, 0x72, 0x69, 0x63, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, - 0x52, 0x05, 0x70, 0x72, 0x69, 0x63, 0x65, 0x22, 0xf9, 0x06, 0x0a, 0x09, 0x44, 0x42, 0x43, 0x61, + 0x52, 0x05, 0x70, 0x72, 0x69, 0x63, 0x65, 0x22, 0xd3, 0x06, 0x0a, 0x09, 0x44, 0x42, 0x43, 0x61, 0x72, 0x61, 0x76, 0x61, 0x6e, 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, 0x2b, 0x0a, 0x05, 0x69, 0x74, 0x65, 0x6d, 0x73, @@ -568,43 +560,40 @@ var file_caravan_caravan_db_proto_rawDesc = []byte{ 0x6d, 0x65, 0x18, 0x11, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x72, 0x74, 0x69, 0x6d, 0x65, 0x12, 0x2b, 0x0a, 0x05, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x18, 0x12, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x15, 0x2e, 0x44, 0x42, 0x43, 0x61, 0x72, 0x61, 0x76, 0x61, 0x6e, 0x2e, 0x47, 0x72, 0x6f, 0x75, 0x70, - 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x05, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x12, 0x24, 0x0a, 0x0d, - 0x6d, 0x65, 0x72, 0x63, 0x68, 0x61, 0x6e, 0x74, 0x6d, 0x6f, 0x6e, 0x65, 0x79, 0x18, 0x13, 0x20, - 0x01, 0x28, 0x05, 0x52, 0x0d, 0x6d, 0x65, 0x72, 0x63, 0x68, 0x61, 0x6e, 0x74, 0x6d, 0x6f, 0x6e, - 0x65, 0x79, 0x1a, 0x42, 0x0a, 0x0a, 0x49, 0x74, 0x65, 0x6d, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, - 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, - 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, - 0x0b, 0x32, 0x08, 0x2e, 0x42, 0x61, 0x67, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x05, 0x76, 0x61, 0x6c, - 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x1a, 0x40, 0x0a, 0x0a, 0x47, 0x6f, 0x6f, 0x64, 0x73, 0x45, - 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x1c, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, - 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x06, 0x2e, 0x47, 0x6f, 0x6f, 0x64, 0x73, 0x52, 0x05, 0x76, - 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x1a, 0x42, 0x0a, 0x09, 0x43, 0x69, 0x74, 0x79, - 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, - 0x28, 0x05, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x1f, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, - 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x09, 0x2e, 0x43, 0x69, 0x74, 0x79, 0x49, 0x6e, 0x66, - 0x6f, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x1a, 0x3b, 0x0a, 0x0d, - 0x4f, 0x6c, 0x64, 0x70, 0x72, 0x69, 0x63, 0x65, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, - 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 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, 0x1a, 0x38, 0x0a, 0x0a, 0x47, 0x72, 0x6f, - 0x75, 0x70, 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, 0x08, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, - 0x02, 0x38, 0x01, 0x22, 0xbf, 0x01, 0x0a, 0x0f, 0x43, 0x61, 0x72, 0x61, 0x76, 0x61, 0x6e, 0x52, - 0x61, 0x6e, 0x6b, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x10, 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18, 0x01, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x75, 0x69, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, - 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x16, 0x0a, - 0x06, 0x75, 0x73, 0x65, 0x72, 0x6c, 0x76, 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06, 0x75, - 0x73, 0x65, 0x72, 0x6c, 0x76, 0x12, 0x16, 0x0a, 0x06, 0x61, 0x76, 0x61, 0x74, 0x61, 0x72, 0x18, - 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x61, 0x76, 0x61, 0x74, 0x61, 0x72, 0x12, 0x12, 0x0a, - 0x04, 0x72, 0x61, 0x6e, 0x6b, 0x18, 0x05, 0x20, 0x01, 0x28, 0x05, 0x52, 0x04, 0x72, 0x61, 0x6e, - 0x6b, 0x12, 0x24, 0x0a, 0x0d, 0x6d, 0x65, 0x72, 0x63, 0x68, 0x61, 0x6e, 0x74, 0x6d, 0x6f, 0x6e, - 0x65, 0x79, 0x18, 0x06, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0d, 0x6d, 0x65, 0x72, 0x63, 0x68, 0x61, - 0x6e, 0x74, 0x6d, 0x6f, 0x6e, 0x65, 0x79, 0x12, 0x1c, 0x0a, 0x09, 0x63, 0x61, 0x72, 0x61, 0x76, - 0x61, 0x6e, 0x4c, 0x76, 0x18, 0x07, 0x20, 0x01, 0x28, 0x05, 0x52, 0x09, 0x63, 0x61, 0x72, 0x61, - 0x76, 0x61, 0x6e, 0x4c, 0x76, 0x42, 0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70, 0x62, 0x62, 0x06, 0x70, - 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x05, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x1a, 0x42, 0x0a, 0x0a, + 0x49, 0x74, 0x65, 0x6d, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, + 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x05, + 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x08, 0x2e, 0x42, 0x61, + 0x67, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, + 0x1a, 0x40, 0x0a, 0x0a, 0x47, 0x6f, 0x6f, 0x64, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, + 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, + 0x12, 0x1c, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, + 0x06, 0x2e, 0x47, 0x6f, 0x6f, 0x64, 0x73, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, + 0x38, 0x01, 0x1a, 0x42, 0x0a, 0x09, 0x43, 0x69, 0x74, 0x79, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, + 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x03, 0x6b, 0x65, + 0x79, 0x12, 0x1f, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, + 0x32, 0x09, 0x2e, 0x43, 0x69, 0x74, 0x79, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x05, 0x76, 0x61, 0x6c, + 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x1a, 0x3b, 0x0a, 0x0d, 0x4f, 0x6c, 0x64, 0x70, 0x72, 0x69, + 0x63, 0x65, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x09, 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, 0x1a, 0x38, 0x0a, 0x0a, 0x47, 0x72, 0x6f, 0x75, 0x70, 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, 0x08, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x22, 0xbf, 0x01, + 0x0a, 0x0f, 0x43, 0x61, 0x72, 0x61, 0x76, 0x61, 0x6e, 0x52, 0x61, 0x6e, 0x6b, 0x49, 0x6e, 0x66, + 0x6f, 0x12, 0x10, 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, + 0x75, 0x69, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x75, 0x73, 0x65, 0x72, 0x6c, + 0x76, 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06, 0x75, 0x73, 0x65, 0x72, 0x6c, 0x76, 0x12, + 0x16, 0x0a, 0x06, 0x61, 0x76, 0x61, 0x74, 0x61, 0x72, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x06, 0x61, 0x76, 0x61, 0x74, 0x61, 0x72, 0x12, 0x12, 0x0a, 0x04, 0x72, 0x61, 0x6e, 0x6b, 0x18, + 0x05, 0x20, 0x01, 0x28, 0x05, 0x52, 0x04, 0x72, 0x61, 0x6e, 0x6b, 0x12, 0x24, 0x0a, 0x0d, 0x6d, + 0x65, 0x72, 0x63, 0x68, 0x61, 0x6e, 0x74, 0x6d, 0x6f, 0x6e, 0x65, 0x79, 0x18, 0x06, 0x20, 0x01, + 0x28, 0x05, 0x52, 0x0d, 0x6d, 0x65, 0x72, 0x63, 0x68, 0x61, 0x6e, 0x74, 0x6d, 0x6f, 0x6e, 0x65, + 0x79, 0x12, 0x1c, 0x0a, 0x09, 0x63, 0x61, 0x72, 0x61, 0x76, 0x61, 0x6e, 0x4c, 0x76, 0x18, 0x07, + 0x20, 0x01, 0x28, 0x05, 0x52, 0x09, 0x63, 0x61, 0x72, 0x61, 0x76, 0x61, 0x6e, 0x4c, 0x76, 0x42, + 0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( diff --git a/pb/user_db.pb.go b/pb/user_db.pb.go index a48d20459..000e738bf 100644 --- a/pb/user_db.pb.go +++ b/pb/user_db.pb.go @@ -154,6 +154,7 @@ type DBUser struct { Vname string `protobuf:"bytes,40,opt,name=vname,proto3" json:"vname"` //@go_tags(`bson:"vname"`)版本名 CaravanLv int32 `protobuf:"varint,41,opt,name=caravanLv,proto3" json:"caravanLv"` //@go_tags(`bson:"caravanlv"`)商队等级 Deposit int64 `protobuf:"varint,42,opt,name=deposit,proto3" json:"deposit" bson:"deposit"` //储蓄 + Profit int64 `protobuf:"varint,43,opt,name=profit,proto3" json:"profit" bson:"profit"` //商队盈利 } func (x *DBUser) Reset() { @@ -482,6 +483,13 @@ func (x *DBUser) GetDeposit() int64 { return 0 } +func (x *DBUser) GetProfit() int64 { + if x != nil { + return x.Profit + } + return 0 +} + type DBUserSetting struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -807,7 +815,7 @@ var file_user_user_db_proto_rawDesc = []byte{ 0x74, 0x65, 0x77, 0x61, 0x79, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x49, 0x64, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x70, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x70, 0x12, 0x1c, 0x0a, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x18, 0x06, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x22, 0x8e, 0x08, 0x0a, + 0x03, 0x52, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x22, 0xa6, 0x08, 0x0a, 0x06, 0x44, 0x42, 0x55, 0x73, 0x65, 0x72, 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, 0x12, 0x0a, 0x04, 0x75, 0x75, 0x69, @@ -872,46 +880,48 @@ var file_user_user_db_proto_rawDesc = []byte{ 0x76, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x63, 0x61, 0x72, 0x61, 0x76, 0x61, 0x6e, 0x4c, 0x76, 0x18, 0x29, 0x20, 0x01, 0x28, 0x05, 0x52, 0x09, 0x63, 0x61, 0x72, 0x61, 0x76, 0x61, 0x6e, 0x4c, 0x76, 0x12, 0x18, 0x0a, 0x07, 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x18, 0x2a, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x07, 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x22, 0xc7, 0x02, - 0x0a, 0x0d, 0x44, 0x42, 0x55, 0x73, 0x65, 0x72, 0x53, 0x65, 0x74, 0x74, 0x69, 0x6e, 0x67, 0x12, - 0x10, 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x75, 0x69, - 0x64, 0x12, 0x16, 0x0a, 0x06, 0x68, 0x75, 0x61, 0x7a, 0x68, 0x69, 0x18, 0x03, 0x20, 0x01, 0x28, - 0x0d, 0x52, 0x06, 0x68, 0x75, 0x61, 0x7a, 0x68, 0x69, 0x12, 0x1c, 0x0a, 0x09, 0x6b, 0x61, 0x6e, - 0x67, 0x6a, 0x75, 0x63, 0x68, 0x69, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x09, 0x6b, 0x61, - 0x6e, 0x67, 0x6a, 0x75, 0x63, 0x68, 0x69, 0x12, 0x1a, 0x0a, 0x08, 0x67, 0x61, 0x6f, 0x67, 0x75, - 0x61, 0x6e, 0x67, 0x18, 0x05, 0x20, 0x01, 0x28, 0x08, 0x52, 0x08, 0x67, 0x61, 0x6f, 0x67, 0x75, - 0x61, 0x6e, 0x67, 0x12, 0x12, 0x0a, 0x04, 0x77, 0x75, 0x6c, 0x69, 0x18, 0x06, 0x20, 0x01, 0x28, - 0x08, 0x52, 0x04, 0x77, 0x75, 0x6c, 0x69, 0x12, 0x14, 0x0a, 0x05, 0x6d, 0x75, 0x73, 0x69, 0x63, - 0x18, 0x07, 0x20, 0x01, 0x28, 0x08, 0x52, 0x05, 0x6d, 0x75, 0x73, 0x69, 0x63, 0x12, 0x16, 0x0a, - 0x06, 0x65, 0x66, 0x66, 0x65, 0x63, 0x74, 0x18, 0x08, 0x20, 0x01, 0x28, 0x08, 0x52, 0x06, 0x65, - 0x66, 0x66, 0x65, 0x63, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x67, 0x75, 0x61, 0x6a, 0x69, 0x18, 0x09, - 0x20, 0x01, 0x28, 0x08, 0x52, 0x05, 0x67, 0x75, 0x61, 0x6a, 0x69, 0x12, 0x14, 0x0a, 0x05, 0x66, - 0x75, 0x62, 0x65, 0x6e, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x08, 0x52, 0x05, 0x66, 0x75, 0x62, 0x65, - 0x6e, 0x12, 0x16, 0x0a, 0x06, 0x74, 0x61, 0x6e, 0x73, 0x75, 0x6f, 0x18, 0x0b, 0x20, 0x01, 0x28, - 0x08, 0x52, 0x06, 0x74, 0x61, 0x6e, 0x73, 0x75, 0x6f, 0x12, 0x18, 0x0a, 0x07, 0x68, 0x75, 0x6f, - 0x64, 0x6f, 0x6e, 0x67, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x68, 0x75, 0x6f, 0x64, - 0x6f, 0x6e, 0x67, 0x12, 0x1c, 0x0a, 0x09, 0x78, 0x75, 0x61, 0x6e, 0x73, 0x68, 0x61, 0x6e, 0x67, - 0x18, 0x0d, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x78, 0x75, 0x61, 0x6e, 0x73, 0x68, 0x61, 0x6e, - 0x67, 0x12, 0x14, 0x0a, 0x05, 0x73, 0x61, 0x69, 0x6a, 0x69, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x08, - 0x52, 0x05, 0x73, 0x61, 0x69, 0x6a, 0x69, 0x22, 0xb8, 0x01, 0x0a, 0x06, 0x44, 0x42, 0x53, 0x69, - 0x67, 0x6e, 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, 0x1a, 0x0a, 0x08, 0x73, 0x69, 0x67, 0x6e, 0x54, 0x69, 0x6d, 0x65, - 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x73, 0x69, 0x67, 0x6e, 0x54, 0x69, 0x6d, 0x65, - 0x12, 0x1c, 0x0a, 0x09, 0x73, 0x69, 0x67, 0x6e, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x04, 0x20, - 0x01, 0x28, 0x05, 0x52, 0x09, 0x73, 0x69, 0x67, 0x6e, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x14, - 0x0a, 0x05, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x18, 0x05, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x67, - 0x72, 0x6f, 0x75, 0x70, 0x12, 0x10, 0x0a, 0x03, 0x64, 0x61, 0x79, 0x18, 0x06, 0x20, 0x01, 0x28, - 0x05, 0x52, 0x03, 0x64, 0x61, 0x79, 0x12, 0x16, 0x0a, 0x06, 0x70, 0x75, 0x7a, 0x7a, 0x6c, 0x65, - 0x18, 0x07, 0x20, 0x03, 0x28, 0x05, 0x52, 0x06, 0x70, 0x75, 0x7a, 0x7a, 0x6c, 0x65, 0x12, 0x12, - 0x0a, 0x04, 0x74, 0x69, 0x70, 0x73, 0x18, 0x08, 0x20, 0x01, 0x28, 0x05, 0x52, 0x04, 0x74, 0x69, - 0x70, 0x73, 0x22, 0x57, 0x0a, 0x0c, 0x44, 0x42, 0x52, 0x61, 0x6e, 0x64, 0x6f, 0x6d, 0x4e, 0x61, - 0x6d, 0x65, 0x12, 0x17, 0x0a, 0x07, 0x6e, 0x61, 0x6d, 0x65, 0x5f, 0x63, 0x6e, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x06, 0x6e, 0x61, 0x6d, 0x65, 0x43, 0x6e, 0x12, 0x16, 0x0a, 0x06, 0x67, - 0x65, 0x6e, 0x64, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06, 0x67, 0x65, 0x6e, - 0x64, 0x65, 0x72, 0x12, 0x16, 0x0a, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x18, 0x03, 0x20, - 0x01, 0x28, 0x05, 0x52, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x42, 0x06, 0x5a, 0x04, 0x2e, - 0x3b, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x20, 0x01, 0x28, 0x03, 0x52, 0x07, 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x12, 0x16, 0x0a, + 0x06, 0x70, 0x72, 0x6f, 0x66, 0x69, 0x74, 0x18, 0x2b, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x70, + 0x72, 0x6f, 0x66, 0x69, 0x74, 0x22, 0xc7, 0x02, 0x0a, 0x0d, 0x44, 0x42, 0x55, 0x73, 0x65, 0x72, + 0x53, 0x65, 0x74, 0x74, 0x69, 0x6e, 0x67, 0x12, 0x10, 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18, 0x02, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x75, 0x69, 0x64, 0x12, 0x16, 0x0a, 0x06, 0x68, 0x75, 0x61, + 0x7a, 0x68, 0x69, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x06, 0x68, 0x75, 0x61, 0x7a, 0x68, + 0x69, 0x12, 0x1c, 0x0a, 0x09, 0x6b, 0x61, 0x6e, 0x67, 0x6a, 0x75, 0x63, 0x68, 0x69, 0x18, 0x04, + 0x20, 0x01, 0x28, 0x0d, 0x52, 0x09, 0x6b, 0x61, 0x6e, 0x67, 0x6a, 0x75, 0x63, 0x68, 0x69, 0x12, + 0x1a, 0x0a, 0x08, 0x67, 0x61, 0x6f, 0x67, 0x75, 0x61, 0x6e, 0x67, 0x18, 0x05, 0x20, 0x01, 0x28, + 0x08, 0x52, 0x08, 0x67, 0x61, 0x6f, 0x67, 0x75, 0x61, 0x6e, 0x67, 0x12, 0x12, 0x0a, 0x04, 0x77, + 0x75, 0x6c, 0x69, 0x18, 0x06, 0x20, 0x01, 0x28, 0x08, 0x52, 0x04, 0x77, 0x75, 0x6c, 0x69, 0x12, + 0x14, 0x0a, 0x05, 0x6d, 0x75, 0x73, 0x69, 0x63, 0x18, 0x07, 0x20, 0x01, 0x28, 0x08, 0x52, 0x05, + 0x6d, 0x75, 0x73, 0x69, 0x63, 0x12, 0x16, 0x0a, 0x06, 0x65, 0x66, 0x66, 0x65, 0x63, 0x74, 0x18, + 0x08, 0x20, 0x01, 0x28, 0x08, 0x52, 0x06, 0x65, 0x66, 0x66, 0x65, 0x63, 0x74, 0x12, 0x14, 0x0a, + 0x05, 0x67, 0x75, 0x61, 0x6a, 0x69, 0x18, 0x09, 0x20, 0x01, 0x28, 0x08, 0x52, 0x05, 0x67, 0x75, + 0x61, 0x6a, 0x69, 0x12, 0x14, 0x0a, 0x05, 0x66, 0x75, 0x62, 0x65, 0x6e, 0x18, 0x0a, 0x20, 0x01, + 0x28, 0x08, 0x52, 0x05, 0x66, 0x75, 0x62, 0x65, 0x6e, 0x12, 0x16, 0x0a, 0x06, 0x74, 0x61, 0x6e, + 0x73, 0x75, 0x6f, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x08, 0x52, 0x06, 0x74, 0x61, 0x6e, 0x73, 0x75, + 0x6f, 0x12, 0x18, 0x0a, 0x07, 0x68, 0x75, 0x6f, 0x64, 0x6f, 0x6e, 0x67, 0x18, 0x0c, 0x20, 0x01, + 0x28, 0x08, 0x52, 0x07, 0x68, 0x75, 0x6f, 0x64, 0x6f, 0x6e, 0x67, 0x12, 0x1c, 0x0a, 0x09, 0x78, + 0x75, 0x61, 0x6e, 0x73, 0x68, 0x61, 0x6e, 0x67, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, + 0x78, 0x75, 0x61, 0x6e, 0x73, 0x68, 0x61, 0x6e, 0x67, 0x12, 0x14, 0x0a, 0x05, 0x73, 0x61, 0x69, + 0x6a, 0x69, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x08, 0x52, 0x05, 0x73, 0x61, 0x69, 0x6a, 0x69, 0x22, + 0xb8, 0x01, 0x0a, 0x06, 0x44, 0x42, 0x53, 0x69, 0x67, 0x6e, 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, 0x1a, 0x0a, 0x08, + 0x73, 0x69, 0x67, 0x6e, 0x54, 0x69, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, + 0x73, 0x69, 0x67, 0x6e, 0x54, 0x69, 0x6d, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x73, 0x69, 0x67, 0x6e, + 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x05, 0x52, 0x09, 0x73, 0x69, 0x67, + 0x6e, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x18, + 0x05, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x12, 0x10, 0x0a, 0x03, + 0x64, 0x61, 0x79, 0x18, 0x06, 0x20, 0x01, 0x28, 0x05, 0x52, 0x03, 0x64, 0x61, 0x79, 0x12, 0x16, + 0x0a, 0x06, 0x70, 0x75, 0x7a, 0x7a, 0x6c, 0x65, 0x18, 0x07, 0x20, 0x03, 0x28, 0x05, 0x52, 0x06, + 0x70, 0x75, 0x7a, 0x7a, 0x6c, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x74, 0x69, 0x70, 0x73, 0x18, 0x08, + 0x20, 0x01, 0x28, 0x05, 0x52, 0x04, 0x74, 0x69, 0x70, 0x73, 0x22, 0x57, 0x0a, 0x0c, 0x44, 0x42, + 0x52, 0x61, 0x6e, 0x64, 0x6f, 0x6d, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x17, 0x0a, 0x07, 0x6e, 0x61, + 0x6d, 0x65, 0x5f, 0x63, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x6e, 0x61, 0x6d, + 0x65, 0x43, 0x6e, 0x12, 0x16, 0x0a, 0x06, 0x67, 0x65, 0x6e, 0x64, 0x65, 0x72, 0x18, 0x02, 0x20, + 0x01, 0x28, 0x05, 0x52, 0x06, 0x67, 0x65, 0x6e, 0x64, 0x65, 0x72, 0x12, 0x16, 0x0a, 0x06, 0x73, + 0x74, 0x61, 0x74, 0x75, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06, 0x73, 0x74, 0x61, + 0x74, 0x75, 0x73, 0x42, 0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, + 0x74, 0x6f, 0x33, } var (