using System; using System.Collections.Generic; using ET; namespace GFGGame { public class StoryLevelCfgArray : SingletonBaseET { public Dictionary LevelCountDIc = new Dictionary(); public void StartScan() { Instance.LevelCountDIc.Clear(); var dataArray = CommonDataManager.Tables.TblStoryLevelCfg.DataList; foreach (var cfg in dataArray) { var key = CalculateHelper.GenerateInstanceZonesLevelStateKey(cfg.Type, cfg.SubType, cfg.ChapterId); Instance.LevelCountDIc.TryGetValue(key, out int count); count++; Instance.LevelCountDIc[key] = count; } } } }