43 lines
1.2 KiB
C#
43 lines
1.2 KiB
C#
//------------------------------------------------------------------------------
|
|
// <auto-generated>
|
|
// This code was generated by a tool.
|
|
// Changes to this file may cause incorrect behavior and will be lost if
|
|
// the code is regenerated.
|
|
// </auto-generated>
|
|
//------------------------------------------------------------------------------
|
|
using Bright.Serialization;
|
|
using System.Collections.Generic;
|
|
using asap.core;
|
|
using GameCore;
|
|
using SimpleJSON;
|
|
using UnityEngine;
|
|
|
|
|
|
namespace cfg
|
|
{
|
|
|
|
public sealed partial class EventPackManager
|
|
{
|
|
public List<int> GetPackIDsByCurrentVipLevel()
|
|
{
|
|
var vipLevel = GContext.container.Resolve<PlayerData>().PriceLv;
|
|
return GetPackIDsByVipLevel(vipLevel);
|
|
}
|
|
public List<int> GetPackIDsByVipLevel(int vipLevel)
|
|
{
|
|
if (vipLevel < 0)
|
|
{
|
|
Debug.LogError($" 获取VIP等级对应的礼包ID列表 错误 vipLevel {vipLevel}");
|
|
return null;
|
|
}
|
|
|
|
if (vipLevel >= VIPPackList.Count)
|
|
{
|
|
Debug.LogWarning($" 获取VIP等级对应的礼包ID列表 错误 vipLevel {vipLevel} VIPPackList.Count {VIPPackList.Count}");
|
|
return VIPPackList[^1];
|
|
}
|
|
return VIPPackList[vipLevel];
|
|
}
|
|
}
|
|
}
|