Main/Config/PartialConfigs/MainLevelConfig.cs
@@ -46,12 +46,16 @@ return waveLineupLists.Count(list => list.Length > 0); } static List<int> allLevels = new List<int>(); // 获取目标关卡的索引 public static int GetToTargetLevelIndex(int targetLevel) { var levels = GetKeys(); levels.Sort(); return levels.IndexOf(targetLevel); if (allLevels.IsNullOrEmpty()) { allLevels = GetKeys(); allLevels.Sort(); } return allLevels.IndexOf(targetLevel); }