lcy
1 天以前 e1757b8dac92acd3063b203e12390ccab30c9ffe
262 幻境阁-客户端 支持配表排序
13个文件已修改
75 ■■■■ 已修改文件
Main/Config/Configs/ChatBubbleBoxConfig.cs 5 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Main/Config/Configs/ModelConfig.cs 5 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Main/Config/Configs/PlayerFaceConfig.cs 5 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Main/Config/Configs/PlayerFacePicConfig.cs 5 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Main/Config/Configs/TitleConfig.cs 5 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Main/System/PhantasmPavilion/IPhantasmPavilionTabHandler.cs 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Main/System/PhantasmPavilion/PhantasmPavilionChatBoxHandler.cs 5 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Main/System/PhantasmPavilion/PhantasmPavilionFaceHandler.cs 5 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Main/System/PhantasmPavilion/PhantasmPavilionFacePicHandler.cs 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Main/System/PhantasmPavilion/PhantasmPavilionManager.LoadConfig.cs 8 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Main/System/PhantasmPavilion/PhantasmPavilionManager.cs 17 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Main/System/PhantasmPavilion/PhantasmPavilionModelHandler.cs 5 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Main/System/PhantasmPavilion/PhantasmPavilionTitleHandler.cs 5 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Main/Config/Configs/ChatBubbleBoxConfig.cs
@@ -1,6 +1,6 @@
//--------------------------------------------------------
//    [Author]:           YYL
//    [  Date ]:           2025年12月1日
//    [  Date ]:           2026年3月17日
//--------------------------------------------------------
using System.Collections.Generic;
@@ -35,6 +35,7 @@
    public int Top;
    public int[] MyColor;
    public int[] OtherColor;
    public int SortIndex;
    public override int LoadKey(string _key)
    {
@@ -167,6 +168,8 @@
                     int.TryParse(OtherColorStringArray[i],out OtherColor[i]);
                }
            }
            int.TryParse(tables[19],out SortIndex);
        }
        catch (Exception exception)
        {
Main/Config/Configs/ModelConfig.cs
@@ -1,6 +1,6 @@
//--------------------------------------------------------
//    [Author]:           YYL
//    [  Date ]:           2025年11月25日
//    [  Date ]:           2026年3月17日
//--------------------------------------------------------
using System.Collections.Generic;
@@ -31,6 +31,7 @@
    public int[] InitAttrValueList;
    public int[] AttrPerStarAddList;
    public string GetWayString;
    public int SortIndex;
    public override int LoadKey(string _key)
    {
@@ -107,6 +108,8 @@
            }
            GetWayString = tables[14];
            int.TryParse(tables[15],out SortIndex);
        }
        catch (Exception exception)
        {
Main/Config/Configs/PlayerFaceConfig.cs
@@ -1,6 +1,6 @@
//--------------------------------------------------------
//    [Author]:           YYL
//    [  Date ]:           Wednesday, November 19, 2025
//    [  Date ]:           2026年3月17日
//--------------------------------------------------------
using System.Collections.Generic;
@@ -31,6 +31,7 @@
    public int[] InitAttrValueList;
    public int[] AttrPerStarAddList;
    public string GetWayString;
    public int SortIndex;
    public override int LoadKey(string _key)
    {
@@ -107,6 +108,8 @@
            }
            GetWayString = tables[14];
            int.TryParse(tables[15],out SortIndex);
        }
        catch (Exception exception)
        {
Main/Config/Configs/PlayerFacePicConfig.cs
@@ -1,6 +1,6 @@
//--------------------------------------------------------
//    [Author]:           YYL
//    [  Date ]:           2025年11月16日
//    [  Date ]:           2026年3月17日
//--------------------------------------------------------
using System.Collections.Generic;
@@ -30,6 +30,7 @@
    public int[] InitAttrValueList;
    public int[] AttrPerStarAddList;
    public string GetWayString;
    public int SortIndex;
    public override int LoadKey(string _key)
    {
@@ -104,6 +105,8 @@
            }
            GetWayString = tables[13];
            int.TryParse(tables[14],out SortIndex);
        }
        catch (Exception exception)
        {
Main/Config/Configs/TitleConfig.cs
@@ -1,6 +1,6 @@
//--------------------------------------------------------
//    [Author]:           YYL
//    [  Date ]:           Saturday, March 14, 2026
//    [  Date ]:           2026年3月17日
//--------------------------------------------------------
using System.Collections.Generic;
@@ -35,6 +35,7 @@
    public int EffValue;
    public int EffPerStarAdd;
    public string GetWayString;
    public int SortIndex;
    public override int LoadKey(string _key)
    {
@@ -119,6 +120,8 @@
            int.TryParse(tables[17],out EffPerStarAdd); 
            GetWayString = tables[18];
            int.TryParse(tables[19],out SortIndex);
        }
        catch (Exception exception)
        {
Main/System/PhantasmPavilion/IPhantasmPavilionTabHandler.cs
@@ -17,4 +17,5 @@
    int[] GetInitAttrValueList(int id);
    int[] GetAttrPerStarAddList(int id);
    string GetGetWayString(int id);
    int GetSortIndex(int id);
}
Main/System/PhantasmPavilion/PhantasmPavilionChatBoxHandler.cs
@@ -63,5 +63,8 @@
    {
        return ChatBubbleBoxConfig.Get(id).GetWayString;
    }
    public int GetSortIndex(int id)
    {
        return ChatBubbleBoxConfig.Get(id).SortIndex;
    }
}
Main/System/PhantasmPavilion/PhantasmPavilionFaceHandler.cs
@@ -63,5 +63,8 @@
    {
        return PlayerFaceConfig.Get(id).GetWayString;
    }
    public int GetSortIndex(int id)
    {
        return PlayerFaceConfig.Get(id).SortIndex;
    }
}
Main/System/PhantasmPavilion/PhantasmPavilionFacePicHandler.cs
@@ -64,4 +64,8 @@
    {
        return PlayerFacePicConfig.Get(id).GetWayString;
    }
    public int GetSortIndex(int id)
    {
        return PlayerFacePicConfig.Get(id).SortIndex;
    }
}
Main/System/PhantasmPavilion/PhantasmPavilionManager.LoadConfig.cs
@@ -128,4 +128,12 @@
            return string.Empty;
        return handler.GetGetWayString(id);
    }
    public int GetSortIndex(PhantasmPavilionType type, int id)
    {
        if (!TryGetHandlerValue(type, out var handler))
            return 0;
        if (!Has(type, id))
            return 0;
        return handler.GetSortIndex(id);
    }
}
Main/System/PhantasmPavilion/PhantasmPavilionManager.cs
@@ -336,7 +336,7 @@
                Debug.LogError($"TitleConfig.Get(id) is null, id: {id}");
                return false;
            }
            if(cfg.EffType > 0)
            if (cfg.EffType > 0)
                return true;
        }
        if (!Has(type, id))
