附魔副本支持跨服
This commit is contained in:
parent
b7ac0d3c49
commit
72ecb44ad2
@ -4,6 +4,7 @@ import (
|
|||||||
"go_dreamfactory/comm"
|
"go_dreamfactory/comm"
|
||||||
"go_dreamfactory/pb"
|
"go_dreamfactory/pb"
|
||||||
cfg "go_dreamfactory/sys/configure/structs"
|
cfg "go_dreamfactory/sys/configure/structs"
|
||||||
|
"time"
|
||||||
)
|
)
|
||||||
|
|
||||||
//参数校验
|
//参数校验
|
||||||
@ -33,6 +34,7 @@ func (this *apiComp) ChallengeOver(session comm.IUserSession, req *pb.EnchantCha
|
|||||||
boos *pb.DBEnchantBoos
|
boos *pb.DBEnchantBoos
|
||||||
ok bool
|
ok bool
|
||||||
err error
|
err error
|
||||||
|
//bNewRecord bool
|
||||||
)
|
)
|
||||||
if errdata = this.ChallengeOverCheck(session, req); errdata != nil {
|
if errdata = this.ChallengeOverCheck(session, req); errdata != nil {
|
||||||
return // 参数校验失败直接返回
|
return // 参数校验失败直接返回
|
||||||
@ -101,6 +103,7 @@ func (this *apiComp) ChallengeOver(session comm.IUserSession, req *pb.EnchantCha
|
|||||||
},
|
},
|
||||||
}
|
}
|
||||||
info.Boss[req.BossType] = boos
|
info.Boss[req.BossType] = boos
|
||||||
|
//bNewRecord = true
|
||||||
} else {
|
} else {
|
||||||
if boos.Score < req.Report.Score {
|
if boos.Score < req.Report.Score {
|
||||||
boos = &pb.DBEnchantBoos{
|
boos = &pb.DBEnchantBoos{
|
||||||
@ -114,6 +117,7 @@ func (this *apiComp) ChallengeOver(session comm.IUserSession, req *pb.EnchantCha
|
|||||||
},
|
},
|
||||||
}
|
}
|
||||||
info.Boss[req.BossType] = boos
|
info.Boss[req.BossType] = boos
|
||||||
|
//bNewRecord = true
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -155,7 +159,15 @@ func (this *apiComp) ChallengeOver(session comm.IUserSession, req *pb.EnchantCha
|
|||||||
}
|
}
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
this.module.modelRank.updateRank(req.Report.Score, session.GetUserId(), req.BossType)
|
|
||||||
|
//if bNewRecord { // 只有新记录才记录战报数据
|
||||||
|
go this.module.AsynHandleSession(session.Clone(), func(session comm.IUserSession) {
|
||||||
|
|
||||||
|
this.module.battlerecord.WrietBattleRecord(session.GetUserId(), req.Report, time.Now().Add(time.Hour*24*8))
|
||||||
|
this.module.modelRank.CheckRank(session.GetUserId(), req.BossType, req.Report)
|
||||||
|
})
|
||||||
|
//}
|
||||||
|
//this.module.modelRank.updateRank(req.Report.Score, session.GetUserId(), req.BossType)
|
||||||
session.SendMsg(string(this.module.GetType()), EnchantChallengeOverResp, &pb.EnchantChallengeOverResp{Data: info, Heroexp: changExp, Atno: atno})
|
session.SendMsg(string(this.module.GetType()), EnchantChallengeOverResp, &pb.EnchantChallengeOverResp{Data: info, Heroexp: changExp, Atno: atno})
|
||||||
go this.module.AsynHandleSession(session.Clone(), func(session comm.IUserSession) {
|
go this.module.AsynHandleSession(session.Clone(), func(session comm.IUserSession) {
|
||||||
this.module.WriteUserLog(session.GetUserId(), req, comm.GMResDelType, "EnchantChallengeOverReq", conf.PsConsume)
|
this.module.WriteUserLog(session.GetUserId(), req, comm.GMResDelType, "EnchantChallengeOverReq", conf.PsConsume)
|
||||||
|
@ -14,11 +14,10 @@ func (this *apiComp) RankListCheck(session comm.IUserSession, req *pb.EnchantRan
|
|||||||
func (this *apiComp) RankList(session comm.IUserSession, req *pb.EnchantRankListReq) (errdata *pb.ErrorData) {
|
func (this *apiComp) RankList(session comm.IUserSession, req *pb.EnchantRankListReq) (errdata *pb.ErrorData) {
|
||||||
var (
|
var (
|
||||||
uids []string
|
uids []string
|
||||||
ranks []*pb.DBEnchant
|
ranks []*pb.DBEnchantRecord
|
||||||
ranksmap map[string]*pb.DBEnchant
|
friends []*pb.DBEnchantRecord
|
||||||
franks []*pb.DBEnchant
|
ranksmap map[string]*pb.DBEnchantRank
|
||||||
players []*pb.DBEnchantRank
|
frank []*pb.DBEnchantRank
|
||||||
friends []*pb.DBEnchantRank
|
|
||||||
err error
|
err error
|
||||||
)
|
)
|
||||||
|
|
||||||
@ -34,7 +33,7 @@ func (this *apiComp) RankList(session comm.IUserSession, req *pb.EnchantRankList
|
|||||||
}
|
}
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
if ranks, err = this.module.modelEnchant.queryPlayers(uids); err != nil {
|
if ranks, err = this.module.modelRank.queryPlayers(uids); err != nil {
|
||||||
errdata = &pb.ErrorData{
|
errdata = &pb.ErrorData{
|
||||||
Code: pb.ErrorCode_DBError,
|
Code: pb.ErrorCode_DBError,
|
||||||
Title: pb.ErrorCode_DBError.ToString(),
|
Title: pb.ErrorCode_DBError.ToString(),
|
||||||
@ -42,27 +41,20 @@ func (this *apiComp) RankList(session comm.IUserSession, req *pb.EnchantRankList
|
|||||||
}
|
}
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
ranksmap = make(map[string]*pb.DBEnchant)
|
ranksmap = make(map[string]*pb.DBEnchantRank)
|
||||||
for _, v := range ranks {
|
for _, v := range ranks {
|
||||||
ranksmap[v.Uid] = v
|
ranksmap[v.Uid] = v.Data[req.BoosType]
|
||||||
}
|
}
|
||||||
players = make([]*pb.DBEnchantRank, 0, len(uids))
|
|
||||||
|
players := make([]*pb.DBEnchantRank, 0, len(uids))
|
||||||
for _, v := range uids {
|
for _, v := range uids {
|
||||||
if player, ok := ranksmap[v]; ok {
|
if player, ok := ranksmap[v]; ok {
|
||||||
players = append(players, &pb.DBEnchantRank{
|
players = append(players, player)
|
||||||
Id: player.Uid,
|
|
||||||
Uinfo: player.Uinfo,
|
|
||||||
Score: player.Boss[req.BoosType].Score,
|
|
||||||
Grade: player.Boss[req.BoosType].Grade,
|
|
||||||
Gradegroup: player.Boss[req.BoosType].Gradegroup,
|
|
||||||
Battletime: player.Boss[req.BoosType].Battletime,
|
|
||||||
Line: player.Boss[req.BoosType].Line,
|
|
||||||
})
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// 获取好友
|
// // 获取好友
|
||||||
fids := this.module.ModuleFriend.GetFriendList(session.GetUserId())
|
fids := this.module.ModuleFriend.GetFriendList(session.GetUserId())
|
||||||
if franks, err = this.module.modelEnchant.queryPlayers(fids); err != nil {
|
if friends, err = this.module.modelRank.queryPlayers(fids); err != nil {
|
||||||
errdata = &pb.ErrorData{
|
errdata = &pb.ErrorData{
|
||||||
Code: pb.ErrorCode_DBError,
|
Code: pb.ErrorCode_DBError,
|
||||||
Title: pb.ErrorCode_DBError.ToString(),
|
Title: pb.ErrorCode_DBError.ToString(),
|
||||||
@ -70,20 +62,14 @@ func (this *apiComp) RankList(session comm.IUserSession, req *pb.EnchantRankList
|
|||||||
}
|
}
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
friends = make([]*pb.DBEnchantRank, len(franks))
|
for _, v := range friends {
|
||||||
for i, v := range franks {
|
if v.Data != nil && v.Data[req.BoosType] != nil {
|
||||||
friends[i] = &pb.DBEnchantRank{
|
frank = append(frank, v.Data[req.BoosType])
|
||||||
Id: v.Uid,
|
|
||||||
Uinfo: v.Uinfo,
|
|
||||||
Score: v.Boss[req.BoosType].Score,
|
|
||||||
Grade: v.Boss[req.BoosType].Grade,
|
|
||||||
Gradegroup: v.Boss[req.BoosType].Gradegroup,
|
|
||||||
Line: v.Boss[req.BoosType].Line,
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
session.SendMsg(string(this.module.GetType()), "ranklist", &pb.EnchantRankListResp{
|
session.SendMsg(string(this.module.GetType()), "ranklist", &pb.EnchantRankListResp{
|
||||||
Ranks: players,
|
Ranks: players,
|
||||||
Friends: friends,
|
Friends: frank,
|
||||||
})
|
})
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
@ -47,15 +47,6 @@ func (this *modelEnchant) getEnchantList(uid string) (result *pb.DBEnchant, err
|
|||||||
return result, err
|
return result, err
|
||||||
}
|
}
|
||||||
|
|
||||||
func (this *modelEnchant) queryPlayers(uIds []string) (result []*pb.DBEnchant, err error) {
|
|
||||||
result = make([]*pb.DBEnchant, 0)
|
|
||||||
if _, err = this.GetByUids(uIds, &result); err != nil && err != mgo.MongodbNil {
|
|
||||||
this.module.Errorln(err)
|
|
||||||
return
|
|
||||||
}
|
|
||||||
return
|
|
||||||
}
|
|
||||||
|
|
||||||
// 红点检测
|
// 红点检测
|
||||||
func (this *modelEnchant) checkReddot33(session comm.IUserSession) bool {
|
func (this *modelEnchant) checkReddot33(session comm.IUserSession) bool {
|
||||||
if conf, err := this.module.configure.GetEnchantBossConfigData(1); err == nil {
|
if conf, err := this.module.configure.GetEnchantBossConfigData(1); err == nil {
|
||||||
|
@ -5,11 +5,15 @@ import (
|
|||||||
"fmt"
|
"fmt"
|
||||||
"go_dreamfactory/comm"
|
"go_dreamfactory/comm"
|
||||||
"go_dreamfactory/lego/core"
|
"go_dreamfactory/lego/core"
|
||||||
|
"go_dreamfactory/lego/sys/mgo"
|
||||||
"go_dreamfactory/lego/sys/redis/pipe"
|
"go_dreamfactory/lego/sys/redis/pipe"
|
||||||
"go_dreamfactory/modules"
|
"go_dreamfactory/modules"
|
||||||
"go_dreamfactory/pb"
|
"go_dreamfactory/pb"
|
||||||
|
"go_dreamfactory/sys/db"
|
||||||
|
"strconv"
|
||||||
|
|
||||||
"github.com/go-redis/redis/v8"
|
"github.com/go-redis/redis/v8"
|
||||||
|
"go.mongodb.org/mongo-driver/bson/primitive"
|
||||||
"go.mongodb.org/mongo-driver/mongo"
|
"go.mongodb.org/mongo-driver/mongo"
|
||||||
"go.mongodb.org/mongo-driver/x/bsonx"
|
"go.mongodb.org/mongo-driver/x/bsonx"
|
||||||
)
|
)
|
||||||
@ -47,7 +51,8 @@ func (this *ModelRank) queryRankUser(boos int32) (ranks []string, err error) {
|
|||||||
var (
|
var (
|
||||||
result []string
|
result []string
|
||||||
)
|
)
|
||||||
if result, err = this.DBModel.Redis.ZRevRange(this.rankKey(boos), 0, comm.MaxRankList).Result(); err != nil {
|
tableName := fmt.Sprintf("%s-%s", db.CrossTag(), this.TableName+strconv.Itoa(int(boos)))
|
||||||
|
if result, err = this.DBModel.Redis.ZRevRange(tableName, 0, comm.MaxRankList).Result(); err != nil {
|
||||||
this.module.Errorln(err)
|
this.module.Errorln(err)
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
@ -82,3 +87,129 @@ func (this *ModelRank) updateRank(Score int32, uid string, boos int32) (err erro
|
|||||||
|
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 记录数据存在跨服
|
||||||
|
func (this *ModelRank) CheckRank(uid string, boosID int32, report *pb.BattleReport) {
|
||||||
|
conn_, err := db.Cross() // 获取跨服数据库对象
|
||||||
|
if err != nil {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
user, err := this.module.ModuleUser.GetUser(uid)
|
||||||
|
if err != nil {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
model := db.NewDBModelNoExpired(db.CrossTag(), comm.TableEnchantRank, conn_)
|
||||||
|
|
||||||
|
// 写入排行榜
|
||||||
|
record := &pb.DBEnchantRecord{
|
||||||
|
Data: map[int32]*pb.DBEnchantRank{},
|
||||||
|
}
|
||||||
|
if err = model.Get(uid, record); err == mgo.MongodbNil {
|
||||||
|
record.Id = primitive.NewObjectID().Hex()
|
||||||
|
record.Uid = uid
|
||||||
|
szLine := make([]*pb.LineUp, 0)
|
||||||
|
var Leadpos int32
|
||||||
|
if report != nil && len(report.Info.Redflist) > 0 {
|
||||||
|
Leadpos = report.Info.Redflist[0].Leadpos
|
||||||
|
for _, v := range report.Info.Redflist[0].Team {
|
||||||
|
if v != nil {
|
||||||
|
szLine = append(szLine, &pb.LineUp{
|
||||||
|
Cid: v.HeroID,
|
||||||
|
Star: v.Star,
|
||||||
|
Lv: v.Lv,
|
||||||
|
})
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
record.Data[boosID] = &pb.DBEnchantRank{
|
||||||
|
Uinfo: &pb.BaseUserInfo{
|
||||||
|
Uid: uid,
|
||||||
|
Sid: user.Sid,
|
||||||
|
Name: user.Name,
|
||||||
|
Gender: user.Gender,
|
||||||
|
Skin: user.CurSkin,
|
||||||
|
Aframe: user.Curaframe,
|
||||||
|
Title: user.Curtitle,
|
||||||
|
Lv: user.Lv,
|
||||||
|
},
|
||||||
|
Line: &pb.LineData{
|
||||||
|
Leadpos: Leadpos,
|
||||||
|
Line: szLine,
|
||||||
|
Bid: report.Info.Id, // 战报id
|
||||||
|
},
|
||||||
|
Score: report.Score,
|
||||||
|
Grade: report.Grade,
|
||||||
|
Gradegroup: report.Info.Scoregroup,
|
||||||
|
Battletime: report.Costtime,
|
||||||
|
}
|
||||||
|
|
||||||
|
model.Add(uid, record)
|
||||||
|
} else if err == nil {
|
||||||
|
szLine := make([]*pb.LineUp, 0)
|
||||||
|
var Leadpos int32
|
||||||
|
if report != nil && len(report.Info.Redflist) > 0 {
|
||||||
|
Leadpos = report.Info.Redflist[0].Leadpos
|
||||||
|
for _, v := range report.Info.Redflist[0].Team {
|
||||||
|
if v != nil {
|
||||||
|
szLine = append(szLine, &pb.LineUp{
|
||||||
|
Cid: v.HeroID,
|
||||||
|
Star: v.Star,
|
||||||
|
Lv: v.Lv,
|
||||||
|
})
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
record.Data[boosID] = &pb.DBEnchantRank{
|
||||||
|
Uinfo: &pb.BaseUserInfo{
|
||||||
|
Uid: uid,
|
||||||
|
Sid: user.Sid,
|
||||||
|
Name: user.Name,
|
||||||
|
Gender: user.Gender,
|
||||||
|
Skin: user.CurSkin,
|
||||||
|
Aframe: user.Curaframe,
|
||||||
|
Title: user.Curtitle,
|
||||||
|
Lv: user.Lv,
|
||||||
|
},
|
||||||
|
Line: &pb.LineData{
|
||||||
|
Leadpos: Leadpos,
|
||||||
|
Line: szLine,
|
||||||
|
Bid: report.Info.Id, // 战报id
|
||||||
|
},
|
||||||
|
Score: report.Score,
|
||||||
|
Grade: report.Grade,
|
||||||
|
Gradegroup: report.Info.Scoregroup,
|
||||||
|
Battletime: report.Costtime,
|
||||||
|
}
|
||||||
|
|
||||||
|
update := make(map[string]interface{}, 0)
|
||||||
|
update["data"] = record.Data
|
||||||
|
model.Change(uid, update)
|
||||||
|
}
|
||||||
|
var (
|
||||||
|
pipe *pipe.RedisPipe = conn_.Redis.RedisPipe(context.TODO())
|
||||||
|
menbers *redis.Z
|
||||||
|
tableName string
|
||||||
|
score int32
|
||||||
|
)
|
||||||
|
score = report.Score
|
||||||
|
tableName = fmt.Sprintf("%s-%s", db.CrossTag(), this.TableName+strconv.Itoa(int(boosID)))
|
||||||
|
menbers = &redis.Z{Score: float64(score), Member: uid}
|
||||||
|
|
||||||
|
if cmd := pipe.ZAdd(tableName, menbers); cmd != nil {
|
||||||
|
if _, err = cmd.Result(); err != nil {
|
||||||
|
this.module.Errorln(err)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if _, err := pipe.Exec(); err != nil {
|
||||||
|
this.module.Errorln(err)
|
||||||
|
return
|
||||||
|
}
|
||||||
|
}
|
||||||
|
func (this *ModelRank) queryPlayers(uIds []string) (result []*pb.DBEnchantRecord, err error) {
|
||||||
|
result = make([]*pb.DBEnchantRecord, 0)
|
||||||
|
if _, err = this.GetByUids(uIds, &result); err != nil && err != mgo.MongodbNil {
|
||||||
|
this.module.Errorln(err)
|
||||||
|
return
|
||||||
|
}
|
||||||
|
return
|
||||||
|
}
|
||||||
|
@ -14,6 +14,7 @@ type Enchant struct {
|
|||||||
modelRank *ModelRank
|
modelRank *ModelRank
|
||||||
battle comm.IBattle
|
battle comm.IBattle
|
||||||
service core.IService
|
service core.IService
|
||||||
|
battlerecord comm.IBattleRecord // 战报模块
|
||||||
}
|
}
|
||||||
|
|
||||||
func NewModule() core.IModule {
|
func NewModule() core.IModule {
|
||||||
@ -42,6 +43,10 @@ func (this *Enchant) Start() (err error) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
this.battle = module.(comm.IBattle)
|
this.battle = module.(comm.IBattle)
|
||||||
|
if module, err = this.service.GetModule(comm.ModuleBattleRecord); err != nil {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
this.battlerecord = module.(comm.IBattleRecord)
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -170,6 +170,70 @@ func (x *DBEnchantBoos) GetBattletime() int32 {
|
|||||||
return 0
|
return 0
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 战斗数据
|
||||||
|
type DBEnchantRecord struct {
|
||||||
|
state protoimpl.MessageState
|
||||||
|
sizeCache protoimpl.SizeCache
|
||||||
|
unknownFields protoimpl.UnknownFields
|
||||||
|
|
||||||
|
Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id" bson:"_id"` //ID
|
||||||
|
Uid string `protobuf:"bytes,2,opt,name=uid,proto3" json:"uid" bson:"uid"` //用户ID
|
||||||
|
Data map[int32]*DBEnchantRank `protobuf:"bytes,3,rep,name=data,proto3" json:"data" protobuf_key:"varint,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` // key boss 类型
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *DBEnchantRecord) Reset() {
|
||||||
|
*x = DBEnchantRecord{}
|
||||||
|
if protoimpl.UnsafeEnabled {
|
||||||
|
mi := &file_enchant_enchant_db_proto_msgTypes[2]
|
||||||
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
|
ms.StoreMessageInfo(mi)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *DBEnchantRecord) String() string {
|
||||||
|
return protoimpl.X.MessageStringOf(x)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (*DBEnchantRecord) ProtoMessage() {}
|
||||||
|
|
||||||
|
func (x *DBEnchantRecord) ProtoReflect() protoreflect.Message {
|
||||||
|
mi := &file_enchant_enchant_db_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 DBEnchantRecord.ProtoReflect.Descriptor instead.
|
||||||
|
func (*DBEnchantRecord) Descriptor() ([]byte, []int) {
|
||||||
|
return file_enchant_enchant_db_proto_rawDescGZIP(), []int{2}
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *DBEnchantRecord) GetId() string {
|
||||||
|
if x != nil {
|
||||||
|
return x.Id
|
||||||
|
}
|
||||||
|
return ""
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *DBEnchantRecord) GetUid() string {
|
||||||
|
if x != nil {
|
||||||
|
return x.Uid
|
||||||
|
}
|
||||||
|
return ""
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *DBEnchantRecord) GetData() map[int32]*DBEnchantRank {
|
||||||
|
if x != nil {
|
||||||
|
return x.Data
|
||||||
|
}
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
||||||
// 排行榜
|
// 排行榜
|
||||||
type DBEnchantRank struct {
|
type DBEnchantRank struct {
|
||||||
state protoimpl.MessageState
|
state protoimpl.MessageState
|
||||||
@ -188,7 +252,7 @@ type DBEnchantRank struct {
|
|||||||
func (x *DBEnchantRank) Reset() {
|
func (x *DBEnchantRank) Reset() {
|
||||||
*x = DBEnchantRank{}
|
*x = DBEnchantRank{}
|
||||||
if protoimpl.UnsafeEnabled {
|
if protoimpl.UnsafeEnabled {
|
||||||
mi := &file_enchant_enchant_db_proto_msgTypes[2]
|
mi := &file_enchant_enchant_db_proto_msgTypes[3]
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
ms.StoreMessageInfo(mi)
|
ms.StoreMessageInfo(mi)
|
||||||
}
|
}
|
||||||
@ -201,7 +265,7 @@ func (x *DBEnchantRank) String() string {
|
|||||||
func (*DBEnchantRank) ProtoMessage() {}
|
func (*DBEnchantRank) ProtoMessage() {}
|
||||||
|
|
||||||
func (x *DBEnchantRank) ProtoReflect() protoreflect.Message {
|
func (x *DBEnchantRank) ProtoReflect() protoreflect.Message {
|
||||||
mi := &file_enchant_enchant_db_proto_msgTypes[2]
|
mi := &file_enchant_enchant_db_proto_msgTypes[3]
|
||||||
if protoimpl.UnsafeEnabled && x != nil {
|
if protoimpl.UnsafeEnabled && x != nil {
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
if ms.LoadMessageInfo() == nil {
|
if ms.LoadMessageInfo() == nil {
|
||||||
@ -214,7 +278,7 @@ func (x *DBEnchantRank) ProtoReflect() protoreflect.Message {
|
|||||||
|
|
||||||
// Deprecated: Use DBEnchantRank.ProtoReflect.Descriptor instead.
|
// Deprecated: Use DBEnchantRank.ProtoReflect.Descriptor instead.
|
||||||
func (*DBEnchantRank) Descriptor() ([]byte, []int) {
|
func (*DBEnchantRank) Descriptor() ([]byte, []int) {
|
||||||
return file_enchant_enchant_db_proto_rawDescGZIP(), []int{2}
|
return file_enchant_enchant_db_proto_rawDescGZIP(), []int{3}
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *DBEnchantRank) GetId() string {
|
func (x *DBEnchantRank) GetId() string {
|
||||||
@ -295,21 +359,32 @@ var file_enchant_enchant_db_proto_rawDesc = []byte{
|
|||||||
0x01, 0x28, 0x0b, 0x32, 0x09, 0x2e, 0x4c, 0x69, 0x6e, 0x65, 0x44, 0x61, 0x74, 0x61, 0x52, 0x04,
|
0x01, 0x28, 0x0b, 0x32, 0x09, 0x2e, 0x4c, 0x69, 0x6e, 0x65, 0x44, 0x61, 0x74, 0x61, 0x52, 0x04,
|
||||||
0x6c, 0x69, 0x6e, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x74, 0x69,
|
0x6c, 0x69, 0x6e, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x74, 0x69,
|
||||||
0x6d, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0a, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65,
|
0x6d, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0a, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65,
|
||||||
0x74, 0x69, 0x6d, 0x65, 0x22, 0xcf, 0x01, 0x0a, 0x0d, 0x44, 0x42, 0x45, 0x6e, 0x63, 0x68, 0x61,
|
0x74, 0x69, 0x6d, 0x65, 0x22, 0xac, 0x01, 0x0a, 0x0f, 0x44, 0x42, 0x45, 0x6e, 0x63, 0x68, 0x61,
|
||||||
0x6e, 0x74, 0x52, 0x61, 0x6e, 0x6b, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01,
|
0x6e, 0x74, 0x52, 0x65, 0x63, 0x6f, 0x72, 0x64, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01,
|
||||||
0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x23, 0x0a, 0x05, 0x75, 0x69, 0x6e, 0x66, 0x6f, 0x18,
|
0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x10, 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18,
|
||||||
0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0d, 0x2e, 0x42, 0x61, 0x73, 0x65, 0x55, 0x73, 0x65, 0x72,
|
0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x75, 0x69, 0x64, 0x12, 0x2e, 0x0a, 0x04, 0x64, 0x61,
|
||||||
0x49, 0x6e, 0x66, 0x6f, 0x52, 0x05, 0x75, 0x69, 0x6e, 0x66, 0x6f, 0x12, 0x1d, 0x0a, 0x04, 0x6c,
|
0x74, 0x61, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x44, 0x42, 0x45, 0x6e, 0x63,
|
||||||
0x69, 0x6e, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x09, 0x2e, 0x4c, 0x69, 0x6e, 0x65,
|
0x68, 0x61, 0x6e, 0x74, 0x52, 0x65, 0x63, 0x6f, 0x72, 0x64, 0x2e, 0x44, 0x61, 0x74, 0x61, 0x45,
|
||||||
0x44, 0x61, 0x74, 0x61, 0x52, 0x04, 0x6c, 0x69, 0x6e, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x73, 0x63,
|
0x6e, 0x74, 0x72, 0x79, 0x52, 0x04, 0x64, 0x61, 0x74, 0x61, 0x1a, 0x47, 0x0a, 0x09, 0x44, 0x61,
|
||||||
0x6f, 0x72, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x73, 0x63, 0x6f, 0x72, 0x65,
|
0x74, 0x61, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01,
|
||||||
0x12, 0x14, 0x0a, 0x05, 0x67, 0x72, 0x61, 0x64, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x05, 0x52,
|
0x20, 0x01, 0x28, 0x05, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x24, 0x0a, 0x05, 0x76, 0x61, 0x6c,
|
||||||
0x05, 0x67, 0x72, 0x61, 0x64, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x67, 0x72, 0x61, 0x64, 0x65, 0x67,
|
0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x44, 0x42, 0x45, 0x6e, 0x63,
|
||||||
0x72, 0x6f, 0x75, 0x70, 0x18, 0x06, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0a, 0x67, 0x72, 0x61, 0x64,
|
0x68, 0x61, 0x6e, 0x74, 0x52, 0x61, 0x6e, 0x6b, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a,
|
||||||
0x65, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x12, 0x1e, 0x0a, 0x0a, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65,
|
0x02, 0x38, 0x01, 0x22, 0xcf, 0x01, 0x0a, 0x0d, 0x44, 0x42, 0x45, 0x6e, 0x63, 0x68, 0x61, 0x6e,
|
||||||
0x74, 0x69, 0x6d, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0a, 0x62, 0x61, 0x74, 0x74,
|
0x74, 0x52, 0x61, 0x6e, 0x6b, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28,
|
||||||
0x6c, 0x65, 0x74, 0x69, 0x6d, 0x65, 0x42, 0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70, 0x62, 0x62, 0x06,
|
0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x23, 0x0a, 0x05, 0x75, 0x69, 0x6e, 0x66, 0x6f, 0x18, 0x02,
|
||||||
0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
|
0x20, 0x01, 0x28, 0x0b, 0x32, 0x0d, 0x2e, 0x42, 0x61, 0x73, 0x65, 0x55, 0x73, 0x65, 0x72, 0x49,
|
||||||
|
0x6e, 0x66, 0x6f, 0x52, 0x05, 0x75, 0x69, 0x6e, 0x66, 0x6f, 0x12, 0x1d, 0x0a, 0x04, 0x6c, 0x69,
|
||||||
|
0x6e, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x09, 0x2e, 0x4c, 0x69, 0x6e, 0x65, 0x44,
|
||||||
|
0x61, 0x74, 0x61, 0x52, 0x04, 0x6c, 0x69, 0x6e, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x73, 0x63, 0x6f,
|
||||||
|
0x72, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x73, 0x63, 0x6f, 0x72, 0x65, 0x12,
|
||||||
|
0x14, 0x0a, 0x05, 0x67, 0x72, 0x61, 0x64, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05,
|
||||||
|
0x67, 0x72, 0x61, 0x64, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x67, 0x72, 0x61, 0x64, 0x65, 0x67, 0x72,
|
||||||
|
0x6f, 0x75, 0x70, 0x18, 0x06, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0a, 0x67, 0x72, 0x61, 0x64, 0x65,
|
||||||
|
0x67, 0x72, 0x6f, 0x75, 0x70, 0x12, 0x1e, 0x0a, 0x0a, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x74,
|
||||||
|
0x69, 0x6d, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0a, 0x62, 0x61, 0x74, 0x74, 0x6c,
|
||||||
|
0x65, 0x74, 0x69, 0x6d, 0x65, 0x42, 0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70, 0x62, 0x62, 0x06, 0x70,
|
||||||
|
0x72, 0x6f, 0x74, 0x6f, 0x33,
|
||||||
}
|
}
|
||||||
|
|
||||||
var (
|
var (
|
||||||
@ -324,27 +399,31 @@ func file_enchant_enchant_db_proto_rawDescGZIP() []byte {
|
|||||||
return file_enchant_enchant_db_proto_rawDescData
|
return file_enchant_enchant_db_proto_rawDescData
|
||||||
}
|
}
|
||||||
|
|
||||||
var file_enchant_enchant_db_proto_msgTypes = make([]protoimpl.MessageInfo, 4)
|
var file_enchant_enchant_db_proto_msgTypes = make([]protoimpl.MessageInfo, 6)
|
||||||
var file_enchant_enchant_db_proto_goTypes = []interface{}{
|
var file_enchant_enchant_db_proto_goTypes = []interface{}{
|
||||||
(*DBEnchant)(nil), // 0: DBEnchant
|
(*DBEnchant)(nil), // 0: DBEnchant
|
||||||
(*DBEnchantBoos)(nil), // 1: DBEnchantBoos
|
(*DBEnchantBoos)(nil), // 1: DBEnchantBoos
|
||||||
(*DBEnchantRank)(nil), // 2: DBEnchantRank
|
(*DBEnchantRecord)(nil), // 2: DBEnchantRecord
|
||||||
nil, // 3: DBEnchant.BossEntry
|
(*DBEnchantRank)(nil), // 3: DBEnchantRank
|
||||||
(*BaseUserInfo)(nil), // 4: BaseUserInfo
|
nil, // 4: DBEnchant.BossEntry
|
||||||
(*LineData)(nil), // 5: LineData
|
nil, // 5: DBEnchantRecord.DataEntry
|
||||||
|
(*BaseUserInfo)(nil), // 6: BaseUserInfo
|
||||||
|
(*LineData)(nil), // 7: LineData
|
||||||
}
|
}
|
||||||
var file_enchant_enchant_db_proto_depIdxs = []int32{
|
var file_enchant_enchant_db_proto_depIdxs = []int32{
|
||||||
4, // 0: DBEnchant.uinfo:type_name -> BaseUserInfo
|
6, // 0: DBEnchant.uinfo:type_name -> BaseUserInfo
|
||||||
3, // 1: DBEnchant.boss:type_name -> DBEnchant.BossEntry
|
4, // 1: DBEnchant.boss:type_name -> DBEnchant.BossEntry
|
||||||
5, // 2: DBEnchantBoos.line:type_name -> LineData
|
7, // 2: DBEnchantBoos.line:type_name -> LineData
|
||||||
4, // 3: DBEnchantRank.uinfo:type_name -> BaseUserInfo
|
5, // 3: DBEnchantRecord.data:type_name -> DBEnchantRecord.DataEntry
|
||||||
5, // 4: DBEnchantRank.line:type_name -> LineData
|
6, // 4: DBEnchantRank.uinfo:type_name -> BaseUserInfo
|
||||||
1, // 5: DBEnchant.BossEntry.value:type_name -> DBEnchantBoos
|
7, // 5: DBEnchantRank.line:type_name -> LineData
|
||||||
6, // [6:6] is the sub-list for method output_type
|
1, // 6: DBEnchant.BossEntry.value:type_name -> DBEnchantBoos
|
||||||
6, // [6:6] is the sub-list for method input_type
|
3, // 7: DBEnchantRecord.DataEntry.value:type_name -> DBEnchantRank
|
||||||
6, // [6:6] is the sub-list for extension type_name
|
8, // [8:8] is the sub-list for method output_type
|
||||||
6, // [6:6] is the sub-list for extension extendee
|
8, // [8:8] is the sub-list for method input_type
|
||||||
0, // [0:6] is the sub-list for field type_name
|
8, // [8:8] is the sub-list for extension type_name
|
||||||
|
8, // [8:8] is the sub-list for extension extendee
|
||||||
|
0, // [0:8] is the sub-list for field type_name
|
||||||
}
|
}
|
||||||
|
|
||||||
func init() { file_enchant_enchant_db_proto_init() }
|
func init() { file_enchant_enchant_db_proto_init() }
|
||||||
@ -380,6 +459,18 @@ func file_enchant_enchant_db_proto_init() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
file_enchant_enchant_db_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} {
|
file_enchant_enchant_db_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} {
|
||||||
|
switch v := v.(*DBEnchantRecord); i {
|
||||||
|
case 0:
|
||||||
|
return &v.state
|
||||||
|
case 1:
|
||||||
|
return &v.sizeCache
|
||||||
|
case 2:
|
||||||
|
return &v.unknownFields
|
||||||
|
default:
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
}
|
||||||
|
file_enchant_enchant_db_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} {
|
||||||
switch v := v.(*DBEnchantRank); i {
|
switch v := v.(*DBEnchantRank); i {
|
||||||
case 0:
|
case 0:
|
||||||
return &v.state
|
return &v.state
|
||||||
@ -398,7 +489,7 @@ func file_enchant_enchant_db_proto_init() {
|
|||||||
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
||||||
RawDescriptor: file_enchant_enchant_db_proto_rawDesc,
|
RawDescriptor: file_enchant_enchant_db_proto_rawDesc,
|
||||||
NumEnums: 0,
|
NumEnums: 0,
|
||||||
NumMessages: 4,
|
NumMessages: 6,
|
||||||
NumExtensions: 0,
|
NumExtensions: 0,
|
||||||
NumServices: 0,
|
NumServices: 0,
|
||||||
},
|
},
|
||||||
|
Loading…
Reference in New Issue
Block a user