Merge branch 'dev' of http://git.legu.cc/liwei_3d/go_dreamfactory into dev
This commit is contained in:
commit
f797754263
@ -40,7 +40,7 @@ func (this *ModelDragon) CreateDragon(session comm.IUserSession, dragons map[str
|
|||||||
)
|
)
|
||||||
dragonList := make([]*pb.DBDragon, 0)
|
dragonList := make([]*pb.DBDragon, 0)
|
||||||
uid := session.GetUserId()
|
uid := session.GetUserId()
|
||||||
if this.module.IsCross() {
|
if db.IsCross() {
|
||||||
if dbModel, err = this.module.GetDBModelByUid(uid, this.TableName); err != nil {
|
if dbModel, err = this.module.GetDBModelByUid(uid, this.TableName); err != nil {
|
||||||
errdata = &pb.ErrorData{
|
errdata = &pb.ErrorData{
|
||||||
Code: pb.ErrorCode_DBError,
|
Code: pb.ErrorCode_DBError,
|
||||||
@ -161,7 +161,7 @@ func (this *ModelDragon) CreateDragon(session comm.IUserSession, dragons map[str
|
|||||||
// 获取坐骑列表
|
// 获取坐骑列表
|
||||||
func (this *ModelDragon) GetDragonList(uid string) (dragon []*pb.DBDragon, err error) {
|
func (this *ModelDragon) GetDragonList(uid string) (dragon []*pb.DBDragon, err error) {
|
||||||
dragon = make([]*pb.DBDragon, 0)
|
dragon = make([]*pb.DBDragon, 0)
|
||||||
if this.module.IsCross() {
|
if db.IsCross() {
|
||||||
if dbModel, err1 := this.module.GetDBModelByUid(uid, this.TableName); err1 == nil {
|
if dbModel, err1 := this.module.GetDBModelByUid(uid, this.TableName); err1 == nil {
|
||||||
if err = dbModel.GetList(uid, &dragon); err != nil {
|
if err = dbModel.GetList(uid, &dragon); err != nil {
|
||||||
this.module.Errorf("err:%v", err)
|
this.module.Errorf("err:%v", err)
|
||||||
@ -180,7 +180,7 @@ func (this *ModelDragon) GetDragonList(uid string) (dragon []*pb.DBDragon, err e
|
|||||||
}
|
}
|
||||||
|
|
||||||
func (this *ModelDragon) UpdateDragonData(uid string, oid string, data map[string]interface{}) (err error) {
|
func (this *ModelDragon) UpdateDragonData(uid string, oid string, data map[string]interface{}) (err error) {
|
||||||
if this.module.IsCross() {
|
if db.IsCross() {
|
||||||
if dbModel, err1 := this.module.GetDBModelByUid(uid, this.TableName); err1 == nil {
|
if dbModel, err1 := this.module.GetDBModelByUid(uid, this.TableName); err1 == nil {
|
||||||
if err = dbModel.ChangeList(uid, oid, data); err != nil {
|
if err = dbModel.ChangeList(uid, oid, data); err != nil {
|
||||||
this.module.Errorf("err:%v", err)
|
this.module.Errorf("err:%v", err)
|
||||||
|
@ -5,6 +5,7 @@ import (
|
|||||||
"go_dreamfactory/pb"
|
"go_dreamfactory/pb"
|
||||||
"go_dreamfactory/sys/configure"
|
"go_dreamfactory/sys/configure"
|
||||||
"go_dreamfactory/utils"
|
"go_dreamfactory/utils"
|
||||||
|
"time"
|
||||||
)
|
)
|
||||||
|
|
||||||
//参数校验
|
//参数校验
|
||||||
@ -48,6 +49,13 @@ func (this *apiComp) GetList(session comm.IUserSession, req *pb.EntertainGetList
|
|||||||
list.Etime = endSeasonTime
|
list.Etime = endSeasonTime
|
||||||
update["etime"] = list.Etime
|
update["etime"] = list.Etime
|
||||||
this.module.ModuleUser.CleanUserMerchantmoney(session)
|
this.module.ModuleUser.CleanUserMerchantmoney(session)
|
||||||
|
curMonth := time.Now().Month() // 计算赛季
|
||||||
|
curYear := time.Now().Year()
|
||||||
|
preMonth := this.module.service.GetOpentime().Month()
|
||||||
|
preYear := this.module.service.GetOpentime().Year()
|
||||||
|
tmp := int(curYear-preYear)*12 + int(curMonth-preMonth)
|
||||||
|
list.Rounds = int32(tmp)
|
||||||
|
update["rounds"] = list.Rounds
|
||||||
}
|
}
|
||||||
this.module.model.modifyEntertainmList(session.GetUserId(), update)
|
this.module.model.modifyEntertainmList(session.GetUserId(), update)
|
||||||
}
|
}
|
||||||
|
@ -8,6 +8,7 @@ import (
|
|||||||
"go_dreamfactory/pb"
|
"go_dreamfactory/pb"
|
||||||
"go_dreamfactory/sys/configure"
|
"go_dreamfactory/sys/configure"
|
||||||
"go_dreamfactory/utils"
|
"go_dreamfactory/utils"
|
||||||
|
"time"
|
||||||
|
|
||||||
"go.mongodb.org/mongo-driver/bson/primitive"
|
"go.mongodb.org/mongo-driver/bson/primitive"
|
||||||
"go.mongodb.org/mongo-driver/mongo"
|
"go.mongodb.org/mongo-driver/mongo"
|
||||||
@ -55,6 +56,12 @@ func (this *modelComp) getEntertainmList(uid string) (result *pb.DBXXLData, err
|
|||||||
endSeasonTime := utils.GetMonthEnd(configure.Now().Unix())
|
endSeasonTime := utils.GetMonthEnd(configure.Now().Unix())
|
||||||
result.Etime = endSeasonTime
|
result.Etime = endSeasonTime
|
||||||
|
|
||||||
|
curMonth := time.Now().Month() // 计算赛季
|
||||||
|
curYear := time.Now().Year()
|
||||||
|
preMonth := this.module.service.GetOpentime().Month()
|
||||||
|
preYear := this.module.service.GetOpentime().Year()
|
||||||
|
tmp := int(curYear-preYear)*12 + int(curMonth-preMonth)
|
||||||
|
result.Rounds = int32(tmp)
|
||||||
// 初始化默认获得类型为1的卡片
|
// 初始化默认获得类型为1的卡片
|
||||||
for _, v := range this.module.configure.GetInitGameConsumeHero() {
|
for _, v := range this.module.configure.GetInitGameConsumeHero() {
|
||||||
result.Card[v] = 1
|
result.Card[v] = 1
|
||||||
|
@ -80,9 +80,9 @@ func (this *MapData) CreateGride(count int) (girdes []*pb.GirdeData) {
|
|||||||
func (this *MapData) SetMap() {
|
func (this *MapData) SetMap() {
|
||||||
sz2 := []int32{
|
sz2 := []int32{
|
||||||
3, 1, 2, 2, 1, 3, 1,
|
3, 1, 2, 2, 1, 3, 1,
|
||||||
5, 1, 2, 3, 1, 2, 2,
|
5, 1, 2, 4, 1, 2, 2,
|
||||||
2, 4, 3, 4, 3, 1, 6,
|
2, 4, 3, 4, 3, 1, 6,
|
||||||
1, 3, 3, 4, 2, 3, 6,
|
1, 3, 4, 4, 4, 3, 6,
|
||||||
1, 5, 2, 5, 6, 1, 4,
|
1, 5, 2, 5, 6, 1, 4,
|
||||||
6, 6, 3, 26, 3, 1, 3,
|
6, 6, 3, 26, 3, 1, 3,
|
||||||
3, 3, 1, 3, 3, 2, 5,
|
3, 3, 1, 3, 3, 2, 5,
|
||||||
@ -1385,17 +1385,89 @@ func (this *MapData) HitCrossElem(color int32, curid int32) (szMap []*pb.MapData
|
|||||||
}
|
}
|
||||||
|
|
||||||
// 检测一个元素
|
// 检测一个元素
|
||||||
func (this *MapData) CheckElem(pos int32) {
|
func (this *MapData) CheckElem(pos int) (xc []int) {
|
||||||
var (
|
var (
|
||||||
color int32
|
color int32
|
||||||
x int32
|
x int
|
||||||
y int32
|
y int
|
||||||
|
tmp []int
|
||||||
)
|
)
|
||||||
color = this.Plat[pos].Color
|
color = this.Plat[pos].Color
|
||||||
x = pos / Width
|
x = pos / Width
|
||||||
y = pos % Height
|
y = pos % Height
|
||||||
this.module.Debugf("color:%d, x:%d, y:%d", color, x, y)
|
this.module.Debugf("color:%d, x:%d, y:%d", color, x, y)
|
||||||
for i := 0; i < Height; i++ {
|
|
||||||
|
|
||||||
|
for i := 1; i < Height; i++ {
|
||||||
|
if y+i < Height {
|
||||||
|
tagPos := x*Width + (y + i)
|
||||||
|
tagColor := this.Plat[tagPos].Color
|
||||||
|
if tagColor == color {
|
||||||
|
tmp = append(tmp, tagPos)
|
||||||
|
} else {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
break
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if len(tmp) >= 2 {
|
||||||
|
xc = append(xc, tmp...)
|
||||||
|
}
|
||||||
|
tmp = []int{}
|
||||||
|
for i := 1; i < Height; i++ {
|
||||||
|
if y-i >= 0 {
|
||||||
|
tagPos := x*Width + (y - i)
|
||||||
|
tagColor := this.Plat[tagPos].Color
|
||||||
|
if tagColor == color {
|
||||||
|
tmp = append(tmp, tagPos)
|
||||||
|
} else {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if len(tmp) >= 2 {
|
||||||
|
xc = append(xc, tmp...)
|
||||||
|
}
|
||||||
|
tmp = []int{}
|
||||||
|
for i := 1; i < Width; i++ {
|
||||||
|
if x-i >= 0 {
|
||||||
|
tagPos := (x-i)*Width + (y)
|
||||||
|
tagColor := this.Plat[tagPos].Color
|
||||||
|
if tagColor == color {
|
||||||
|
tmp = append(tmp, tagPos)
|
||||||
|
} else {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if len(tmp) >= 2 {
|
||||||
|
xc = append(xc, tmp...)
|
||||||
|
}
|
||||||
|
tmp = []int{}
|
||||||
|
for i := 1; i < Width; i++ {
|
||||||
|
if x+i < Width {
|
||||||
|
tagPos := (x+i)*Width + (y)
|
||||||
|
tagColor := this.Plat[tagPos].Color
|
||||||
|
if tagColor == color {
|
||||||
|
tmp = append(tmp, tagPos)
|
||||||
|
} else {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if len(tmp) >= 2 {
|
||||||
|
xc = append(xc, tmp...)
|
||||||
|
}
|
||||||
|
|
||||||
|
if len(xc) > 0 {
|
||||||
|
xc = append(xc, pos)
|
||||||
|
}
|
||||||
|
return
|
||||||
}
|
}
|
||||||
|
@ -27,8 +27,10 @@ func (this *apiComp) RefreshAssistHero(session comm.IUserSession, req *pb.Friend
|
|||||||
heros []*pb.DBHero
|
heros []*pb.DBHero
|
||||||
uids []string
|
uids []string
|
||||||
names []string
|
names []string
|
||||||
|
sz []int32
|
||||||
//aherofr []*pb.DBHero // 好友的助战列表
|
//aherofr []*pb.DBHero // 好友的助战列表
|
||||||
)
|
)
|
||||||
|
strangerCount = comm.AssistHeroCount // 默认一个界面12条
|
||||||
list, err = this.module.modelAssist.getAssist(session.GetUserId())
|
list, err = this.module.modelAssist.getAssist(session.GetUserId())
|
||||||
if err != nil {
|
if err != nil {
|
||||||
errdata = &pb.ErrorData{
|
errdata = &pb.ErrorData{
|
||||||
@ -47,48 +49,50 @@ func (this *apiComp) RefreshAssistHero(session comm.IUserSession, req *pb.Friend
|
|||||||
}
|
}
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
if friends, err = this.module.modelFriend.GetFriends(self.FriendIds); err != nil {
|
if friends, err = this.module.modelFriend.GetFriends(self.FriendIds); err == nil {
|
||||||
|
|
||||||
for _, v := range friends {
|
for _, v := range friends {
|
||||||
if v.AssistHeroId != "" {
|
if v.AssistHeroId != "" && session.GetUserId() != v.Uid {
|
||||||
names = append(names, v.Info.Name)
|
names = append(names, v.Info.Name)
|
||||||
uids = append(uids, v.Uid)
|
uids = append(uids, v.Uid)
|
||||||
heros = append(heros, v.Hero)
|
heros = append(heros, v.Hero)
|
||||||
|
sz = append(sz, 1)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
list.Data = make(map[string]string)
|
||||||
|
if int32(len(sz)) > strangerCount {
|
||||||
|
szData := comm.GetRandWs(sz, strangerCount)
|
||||||
|
for _, v := range szData {
|
||||||
|
ahero = append(ahero, heros[v])
|
||||||
|
list.Data[uids[v]] = names[v]
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
if len(sz) > 0 {
|
||||||
|
szData := comm.GetRandWs(sz, int32(len(sz)/2+1))
|
||||||
|
for _, v := range szData {
|
||||||
|
ahero = append(ahero, heros[v])
|
||||||
|
list.Data[uids[v]] = names[v]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
if list.RefreshNum >= this.module.ModuleTools.GetGlobalConf().FriendHelpHeroRefreshNum {
|
if list.RefreshNum >= this.module.ModuleTools.GetGlobalConf().FriendHelpHeroRefreshNum {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
list.RefreshNum++
|
list.RefreshNum++
|
||||||
strangerCount = comm.AssistHeroCount // 默认一个界面12条
|
|
||||||
if int32(len(uids)) > list.RefreshNum*comm.AssistHeroCount {
|
|
||||||
strangerCount = int32(len(uids)) - list.RefreshNum*comm.AssistHeroCount
|
|
||||||
if strangerCount > comm.AssistHeroCount {
|
|
||||||
strangerCount = comm.AssistHeroCount
|
|
||||||
}
|
|
||||||
heros = append(heros[list.RefreshNum*comm.AssistHeroCount : list.RefreshNum*comm.AssistHeroCount+strangerCount])
|
|
||||||
names = append(names[list.RefreshNum*comm.AssistHeroCount : list.RefreshNum*comm.AssistHeroCount+strangerCount])
|
|
||||||
uids = append(uids[list.RefreshNum*comm.AssistHeroCount : list.RefreshNum*comm.AssistHeroCount+strangerCount])
|
|
||||||
} else {
|
|
||||||
heros = []*pb.DBHero{}
|
|
||||||
names = []string{}
|
|
||||||
uids = []string{}
|
|
||||||
}
|
|
||||||
for pos, key := range uids {
|
|
||||||
list.Data[key] = names[pos]
|
|
||||||
ahero = append(ahero, heros[pos])
|
|
||||||
}
|
|
||||||
list.Data = make(map[string]string)
|
|
||||||
//localNum, _ := this.module.modelFriend.DB.CountDocuments(core.SqlTable(this.module.modelFriend.TableName), bson.M{})
|
|
||||||
//randomIndex := comm.GetRandNum(0, int32(localNum))
|
|
||||||
cur, err := this.module.modelFriend.DB.Find(core.SqlTable(this.module.modelFriend.TableName), bson.M{"assistHeroId": bson.M{"$ne": ""}}, options.Find().SetSkip(0).SetLimit(int64(strangerCount)))
|
cur, err := this.module.modelFriend.DB.Find(core.SqlTable(this.module.modelFriend.TableName), bson.M{"assistHeroId": bson.M{"$ne": ""}}, options.Find().SetSkip(0).SetLimit(int64(strangerCount)))
|
||||||
for cur.Next(context.TODO()) {
|
for cur.Next(context.TODO()) {
|
||||||
tmp := &pb.DBFriend{}
|
tmp := &pb.DBFriend{}
|
||||||
if err = cur.Decode(tmp); err == nil {
|
if err = cur.Decode(tmp); err == nil {
|
||||||
if session.GetUserId() != tmp.Uid {
|
if session.GetUserId() != tmp.Uid {
|
||||||
|
if int32(len(list.Data)) >= strangerCount {
|
||||||
|
break
|
||||||
|
}
|
||||||
ahero = append(ahero, tmp.Hero)
|
ahero = append(ahero, tmp.Hero)
|
||||||
list.Data[tmp.Uid] = tmp.Info.Name
|
list.Data[tmp.Uid] = tmp.Info.Name
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -2,6 +2,7 @@ package hunting
|
|||||||
|
|
||||||
import (
|
import (
|
||||||
"context"
|
"context"
|
||||||
|
"fmt"
|
||||||
"go_dreamfactory/comm"
|
"go_dreamfactory/comm"
|
||||||
"go_dreamfactory/lego/core"
|
"go_dreamfactory/lego/core"
|
||||||
"go_dreamfactory/lego/sys/mgo"
|
"go_dreamfactory/lego/sys/mgo"
|
||||||
@ -54,10 +55,10 @@ func (this *ModelRank) getHuntingRank(uid string) *pb.DBHuntingRecord {
|
|||||||
// 获取排行榜前50的用户名单
|
// 获取排行榜前50的用户名单
|
||||||
func (this *ModelRank) querySRankUser(bossid int) (ranks []string, err error) {
|
func (this *ModelRank) querySRankUser(bossid int) (ranks []string, err error) {
|
||||||
var (
|
var (
|
||||||
result []string
|
result []string
|
||||||
|
tableName string
|
||||||
)
|
)
|
||||||
|
tableName = fmt.Sprintf("%s-%s", db.CrossTag(), this.TableName+strconv.Itoa(int(bossid)))
|
||||||
tableName := this.TableName + strconv.Itoa(int(bossid))
|
|
||||||
if result, err = this.Redis.ZRevRange(tableName, 0, comm.MinRankList).Result(); err != nil {
|
if result, err = this.Redis.ZRevRange(tableName, 0, comm.MinRankList).Result(); err != nil {
|
||||||
//this.module.Errorln(err)
|
//this.module.Errorln(err)
|
||||||
return
|
return
|
||||||
@ -172,7 +173,7 @@ func (this *ModelRank) CheckRank(uid string, boosID int32, difficulty int32, lin
|
|||||||
score int32
|
score int32
|
||||||
)
|
)
|
||||||
score = difficulty*10000 + (10000 - costTime)
|
score = difficulty*10000 + (10000 - costTime)
|
||||||
tableName = this.TableName + strconv.Itoa(int(boosID))
|
tableName = fmt.Sprintf("%s-%s", db.CrossTag(), this.TableName+strconv.Itoa(int(boosID)))
|
||||||
menbers = &redis.Z{Score: float64(score), Member: uid}
|
menbers = &redis.Z{Score: float64(score), Member: uid}
|
||||||
|
|
||||||
if cmd := pipe.ZAdd(tableName, menbers); cmd != nil {
|
if cmd := pipe.ZAdd(tableName, menbers); cmd != nil {
|
||||||
|
@ -7,6 +7,7 @@ import (
|
|||||||
"go_dreamfactory/lego/core"
|
"go_dreamfactory/lego/core"
|
||||||
"go_dreamfactory/lego/sys/redis/pipe"
|
"go_dreamfactory/lego/sys/redis/pipe"
|
||||||
"go_dreamfactory/modules"
|
"go_dreamfactory/modules"
|
||||||
|
"go_dreamfactory/sys/db"
|
||||||
"strconv"
|
"strconv"
|
||||||
|
|
||||||
"github.com/go-redis/redis/v8"
|
"github.com/go-redis/redis/v8"
|
||||||
@ -29,14 +30,15 @@ func (this *modelRank) Init(service core.IService, module core.IModule, comp cor
|
|||||||
// 更新排名
|
// 更新排名
|
||||||
func (this *modelRank) updateRank(Score int32, uid string, nandu int) (err error) {
|
func (this *modelRank) updateRank(Score int32, uid string, nandu int) (err error) {
|
||||||
var (
|
var (
|
||||||
pipe *pipe.RedisPipe = this.DBModel.Redis.RedisPipe(context.TODO())
|
pipe *pipe.RedisPipe = this.DBModel.Redis.RedisPipe(context.TODO())
|
||||||
menbers *redis.Z
|
menbers *redis.Z
|
||||||
cmd *redis.IntCmd
|
cmd *redis.IntCmd
|
||||||
|
tableName string
|
||||||
)
|
)
|
||||||
|
|
||||||
menbers = &redis.Z{Score: float64(Score), Member: uid}
|
menbers = &redis.Z{Score: float64(Score), Member: uid}
|
||||||
|
tableName = fmt.Sprintf("%s-%s", db.CrossTag(), this.TableName+strconv.Itoa(int(nandu)))
|
||||||
if cmd = pipe.ZAdd(this.TableName+strconv.Itoa(nandu), menbers); err != nil {
|
if cmd = pipe.ZAdd(tableName, menbers); err != nil {
|
||||||
this.module.Errorln(err)
|
this.module.Errorln(err)
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -55,9 +57,11 @@ func (this *modelRank) updateRank(Score int32, uid string, nandu int) (err error
|
|||||||
// 获取排行榜前50的用户名单
|
// 获取排行榜前50的用户名单
|
||||||
func (this *modelRank) queryIntegralRankUser(nandu int) (ranks []string, err error) {
|
func (this *modelRank) queryIntegralRankUser(nandu int) (ranks []string, err error) {
|
||||||
var (
|
var (
|
||||||
result []string
|
result []string
|
||||||
|
tableName string
|
||||||
)
|
)
|
||||||
if result, err = this.DBModel.Redis.ZRevRange(fmt.Sprintf("%s-%s", this.DBModel.ServiceId, this.TableName+strconv.Itoa(nandu)), 0, 50).Result(); err != nil {
|
tableName = fmt.Sprintf("%s-%s", db.CrossTag(), this.TableName+strconv.Itoa(int(nandu)))
|
||||||
|
if result, err = this.DBModel.Redis.ZRevRange(tableName, 0, comm.MaxRankList).Result(); err != nil {
|
||||||
this.module.Errorln(err)
|
this.module.Errorln(err)
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
@ -119,10 +119,12 @@ func (this *apiComp) Login(session comm.IUserSession, req *pb.UserLoginReq) (err
|
|||||||
update["globalbuff"] = 0
|
update["globalbuff"] = 0
|
||||||
update["consumPs"] = 0
|
update["consumPs"] = 0
|
||||||
update["loginContinueCount"] = expand.LoginContinueCount + 1
|
update["loginContinueCount"] = expand.LoginContinueCount + 1
|
||||||
this.module.modelExpand.Change(user.Uid, update)
|
//this.module.modelExpand.Change(user.Uid, update)
|
||||||
|
this.module.modelExpand.ChangeUserExpand(user.Uid, update)
|
||||||
firstLogin = true
|
firstLogin = true
|
||||||
}
|
}
|
||||||
err = this.module.modelUser.Change(user.Uid, update)
|
err = this.module.modelUser.Change(user.Uid, update)
|
||||||
|
err = this.module.modelUser.updateUserAttr(user.Uid, update)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
errdata = &pb.ErrorData{
|
errdata = &pb.ErrorData{
|
||||||
Code: pb.ErrorCode_DBError,
|
Code: pb.ErrorCode_DBError,
|
||||||
|
@ -2,6 +2,7 @@ package viking
|
|||||||
|
|
||||||
import (
|
import (
|
||||||
"context"
|
"context"
|
||||||
|
"fmt"
|
||||||
"go_dreamfactory/comm"
|
"go_dreamfactory/comm"
|
||||||
"go_dreamfactory/lego/core"
|
"go_dreamfactory/lego/core"
|
||||||
"go_dreamfactory/lego/sys/mgo"
|
"go_dreamfactory/lego/sys/mgo"
|
||||||
@ -56,8 +57,8 @@ func (this *ModelRank) querySRankUser(bossid int) (ranks []string, err error) {
|
|||||||
var (
|
var (
|
||||||
result []string
|
result []string
|
||||||
)
|
)
|
||||||
|
tableName := fmt.Sprintf("%s-%s", db.CrossTag(), this.TableName+strconv.Itoa(int(bossid)))
|
||||||
tableName := this.TableName + strconv.Itoa(int(bossid))
|
//tableName := this.TableName + strconv.Itoa(int(bossid))
|
||||||
if result, err = this.Redis.ZRevRange(tableName, 0, comm.MinRankList).Result(); err != nil {
|
if result, err = this.Redis.ZRevRange(tableName, 0, comm.MinRankList).Result(); err != nil {
|
||||||
//this.module.Errorln(err)
|
//this.module.Errorln(err)
|
||||||
return
|
return
|
||||||
@ -172,7 +173,7 @@ func (this *ModelRank) CheckRank(uid string, boosID int32, difficulty int32, lin
|
|||||||
score int32
|
score int32
|
||||||
)
|
)
|
||||||
score = difficulty*10000 + (10000 - costTime)
|
score = difficulty*10000 + (10000 - costTime)
|
||||||
tableName = this.TableName + strconv.Itoa(int(boosID))
|
tableName = fmt.Sprintf("%s-%s", db.CrossTag(), this.TableName+strconv.Itoa(int(boosID)))
|
||||||
menbers = &redis.Z{Score: float64(score), Member: uid}
|
menbers = &redis.Z{Score: float64(score), Member: uid}
|
||||||
|
|
||||||
if cmd := pipe.ZAdd(tableName, menbers); cmd != nil {
|
if cmd := pipe.ZAdd(tableName, menbers); cmd != nil {
|
||||||
|
@ -206,7 +206,8 @@ func (this *ModelSRank) CheckSeasonRank(uid string, boosID int32, difficulty int
|
|||||||
score int32
|
score int32
|
||||||
)
|
)
|
||||||
score = difficulty*10000 + (10000 - huihe)
|
score = difficulty*10000 + (10000 - huihe)
|
||||||
tableName = this.TableName + strconv.Itoa(int(boosID))
|
//tableName = this.TableName + strconv.Itoa(int(boosID))
|
||||||
|
tableName = fmt.Sprintf("%s-%s", db.CrossTag(), this.TableName+strconv.Itoa(int(boosID)))
|
||||||
menbers = &redis.Z{Score: float64(score), Member: uid}
|
menbers = &redis.Z{Score: float64(score), Member: uid}
|
||||||
|
|
||||||
if cmd := pipe.ZAdd(tableName, menbers); cmd != nil {
|
if cmd := pipe.ZAdd(tableName, menbers); cmd != nil {
|
||||||
@ -252,10 +253,10 @@ func (this *ModelSRank) raceSettlement() {
|
|||||||
|
|
||||||
for iBossType := 1; iBossType <= 3; iBossType++ {
|
for iBossType := 1; iBossType <= 3; iBossType++ {
|
||||||
mailCid = fmt.Sprintf("SeasonViking%dReward", iBossType)
|
mailCid = fmt.Sprintf("SeasonViking%dReward", iBossType)
|
||||||
tableName := this.TableName + strconv.Itoa(int(iBossType))
|
//tableName := this.TableName + strconv.Itoa(int(iBossType))
|
||||||
szReward = this.moduleViking.configure.GetVikingRewardConf()
|
szReward = this.moduleViking.configure.GetVikingRewardConf()
|
||||||
|
tableName := fmt.Sprintf("%s-%s", db.CrossTag(), this.TableName+strconv.Itoa(int(iBossType)))
|
||||||
if result, err = this.DBModel.Redis.ZRevRange(fmt.Sprintf("%s-%s", this.DBModel, tableName), 0, comm.MaxRankList).Result(); err != nil {
|
if result, err = this.DBModel.Redis.ZRevRange(tableName, 0, comm.MaxRankList).Result(); err != nil {
|
||||||
this.moduleViking.Errorln(err)
|
this.moduleViking.Errorln(err)
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
@ -420,6 +420,7 @@ type DBXXLData struct {
|
|||||||
Maxsocre int32 `protobuf:"varint,19,opt,name=maxsocre,proto3" json:"maxsocre"` // 单局最大得分
|
Maxsocre int32 `protobuf:"varint,19,opt,name=maxsocre,proto3" json:"maxsocre"` // 单局最大得分
|
||||||
Uinfo *BaseUserInfo `protobuf:"bytes,20,opt,name=uinfo,proto3" json:"uinfo"` //用户基础
|
Uinfo *BaseUserInfo `protobuf:"bytes,20,opt,name=uinfo,proto3" json:"uinfo"` //用户基础
|
||||||
Taskprogess int32 `protobuf:"varint,21,opt,name=taskprogess,proto3" json:"taskprogess"` // 任务奖励进度
|
Taskprogess int32 `protobuf:"varint,21,opt,name=taskprogess,proto3" json:"taskprogess"` // 任务奖励进度
|
||||||
|
Rounds int32 `protobuf:"varint,22,opt,name=rounds,proto3" json:"rounds"` // 赛季轮数
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *DBXXLData) Reset() {
|
func (x *DBXXLData) Reset() {
|
||||||
@ -601,6 +602,13 @@ func (x *DBXXLData) GetTaskprogess() int32 {
|
|||||||
return 0
|
return 0
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func (x *DBXXLData) GetRounds() int32 {
|
||||||
|
if x != nil {
|
||||||
|
return x.Rounds
|
||||||
|
}
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
|
||||||
// 三消游戏规则
|
// 三消游戏规则
|
||||||
type DBXxlRules struct {
|
type DBXxlRules struct {
|
||||||
state protoimpl.MessageState
|
state protoimpl.MessageState
|
||||||
@ -977,7 +985,7 @@ var file_entertain_entertain_db_proto_rawDesc = []byte{
|
|||||||
0x44, 0x61, 0x74, 0x61, 0x12, 0x14, 0x0a, 0x05, 0x62, 0x6f, 0x78, 0x69, 0x64, 0x18, 0x01, 0x20,
|
0x44, 0x61, 0x74, 0x61, 0x12, 0x14, 0x0a, 0x05, 0x62, 0x6f, 0x78, 0x69, 0x64, 0x18, 0x01, 0x20,
|
||||||
0x01, 0x28, 0x05, 0x52, 0x05, 0x62, 0x6f, 0x78, 0x69, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x6f, 0x70,
|
0x01, 0x28, 0x05, 0x52, 0x05, 0x62, 0x6f, 0x78, 0x69, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x6f, 0x70,
|
||||||
0x65, 0x6e, 0x74, 0x69, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x6f, 0x70,
|
0x65, 0x6e, 0x74, 0x69, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x6f, 0x70,
|
||||||
0x65, 0x6e, 0x74, 0x69, 0x6d, 0x65, 0x22, 0xe8, 0x05, 0x0a, 0x09, 0x44, 0x42, 0x58, 0x58, 0x4c,
|
0x65, 0x6e, 0x74, 0x69, 0x6d, 0x65, 0x22, 0x80, 0x06, 0x0a, 0x09, 0x44, 0x42, 0x58, 0x58, 0x4c,
|
||||||
0x44, 0x61, 0x74, 0x61, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09,
|
0x44, 0x61, 0x74, 0x61, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09,
|
||||||
0x52, 0x02, 0x69, 0x64, 0x12, 0x10, 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28,
|
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, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64,
|
0x09, 0x52, 0x03, 0x75, 0x69, 0x64, 0x12, 0x16, 0x0a, 0x06, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64,
|
||||||
@ -1016,72 +1024,73 @@ var file_entertain_entertain_db_proto_rawDesc = []byte{
|
|||||||
0x18, 0x14, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0d, 0x2e, 0x42, 0x61, 0x73, 0x65, 0x55, 0x73, 0x65,
|
0x18, 0x14, 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, 0x20, 0x0a, 0x0b,
|
0x72, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x05, 0x75, 0x69, 0x6e, 0x66, 0x6f, 0x12, 0x20, 0x0a, 0x0b,
|
||||||
0x74, 0x61, 0x73, 0x6b, 0x70, 0x72, 0x6f, 0x67, 0x65, 0x73, 0x73, 0x18, 0x15, 0x20, 0x01, 0x28,
|
0x74, 0x61, 0x73, 0x6b, 0x70, 0x72, 0x6f, 0x67, 0x65, 0x73, 0x73, 0x18, 0x15, 0x20, 0x01, 0x28,
|
||||||
0x05, 0x52, 0x0b, 0x74, 0x61, 0x73, 0x6b, 0x70, 0x72, 0x6f, 0x67, 0x65, 0x73, 0x73, 0x1a, 0x37,
|
0x05, 0x52, 0x0b, 0x74, 0x61, 0x73, 0x6b, 0x70, 0x72, 0x6f, 0x67, 0x65, 0x73, 0x73, 0x12, 0x16,
|
||||||
0x0a, 0x09, 0x43, 0x61, 0x72, 0x64, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b,
|
0x0a, 0x06, 0x72, 0x6f, 0x75, 0x6e, 0x64, 0x73, 0x18, 0x16, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06,
|
||||||
0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a,
|
0x72, 0x6f, 0x75, 0x6e, 0x64, 0x73, 0x1a, 0x37, 0x0a, 0x09, 0x43, 0x61, 0x72, 0x64, 0x45, 0x6e,
|
||||||
0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x76, 0x61,
|
0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09,
|
||||||
0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x1a, 0x38, 0x0a, 0x0a, 0x53, 0x6b, 0x69, 0x6c, 0x6c,
|
0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02,
|
||||||
0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01,
|
0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x1a,
|
||||||
0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65,
|
0x38, 0x0a, 0x0a, 0x53, 0x6b, 0x69, 0x6c, 0x6c, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a,
|
||||||
0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38,
|
0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12,
|
||||||
0x01, 0x22, 0xac, 0x02, 0x0a, 0x0a, 0x44, 0x42, 0x58, 0x78, 0x6c, 0x52, 0x75, 0x6c, 0x65, 0x73,
|
0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05,
|
||||||
0x12, 0x1a, 0x0a, 0x08, 0x52, 0x6f, 0x6f, 0x6d, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01,
|
0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x22, 0xac, 0x02, 0x0a, 0x0a, 0x44, 0x42,
|
||||||
0x28, 0x05, 0x52, 0x08, 0x52, 0x6f, 0x6f, 0x6d, 0x54, 0x79, 0x70, 0x65, 0x12, 0x14, 0x0a, 0x05,
|
0x58, 0x78, 0x6c, 0x52, 0x75, 0x6c, 0x65, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x52, 0x6f, 0x6f, 0x6d,
|
||||||
0x63, 0x61, 0x72, 0x64, 0x31, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x63, 0x61, 0x72,
|
0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x08, 0x52, 0x6f, 0x6f, 0x6d,
|
||||||
0x64, 0x31, 0x12, 0x14, 0x0a, 0x05, 0x63, 0x61, 0x72, 0x64, 0x32, 0x18, 0x03, 0x20, 0x01, 0x28,
|
0x54, 0x79, 0x70, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x63, 0x61, 0x72, 0x64, 0x31, 0x18, 0x02, 0x20,
|
||||||
0x09, 0x52, 0x05, 0x63, 0x61, 0x72, 0x64, 0x32, 0x12, 0x2f, 0x0a, 0x06, 0x73, 0x6b, 0x69, 0x6c,
|
0x01, 0x28, 0x09, 0x52, 0x05, 0x63, 0x61, 0x72, 0x64, 0x31, 0x12, 0x14, 0x0a, 0x05, 0x63, 0x61,
|
||||||
0x6c, 0x31, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x44, 0x42, 0x58, 0x78, 0x6c,
|
0x72, 0x64, 0x32, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x63, 0x61, 0x72, 0x64, 0x32,
|
||||||
0x52, 0x75, 0x6c, 0x65, 0x73, 0x2e, 0x53, 0x6b, 0x69, 0x6c, 0x6c, 0x31, 0x45, 0x6e, 0x74, 0x72,
|
0x12, 0x2f, 0x0a, 0x06, 0x73, 0x6b, 0x69, 0x6c, 0x6c, 0x31, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b,
|
||||||
0x79, 0x52, 0x06, 0x73, 0x6b, 0x69, 0x6c, 0x6c, 0x31, 0x12, 0x2f, 0x0a, 0x06, 0x73, 0x6b, 0x69,
|
0x32, 0x17, 0x2e, 0x44, 0x42, 0x58, 0x78, 0x6c, 0x52, 0x75, 0x6c, 0x65, 0x73, 0x2e, 0x53, 0x6b,
|
||||||
0x6c, 0x6c, 0x32, 0x18, 0x05, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x44, 0x42, 0x58, 0x78,
|
0x69, 0x6c, 0x6c, 0x31, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x06, 0x73, 0x6b, 0x69, 0x6c, 0x6c,
|
||||||
0x6c, 0x52, 0x75, 0x6c, 0x65, 0x73, 0x2e, 0x53, 0x6b, 0x69, 0x6c, 0x6c, 0x32, 0x45, 0x6e, 0x74,
|
0x31, 0x12, 0x2f, 0x0a, 0x06, 0x73, 0x6b, 0x69, 0x6c, 0x6c, 0x32, 0x18, 0x05, 0x20, 0x03, 0x28,
|
||||||
0x72, 0x79, 0x52, 0x06, 0x73, 0x6b, 0x69, 0x6c, 0x6c, 0x32, 0x1a, 0x39, 0x0a, 0x0b, 0x53, 0x6b,
|
0x0b, 0x32, 0x17, 0x2e, 0x44, 0x42, 0x58, 0x78, 0x6c, 0x52, 0x75, 0x6c, 0x65, 0x73, 0x2e, 0x53,
|
||||||
0x69, 0x6c, 0x6c, 0x31, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79,
|
0x6b, 0x69, 0x6c, 0x6c, 0x32, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x06, 0x73, 0x6b, 0x69, 0x6c,
|
||||||
0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76,
|
0x6c, 0x32, 0x1a, 0x39, 0x0a, 0x0b, 0x53, 0x6b, 0x69, 0x6c, 0x6c, 0x31, 0x45, 0x6e, 0x74, 0x72,
|
||||||
0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75,
|
0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03,
|
||||||
0x65, 0x3a, 0x02, 0x38, 0x01, 0x1a, 0x39, 0x0a, 0x0b, 0x53, 0x6b, 0x69, 0x6c, 0x6c, 0x32, 0x45,
|
0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01,
|
||||||
0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28,
|
0x28, 0x05, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x1a, 0x39, 0x0a,
|
||||||
0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18,
|
0x0b, 0x53, 0x6b, 0x69, 0x6c, 0x6c, 0x32, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03,
|
||||||
0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01,
|
0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14,
|
||||||
0x22, 0xa6, 0x01, 0x0a, 0x09, 0x58, 0x78, 0x6c, 0x50, 0x6c, 0x61, 0x79, 0x65, 0x72, 0x12, 0x23,
|
0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x76,
|
||||||
0x0a, 0x05, 0x75, 0x69, 0x6e, 0x66, 0x6f, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0d, 0x2e,
|
0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x22, 0xa6, 0x01, 0x0a, 0x09, 0x58, 0x78, 0x6c,
|
||||||
0x42, 0x61, 0x73, 0x65, 0x55, 0x73, 0x65, 0x72, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x05, 0x75, 0x69,
|
0x50, 0x6c, 0x61, 0x79, 0x65, 0x72, 0x12, 0x23, 0x0a, 0x05, 0x75, 0x69, 0x6e, 0x66, 0x6f, 0x18,
|
||||||
0x6e, 0x66, 0x6f, 0x12, 0x12, 0x0a, 0x04, 0x72, 0x61, 0x6e, 0x6b, 0x18, 0x02, 0x20, 0x01, 0x28,
|
0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0d, 0x2e, 0x42, 0x61, 0x73, 0x65, 0x55, 0x73, 0x65, 0x72,
|
||||||
0x05, 0x52, 0x04, 0x72, 0x61, 0x6e, 0x6b, 0x12, 0x24, 0x0a, 0x0d, 0x6d, 0x61, 0x78, 0x63, 0x6f,
|
0x49, 0x6e, 0x66, 0x6f, 0x52, 0x05, 0x75, 0x69, 0x6e, 0x66, 0x6f, 0x12, 0x12, 0x0a, 0x04, 0x72,
|
||||||
0x6e, 0x73, 0x75, 0x6d, 0x65, 0x65, 0x78, 0x70, 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0d,
|
0x61, 0x6e, 0x6b, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x04, 0x72, 0x61, 0x6e, 0x6b, 0x12,
|
||||||
0x6d, 0x61, 0x78, 0x63, 0x6f, 0x6e, 0x73, 0x75, 0x6d, 0x65, 0x65, 0x78, 0x70, 0x12, 0x1e, 0x0a,
|
0x24, 0x0a, 0x0d, 0x6d, 0x61, 0x78, 0x63, 0x6f, 0x6e, 0x73, 0x75, 0x6d, 0x65, 0x65, 0x78, 0x70,
|
||||||
0x0a, 0x63, 0x6f, 0x6e, 0x73, 0x75, 0x6d, 0x65, 0x65, 0x78, 0x70, 0x18, 0x04, 0x20, 0x01, 0x28,
|
0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0d, 0x6d, 0x61, 0x78, 0x63, 0x6f, 0x6e, 0x73, 0x75,
|
||||||
0x05, 0x52, 0x0a, 0x63, 0x6f, 0x6e, 0x73, 0x75, 0x6d, 0x65, 0x65, 0x78, 0x70, 0x12, 0x1a, 0x0a,
|
0x6d, 0x65, 0x65, 0x78, 0x70, 0x12, 0x1e, 0x0a, 0x0a, 0x63, 0x6f, 0x6e, 0x73, 0x75, 0x6d, 0x65,
|
||||||
0x08, 0x6d, 0x61, 0x78, 0x73, 0x6f, 0x63, 0x72, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x05, 0x52,
|
0x65, 0x78, 0x70, 0x18, 0x04, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0a, 0x63, 0x6f, 0x6e, 0x73, 0x75,
|
||||||
0x08, 0x6d, 0x61, 0x78, 0x73, 0x6f, 0x63, 0x72, 0x65, 0x22, 0xa5, 0x03, 0x0a, 0x0b, 0x44, 0x42,
|
0x6d, 0x65, 0x65, 0x78, 0x70, 0x12, 0x1a, 0x0a, 0x08, 0x6d, 0x61, 0x78, 0x73, 0x6f, 0x63, 0x72,
|
||||||
0x58, 0x78, 0x6c, 0x52, 0x65, 0x63, 0x6f, 0x72, 0x64, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18,
|
0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x05, 0x52, 0x08, 0x6d, 0x61, 0x78, 0x73, 0x6f, 0x63, 0x72,
|
||||||
0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x0e, 0x0a, 0x02, 0x70, 0x31, 0x18,
|
0x65, 0x22, 0xa5, 0x03, 0x0a, 0x0b, 0x44, 0x42, 0x58, 0x78, 0x6c, 0x52, 0x65, 0x63, 0x6f, 0x72,
|
||||||
0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x70, 0x31, 0x12, 0x0e, 0x0a, 0x02, 0x70, 0x32, 0x18,
|
0x64, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69,
|
||||||
0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x70, 0x32, 0x12, 0x25, 0x0a, 0x06, 0x75, 0x69, 0x6e,
|
0x64, 0x12, 0x0e, 0x0a, 0x02, 0x70, 0x31, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x70,
|
||||||
0x66, 0x6f, 0x31, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0d, 0x2e, 0x42, 0x61, 0x73, 0x65,
|
0x31, 0x12, 0x0e, 0x0a, 0x02, 0x70, 0x32, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x70,
|
||||||
0x55, 0x73, 0x65, 0x72, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x06, 0x75, 0x69, 0x6e, 0x66, 0x6f, 0x31,
|
0x32, 0x12, 0x25, 0x0a, 0x06, 0x75, 0x69, 0x6e, 0x66, 0x6f, 0x31, 0x18, 0x04, 0x20, 0x01, 0x28,
|
||||||
0x12, 0x25, 0x0a, 0x06, 0x75, 0x69, 0x6e, 0x66, 0x6f, 0x32, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0b,
|
0x0b, 0x32, 0x0d, 0x2e, 0x42, 0x61, 0x73, 0x65, 0x55, 0x73, 0x65, 0x72, 0x49, 0x6e, 0x66, 0x6f,
|
||||||
0x32, 0x0d, 0x2e, 0x42, 0x61, 0x73, 0x65, 0x55, 0x73, 0x65, 0x72, 0x49, 0x6e, 0x66, 0x6f, 0x52,
|
0x52, 0x06, 0x75, 0x69, 0x6e, 0x66, 0x6f, 0x31, 0x12, 0x25, 0x0a, 0x06, 0x75, 0x69, 0x6e, 0x66,
|
||||||
0x06, 0x75, 0x69, 0x6e, 0x66, 0x6f, 0x32, 0x12, 0x18, 0x0a, 0x07, 0x70, 0x31, 0x73, 0x63, 0x6f,
|
0x6f, 0x32, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0d, 0x2e, 0x42, 0x61, 0x73, 0x65, 0x55,
|
||||||
0x72, 0x65, 0x18, 0x06, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x70, 0x31, 0x73, 0x63, 0x6f, 0x72,
|
0x73, 0x65, 0x72, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x06, 0x75, 0x69, 0x6e, 0x66, 0x6f, 0x32, 0x12,
|
||||||
0x65, 0x12, 0x18, 0x0a, 0x07, 0x70, 0x32, 0x73, 0x63, 0x6f, 0x72, 0x65, 0x18, 0x07, 0x20, 0x01,
|
0x18, 0x0a, 0x07, 0x70, 0x31, 0x73, 0x63, 0x6f, 0x72, 0x65, 0x18, 0x06, 0x20, 0x01, 0x28, 0x05,
|
||||||
0x28, 0x05, 0x52, 0x07, 0x70, 0x32, 0x73, 0x63, 0x6f, 0x72, 0x65, 0x12, 0x10, 0x0a, 0x03, 0x77,
|
0x52, 0x07, 0x70, 0x31, 0x73, 0x63, 0x6f, 0x72, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x70, 0x32, 0x73,
|
||||||
0x69, 0x6e, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x77, 0x69, 0x6e, 0x12, 0x1a, 0x0a,
|
0x63, 0x6f, 0x72, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x70, 0x32, 0x73, 0x63,
|
||||||
0x08, 0x77, 0x69, 0x6e, 0x73, 0x63, 0x6f, 0x72, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x05, 0x52,
|
0x6f, 0x72, 0x65, 0x12, 0x10, 0x0a, 0x03, 0x77, 0x69, 0x6e, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09,
|
||||||
0x08, 0x77, 0x69, 0x6e, 0x73, 0x63, 0x6f, 0x72, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x6c, 0x6f, 0x73,
|
0x52, 0x03, 0x77, 0x69, 0x6e, 0x12, 0x1a, 0x0a, 0x08, 0x77, 0x69, 0x6e, 0x73, 0x63, 0x6f, 0x72,
|
||||||
0x74, 0x73, 0x63, 0x6f, 0x72, 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x05, 0x52, 0x09, 0x6c, 0x6f,
|
0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x05, 0x52, 0x08, 0x77, 0x69, 0x6e, 0x73, 0x63, 0x6f, 0x72,
|
||||||
0x73, 0x74, 0x73, 0x63, 0x6f, 0x72, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x70, 0x31, 0x63, 0x61, 0x72,
|
0x65, 0x12, 0x1c, 0x0a, 0x09, 0x6c, 0x6f, 0x73, 0x74, 0x73, 0x63, 0x6f, 0x72, 0x65, 0x18, 0x0a,
|
||||||
0x64, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x70, 0x31, 0x63, 0x61, 0x72, 0x64, 0x12,
|
0x20, 0x01, 0x28, 0x05, 0x52, 0x09, 0x6c, 0x6f, 0x73, 0x74, 0x73, 0x63, 0x6f, 0x72, 0x65, 0x12,
|
||||||
0x18, 0x0a, 0x07, 0x70, 0x32, 0x63, 0x61, 0x72, 0x64, 0x73, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x09,
|
0x16, 0x0a, 0x06, 0x70, 0x31, 0x63, 0x61, 0x72, 0x64, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52,
|
||||||
0x52, 0x07, 0x70, 0x32, 0x63, 0x61, 0x72, 0x64, 0x73, 0x12, 0x22, 0x0a, 0x0c, 0x70, 0x31, 0x74,
|
0x06, 0x70, 0x31, 0x63, 0x61, 0x72, 0x64, 0x12, 0x18, 0x0a, 0x07, 0x70, 0x32, 0x63, 0x61, 0x72,
|
||||||
0x6f, 0x74, 0x6c, 0x61, 0x73, 0x63, 0x6f, 0x72, 0x65, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x05, 0x52,
|
0x64, 0x73, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x70, 0x32, 0x63, 0x61, 0x72, 0x64,
|
||||||
0x0c, 0x70, 0x31, 0x74, 0x6f, 0x74, 0x6c, 0x61, 0x73, 0x63, 0x6f, 0x72, 0x65, 0x12, 0x22, 0x0a,
|
0x73, 0x12, 0x22, 0x0a, 0x0c, 0x70, 0x31, 0x74, 0x6f, 0x74, 0x6c, 0x61, 0x73, 0x63, 0x6f, 0x72,
|
||||||
0x0c, 0x70, 0x32, 0x74, 0x6f, 0x74, 0x6c, 0x61, 0x73, 0x63, 0x6f, 0x72, 0x65, 0x18, 0x0e, 0x20,
|
0x65, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0c, 0x70, 0x31, 0x74, 0x6f, 0x74, 0x6c, 0x61,
|
||||||
0x01, 0x28, 0x05, 0x52, 0x0c, 0x70, 0x32, 0x74, 0x6f, 0x74, 0x6c, 0x61, 0x73, 0x63, 0x6f, 0x72,
|
0x73, 0x63, 0x6f, 0x72, 0x65, 0x12, 0x22, 0x0a, 0x0c, 0x70, 0x32, 0x74, 0x6f, 0x74, 0x6c, 0x61,
|
||||||
0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x63, 0x72, 0x65, 0x61, 0x74, 0x65, 0x74, 0x69, 0x6d, 0x65, 0x18,
|
0x73, 0x63, 0x6f, 0x72, 0x65, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0c, 0x70, 0x32, 0x74,
|
||||||
0x0f, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x63, 0x72, 0x65, 0x61, 0x74, 0x65, 0x74, 0x69, 0x6d,
|
0x6f, 0x74, 0x6c, 0x61, 0x73, 0x63, 0x6f, 0x72, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x63, 0x72, 0x65,
|
||||||
0x65, 0x42, 0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f,
|
0x61, 0x74, 0x65, 0x74, 0x69, 0x6d, 0x65, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x63,
|
||||||
0x33,
|
0x72, 0x65, 0x61, 0x74, 0x65, 0x74, 0x69, 0x6d, 0x65, 0x42, 0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70,
|
||||||
|
0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
|
||||||
}
|
}
|
||||||
|
|
||||||
var (
|
var (
|
||||||
|
@ -160,7 +160,6 @@ type DBUser struct {
|
|||||||
Titles []string `protobuf:"bytes,47,rep,name=titles,proto3" json:"titles"` // 称号
|
Titles []string `protobuf:"bytes,47,rep,name=titles,proto3" json:"titles"` // 称号
|
||||||
Curtitle string `protobuf:"bytes,48,opt,name=curtitle,proto3" json:"curtitle"` // 默认称号
|
Curtitle string `protobuf:"bytes,48,opt,name=curtitle,proto3" json:"curtitle"` // 默认称号
|
||||||
Curaframe string `protobuf:"bytes,49,opt,name=curaframe,proto3" json:"curaframe"` //默认头像框
|
Curaframe string `protobuf:"bytes,49,opt,name=curaframe,proto3" json:"curaframe"` //默认头像框
|
||||||
Consumeexp int32 `protobuf:"varint,50,opt,name=consumeexp,proto3" json:"consumeexp"` //消消乐赛季进度积分
|
|
||||||
Consumemoney int32 `protobuf:"varint,51,opt,name=consumemoney,proto3" json:"consumemoney"` //三消专属货币
|
Consumemoney int32 `protobuf:"varint,51,opt,name=consumemoney,proto3" json:"consumemoney"` //三消专属货币
|
||||||
Ban bool `protobuf:"varint,52,opt,name=ban,proto3" json:"ban"` // 封号标识
|
Ban bool `protobuf:"varint,52,opt,name=ban,proto3" json:"ban"` // 封号标识
|
||||||
Prohibition int32 `protobuf:"varint,53,opt,name=prohibition,proto3" json:"prohibition"` // 禁言
|
Prohibition int32 `protobuf:"varint,53,opt,name=prohibition,proto3" json:"prohibition"` // 禁言
|
||||||
@ -530,13 +529,6 @@ func (x *DBUser) GetCuraframe() string {
|
|||||||
return ""
|
return ""
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *DBUser) GetConsumeexp() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.Consumeexp
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *DBUser) GetConsumemoney() int32 {
|
func (x *DBUser) GetConsumemoney() int32 {
|
||||||
if x != nil {
|
if x != nil {
|
||||||
return x.Consumemoney
|
return x.Consumemoney
|
||||||
@ -987,8 +979,6 @@ var file_user_user_db_proto_rawDesc = []byte{
|
|||||||
0x65, 0x18, 0x30, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x63, 0x75, 0x72, 0x74, 0x69, 0x74, 0x6c,
|
0x65, 0x18, 0x30, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x63, 0x75, 0x72, 0x74, 0x69, 0x74, 0x6c,
|
||||||
0x65, 0x12, 0x1c, 0x0a, 0x09, 0x63, 0x75, 0x72, 0x61, 0x66, 0x72, 0x61, 0x6d, 0x65, 0x18, 0x31,
|
0x65, 0x12, 0x1c, 0x0a, 0x09, 0x63, 0x75, 0x72, 0x61, 0x66, 0x72, 0x61, 0x6d, 0x65, 0x18, 0x31,
|
||||||
0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x63, 0x75, 0x72, 0x61, 0x66, 0x72, 0x61, 0x6d, 0x65, 0x12,
|
0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x63, 0x75, 0x72, 0x61, 0x66, 0x72, 0x61, 0x6d, 0x65, 0x12,
|
||||||
0x1e, 0x0a, 0x0a, 0x63, 0x6f, 0x6e, 0x73, 0x75, 0x6d, 0x65, 0x65, 0x78, 0x70, 0x18, 0x32, 0x20,
|
|
||||||
0x01, 0x28, 0x05, 0x52, 0x0a, 0x63, 0x6f, 0x6e, 0x73, 0x75, 0x6d, 0x65, 0x65, 0x78, 0x70, 0x12,
|
|
||||||
0x22, 0x0a, 0x0c, 0x63, 0x6f, 0x6e, 0x73, 0x75, 0x6d, 0x65, 0x6d, 0x6f, 0x6e, 0x65, 0x79, 0x18,
|
0x22, 0x0a, 0x0c, 0x63, 0x6f, 0x6e, 0x73, 0x75, 0x6d, 0x65, 0x6d, 0x6f, 0x6e, 0x65, 0x79, 0x18,
|
||||||
0x33, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0c, 0x63, 0x6f, 0x6e, 0x73, 0x75, 0x6d, 0x65, 0x6d, 0x6f,
|
0x33, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0c, 0x63, 0x6f, 0x6e, 0x73, 0x75, 0x6d, 0x65, 0x6d, 0x6f,
|
||||||
0x6e, 0x65, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x62, 0x61, 0x6e, 0x18, 0x34, 0x20, 0x01, 0x28, 0x08,
|
0x6e, 0x65, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x62, 0x61, 0x6e, 0x18, 0x34, 0x20, 0x01, 0x28, 0x08,
|
||||||
|
Loading…
Reference in New Issue
Block a user