From fb2a940dad8a306fc550224d4aa13335fdbd6f7a Mon Sep 17 00:00:00 2001 From: 王家文 Date: Thu, 18 Apr 2024 20:06:22 +0800 Subject: [PATCH] feat✨:游戏功能配置 --- configs/confcardholder/get.go | 29 +---------------------------- 1 file changed, 1 insertion(+), 28 deletions(-) diff --git a/configs/confcardholder/get.go b/configs/confcardholder/get.go index 78e8fd2..81023d1 100644 --- a/configs/confcardholder/get.go +++ b/configs/confcardholder/get.go @@ -6,36 +6,9 @@ import ( // GetCurrent 获取 当前配置 func GetCurrent(gameId string) (conf *ActivityConfig, has bool) { - //currentKey := fmt.Sprintf("%s:%s:%s:current", - // svconst.REDIS_CACHEP_REFIX, - // svconst.MYSQL_TABLE_S_CARDHOLDER_CONFIG, - // gameId) - //currentId := zredis.GetInt64(zredis.GetConn(), currentKey) - //timeNow := lxtime.NowUninx() - //confRaw := new(ActivityConfigRaw) - //hasFind := false - //if currentId == 0 { - // hasFind = confbase.FindDuringTime(confRaw, gameId) - //} else { - // conf, has = GetConfig(gameId, currentId) - // if has { - // if timeNow < conf.StartTime || timeNow > conf.EndTime { - // hasFind = confbase.FindDuringTime(confRaw, gameId) - // } - // } else { - // hasFind = confbase.FindDuringTime(confRaw, gameId) - // } - //} - //if hasFind { - // conf = new(ActivityConfig) - // conf.Decode(gameId, confRaw) - // svredis.SaveData(gameId, conf) - // has = true - // currentId = conf.Id - // _ = zredis.Set(zredis.GetConn(), currentKey, utstring.Int64ToString(currentId)) - //} conf = new(ActivityConfig) has = confbase.GetCurrent[*ActivityConfig, ActivityConfigRaw](gameId, conf) + return } -- libgit2 0.21.0