@@ -407,7 +407,7 @@
    public int Cmp(int a, int b, PhantasmPavilionType type)
    {
        // 获取 a 和 b 的解锁状态
        // 1. 获取 a 和 b 的解锁状态
        int stateA = (int)GetUnLockState(type, a);
        int stateB = (int)GetUnLockState(type, b);
@@ -415,11 +415,22 @@
        int priorityA = stateA == 2 ? 0 : (stateA == 1 ? 1 : 2);
        int priorityB = stateB == 2 ? 0 : (stateB == 1 ? 1 : 2);
        // 优先判断状态
        if (priorityA != priorityB)
        {
            return priorityA.CompareTo(priorityB);
        }
        // 2. 状态相同的话,获取两者的 SortIndex
        int sortIndexA = GetSortIndex(type, a);
        int sortIndexB = GetSortIndex(type, b);
        if (sortIndexA != sortIndexB)
        {
            return sortIndexA.CompareTo(sortIndexB);
        }
        // 3. 状态和 SortIndex 都相同的话,按唯一 ID 排序
        return a.CompareTo(b);
    }
Main/System/PhantasmPavilion/PhantasmPavilionModelHandler.cs
@@ -63,5 +63,8 @@
    {
        return ModelConfig.Get(id).GetWayString;
    }
    public int GetSortIndex(int id)
    {
        return ModelConfig.Get(id).SortIndex;
    }
}
Main/System/PhantasmPavilion/PhantasmPavilionTitleHandler.cs
@@ -63,6 +63,9 @@
    {
        return TitleConfig.Get(id).GetWayString;
    }
    public int GetSortIndex(int id)
    {
        return TitleConfig.Get(id).SortIndex;
    }
}