少年修仙传客户端代码仓库
Client_PangDeRong
2018-08-31 e8a98f2b0c3f7fcc614898aa7df7c01fa35f9e45
System/Compose/New/ComposeWinModel.cs
@@ -11,7 +11,6 @@
    private Dictionary<int, Dictionary<int, List<ItemCompoundConfig>>> firstTypeDict = null;
    private Dictionary<int, List<ItemCompoundConfig>> secondTypeDict = null;
    private Dictionary<int, List<int>> composeJobLimitDict = new Dictionary<int, List<int>>();
    public ComposeFuncType funcType = ComposeFuncType.Wings;
    private FuncConfigConfig addonsFormulaModel;
    public event Action ResetModelEvent;
    SelectEquipModel _selectModel;
@@ -796,57 +795,50 @@
    #region 处理跳转界面数据
    public bool CheckComposeItemById(int itemId)
    public bool CheckComposeItemById(int itemId,out int jumpId)
    {
        jumpId = 0;
        ItemConfig itemConfig = Config.Instance.Get<ItemConfig>(itemId);
        if (itemConfig == null) return false;
        switch(itemConfig.Type)
        ItemCompoundConfig itemCompound = Config.Instance.Get<ItemCompoundConfig>(itemConfig.ComposeID);
        if(itemCompound.levelNeed <= PlayerDatas.Instance.baseData.LV)
        {
            case 25:
            case 35:
                funcType = ComposeFuncType.Item;
                break;
            case 39:
                funcType = ComposeFuncType.Wings;
                break;
            case 44:
                funcType = ComposeFuncType.Ticket;
                break;
        }
        firstTypeDict = ItemCompoundConfig.GetAllFirstComposeTypeDict((int)funcType);
        if (firstTypeDict != null)
        {
            foreach (var secondType in firstTypeDict.Keys)
            switch (itemCompound.firstType)
            {
                Dictionary<int, List<ItemCompoundConfig>> secondTypeDict = firstTypeDict[secondType];
                foreach(var thirdType in secondTypeDict.Keys)
                {
                    for(int i = 0; i < secondTypeDict[thirdType].Count; i++)
                    {
                        ItemCompoundConfig compoundConfig = secondTypeDict[thirdType][i];
                        int[] fixedIds = ConfigParse.GetMultipleStr<int>(compoundConfig.itemID);
                        if(fixedIds.Contains(itemId))
                        {
                            if(compoundConfig.levelNeed <= PlayerDatas.Instance.baseData.LV)
                            {
                                this.secondType = secondType;
                                this.thirdType = thirdType;
                                return true;
                            }
                            else
                            {
                                SysNotifyMgr.Instance.ShowTip("TicketComposeUnlock",compoundConfig.levelNeed,compoundConfig.secondTypeName);
                                return false;
                            }
                        }
                    }
                }
                case 1:
                    jumpId = (int)JumpUIType.ComposeFunc1;
                    break;
                case 2:
                    jumpId = (int)JumpUIType.ComposeFunc2;
                    break;
                case 3:
                    jumpId = (int)JumpUIType.ComposeFunc3;
                    break;
                case 4:
                    jumpId = (int)JumpUIType.ComposeFunc4;
                    break;
                case 5:
                    jumpId = (int)JumpUIType.ComposeFunc5;
                    break;
            }
        }
            this.secondType = itemCompound.secondType;
        return false;
            if(itemConfig.ComposeID == 223)
            {
                this.thirdType = PlayerDatas.Instance.baseData.Job;
            }
            else
            {
                this.thirdType = itemCompound.thirdType;
            }
            return true;
        }
        else
        {
            SysNotifyMgr.Instance.ShowTip("TicketComposeUnlock", itemCompound.levelNeed, itemCompound.secondTypeName);
            return false;
        }
    }
    public int secondType { get; private set; }
@@ -855,7 +847,6 @@
    {
        this.secondType = secondType;
        this.thirdType = thirdType;
        funcType = type;
        GetFirstTypeModel((int)type);
        Dictionary<int, List<ItemCompoundConfig>> dict = GetSecondTypeModel((int)type,secondType);
        if(dict == null)