From b1298fe25fa2d37e5f35c36a7af4d0a762598595 Mon Sep 17 00:00:00 2001 From: sk <123456@qq.com> Date: Fri, 27 Sep 2024 15:17:40 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E9=9D=9E=E9=A6=96=E6=AC=A1?= =?UTF-8?q?=E7=99=BB=E5=BD=95=E6=A0=87=E8=AE=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- common/constant.go | 12 +++++++++--- model/player.go | 17 +++++------------ protocol/player/player.pb.go | 2 +- protocol/player/player.proto | 2 +- worldsrv/action_player.go | 5 +++++ worldsrv/action_server.go | 8 +------- 6 files changed, 22 insertions(+), 24 deletions(-) diff --git a/common/constant.go b/common/constant.go index e28931a..fdc1687 100644 --- a/common/constant.go +++ b/common/constant.go @@ -807,9 +807,10 @@ var ( ) const ( - AttributeGuideStep = 1 // 引导步骤 - AttributeGuideSkip = 2 // 跳过引导 - AttributeGuideTest = 3 // 测试引导 + AttributeGuideStep = 1 // 引导步骤 + AttributeGuideSkip = 2 // 跳过引导 + AttributeGuideTest = 3 // 测试引导 + AttributeGuideCustom = 4 // 竞技馆引导页 ) const ( @@ -861,3 +862,8 @@ const ( PlayerChangeTypeCoin = 0 // 金币 PlayerChangeTypeNum = 1 // 积分 ) + +// 玩家状态标记 +const ( + PlayerFlagsGuideCustom = 1 << iota // 竞技馆引导页关闭状态 +) diff --git a/model/player.go b/model/player.go index 27cf053..3d8c6c5 100644 --- a/model/player.go +++ b/model/player.go @@ -29,13 +29,6 @@ const ( VER_PLAYER_MAX ) -const ( - PLAYER_FLAGS_PRIVILEGE int64 = 1 << iota - PLAYER_FLAGS_FIRSTGAME //首次游戏 - PLAYER_FLAGS_FIRSTBINDTEL //首次绑定账号 - PLAYER_FLAGS_CANREBATE //是否能够返利 -) - const ( DEFAULT_PLAYER_SAFEBOX_PWD = "" //保险箱默认密码 ) @@ -402,7 +395,7 @@ type PlayerData struct { InviterHead int32 //邀请人头像 BeUnderAgentCode string //隶属经销商(推广人) SubBeUnderAgentCode string //经销商子id - Flags int64 //标记 + Flags int //标记 GameCoinTs int64 //游服金币对账时间戳 Ver int32 //数据版本号 CheckSum uint32 //校验码(预防暴库修改数据) @@ -501,7 +494,7 @@ type PlayerData struct { DiamondLotteryScore int64 //钻石抽奖幸运值 VCardCost int64 // 消耗v卡数量 MoneyTotal int64 // 现金总充值金额,不包含api加币时的现金 - GuideStep int32 // 引导步骤;跳过引导后,该值会置为-1 + GuideStep int32 // tienlen游戏引导步骤;跳过引导后,该值会置为-1 } // 七日签到数据 @@ -802,15 +795,15 @@ func ConvertPlayerDataToWebData(param *WebPlayerDataParam) *webapi.PlayerData { return pdfw } func (this *PlayerData) IsMarkFlag(flag int) bool { - return this.Flags&(1<= 3 { - if p.Flags&model.PLAYER_FLAGS_PRIVILEGE == 0 { - p.Flags |= model.PLAYER_FLAGS_PRIVILEGE - } else { - p.Flags &= ^model.PLAYER_FLAGS_PRIVILEGE - } - } + } } }