hch
2025-12-09 c3bbfe2736a773f9f03fa25c0575608e9ee6c13c
Main/System/OSActivity/OSActivityManager.cs
@@ -13,11 +13,14 @@
    public List<int> osHeroCallGiftSortList = new List<int>();    //开服招募礼包 充值ID + 100000000
    //开服榜对应的功能ID
    Dictionary<int, int> rankTypeToFuncID = new Dictionary<int, int>()
    {
        {3, 45},
        {4, 46},
    };
    public override void Init()
    {
@@ -38,6 +41,8 @@
    void BeforePlayerDataInitialize()
    {
        osGalaScore = 0; //当前积分 累计的;消耗的是货币55
        osGalaAwardState = 0; //按位记录是否领取
    }
    void ParseConfig()
@@ -60,6 +65,9 @@
            osHeroCallGiftSortList.Add(_list[i] + 100000000);
        }
        config = FuncConfigConfig.Get("OSACelebration");
        osGalaOpenDays = int.Parse(config.Numerical1);
        osGalaScoreAwards = ConfigParse.ParseIntArray2Dict(config.Numerical2);
    }
    // 开服排行活动是否开启
@@ -187,4 +195,32 @@
                break;
        }
    }
    #region 开服庆典
    //开服庆典
    public int osGalaOpenDays = 0; //持续天数
    public Dictionary<int, int[][]> osGalaScoreAwards = new Dictionary<int, int[][]>();  // 开服庆典积分奖励
    public int osGalaScore = 0; //当前积分 累计的;消耗的是货币55
    public int osGalaAwardState = 0; //按位记录是否领取
    public event Action OnOSGalaDataChangeEvent;
    public void UpdateOSGalaData(HAB05_tagSCOSACelebrationInfo netPack)
    {
        osGalaScore = (int)netPack.PointTotal;
        osGalaAwardState = (int)netPack.PointAward;
        OnOSGalaDataChangeEvent?.Invoke();
    }
    public bool IsOpenedOSGala()
    {
        if (!FuncOpen.Instance.IsFuncOpen((int)FuncOpenEnum.OSGala))
        {
            return false;
        }
        //结束后延迟一天关闭展示
        return TimeUtility.OpenDay <= osGalaOpenDays;
    }
    #endregion
}