上传竞技场代码
This commit is contained in:
parent
17714c9595
commit
e7edca436e
@ -62,6 +62,7 @@ const (
|
|||||||
ModuleLinestory core.M_Modules = "linestory" //支线剧情
|
ModuleLinestory core.M_Modules = "linestory" //支线剧情
|
||||||
ModuleBattle core.M_Modules = "battle" //战斗
|
ModuleBattle core.M_Modules = "battle" //战斗
|
||||||
ModuleLibrary core.M_Modules = "library" //藏书馆
|
ModuleLibrary core.M_Modules = "library" //藏书馆
|
||||||
|
ModuleArena core.M_Modules = "arena" //竞技场
|
||||||
//ModuleFetter core.M_Modules = "herofetter" //好友模块
|
//ModuleFetter core.M_Modules = "herofetter" //好友模块
|
||||||
)
|
)
|
||||||
|
|
||||||
@ -149,6 +150,9 @@ const (
|
|||||||
TableCrossSession = "crosssession"
|
TableCrossSession = "crosssession"
|
||||||
|
|
||||||
TableServerData = "serverdata" // 跨服服务器相关数据
|
TableServerData = "serverdata" // 跨服服务器相关数据
|
||||||
|
|
||||||
|
///竞技场
|
||||||
|
TableArena = "arena"
|
||||||
)
|
)
|
||||||
|
|
||||||
//RPC服务接口定义处
|
//RPC服务接口定义处
|
||||||
|
56
modules/arena/modelarena.go
Normal file
56
modules/arena/modelarena.go
Normal file
@ -0,0 +1,56 @@
|
|||||||
|
package arena
|
||||||
|
|
||||||
|
import (
|
||||||
|
"context"
|
||||||
|
"go_dreamfactory/comm"
|
||||||
|
"go_dreamfactory/lego/core"
|
||||||
|
"go_dreamfactory/modules"
|
||||||
|
"go_dreamfactory/pb"
|
||||||
|
|
||||||
|
"go.mongodb.org/mongo-driver/bson"
|
||||||
|
"go.mongodb.org/mongo-driver/mongo"
|
||||||
|
"go.mongodb.org/mongo-driver/x/bsonx"
|
||||||
|
)
|
||||||
|
|
||||||
|
///竞技场 数据组件
|
||||||
|
type modelArena struct {
|
||||||
|
modules.MCompModel
|
||||||
|
module *Arena
|
||||||
|
}
|
||||||
|
|
||||||
|
//组件初始化接口
|
||||||
|
func (this *modelArena) Init(service core.IService, module core.IModule, comp core.IModuleComp, opt core.IModuleOptions) (err error) {
|
||||||
|
this.TableName = comm.TableArena
|
||||||
|
this.MCompModel.Init(service, module, comp, opt)
|
||||||
|
this.module = module.(*Arena)
|
||||||
|
//创建uid索引
|
||||||
|
this.DB.CreateIndex(core.SqlTable(this.TableName), mongo.IndexModel{
|
||||||
|
Keys: bsonx.Doc{{Key: "uid", Value: bsonx.Int32(1)}},
|
||||||
|
})
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
//获取目标去陪数据
|
||||||
|
func (this *modelArena) matche(integral int32) (results []*pb.DBArenaUser, err error) {
|
||||||
|
var (
|
||||||
|
cursor *mongo.Cursor
|
||||||
|
)
|
||||||
|
project := bson.M{"$project": bson.M{
|
||||||
|
"diff": bson.M{
|
||||||
|
"$abs": bson.M{"$subtract": bson.A{integral, "$start"}},
|
||||||
|
},
|
||||||
|
}}
|
||||||
|
if cursor, err = this.DBModel.DB.Aggregate(comm.TableArena, bson.A{project}); err != nil {
|
||||||
|
this.module.Errorln(err)
|
||||||
|
return
|
||||||
|
} else {
|
||||||
|
for cursor.Next(context.Background()) {
|
||||||
|
temp := &pb.DBArenaUser{}
|
||||||
|
if err = cursor.Decode(temp); err != nil {
|
||||||
|
this.module.Errorln(err)
|
||||||
|
return
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return
|
||||||
|
}
|
33
modules/arena/module.go
Normal file
33
modules/arena/module.go
Normal file
@ -0,0 +1,33 @@
|
|||||||
|
package arena
|
||||||
|
|
||||||
|
import (
|
||||||
|
"go_dreamfactory/comm"
|
||||||
|
"go_dreamfactory/lego/core"
|
||||||
|
"go_dreamfactory/modules"
|
||||||
|
)
|
||||||
|
|
||||||
|
/*
|
||||||
|
模块名:战斗模块
|
||||||
|
描述:处理游侠战斗相关业务
|
||||||
|
开发:李伟
|
||||||
|
*/
|
||||||
|
func NewModule() core.IModule {
|
||||||
|
m := new(Arena)
|
||||||
|
return m
|
||||||
|
}
|
||||||
|
|
||||||
|
type Arena struct {
|
||||||
|
modules.ModuleBase
|
||||||
|
}
|
||||||
|
|
||||||
|
//模块名
|
||||||
|
func (this *Arena) GetType() core.M_Modules {
|
||||||
|
return comm.ModuleArena
|
||||||
|
}
|
||||||
|
|
||||||
|
//模块初始化接口 注册用户创建角色事件
|
||||||
|
func (this *Arena) Init(service core.IService, module core.IModule, options core.IModuleOptions) (err error) {
|
||||||
|
err = this.ModuleBase.Init(service, module, options)
|
||||||
|
|
||||||
|
return
|
||||||
|
}
|
237
pb/arena_db.pb.go
Normal file
237
pb/arena_db.pb.go
Normal file
@ -0,0 +1,237 @@
|
|||||||
|
// Code generated by protoc-gen-go. DO NOT EDIT.
|
||||||
|
// versions:
|
||||||
|
// protoc-gen-go v1.28.0
|
||||||
|
// protoc v3.20.0
|
||||||
|
// source: arena/arena_db.proto
|
||||||
|
|
||||||
|
package pb
|
||||||
|
|
||||||
|
import (
|
||||||
|
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
|
||||||
|
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
|
||||||
|
reflect "reflect"
|
||||||
|
sync "sync"
|
||||||
|
)
|
||||||
|
|
||||||
|
const (
|
||||||
|
// Verify that this generated code is sufficiently up-to-date.
|
||||||
|
_ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
|
||||||
|
// Verify that runtime/protoimpl is sufficiently up-to-date.
|
||||||
|
_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
|
||||||
|
)
|
||||||
|
|
||||||
|
//玩家战斗阵型
|
||||||
|
type DBPlayerBattleFormt struct {
|
||||||
|
state protoimpl.MessageState
|
||||||
|
sizeCache protoimpl.SizeCache
|
||||||
|
unknownFields protoimpl.UnknownFields
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *DBPlayerBattleFormt) Reset() {
|
||||||
|
*x = DBPlayerBattleFormt{}
|
||||||
|
if protoimpl.UnsafeEnabled {
|
||||||
|
mi := &file_arena_arena_db_proto_msgTypes[0]
|
||||||
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
|
ms.StoreMessageInfo(mi)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *DBPlayerBattleFormt) String() string {
|
||||||
|
return protoimpl.X.MessageStringOf(x)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (*DBPlayerBattleFormt) ProtoMessage() {}
|
||||||
|
|
||||||
|
func (x *DBPlayerBattleFormt) ProtoReflect() protoreflect.Message {
|
||||||
|
mi := &file_arena_arena_db_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 DBPlayerBattleFormt.ProtoReflect.Descriptor instead.
|
||||||
|
func (*DBPlayerBattleFormt) Descriptor() ([]byte, []int) {
|
||||||
|
return file_arena_arena_db_proto_rawDescGZIP(), []int{0}
|
||||||
|
}
|
||||||
|
|
||||||
|
type DBArenaUser struct {
|
||||||
|
state protoimpl.MessageState
|
||||||
|
sizeCache protoimpl.SizeCache
|
||||||
|
unknownFields protoimpl.UnknownFields
|
||||||
|
|
||||||
|
Uid string `protobuf:"bytes,1,opt,name=uid,proto3" json:"uid"` //用户id
|
||||||
|
Integral int32 `protobuf:"varint,2,opt,name=Integral,proto3" json:"Integral"` //积分
|
||||||
|
Attack *DBPlayerBattleFormt `protobuf:"bytes,3,opt,name=attack,proto3" json:"attack"` //进攻阵型
|
||||||
|
Defend *DBPlayerBattleFormt `protobuf:"bytes,4,opt,name=defend,proto3" json:"defend"` //防守阵型
|
||||||
|
Streak int32 `protobuf:"varint,5,opt,name=streak,proto3" json:"streak"` //连胜
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *DBArenaUser) Reset() {
|
||||||
|
*x = DBArenaUser{}
|
||||||
|
if protoimpl.UnsafeEnabled {
|
||||||
|
mi := &file_arena_arena_db_proto_msgTypes[1]
|
||||||
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
|
ms.StoreMessageInfo(mi)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *DBArenaUser) String() string {
|
||||||
|
return protoimpl.X.MessageStringOf(x)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (*DBArenaUser) ProtoMessage() {}
|
||||||
|
|
||||||
|
func (x *DBArenaUser) ProtoReflect() protoreflect.Message {
|
||||||
|
mi := &file_arena_arena_db_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 DBArenaUser.ProtoReflect.Descriptor instead.
|
||||||
|
func (*DBArenaUser) Descriptor() ([]byte, []int) {
|
||||||
|
return file_arena_arena_db_proto_rawDescGZIP(), []int{1}
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *DBArenaUser) GetUid() string {
|
||||||
|
if x != nil {
|
||||||
|
return x.Uid
|
||||||
|
}
|
||||||
|
return ""
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *DBArenaUser) GetIntegral() int32 {
|
||||||
|
if x != nil {
|
||||||
|
return x.Integral
|
||||||
|
}
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *DBArenaUser) GetAttack() *DBPlayerBattleFormt {
|
||||||
|
if x != nil {
|
||||||
|
return x.Attack
|
||||||
|
}
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *DBArenaUser) GetDefend() *DBPlayerBattleFormt {
|
||||||
|
if x != nil {
|
||||||
|
return x.Defend
|
||||||
|
}
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *DBArenaUser) GetStreak() int32 {
|
||||||
|
if x != nil {
|
||||||
|
return x.Streak
|
||||||
|
}
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
|
||||||
|
var File_arena_arena_db_proto protoreflect.FileDescriptor
|
||||||
|
|
||||||
|
var file_arena_arena_db_proto_rawDesc = []byte{
|
||||||
|
0x0a, 0x14, 0x61, 0x72, 0x65, 0x6e, 0x61, 0x2f, 0x61, 0x72, 0x65, 0x6e, 0x61, 0x5f, 0x64, 0x62,
|
||||||
|
0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x15, 0x0a, 0x13, 0x44, 0x42, 0x50, 0x6c, 0x61, 0x79,
|
||||||
|
0x65, 0x72, 0x42, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x46, 0x6f, 0x72, 0x6d, 0x74, 0x22, 0xaf, 0x01,
|
||||||
|
0x0a, 0x0b, 0x44, 0x42, 0x41, 0x72, 0x65, 0x6e, 0x61, 0x55, 0x73, 0x65, 0x72, 0x12, 0x10, 0x0a,
|
||||||
|
0x03, 0x75, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x75, 0x69, 0x64, 0x12,
|
||||||
|
0x1a, 0x0a, 0x08, 0x49, 0x6e, 0x74, 0x65, 0x67, 0x72, 0x61, 0x6c, 0x18, 0x02, 0x20, 0x01, 0x28,
|
||||||
|
0x05, 0x52, 0x08, 0x49, 0x6e, 0x74, 0x65, 0x67, 0x72, 0x61, 0x6c, 0x12, 0x2c, 0x0a, 0x06, 0x61,
|
||||||
|
0x74, 0x74, 0x61, 0x63, 0x6b, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x14, 0x2e, 0x44, 0x42,
|
||||||
|
0x50, 0x6c, 0x61, 0x79, 0x65, 0x72, 0x42, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x46, 0x6f, 0x72, 0x6d,
|
||||||
|
0x74, 0x52, 0x06, 0x61, 0x74, 0x74, 0x61, 0x63, 0x6b, 0x12, 0x2c, 0x0a, 0x06, 0x64, 0x65, 0x66,
|
||||||
|
0x65, 0x6e, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x14, 0x2e, 0x44, 0x42, 0x50, 0x6c,
|
||||||
|
0x61, 0x79, 0x65, 0x72, 0x42, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x46, 0x6f, 0x72, 0x6d, 0x74, 0x52,
|
||||||
|
0x06, 0x64, 0x65, 0x66, 0x65, 0x6e, 0x64, 0x12, 0x16, 0x0a, 0x06, 0x73, 0x74, 0x72, 0x65, 0x61,
|
||||||
|
0x6b, 0x18, 0x05, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06, 0x73, 0x74, 0x72, 0x65, 0x61, 0x6b, 0x42,
|
||||||
|
0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
|
||||||
|
}
|
||||||
|
|
||||||
|
var (
|
||||||
|
file_arena_arena_db_proto_rawDescOnce sync.Once
|
||||||
|
file_arena_arena_db_proto_rawDescData = file_arena_arena_db_proto_rawDesc
|
||||||
|
)
|
||||||
|
|
||||||
|
func file_arena_arena_db_proto_rawDescGZIP() []byte {
|
||||||
|
file_arena_arena_db_proto_rawDescOnce.Do(func() {
|
||||||
|
file_arena_arena_db_proto_rawDescData = protoimpl.X.CompressGZIP(file_arena_arena_db_proto_rawDescData)
|
||||||
|
})
|
||||||
|
return file_arena_arena_db_proto_rawDescData
|
||||||
|
}
|
||||||
|
|
||||||
|
var file_arena_arena_db_proto_msgTypes = make([]protoimpl.MessageInfo, 2)
|
||||||
|
var file_arena_arena_db_proto_goTypes = []interface{}{
|
||||||
|
(*DBPlayerBattleFormt)(nil), // 0: DBPlayerBattleFormt
|
||||||
|
(*DBArenaUser)(nil), // 1: DBArenaUser
|
||||||
|
}
|
||||||
|
var file_arena_arena_db_proto_depIdxs = []int32{
|
||||||
|
0, // 0: DBArenaUser.attack:type_name -> DBPlayerBattleFormt
|
||||||
|
0, // 1: DBArenaUser.defend:type_name -> DBPlayerBattleFormt
|
||||||
|
2, // [2:2] is the sub-list for method output_type
|
||||||
|
2, // [2:2] is the sub-list for method input_type
|
||||||
|
2, // [2:2] is the sub-list for extension type_name
|
||||||
|
2, // [2:2] is the sub-list for extension extendee
|
||||||
|
0, // [0:2] is the sub-list for field type_name
|
||||||
|
}
|
||||||
|
|
||||||
|
func init() { file_arena_arena_db_proto_init() }
|
||||||
|
func file_arena_arena_db_proto_init() {
|
||||||
|
if File_arena_arena_db_proto != nil {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
if !protoimpl.UnsafeEnabled {
|
||||||
|
file_arena_arena_db_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
|
||||||
|
switch v := v.(*DBPlayerBattleFormt); i {
|
||||||
|
case 0:
|
||||||
|
return &v.state
|
||||||
|
case 1:
|
||||||
|
return &v.sizeCache
|
||||||
|
case 2:
|
||||||
|
return &v.unknownFields
|
||||||
|
default:
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
}
|
||||||
|
file_arena_arena_db_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} {
|
||||||
|
switch v := v.(*DBArenaUser); 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{
|
||||||
|
File: protoimpl.DescBuilder{
|
||||||
|
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
||||||
|
RawDescriptor: file_arena_arena_db_proto_rawDesc,
|
||||||
|
NumEnums: 0,
|
||||||
|
NumMessages: 2,
|
||||||
|
NumExtensions: 0,
|
||||||
|
NumServices: 0,
|
||||||
|
},
|
||||||
|
GoTypes: file_arena_arena_db_proto_goTypes,
|
||||||
|
DependencyIndexes: file_arena_arena_db_proto_depIdxs,
|
||||||
|
MessageInfos: file_arena_arena_db_proto_msgTypes,
|
||||||
|
}.Build()
|
||||||
|
File_arena_arena_db_proto = out.File
|
||||||
|
file_arena_arena_db_proto_rawDesc = nil
|
||||||
|
file_arena_arena_db_proto_goTypes = nil
|
||||||
|
file_arena_arena_db_proto_depIdxs = nil
|
||||||
|
}
|
504
pb/arena_msg.pb.go
Normal file
504
pb/arena_msg.pb.go
Normal file
@ -0,0 +1,504 @@
|
|||||||
|
// Code generated by protoc-gen-go. DO NOT EDIT.
|
||||||
|
// versions:
|
||||||
|
// protoc-gen-go v1.28.0
|
||||||
|
// protoc v3.20.0
|
||||||
|
// source: arena/arena_msg.proto
|
||||||
|
|
||||||
|
package pb
|
||||||
|
|
||||||
|
import (
|
||||||
|
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
|
||||||
|
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
|
||||||
|
reflect "reflect"
|
||||||
|
sync "sync"
|
||||||
|
)
|
||||||
|
|
||||||
|
const (
|
||||||
|
// Verify that this generated code is sufficiently up-to-date.
|
||||||
|
_ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
|
||||||
|
// Verify that runtime/protoimpl is sufficiently up-to-date.
|
||||||
|
_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
|
||||||
|
)
|
||||||
|
|
||||||
|
//竞技场信息 请求
|
||||||
|
type ArenaInfoReq struct {
|
||||||
|
state protoimpl.MessageState
|
||||||
|
sizeCache protoimpl.SizeCache
|
||||||
|
unknownFields protoimpl.UnknownFields
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *ArenaInfoReq) Reset() {
|
||||||
|
*x = ArenaInfoReq{}
|
||||||
|
if protoimpl.UnsafeEnabled {
|
||||||
|
mi := &file_arena_arena_msg_proto_msgTypes[0]
|
||||||
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
|
ms.StoreMessageInfo(mi)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *ArenaInfoReq) String() string {
|
||||||
|
return protoimpl.X.MessageStringOf(x)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (*ArenaInfoReq) ProtoMessage() {}
|
||||||
|
|
||||||
|
func (x *ArenaInfoReq) ProtoReflect() protoreflect.Message {
|
||||||
|
mi := &file_arena_arena_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 ArenaInfoReq.ProtoReflect.Descriptor instead.
|
||||||
|
func (*ArenaInfoReq) Descriptor() ([]byte, []int) {
|
||||||
|
return file_arena_arena_msg_proto_rawDescGZIP(), []int{0}
|
||||||
|
}
|
||||||
|
|
||||||
|
//竞技场信息 回应
|
||||||
|
type ArenaInfoResp struct {
|
||||||
|
state protoimpl.MessageState
|
||||||
|
sizeCache protoimpl.SizeCache
|
||||||
|
unknownFields protoimpl.UnknownFields
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *ArenaInfoResp) Reset() {
|
||||||
|
*x = ArenaInfoResp{}
|
||||||
|
if protoimpl.UnsafeEnabled {
|
||||||
|
mi := &file_arena_arena_msg_proto_msgTypes[1]
|
||||||
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
|
ms.StoreMessageInfo(mi)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *ArenaInfoResp) String() string {
|
||||||
|
return protoimpl.X.MessageStringOf(x)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (*ArenaInfoResp) ProtoMessage() {}
|
||||||
|
|
||||||
|
func (x *ArenaInfoResp) ProtoReflect() protoreflect.Message {
|
||||||
|
mi := &file_arena_arena_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 ArenaInfoResp.ProtoReflect.Descriptor instead.
|
||||||
|
func (*ArenaInfoResp) Descriptor() ([]byte, []int) {
|
||||||
|
return file_arena_arena_msg_proto_rawDescGZIP(), []int{1}
|
||||||
|
}
|
||||||
|
|
||||||
|
//竞技场匹配 请求
|
||||||
|
type ArenaMatcheReq struct {
|
||||||
|
state protoimpl.MessageState
|
||||||
|
sizeCache protoimpl.SizeCache
|
||||||
|
unknownFields protoimpl.UnknownFields
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *ArenaMatcheReq) Reset() {
|
||||||
|
*x = ArenaMatcheReq{}
|
||||||
|
if protoimpl.UnsafeEnabled {
|
||||||
|
mi := &file_arena_arena_msg_proto_msgTypes[2]
|
||||||
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
|
ms.StoreMessageInfo(mi)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *ArenaMatcheReq) String() string {
|
||||||
|
return protoimpl.X.MessageStringOf(x)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (*ArenaMatcheReq) ProtoMessage() {}
|
||||||
|
|
||||||
|
func (x *ArenaMatcheReq) ProtoReflect() protoreflect.Message {
|
||||||
|
mi := &file_arena_arena_msg_proto_msgTypes[2]
|
||||||
|
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 ArenaMatcheReq.ProtoReflect.Descriptor instead.
|
||||||
|
func (*ArenaMatcheReq) Descriptor() ([]byte, []int) {
|
||||||
|
return file_arena_arena_msg_proto_rawDescGZIP(), []int{2}
|
||||||
|
}
|
||||||
|
|
||||||
|
//竞技场匹配 回应
|
||||||
|
type ArenaMatcheResp struct {
|
||||||
|
state protoimpl.MessageState
|
||||||
|
sizeCache protoimpl.SizeCache
|
||||||
|
unknownFields protoimpl.UnknownFields
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *ArenaMatcheResp) Reset() {
|
||||||
|
*x = ArenaMatcheResp{}
|
||||||
|
if protoimpl.UnsafeEnabled {
|
||||||
|
mi := &file_arena_arena_msg_proto_msgTypes[3]
|
||||||
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
|
ms.StoreMessageInfo(mi)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *ArenaMatcheResp) String() string {
|
||||||
|
return protoimpl.X.MessageStringOf(x)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (*ArenaMatcheResp) ProtoMessage() {}
|
||||||
|
|
||||||
|
func (x *ArenaMatcheResp) ProtoReflect() protoreflect.Message {
|
||||||
|
mi := &file_arena_arena_msg_proto_msgTypes[3]
|
||||||
|
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 ArenaMatcheResp.ProtoReflect.Descriptor instead.
|
||||||
|
func (*ArenaMatcheResp) Descriptor() ([]byte, []int) {
|
||||||
|
return file_arena_arena_msg_proto_rawDescGZIP(), []int{3}
|
||||||
|
}
|
||||||
|
|
||||||
|
//竞技场挑战 请求
|
||||||
|
type ArenaChallengeReq struct {
|
||||||
|
state protoimpl.MessageState
|
||||||
|
sizeCache protoimpl.SizeCache
|
||||||
|
unknownFields protoimpl.UnknownFields
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *ArenaChallengeReq) Reset() {
|
||||||
|
*x = ArenaChallengeReq{}
|
||||||
|
if protoimpl.UnsafeEnabled {
|
||||||
|
mi := &file_arena_arena_msg_proto_msgTypes[4]
|
||||||
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
|
ms.StoreMessageInfo(mi)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *ArenaChallengeReq) String() string {
|
||||||
|
return protoimpl.X.MessageStringOf(x)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (*ArenaChallengeReq) ProtoMessage() {}
|
||||||
|
|
||||||
|
func (x *ArenaChallengeReq) ProtoReflect() protoreflect.Message {
|
||||||
|
mi := &file_arena_arena_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 ArenaChallengeReq.ProtoReflect.Descriptor instead.
|
||||||
|
func (*ArenaChallengeReq) Descriptor() ([]byte, []int) {
|
||||||
|
return file_arena_arena_msg_proto_rawDescGZIP(), []int{4}
|
||||||
|
}
|
||||||
|
|
||||||
|
//竞技场挑战 回应
|
||||||
|
type ArenaChallengeResp struct {
|
||||||
|
state protoimpl.MessageState
|
||||||
|
sizeCache protoimpl.SizeCache
|
||||||
|
unknownFields protoimpl.UnknownFields
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *ArenaChallengeResp) Reset() {
|
||||||
|
*x = ArenaChallengeResp{}
|
||||||
|
if protoimpl.UnsafeEnabled {
|
||||||
|
mi := &file_arena_arena_msg_proto_msgTypes[5]
|
||||||
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
|
ms.StoreMessageInfo(mi)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *ArenaChallengeResp) String() string {
|
||||||
|
return protoimpl.X.MessageStringOf(x)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (*ArenaChallengeResp) ProtoMessage() {}
|
||||||
|
|
||||||
|
func (x *ArenaChallengeResp) ProtoReflect() protoreflect.Message {
|
||||||
|
mi := &file_arena_arena_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 ArenaChallengeResp.ProtoReflect.Descriptor instead.
|
||||||
|
func (*ArenaChallengeResp) Descriptor() ([]byte, []int) {
|
||||||
|
return file_arena_arena_msg_proto_rawDescGZIP(), []int{5}
|
||||||
|
}
|
||||||
|
|
||||||
|
//竞技场排行榜 请求
|
||||||
|
type ArenaRankReq struct {
|
||||||
|
state protoimpl.MessageState
|
||||||
|
sizeCache protoimpl.SizeCache
|
||||||
|
unknownFields protoimpl.UnknownFields
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *ArenaRankReq) Reset() {
|
||||||
|
*x = ArenaRankReq{}
|
||||||
|
if protoimpl.UnsafeEnabled {
|
||||||
|
mi := &file_arena_arena_msg_proto_msgTypes[6]
|
||||||
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
|
ms.StoreMessageInfo(mi)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *ArenaRankReq) String() string {
|
||||||
|
return protoimpl.X.MessageStringOf(x)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (*ArenaRankReq) ProtoMessage() {}
|
||||||
|
|
||||||
|
func (x *ArenaRankReq) ProtoReflect() protoreflect.Message {
|
||||||
|
mi := &file_arena_arena_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 ArenaRankReq.ProtoReflect.Descriptor instead.
|
||||||
|
func (*ArenaRankReq) Descriptor() ([]byte, []int) {
|
||||||
|
return file_arena_arena_msg_proto_rawDescGZIP(), []int{6}
|
||||||
|
}
|
||||||
|
|
||||||
|
//竞技场排行榜 回应
|
||||||
|
type ArenaRankResp struct {
|
||||||
|
state protoimpl.MessageState
|
||||||
|
sizeCache protoimpl.SizeCache
|
||||||
|
unknownFields protoimpl.UnknownFields
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *ArenaRankResp) Reset() {
|
||||||
|
*x = ArenaRankResp{}
|
||||||
|
if protoimpl.UnsafeEnabled {
|
||||||
|
mi := &file_arena_arena_msg_proto_msgTypes[7]
|
||||||
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
|
ms.StoreMessageInfo(mi)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *ArenaRankResp) String() string {
|
||||||
|
return protoimpl.X.MessageStringOf(x)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (*ArenaRankResp) ProtoMessage() {}
|
||||||
|
|
||||||
|
func (x *ArenaRankResp) ProtoReflect() protoreflect.Message {
|
||||||
|
mi := &file_arena_arena_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 ArenaRankResp.ProtoReflect.Descriptor instead.
|
||||||
|
func (*ArenaRankResp) Descriptor() ([]byte, []int) {
|
||||||
|
return file_arena_arena_msg_proto_rawDescGZIP(), []int{7}
|
||||||
|
}
|
||||||
|
|
||||||
|
var File_arena_arena_msg_proto protoreflect.FileDescriptor
|
||||||
|
|
||||||
|
var file_arena_arena_msg_proto_rawDesc = []byte{
|
||||||
|
0x0a, 0x15, 0x61, 0x72, 0x65, 0x6e, 0x61, 0x2f, 0x61, 0x72, 0x65, 0x6e, 0x61, 0x5f, 0x6d, 0x73,
|
||||||
|
0x67, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x0e, 0x0a, 0x0c, 0x41, 0x72, 0x65, 0x6e, 0x61,
|
||||||
|
0x49, 0x6e, 0x66, 0x6f, 0x52, 0x65, 0x71, 0x22, 0x0f, 0x0a, 0x0d, 0x41, 0x72, 0x65, 0x6e, 0x61,
|
||||||
|
0x49, 0x6e, 0x66, 0x6f, 0x52, 0x65, 0x73, 0x70, 0x22, 0x10, 0x0a, 0x0e, 0x41, 0x72, 0x65, 0x6e,
|
||||||
|
0x61, 0x4d, 0x61, 0x74, 0x63, 0x68, 0x65, 0x52, 0x65, 0x71, 0x22, 0x11, 0x0a, 0x0f, 0x41, 0x72,
|
||||||
|
0x65, 0x6e, 0x61, 0x4d, 0x61, 0x74, 0x63, 0x68, 0x65, 0x52, 0x65, 0x73, 0x70, 0x22, 0x13, 0x0a,
|
||||||
|
0x11, 0x41, 0x72, 0x65, 0x6e, 0x61, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x52,
|
||||||
|
0x65, 0x71, 0x22, 0x14, 0x0a, 0x12, 0x41, 0x72, 0x65, 0x6e, 0x61, 0x43, 0x68, 0x61, 0x6c, 0x6c,
|
||||||
|
0x65, 0x6e, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x22, 0x0e, 0x0a, 0x0c, 0x41, 0x72, 0x65, 0x6e,
|
||||||
|
0x61, 0x52, 0x61, 0x6e, 0x6b, 0x52, 0x65, 0x71, 0x22, 0x0f, 0x0a, 0x0d, 0x41, 0x72, 0x65, 0x6e,
|
||||||
|
0x61, 0x52, 0x61, 0x6e, 0x6b, 0x52, 0x65, 0x73, 0x70, 0x42, 0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70,
|
||||||
|
0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
|
||||||
|
}
|
||||||
|
|
||||||
|
var (
|
||||||
|
file_arena_arena_msg_proto_rawDescOnce sync.Once
|
||||||
|
file_arena_arena_msg_proto_rawDescData = file_arena_arena_msg_proto_rawDesc
|
||||||
|
)
|
||||||
|
|
||||||
|
func file_arena_arena_msg_proto_rawDescGZIP() []byte {
|
||||||
|
file_arena_arena_msg_proto_rawDescOnce.Do(func() {
|
||||||
|
file_arena_arena_msg_proto_rawDescData = protoimpl.X.CompressGZIP(file_arena_arena_msg_proto_rawDescData)
|
||||||
|
})
|
||||||
|
return file_arena_arena_msg_proto_rawDescData
|
||||||
|
}
|
||||||
|
|
||||||
|
var file_arena_arena_msg_proto_msgTypes = make([]protoimpl.MessageInfo, 8)
|
||||||
|
var file_arena_arena_msg_proto_goTypes = []interface{}{
|
||||||
|
(*ArenaInfoReq)(nil), // 0: ArenaInfoReq
|
||||||
|
(*ArenaInfoResp)(nil), // 1: ArenaInfoResp
|
||||||
|
(*ArenaMatcheReq)(nil), // 2: ArenaMatcheReq
|
||||||
|
(*ArenaMatcheResp)(nil), // 3: ArenaMatcheResp
|
||||||
|
(*ArenaChallengeReq)(nil), // 4: ArenaChallengeReq
|
||||||
|
(*ArenaChallengeResp)(nil), // 5: ArenaChallengeResp
|
||||||
|
(*ArenaRankReq)(nil), // 6: ArenaRankReq
|
||||||
|
(*ArenaRankResp)(nil), // 7: ArenaRankResp
|
||||||
|
}
|
||||||
|
var file_arena_arena_msg_proto_depIdxs = []int32{
|
||||||
|
0, // [0:0] is the sub-list for method output_type
|
||||||
|
0, // [0:0] is the sub-list for method input_type
|
||||||
|
0, // [0:0] is the sub-list for extension type_name
|
||||||
|
0, // [0:0] is the sub-list for extension extendee
|
||||||
|
0, // [0:0] is the sub-list for field type_name
|
||||||
|
}
|
||||||
|
|
||||||
|
func init() { file_arena_arena_msg_proto_init() }
|
||||||
|
func file_arena_arena_msg_proto_init() {
|
||||||
|
if File_arena_arena_msg_proto != nil {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
if !protoimpl.UnsafeEnabled {
|
||||||
|
file_arena_arena_msg_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
|
||||||
|
switch v := v.(*ArenaInfoReq); 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[1].Exporter = func(v interface{}, i int) interface{} {
|
||||||
|
switch v := v.(*ArenaInfoResp); 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[2].Exporter = func(v interface{}, i int) interface{} {
|
||||||
|
switch v := v.(*ArenaMatcheReq); 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[3].Exporter = func(v interface{}, i int) interface{} {
|
||||||
|
switch v := v.(*ArenaMatcheResp); 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[4].Exporter = func(v interface{}, i int) interface{} {
|
||||||
|
switch v := v.(*ArenaChallengeReq); 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[5].Exporter = func(v interface{}, i int) interface{} {
|
||||||
|
switch v := v.(*ArenaChallengeResp); 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[6].Exporter = func(v interface{}, i int) interface{} {
|
||||||
|
switch v := v.(*ArenaRankReq); 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[7].Exporter = func(v interface{}, i int) interface{} {
|
||||||
|
switch v := v.(*ArenaRankResp); 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{
|
||||||
|
File: protoimpl.DescBuilder{
|
||||||
|
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
||||||
|
RawDescriptor: file_arena_arena_msg_proto_rawDesc,
|
||||||
|
NumEnums: 0,
|
||||||
|
NumMessages: 8,
|
||||||
|
NumExtensions: 0,
|
||||||
|
NumServices: 0,
|
||||||
|
},
|
||||||
|
GoTypes: file_arena_arena_msg_proto_goTypes,
|
||||||
|
DependencyIndexes: file_arena_arena_msg_proto_depIdxs,
|
||||||
|
MessageInfos: file_arena_arena_msg_proto_msgTypes,
|
||||||
|
}.Build()
|
||||||
|
File_arena_arena_msg_proto = out.File
|
||||||
|
file_arena_arena_msg_proto_rawDesc = nil
|
||||||
|
file_arena_arena_msg_proto_goTypes = nil
|
||||||
|
file_arena_arena_msg_proto_depIdxs = nil
|
||||||
|
}
|
Loading…
Reference in New Issue
Block a user