lcy
2026-06-10 bcbbdae9f85dbb3efd58f0eaafe9f548caa5d923
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
using System.Collections.Generic;
 
public partial class FamilyAtkDefBatDefenderConfig : ConfigBase<int, FamilyAtkDefBatDefenderConfig>
{
    /// <summary>获取指定防守类型的总星数</summary>
    public static int GetTotalStarCount(int defType)
    {
        var config = Get(defType);
        if (config == null || config.DefStarList == null) return 0;
        int total = 0;
        for (int i = 0; i < config.DefStarList.Length; i++)
            total += config.DefStarList[i];
        return total;
    }
 
    /// <summary>获取指定防守类型的星数列表</summary>
    public static int[] GetDefStarList(int defType)
    {
        return Get(defType)?.DefStarList;
    }
}