From 489ab8e5d1eb11f85e676658242fcc2fa1e6f960 Mon Sep 17 00:00:00 2001 From: liwei1dao Date: Wed, 1 Feb 2023 10:02:34 +0800 Subject: [PATCH 01/17] =?UTF-8?q?=E4=B8=8A=E4=BC=A0=E6=97=A5=E5=BF=97?= =?UTF-8?q?=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- lego/sys/log/flieout.go | 75 +++++++++++++++++++++++++++-------------- lego/sys/log/logger.go | 1 + lego/sys/log/options.go | 8 +++++ 3 files changed, 58 insertions(+), 26 deletions(-) diff --git a/lego/sys/log/flieout.go b/lego/sys/log/flieout.go index db40c42d9..2b30065bc 100644 --- a/lego/sys/log/flieout.go +++ b/lego/sys/log/flieout.go @@ -35,6 +35,7 @@ type LogFileOut struct { MaxBackups int `json:"maxbackups" yaml:"maxbackups"` //备份日志的最大数量 LocalTime bool `json:"localtime" yaml:"localtime"` //是使用本地时间还是使用世界标准时间 Compress bool `json:"compress" yaml:"compress"` //是否压缩备份日志 + UniqueLog bool `json:"uniquelog" yaml:"uniquelog"` //是否唯一日志文件 size int64 ctime time.Time file *os.File @@ -79,31 +80,42 @@ func (l *LogFileOut) Write(p []byte) (n int, err error) { return n, err } -func (l *LogFileOut) openExistingOrNew(writeLen int) error { - l.mill() +func (this *LogFileOut) openExistingOrNew(writeLen int) error { + this.mill() - filename := l.filename() + filename := this.filename() info, err := osStat(filename) if os.IsNotExist(err) { - return l.openNew() + return this.openNew() } if err != nil { return fmt.Errorf("error getting log file info: %s", err) } //校验是否需要切割日志 - if info.Size()+int64(writeLen) >= l.max() || (!l.ctime.IsZero() && time.Since(l.ctime) > l.CupTime) { - return l.rotate() + if !this.UniqueLog && (info.Size()+int64(writeLen) >= this.max() || (!this.ctime.IsZero() && time.Since(this.ctime) > this.CupTime)) { + return this.rotate() } - - file, err := os.OpenFile(filename, os.O_CREATE|os.O_WRONLY|os.O_TRUNC, 0666) - if err != nil { - // if we fail to open the old log file for some reason, just ignore - // it and open a new log file. - return l.openNew() + mode := os.FileMode(0666) + if !this.UniqueLog { + file, err := os.OpenFile(filename, os.O_CREATE|os.O_WRONLY|os.O_TRUNC, mode) + if err != nil { + // if we fail to open the old log file for some reason, just ignore + // it and open a new log file. + return this.openNew() + } + this.file = file + this.size = info.Size() + } else { + //最佳写入 + f, err := os.OpenFile(filename, os.O_APPEND|os.O_CREATE|os.O_WRONLY, mode) + if err != nil { + return fmt.Errorf("can't open new logfile: %s", err) + } + this.file = f + this.size = 0 + this.ctime = currentTime() } - l.file = file - l.size = info.Size() return nil } @@ -210,21 +222,21 @@ func (l *LogFileOut) mill() { } //备份老的日志文件创建新的日志文件 -func (l *LogFileOut) openNew() error { - err := os.MkdirAll(l.dir(), 0755) +func (this *LogFileOut) openNew() error { + err := os.MkdirAll(this.dir(), 0755) if err != nil { return fmt.Errorf("can't make directories for new logfile: %s", err) } - name := l.filename() + name := this.filename() mode := os.FileMode(0666) info, err := osStat(name) //备份老的日志文件 - if err == nil { + if !this.UniqueLog && err == nil { // Copy the mode off the old logfile. mode = info.Mode() // move the existing file - newname := backupName(name, l.LocalTime) + newname := backupName(name, this.LocalTime) if err := os.Rename(name, newname); err != nil { return fmt.Errorf("can't rename log file: %s", err) } @@ -235,14 +247,25 @@ func (l *LogFileOut) openNew() error { } } - //创建新的日志文件 - f, err := os.OpenFile(name, os.O_CREATE|os.O_WRONLY|os.O_TRUNC, mode) - if err != nil { - return fmt.Errorf("can't open new logfile: %s", err) + if !this.UniqueLog { + //创建新的日志文件 + f, err := os.OpenFile(name, os.O_CREATE|os.O_WRONLY|os.O_TRUNC, mode) + if err != nil { + return fmt.Errorf("can't open new logfile: %s", err) + } + this.file = f + this.size = 0 + this.ctime = currentTime() + } else { + //最佳写入 + f, err := os.OpenFile(name, os.O_APPEND|os.O_CREATE|os.O_WRONLY, mode) + if err != nil { + return fmt.Errorf("can't open new logfile: %s", err) + } + this.file = f + this.size = 0 + this.ctime = currentTime() } - l.file = f - l.size = 0 - l.ctime = currentTime() return nil } diff --git a/lego/sys/log/logger.go b/lego/sys/log/logger.go index f7e5d3da0..453141f28 100644 --- a/lego/sys/log/logger.go +++ b/lego/sys/log/logger.go @@ -17,6 +17,7 @@ func newSys(options *Options) (sys *Logger, err error) { MaxBackups: options.MaxBackups, //最大备份数 MaxSize: options.MaxSize, //最大日志文件大小 LocalTime: true, //使用本地时间 + UniqueLog: options.UniqueLog, //是否唯一文件 } if !options.IsDebug { if err = hook.openNew(); err != nil { diff --git a/lego/sys/log/options.go b/lego/sys/log/options.go index ea07c84ad..2d1296566 100644 --- a/lego/sys/log/options.go +++ b/lego/sys/log/options.go @@ -22,6 +22,7 @@ type Options struct { ReportCaller Loglevel //是否输出堆栈信息 CallerSkip int //堆栈深度 Encoder LogEncoder //日志输出样式 + UniqueLog bool //唯一日志文件(文件不分割 不备份,一直追加日志) CupTimeTime int //日志分割时间 单位 小时 MaxAgeTime int //日志最大保存时间 单位天 MaxBackups int //最大备份日志个数 @@ -75,6 +76,13 @@ func SetEncoder(v LogEncoder) Option { } } +///设置唯一日志 +func SetUniqueLog(v bool) Option { + return func(o *Options) { + o.UniqueLog = v + } +} + ///日志分割时间 单位 小时 func SetRotationTime(v int) Option { return func(o *Options) { From 82c4fc443e5fb8c2bb4cac39a3c5dc102fb1ac3d Mon Sep 17 00:00:00 2001 From: liwei Date: Wed, 1 Feb 2023 10:05:48 +0800 Subject: [PATCH 02/17] =?UTF-8?q?=E4=B8=8A=E4=BC=A0=E9=85=8D=E7=BD=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- bin/json/game_opencond.json | 228 ------------------------------------ 1 file changed, 228 deletions(-) diff --git a/bin/json/game_opencond.json b/bin/json/game_opencond.json index 19d7d8a83..2f31504c2 100644 --- a/bin/json/game_opencond.json +++ b/bin/json/game_opencond.json @@ -9,10 +9,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -35,10 +31,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -61,10 +53,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -87,10 +75,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -113,10 +97,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -139,10 +119,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -165,10 +141,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -191,10 +163,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -217,10 +185,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -243,10 +207,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -269,10 +229,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -295,10 +251,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -321,10 +273,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -347,10 +295,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -373,10 +317,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -399,10 +339,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -425,10 +361,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -451,10 +383,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -477,10 +405,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -503,10 +427,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -529,10 +449,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -555,10 +471,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -581,10 +493,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -607,10 +515,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -633,10 +537,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -659,10 +559,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -685,10 +581,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -711,10 +603,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -759,10 +647,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -785,10 +669,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -811,10 +691,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -837,10 +713,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -863,10 +735,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -889,10 +757,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -915,10 +779,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -941,10 +801,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -967,10 +823,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -993,10 +845,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -1019,10 +867,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -1045,10 +889,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -1071,10 +911,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -1097,10 +933,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -1123,10 +955,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -1149,10 +977,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -1175,10 +999,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -1201,10 +1021,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -1293,10 +1109,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -1319,10 +1131,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -1345,10 +1153,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -1371,10 +1175,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -1397,10 +1197,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -1423,10 +1219,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -1449,10 +1241,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -1475,10 +1263,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -1501,10 +1285,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -1527,10 +1307,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", @@ -1553,10 +1329,6 @@ { "key": 1, "param": 1 - }, - { - "key": 2, - "param": 1 } ], "optional": "", From b948869ebbc4b99e74e4ced11e5b012841b76d7c Mon Sep 17 00:00:00 2001 From: liwei1dao Date: Wed, 1 Feb 2023 10:12:05 +0800 Subject: [PATCH 03/17] =?UTF-8?q?=E4=BC=98=E5=8C=96cmd=20=E6=97=A5?= =?UTF-8?q?=E5=BF=97=E9=85=8D=E7=BD=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- services/cmd/main.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/services/cmd/main.go b/services/cmd/main.go index 5067de701..cc347f900 100644 --- a/services/cmd/main.go +++ b/services/cmd/main.go @@ -88,7 +88,8 @@ func main() { if err := log.OnInit(nil, log.SetFileName("./s.log"), log.SetLoglevel(log.DebugLevel), - log.SetIsDebug(true)); err != nil { + log.SetUniqueLog(true), + log.SetIsDebug(false)); err != nil { panic(fmt.Sprintf("Sys log Init err:%v", err)) } else { log.Infof("Sys log Init success !") @@ -341,6 +342,7 @@ func convertServiceSttings(config *comm.GameConfig, id int, stype string, ip str "IsDebug": false, "Loglevel": log.InfoLevel, "MaxAgeTime": 7, + "UniqueLog": true, } } From 2e73a05c68ecbdfbe74ed285b823d45248c40300 Mon Sep 17 00:00:00 2001 From: meixiongfeng <766881921@qq.com> Date: Wed, 1 Feb 2023 10:30:02 +0800 Subject: [PATCH 04/17] =?UTF-8?q?trace=20=E6=80=A7=E8=83=BD=E5=88=86?= =?UTF-8?q?=E6=9E=90?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- modules/hero/hero_test.go | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/modules/hero/hero_test.go b/modules/hero/hero_test.go index e93dca1ea..d5a4ab5d5 100644 --- a/modules/hero/hero_test.go +++ b/modules/hero/hero_test.go @@ -18,7 +18,9 @@ import ( "go_dreamfactory/sys/configure" "go_dreamfactory/sys/db" "go_dreamfactory/utils" + "os" "reflect" + "runtime/trace" "strings" "testing" "time" @@ -70,6 +72,20 @@ func GetMonthStartEnd() (int64, int64) { return _d1, _d2 } func Test_Main(t *testing.T) { + //创建trace文件 + f, err := os.Create("trace.out") + if err != nil { + panic(err) + } + + defer f.Close() + + //启动trace goroutine + err = trace.Start(f) + if err != nil { + panic(err) + } + defer trace.Stop() var star1, star2, star3 int32 var rst int32 From 922cf78224d918e0877c5bea96cd1379bd67ce55 Mon Sep 17 00:00:00 2001 From: liwei1dao Date: Wed, 1 Feb 2023 10:52:16 +0800 Subject: [PATCH 05/17] =?UTF-8?q?=E4=B8=8A=E4=BC=A0=E4=BB=A3=E7=A0=81?= =?UTF-8?q?=E6=BA=90=E5=A4=B4=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- services/comp_gateroute.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/services/comp_gateroute.go b/services/comp_gateroute.go index 1f87e10f4..63b3d6e10 100644 --- a/services/comp_gateroute.go +++ b/services/comp_gateroute.go @@ -199,7 +199,7 @@ func (this *SCompGateRoute) NoticeUserLogin(ctx context.Context, args *pb.Notice "serviceTag": args.ServiceTag, "gatewayServiceId": args.GatewayServiceId, "ip": args.Ip, - }) + }, db.SetDBMgoLog(false)) return nil } From cb5b4458f72badd98eaa5f9762e719c4a210e830 Mon Sep 17 00:00:00 2001 From: liwei1dao Date: Wed, 1 Feb 2023 15:45:04 +0800 Subject: [PATCH 06/17] =?UTF-8?q?=E4=B8=8A=E4=BC=A0=E5=AE=9E=E6=97=B6pvp?= =?UTF-8?q?=E6=B6=88=E6=81=AF=E5=A4=B4=E6=94=B9=E5=8A=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- comm/const.go | 1 - modules/gateway/agent.go | 3 + modules/rtimepvp/api.go | 29 --- modules/rtimepvp/module.go | 28 --- pb/arena_msg.pb.go | 138 ++++++++++---- pb/comm.pb.go | 362 +++++++++++++++++++------------------ 6 files changed, 295 insertions(+), 266 deletions(-) delete mode 100644 modules/rtimepvp/api.go delete mode 100644 modules/rtimepvp/module.go diff --git a/comm/const.go b/comm/const.go index b1bcbfd38..5ba030703 100644 --- a/comm/const.go +++ b/comm/const.go @@ -78,7 +78,6 @@ const ( ModuleEnchant core.M_Modules = "enchant" //附魔 ModuleAutoBattle core.M_Modules = "autobattle" //自动战斗 ModuleMline core.M_Modules = "mline" //主线模块 - ModuleRTimePVP core.M_Modules = "rtimepvp" //实时pvp ) //数据表名定义处 diff --git a/modules/gateway/agent.go b/modules/gateway/agent.go index b0de4c975..22d6ccbf8 100644 --- a/modules/gateway/agent.go +++ b/modules/gateway/agent.go @@ -313,6 +313,9 @@ func (this *Agent) messageDistribution(msg *pb.UserMessage) (err error) { return } } else { //跨集群调用 + if msg.ServicePath != "" { //客户端是否制定目标服务器 /wroker/woker0 + servicePath = msg.ServicePath + } if err = this.gateway.Service().AcrossClusterRpcCall(context.Background(), serviceTag, servicePath, string(comm.Rpc_GatewayRoute), req, reply); err != nil { this.gateway.Error("[UserResponse]", log.Field{Key: "uid", Value: this.uId}, diff --git a/modules/rtimepvp/api.go b/modules/rtimepvp/api.go deleted file mode 100644 index 2ea30dc96..000000000 --- a/modules/rtimepvp/api.go +++ /dev/null @@ -1,29 +0,0 @@ -package rtimepvp - -import ( - "go_dreamfactory/modules" - - "go_dreamfactory/lego/core" -) - -/* -装备模块 API -*/ -type apiComp struct { - modules.MCompGate - service core.IService - module *RTimePVP -} - -//组件初始化接口 -func (this *apiComp) Init(service core.IService, module core.IModule, comp core.IModuleComp, options core.IModuleOptions) (err error) { - this.MCompGate.Init(service, module, comp, options) - this.module = module.(*RTimePVP) - this.service = service - return -} - -func (this *apiComp) Start() (err error) { - err = this.MCompGate.Start() - return -} diff --git a/modules/rtimepvp/module.go b/modules/rtimepvp/module.go deleted file mode 100644 index d8decae43..000000000 --- a/modules/rtimepvp/module.go +++ /dev/null @@ -1,28 +0,0 @@ -package rtimepvp - -import ( - "go_dreamfactory/comm" - "go_dreamfactory/lego/base" - "go_dreamfactory/lego/core" - "go_dreamfactory/modules" -) - -/* -模块名:实时PVP -描述:同步战斗模块 -开发:李伟 -*/ -func NewModule() core.IModule { - m := new(RTimePVP) - return m -} - -type RTimePVP struct { - modules.ModuleBase - service base.IRPCXService -} - -//模块名 -func (this *RTimePVP) GetType() core.M_Modules { - return comm.ModuleRTimePVP -} diff --git a/pb/arena_msg.pb.go b/pb/arena_msg.pb.go index 1d8ebd269..ca11fbd95 100644 --- a/pb/arena_msg.pb.go +++ b/pb/arena_msg.pb.go @@ -1292,6 +1292,62 @@ func (x *ArenaPlotRewardResp) GetNpc() map[int32]*DBNpc { return nil } +//实时pvp推送 +type ArenaRTimePvpPush struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + RoomId string `protobuf:"bytes,1,opt,name=RoomId,proto3" json:"RoomId"` + Info *BattleInfo `protobuf:"bytes,2,opt,name=info,proto3" json:"info"` +} + +func (x *ArenaRTimePvpPush) Reset() { + *x = ArenaRTimePvpPush{} + if protoimpl.UnsafeEnabled { + mi := &file_arena_arena_msg_proto_msgTypes[24] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *ArenaRTimePvpPush) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*ArenaRTimePvpPush) ProtoMessage() {} + +func (x *ArenaRTimePvpPush) ProtoReflect() protoreflect.Message { + mi := &file_arena_arena_msg_proto_msgTypes[24] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use ArenaRTimePvpPush.ProtoReflect.Descriptor instead. +func (*ArenaRTimePvpPush) Descriptor() ([]byte, []int) { + return file_arena_arena_msg_proto_rawDescGZIP(), []int{24} +} + +func (x *ArenaRTimePvpPush) GetRoomId() string { + if x != nil { + return x.RoomId + } + return "" +} + +func (x *ArenaRTimePvpPush) GetInfo() *BattleInfo { + if x != nil { + return x.Info + } + return nil +} + var File_arena_arena_msg_proto protoreflect.FileDescriptor var file_arena_arena_msg_proto_rawDesc = []byte{ @@ -1406,8 +1462,12 @@ var file_arena_arena_msg_proto_rawDesc = []byte{ 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x1c, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x06, 0x2e, 0x44, 0x42, 0x4e, 0x70, 0x63, 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, + 0x01, 0x22, 0x4c, 0x0a, 0x11, 0x41, 0x72, 0x65, 0x6e, 0x61, 0x52, 0x54, 0x69, 0x6d, 0x65, 0x50, + 0x76, 0x70, 0x50, 0x75, 0x73, 0x68, 0x12, 0x16, 0x0a, 0x06, 0x52, 0x6f, 0x6f, 0x6d, 0x49, 0x64, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x52, 0x6f, 0x6f, 0x6d, 0x49, 0x64, 0x12, 0x1f, + 0x0a, 0x04, 0x69, 0x6e, 0x66, 0x6f, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0b, 0x2e, 0x42, + 0x61, 0x74, 0x74, 0x6c, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x04, 0x69, 0x6e, 0x66, 0x6f, 0x42, + 0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -1422,7 +1482,7 @@ func file_arena_arena_msg_proto_rawDescGZIP() []byte { return file_arena_arena_msg_proto_rawDescData } -var file_arena_arena_msg_proto_msgTypes = make([]protoimpl.MessageInfo, 25) +var file_arena_arena_msg_proto_msgTypes = make([]protoimpl.MessageInfo, 26) var file_arena_arena_msg_proto_goTypes = []interface{}{ (*ArenaInfoReq)(nil), // 0: ArenaInfoReq (*ArenaInfoResp)(nil), // 1: ArenaInfoResp @@ -1448,36 +1508,38 @@ var file_arena_arena_msg_proto_goTypes = []interface{}{ (*ArenaPlotResp)(nil), // 21: ArenaPlotResp (*ArenaPlotRewardReq)(nil), // 22: ArenaPlotRewardReq (*ArenaPlotRewardResp)(nil), // 23: ArenaPlotRewardResp - nil, // 24: ArenaPlotRewardResp.NpcEntry - (*DBArenaUser)(nil), // 25: DBArenaUser - (*ArenaPlayer)(nil), // 26: ArenaPlayer - (*BattleFormation)(nil), // 27: BattleFormation - (ErrorCode)(0), // 28: ErrorCode - (*BattleInfo)(nil), // 29: BattleInfo - (*BattleReport)(nil), // 30: BattleReport - (*DBNpc)(nil), // 31: DBNpc + (*ArenaRTimePvpPush)(nil), // 24: ArenaRTimePvpPush + nil, // 25: ArenaPlotRewardResp.NpcEntry + (*DBArenaUser)(nil), // 26: DBArenaUser + (*ArenaPlayer)(nil), // 27: ArenaPlayer + (*BattleFormation)(nil), // 28: BattleFormation + (ErrorCode)(0), // 29: ErrorCode + (*BattleInfo)(nil), // 30: BattleInfo + (*BattleReport)(nil), // 31: BattleReport + (*DBNpc)(nil), // 32: DBNpc } var file_arena_arena_msg_proto_depIdxs = []int32{ - 25, // 0: ArenaInfoResp.info:type_name -> DBArenaUser - 25, // 1: ArenaOtherInfoResp.info:type_name -> DBArenaUser - 26, // 2: ArenaMatcheResp.players:type_name -> ArenaPlayer - 27, // 3: ArenaChallengeReq.battle:type_name -> BattleFormation - 28, // 4: ArenaChallengeResp.code:type_name -> ErrorCode - 29, // 5: ArenaChallengeResp.info:type_name -> BattleInfo - 30, // 6: ArenaChallengeRewardReq.report:type_name -> BattleReport - 26, // 7: ArenaRankResp.players:type_name -> ArenaPlayer - 25, // 8: ArenaRankResp.info:type_name -> DBArenaUser - 27, // 9: ArenaPlotReq.battle:type_name -> BattleFormation - 28, // 10: ArenaPlotResp.code:type_name -> ErrorCode - 29, // 11: ArenaPlotResp.info:type_name -> BattleInfo - 30, // 12: ArenaPlotRewardReq.report:type_name -> BattleReport - 24, // 13: ArenaPlotRewardResp.npc:type_name -> ArenaPlotRewardResp.NpcEntry - 31, // 14: ArenaPlotRewardResp.NpcEntry.value:type_name -> DBNpc - 15, // [15:15] is the sub-list for method output_type - 15, // [15:15] is the sub-list for method input_type - 15, // [15:15] is the sub-list for extension type_name - 15, // [15:15] is the sub-list for extension extendee - 0, // [0:15] is the sub-list for field type_name + 26, // 0: ArenaInfoResp.info:type_name -> DBArenaUser + 26, // 1: ArenaOtherInfoResp.info:type_name -> DBArenaUser + 27, // 2: ArenaMatcheResp.players:type_name -> ArenaPlayer + 28, // 3: ArenaChallengeReq.battle:type_name -> BattleFormation + 29, // 4: ArenaChallengeResp.code:type_name -> ErrorCode + 30, // 5: ArenaChallengeResp.info:type_name -> BattleInfo + 31, // 6: ArenaChallengeRewardReq.report:type_name -> BattleReport + 27, // 7: ArenaRankResp.players:type_name -> ArenaPlayer + 26, // 8: ArenaRankResp.info:type_name -> DBArenaUser + 28, // 9: ArenaPlotReq.battle:type_name -> BattleFormation + 29, // 10: ArenaPlotResp.code:type_name -> ErrorCode + 30, // 11: ArenaPlotResp.info:type_name -> BattleInfo + 31, // 12: ArenaPlotRewardReq.report:type_name -> BattleReport + 25, // 13: ArenaPlotRewardResp.npc:type_name -> ArenaPlotRewardResp.NpcEntry + 30, // 14: ArenaRTimePvpPush.info:type_name -> BattleInfo + 32, // 15: ArenaPlotRewardResp.NpcEntry.value:type_name -> DBNpc + 16, // [16:16] is the sub-list for method output_type + 16, // [16:16] is the sub-list for method input_type + 16, // [16:16] is the sub-list for extension type_name + 16, // [16:16] is the sub-list for extension extendee + 0, // [0:16] is the sub-list for field type_name } func init() { file_arena_arena_msg_proto_init() } @@ -1777,6 +1839,18 @@ func file_arena_arena_msg_proto_init() { return nil } } + file_arena_arena_msg_proto_msgTypes[24].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*ArenaRTimePvpPush); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } } type x struct{} out := protoimpl.TypeBuilder{ @@ -1784,7 +1858,7 @@ func file_arena_arena_msg_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_arena_arena_msg_proto_rawDesc, NumEnums: 0, - NumMessages: 25, + NumMessages: 26, NumExtensions: 0, NumServices: 0, }, diff --git a/pb/comm.pb.go b/pb/comm.pb.go index 81da18eee..8389c7583 100644 --- a/pb/comm.pb.go +++ b/pb/comm.pb.go @@ -86,8 +86,9 @@ type UserMessage struct { MainType string `protobuf:"bytes,1,opt,name=MainType,proto3" json:"MainType"` //用户消息处理 模块名 例如:user 对应项目中 user的模块 SubType string `protobuf:"bytes,2,opt,name=SubType,proto3" json:"SubType"` //用户消息处理函数名 例如:login 对应项目中 user的模块中 // api_login 的处理函数 - Data *anypb.Any `protobuf:"bytes,3,opt,name=data,proto3" json:"data"` - Sec string `protobuf:"bytes,4,opt,name=sec,proto3" json:"sec"` //密文 + ServicePath string `protobuf:"bytes,3,opt,name=servicePath,proto3" json:"servicePath"` // 消息路由地址 部分消息前端确定转发给谁 + Data *anypb.Any `protobuf:"bytes,4,opt,name=data,proto3" json:"data"` + Sec string `protobuf:"bytes,5,opt,name=sec,proto3" json:"sec"` //密文 } func (x *UserMessage) Reset() { @@ -136,6 +137,13 @@ func (x *UserMessage) GetSubType() string { return "" } +func (x *UserMessage) GetServicePath() string { + if x != nil { + return x.ServicePath + } + return "" +} + func (x *UserMessage) GetData() *anypb.Any { if x != nil { return x.Data @@ -1771,185 +1779,187 @@ var file_comm_proto_rawDesc = []byte{ 0x0a, 0x0a, 0x63, 0x6f, 0x6d, 0x6d, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x0f, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x63, 0x6f, 0x64, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x19, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2f, 0x61, - 0x6e, 0x79, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x7f, 0x0a, 0x0b, 0x55, 0x73, 0x65, 0x72, - 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x4d, 0x61, 0x69, 0x6e, 0x54, - 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x4d, 0x61, 0x69, 0x6e, 0x54, - 0x79, 0x70, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x53, 0x75, 0x62, 0x54, 0x79, 0x70, 0x65, 0x18, 0x02, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x53, 0x75, 0x62, 0x54, 0x79, 0x70, 0x65, 0x12, 0x28, 0x0a, - 0x04, 0x64, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x14, 0x2e, 0x67, 0x6f, - 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x41, 0x6e, - 0x79, 0x52, 0x04, 0x64, 0x61, 0x74, 0x61, 0x12, 0x10, 0x0a, 0x03, 0x73, 0x65, 0x63, 0x18, 0x04, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x73, 0x65, 0x63, 0x22, 0x8e, 0x02, 0x0a, 0x0c, 0x41, 0x67, - 0x65, 0x6e, 0x74, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x70, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x49, 0x70, 0x12, 0x24, 0x0a, 0x0d, 0x55, 0x73, - 0x65, 0x72, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x0d, 0x55, 0x73, 0x65, 0x72, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x49, 0x64, - 0x12, 0x16, 0x0a, 0x06, 0x55, 0x73, 0x65, 0x72, 0x49, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x06, 0x55, 0x73, 0x65, 0x72, 0x49, 0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x53, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x54, 0x61, 0x67, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x53, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x54, 0x61, 0x67, 0x12, 0x2a, 0x0a, 0x10, 0x47, 0x61, 0x74, 0x65, - 0x77, 0x61, 0x79, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x49, 0x64, 0x18, 0x05, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x10, 0x47, 0x61, 0x74, 0x65, 0x77, 0x61, 0x79, 0x53, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x4d, 0x61, 0x69, 0x6e, 0x54, 0x79, 0x70, 0x65, - 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x4d, 0x61, 0x69, 0x6e, 0x54, 0x79, 0x70, 0x65, - 0x12, 0x18, 0x0a, 0x07, 0x53, 0x75, 0x62, 0x54, 0x79, 0x70, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x07, 0x53, 0x75, 0x62, 0x54, 0x79, 0x70, 0x65, 0x12, 0x2e, 0x0a, 0x07, 0x4d, 0x65, - 0x73, 0x73, 0x61, 0x67, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x14, 0x2e, 0x67, 0x6f, - 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x41, 0x6e, - 0x79, 0x52, 0x07, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x22, 0xad, 0x01, 0x0a, 0x0f, 0x52, - 0x50, 0x43, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x12, 0x1e, - 0x0a, 0x04, 0x43, 0x6f, 0x64, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x0a, 0x2e, 0x45, - 0x72, 0x72, 0x6f, 0x72, 0x43, 0x6f, 0x64, 0x65, 0x52, 0x04, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x22, - 0x0a, 0x0c, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x18, 0x02, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x4d, 0x65, 0x73, 0x73, 0x61, - 0x67, 0x65, 0x12, 0x32, 0x0a, 0x09, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x44, 0x61, 0x74, 0x61, 0x18, - 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x14, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, - 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x41, 0x6e, 0x79, 0x52, 0x09, 0x45, 0x72, 0x72, - 0x6f, 0x72, 0x44, 0x61, 0x74, 0x61, 0x12, 0x22, 0x0a, 0x05, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x18, - 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0c, 0x2e, 0x55, 0x73, 0x65, 0x72, 0x4d, 0x65, 0x73, 0x73, - 0x61, 0x67, 0x65, 0x52, 0x05, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x22, 0x69, 0x0a, 0x0d, 0x41, 0x67, - 0x65, 0x6e, 0x74, 0x42, 0x75, 0x69, 0x6c, 0x64, 0x52, 0x65, 0x71, 0x12, 0x24, 0x0a, 0x0d, 0x55, + 0x6e, 0x79, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xa1, 0x01, 0x0a, 0x0b, 0x55, 0x73, 0x65, + 0x72, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x4d, 0x61, 0x69, 0x6e, + 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x4d, 0x61, 0x69, 0x6e, + 0x54, 0x79, 0x70, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x53, 0x75, 0x62, 0x54, 0x79, 0x70, 0x65, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x53, 0x75, 0x62, 0x54, 0x79, 0x70, 0x65, 0x12, 0x20, + 0x0a, 0x0b, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x18, 0x03, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x0b, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, + 0x12, 0x28, 0x0a, 0x04, 0x64, 0x61, 0x74, 0x61, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x14, + 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, + 0x2e, 0x41, 0x6e, 0x79, 0x52, 0x04, 0x64, 0x61, 0x74, 0x61, 0x12, 0x10, 0x0a, 0x03, 0x73, 0x65, + 0x63, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x73, 0x65, 0x63, 0x22, 0x8e, 0x02, 0x0a, + 0x0c, 0x41, 0x67, 0x65, 0x6e, 0x74, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x12, 0x0e, 0x0a, + 0x02, 0x49, 0x70, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x49, 0x70, 0x12, 0x24, 0x0a, + 0x0d, 0x55, 0x73, 0x65, 0x72, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x18, 0x02, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x55, 0x73, 0x65, 0x72, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, + 0x6e, 0x49, 0x64, 0x12, 0x16, 0x0a, 0x06, 0x55, 0x73, 0x65, 0x72, 0x49, 0x64, 0x18, 0x03, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x06, 0x55, 0x73, 0x65, 0x72, 0x49, 0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x53, + 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x54, 0x61, 0x67, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x0a, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x54, 0x61, 0x67, 0x12, 0x2a, 0x0a, 0x10, 0x47, + 0x61, 0x74, 0x65, 0x77, 0x61, 0x79, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x49, 0x64, 0x18, + 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x10, 0x47, 0x61, 0x74, 0x65, 0x77, 0x61, 0x79, 0x53, 0x65, + 0x72, 0x76, 0x69, 0x63, 0x65, 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x4d, 0x61, 0x69, 0x6e, 0x54, + 0x79, 0x70, 0x65, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x4d, 0x61, 0x69, 0x6e, 0x54, + 0x79, 0x70, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x53, 0x75, 0x62, 0x54, 0x79, 0x70, 0x65, 0x18, 0x07, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x53, 0x75, 0x62, 0x54, 0x79, 0x70, 0x65, 0x12, 0x2e, 0x0a, + 0x07, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x14, + 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, + 0x2e, 0x41, 0x6e, 0x79, 0x52, 0x07, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x22, 0xad, 0x01, + 0x0a, 0x0f, 0x52, 0x50, 0x43, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x52, 0x65, 0x70, 0x6c, + 0x79, 0x12, 0x1e, 0x0a, 0x04, 0x43, 0x6f, 0x64, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0e, 0x32, + 0x0a, 0x2e, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x43, 0x6f, 0x64, 0x65, 0x52, 0x04, 0x43, 0x6f, 0x64, + 0x65, 0x12, 0x22, 0x0a, 0x0c, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, + 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x4d, 0x65, + 0x73, 0x73, 0x61, 0x67, 0x65, 0x12, 0x32, 0x0a, 0x09, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x44, 0x61, + 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x14, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, + 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x41, 0x6e, 0x79, 0x52, 0x09, + 0x45, 0x72, 0x72, 0x6f, 0x72, 0x44, 0x61, 0x74, 0x61, 0x12, 0x22, 0x0a, 0x05, 0x52, 0x65, 0x70, + 0x6c, 0x79, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0c, 0x2e, 0x55, 0x73, 0x65, 0x72, 0x4d, + 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x52, 0x05, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x22, 0x69, 0x0a, + 0x0d, 0x41, 0x67, 0x65, 0x6e, 0x74, 0x42, 0x75, 0x69, 0x6c, 0x64, 0x52, 0x65, 0x71, 0x12, 0x24, + 0x0a, 0x0d, 0x55, 0x73, 0x65, 0x72, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x55, 0x73, 0x65, 0x72, 0x53, 0x65, 0x73, 0x73, 0x69, + 0x6f, 0x6e, 0x49, 0x64, 0x12, 0x16, 0x0a, 0x06, 0x55, 0x73, 0x65, 0x72, 0x49, 0x64, 0x18, 0x02, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x55, 0x73, 0x65, 0x72, 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, + 0x57, 0x6f, 0x72, 0x6b, 0x65, 0x72, 0x49, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, + 0x57, 0x6f, 0x72, 0x6b, 0x65, 0x72, 0x49, 0x64, 0x22, 0x37, 0x0a, 0x0f, 0x41, 0x67, 0x65, 0x6e, + 0x74, 0x55, 0x6e, 0x42, 0x75, 0x69, 0x6c, 0x64, 0x52, 0x65, 0x71, 0x12, 0x24, 0x0a, 0x0d, 0x55, 0x73, 0x65, 0x72, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x55, 0x73, 0x65, 0x72, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x49, - 0x64, 0x12, 0x16, 0x0a, 0x06, 0x55, 0x73, 0x65, 0x72, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x06, 0x55, 0x73, 0x65, 0x72, 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x57, 0x6f, 0x72, - 0x6b, 0x65, 0x72, 0x49, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x57, 0x6f, 0x72, - 0x6b, 0x65, 0x72, 0x49, 0x64, 0x22, 0x37, 0x0a, 0x0f, 0x41, 0x67, 0x65, 0x6e, 0x74, 0x55, 0x6e, - 0x42, 0x75, 0x69, 0x6c, 0x64, 0x52, 0x65, 0x71, 0x12, 0x24, 0x0a, 0x0d, 0x55, 0x73, 0x65, 0x72, + 0x64, 0x22, 0x5f, 0x0a, 0x13, 0x41, 0x67, 0x65, 0x6e, 0x74, 0x53, 0x65, 0x6e, 0x64, 0x4d, 0x65, + 0x73, 0x73, 0x61, 0x67, 0x65, 0x52, 0x65, 0x71, 0x12, 0x24, 0x0a, 0x0d, 0x55, 0x73, 0x65, 0x72, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x0d, 0x55, 0x73, 0x65, 0x72, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x22, 0x5f, - 0x0a, 0x13, 0x41, 0x67, 0x65, 0x6e, 0x74, 0x53, 0x65, 0x6e, 0x64, 0x4d, 0x65, 0x73, 0x73, 0x61, - 0x67, 0x65, 0x52, 0x65, 0x71, 0x12, 0x24, 0x0a, 0x0d, 0x55, 0x73, 0x65, 0x72, 0x53, 0x65, 0x73, - 0x73, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x55, 0x73, - 0x65, 0x72, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x12, 0x22, 0x0a, 0x05, 0x52, - 0x65, 0x70, 0x6c, 0x79, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0c, 0x2e, 0x55, 0x73, 0x65, - 0x72, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x52, 0x05, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x22, - 0x99, 0x01, 0x0a, 0x0f, 0x42, 0x61, 0x74, 0x63, 0x68, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, - 0x52, 0x65, 0x71, 0x12, 0x26, 0x0a, 0x0e, 0x55, 0x73, 0x65, 0x72, 0x53, 0x65, 0x73, 0x73, 0x69, - 0x6f, 0x6e, 0x49, 0x64, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x09, 0x52, 0x0e, 0x55, 0x73, 0x65, - 0x72, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x4d, - 0x61, 0x69, 0x6e, 0x54, 0x79, 0x70, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x4d, - 0x61, 0x69, 0x6e, 0x54, 0x79, 0x70, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x53, 0x75, 0x62, 0x54, 0x79, - 0x70, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x53, 0x75, 0x62, 0x54, 0x79, 0x70, - 0x65, 0x12, 0x28, 0x0a, 0x04, 0x44, 0x61, 0x74, 0x61, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, - 0x14, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, - 0x66, 0x2e, 0x41, 0x6e, 0x79, 0x52, 0x04, 0x44, 0x61, 0x74, 0x61, 0x22, 0x75, 0x0a, 0x13, 0x42, - 0x72, 0x6f, 0x61, 0x64, 0x43, 0x61, 0x73, 0x74, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x52, - 0x65, 0x71, 0x12, 0x1a, 0x0a, 0x08, 0x4d, 0x61, 0x69, 0x6e, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x4d, 0x61, 0x69, 0x6e, 0x54, 0x79, 0x70, 0x65, 0x12, 0x18, - 0x0a, 0x07, 0x53, 0x75, 0x62, 0x54, 0x79, 0x70, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x07, 0x53, 0x75, 0x62, 0x54, 0x79, 0x70, 0x65, 0x12, 0x28, 0x0a, 0x04, 0x44, 0x61, 0x74, 0x61, - 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x14, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, - 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x41, 0x6e, 0x79, 0x52, 0x04, 0x44, 0x61, - 0x74, 0x61, 0x22, 0x36, 0x0a, 0x0e, 0x41, 0x67, 0x65, 0x6e, 0x74, 0x43, 0x6c, 0x6f, 0x73, 0x65, - 0x65, 0x52, 0x65, 0x71, 0x12, 0x24, 0x0a, 0x0d, 0x55, 0x73, 0x65, 0x72, 0x53, 0x65, 0x73, 0x73, - 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x55, 0x73, 0x65, - 0x72, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x22, 0xae, 0x01, 0x0a, 0x12, 0x4e, - 0x6f, 0x74, 0x69, 0x63, 0x65, 0x55, 0x73, 0x65, 0x72, 0x4c, 0x6f, 0x67, 0x69, 0x6e, 0x52, 0x65, - 0x71, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x70, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x49, - 0x70, 0x12, 0x24, 0x0a, 0x0d, 0x55, 0x73, 0x65, 0x72, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, - 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x55, 0x73, 0x65, 0x72, 0x53, 0x65, - 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x12, 0x16, 0x0a, 0x06, 0x55, 0x73, 0x65, 0x72, 0x49, - 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x55, 0x73, 0x65, 0x72, 0x49, 0x64, 0x12, - 0x1e, 0x0a, 0x0a, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x54, 0x61, 0x67, 0x18, 0x04, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x0a, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x54, 0x61, 0x67, 0x12, - 0x2a, 0x0a, 0x10, 0x47, 0x61, 0x74, 0x65, 0x77, 0x61, 0x79, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, - 0x65, 0x49, 0x64, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x10, 0x47, 0x61, 0x74, 0x65, 0x77, - 0x61, 0x79, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x49, 0x64, 0x22, 0xae, 0x01, 0x0a, 0x12, - 0x4e, 0x6f, 0x74, 0x69, 0x63, 0x65, 0x55, 0x73, 0x65, 0x72, 0x43, 0x6c, 0x6f, 0x73, 0x65, 0x52, - 0x65, 0x71, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x70, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, - 0x49, 0x70, 0x12, 0x24, 0x0a, 0x0d, 0x55, 0x73, 0x65, 0x72, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, - 0x6e, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x55, 0x73, 0x65, 0x72, 0x53, - 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x12, 0x16, 0x0a, 0x06, 0x55, 0x73, 0x65, 0x72, - 0x49, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x55, 0x73, 0x65, 0x72, 0x49, 0x64, - 0x12, 0x1e, 0x0a, 0x0a, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x54, 0x61, 0x67, 0x18, 0x04, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x54, 0x61, 0x67, - 0x12, 0x2a, 0x0a, 0x10, 0x47, 0x61, 0x74, 0x65, 0x77, 0x61, 0x79, 0x53, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x49, 0x64, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x10, 0x47, 0x61, 0x74, 0x65, - 0x77, 0x61, 0x79, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x49, 0x64, 0x22, 0x3f, 0x0a, 0x09, - 0x53, 0x6b, 0x69, 0x6c, 0x6c, 0x44, 0x61, 0x74, 0x61, 0x12, 0x18, 0x0a, 0x07, 0x73, 0x6b, 0x69, - 0x6c, 0x6c, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x73, 0x6b, 0x69, 0x6c, - 0x6c, 0x49, 0x44, 0x12, 0x18, 0x0a, 0x07, 0x73, 0x6b, 0x69, 0x6c, 0x6c, 0x4c, 0x76, 0x18, 0x02, - 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x73, 0x6b, 0x69, 0x6c, 0x6c, 0x4c, 0x76, 0x22, 0x36, 0x0a, - 0x0a, 0x55, 0x73, 0x65, 0x72, 0x41, 0x73, 0x73, 0x65, 0x74, 0x73, 0x12, 0x0c, 0x0a, 0x01, 0x41, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x01, 0x41, 0x12, 0x0c, 0x0a, 0x01, 0x54, 0x18, 0x02, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x01, 0x54, 0x12, 0x0c, 0x0a, 0x01, 0x4e, 0x18, 0x03, 0x20, 0x01, - 0x28, 0x05, 0x52, 0x01, 0x4e, 0x22, 0x42, 0x0a, 0x08, 0x55, 0x73, 0x65, 0x72, 0x41, 0x74, 0x6e, - 0x6f, 0x12, 0x0c, 0x0a, 0x01, 0x41, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x01, 0x41, 0x12, - 0x0c, 0x0a, 0x01, 0x54, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x01, 0x54, 0x12, 0x0c, 0x0a, - 0x01, 0x4e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x01, 0x4e, 0x12, 0x0c, 0x0a, 0x01, 0x4f, - 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x01, 0x4f, 0x22, 0x39, 0x0a, 0x09, 0x54, 0x61, 0x73, - 0x6b, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x12, 0x14, 0x0a, 0x05, 0x66, 0x69, 0x72, 0x73, 0x74, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x66, 0x69, 0x72, 0x73, 0x74, 0x12, 0x16, 0x0a, 0x06, - 0x73, 0x65, 0x63, 0x6f, 0x6e, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06, 0x73, 0x65, - 0x63, 0x6f, 0x6e, 0x64, 0x22, 0x54, 0x0a, 0x0a, 0x52, 0x74, 0x61, 0x73, 0x6b, 0x50, 0x61, 0x72, - 0x61, 0x6d, 0x12, 0x16, 0x0a, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x31, 0x18, 0x01, 0x20, 0x01, - 0x28, 0x05, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x31, 0x12, 0x16, 0x0a, 0x06, 0x70, 0x61, - 0x72, 0x61, 0x6d, 0x32, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, - 0x6d, 0x32, 0x12, 0x16, 0x0a, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x33, 0x18, 0x03, 0x20, 0x01, - 0x28, 0x05, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x33, 0x22, 0x1a, 0x0a, 0x06, 0x55, 0x49, - 0x64, 0x52, 0x65, 0x71, 0x12, 0x10, 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x03, 0x75, 0x69, 0x64, 0x22, 0x1d, 0x0a, 0x07, 0x4e, 0x61, 0x6d, 0x65, 0x52, 0x65, - 0x71, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x22, 0x0a, 0x0a, 0x08, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x52, 0x65, - 0x71, 0x22, 0x0b, 0x0a, 0x09, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x52, 0x65, 0x73, 0x70, 0x22, 0x29, - 0x0a, 0x0f, 0x52, 0x50, 0x43, 0x47, 0x65, 0x6e, 0x65, 0x72, 0x61, 0x6c, 0x52, 0x65, 0x71, 0x41, - 0x31, 0x12, 0x16, 0x0a, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x31, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x31, 0x22, 0x41, 0x0a, 0x0f, 0x52, 0x50, 0x43, - 0x47, 0x65, 0x6e, 0x65, 0x72, 0x61, 0x6c, 0x52, 0x65, 0x71, 0x41, 0x32, 0x12, 0x16, 0x0a, 0x06, - 0x70, 0x61, 0x72, 0x61, 0x6d, 0x31, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x70, 0x61, - 0x72, 0x61, 0x6d, 0x31, 0x12, 0x16, 0x0a, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x32, 0x18, 0x02, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x32, 0x22, 0x59, 0x0a, 0x0f, - 0x52, 0x50, 0x43, 0x47, 0x65, 0x6e, 0x65, 0x72, 0x61, 0x6c, 0x52, 0x65, 0x71, 0x41, 0x33, 0x12, + 0x0d, 0x55, 0x73, 0x65, 0x72, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x12, 0x22, + 0x0a, 0x05, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0c, 0x2e, + 0x55, 0x73, 0x65, 0x72, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x52, 0x05, 0x52, 0x65, 0x70, + 0x6c, 0x79, 0x22, 0x99, 0x01, 0x0a, 0x0f, 0x42, 0x61, 0x74, 0x63, 0x68, 0x4d, 0x65, 0x73, 0x73, + 0x61, 0x67, 0x65, 0x52, 0x65, 0x71, 0x12, 0x26, 0x0a, 0x0e, 0x55, 0x73, 0x65, 0x72, 0x53, 0x65, + 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x09, 0x52, 0x0e, + 0x55, 0x73, 0x65, 0x72, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x73, 0x12, 0x1a, + 0x0a, 0x08, 0x4d, 0x61, 0x69, 0x6e, 0x54, 0x79, 0x70, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x08, 0x4d, 0x61, 0x69, 0x6e, 0x54, 0x79, 0x70, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x53, 0x75, + 0x62, 0x54, 0x79, 0x70, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x53, 0x75, 0x62, + 0x54, 0x79, 0x70, 0x65, 0x12, 0x28, 0x0a, 0x04, 0x44, 0x61, 0x74, 0x61, 0x18, 0x04, 0x20, 0x01, + 0x28, 0x0b, 0x32, 0x14, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, + 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x41, 0x6e, 0x79, 0x52, 0x04, 0x44, 0x61, 0x74, 0x61, 0x22, 0x75, + 0x0a, 0x13, 0x42, 0x72, 0x6f, 0x61, 0x64, 0x43, 0x61, 0x73, 0x74, 0x4d, 0x65, 0x73, 0x73, 0x61, + 0x67, 0x65, 0x52, 0x65, 0x71, 0x12, 0x1a, 0x0a, 0x08, 0x4d, 0x61, 0x69, 0x6e, 0x54, 0x79, 0x70, + 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x4d, 0x61, 0x69, 0x6e, 0x54, 0x79, 0x70, + 0x65, 0x12, 0x18, 0x0a, 0x07, 0x53, 0x75, 0x62, 0x54, 0x79, 0x70, 0x65, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x07, 0x53, 0x75, 0x62, 0x54, 0x79, 0x70, 0x65, 0x12, 0x28, 0x0a, 0x04, 0x44, + 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x14, 0x2e, 0x67, 0x6f, 0x6f, 0x67, + 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x41, 0x6e, 0x79, 0x52, + 0x04, 0x44, 0x61, 0x74, 0x61, 0x22, 0x36, 0x0a, 0x0e, 0x41, 0x67, 0x65, 0x6e, 0x74, 0x43, 0x6c, + 0x6f, 0x73, 0x65, 0x65, 0x52, 0x65, 0x71, 0x12, 0x24, 0x0a, 0x0d, 0x55, 0x73, 0x65, 0x72, 0x53, + 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, + 0x55, 0x73, 0x65, 0x72, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x22, 0xae, 0x01, + 0x0a, 0x12, 0x4e, 0x6f, 0x74, 0x69, 0x63, 0x65, 0x55, 0x73, 0x65, 0x72, 0x4c, 0x6f, 0x67, 0x69, + 0x6e, 0x52, 0x65, 0x71, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x70, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x02, 0x49, 0x70, 0x12, 0x24, 0x0a, 0x0d, 0x55, 0x73, 0x65, 0x72, 0x53, 0x65, 0x73, 0x73, + 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x55, 0x73, 0x65, + 0x72, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x12, 0x16, 0x0a, 0x06, 0x55, 0x73, + 0x65, 0x72, 0x49, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x55, 0x73, 0x65, 0x72, + 0x49, 0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x54, 0x61, 0x67, + 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x54, + 0x61, 0x67, 0x12, 0x2a, 0x0a, 0x10, 0x47, 0x61, 0x74, 0x65, 0x77, 0x61, 0x79, 0x53, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x49, 0x64, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x10, 0x47, 0x61, + 0x74, 0x65, 0x77, 0x61, 0x79, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x49, 0x64, 0x22, 0xae, + 0x01, 0x0a, 0x12, 0x4e, 0x6f, 0x74, 0x69, 0x63, 0x65, 0x55, 0x73, 0x65, 0x72, 0x43, 0x6c, 0x6f, + 0x73, 0x65, 0x52, 0x65, 0x71, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x70, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x02, 0x49, 0x70, 0x12, 0x24, 0x0a, 0x0d, 0x55, 0x73, 0x65, 0x72, 0x53, 0x65, 0x73, + 0x73, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x55, 0x73, + 0x65, 0x72, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x12, 0x16, 0x0a, 0x06, 0x55, + 0x73, 0x65, 0x72, 0x49, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x55, 0x73, 0x65, + 0x72, 0x49, 0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x54, 0x61, + 0x67, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, + 0x54, 0x61, 0x67, 0x12, 0x2a, 0x0a, 0x10, 0x47, 0x61, 0x74, 0x65, 0x77, 0x61, 0x79, 0x53, 0x65, + 0x72, 0x76, 0x69, 0x63, 0x65, 0x49, 0x64, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x10, 0x47, + 0x61, 0x74, 0x65, 0x77, 0x61, 0x79, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x49, 0x64, 0x22, + 0x3f, 0x0a, 0x09, 0x53, 0x6b, 0x69, 0x6c, 0x6c, 0x44, 0x61, 0x74, 0x61, 0x12, 0x18, 0x0a, 0x07, + 0x73, 0x6b, 0x69, 0x6c, 0x6c, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x73, + 0x6b, 0x69, 0x6c, 0x6c, 0x49, 0x44, 0x12, 0x18, 0x0a, 0x07, 0x73, 0x6b, 0x69, 0x6c, 0x6c, 0x4c, + 0x76, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x73, 0x6b, 0x69, 0x6c, 0x6c, 0x4c, 0x76, + 0x22, 0x36, 0x0a, 0x0a, 0x55, 0x73, 0x65, 0x72, 0x41, 0x73, 0x73, 0x65, 0x74, 0x73, 0x12, 0x0c, + 0x0a, 0x01, 0x41, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x01, 0x41, 0x12, 0x0c, 0x0a, 0x01, + 0x54, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x01, 0x54, 0x12, 0x0c, 0x0a, 0x01, 0x4e, 0x18, + 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x01, 0x4e, 0x22, 0x42, 0x0a, 0x08, 0x55, 0x73, 0x65, 0x72, + 0x41, 0x74, 0x6e, 0x6f, 0x12, 0x0c, 0x0a, 0x01, 0x41, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x01, 0x41, 0x12, 0x0c, 0x0a, 0x01, 0x54, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x01, 0x54, + 0x12, 0x0c, 0x0a, 0x01, 0x4e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x01, 0x4e, 0x12, 0x0c, + 0x0a, 0x01, 0x4f, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x01, 0x4f, 0x22, 0x39, 0x0a, 0x09, + 0x54, 0x61, 0x73, 0x6b, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x12, 0x14, 0x0a, 0x05, 0x66, 0x69, 0x72, + 0x73, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x66, 0x69, 0x72, 0x73, 0x74, 0x12, + 0x16, 0x0a, 0x06, 0x73, 0x65, 0x63, 0x6f, 0x6e, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, + 0x06, 0x73, 0x65, 0x63, 0x6f, 0x6e, 0x64, 0x22, 0x54, 0x0a, 0x0a, 0x52, 0x74, 0x61, 0x73, 0x6b, + 0x50, 0x61, 0x72, 0x61, 0x6d, 0x12, 0x16, 0x0a, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x31, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x31, 0x12, 0x16, 0x0a, + 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x32, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06, 0x70, + 0x61, 0x72, 0x61, 0x6d, 0x32, 0x12, 0x16, 0x0a, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x33, 0x18, + 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x33, 0x22, 0x1a, 0x0a, + 0x06, 0x55, 0x49, 0x64, 0x52, 0x65, 0x71, 0x12, 0x10, 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x75, 0x69, 0x64, 0x22, 0x1d, 0x0a, 0x07, 0x4e, 0x61, 0x6d, + 0x65, 0x52, 0x65, 0x71, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x22, 0x0a, 0x0a, 0x08, 0x45, 0x6d, 0x70, 0x74, + 0x79, 0x52, 0x65, 0x71, 0x22, 0x0b, 0x0a, 0x09, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x52, 0x65, 0x73, + 0x70, 0x22, 0x29, 0x0a, 0x0f, 0x52, 0x50, 0x43, 0x47, 0x65, 0x6e, 0x65, 0x72, 0x61, 0x6c, 0x52, + 0x65, 0x71, 0x41, 0x31, 0x12, 0x16, 0x0a, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x31, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x31, 0x22, 0x41, 0x0a, 0x0f, + 0x52, 0x50, 0x43, 0x47, 0x65, 0x6e, 0x65, 0x72, 0x61, 0x6c, 0x52, 0x65, 0x71, 0x41, 0x32, 0x12, 0x16, 0x0a, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x31, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x31, 0x12, 0x16, 0x0a, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, - 0x32, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x32, 0x12, - 0x16, 0x0a, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x33, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x33, 0x22, 0x71, 0x0a, 0x0f, 0x52, 0x50, 0x43, 0x47, 0x65, - 0x6e, 0x65, 0x72, 0x61, 0x6c, 0x52, 0x65, 0x71, 0x41, 0x34, 0x12, 0x16, 0x0a, 0x06, 0x70, 0x61, - 0x72, 0x61, 0x6d, 0x31, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, - 0x6d, 0x31, 0x12, 0x16, 0x0a, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x32, 0x18, 0x02, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x32, 0x12, 0x16, 0x0a, 0x06, 0x70, 0x61, - 0x72, 0x61, 0x6d, 0x33, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, - 0x6d, 0x33, 0x12, 0x16, 0x0a, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x34, 0x18, 0x04, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x34, 0x22, 0x51, 0x0a, 0x0b, 0x52, 0x50, - 0x43, 0x52, 0x54, 0x61, 0x73, 0x6b, 0x52, 0x65, 0x71, 0x12, 0x10, 0x0a, 0x03, 0x75, 0x69, 0x64, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x75, 0x69, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x74, - 0x61, 0x73, 0x6b, 0x54, 0x79, 0x70, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x08, 0x74, - 0x61, 0x73, 0x6b, 0x54, 0x79, 0x70, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x70, 0x61, 0x72, 0x61, 0x6d, - 0x18, 0x03, 0x20, 0x03, 0x28, 0x05, 0x52, 0x05, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x22, 0xa1, 0x03, - 0x0a, 0x0d, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x44, 0x42, 0x49, 0x6e, 0x66, 0x6f, 0x12, - 0x1a, 0x0a, 0x08, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x08, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x69, 0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x73, - 0x65, 0x72, 0x76, 0x65, 0x72, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x0a, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x6f, - 0x77, 0x6e, 0x65, 0x72, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x6f, 0x77, 0x6e, 0x65, - 0x72, 0x12, 0x14, 0x0a, 0x05, 0x63, 0x72, 0x6f, 0x73, 0x73, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x05, 0x63, 0x72, 0x6f, 0x73, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x63, 0x72, 0x6f, 0x73, 0x73, - 0x49, 0x64, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x63, 0x72, 0x6f, 0x73, 0x73, 0x49, - 0x64, 0x12, 0x22, 0x0a, 0x0c, 0x73, 0x69, 0x6e, 0x67, 0x6c, 0x65, 0x73, 0x65, 0x72, 0x76, 0x65, - 0x72, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x73, 0x69, 0x6e, 0x67, 0x6c, 0x65, 0x73, - 0x65, 0x72, 0x76, 0x65, 0x72, 0x12, 0x1a, 0x0a, 0x08, 0x6f, 0x70, 0x65, 0x6e, 0x74, 0x69, 0x6d, - 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x6f, 0x70, 0x65, 0x6e, 0x74, 0x69, 0x6d, - 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x72, 0x65, 0x64, 0x69, 0x73, 0x49, 0x73, 0x43, 0x6c, 0x75, 0x73, - 0x74, 0x65, 0x72, 0x18, 0x08, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0e, 0x72, 0x65, 0x64, 0x69, 0x73, - 0x49, 0x73, 0x43, 0x6c, 0x75, 0x73, 0x74, 0x65, 0x72, 0x12, 0x1c, 0x0a, 0x09, 0x72, 0x65, 0x64, - 0x69, 0x73, 0x41, 0x64, 0x64, 0x72, 0x18, 0x09, 0x20, 0x03, 0x28, 0x09, 0x52, 0x09, 0x72, 0x65, - 0x64, 0x69, 0x73, 0x41, 0x64, 0x64, 0x72, 0x12, 0x24, 0x0a, 0x0d, 0x72, 0x65, 0x64, 0x69, 0x73, - 0x50, 0x61, 0x73, 0x73, 0x77, 0x6f, 0x72, 0x64, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, - 0x72, 0x65, 0x64, 0x69, 0x73, 0x50, 0x61, 0x73, 0x73, 0x77, 0x6f, 0x72, 0x64, 0x12, 0x18, 0x0a, - 0x07, 0x72, 0x65, 0x64, 0x69, 0x73, 0x44, 0x62, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, - 0x72, 0x65, 0x64, 0x69, 0x73, 0x44, 0x62, 0x12, 0x1e, 0x0a, 0x0a, 0x4d, 0x6f, 0x6e, 0x67, 0x6f, - 0x64, 0x62, 0x55, 0x72, 0x6c, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4d, 0x6f, 0x6e, - 0x67, 0x6f, 0x64, 0x62, 0x55, 0x72, 0x6c, 0x12, 0x28, 0x0a, 0x0f, 0x6d, 0x6f, 0x6e, 0x67, 0x6f, - 0x64, 0x62, 0x44, 0x61, 0x74, 0x61, 0x62, 0x61, 0x73, 0x65, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x0f, 0x6d, 0x6f, 0x6e, 0x67, 0x6f, 0x64, 0x62, 0x44, 0x61, 0x74, 0x61, 0x62, 0x61, 0x73, - 0x65, 0x2a, 0x43, 0x0a, 0x12, 0x48, 0x65, 0x72, 0x6f, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, - 0x74, 0x65, 0x73, 0x54, 0x79, 0x70, 0x65, 0x12, 0x06, 0x0a, 0x02, 0x48, 0x70, 0x10, 0x00, 0x12, - 0x07, 0x0a, 0x03, 0x41, 0x74, 0x6b, 0x10, 0x01, 0x12, 0x07, 0x0a, 0x03, 0x44, 0x65, 0x66, 0x10, - 0x02, 0x12, 0x09, 0x0a, 0x05, 0x53, 0x70, 0x65, 0x65, 0x64, 0x10, 0x03, 0x12, 0x08, 0x0a, 0x04, - 0x43, 0x72, 0x69, 0x74, 0x10, 0x04, 0x42, 0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70, 0x62, 0x62, 0x06, - 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x32, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x32, 0x22, + 0x59, 0x0a, 0x0f, 0x52, 0x50, 0x43, 0x47, 0x65, 0x6e, 0x65, 0x72, 0x61, 0x6c, 0x52, 0x65, 0x71, + 0x41, 0x33, 0x12, 0x16, 0x0a, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x31, 0x18, 0x01, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x31, 0x12, 0x16, 0x0a, 0x06, 0x70, 0x61, + 0x72, 0x61, 0x6d, 0x32, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, + 0x6d, 0x32, 0x12, 0x16, 0x0a, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x33, 0x18, 0x03, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x33, 0x22, 0x71, 0x0a, 0x0f, 0x52, 0x50, + 0x43, 0x47, 0x65, 0x6e, 0x65, 0x72, 0x61, 0x6c, 0x52, 0x65, 0x71, 0x41, 0x34, 0x12, 0x16, 0x0a, + 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x31, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x70, + 0x61, 0x72, 0x61, 0x6d, 0x31, 0x12, 0x16, 0x0a, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x32, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x32, 0x12, 0x16, 0x0a, + 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x33, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x70, + 0x61, 0x72, 0x61, 0x6d, 0x33, 0x12, 0x16, 0x0a, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x34, 0x18, + 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x34, 0x22, 0x51, 0x0a, + 0x0b, 0x52, 0x50, 0x43, 0x52, 0x54, 0x61, 0x73, 0x6b, 0x52, 0x65, 0x71, 0x12, 0x10, 0x0a, 0x03, + 0x75, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x75, 0x69, 0x64, 0x12, 0x1a, + 0x0a, 0x08, 0x74, 0x61, 0x73, 0x6b, 0x54, 0x79, 0x70, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, + 0x52, 0x08, 0x74, 0x61, 0x73, 0x6b, 0x54, 0x79, 0x70, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x70, 0x61, + 0x72, 0x61, 0x6d, 0x18, 0x03, 0x20, 0x03, 0x28, 0x05, 0x52, 0x05, 0x70, 0x61, 0x72, 0x61, 0x6d, + 0x22, 0xa1, 0x03, 0x0a, 0x0d, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x44, 0x42, 0x49, 0x6e, + 0x66, 0x6f, 0x12, 0x1a, 0x0a, 0x08, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x69, 0x64, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x69, 0x64, 0x12, 0x1e, + 0x0a, 0x0a, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x0a, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x14, + 0x0a, 0x05, 0x6f, 0x77, 0x6e, 0x65, 0x72, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x6f, + 0x77, 0x6e, 0x65, 0x72, 0x12, 0x14, 0x0a, 0x05, 0x63, 0x72, 0x6f, 0x73, 0x73, 0x18, 0x04, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x05, 0x63, 0x72, 0x6f, 0x73, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x63, 0x72, + 0x6f, 0x73, 0x73, 0x49, 0x64, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x63, 0x72, 0x6f, + 0x73, 0x73, 0x49, 0x64, 0x12, 0x22, 0x0a, 0x0c, 0x73, 0x69, 0x6e, 0x67, 0x6c, 0x65, 0x73, 0x65, + 0x72, 0x76, 0x65, 0x72, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x73, 0x69, 0x6e, 0x67, + 0x6c, 0x65, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x12, 0x1a, 0x0a, 0x08, 0x6f, 0x70, 0x65, 0x6e, + 0x74, 0x69, 0x6d, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x6f, 0x70, 0x65, 0x6e, + 0x74, 0x69, 0x6d, 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x72, 0x65, 0x64, 0x69, 0x73, 0x49, 0x73, 0x43, + 0x6c, 0x75, 0x73, 0x74, 0x65, 0x72, 0x18, 0x08, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0e, 0x72, 0x65, + 0x64, 0x69, 0x73, 0x49, 0x73, 0x43, 0x6c, 0x75, 0x73, 0x74, 0x65, 0x72, 0x12, 0x1c, 0x0a, 0x09, + 0x72, 0x65, 0x64, 0x69, 0x73, 0x41, 0x64, 0x64, 0x72, 0x18, 0x09, 0x20, 0x03, 0x28, 0x09, 0x52, + 0x09, 0x72, 0x65, 0x64, 0x69, 0x73, 0x41, 0x64, 0x64, 0x72, 0x12, 0x24, 0x0a, 0x0d, 0x72, 0x65, + 0x64, 0x69, 0x73, 0x50, 0x61, 0x73, 0x73, 0x77, 0x6f, 0x72, 0x64, 0x18, 0x0a, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x0d, 0x72, 0x65, 0x64, 0x69, 0x73, 0x50, 0x61, 0x73, 0x73, 0x77, 0x6f, 0x72, 0x64, + 0x12, 0x18, 0x0a, 0x07, 0x72, 0x65, 0x64, 0x69, 0x73, 0x44, 0x62, 0x18, 0x0b, 0x20, 0x01, 0x28, + 0x05, 0x52, 0x07, 0x72, 0x65, 0x64, 0x69, 0x73, 0x44, 0x62, 0x12, 0x1e, 0x0a, 0x0a, 0x4d, 0x6f, + 0x6e, 0x67, 0x6f, 0x64, 0x62, 0x55, 0x72, 0x6c, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, + 0x4d, 0x6f, 0x6e, 0x67, 0x6f, 0x64, 0x62, 0x55, 0x72, 0x6c, 0x12, 0x28, 0x0a, 0x0f, 0x6d, 0x6f, + 0x6e, 0x67, 0x6f, 0x64, 0x62, 0x44, 0x61, 0x74, 0x61, 0x62, 0x61, 0x73, 0x65, 0x18, 0x0d, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x0f, 0x6d, 0x6f, 0x6e, 0x67, 0x6f, 0x64, 0x62, 0x44, 0x61, 0x74, 0x61, + 0x62, 0x61, 0x73, 0x65, 0x2a, 0x43, 0x0a, 0x12, 0x48, 0x65, 0x72, 0x6f, 0x41, 0x74, 0x74, 0x72, + 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x54, 0x79, 0x70, 0x65, 0x12, 0x06, 0x0a, 0x02, 0x48, 0x70, + 0x10, 0x00, 0x12, 0x07, 0x0a, 0x03, 0x41, 0x74, 0x6b, 0x10, 0x01, 0x12, 0x07, 0x0a, 0x03, 0x44, + 0x65, 0x66, 0x10, 0x02, 0x12, 0x09, 0x0a, 0x05, 0x53, 0x70, 0x65, 0x65, 0x64, 0x10, 0x03, 0x12, + 0x08, 0x0a, 0x04, 0x43, 0x72, 0x69, 0x74, 0x10, 0x04, 0x42, 0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70, + 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( From e9238d52b0872b0cdbf20652dd5f7c9f9c9c63da Mon Sep 17 00:00:00 2001 From: liwei1dao Date: Wed, 1 Feb 2023 15:59:13 +0800 Subject: [PATCH 07/17] =?UTF-8?q?=E4=B8=8A=E4=BC=A0=E6=88=98=E6=96=97?= =?UTF-8?q?=E8=A7=92=E8=89=B2boosid?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- modules/battle/modelBattle.go | 5 ++++- pb/arena_msg.pb.go | 25 ++++++++++++++++++------- pb/battle_db.pb.go | 10 +++++----- pb/comm.pb.go | 2 +- 4 files changed, 28 insertions(+), 14 deletions(-) diff --git a/modules/battle/modelBattle.go b/modules/battle/modelBattle.go index acdea1c33..d4224fdd8 100644 --- a/modules/battle/modelBattle.go +++ b/modules/battle/modelBattle.go @@ -481,8 +481,11 @@ func (this *modelBattleComp) createMasterRoles(comp, wheel int, fid int32) (capt CaptainSkill: hero.CaptainSkill, NormalSkill: hero.NormalSkill, Property: hero.Property, - Isboos: v.IsBoss, } + if v.IsBoss == 1 { + roles[i].Boosid = v.Monster + } + for i, v := range roles[i].NormalSkill { if i == 0 { v.SkillLv = monst.Skill1 diff --git a/pb/arena_msg.pb.go b/pb/arena_msg.pb.go index ca11fbd95..274e14864 100644 --- a/pb/arena_msg.pb.go +++ b/pb/arena_msg.pb.go @@ -1298,8 +1298,9 @@ type ArenaRTimePvpPush struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - RoomId string `protobuf:"bytes,1,opt,name=RoomId,proto3" json:"RoomId"` - Info *BattleInfo `protobuf:"bytes,2,opt,name=info,proto3" json:"info"` + RoomId string `protobuf:"bytes,1,opt,name=RoomId,proto3" json:"RoomId"` + ServicePath string `protobuf:"bytes,2,opt,name=servicePath,proto3" json:"servicePath"` + Info *BattleInfo `protobuf:"bytes,3,opt,name=info,proto3" json:"info"` } func (x *ArenaRTimePvpPush) Reset() { @@ -1341,6 +1342,13 @@ func (x *ArenaRTimePvpPush) GetRoomId() string { return "" } +func (x *ArenaRTimePvpPush) GetServicePath() string { + if x != nil { + return x.ServicePath + } + return "" +} + func (x *ArenaRTimePvpPush) GetInfo() *BattleInfo { if x != nil { return x.Info @@ -1462,12 +1470,15 @@ var file_arena_arena_msg_proto_rawDesc = []byte{ 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x1c, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x06, 0x2e, 0x44, 0x42, 0x4e, 0x70, 0x63, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, - 0x01, 0x22, 0x4c, 0x0a, 0x11, 0x41, 0x72, 0x65, 0x6e, 0x61, 0x52, 0x54, 0x69, 0x6d, 0x65, 0x50, + 0x01, 0x22, 0x6e, 0x0a, 0x11, 0x41, 0x72, 0x65, 0x6e, 0x61, 0x52, 0x54, 0x69, 0x6d, 0x65, 0x50, 0x76, 0x70, 0x50, 0x75, 0x73, 0x68, 0x12, 0x16, 0x0a, 0x06, 0x52, 0x6f, 0x6f, 0x6d, 0x49, 0x64, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x52, 0x6f, 0x6f, 0x6d, 0x49, 0x64, 0x12, 0x1f, - 0x0a, 0x04, 0x69, 0x6e, 0x66, 0x6f, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0b, 0x2e, 0x42, - 0x61, 0x74, 0x74, 0x6c, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x04, 0x69, 0x6e, 0x66, 0x6f, 0x42, - 0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x52, 0x6f, 0x6f, 0x6d, 0x49, 0x64, 0x12, 0x20, + 0x0a, 0x0b, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x0b, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, + 0x12, 0x1f, 0x0a, 0x04, 0x69, 0x6e, 0x66, 0x6f, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0b, + 0x2e, 0x42, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x04, 0x69, 0x6e, 0x66, + 0x6f, 0x42, 0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, + 0x33, } var ( diff --git a/pb/battle_db.pb.go b/pb/battle_db.pb.go index 6a75d67da..26577a806 100644 --- a/pb/battle_db.pb.go +++ b/pb/battle_db.pb.go @@ -270,7 +270,7 @@ type BattleRole struct { EquipSkill []*SkillData `protobuf:"bytes,11,rep,name=equipSkill,proto3" json:"equipSkill" bson:"normalSkill"` //普通技能 Property map[string]int32 `protobuf:"bytes,12,rep,name=property,proto3" json:"property" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"varint,2,opt,name=value,proto3"` // 属性相关 Ishelp bool `protobuf:"varint,13,opt,name=ishelp,proto3" json:"ishelp"` //是否是助战英雄 - Isboos int32 `protobuf:"varint,14,opt,name=isboos,proto3" json:"isboos"` //是否是boos + Boosid int32 `protobuf:"varint,14,opt,name=boosid,proto3" json:"boosid"` //是否是boos } func (x *BattleRole) Reset() { @@ -396,9 +396,9 @@ func (x *BattleRole) GetIshelp() bool { return false } -func (x *BattleRole) GetIsboos() int32 { +func (x *BattleRole) GetBoosid() int32 { if x != nil { - return x.Isboos + return x.Boosid } return 0 } @@ -650,8 +650,8 @@ var file_battle_battle_db_proto_rawDesc = []byte{ 0x70, 0x65, 0x72, 0x74, 0x79, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x08, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x12, 0x16, 0x0a, 0x06, 0x69, 0x73, 0x68, 0x65, 0x6c, 0x70, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x08, 0x52, 0x06, 0x69, 0x73, 0x68, 0x65, 0x6c, 0x70, 0x12, 0x16, 0x0a, 0x06, - 0x69, 0x73, 0x62, 0x6f, 0x6f, 0x73, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06, 0x69, 0x73, - 0x62, 0x6f, 0x6f, 0x73, 0x1a, 0x3b, 0x0a, 0x0d, 0x50, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, + 0x62, 0x6f, 0x6f, 0x73, 0x69, 0x64, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06, 0x62, 0x6f, + 0x6f, 0x73, 0x69, 0x64, 0x1a, 0x3b, 0x0a, 0x0d, 0x50, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 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, diff --git a/pb/comm.pb.go b/pb/comm.pb.go index 8389c7583..bd439f32f 100644 --- a/pb/comm.pb.go +++ b/pb/comm.pb.go @@ -86,7 +86,7 @@ type UserMessage struct { MainType string `protobuf:"bytes,1,opt,name=MainType,proto3" json:"MainType"` //用户消息处理 模块名 例如:user 对应项目中 user的模块 SubType string `protobuf:"bytes,2,opt,name=SubType,proto3" json:"SubType"` //用户消息处理函数名 例如:login 对应项目中 user的模块中 // api_login 的处理函数 - ServicePath string `protobuf:"bytes,3,opt,name=servicePath,proto3" json:"servicePath"` // 消息路由地址 部分消息前端确定转发给谁 + ServicePath string `protobuf:"bytes,3,opt,name=servicePath,proto3" json:"servicePath"` // 消息路由地址 部分消息前端确定转发给谁 \worker\worker0 Data *anypb.Any `protobuf:"bytes,4,opt,name=data,proto3" json:"data"` Sec string `protobuf:"bytes,5,opt,name=sec,proto3" json:"sec"` //密文 } From 44efa1f5d917cae41607bf0b24b5d0ee25d0c246 Mon Sep 17 00:00:00 2001 From: liwei1dao Date: Wed, 1 Feb 2023 16:10:13 +0800 Subject: [PATCH 08/17] =?UTF-8?q?=E4=B8=8A=E4=BC=A0=E6=88=98=E6=96=97?= =?UTF-8?q?=E8=A7=92=E8=89=B2=E6=95=B0=E6=8D=AE=E7=BB=93=E6=9E=84=E8=B0=83?= =?UTF-8?q?=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- modules/battle/modelBattle.go | 5 +- pb/battle_db.pb.go | 147 ++++++++++++++++++---------------- 2 files changed, 80 insertions(+), 72 deletions(-) diff --git a/modules/battle/modelBattle.go b/modules/battle/modelBattle.go index d4224fdd8..d424dca15 100644 --- a/modules/battle/modelBattle.go +++ b/modules/battle/modelBattle.go @@ -481,9 +481,8 @@ func (this *modelBattleComp) createMasterRoles(comp, wheel int, fid int32) (capt CaptainSkill: hero.CaptainSkill, NormalSkill: hero.NormalSkill, Property: hero.Property, - } - if v.IsBoss == 1 { - roles[i].Boosid = v.Monster + Isboos: v.IsBoss, + Monsterid: v.Monster, } for i, v := range roles[i].NormalSkill { diff --git a/pb/battle_db.pb.go b/pb/battle_db.pb.go index 26577a806..c71d39316 100644 --- a/pb/battle_db.pb.go +++ b/pb/battle_db.pb.go @@ -270,7 +270,8 @@ type BattleRole struct { EquipSkill []*SkillData `protobuf:"bytes,11,rep,name=equipSkill,proto3" json:"equipSkill" bson:"normalSkill"` //普通技能 Property map[string]int32 `protobuf:"bytes,12,rep,name=property,proto3" json:"property" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"varint,2,opt,name=value,proto3"` // 属性相关 Ishelp bool `protobuf:"varint,13,opt,name=ishelp,proto3" json:"ishelp"` //是否是助战英雄 - Boosid int32 `protobuf:"varint,14,opt,name=boosid,proto3" json:"boosid"` //是否是boos + Isboos int32 `protobuf:"varint,14,opt,name=isboos,proto3" json:"isboos"` //是否是boos + Monsterid int32 `protobuf:"varint,15,opt,name=monsterid,proto3" json:"monsterid"` //怪物id } func (x *BattleRole) Reset() { @@ -396,9 +397,16 @@ func (x *BattleRole) GetIshelp() bool { return false } -func (x *BattleRole) GetBoosid() int32 { +func (x *BattleRole) GetIsboos() int32 { if x != nil { - return x.Boosid + return x.Isboos + } + return 0 +} + +func (x *BattleRole) GetMonsterid() int32 { + if x != nil { + return x.Monsterid } return 0 } @@ -624,7 +632,7 @@ var File_battle_battle_db_proto protoreflect.FileDescriptor var file_battle_battle_db_proto_rawDesc = []byte{ 0x0a, 0x16, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x2f, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x5f, 0x64, 0x62, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x0a, 0x63, 0x6f, 0x6d, 0x6d, 0x2e, 0x70, - 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xea, 0x03, 0x0a, 0x0a, 0x42, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x52, + 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x88, 0x04, 0x0a, 0x0a, 0x42, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x52, 0x6f, 0x6c, 0x65, 0x12, 0x10, 0x0a, 0x03, 0x74, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x03, 0x74, 0x69, 0x64, 0x12, 0x10, 0x0a, 0x03, 0x6f, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6f, 0x69, 0x64, 0x12, 0x10, 0x0a, 0x03, 0x70, 0x6f, 0x73, 0x18, 0x03, @@ -650,71 +658,72 @@ var file_battle_battle_db_proto_rawDesc = []byte{ 0x70, 0x65, 0x72, 0x74, 0x79, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x08, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x12, 0x16, 0x0a, 0x06, 0x69, 0x73, 0x68, 0x65, 0x6c, 0x70, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x08, 0x52, 0x06, 0x69, 0x73, 0x68, 0x65, 0x6c, 0x70, 0x12, 0x16, 0x0a, 0x06, - 0x62, 0x6f, 0x6f, 0x73, 0x69, 0x64, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06, 0x62, 0x6f, - 0x6f, 0x73, 0x69, 0x64, 0x1a, 0x3b, 0x0a, 0x0d, 0x50, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 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, 0x22, 0x9e, 0x01, 0x0a, 0x0d, 0x44, 0x42, 0x42, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x46, 0x6f, - 0x72, 0x6d, 0x74, 0x12, 0x18, 0x0a, 0x07, 0x6c, 0x65, 0x61, 0x64, 0x70, 0x6f, 0x73, 0x18, 0x01, - 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x6c, 0x65, 0x61, 0x64, 0x70, 0x6f, 0x73, 0x12, 0x1f, 0x0a, - 0x04, 0x74, 0x65, 0x61, 0x6d, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0b, 0x2e, 0x42, 0x61, - 0x74, 0x74, 0x6c, 0x65, 0x52, 0x6f, 0x6c, 0x65, 0x52, 0x04, 0x74, 0x65, 0x61, 0x6d, 0x12, 0x25, - 0x0a, 0x07, 0x73, 0x79, 0x73, 0x74, 0x65, 0x61, 0x6d, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, - 0x0b, 0x2e, 0x42, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x52, 0x6f, 0x6c, 0x65, 0x52, 0x07, 0x73, 0x79, - 0x73, 0x74, 0x65, 0x61, 0x6d, 0x12, 0x2b, 0x0a, 0x0a, 0x62, 0x61, 0x63, 0x6b, 0x75, 0x70, 0x74, - 0x65, 0x61, 0x6d, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0b, 0x2e, 0x42, 0x61, 0x74, 0x74, - 0x6c, 0x65, 0x52, 0x6f, 0x6c, 0x65, 0x52, 0x0a, 0x62, 0x61, 0x63, 0x6b, 0x75, 0x70, 0x74, 0x65, - 0x61, 0x6d, 0x22, 0xbd, 0x03, 0x0a, 0x0e, 0x44, 0x42, 0x42, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x52, - 0x65, 0x63, 0x6f, 0x72, 0x64, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x74, 0x69, 0x74, 0x6c, 0x65, 0x18, 0x02, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x74, 0x69, 0x74, 0x6c, 0x65, 0x12, 0x21, 0x0a, 0x05, 0x62, - 0x74, 0x79, 0x70, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x0b, 0x2e, 0x42, 0x61, 0x74, - 0x74, 0x6c, 0x65, 0x54, 0x79, 0x70, 0x65, 0x52, 0x05, 0x62, 0x74, 0x79, 0x70, 0x65, 0x12, 0x1f, - 0x0a, 0x05, 0x70, 0x74, 0x79, 0x70, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x09, 0x2e, - 0x50, 0x6c, 0x61, 0x79, 0x54, 0x79, 0x70, 0x65, 0x52, 0x05, 0x70, 0x74, 0x79, 0x70, 0x65, 0x12, - 0x16, 0x0a, 0x06, 0x70, 0x6c, 0x65, 0x76, 0x65, 0x6c, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x06, 0x70, 0x6c, 0x65, 0x76, 0x65, 0x6c, 0x12, 0x23, 0x0a, 0x05, 0x73, 0x74, 0x61, 0x74, 0x65, - 0x18, 0x06, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x0d, 0x2e, 0x42, 0x42, 0x61, 0x74, 0x74, 0x6c, 0x65, - 0x53, 0x74, 0x61, 0x74, 0x65, 0x52, 0x05, 0x73, 0x74, 0x61, 0x74, 0x65, 0x12, 0x1c, 0x0a, 0x09, - 0x72, 0x65, 0x64, 0x43, 0x6f, 0x6d, 0x70, 0x49, 0x64, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x09, 0x72, 0x65, 0x64, 0x43, 0x6f, 0x6d, 0x70, 0x49, 0x64, 0x12, 0x2a, 0x0a, 0x08, 0x72, 0x65, - 0x64, 0x66, 0x6c, 0x69, 0x73, 0x74, 0x18, 0x08, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x44, - 0x42, 0x42, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x46, 0x6f, 0x72, 0x6d, 0x74, 0x52, 0x08, 0x72, 0x65, - 0x64, 0x66, 0x6c, 0x69, 0x73, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x62, 0x6c, 0x75, 0x65, 0x43, 0x6f, - 0x6d, 0x70, 0x49, 0x64, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x62, 0x6c, 0x75, 0x65, - 0x43, 0x6f, 0x6d, 0x70, 0x49, 0x64, 0x12, 0x2c, 0x0a, 0x09, 0x62, 0x75, 0x6c, 0x65, 0x66, 0x6c, - 0x69, 0x73, 0x74, 0x18, 0x0a, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x44, 0x42, 0x42, 0x61, - 0x74, 0x74, 0x6c, 0x65, 0x46, 0x6f, 0x72, 0x6d, 0x74, 0x52, 0x09, 0x62, 0x75, 0x6c, 0x65, 0x66, - 0x6c, 0x69, 0x73, 0x74, 0x12, 0x2f, 0x0a, 0x0b, 0x72, 0x6f, 0x75, 0x6e, 0x64, 0x72, 0x65, 0x73, - 0x75, 0x6c, 0x74, 0x18, 0x0b, 0x20, 0x03, 0x28, 0x0e, 0x32, 0x0d, 0x2e, 0x44, 0x42, 0x42, 0x61, - 0x74, 0x74, 0x6c, 0x65, 0x43, 0x6f, 0x6d, 0x70, 0x52, 0x0b, 0x72, 0x6f, 0x75, 0x6e, 0x64, 0x72, - 0x65, 0x73, 0x75, 0x6c, 0x74, 0x12, 0x25, 0x0a, 0x06, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x18, - 0x0c, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x0d, 0x2e, 0x44, 0x42, 0x42, 0x61, 0x74, 0x74, 0x6c, 0x65, - 0x43, 0x6f, 0x6d, 0x70, 0x52, 0x06, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x12, 0x14, 0x0a, 0x05, - 0x74, 0x61, 0x73, 0x6b, 0x73, 0x18, 0x0d, 0x20, 0x03, 0x28, 0x05, 0x52, 0x05, 0x74, 0x61, 0x73, - 0x6b, 0x73, 0x2a, 0x39, 0x0a, 0x0a, 0x42, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x54, 0x79, 0x70, 0x65, - 0x12, 0x07, 0x0a, 0x03, 0x6e, 0x69, 0x6c, 0x10, 0x00, 0x12, 0x07, 0x0a, 0x03, 0x70, 0x76, 0x65, - 0x10, 0x01, 0x12, 0x07, 0x0a, 0x03, 0x70, 0x76, 0x70, 0x10, 0x02, 0x12, 0x07, 0x0a, 0x03, 0x70, - 0x76, 0x62, 0x10, 0x03, 0x12, 0x07, 0x0a, 0x03, 0x65, 0x76, 0x65, 0x10, 0x04, 0x2a, 0xb3, 0x01, - 0x0a, 0x08, 0x50, 0x6c, 0x61, 0x79, 0x54, 0x79, 0x70, 0x65, 0x12, 0x08, 0x0a, 0x04, 0x6e, 0x75, - 0x6c, 0x6c, 0x10, 0x00, 0x12, 0x0c, 0x0a, 0x08, 0x6d, 0x61, 0x69, 0x6e, 0x6c, 0x69, 0x6e, 0x65, - 0x10, 0x01, 0x12, 0x0a, 0x0a, 0x06, 0x70, 0x61, 0x67, 0x6f, 0x64, 0x61, 0x10, 0x02, 0x12, 0x09, - 0x0a, 0x05, 0x72, 0x74, 0x61, 0x73, 0x6b, 0x10, 0x03, 0x12, 0x0b, 0x0a, 0x07, 0x68, 0x75, 0x6e, - 0x74, 0x69, 0x6e, 0x67, 0x10, 0x04, 0x12, 0x0a, 0x0a, 0x06, 0x76, 0x69, 0x6b, 0x69, 0x6e, 0x67, - 0x10, 0x05, 0x12, 0x0f, 0x0a, 0x0b, 0x6d, 0x6f, 0x6f, 0x6e, 0x66, 0x61, 0x6e, 0x74, 0x61, 0x73, - 0x79, 0x10, 0x06, 0x12, 0x09, 0x0a, 0x05, 0x61, 0x72, 0x65, 0x6e, 0x61, 0x10, 0x07, 0x12, 0x0b, - 0x0a, 0x07, 0x61, 0x63, 0x61, 0x64, 0x65, 0x6d, 0x79, 0x10, 0x08, 0x12, 0x10, 0x0a, 0x0c, 0x68, - 0x65, 0x72, 0x6f, 0x74, 0x65, 0x61, 0x63, 0x68, 0x69, 0x6e, 0x67, 0x10, 0x09, 0x12, 0x0a, 0x0a, - 0x06, 0x63, 0x6f, 0x6d, 0x62, 0x61, 0x74, 0x10, 0x0a, 0x12, 0x0b, 0x0a, 0x07, 0x65, 0x6e, 0x63, - 0x68, 0x61, 0x6e, 0x74, 0x10, 0x0b, 0x12, 0x0b, 0x0a, 0x07, 0x73, 0x6f, 0x63, 0x69, 0x61, 0x74, - 0x79, 0x10, 0x0c, 0x2a, 0x1f, 0x0a, 0x0c, 0x42, 0x42, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x53, 0x74, - 0x61, 0x74, 0x65, 0x12, 0x06, 0x0a, 0x02, 0x69, 0x6e, 0x10, 0x00, 0x12, 0x07, 0x0a, 0x03, 0x65, - 0x6e, 0x64, 0x10, 0x02, 0x2a, 0x2b, 0x0a, 0x0c, 0x44, 0x42, 0x42, 0x61, 0x74, 0x74, 0x6c, 0x65, - 0x43, 0x6f, 0x6d, 0x70, 0x12, 0x08, 0x0a, 0x04, 0x64, 0x72, 0x61, 0x77, 0x10, 0x00, 0x12, 0x07, - 0x0a, 0x03, 0x72, 0x65, 0x64, 0x10, 0x01, 0x12, 0x08, 0x0a, 0x04, 0x62, 0x75, 0x6c, 0x65, 0x10, - 0x02, 0x42, 0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, - 0x33, + 0x69, 0x73, 0x62, 0x6f, 0x6f, 0x73, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06, 0x69, 0x73, + 0x62, 0x6f, 0x6f, 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x6d, 0x6f, 0x6e, 0x73, 0x74, 0x65, 0x72, 0x69, + 0x64, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x05, 0x52, 0x09, 0x6d, 0x6f, 0x6e, 0x73, 0x74, 0x65, 0x72, + 0x69, 0x64, 0x1a, 0x3b, 0x0a, 0x0d, 0x50, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 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, 0x22, + 0x9e, 0x01, 0x0a, 0x0d, 0x44, 0x42, 0x42, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x46, 0x6f, 0x72, 0x6d, + 0x74, 0x12, 0x18, 0x0a, 0x07, 0x6c, 0x65, 0x61, 0x64, 0x70, 0x6f, 0x73, 0x18, 0x01, 0x20, 0x01, + 0x28, 0x05, 0x52, 0x07, 0x6c, 0x65, 0x61, 0x64, 0x70, 0x6f, 0x73, 0x12, 0x1f, 0x0a, 0x04, 0x74, + 0x65, 0x61, 0x6d, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0b, 0x2e, 0x42, 0x61, 0x74, 0x74, + 0x6c, 0x65, 0x52, 0x6f, 0x6c, 0x65, 0x52, 0x04, 0x74, 0x65, 0x61, 0x6d, 0x12, 0x25, 0x0a, 0x07, + 0x73, 0x79, 0x73, 0x74, 0x65, 0x61, 0x6d, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0b, 0x2e, + 0x42, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x52, 0x6f, 0x6c, 0x65, 0x52, 0x07, 0x73, 0x79, 0x73, 0x74, + 0x65, 0x61, 0x6d, 0x12, 0x2b, 0x0a, 0x0a, 0x62, 0x61, 0x63, 0x6b, 0x75, 0x70, 0x74, 0x65, 0x61, + 0x6d, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0b, 0x2e, 0x42, 0x61, 0x74, 0x74, 0x6c, 0x65, + 0x52, 0x6f, 0x6c, 0x65, 0x52, 0x0a, 0x62, 0x61, 0x63, 0x6b, 0x75, 0x70, 0x74, 0x65, 0x61, 0x6d, + 0x22, 0xbd, 0x03, 0x0a, 0x0e, 0x44, 0x42, 0x42, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x52, 0x65, 0x63, + 0x6f, 0x72, 0x64, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x02, 0x69, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x74, 0x69, 0x74, 0x6c, 0x65, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x05, 0x74, 0x69, 0x74, 0x6c, 0x65, 0x12, 0x21, 0x0a, 0x05, 0x62, 0x74, 0x79, + 0x70, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x0b, 0x2e, 0x42, 0x61, 0x74, 0x74, 0x6c, + 0x65, 0x54, 0x79, 0x70, 0x65, 0x52, 0x05, 0x62, 0x74, 0x79, 0x70, 0x65, 0x12, 0x1f, 0x0a, 0x05, + 0x70, 0x74, 0x79, 0x70, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x09, 0x2e, 0x50, 0x6c, + 0x61, 0x79, 0x54, 0x79, 0x70, 0x65, 0x52, 0x05, 0x70, 0x74, 0x79, 0x70, 0x65, 0x12, 0x16, 0x0a, + 0x06, 0x70, 0x6c, 0x65, 0x76, 0x65, 0x6c, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x70, + 0x6c, 0x65, 0x76, 0x65, 0x6c, 0x12, 0x23, 0x0a, 0x05, 0x73, 0x74, 0x61, 0x74, 0x65, 0x18, 0x06, + 0x20, 0x01, 0x28, 0x0e, 0x32, 0x0d, 0x2e, 0x42, 0x42, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x53, 0x74, + 0x61, 0x74, 0x65, 0x52, 0x05, 0x73, 0x74, 0x61, 0x74, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x72, 0x65, + 0x64, 0x43, 0x6f, 0x6d, 0x70, 0x49, 0x64, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x72, + 0x65, 0x64, 0x43, 0x6f, 0x6d, 0x70, 0x49, 0x64, 0x12, 0x2a, 0x0a, 0x08, 0x72, 0x65, 0x64, 0x66, + 0x6c, 0x69, 0x73, 0x74, 0x18, 0x08, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x44, 0x42, 0x42, + 0x61, 0x74, 0x74, 0x6c, 0x65, 0x46, 0x6f, 0x72, 0x6d, 0x74, 0x52, 0x08, 0x72, 0x65, 0x64, 0x66, + 0x6c, 0x69, 0x73, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x62, 0x6c, 0x75, 0x65, 0x43, 0x6f, 0x6d, 0x70, + 0x49, 0x64, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x62, 0x6c, 0x75, 0x65, 0x43, 0x6f, + 0x6d, 0x70, 0x49, 0x64, 0x12, 0x2c, 0x0a, 0x09, 0x62, 0x75, 0x6c, 0x65, 0x66, 0x6c, 0x69, 0x73, + 0x74, 0x18, 0x0a, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x44, 0x42, 0x42, 0x61, 0x74, 0x74, + 0x6c, 0x65, 0x46, 0x6f, 0x72, 0x6d, 0x74, 0x52, 0x09, 0x62, 0x75, 0x6c, 0x65, 0x66, 0x6c, 0x69, + 0x73, 0x74, 0x12, 0x2f, 0x0a, 0x0b, 0x72, 0x6f, 0x75, 0x6e, 0x64, 0x72, 0x65, 0x73, 0x75, 0x6c, + 0x74, 0x18, 0x0b, 0x20, 0x03, 0x28, 0x0e, 0x32, 0x0d, 0x2e, 0x44, 0x42, 0x42, 0x61, 0x74, 0x74, + 0x6c, 0x65, 0x43, 0x6f, 0x6d, 0x70, 0x52, 0x0b, 0x72, 0x6f, 0x75, 0x6e, 0x64, 0x72, 0x65, 0x73, + 0x75, 0x6c, 0x74, 0x12, 0x25, 0x0a, 0x06, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x18, 0x0c, 0x20, + 0x01, 0x28, 0x0e, 0x32, 0x0d, 0x2e, 0x44, 0x42, 0x42, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x43, 0x6f, + 0x6d, 0x70, 0x52, 0x06, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x74, 0x61, + 0x73, 0x6b, 0x73, 0x18, 0x0d, 0x20, 0x03, 0x28, 0x05, 0x52, 0x05, 0x74, 0x61, 0x73, 0x6b, 0x73, + 0x2a, 0x39, 0x0a, 0x0a, 0x42, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x54, 0x79, 0x70, 0x65, 0x12, 0x07, + 0x0a, 0x03, 0x6e, 0x69, 0x6c, 0x10, 0x00, 0x12, 0x07, 0x0a, 0x03, 0x70, 0x76, 0x65, 0x10, 0x01, + 0x12, 0x07, 0x0a, 0x03, 0x70, 0x76, 0x70, 0x10, 0x02, 0x12, 0x07, 0x0a, 0x03, 0x70, 0x76, 0x62, + 0x10, 0x03, 0x12, 0x07, 0x0a, 0x03, 0x65, 0x76, 0x65, 0x10, 0x04, 0x2a, 0xb3, 0x01, 0x0a, 0x08, + 0x50, 0x6c, 0x61, 0x79, 0x54, 0x79, 0x70, 0x65, 0x12, 0x08, 0x0a, 0x04, 0x6e, 0x75, 0x6c, 0x6c, + 0x10, 0x00, 0x12, 0x0c, 0x0a, 0x08, 0x6d, 0x61, 0x69, 0x6e, 0x6c, 0x69, 0x6e, 0x65, 0x10, 0x01, + 0x12, 0x0a, 0x0a, 0x06, 0x70, 0x61, 0x67, 0x6f, 0x64, 0x61, 0x10, 0x02, 0x12, 0x09, 0x0a, 0x05, + 0x72, 0x74, 0x61, 0x73, 0x6b, 0x10, 0x03, 0x12, 0x0b, 0x0a, 0x07, 0x68, 0x75, 0x6e, 0x74, 0x69, + 0x6e, 0x67, 0x10, 0x04, 0x12, 0x0a, 0x0a, 0x06, 0x76, 0x69, 0x6b, 0x69, 0x6e, 0x67, 0x10, 0x05, + 0x12, 0x0f, 0x0a, 0x0b, 0x6d, 0x6f, 0x6f, 0x6e, 0x66, 0x61, 0x6e, 0x74, 0x61, 0x73, 0x79, 0x10, + 0x06, 0x12, 0x09, 0x0a, 0x05, 0x61, 0x72, 0x65, 0x6e, 0x61, 0x10, 0x07, 0x12, 0x0b, 0x0a, 0x07, + 0x61, 0x63, 0x61, 0x64, 0x65, 0x6d, 0x79, 0x10, 0x08, 0x12, 0x10, 0x0a, 0x0c, 0x68, 0x65, 0x72, + 0x6f, 0x74, 0x65, 0x61, 0x63, 0x68, 0x69, 0x6e, 0x67, 0x10, 0x09, 0x12, 0x0a, 0x0a, 0x06, 0x63, + 0x6f, 0x6d, 0x62, 0x61, 0x74, 0x10, 0x0a, 0x12, 0x0b, 0x0a, 0x07, 0x65, 0x6e, 0x63, 0x68, 0x61, + 0x6e, 0x74, 0x10, 0x0b, 0x12, 0x0b, 0x0a, 0x07, 0x73, 0x6f, 0x63, 0x69, 0x61, 0x74, 0x79, 0x10, + 0x0c, 0x2a, 0x1f, 0x0a, 0x0c, 0x42, 0x42, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, + 0x65, 0x12, 0x06, 0x0a, 0x02, 0x69, 0x6e, 0x10, 0x00, 0x12, 0x07, 0x0a, 0x03, 0x65, 0x6e, 0x64, + 0x10, 0x02, 0x2a, 0x2b, 0x0a, 0x0c, 0x44, 0x42, 0x42, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x43, 0x6f, + 0x6d, 0x70, 0x12, 0x08, 0x0a, 0x04, 0x64, 0x72, 0x61, 0x77, 0x10, 0x00, 0x12, 0x07, 0x0a, 0x03, + 0x72, 0x65, 0x64, 0x10, 0x01, 0x12, 0x08, 0x0a, 0x04, 0x62, 0x75, 0x6c, 0x65, 0x10, 0x02, 0x42, + 0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( From 4a3296a4db9c1ecadb8eb0063896ded69a638693 Mon Sep 17 00:00:00 2001 From: meixiongfeng <766881921@qq.com> Date: Wed, 1 Feb 2023 16:23:06 +0800 Subject: [PATCH 09/17] =?UTF-8?q?=E5=A4=9A=E4=BD=99=E8=8B=B1=E9=9B=84?= =?UTF-8?q?=E8=BD=AC=E7=A2=8E=E7=89=87=E5=A4=84=E7=90=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- bin/json/game_hero.json | 1952 ++++++++++++++++++++++-- bin/json/game_item.json | 44 + modules/hero/model_hero.go | 92 +- modules/hero/module.go | 2 +- sys/configure/structs/game.heroData.go | 30 + 5 files changed, 1975 insertions(+), 145 deletions(-) diff --git a/bin/json/game_hero.json b/bin/json/game_hero.json index 4c96cbc7b..03f901633 100644 --- a/bin/json/game_hero.json +++ b/bin/json/game_hero.json @@ -58,7 +58,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "13002", @@ -119,7 +133,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "13003", @@ -180,7 +208,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "13004", @@ -241,7 +283,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "13005", @@ -302,7 +358,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "14001", @@ -363,7 +433,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "14002", @@ -424,7 +508,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "14003", @@ -485,7 +583,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "14004", @@ -546,7 +658,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "14005", @@ -607,7 +733,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "14006", @@ -668,7 +808,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "14007", @@ -729,7 +883,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "15001", @@ -790,7 +958,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "15002", @@ -851,7 +1033,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "15003", @@ -912,7 +1108,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "15004", @@ -973,7 +1183,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "23001", @@ -1034,7 +1258,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "23002", @@ -1095,7 +1333,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "23003", @@ -1156,7 +1408,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "23004", @@ -1217,7 +1483,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "24001", @@ -1278,7 +1558,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "24002", @@ -1339,7 +1633,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "24003", @@ -1400,7 +1708,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "24004", @@ -1461,7 +1783,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "24005", @@ -1522,7 +1858,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "24006", @@ -1583,7 +1933,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "24007", @@ -1644,7 +2008,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "24008", @@ -1705,7 +2083,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "24009", @@ -1766,7 +2158,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "25001", @@ -1827,7 +2233,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "25002", @@ -1888,7 +2308,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "25003", @@ -1949,7 +2383,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "25004", @@ -2010,7 +2458,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "33001", @@ -2071,7 +2533,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "33002", @@ -2132,7 +2608,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "33003", @@ -2193,7 +2683,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "33004", @@ -2254,7 +2758,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "33005", @@ -2315,7 +2833,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "33006", @@ -2376,7 +2908,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "34001", @@ -2437,7 +2983,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "34002", @@ -2498,7 +3058,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "34003", @@ -2559,7 +3133,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "34004", @@ -2620,7 +3208,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "34005", @@ -2681,7 +3283,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "34006", @@ -2742,7 +3358,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "34007", @@ -2803,7 +3433,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "34008", @@ -2864,7 +3508,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "35001", @@ -2925,7 +3583,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "35002", @@ -2986,7 +3658,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "35003", @@ -3047,7 +3733,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "35004", @@ -3108,7 +3808,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "35005", @@ -3169,7 +3883,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "35006", @@ -3230,7 +3958,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "43001", @@ -3291,7 +4033,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "43002", @@ -3352,7 +4108,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "43003", @@ -3413,7 +4183,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "43004", @@ -3474,7 +4258,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "43005", @@ -3535,7 +4333,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "43006", @@ -3596,7 +4408,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "43007", @@ -3657,7 +4483,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "44001", @@ -3718,7 +4558,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "44002", @@ -3779,7 +4633,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "44003", @@ -3840,7 +4708,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "44004", @@ -3901,7 +4783,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "44006", @@ -3962,7 +4858,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "45001", @@ -4023,7 +4933,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "45002", @@ -4084,7 +5008,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "45003", @@ -4145,7 +5083,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "45004", @@ -4206,7 +5158,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "44005", @@ -4267,7 +5233,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "15005", @@ -4328,7 +5308,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "43901", @@ -4389,7 +5383,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "43902", @@ -4450,7 +5458,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "43903", @@ -4511,7 +5533,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "42911", @@ -4572,7 +5608,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "43911", @@ -4633,7 +5683,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "44911", @@ -4694,7 +5758,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "43921", @@ -4755,7 +5833,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "44921", @@ -4816,7 +5908,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "45921", @@ -4877,7 +5983,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "51001", @@ -4938,7 +6058,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "51002", @@ -4999,7 +6133,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "51003", @@ -5060,7 +6208,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "51004", @@ -5121,7 +6283,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "51005", @@ -5182,7 +6358,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "51006", @@ -5243,7 +6433,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "51007", @@ -5304,7 +6508,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "54005", @@ -5365,7 +6583,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "51010", @@ -5426,7 +6658,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "51011", @@ -5487,7 +6733,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "51012", @@ -5548,7 +6808,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "51013", @@ -5609,7 +6883,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "51014", @@ -5670,7 +6958,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "54001", @@ -5731,7 +7033,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "53001", @@ -5792,7 +7108,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "53002", @@ -5853,7 +7183,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "53003", @@ -5914,7 +7258,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "54002", @@ -5975,7 +7333,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "53005", @@ -6036,7 +7408,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "53006", @@ -6097,7 +7483,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "55001", @@ -6158,7 +7558,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "55002", @@ -6219,7 +7633,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "55003", @@ -6280,7 +7708,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "55004", @@ -6341,7 +7783,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "55005", @@ -6402,7 +7858,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "55006", @@ -6463,7 +7933,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "55007", @@ -6524,7 +8008,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "11021", @@ -6585,7 +8083,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "12003", @@ -6648,7 +8160,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "63002", @@ -6709,7 +8235,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "63003", @@ -6770,7 +8310,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "63004", @@ -6831,7 +8385,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "64003", @@ -6892,7 +8460,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "74002", @@ -6953,7 +8535,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "74003", @@ -7014,7 +8610,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "74004", @@ -7075,7 +8685,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "83002", @@ -7136,7 +8760,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "83006", @@ -7197,7 +8835,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "84002", @@ -7258,7 +8910,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "94002", @@ -7319,7 +8985,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "94005", @@ -7380,7 +9060,21 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] }, { "hid": "101004", @@ -7441,6 +9135,20 @@ ], "angle": 0, "deviation": 0, - "show": 1 + "show": 1, + "herofrag": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ], + "heroskillup": [ + { + "a": "item", + "t": "625001", + "n": 1 + } + ] } ] \ No newline at end of file diff --git a/bin/json/game_item.json b/bin/json/game_item.json index 52886d0d3..96fdb73b1 100644 --- a/bin/json/game_item.json +++ b/bin/json/game_item.json @@ -6332,5 +6332,49 @@ "key": "itemtipstxt_10017", "text": "体力药剂不足" } + }, + { + "id": "625001", + "name": { + "key": "itemname_90001", + "text": "阿宝碎片" + }, + "usetype": 3, + "color": 5, + "bagtype": 1, + "index": 99, + "special_type": 0, + "time": 0, + "effects": "effect_ui_wuping_2", + "box_id": 0, + "synthetize_num": 0, + "access": [ + 155 + ], + "use_skip": 155, + "upper_limit": 999, + "uselv": 0, + "isani": 0, + "star": 0, + "race": 0, + "img": "ytx_js_25001", + "ico": "ytx_js_25001", + "intr": { + "key": "itemdesc_625001", + "text": "阿宝天赋点" + }, + "sale": [ + { + "a": "attr", + "t": "gold", + "n": 1000 + } + ], + "synthetize_deplete": [], + "decompose_deplete": [], + "tipstxt": { + "key": "itemtipstxt_625001", + "text": "阿宝的天赋点不足" + } } ] \ No newline at end of file diff --git a/modules/hero/model_hero.go b/modules/hero/model_hero.go index c1508f357..682f8d478 100644 --- a/modules/hero/model_hero.go +++ b/modules/hero/model_hero.go @@ -135,7 +135,7 @@ func (this *ModelHero) initHeroOverlying(uid string, heroCfgId string, count int ) hero = this.InitHero(uid, heroCfgId) if hero != nil { - hero.SameCount = count + hero.SameCount = 1 // 新需求 不需要判断叠加 if this.moduleHero.IsCross() { if model, err = this.moduleHero.GetDBModuleByUid(uid, this.TableName, this.Expired); err != nil { this.moduleHero.Errorln(err) @@ -171,35 +171,38 @@ func (this *ModelHero) createHeroOverlying(uid string, heroCfgId string, count i this.moduleHero.Errorf("err:%v", err) } } + for _, obj := range heros { + if obj.HeroID == heroCfgId { // z + return + } + } + for _, h := range heros { + if h.HeroID == heroCfgId && + h.IsOverlying { + h.SameCount += count + data := map[string]interface{}{ + "sameCount": h.SameCount, //叠加数 + } + hero = h - if len(heros) >= 0 { - for _, h := range heros { - if h.HeroID == heroCfgId && - h.IsOverlying { - h.SameCount += count - data := map[string]interface{}{ - "sameCount": h.SameCount, //叠加数 - } - hero = h - - if this.moduleHero.IsCross() { - if model, err := this.moduleHero.GetDBModuleByUid(uid, this.TableName, this.Expired); err != nil { - this.moduleHero.Errorln(err) - } else { - if err := model.ChangeList(uid, h.Id, data); err != nil { - return nil, err - } - } + if this.moduleHero.IsCross() { + if model, err := this.moduleHero.GetDBModuleByUid(uid, this.TableName, this.Expired); err != nil { + this.moduleHero.Errorln(err) } else { - if err := this.ChangeList(uid, h.Id, data); err != nil { + if err := model.ChangeList(uid, h.Id, data); err != nil { return nil, err } } - - return + } else { + if err := this.ChangeList(uid, h.Id, data); err != nil { + return nil, err + } } + + return } } + return this.initHeroOverlying(uid, heroCfgId, count) } @@ -881,3 +884,48 @@ func (this *ModelHero) resetTalentProperty(hero *pb.DBHero) { } } + +// 创建一条英雄信息,如果有这个英雄 则转换成对应的碎片 +func (this *ModelHero) createHero(session comm.IUserSession, heroCfgId string, count int32) (hero *pb.DBHero, err error) { + heros := make([]*pb.DBHero, 0) + uid := session.GetUserId() + bNew := false // 新活得的英雄 + if this.moduleHero.IsCross() { + if dbModel, err := this.moduleHero.GetDBModuleByUid(uid, this.TableName, this.Expired); err != nil { + this.moduleHero.Errorln(err) + + } else { + if err = dbModel.GetList(uid, &heros); err != nil { + this.moduleHero.Errorf("err:%v", err) + } + } + } else { + if err = this.GetList(uid, &heros); err != nil { + this.moduleHero.Errorf("err:%v", err) + } + } + for _, obj := range heros { + if obj.HeroID == heroCfgId { // z + bNew = true + break + } + } + if !bNew { // 没有当前英雄 + count -= 1 + hero, err = this.initHeroOverlying(uid, heroCfgId, 1) + } + + // 转碎片处理 + if count > 0 { + heroCfg := this.moduleHero.configure.GetHeroConfig(heroCfgId) + if heroCfg != nil { + res := make([]*cfg.Gameatn, 0) + for i := 0; i < int(count); i++ { + res = append(res, heroCfg.Herofrag...) + } + this.moduleHero.DispenseRes(session, res, true) + } + } + + return +} diff --git a/modules/hero/module.go b/modules/hero/module.go index faf671c6b..a1ea27bb4 100644 --- a/modules/hero/module.go +++ b/modules/hero/module.go @@ -78,7 +78,7 @@ func (this *Hero) Start() (err error) { //创建单个叠加英雄 func (this *Hero) createRepeatHero(session comm.IUserSession, heroCfgId string, num int32) (hero *pb.DBHero, code pb.ErrorCode) { var err error - hero, err = this.modelHero.createHeroOverlying(session.GetUserId(), heroCfgId, num) + hero, err = this.modelHero.createHero(session, heroCfgId, num) if err == nil { //go func(uid string, heroCfgId string) { // 携程处理 图鉴数据 if db.IsCross() { diff --git a/sys/configure/structs/game.heroData.go b/sys/configure/structs/game.heroData.go index 9f5b847df..5f048a86a 100644 --- a/sys/configure/structs/game.heroData.go +++ b/sys/configure/structs/game.heroData.go @@ -43,6 +43,8 @@ type GameHeroData struct { Angle int32 Deviation int32 Show int32 + Herofrag []*Gameatn + Heroskillup []*Gameatn } const TypeId_GameHeroData = 1513828672 @@ -129,6 +131,34 @@ func (_v *GameHeroData)Deserialize(_buf map[string]interface{}) (err error) { { var _ok_ bool; var _tempNum_ float64; if _tempNum_, _ok_ = _buf["angle"].(float64); !_ok_ { err = errors.New("angle error"); return }; _v.Angle = int32(_tempNum_) } { var _ok_ bool; var _tempNum_ float64; if _tempNum_, _ok_ = _buf["deviation"].(float64); !_ok_ { err = errors.New("deviation error"); return }; _v.Deviation = int32(_tempNum_) } { var _ok_ bool; var _tempNum_ float64; if _tempNum_, _ok_ = _buf["show"].(float64); !_ok_ { err = errors.New("show error"); return }; _v.Show = int32(_tempNum_) } + { + var _arr_ []interface{} + var _ok_ bool + if _arr_, _ok_ = _buf["herofrag"].([]interface{}); !_ok_ { err = errors.New("herofrag error"); return } + + _v.Herofrag = make([]*Gameatn, 0, len(_arr_)) + + for _, _e_ := range _arr_ { + var _list_v_ *Gameatn + { var _ok_ bool; var _x_ map[string]interface{}; if _x_, _ok_ = _e_.(map[string]interface{}); !_ok_ { err = errors.New("_list_v_ error"); return }; if _list_v_, err = DeserializeGameatn(_x_); err != nil { return } } + _v.Herofrag = append(_v.Herofrag, _list_v_) + } + } + + { + var _arr_ []interface{} + var _ok_ bool + if _arr_, _ok_ = _buf["heroskillup"].([]interface{}); !_ok_ { err = errors.New("heroskillup error"); return } + + _v.Heroskillup = make([]*Gameatn, 0, len(_arr_)) + + for _, _e_ := range _arr_ { + var _list_v_ *Gameatn + { var _ok_ bool; var _x_ map[string]interface{}; if _x_, _ok_ = _e_.(map[string]interface{}); !_ok_ { err = errors.New("_list_v_ error"); return }; if _list_v_, err = DeserializeGameatn(_x_); err != nil { return } } + _v.Heroskillup = append(_v.Heroskillup, _list_v_) + } + } + return } From 4f6aafdcde45f57bdce6191de9c91cd27e9c529d Mon Sep 17 00:00:00 2001 From: meixiongfeng <766881921@qq.com> Date: Wed, 1 Feb 2023 17:04:27 +0800 Subject: [PATCH 10/17] =?UTF-8?q?=E8=8B=B1=E9=9B=84=E8=BD=AC=E6=8D=A2?= =?UTF-8?q?=E7=A2=8E=E7=89=87?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- comm/const.go | 4 ++++ modules/hero/model_hero.go | 13 ++++++++----- modules/hero/module.go | 11 +++++++---- 3 files changed, 19 insertions(+), 9 deletions(-) diff --git a/comm/const.go b/comm/const.go index 5ba030703..5a9efeef1 100644 --- a/comm/const.go +++ b/comm/const.go @@ -561,6 +561,10 @@ const ( Rtype155 TaskType = 155 //调整助战英雄n次 Rtype156 TaskType = 156 //完成工会任务n次 Rtype157 TaskType = 157 //战斗在xx系统中完成xx事件 + Rtype158 TaskType = 158 //主线第X章关卡总星数达到N星 + Rtype159 TaskType = 159 //主线第X章关卡全部达到三星 + Rtype160 TaskType = 160 //主线总星数达到X星 + Rtype161 TaskType = 161 //在自动战斗过程中完成另一场战斗 ) const ( diff --git a/modules/hero/model_hero.go b/modules/hero/model_hero.go index 682f8d478..6ab0b28eb 100644 --- a/modules/hero/model_hero.go +++ b/modules/hero/model_hero.go @@ -886,10 +886,9 @@ func (this *ModelHero) resetTalentProperty(hero *pb.DBHero) { } // 创建一条英雄信息,如果有这个英雄 则转换成对应的碎片 -func (this *ModelHero) createHero(session comm.IUserSession, heroCfgId string, count int32) (hero *pb.DBHero, err error) { +func (this *ModelHero) createHero(session comm.IUserSession, heroCfgId string, count int32) (hero *pb.DBHero, bFirst bool, err error) { heros := make([]*pb.DBHero, 0) uid := session.GetUserId() - bNew := false // 新活得的英雄 if this.moduleHero.IsCross() { if dbModel, err := this.moduleHero.GetDBModuleByUid(uid, this.TableName, this.Expired); err != nil { this.moduleHero.Errorln(err) @@ -905,14 +904,18 @@ func (this *ModelHero) createHero(session comm.IUserSession, heroCfgId string, c } } for _, obj := range heros { - if obj.HeroID == heroCfgId { // z - bNew = true + if obj.HeroID == heroCfgId { + hero = obj + bFirst = false break } } - if !bNew { // 没有当前英雄 + if hero != nil { // 没有当前英雄 count -= 1 hero, err = this.initHeroOverlying(uid, heroCfgId, 1) + if err != nil { + return + } } // 转碎片处理 diff --git a/modules/hero/module.go b/modules/hero/module.go index a1ea27bb4..9c977d6b3 100644 --- a/modules/hero/module.go +++ b/modules/hero/module.go @@ -77,9 +77,12 @@ func (this *Hero) Start() (err error) { //创建单个叠加英雄 func (this *Hero) createRepeatHero(session comm.IUserSession, heroCfgId string, num int32) (hero *pb.DBHero, code pb.ErrorCode) { - var err error - hero, err = this.modelHero.createHero(session, heroCfgId, num) - if err == nil { + var ( + err error + bFirst bool + ) + hero, bFirst, err = this.modelHero.createHero(session, heroCfgId, num) + if err == nil && bFirst { //go func(uid string, heroCfgId string) { // 携程处理 图鉴数据 if db.IsCross() { this.moduleFetter.SendRpcAddHero(session, heroCfgId) @@ -295,9 +298,9 @@ func (this *Hero) CreateRepeatHeros(session comm.IUserSession, heros map[string] this.ModuleUser.ChangeUserExpand(session.GetUserId(), initUpdate) firstGet = append(firstGet, heroCfgId) } + changeList = append(changeList, hero) } } - changeList = append(changeList, hero) } if bPush && len(changeList) > 0 { //推送 From 949037c4b948f8ad143a11226dd75d73c07f2f13 Mon Sep 17 00:00:00 2001 From: meixiongfeng <766881921@qq.com> Date: Wed, 1 Feb 2023 18:26:47 +0800 Subject: [PATCH 11/17] =?UTF-8?q?=E4=B8=8D=E5=86=8D=E5=86=99=E5=9B=BE?= =?UTF-8?q?=E9=89=B4=E6=95=B0=E6=8D=AE,=E5=8F=AF=E9=80=9A=E8=BF=87?= =?UTF-8?q?=E8=8B=B1=E9=9B=84=E5=88=97=E8=A1=A8=E6=95=B0=E6=8D=AE=E8=8E=B7?= =?UTF-8?q?=E5=8F=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- modules/hero/model_hero.go | 3 ++- modules/hero/module.go | 53 ++++++++++++++------------------------ 2 files changed, 21 insertions(+), 35 deletions(-) diff --git a/modules/hero/model_hero.go b/modules/hero/model_hero.go index 6ab0b28eb..f7b999c1c 100644 --- a/modules/hero/model_hero.go +++ b/modules/hero/model_hero.go @@ -903,6 +903,7 @@ func (this *ModelHero) createHero(session comm.IUserSession, heroCfgId string, c this.moduleHero.Errorf("err:%v", err) } } + bFirst = true for _, obj := range heros { if obj.HeroID == heroCfgId { hero = obj @@ -910,7 +911,7 @@ func (this *ModelHero) createHero(session comm.IUserSession, heroCfgId string, c break } } - if hero != nil { // 没有当前英雄 + if bFirst { // 没有当前英雄 count -= 1 hero, err = this.initHeroOverlying(uid, heroCfgId, 1) if err != nil { diff --git a/modules/hero/module.go b/modules/hero/module.go index 9c977d6b3..3c3d5826b 100644 --- a/modules/hero/module.go +++ b/modules/hero/module.go @@ -76,10 +76,9 @@ func (this *Hero) Start() (err error) { } //创建单个叠加英雄 -func (this *Hero) createRepeatHero(session comm.IUserSession, heroCfgId string, num int32) (hero *pb.DBHero, code pb.ErrorCode) { +func (this *Hero) createRepeatHero(session comm.IUserSession, heroCfgId string, num int32) (hero *pb.DBHero, bFirst bool, code pb.ErrorCode) { var ( - err error - bFirst bool + err error ) hero, bFirst, err = this.modelHero.createHero(session, heroCfgId, num) if err == nil && bFirst { @@ -270,47 +269,33 @@ func (this *Hero) CreateRepeatHeros(session comm.IUserSession, heros map[string] var ( changeList []*pb.DBHero firstGet []string + bFirst bool ) for heroCfgId, num := range heros { if num == 0 { // 数量为0 不做处理 continue } - if hero, code = this.createRepeatHero(session, heroCfgId, num); code != pb.ErrorCode_Success { + if hero, bFirst, code = this.createRepeatHero(session, heroCfgId, num); code != pb.ErrorCode_Success { this.Errorf("create hero %s failed", heroCfgId) - return + continue } - if result, err1 := this.ModuleUser.GetUserExpand(session.GetUserId()); err1 == nil { - initUpdate := map[string]interface{}{} - sz := result.GetTujian() - if len(sz) == 0 { - sz = make(map[string]int32, 0) - } - - if _, ok := result.GetTujian()[heroCfgId]; !ok { - heroConf := this.modelHero.moduleHero.configure.GetHeroConfig(heroCfgId) - if heroConf != nil { - if heroConf.Handbook == -1 { - sz[heroCfgId] = 0 - } else { - sz[heroCfgId] = 1 - } - initUpdate["tujian"] = sz - this.ModuleUser.ChangeUserExpand(session.GetUserId(), initUpdate) - firstGet = append(firstGet, heroCfgId) - } - changeList = append(changeList, hero) - } + if bFirst { + firstGet = append(firstGet, heroCfgId) + changeList = append(changeList, hero) } } - if bPush && len(changeList) > 0 { //推送 - session.SendMsg("hero", "change", &pb.HeroChangePush{List: changeList}) - } - // 首次获得英雄 则推送 - if len(firstGet) > 0 { - session.SendMsg("hero", "firstget", &pb.HeroFirstGetPush{ - HeroId: firstGet, - }) + if bPush { //推送 + if len(changeList) > 0 { + session.SendMsg("hero", "change", &pb.HeroChangePush{List: changeList}) + } + + // 首次获得英雄 则推送 + if len(firstGet) > 0 { + session.SendMsg("hero", "firstget", &pb.HeroFirstGetPush{ + HeroId: firstGet, + }) + } } return From e8a82df85d93c6f391a2bcd75c3dc6b75729c0fd Mon Sep 17 00:00:00 2001 From: wh_zcy Date: Wed, 1 Feb 2023 18:40:24 +0800 Subject: [PATCH 12/17] =?UTF-8?q?=E6=9C=8D=E5=8A=A1=E5=88=97=E8=A1=A8?= =?UTF-8?q?=E9=85=8D=E7=BD=AE=E5=B7=A5=E5=85=B7?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- cmd/v2/FyneApp.toml | 4 +- cmd/v2/lib/common/lang.go | 1 + cmd/v2/lib/storage/config.go | 33 +++-- cmd/v2/ui/app_interface.go | 1 + cmd/v2/ui/tool_mgo.go | 246 +++++++++++++++++++++++++++++++++++ cmd/v2/ui/toolwindow.go | 3 + go.mod | 12 +- go.sum | 33 ----- 8 files changed, 277 insertions(+), 56 deletions(-) create mode 100644 cmd/v2/ui/tool_mgo.go diff --git a/cmd/v2/FyneApp.toml b/cmd/v2/FyneApp.toml index c552525f7..7add2c04c 100644 --- a/cmd/v2/FyneApp.toml +++ b/cmd/v2/FyneApp.toml @@ -4,5 +4,5 @@ Website = "http://legu.cc" Icon = "app.png" Name = "RobotGUI" ID = "cc.legu.app" - Version = "1.2.7" - Build = 37 + Version = "1.2.8" + Build = 38 diff --git a/cmd/v2/lib/common/lang.go b/cmd/v2/lib/common/lang.go index 865c2b1d6..7751e24e1 100644 --- a/cmd/v2/lib/common/lang.go +++ b/cmd/v2/lib/common/lang.go @@ -97,6 +97,7 @@ const ( TOOLBAR_PB = "protobuf" TOOLBAR_AUTO = "自动化" TOOLBAR_PING = "端口扫描" + TOOLBAR_MGODB = "MongoDB" TOOLBAR_PERF_TIP = "开始" TOOLBAR_PERF_CONF = "配置" diff --git a/cmd/v2/lib/storage/config.go b/cmd/v2/lib/storage/config.go index e5e1f6788..b36b86507 100644 --- a/cmd/v2/lib/storage/config.go +++ b/cmd/v2/lib/storage/config.go @@ -1,5 +1,7 @@ package storage +import "go_dreamfactory/pb" + //默认配置 func NewDefaultConfig() *Config { return &Config{ @@ -26,16 +28,27 @@ func NewDefaultConfig() *Config { } type Config struct { - Pressure PressureConfig `json:"Pressure,omitempty"` - UserCount int32 `json:"UserCount,omitempty"` //用户数 - SId string `json:"sid,omitempty"` //区服ID - WsAddr string `json:"wsAddr,omitempty"` //websocket addr - IntervalS int32 `json:"intervalS,omitempty"` //间隔时间s - LubanConf *LubanConfig `json:"lubanConf,omitempty"` //luban工具配置 - PbConf *ProtobufConfig `json:"pbConf,omitempty"` //Pb配置 - SyncConf *SyncConfig `json:"syncConf,omitempty"` //同步配置 - UpgradeUrl string `json:"upgradeUrl,omitempty"` //升级服务 - Servers []*ServerConfig `json:"servers,omitempty"` //区服配置 + Pressure PressureConfig `json:"Pressure,omitempty"` + UserCount int32 `json:"UserCount,omitempty"` //用户数 + SId string `json:"sid,omitempty"` //区服ID + WsAddr string `json:"wsAddr,omitempty"` //websocket addr + IntervalS int32 `json:"intervalS,omitempty"` //间隔时间s + LubanConf *LubanConfig `json:"lubanConf,omitempty"` //luban工具配置 + PbConf *ProtobufConfig `json:"pbConf,omitempty"` //Pb配置 + SyncConf *SyncConfig `json:"syncConf,omitempty"` //同步配置 + UpgradeUrl string `json:"upgradeUrl,omitempty"` //升级服务 + Servers []*ServerConfig `json:"servers,omitempty"` //区服配置 + MgoDB *MgoDB `json:"mgoDB,omitempty"` //MongoDB配置 + ServiceDBInfo *pb.ServiceDBInfo `json:"serviceDBInfo,omitempty"` // +} + +type MgoDB struct { + Name string `json:"name,omitempty"` // + Host string `json:"host,omitempty"` + Port int32 `json:"port,omitempty"` + User string `json:"user,omitempty"` + Password string `json:"password,omitempty"` + Database string `json:"database,omitempty"` } //压测配置 diff --git a/cmd/v2/ui/app_interface.go b/cmd/v2/ui/app_interface.go index fa3f39373..e0e3769a1 100644 --- a/cmd/v2/ui/app_interface.go +++ b/cmd/v2/ui/app_interface.go @@ -33,6 +33,7 @@ var ( &appLock{}, &appTerm{}, &appPing{}, + &appMgo{}, } perfRegister = []appInterface{ diff --git a/cmd/v2/ui/tool_mgo.go b/cmd/v2/ui/tool_mgo.go new file mode 100644 index 000000000..4a30fc8c5 --- /dev/null +++ b/cmd/v2/ui/tool_mgo.go @@ -0,0 +1,246 @@ +package ui + +import ( + "context" + "errors" + "fmt" + "go_dreamfactory/cmd/v2/lib/common" + os_storage "go_dreamfactory/cmd/v2/lib/storage" + "go_dreamfactory/cmd/v2/service" + "go_dreamfactory/cmd/v2/service/observer" + "go_dreamfactory/pb" + "strings" + + "fyne.io/fyne/v2" + "fyne.io/fyne/v2/container" + "fyne.io/fyne/v2/dialog" + "fyne.io/fyne/v2/layout" + "fyne.io/fyne/v2/theme" + "fyne.io/fyne/v2/widget" + "github.com/sirupsen/logrus" + "github.com/spf13/cast" + + "go.mongodb.org/mongo-driver/mongo" + "go.mongodb.org/mongo-driver/mongo/options" +) + +type appMgo struct { + appAdapter + conf *os_storage.Config + storage os_storage.Storage + db *mongo.Database + client *mongo.Client + scriptEntry *widget.Entry +} + +func (this *appMgo) LazyInit(ptService service.PttService, obs observer.Observer) error { + this.tabItem = container.NewTabItemWithIcon(common.TOOLBAR_MGODB, theme.DownloadIcon(), nil) + content := container.NewMax() + content.Objects = []fyne.CanvasObject{} + + this.scriptEntry = widget.NewMultiLineEntry() + + connWinBtn := widget.NewButton("连接设置", this.showConWin) + openConnBtn := widget.NewButton("打开连接", this.openConn) + closeConnBtn := widget.NewButton("关闭连接", this.closeConn) + createServerConfBtn := widget.NewButton("创建服务配置", this.createServerConf) + btns := container.NewHBox(connWinBtn, openConnBtn, createServerConfBtn, layout.NewSpacer(), closeConnBtn) + content.Objects = append(content.Objects, container.NewBorder(btns, nil, nil, nil, this.scriptEntry)) + this.tabItem.Content = content + this.storage, _ = os_storage.NewOSStorage() + var err error + this.conf, err = this.storage.LoadConfig() + if err != nil { + logrus.Error(err) + return err + } + return nil +} + +func (this *appMgo) openConn() { + if this.conf.MgoDB == nil { + dialog.ShowError(errors.New("MgoDB没有配置"), toolWin.w) + return + } + var option *options.ClientOptions + if (this.conf.MgoDB.User == "" && this.conf.MgoDB.Password == "") && + this.conf.MgoDB.Host != "" && this.conf.MgoDB.Port != 0 && this.conf.MgoDB.Database != "" { + option = options.Client().ApplyURI(fmt.Sprintf("mongodb://%s:%d", this.conf.MgoDB.Host, this.conf.MgoDB.Port)) + } else { + option = options.Client().ApplyURI(fmt.Sprintf("mongodb://%s:%s@%s:%d", this.conf.MgoDB.User, this.conf.MgoDB.Password, + this.conf.MgoDB.Host, this.conf.MgoDB.Port)) + } + client, err := mongo.Connect(context.TODO(), option) + if err != nil { + logrus.Error(err) + return + } + if err2 := client.Ping(context.TODO(), nil); err2 != nil { + logrus.Error("Mongo连接失败", err2) + return + } + this.db = client.Database(this.conf.MgoDB.Database) + + this.scriptEntry.Text = this.db.Name() + " 连接成功" + this.scriptEntry.Refresh() +} + +func (this *appMgo) closeConn() { + if this.db != nil { + if err := this.db.Client().Disconnect(context.TODO()); err != nil { + this.scriptEntry.Text = "连接关闭失败" + } else { + this.scriptEntry.Text = "连接关闭成功" + } + this.scriptEntry.Refresh() + } +} + +func (this *appMgo) createServerConf() { + serverId := widget.NewEntry() + serverName := widget.NewEntry() + owner := widget.NewEntry() + cross := widget.NewEntry() + crossId := widget.NewEntry() + singleserver := widget.NewEntry() + opentime := widget.NewEntry() + redisIsCluster := widget.NewEntry() + redisAddr := widget.NewEntry() + redisPassword := widget.NewEntry() + redisDb := widget.NewEntry() + mongoUrl := widget.NewEntry() + mongoDatabase := widget.NewEntry() + + form := widget.NewForm( + widget.NewFormItem("serverid", serverId), + widget.NewFormItem("serverName", serverName), + widget.NewFormItem("owner", owner), + widget.NewFormItem("cross", cross), + widget.NewFormItem("crossId", crossId), + widget.NewFormItem("singleserver", singleserver), + widget.NewFormItem("opentime", opentime), + widget.NewFormItem("redisIsCluster", redisIsCluster), + widget.NewFormItem("redisAddr", redisAddr), + widget.NewFormItem("redisPassword", redisPassword), + widget.NewFormItem("redisDb", redisDb), + widget.NewFormItem("mongoUrl", mongoUrl), + widget.NewFormItem("mongoDatabase", mongoDatabase), + ) + + if this.conf.ServiceDBInfo != nil { + serverId.Text = this.conf.ServiceDBInfo.Serverid + serverName.Text = this.conf.ServiceDBInfo.ServerName + owner.Text = this.conf.ServiceDBInfo.Owner + cross.Text = this.conf.ServiceDBInfo.Cross + crossId.Text = this.conf.ServiceDBInfo.CrossId + singleserver.Text = this.conf.ServiceDBInfo.Singleserver + opentime.Text = cast.ToString(this.conf.ServiceDBInfo.Opentime) + redisIsCluster.Text = cast.ToString(this.conf.ServiceDBInfo.RedisIsCluster) + redisAddr.Text = strings.Join(this.conf.ServiceDBInfo.RedisAddr, ",") + redisPassword.Text = this.conf.ServiceDBInfo.RedisPassword + redisDb.Text = cast.ToString(this.conf.ServiceDBInfo.RedisDb) + mongoUrl.Text = this.conf.ServiceDBInfo.MongodbUrl + mongoDatabase.Text = this.conf.ServiceDBInfo.MongodbDatabase + } + + subBtn := widget.NewButton("保存", func() { + this.conf.ServiceDBInfo = &pb.ServiceDBInfo{ + Serverid: serverId.Text, + ServerName: serverName.Text, + Owner: owner.Text, + Cross: cross.Text, + CrossId: crossId.Text, + Singleserver: singleserver.Text, + Opentime: cast.ToInt64(opentime.Text), + RedisIsCluster: cast.ToBool(redisIsCluster.Text), + RedisAddr: strings.Split(redisAddr.Text, ","), + RedisPassword: redisPassword.Text, + RedisDb: cast.ToInt32(redisDb.Text), + MongodbUrl: mongoUrl.Text, + MongodbDatabase: mongoDatabase.Text, + } + if err := this.storage.StoreConfig(this.conf); err != nil { + logrus.Error(err) + } + }) + subBtn.Importance = widget.HighImportance + + execBtn := widget.NewButton("插入", func() { + if this.db == nil { + common.ShowTip("请先打开连接") + return + } + c := this.db.Collection("serverdata") + if _, err := c.InsertOne(context.TODO(), this.conf.ServiceDBInfo); err != nil { + logrus.Error(err) + return + } + + this.scriptEntry.Text = "插入成功" + this.scriptEntry.Refresh() + }) + dconf := dialog.NewCustom("配置", "关闭", container.NewVBox(form, container.NewHBox(layout.NewSpacer(), subBtn, execBtn)), toolWin.w) + dconf.Resize(fyne.NewSize(400, 600)) + dconf.Show() + +} + +func (this *appMgo) showConWin() { + + connName := widget.NewEntry() + + address := widget.NewEntry() + + port := widget.NewEntry() + + user := widget.NewEntry() + password := widget.NewPasswordEntry() + + database := widget.NewEntry() + + form := widget.NewForm( + widget.NewFormItem("Name", connName), + widget.NewFormItem("Address", container.NewBorder(nil, nil, nil, port, address)), + widget.NewFormItem("User", user), + widget.NewFormItem("Password", password), + widget.NewFormItem("Database", database), + ) + + if this.conf.MgoDB != nil { + connName.Text = this.conf.MgoDB.Name + address.Text = this.conf.MgoDB.Host + port.Text = cast.ToString(this.conf.MgoDB.Port) + user.Text = this.conf.MgoDB.User + password.Text = this.conf.MgoDB.Password + database.Text = this.conf.MgoDB.Database + } + form.OnSubmit = func() { + this.conf.MgoDB = &os_storage.MgoDB{ + Name: connName.Text, + Host: address.Text, + Port: cast.ToInt32(port.Text), + User: user.Text, + Password: password.Text, + Database: database.Text, + } + + if connName.Text == "" || address.Text == "" || port.Text == "" { + common.ShowTip("请填写完整") + return + } + if err := this.storage.StoreConfig(this.conf); err != nil { + logrus.Error(err) + return + } + dialog.ShowInformation("提示", "保存成功", toolWin.w) + } + form.SubmitText = "保存" + + dconf := dialog.NewCustom("设置链接", "关闭", form, toolWin.w) + dconf.Resize(fyne.NewSize(400, 200)) + dconf.Show() +} + +func (a *appMgo) GetAppName() string { + return common.TOOLBAR_MGODB +} diff --git a/cmd/v2/ui/toolwindow.go b/cmd/v2/ui/toolwindow.go index 9abc7ab3e..48bb2d3f7 100644 --- a/cmd/v2/ui/toolwindow.go +++ b/cmd/v2/ui/toolwindow.go @@ -56,6 +56,9 @@ func NewToolWindow(ui *UIImpl, parent fyne.Window) ToolWindow { widget.NewToolbarAction(theme.ComputerIcon(), func() { openApp2(mw.at, common.TOOLBAR_PING) }), + widget.NewToolbarAction(theme.SettingsIcon(), func() { + openApp2(mw.at, common.TOOLBAR_MGODB) + }), widget.NewToolbarSpacer(), widget.NewToolbarAction(theme.HelpIcon(), func() { diff --git a/go.mod b/go.mod index 7be7df068..2b8ace255 100644 --- a/go.mod +++ b/go.mod @@ -9,7 +9,6 @@ require ( github.com/Pallinder/go-randomdata v1.2.0 github.com/atotto/clipboard v0.1.4 github.com/axgle/mahonia v0.0.0-20180208002826-3358181d7394 - github.com/boltdb/bolt v1.3.1 github.com/gin-gonic/gin v1.8.1 github.com/go-playground/validator/v10 v10.10.1 github.com/go-redis/redis/v8 v8.11.5 @@ -30,13 +29,11 @@ require ( github.com/spf13/cast v1.5.0 github.com/spf13/cobra v1.5.0 github.com/spf13/pflag v1.0.5 - github.com/spf13/viper v1.12.0 github.com/tidwall/gjson v1.14.1 github.com/ugorji/go/codec v1.2.7 github.com/valyala/fastrand v1.1.0 go.mongodb.org/mongo-driver v1.5.1 go.uber.org/multierr v1.6.0 - golang.design/x/hotkey v0.4.0 golang.org/x/net v0.2.0 google.golang.org/grpc v1.46.2 google.golang.org/protobuf v1.28.0 @@ -85,7 +82,7 @@ require ( github.com/go-logr/logr v1.2.3 // indirect github.com/go-logr/stdr v1.2.2 // indirect github.com/go-ole/go-ole v1.2.6 // indirect - github.com/go-ping/ping v0.0.0-20211130115550-779d1e919534 // indirect + github.com/go-ping/ping v0.0.0-20211130115550-779d1e919534 github.com/go-playground/locales v0.14.0 // indirect github.com/go-playground/universal-translator v0.18.0 // indirect github.com/go-redis/redis_rate/v9 v9.1.2 // indirect @@ -107,7 +104,6 @@ require ( github.com/hashicorp/go-multierror v1.1.1 // indirect github.com/hashicorp/go-rootcerts v1.0.2 // indirect github.com/hashicorp/golang-lru v0.5.4 // indirect - github.com/hashicorp/hcl v1.0.0 // indirect github.com/hashicorp/serf v0.9.7 // indirect github.com/inconshreveable/mousetrap v1.0.0 // indirect github.com/influxdata/influxdb1-client v0.0.0-20220302092344-a9ab5670611c // indirect @@ -122,7 +118,6 @@ require ( github.com/leodido/go-urn v1.2.1 // indirect github.com/lucas-clemente/quic-go v0.27.0 // indirect github.com/lufia/plan9stats v0.0.0-20211012122336-39d0f177ccd0 // indirect - github.com/magiconair/properties v1.8.6 // indirect github.com/marten-seemann/qtls-go1-16 v0.1.5 // indirect github.com/marten-seemann/qtls-go1-17 v0.1.1 // indirect github.com/marten-seemann/qtls-go1-18 v0.1.1 // indirect @@ -135,7 +130,6 @@ require ( github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect github.com/nxadm/tail v1.4.8 // indirect github.com/onsi/ginkgo v1.16.5 // indirect - github.com/pelletier/go-toml v1.9.5 // indirect github.com/pelletier/go-toml/v2 v2.0.2 // indirect github.com/philhofer/fwd v1.1.1 // indirect github.com/pkg/errors v0.9.1 @@ -150,12 +144,9 @@ require ( github.com/smallnest/quick v0.0.0-20220103065406-780def6371e6 // indirect github.com/smartystreets/goconvey v1.7.2 github.com/soheilhy/cmux v0.1.5 // indirect - github.com/spf13/afero v1.8.2 // indirect - github.com/spf13/jwalterweatherman v1.1.0 // indirect github.com/srwiley/oksvg v0.0.0-20200311192757-870daf9aa564 // indirect github.com/srwiley/rasterx v0.0.0-20200120212402-85cb7272f5e9 // indirect github.com/stretchr/testify v1.8.0 // indirect - github.com/subosito/gotenv v1.4.0 // indirect github.com/templexxx/cpufeat v0.0.0-20180724012125-cef66df7f161 // indirect github.com/templexxx/xor v0.0.0-20191217153810-f85b25db303b // indirect github.com/tevino/abool v1.2.0 // indirect @@ -187,7 +178,6 @@ require ( golang.org/x/sys v0.2.0 // indirect golang.org/x/text v0.4.0 golang.org/x/tools v0.3.0 // indirect - gopkg.in/ini.v1 v1.66.6 // indirect gopkg.in/natefinch/lumberjack.v2 v2.0.0 // indirect gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7 // indirect gopkg.in/yaml.v3 v3.0.1 diff --git a/go.sum b/go.sum index f06e13ad0..f50605580 100644 --- a/go.sum +++ b/go.sum @@ -5,7 +5,6 @@ cloud.google.com/go v0.37.0/go.mod h1:TS1dMSSfndXH133OKGwekG838Om/cQT0BUHV3HcBgo cloud.google.com/go v0.38.0/go.mod h1:990N+gfupTy94rShfmMCWGDn0LpTmnzTp2qbd1dvSRU= cloud.google.com/go v0.44.1/go.mod h1:iSa0KzasP4Uvy3f1mN/7PiObzGgflwredwwASm/v6AU= cloud.google.com/go v0.44.2/go.mod h1:60680Gw3Yr4ikxnPRS/oxxkBccT6SA1yMk63TGekxKY= -cloud.google.com/go v0.44.3/go.mod h1:60680Gw3Yr4ikxnPRS/oxxkBccT6SA1yMk63TGekxKY= cloud.google.com/go v0.45.1/go.mod h1:RpBamKRgapWJb87xiFSdk4g1CME7QZg3uwTez+TSTjc= cloud.google.com/go v0.46.3/go.mod h1:a6bKKbmY7er1mI7TEI4lsAkts/mkhTSZK8w33B4RAg0= cloud.google.com/go v0.50.0/go.mod h1:r9sluTvynVuxRIOHXQEHMFffphuXHOMZMycpNR5e6To= @@ -18,7 +17,6 @@ cloud.google.com/go v0.62.0/go.mod h1:jmCYTdRCQuc1PHIIJ/maLInMho30T/Y0M4hTdTShOY cloud.google.com/go v0.65.0/go.mod h1:O5N8zS7uWy9vkA9vayVHs65eM1ubvY4h553ofrNHObY= cloud.google.com/go v0.72.0/go.mod h1:M+5Vjvlc2wnp6tjzE102Dw08nGShTscUx2nZMufOKPI= cloud.google.com/go v0.74.0/go.mod h1:VV1xSbzvo+9QJOxLDaJfTjx5e+MePCpCWwvftOeQmWk= -cloud.google.com/go v0.75.0/go.mod h1:VGuuCn7PG0dwsd5XPVm2Mm3wlh3EL55/79EKB6hlPTY= cloud.google.com/go v0.78.0/go.mod h1:QjdrLG0uq+YwhjoVOLsS1t7TW8fs36kLs4XO5R5ECHg= cloud.google.com/go v0.79.0/go.mod h1:3bzgcEeQlzbuEAYu4mrWhKqWjmpprinYgKJLgKHnbb8= cloud.google.com/go v0.81.0/go.mod h1:mk/AM35KwGk/Nm2YSeZbxXdrNK3KZOYHmLkOqC2V6E0= @@ -40,7 +38,6 @@ cloud.google.com/go/storage v1.5.0/go.mod h1:tpKbwo567HUNpVclU5sGELwQWBDZ8gh0Zeo cloud.google.com/go/storage v1.6.0/go.mod h1:N7U0C8pVQ/+NIKOBQyamJIeKQKkZ+mxpohlUTyfDhBk= cloud.google.com/go/storage v1.8.0/go.mod h1:Wv1Oy7z6Yz3DshWRJFhqM/UCfaWIRTdp0RXyy7KQOVs= cloud.google.com/go/storage v1.10.0/go.mod h1:FLPqc6j+Ki4BU591ie1oL6qBQGu2Bl/tZ9ullr3+Kg0= -cloud.google.com/go/storage v1.14.0/go.mod h1:GrKmX003DSIwi9o29oFT7YDnHYwZoctc3fOKtUw0Xmo= dmitri.shuralyov.com/app/changes v0.0.0-20180602232624-0a106ad413e3/go.mod h1:Yl+fi1br7+Rr3LqpNJf1/uxUdtRUV+Tnj0o93V2B9MU= dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9/go.mod h1:H6x//7gZCb22OMCxBHrMx7a5I7Hp++hsVxbQ4BYO7hU= dmitri.shuralyov.com/html/belt v0.0.0-20180602232347-f7d459c86be0/go.mod h1:JLBrvjyP0v+ecvNYvCpyZgu5/xkfAUhi6wJj28eUfSU= @@ -98,8 +95,6 @@ github.com/beorn7/perks v1.0.0/go.mod h1:KWe93zE9D1o94FZ5RNwFwVgaQK1VOXiVxmqh+Ce github.com/beorn7/perks v1.0.1/go.mod h1:G2ZrVWU2WbWT9wwq4/hrbKbnv/1ERSJQ0ibhJ6rlkpw= github.com/bgentry/speakeasy v0.1.0/go.mod h1:+zsyZBPWlz7T6j88CTgSN5bM796AkVf0kBD4zp0CCIs= github.com/bketelsen/crypt v0.0.4/go.mod h1:aI6NrJ0pMGgvZKL1iVgXLnfIFJtfV+bKCoqOes/6LfM= -github.com/boltdb/bolt v1.3.1 h1:JQmyP4ZBrce+ZQu0dY660FMfatumYDLun9hBCUVIkF4= -github.com/boltdb/bolt v1.3.1/go.mod h1:clJnj/oiGkjum5o1McbSZDSLxVThjynRyGBgiAx27Ps= github.com/bradfitz/go-smtpd v0.0.0-20170404230938-deb6d6237625/go.mod h1:HYsPBTaaSFSlLx/70C2HPIMNZpVV8+vt/A+FMnYP11g= github.com/buger/jsonparser v0.0.0-20181115193947-bf1c66bbce23/go.mod h1:bbYlZJ7hK1yFx9hf58LP0zeX7UjIGs20ufpu3evjr+s= github.com/buger/jsonparser v1.1.1/go.mod h1:6RYKKt7H4d4+iWqouImQ9R2FZql3VbhNgx27UK13J/0= @@ -330,7 +325,6 @@ github.com/google/pprof v0.0.0-20200430221834-fc25d7d30c6d/go.mod h1:ZgVRPoUq/hf github.com/google/pprof v0.0.0-20200708004538-1a94d8640e99/go.mod h1:ZgVRPoUq/hfqzAqh7sHMqb3I9Rq5C59dIz2SbBwJ4eM= github.com/google/pprof v0.0.0-20201023163331-3e6fc7fc9c4c/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= github.com/google/pprof v0.0.0-20201203190320-1bf35d6f28c2/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= -github.com/google/pprof v0.0.0-20201218002935-b9804c9f04c2/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= github.com/google/pprof v0.0.0-20210122040257-d980be63207e/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= github.com/google/pprof v0.0.0-20210226084205-cbba55b83ad5/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= github.com/google/pprof v0.0.0-20210407192527-94a9f03dee38/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= @@ -343,7 +337,6 @@ github.com/googleapis/gax-go v2.0.0+incompatible/go.mod h1:SFVmujtThgffbyetf+mdk github.com/googleapis/gax-go/v2 v2.0.3/go.mod h1:LLvjysVCY1JZeum8Z6l8qUty8fiNwE08qbEPm1M08qg= github.com/googleapis/gax-go/v2 v2.0.4/go.mod h1:0Wqv26UfaUD9n4G6kQubkQ+KchISgw+vpHVxEJEs9eg= github.com/googleapis/gax-go/v2 v2.0.5/go.mod h1:DWXyrwAJ9X0FpwwEdw+IPEYBICEFu5mhpdKc/us6bOk= -github.com/googleapis/google-cloud-go-testing v0.0.0-20200911160855-bcd43fbb19e8/go.mod h1:dvDLG8qkwmyD9a/MJJN3XJcT3xFxOKAvTZGvuZmac9g= github.com/gopherjs/gopherjs v0.0.0-20181017120253-0766667cb4d1/go.mod h1:wJfORRmW1u3UXTncJ5qlYoELFm8eSnnEO6hX4iZ3EWY= github.com/gopherjs/gopherjs v0.0.0-20211219123610-ec9572f70e60/go.mod h1:cz9oNYuRUWGdHmLF2IodMLkAhcPtXeULvcBNagUrxTI= github.com/gopherjs/gopherjs v1.17.2 h1:fQnZVsXk8uxXIStYb0N4bGk7jeyTalG/wsZjQ25dO0g= @@ -401,7 +394,6 @@ github.com/hashicorp/golang-lru v0.5.0/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ github.com/hashicorp/golang-lru v0.5.1/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8= github.com/hashicorp/golang-lru v0.5.4 h1:YDjusn29QI/Das2iO9M0BHnIbxPeyuCHsjMW+lJfyTc= github.com/hashicorp/golang-lru v0.5.4/go.mod h1:iADmTwqILo4mZ8BN3D2Q6+9jd8WM5uGBxy+E8yxSoD4= -github.com/hashicorp/hcl v1.0.0 h1:0Anlzjpi4vEasTeNFn2mLJgTSwt0+6sfsiTG8qcWGx4= github.com/hashicorp/hcl v1.0.0/go.mod h1:E5yfLk+7swimpb2L/Alb/PJmXilQ/rhwaUYs4T20WEQ= github.com/hashicorp/logutils v1.0.0/go.mod h1:QIAnNjmIWmVIIkWDTG1z5v++HQmx9WQRO+LraFDTW64= github.com/hashicorp/mdns v1.0.0/go.mod h1:tL+uN++7HEJ6SQLQ2/p+z2pH24WQKWjBPkE0mNTz8vQ= @@ -490,8 +482,6 @@ github.com/lufia/plan9stats v0.0.0-20211012122336-39d0f177ccd0 h1:6E+4a0GO5zZEnZ github.com/lufia/plan9stats v0.0.0-20211012122336-39d0f177ccd0/go.mod h1:zJYVVT2jmtg6P3p1VtQj7WsuWi/y4VnjVBn7F8KPB3I= github.com/lunixbochs/vtclean v1.0.0/go.mod h1:pHhQNgMf3btfWnGBVipUOjRYhoOsdGqdm/+2c2E2WMI= github.com/magiconair/properties v1.8.5/go.mod h1:y3VJvCyxH9uVvJTWEGAELF3aiYNyPKd5NZ3oSwXrF60= -github.com/magiconair/properties v1.8.6 h1:5ibWZ6iY0NctNGWo87LalDlEZ6R41TqbbDamhfG/Qzo= -github.com/magiconair/properties v1.8.6/go.mod h1:y3VJvCyxH9uVvJTWEGAELF3aiYNyPKd5NZ3oSwXrF60= github.com/mailru/easyjson v0.0.0-20190312143242-1de009706dbe/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc= github.com/markbates/oncer v0.0.0-20181203154359-bf2de49a0be2/go.mod h1:Ld9puTsIW75CHf65OeIOkyKbteujpZVXDpWK6YGZbxE= github.com/markbates/safe v1.0.1/go.mod h1:nAqgmRi7cY2nqMc92/bSEeQA+R4OheNU2T1kNSCBdG0= @@ -590,8 +580,6 @@ github.com/pascaldekloe/goe v0.1.0 h1:cBOtyMzM9HTpWjXfbbunk26uA6nG3a8n06Wieeh0Mw github.com/pascaldekloe/goe v0.1.0/go.mod h1:lzWF7FIEvWOWxwDKqyGYQf6ZUaNfKdP144TG7ZOy1lc= github.com/pelletier/go-toml v1.7.0/go.mod h1:vwGMzjaWMwyfHwgIBhI2YUM4fB6nL6lVAvS1LBMMhTE= github.com/pelletier/go-toml v1.9.3/go.mod h1:u1nR/EPcESfeI/szUZKdtJ0xRNbUoANCkoOuaOx1Y+c= -github.com/pelletier/go-toml v1.9.5 h1:4yBQzkHv+7BHq2PQUZF3Mx0IYxG7LsP222s7Agd3ve8= -github.com/pelletier/go-toml v1.9.5/go.mod h1:u1nR/EPcESfeI/szUZKdtJ0xRNbUoANCkoOuaOx1Y+c= github.com/pelletier/go-toml/v2 v2.0.2 h1:+jQXlF3scKIcSEKkdHzXhCTDLPFi5r1wnK6yPS+49Gw= github.com/pelletier/go-toml/v2 v2.0.2/go.mod h1:MovirKjgVRESsAvNZlAjtFwV867yGuwRkXbG66OzopI= github.com/peterbourgon/g2s v0.0.0-20140925154142-ec76db4c1ac1 h1:5Dl+ADmsGerAqHwWzyLqkNaUBQ+48DQwfDCaW1gHAQM= @@ -604,7 +592,6 @@ github.com/pkg/errors v0.8.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINE github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4= github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pkg/sftp v1.10.1/go.mod h1:lYOWFsE0bwd1+KfKJaKeuokY15vzFx25BLbzYYoAxZI= -github.com/pkg/sftp v1.13.1/go.mod h1:3HaPG6Dq1ILlpPZRO0HVMrsydcdLt6HRDccSgb87qRg= github.com/pkg/sftp v1.13.5 h1:a3RLUqkyjYRtBTZJZ1VRrKbN3zhuPLlUc3sphVz81go= github.com/pkg/sftp v1.13.5/go.mod h1:wHDZ0IZX6JcBYRK1TH9bcVq8G7TLpVHYIGJRFnmPfxg= github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= @@ -713,8 +700,6 @@ github.com/soheilhy/cmux v0.1.5/go.mod h1:T7TcVDs9LWfQgPlPsdngu6I6QIoyIFZDDC6sNE github.com/sourcegraph/annotate v0.0.0-20160123013949-f4cad6c6324d/go.mod h1:UdhH50NIW0fCiwBSr0co2m7BnFLdv4fQTgdqdJTHFeE= github.com/sourcegraph/syntaxhighlight v0.0.0-20170531221838-bd320f5d308e/go.mod h1:HuIsMU8RRBOtsCgI77wP899iHVBQpCmg4ErYMZB+2IA= github.com/spf13/afero v1.6.0/go.mod h1:Ai8FlHk4v/PARR026UzYexafAt9roJ7LcLMAmO6Z93I= -github.com/spf13/afero v1.8.2 h1:xehSyVa0YnHWsJ49JFljMpg1HX19V6NDZ1fkm1Xznbo= -github.com/spf13/afero v1.8.2/go.mod h1:CtAatgMJh6bJEIs48Ay/FOnkljP3WeGUG0MC1RfAqwo= github.com/spf13/cast v1.3.1/go.mod h1:Qx5cxh0v+4UWYiBimWS+eyWzqEqokIECu5etghLkUJE= github.com/spf13/cast v1.5.0 h1:rj3WzYc11XZaIZMPKmwP96zkFEnnAmV8s6XbB2aY32w= github.com/spf13/cast v1.5.0/go.mod h1:SpXXQ5YoyJw6s3/6cMTQuxvgRl3PCJiyaX9p6b155UU= @@ -722,14 +707,11 @@ github.com/spf13/cobra v0.0.3/go.mod h1:1l0Ry5zgKvJasoi3XT1TypsSe7PqH0Sj9dhYf7v3 github.com/spf13/cobra v1.2.1/go.mod h1:ExllRjgxM/piMAM+3tAZvg8fsklGAf3tPfi+i8t68Nk= github.com/spf13/cobra v1.5.0 h1:X+jTBEBqF0bHN+9cSMgmfuvv2VHJ9ezmFNf9Y/XstYU= github.com/spf13/cobra v1.5.0/go.mod h1:dWXEIy2H428czQCjInthrTRUg7yKbok+2Qi/yBIJoUM= -github.com/spf13/jwalterweatherman v1.1.0 h1:ue6voC5bR5F8YxI5S67j9i582FU4Qvo2bmqnqMYADFk= github.com/spf13/jwalterweatherman v1.1.0/go.mod h1:aNWZUN0dPAAO/Ljvb5BEdw96iTZ0EXowPYD95IqWIGo= github.com/spf13/pflag v1.0.3/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4= github.com/spf13/pflag v1.0.5 h1:iy+VFUOCP1a+8yFto/drg2CJ5u0yRoB7fZw3DKv/JXA= github.com/spf13/pflag v1.0.5/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg= github.com/spf13/viper v1.8.1/go.mod h1:o0Pch8wJ9BVSWGQMbra6iw0oQ5oktSIBaujf1rJH9Ns= -github.com/spf13/viper v1.12.0 h1:CZ7eSOd3kZoaYDLbXnmzgQI5RlciuXBMA+18HwHRfZQ= -github.com/spf13/viper v1.12.0/go.mod h1:b6COn30jlNxbm/V2IqWiNWkJ+vZNiMNksliPCiuKtSI= github.com/srwiley/oksvg v0.0.0-20200311192757-870daf9aa564 h1:HunZiaEKNGVdhTRQOVpMmj5MQnGnv+e8uZNu3xFLgyM= github.com/srwiley/oksvg v0.0.0-20200311192757-870daf9aa564/go.mod h1:afMbS0qvv1m5tfENCwnOdZGOF8RGR/FsZ7bvBxQGZG4= github.com/srwiley/rasterx v0.0.0-20200120212402-85cb7272f5e9 h1:m59mIOBO4kfcNCEzJNy71UkeF4XIx2EVmL9KLwDQdmM= @@ -750,8 +732,6 @@ github.com/stretchr/testify v1.7.2/go.mod h1:R6va5+xMeoiuVRoj+gSkQ7d3FALtqAAGI1F github.com/stretchr/testify v1.8.0 h1:pSgiaMZlXftHpm5L7V1+rVB+AZJydKsMxsQBIJw4PKk= github.com/stretchr/testify v1.8.0/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO+kdMU+MU= github.com/subosito/gotenv v1.2.0/go.mod h1:N0PQaV/YGNqwC0u51sEeR/aUtSLEXKX9iv69rRypqCw= -github.com/subosito/gotenv v1.4.0 h1:yAzM1+SmVcz5R4tXGsNMu1jUl2aOJXoiWUCEwwnGrvs= -github.com/subosito/gotenv v1.4.0/go.mod h1:mZd6rFysKEcUhUHXJk0C/08wAgyDBFuwEYL7vWWGaGo= github.com/tarm/serial v0.0.0-20180830185346-98f6abe2eb07/go.mod h1:kDXzergiv9cbyO7IOYJZWg1U88JhDg3PB6klq9Hg2pA= github.com/templexxx/cpufeat v0.0.0-20180724012125-cef66df7f161 h1:89CEmDvlq/F7SJEOqkIdNDGJXrQIhuIx9D2DBXjavSU= github.com/templexxx/cpufeat v0.0.0-20180724012125-cef66df7f161/go.mod h1:wM7WEvslTq+iOEAMDLSzhVuOt5BRZ05WirO+b09GHQU= @@ -845,9 +825,6 @@ go.uber.org/zap v1.15.0/go.mod h1:Mb2vm2krFEG5DV0W9qcHBYFtp/Wku1cvYaqPsS/WYfc= go.uber.org/zap v1.17.0 h1:MTjgFu6ZLKvY6Pvaqk97GlxNBuMpV4Hy/3P6tRGlI2U= go.uber.org/zap v1.17.0/go.mod h1:MXVU+bhUf/A7Xi2HNOnopQOrmycQ5Ih87HtOu4q5SSo= go4.org v0.0.0-20180809161055-417644f6feb5/go.mod h1:MkTOUMDaeVYJUOUsaDXIhWPZYa1yOyC1qaOBpL57BhE= -golang.design/x/hotkey v0.4.0 h1:jmY6QJdakEdYn0KBm48IZRw3emBpDXRhIWUHqPVsWBY= -golang.design/x/hotkey v0.4.0/go.mod h1:M8SGcwFYHnKRa83FpTFQoZvPO5vVT+kWPztFqTQKmXA= -golang.design/x/mainthread v0.3.0 h1:UwFus0lcPodNpMOGoQMe87jSFwbSsEY//CA7yVmu4j8= golang.org/x/build v0.0.0-20190111050920-041ab4dc3f9d/go.mod h1:OWs+y06UdEOHN4y+MfF/py+xQ/tYqIWW03b70/CG9Rw= golang.org/x/crypto v0.0.0-20180904163835-0709b304e793/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= golang.org/x/crypto v0.0.0-20181029021203-45a5f77698d3/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= @@ -865,10 +842,8 @@ golang.org/x/crypto v0.0.0-20200302210943-78000ba7a073/go.mod h1:LzIPMQfyMNhhGPh golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20200709230013-948cd5f35899/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20201012173705-84dcc777aaee/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= -golang.org/x/crypto v0.0.0-20210421170649-83a5a9bb288b/go.mod h1:T9bdIzuCu7OtxOm1hfPfRQxPLYneinmdGuTeoZ9dtd4= golang.org/x/crypto v0.0.0-20210711020723-a769d52b0f97/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= -golang.org/x/crypto v0.0.0-20211108221036-ceb1ce70b4fa/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= golang.org/x/crypto v0.0.0-20211215153901-e495a2d5b3d3/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= golang.org/x/crypto v0.0.0-20220408190544-5352b0902921/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= golang.org/x/crypto v0.0.0-20220829220503-c86fa9a7ed90 h1:Y/gsMcFOcR+6S6f3YeMKl5g+dZMEWqcz5Czj/GWYbkM= @@ -960,7 +935,6 @@ golang.org/x/net v0.0.0-20201031054903-ff519b6c9102/go.mod h1:sp8m0HH+o8qH0wwXwY golang.org/x/net v0.0.0-20201110031124-69a78807bb2b/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= golang.org/x/net v0.0.0-20201202161906-c7110b5ffcbb/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= golang.org/x/net v0.0.0-20201209123823-ac852fbbde11/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= -golang.org/x/net v0.0.0-20201224014010-6772e930b67b/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= golang.org/x/net v0.0.0-20210119194325-5f4716e94777/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= golang.org/x/net v0.0.0-20210226172049-e18ecbb05110/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= golang.org/x/net v0.0.0-20210316092652-d523dce5a7f4/go.mod h1:RBQZq4jEuRlivfhVLdyRGr576XBO4/greRjx4P4O3yc= @@ -1062,7 +1036,6 @@ golang.org/x/sys v0.0.0-20210104204734-6f8348627aad/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20210112080510-489259a85091/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210119212857-b64e53b001e4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210220050731-9a76102bfb43/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210225134936-a50acf3fe073/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210303074136-134d130e1a04/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210305230114-8fe3ee5dd75b/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210315160823-c6e025ad8005/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -1071,7 +1044,6 @@ golang.org/x/sys v0.0.0-20210330210617-4fbd30eecc44/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20210403161142-5e06dd20ab57/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210420072515-93ed5bcd2bfe/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210423082822-04245dca01da/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210423185535-09eb48e85fd7/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210510120138-977fb7262007/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= @@ -1167,7 +1139,6 @@ golang.org/x/tools v0.0.0-20201208233053-a543418bbed2/go.mod h1:emZCQorbCU4vsT4f golang.org/x/tools v0.0.0-20201224043029-2b0845dc783e/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= golang.org/x/tools v0.0.0-20210105154028-b0ab187a4818/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= golang.org/x/tools v0.0.0-20210106214847-113979e3529a/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= -golang.org/x/tools v0.0.0-20210108195828-e2f9c7f1fc8e/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= golang.org/x/tools v0.1.0/go.mod h1:xkSsbof2nBLbhDlRMhhhyNLN/zl3eTqcnHD5viDpcZ0= golang.org/x/tools v0.1.1/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= golang.org/x/tools v0.1.2/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= @@ -1255,9 +1226,7 @@ google.golang.org/genproto v0.0.0-20201109203340-2640f1f9cdfb/go.mod h1:FWY/as6D google.golang.org/genproto v0.0.0-20201201144952-b05cb90ed32e/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20201210142538-e3217bee35cc/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20201214200347-8c77b98c765d/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= -google.golang.org/genproto v0.0.0-20210108203827-ffc7fda8c3d7/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20210222152913-aa3ee6e6a81c/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= -google.golang.org/genproto v0.0.0-20210226172003-ab064af71705/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20210303154014-9728d6b83eeb/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20210310155132-4ce2db91004e/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20210319143718-93e7006c17a6/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= @@ -1318,8 +1287,6 @@ gopkg.in/fsnotify.v1 v1.4.7/go.mod h1:Tz8NjZHkW78fSQdbUxIjBTcgA1z1m8ZHf0WmKUhAMy gopkg.in/inf.v0 v0.9.1/go.mod h1:cWUDdTG/fYaXco+Dcufb5Vnc6Gp2YChqWtbxRZE0mXw= gopkg.in/ini.v1 v1.42.0/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k= gopkg.in/ini.v1 v1.62.0/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k= -gopkg.in/ini.v1 v1.66.6 h1:LATuAqN/shcYAOkv3wl2L4rkaKqkcgTBQjOyYDvcPKI= -gopkg.in/ini.v1 v1.66.6/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k= gopkg.in/natefinch/lumberjack.v2 v2.0.0 h1:1Lc07Kr7qY4U2YPouBjpCLxpiyxIVoxqXgkXLknAOE8= gopkg.in/natefinch/lumberjack.v2 v2.0.0/go.mod h1:l0ndWWf7gzL7RNwBG7wST/UCcT4T24xpD6X8LsfU/+k= gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7 h1:uRGJdciOHaEIrze2W8Q3AKkepLTh2hOroT7a+7czfdQ= From eb7c3b7c60ec00889b41607a2f17a641c3964df6 Mon Sep 17 00:00:00 2001 From: meixiongfeng <766881921@qq.com> Date: Thu, 2 Feb 2023 09:55:37 +0800 Subject: [PATCH 13/17] =?UTF-8?q?=E5=88=9B=E5=BB=BA=E7=89=B9=E6=AE=8A?= =?UTF-8?q?=E8=8B=B1=E9=9B=84=E6=97=B6=E6=A0=A1=E9=AA=8C=E6=98=AF=E5=90=A6?= =?UTF-8?q?=E6=9C=89=E9=87=8D=E5=A4=8D=E8=8B=B1=E9=9B=84?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- modules/hero/api_specified.go | 2 +- modules/hero/model_hero.go | 9 ++++++++- modules/hero/module.go | 4 ++-- modules/user/api_gettujian.go | 18 ++++-------------- 4 files changed, 15 insertions(+), 18 deletions(-) diff --git a/modules/hero/api_specified.go b/modules/hero/api_specified.go index 6680dc7a0..301ef9462 100644 --- a/modules/hero/api_specified.go +++ b/modules/hero/api_specified.go @@ -25,7 +25,7 @@ func (this *apiComp) GetSpecified(session comm.IUserSession, req *pb.HeroGetSpec if code != pb.ErrorCode_Success { return } - hero, err := this.module.modelHero.createOneHero(session.GetUserId(), req.HeroCoinfigID) + hero, err := this.module.modelHero.createSpecialHero(session.GetUserId(), req.HeroCoinfigID) if err == nil { code = pb.ErrorCode_HeroNoExist } diff --git a/modules/hero/model_hero.go b/modules/hero/model_hero.go index f7b999c1c..3038e9822 100644 --- a/modules/hero/model_hero.go +++ b/modules/hero/model_hero.go @@ -96,7 +96,14 @@ func (this *ModelHero) initHeroSkill(hero *pb.DBHero) []*pb.SkillData { } //创建一个指定的英雄 -func (this *ModelHero) createOneHero(uid string, heroCfgId string) (hero *pb.DBHero, err error) { +func (this *ModelHero) createSpecialHero(uid string, heroCfgId string) (hero *pb.DBHero, err error) { + list := this.getHeroList(uid) + for _, v := range list { + if v.HeroID == heroCfgId { + hero = v + return + } + } hero = this.InitHero(uid, heroCfgId) if hero != nil { if err = this.AddList(uid, hero.Id, hero); err != nil { diff --git a/modules/hero/module.go b/modules/hero/module.go index 3c3d5826b..ba455018b 100644 --- a/modules/hero/module.go +++ b/modules/hero/module.go @@ -234,7 +234,7 @@ func (this *Hero) GetSpecifiedHero(session comm.IUserSession, heroConfId string, code = pb.ErrorCode_ReqParameterError return } - hero, err := this.modelHero.createOneHero(session.GetUserId(), heroConfId) + hero, err := this.modelHero.createSpecialHero(session.GetUserId(), heroConfId) if err != nil { return pb.ErrorCode_HeroCreate } @@ -683,7 +683,7 @@ func (this *Hero) GetAllMaxHero(session comm.IUserSession) (code pb.ErrorCode) { } // 开始创建英雄 - hero, err := this.modelHero.createOneHero(session.GetUserId(), v.Hid) + hero, err := this.modelHero.createSpecialHero(session.GetUserId(), v.Hid) if err != nil { return pb.ErrorCode_HeroCreate } diff --git a/modules/user/api_gettujian.go b/modules/user/api_gettujian.go index 7a75b1a1a..81b3b193b 100644 --- a/modules/user/api_gettujian.go +++ b/modules/user/api_gettujian.go @@ -2,7 +2,6 @@ package user import ( "go_dreamfactory/comm" - "go_dreamfactory/lego/sys/log" "go_dreamfactory/pb" "google.golang.org/protobuf/proto" @@ -17,21 +16,12 @@ func (this *apiComp) GetTujian(session comm.IUserSession, req *pb.UserGetTujianR return } - uid := session.GetUserId() rsp := &pb.UserGetTujianResp{} - if result, err := this.module.modelExpand.GetUserExpand(uid); err != nil { - this.module.Error("玩家扩展数据", - log.Field{Key: "uid", Value: uid}, - log.Field{Key: "err", Value: err.Error()}, - ) - return - } else { - for k, v := range result.Tujian { - if v == 0 { - rsp.Heroids = append(rsp.Heroids, k) - } - } + list := this.module.ModuleHero.GetHeroList(session.GetUserId()) + for _, v := range list { + rsp.Heroids = append(rsp.Heroids, v.HeroID) } + err := session.SendMsg(string(this.module.GetType()), UserGetTujianResp, rsp) if err != nil { code = pb.ErrorCode_SystemError From cdd3db85b2a7b48fc013b2e1af7260a75b8c264b Mon Sep 17 00:00:00 2001 From: wh_zcy Date: Thu, 2 Feb 2023 10:42:49 +0800 Subject: [PATCH 14/17] =?UTF-8?q?=E5=BC=80=E6=94=BE=E4=BB=BB=E5=8A=A1?= =?UTF-8?q?=E8=A7=A6=E5=8F=91=E5=8D=8F=E8=AE=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- cmd/v2/ui/protocol.go | 52 +- cmd/v2/ui/views/rtask_apply.go | 44 -- cmd/v2/ui/views/rtask_battlefinish.go | 33 - cmd/v2/ui/views/rtask_battlestart.go | 43 - cmd/v2/ui/views/rtask_choose.go | 52 -- cmd/v2/ui/views/rtask_reward.go | 37 - modules/rtask/api.go | 10 +- modules/rtask/api_send.go | 29 + pb/rtask_msg.pb.go | 1048 +++++-------------------- pb/userexpand.pb.go | 2 +- 10 files changed, 250 insertions(+), 1100 deletions(-) delete mode 100644 cmd/v2/ui/views/rtask_apply.go delete mode 100644 cmd/v2/ui/views/rtask_battlefinish.go delete mode 100644 cmd/v2/ui/views/rtask_battlestart.go delete mode 100644 cmd/v2/ui/views/rtask_choose.go delete mode 100644 cmd/v2/ui/views/rtask_reward.go create mode 100644 modules/rtask/api_send.go diff --git a/cmd/v2/ui/protocol.go b/cmd/v2/ui/protocol.go index 4ffc79776..13cdc6dca 100644 --- a/cmd/v2/ui/protocol.go +++ b/cmd/v2/ui/protocol.go @@ -102,14 +102,9 @@ var ( // pagoda ff(comm.ModulePagoda, "getlist"): &formview.PagodaListView{}, // rtask - ff(comm.ModuleRtask, rtask.RtaskSubTypeList): &formview.RtaskListView{}, - ff(comm.ModuleRtask, rtask.RtaskSubTypeApply): &formview.RtaskDoitView{}, - ff(comm.ModuleRtask, rtask.RtaskSubTypeChoose): &formview.RtaskChooseView{}, - ff(comm.ModuleRtask, rtask.RtaskSubTypeReward): &formview.RtaskRewardView{}, - ff(comm.ModuleRtask, "rtest"): &formview.RtaskTestView{}, - ff(comm.ModuleRtask, rtask.RtaskSubTypeBattleStart): &formview.RtaskBattlestartView{}, - ff(comm.ModuleRtask, rtask.RtaskSubTypeBattleFinish): &formview.RtaskBattleFinishView{}, - ff(comm.ModuleRtask, rtask.RtaskSubTypeGetrecord): &formview.RtaskRecordView{}, + ff(comm.ModuleRtask, rtask.RtaskSubTypeList): &formview.RtaskListView{}, + ff(comm.ModuleRtask, "rtest"): &formview.RtaskTestView{}, + ff(comm.ModuleRtask, rtask.RtaskSubTypeGetrecord): &formview.RtaskRecordView{}, // linestory ff(comm.ModuleLinestory, linestory.LinestorySubTypeChapter): &formview.LinestoryMineView{}, ff(comm.ModuleLibrary, library.LibraryFetterstoryTaskResp): &formview.FetterstoryView{}, @@ -227,12 +222,6 @@ var ( }, "rtask": { ff(comm.ModuleRtask, rtask.RtaskSubTypeList), - ff(comm.ModuleRtask, rtask.RtaskSubTypeApply), - ff(comm.ModuleRtask, rtask.RtaskSubTypeChoose), - ff(comm.ModuleRtask, rtask.RtaskSubTypeReward), - - ff(comm.ModuleRtask, rtask.RtaskSubTypeBattleStart), - ff(comm.ModuleRtask, rtask.RtaskSubTypeBattleFinish), ff(comm.ModuleRtask, rtask.RtaskSubTypeGetrecord), ff(comm.ModuleRtask, "rtest"), }, @@ -770,41 +759,6 @@ var ( return "" }, }, - ff(comm.ModuleRtask, rtask.RtaskSubTypeApply): { - NavLabel: "做任务", - Desc: "执行随机任务", - MainType: string(comm.ModuleRtask), - SubType: rtask.RtaskSubTypeApply, - Enabled: true, - }, - ff(comm.ModuleRtask, rtask.RtaskSubTypeChoose): { - NavLabel: "情景对答", - Desc: "情景对答", - MainType: string(comm.ModuleRtask), - SubType: rtask.RtaskSubTypeChoose, - Enabled: true, - }, - ff(comm.ModuleRtask, rtask.RtaskSubTypeReward): { - NavLabel: "领奖", - Desc: "领奖", - MainType: string(comm.ModuleRtask), - SubType: rtask.RtaskSubTypeReward, - Enabled: true, - }, - ff(comm.ModuleRtask, rtask.RtaskSubTypeBattleStart): { - NavLabel: "战斗开始", - Desc: "战斗开始", - MainType: string(comm.ModuleRtask), - SubType: rtask.RtaskSubTypeBattleStart, - Enabled: true, - }, - ff(comm.ModuleRtask, rtask.RtaskSubTypeBattleFinish): { - NavLabel: "战斗结束", - Desc: "战斗结束", - MainType: string(comm.ModuleRtask), - SubType: rtask.RtaskSubTypeBattleFinish, - Enabled: true, - }, ff(comm.ModuleRtask, rtask.RtaskSubTypeGetrecord): { NavLabel: "任务数据", Desc: "任务数据", diff --git a/cmd/v2/ui/views/rtask_apply.go b/cmd/v2/ui/views/rtask_apply.go deleted file mode 100644 index eff997d7f..000000000 --- a/cmd/v2/ui/views/rtask_apply.go +++ /dev/null @@ -1,44 +0,0 @@ -package formview - -import ( - "errors" - "go_dreamfactory/cmd/v2/model" - "go_dreamfactory/cmd/v2/service" - "go_dreamfactory/pb" - - "fyne.io/fyne/v2" - "fyne.io/fyne/v2/dialog" - "fyne.io/fyne/v2/widget" - "github.com/sirupsen/logrus" - "github.com/spf13/cast" -) - -type RtaskDoitView struct { - BaseformView -} - -func (this *RtaskDoitView) CreateView(t *model.TestCase) fyne.CanvasObject { - taskId := widget.NewEntry() - taskId.PlaceHolder = "任务ID" - - subTaskId := widget.NewEntry() - subTaskId.PlaceHolder = "支线任务ID" - - this.form.AppendItem(widget.NewFormItem("任务ID", taskId)) - this.form.AppendItem(widget.NewFormItem("支线任务ID", subTaskId)) - - this.form.OnSubmit = func() { - if taskId.Text == "" { - dialog.ShowError(errors.New("请填写任务ID"), this.w) - return - } - if err := service.GetPttService().SendToClient(t.MainType, t.SubType, &pb.RtaskApplyReq{ - RtaskId: cast.ToInt32(taskId.Text), - RtaskSubId: cast.ToInt32(subTaskId.Text), - }); err != nil { - logrus.Error(err) - } - } - - return this.form -} diff --git a/cmd/v2/ui/views/rtask_battlefinish.go b/cmd/v2/ui/views/rtask_battlefinish.go deleted file mode 100644 index 581af854f..000000000 --- a/cmd/v2/ui/views/rtask_battlefinish.go +++ /dev/null @@ -1,33 +0,0 @@ -package formview - -import ( - "go_dreamfactory/cmd/v2/model" - "go_dreamfactory/cmd/v2/service" - "go_dreamfactory/pb" - - "fyne.io/fyne/v2" - "fyne.io/fyne/v2/widget" - "github.com/sirupsen/logrus" - "github.com/spf13/cast" -) - -type RtaskBattleFinishView struct { - BaseformView -} - -func (this *RtaskBattleFinishView) CreateView(t *model.TestCase) fyne.CanvasObject { - taskId := widget.NewEntry() - - this.form.AppendItem(widget.NewFormItem("任务ID", taskId)) - - this.form.OnSubmit = func() { - if err := service.GetPttService().SendToClient(t.MainType, t.SubType, - &pb.RtaskBattleFinishReq{ - RtaskId: cast.ToInt32(taskId.Text), - }); err != nil { - logrus.Error(err) - } - } - - return this.form -} diff --git a/cmd/v2/ui/views/rtask_battlestart.go b/cmd/v2/ui/views/rtask_battlestart.go deleted file mode 100644 index 09715e014..000000000 --- a/cmd/v2/ui/views/rtask_battlestart.go +++ /dev/null @@ -1,43 +0,0 @@ -package formview - -import ( - "go_dreamfactory/cmd/v2/model" - "go_dreamfactory/cmd/v2/service" - "go_dreamfactory/pb" - "strings" - - "fyne.io/fyne/v2" - "fyne.io/fyne/v2/widget" - "github.com/sirupsen/logrus" - "github.com/spf13/cast" -) - -type RtaskBattlestartView struct { - BaseformView -} - -func (this *RtaskBattlestartView) CreateView(t *model.TestCase) fyne.CanvasObject { - confId := widget.NewEntry() - - leadpos := widget.NewEntry() - - teamIds := widget.NewEntry() - teamIds.PlaceHolder = ",号分隔" - - this.form.AppendItem(widget.NewFormItem("关卡ID", confId)) - this.form.AppendItem(widget.NewFormItem("队长位置", leadpos)) - this.form.AppendItem(widget.NewFormItem("阵容信息", teamIds)) - - this.form.OnSubmit = func() { - if err := service.GetPttService().SendToClient(t.MainType, t.SubType, - - &pb.RtaskBattleStartReq{ - BattleConfId: cast.ToInt32(confId.Text), - Leadpos: cast.ToInt32(leadpos.Text), - Teamids: strings.Split(teamIds.Text, ","), - }); err != nil { - logrus.Error(err) - } - } - return this.form -} diff --git a/cmd/v2/ui/views/rtask_choose.go b/cmd/v2/ui/views/rtask_choose.go deleted file mode 100644 index b78cb690e..000000000 --- a/cmd/v2/ui/views/rtask_choose.go +++ /dev/null @@ -1,52 +0,0 @@ -package formview - -import ( - "errors" - "go_dreamfactory/cmd/v2/model" - "go_dreamfactory/cmd/v2/service" - "go_dreamfactory/pb" - - "fyne.io/fyne/v2" - "fyne.io/fyne/v2/dialog" - "fyne.io/fyne/v2/widget" - "github.com/sirupsen/logrus" - "github.com/spf13/cast" -) - -type RtaskChooseView struct { - BaseformView -} - -func (this *RtaskChooseView) CreateView(t *model.TestCase) fyne.CanvasObject { - taskId := widget.NewEntry() - taskId.PlaceHolder = "任务ID" - - subTaskId := widget.NewEntry() - subTaskId.PlaceHolder = "支线任务ID" - - chooseId := widget.NewEntry() - chooseId.PlaceHolder = "选项ID" - - this.form.AppendItem(widget.NewFormItem("任务ID", taskId)) - this.form.AppendItem(widget.NewFormItem("支线任务ID", subTaskId)) - this.form.AppendItem(widget.NewFormItem("选项ID", chooseId)) - - this.form.OnSubmit = func() { - if taskId.Text == "" { - dialog.ShowError(errors.New("请填写任务ID"), this.w) - return - } - if chooseId.Text == "" { - dialog.ShowError(errors.New("请填写选项ID"), this.w) - return - } - if err := service.GetPttService().SendToClient(t.MainType, t.SubType, &pb.RtaskChooseReq{ - RtaskId: cast.ToInt32(taskId.Text), - RtaskSubId: cast.ToInt32(subTaskId.Text), - ChooseId: cast.ToInt32(chooseId.Text), - }); err != nil { - logrus.Error(err) - } - } - return this.form -} diff --git a/cmd/v2/ui/views/rtask_reward.go b/cmd/v2/ui/views/rtask_reward.go deleted file mode 100644 index 16b4cb0fc..000000000 --- a/cmd/v2/ui/views/rtask_reward.go +++ /dev/null @@ -1,37 +0,0 @@ -package formview - -import ( - "errors" - "go_dreamfactory/cmd/v2/model" - "go_dreamfactory/cmd/v2/service" - "go_dreamfactory/pb" - - "fyne.io/fyne/v2" - "fyne.io/fyne/v2/dialog" - "fyne.io/fyne/v2/widget" - "github.com/sirupsen/logrus" - "github.com/spf13/cast" -) - -type RtaskRewardView struct { - BaseformView -} - -func (this *RtaskRewardView) CreateView(t *model.TestCase) fyne.CanvasObject { - taskId := widget.NewEntry() - taskId.PlaceHolder = "任务ID" - - this.form.AppendItem(widget.NewFormItem("任务ID", taskId)) - this.form.OnSubmit = func() { - if taskId.Text == "" { - dialog.ShowError(errors.New("请填写任务ID"), this.w) - return - } - if err := service.GetPttService().SendToClient(t.MainType, t.SubType, &pb.RtaskGetRewardReq{ - RtaskId: cast.ToInt32(taskId.Text), - }); err != nil { - logrus.Error(err) - } - } - return this.form -} diff --git a/modules/rtask/api.go b/modules/rtask/api.go index 861698558..7e0350733 100644 --- a/modules/rtask/api.go +++ b/modules/rtask/api.go @@ -6,13 +6,9 @@ import ( ) const ( - RtaskSubTypeChoose = "choose" //选择 - RtaskSubTypeList = "list" //随机任务列表 - RtaskSubTypeApply = "apply" //做任务 - RtaskSubTypeReward = "getreward" //奖励 - RtaskSubTypeBattleStart = "battlestart" //战斗开始 - RtaskSubTypeBattleFinish = "battlefinish" //战斗完成 - RtaskSubTypeGetrecord = "getrecord" //任务数据 + RtaskSubTypeList = "list" //随机任务列表 + RtaskSubTypeGetrecord = "getrecord" //任务数据 + RtaskSubTypeSend = "send" //触发任务 ) type apiComp struct { diff --git a/modules/rtask/api_send.go b/modules/rtask/api_send.go new file mode 100644 index 000000000..c0d5ffef8 --- /dev/null +++ b/modules/rtask/api_send.go @@ -0,0 +1,29 @@ +package rtask + +import ( + "go_dreamfactory/comm" + "go_dreamfactory/pb" + + "google.golang.org/protobuf/proto" +) + +func (this *apiComp) SendCheck(session comm.IUserSession, req *pb.RtaskSendReq) (code pb.ErrorCode) { + if len(req.Params) == 0 || req.TaskType == 0 { + code = pb.ErrorCode_ReqParameterError + } + return +} + +func (this *apiComp) Send(session comm.IUserSession, req *pb.RtaskSendReq) (code pb.ErrorCode, data proto.Message) { + if code = this.moduleRtask.SendToRtask(session, comm.TaskType(req.TaskType), req.Params...); code != pb.ErrorCode_Success { + return + } + + rsp := &pb.RtaskSendResp{ + IsSucc: true, + } + if err := session.SendMsg(string(this.moduleRtask.GetType()), RtaskSubTypeSend, rsp); err != nil { + code = pb.ErrorCode_SystemError + } + return +} diff --git a/pb/rtask_msg.pb.go b/pb/rtask_msg.pb.go index b6250b6da..245389389 100644 --- a/pb/rtask_msg.pb.go +++ b/pb/rtask_msg.pb.go @@ -20,109 +20,6 @@ const ( _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) ) -// 申请做任务 -type RtaskApplyReq struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - RtaskId int32 `protobuf:"varint,1,opt,name=rtaskId,proto3" json:"rtaskId"` //任务ID - RtaskSubId int32 `protobuf:"varint,2,opt,name=rtaskSubId,proto3" json:"rtaskSubId"` //支线任务ID -} - -func (x *RtaskApplyReq) Reset() { - *x = RtaskApplyReq{} - if protoimpl.UnsafeEnabled { - mi := &file_rtask_rtask_msg_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *RtaskApplyReq) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*RtaskApplyReq) ProtoMessage() {} - -func (x *RtaskApplyReq) ProtoReflect() protoreflect.Message { - mi := &file_rtask_rtask_msg_proto_msgTypes[0] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use RtaskApplyReq.ProtoReflect.Descriptor instead. -func (*RtaskApplyReq) Descriptor() ([]byte, []int) { - return file_rtask_rtask_msg_proto_rawDescGZIP(), []int{0} -} - -func (x *RtaskApplyReq) GetRtaskId() int32 { - if x != nil { - return x.RtaskId - } - return 0 -} - -func (x *RtaskApplyReq) GetRtaskSubId() int32 { - if x != nil { - return x.RtaskSubId - } - return 0 -} - -type RtaskApplyResp struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - RtaskId int32 `protobuf:"varint,1,opt,name=rtaskId,proto3" json:"rtaskId"` -} - -func (x *RtaskApplyResp) Reset() { - *x = RtaskApplyResp{} - if protoimpl.UnsafeEnabled { - mi := &file_rtask_rtask_msg_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *RtaskApplyResp) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*RtaskApplyResp) ProtoMessage() {} - -func (x *RtaskApplyResp) ProtoReflect() protoreflect.Message { - mi := &file_rtask_rtask_msg_proto_msgTypes[1] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use RtaskApplyResp.ProtoReflect.Descriptor instead. -func (*RtaskApplyResp) Descriptor() ([]byte, []int) { - return file_rtask_rtask_msg_proto_rawDescGZIP(), []int{1} -} - -func (x *RtaskApplyResp) GetRtaskId() int32 { - if x != nil { - return x.RtaskId - } - return 0 -} - // 任务列表 type RtasklistReq struct { state protoimpl.MessageState @@ -135,7 +32,7 @@ type RtasklistReq struct { func (x *RtasklistReq) Reset() { *x = RtasklistReq{} if protoimpl.UnsafeEnabled { - mi := &file_rtask_rtask_msg_proto_msgTypes[2] + mi := &file_rtask_rtask_msg_proto_msgTypes[0] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -148,7 +45,7 @@ func (x *RtasklistReq) String() string { func (*RtasklistReq) ProtoMessage() {} func (x *RtasklistReq) ProtoReflect() protoreflect.Message { - mi := &file_rtask_rtask_msg_proto_msgTypes[2] + mi := &file_rtask_rtask_msg_proto_msgTypes[0] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -161,7 +58,7 @@ func (x *RtasklistReq) ProtoReflect() protoreflect.Message { // Deprecated: Use RtasklistReq.ProtoReflect.Descriptor instead. func (*RtasklistReq) Descriptor() ([]byte, []int) { - return file_rtask_rtask_msg_proto_rawDescGZIP(), []int{2} + return file_rtask_rtask_msg_proto_rawDescGZIP(), []int{0} } func (x *RtasklistReq) GetGroupId() int32 { @@ -183,7 +80,7 @@ type RtasklistResp struct { func (x *RtasklistResp) Reset() { *x = RtasklistResp{} if protoimpl.UnsafeEnabled { - mi := &file_rtask_rtask_msg_proto_msgTypes[3] + mi := &file_rtask_rtask_msg_proto_msgTypes[1] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -196,7 +93,7 @@ func (x *RtasklistResp) String() string { func (*RtasklistResp) ProtoMessage() {} func (x *RtasklistResp) ProtoReflect() protoreflect.Message { - mi := &file_rtask_rtask_msg_proto_msgTypes[3] + mi := &file_rtask_rtask_msg_proto_msgTypes[1] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -209,7 +106,7 @@ func (x *RtasklistResp) ProtoReflect() protoreflect.Message { // Deprecated: Use RtasklistResp.ProtoReflect.Descriptor instead. func (*RtasklistResp) Descriptor() ([]byte, []int) { - return file_rtask_rtask_msg_proto_rawDescGZIP(), []int{3} + return file_rtask_rtask_msg_proto_rawDescGZIP(), []int{1} } func (x *RtasklistResp) GetRtaskIds() []int32 { @@ -226,133 +123,6 @@ func (x *RtasklistResp) GetGroupId() int32 { return 0 } -// 对话选项 -type RtaskChooseReq struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - RtaskId int32 `protobuf:"varint,1,opt,name=rtaskId,proto3" json:"rtaskId"` //任务ID - ChooseId int32 `protobuf:"varint,2,opt,name=chooseId,proto3" json:"chooseId"` //选项配置ID - RtaskSubId int32 `protobuf:"varint,3,opt,name=rtaskSubId,proto3" json:"rtaskSubId"` //支线任务ID -} - -func (x *RtaskChooseReq) Reset() { - *x = RtaskChooseReq{} - if protoimpl.UnsafeEnabled { - mi := &file_rtask_rtask_msg_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *RtaskChooseReq) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*RtaskChooseReq) ProtoMessage() {} - -func (x *RtaskChooseReq) ProtoReflect() protoreflect.Message { - mi := &file_rtask_rtask_msg_proto_msgTypes[4] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use RtaskChooseReq.ProtoReflect.Descriptor instead. -func (*RtaskChooseReq) Descriptor() ([]byte, []int) { - return file_rtask_rtask_msg_proto_rawDescGZIP(), []int{4} -} - -func (x *RtaskChooseReq) GetRtaskId() int32 { - if x != nil { - return x.RtaskId - } - return 0 -} - -func (x *RtaskChooseReq) GetChooseId() int32 { - if x != nil { - return x.ChooseId - } - return 0 -} - -func (x *RtaskChooseReq) GetRtaskSubId() int32 { - if x != nil { - return x.RtaskSubId - } - return 0 -} - -type RtaskChooseResp struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - RtaskId int32 `protobuf:"varint,1,opt,name=rtaskId,proto3" json:"rtaskId"` //任务ID - ChooseId int32 `protobuf:"varint,2,opt,name=chooseId,proto3" json:"chooseId"` //选项配置ID - RtaskSubId int32 `protobuf:"varint,3,opt,name=rtaskSubId,proto3" json:"rtaskSubId"` //支线任务ID -} - -func (x *RtaskChooseResp) Reset() { - *x = RtaskChooseResp{} - if protoimpl.UnsafeEnabled { - mi := &file_rtask_rtask_msg_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *RtaskChooseResp) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*RtaskChooseResp) ProtoMessage() {} - -func (x *RtaskChooseResp) ProtoReflect() protoreflect.Message { - mi := &file_rtask_rtask_msg_proto_msgTypes[5] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use RtaskChooseResp.ProtoReflect.Descriptor instead. -func (*RtaskChooseResp) Descriptor() ([]byte, []int) { - return file_rtask_rtask_msg_proto_rawDescGZIP(), []int{5} -} - -func (x *RtaskChooseResp) GetRtaskId() int32 { - if x != nil { - return x.RtaskId - } - return 0 -} - -func (x *RtaskChooseResp) GetChooseId() int32 { - if x != nil { - return x.ChooseId - } - return 0 -} - -func (x *RtaskChooseResp) GetRtaskSubId() int32 { - if x != nil { - return x.RtaskSubId - } - return 0 -} - // 任务完成推送 type RtaskFinishPush struct { state protoimpl.MessageState @@ -365,7 +135,7 @@ type RtaskFinishPush struct { func (x *RtaskFinishPush) Reset() { *x = RtaskFinishPush{} if protoimpl.UnsafeEnabled { - mi := &file_rtask_rtask_msg_proto_msgTypes[6] + mi := &file_rtask_rtask_msg_proto_msgTypes[2] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -378,7 +148,7 @@ func (x *RtaskFinishPush) String() string { func (*RtaskFinishPush) ProtoMessage() {} func (x *RtaskFinishPush) ProtoReflect() protoreflect.Message { - mi := &file_rtask_rtask_msg_proto_msgTypes[6] + mi := &file_rtask_rtask_msg_proto_msgTypes[2] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -391,7 +161,7 @@ func (x *RtaskFinishPush) ProtoReflect() protoreflect.Message { // Deprecated: Use RtaskFinishPush.ProtoReflect.Descriptor instead. func (*RtaskFinishPush) Descriptor() ([]byte, []int) { - return file_rtask_rtask_msg_proto_rawDescGZIP(), []int{6} + return file_rtask_rtask_msg_proto_rawDescGZIP(), []int{2} } func (x *RtaskFinishPush) GetRtaskId() int32 { @@ -414,7 +184,7 @@ type RtaskFinishIdsPush struct { func (x *RtaskFinishIdsPush) Reset() { *x = RtaskFinishIdsPush{} if protoimpl.UnsafeEnabled { - mi := &file_rtask_rtask_msg_proto_msgTypes[7] + mi := &file_rtask_rtask_msg_proto_msgTypes[3] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -427,7 +197,7 @@ func (x *RtaskFinishIdsPush) String() string { func (*RtaskFinishIdsPush) ProtoMessage() {} func (x *RtaskFinishIdsPush) ProtoReflect() protoreflect.Message { - mi := &file_rtask_rtask_msg_proto_msgTypes[7] + mi := &file_rtask_rtask_msg_proto_msgTypes[3] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -440,7 +210,7 @@ func (x *RtaskFinishIdsPush) ProtoReflect() protoreflect.Message { // Deprecated: Use RtaskFinishIdsPush.ProtoReflect.Descriptor instead. func (*RtaskFinishIdsPush) Descriptor() ([]byte, []int) { - return file_rtask_rtask_msg_proto_rawDescGZIP(), []int{7} + return file_rtask_rtask_msg_proto_rawDescGZIP(), []int{3} } func (x *RtaskFinishIdsPush) GetRtaskId() []int32 { @@ -457,347 +227,6 @@ func (x *RtaskFinishIdsPush) GetGroupId() int32 { return 0 } -// 领奖 -type RtaskGetRewardReq struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - RtaskId int32 `protobuf:"varint,1,opt,name=rtaskId,proto3" json:"rtaskId"` - RtaskSubId int32 `protobuf:"varint,2,opt,name=rtaskSubId,proto3" json:"rtaskSubId"` //支线任务ID -} - -func (x *RtaskGetRewardReq) Reset() { - *x = RtaskGetRewardReq{} - if protoimpl.UnsafeEnabled { - mi := &file_rtask_rtask_msg_proto_msgTypes[8] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *RtaskGetRewardReq) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*RtaskGetRewardReq) ProtoMessage() {} - -func (x *RtaskGetRewardReq) ProtoReflect() protoreflect.Message { - mi := &file_rtask_rtask_msg_proto_msgTypes[8] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use RtaskGetRewardReq.ProtoReflect.Descriptor instead. -func (*RtaskGetRewardReq) Descriptor() ([]byte, []int) { - return file_rtask_rtask_msg_proto_rawDescGZIP(), []int{8} -} - -func (x *RtaskGetRewardReq) GetRtaskId() int32 { - if x != nil { - return x.RtaskId - } - return 0 -} - -func (x *RtaskGetRewardReq) GetRtaskSubId() int32 { - if x != nil { - return x.RtaskSubId - } - return 0 -} - -type RtaskGetRewardResp struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - RtaskId int32 `protobuf:"varint,1,opt,name=rtaskId,proto3" json:"rtaskId"` - RtaskSubId int32 `protobuf:"varint,2,opt,name=rtaskSubId,proto3" json:"rtaskSubId"` //支线任务ID -} - -func (x *RtaskGetRewardResp) Reset() { - *x = RtaskGetRewardResp{} - if protoimpl.UnsafeEnabled { - mi := &file_rtask_rtask_msg_proto_msgTypes[9] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *RtaskGetRewardResp) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*RtaskGetRewardResp) ProtoMessage() {} - -func (x *RtaskGetRewardResp) ProtoReflect() protoreflect.Message { - mi := &file_rtask_rtask_msg_proto_msgTypes[9] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use RtaskGetRewardResp.ProtoReflect.Descriptor instead. -func (*RtaskGetRewardResp) Descriptor() ([]byte, []int) { - return file_rtask_rtask_msg_proto_rawDescGZIP(), []int{9} -} - -func (x *RtaskGetRewardResp) GetRtaskId() int32 { - if x != nil { - return x.RtaskId - } - return 0 -} - -func (x *RtaskGetRewardResp) GetRtaskSubId() int32 { - if x != nil { - return x.RtaskSubId - } - return 0 -} - -// 开始战斗 -type RtaskBattleStartReq struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - BattleConfId int32 `protobuf:"varint,1,opt,name=battleConfId,proto3" json:"battleConfId"` //战斗配表ID - Leadpos int32 `protobuf:"varint,3,opt,name=leadpos,proto3" json:"leadpos"` //队长位置 - Teamids []string `protobuf:"bytes,4,rep,name=teamids,proto3" json:"teamids"` //阵容信息 -} - -func (x *RtaskBattleStartReq) Reset() { - *x = RtaskBattleStartReq{} - if protoimpl.UnsafeEnabled { - mi := &file_rtask_rtask_msg_proto_msgTypes[10] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *RtaskBattleStartReq) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*RtaskBattleStartReq) ProtoMessage() {} - -func (x *RtaskBattleStartReq) ProtoReflect() protoreflect.Message { - mi := &file_rtask_rtask_msg_proto_msgTypes[10] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use RtaskBattleStartReq.ProtoReflect.Descriptor instead. -func (*RtaskBattleStartReq) Descriptor() ([]byte, []int) { - return file_rtask_rtask_msg_proto_rawDescGZIP(), []int{10} -} - -func (x *RtaskBattleStartReq) GetBattleConfId() int32 { - if x != nil { - return x.BattleConfId - } - return 0 -} - -func (x *RtaskBattleStartReq) GetLeadpos() int32 { - if x != nil { - return x.Leadpos - } - return 0 -} - -func (x *RtaskBattleStartReq) GetTeamids() []string { - if x != nil { - return x.Teamids - } - return nil -} - -type RtaskBattleStartResp struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - Info *BattleInfo `protobuf:"bytes,1,opt,name=info,proto3" json:"info"` //战斗信息 -} - -func (x *RtaskBattleStartResp) Reset() { - *x = RtaskBattleStartResp{} - if protoimpl.UnsafeEnabled { - mi := &file_rtask_rtask_msg_proto_msgTypes[11] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *RtaskBattleStartResp) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*RtaskBattleStartResp) ProtoMessage() {} - -func (x *RtaskBattleStartResp) ProtoReflect() protoreflect.Message { - mi := &file_rtask_rtask_msg_proto_msgTypes[11] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use RtaskBattleStartResp.ProtoReflect.Descriptor instead. -func (*RtaskBattleStartResp) Descriptor() ([]byte, []int) { - return file_rtask_rtask_msg_proto_rawDescGZIP(), []int{11} -} - -func (x *RtaskBattleStartResp) GetInfo() *BattleInfo { - if x != nil { - return x.Info - } - return nil -} - -// 战斗完成 -type RtaskBattleFinishReq struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - RtaskId int32 `protobuf:"varint,1,opt,name=rtaskId,proto3" json:"rtaskId"` //任务ID - RtaskSubId int32 `protobuf:"varint,2,opt,name=rtaskSubId,proto3" json:"rtaskSubId"` //支线任务ID - ChooseId int32 `protobuf:"varint,3,opt,name=chooseId,proto3" json:"chooseId"` //选项配置ID -} - -func (x *RtaskBattleFinishReq) Reset() { - *x = RtaskBattleFinishReq{} - if protoimpl.UnsafeEnabled { - mi := &file_rtask_rtask_msg_proto_msgTypes[12] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *RtaskBattleFinishReq) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*RtaskBattleFinishReq) ProtoMessage() {} - -func (x *RtaskBattleFinishReq) ProtoReflect() protoreflect.Message { - mi := &file_rtask_rtask_msg_proto_msgTypes[12] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use RtaskBattleFinishReq.ProtoReflect.Descriptor instead. -func (*RtaskBattleFinishReq) Descriptor() ([]byte, []int) { - return file_rtask_rtask_msg_proto_rawDescGZIP(), []int{12} -} - -func (x *RtaskBattleFinishReq) GetRtaskId() int32 { - if x != nil { - return x.RtaskId - } - return 0 -} - -func (x *RtaskBattleFinishReq) GetRtaskSubId() int32 { - if x != nil { - return x.RtaskSubId - } - return 0 -} - -func (x *RtaskBattleFinishReq) GetChooseId() int32 { - if x != nil { - return x.ChooseId - } - return 0 -} - -type RtaskBattleFinishResp struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - RtaskId int32 `protobuf:"varint,1,opt,name=rtaskId,proto3" json:"rtaskId"` //任务ID - RtaskSubId int32 `protobuf:"varint,2,opt,name=rtaskSubId,proto3" json:"rtaskSubId"` //支线任务ID -} - -func (x *RtaskBattleFinishResp) Reset() { - *x = RtaskBattleFinishResp{} - if protoimpl.UnsafeEnabled { - mi := &file_rtask_rtask_msg_proto_msgTypes[13] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *RtaskBattleFinishResp) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*RtaskBattleFinishResp) ProtoMessage() {} - -func (x *RtaskBattleFinishResp) ProtoReflect() protoreflect.Message { - mi := &file_rtask_rtask_msg_proto_msgTypes[13] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use RtaskBattleFinishResp.ProtoReflect.Descriptor instead. -func (*RtaskBattleFinishResp) Descriptor() ([]byte, []int) { - return file_rtask_rtask_msg_proto_rawDescGZIP(), []int{13} -} - -func (x *RtaskBattleFinishResp) GetRtaskId() int32 { - if x != nil { - return x.RtaskId - } - return 0 -} - -func (x *RtaskBattleFinishResp) GetRtaskSubId() int32 { - if x != nil { - return x.RtaskSubId - } - return 0 -} - //获取玩家任务记录 type RtaskGetrecordReq struct { state protoimpl.MessageState @@ -808,7 +237,7 @@ type RtaskGetrecordReq struct { func (x *RtaskGetrecordReq) Reset() { *x = RtaskGetrecordReq{} if protoimpl.UnsafeEnabled { - mi := &file_rtask_rtask_msg_proto_msgTypes[14] + mi := &file_rtask_rtask_msg_proto_msgTypes[4] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -821,7 +250,7 @@ func (x *RtaskGetrecordReq) String() string { func (*RtaskGetrecordReq) ProtoMessage() {} func (x *RtaskGetrecordReq) ProtoReflect() protoreflect.Message { - mi := &file_rtask_rtask_msg_proto_msgTypes[14] + mi := &file_rtask_rtask_msg_proto_msgTypes[4] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -834,7 +263,7 @@ func (x *RtaskGetrecordReq) ProtoReflect() protoreflect.Message { // Deprecated: Use RtaskGetrecordReq.ProtoReflect.Descriptor instead. func (*RtaskGetrecordReq) Descriptor() ([]byte, []int) { - return file_rtask_rtask_msg_proto_rawDescGZIP(), []int{14} + return file_rtask_rtask_msg_proto_rawDescGZIP(), []int{4} } type RtaskGetrecordResp struct { @@ -848,7 +277,7 @@ type RtaskGetrecordResp struct { func (x *RtaskGetrecordResp) Reset() { *x = RtaskGetrecordResp{} if protoimpl.UnsafeEnabled { - mi := &file_rtask_rtask_msg_proto_msgTypes[15] + mi := &file_rtask_rtask_msg_proto_msgTypes[5] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -861,7 +290,7 @@ func (x *RtaskGetrecordResp) String() string { func (*RtaskGetrecordResp) ProtoMessage() {} func (x *RtaskGetrecordResp) ProtoReflect() protoreflect.Message { - mi := &file_rtask_rtask_msg_proto_msgTypes[15] + mi := &file_rtask_rtask_msg_proto_msgTypes[5] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -874,7 +303,7 @@ func (x *RtaskGetrecordResp) ProtoReflect() protoreflect.Message { // Deprecated: Use RtaskGetrecordResp.ProtoReflect.Descriptor instead. func (*RtaskGetrecordResp) Descriptor() ([]byte, []int) { - return file_rtask_rtask_msg_proto_rawDescGZIP(), []int{15} + return file_rtask_rtask_msg_proto_rawDescGZIP(), []int{5} } func (x *RtaskGetrecordResp) GetRecord() *DBRtaskRecord { @@ -884,6 +313,109 @@ func (x *RtaskGetrecordResp) GetRecord() *DBRtaskRecord { return nil } +//任务触发 +type RtaskSendReq struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + TaskType int32 `protobuf:"varint,1,opt,name=taskType,proto3" json:"taskType"` //任务类型 + Params []int32 `protobuf:"varint,2,rep,packed,name=params,proto3" json:"params"` //任务参数 +} + +func (x *RtaskSendReq) Reset() { + *x = RtaskSendReq{} + if protoimpl.UnsafeEnabled { + mi := &file_rtask_rtask_msg_proto_msgTypes[6] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *RtaskSendReq) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*RtaskSendReq) ProtoMessage() {} + +func (x *RtaskSendReq) ProtoReflect() protoreflect.Message { + mi := &file_rtask_rtask_msg_proto_msgTypes[6] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use RtaskSendReq.ProtoReflect.Descriptor instead. +func (*RtaskSendReq) Descriptor() ([]byte, []int) { + return file_rtask_rtask_msg_proto_rawDescGZIP(), []int{6} +} + +func (x *RtaskSendReq) GetTaskType() int32 { + if x != nil { + return x.TaskType + } + return 0 +} + +func (x *RtaskSendReq) GetParams() []int32 { + if x != nil { + return x.Params + } + return nil +} + +type RtaskSendResp struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + IsSucc bool `protobuf:"varint,1,opt,name=isSucc,proto3" json:"isSucc"` +} + +func (x *RtaskSendResp) Reset() { + *x = RtaskSendResp{} + if protoimpl.UnsafeEnabled { + mi := &file_rtask_rtask_msg_proto_msgTypes[7] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *RtaskSendResp) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*RtaskSendResp) ProtoMessage() {} + +func (x *RtaskSendResp) ProtoReflect() protoreflect.Message { + mi := &file_rtask_rtask_msg_proto_msgTypes[7] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use RtaskSendResp.ProtoReflect.Descriptor instead. +func (*RtaskSendResp) Descriptor() ([]byte, []int) { + return file_rtask_rtask_msg_proto_rawDescGZIP(), []int{7} +} + +func (x *RtaskSendResp) GetIsSucc() bool { + if x != nil { + return x.IsSucc + } + return false +} + // 测试使用 type RtaskTestReq struct { state protoimpl.MessageState @@ -900,7 +432,7 @@ type RtaskTestReq struct { func (x *RtaskTestReq) Reset() { *x = RtaskTestReq{} if protoimpl.UnsafeEnabled { - mi := &file_rtask_rtask_msg_proto_msgTypes[16] + mi := &file_rtask_rtask_msg_proto_msgTypes[8] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -913,7 +445,7 @@ func (x *RtaskTestReq) String() string { func (*RtaskTestReq) ProtoMessage() {} func (x *RtaskTestReq) ProtoReflect() protoreflect.Message { - mi := &file_rtask_rtask_msg_proto_msgTypes[16] + mi := &file_rtask_rtask_msg_proto_msgTypes[8] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -926,7 +458,7 @@ func (x *RtaskTestReq) ProtoReflect() protoreflect.Message { // Deprecated: Use RtaskTestReq.ProtoReflect.Descriptor instead. func (*RtaskTestReq) Descriptor() ([]byte, []int) { - return file_rtask_rtask_msg_proto_rawDescGZIP(), []int{16} + return file_rtask_rtask_msg_proto_rawDescGZIP(), []int{8} } func (x *RtaskTestReq) GetRtaskType() int32 { @@ -976,7 +508,7 @@ type RtaskTestResp struct { func (x *RtaskTestResp) Reset() { *x = RtaskTestResp{} if protoimpl.UnsafeEnabled { - mi := &file_rtask_rtask_msg_proto_msgTypes[17] + mi := &file_rtask_rtask_msg_proto_msgTypes[9] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -989,7 +521,7 @@ func (x *RtaskTestResp) String() string { func (*RtaskTestResp) ProtoMessage() {} func (x *RtaskTestResp) ProtoReflect() protoreflect.Message { - mi := &file_rtask_rtask_msg_proto_msgTypes[17] + mi := &file_rtask_rtask_msg_proto_msgTypes[9] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1002,7 +534,7 @@ func (x *RtaskTestResp) ProtoReflect() protoreflect.Message { // Deprecated: Use RtaskTestResp.ProtoReflect.Descriptor instead. func (*RtaskTestResp) Descriptor() ([]byte, []int) { - return file_rtask_rtask_msg_proto_rawDescGZIP(), []int{17} + return file_rtask_rtask_msg_proto_rawDescGZIP(), []int{9} } func (x *RtaskTestResp) GetFlag() bool { @@ -1026,94 +558,48 @@ var file_rtask_rtask_msg_proto_rawDesc = []byte{ 0x67, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x17, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x2f, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x5f, 0x6d, 0x73, 0x67, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x14, 0x72, 0x74, 0x61, 0x73, 0x6b, 0x2f, 0x72, 0x74, 0x61, 0x73, 0x6b, 0x5f, 0x64, 0x62, - 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x49, 0x0a, 0x0d, 0x52, 0x74, 0x61, 0x73, 0x6b, 0x41, - 0x70, 0x70, 0x6c, 0x79, 0x52, 0x65, 0x71, 0x12, 0x18, 0x0a, 0x07, 0x72, 0x74, 0x61, 0x73, 0x6b, - 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x72, 0x74, 0x61, 0x73, 0x6b, 0x49, - 0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x72, 0x74, 0x61, 0x73, 0x6b, 0x53, 0x75, 0x62, 0x49, 0x64, 0x18, - 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0a, 0x72, 0x74, 0x61, 0x73, 0x6b, 0x53, 0x75, 0x62, 0x49, - 0x64, 0x22, 0x2a, 0x0a, 0x0e, 0x52, 0x74, 0x61, 0x73, 0x6b, 0x41, 0x70, 0x70, 0x6c, 0x79, 0x52, - 0x65, 0x73, 0x70, 0x12, 0x18, 0x0a, 0x07, 0x72, 0x74, 0x61, 0x73, 0x6b, 0x49, 0x64, 0x18, 0x01, - 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x72, 0x74, 0x61, 0x73, 0x6b, 0x49, 0x64, 0x22, 0x28, 0x0a, - 0x0c, 0x52, 0x74, 0x61, 0x73, 0x6b, 0x6c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x71, 0x12, 0x18, 0x0a, - 0x07, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, - 0x67, 0x72, 0x6f, 0x75, 0x70, 0x49, 0x64, 0x22, 0x45, 0x0a, 0x0d, 0x52, 0x74, 0x61, 0x73, 0x6b, - 0x6c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x73, 0x70, 0x12, 0x1a, 0x0a, 0x08, 0x72, 0x74, 0x61, 0x73, - 0x6b, 0x49, 0x64, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x05, 0x52, 0x08, 0x72, 0x74, 0x61, 0x73, - 0x6b, 0x49, 0x64, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x49, 0x64, 0x18, - 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x49, 0x64, 0x22, 0x66, - 0x0a, 0x0e, 0x52, 0x74, 0x61, 0x73, 0x6b, 0x43, 0x68, 0x6f, 0x6f, 0x73, 0x65, 0x52, 0x65, 0x71, - 0x12, 0x18, 0x0a, 0x07, 0x72, 0x74, 0x61, 0x73, 0x6b, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x05, 0x52, 0x07, 0x72, 0x74, 0x61, 0x73, 0x6b, 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x63, 0x68, - 0x6f, 0x6f, 0x73, 0x65, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x08, 0x63, 0x68, - 0x6f, 0x6f, 0x73, 0x65, 0x49, 0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x72, 0x74, 0x61, 0x73, 0x6b, 0x53, - 0x75, 0x62, 0x49, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0a, 0x72, 0x74, 0x61, 0x73, - 0x6b, 0x53, 0x75, 0x62, 0x49, 0x64, 0x22, 0x67, 0x0a, 0x0f, 0x52, 0x74, 0x61, 0x73, 0x6b, 0x43, - 0x68, 0x6f, 0x6f, 0x73, 0x65, 0x52, 0x65, 0x73, 0x70, 0x12, 0x18, 0x0a, 0x07, 0x72, 0x74, 0x61, - 0x73, 0x6b, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x72, 0x74, 0x61, 0x73, - 0x6b, 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x63, 0x68, 0x6f, 0x6f, 0x73, 0x65, 0x49, 0x64, 0x18, - 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x08, 0x63, 0x68, 0x6f, 0x6f, 0x73, 0x65, 0x49, 0x64, 0x12, - 0x1e, 0x0a, 0x0a, 0x72, 0x74, 0x61, 0x73, 0x6b, 0x53, 0x75, 0x62, 0x49, 0x64, 0x18, 0x03, 0x20, - 0x01, 0x28, 0x05, 0x52, 0x0a, 0x72, 0x74, 0x61, 0x73, 0x6b, 0x53, 0x75, 0x62, 0x49, 0x64, 0x22, - 0x2b, 0x0a, 0x0f, 0x52, 0x74, 0x61, 0x73, 0x6b, 0x46, 0x69, 0x6e, 0x69, 0x73, 0x68, 0x50, 0x75, - 0x73, 0x68, 0x12, 0x18, 0x0a, 0x07, 0x72, 0x74, 0x61, 0x73, 0x6b, 0x49, 0x64, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x05, 0x52, 0x07, 0x72, 0x74, 0x61, 0x73, 0x6b, 0x49, 0x64, 0x22, 0x48, 0x0a, 0x12, - 0x52, 0x74, 0x61, 0x73, 0x6b, 0x46, 0x69, 0x6e, 0x69, 0x73, 0x68, 0x49, 0x64, 0x73, 0x50, 0x75, - 0x73, 0x68, 0x12, 0x18, 0x0a, 0x07, 0x72, 0x74, 0x61, 0x73, 0x6b, 0x49, 0x64, 0x18, 0x01, 0x20, - 0x03, 0x28, 0x05, 0x52, 0x07, 0x72, 0x74, 0x61, 0x73, 0x6b, 0x49, 0x64, 0x12, 0x18, 0x0a, 0x07, - 0x67, 0x72, 0x6f, 0x75, 0x70, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x67, - 0x72, 0x6f, 0x75, 0x70, 0x49, 0x64, 0x22, 0x4d, 0x0a, 0x11, 0x52, 0x74, 0x61, 0x73, 0x6b, 0x47, - 0x65, 0x74, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x52, 0x65, 0x71, 0x12, 0x18, 0x0a, 0x07, 0x72, - 0x74, 0x61, 0x73, 0x6b, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x72, 0x74, - 0x61, 0x73, 0x6b, 0x49, 0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x72, 0x74, 0x61, 0x73, 0x6b, 0x53, 0x75, - 0x62, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0a, 0x72, 0x74, 0x61, 0x73, 0x6b, - 0x53, 0x75, 0x62, 0x49, 0x64, 0x22, 0x4e, 0x0a, 0x12, 0x52, 0x74, 0x61, 0x73, 0x6b, 0x47, 0x65, - 0x74, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x52, 0x65, 0x73, 0x70, 0x12, 0x18, 0x0a, 0x07, 0x72, - 0x74, 0x61, 0x73, 0x6b, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x72, 0x74, - 0x61, 0x73, 0x6b, 0x49, 0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x72, 0x74, 0x61, 0x73, 0x6b, 0x53, 0x75, - 0x62, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0a, 0x72, 0x74, 0x61, 0x73, 0x6b, - 0x53, 0x75, 0x62, 0x49, 0x64, 0x22, 0x6d, 0x0a, 0x13, 0x52, 0x74, 0x61, 0x73, 0x6b, 0x42, 0x61, - 0x74, 0x74, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x72, 0x74, 0x52, 0x65, 0x71, 0x12, 0x22, 0x0a, 0x0c, - 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x43, 0x6f, 0x6e, 0x66, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, - 0x28, 0x05, 0x52, 0x0c, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x43, 0x6f, 0x6e, 0x66, 0x49, 0x64, - 0x12, 0x18, 0x0a, 0x07, 0x6c, 0x65, 0x61, 0x64, 0x70, 0x6f, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, - 0x05, 0x52, 0x07, 0x6c, 0x65, 0x61, 0x64, 0x70, 0x6f, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x74, 0x65, - 0x61, 0x6d, 0x69, 0x64, 0x73, 0x18, 0x04, 0x20, 0x03, 0x28, 0x09, 0x52, 0x07, 0x74, 0x65, 0x61, - 0x6d, 0x69, 0x64, 0x73, 0x22, 0x37, 0x0a, 0x14, 0x52, 0x74, 0x61, 0x73, 0x6b, 0x42, 0x61, 0x74, - 0x74, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x72, 0x74, 0x52, 0x65, 0x73, 0x70, 0x12, 0x1f, 0x0a, 0x04, - 0x69, 0x6e, 0x66, 0x6f, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0b, 0x2e, 0x42, 0x61, 0x74, - 0x74, 0x6c, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x04, 0x69, 0x6e, 0x66, 0x6f, 0x22, 0x6c, 0x0a, - 0x14, 0x52, 0x74, 0x61, 0x73, 0x6b, 0x42, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x46, 0x69, 0x6e, 0x69, - 0x73, 0x68, 0x52, 0x65, 0x71, 0x12, 0x18, 0x0a, 0x07, 0x72, 0x74, 0x61, 0x73, 0x6b, 0x49, 0x64, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x72, 0x74, 0x61, 0x73, 0x6b, 0x49, 0x64, 0x12, - 0x1e, 0x0a, 0x0a, 0x72, 0x74, 0x61, 0x73, 0x6b, 0x53, 0x75, 0x62, 0x49, 0x64, 0x18, 0x02, 0x20, - 0x01, 0x28, 0x05, 0x52, 0x0a, 0x72, 0x74, 0x61, 0x73, 0x6b, 0x53, 0x75, 0x62, 0x49, 0x64, 0x12, - 0x1a, 0x0a, 0x08, 0x63, 0x68, 0x6f, 0x6f, 0x73, 0x65, 0x49, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, - 0x05, 0x52, 0x08, 0x63, 0x68, 0x6f, 0x6f, 0x73, 0x65, 0x49, 0x64, 0x22, 0x51, 0x0a, 0x15, 0x52, - 0x74, 0x61, 0x73, 0x6b, 0x42, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x46, 0x69, 0x6e, 0x69, 0x73, 0x68, - 0x52, 0x65, 0x73, 0x70, 0x12, 0x18, 0x0a, 0x07, 0x72, 0x74, 0x61, 0x73, 0x6b, 0x49, 0x64, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x72, 0x74, 0x61, 0x73, 0x6b, 0x49, 0x64, 0x12, 0x1e, - 0x0a, 0x0a, 0x72, 0x74, 0x61, 0x73, 0x6b, 0x53, 0x75, 0x62, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, - 0x28, 0x05, 0x52, 0x0a, 0x72, 0x74, 0x61, 0x73, 0x6b, 0x53, 0x75, 0x62, 0x49, 0x64, 0x22, 0x13, + 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x28, 0x0a, 0x0c, 0x52, 0x74, 0x61, 0x73, 0x6b, 0x6c, + 0x69, 0x73, 0x74, 0x52, 0x65, 0x71, 0x12, 0x18, 0x0a, 0x07, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x49, + 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x49, 0x64, + 0x22, 0x45, 0x0a, 0x0d, 0x52, 0x74, 0x61, 0x73, 0x6b, 0x6c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x73, + 0x70, 0x12, 0x1a, 0x0a, 0x08, 0x72, 0x74, 0x61, 0x73, 0x6b, 0x49, 0x64, 0x73, 0x18, 0x01, 0x20, + 0x03, 0x28, 0x05, 0x52, 0x08, 0x72, 0x74, 0x61, 0x73, 0x6b, 0x49, 0x64, 0x73, 0x12, 0x18, 0x0a, + 0x07, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, + 0x67, 0x72, 0x6f, 0x75, 0x70, 0x49, 0x64, 0x22, 0x2b, 0x0a, 0x0f, 0x52, 0x74, 0x61, 0x73, 0x6b, + 0x46, 0x69, 0x6e, 0x69, 0x73, 0x68, 0x50, 0x75, 0x73, 0x68, 0x12, 0x18, 0x0a, 0x07, 0x72, 0x74, + 0x61, 0x73, 0x6b, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x72, 0x74, 0x61, + 0x73, 0x6b, 0x49, 0x64, 0x22, 0x48, 0x0a, 0x12, 0x52, 0x74, 0x61, 0x73, 0x6b, 0x46, 0x69, 0x6e, + 0x69, 0x73, 0x68, 0x49, 0x64, 0x73, 0x50, 0x75, 0x73, 0x68, 0x12, 0x18, 0x0a, 0x07, 0x72, 0x74, + 0x61, 0x73, 0x6b, 0x49, 0x64, 0x18, 0x01, 0x20, 0x03, 0x28, 0x05, 0x52, 0x07, 0x72, 0x74, 0x61, + 0x73, 0x6b, 0x49, 0x64, 0x12, 0x18, 0x0a, 0x07, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x49, 0x64, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x49, 0x64, 0x22, 0x13, 0x0a, 0x11, 0x52, 0x74, 0x61, 0x73, 0x6b, 0x47, 0x65, 0x74, 0x72, 0x65, 0x63, 0x6f, 0x72, 0x64, 0x52, 0x65, 0x71, 0x22, 0x3c, 0x0a, 0x12, 0x52, 0x74, 0x61, 0x73, 0x6b, 0x47, 0x65, 0x74, 0x72, 0x65, 0x63, 0x6f, 0x72, 0x64, 0x52, 0x65, 0x73, 0x70, 0x12, 0x26, 0x0a, 0x06, 0x72, 0x65, 0x63, 0x6f, 0x72, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x44, 0x42, 0x52, 0x74, 0x61, 0x73, 0x6b, 0x52, 0x65, 0x63, 0x6f, 0x72, 0x64, 0x52, 0x06, 0x72, 0x65, 0x63, 0x6f, 0x72, - 0x64, 0x22, 0x94, 0x01, 0x0a, 0x0c, 0x52, 0x74, 0x61, 0x73, 0x6b, 0x54, 0x65, 0x73, 0x74, 0x52, - 0x65, 0x71, 0x12, 0x1c, 0x0a, 0x09, 0x72, 0x74, 0x61, 0x73, 0x6b, 0x54, 0x79, 0x70, 0x65, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x09, 0x72, 0x74, 0x61, 0x73, 0x6b, 0x54, 0x79, 0x70, 0x65, - 0x12, 0x16, 0x0a, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x05, - 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x63, 0x6f, 0x6e, 0x64, - 0x69, 0x49, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x63, 0x6f, 0x6e, 0x64, 0x69, - 0x49, 0x64, 0x12, 0x18, 0x0a, 0x07, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x49, 0x64, 0x18, 0x04, 0x20, - 0x01, 0x28, 0x05, 0x52, 0x07, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, - 0x72, 0x74, 0x61, 0x73, 0x6b, 0x49, 0x64, 0x73, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, - 0x72, 0x74, 0x61, 0x73, 0x6b, 0x49, 0x64, 0x73, 0x22, 0x3f, 0x0a, 0x0d, 0x52, 0x74, 0x61, 0x73, - 0x6b, 0x54, 0x65, 0x73, 0x74, 0x52, 0x65, 0x73, 0x70, 0x12, 0x12, 0x0a, 0x04, 0x66, 0x6c, 0x61, - 0x67, 0x18, 0x01, 0x20, 0x01, 0x28, 0x08, 0x52, 0x04, 0x66, 0x6c, 0x61, 0x67, 0x12, 0x1a, 0x0a, - 0x08, 0x72, 0x74, 0x61, 0x73, 0x6b, 0x49, 0x64, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x05, 0x52, - 0x08, 0x72, 0x74, 0x61, 0x73, 0x6b, 0x49, 0x64, 0x73, 0x42, 0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70, - 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x64, 0x22, 0x42, 0x0a, 0x0c, 0x52, 0x74, 0x61, 0x73, 0x6b, 0x53, 0x65, 0x6e, 0x64, 0x52, 0x65, + 0x71, 0x12, 0x1a, 0x0a, 0x08, 0x74, 0x61, 0x73, 0x6b, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x05, 0x52, 0x08, 0x74, 0x61, 0x73, 0x6b, 0x54, 0x79, 0x70, 0x65, 0x12, 0x16, 0x0a, + 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x05, 0x52, 0x06, 0x70, + 0x61, 0x72, 0x61, 0x6d, 0x73, 0x22, 0x27, 0x0a, 0x0d, 0x52, 0x74, 0x61, 0x73, 0x6b, 0x53, 0x65, + 0x6e, 0x64, 0x52, 0x65, 0x73, 0x70, 0x12, 0x16, 0x0a, 0x06, 0x69, 0x73, 0x53, 0x75, 0x63, 0x63, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x08, 0x52, 0x06, 0x69, 0x73, 0x53, 0x75, 0x63, 0x63, 0x22, 0x94, + 0x01, 0x0a, 0x0c, 0x52, 0x74, 0x61, 0x73, 0x6b, 0x54, 0x65, 0x73, 0x74, 0x52, 0x65, 0x71, 0x12, + 0x1c, 0x0a, 0x09, 0x72, 0x74, 0x61, 0x73, 0x6b, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, + 0x28, 0x05, 0x52, 0x09, 0x72, 0x74, 0x61, 0x73, 0x6b, 0x54, 0x79, 0x70, 0x65, 0x12, 0x16, 0x0a, + 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x05, 0x52, 0x06, 0x70, + 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x63, 0x6f, 0x6e, 0x64, 0x69, 0x49, 0x64, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x63, 0x6f, 0x6e, 0x64, 0x69, 0x49, 0x64, 0x12, + 0x18, 0x0a, 0x07, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x49, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x05, + 0x52, 0x07, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x72, 0x74, 0x61, + 0x73, 0x6b, 0x49, 0x64, 0x73, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x72, 0x74, 0x61, + 0x73, 0x6b, 0x49, 0x64, 0x73, 0x22, 0x3f, 0x0a, 0x0d, 0x52, 0x74, 0x61, 0x73, 0x6b, 0x54, 0x65, + 0x73, 0x74, 0x52, 0x65, 0x73, 0x70, 0x12, 0x12, 0x0a, 0x04, 0x66, 0x6c, 0x61, 0x67, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x08, 0x52, 0x04, 0x66, 0x6c, 0x61, 0x67, 0x12, 0x1a, 0x0a, 0x08, 0x72, 0x74, + 0x61, 0x73, 0x6b, 0x49, 0x64, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x05, 0x52, 0x08, 0x72, 0x74, + 0x61, 0x73, 0x6b, 0x49, 0x64, 0x73, 0x42, 0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70, 0x62, 0x62, 0x06, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -1128,37 +614,27 @@ func file_rtask_rtask_msg_proto_rawDescGZIP() []byte { return file_rtask_rtask_msg_proto_rawDescData } -var file_rtask_rtask_msg_proto_msgTypes = make([]protoimpl.MessageInfo, 18) +var file_rtask_rtask_msg_proto_msgTypes = make([]protoimpl.MessageInfo, 10) var file_rtask_rtask_msg_proto_goTypes = []interface{}{ - (*RtaskApplyReq)(nil), // 0: RtaskApplyReq - (*RtaskApplyResp)(nil), // 1: RtaskApplyResp - (*RtasklistReq)(nil), // 2: RtasklistReq - (*RtasklistResp)(nil), // 3: RtasklistResp - (*RtaskChooseReq)(nil), // 4: RtaskChooseReq - (*RtaskChooseResp)(nil), // 5: RtaskChooseResp - (*RtaskFinishPush)(nil), // 6: RtaskFinishPush - (*RtaskFinishIdsPush)(nil), // 7: RtaskFinishIdsPush - (*RtaskGetRewardReq)(nil), // 8: RtaskGetRewardReq - (*RtaskGetRewardResp)(nil), // 9: RtaskGetRewardResp - (*RtaskBattleStartReq)(nil), // 10: RtaskBattleStartReq - (*RtaskBattleStartResp)(nil), // 11: RtaskBattleStartResp - (*RtaskBattleFinishReq)(nil), // 12: RtaskBattleFinishReq - (*RtaskBattleFinishResp)(nil), // 13: RtaskBattleFinishResp - (*RtaskGetrecordReq)(nil), // 14: RtaskGetrecordReq - (*RtaskGetrecordResp)(nil), // 15: RtaskGetrecordResp - (*RtaskTestReq)(nil), // 16: RtaskTestReq - (*RtaskTestResp)(nil), // 17: RtaskTestResp - (*BattleInfo)(nil), // 18: BattleInfo - (*DBRtaskRecord)(nil), // 19: DBRtaskRecord + (*RtasklistReq)(nil), // 0: RtasklistReq + (*RtasklistResp)(nil), // 1: RtasklistResp + (*RtaskFinishPush)(nil), // 2: RtaskFinishPush + (*RtaskFinishIdsPush)(nil), // 3: RtaskFinishIdsPush + (*RtaskGetrecordReq)(nil), // 4: RtaskGetrecordReq + (*RtaskGetrecordResp)(nil), // 5: RtaskGetrecordResp + (*RtaskSendReq)(nil), // 6: RtaskSendReq + (*RtaskSendResp)(nil), // 7: RtaskSendResp + (*RtaskTestReq)(nil), // 8: RtaskTestReq + (*RtaskTestResp)(nil), // 9: RtaskTestResp + (*DBRtaskRecord)(nil), // 10: DBRtaskRecord } var file_rtask_rtask_msg_proto_depIdxs = []int32{ - 18, // 0: RtaskBattleStartResp.info:type_name -> BattleInfo - 19, // 1: RtaskGetrecordResp.record:type_name -> DBRtaskRecord - 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 + 10, // 0: RtaskGetrecordResp.record:type_name -> DBRtaskRecord + 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 } func init() { file_rtask_rtask_msg_proto_init() } @@ -1170,30 +646,6 @@ func file_rtask_rtask_msg_proto_init() { file_rtask_rtask_db_proto_init() if !protoimpl.UnsafeEnabled { file_rtask_rtask_msg_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*RtaskApplyReq); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_rtask_rtask_msg_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*RtaskApplyResp); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_rtask_rtask_msg_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*RtasklistReq); i { case 0: return &v.state @@ -1205,7 +657,7 @@ func file_rtask_rtask_msg_proto_init() { return nil } } - file_rtask_rtask_msg_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + file_rtask_rtask_msg_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*RtasklistResp); i { case 0: return &v.state @@ -1217,31 +669,7 @@ func file_rtask_rtask_msg_proto_init() { return nil } } - file_rtask_rtask_msg_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*RtaskChooseReq); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_rtask_rtask_msg_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*RtaskChooseResp); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_rtask_rtask_msg_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { + file_rtask_rtask_msg_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*RtaskFinishPush); i { case 0: return &v.state @@ -1253,7 +681,7 @@ func file_rtask_rtask_msg_proto_init() { return nil } } - file_rtask_rtask_msg_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} { + file_rtask_rtask_msg_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*RtaskFinishIdsPush); i { case 0: return &v.state @@ -1265,79 +693,7 @@ func file_rtask_rtask_msg_proto_init() { return nil } } - file_rtask_rtask_msg_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*RtaskGetRewardReq); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_rtask_rtask_msg_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*RtaskGetRewardResp); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_rtask_rtask_msg_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*RtaskBattleStartReq); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_rtask_rtask_msg_proto_msgTypes[11].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*RtaskBattleStartResp); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_rtask_rtask_msg_proto_msgTypes[12].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*RtaskBattleFinishReq); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_rtask_rtask_msg_proto_msgTypes[13].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*RtaskBattleFinishResp); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_rtask_rtask_msg_proto_msgTypes[14].Exporter = func(v interface{}, i int) interface{} { + file_rtask_rtask_msg_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*RtaskGetrecordReq); i { case 0: return &v.state @@ -1349,7 +705,7 @@ func file_rtask_rtask_msg_proto_init() { return nil } } - file_rtask_rtask_msg_proto_msgTypes[15].Exporter = func(v interface{}, i int) interface{} { + file_rtask_rtask_msg_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*RtaskGetrecordResp); i { case 0: return &v.state @@ -1361,7 +717,31 @@ func file_rtask_rtask_msg_proto_init() { return nil } } - file_rtask_rtask_msg_proto_msgTypes[16].Exporter = func(v interface{}, i int) interface{} { + file_rtask_rtask_msg_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*RtaskSendReq); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_rtask_rtask_msg_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*RtaskSendResp); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_rtask_rtask_msg_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*RtaskTestReq); i { case 0: return &v.state @@ -1373,7 +753,7 @@ func file_rtask_rtask_msg_proto_init() { return nil } } - file_rtask_rtask_msg_proto_msgTypes[17].Exporter = func(v interface{}, i int) interface{} { + file_rtask_rtask_msg_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*RtaskTestResp); i { case 0: return &v.state @@ -1392,7 +772,7 @@ func file_rtask_rtask_msg_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_rtask_rtask_msg_proto_rawDesc, NumEnums: 0, - NumMessages: 18, + NumMessages: 10, NumExtensions: 0, NumServices: 0, }, diff --git a/pb/userexpand.pb.go b/pb/userexpand.pb.go index 9203c6dac..aad7c7259 100644 --- a/pb/userexpand.pb.go +++ b/pb/userexpand.pb.go @@ -55,7 +55,7 @@ type DBUserExpand struct { Recovertimeunifiedticket int64 `protobuf:"varint,31,opt,name=recovertimeunifiedticket,proto3" json:"recovertimeunifiedticket"` //@go_tags(`bson:"recovertimeunifiedticket"`)同意门票恢复时间 SociatyTicketBuyNum int32 `protobuf:"varint,32,opt,name=sociatyTicketBuyNum,proto3" json:"sociatyTicketBuyNum" bson:"sociatyTicketBuyNum"` //公会boss挑战券购买次数 SociatyTicket int32 `protobuf:"varint,33,opt,name=sociatyTicket,proto3" json:"sociatyTicket" bson:"sociatyTicket"` //公会boss挑战券数量 - Mline map[int32]int32 `protobuf:"bytes,34,rep,name=mline,proto3" json:"mline" protobuf_key:"varint,1,opt,name=key,proto3" protobuf_val:"varint,2,opt,name=value,proto3" bson:"mline"` //主线关卡最大进度 + Mline map[int32]int32 `protobuf:"bytes,34,rep,name=mline,proto3" json:"mline" protobuf_key:"varint,1,opt,name=key,proto3" protobuf_val:"varint,2,opt,name=value,proto3" bson:"mline"` //主线关卡最大进度 key难度val是关卡ID } func (x *DBUserExpand) Reset() { From 5581657283dbfcca9a94b1269147a225a58852b5 Mon Sep 17 00:00:00 2001 From: meixiongfeng <766881921@qq.com> Date: Thu, 2 Feb 2023 16:57:09 +0800 Subject: [PATCH 15/17] =?UTF-8?q?=E6=89=A9=E5=B1=95=E5=AD=97=E6=AE=B5?= =?UTF-8?q?=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- modules/hero/api_drawCard.go | 3 +- modules/hero/module.go | 6 +- modules/user/module.go | 18 +-- pb/userexpand.pb.go | 212 ++++++++++++++++------------------- 4 files changed, 111 insertions(+), 128 deletions(-) diff --git a/modules/hero/api_drawCard.go b/modules/hero/api_drawCard.go index 51a6bd3d1..78d07374e 100644 --- a/modules/hero/api_drawCard.go +++ b/modules/hero/api_drawCard.go @@ -65,8 +65,9 @@ func (this *apiComp) DrawCard(session comm.IUserSession, req *pb.HeroDrawCardReq } for i := 0; i < int(req.DrawCount); i++ { - pool = this.module.modelHero.CheckPool(drawCount, cfgDraw) drawCount += 1 + pool = this.module.modelHero.CheckPool(drawCount, cfgDraw) + strPool = append(strPool, pool) ret := this.module.CheckCondition(session.GetUserId()) if ret == true { // 命中插入5星英雄 diff --git a/modules/hero/module.go b/modules/hero/module.go index ba455018b..5b7db230d 100644 --- a/modules/hero/module.go +++ b/modules/hero/module.go @@ -616,11 +616,7 @@ func (this *Hero) CheckLvNum(uid string, lv int32) int32 { } func (this *Hero) GetTujianHeroNum(uid string) int32 { - if result, err1 := this.ModuleUser.GetUserExpand(uid); err1 == nil { - tujian := result.GetTujian() - return int32(len(tujian)) - } - return 0 + return int32(len(this.modelHero.getHeroList(uid))) } ////拥有觉醒至A级的B星英雄N个 diff --git a/modules/user/module.go b/modules/user/module.go index 6c8bfbfc4..399373822 100644 --- a/modules/user/module.go +++ b/modules/user/module.go @@ -628,16 +628,18 @@ func (this *User) RpcQueryUser(ctx context.Context, req *pb.NameReq, reply *pb.U } func (this *User) CheckTujianHero(session comm.IUserSession, heros []string) []bool { sz := make([]bool, len(heros)) - - userEx, err := this.GetUserExpand(session.GetUserId()) - if err != nil { - return sz - } - for i, heroid := range heros { - if _, ok := userEx.Tujian[heroid]; ok { - sz[i] = true + index := 0 + list := this.ModuleHero.GetHeroList(session.GetUserId()) + for _, v1 := range heros { + for _, h := range list { + if v1 == h.HeroID { + sz[index] = true + index++ + break + } } } + return sz } diff --git a/pb/userexpand.pb.go b/pb/userexpand.pb.go index 9203c6dac..aaa69f7c9 100644 --- a/pb/userexpand.pb.go +++ b/pb/userexpand.pb.go @@ -26,36 +26,36 @@ type DBUserExpand struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id"` //主键id - Uid string `protobuf:"bytes,2,opt,name=uid,proto3" json:"uid"` //用户id - Lastreadnotiftime int64 `protobuf:"varint,3,opt,name=lastreadnotiftime,proto3" json:"lastreadnotiftime"` //最后阅读公告时间 - LastInitdataTime int64 `protobuf:"varint,4,opt,name=lastInitdataTime,proto3" json:"lastInitdataTime"` //上次初始数据时间 - InitdataCount uint32 `protobuf:"varint,5,opt,name=initdataCount,proto3" json:"initdataCount"` //今日初始累计次数 - Chatchannel int32 `protobuf:"varint,6,opt,name=chatchannel,proto3" json:"chatchannel"` //跨服聊天频道 - ModifynameCount int32 `protobuf:"varint,7,opt,name=modifynameCount,proto3" json:"modifynameCount"` //修改昵称次数 - Tujian map[string]int32 `protobuf:"bytes,8,rep,name=tujian,proto3" json:"tujian" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"varint,2,opt,name=value,proto3"` //图鉴 - Activeday int32 `protobuf:"varint,11,opt,name=activeday,proto3" json:"activeday"` //日活跃度 - Activeweek int32 `protobuf:"varint,12,opt,name=activeweek,proto3" json:"activeweek"` //周活跃度 - Sign string `protobuf:"bytes,13,opt,name=sign,proto3" json:"sign"` //用户签名 - FriendPoint int32 `protobuf:"varint,14,opt,name=friendPoint,proto3" json:"friendPoint" bson:"friendPoint"` //友情点 - FriendPointID int32 `protobuf:"varint,15,opt,name=friendPointID,proto3" json:"friendPointID" bson:"friendPointID"` //每日获赠友情点 - FriendPointOD int32 `protobuf:"varint,16,opt,name=friendPointOD,proto3" json:"friendPointOD" bson:"friendPointOD"` //每日送出友情点 - LoginAddCount int32 `protobuf:"varint,19,opt,name=loginAddCount,proto3" json:"loginAddCount"` //@go_tasgs(`bson:"loginAddCount"`) 累计登录天数 - LoginContinueCount int32 `protobuf:"varint,20,opt,name=loginContinueCount,proto3" json:"loginContinueCount"` //@go_tasgs(`bson:"loginContinueCount"`) 连续登录天数 - RtaskId int32 `protobuf:"varint,21,opt,name=rtaskId,proto3" json:"rtaskId" bson:"rtaskId"` // 当前完成的随机任务ID - TeamHeroIds []string `protobuf:"bytes,22,rep,name=teamHeroIds,proto3" json:"teamHeroIds" bson:"teamHeroIds"` //阵容英雄IDs - SociatyId string `protobuf:"bytes,23,opt,name=sociatyId,proto3" json:"sociatyId" bson:"sociatyId"` //公会ID - SociatyCd int64 `protobuf:"varint,24,opt,name=sociatyCd,proto3" json:"sociatyCd" bson:"sociatyCd"` //主动退出CD - Guildcoin int32 `protobuf:"varint,25,opt,name=guildcoin,proto3" json:"guildcoin" bson:"guildcoin"` //公会币 - Arenacoin int32 `protobuf:"varint,26,opt,name=arenacoin,proto3" json:"arenacoin" bson:"arenacoin"` //竞技场币 - Physicalbuynum int32 `protobuf:"varint,27,opt,name=physicalbuynum,proto3" json:"physicalbuynum"` //@go_tags(`bson:"physicalbuynum"`)体力购买次数 - PhysicalbuyLasttime int64 `protobuf:"varint,28,opt,name=physicalbuyLasttime,proto3" json:"physicalbuyLasttime"` //@go_tags(`bson:"physicalbuyLasttime"`)最后购买体力事件 - Buyunifiedticket int32 `protobuf:"varint,29,opt,name=buyunifiedticket,proto3" json:"buyunifiedticket"` //@go_tags(`bson:"buyunifiedticket"`)购买统一入场门票次数 - Lasttimeunifiedticket int64 `protobuf:"varint,30,opt,name=lasttimeunifiedticket,proto3" json:"lasttimeunifiedticket"` //@go_tags(`bson:"lasttimeunifiedticket"`)最后购买统一入场门票时间 - Recovertimeunifiedticket int64 `protobuf:"varint,31,opt,name=recovertimeunifiedticket,proto3" json:"recovertimeunifiedticket"` //@go_tags(`bson:"recovertimeunifiedticket"`)同意门票恢复时间 - SociatyTicketBuyNum int32 `protobuf:"varint,32,opt,name=sociatyTicketBuyNum,proto3" json:"sociatyTicketBuyNum" bson:"sociatyTicketBuyNum"` //公会boss挑战券购买次数 - SociatyTicket int32 `protobuf:"varint,33,opt,name=sociatyTicket,proto3" json:"sociatyTicket" bson:"sociatyTicket"` //公会boss挑战券数量 - Mline map[int32]int32 `protobuf:"bytes,34,rep,name=mline,proto3" json:"mline" protobuf_key:"varint,1,opt,name=key,proto3" protobuf_val:"varint,2,opt,name=value,proto3" bson:"mline"` //主线关卡最大进度 + Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id"` //主键id + Uid string `protobuf:"bytes,2,opt,name=uid,proto3" json:"uid"` //用户id + Lastreadnotiftime int64 `protobuf:"varint,3,opt,name=lastreadnotiftime,proto3" json:"lastreadnotiftime"` //最后阅读公告时间 + LastInitdataTime int64 `protobuf:"varint,4,opt,name=lastInitdataTime,proto3" json:"lastInitdataTime"` //上次初始数据时间 + InitdataCount uint32 `protobuf:"varint,5,opt,name=initdataCount,proto3" json:"initdataCount"` //今日初始累计次数 + Chatchannel int32 `protobuf:"varint,6,opt,name=chatchannel,proto3" json:"chatchannel"` //跨服聊天频道 + ModifynameCount int32 `protobuf:"varint,7,opt,name=modifynameCount,proto3" json:"modifynameCount"` //修改昵称次数 + //map tujian = 8; //图鉴 + Activeday int32 `protobuf:"varint,11,opt,name=activeday,proto3" json:"activeday"` //日活跃度 + Activeweek int32 `protobuf:"varint,12,opt,name=activeweek,proto3" json:"activeweek"` //周活跃度 + Sign string `protobuf:"bytes,13,opt,name=sign,proto3" json:"sign"` //用户签名 + FriendPoint int32 `protobuf:"varint,14,opt,name=friendPoint,proto3" json:"friendPoint" bson:"friendPoint"` //友情点 + FriendPointID int32 `protobuf:"varint,15,opt,name=friendPointID,proto3" json:"friendPointID" bson:"friendPointID"` //每日获赠友情点 + FriendPointOD int32 `protobuf:"varint,16,opt,name=friendPointOD,proto3" json:"friendPointOD" bson:"friendPointOD"` //每日送出友情点 + LoginAddCount int32 `protobuf:"varint,19,opt,name=loginAddCount,proto3" json:"loginAddCount"` //@go_tasgs(`bson:"loginAddCount"`) 累计登录天数 + LoginContinueCount int32 `protobuf:"varint,20,opt,name=loginContinueCount,proto3" json:"loginContinueCount"` //@go_tasgs(`bson:"loginContinueCount"`) 连续登录天数 + RtaskId int32 `protobuf:"varint,21,opt,name=rtaskId,proto3" json:"rtaskId" bson:"rtaskId"` // 当前完成的随机任务ID + TeamHeroIds []string `protobuf:"bytes,22,rep,name=teamHeroIds,proto3" json:"teamHeroIds" bson:"teamHeroIds"` //阵容英雄IDs + SociatyId string `protobuf:"bytes,23,opt,name=sociatyId,proto3" json:"sociatyId" bson:"sociatyId"` //公会ID + SociatyCd int64 `protobuf:"varint,24,opt,name=sociatyCd,proto3" json:"sociatyCd" bson:"sociatyCd"` //主动退出CD + Guildcoin int32 `protobuf:"varint,25,opt,name=guildcoin,proto3" json:"guildcoin" bson:"guildcoin"` //公会币 + Arenacoin int32 `protobuf:"varint,26,opt,name=arenacoin,proto3" json:"arenacoin" bson:"arenacoin"` //竞技场币 + Physicalbuynum int32 `protobuf:"varint,27,opt,name=physicalbuynum,proto3" json:"physicalbuynum"` //@go_tags(`bson:"physicalbuynum"`)体力购买次数 + PhysicalbuyLasttime int64 `protobuf:"varint,28,opt,name=physicalbuyLasttime,proto3" json:"physicalbuyLasttime"` //@go_tags(`bson:"physicalbuyLasttime"`)最后购买体力事件 + Buyunifiedticket int32 `protobuf:"varint,29,opt,name=buyunifiedticket,proto3" json:"buyunifiedticket"` //@go_tags(`bson:"buyunifiedticket"`)购买统一入场门票次数 + Lasttimeunifiedticket int64 `protobuf:"varint,30,opt,name=lasttimeunifiedticket,proto3" json:"lasttimeunifiedticket"` //@go_tags(`bson:"lasttimeunifiedticket"`)最后购买统一入场门票时间 + Recovertimeunifiedticket int64 `protobuf:"varint,31,opt,name=recovertimeunifiedticket,proto3" json:"recovertimeunifiedticket"` //@go_tags(`bson:"recovertimeunifiedticket"`)同意门票恢复时间 + SociatyTicketBuyNum int32 `protobuf:"varint,32,opt,name=sociatyTicketBuyNum,proto3" json:"sociatyTicketBuyNum" bson:"sociatyTicketBuyNum"` //公会boss挑战券购买次数 + SociatyTicket int32 `protobuf:"varint,33,opt,name=sociatyTicket,proto3" json:"sociatyTicket" bson:"sociatyTicket"` //公会boss挑战券数量 + Mline map[int32]int32 `protobuf:"bytes,34,rep,name=mline,proto3" json:"mline" protobuf_key:"varint,1,opt,name=key,proto3" protobuf_val:"varint,2,opt,name=value,proto3" bson:"mline"` //主线关卡最大进度 key难度val是关卡ID } func (x *DBUserExpand) Reset() { @@ -139,13 +139,6 @@ func (x *DBUserExpand) GetModifynameCount() int32 { return 0 } -func (x *DBUserExpand) GetTujian() map[string]int32 { - if x != nil { - return x.Tujian - } - return nil -} - func (x *DBUserExpand) GetActiveday() int32 { if x != nil { return x.Activeday @@ -304,7 +297,7 @@ var File_userexpand_proto protoreflect.FileDescriptor var file_userexpand_proto_rawDesc = []byte{ 0x0a, 0x10, 0x75, 0x73, 0x65, 0x72, 0x65, 0x78, 0x70, 0x61, 0x6e, 0x64, 0x2e, 0x70, 0x72, 0x6f, - 0x74, 0x6f, 0x22, 0xee, 0x09, 0x0a, 0x0c, 0x44, 0x42, 0x55, 0x73, 0x65, 0x72, 0x45, 0x78, 0x70, + 0x74, 0x6f, 0x22, 0x80, 0x09, 0x0a, 0x0c, 0x44, 0x42, 0x55, 0x73, 0x65, 0x72, 0x45, 0x78, 0x70, 0x61, 0x6e, 0x64, 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, 0x2c, 0x0a, 0x11, 0x6c, 0x61, 0x73, 0x74, 0x72, 0x65, 0x61, @@ -320,71 +313,64 @@ var file_userexpand_proto_rawDesc = []byte{ 0x63, 0x68, 0x61, 0x6e, 0x6e, 0x65, 0x6c, 0x12, 0x28, 0x0a, 0x0f, 0x6d, 0x6f, 0x64, 0x69, 0x66, 0x79, 0x6e, 0x61, 0x6d, 0x65, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x07, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0f, 0x6d, 0x6f, 0x64, 0x69, 0x66, 0x79, 0x6e, 0x61, 0x6d, 0x65, 0x43, 0x6f, 0x75, 0x6e, - 0x74, 0x12, 0x31, 0x0a, 0x06, 0x74, 0x75, 0x6a, 0x69, 0x61, 0x6e, 0x18, 0x08, 0x20, 0x03, 0x28, - 0x0b, 0x32, 0x19, 0x2e, 0x44, 0x42, 0x55, 0x73, 0x65, 0x72, 0x45, 0x78, 0x70, 0x61, 0x6e, 0x64, - 0x2e, 0x54, 0x75, 0x6a, 0x69, 0x61, 0x6e, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x06, 0x74, 0x75, - 0x6a, 0x69, 0x61, 0x6e, 0x12, 0x1c, 0x0a, 0x09, 0x61, 0x63, 0x74, 0x69, 0x76, 0x65, 0x64, 0x61, - 0x79, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x05, 0x52, 0x09, 0x61, 0x63, 0x74, 0x69, 0x76, 0x65, 0x64, - 0x61, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x63, 0x74, 0x69, 0x76, 0x65, 0x77, 0x65, 0x65, 0x6b, - 0x18, 0x0c, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0a, 0x61, 0x63, 0x74, 0x69, 0x76, 0x65, 0x77, 0x65, - 0x65, 0x6b, 0x12, 0x12, 0x0a, 0x04, 0x73, 0x69, 0x67, 0x6e, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x04, 0x73, 0x69, 0x67, 0x6e, 0x12, 0x20, 0x0a, 0x0b, 0x66, 0x72, 0x69, 0x65, 0x6e, 0x64, - 0x50, 0x6f, 0x69, 0x6e, 0x74, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0b, 0x66, 0x72, 0x69, - 0x65, 0x6e, 0x64, 0x50, 0x6f, 0x69, 0x6e, 0x74, 0x12, 0x24, 0x0a, 0x0d, 0x66, 0x72, 0x69, 0x65, - 0x6e, 0x64, 0x50, 0x6f, 0x69, 0x6e, 0x74, 0x49, 0x44, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x05, 0x52, - 0x0d, 0x66, 0x72, 0x69, 0x65, 0x6e, 0x64, 0x50, 0x6f, 0x69, 0x6e, 0x74, 0x49, 0x44, 0x12, 0x24, - 0x0a, 0x0d, 0x66, 0x72, 0x69, 0x65, 0x6e, 0x64, 0x50, 0x6f, 0x69, 0x6e, 0x74, 0x4f, 0x44, 0x18, - 0x10, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0d, 0x66, 0x72, 0x69, 0x65, 0x6e, 0x64, 0x50, 0x6f, 0x69, - 0x6e, 0x74, 0x4f, 0x44, 0x12, 0x24, 0x0a, 0x0d, 0x6c, 0x6f, 0x67, 0x69, 0x6e, 0x41, 0x64, 0x64, - 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x13, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0d, 0x6c, 0x6f, 0x67, - 0x69, 0x6e, 0x41, 0x64, 0x64, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x2e, 0x0a, 0x12, 0x6c, 0x6f, - 0x67, 0x69, 0x6e, 0x43, 0x6f, 0x6e, 0x74, 0x69, 0x6e, 0x75, 0x65, 0x43, 0x6f, 0x75, 0x6e, 0x74, - 0x18, 0x14, 0x20, 0x01, 0x28, 0x05, 0x52, 0x12, 0x6c, 0x6f, 0x67, 0x69, 0x6e, 0x43, 0x6f, 0x6e, - 0x74, 0x69, 0x6e, 0x75, 0x65, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x18, 0x0a, 0x07, 0x72, 0x74, - 0x61, 0x73, 0x6b, 0x49, 0x64, 0x18, 0x15, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x72, 0x74, 0x61, - 0x73, 0x6b, 0x49, 0x64, 0x12, 0x20, 0x0a, 0x0b, 0x74, 0x65, 0x61, 0x6d, 0x48, 0x65, 0x72, 0x6f, - 0x49, 0x64, 0x73, 0x18, 0x16, 0x20, 0x03, 0x28, 0x09, 0x52, 0x0b, 0x74, 0x65, 0x61, 0x6d, 0x48, - 0x65, 0x72, 0x6f, 0x49, 0x64, 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x73, 0x6f, 0x63, 0x69, 0x61, 0x74, - 0x79, 0x49, 0x64, 0x18, 0x17, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x73, 0x6f, 0x63, 0x69, 0x61, - 0x74, 0x79, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x73, 0x6f, 0x63, 0x69, 0x61, 0x74, 0x79, 0x43, - 0x64, 0x18, 0x18, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x73, 0x6f, 0x63, 0x69, 0x61, 0x74, 0x79, - 0x43, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x67, 0x75, 0x69, 0x6c, 0x64, 0x63, 0x6f, 0x69, 0x6e, 0x18, - 0x19, 0x20, 0x01, 0x28, 0x05, 0x52, 0x09, 0x67, 0x75, 0x69, 0x6c, 0x64, 0x63, 0x6f, 0x69, 0x6e, - 0x12, 0x1c, 0x0a, 0x09, 0x61, 0x72, 0x65, 0x6e, 0x61, 0x63, 0x6f, 0x69, 0x6e, 0x18, 0x1a, 0x20, - 0x01, 0x28, 0x05, 0x52, 0x09, 0x61, 0x72, 0x65, 0x6e, 0x61, 0x63, 0x6f, 0x69, 0x6e, 0x12, 0x26, - 0x0a, 0x0e, 0x70, 0x68, 0x79, 0x73, 0x69, 0x63, 0x61, 0x6c, 0x62, 0x75, 0x79, 0x6e, 0x75, 0x6d, - 0x18, 0x1b, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0e, 0x70, 0x68, 0x79, 0x73, 0x69, 0x63, 0x61, 0x6c, - 0x62, 0x75, 0x79, 0x6e, 0x75, 0x6d, 0x12, 0x30, 0x0a, 0x13, 0x70, 0x68, 0x79, 0x73, 0x69, 0x63, - 0x61, 0x6c, 0x62, 0x75, 0x79, 0x4c, 0x61, 0x73, 0x74, 0x74, 0x69, 0x6d, 0x65, 0x18, 0x1c, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x13, 0x70, 0x68, 0x79, 0x73, 0x69, 0x63, 0x61, 0x6c, 0x62, 0x75, 0x79, - 0x4c, 0x61, 0x73, 0x74, 0x74, 0x69, 0x6d, 0x65, 0x12, 0x2a, 0x0a, 0x10, 0x62, 0x75, 0x79, 0x75, - 0x6e, 0x69, 0x66, 0x69, 0x65, 0x64, 0x74, 0x69, 0x63, 0x6b, 0x65, 0x74, 0x18, 0x1d, 0x20, 0x01, - 0x28, 0x05, 0x52, 0x10, 0x62, 0x75, 0x79, 0x75, 0x6e, 0x69, 0x66, 0x69, 0x65, 0x64, 0x74, 0x69, - 0x63, 0x6b, 0x65, 0x74, 0x12, 0x34, 0x0a, 0x15, 0x6c, 0x61, 0x73, 0x74, 0x74, 0x69, 0x6d, 0x65, - 0x75, 0x6e, 0x69, 0x66, 0x69, 0x65, 0x64, 0x74, 0x69, 0x63, 0x6b, 0x65, 0x74, 0x18, 0x1e, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x15, 0x6c, 0x61, 0x73, 0x74, 0x74, 0x69, 0x6d, 0x65, 0x75, 0x6e, 0x69, - 0x66, 0x69, 0x65, 0x64, 0x74, 0x69, 0x63, 0x6b, 0x65, 0x74, 0x12, 0x3a, 0x0a, 0x18, 0x72, 0x65, - 0x63, 0x6f, 0x76, 0x65, 0x72, 0x74, 0x69, 0x6d, 0x65, 0x75, 0x6e, 0x69, 0x66, 0x69, 0x65, 0x64, - 0x74, 0x69, 0x63, 0x6b, 0x65, 0x74, 0x18, 0x1f, 0x20, 0x01, 0x28, 0x03, 0x52, 0x18, 0x72, 0x65, - 0x63, 0x6f, 0x76, 0x65, 0x72, 0x74, 0x69, 0x6d, 0x65, 0x75, 0x6e, 0x69, 0x66, 0x69, 0x65, 0x64, - 0x74, 0x69, 0x63, 0x6b, 0x65, 0x74, 0x12, 0x30, 0x0a, 0x13, 0x73, 0x6f, 0x63, 0x69, 0x61, 0x74, - 0x79, 0x54, 0x69, 0x63, 0x6b, 0x65, 0x74, 0x42, 0x75, 0x79, 0x4e, 0x75, 0x6d, 0x18, 0x20, 0x20, - 0x01, 0x28, 0x05, 0x52, 0x13, 0x73, 0x6f, 0x63, 0x69, 0x61, 0x74, 0x79, 0x54, 0x69, 0x63, 0x6b, - 0x65, 0x74, 0x42, 0x75, 0x79, 0x4e, 0x75, 0x6d, 0x12, 0x24, 0x0a, 0x0d, 0x73, 0x6f, 0x63, 0x69, - 0x61, 0x74, 0x79, 0x54, 0x69, 0x63, 0x6b, 0x65, 0x74, 0x18, 0x21, 0x20, 0x01, 0x28, 0x05, 0x52, - 0x0d, 0x73, 0x6f, 0x63, 0x69, 0x61, 0x74, 0x79, 0x54, 0x69, 0x63, 0x6b, 0x65, 0x74, 0x12, 0x2e, - 0x0a, 0x05, 0x6d, 0x6c, 0x69, 0x6e, 0x65, 0x18, 0x22, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x18, 0x2e, - 0x44, 0x42, 0x55, 0x73, 0x65, 0x72, 0x45, 0x78, 0x70, 0x61, 0x6e, 0x64, 0x2e, 0x4d, 0x6c, 0x69, - 0x6e, 0x65, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x05, 0x6d, 0x6c, 0x69, 0x6e, 0x65, 0x1a, 0x39, - 0x0a, 0x0b, 0x54, 0x75, 0x6a, 0x69, 0x61, 0x6e, 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, 0x4d, 0x6c, 0x69, - 0x6e, 0x65, 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, + 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x61, 0x63, 0x74, 0x69, 0x76, 0x65, 0x64, 0x61, 0x79, 0x18, 0x0b, + 0x20, 0x01, 0x28, 0x05, 0x52, 0x09, 0x61, 0x63, 0x74, 0x69, 0x76, 0x65, 0x64, 0x61, 0x79, 0x12, + 0x1e, 0x0a, 0x0a, 0x61, 0x63, 0x74, 0x69, 0x76, 0x65, 0x77, 0x65, 0x65, 0x6b, 0x18, 0x0c, 0x20, + 0x01, 0x28, 0x05, 0x52, 0x0a, 0x61, 0x63, 0x74, 0x69, 0x76, 0x65, 0x77, 0x65, 0x65, 0x6b, 0x12, + 0x12, 0x0a, 0x04, 0x73, 0x69, 0x67, 0x6e, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x73, + 0x69, 0x67, 0x6e, 0x12, 0x20, 0x0a, 0x0b, 0x66, 0x72, 0x69, 0x65, 0x6e, 0x64, 0x50, 0x6f, 0x69, + 0x6e, 0x74, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0b, 0x66, 0x72, 0x69, 0x65, 0x6e, 0x64, + 0x50, 0x6f, 0x69, 0x6e, 0x74, 0x12, 0x24, 0x0a, 0x0d, 0x66, 0x72, 0x69, 0x65, 0x6e, 0x64, 0x50, + 0x6f, 0x69, 0x6e, 0x74, 0x49, 0x44, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0d, 0x66, 0x72, + 0x69, 0x65, 0x6e, 0x64, 0x50, 0x6f, 0x69, 0x6e, 0x74, 0x49, 0x44, 0x12, 0x24, 0x0a, 0x0d, 0x66, + 0x72, 0x69, 0x65, 0x6e, 0x64, 0x50, 0x6f, 0x69, 0x6e, 0x74, 0x4f, 0x44, 0x18, 0x10, 0x20, 0x01, + 0x28, 0x05, 0x52, 0x0d, 0x66, 0x72, 0x69, 0x65, 0x6e, 0x64, 0x50, 0x6f, 0x69, 0x6e, 0x74, 0x4f, + 0x44, 0x12, 0x24, 0x0a, 0x0d, 0x6c, 0x6f, 0x67, 0x69, 0x6e, 0x41, 0x64, 0x64, 0x43, 0x6f, 0x75, + 0x6e, 0x74, 0x18, 0x13, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0d, 0x6c, 0x6f, 0x67, 0x69, 0x6e, 0x41, + 0x64, 0x64, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x2e, 0x0a, 0x12, 0x6c, 0x6f, 0x67, 0x69, 0x6e, + 0x43, 0x6f, 0x6e, 0x74, 0x69, 0x6e, 0x75, 0x65, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x14, 0x20, + 0x01, 0x28, 0x05, 0x52, 0x12, 0x6c, 0x6f, 0x67, 0x69, 0x6e, 0x43, 0x6f, 0x6e, 0x74, 0x69, 0x6e, + 0x75, 0x65, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x18, 0x0a, 0x07, 0x72, 0x74, 0x61, 0x73, 0x6b, + 0x49, 0x64, 0x18, 0x15, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x72, 0x74, 0x61, 0x73, 0x6b, 0x49, + 0x64, 0x12, 0x20, 0x0a, 0x0b, 0x74, 0x65, 0x61, 0x6d, 0x48, 0x65, 0x72, 0x6f, 0x49, 0x64, 0x73, + 0x18, 0x16, 0x20, 0x03, 0x28, 0x09, 0x52, 0x0b, 0x74, 0x65, 0x61, 0x6d, 0x48, 0x65, 0x72, 0x6f, + 0x49, 0x64, 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x73, 0x6f, 0x63, 0x69, 0x61, 0x74, 0x79, 0x49, 0x64, + 0x18, 0x17, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x73, 0x6f, 0x63, 0x69, 0x61, 0x74, 0x79, 0x49, + 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x73, 0x6f, 0x63, 0x69, 0x61, 0x74, 0x79, 0x43, 0x64, 0x18, 0x18, + 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x73, 0x6f, 0x63, 0x69, 0x61, 0x74, 0x79, 0x43, 0x64, 0x12, + 0x1c, 0x0a, 0x09, 0x67, 0x75, 0x69, 0x6c, 0x64, 0x63, 0x6f, 0x69, 0x6e, 0x18, 0x19, 0x20, 0x01, + 0x28, 0x05, 0x52, 0x09, 0x67, 0x75, 0x69, 0x6c, 0x64, 0x63, 0x6f, 0x69, 0x6e, 0x12, 0x1c, 0x0a, + 0x09, 0x61, 0x72, 0x65, 0x6e, 0x61, 0x63, 0x6f, 0x69, 0x6e, 0x18, 0x1a, 0x20, 0x01, 0x28, 0x05, + 0x52, 0x09, 0x61, 0x72, 0x65, 0x6e, 0x61, 0x63, 0x6f, 0x69, 0x6e, 0x12, 0x26, 0x0a, 0x0e, 0x70, + 0x68, 0x79, 0x73, 0x69, 0x63, 0x61, 0x6c, 0x62, 0x75, 0x79, 0x6e, 0x75, 0x6d, 0x18, 0x1b, 0x20, + 0x01, 0x28, 0x05, 0x52, 0x0e, 0x70, 0x68, 0x79, 0x73, 0x69, 0x63, 0x61, 0x6c, 0x62, 0x75, 0x79, + 0x6e, 0x75, 0x6d, 0x12, 0x30, 0x0a, 0x13, 0x70, 0x68, 0x79, 0x73, 0x69, 0x63, 0x61, 0x6c, 0x62, + 0x75, 0x79, 0x4c, 0x61, 0x73, 0x74, 0x74, 0x69, 0x6d, 0x65, 0x18, 0x1c, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x13, 0x70, 0x68, 0x79, 0x73, 0x69, 0x63, 0x61, 0x6c, 0x62, 0x75, 0x79, 0x4c, 0x61, 0x73, + 0x74, 0x74, 0x69, 0x6d, 0x65, 0x12, 0x2a, 0x0a, 0x10, 0x62, 0x75, 0x79, 0x75, 0x6e, 0x69, 0x66, + 0x69, 0x65, 0x64, 0x74, 0x69, 0x63, 0x6b, 0x65, 0x74, 0x18, 0x1d, 0x20, 0x01, 0x28, 0x05, 0x52, + 0x10, 0x62, 0x75, 0x79, 0x75, 0x6e, 0x69, 0x66, 0x69, 0x65, 0x64, 0x74, 0x69, 0x63, 0x6b, 0x65, + 0x74, 0x12, 0x34, 0x0a, 0x15, 0x6c, 0x61, 0x73, 0x74, 0x74, 0x69, 0x6d, 0x65, 0x75, 0x6e, 0x69, + 0x66, 0x69, 0x65, 0x64, 0x74, 0x69, 0x63, 0x6b, 0x65, 0x74, 0x18, 0x1e, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x15, 0x6c, 0x61, 0x73, 0x74, 0x74, 0x69, 0x6d, 0x65, 0x75, 0x6e, 0x69, 0x66, 0x69, 0x65, + 0x64, 0x74, 0x69, 0x63, 0x6b, 0x65, 0x74, 0x12, 0x3a, 0x0a, 0x18, 0x72, 0x65, 0x63, 0x6f, 0x76, + 0x65, 0x72, 0x74, 0x69, 0x6d, 0x65, 0x75, 0x6e, 0x69, 0x66, 0x69, 0x65, 0x64, 0x74, 0x69, 0x63, + 0x6b, 0x65, 0x74, 0x18, 0x1f, 0x20, 0x01, 0x28, 0x03, 0x52, 0x18, 0x72, 0x65, 0x63, 0x6f, 0x76, + 0x65, 0x72, 0x74, 0x69, 0x6d, 0x65, 0x75, 0x6e, 0x69, 0x66, 0x69, 0x65, 0x64, 0x74, 0x69, 0x63, + 0x6b, 0x65, 0x74, 0x12, 0x30, 0x0a, 0x13, 0x73, 0x6f, 0x63, 0x69, 0x61, 0x74, 0x79, 0x54, 0x69, + 0x63, 0x6b, 0x65, 0x74, 0x42, 0x75, 0x79, 0x4e, 0x75, 0x6d, 0x18, 0x20, 0x20, 0x01, 0x28, 0x05, + 0x52, 0x13, 0x73, 0x6f, 0x63, 0x69, 0x61, 0x74, 0x79, 0x54, 0x69, 0x63, 0x6b, 0x65, 0x74, 0x42, + 0x75, 0x79, 0x4e, 0x75, 0x6d, 0x12, 0x24, 0x0a, 0x0d, 0x73, 0x6f, 0x63, 0x69, 0x61, 0x74, 0x79, + 0x54, 0x69, 0x63, 0x6b, 0x65, 0x74, 0x18, 0x21, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0d, 0x73, 0x6f, + 0x63, 0x69, 0x61, 0x74, 0x79, 0x54, 0x69, 0x63, 0x6b, 0x65, 0x74, 0x12, 0x2e, 0x0a, 0x05, 0x6d, + 0x6c, 0x69, 0x6e, 0x65, 0x18, 0x22, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x44, 0x42, 0x55, + 0x73, 0x65, 0x72, 0x45, 0x78, 0x70, 0x61, 0x6e, 0x64, 0x2e, 0x4d, 0x6c, 0x69, 0x6e, 0x65, 0x45, + 0x6e, 0x74, 0x72, 0x79, 0x52, 0x05, 0x6d, 0x6c, 0x69, 0x6e, 0x65, 0x1a, 0x38, 0x0a, 0x0a, 0x4d, + 0x6c, 0x69, 0x6e, 0x65, 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 ( @@ -399,20 +385,18 @@ func file_userexpand_proto_rawDescGZIP() []byte { return file_userexpand_proto_rawDescData } -var file_userexpand_proto_msgTypes = make([]protoimpl.MessageInfo, 3) +var file_userexpand_proto_msgTypes = make([]protoimpl.MessageInfo, 2) var file_userexpand_proto_goTypes = []interface{}{ (*DBUserExpand)(nil), // 0: DBUserExpand - nil, // 1: DBUserExpand.TujianEntry - nil, // 2: DBUserExpand.MlineEntry + nil, // 1: DBUserExpand.MlineEntry } var file_userexpand_proto_depIdxs = []int32{ - 1, // 0: DBUserExpand.tujian:type_name -> DBUserExpand.TujianEntry - 2, // 1: DBUserExpand.mline:type_name -> DBUserExpand.MlineEntry - 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 + 1, // 0: DBUserExpand.mline:type_name -> DBUserExpand.MlineEntry + 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 } func init() { file_userexpand_proto_init() } @@ -440,7 +424,7 @@ func file_userexpand_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_userexpand_proto_rawDesc, NumEnums: 0, - NumMessages: 3, + NumMessages: 2, NumExtensions: 0, NumServices: 0, }, From 4701ab2fb74ef3c63e0102d93f9619570e804818 Mon Sep 17 00:00:00 2001 From: meixiongfeng <766881921@qq.com> Date: Thu, 2 Feb 2023 18:15:02 +0800 Subject: [PATCH 16/17] =?UTF-8?q?=E4=B8=BB=E7=BA=BF=E4=BB=BB=E5=8A=A1?= =?UTF-8?q?=E5=9F=8B=E7=82=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- modules/mline/api_challengeover.go | 46 ++++-- pb/arena_db.pb.go | 2 +- pb/arena_msg.pb.go | 255 +++++++++++++++++++++++++---- 3 files changed, 262 insertions(+), 41 deletions(-) diff --git a/modules/mline/api_challengeover.go b/modules/mline/api_challengeover.go index f3fdeb987..3dc3cbc0c 100644 --- a/modules/mline/api_challengeover.go +++ b/modules/mline/api_challengeover.go @@ -175,18 +175,7 @@ func (this *apiComp) ChallengeOver(session comm.IUserSession, req *pb.MlineChall }) } } - // 加主角经验 - // if stageConf.Exp > 0 { - // res := make([]*cfg.Gameatn, 0) - // res = append(res, &cfg.Gameatn{ - // A: "attr", - // T: "exp", - // N: stageConf.Exp, - // }) - // if code = this.module.DispenseRes(session, res, true); code != pb.ErrorCode_Success { - // this.module.Debugf("Mline Commonaward DispenseRes err:+%v", res) - // } - // } + // 加英雄经验 if stageConf.HeroExp > 0 { if req.Report != nil && req.Report.Info != nil && len(req.Report.Info.Redflist) > 0 { @@ -203,5 +192,38 @@ func (this *apiComp) ChallengeOver(session comm.IUserSession, req *pb.MlineChall // 主线任务统计 Rtype60 this.module.ModuleRtask.SendToRtask(session, comm.Rtype60, 1) this.module.ModuleRtask.SendToRtask(session, comm.Rtype61, int32(req.StageId)) + var ( + ChapterStar int32 + bAll3Star bool + allStar int32 + ) + bAll3Star = true + for _, v1 := range curChapter.Star { + star := 0 + for _, v := range szStar { + if v1&v == v { + ChapterStar++ + star++ + } + } + if star != 3 && bAll3Star { + bAll3Star = false + } + } + + this.module.ModuleRtask.SendToRtask(session, comm.Rtype158, curChapter.ChapterId, ChapterStar) + if bAll3Star { + this.module.ModuleRtask.SendToRtask(session, comm.Rtype159, curChapter.ChapterId) + } + for _, v2 := range list { + for _, v1 := range v2.Star { + for _, v := range szStar { + if v1&v == v { + allStar++ + } + } + } + } + this.module.ModuleRtask.SendToRtask(session, comm.Rtype160, allStar) return } diff --git a/pb/arena_db.pb.go b/pb/arena_db.pb.go index 668737182..566ba115a 100644 --- a/pb/arena_db.pb.go +++ b/pb/arena_db.pb.go @@ -470,7 +470,7 @@ type DBArenaUser struct { Avatar string `protobuf:"bytes,3,opt,name=avatar,proto3" json:"avatar" bson:"avatar"` //头像 Lv int32 `protobuf:"varint,4,opt,name=lv,proto3" json:"lv" bson:"lv"` //等级 Integral int32 `protobuf:"varint,5,opt,name=integral,proto3" json:"integral"` //积分 - // int32 ticket = 6; //挑战券 + // int32 ticket = 6; //挑战券 Dan int32 `protobuf:"varint,7,opt,name=dan,proto3" json:"dan"` //段位 Attack *DBPlayerBattleFormt `protobuf:"bytes,8,opt,name=attack,proto3" json:"attack"` //进攻阵型 Defend *DBPlayerBattleFormt `protobuf:"bytes,9,opt,name=defend,proto3" json:"defend"` //防守阵型 diff --git a/pb/arena_msg.pb.go b/pb/arena_msg.pb.go index 274e14864..9449ea326 100644 --- a/pb/arena_msg.pb.go +++ b/pb/arena_msg.pb.go @@ -1356,6 +1356,157 @@ func (x *ArenaRTimePvpPush) GetInfo() *BattleInfo { return nil } +//实时pvp 指令请求 +type ArenaRtPvpCmdReq struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + RoomId string `protobuf:"bytes,1,opt,name=RoomId,proto3" json:"RoomId"` + CmdType string `protobuf:"bytes,2,opt,name=CmdType,proto3" json:"CmdType"` + Cmd []byte `protobuf:"bytes,3,opt,name=Cmd,proto3" json:"Cmd"` +} + +func (x *ArenaRtPvpCmdReq) Reset() { + *x = ArenaRtPvpCmdReq{} + if protoimpl.UnsafeEnabled { + mi := &file_arena_arena_msg_proto_msgTypes[25] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *ArenaRtPvpCmdReq) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*ArenaRtPvpCmdReq) ProtoMessage() {} + +func (x *ArenaRtPvpCmdReq) ProtoReflect() protoreflect.Message { + mi := &file_arena_arena_msg_proto_msgTypes[25] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use ArenaRtPvpCmdReq.ProtoReflect.Descriptor instead. +func (*ArenaRtPvpCmdReq) Descriptor() ([]byte, []int) { + return file_arena_arena_msg_proto_rawDescGZIP(), []int{25} +} + +func (x *ArenaRtPvpCmdReq) GetRoomId() string { + if x != nil { + return x.RoomId + } + return "" +} + +func (x *ArenaRtPvpCmdReq) GetCmdType() string { + if x != nil { + return x.CmdType + } + return "" +} + +func (x *ArenaRtPvpCmdReq) GetCmd() []byte { + if x != nil { + return x.Cmd + } + return nil +} + +//实时pvp 指令请求回应 +type ArenaRtPvpCmdResp struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + IsSucc bool `protobuf:"varint,1,opt,name=IsSucc,proto3" json:"IsSucc"` +} + +func (x *ArenaRtPvpCmdResp) Reset() { + *x = ArenaRtPvpCmdResp{} + if protoimpl.UnsafeEnabled { + mi := &file_arena_arena_msg_proto_msgTypes[26] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *ArenaRtPvpCmdResp) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*ArenaRtPvpCmdResp) ProtoMessage() {} + +func (x *ArenaRtPvpCmdResp) ProtoReflect() protoreflect.Message { + mi := &file_arena_arena_msg_proto_msgTypes[26] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use ArenaRtPvpCmdResp.ProtoReflect.Descriptor instead. +func (*ArenaRtPvpCmdResp) Descriptor() ([]byte, []int) { + return file_arena_arena_msg_proto_rawDescGZIP(), []int{26} +} + +func (x *ArenaRtPvpCmdResp) GetIsSucc() bool { + if x != nil { + return x.IsSucc + } + return false +} + +//实时Pvp 指令推送 +type ArenaRtPvpCmdPush struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *ArenaRtPvpCmdPush) Reset() { + *x = ArenaRtPvpCmdPush{} + if protoimpl.UnsafeEnabled { + mi := &file_arena_arena_msg_proto_msgTypes[27] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *ArenaRtPvpCmdPush) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*ArenaRtPvpCmdPush) ProtoMessage() {} + +func (x *ArenaRtPvpCmdPush) ProtoReflect() protoreflect.Message { + mi := &file_arena_arena_msg_proto_msgTypes[27] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use ArenaRtPvpCmdPush.ProtoReflect.Descriptor instead. +func (*ArenaRtPvpCmdPush) Descriptor() ([]byte, []int) { + return file_arena_arena_msg_proto_rawDescGZIP(), []int{27} +} + var File_arena_arena_msg_proto protoreflect.FileDescriptor var file_arena_arena_msg_proto_rawDesc = []byte{ @@ -1477,8 +1628,17 @@ var file_arena_arena_msg_proto_rawDesc = []byte{ 0x01, 0x28, 0x09, 0x52, 0x0b, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x1f, 0x0a, 0x04, 0x69, 0x6e, 0x66, 0x6f, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0b, 0x2e, 0x42, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x04, 0x69, 0x6e, 0x66, - 0x6f, 0x42, 0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, - 0x33, + 0x6f, 0x22, 0x56, 0x0a, 0x10, 0x41, 0x72, 0x65, 0x6e, 0x61, 0x52, 0x74, 0x50, 0x76, 0x70, 0x43, + 0x6d, 0x64, 0x52, 0x65, 0x71, 0x12, 0x16, 0x0a, 0x06, 0x52, 0x6f, 0x6f, 0x6d, 0x49, 0x64, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x52, 0x6f, 0x6f, 0x6d, 0x49, 0x64, 0x12, 0x18, 0x0a, + 0x07, 0x43, 0x6d, 0x64, 0x54, 0x79, 0x70, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, + 0x43, 0x6d, 0x64, 0x54, 0x79, 0x70, 0x65, 0x12, 0x10, 0x0a, 0x03, 0x43, 0x6d, 0x64, 0x18, 0x03, + 0x20, 0x01, 0x28, 0x0c, 0x52, 0x03, 0x43, 0x6d, 0x64, 0x22, 0x2b, 0x0a, 0x11, 0x41, 0x72, 0x65, + 0x6e, 0x61, 0x52, 0x74, 0x50, 0x76, 0x70, 0x43, 0x6d, 0x64, 0x52, 0x65, 0x73, 0x70, 0x12, 0x16, + 0x0a, 0x06, 0x49, 0x73, 0x53, 0x75, 0x63, 0x63, 0x18, 0x01, 0x20, 0x01, 0x28, 0x08, 0x52, 0x06, + 0x49, 0x73, 0x53, 0x75, 0x63, 0x63, 0x22, 0x13, 0x0a, 0x11, 0x41, 0x72, 0x65, 0x6e, 0x61, 0x52, + 0x74, 0x50, 0x76, 0x70, 0x43, 0x6d, 0x64, 0x50, 0x75, 0x73, 0x68, 0x42, 0x06, 0x5a, 0x04, 0x2e, + 0x3b, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -1493,7 +1653,7 @@ func file_arena_arena_msg_proto_rawDescGZIP() []byte { return file_arena_arena_msg_proto_rawDescData } -var file_arena_arena_msg_proto_msgTypes = make([]protoimpl.MessageInfo, 26) +var file_arena_arena_msg_proto_msgTypes = make([]protoimpl.MessageInfo, 29) var file_arena_arena_msg_proto_goTypes = []interface{}{ (*ArenaInfoReq)(nil), // 0: ArenaInfoReq (*ArenaInfoResp)(nil), // 1: ArenaInfoResp @@ -1520,32 +1680,35 @@ var file_arena_arena_msg_proto_goTypes = []interface{}{ (*ArenaPlotRewardReq)(nil), // 22: ArenaPlotRewardReq (*ArenaPlotRewardResp)(nil), // 23: ArenaPlotRewardResp (*ArenaRTimePvpPush)(nil), // 24: ArenaRTimePvpPush - nil, // 25: ArenaPlotRewardResp.NpcEntry - (*DBArenaUser)(nil), // 26: DBArenaUser - (*ArenaPlayer)(nil), // 27: ArenaPlayer - (*BattleFormation)(nil), // 28: BattleFormation - (ErrorCode)(0), // 29: ErrorCode - (*BattleInfo)(nil), // 30: BattleInfo - (*BattleReport)(nil), // 31: BattleReport - (*DBNpc)(nil), // 32: DBNpc + (*ArenaRtPvpCmdReq)(nil), // 25: ArenaRtPvpCmdReq + (*ArenaRtPvpCmdResp)(nil), // 26: ArenaRtPvpCmdResp + (*ArenaRtPvpCmdPush)(nil), // 27: ArenaRtPvpCmdPush + nil, // 28: ArenaPlotRewardResp.NpcEntry + (*DBArenaUser)(nil), // 29: DBArenaUser + (*ArenaPlayer)(nil), // 30: ArenaPlayer + (*BattleFormation)(nil), // 31: BattleFormation + (ErrorCode)(0), // 32: ErrorCode + (*BattleInfo)(nil), // 33: BattleInfo + (*BattleReport)(nil), // 34: BattleReport + (*DBNpc)(nil), // 35: DBNpc } var file_arena_arena_msg_proto_depIdxs = []int32{ - 26, // 0: ArenaInfoResp.info:type_name -> DBArenaUser - 26, // 1: ArenaOtherInfoResp.info:type_name -> DBArenaUser - 27, // 2: ArenaMatcheResp.players:type_name -> ArenaPlayer - 28, // 3: ArenaChallengeReq.battle:type_name -> BattleFormation - 29, // 4: ArenaChallengeResp.code:type_name -> ErrorCode - 30, // 5: ArenaChallengeResp.info:type_name -> BattleInfo - 31, // 6: ArenaChallengeRewardReq.report:type_name -> BattleReport - 27, // 7: ArenaRankResp.players:type_name -> ArenaPlayer - 26, // 8: ArenaRankResp.info:type_name -> DBArenaUser - 28, // 9: ArenaPlotReq.battle:type_name -> BattleFormation - 29, // 10: ArenaPlotResp.code:type_name -> ErrorCode - 30, // 11: ArenaPlotResp.info:type_name -> BattleInfo - 31, // 12: ArenaPlotRewardReq.report:type_name -> BattleReport - 25, // 13: ArenaPlotRewardResp.npc:type_name -> ArenaPlotRewardResp.NpcEntry - 30, // 14: ArenaRTimePvpPush.info:type_name -> BattleInfo - 32, // 15: ArenaPlotRewardResp.NpcEntry.value:type_name -> DBNpc + 29, // 0: ArenaInfoResp.info:type_name -> DBArenaUser + 29, // 1: ArenaOtherInfoResp.info:type_name -> DBArenaUser + 30, // 2: ArenaMatcheResp.players:type_name -> ArenaPlayer + 31, // 3: ArenaChallengeReq.battle:type_name -> BattleFormation + 32, // 4: ArenaChallengeResp.code:type_name -> ErrorCode + 33, // 5: ArenaChallengeResp.info:type_name -> BattleInfo + 34, // 6: ArenaChallengeRewardReq.report:type_name -> BattleReport + 30, // 7: ArenaRankResp.players:type_name -> ArenaPlayer + 29, // 8: ArenaRankResp.info:type_name -> DBArenaUser + 31, // 9: ArenaPlotReq.battle:type_name -> BattleFormation + 32, // 10: ArenaPlotResp.code:type_name -> ErrorCode + 33, // 11: ArenaPlotResp.info:type_name -> BattleInfo + 34, // 12: ArenaPlotRewardReq.report:type_name -> BattleReport + 28, // 13: ArenaPlotRewardResp.npc:type_name -> ArenaPlotRewardResp.NpcEntry + 33, // 14: ArenaRTimePvpPush.info:type_name -> BattleInfo + 35, // 15: ArenaPlotRewardResp.NpcEntry.value:type_name -> DBNpc 16, // [16:16] is the sub-list for method output_type 16, // [16:16] is the sub-list for method input_type 16, // [16:16] is the sub-list for extension type_name @@ -1862,6 +2025,42 @@ func file_arena_arena_msg_proto_init() { return nil } } + file_arena_arena_msg_proto_msgTypes[25].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*ArenaRtPvpCmdReq); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_arena_arena_msg_proto_msgTypes[26].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*ArenaRtPvpCmdResp); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_arena_arena_msg_proto_msgTypes[27].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*ArenaRtPvpCmdPush); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } } type x struct{} out := protoimpl.TypeBuilder{ @@ -1869,7 +2068,7 @@ func file_arena_arena_msg_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_arena_arena_msg_proto_rawDesc, NumEnums: 0, - NumMessages: 26, + NumMessages: 29, NumExtensions: 0, NumServices: 0, }, From aa91ee0b32cdb0b335aa055f6492ca110aaa507d Mon Sep 17 00:00:00 2001 From: meixiongfeng <766881921@qq.com> Date: Fri, 3 Feb 2023 15:36:39 +0800 Subject: [PATCH 17/17] =?UTF-8?q?=E6=8A=BD=E5=8D=A1=E6=96=B0=E8=A7=84?= =?UTF-8?q?=E5=88=99?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- bin/json/game_global.json | 10 ++- modules/hero/api_drawCard.go | 53 ++++++++++++++- modules/hero/hero_test.go | 6 ++ modules/hero/module.go | 31 +++++++++ pb/hero_db.pb.go | 84 +++++++++++++----------- sys/configure/structs/game.globalData.go | 21 ++++++ 6 files changed, 165 insertions(+), 40 deletions(-) diff --git a/bin/json/game_global.json b/bin/json/game_global.json index 972ddd2cd..ef9a8c8c0 100644 --- a/bin/json/game_global.json +++ b/bin/json/game_global.json @@ -364,6 +364,12 @@ 29, 5 ], + "DrawCard_5StarsInRange1": [ + 30, + 49, + 5 + ], + "DrawCard_5StarsInRange1_pool": "base_pool7", "DrawCard_ContinuousRestriction_Star5": 20, "DrawCard_ContinuousRestriction_Camp": 2, "EquipmentConsumption": [ @@ -525,6 +531,8 @@ "GuildBoss_MaxBuyNum": 5, "GuildBoss_troop2": 45, "GuildBoss_troop3": 60, - "zhayantime": 5 + "zhayantime": 5, + "rotateAngle": 360, + "rotateDizzyTime": 1 } ] \ No newline at end of file diff --git a/modules/hero/api_drawCard.go b/modules/hero/api_drawCard.go index 78d07374e..4c2b5b99e 100644 --- a/modules/hero/api_drawCard.go +++ b/modules/hero/api_drawCard.go @@ -29,7 +29,7 @@ func (this *apiComp) DrawCard(session comm.IUserSession, req *pb.HeroDrawCardReq cfgDraw *cfg.GameGlobalData costAtn *cfg.Gameatn heroRecord *pb.DBHeroRecord - pool string + pool string // 当前抽对应的卡池 _mapAddHero map[string]int32 strPool []string // 10连跨多个卡池情况 update map[string]interface{} @@ -129,7 +129,56 @@ func (this *apiComp) DrawCard(session comm.IUserSession, req *pb.HeroDrawCardReq } } } - + inRangeConf1 := this.module.configure.GetGlobalConf().DrawCard5StarsInRange1 + if len(inRangeConf1) == 3 { + iStart := inRangeConf1[0] // 抽卡开始 + iEnd := inRangeConf1[1] // 抽卡结束 + star := inRangeConf1[2] + if star >= 3 { // 保底必须三星+ + if heroRecord.Inevitable == 0 && heroRecord.Drawcount > iStart && heroRecord.Drawcount < iEnd && iEnd >= iStart { + n, _ := rand.Int(rand.Reader, big.NewInt(int64(iEnd-iStart))) + if n.Int64() < 1 { // 抽中 + starIndex = star + heroRecord.Inevitable = heroRecord.Drawcount + update["inevitable1"] = heroRecord.Drawcount + szStar = append(szStar, star) + if star == 4 { + heroRecord.Star4 = 0 + star4Max++ + } else if star == 5 { + star5Max++ + heroRecord.Star5 = 0 + } + // 修改卡池 + newPoll := this.module.configure.GetGlobalConf().DrawCard5StarsInRange1Pool + if newPoll != "" { + strPool[len(strPool)-1] = newPoll + } + continue + } + } + // 保底情况 + if heroRecord.Drawcount == iEnd && heroRecord.Inevitable == 0 { + starIndex = star + heroRecord.Inevitable1 = heroRecord.Drawcount + update["inevitable1"] = heroRecord.Drawcount + szStar = append(szStar, star) + if star == 4 { + heroRecord.Star4 = 0 + star4Max++ + } else if star == 5 { + star5Max++ + heroRecord.Star5 = 0 + } + // 修改卡池 + newPoll := this.module.configure.GetGlobalConf().DrawCard5StarsInRange1Pool + if newPoll != "" { + strPool[len(strPool)-1] = newPoll + } + continue + } + } + } heroRecord.Star4++ // 4星保底数量+1 heroRecord.Star5++ // 5星保底数量+1 if starIndex == 1 { diff --git a/modules/hero/hero_test.go b/modules/hero/hero_test.go index d5a4ab5d5..1697337f3 100644 --- a/modules/hero/hero_test.go +++ b/modules/hero/hero_test.go @@ -72,6 +72,12 @@ func GetMonthStartEnd() (int64, int64) { return _d1, _d2 } func Test_Main(t *testing.T) { + + sz := make([]string, 0) + for i := 0; i < 10; i++ { + sz = append(sz, "1") + } + sz[len(sz)-1] = "xxxx" //创建trace文件 f, err := os.Create("trace.out") if err != nil { diff --git a/modules/hero/module.go b/modules/hero/module.go index 5b7db230d..fc31518ce 100644 --- a/modules/hero/module.go +++ b/modules/hero/module.go @@ -770,3 +770,34 @@ func (this *Hero) SendTaskMsg(session comm.IUserSession, szStar []int32, drawCou } this.ModuleRtask.SendToRtask(session, comm.Rtype89, drawCount) } + +func (this Hero) newCondition(heroRecord *pb.DBHeroRecord) (get bool, starIndex int32) { + inRangeConf := this.configure.GetGlobalConf().DrawCard5StarsInRange + if len(inRangeConf) == 3 { + iStart := inRangeConf[0] // 抽卡开始 + iEnd := inRangeConf[1] // 抽卡结束 + star := inRangeConf[2] + if star >= 3 { // 保底必须三星+ + if heroRecord.Inevitable == 0 && heroRecord.Drawcount > iStart && heroRecord.Drawcount < iEnd && iEnd >= iStart { + n, _ := rand.Int(rand.Reader, big.NewInt(int64(iEnd-iStart))) + if n.Int64() < 1 { // 抽中 + starIndex = star + heroRecord.Inevitable = heroRecord.Drawcount + update := make(map[string]interface{}) + update["inevitable"] = heroRecord.Drawcount + + get = true + } + } + // 保底情况 + if heroRecord.Drawcount == iEnd && heroRecord.Inevitable == 0 { + starIndex = star + heroRecord.Inevitable = heroRecord.Drawcount + + get = true + } + } + } + get = false + return +} diff --git a/pb/hero_db.pb.go b/pb/hero_db.pb.go index d5e32eafa..93d70a009 100644 --- a/pb/hero_db.pb.go +++ b/pb/hero_db.pb.go @@ -375,19 +375,20 @@ type DBHeroRecord struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id" bson:"_id"` //ID 主键id - Uid string `protobuf:"bytes,2,opt,name=uid,proto3" json:"uid" bson:"uid"` //用户ID - Star4 int32 `protobuf:"varint,3,opt,name=star4,proto3" json:"star4"` // 4星保底 - Star5 int32 `protobuf:"varint,4,opt,name=star5,proto3" json:"star5"` // 5星保底 - Mtime int64 `protobuf:"varint,5,opt,name=mtime,proto3" json:"mtime"` // 修改时间 - Drawcount int32 `protobuf:"varint,6,opt,name=drawcount,proto3" json:"drawcount"` // 普通卡牌累计抽取次数 - Condition map[string]int32 `protobuf:"bytes,7,rep,name=condition,proto3" json:"condition" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"varint,2,opt,name=value,proto3"` // key recharge、login 等 value 累计抽卡次数 - Star5Hero map[string]int32 `protobuf:"bytes,8,rep,name=star5Hero,proto3" json:"star5Hero" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"varint,2,opt,name=value,proto3"` // 第totalcount 次抽到的5星英雄 key 英雄id - Totalcount int32 `protobuf:"varint,9,opt,name=totalcount,proto3" json:"totalcount"` // 总的累计抽卡次数 - Daycount int32 `protobuf:"varint,10,opt,name=daycount,proto3" json:"daycount"` // 今天抽卡次数 - Onebuy int32 `protobuf:"varint,11,opt,name=onebuy,proto3" json:"onebuy"` // 单次购买次数 - Tenbuy int32 `protobuf:"varint,12,opt,name=tenbuy,proto3" json:"tenbuy"` // 十连购买次数 - Inevitable int32 `protobuf:"varint,13,opt,name=inevitable,proto3" json:"inevitable"` //第2-30次抽奖必出一个5星英雄 + Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id" bson:"_id"` //ID 主键id + Uid string `protobuf:"bytes,2,opt,name=uid,proto3" json:"uid" bson:"uid"` //用户ID + Star4 int32 `protobuf:"varint,3,opt,name=star4,proto3" json:"star4"` // 4星保底 + Star5 int32 `protobuf:"varint,4,opt,name=star5,proto3" json:"star5"` // 5星保底 + Mtime int64 `protobuf:"varint,5,opt,name=mtime,proto3" json:"mtime"` // 修改时间 + Drawcount int32 `protobuf:"varint,6,opt,name=drawcount,proto3" json:"drawcount"` // 普通卡牌累计抽取次数 + Condition map[string]int32 `protobuf:"bytes,7,rep,name=condition,proto3" json:"condition" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"varint,2,opt,name=value,proto3"` // key recharge、login 等 value 累计抽卡次数 + Star5Hero map[string]int32 `protobuf:"bytes,8,rep,name=star5Hero,proto3" json:"star5Hero" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"varint,2,opt,name=value,proto3"` // 第totalcount 次抽到的5星英雄 key 英雄id + Totalcount int32 `protobuf:"varint,9,opt,name=totalcount,proto3" json:"totalcount"` // 总的累计抽卡次数 + Daycount int32 `protobuf:"varint,10,opt,name=daycount,proto3" json:"daycount"` // 今天抽卡次数 + Onebuy int32 `protobuf:"varint,11,opt,name=onebuy,proto3" json:"onebuy"` // 单次购买次数 + Tenbuy int32 `protobuf:"varint,12,opt,name=tenbuy,proto3" json:"tenbuy"` // 十连购买次数 + Inevitable int32 `protobuf:"varint,13,opt,name=inevitable,proto3" json:"inevitable"` //第2-30次抽奖必出一个5星英雄 + Inevitable1 int32 `protobuf:"varint,14,opt,name=inevitable1,proto3" json:"inevitable1"` //第30-50次抽奖必出一个5星英雄 } func (x *DBHeroRecord) Reset() { @@ -513,6 +514,13 @@ func (x *DBHeroRecord) GetInevitable() int32 { return 0 } +func (x *DBHeroRecord) GetInevitable1() int32 { + if x != nil { + return x.Inevitable1 + } + return 0 +} + // 英雄天赋系统 type DBHeroTalent struct { state protoimpl.MessageState @@ -693,7 +701,7 @@ var file_hero_hero_db_proto_rawDesc = []byte{ 0x70, 0x65, 0x72, 0x74, 0x79, 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, 0x22, 0x90, 0x04, 0x0a, 0x0c, 0x44, 0x42, 0x48, 0x65, 0x72, + 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x22, 0xb2, 0x04, 0x0a, 0x0c, 0x44, 0x42, 0x48, 0x65, 0x72, 0x6f, 0x52, 0x65, 0x63, 0x6f, 0x72, 0x64, 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, 0x73, 0x74, 0x61, @@ -718,31 +726,33 @@ var file_hero_hero_db_proto_rawDesc = []byte{ 0x6e, 0x65, 0x62, 0x75, 0x79, 0x12, 0x16, 0x0a, 0x06, 0x74, 0x65, 0x6e, 0x62, 0x75, 0x79, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06, 0x74, 0x65, 0x6e, 0x62, 0x75, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x69, 0x6e, 0x65, 0x76, 0x69, 0x74, 0x61, 0x62, 0x6c, 0x65, 0x18, 0x0d, 0x20, 0x01, 0x28, - 0x05, 0x52, 0x0a, 0x69, 0x6e, 0x65, 0x76, 0x69, 0x74, 0x61, 0x62, 0x6c, 0x65, 0x1a, 0x3c, 0x0a, - 0x0e, 0x43, 0x6f, 0x6e, 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, + 0x05, 0x52, 0x0a, 0x69, 0x6e, 0x65, 0x76, 0x69, 0x74, 0x61, 0x62, 0x6c, 0x65, 0x12, 0x20, 0x0a, + 0x0b, 0x69, 0x6e, 0x65, 0x76, 0x69, 0x74, 0x61, 0x62, 0x6c, 0x65, 0x31, 0x18, 0x0e, 0x20, 0x01, + 0x28, 0x05, 0x52, 0x0b, 0x69, 0x6e, 0x65, 0x76, 0x69, 0x74, 0x61, 0x62, 0x6c, 0x65, 0x31, 0x1a, + 0x3c, 0x0a, 0x0e, 0x43, 0x6f, 0x6e, 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 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, 0x3c, 0x0a, + 0x0e, 0x53, 0x74, 0x61, 0x72, 0x35, 0x48, 0x65, 0x72, 0x6f, 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, 0x3c, 0x0a, 0x0e, 0x53, - 0x74, 0x61, 0x72, 0x35, 0x48, 0x65, 0x72, 0x6f, 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, 0x22, 0xb6, 0x01, 0x0a, 0x0c, 0x44, 0x42, - 0x48, 0x65, 0x72, 0x6f, 0x54, 0x61, 0x6c, 0x65, 0x6e, 0x74, 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, 0x16, 0x0a, 0x06, - 0x68, 0x65, 0x72, 0x6f, 0x49, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x68, 0x65, - 0x72, 0x6f, 0x49, 0x64, 0x12, 0x31, 0x0a, 0x06, 0x74, 0x61, 0x6c, 0x65, 0x6e, 0x74, 0x18, 0x04, - 0x20, 0x03, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x44, 0x42, 0x48, 0x65, 0x72, 0x6f, 0x54, 0x61, 0x6c, - 0x65, 0x6e, 0x74, 0x2e, 0x54, 0x61, 0x6c, 0x65, 0x6e, 0x74, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, - 0x06, 0x74, 0x61, 0x6c, 0x65, 0x6e, 0x74, 0x1a, 0x39, 0x0a, 0x0b, 0x54, 0x61, 0x6c, 0x65, 0x6e, - 0x74, 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, 0x2f, 0x0a, 0x08, 0x48, 0x65, 0x72, 0x6f, 0x54, 0x79, 0x70, 0x65, 0x12, 0x0f, - 0x0a, 0x0b, 0x48, 0x65, 0x72, 0x6f, 0x54, 0x79, 0x70, 0x65, 0x4e, 0x69, 0x6c, 0x10, 0x00, 0x12, - 0x12, 0x0a, 0x0e, 0x48, 0x65, 0x72, 0x6f, 0x54, 0x79, 0x70, 0x65, 0x4b, 0x6f, 0x6e, 0x67, 0x46, - 0x75, 0x10, 0x01, 0x42, 0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, - 0x74, 0x6f, 0x33, + 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x22, 0xb6, 0x01, 0x0a, 0x0c, + 0x44, 0x42, 0x48, 0x65, 0x72, 0x6f, 0x54, 0x61, 0x6c, 0x65, 0x6e, 0x74, 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, 0x16, + 0x0a, 0x06, 0x68, 0x65, 0x72, 0x6f, 0x49, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, + 0x68, 0x65, 0x72, 0x6f, 0x49, 0x64, 0x12, 0x31, 0x0a, 0x06, 0x74, 0x61, 0x6c, 0x65, 0x6e, 0x74, + 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x44, 0x42, 0x48, 0x65, 0x72, 0x6f, 0x54, + 0x61, 0x6c, 0x65, 0x6e, 0x74, 0x2e, 0x54, 0x61, 0x6c, 0x65, 0x6e, 0x74, 0x45, 0x6e, 0x74, 0x72, + 0x79, 0x52, 0x06, 0x74, 0x61, 0x6c, 0x65, 0x6e, 0x74, 0x1a, 0x39, 0x0a, 0x0b, 0x54, 0x61, 0x6c, + 0x65, 0x6e, 0x74, 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, 0x2f, 0x0a, 0x08, 0x48, 0x65, 0x72, 0x6f, 0x54, 0x79, 0x70, 0x65, + 0x12, 0x0f, 0x0a, 0x0b, 0x48, 0x65, 0x72, 0x6f, 0x54, 0x79, 0x70, 0x65, 0x4e, 0x69, 0x6c, 0x10, + 0x00, 0x12, 0x12, 0x0a, 0x0e, 0x48, 0x65, 0x72, 0x6f, 0x54, 0x79, 0x70, 0x65, 0x4b, 0x6f, 0x6e, + 0x67, 0x46, 0x75, 0x10, 0x01, 0x42, 0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70, 0x62, 0x62, 0x06, 0x70, + 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( diff --git a/sys/configure/structs/game.globalData.go b/sys/configure/structs/game.globalData.go index 6b499b1b0..7a98c3a6b 100644 --- a/sys/configure/structs/game.globalData.go +++ b/sys/configure/structs/game.globalData.go @@ -143,6 +143,8 @@ type GameGlobalData struct { DrawCardRechargeReward []int32 DrawCardRegressionReward []int32 DrawCard5StarsInRange []int32 + DrawCard5StarsInRange1 []int32 + DrawCard5StarsInRange1Pool string DrawCardContinuousRestrictionStar5 int32 DrawCardContinuousRestrictionCamp int32 EquipmentConsumption []int32 @@ -169,6 +171,8 @@ type GameGlobalData struct { GuildBossTroop2 int32 GuildBossTroop3 int32 Zhayantime float32 + RotateAngle float32 + RotateDizzyTime float32 } const TypeId_GameGlobalData = 477542761 @@ -622,6 +626,21 @@ func (_v *GameGlobalData)Deserialize(_buf map[string]interface{}) (err error) { } } + { + var _arr_ []interface{} + var _ok_ bool + if _arr_, _ok_ = _buf["DrawCard_5StarsInRange1"].([]interface{}); !_ok_ { err = errors.New("DrawCard_5StarsInRange1 error"); return } + + _v.DrawCard5StarsInRange1 = make([]int32, 0, len(_arr_)) + + for _, _e_ := range _arr_ { + var _list_v_ int32 + { var _ok_ bool; var _x_ float64; if _x_, _ok_ = _e_.(float64); !_ok_ { err = errors.New("_list_v_ error"); return }; _list_v_ = int32(_x_) } + _v.DrawCard5StarsInRange1 = append(_v.DrawCard5StarsInRange1, _list_v_) + } + } + + { var _ok_ bool; if _v.DrawCard5StarsInRange1Pool, _ok_ = _buf["DrawCard_5StarsInRange1_pool"].(string); !_ok_ { err = errors.New("DrawCard_5StarsInRange1_pool error"); return } } { var _ok_ bool; var _tempNum_ float64; if _tempNum_, _ok_ = _buf["DrawCard_ContinuousRestriction_Star5"].(float64); !_ok_ { err = errors.New("DrawCard_ContinuousRestriction_Star5 error"); return }; _v.DrawCardContinuousRestrictionStar5 = int32(_tempNum_) } { var _ok_ bool; var _tempNum_ float64; if _tempNum_, _ok_ = _buf["DrawCard_ContinuousRestriction_Camp"].(float64); !_ok_ { err = errors.New("DrawCard_ContinuousRestriction_Camp error"); return }; _v.DrawCardContinuousRestrictionCamp = int32(_tempNum_) } { @@ -700,6 +719,8 @@ func (_v *GameGlobalData)Deserialize(_buf map[string]interface{}) (err error) { { var _ok_ bool; var _tempNum_ float64; if _tempNum_, _ok_ = _buf["GuildBoss_troop2"].(float64); !_ok_ { err = errors.New("GuildBoss_troop2 error"); return }; _v.GuildBossTroop2 = int32(_tempNum_) } { var _ok_ bool; var _tempNum_ float64; if _tempNum_, _ok_ = _buf["GuildBoss_troop3"].(float64); !_ok_ { err = errors.New("GuildBoss_troop3 error"); return }; _v.GuildBossTroop3 = int32(_tempNum_) } { var _ok_ bool; var _tempNum_ float64; if _tempNum_, _ok_ = _buf["zhayantime"].(float64); !_ok_ { err = errors.New("zhayantime error"); return }; _v.Zhayantime = float32(_tempNum_) } + { var _ok_ bool; var _tempNum_ float64; if _tempNum_, _ok_ = _buf["rotateAngle"].(float64); !_ok_ { err = errors.New("rotateAngle error"); return }; _v.RotateAngle = float32(_tempNum_) } + { var _ok_ bool; var _tempNum_ float64; if _tempNum_, _ok_ = _buf["rotateDizzyTime"].(float64); !_ok_ { err = errors.New("rotateDizzyTime error"); return }; _v.RotateDizzyTime = float32(_tempNum_) } return }