add 红包活动
This commit is contained in:
parent
adf2dc3c92
commit
7f6b4a86ae
|
|
@ -330,6 +330,7 @@ const (
|
||||||
GainWayCompoundGain = 119 // 道具合成获得
|
GainWayCompoundGain = 119 // 道具合成获得
|
||||||
GainWayItem_PigBankTakeCoin = 120 // 购买金币存钱罐奖励道具
|
GainWayItem_PigBankTakeCoin = 120 // 购买金币存钱罐奖励道具
|
||||||
GainWayItem_PigBankTakeDiamond = 121 // 购买钻石存钱罐奖励道具
|
GainWayItem_PigBankTakeDiamond = 121 // 购买钻石存钱罐奖励道具
|
||||||
|
GainWayRedPacket = 122 // 红包奖励
|
||||||
)
|
)
|
||||||
|
|
||||||
// 后台选择 金币变化类型 的充值 类型id号起始
|
// 后台选择 金币变化类型 的充值 类型id号起始
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,277 @@
|
||||||
|
// --------------------------------------------------------------------------------------------
|
||||||
|
// The following code is automatically generated by the mongo-dao-generator tool.
|
||||||
|
// Please do not modify this code manually to avoid being overwritten in the next generation.
|
||||||
|
// For more tool details, please click the link to view https://github.com/dobyte/mongo-dao-generator
|
||||||
|
// --------------------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
package internal
|
||||||
|
|
||||||
|
import (
|
||||||
|
"context"
|
||||||
|
"errors"
|
||||||
|
"go.mongodb.org/mongo-driver/bson"
|
||||||
|
"go.mongodb.org/mongo-driver/bson/primitive"
|
||||||
|
"go.mongodb.org/mongo-driver/mongo"
|
||||||
|
"go.mongodb.org/mongo-driver/mongo/options"
|
||||||
|
modelpkg "mongo.games.com/game/model"
|
||||||
|
)
|
||||||
|
|
||||||
|
type RedPacketFilterFunc func(cols *RedPacketColumns) interface{}
|
||||||
|
type RedPacketUpdateFunc func(cols *RedPacketColumns) interface{}
|
||||||
|
type RedPacketPipelineFunc func(cols *RedPacketColumns) interface{}
|
||||||
|
type RedPacketCountOptionsFunc func(cols *RedPacketColumns) *options.CountOptions
|
||||||
|
type RedPacketAggregateOptionsFunc func(cols *RedPacketColumns) *options.AggregateOptions
|
||||||
|
type RedPacketFindOneOptionsFunc func(cols *RedPacketColumns) *options.FindOneOptions
|
||||||
|
type RedPacketFindManyOptionsFunc func(cols *RedPacketColumns) *options.FindOptions
|
||||||
|
type RedPacketUpdateOptionsFunc func(cols *RedPacketColumns) *options.UpdateOptions
|
||||||
|
type RedPacketDeleteOptionsFunc func(cols *RedPacketColumns) *options.DeleteOptions
|
||||||
|
type RedPacketInsertOneOptionsFunc func(cols *RedPacketColumns) *options.InsertOneOptions
|
||||||
|
type RedPacketInsertManyOptionsFunc func(cols *RedPacketColumns) *options.InsertManyOptions
|
||||||
|
|
||||||
|
type RedPacket struct {
|
||||||
|
Columns *RedPacketColumns
|
||||||
|
Database *mongo.Database
|
||||||
|
Collection *mongo.Collection
|
||||||
|
}
|
||||||
|
|
||||||
|
type RedPacketColumns struct {
|
||||||
|
ID string
|
||||||
|
Cid string // 红包活动id
|
||||||
|
Use string // 已发红包 红包奖励数量:已发个数
|
||||||
|
Ts string // 更新时间戳
|
||||||
|
}
|
||||||
|
|
||||||
|
var redPacketColumns = &RedPacketColumns{
|
||||||
|
ID: "_id",
|
||||||
|
Cid: "Cid", // 红包活动id
|
||||||
|
Use: "Use", // 已发红包 红包奖励数量:已发个数
|
||||||
|
Ts: "Ts", // 更新时间戳
|
||||||
|
}
|
||||||
|
|
||||||
|
func NewRedPacket() *RedPacket {
|
||||||
|
return &RedPacket{
|
||||||
|
Columns: redPacketColumns,
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// Count returns the number of documents in the collection.
|
||||||
|
func (dao *RedPacket) Count(ctx context.Context, filterFunc RedPacketFilterFunc, optionsFunc ...RedPacketCountOptionsFunc) (int64, error) {
|
||||||
|
var (
|
||||||
|
opts *options.CountOptions
|
||||||
|
filter = filterFunc(dao.Columns)
|
||||||
|
)
|
||||||
|
|
||||||
|
if len(optionsFunc) > 0 {
|
||||||
|
opts = optionsFunc[0](dao.Columns)
|
||||||
|
}
|
||||||
|
|
||||||
|
return dao.Collection.CountDocuments(ctx, filter, opts)
|
||||||
|
}
|
||||||
|
|
||||||
|
// Aggregate executes an aggregate command against the collection and returns a cursor over the resulting documents.
|
||||||
|
func (dao *RedPacket) Aggregate(ctx context.Context, pipelineFunc RedPacketPipelineFunc, optionsFunc ...RedPacketAggregateOptionsFunc) (*mongo.Cursor, error) {
|
||||||
|
var (
|
||||||
|
opts *options.AggregateOptions
|
||||||
|
pipeline = pipelineFunc(dao.Columns)
|
||||||
|
)
|
||||||
|
|
||||||
|
if len(optionsFunc) > 0 {
|
||||||
|
opts = optionsFunc[0](dao.Columns)
|
||||||
|
}
|
||||||
|
|
||||||
|
return dao.Collection.Aggregate(ctx, pipeline, opts)
|
||||||
|
}
|
||||||
|
|
||||||
|
// InsertOne executes an insert command to insert a single document into the collection.
|
||||||
|
func (dao *RedPacket) InsertOne(ctx context.Context, model *modelpkg.RedPacket, optionsFunc ...RedPacketInsertOneOptionsFunc) (*mongo.InsertOneResult, error) {
|
||||||
|
if model == nil {
|
||||||
|
return nil, errors.New("model is nil")
|
||||||
|
}
|
||||||
|
|
||||||
|
if err := dao.autofill(ctx, model); err != nil {
|
||||||
|
return nil, err
|
||||||
|
}
|
||||||
|
|
||||||
|
var opts *options.InsertOneOptions
|
||||||
|
|
||||||
|
if len(optionsFunc) > 0 {
|
||||||
|
opts = optionsFunc[0](dao.Columns)
|
||||||
|
}
|
||||||
|
|
||||||
|
return dao.Collection.InsertOne(ctx, model, opts)
|
||||||
|
}
|
||||||
|
|
||||||
|
// InsertMany executes an insert command to insert multiple documents into the collection.
|
||||||
|
func (dao *RedPacket) InsertMany(ctx context.Context, models []*modelpkg.RedPacket, optionsFunc ...RedPacketInsertManyOptionsFunc) (*mongo.InsertManyResult, error) {
|
||||||
|
if len(models) == 0 {
|
||||||
|
return nil, errors.New("models is empty")
|
||||||
|
}
|
||||||
|
|
||||||
|
documents := make([]interface{}, 0, len(models))
|
||||||
|
for i := range models {
|
||||||
|
model := models[i]
|
||||||
|
if err := dao.autofill(ctx, model); err != nil {
|
||||||
|
return nil, err
|
||||||
|
}
|
||||||
|
documents = append(documents, model)
|
||||||
|
}
|
||||||
|
|
||||||
|
var opts *options.InsertManyOptions
|
||||||
|
|
||||||
|
if len(optionsFunc) > 0 {
|
||||||
|
opts = optionsFunc[0](dao.Columns)
|
||||||
|
}
|
||||||
|
|
||||||
|
return dao.Collection.InsertMany(ctx, documents, opts)
|
||||||
|
}
|
||||||
|
|
||||||
|
// UpdateOne executes an update command to update at most one document in the collection.
|
||||||
|
func (dao *RedPacket) UpdateOne(ctx context.Context, filterFunc RedPacketFilterFunc, updateFunc RedPacketUpdateFunc, optionsFunc ...RedPacketUpdateOptionsFunc) (*mongo.UpdateResult, error) {
|
||||||
|
var (
|
||||||
|
opts *options.UpdateOptions
|
||||||
|
filter = filterFunc(dao.Columns)
|
||||||
|
update = updateFunc(dao.Columns)
|
||||||
|
)
|
||||||
|
|
||||||
|
if len(optionsFunc) > 0 {
|
||||||
|
opts = optionsFunc[0](dao.Columns)
|
||||||
|
}
|
||||||
|
|
||||||
|
return dao.Collection.UpdateOne(ctx, filter, update, opts)
|
||||||
|
}
|
||||||
|
|
||||||
|
// UpdateOneByID executes an update command to update at most one document in the collection.
|
||||||
|
func (dao *RedPacket) UpdateOneByID(ctx context.Context, id string, updateFunc RedPacketUpdateFunc, optionsFunc ...RedPacketUpdateOptionsFunc) (*mongo.UpdateResult, error) {
|
||||||
|
objectID, err := primitive.ObjectIDFromHex(id)
|
||||||
|
if err != nil {
|
||||||
|
return nil, err
|
||||||
|
}
|
||||||
|
|
||||||
|
return dao.UpdateOne(ctx, func(cols *RedPacketColumns) interface{} {
|
||||||
|
return bson.M{"_id": objectID}
|
||||||
|
}, updateFunc, optionsFunc...)
|
||||||
|
}
|
||||||
|
|
||||||
|
// UpdateMany executes an update command to update documents in the collection.
|
||||||
|
func (dao *RedPacket) UpdateMany(ctx context.Context, filterFunc RedPacketFilterFunc, updateFunc RedPacketUpdateFunc, optionsFunc ...RedPacketUpdateOptionsFunc) (*mongo.UpdateResult, error) {
|
||||||
|
var (
|
||||||
|
opts *options.UpdateOptions
|
||||||
|
filter = filterFunc(dao.Columns)
|
||||||
|
update = updateFunc(dao.Columns)
|
||||||
|
)
|
||||||
|
|
||||||
|
if len(optionsFunc) > 0 {
|
||||||
|
opts = optionsFunc[0](dao.Columns)
|
||||||
|
}
|
||||||
|
|
||||||
|
return dao.Collection.UpdateMany(ctx, filter, update, opts)
|
||||||
|
}
|
||||||
|
|
||||||
|
// FindOne executes a find command and returns a model for one document in the collection.
|
||||||
|
func (dao *RedPacket) FindOne(ctx context.Context, filterFunc RedPacketFilterFunc, optionsFunc ...RedPacketFindOneOptionsFunc) (*modelpkg.RedPacket, error) {
|
||||||
|
var (
|
||||||
|
opts *options.FindOneOptions
|
||||||
|
model = &modelpkg.RedPacket{}
|
||||||
|
filter = filterFunc(dao.Columns)
|
||||||
|
)
|
||||||
|
|
||||||
|
if len(optionsFunc) > 0 {
|
||||||
|
opts = optionsFunc[0](dao.Columns)
|
||||||
|
}
|
||||||
|
|
||||||
|
err := dao.Collection.FindOne(ctx, filter, opts).Decode(model)
|
||||||
|
if err != nil {
|
||||||
|
if err == mongo.ErrNoDocuments {
|
||||||
|
return nil, nil
|
||||||
|
}
|
||||||
|
return nil, err
|
||||||
|
}
|
||||||
|
|
||||||
|
return model, nil
|
||||||
|
}
|
||||||
|
|
||||||
|
// FindOneByID executes a find command and returns a model for one document in the collection.
|
||||||
|
func (dao *RedPacket) FindOneByID(ctx context.Context, id string, optionsFunc ...RedPacketFindOneOptionsFunc) (*modelpkg.RedPacket, error) {
|
||||||
|
objectID, err := primitive.ObjectIDFromHex(id)
|
||||||
|
if err != nil {
|
||||||
|
return nil, err
|
||||||
|
}
|
||||||
|
|
||||||
|
return dao.FindOne(ctx, func(cols *RedPacketColumns) interface{} {
|
||||||
|
return bson.M{"_id": objectID}
|
||||||
|
}, optionsFunc...)
|
||||||
|
}
|
||||||
|
|
||||||
|
// FindMany executes a find command and returns many models the matching documents in the collection.
|
||||||
|
func (dao *RedPacket) FindMany(ctx context.Context, filterFunc RedPacketFilterFunc, optionsFunc ...RedPacketFindManyOptionsFunc) ([]*modelpkg.RedPacket, error) {
|
||||||
|
var (
|
||||||
|
opts *options.FindOptions
|
||||||
|
filter = filterFunc(dao.Columns)
|
||||||
|
)
|
||||||
|
|
||||||
|
if len(optionsFunc) > 0 {
|
||||||
|
opts = optionsFunc[0](dao.Columns)
|
||||||
|
}
|
||||||
|
|
||||||
|
cur, err := dao.Collection.Find(ctx, filter, opts)
|
||||||
|
if err != nil {
|
||||||
|
return nil, err
|
||||||
|
}
|
||||||
|
|
||||||
|
models := make([]*modelpkg.RedPacket, 0)
|
||||||
|
|
||||||
|
if err = cur.All(ctx, &models); err != nil {
|
||||||
|
return nil, err
|
||||||
|
}
|
||||||
|
|
||||||
|
return models, nil
|
||||||
|
}
|
||||||
|
|
||||||
|
// DeleteOne executes a delete command to delete at most one document from the collection.
|
||||||
|
func (dao *RedPacket) DeleteOne(ctx context.Context, filterFunc RedPacketFilterFunc, optionsFunc ...RedPacketDeleteOptionsFunc) (*mongo.DeleteResult, error) {
|
||||||
|
var (
|
||||||
|
opts *options.DeleteOptions
|
||||||
|
filter = filterFunc(dao.Columns)
|
||||||
|
)
|
||||||
|
|
||||||
|
if len(optionsFunc) > 0 {
|
||||||
|
opts = optionsFunc[0](dao.Columns)
|
||||||
|
}
|
||||||
|
|
||||||
|
return dao.Collection.DeleteOne(ctx, filter, opts)
|
||||||
|
}
|
||||||
|
|
||||||
|
// DeleteOneByID executes a delete command to delete at most one document from the collection.
|
||||||
|
func (dao *RedPacket) DeleteOneByID(ctx context.Context, id string, optionsFunc ...RedPacketDeleteOptionsFunc) (*mongo.DeleteResult, error) {
|
||||||
|
objectID, err := primitive.ObjectIDFromHex(id)
|
||||||
|
if err != nil {
|
||||||
|
return nil, err
|
||||||
|
}
|
||||||
|
|
||||||
|
return dao.DeleteOne(ctx, func(cols *RedPacketColumns) interface{} {
|
||||||
|
return bson.M{"_id": objectID}
|
||||||
|
}, optionsFunc...)
|
||||||
|
}
|
||||||
|
|
||||||
|
// DeleteMany executes a delete command to delete documents from the collection.
|
||||||
|
func (dao *RedPacket) DeleteMany(ctx context.Context, filterFunc RedPacketFilterFunc, optionsFunc ...RedPacketDeleteOptionsFunc) (*mongo.DeleteResult, error) {
|
||||||
|
var (
|
||||||
|
opts *options.DeleteOptions
|
||||||
|
filter = filterFunc(dao.Columns)
|
||||||
|
)
|
||||||
|
|
||||||
|
if len(optionsFunc) > 0 {
|
||||||
|
opts = optionsFunc[0](dao.Columns)
|
||||||
|
}
|
||||||
|
|
||||||
|
return dao.Collection.DeleteMany(ctx, filter, opts)
|
||||||
|
}
|
||||||
|
|
||||||
|
// autofill when inserting data
|
||||||
|
func (dao *RedPacket) autofill(ctx context.Context, model *modelpkg.RedPacket) error {
|
||||||
|
if model.ID.IsZero() {
|
||||||
|
model.ID = primitive.NewObjectID()
|
||||||
|
}
|
||||||
|
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,88 @@
|
||||||
|
package dao
|
||||||
|
|
||||||
|
import (
|
||||||
|
"context"
|
||||||
|
"errors"
|
||||||
|
|
||||||
|
"go.mongodb.org/mongo-driver/bson"
|
||||||
|
"go.mongodb.org/mongo-driver/mongo"
|
||||||
|
"go.mongodb.org/mongo-driver/mongo/options"
|
||||||
|
"mongo.games.com/goserver/core/logger"
|
||||||
|
"mongo.games.com/goserver/core/mongox"
|
||||||
|
|
||||||
|
"mongo.games.com/game/dao/internal"
|
||||||
|
modelpkg "mongo.games.com/game/model"
|
||||||
|
)
|
||||||
|
|
||||||
|
var (
|
||||||
|
_ = context.Background()
|
||||||
|
_ = logger.Logger
|
||||||
|
_ = bson.M{}
|
||||||
|
_ = mongo.Database{}
|
||||||
|
)
|
||||||
|
|
||||||
|
type RedPacketColumns = internal.RedPacketColumns
|
||||||
|
|
||||||
|
type RedPacket struct {
|
||||||
|
*internal.RedPacket
|
||||||
|
}
|
||||||
|
|
||||||
|
func GetRedPacket(key string) (*RedPacket, error) {
|
||||||
|
return mongox.GetDao(key, NewRedPacket)
|
||||||
|
}
|
||||||
|
|
||||||
|
func NewRedPacket(db *mongo.Database, c *mongo.Collection) (*RedPacket, any) {
|
||||||
|
if db == nil || c == nil {
|
||||||
|
return &RedPacket{}, &modelpkg.RedPacket{}
|
||||||
|
}
|
||||||
|
|
||||||
|
v := internal.NewRedPacket()
|
||||||
|
v.Database = db
|
||||||
|
v.Collection = c
|
||||||
|
|
||||||
|
// 创建索引
|
||||||
|
c.Indexes().CreateOne(context.Background(), mongo.IndexModel{
|
||||||
|
Keys: bson.D{{"cid", 1}}, // 1 表示升序,-1 表示降序
|
||||||
|
Options: options.Index().SetBackground(true).SetSparse(true), // 后台创建索引,稀疏索引
|
||||||
|
})
|
||||||
|
c.Indexes().CreateOne(context.Background(), mongo.IndexModel{
|
||||||
|
Keys: bson.D{{"ts", 1}}, // 1 表示升序,-1 表示降序
|
||||||
|
Options: options.Index().SetBackground(true).SetSparse(true), // 后台创建索引,稀疏索引
|
||||||
|
})
|
||||||
|
c.Indexes().CreateOne(context.Background(), mongo.IndexModel{
|
||||||
|
Keys: bson.D{{"ts", -1}}, // 1 表示升序,-1 表示降序
|
||||||
|
Options: options.Index().SetBackground(true).SetSparse(true), // 后台创建索引,稀疏索引
|
||||||
|
})
|
||||||
|
|
||||||
|
return &RedPacket{RedPacket: v}, &modelpkg.RedPacket{}
|
||||||
|
}
|
||||||
|
|
||||||
|
func (r *RedPacket) GetAll() (res []*modelpkg.RedPacket, err error) {
|
||||||
|
res, err = r.FindMany(context.Background(), func(cols *RedPacketColumns) interface{} {
|
||||||
|
return bson.M{}
|
||||||
|
})
|
||||||
|
if err != nil && !errors.Is(err, mongo.ErrNoDocuments) {
|
||||||
|
return nil, err
|
||||||
|
}
|
||||||
|
|
||||||
|
return res, nil
|
||||||
|
}
|
||||||
|
|
||||||
|
func (r *RedPacket) UpdateAll(list []*modelpkg.RedPacket) error {
|
||||||
|
var operations []mongo.WriteModel
|
||||||
|
for _, v := range list {
|
||||||
|
updateDataMap := bson.M{
|
||||||
|
"$set": v,
|
||||||
|
}
|
||||||
|
delete(updateDataMap["$set"].(bson.M), "_id") // 删除 _id 字段
|
||||||
|
operations = append(operations, mongo.NewUpdateOneModel().SetFilter(bson.M{"_id": v.ID}).SetUpdate(bson.M{"$set": v}).SetUpsert(true))
|
||||||
|
}
|
||||||
|
|
||||||
|
_, err := r.Collection.BulkWrite(context.Background(), operations) // 批量更新
|
||||||
|
if err != nil {
|
||||||
|
logger.Logger.Errorf("RedPacket.UpdateAll error: %v", err)
|
||||||
|
return err
|
||||||
|
}
|
||||||
|
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,52 @@
|
||||||
|
package svc
|
||||||
|
|
||||||
|
import (
|
||||||
|
"net/rpc"
|
||||||
|
|
||||||
|
"mongo.games.com/goserver/core/logger"
|
||||||
|
"mongo.games.com/goserver/core/mongox"
|
||||||
|
|
||||||
|
"mongo.games.com/game/dao"
|
||||||
|
"mongo.games.com/game/model"
|
||||||
|
)
|
||||||
|
|
||||||
|
var RedPacketSvc = new(RedPacketService)
|
||||||
|
|
||||||
|
func init() {
|
||||||
|
rpc.Register(RedPacketSvc)
|
||||||
|
}
|
||||||
|
|
||||||
|
type RedPacketService struct {
|
||||||
|
}
|
||||||
|
|
||||||
|
func (r *RedPacketService) GetAll(plt *string, res *[]*model.RedPacket) error {
|
||||||
|
d, err := dao.GetRedPacket(*plt)
|
||||||
|
if err != nil {
|
||||||
|
return err
|
||||||
|
}
|
||||||
|
|
||||||
|
list, err := d.GetAll()
|
||||||
|
if err != nil {
|
||||||
|
logger.Logger.Errorf("GetAll error: %v", err)
|
||||||
|
return err
|
||||||
|
}
|
||||||
|
|
||||||
|
*res = list
|
||||||
|
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
||||||
|
func (r *RedPacketService) UpdateAll(plt *string, list []*model.RedPacket) error {
|
||||||
|
d, err := mongox.GetDao(*plt, dao.NewRedPacket)
|
||||||
|
if err != nil {
|
||||||
|
return err
|
||||||
|
}
|
||||||
|
|
||||||
|
err = d.UpdateAll(list)
|
||||||
|
if err != nil {
|
||||||
|
logger.Logger.Errorf("UpdateAll error: %v", err)
|
||||||
|
return err
|
||||||
|
}
|
||||||
|
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
@ -51,4 +51,5 @@ const (
|
||||||
ETCDKEY_LotteryUser = "/game/user_lottery" //抽奖用户必中配置
|
ETCDKEY_LotteryUser = "/game/user_lottery" //抽奖用户必中配置
|
||||||
ETCDKEY_PigBankDiamond = "/game/pigbank_diamond" //存钱罐消耗获得
|
ETCDKEY_PigBankDiamond = "/game/pigbank_diamond" //存钱罐消耗获得
|
||||||
ETCDKEY_PigBankProp = "/game/pigbank_prop" //存钱罐属性
|
ETCDKEY_PigBankProp = "/game/pigbank_prop" //存钱罐属性
|
||||||
|
ETCDKEY_REDPACKET = "/game/act_redpacket" //红包配置
|
||||||
)
|
)
|
||||||
|
|
|
||||||
|
|
@ -25,6 +25,7 @@ const (
|
||||||
OpPhoneLottery = 5
|
OpPhoneLottery = 5
|
||||||
OpCollect = 6
|
OpCollect = 6
|
||||||
OpDiamondLottery = 7
|
OpDiamondLottery = 7
|
||||||
|
OpRedPacket = 8 // 红包活动
|
||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
|
|
@ -167,6 +168,8 @@ type AllConfig struct {
|
||||||
*webapi.GamePigBankDiamondConfig
|
*webapi.GamePigBankDiamondConfig
|
||||||
// 存钱罐属性
|
// 存钱罐属性
|
||||||
*webapi.GamePigBankPropConfig
|
*webapi.GamePigBankPropConfig
|
||||||
|
// 红包配置
|
||||||
|
*webapi.RedPacketConfig
|
||||||
}
|
}
|
||||||
|
|
||||||
type GlobalConfig struct {
|
type GlobalConfig struct {
|
||||||
|
|
|
||||||
|
|
@ -564,6 +564,7 @@ type WelfareData struct {
|
||||||
DiamondBank *DiamondBankData // 钻石储存罐
|
DiamondBank *DiamondBankData // 钻石储存罐
|
||||||
PermitAward map[int32]int64 // 赛季通行证奖励领取时间
|
PermitAward map[int32]int64 // 赛季通行证奖励领取时间
|
||||||
PermitExchange map[int32][]int64 // 赛季通行证兑换次数, 多次的兑换时间
|
PermitExchange map[int32][]int64 // 赛季通行证兑换次数, 多次的兑换时间
|
||||||
|
RedPacket map[int64]int // 红包活动 活动id:领取次数
|
||||||
}
|
}
|
||||||
|
|
||||||
func NewWelfareData() *WelfareData {
|
func NewWelfareData() *WelfareData {
|
||||||
|
|
@ -580,6 +581,7 @@ func NewWelfareData() *WelfareData {
|
||||||
},
|
},
|
||||||
PermitAward: make(map[int32]int64),
|
PermitAward: make(map[int32]int64),
|
||||||
PermitExchange: make(map[int32][]int64),
|
PermitExchange: make(map[int32][]int64),
|
||||||
|
RedPacket: make(map[int64]int),
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,55 @@
|
||||||
|
package model
|
||||||
|
|
||||||
|
import (
|
||||||
|
"errors"
|
||||||
|
"time"
|
||||||
|
|
||||||
|
"go.mongodb.org/mongo-driver/bson/primitive"
|
||||||
|
"mongo.games.com/goserver/core/logger"
|
||||||
|
)
|
||||||
|
|
||||||
|
//go:generate mongoctl -model-dir=. -model-names=RedPacket -dao-dir=../dao/
|
||||||
|
type RedPacket struct {
|
||||||
|
ID primitive.ObjectID `bson:"_id" gen:"autoFill"`
|
||||||
|
Cid int64 // 红包活动id
|
||||||
|
Use map[int64]int64 // 已发红包 红包奖励数量:已发个数
|
||||||
|
Ts int64 // 更新时间戳
|
||||||
|
}
|
||||||
|
|
||||||
|
func (r *RedPacket) DatabaseName() string {
|
||||||
|
return "log"
|
||||||
|
}
|
||||||
|
|
||||||
|
func (r *RedPacket) CollectionName() string {
|
||||||
|
return "log_redpacket"
|
||||||
|
}
|
||||||
|
|
||||||
|
func GetRedPacketAll(plt string) (res []*RedPacket, err error) {
|
||||||
|
if rpcCli == nil {
|
||||||
|
logger.Logger.Error("model.GetRedPacketAll rpcCli == nil")
|
||||||
|
return nil, errors.New("rpc client is nil")
|
||||||
|
}
|
||||||
|
|
||||||
|
err = rpcCli.CallWithTimeout("RedPacketSvc.GetAll", &plt, &res, time.Second*30)
|
||||||
|
if err != nil {
|
||||||
|
logger.Logger.Errorf("GetRedPacketAll error: %v", err)
|
||||||
|
return nil, err
|
||||||
|
}
|
||||||
|
|
||||||
|
return res, nil
|
||||||
|
}
|
||||||
|
|
||||||
|
func UpdateRedPacketAll(plt string, list []*RedPacket) error {
|
||||||
|
if rpcCli == nil {
|
||||||
|
logger.Logger.Error("model.UpdateRedPacketAll rpcCli == nil")
|
||||||
|
return errors.New("rpc client is nil")
|
||||||
|
}
|
||||||
|
|
||||||
|
err := rpcCli.CallWithTimeout("RedPacketSvc.UpdateAll", &plt, &list, time.Second*30)
|
||||||
|
if err != nil {
|
||||||
|
logger.Logger.Errorf("UpdateRedPacketAll error: %v", err)
|
||||||
|
return err
|
||||||
|
}
|
||||||
|
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
@ -76,6 +76,7 @@ type RegisterHandlerParam struct {
|
||||||
}
|
}
|
||||||
|
|
||||||
// RegisterHandler 注册消息处理函数
|
// RegisterHandler 注册消息处理函数
|
||||||
|
// 必须在init()函数中调用
|
||||||
func (c *MessageMgr) RegisterHandler(param *RegisterHandlerParam) {
|
func (c *MessageMgr) RegisterHandler(param *RegisterHandlerParam) {
|
||||||
if param == nil {
|
if param == nil {
|
||||||
return
|
return
|
||||||
|
|
@ -143,6 +144,7 @@ func WriteWithOptions(data interface{}, name string, opts ...broker.PublishOptio
|
||||||
}
|
}
|
||||||
|
|
||||||
// RegisterHandler 注册消息处理函数
|
// RegisterHandler 注册消息处理函数
|
||||||
|
// 必须在init()函数中调用
|
||||||
func RegisterHandler(param *RegisterHandlerParam) {
|
func RegisterHandler(param *RegisterHandlerParam) {
|
||||||
MessageMgrSingle.RegisterHandler(param)
|
MessageMgrSingle.RegisterHandler(param)
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -9860,6 +9860,244 @@ func (x *GamePigBankPropConfig) GetPropInfo() []*PigBankPropInfo {
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// etcd /game/act_redpacket
|
||||||
|
type RedPacketConfig struct {
|
||||||
|
state protoimpl.MessageState
|
||||||
|
sizeCache protoimpl.SizeCache
|
||||||
|
unknownFields protoimpl.UnknownFields
|
||||||
|
|
||||||
|
Platform string `protobuf:"bytes,1,opt,name=Platform,proto3" json:"Platform,omitempty"` // 平台
|
||||||
|
List []*RedPacketInfo `protobuf:"bytes,4,rep,name=List,proto3" json:"List,omitempty"` // 活动列表
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *RedPacketConfig) Reset() {
|
||||||
|
*x = RedPacketConfig{}
|
||||||
|
if protoimpl.UnsafeEnabled {
|
||||||
|
mi := &file_protocol_webapi_common_proto_msgTypes[104]
|
||||||
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
|
ms.StoreMessageInfo(mi)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *RedPacketConfig) String() string {
|
||||||
|
return protoimpl.X.MessageStringOf(x)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (*RedPacketConfig) ProtoMessage() {}
|
||||||
|
|
||||||
|
func (x *RedPacketConfig) ProtoReflect() protoreflect.Message {
|
||||||
|
mi := &file_protocol_webapi_common_proto_msgTypes[104]
|
||||||
|
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 RedPacketConfig.ProtoReflect.Descriptor instead.
|
||||||
|
func (*RedPacketConfig) Descriptor() ([]byte, []int) {
|
||||||
|
return file_protocol_webapi_common_proto_rawDescGZIP(), []int{104}
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *RedPacketConfig) GetPlatform() string {
|
||||||
|
if x != nil {
|
||||||
|
return x.Platform
|
||||||
|
}
|
||||||
|
return ""
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *RedPacketConfig) GetList() []*RedPacketInfo {
|
||||||
|
if x != nil {
|
||||||
|
return x.List
|
||||||
|
}
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
||||||
|
type RedPacketInfo struct {
|
||||||
|
state protoimpl.MessageState
|
||||||
|
sizeCache protoimpl.SizeCache
|
||||||
|
unknownFields protoimpl.UnknownFields
|
||||||
|
|
||||||
|
Id int64 `protobuf:"varint,1,opt,name=Id,proto3" json:"Id,omitempty"` // 配置id
|
||||||
|
On int32 `protobuf:"varint,2,opt,name=On,proto3" json:"On,omitempty"` // 开关 1开启 2关闭
|
||||||
|
StartHMS int64 `protobuf:"varint,3,opt,name=StartHMS,proto3" json:"StartHMS,omitempty"` // 开始时间,时*10000 + 分*100 + 秒
|
||||||
|
EndHMS int64 `protobuf:"varint,4,opt,name=EndHMS,proto3" json:"EndHMS,omitempty"` // 结束时间,时*10000 + 分*100 + 秒
|
||||||
|
StayTs int64 `protobuf:"varint,5,opt,name=StayTs,proto3" json:"StayTs,omitempty"` // 持续时长,单位秒
|
||||||
|
MaxCount int64 `protobuf:"varint,6,opt,name=MaxCount,proto3" json:"MaxCount,omitempty"` // 每人最大领取次数 0无限制
|
||||||
|
LessCount int64 `protobuf:"varint,7,opt,name=LessCount,proto3" json:"LessCount,omitempty"` // 保底红包个数
|
||||||
|
ItemId int32 `protobuf:"varint,8,opt,name=ItemId,proto3" json:"ItemId,omitempty"` // 奖励类型(道具id,100001金币 100002钻石)
|
||||||
|
TotalNum int64 `protobuf:"varint,9,opt,name=TotalNum,proto3" json:"TotalNum,omitempty"` // 总奖励数量
|
||||||
|
RedList []*RedInfo `protobuf:"bytes,10,rep,name=RedList,proto3" json:"RedList,omitempty"` // 红包奖励列表
|
||||||
|
PlayerLimit int32 `protobuf:"varint,11,opt,name=PlayerLimit,proto3" json:"PlayerLimit,omitempty"` // 玩家最大领取红包次数 0无限制
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *RedPacketInfo) Reset() {
|
||||||
|
*x = RedPacketInfo{}
|
||||||
|
if protoimpl.UnsafeEnabled {
|
||||||
|
mi := &file_protocol_webapi_common_proto_msgTypes[105]
|
||||||
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
|
ms.StoreMessageInfo(mi)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *RedPacketInfo) String() string {
|
||||||
|
return protoimpl.X.MessageStringOf(x)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (*RedPacketInfo) ProtoMessage() {}
|
||||||
|
|
||||||
|
func (x *RedPacketInfo) ProtoReflect() protoreflect.Message {
|
||||||
|
mi := &file_protocol_webapi_common_proto_msgTypes[105]
|
||||||
|
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 RedPacketInfo.ProtoReflect.Descriptor instead.
|
||||||
|
func (*RedPacketInfo) Descriptor() ([]byte, []int) {
|
||||||
|
return file_protocol_webapi_common_proto_rawDescGZIP(), []int{105}
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *RedPacketInfo) GetId() int64 {
|
||||||
|
if x != nil {
|
||||||
|
return x.Id
|
||||||
|
}
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *RedPacketInfo) GetOn() int32 {
|
||||||
|
if x != nil {
|
||||||
|
return x.On
|
||||||
|
}
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *RedPacketInfo) GetStartHMS() int64 {
|
||||||
|
if x != nil {
|
||||||
|
return x.StartHMS
|
||||||
|
}
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *RedPacketInfo) GetEndHMS() int64 {
|
||||||
|
if x != nil {
|
||||||
|
return x.EndHMS
|
||||||
|
}
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *RedPacketInfo) GetStayTs() int64 {
|
||||||
|
if x != nil {
|
||||||
|
return x.StayTs
|
||||||
|
}
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *RedPacketInfo) GetMaxCount() int64 {
|
||||||
|
if x != nil {
|
||||||
|
return x.MaxCount
|
||||||
|
}
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *RedPacketInfo) GetLessCount() int64 {
|
||||||
|
if x != nil {
|
||||||
|
return x.LessCount
|
||||||
|
}
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *RedPacketInfo) GetItemId() int32 {
|
||||||
|
if x != nil {
|
||||||
|
return x.ItemId
|
||||||
|
}
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *RedPacketInfo) GetTotalNum() int64 {
|
||||||
|
if x != nil {
|
||||||
|
return x.TotalNum
|
||||||
|
}
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *RedPacketInfo) GetRedList() []*RedInfo {
|
||||||
|
if x != nil {
|
||||||
|
return x.RedList
|
||||||
|
}
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *RedPacketInfo) GetPlayerLimit() int32 {
|
||||||
|
if x != nil {
|
||||||
|
return x.PlayerLimit
|
||||||
|
}
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
|
||||||
|
type RedInfo struct {
|
||||||
|
state protoimpl.MessageState
|
||||||
|
sizeCache protoimpl.SizeCache
|
||||||
|
unknownFields protoimpl.UnknownFields
|
||||||
|
|
||||||
|
Num int64 `protobuf:"varint,1,opt,name=Num,proto3" json:"Num,omitempty"` // 数量
|
||||||
|
Rate int64 `protobuf:"varint,2,opt,name=Rate,proto3" json:"Rate,omitempty"` // 概率,百分比
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *RedInfo) Reset() {
|
||||||
|
*x = RedInfo{}
|
||||||
|
if protoimpl.UnsafeEnabled {
|
||||||
|
mi := &file_protocol_webapi_common_proto_msgTypes[106]
|
||||||
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
|
ms.StoreMessageInfo(mi)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *RedInfo) String() string {
|
||||||
|
return protoimpl.X.MessageStringOf(x)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (*RedInfo) ProtoMessage() {}
|
||||||
|
|
||||||
|
func (x *RedInfo) ProtoReflect() protoreflect.Message {
|
||||||
|
mi := &file_protocol_webapi_common_proto_msgTypes[106]
|
||||||
|
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 RedInfo.ProtoReflect.Descriptor instead.
|
||||||
|
func (*RedInfo) Descriptor() ([]byte, []int) {
|
||||||
|
return file_protocol_webapi_common_proto_rawDescGZIP(), []int{106}
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *RedInfo) GetNum() int64 {
|
||||||
|
if x != nil {
|
||||||
|
return x.Num
|
||||||
|
}
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *RedInfo) GetRate() int64 {
|
||||||
|
if x != nil {
|
||||||
|
return x.Rate
|
||||||
|
}
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
|
||||||
var File_protocol_webapi_common_proto protoreflect.FileDescriptor
|
var File_protocol_webapi_common_proto protoreflect.FileDescriptor
|
||||||
|
|
||||||
var file_protocol_webapi_common_proto_rawDesc = []byte{
|
var file_protocol_webapi_common_proto_rawDesc = []byte{
|
||||||
|
|
@ -11387,10 +11625,38 @@ var file_protocol_webapi_common_proto_rawDesc = []byte{
|
||||||
0x72, 0x6d, 0x12, 0x33, 0x0a, 0x08, 0x50, 0x72, 0x6f, 0x70, 0x49, 0x6e, 0x66, 0x6f, 0x18, 0x02,
|
0x72, 0x6d, 0x12, 0x33, 0x0a, 0x08, 0x50, 0x72, 0x6f, 0x70, 0x49, 0x6e, 0x66, 0x6f, 0x18, 0x02,
|
||||||
0x20, 0x03, 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x77, 0x65, 0x62, 0x61, 0x70, 0x69, 0x2e, 0x50, 0x69,
|
0x20, 0x03, 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x77, 0x65, 0x62, 0x61, 0x70, 0x69, 0x2e, 0x50, 0x69,
|
||||||
0x67, 0x42, 0x61, 0x6e, 0x6b, 0x50, 0x72, 0x6f, 0x70, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x08, 0x50,
|
0x67, 0x42, 0x61, 0x6e, 0x6b, 0x50, 0x72, 0x6f, 0x70, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x08, 0x50,
|
||||||
0x72, 0x6f, 0x70, 0x49, 0x6e, 0x66, 0x6f, 0x42, 0x26, 0x5a, 0x24, 0x6d, 0x6f, 0x6e, 0x67, 0x6f,
|
0x72, 0x6f, 0x70, 0x49, 0x6e, 0x66, 0x6f, 0x22, 0x58, 0x0a, 0x0f, 0x52, 0x65, 0x64, 0x50, 0x61,
|
||||||
0x2e, 0x67, 0x61, 0x6d, 0x65, 0x73, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x67, 0x61, 0x6d, 0x65, 0x2f,
|
0x63, 0x6b, 0x65, 0x74, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x6c,
|
||||||
0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x2f, 0x77, 0x65, 0x62, 0x61, 0x70, 0x69, 0x62,
|
0x61, 0x74, 0x66, 0x6f, 0x72, 0x6d, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, 0x6c,
|
||||||
0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
|
0x61, 0x74, 0x66, 0x6f, 0x72, 0x6d, 0x12, 0x29, 0x0a, 0x04, 0x4c, 0x69, 0x73, 0x74, 0x18, 0x04,
|
||||||
|
0x20, 0x03, 0x28, 0x0b, 0x32, 0x15, 0x2e, 0x77, 0x65, 0x62, 0x61, 0x70, 0x69, 0x2e, 0x52, 0x65,
|
||||||
|
0x64, 0x50, 0x61, 0x63, 0x6b, 0x65, 0x74, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x04, 0x4c, 0x69, 0x73,
|
||||||
|
0x74, 0x22, 0xb6, 0x02, 0x0a, 0x0d, 0x52, 0x65, 0x64, 0x50, 0x61, 0x63, 0x6b, 0x65, 0x74, 0x49,
|
||||||
|
0x6e, 0x66, 0x6f, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52,
|
||||||
|
0x02, 0x49, 0x64, 0x12, 0x0e, 0x0a, 0x02, 0x4f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52,
|
||||||
|
0x02, 0x4f, 0x6e, 0x12, 0x1a, 0x0a, 0x08, 0x53, 0x74, 0x61, 0x72, 0x74, 0x48, 0x4d, 0x53, 0x18,
|
||||||
|
0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x53, 0x74, 0x61, 0x72, 0x74, 0x48, 0x4d, 0x53, 0x12,
|
||||||
|
0x16, 0x0a, 0x06, 0x45, 0x6e, 0x64, 0x48, 0x4d, 0x53, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52,
|
||||||
|
0x06, 0x45, 0x6e, 0x64, 0x48, 0x4d, 0x53, 0x12, 0x16, 0x0a, 0x06, 0x53, 0x74, 0x61, 0x79, 0x54,
|
||||||
|
0x73, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x53, 0x74, 0x61, 0x79, 0x54, 0x73, 0x12,
|
||||||
|
0x1a, 0x0a, 0x08, 0x4d, 0x61, 0x78, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x06, 0x20, 0x01, 0x28,
|
||||||
|
0x03, 0x52, 0x08, 0x4d, 0x61, 0x78, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x4c,
|
||||||
|
0x65, 0x73, 0x73, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x07, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09,
|
||||||
|
0x4c, 0x65, 0x73, 0x73, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x16, 0x0a, 0x06, 0x49, 0x74, 0x65,
|
||||||
|
0x6d, 0x49, 0x64, 0x18, 0x08, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06, 0x49, 0x74, 0x65, 0x6d, 0x49,
|
||||||
|
0x64, 0x12, 0x1a, 0x0a, 0x08, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x4e, 0x75, 0x6d, 0x18, 0x09, 0x20,
|
||||||
|
0x01, 0x28, 0x03, 0x52, 0x08, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x4e, 0x75, 0x6d, 0x12, 0x29, 0x0a,
|
||||||
|
0x07, 0x52, 0x65, 0x64, 0x4c, 0x69, 0x73, 0x74, 0x18, 0x0a, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0f,
|
||||||
|
0x2e, 0x77, 0x65, 0x62, 0x61, 0x70, 0x69, 0x2e, 0x52, 0x65, 0x64, 0x49, 0x6e, 0x66, 0x6f, 0x52,
|
||||||
|
0x07, 0x52, 0x65, 0x64, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x20, 0x0a, 0x0b, 0x50, 0x6c, 0x61, 0x79,
|
||||||
|
0x65, 0x72, 0x4c, 0x69, 0x6d, 0x69, 0x74, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0b, 0x50,
|
||||||
|
0x6c, 0x61, 0x79, 0x65, 0x72, 0x4c, 0x69, 0x6d, 0x69, 0x74, 0x22, 0x2f, 0x0a, 0x07, 0x52, 0x65,
|
||||||
|
0x64, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x10, 0x0a, 0x03, 0x4e, 0x75, 0x6d, 0x18, 0x01, 0x20, 0x01,
|
||||||
|
0x28, 0x03, 0x52, 0x03, 0x4e, 0x75, 0x6d, 0x12, 0x12, 0x0a, 0x04, 0x52, 0x61, 0x74, 0x65, 0x18,
|
||||||
|
0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x52, 0x61, 0x74, 0x65, 0x42, 0x26, 0x5a, 0x24, 0x6d,
|
||||||
|
0x6f, 0x6e, 0x67, 0x6f, 0x2e, 0x67, 0x61, 0x6d, 0x65, 0x73, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x67,
|
||||||
|
0x61, 0x6d, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x2f, 0x77, 0x65, 0x62,
|
||||||
|
0x61, 0x70, 0x69, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
|
||||||
}
|
}
|
||||||
|
|
||||||
var (
|
var (
|
||||||
|
|
@ -11405,7 +11671,7 @@ func file_protocol_webapi_common_proto_rawDescGZIP() []byte {
|
||||||
return file_protocol_webapi_common_proto_rawDescData
|
return file_protocol_webapi_common_proto_rawDescData
|
||||||
}
|
}
|
||||||
|
|
||||||
var file_protocol_webapi_common_proto_msgTypes = make([]protoimpl.MessageInfo, 114)
|
var file_protocol_webapi_common_proto_msgTypes = make([]protoimpl.MessageInfo, 117)
|
||||||
var file_protocol_webapi_common_proto_goTypes = []interface{}{
|
var file_protocol_webapi_common_proto_goTypes = []interface{}{
|
||||||
(*MysqlDbSetting)(nil), // 0: webapi.MysqlDbSetting
|
(*MysqlDbSetting)(nil), // 0: webapi.MysqlDbSetting
|
||||||
(*MongoDbSetting)(nil), // 1: webapi.MongoDbSetting
|
(*MongoDbSetting)(nil), // 1: webapi.MongoDbSetting
|
||||||
|
|
@ -11511,32 +11777,35 @@ var file_protocol_webapi_common_proto_goTypes = []interface{}{
|
||||||
(*GamePigBankDiamondConfig)(nil), // 101: webapi.GamePigBankDiamondConfig
|
(*GamePigBankDiamondConfig)(nil), // 101: webapi.GamePigBankDiamondConfig
|
||||||
(*PigBankPropInfo)(nil), // 102: webapi.PigBankPropInfo
|
(*PigBankPropInfo)(nil), // 102: webapi.PigBankPropInfo
|
||||||
(*GamePigBankPropConfig)(nil), // 103: webapi.GamePigBankPropConfig
|
(*GamePigBankPropConfig)(nil), // 103: webapi.GamePigBankPropConfig
|
||||||
nil, // 104: webapi.Platform.BindTelRewardEntry
|
(*RedPacketConfig)(nil), // 104: webapi.RedPacketConfig
|
||||||
nil, // 105: webapi.PlayerData.RankScoreEntry
|
(*RedPacketInfo)(nil), // 105: webapi.RedPacketInfo
|
||||||
nil, // 106: webapi.ItemShop.AwardEntry
|
(*RedInfo)(nil), // 106: webapi.RedInfo
|
||||||
nil, // 107: webapi.VIPcfg.AwardEntry
|
nil, // 107: webapi.Platform.BindTelRewardEntry
|
||||||
nil, // 108: webapi.VIPcfg.Privilege1Entry
|
nil, // 108: webapi.PlayerData.RankScoreEntry
|
||||||
nil, // 109: webapi.VIPcfg.Privilege7Entry
|
nil, // 109: webapi.ItemShop.AwardEntry
|
||||||
nil, // 110: webapi.VIPcfg.Privilege9Entry
|
nil, // 110: webapi.VIPcfg.AwardEntry
|
||||||
nil, // 111: webapi.ActInviteConfig.PayScoreEntry
|
nil, // 111: webapi.VIPcfg.Privilege1Entry
|
||||||
nil, // 112: webapi.SkinLevel.UpItemEntry
|
nil, // 112: webapi.VIPcfg.Privilege7Entry
|
||||||
nil, // 113: webapi.SkinItem.UnlockParamEntry
|
nil, // 113: webapi.VIPcfg.Privilege9Entry
|
||||||
(*server.DB_GameFree)(nil), // 114: server.DB_GameFree
|
nil, // 114: webapi.ActInviteConfig.PayScoreEntry
|
||||||
(*server.DB_GameItem)(nil), // 115: server.DB_GameItem
|
nil, // 115: webapi.SkinLevel.UpItemEntry
|
||||||
|
nil, // 116: webapi.SkinItem.UnlockParamEntry
|
||||||
|
(*server.DB_GameFree)(nil), // 117: server.DB_GameFree
|
||||||
|
(*server.DB_GameItem)(nil), // 118: server.DB_GameItem
|
||||||
}
|
}
|
||||||
var file_protocol_webapi_common_proto_depIdxs = []int32{
|
var file_protocol_webapi_common_proto_depIdxs = []int32{
|
||||||
2, // 0: webapi.Platform.Leaderboard:type_name -> webapi.RankSwitch
|
2, // 0: webapi.Platform.Leaderboard:type_name -> webapi.RankSwitch
|
||||||
3, // 1: webapi.Platform.ClubConfig:type_name -> webapi.ClubConfig
|
3, // 1: webapi.Platform.ClubConfig:type_name -> webapi.ClubConfig
|
||||||
4, // 2: webapi.Platform.ThirdGameMerchant:type_name -> webapi.ThirdGame
|
4, // 2: webapi.Platform.ThirdGameMerchant:type_name -> webapi.ThirdGame
|
||||||
104, // 3: webapi.Platform.BindTelReward:type_name -> webapi.Platform.BindTelRewardEntry
|
107, // 3: webapi.Platform.BindTelReward:type_name -> webapi.Platform.BindTelRewardEntry
|
||||||
6, // 4: webapi.GameConfigGlobal.GameStatus:type_name -> webapi.GameStatus
|
6, // 4: webapi.GameConfigGlobal.GameStatus:type_name -> webapi.GameStatus
|
||||||
114, // 5: webapi.GameFree.DbGameFree:type_name -> server.DB_GameFree
|
117, // 5: webapi.GameFree.DbGameFree:type_name -> server.DB_GameFree
|
||||||
8, // 6: webapi.PlatformGameConfig.DbGameFrees:type_name -> webapi.GameFree
|
8, // 6: webapi.PlatformGameConfig.DbGameFrees:type_name -> webapi.GameFree
|
||||||
0, // 7: webapi.PlatformDbConfig.Mysql:type_name -> webapi.MysqlDbSetting
|
0, // 7: webapi.PlatformDbConfig.Mysql:type_name -> webapi.MysqlDbSetting
|
||||||
1, // 8: webapi.PlatformDbConfig.MongoDb:type_name -> webapi.MongoDbSetting
|
1, // 8: webapi.PlatformDbConfig.MongoDb:type_name -> webapi.MongoDbSetting
|
||||||
1, // 9: webapi.PlatformDbConfig.MongoDbLog:type_name -> webapi.MongoDbSetting
|
1, // 9: webapi.PlatformDbConfig.MongoDbLog:type_name -> webapi.MongoDbSetting
|
||||||
114, // 10: webapi.GameConfigGroup.DbGameFree:type_name -> server.DB_GameFree
|
117, // 10: webapi.GameConfigGroup.DbGameFree:type_name -> server.DB_GameFree
|
||||||
105, // 11: webapi.PlayerData.RankScore:type_name -> webapi.PlayerData.RankScoreEntry
|
108, // 11: webapi.PlayerData.RankScore:type_name -> webapi.PlayerData.RankScoreEntry
|
||||||
32, // 12: webapi.PlayerData.Items:type_name -> webapi.ItemInfo
|
32, // 12: webapi.PlayerData.Items:type_name -> webapi.ItemInfo
|
||||||
14, // 13: webapi.PlayerData.RoleUnlockList:type_name -> webapi.ModInfo
|
14, // 13: webapi.PlayerData.RoleUnlockList:type_name -> webapi.ModInfo
|
||||||
14, // 14: webapi.PlayerData.PetUnlockList:type_name -> webapi.ModInfo
|
14, // 14: webapi.PlayerData.PetUnlockList:type_name -> webapi.ModInfo
|
||||||
|
|
@ -11549,7 +11818,7 @@ var file_protocol_webapi_common_proto_depIdxs = []int32{
|
||||||
32, // 21: webapi.ExchangeShop.Items:type_name -> webapi.ItemInfo
|
32, // 21: webapi.ExchangeShop.Items:type_name -> webapi.ItemInfo
|
||||||
25, // 22: webapi.ExchangeShopList.List:type_name -> webapi.ExchangeShop
|
25, // 22: webapi.ExchangeShopList.List:type_name -> webapi.ExchangeShop
|
||||||
29, // 23: webapi.ExchangeShopList.Weight:type_name -> webapi.ShopWeight
|
29, // 23: webapi.ExchangeShopList.Weight:type_name -> webapi.ShopWeight
|
||||||
106, // 24: webapi.ItemShop.Award:type_name -> webapi.ItemShop.AwardEntry
|
109, // 24: webapi.ItemShop.Award:type_name -> webapi.ItemShop.AwardEntry
|
||||||
30, // 25: webapi.ItemShopList.List:type_name -> webapi.ItemShop
|
30, // 25: webapi.ItemShopList.List:type_name -> webapi.ItemShop
|
||||||
32, // 26: webapi.MatchInfoAward.ItemId:type_name -> webapi.ItemInfo
|
32, // 26: webapi.MatchInfoAward.ItemId:type_name -> webapi.ItemInfo
|
||||||
33, // 27: webapi.GameMatchDate.Award:type_name -> webapi.MatchInfoAward
|
33, // 27: webapi.GameMatchDate.Award:type_name -> webapi.MatchInfoAward
|
||||||
|
|
@ -11570,14 +11839,14 @@ var file_protocol_webapi_common_proto_depIdxs = []int32{
|
||||||
38, // 42: webapi.WelfareSpree.Item:type_name -> webapi.WelfareDate
|
38, // 42: webapi.WelfareSpree.Item:type_name -> webapi.WelfareDate
|
||||||
48, // 43: webapi.WelfareFirstPayDataList.List:type_name -> webapi.WelfareSpree
|
48, // 43: webapi.WelfareFirstPayDataList.List:type_name -> webapi.WelfareSpree
|
||||||
48, // 44: webapi.WelfareContinuousPayDataList.List:type_name -> webapi.WelfareSpree
|
48, // 44: webapi.WelfareContinuousPayDataList.List:type_name -> webapi.WelfareSpree
|
||||||
107, // 45: webapi.VIPcfg.Award:type_name -> webapi.VIPcfg.AwardEntry
|
110, // 45: webapi.VIPcfg.Award:type_name -> webapi.VIPcfg.AwardEntry
|
||||||
108, // 46: webapi.VIPcfg.Privilege1:type_name -> webapi.VIPcfg.Privilege1Entry
|
111, // 46: webapi.VIPcfg.Privilege1:type_name -> webapi.VIPcfg.Privilege1Entry
|
||||||
109, // 47: webapi.VIPcfg.Privilege7:type_name -> webapi.VIPcfg.Privilege7Entry
|
112, // 47: webapi.VIPcfg.Privilege7:type_name -> webapi.VIPcfg.Privilege7Entry
|
||||||
110, // 48: webapi.VIPcfg.Privilege9:type_name -> webapi.VIPcfg.Privilege9Entry
|
113, // 48: webapi.VIPcfg.Privilege9:type_name -> webapi.VIPcfg.Privilege9Entry
|
||||||
51, // 49: webapi.VIPcfgDataList.List:type_name -> webapi.VIPcfg
|
51, // 49: webapi.VIPcfgDataList.List:type_name -> webapi.VIPcfg
|
||||||
38, // 50: webapi.ChessRankConfig.Item:type_name -> webapi.WelfareDate
|
38, // 50: webapi.ChessRankConfig.Item:type_name -> webapi.WelfareDate
|
||||||
55, // 51: webapi.ChessRankcfgData.Datas:type_name -> webapi.ChessRankConfig
|
55, // 51: webapi.ChessRankcfgData.Datas:type_name -> webapi.ChessRankConfig
|
||||||
111, // 52: webapi.ActInviteConfig.PayScore:type_name -> webapi.ActInviteConfig.PayScoreEntry
|
114, // 52: webapi.ActInviteConfig.PayScore:type_name -> webapi.ActInviteConfig.PayScoreEntry
|
||||||
62, // 53: webapi.ActInviteConfig.Awards1:type_name -> webapi.RankAward
|
62, // 53: webapi.ActInviteConfig.Awards1:type_name -> webapi.RankAward
|
||||||
62, // 54: webapi.ActInviteConfig.Awards2:type_name -> webapi.RankAward
|
62, // 54: webapi.ActInviteConfig.Awards2:type_name -> webapi.RankAward
|
||||||
62, // 55: webapi.ActInviteConfig.Awards3:type_name -> webapi.RankAward
|
62, // 55: webapi.ActInviteConfig.Awards3:type_name -> webapi.RankAward
|
||||||
|
|
@ -11594,12 +11863,12 @@ var file_protocol_webapi_common_proto_depIdxs = []int32{
|
||||||
69, // 66: webapi.DiamondLotteryData.Info:type_name -> webapi.DiamondLotteryInfo
|
69, // 66: webapi.DiamondLotteryData.Info:type_name -> webapi.DiamondLotteryInfo
|
||||||
70, // 67: webapi.DiamondLotteryData.Players:type_name -> webapi.DiamondLotteryPlayers
|
70, // 67: webapi.DiamondLotteryData.Players:type_name -> webapi.DiamondLotteryPlayers
|
||||||
72, // 68: webapi.DiamondLotteryConfig.LotteryData:type_name -> webapi.DiamondLotteryData
|
72, // 68: webapi.DiamondLotteryConfig.LotteryData:type_name -> webapi.DiamondLotteryData
|
||||||
115, // 69: webapi.ItemConfig.Items:type_name -> server.DB_GameItem
|
118, // 69: webapi.ItemConfig.Items:type_name -> server.DB_GameItem
|
||||||
32, // 70: webapi.RankAwardInfo.Item:type_name -> webapi.ItemInfo
|
32, // 70: webapi.RankAwardInfo.Item:type_name -> webapi.ItemInfo
|
||||||
75, // 71: webapi.RankTypeInfo.Award:type_name -> webapi.RankAwardInfo
|
75, // 71: webapi.RankTypeInfo.Award:type_name -> webapi.RankAwardInfo
|
||||||
76, // 72: webapi.RankTypeConfig.Info:type_name -> webapi.RankTypeInfo
|
76, // 72: webapi.RankTypeConfig.Info:type_name -> webapi.RankTypeInfo
|
||||||
112, // 73: webapi.SkinLevel.UpItem:type_name -> webapi.SkinLevel.UpItemEntry
|
115, // 73: webapi.SkinLevel.UpItem:type_name -> webapi.SkinLevel.UpItemEntry
|
||||||
113, // 74: webapi.SkinItem.UnlockParam:type_name -> webapi.SkinItem.UnlockParamEntry
|
116, // 74: webapi.SkinItem.UnlockParam:type_name -> webapi.SkinItem.UnlockParamEntry
|
||||||
78, // 75: webapi.SkinItem.Levels:type_name -> webapi.SkinLevel
|
78, // 75: webapi.SkinItem.Levels:type_name -> webapi.SkinLevel
|
||||||
79, // 76: webapi.SkinConfig.Items:type_name -> webapi.SkinItem
|
79, // 76: webapi.SkinConfig.Items:type_name -> webapi.SkinItem
|
||||||
82, // 77: webapi.AwardLogConfig.AwardLog:type_name -> webapi.AwardLogData
|
82, // 77: webapi.AwardLogConfig.AwardLog:type_name -> webapi.AwardLogData
|
||||||
|
|
@ -11618,11 +11887,13 @@ var file_protocol_webapi_common_proto_depIdxs = []int32{
|
||||||
32, // 90: webapi.PigBankDiamondInfo.DiamondExc:type_name -> webapi.ItemInfo
|
32, // 90: webapi.PigBankDiamondInfo.DiamondExc:type_name -> webapi.ItemInfo
|
||||||
100, // 91: webapi.GamePigBankDiamondConfig.DiamondInfo:type_name -> webapi.PigBankDiamondInfo
|
100, // 91: webapi.GamePigBankDiamondConfig.DiamondInfo:type_name -> webapi.PigBankDiamondInfo
|
||||||
102, // 92: webapi.GamePigBankPropConfig.PropInfo:type_name -> webapi.PigBankPropInfo
|
102, // 92: webapi.GamePigBankPropConfig.PropInfo:type_name -> webapi.PigBankPropInfo
|
||||||
93, // [93:93] is the sub-list for method output_type
|
105, // 93: webapi.RedPacketConfig.List:type_name -> webapi.RedPacketInfo
|
||||||
93, // [93:93] is the sub-list for method input_type
|
106, // 94: webapi.RedPacketInfo.RedList:type_name -> webapi.RedInfo
|
||||||
93, // [93:93] is the sub-list for extension type_name
|
95, // [95:95] is the sub-list for method output_type
|
||||||
93, // [93:93] is the sub-list for extension extendee
|
95, // [95:95] is the sub-list for method input_type
|
||||||
0, // [0:93] is the sub-list for field type_name
|
95, // [95:95] is the sub-list for extension type_name
|
||||||
|
95, // [95:95] is the sub-list for extension extendee
|
||||||
|
0, // [0:95] is the sub-list for field type_name
|
||||||
}
|
}
|
||||||
|
|
||||||
func init() { file_protocol_webapi_common_proto_init() }
|
func init() { file_protocol_webapi_common_proto_init() }
|
||||||
|
|
@ -12879,6 +13150,42 @@ func file_protocol_webapi_common_proto_init() {
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
file_protocol_webapi_common_proto_msgTypes[104].Exporter = func(v interface{}, i int) interface{} {
|
||||||
|
switch v := v.(*RedPacketConfig); i {
|
||||||
|
case 0:
|
||||||
|
return &v.state
|
||||||
|
case 1:
|
||||||
|
return &v.sizeCache
|
||||||
|
case 2:
|
||||||
|
return &v.unknownFields
|
||||||
|
default:
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
}
|
||||||
|
file_protocol_webapi_common_proto_msgTypes[105].Exporter = func(v interface{}, i int) interface{} {
|
||||||
|
switch v := v.(*RedPacketInfo); i {
|
||||||
|
case 0:
|
||||||
|
return &v.state
|
||||||
|
case 1:
|
||||||
|
return &v.sizeCache
|
||||||
|
case 2:
|
||||||
|
return &v.unknownFields
|
||||||
|
default:
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
}
|
||||||
|
file_protocol_webapi_common_proto_msgTypes[106].Exporter = func(v interface{}, i int) interface{} {
|
||||||
|
switch v := v.(*RedInfo); i {
|
||||||
|
case 0:
|
||||||
|
return &v.state
|
||||||
|
case 1:
|
||||||
|
return &v.sizeCache
|
||||||
|
case 2:
|
||||||
|
return &v.unknownFields
|
||||||
|
default:
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
type x struct{}
|
type x struct{}
|
||||||
out := protoimpl.TypeBuilder{
|
out := protoimpl.TypeBuilder{
|
||||||
|
|
@ -12886,7 +13193,7 @@ func file_protocol_webapi_common_proto_init() {
|
||||||
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
||||||
RawDescriptor: file_protocol_webapi_common_proto_rawDesc,
|
RawDescriptor: file_protocol_webapi_common_proto_rawDesc,
|
||||||
NumEnums: 0,
|
NumEnums: 0,
|
||||||
NumMessages: 114,
|
NumMessages: 117,
|
||||||
NumExtensions: 0,
|
NumExtensions: 0,
|
||||||
NumServices: 0,
|
NumServices: 0,
|
||||||
},
|
},
|
||||||
|
|
|
||||||
|
|
@ -1096,4 +1096,29 @@ message PigBankPropInfo {
|
||||||
message GamePigBankPropConfig{
|
message GamePigBankPropConfig{
|
||||||
string Platform = 1; // 平台
|
string Platform = 1; // 平台
|
||||||
repeated PigBankPropInfo PropInfo = 2; // 存钱罐属性
|
repeated PigBankPropInfo PropInfo = 2; // 存钱罐属性
|
||||||
|
}
|
||||||
|
|
||||||
|
// etcd /game/act_redpacket
|
||||||
|
message RedPacketConfig{
|
||||||
|
string Platform = 1; // 平台
|
||||||
|
repeated RedPacketInfo List = 4; // 活动列表
|
||||||
|
}
|
||||||
|
|
||||||
|
message RedPacketInfo{
|
||||||
|
int64 Id = 1; // 配置id
|
||||||
|
int32 On = 2; // 开关 1开启 2关闭
|
||||||
|
int64 StartHMS = 3; // 开始时间,时*10000 + 分*100 + 秒
|
||||||
|
int64 EndHMS = 4; // 结束时间,时*10000 + 分*100 + 秒
|
||||||
|
int64 StayTs = 5; // 持续时长,单位秒
|
||||||
|
int64 MaxCount = 6; // 每人最大领取次数 0无限制
|
||||||
|
int64 LessCount = 7; // 保底红包个数
|
||||||
|
int32 ItemId = 8; // 奖励类型(道具id,100001金币 100002钻石)
|
||||||
|
int64 TotalNum = 9; // 总奖励数量
|
||||||
|
repeated RedInfo RedList = 10; // 红包奖励列表
|
||||||
|
int32 PlayerLimit = 11; // 玩家最大领取红包次数 0无限制
|
||||||
|
}
|
||||||
|
|
||||||
|
message RedInfo{
|
||||||
|
int64 Num = 1; // 数量
|
||||||
|
int64 Rate = 2; // 概率,百分比
|
||||||
}
|
}
|
||||||
|
|
@ -168,6 +168,10 @@ const (
|
||||||
SPacketID_PACKET_SCLotteryInfo SPacketID = 2927 // 抽奖信息
|
SPacketID_PACKET_SCLotteryInfo SPacketID = 2927 // 抽奖信息
|
||||||
SPacketID_PACKET_NotifyLotteryAward SPacketID = 2928 // 通知抽奖中奖
|
SPacketID_PACKET_NotifyLotteryAward SPacketID = 2928 // 通知抽奖中奖
|
||||||
SPacketID_PACKET_NotifyLotteryCode SPacketID = 2929 // 通知获得抽奖号码
|
SPacketID_PACKET_NotifyLotteryCode SPacketID = 2929 // 通知获得抽奖号码
|
||||||
|
SPacketID_PACKET_CSRedPacketInfo SPacketID = 2930 // 红包信息
|
||||||
|
SPacketID_PACKET_SCRedPacketInfo SPacketID = 2931 // 红包信息
|
||||||
|
SPacketID_PACKET_CSRedPacketDraw SPacketID = 2932 // 抽红包
|
||||||
|
SPacketID_PACKET_SCRedPacketDraw SPacketID = 2933 // 抽红包
|
||||||
)
|
)
|
||||||
|
|
||||||
// Enum value maps for SPacketID.
|
// Enum value maps for SPacketID.
|
||||||
|
|
@ -223,6 +227,10 @@ var (
|
||||||
2927: "PACKET_SCLotteryInfo",
|
2927: "PACKET_SCLotteryInfo",
|
||||||
2928: "PACKET_NotifyLotteryAward",
|
2928: "PACKET_NotifyLotteryAward",
|
||||||
2929: "PACKET_NotifyLotteryCode",
|
2929: "PACKET_NotifyLotteryCode",
|
||||||
|
2930: "PACKET_CSRedPacketInfo",
|
||||||
|
2931: "PACKET_SCRedPacketInfo",
|
||||||
|
2932: "PACKET_CSRedPacketDraw",
|
||||||
|
2933: "PACKET_SCRedPacketDraw",
|
||||||
}
|
}
|
||||||
SPacketID_value = map[string]int32{
|
SPacketID_value = map[string]int32{
|
||||||
"PACKET_SHOP_ZERO": 0,
|
"PACKET_SHOP_ZERO": 0,
|
||||||
|
|
@ -275,6 +283,10 @@ var (
|
||||||
"PACKET_SCLotteryInfo": 2927,
|
"PACKET_SCLotteryInfo": 2927,
|
||||||
"PACKET_NotifyLotteryAward": 2928,
|
"PACKET_NotifyLotteryAward": 2928,
|
||||||
"PACKET_NotifyLotteryCode": 2929,
|
"PACKET_NotifyLotteryCode": 2929,
|
||||||
|
"PACKET_CSRedPacketInfo": 2930,
|
||||||
|
"PACKET_SCRedPacketInfo": 2931,
|
||||||
|
"PACKET_CSRedPacketDraw": 2932,
|
||||||
|
"PACKET_SCRedPacketDraw": 2933,
|
||||||
}
|
}
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -4578,6 +4590,302 @@ func (x *NotifyLotteryCode) GetInfo() []*LotteryInfo {
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 红包信息
|
||||||
|
//PACKET_CSRedPacketInfo
|
||||||
|
type CSRedPacketInfo struct {
|
||||||
|
state protoimpl.MessageState
|
||||||
|
sizeCache protoimpl.SizeCache
|
||||||
|
unknownFields protoimpl.UnknownFields
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *CSRedPacketInfo) Reset() {
|
||||||
|
*x = CSRedPacketInfo{}
|
||||||
|
if protoimpl.UnsafeEnabled {
|
||||||
|
mi := &file_protocol_welfare_welfare_proto_msgTypes[67]
|
||||||
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
|
ms.StoreMessageInfo(mi)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *CSRedPacketInfo) String() string {
|
||||||
|
return protoimpl.X.MessageStringOf(x)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (*CSRedPacketInfo) ProtoMessage() {}
|
||||||
|
|
||||||
|
func (x *CSRedPacketInfo) ProtoReflect() protoreflect.Message {
|
||||||
|
mi := &file_protocol_welfare_welfare_proto_msgTypes[67]
|
||||||
|
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 CSRedPacketInfo.ProtoReflect.Descriptor instead.
|
||||||
|
func (*CSRedPacketInfo) Descriptor() ([]byte, []int) {
|
||||||
|
return file_protocol_welfare_welfare_proto_rawDescGZIP(), []int{67}
|
||||||
|
}
|
||||||
|
|
||||||
|
//PACKET_SCRedPacketInfo
|
||||||
|
type SCRedPacketInfo struct {
|
||||||
|
state protoimpl.MessageState
|
||||||
|
sizeCache protoimpl.SizeCache
|
||||||
|
unknownFields protoimpl.UnknownFields
|
||||||
|
|
||||||
|
Info []*RedPacketInfo `protobuf:"bytes,1,rep,name=Info,proto3" json:"Info,omitempty"` // 红包信息
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *SCRedPacketInfo) Reset() {
|
||||||
|
*x = SCRedPacketInfo{}
|
||||||
|
if protoimpl.UnsafeEnabled {
|
||||||
|
mi := &file_protocol_welfare_welfare_proto_msgTypes[68]
|
||||||
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
|
ms.StoreMessageInfo(mi)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *SCRedPacketInfo) String() string {
|
||||||
|
return protoimpl.X.MessageStringOf(x)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (*SCRedPacketInfo) ProtoMessage() {}
|
||||||
|
|
||||||
|
func (x *SCRedPacketInfo) ProtoReflect() protoreflect.Message {
|
||||||
|
mi := &file_protocol_welfare_welfare_proto_msgTypes[68]
|
||||||
|
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 SCRedPacketInfo.ProtoReflect.Descriptor instead.
|
||||||
|
func (*SCRedPacketInfo) Descriptor() ([]byte, []int) {
|
||||||
|
return file_protocol_welfare_welfare_proto_rawDescGZIP(), []int{68}
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *SCRedPacketInfo) GetInfo() []*RedPacketInfo {
|
||||||
|
if x != nil {
|
||||||
|
return x.Info
|
||||||
|
}
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
||||||
|
type RedPacketInfo struct {
|
||||||
|
state protoimpl.MessageState
|
||||||
|
sizeCache protoimpl.SizeCache
|
||||||
|
unknownFields protoimpl.UnknownFields
|
||||||
|
|
||||||
|
Id int64 `protobuf:"varint,1,opt,name=Id,proto3" json:"Id,omitempty"` // id
|
||||||
|
StartTs int64 `protobuf:"varint,2,opt,name=StartTs,proto3" json:"StartTs,omitempty"` // 开始时间
|
||||||
|
EndTs int64 `protobuf:"varint,3,opt,name=EndTs,proto3" json:"EndTs,omitempty"` // 结束时间
|
||||||
|
StayTs int64 `protobuf:"varint,4,opt,name=StayTs,proto3" json:"StayTs,omitempty"` // 持续时长,单位秒;0代表不限制
|
||||||
|
MaxCount int64 `protobuf:"varint,5,opt,name=MaxCount,proto3" json:"MaxCount,omitempty"` // 最大领取次数;-1代表不限制
|
||||||
|
RemainCount int64 `protobuf:"varint,6,opt,name=RemainCount,proto3" json:"RemainCount,omitempty"` // 剩余次数;-1代表不限制
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *RedPacketInfo) Reset() {
|
||||||
|
*x = RedPacketInfo{}
|
||||||
|
if protoimpl.UnsafeEnabled {
|
||||||
|
mi := &file_protocol_welfare_welfare_proto_msgTypes[69]
|
||||||
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
|
ms.StoreMessageInfo(mi)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *RedPacketInfo) String() string {
|
||||||
|
return protoimpl.X.MessageStringOf(x)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (*RedPacketInfo) ProtoMessage() {}
|
||||||
|
|
||||||
|
func (x *RedPacketInfo) ProtoReflect() protoreflect.Message {
|
||||||
|
mi := &file_protocol_welfare_welfare_proto_msgTypes[69]
|
||||||
|
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 RedPacketInfo.ProtoReflect.Descriptor instead.
|
||||||
|
func (*RedPacketInfo) Descriptor() ([]byte, []int) {
|
||||||
|
return file_protocol_welfare_welfare_proto_rawDescGZIP(), []int{69}
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *RedPacketInfo) GetId() int64 {
|
||||||
|
if x != nil {
|
||||||
|
return x.Id
|
||||||
|
}
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *RedPacketInfo) GetStartTs() int64 {
|
||||||
|
if x != nil {
|
||||||
|
return x.StartTs
|
||||||
|
}
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *RedPacketInfo) GetEndTs() int64 {
|
||||||
|
if x != nil {
|
||||||
|
return x.EndTs
|
||||||
|
}
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *RedPacketInfo) GetStayTs() int64 {
|
||||||
|
if x != nil {
|
||||||
|
return x.StayTs
|
||||||
|
}
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *RedPacketInfo) GetMaxCount() int64 {
|
||||||
|
if x != nil {
|
||||||
|
return x.MaxCount
|
||||||
|
}
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *RedPacketInfo) GetRemainCount() int64 {
|
||||||
|
if x != nil {
|
||||||
|
return x.RemainCount
|
||||||
|
}
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
|
||||||
|
// 抽红包
|
||||||
|
//PACKET_CSRedPacketDraw
|
||||||
|
type CSRedPacketDraw struct {
|
||||||
|
state protoimpl.MessageState
|
||||||
|
sizeCache protoimpl.SizeCache
|
||||||
|
unknownFields protoimpl.UnknownFields
|
||||||
|
|
||||||
|
Id int64 `protobuf:"varint,1,opt,name=Id,proto3" json:"Id,omitempty"` // id
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *CSRedPacketDraw) Reset() {
|
||||||
|
*x = CSRedPacketDraw{}
|
||||||
|
if protoimpl.UnsafeEnabled {
|
||||||
|
mi := &file_protocol_welfare_welfare_proto_msgTypes[70]
|
||||||
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
|
ms.StoreMessageInfo(mi)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *CSRedPacketDraw) String() string {
|
||||||
|
return protoimpl.X.MessageStringOf(x)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (*CSRedPacketDraw) ProtoMessage() {}
|
||||||
|
|
||||||
|
func (x *CSRedPacketDraw) ProtoReflect() protoreflect.Message {
|
||||||
|
mi := &file_protocol_welfare_welfare_proto_msgTypes[70]
|
||||||
|
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 CSRedPacketDraw.ProtoReflect.Descriptor instead.
|
||||||
|
func (*CSRedPacketDraw) Descriptor() ([]byte, []int) {
|
||||||
|
return file_protocol_welfare_welfare_proto_rawDescGZIP(), []int{70}
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *CSRedPacketDraw) GetId() int64 {
|
||||||
|
if x != nil {
|
||||||
|
return x.Id
|
||||||
|
}
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
|
||||||
|
//PACKET_SCRedPacketDraw
|
||||||
|
type SCRedPacketDraw struct {
|
||||||
|
state protoimpl.MessageState
|
||||||
|
sizeCache protoimpl.SizeCache
|
||||||
|
unknownFields protoimpl.UnknownFields
|
||||||
|
|
||||||
|
OpRetCode OpResultCode `protobuf:"varint,1,opt,name=OpRetCode,proto3,enum=welfare.OpResultCode" json:"OpRetCode,omitempty"` // 错误码
|
||||||
|
Id int64 `protobuf:"varint,2,opt,name=Id,proto3" json:"Id,omitempty"` // id
|
||||||
|
Award []*PropInfo `protobuf:"bytes,3,rep,name=Award,proto3" json:"Award,omitempty"` // 奖励
|
||||||
|
RemainCount int64 `protobuf:"varint,4,opt,name=RemainCount,proto3" json:"RemainCount,omitempty"` // 剩余次数;-1代表不限制
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *SCRedPacketDraw) Reset() {
|
||||||
|
*x = SCRedPacketDraw{}
|
||||||
|
if protoimpl.UnsafeEnabled {
|
||||||
|
mi := &file_protocol_welfare_welfare_proto_msgTypes[71]
|
||||||
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
|
ms.StoreMessageInfo(mi)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *SCRedPacketDraw) String() string {
|
||||||
|
return protoimpl.X.MessageStringOf(x)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (*SCRedPacketDraw) ProtoMessage() {}
|
||||||
|
|
||||||
|
func (x *SCRedPacketDraw) ProtoReflect() protoreflect.Message {
|
||||||
|
mi := &file_protocol_welfare_welfare_proto_msgTypes[71]
|
||||||
|
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 SCRedPacketDraw.ProtoReflect.Descriptor instead.
|
||||||
|
func (*SCRedPacketDraw) Descriptor() ([]byte, []int) {
|
||||||
|
return file_protocol_welfare_welfare_proto_rawDescGZIP(), []int{71}
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *SCRedPacketDraw) GetOpRetCode() OpResultCode {
|
||||||
|
if x != nil {
|
||||||
|
return x.OpRetCode
|
||||||
|
}
|
||||||
|
return OpResultCode_OPRC_Sucess
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *SCRedPacketDraw) GetId() int64 {
|
||||||
|
if x != nil {
|
||||||
|
return x.Id
|
||||||
|
}
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *SCRedPacketDraw) GetAward() []*PropInfo {
|
||||||
|
if x != nil {
|
||||||
|
return x.Award
|
||||||
|
}
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *SCRedPacketDraw) GetRemainCount() int64 {
|
||||||
|
if x != nil {
|
||||||
|
return x.RemainCount
|
||||||
|
}
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
|
||||||
var File_protocol_welfare_welfare_proto protoreflect.FileDescriptor
|
var File_protocol_welfare_welfare_proto protoreflect.FileDescriptor
|
||||||
|
|
||||||
var file_protocol_welfare_welfare_proto_rawDesc = []byte{
|
var file_protocol_welfare_welfare_proto_rawDesc = []byte{
|
||||||
|
|
@ -5069,131 +5377,166 @@ var file_protocol_welfare_welfare_proto_rawDesc = []byte{
|
||||||
0x6f, 0x74, 0x74, 0x65, 0x72, 0x79, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x28, 0x0a, 0x04, 0x49, 0x6e,
|
0x6f, 0x74, 0x74, 0x65, 0x72, 0x79, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x28, 0x0a, 0x04, 0x49, 0x6e,
|
||||||
0x66, 0x6f, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x14, 0x2e, 0x77, 0x65, 0x6c, 0x66, 0x61,
|
0x66, 0x6f, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x14, 0x2e, 0x77, 0x65, 0x6c, 0x66, 0x61,
|
||||||
0x72, 0x65, 0x2e, 0x4c, 0x6f, 0x74, 0x74, 0x65, 0x72, 0x79, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x04,
|
0x72, 0x65, 0x2e, 0x4c, 0x6f, 0x74, 0x74, 0x65, 0x72, 0x79, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x04,
|
||||||
0x49, 0x6e, 0x66, 0x6f, 0x2a, 0xf5, 0x02, 0x0a, 0x0c, 0x4f, 0x70, 0x52, 0x65, 0x73, 0x75, 0x6c,
|
0x49, 0x6e, 0x66, 0x6f, 0x22, 0x11, 0x0a, 0x0f, 0x43, 0x53, 0x52, 0x65, 0x64, 0x50, 0x61, 0x63,
|
||||||
0x74, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x0f, 0x0a, 0x0b, 0x4f, 0x50, 0x52, 0x43, 0x5f, 0x53, 0x75,
|
0x6b, 0x65, 0x74, 0x49, 0x6e, 0x66, 0x6f, 0x22, 0x3d, 0x0a, 0x0f, 0x53, 0x43, 0x52, 0x65, 0x64,
|
||||||
0x63, 0x65, 0x73, 0x73, 0x10, 0x00, 0x12, 0x0e, 0x0a, 0x0a, 0x4f, 0x50, 0x52, 0x43, 0x5f, 0x45,
|
0x50, 0x61, 0x63, 0x6b, 0x65, 0x74, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x2a, 0x0a, 0x04, 0x49, 0x6e,
|
||||||
0x72, 0x72, 0x6f, 0x72, 0x10, 0x01, 0x12, 0x10, 0x0a, 0x0c, 0x4f, 0x50, 0x52, 0x43, 0x5f, 0x4e,
|
0x66, 0x6f, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x16, 0x2e, 0x77, 0x65, 0x6c, 0x66, 0x61,
|
||||||
0x6f, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x10, 0x02, 0x12, 0x14, 0x0a, 0x10, 0x4f, 0x50, 0x52, 0x43,
|
0x72, 0x65, 0x2e, 0x52, 0x65, 0x64, 0x50, 0x61, 0x63, 0x6b, 0x65, 0x74, 0x49, 0x6e, 0x66, 0x6f,
|
||||||
0x5f, 0x43, 0x6f, 0x69, 0x6e, 0x54, 0x6f, 0x6f, 0x4d, 0x6f, 0x72, 0x65, 0x10, 0x03, 0x12, 0x10,
|
0x52, 0x04, 0x49, 0x6e, 0x66, 0x6f, 0x22, 0xa5, 0x01, 0x0a, 0x0d, 0x52, 0x65, 0x64, 0x50, 0x61,
|
||||||
0x0a, 0x0c, 0x4f, 0x50, 0x52, 0x43, 0x5f, 0x45, 0x72, 0x72, 0x43, 0x6f, 0x69, 0x6e, 0x10, 0x04,
|
0x63, 0x6b, 0x65, 0x74, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x64, 0x18, 0x01,
|
||||||
0x12, 0x14, 0x0a, 0x10, 0x4f, 0x50, 0x52, 0x43, 0x5f, 0x41, 0x6c, 0x72, 0x65, 0x61, 0x64, 0x79,
|
0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, 0x64, 0x12, 0x18, 0x0a, 0x07, 0x53, 0x74, 0x61, 0x72,
|
||||||
0x42, 0x69, 0x6e, 0x64, 0x10, 0x05, 0x12, 0x11, 0x0a, 0x0d, 0x4f, 0x50, 0x52, 0x43, 0x5f, 0x42,
|
0x74, 0x54, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x07, 0x53, 0x74, 0x61, 0x72, 0x74,
|
||||||
0x69, 0x6e, 0x64, 0x53, 0x65, 0x6c, 0x66, 0x10, 0x06, 0x12, 0x11, 0x0a, 0x0d, 0x4f, 0x50, 0x52,
|
0x54, 0x73, 0x12, 0x14, 0x0a, 0x05, 0x45, 0x6e, 0x64, 0x54, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28,
|
||||||
0x43, 0x5f, 0x4d, 0x79, 0x49, 0x6e, 0x76, 0x69, 0x74, 0x65, 0x10, 0x07, 0x12, 0x11, 0x0a, 0x0d,
|
0x03, 0x52, 0x05, 0x45, 0x6e, 0x64, 0x54, 0x73, 0x12, 0x16, 0x0a, 0x06, 0x53, 0x74, 0x61, 0x79,
|
||||||
0x4f, 0x50, 0x52, 0x43, 0x5f, 0x4e, 0x6f, 0x74, 0x45, 0x78, 0x69, 0x73, 0x74, 0x10, 0x08, 0x12,
|
0x54, 0x73, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x53, 0x74, 0x61, 0x79, 0x54, 0x73,
|
||||||
0x14, 0x0a, 0x10, 0x4f, 0x50, 0x52, 0x43, 0x5f, 0x44, 0x69, 0x61, 0x6d, 0x6f, 0x6e, 0x64, 0x4c,
|
0x12, 0x1a, 0x0a, 0x08, 0x4d, 0x61, 0x78, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x05, 0x20, 0x01,
|
||||||
0x65, 0x73, 0x73, 0x10, 0x09, 0x12, 0x17, 0x0a, 0x13, 0x4f, 0x50, 0x52, 0x43, 0x5f, 0x50, 0x69,
|
0x28, 0x03, 0x52, 0x08, 0x4d, 0x61, 0x78, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x20, 0x0a, 0x0b,
|
||||||
0x67, 0x62, 0x61, 0x6e, 0x6b, 0x4e, 0x6f, 0x74, 0x46, 0x75, 0x6c, 0x6c, 0x10, 0x0a, 0x12, 0x1d,
|
0x52, 0x65, 0x6d, 0x61, 0x69, 0x6e, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x06, 0x20, 0x01, 0x28,
|
||||||
0x0a, 0x19, 0x4f, 0x50, 0x52, 0x43, 0x5f, 0x50, 0x69, 0x67, 0x62, 0x61, 0x6e, 0x6b, 0x4f, 0x76,
|
0x03, 0x52, 0x0b, 0x52, 0x65, 0x6d, 0x61, 0x69, 0x6e, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x22, 0x21,
|
||||||
0x65, 0x72, 0x54, 0x61, 0x6b, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x10, 0x0b, 0x12, 0x16, 0x0a,
|
0x0a, 0x0f, 0x43, 0x53, 0x52, 0x65, 0x64, 0x50, 0x61, 0x63, 0x6b, 0x65, 0x74, 0x44, 0x72, 0x61,
|
||||||
0x12, 0x4f, 0x50, 0x52, 0x43, 0x5f, 0x45, 0x78, 0x63, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x4c, 0x69,
|
0x77, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x49,
|
||||||
0x6d, 0x69, 0x74, 0x10, 0x0c, 0x12, 0x1b, 0x0a, 0x17, 0x4f, 0x50, 0x52, 0x43, 0x5f, 0x45, 0x78,
|
0x64, 0x22, 0xa1, 0x01, 0x0a, 0x0f, 0x53, 0x43, 0x52, 0x65, 0x64, 0x50, 0x61, 0x63, 0x6b, 0x65,
|
||||||
0x63, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x4c, 0x65, 0x76, 0x65, 0x6c, 0x4c, 0x69, 0x6d, 0x69, 0x74,
|
0x74, 0x44, 0x72, 0x61, 0x77, 0x12, 0x33, 0x0a, 0x09, 0x4f, 0x70, 0x52, 0x65, 0x74, 0x43, 0x6f,
|
||||||
0x10, 0x0d, 0x12, 0x13, 0x0a, 0x0f, 0x4f, 0x50, 0x52, 0x43, 0x5f, 0x4e, 0x65, 0x65, 0x64, 0x50,
|
0x64, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x15, 0x2e, 0x77, 0x65, 0x6c, 0x66, 0x61,
|
||||||
0x65, 0x72, 0x6d, 0x69, 0x74, 0x10, 0x0e, 0x12, 0x10, 0x0a, 0x0c, 0x4f, 0x50, 0x52, 0x43, 0x5f,
|
0x72, 0x65, 0x2e, 0x4f, 0x70, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x43, 0x6f, 0x64, 0x65, 0x52,
|
||||||
0x45, 0x72, 0x72, 0x43, 0x6f, 0x73, 0x74, 0x10, 0x0f, 0x12, 0x11, 0x0a, 0x0d, 0x4f, 0x50, 0x52,
|
0x09, 0x4f, 0x70, 0x52, 0x65, 0x74, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x64,
|
||||||
0x43, 0x5f, 0x4e, 0x6f, 0x74, 0x46, 0x6f, 0x75, 0x6e, 0x64, 0x10, 0x10, 0x2a, 0x92, 0x0c, 0x0a,
|
0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, 0x64, 0x12, 0x27, 0x0a, 0x05, 0x41, 0x77,
|
||||||
0x09, 0x53, 0x50, 0x61, 0x63, 0x6b, 0x65, 0x74, 0x49, 0x44, 0x12, 0x14, 0x0a, 0x10, 0x50, 0x41,
|
0x61, 0x72, 0x64, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x11, 0x2e, 0x77, 0x65, 0x6c, 0x66,
|
||||||
0x43, 0x4b, 0x45, 0x54, 0x5f, 0x53, 0x48, 0x4f, 0x50, 0x5f, 0x5a, 0x45, 0x52, 0x4f, 0x10, 0x00,
|
0x61, 0x72, 0x65, 0x2e, 0x50, 0x72, 0x6f, 0x70, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x05, 0x41, 0x77,
|
||||||
0x12, 0x21, 0x0a, 0x1c, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x43, 0x53, 0x5f, 0x57, 0x45,
|
0x61, 0x72, 0x64, 0x12, 0x20, 0x0a, 0x0b, 0x52, 0x65, 0x6d, 0x61, 0x69, 0x6e, 0x43, 0x6f, 0x75,
|
||||||
0x4c, 0x46, 0x5f, 0x47, 0x45, 0x54, 0x52, 0x45, 0x4c, 0x49, 0x45, 0x46, 0x46, 0x55, 0x4e, 0x44,
|
0x6e, 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x52, 0x65, 0x6d, 0x61, 0x69, 0x6e,
|
||||||
0x10, 0x94, 0x14, 0x12, 0x21, 0x0a, 0x1c, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x53, 0x43,
|
0x43, 0x6f, 0x75, 0x6e, 0x74, 0x2a, 0xf5, 0x02, 0x0a, 0x0c, 0x4f, 0x70, 0x52, 0x65, 0x73, 0x75,
|
||||||
0x5f, 0x57, 0x45, 0x4c, 0x46, 0x5f, 0x47, 0x45, 0x54, 0x52, 0x45, 0x4c, 0x49, 0x45, 0x46, 0x46,
|
0x6c, 0x74, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x0f, 0x0a, 0x0b, 0x4f, 0x50, 0x52, 0x43, 0x5f, 0x53,
|
||||||
0x55, 0x4e, 0x44, 0x10, 0x95, 0x14, 0x12, 0x20, 0x0a, 0x1b, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54,
|
0x75, 0x63, 0x65, 0x73, 0x73, 0x10, 0x00, 0x12, 0x0e, 0x0a, 0x0a, 0x4f, 0x50, 0x52, 0x43, 0x5f,
|
||||||
0x5f, 0x43, 0x53, 0x5f, 0x57, 0x45, 0x4c, 0x46, 0x5f, 0x47, 0x45, 0x54, 0x54, 0x55, 0x52, 0x4e,
|
0x45, 0x72, 0x72, 0x6f, 0x72, 0x10, 0x01, 0x12, 0x10, 0x0a, 0x0c, 0x4f, 0x50, 0x52, 0x43, 0x5f,
|
||||||
0x50, 0x4c, 0x41, 0x54, 0x45, 0x10, 0x96, 0x14, 0x12, 0x20, 0x0a, 0x1b, 0x50, 0x41, 0x43, 0x4b,
|
0x4e, 0x6f, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x10, 0x02, 0x12, 0x14, 0x0a, 0x10, 0x4f, 0x50, 0x52,
|
||||||
0x45, 0x54, 0x5f, 0x53, 0x43, 0x5f, 0x57, 0x45, 0x4c, 0x46, 0x5f, 0x47, 0x45, 0x54, 0x54, 0x55,
|
0x43, 0x5f, 0x43, 0x6f, 0x69, 0x6e, 0x54, 0x6f, 0x6f, 0x4d, 0x6f, 0x72, 0x65, 0x10, 0x03, 0x12,
|
||||||
0x52, 0x4e, 0x50, 0x4c, 0x41, 0x54, 0x45, 0x10, 0x97, 0x14, 0x12, 0x20, 0x0a, 0x1b, 0x50, 0x41,
|
0x10, 0x0a, 0x0c, 0x4f, 0x50, 0x52, 0x43, 0x5f, 0x45, 0x72, 0x72, 0x43, 0x6f, 0x69, 0x6e, 0x10,
|
||||||
0x43, 0x4b, 0x45, 0x54, 0x5f, 0x43, 0x53, 0x5f, 0x57, 0x45, 0x4c, 0x46, 0x5f, 0x47, 0x45, 0x54,
|
0x04, 0x12, 0x14, 0x0a, 0x10, 0x4f, 0x50, 0x52, 0x43, 0x5f, 0x41, 0x6c, 0x72, 0x65, 0x61, 0x64,
|
||||||
0x41, 0x44, 0x44, 0x55, 0x50, 0x53, 0x49, 0x47, 0x4e, 0x10, 0x98, 0x14, 0x12, 0x20, 0x0a, 0x1b,
|
0x79, 0x42, 0x69, 0x6e, 0x64, 0x10, 0x05, 0x12, 0x11, 0x0a, 0x0d, 0x4f, 0x50, 0x52, 0x43, 0x5f,
|
||||||
0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x53, 0x43, 0x5f, 0x57, 0x45, 0x4c, 0x46, 0x5f, 0x47,
|
0x42, 0x69, 0x6e, 0x64, 0x53, 0x65, 0x6c, 0x66, 0x10, 0x06, 0x12, 0x11, 0x0a, 0x0d, 0x4f, 0x50,
|
||||||
0x45, 0x54, 0x41, 0x44, 0x44, 0x55, 0x50, 0x53, 0x49, 0x47, 0x4e, 0x10, 0x99, 0x14, 0x12, 0x1f,
|
0x52, 0x43, 0x5f, 0x4d, 0x79, 0x49, 0x6e, 0x76, 0x69, 0x74, 0x65, 0x10, 0x07, 0x12, 0x11, 0x0a,
|
||||||
0x0a, 0x1a, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x43, 0x53, 0x5f, 0x57, 0x45, 0x4c, 0x46,
|
0x0d, 0x4f, 0x50, 0x52, 0x43, 0x5f, 0x4e, 0x6f, 0x74, 0x45, 0x78, 0x69, 0x73, 0x74, 0x10, 0x08,
|
||||||
0x5f, 0x57, 0x45, 0x4c, 0x46, 0x41, 0x52, 0x45, 0x49, 0x4e, 0x46, 0x4f, 0x10, 0x9a, 0x14, 0x12,
|
0x12, 0x14, 0x0a, 0x10, 0x4f, 0x50, 0x52, 0x43, 0x5f, 0x44, 0x69, 0x61, 0x6d, 0x6f, 0x6e, 0x64,
|
||||||
0x1f, 0x0a, 0x1a, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x53, 0x43, 0x5f, 0x57, 0x45, 0x4c,
|
0x4c, 0x65, 0x73, 0x73, 0x10, 0x09, 0x12, 0x17, 0x0a, 0x13, 0x4f, 0x50, 0x52, 0x43, 0x5f, 0x50,
|
||||||
0x46, 0x5f, 0x57, 0x45, 0x4c, 0x46, 0x41, 0x52, 0x45, 0x49, 0x4e, 0x46, 0x4f, 0x10, 0x9b, 0x14,
|
0x69, 0x67, 0x62, 0x61, 0x6e, 0x6b, 0x4e, 0x6f, 0x74, 0x46, 0x75, 0x6c, 0x6c, 0x10, 0x0a, 0x12,
|
||||||
0x12, 0x1f, 0x0a, 0x1a, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x43, 0x53, 0x5f, 0x57, 0x45,
|
0x1d, 0x0a, 0x19, 0x4f, 0x50, 0x52, 0x43, 0x5f, 0x50, 0x69, 0x67, 0x62, 0x61, 0x6e, 0x6b, 0x4f,
|
||||||
0x4c, 0x46, 0x5f, 0x42, 0x4c, 0x49, 0x4e, 0x42, 0x4f, 0x58, 0x49, 0x4e, 0x46, 0x4f, 0x10, 0x9c,
|
0x76, 0x65, 0x72, 0x54, 0x61, 0x6b, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x10, 0x0b, 0x12, 0x16,
|
||||||
0x14, 0x12, 0x1f, 0x0a, 0x1a, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x53, 0x43, 0x5f, 0x57,
|
0x0a, 0x12, 0x4f, 0x50, 0x52, 0x43, 0x5f, 0x45, 0x78, 0x63, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x4c,
|
||||||
|
0x69, 0x6d, 0x69, 0x74, 0x10, 0x0c, 0x12, 0x1b, 0x0a, 0x17, 0x4f, 0x50, 0x52, 0x43, 0x5f, 0x45,
|
||||||
|
0x78, 0x63, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x4c, 0x65, 0x76, 0x65, 0x6c, 0x4c, 0x69, 0x6d, 0x69,
|
||||||
|
0x74, 0x10, 0x0d, 0x12, 0x13, 0x0a, 0x0f, 0x4f, 0x50, 0x52, 0x43, 0x5f, 0x4e, 0x65, 0x65, 0x64,
|
||||||
|
0x50, 0x65, 0x72, 0x6d, 0x69, 0x74, 0x10, 0x0e, 0x12, 0x10, 0x0a, 0x0c, 0x4f, 0x50, 0x52, 0x43,
|
||||||
|
0x5f, 0x45, 0x72, 0x72, 0x43, 0x6f, 0x73, 0x74, 0x10, 0x0f, 0x12, 0x11, 0x0a, 0x0d, 0x4f, 0x50,
|
||||||
|
0x52, 0x43, 0x5f, 0x4e, 0x6f, 0x74, 0x46, 0x6f, 0x75, 0x6e, 0x64, 0x10, 0x10, 0x2a, 0x86, 0x0d,
|
||||||
|
0x0a, 0x09, 0x53, 0x50, 0x61, 0x63, 0x6b, 0x65, 0x74, 0x49, 0x44, 0x12, 0x14, 0x0a, 0x10, 0x50,
|
||||||
|
0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x53, 0x48, 0x4f, 0x50, 0x5f, 0x5a, 0x45, 0x52, 0x4f, 0x10,
|
||||||
|
0x00, 0x12, 0x21, 0x0a, 0x1c, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x43, 0x53, 0x5f, 0x57,
|
||||||
|
0x45, 0x4c, 0x46, 0x5f, 0x47, 0x45, 0x54, 0x52, 0x45, 0x4c, 0x49, 0x45, 0x46, 0x46, 0x55, 0x4e,
|
||||||
|
0x44, 0x10, 0x94, 0x14, 0x12, 0x21, 0x0a, 0x1c, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x53,
|
||||||
|
0x43, 0x5f, 0x57, 0x45, 0x4c, 0x46, 0x5f, 0x47, 0x45, 0x54, 0x52, 0x45, 0x4c, 0x49, 0x45, 0x46,
|
||||||
|
0x46, 0x55, 0x4e, 0x44, 0x10, 0x95, 0x14, 0x12, 0x20, 0x0a, 0x1b, 0x50, 0x41, 0x43, 0x4b, 0x45,
|
||||||
|
0x54, 0x5f, 0x43, 0x53, 0x5f, 0x57, 0x45, 0x4c, 0x46, 0x5f, 0x47, 0x45, 0x54, 0x54, 0x55, 0x52,
|
||||||
|
0x4e, 0x50, 0x4c, 0x41, 0x54, 0x45, 0x10, 0x96, 0x14, 0x12, 0x20, 0x0a, 0x1b, 0x50, 0x41, 0x43,
|
||||||
|
0x4b, 0x45, 0x54, 0x5f, 0x53, 0x43, 0x5f, 0x57, 0x45, 0x4c, 0x46, 0x5f, 0x47, 0x45, 0x54, 0x54,
|
||||||
|
0x55, 0x52, 0x4e, 0x50, 0x4c, 0x41, 0x54, 0x45, 0x10, 0x97, 0x14, 0x12, 0x20, 0x0a, 0x1b, 0x50,
|
||||||
|
0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x43, 0x53, 0x5f, 0x57, 0x45, 0x4c, 0x46, 0x5f, 0x47, 0x45,
|
||||||
|
0x54, 0x41, 0x44, 0x44, 0x55, 0x50, 0x53, 0x49, 0x47, 0x4e, 0x10, 0x98, 0x14, 0x12, 0x20, 0x0a,
|
||||||
|
0x1b, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x53, 0x43, 0x5f, 0x57, 0x45, 0x4c, 0x46, 0x5f,
|
||||||
|
0x47, 0x45, 0x54, 0x41, 0x44, 0x44, 0x55, 0x50, 0x53, 0x49, 0x47, 0x4e, 0x10, 0x99, 0x14, 0x12,
|
||||||
|
0x1f, 0x0a, 0x1a, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x43, 0x53, 0x5f, 0x57, 0x45, 0x4c,
|
||||||
|
0x46, 0x5f, 0x57, 0x45, 0x4c, 0x46, 0x41, 0x52, 0x45, 0x49, 0x4e, 0x46, 0x4f, 0x10, 0x9a, 0x14,
|
||||||
|
0x12, 0x1f, 0x0a, 0x1a, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x53, 0x43, 0x5f, 0x57, 0x45,
|
||||||
|
0x4c, 0x46, 0x5f, 0x57, 0x45, 0x4c, 0x46, 0x41, 0x52, 0x45, 0x49, 0x4e, 0x46, 0x4f, 0x10, 0x9b,
|
||||||
|
0x14, 0x12, 0x1f, 0x0a, 0x1a, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x43, 0x53, 0x5f, 0x57,
|
||||||
0x45, 0x4c, 0x46, 0x5f, 0x42, 0x4c, 0x49, 0x4e, 0x42, 0x4f, 0x58, 0x49, 0x4e, 0x46, 0x4f, 0x10,
|
0x45, 0x4c, 0x46, 0x5f, 0x42, 0x4c, 0x49, 0x4e, 0x42, 0x4f, 0x58, 0x49, 0x4e, 0x46, 0x4f, 0x10,
|
||||||
0x9d, 0x14, 0x12, 0x1e, 0x0a, 0x19, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x43, 0x53, 0x5f,
|
0x9c, 0x14, 0x12, 0x1f, 0x0a, 0x1a, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x53, 0x43, 0x5f,
|
||||||
0x57, 0x45, 0x4c, 0x46, 0x5f, 0x47, 0x45, 0x54, 0x42, 0x4c, 0x49, 0x4e, 0x42, 0x4f, 0x58, 0x10,
|
0x57, 0x45, 0x4c, 0x46, 0x5f, 0x42, 0x4c, 0x49, 0x4e, 0x42, 0x4f, 0x58, 0x49, 0x4e, 0x46, 0x4f,
|
||||||
0x9e, 0x14, 0x12, 0x1e, 0x0a, 0x19, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x53, 0x43, 0x5f,
|
0x10, 0x9d, 0x14, 0x12, 0x1e, 0x0a, 0x19, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x43, 0x53,
|
||||||
0x57, 0x45, 0x4c, 0x46, 0x5f, 0x47, 0x45, 0x54, 0x42, 0x4c, 0x49, 0x4e, 0x42, 0x4f, 0x58, 0x10,
|
0x5f, 0x57, 0x45, 0x4c, 0x46, 0x5f, 0x47, 0x45, 0x54, 0x42, 0x4c, 0x49, 0x4e, 0x42, 0x4f, 0x58,
|
||||||
0x9f, 0x14, 0x12, 0x20, 0x0a, 0x1b, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x43, 0x53, 0x5f,
|
0x10, 0x9e, 0x14, 0x12, 0x1e, 0x0a, 0x19, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x53, 0x43,
|
||||||
0x57, 0x45, 0x4c, 0x46, 0x5f, 0x46, 0x49, 0x52, 0x53, 0x54, 0x50, 0x41, 0x59, 0x49, 0x4e, 0x46,
|
0x5f, 0x57, 0x45, 0x4c, 0x46, 0x5f, 0x47, 0x45, 0x54, 0x42, 0x4c, 0x49, 0x4e, 0x42, 0x4f, 0x58,
|
||||||
0x4f, 0x10, 0xa0, 0x14, 0x12, 0x20, 0x0a, 0x1b, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x53,
|
0x10, 0x9f, 0x14, 0x12, 0x20, 0x0a, 0x1b, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x43, 0x53,
|
||||||
0x43, 0x5f, 0x57, 0x45, 0x4c, 0x46, 0x5f, 0x46, 0x49, 0x52, 0x53, 0x54, 0x50, 0x41, 0x59, 0x49,
|
0x5f, 0x57, 0x45, 0x4c, 0x46, 0x5f, 0x46, 0x49, 0x52, 0x53, 0x54, 0x50, 0x41, 0x59, 0x49, 0x4e,
|
||||||
0x4e, 0x46, 0x4f, 0x10, 0xa1, 0x14, 0x12, 0x1c, 0x0a, 0x17, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54,
|
0x46, 0x4f, 0x10, 0xa0, 0x14, 0x12, 0x20, 0x0a, 0x1b, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f,
|
||||||
0x5f, 0x43, 0x53, 0x5f, 0x57, 0x45, 0x4c, 0x46, 0x5f, 0x46, 0x49, 0x52, 0x53, 0x54, 0x50, 0x41,
|
0x53, 0x43, 0x5f, 0x57, 0x45, 0x4c, 0x46, 0x5f, 0x46, 0x49, 0x52, 0x53, 0x54, 0x50, 0x41, 0x59,
|
||||||
0x59, 0x10, 0xa2, 0x14, 0x12, 0x1c, 0x0a, 0x17, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x53,
|
0x49, 0x4e, 0x46, 0x4f, 0x10, 0xa1, 0x14, 0x12, 0x1c, 0x0a, 0x17, 0x50, 0x41, 0x43, 0x4b, 0x45,
|
||||||
0x43, 0x5f, 0x57, 0x45, 0x4c, 0x46, 0x5f, 0x46, 0x49, 0x52, 0x53, 0x54, 0x50, 0x41, 0x59, 0x10,
|
0x54, 0x5f, 0x43, 0x53, 0x5f, 0x57, 0x45, 0x4c, 0x46, 0x5f, 0x46, 0x49, 0x52, 0x53, 0x54, 0x50,
|
||||||
0xa3, 0x14, 0x12, 0x21, 0x0a, 0x1c, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x43, 0x53, 0x5f,
|
0x41, 0x59, 0x10, 0xa2, 0x14, 0x12, 0x1c, 0x0a, 0x17, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f,
|
||||||
0x57, 0x45, 0x4c, 0x46, 0x5f, 0x43, 0x4f, 0x4e, 0x54, 0x49, 0x4e, 0x50, 0x41, 0x59, 0x49, 0x4e,
|
0x53, 0x43, 0x5f, 0x57, 0x45, 0x4c, 0x46, 0x5f, 0x46, 0x49, 0x52, 0x53, 0x54, 0x50, 0x41, 0x59,
|
||||||
0x46, 0x4f, 0x10, 0xa4, 0x14, 0x12, 0x21, 0x0a, 0x1c, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f,
|
0x10, 0xa3, 0x14, 0x12, 0x21, 0x0a, 0x1c, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x43, 0x53,
|
||||||
0x53, 0x43, 0x5f, 0x57, 0x45, 0x4c, 0x46, 0x5f, 0x43, 0x4f, 0x4e, 0x54, 0x49, 0x4e, 0x50, 0x41,
|
0x5f, 0x57, 0x45, 0x4c, 0x46, 0x5f, 0x43, 0x4f, 0x4e, 0x54, 0x49, 0x4e, 0x50, 0x41, 0x59, 0x49,
|
||||||
0x59, 0x49, 0x4e, 0x46, 0x4f, 0x10, 0xa5, 0x14, 0x12, 0x1d, 0x0a, 0x18, 0x50, 0x41, 0x43, 0x4b,
|
0x4e, 0x46, 0x4f, 0x10, 0xa4, 0x14, 0x12, 0x21, 0x0a, 0x1c, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54,
|
||||||
0x45, 0x54, 0x5f, 0x43, 0x53, 0x5f, 0x57, 0x45, 0x4c, 0x46, 0x5f, 0x43, 0x4f, 0x4e, 0x54, 0x49,
|
0x5f, 0x53, 0x43, 0x5f, 0x57, 0x45, 0x4c, 0x46, 0x5f, 0x43, 0x4f, 0x4e, 0x54, 0x49, 0x4e, 0x50,
|
||||||
0x4e, 0x50, 0x41, 0x59, 0x10, 0xa6, 0x14, 0x12, 0x1d, 0x0a, 0x18, 0x50, 0x41, 0x43, 0x4b, 0x45,
|
0x41, 0x59, 0x49, 0x4e, 0x46, 0x4f, 0x10, 0xa5, 0x14, 0x12, 0x1d, 0x0a, 0x18, 0x50, 0x41, 0x43,
|
||||||
0x54, 0x5f, 0x53, 0x43, 0x5f, 0x57, 0x45, 0x4c, 0x46, 0x5f, 0x43, 0x4f, 0x4e, 0x54, 0x49, 0x4e,
|
0x4b, 0x45, 0x54, 0x5f, 0x43, 0x53, 0x5f, 0x57, 0x45, 0x4c, 0x46, 0x5f, 0x43, 0x4f, 0x4e, 0x54,
|
||||||
0x50, 0x41, 0x59, 0x10, 0xa7, 0x14, 0x12, 0x22, 0x0a, 0x1d, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54,
|
0x49, 0x4e, 0x50, 0x41, 0x59, 0x10, 0xa6, 0x14, 0x12, 0x1d, 0x0a, 0x18, 0x50, 0x41, 0x43, 0x4b,
|
||||||
0x5f, 0x43, 0x53, 0x5f, 0x53, 0x69, 0x67, 0x6e, 0x44, 0x61, 0x79, 0x5f, 0x41, 0x64, 0x64, 0x75,
|
0x45, 0x54, 0x5f, 0x53, 0x43, 0x5f, 0x57, 0x45, 0x4c, 0x46, 0x5f, 0x43, 0x4f, 0x4e, 0x54, 0x49,
|
||||||
0x70, 0x32, 0x41, 0x77, 0x61, 0x72, 0x64, 0x10, 0xa8, 0x14, 0x12, 0x22, 0x0a, 0x1d, 0x50, 0x41,
|
0x4e, 0x50, 0x41, 0x59, 0x10, 0xa7, 0x14, 0x12, 0x22, 0x0a, 0x1d, 0x50, 0x41, 0x43, 0x4b, 0x45,
|
||||||
0x43, 0x4b, 0x45, 0x54, 0x5f, 0x53, 0x43, 0x5f, 0x53, 0x69, 0x67, 0x6e, 0x44, 0x61, 0x79, 0x5f,
|
0x54, 0x5f, 0x43, 0x53, 0x5f, 0x53, 0x69, 0x67, 0x6e, 0x44, 0x61, 0x79, 0x5f, 0x41, 0x64, 0x64,
|
||||||
0x41, 0x64, 0x64, 0x75, 0x70, 0x32, 0x41, 0x77, 0x61, 0x72, 0x64, 0x10, 0xa9, 0x14, 0x12, 0x18,
|
0x75, 0x70, 0x32, 0x41, 0x77, 0x61, 0x72, 0x64, 0x10, 0xa8, 0x14, 0x12, 0x22, 0x0a, 0x1d, 0x50,
|
||||||
0x0a, 0x13, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x43, 0x53, 0x57, 0x65, 0x6c, 0x66, 0x52,
|
0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x53, 0x43, 0x5f, 0x53, 0x69, 0x67, 0x6e, 0x44, 0x61, 0x79,
|
||||||
0x65, 0x6c, 0x69, 0x65, 0x66, 0x10, 0xd4, 0x16, 0x12, 0x18, 0x0a, 0x13, 0x50, 0x41, 0x43, 0x4b,
|
0x5f, 0x41, 0x64, 0x64, 0x75, 0x70, 0x32, 0x41, 0x77, 0x61, 0x72, 0x64, 0x10, 0xa9, 0x14, 0x12,
|
||||||
0x45, 0x54, 0x5f, 0x53, 0x43, 0x57, 0x65, 0x6c, 0x66, 0x52, 0x65, 0x6c, 0x69, 0x65, 0x66, 0x10,
|
0x18, 0x0a, 0x13, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x43, 0x53, 0x57, 0x65, 0x6c, 0x66,
|
||||||
0xd5, 0x16, 0x12, 0x18, 0x0a, 0x13, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x43, 0x53, 0x49,
|
0x52, 0x65, 0x6c, 0x69, 0x65, 0x66, 0x10, 0xd4, 0x16, 0x12, 0x18, 0x0a, 0x13, 0x50, 0x41, 0x43,
|
||||||
0x6e, 0x76, 0x69, 0x74, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x10, 0xd6, 0x16, 0x12, 0x18, 0x0a, 0x13,
|
0x4b, 0x45, 0x54, 0x5f, 0x53, 0x43, 0x57, 0x65, 0x6c, 0x66, 0x52, 0x65, 0x6c, 0x69, 0x65, 0x66,
|
||||||
0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x53, 0x43, 0x49, 0x6e, 0x76, 0x69, 0x74, 0x65, 0x49,
|
0x10, 0xd5, 0x16, 0x12, 0x18, 0x0a, 0x13, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x43, 0x53,
|
||||||
0x6e, 0x66, 0x6f, 0x10, 0xd7, 0x16, 0x12, 0x18, 0x0a, 0x13, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54,
|
0x49, 0x6e, 0x76, 0x69, 0x74, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x10, 0xd6, 0x16, 0x12, 0x18, 0x0a,
|
||||||
0x5f, 0x43, 0x53, 0x42, 0x69, 0x6e, 0x64, 0x49, 0x6e, 0x76, 0x69, 0x74, 0x65, 0x10, 0xd8, 0x16,
|
0x13, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x53, 0x43, 0x49, 0x6e, 0x76, 0x69, 0x74, 0x65,
|
||||||
0x12, 0x18, 0x0a, 0x13, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x53, 0x43, 0x42, 0x69, 0x6e,
|
0x49, 0x6e, 0x66, 0x6f, 0x10, 0xd7, 0x16, 0x12, 0x18, 0x0a, 0x13, 0x50, 0x41, 0x43, 0x4b, 0x45,
|
||||||
0x64, 0x49, 0x6e, 0x76, 0x69, 0x74, 0x65, 0x10, 0xd9, 0x16, 0x12, 0x1c, 0x0a, 0x17, 0x50, 0x41,
|
0x54, 0x5f, 0x43, 0x53, 0x42, 0x69, 0x6e, 0x64, 0x49, 0x6e, 0x76, 0x69, 0x74, 0x65, 0x10, 0xd8,
|
||||||
0x43, 0x4b, 0x45, 0x54, 0x5f, 0x43, 0x53, 0x50, 0x69, 0x67, 0x62, 0x61, 0x6e, 0x6b, 0x47, 0x65,
|
0x16, 0x12, 0x18, 0x0a, 0x13, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x53, 0x43, 0x42, 0x69,
|
||||||
0x74, 0x49, 0x6e, 0x66, 0x6f, 0x10, 0xde, 0x16, 0x12, 0x1c, 0x0a, 0x17, 0x50, 0x41, 0x43, 0x4b,
|
0x6e, 0x64, 0x49, 0x6e, 0x76, 0x69, 0x74, 0x65, 0x10, 0xd9, 0x16, 0x12, 0x1c, 0x0a, 0x17, 0x50,
|
||||||
0x45, 0x54, 0x5f, 0x53, 0x43, 0x50, 0x69, 0x67, 0x62, 0x61, 0x6e, 0x6b, 0x47, 0x65, 0x74, 0x49,
|
0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x43, 0x53, 0x50, 0x69, 0x67, 0x62, 0x61, 0x6e, 0x6b, 0x47,
|
||||||
0x6e, 0x66, 0x6f, 0x10, 0xdf, 0x16, 0x12, 0x1d, 0x0a, 0x18, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54,
|
0x65, 0x74, 0x49, 0x6e, 0x66, 0x6f, 0x10, 0xde, 0x16, 0x12, 0x1c, 0x0a, 0x17, 0x50, 0x41, 0x43,
|
||||||
0x5f, 0x43, 0x53, 0x50, 0x69, 0x67, 0x62, 0x61, 0x6e, 0x6b, 0x54, 0x61, 0x6b, 0x65, 0x43, 0x6f,
|
0x4b, 0x45, 0x54, 0x5f, 0x53, 0x43, 0x50, 0x69, 0x67, 0x62, 0x61, 0x6e, 0x6b, 0x47, 0x65, 0x74,
|
||||||
0x69, 0x6e, 0x10, 0xe0, 0x16, 0x12, 0x1d, 0x0a, 0x18, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f,
|
0x49, 0x6e, 0x66, 0x6f, 0x10, 0xdf, 0x16, 0x12, 0x1d, 0x0a, 0x18, 0x50, 0x41, 0x43, 0x4b, 0x45,
|
||||||
0x53, 0x43, 0x50, 0x69, 0x67, 0x62, 0x61, 0x6e, 0x6b, 0x54, 0x61, 0x6b, 0x65, 0x43, 0x6f, 0x69,
|
0x54, 0x5f, 0x43, 0x53, 0x50, 0x69, 0x67, 0x62, 0x61, 0x6e, 0x6b, 0x54, 0x61, 0x6b, 0x65, 0x43,
|
||||||
0x6e, 0x10, 0xe1, 0x16, 0x12, 0x20, 0x0a, 0x1b, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x43,
|
0x6f, 0x69, 0x6e, 0x10, 0xe0, 0x16, 0x12, 0x1d, 0x0a, 0x18, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54,
|
||||||
0x53, 0x44, 0x69, 0x61, 0x6d, 0x6f, 0x6e, 0x64, 0x42, 0x61, 0x6e, 0x6b, 0x47, 0x65, 0x74, 0x49,
|
0x5f, 0x53, 0x43, 0x50, 0x69, 0x67, 0x62, 0x61, 0x6e, 0x6b, 0x54, 0x61, 0x6b, 0x65, 0x43, 0x6f,
|
||||||
0x6e, 0x66, 0x6f, 0x10, 0xe2, 0x16, 0x12, 0x20, 0x0a, 0x1b, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54,
|
0x69, 0x6e, 0x10, 0xe1, 0x16, 0x12, 0x20, 0x0a, 0x1b, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f,
|
||||||
0x5f, 0x53, 0x43, 0x44, 0x69, 0x61, 0x6d, 0x6f, 0x6e, 0x64, 0x42, 0x61, 0x6e, 0x6b, 0x47, 0x65,
|
0x43, 0x53, 0x44, 0x69, 0x61, 0x6d, 0x6f, 0x6e, 0x64, 0x42, 0x61, 0x6e, 0x6b, 0x47, 0x65, 0x74,
|
||||||
0x74, 0x49, 0x6e, 0x66, 0x6f, 0x10, 0xe3, 0x16, 0x12, 0x24, 0x0a, 0x1f, 0x50, 0x41, 0x43, 0x4b,
|
0x49, 0x6e, 0x66, 0x6f, 0x10, 0xe2, 0x16, 0x12, 0x20, 0x0a, 0x1b, 0x50, 0x41, 0x43, 0x4b, 0x45,
|
||||||
0x45, 0x54, 0x5f, 0x53, 0x43, 0x44, 0x69, 0x61, 0x6d, 0x6f, 0x6e, 0x64, 0x42, 0x61, 0x6e, 0x6b,
|
0x54, 0x5f, 0x53, 0x43, 0x44, 0x69, 0x61, 0x6d, 0x6f, 0x6e, 0x64, 0x42, 0x61, 0x6e, 0x6b, 0x47,
|
||||||
0x54, 0x61, 0x6b, 0x65, 0x44, 0x69, 0x61, 0x6d, 0x6f, 0x6e, 0x64, 0x10, 0xe4, 0x16, 0x12, 0x18,
|
0x65, 0x74, 0x49, 0x6e, 0x66, 0x6f, 0x10, 0xe3, 0x16, 0x12, 0x24, 0x0a, 0x1f, 0x50, 0x41, 0x43,
|
||||||
0x0a, 0x13, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x43, 0x53, 0x50, 0x65, 0x72, 0x6d, 0x69,
|
0x4b, 0x45, 0x54, 0x5f, 0x53, 0x43, 0x44, 0x69, 0x61, 0x6d, 0x6f, 0x6e, 0x64, 0x42, 0x61, 0x6e,
|
||||||
0x74, 0x49, 0x6e, 0x66, 0x6f, 0x10, 0xe5, 0x16, 0x12, 0x18, 0x0a, 0x13, 0x50, 0x41, 0x43, 0x4b,
|
0x6b, 0x54, 0x61, 0x6b, 0x65, 0x44, 0x69, 0x61, 0x6d, 0x6f, 0x6e, 0x64, 0x10, 0xe4, 0x16, 0x12,
|
||||||
0x45, 0x54, 0x5f, 0x53, 0x43, 0x50, 0x65, 0x72, 0x6d, 0x69, 0x74, 0x49, 0x6e, 0x66, 0x6f, 0x10,
|
0x18, 0x0a, 0x13, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x43, 0x53, 0x50, 0x65, 0x72, 0x6d,
|
||||||
0xe6, 0x16, 0x12, 0x20, 0x0a, 0x1b, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x43, 0x53, 0x50,
|
0x69, 0x74, 0x49, 0x6e, 0x66, 0x6f, 0x10, 0xe5, 0x16, 0x12, 0x18, 0x0a, 0x13, 0x50, 0x41, 0x43,
|
||||||
0x65, 0x72, 0x6d, 0x69, 0x74, 0x45, 0x78, 0x63, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x4c, 0x69, 0x73,
|
0x4b, 0x45, 0x54, 0x5f, 0x53, 0x43, 0x50, 0x65, 0x72, 0x6d, 0x69, 0x74, 0x49, 0x6e, 0x66, 0x6f,
|
||||||
0x74, 0x10, 0xe7, 0x16, 0x12, 0x20, 0x0a, 0x1b, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x53,
|
0x10, 0xe6, 0x16, 0x12, 0x20, 0x0a, 0x1b, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x43, 0x53,
|
||||||
0x43, 0x50, 0x65, 0x72, 0x6d, 0x69, 0x74, 0x45, 0x78, 0x63, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x4c,
|
0x50, 0x65, 0x72, 0x6d, 0x69, 0x74, 0x45, 0x78, 0x63, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x4c, 0x69,
|
||||||
0x69, 0x73, 0x74, 0x10, 0xe8, 0x16, 0x12, 0x19, 0x0a, 0x14, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54,
|
0x73, 0x74, 0x10, 0xe7, 0x16, 0x12, 0x20, 0x0a, 0x1b, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f,
|
||||||
0x5f, 0x43, 0x53, 0x50, 0x65, 0x72, 0x6d, 0x69, 0x74, 0x41, 0x77, 0x61, 0x72, 0x64, 0x10, 0xe9,
|
0x53, 0x43, 0x50, 0x65, 0x72, 0x6d, 0x69, 0x74, 0x45, 0x78, 0x63, 0x68, 0x61, 0x6e, 0x67, 0x65,
|
||||||
0x16, 0x12, 0x19, 0x0a, 0x14, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x53, 0x43, 0x50, 0x65,
|
0x4c, 0x69, 0x73, 0x74, 0x10, 0xe8, 0x16, 0x12, 0x19, 0x0a, 0x14, 0x50, 0x41, 0x43, 0x4b, 0x45,
|
||||||
0x72, 0x6d, 0x69, 0x74, 0x41, 0x77, 0x61, 0x72, 0x64, 0x10, 0xea, 0x16, 0x12, 0x1c, 0x0a, 0x17,
|
0x54, 0x5f, 0x43, 0x53, 0x50, 0x65, 0x72, 0x6d, 0x69, 0x74, 0x41, 0x77, 0x61, 0x72, 0x64, 0x10,
|
||||||
0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x43, 0x53, 0x50, 0x65, 0x72, 0x6d, 0x69, 0x74, 0x45,
|
0xe9, 0x16, 0x12, 0x19, 0x0a, 0x14, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x53, 0x43, 0x50,
|
||||||
0x78, 0x63, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x10, 0xeb, 0x16, 0x12, 0x1c, 0x0a, 0x17, 0x50, 0x41,
|
0x65, 0x72, 0x6d, 0x69, 0x74, 0x41, 0x77, 0x61, 0x72, 0x64, 0x10, 0xea, 0x16, 0x12, 0x1c, 0x0a,
|
||||||
0x43, 0x4b, 0x45, 0x54, 0x5f, 0x53, 0x43, 0x50, 0x65, 0x72, 0x6d, 0x69, 0x74, 0x45, 0x78, 0x63,
|
0x17, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x43, 0x53, 0x50, 0x65, 0x72, 0x6d, 0x69, 0x74,
|
||||||
0x68, 0x61, 0x6e, 0x67, 0x65, 0x10, 0xec, 0x16, 0x12, 0x18, 0x0a, 0x13, 0x50, 0x41, 0x43, 0x4b,
|
0x45, 0x78, 0x63, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x10, 0xeb, 0x16, 0x12, 0x1c, 0x0a, 0x17, 0x50,
|
||||||
0x45, 0x54, 0x5f, 0x43, 0x53, 0x50, 0x65, 0x72, 0x6d, 0x69, 0x74, 0x53, 0x68, 0x6f, 0x70, 0x10,
|
0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x53, 0x43, 0x50, 0x65, 0x72, 0x6d, 0x69, 0x74, 0x45, 0x78,
|
||||||
0xed, 0x16, 0x12, 0x18, 0x0a, 0x13, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x53, 0x43, 0x50,
|
0x63, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x10, 0xec, 0x16, 0x12, 0x18, 0x0a, 0x13, 0x50, 0x41, 0x43,
|
||||||
0x65, 0x72, 0x6d, 0x69, 0x74, 0x53, 0x68, 0x6f, 0x70, 0x10, 0x8c, 0x17, 0x12, 0x19, 0x0a, 0x14,
|
0x4b, 0x45, 0x54, 0x5f, 0x43, 0x53, 0x50, 0x65, 0x72, 0x6d, 0x69, 0x74, 0x53, 0x68, 0x6f, 0x70,
|
||||||
0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x43, 0x53, 0x4c, 0x6f, 0x74, 0x74, 0x65, 0x72, 0x79,
|
0x10, 0xed, 0x16, 0x12, 0x18, 0x0a, 0x13, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x53, 0x43,
|
||||||
0x49, 0x6e, 0x66, 0x6f, 0x10, 0xee, 0x16, 0x12, 0x19, 0x0a, 0x14, 0x50, 0x41, 0x43, 0x4b, 0x45,
|
0x50, 0x65, 0x72, 0x6d, 0x69, 0x74, 0x53, 0x68, 0x6f, 0x70, 0x10, 0x8c, 0x17, 0x12, 0x19, 0x0a,
|
||||||
0x54, 0x5f, 0x53, 0x43, 0x4c, 0x6f, 0x74, 0x74, 0x65, 0x72, 0x79, 0x49, 0x6e, 0x66, 0x6f, 0x10,
|
0x14, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x43, 0x53, 0x4c, 0x6f, 0x74, 0x74, 0x65, 0x72,
|
||||||
0xef, 0x16, 0x12, 0x1e, 0x0a, 0x19, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x4e, 0x6f, 0x74,
|
0x79, 0x49, 0x6e, 0x66, 0x6f, 0x10, 0xee, 0x16, 0x12, 0x19, 0x0a, 0x14, 0x50, 0x41, 0x43, 0x4b,
|
||||||
0x69, 0x66, 0x79, 0x4c, 0x6f, 0x74, 0x74, 0x65, 0x72, 0x79, 0x41, 0x77, 0x61, 0x72, 0x64, 0x10,
|
0x45, 0x54, 0x5f, 0x53, 0x43, 0x4c, 0x6f, 0x74, 0x74, 0x65, 0x72, 0x79, 0x49, 0x6e, 0x66, 0x6f,
|
||||||
0xf0, 0x16, 0x12, 0x1d, 0x0a, 0x18, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x4e, 0x6f, 0x74,
|
0x10, 0xef, 0x16, 0x12, 0x1e, 0x0a, 0x19, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x4e, 0x6f,
|
||||||
0x69, 0x66, 0x79, 0x4c, 0x6f, 0x74, 0x74, 0x65, 0x72, 0x79, 0x43, 0x6f, 0x64, 0x65, 0x10, 0xf1,
|
0x74, 0x69, 0x66, 0x79, 0x4c, 0x6f, 0x74, 0x74, 0x65, 0x72, 0x79, 0x41, 0x77, 0x61, 0x72, 0x64,
|
||||||
0x16, 0x42, 0x27, 0x5a, 0x25, 0x6d, 0x6f, 0x6e, 0x67, 0x6f, 0x2e, 0x67, 0x61, 0x6d, 0x65, 0x73,
|
0x10, 0xf0, 0x16, 0x12, 0x1d, 0x0a, 0x18, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x4e, 0x6f,
|
||||||
0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x67, 0x61, 0x6d, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63,
|
0x74, 0x69, 0x66, 0x79, 0x4c, 0x6f, 0x74, 0x74, 0x65, 0x72, 0x79, 0x43, 0x6f, 0x64, 0x65, 0x10,
|
||||||
0x6f, 0x6c, 0x2f, 0x77, 0x65, 0x6c, 0x66, 0x61, 0x72, 0x65, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74,
|
0xf1, 0x16, 0x12, 0x1b, 0x0a, 0x16, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x43, 0x53, 0x52,
|
||||||
0x6f, 0x33,
|
0x65, 0x64, 0x50, 0x61, 0x63, 0x6b, 0x65, 0x74, 0x49, 0x6e, 0x66, 0x6f, 0x10, 0xf2, 0x16, 0x12,
|
||||||
|
0x1b, 0x0a, 0x16, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x53, 0x43, 0x52, 0x65, 0x64, 0x50,
|
||||||
|
0x61, 0x63, 0x6b, 0x65, 0x74, 0x49, 0x6e, 0x66, 0x6f, 0x10, 0xf3, 0x16, 0x12, 0x1b, 0x0a, 0x16,
|
||||||
|
0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x43, 0x53, 0x52, 0x65, 0x64, 0x50, 0x61, 0x63, 0x6b,
|
||||||
|
0x65, 0x74, 0x44, 0x72, 0x61, 0x77, 0x10, 0xf4, 0x16, 0x12, 0x1b, 0x0a, 0x16, 0x50, 0x41, 0x43,
|
||||||
|
0x4b, 0x45, 0x54, 0x5f, 0x53, 0x43, 0x52, 0x65, 0x64, 0x50, 0x61, 0x63, 0x6b, 0x65, 0x74, 0x44,
|
||||||
|
0x72, 0x61, 0x77, 0x10, 0xf5, 0x16, 0x42, 0x27, 0x5a, 0x25, 0x6d, 0x6f, 0x6e, 0x67, 0x6f, 0x2e,
|
||||||
|
0x67, 0x61, 0x6d, 0x65, 0x73, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x67, 0x61, 0x6d, 0x65, 0x2f, 0x70,
|
||||||
|
0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x2f, 0x77, 0x65, 0x6c, 0x66, 0x61, 0x72, 0x65, 0x62,
|
||||||
|
0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
|
||||||
}
|
}
|
||||||
|
|
||||||
var (
|
var (
|
||||||
|
|
@ -5209,7 +5552,7 @@ func file_protocol_welfare_welfare_proto_rawDescGZIP() []byte {
|
||||||
}
|
}
|
||||||
|
|
||||||
var file_protocol_welfare_welfare_proto_enumTypes = make([]protoimpl.EnumInfo, 2)
|
var file_protocol_welfare_welfare_proto_enumTypes = make([]protoimpl.EnumInfo, 2)
|
||||||
var file_protocol_welfare_welfare_proto_msgTypes = make([]protoimpl.MessageInfo, 70)
|
var file_protocol_welfare_welfare_proto_msgTypes = make([]protoimpl.MessageInfo, 75)
|
||||||
var file_protocol_welfare_welfare_proto_goTypes = []interface{}{
|
var file_protocol_welfare_welfare_proto_goTypes = []interface{}{
|
||||||
(OpResultCode)(0), // 0: welfare.OpResultCode
|
(OpResultCode)(0), // 0: welfare.OpResultCode
|
||||||
(SPacketID)(0), // 1: welfare.SPacketID
|
(SPacketID)(0), // 1: welfare.SPacketID
|
||||||
|
|
@ -5280,9 +5623,14 @@ var file_protocol_welfare_welfare_proto_goTypes = []interface{}{
|
||||||
(*SCLotteryInfo)(nil), // 66: welfare.SCLotteryInfo
|
(*SCLotteryInfo)(nil), // 66: welfare.SCLotteryInfo
|
||||||
(*NotifyLotteryAward)(nil), // 67: welfare.NotifyLotteryAward
|
(*NotifyLotteryAward)(nil), // 67: welfare.NotifyLotteryAward
|
||||||
(*NotifyLotteryCode)(nil), // 68: welfare.NotifyLotteryCode
|
(*NotifyLotteryCode)(nil), // 68: welfare.NotifyLotteryCode
|
||||||
nil, // 69: welfare.SCInviteInfo.PayScoreEntry
|
(*CSRedPacketInfo)(nil), // 69: welfare.CSRedPacketInfo
|
||||||
nil, // 70: welfare.PigBankCoinInfo.GoldExcEntry
|
(*SCRedPacketInfo)(nil), // 70: welfare.SCRedPacketInfo
|
||||||
nil, // 71: welfare.PigBankDiamondInfo.DiamondExcEntry
|
(*RedPacketInfo)(nil), // 71: welfare.RedPacketInfo
|
||||||
|
(*CSRedPacketDraw)(nil), // 72: welfare.CSRedPacketDraw
|
||||||
|
(*SCRedPacketDraw)(nil), // 73: welfare.SCRedPacketDraw
|
||||||
|
nil, // 74: welfare.SCInviteInfo.PayScoreEntry
|
||||||
|
nil, // 75: welfare.PigBankCoinInfo.GoldExcEntry
|
||||||
|
nil, // 76: welfare.PigBankDiamondInfo.DiamondExcEntry
|
||||||
}
|
}
|
||||||
var file_protocol_welfare_welfare_proto_depIdxs = []int32{
|
var file_protocol_welfare_welfare_proto_depIdxs = []int32{
|
||||||
0, // 0: welfare.SCGetReliefFund.OpRetCode:type_name -> welfare.OpResultCode
|
0, // 0: welfare.SCGetReliefFund.OpRetCode:type_name -> welfare.OpResultCode
|
||||||
|
|
@ -5309,16 +5657,16 @@ var file_protocol_welfare_welfare_proto_depIdxs = []int32{
|
||||||
0, // 21: welfare.SCWelfareContinuousPayData.OpRetCode:type_name -> welfare.OpResultCode
|
0, // 21: welfare.SCWelfareContinuousPayData.OpRetCode:type_name -> welfare.OpResultCode
|
||||||
23, // 22: welfare.SCWelfareContinuousPayData.List:type_name -> welfare.WelfareSpree
|
23, // 22: welfare.SCWelfareContinuousPayData.List:type_name -> welfare.WelfareSpree
|
||||||
0, // 23: welfare.SCWelfareContinuousPay.OpRetCode:type_name -> welfare.OpResultCode
|
0, // 23: welfare.SCWelfareContinuousPay.OpRetCode:type_name -> welfare.OpResultCode
|
||||||
69, // 24: welfare.SCInviteInfo.PayScore:type_name -> welfare.SCInviteInfo.PayScoreEntry
|
74, // 24: welfare.SCInviteInfo.PayScore:type_name -> welfare.SCInviteInfo.PayScoreEntry
|
||||||
35, // 25: welfare.SCInviteInfo.Awards1:type_name -> welfare.RankAward
|
35, // 25: welfare.SCInviteInfo.Awards1:type_name -> welfare.RankAward
|
||||||
35, // 26: welfare.SCInviteInfo.Awards2:type_name -> welfare.RankAward
|
35, // 26: welfare.SCInviteInfo.Awards2:type_name -> welfare.RankAward
|
||||||
35, // 27: welfare.SCInviteInfo.Awards3:type_name -> welfare.RankAward
|
35, // 27: welfare.SCInviteInfo.Awards3:type_name -> welfare.RankAward
|
||||||
0, // 28: welfare.SCBindInvite.OpRetCode:type_name -> welfare.OpResultCode
|
0, // 28: welfare.SCBindInvite.OpRetCode:type_name -> welfare.OpResultCode
|
||||||
70, // 29: welfare.PigBankCoinInfo.GoldExc:type_name -> welfare.PigBankCoinInfo.GoldExcEntry
|
75, // 29: welfare.PigBankCoinInfo.GoldExc:type_name -> welfare.PigBankCoinInfo.GoldExcEntry
|
||||||
0, // 30: welfare.SCPigbankGetInfo.OpRetCode:type_name -> welfare.OpResultCode
|
0, // 30: welfare.SCPigbankGetInfo.OpRetCode:type_name -> welfare.OpResultCode
|
||||||
39, // 31: welfare.SCPigbankGetInfo.infoArr:type_name -> welfare.PigBankCoinInfo
|
39, // 31: welfare.SCPigbankGetInfo.infoArr:type_name -> welfare.PigBankCoinInfo
|
||||||
0, // 32: welfare.SCPigbankTakeCoin.OpRetCode:type_name -> welfare.OpResultCode
|
0, // 32: welfare.SCPigbankTakeCoin.OpRetCode:type_name -> welfare.OpResultCode
|
||||||
71, // 33: welfare.PigBankDiamondInfo.DiamondExc:type_name -> welfare.PigBankDiamondInfo.DiamondExcEntry
|
76, // 33: welfare.PigBankDiamondInfo.DiamondExc:type_name -> welfare.PigBankDiamondInfo.DiamondExcEntry
|
||||||
0, // 34: welfare.SCDiamondBankGetInfo.OpRetCode:type_name -> welfare.OpResultCode
|
0, // 34: welfare.SCDiamondBankGetInfo.OpRetCode:type_name -> welfare.OpResultCode
|
||||||
45, // 35: welfare.SCDiamondBankGetInfo.infoArr:type_name -> welfare.PigBankDiamondInfo
|
45, // 35: welfare.SCDiamondBankGetInfo.infoArr:type_name -> welfare.PigBankDiamondInfo
|
||||||
0, // 36: welfare.SCDiamondBankTakeDiamond.OpRetCode:type_name -> welfare.OpResultCode
|
0, // 36: welfare.SCDiamondBankTakeDiamond.OpRetCode:type_name -> welfare.OpResultCode
|
||||||
|
|
@ -5341,11 +5689,14 @@ var file_protocol_welfare_welfare_proto_depIdxs = []int32{
|
||||||
65, // 53: welfare.SCLotteryInfo.Last:type_name -> welfare.LotteryInfo
|
65, // 53: welfare.SCLotteryInfo.Last:type_name -> welfare.LotteryInfo
|
||||||
65, // 54: welfare.NotifyLotteryAward.Info:type_name -> welfare.LotteryInfo
|
65, // 54: welfare.NotifyLotteryAward.Info:type_name -> welfare.LotteryInfo
|
||||||
65, // 55: welfare.NotifyLotteryCode.Info:type_name -> welfare.LotteryInfo
|
65, // 55: welfare.NotifyLotteryCode.Info:type_name -> welfare.LotteryInfo
|
||||||
56, // [56:56] is the sub-list for method output_type
|
71, // 56: welfare.SCRedPacketInfo.Info:type_name -> welfare.RedPacketInfo
|
||||||
56, // [56:56] is the sub-list for method input_type
|
0, // 57: welfare.SCRedPacketDraw.OpRetCode:type_name -> welfare.OpResultCode
|
||||||
56, // [56:56] is the sub-list for extension type_name
|
49, // 58: welfare.SCRedPacketDraw.Award:type_name -> welfare.PropInfo
|
||||||
56, // [56:56] is the sub-list for extension extendee
|
59, // [59:59] is the sub-list for method output_type
|
||||||
0, // [0:56] is the sub-list for field type_name
|
59, // [59:59] is the sub-list for method input_type
|
||||||
|
59, // [59:59] is the sub-list for extension type_name
|
||||||
|
59, // [59:59] is the sub-list for extension extendee
|
||||||
|
0, // [0:59] is the sub-list for field type_name
|
||||||
}
|
}
|
||||||
|
|
||||||
func init() { file_protocol_welfare_welfare_proto_init() }
|
func init() { file_protocol_welfare_welfare_proto_init() }
|
||||||
|
|
@ -6158,6 +6509,66 @@ func file_protocol_welfare_welfare_proto_init() {
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
file_protocol_welfare_welfare_proto_msgTypes[67].Exporter = func(v interface{}, i int) interface{} {
|
||||||
|
switch v := v.(*CSRedPacketInfo); i {
|
||||||
|
case 0:
|
||||||
|
return &v.state
|
||||||
|
case 1:
|
||||||
|
return &v.sizeCache
|
||||||
|
case 2:
|
||||||
|
return &v.unknownFields
|
||||||
|
default:
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
}
|
||||||
|
file_protocol_welfare_welfare_proto_msgTypes[68].Exporter = func(v interface{}, i int) interface{} {
|
||||||
|
switch v := v.(*SCRedPacketInfo); i {
|
||||||
|
case 0:
|
||||||
|
return &v.state
|
||||||
|
case 1:
|
||||||
|
return &v.sizeCache
|
||||||
|
case 2:
|
||||||
|
return &v.unknownFields
|
||||||
|
default:
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
}
|
||||||
|
file_protocol_welfare_welfare_proto_msgTypes[69].Exporter = func(v interface{}, i int) interface{} {
|
||||||
|
switch v := v.(*RedPacketInfo); i {
|
||||||
|
case 0:
|
||||||
|
return &v.state
|
||||||
|
case 1:
|
||||||
|
return &v.sizeCache
|
||||||
|
case 2:
|
||||||
|
return &v.unknownFields
|
||||||
|
default:
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
}
|
||||||
|
file_protocol_welfare_welfare_proto_msgTypes[70].Exporter = func(v interface{}, i int) interface{} {
|
||||||
|
switch v := v.(*CSRedPacketDraw); i {
|
||||||
|
case 0:
|
||||||
|
return &v.state
|
||||||
|
case 1:
|
||||||
|
return &v.sizeCache
|
||||||
|
case 2:
|
||||||
|
return &v.unknownFields
|
||||||
|
default:
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
}
|
||||||
|
file_protocol_welfare_welfare_proto_msgTypes[71].Exporter = func(v interface{}, i int) interface{} {
|
||||||
|
switch v := v.(*SCRedPacketDraw); i {
|
||||||
|
case 0:
|
||||||
|
return &v.state
|
||||||
|
case 1:
|
||||||
|
return &v.sizeCache
|
||||||
|
case 2:
|
||||||
|
return &v.unknownFields
|
||||||
|
default:
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
type x struct{}
|
type x struct{}
|
||||||
out := protoimpl.TypeBuilder{
|
out := protoimpl.TypeBuilder{
|
||||||
|
|
@ -6165,7 +6576,7 @@ func file_protocol_welfare_welfare_proto_init() {
|
||||||
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
||||||
RawDescriptor: file_protocol_welfare_welfare_proto_rawDesc,
|
RawDescriptor: file_protocol_welfare_welfare_proto_rawDesc,
|
||||||
NumEnums: 2,
|
NumEnums: 2,
|
||||||
NumMessages: 70,
|
NumMessages: 75,
|
||||||
NumExtensions: 0,
|
NumExtensions: 0,
|
||||||
NumServices: 0,
|
NumServices: 0,
|
||||||
},
|
},
|
||||||
|
|
|
||||||
|
|
@ -84,6 +84,12 @@ enum SPacketID {
|
||||||
PACKET_SCLotteryInfo = 2927; // 抽奖信息
|
PACKET_SCLotteryInfo = 2927; // 抽奖信息
|
||||||
PACKET_NotifyLotteryAward = 2928; // 通知抽奖中奖
|
PACKET_NotifyLotteryAward = 2928; // 通知抽奖中奖
|
||||||
PACKET_NotifyLotteryCode = 2929; // 通知获得抽奖号码
|
PACKET_NotifyLotteryCode = 2929; // 通知获得抽奖号码
|
||||||
|
|
||||||
|
PACKET_CSRedPacketInfo = 2930; // 红包信息
|
||||||
|
PACKET_SCRedPacketInfo = 2931; // 红包信息
|
||||||
|
|
||||||
|
PACKET_CSRedPacketDraw = 2932; // 抽红包
|
||||||
|
PACKET_SCRedPacketDraw = 2933; // 抽红包
|
||||||
}
|
}
|
||||||
|
|
||||||
//救济金领取
|
//救济金领取
|
||||||
|
|
@ -556,4 +562,34 @@ message NotifyLotteryAward{
|
||||||
//PACKET_NotifyLotteryCode
|
//PACKET_NotifyLotteryCode
|
||||||
message NotifyLotteryCode{
|
message NotifyLotteryCode{
|
||||||
repeated LotteryInfo Info = 1;
|
repeated LotteryInfo Info = 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
// 红包信息
|
||||||
|
//PACKET_CSRedPacketInfo
|
||||||
|
message CSRedPacketInfo{
|
||||||
|
}
|
||||||
|
//PACKET_SCRedPacketInfo
|
||||||
|
message SCRedPacketInfo{
|
||||||
|
repeated RedPacketInfo Info = 1; // 红包信息
|
||||||
|
}
|
||||||
|
message RedPacketInfo{
|
||||||
|
int64 Id = 1; // id
|
||||||
|
int64 StartTs = 2; // 开始时间
|
||||||
|
int64 EndTs = 3; // 结束时间
|
||||||
|
int64 StayTs = 4; // 持续时长,单位秒;0代表不限制
|
||||||
|
int64 MaxCount = 5; // 最大领取次数;-1代表不限制
|
||||||
|
int64 RemainCount = 6; // 剩余次数;-1代表不限制
|
||||||
|
}
|
||||||
|
|
||||||
|
// 抽红包
|
||||||
|
//PACKET_CSRedPacketDraw
|
||||||
|
message CSRedPacketDraw{
|
||||||
|
int64 Id = 1; // id
|
||||||
|
}
|
||||||
|
//PACKET_SCRedPacketDraw
|
||||||
|
message SCRedPacketDraw{
|
||||||
|
OpResultCode OpRetCode = 1; // 错误码
|
||||||
|
int64 Id = 2; // id
|
||||||
|
repeated PropInfo Award = 3; // 奖励
|
||||||
|
int64 RemainCount = 4; // 剩余次数;-1代表不限制
|
||||||
}
|
}
|
||||||
|
|
@ -16,8 +16,8 @@ data_type 数据类型
|
||||||
3新用户平均局数
|
3新用户平均局数
|
||||||
4平均倍数
|
4平均倍数
|
||||||
5活跃破产率
|
5活跃破产率
|
||||||
start_time 开始时间
|
start_time 开始时间 格式:2024-12-26
|
||||||
end_time 结束时间
|
end_time 结束时间 格式:2024-12-26
|
||||||
*/
|
*/
|
||||||
|
|
||||||
// Download 下载
|
// Download 下载
|
||||||
|
|
|
||||||
|
|
@ -1344,6 +1344,40 @@ func CSClientUpgrades(s *netlib.Session, packetid int, data interface{}, sid int
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func CSRedPacketInfo(s *netlib.Session, packetid int, data interface{}, sid int64) error {
|
||||||
|
logger.Logger.Tracef("CSRedPacketInfo Process recv %v", data)
|
||||||
|
_, ok := data.(*welfare.CSRedPacketInfo)
|
||||||
|
if !ok {
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
||||||
|
p := PlayerMgrSington.GetOnlinePlayer(sid)
|
||||||
|
if p == nil {
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
||||||
|
pack := WelfareMgrSington.SendRedPacketInfo(p)
|
||||||
|
logger.Logger.Tracef("SCRedPacketInfo: %v", pack)
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
||||||
|
func CSRedPacketDraw(s *netlib.Session, packetid int, data interface{}, sid int64) error {
|
||||||
|
logger.Logger.Tracef("CSRedPacketDraw Process recv %v", data)
|
||||||
|
msg, ok := data.(*welfare.CSRedPacketDraw)
|
||||||
|
if !ok {
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
||||||
|
p := PlayerMgrSington.GetOnlinePlayer(sid)
|
||||||
|
if p == nil {
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
||||||
|
pack := WelfareMgrSington.GetRedPacket(p, msg.GetId())
|
||||||
|
logger.Logger.Tracef("SCRedPacketDraw: %v", pack)
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
||||||
func init() {
|
func init() {
|
||||||
// 领取救济金
|
// 领取救济金
|
||||||
common.RegisterHandler(int(welfare.SPacketID_PACKET_CS_WELF_GETRELIEFFUND), &CSGetReliefFundHandler{})
|
common.RegisterHandler(int(welfare.SPacketID_PACKET_CS_WELF_GETRELIEFFUND), &CSGetReliefFundHandler{})
|
||||||
|
|
@ -1411,4 +1445,8 @@ func init() {
|
||||||
common.Register(int(welfare.SPacketID_PACKET_CSPermitShop), welfare.CSPermitShop{}, CSPermitShop)
|
common.Register(int(welfare.SPacketID_PACKET_CSPermitShop), welfare.CSPermitShop{}, CSPermitShop)
|
||||||
// 客户端升级奖励信息
|
// 客户端升级奖励信息
|
||||||
common.Register(int(upgrade.PacketID_PACKET_CSClientUpgrades), upgrade.CSClientUpgrades{}, CSClientUpgrades)
|
common.Register(int(upgrade.PacketID_PACKET_CSClientUpgrades), upgrade.CSClientUpgrades{}, CSClientUpgrades)
|
||||||
|
// 红包活动信息
|
||||||
|
common.Register(int(welfare.SPacketID_PACKET_CSRedPacketInfo), welfare.CSRedPacketInfo{}, CSRedPacketInfo)
|
||||||
|
// 红包活动领取
|
||||||
|
common.Register(int(welfare.SPacketID_PACKET_CSRedPacketDraw), welfare.CSRedPacketDraw{}, CSRedPacketDraw)
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,185 @@
|
||||||
|
package main
|
||||||
|
|
||||||
|
import (
|
||||||
|
"fmt"
|
||||||
|
"golang.org/x/exp/maps"
|
||||||
|
"mongo.games.com/goserver/core/logger"
|
||||||
|
"time"
|
||||||
|
|
||||||
|
"mongo.games.com/goserver/core/module"
|
||||||
|
|
||||||
|
"mongo.games.com/game/common"
|
||||||
|
"mongo.games.com/game/model"
|
||||||
|
webapiproto "mongo.games.com/game/protocol/webapi"
|
||||||
|
)
|
||||||
|
|
||||||
|
var RedPacketMgrInst = &RedPacketMgr{
|
||||||
|
RedPacketData: make(map[string]map[int64]*model.RedPacket),
|
||||||
|
}
|
||||||
|
|
||||||
|
func init() {
|
||||||
|
module.RegisteModule(RedPacketMgrInst, time.Hour, 0)
|
||||||
|
|
||||||
|
common.RegisterClockFunc(&common.ClockFunc{
|
||||||
|
OnDayTimerFunc: func() {
|
||||||
|
RedPacketMgrInst.RedPacketData = make(map[string]map[int64]*model.RedPacket)
|
||||||
|
},
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
type RedPacketMgr struct {
|
||||||
|
RedPacketData map[string]map[int64]*model.RedPacket // 红包活动状态 平台:活动id:活动状态
|
||||||
|
}
|
||||||
|
|
||||||
|
func (m *RedPacketMgr) ModuleName() string {
|
||||||
|
return "RedPacketMgr"
|
||||||
|
}
|
||||||
|
|
||||||
|
func (m *RedPacketMgr) Init() {
|
||||||
|
// 加载红包配置
|
||||||
|
for _, v := range PlatformMgrSingleton.GetPlatforms() {
|
||||||
|
if v == nil || v.IdStr == common.Platform_Sys {
|
||||||
|
continue
|
||||||
|
}
|
||||||
|
list, err := model.GetRedPacketAll(v.IdStr)
|
||||||
|
if err != nil {
|
||||||
|
panic(fmt.Sprintf("GetRedPacketAll error: %v", err))
|
||||||
|
}
|
||||||
|
for _, v1 := range list {
|
||||||
|
if m.RedPacketData[v.IdStr] == nil {
|
||||||
|
m.RedPacketData[v.IdStr] = make(map[int64]*model.RedPacket)
|
||||||
|
}
|
||||||
|
m.RedPacketData[v.IdStr][v1.Cid] = &model.RedPacket{
|
||||||
|
Cid: v1.Cid,
|
||||||
|
Use: v1.Use,
|
||||||
|
Ts: v1.Ts,
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
func (m *RedPacketMgr) Update() {
|
||||||
|
}
|
||||||
|
|
||||||
|
func (m *RedPacketMgr) Shutdown() {
|
||||||
|
// 保存红包配置
|
||||||
|
for k, v := range m.RedPacketData {
|
||||||
|
if err := model.UpdateRedPacketAll(k, maps.Values(v)); err != nil {
|
||||||
|
logger.Logger.Errorf("UpdateRedPacketAll error: %v", err)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
module.UnregisteModule(m)
|
||||||
|
}
|
||||||
|
|
||||||
|
// GetRemainReward 获取剩余奖励数量
|
||||||
|
func (m *RedPacketMgr) GetRemainReward(plt string, id int64) int64 {
|
||||||
|
v, ok := m.RedPacketData[plt]
|
||||||
|
if !ok {
|
||||||
|
v = make(map[int64]*model.RedPacket)
|
||||||
|
m.RedPacketData[plt] = v
|
||||||
|
}
|
||||||
|
d, ok := v[id]
|
||||||
|
if !ok {
|
||||||
|
d = &model.RedPacket{
|
||||||
|
Cid: id,
|
||||||
|
Use: make(map[int64]int64),
|
||||||
|
Ts: time.Now().Unix(),
|
||||||
|
}
|
||||||
|
v[id] = d
|
||||||
|
}
|
||||||
|
|
||||||
|
cfg := WelfareMgrSington.GetConfig(plt).RedPacketConfig
|
||||||
|
if cfg == nil {
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
|
||||||
|
for _, v := range cfg.GetList() {
|
||||||
|
if v.Id == id {
|
||||||
|
total := 0
|
||||||
|
for k1, v1 := range d.Use {
|
||||||
|
total += int(k1 * v1)
|
||||||
|
}
|
||||||
|
|
||||||
|
ret := v.GetTotalNum() - int64(total)
|
||||||
|
if ret < 0 {
|
||||||
|
ret = 0
|
||||||
|
}
|
||||||
|
return ret
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return 0
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
// GetRemainTimes 获取剩余次数
|
||||||
|
// 返回最大次数和剩余次数
|
||||||
|
func (m *RedPacketMgr) GetRemainTimes(p *Player, id int64) (int64, int64) {
|
||||||
|
var cfg *webapiproto.RedPacketInfo
|
||||||
|
for _, v := range WelfareMgrSington.GetConfig(p.Platform).RedPacketConfig.GetList() {
|
||||||
|
if v.GetId() == id {
|
||||||
|
cfg = v
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return m.GetRemainTimesByConfig(p, cfg)
|
||||||
|
}
|
||||||
|
|
||||||
|
// GetRemainTimesByConfig 获取剩余次数
|
||||||
|
// 返回最大次数和剩余次数
|
||||||
|
func (m *RedPacketMgr) GetRemainTimesByConfig(p *Player, cfg *webapiproto.RedPacketInfo) (int64, int64) {
|
||||||
|
if cfg == nil {
|
||||||
|
return 0, 0
|
||||||
|
}
|
||||||
|
|
||||||
|
var limit int32
|
||||||
|
if cfg.GetPlayerLimit() > 0 && cfg.GetMaxCount() > 0 {
|
||||||
|
if cfg.GetPlayerLimit() < int32(cfg.GetMaxCount()) {
|
||||||
|
limit = cfg.GetPlayerLimit()
|
||||||
|
} else {
|
||||||
|
limit = int32(cfg.GetMaxCount())
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
if cfg.GetPlayerLimit() > 0 {
|
||||||
|
limit = cfg.GetPlayerLimit()
|
||||||
|
}
|
||||||
|
if cfg.GetMaxCount() > 0 {
|
||||||
|
limit = int32(cfg.GetMaxCount())
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if limit <= 0 {
|
||||||
|
return -1, -1
|
||||||
|
}
|
||||||
|
n := 0
|
||||||
|
if p.WelfData != nil && p.WelfData.RedPacket != nil {
|
||||||
|
if _, exist := p.WelfData.RedPacket[cfg.GetId()]; exist {
|
||||||
|
n = p.WelfData.RedPacket[cfg.GetId()]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
remainCount := int64(limit) - int64(n)
|
||||||
|
if remainCount < 0 {
|
||||||
|
remainCount = 0
|
||||||
|
}
|
||||||
|
return int64(limit), remainCount
|
||||||
|
}
|
||||||
|
|
||||||
|
// AddUse 添加使用红包
|
||||||
|
func (m *RedPacketMgr) AddUse(plt string, id int64, n int64) {
|
||||||
|
v, ok := m.RedPacketData[plt]
|
||||||
|
if !ok {
|
||||||
|
v = make(map[int64]*model.RedPacket)
|
||||||
|
m.RedPacketData[plt] = v
|
||||||
|
}
|
||||||
|
d, ok := v[id]
|
||||||
|
if !ok {
|
||||||
|
d = &model.RedPacket{
|
||||||
|
Cid: id,
|
||||||
|
Use: make(map[int64]int64),
|
||||||
|
Ts: time.Now().Unix(),
|
||||||
|
}
|
||||||
|
v[id] = d
|
||||||
|
}
|
||||||
|
d.Use[n]++
|
||||||
|
d.Ts = time.Now().Unix()
|
||||||
|
}
|
||||||
|
|
@ -110,6 +110,8 @@ func init() {
|
||||||
etcd.Register(etcd.ETCDKEY_PigBankDiamond, webapi.GamePigBankDiamondConfig{}, platformConfigEvent)
|
etcd.Register(etcd.ETCDKEY_PigBankDiamond, webapi.GamePigBankDiamondConfig{}, platformConfigEvent)
|
||||||
// 存钱罐属性值
|
// 存钱罐属性值
|
||||||
etcd.Register(etcd.ETCDKEY_PigBankProp, webapi.GamePigBankPropConfig{}, platformConfigEvent)
|
etcd.Register(etcd.ETCDKEY_PigBankProp, webapi.GamePigBankPropConfig{}, platformConfigEvent)
|
||||||
|
// 红包配置
|
||||||
|
etcd.Register(etcd.ETCDKEY_REDPACKET, webapi.RedPacketConfig{}, platformConfigEvent)
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -356,6 +358,9 @@ func platformConfigEvent(ctx context.Context, completeKey string, isInit bool, e
|
||||||
PlatformMgrSingleton.GetConfig(config.Platform).GamePigBankDiamondConfig = config
|
PlatformMgrSingleton.GetConfig(config.Platform).GamePigBankDiamondConfig = config
|
||||||
case *webapi.GamePigBankPropConfig:
|
case *webapi.GamePigBankPropConfig:
|
||||||
PlatformMgrSingleton.GetConfig(config.Platform).GamePigBankPropConfig = config
|
PlatformMgrSingleton.GetConfig(config.Platform).GamePigBankPropConfig = config
|
||||||
|
case *webapi.RedPacketConfig:
|
||||||
|
WelfareMgrSington.UpdateRedPacket(config, isInit)
|
||||||
|
|
||||||
default:
|
default:
|
||||||
logger.Logger.Errorf("etcd completeKey:%s, Not processed", completeKey)
|
logger.Logger.Errorf("etcd completeKey:%s, Not processed", completeKey)
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -16,10 +16,11 @@ func RegisterPlayerListener[Player, Scene any](l PlayerListener[Player, Scene])
|
||||||
type PlayerListener[Player, Scene any] interface {
|
type PlayerListener[Player, Scene any] interface {
|
||||||
common.ClockSinker
|
common.ClockSinker
|
||||||
// 登出相关
|
// 登出相关
|
||||||
OnPlayerLogined(p Player) // 玩家登录时触发
|
OnPlayerLogined(p Player) // 玩家登录时触发
|
||||||
OnPlayerLogouted(p Player) // 玩家登出时触发
|
OnPlayerLogouted(p Player) // 玩家登出时触发
|
||||||
OnPlayerDropLine(p Player) // 玩家掉线时触发
|
OnPlayerDropLine(p Player) // 玩家掉线时触发
|
||||||
OnPlayerRehold(p Player) // 玩家重新连接时触发
|
OnPlayerRehold(p Player) // 玩家重新连接时触发
|
||||||
|
OnPlayerDayChanged(p Player, isLogin, isContinue bool) // 玩家跨天时触发
|
||||||
// 业务相关
|
// 业务相关
|
||||||
OnPlayerEnterSceneBefore(p Player, s Scene) // 玩家进入场景前触发
|
OnPlayerEnterSceneBefore(p Player, s Scene) // 玩家进入场景前触发
|
||||||
OnPlayerEnterSceneAfter(p Player, s Scene) // 玩家进入场景后触发
|
OnPlayerEnterSceneAfter(p Player, s Scene) // 玩家进入场景后触发
|
||||||
|
|
@ -61,6 +62,14 @@ func FirePlayerRehold[Player, Scene any](p Player) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func FirePlayerDayChanged[Player, Scene any](p Player, isLogin, isContinue bool) {
|
||||||
|
for _, l := range _playerListeners {
|
||||||
|
if l != nil {
|
||||||
|
l.(PlayerListener[Player, Scene]).OnPlayerDayChanged(p, isLogin, isContinue)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
func FirePlayerEnterSceneBefore[Player, Scene any](p Player, s Scene) {
|
func FirePlayerEnterSceneBefore[Player, Scene any](p Player, s Scene) {
|
||||||
for _, l := range _playerListeners {
|
for _, l := range _playerListeners {
|
||||||
if l != nil {
|
if l != nil {
|
||||||
|
|
@ -113,16 +122,17 @@ type BasePlayerListener[Player, Scene any] struct {
|
||||||
common.ClockFunc
|
common.ClockFunc
|
||||||
}
|
}
|
||||||
|
|
||||||
func (l *BasePlayerListener[Player, Scene]) OnPlayerLogined(p Player) {}
|
func (l *BasePlayerListener[Player, Scene]) OnPlayerLogined(p Player) {}
|
||||||
func (l *BasePlayerListener[Player, Scene]) OnPlayerLogouted(p Player) {}
|
func (l *BasePlayerListener[Player, Scene]) OnPlayerLogouted(p Player) {}
|
||||||
func (l *BasePlayerListener[Player, Scene]) OnPlayerDropLine(p Player) {}
|
func (l *BasePlayerListener[Player, Scene]) OnPlayerDropLine(p Player) {}
|
||||||
func (l *BasePlayerListener[Player, Scene]) OnPlayerRehold(p Player) {}
|
func (l *BasePlayerListener[Player, Scene]) OnPlayerRehold(p Player) {}
|
||||||
func (l *BasePlayerListener[Player, Scene]) OnPlayerEnterSceneBefore(p Player, s Scene) {}
|
func (l *BasePlayerListener[Player, Scene]) OnPlayerDayChanged(p Player, isLogin, isContinue bool) {}
|
||||||
func (l *BasePlayerListener[Player, Scene]) OnPlayerEnterSceneAfter(p Player, s Scene) {}
|
func (l *BasePlayerListener[Player, Scene]) OnPlayerEnterSceneBefore(p Player, s Scene) {}
|
||||||
func (l *BasePlayerListener[Player, Scene]) OnPlayerLeaveSceneBefore(p Player, s Scene) {}
|
func (l *BasePlayerListener[Player, Scene]) OnPlayerEnterSceneAfter(p Player, s Scene) {}
|
||||||
func (l *BasePlayerListener[Player, Scene]) OnPlayerLeaveSceneAfter(p Player, s Scene) {}
|
func (l *BasePlayerListener[Player, Scene]) OnPlayerLeaveSceneBefore(p Player, s Scene) {}
|
||||||
func (l *BasePlayerListener[Player, Scene]) OnPlayerReturnSceneBefore(p Player, s Scene) {}
|
func (l *BasePlayerListener[Player, Scene]) OnPlayerLeaveSceneAfter(p Player, s Scene) {}
|
||||||
func (l *BasePlayerListener[Player, Scene]) OnPlayerReturnSceneAfter(p Player, s Scene) {}
|
func (l *BasePlayerListener[Player, Scene]) OnPlayerReturnSceneBefore(p Player, s Scene) {}
|
||||||
|
func (l *BasePlayerListener[Player, Scene]) OnPlayerReturnSceneAfter(p Player, s Scene) {}
|
||||||
|
|
||||||
type PlayerListenerFunc[Player, Scene any] struct {
|
type PlayerListenerFunc[Player, Scene any] struct {
|
||||||
common.ClockFunc
|
common.ClockFunc
|
||||||
|
|
@ -130,6 +140,7 @@ type PlayerListenerFunc[Player, Scene any] struct {
|
||||||
OnPlayerLogoutedFunc func(p Player)
|
OnPlayerLogoutedFunc func(p Player)
|
||||||
OnPlayerDropLineFunc func(p Player)
|
OnPlayerDropLineFunc func(p Player)
|
||||||
OnPlayerReholdFunc func(p Player)
|
OnPlayerReholdFunc func(p Player)
|
||||||
|
OnPlayerDayChangedFunc func(p Player, isLogin, isContinue bool)
|
||||||
OnPlayerEnterSceneBeforeFunc func(p Player, s Scene)
|
OnPlayerEnterSceneBeforeFunc func(p Player, s Scene)
|
||||||
OnPlayerEnterSceneAfterFunc func(p Player, s Scene)
|
OnPlayerEnterSceneAfterFunc func(p Player, s Scene)
|
||||||
OnPlayerLeaveSceneBeforeFunc func(p Player, s Scene)
|
OnPlayerLeaveSceneBeforeFunc func(p Player, s Scene)
|
||||||
|
|
@ -162,6 +173,12 @@ func (l *PlayerListenerFunc[Player, Scene]) OnPlayerRehold(p Player) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func (l *PlayerListenerFunc[Player, Scene]) OnPlayerDayChanged(p Player, isLogin, isContinue bool) {
|
||||||
|
if l.OnPlayerDayChangedFunc != nil {
|
||||||
|
l.OnPlayerDayChangedFunc(p, isLogin, isContinue)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
func (l *PlayerListenerFunc[Player, Scene]) OnPlayerEnterSceneBefore(p Player, s Scene) {
|
func (l *PlayerListenerFunc[Player, Scene]) OnPlayerEnterSceneBefore(p Player, s Scene) {
|
||||||
if l.OnPlayerEnterSceneBeforeFunc != nil {
|
if l.OnPlayerEnterSceneBeforeFunc != nil {
|
||||||
l.OnPlayerEnterSceneBeforeFunc(p, s)
|
l.OnPlayerEnterSceneBeforeFunc(p, s)
|
||||||
|
|
@ -198,7 +215,7 @@ func (l *PlayerListenerFunc[Player, Scene]) OnPlayerReturnSceneAfter(p Player, s
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
func RegisterPlayerListenerFunc[P, S any](l *PlayerListenerFunc[P, S]) {
|
func RegisterPlayerListenerFunc[Player, Scene any](l *PlayerListenerFunc[Player, Scene]) {
|
||||||
common.RegisterClockFunc(&l.ClockFunc)
|
common.RegisterClockFunc(&l.ClockFunc)
|
||||||
RegisterPlayerListener(l)
|
RegisterPlayerListener(l)
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -17,7 +17,7 @@ type PlayerLoadReplay struct {
|
||||||
// 重连不会执行
|
// 重连不会执行
|
||||||
type IPlayerLoad interface {
|
type IPlayerLoad interface {
|
||||||
// Load 查询数据库,在task中执行
|
// Load 查询数据库,在task中执行
|
||||||
Load(platform string, snid int32, data any) *PlayerLoadReplay
|
Load(platform string, snid int32, playerBaseData any) *PlayerLoadReplay
|
||||||
// Callback 数据查询成功的回掉方法
|
// Callback 数据查询成功的回掉方法
|
||||||
Callback(data any, ret *PlayerLoadReplay)
|
Callback(data any, ret *PlayerLoadReplay)
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1646,20 +1646,16 @@ func (this *Player) OnDayTimer(login, continuous bool, t int) {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
this.lastOnDayChange = time.Now().Local()
|
this.lastOnDayChange = time.Now().Local()
|
||||||
|
this.dirty = true
|
||||||
|
|
||||||
logger.Logger.Infof("(this *Player) (%v) OnDayTimer(%v,%v) ", this.SnId, login, continuous)
|
logger.Logger.Infof("(this *Player) (%v) OnDayTimer(%v,%v) ", this.SnId, login, continuous)
|
||||||
|
|
||||||
this.dirty = true
|
internal.FirePlayerDayChanged[*Player, *Scene](this, login, continuous)
|
||||||
|
|
||||||
if login || this.scene == nil {
|
if login || this.scene == nil {
|
||||||
//跨天登录 数据给昨天,今天置为空
|
//跨天登录 数据给昨天,今天置为空
|
||||||
this.YesterdayGameData = this.TodayGameData
|
this.YesterdayGameData = this.TodayGameData
|
||||||
this.TodayGameData = model.NewPlayerGameCtrlData()
|
this.TodayGameData = model.NewPlayerGameCtrlData()
|
||||||
/*
|
|
||||||
for k, v := range this.YesterdayGameData.CtrlData {
|
|
||||||
t := &model.PlayerGameStatics{}
|
|
||||||
t.AvgBetCoin = v.AvgBetCoin
|
|
||||||
this.TodayGameData.CtrlData[k] = t
|
|
||||||
}
|
|
||||||
*/
|
|
||||||
}
|
}
|
||||||
|
|
||||||
//this.OnTimeDayTotal(continuous, t)
|
//this.OnTimeDayTotal(continuous, t)
|
||||||
|
|
@ -1667,8 +1663,6 @@ func (this *Player) OnDayTimer(login, continuous bool, t int) {
|
||||||
//商城数据更新
|
//商城数据更新
|
||||||
this.ShopTotal = make(map[int32]*model.ShopTotal)
|
this.ShopTotal = make(map[int32]*model.ShopTotal)
|
||||||
this.ShopLastLookTime = make(map[int32]int64)
|
this.ShopLastLookTime = make(map[int32]int64)
|
||||||
// 福利活动更新
|
|
||||||
WelfareMgrSington.OnDayChanged(this)
|
|
||||||
this.VipMatchTimes = 0
|
this.VipMatchTimes = 0
|
||||||
//VIP商城数据更新
|
//VIP商城数据更新
|
||||||
this.UpdateVipShopData()
|
this.UpdateVipShopData()
|
||||||
|
|
|
||||||
|
|
@ -3,6 +3,7 @@ package main
|
||||||
import (
|
import (
|
||||||
"fmt"
|
"fmt"
|
||||||
"math"
|
"math"
|
||||||
|
"slices"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"mongo.games.com/goserver/core/logger"
|
"mongo.games.com/goserver/core/logger"
|
||||||
|
|
@ -17,6 +18,7 @@ import (
|
||||||
webapi_proto "mongo.games.com/game/protocol/webapi"
|
webapi_proto "mongo.games.com/game/protocol/webapi"
|
||||||
"mongo.games.com/game/protocol/welfare"
|
"mongo.games.com/game/protocol/welfare"
|
||||||
"mongo.games.com/game/srvdata"
|
"mongo.games.com/game/srvdata"
|
||||||
|
"mongo.games.com/game/worldsrv/internal"
|
||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
|
|
@ -1114,11 +1116,11 @@ func (this *WelfareMgr) BlindBoxInfo(p *Player, bid int32) {
|
||||||
pack.MinId = blindBox.MinId
|
pack.MinId = blindBox.MinId
|
||||||
pack.Draw = 1
|
pack.Draw = 1
|
||||||
cyc := info.BlindBoxCycle
|
cyc := info.BlindBoxCycle
|
||||||
if p.WelfData.BlindBoxId == -1 {
|
if p.WelfData.BlindBoxId == -1 { // == 1代表当日循环
|
||||||
if cyc == 1 || blindBox.Cycle == model.WelfareOpen {
|
if cyc == 1 || blindBox.Cycle == model.WelfareOpen {
|
||||||
p.WelfData.BlindBoxId = 0
|
p.WelfData.BlindBoxId = 0
|
||||||
}
|
}
|
||||||
} // == 1代表当日循环
|
}
|
||||||
if p.WelfData.BlindBoxId == 0 { // 未领取过发随机Date
|
if p.WelfData.BlindBoxId == 0 { // 未领取过发随机Date
|
||||||
|
|
||||||
idx := bid
|
idx := bid
|
||||||
|
|
@ -2140,27 +2142,187 @@ func (this *WelfareMgr) UpdateDiamondBankData(p *Player, coinNum int64, isWin bo
|
||||||
logger.Logger.Tracef("玩家更新钻石存储罐数据 snid = %d,coinNum = %d,isWin = %s,当前钻石存储罐钻石数量:%f,本次增加钻石数量:%f", p.SnId, coinNum, isWin, p.WelfData.DiamondBank.BankDiamond, addDiamond)
|
logger.Logger.Tracef("玩家更新钻石存储罐数据 snid = %d,coinNum = %d,isWin = %s,当前钻石存储罐钻石数量:%f,本次增加钻石数量:%f", p.SnId, coinNum, isWin, p.WelfData.DiamondBank.BankDiamond, addDiamond)
|
||||||
}
|
}
|
||||||
|
|
||||||
func (this *WelfareMgr) Update() {
|
// UpdateRedPacket 更新红包配置
|
||||||
|
func (this *WelfareMgr) UpdateRedPacket(cfg *webapi_proto.RedPacketConfig, isInit bool) {
|
||||||
|
this.GetConfig(cfg.Platform).RedPacketConfig = cfg
|
||||||
|
if !isInit {
|
||||||
|
// 广播给客户端
|
||||||
|
for _, p := range PlayerMgrSington.players {
|
||||||
|
this.ReleaseRedPacket(p)
|
||||||
|
this.SendRedPacketInfo(p)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// ReleaseRedPacket 释放玩家红包数据
|
||||||
|
func (this *WelfareMgr) ReleaseRedPacket(p *Player) {
|
||||||
|
if p == nil || p.IsOffline() || p.IsRobot() {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
ids := make([]int64, 0)
|
||||||
|
for _, v := range this.GetConfig(p.Platform).RedPacketConfig.GetList() {
|
||||||
|
ids = append(ids, v.GetId())
|
||||||
|
}
|
||||||
|
delIds := make([]int64, 0)
|
||||||
|
if p.WelfData != nil && p.WelfData.RedPacket != nil {
|
||||||
|
for k, _ := range p.WelfData.RedPacket {
|
||||||
|
if !slices.Contains(ids, k) {
|
||||||
|
delIds = append(delIds, k)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
for _, v := range delIds {
|
||||||
|
delete(p.WelfData.RedPacket, v)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// SendRedPacketInfo 发送红包信息
|
||||||
|
func (this *WelfareMgr) SendRedPacketInfo(p *Player) *welfare.SCRedPacketInfo {
|
||||||
|
if p == nil || p.IsOffline() || p.IsRobot() {
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
||||||
|
pack := &welfare.SCRedPacketInfo{}
|
||||||
|
now := time.Now().Unix()
|
||||||
|
for _, v := range this.GetConfig(p.Platform).RedPacketConfig.GetList() {
|
||||||
|
if v.GetOn() != common.On {
|
||||||
|
continue
|
||||||
|
}
|
||||||
|
startTs, endTs := common.IntToTime(int(v.GetStartHMS())).Unix(), common.IntToTime(int(v.GetEndHMS())).Unix()
|
||||||
|
if now < startTs || now >= endTs {
|
||||||
|
continue
|
||||||
|
}
|
||||||
|
info := &welfare.RedPacketInfo{
|
||||||
|
Id: v.GetId(),
|
||||||
|
StartTs: startTs,
|
||||||
|
EndTs: endTs,
|
||||||
|
StayTs: v.GetStayTs(),
|
||||||
|
}
|
||||||
|
info.MaxCount, info.RemainCount = RedPacketMgrInst.GetRemainTimesByConfig(p, v)
|
||||||
|
if info.RemainCount > 0 {
|
||||||
|
pack.Info = append(pack.Info, info)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
p.SendToClient(int(welfare.SPacketID_PACKET_SCRedPacketInfo), pack)
|
||||||
|
return pack
|
||||||
|
}
|
||||||
|
|
||||||
|
// GetRedPacket 抽红包
|
||||||
|
// id 红包活动id
|
||||||
|
func (this *WelfareMgr) GetRedPacket(p *Player, id int64) *welfare.SCRedPacketDraw {
|
||||||
|
if p == nil || p.IsOffline() {
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
pack := &welfare.SCRedPacketDraw{
|
||||||
|
OpRetCode: welfare.OpResultCode_OPRC_Error,
|
||||||
|
Id: id,
|
||||||
|
}
|
||||||
|
Send := func(code welfare.OpResultCode) {
|
||||||
|
pack.OpRetCode = code
|
||||||
|
p.SendToClient(int(welfare.SPacketID_PACKET_SCRedPacketDraw), pack)
|
||||||
|
}
|
||||||
|
|
||||||
|
var cfg *webapi_proto.RedPacketInfo
|
||||||
|
for _, v := range this.GetConfig(p.Platform).RedPacketConfig.GetList() {
|
||||||
|
if v.GetId() == id {
|
||||||
|
cfg = v
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
now := time.Now().Unix()
|
||||||
|
if cfg == nil || cfg.GetOn() != common.On ||
|
||||||
|
now < common.IntToTime(int(cfg.GetStartHMS())).Unix() || now >= common.IntToTime(int(cfg.GetEndHMS())).Unix() {
|
||||||
|
Send(welfare.OpResultCode_OPRC_Error)
|
||||||
|
return pack
|
||||||
|
}
|
||||||
|
|
||||||
|
// 次数限制
|
||||||
|
n := 0
|
||||||
|
if p.WelfData != nil && p.WelfData.RedPacket != nil {
|
||||||
|
if _, exist := p.WelfData.RedPacket[id]; exist {
|
||||||
|
n = p.WelfData.RedPacket[id]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if cfg.GetPlayerLimit() > 0 && n >= int(cfg.GetPlayerLimit()) {
|
||||||
|
Send(welfare.OpResultCode_OPRC_NoTimes)
|
||||||
|
return pack
|
||||||
|
}
|
||||||
|
if cfg.GetMaxCount() > 0 && cfg.GetMaxCount() <= int64(n) {
|
||||||
|
Send(welfare.OpResultCode_OPRC_NoTimes)
|
||||||
|
return pack
|
||||||
|
}
|
||||||
|
|
||||||
|
// 余额检查
|
||||||
|
var reward int64 // 红包奖金
|
||||||
|
remain := RedPacketMgrInst.GetRemainReward(p.Platform, id)
|
||||||
|
if remain <= 0 {
|
||||||
|
// 空奖
|
||||||
|
} else {
|
||||||
|
// 保底计算
|
||||||
|
|
||||||
|
// 概率抽奖
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
if p.WelfData != nil {
|
||||||
|
p.WelfData.RedPacket[id]++
|
||||||
|
RedPacketMgrInst.AddUse(p.Platform, id, reward)
|
||||||
|
if reward > 0 {
|
||||||
|
BagMgrSingleton.AddItems(&model.AddItemParam{
|
||||||
|
Platform: p.Platform,
|
||||||
|
SnId: p.GetSnId(),
|
||||||
|
Change: []*model.Item{{ItemId: cfg.GetItemId(), ItemNum: reward}},
|
||||||
|
GainWay: common.GainWayRedPacket,
|
||||||
|
Operator: "system",
|
||||||
|
Remark: "红包奖励",
|
||||||
|
})
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
//todo 抽奖记录
|
||||||
|
|
||||||
|
_, pack.RemainCount = RedPacketMgrInst.GetRemainTimesByConfig(p, cfg)
|
||||||
|
p.SendToClient(int(welfare.SPacketID_PACKET_SCRedPacketDraw), pack)
|
||||||
|
return pack
|
||||||
|
}
|
||||||
|
|
||||||
|
func (this *WelfareMgr) Update() {
|
||||||
}
|
}
|
||||||
|
|
||||||
func (this *WelfareMgr) Shutdown() {
|
func (this *WelfareMgr) Shutdown() {
|
||||||
module.UnregisteModule(this)
|
module.UnregisteModule(this)
|
||||||
}
|
}
|
||||||
|
|
||||||
func (this *WelfareMgr) OnDayTimer() {
|
|
||||||
for _, v := range this.GetConfigs() {
|
|
||||||
v.BlindBoxCycle = 0
|
|
||||||
v.FirstPayCycle = 0
|
|
||||||
v.ContinuousPayCycle = 0
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
func (this *WelfareMgr) InterestClockEvent() int {
|
|
||||||
return (1 << common.ClockEventMax) - 1
|
|
||||||
}
|
|
||||||
|
|
||||||
func init() {
|
func init() {
|
||||||
module.RegisteModule(WelfareMgrSington, time.Second, 0)
|
module.RegisteModule(WelfareMgrSington, time.Second, 0)
|
||||||
common.ClockMgrSingleton.RegisterSinker(WelfareMgrSington)
|
|
||||||
|
internal.RegisterPlayerListenerFunc(&internal.PlayerListenerFunc[*Player, *Scene]{
|
||||||
|
ClockFunc: common.ClockFunc{
|
||||||
|
OnDayTimerFunc: func() {
|
||||||
|
for _, v := range WelfareMgrSington.GetConfigs() {
|
||||||
|
v.BlindBoxCycle = 0
|
||||||
|
v.FirstPayCycle = 0
|
||||||
|
v.ContinuousPayCycle = 0
|
||||||
|
}
|
||||||
|
},
|
||||||
|
},
|
||||||
|
|
||||||
|
OnPlayerLoginedFunc: func(p *Player) {
|
||||||
|
WelfareMgrSington.SendRedPacketInfo(p)
|
||||||
|
},
|
||||||
|
|
||||||
|
OnPlayerReholdFunc: func(p *Player) {
|
||||||
|
WelfareMgrSington.SendRedPacketInfo(p)
|
||||||
|
},
|
||||||
|
|
||||||
|
OnPlayerDayChangedFunc: func(p *Player, isLogin, isContinue bool) {
|
||||||
|
if p.WelfData != nil && p.WelfData.RedPacket != nil {
|
||||||
|
p.WelfData.RedPacket = make(map[int64]int)
|
||||||
|
}
|
||||||
|
WelfareMgrSington.OnDayChanged(p)
|
||||||
|
},
|
||||||
|
})
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue