少年修仙传客户端代码仓库
hch
2025-03-03 28785d6ddf9c08e49527ede9405c7b6c93c6ed32
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 TreasureCntAwardConfig : IConfigPostProcess
{
    //<寻宝类型,<奖励记录索引,条目ID>>
    static Dictionary<int, Dictionary<int, int>> idDict = new Dictionary<int, Dictionary<int, int>>();
 
    public void OnConfigParseCompleted()
    {
        if (!idDict.ContainsKey(TreasureType))
            idDict[TreasureType] = new Dictionary<int, int>();
        idDict[TreasureType][AwardIndex] = ID;
    }
 
    public static Dictionary<int, int> GetAwardIndexDict(int treasureType)
    {
        Dictionary<int, int> awardIndexDict;
        idDict.TryGetValue(treasureType, out awardIndexDict);
        return awardIndexDict;
    }
}