少年修仙传客户端代码仓库
client_Hale
2019-04-15 c79dbe6647429b864d15a21b3baa77ffa8d48768
Merge branch 'master' of http://192.168.0.87:10010/r/snxxz_scripts
12个文件已修改
3个文件已添加
683 ■■■■ 已修改文件
Fight/GameActor/GA_Hero.cs 55 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Lua/Gen/StoreModelWrap.cs 24 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/BetterItemGet/BetterEquipGetModel.cs 6 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/KnapSack/Logic/ItemLogicUtility.cs 212 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/MainInterfacePanel/HighSettingFadeInFadeOut.cs 7 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/Mount/MountModel.cs 23 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/SpiritWeapon.meta 9 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/SpiritWeapon/SpiritWeaponModel.cs 23 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/SpiritWeapon/SpiritWeaponModel.cs.meta 12 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/Store/StoreModel.cs 156 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/Strengthening/StrengthenModel.cs 40 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/Strengthening/WingsBouncedWin.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/Strengthening/WingsRedDotModel.cs 8 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/Strengthening/WingsRefined.cs 24 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Utility/VesselExtension.cs 82 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Fight/GameActor/GA_Hero.cs
@@ -65,11 +65,9 @@
    /// 用户点击锁定, 被攻击锁定攻击者...
    /// </summary>
    private GActor m_LockTarget;
    public GActor LockTarget
    {
    public GActor LockTarget {
        get { return m_LockTarget; }
        set
        {
        set {
            if (m_LockTarget == value)
            {
                return;
@@ -91,14 +89,11 @@
    public MapArea currentBossArea;
    private uint _atkBossID;
    public uint atkBossID
    {
        get
        {
    public uint atkBossID {
        get {
            return _atkBossID;
        }
        set
        {
        set {
            if (_atkBossID != value)
            {
                _atkBossID = value;
@@ -114,28 +109,22 @@
        }
    }
    public sealed override int NextAction
    {
        get
        {
    public sealed override int NextAction {
        get {
            return base.NextAction;
        }
        set
        {
        set {
            base.NextAction = value;
        }
    }
    public sealed override GActor SelectTarget
    {
        get
        {
    public sealed override GActor SelectTarget {
        get {
            return base.SelectTarget;
        }
        set
        {
        set {
            if (base.SelectTarget == value)
            {
                return;
@@ -539,11 +528,10 @@
    {
        if (upOrDown == 1)
        {
            PackModel _packModel = ModelCenter.Instance.GetModel<PackModel>();
            SinglePack _horsePackModel = _packModel.GetSinglePack(PackType.Equip);
            if (_horsePackModel != null)
            var _packModel = ModelCenter.Instance.GetModel<PackModel>();
            var _horseItem = _packModel.GetItemByIndex(PackType.Equip, 5);
            if (_horseItem != null)
            {
                ItemModel _horseItem = _horsePackModel.GetItemByIndex((int)RoleEquipType.Mount);
                SwitchHorse((uint)_horseItem.itemId);
            }
        }
@@ -671,10 +659,8 @@
    }
    private HeavenBattleModel m_HeavenBattleModel = null;
    public HeavenBattleModel heavenBattleModel
    {
        get
        {
    public HeavenBattleModel heavenBattleModel {
        get {
            return m_HeavenBattleModel ?? (m_HeavenBattleModel = ModelCenter.Instance.GetModel<HeavenBattleModel>());
        }
    }
@@ -767,14 +753,11 @@
    #region 地图区域相关处理
    private int m_CurMapArea = 1 << (int)MapArea.E_Type.Normal;
    public int CurMapArea
    {
        get
        {
    public int CurMapArea {
        get {
            return m_CurMapArea;
        }
        set
        {
        set {
            m_CurMapArea = value;
        }
    }
Lua/Gen/StoreModelWrap.cs
@@ -1543,9 +1543,6 @@
                
                {
                    
                    gen_to_be_invoked.UpdateFairyEquipRedpoint(  );
                    
                    return 0;
                }
@@ -1571,10 +1568,6 @@
                {
                    StoreConfig _storeConfig = (StoreConfig)translator.GetObject(L, 2, typeof(StoreConfig));
                    
                    gen_to_be_invoked.ClearFairyEquipRedpoint( _storeConfig );
                    return 0;
                }
                
@@ -1599,10 +1592,6 @@
                {
                    StoreFunc _storeFunc;translator.Get(L, 2, out _storeFunc);
                    
                    gen_to_be_invoked.SwitchFuncTitleClearRedpoint( _storeFunc );
                    return 0;
                }
                
@@ -1618,22 +1607,9 @@
            try {
            
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);
                StoreModel gen_to_be_invoked = (StoreModel)translator.FastGetCSObj(L, 1);
                
                {
                    StoreConfig _config = (StoreConfig)translator.GetObject(L, 2, typeof(StoreConfig));
                    string _fairySaveKey;
                        bool gen_ret = gen_to_be_invoked.TryGetFairySaveKey( _config, out _fairySaveKey );
                        LuaAPI.lua_pushboolean(L, gen_ret);
                    LuaAPI.lua_pushstring(L, _fairySaveKey);
                    
                    return 2;
                }
System/BetterItemGet/BetterEquipGetModel.cs
@@ -288,9 +288,8 @@
            return guid;
        }
        private void RemoveItemByEquipPlace(int _place)
        private void RemoveItemByEquipPlace(int place)
        {
            var place = _place == 10 ? 9 : _place;
            var keys = new List<string>(betterEquipModels.Keys);
            for (int i = keys.Count - 1; i >= 0; i--)
            {
@@ -315,9 +314,8 @@
            }
        }
        private bool TryGetEquipByPlace(int _place, out ItemModel _itemModel)
        private bool TryGetEquipByPlace(int place, out ItemModel _itemModel)
        {
            var place = _place == 10 ? 9 : _place;
            var keys = new List<string>(betterEquipModels.Keys);
            for (int i = keys.Count - 1; i >= 0; i--)
            {
System/KnapSack/Logic/ItemLogicUtility.cs
@@ -134,17 +134,17 @@
                }
                foreach (var item in keyValues)
                {
                    Add(item.Key, item.Value);
                {
                    Add(item.Key, item.Value);
                }
            }
            public void AddBaseProperties(int itemId, List<int> reference)
            {
                var config = ItemConfig.Get(itemId);
                if (config == null)
                {
                    return;
                if (config == null)
                {
                    return;
                }
                if (config.Effect1 != 0 && reference.Contains(config.Effect1))
                {
@@ -184,9 +184,9 @@
                AddRange(config.OutOfPrintAttr, config.OutOfPrintAttrValue);
            }
            public bool ContainsKey(int id)
            {
                return properties.ContainsKey(id);
            public bool ContainsKey(int id)
            {
                return properties.ContainsKey(id);
            }
        }
@@ -207,22 +207,22 @@
            if (isPreview)
            {
                switch ((RoleEquipType)config.EquipPlace)
                {
                    case RoleEquipType.Weapon:
                    case RoleEquipType.Weapon2:
                    case RoleEquipType.Hat:
                    case RoleEquipType.Clothes:
                    case RoleEquipType.Belt:
                    case RoleEquipType.Trousers:
                    case RoleEquipType.Shoes:
                    case RoleEquipType.Glove:
                    case RoleEquipType.Neck:
                    case RoleEquipType.FairyCan1:
                    case RoleEquipType.FairyCan2:
                {
                    case RoleEquipType.Weapon:
                    case RoleEquipType.Weapon2:
                    case RoleEquipType.Hat:
                    case RoleEquipType.Clothes:
                    case RoleEquipType.Belt:
                    case RoleEquipType.Trousers:
                    case RoleEquipType.Shoes:
                    case RoleEquipType.Glove:
                    case RoleEquipType.Neck:
                    case RoleEquipType.FairyCan1:
                    case RoleEquipType.FairyCan2:
                    case RoleEquipType.Jade:
                        properties.AddRange(GetEquipLegendProperties(itemId));
                        break;
                    case RoleEquipType.Wing:
                        break;
                    case RoleEquipType.Wing:
                        properties.AddRange(GetWingsLegendProperties(itemId));
                        break;
                }
@@ -248,15 +248,15 @@
        private Dictionary<int, int> GetEquipLegendProperties(int itemId)
        {
            var legendProperties = LegendPropertyUtility.GetEquipProperties(itemId);
            var properties = new Dictionary<int, int>();
            if (legendProperties != null)
            {
                foreach (var item in legendProperties)
                {
                    properties[item.x] = item.y;
                }
            }
            var legendProperties = LegendPropertyUtility.GetEquipProperties(itemId);
            var properties = new Dictionary<int, int>();
            if (legendProperties != null)
            {
                foreach (var item in legendProperties)
                {
                    properties[item.x] = item.y;
                }
            }
            return properties;
        }
@@ -278,8 +278,8 @@
            }
            return properties;
        }
        }
        public bool IsCustomItem(int itemId)
        {
            if (!ItemConfig.Has(itemId))
@@ -305,10 +305,10 @@
            }
            var minAttack = properties.ContainsKey((int)PropertyType.MinAtk) ? properties[(int)PropertyType.MinAtk] : 0;
            var maxAttack = properties.ContainsKey((int)PropertyType.MaxAtk) ? properties[(int)PropertyType.MaxAtk] : 0;
            var attack = properties.ContainsKey((int)PropertyType.ATK) ? properties[(int)PropertyType.ATK] : 0;
            properties[(int)PropertyType.MinAtk] = minAttack + attack;
            var maxAttack = properties.ContainsKey((int)PropertyType.MaxAtk) ? properties[(int)PropertyType.MaxAtk] : 0;
            var attack = properties.ContainsKey((int)PropertyType.ATK) ? properties[(int)PropertyType.ATK] : 0;
            properties[(int)PropertyType.MinAtk] = minAttack + attack;
            properties[(int)PropertyType.MaxAtk] = maxAttack + attack;
            Equation.Instance.Clear();
@@ -322,11 +322,11 @@
                {
                    case PropertyType.ATKSPEED:
                    case PropertyType.OnlyFinalHurt:
                    case PropertyType.PVPAtkBackHP:
                    case PropertyType.MinAtk:
                    case PropertyType.PVPAtkBackHP:
                    case PropertyType.MinAtk:
                    case PropertyType.MaxAtk:
                        curEquipAttrDict.Add(attrType, properties[key]);
                        break;
                        break;
                    default:
                        if (GSProValueDict != null && GSProValueDict.ContainsKey(attrType))
                        {
@@ -377,9 +377,9 @@
                return;
            }
            if (item.isAuction)
            {
                return;
            if (item.isAuction)
            {
                return;
            }
            if (item.config.UseLV > PlayerDatas.Instance.baseData.LV)
@@ -587,7 +587,7 @@
                return false;
            }
            var putModel = packModel.GetItemByIndex(PackType.Equip, (int)RoleEquipType.Wing);
            var putModel = packModel.GetItemByIndex(PackType.Equip, SpiritWeaponModel.WING_EQUIPINDEX);
            var singlePack = packModel.GetSinglePack(PackType.Item);
            if (singlePack == null)
            {
@@ -623,11 +623,11 @@
                return false;
            }
            var itemModels = packModel.GetItems(PackType.Item, new SinglePack.FilterParams()
            {
                itemTypes = new List<int>() { (int)ItemType.Equip_Wing }
            });
            var itemModels = packModel.GetItems(PackType.Item, new SinglePack.FilterParams()
            {
                itemTypes = new List<int>() { (int)ItemType.Equip_Wing }
            });
            if (itemModels != null)
            {
                for (int i = 0; i < itemModels.Count; i++)
@@ -719,11 +719,11 @@
        private void SetGetBetterEquipEvent(ItemModel model)
        {
            if (model.isAuction)
            {
                return;
            }
            if (model.isAuction)
            {
                return;
            }
            var itemEffectTime = model.GetUseData((int)ItemUseDataKey.createTime);
            if (!itemEffectTime.IsNullOrEmpty() && itemEffectTime.Count > 0)
            {
@@ -741,22 +741,22 @@
                        return;
                    }
                }
            }
            if (!equipModel.IsLevelUnLocked(model.config.LV))
            {
                return;
            }
            int isFightUp = IsFightUp(model.itemId, model.score);
            if (isFightUp != 1)
            {
                return;
            }
            if (GetBetterEquipEvent != null)
            {
                GetBetterEquipEvent(model.guid);
            if (!equipModel.IsLevelUnLocked(model.config.LV))
            {
                return;
            }
            int isFightUp = IsFightUp(model.itemId, model.score);
            if (isFightUp != 1)
            {
                return;
            }
            if (GetBetterEquipEvent != null)
            {
                GetBetterEquipEvent(model.guid);
            }
        }
@@ -870,8 +870,8 @@
        private int playerLv;
        private Dictionary<int, List<ItemModel>> _lifePotionDict = new Dictionary<int, List<ItemModel>>(); //key 药水等级
        private List<int> _sellItemScorelist = new List<int>();
        private Dictionary<int, Dictionary<int, List<ItemModel>>> _sameIndexEquipDict = new Dictionary<int, Dictionary<int, List<ItemModel>>>();  //存储相同装备位的装备
                                                                                                                                                  // private  _sameEquipScoreDict = new Dictionary<int, List<ItemModel>>(); //存储相同ID中相同装备评分的装备
        private Dictionary<int, Dictionary<int, List<ItemModel>>> _sameIndexEquipDict = new Dictionary<int, Dictionary<int, List<ItemModel>>>();  //存储相同装备位的装备
                                                                                                                                                  // private  _sameEquipScoreDict = new Dictionary<int, List<ItemModel>>(); //存储相同ID中相同装备评分的装备
        private Dictionary<int, ItemModel> _packModelDict;
        private List<ItemModel> _sellItemlist = new List<ItemModel>();
@@ -1352,18 +1352,18 @@
        public bool IsOverdue(string guid)
        {
            var item = packModel.GetItemByGuid(guid);
            if (item == null)
            {
                return false;
            if (item == null)
            {
                return false;
            }
            if (item.isAuction)
            {
                return item.auctionSurplusTime < 0;
            }
            else
            {
                return item.overdueSurplusTime < 0;
            if (item.isAuction)
            {
                return item.auctionSurplusTime < 0;
            }
            else
            {
                return item.overdueSurplusTime < 0;
            }
        }
@@ -1375,36 +1375,36 @@
            return config != null && (config.JobLimit == 0 || config.JobLimit == PlayerDatas.Instance.baseData.Job);
        }
        public bool IsEquip(int itemId)
        {
            if (!ItemConfig.Has(itemId))
            {
                return false;
            }
            var config = ItemConfig.Get(itemId);
            return config.Type >= 101 && config.Type <= 112;
        public bool IsEquip(int itemId)
        {
            if (!ItemConfig.Has(itemId))
            {
                return false;
            }
            var config = ItemConfig.Get(itemId);
            return config.Type >= 101 && config.Type <= 112;
        }
        public bool IsWing(int itemId)
        {
            if (!ItemConfig.Has(itemId))
            {
                return false;
            }
            var config = ItemConfig.Get(itemId);
            return config.Type == 113 || config.Type == 39 || config.Type == 52;
        public bool IsWing(int itemId)
        {
            if (!ItemConfig.Has(itemId))
            {
                return false;
            }
            var config = ItemConfig.Get(itemId);
            return config.Type == 113 || config.Type == 39 || config.Type == 52;
        }
        public bool IsDogzEquip(int itemId)
        {
            if (!ItemConfig.Has(itemId))
            {
                return false;
            }
            var config = ItemConfig.Get(itemId);
            return config.Type >= 119 && config.Type <= 124;
        public bool IsDogzEquip(int itemId)
        {
            if (!ItemConfig.Has(itemId))
            {
                return false;
            }
            var config = ItemConfig.Get(itemId);
            return config.Type >= 119 && config.Type <= 124;
        }
    }
System/MainInterfacePanel/HighSettingFadeInFadeOut.cs
@@ -231,13 +231,14 @@
                }
            }
            m_Switch.gameObject.SetActive(IsShowButton());
        }
        public bool IsShowButton()//是否显示切换按钮
        bool IsShowButton()
        {
            foreach (var grid in m_GridGroup1)
            {
                if (!grid.alwayShow)
                if (!grid.alwayShow && grid.gameObject.activeSelf)
                {
                    return true;
                }
@@ -245,7 +246,7 @@
            foreach (var grid in m_GridGroup2)
            {
                if (!grid.alwayShow)
                if (!grid.alwayShow && grid.gameObject.activeSelf)
                {
                    return true;
                }
System/Mount/MountModel.cs
@@ -273,7 +273,11 @@
    public Redpoint redPointStre2 = new Redpoint(MainRedDot.RedPoint_MountPackKey, Redpoint_key2);//坐骑兽魂
    private void OnItemRefreshEvent(PackType type, int index, int id)
    {
        MountH0704(playerPack.GetItemByIndex(type, index));
        if (type == PackType.Equip)
        {
            RefreshCurrentMount(playerPack.GetItemByIndex(type, index));
        }
        if (type == PackType.Item)
        {
            if (_DicMountItem.ContainsKey(id))
@@ -519,19 +523,22 @@
            }
        }
        return SkillLv;
    }
    public void MountH0704(ItemModel info)//获取当前的坐骑
    }
    void RefreshCurrentMount(ItemModel info)//获取当前的坐骑
    {
        if (info == null)
        {
            return;
        }
        if (info == null || info.packType != PackType.Equip)
            return;
        if (info.gridIndex == (byte)RoleEquipType.Mount)//坐骑位置19
        if (info.config.EquipPlace == (byte)RoleEquipType.Mount)//坐骑位置19
        {
            if (Hconfigs.Count <= 0)
            {
                Hconfigs = HorseConfig.GetValues();
            }
            // var configs = HorseConfig.GetValues();
            foreach (var config in Hconfigs)
            {
                if (config.ItemID == info.itemId)
@@ -542,10 +549,10 @@
                    {
                        Event_MountAlteration(_HorseIDNow);
                    }
                }
            }
        }
        MountDanRed();
        MountStoneRed();
    }
System/SpiritWeapon.meta
New file
@@ -0,0 +1,9 @@
fileFormatVersion: 2
guid: f6b2d7f697c59b44b92546aadd720fb3
folderAsset: yes
timeCreated: 1555300518
licenseType: Pro
DefaultImporter:
  userData:
  assetBundleName:
  assetBundleVariant:
System/SpiritWeapon/SpiritWeaponModel.cs
New file
@@ -0,0 +1,23 @@
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
namespace Snxxz.UI
{
    public class SpiritWeaponModel : Model
    {
        public const int WING_EQUIPINDEX = 0;
        public override void Init()
        {
        }
        public override void UnInit()
        {
        }
    }
}
System/SpiritWeapon/SpiritWeaponModel.cs.meta
New file
@@ -0,0 +1,12 @@
fileFormatVersion: 2
guid: 941a122e2cd001447a58e7d3b82b8950
timeCreated: 1555300546
licenseType: Pro
MonoImporter:
  serializedVersion: 2
  defaultReferences: []
  executionOrder: 0
  icon: {instanceID: 0}
  userData:
  assetBundleName:
  assetBundleVariant:
System/Store/StoreModel.cs
@@ -83,7 +83,6 @@
        TimeMgr.Instance.OnHourEvent -= RefreshServerHour;
        GlobalTimeEvent.Instance.secondEvent -= UpdateSecond;
        NewBieCenter.Instance.guideBeginEvent -= GuidBegin;
        packModel.refreshItemCountEvent -= UpdateFairyEquip;
        shopItemlimitDict.Clear();
        petAndMountPushlist.Clear();
        ClearPushData();
@@ -112,7 +111,6 @@
        WindowCenter.Instance.windowAfterOpenEvent += windowAfterOpen;
        WindowCenter.Instance.windowAfterCloseEvent += windowAfterClose;
        NewBieCenter.Instance.guideBeginEvent += GuidBegin;
        packModel.refreshItemCountEvent += UpdateFairyEquip;
        UpdateShowStore();
        SetIsMustBuyDay();
        ControllerRedPoint();
@@ -730,7 +728,6 @@
            case PlayerDataType.FBHelpPoint:
                UpdateFreeShopRedpoint();
                UpdateCanBuyRedpoint();
                UpdateFairyEquipRedpoint();
                break;
        }
    }
@@ -810,7 +807,6 @@
            UpdateCanBuyRedpoint();
            UpdateMustBuyRedpoint();
            UpdatePetAndMountPutAwayRedpoint();
            UpdateFairyEquipRedpoint();
        }
        if (RefreshBuyShopLimitEvent != null)
            RefreshBuyShopLimitEvent();
@@ -1093,7 +1089,6 @@
                UpdateCanBuyRedpoint();
                UpdateMustBuyRedpoint();
                UpdatePetAndMountPutAwayRedpoint();
                UpdateFairyEquipRedpoint();
                break;
            case FuncOpenEnum.BlastFurnace:
                ControllerRedPoint();
@@ -1353,155 +1348,6 @@
        }
    }
    private void UpdateFairyEquip(PackType type, int index, int id)
    {
        if (type != PackType.Equip
            && (index != (int)RoleEquipType.FairyCan1 || index != (int)RoleEquipType.FairyCan2)) return;
        ClearAllFairyEquipRedpoint();
    }
    public void UpdateFairyEquipRedpoint()
    {
        if (!FuncOpen.Instance.IsFuncOpen((int)FuncOpenEnum.Store)) return;
        foreach (var key in showStoreTypeDict.Keys)
        {
            var storeDatas = showStoreTypeDict[key];
            for (int i = 0; i < storeDatas.Count; i++)
            {
                var storeData = storeDatas[i];
                var storeConfig = storeData.storeConfig;
                int type = 0;
                TryGetRedTypeByShopId(storeConfig.ID, out type);
                if (type == 5)
                {
                    string fairySaveKey = string.Empty;
                    bool isGetSave = TryGetFairySaveKey(storeConfig, out fairySaveKey);
                    int remainNum = 0;
                    if (!TryGetIsSellOut(storeConfig, out remainNum))
                    {
                        if (UIHelper.GetMoneyCnt(storeConfig.MoneyType) >= (ulong)storeConfig.MoneyNumber)
                        {
                            if (isGetSave)
                            {
                                shopRedDict[storeData.shopId].state = RedPointState.Simple;
                                LocalSave.SetBool(fairySaveKey, true);
                            }
                            else
                            {
                                shopRedDict[storeData.shopId].state = RedPointState.None;
                            }
                        }
                        else
                        {
                            if (shopRedDict[storeData.shopId].state != RedPointState.None)
                            {
                                LocalSave.SetBool(fairySaveKey, false);
                                shopRedDict[storeConfig.ID].state = RedPointState.None;
                            }
                        }
                    }
                    else
                    {
                        shopRedDict[storeConfig.ID].state = RedPointState.None;
                    }
                }
            }
        }
    }
    public void ClearFairyEquipRedpoint(StoreConfig storeConfig)
    {
        int type = 0;
        TryGetRedTypeByShopId(storeConfig.ID, out type);
        if (type == 5)
        {
            if (shopRedDict[storeConfig.ID].state != RedPointState.None)
            {
                shopRedDict[storeConfig.ID].state = RedPointState.None;
                string key1 = StringUtility.Contact(PlayerDatas.Instance.baseData.PlayerID, "ShopId", storeConfig.ID, "EquipPlace:", 9);
                string key2 = StringUtility.Contact(PlayerDatas.Instance.baseData.PlayerID, "ShopId", storeConfig.ID, "EquipPlace:", 10);
                if (LocalSave.GetBool(key1))
                {
                    LocalSave.SetBool(key1, false);
                }
                else if (LocalSave.GetBool(key2))
                {
                    LocalSave.SetBool(key2, false);
                }
            }
        }
    }
    public void SwitchFuncTitleClearRedpoint(StoreFunc storeFunc)
    {
        if (storeFuncType == StoreFunc.IntegralStore && storeFunc != StoreFunc.IntegralStore)
        {
            ClearAllFairyEquipRedpoint();
        }
    }
    private void ClearAllFairyEquipRedpoint()
    {
        foreach (var key in shopRedDict.Keys)
        {
            StoreConfig storeConfig = StoreConfig.Get(key);
            ItemConfig itemConfig = ItemConfig.Get(storeConfig.ItemID);
            int type = 0;
            TryGetRedTypeByShopId(storeConfig.ID, out type);
            if (type == 5)
            {
                if (shopRedDict[key].state != RedPointState.None)
                {
                    shopRedDict[key].state = RedPointState.None;
                    string key1 = StringUtility.Contact(PlayerDatas.Instance.baseData.PlayerID, "ShopId", key, "EquipPlace:", 9);
                    string key2 = StringUtility.Contact(PlayerDatas.Instance.baseData.PlayerID, "ShopId", key, "EquipPlace:", 10);
                    if (LocalSave.GetBool(key1))
                    {
                        LocalSave.SetBool(key1, false);
                    }
                    else if (LocalSave.GetBool(key2))
                    {
                        LocalSave.SetBool(key2, false);
                    }
                }
            }
        }
    }
    public bool TryGetFairySaveKey(StoreConfig config, out string fairySaveKey)
    {
        fairySaveKey = string.Empty;
        if (config == null) return false;
        ItemConfig itemConfig = ItemConfig.Get(config.ItemID);
        if (itemConfig.EquipPlace == (int)RoleEquipType.FairyCan1)
        {
            string key1 = StringUtility.Contact(PlayerDatas.Instance.baseData.PlayerID, "ShopId", config.ID, "EquipPlace:", 9);
            string key2 = StringUtility.Contact(PlayerDatas.Instance.baseData.PlayerID, "ShopId", config.ID, "EquipPlace:", 10);
            ItemModel itemModel1 = packModel.GetItemByIndex(PackType.Equip, 9);
            ItemModel itemModel2 = packModel.GetItemByIndex(PackType.Equip, 10);
            if (itemModel1 == null
                && (!PlayerPrefs.HasKey(key1) || LocalSave.GetBool(key1)))
            {
                fairySaveKey = key1;
                return true;
            }
            else if (itemModel2 == null
                 && (!PlayerPrefs.HasKey(key2) || LocalSave.GetBool(key2)))
            {
                fairySaveKey = key2;
                return true;
            }
        }
        return false;
    }
    public void UpdateMustBuyRedpoint()
    {
        if (!FuncOpen.Instance.IsFuncOpen((int)FuncOpenEnum.Store)) return;
@@ -1685,13 +1531,11 @@
    {
        ClearMustBuyRedpoint(storeConfig);
        ClearPetAndMountRedpoint(storeConfig);
        ClearFairyEquipRedpoint(storeConfig);
    }
    public void CloseAllRedpoint(StoreFunc storeFunc)
    {
        ClearAllPetAndMountRedpoint(storeFunc);
        SwitchFuncTitleClearRedpoint(storeFunc);
    }
    #endregion
System/Strengthening/StrengthenModel.cs
@@ -8,27 +8,27 @@
public class StrengthenModel : Model, IBeforePlayerDataInitialize, IPlayerLoginOk
{
{
    PackModel _playerPack;
    PackModel playerPack { get { return _playerPack ?? (_playerPack = ModelCenter.Instance.GetModel<PackModel>()); } }
    public void OnBeforePlayerDataInitialize()
    {
    PackModel playerPack { get { return _playerPack ?? (_playerPack = ModelCenter.Instance.GetModel<PackModel>()); } }
    public void OnBeforePlayerDataInitialize()
    {
    }
    public override void Init()
    {
    {
    }
    public override void UnInit()
    {
    {
    }
    public void OnPlayerLoginOk()
    {
    {
    }
    //===========羽翼精炼
    Dictionary<int, WingRefineAttrModel> _DicWingRe = new Dictionary<int, WingRefineAttrModel>();
@@ -74,8 +74,8 @@
        if (tegWing.Count <= 0)
        {
            tegWing = WingRefineAttrConfig.GetValues();
        }
        //  var configs = WingRefineAttrConfig.GetValues();
        }
        //  var configs = WingRefineAttrConfig.GetValues();
        foreach (var values in tegWing)
        {
            if (Item.LV == values.wingsPhase)
@@ -103,7 +103,7 @@
        {
            return false;
        }
        ItemModel itemModel = playerPack.GetItemByIndex(PackType.Equip, (int)RoleEquipType.Wing);
        ItemModel itemModel = playerPack.GetItemByIndex(PackType.Equip, SpiritWeaponModel.WING_EQUIPINDEX);
        if (itemModel.GetUseData((int)ItemUseDataKey.wingProgressValue) != null)
        {
            int currentRefining = 0;
@@ -112,8 +112,8 @@
            if (tegWing.Count <= 0)
            {
                tegWing = WingRefineAttrConfig.GetValues();
            }
            //  var wingRefineAttrConfigs = WingRefineAttrConfig.GetValues();
            }
            //  var wingRefineAttrConfigs = WingRefineAttrConfig.GetValues();
            foreach (var value in tegWing)
            {
                if (itemModel.config.LV == value.wingsPhase)
@@ -134,8 +134,8 @@
        {
            return false;
        }
    }
    }
}
System/Strengthening/WingsBouncedWin.cs
@@ -61,7 +61,7 @@
        {
            if (PackType.Equip == arg1)
            {
                ItemModel itemModel = playerPack.GetItemByIndex(PackType.Equip, (int)RoleEquipType.Wing);
                ItemModel itemModel = playerPack.GetItemByIndex(PackType.Equip, SpiritWeaponModel.WING_EQUIPINDEX);
                if (itemModel != null)
                {
                    Close();
System/Strengthening/WingsRedDotModel.cs
@@ -33,7 +33,7 @@
            packModel.itemCntAddEvent += ItemCntAddAct;//物品数量增加
            packModel.itemCntReduceEvent += ItemCntReduceAct;//物品数量减少
            FuncOpen.Instance.OnFuncStateChangeEvent += OnFuncStateChange;
            ItemModel itemModel = packModel.GetItemByIndex(PackType.Equip, (int)RoleEquipType.Wing);
            ItemModel itemModel = packModel.GetItemByIndex(PackType.Equip, SpiritWeaponModel.WING_EQUIPINDEX);
            if (IsOnePutOn)
            {
                WingsDot();
@@ -78,7 +78,7 @@
        public void WingsDot()
        {
            redPointStre.state = RedPointState.None;
            ItemModel itemModel = packModel.GetItemByIndex(PackType.Equip, (int)RoleEquipType.Wing);
            ItemModel itemModel = packModel.GetItemByIndex(PackType.Equip, SpiritWeaponModel.WING_EQUIPINDEX);
            if (itemModel == null || !FuncOpen.Instance.IsFuncOpen(90))
            {
@@ -174,7 +174,7 @@
            }
            if (arg1 == PackType.Equip)//装备背包物品增加
            {
                ItemModel itemModel = packModel.GetItemByIndex(PackType.Equip, (int)RoleEquipType.Wing);
                ItemModel itemModel = packModel.GetItemByIndex(PackType.Equip, SpiritWeaponModel.WING_EQUIPINDEX);
                if (IsOnePutOn)
                {
                    WingsDot();
@@ -225,7 +225,7 @@
            }
            if (arg1 == PackType.Equip)//装备脱下
            {
                ItemModel itemModel = packModel.GetItemByIndex(PackType.Equip, (int)RoleEquipType.Wing);
                ItemModel itemModel = packModel.GetItemByIndex(PackType.Equip, SpiritWeaponModel.WING_EQUIPINDEX);
                if (itemModel == null && redPointStre.state == RedPointState.Simple)
                {
                    redPointStre.state = RedPointState.None;
System/Strengthening/WingsRefined.cs
@@ -226,7 +226,7 @@
    void RefiningButton()//精炼按钮
    {
        ItemModel itemModel = playerPack.GetItemByIndex(PackType.Equip, (int)RoleEquipType.Wing);
        ItemModel itemModel = playerPack.GetItemByIndex(PackType.Equip, SpiritWeaponModel.WING_EQUIPINDEX);
        if (itemModel == null)
        {
@@ -279,7 +279,7 @@
        }
        ItemModel itemModel = playerPack.GetItemByIndex(PackType.Equip, (int)RoleEquipType.Wing);
        ItemModel itemModel = playerPack.GetItemByIndex(PackType.Equip, SpiritWeaponModel.WING_EQUIPINDEX);
        if (itemModel == null)
        {
            return;
@@ -396,7 +396,7 @@
            }
        }
        ItemModel itemModel = playerPack.GetItemByIndex(PackType.Equip, (int)RoleEquipType.Wing);
        ItemModel itemModel = playerPack.GetItemByIndex(PackType.Equip, SpiritWeaponModel.WING_EQUIPINDEX);
        int WingLv2 = itemModel.config.LV;
        foreach (var key in dicWingUseDateValue.Keys)
        {
@@ -412,7 +412,7 @@
    void KeyRefiningButton()//一键精炼
    {
        ItemModel itemModel = playerPack.GetItemByIndex(PackType.Equip, (int)RoleEquipType.Wing);
        ItemModel itemModel = playerPack.GetItemByIndex(PackType.Equip, SpiritWeaponModel.WING_EQUIPINDEX);
        if (itemModel == null)
        {
            ServerTipDetails.DisplayNormalTip(Language.Get("EquipReinforceWin_WingRefLv_2"));
@@ -517,7 +517,7 @@
        //背包字典
        SinglePack rptItemPack = playerPack.GetSinglePack(PackType.Item);
        ItemModel putOnModel = playerPack.GetItemByIndex(PackType.Equip, (int)RoleEquipType.Wing);
        ItemModel putOnModel = playerPack.GetItemByIndex(PackType.Equip, SpiritWeaponModel.WING_EQUIPINDEX);
        if (rptItemPack == null || rptItemPack.GetAllItems().Count == 0 || putOnModel == null)
        {
            return;
@@ -555,7 +555,7 @@
    void EquipmentPositionJudgment()//判断是否有穿戴翅膀
    {
        Backpacking();//物品读取
        ItemModel itemModel = playerPack.GetItemByIndex(PackType.Equip, (int)RoleEquipType.Wing);
        ItemModel itemModel = playerPack.GetItemByIndex(PackType.Equip, SpiritWeaponModel.WING_EQUIPINDEX);
        int itemID = 0;
        if (itemModel != null)
        {
@@ -595,7 +595,7 @@
            return;
        }
        EquipFirstTxt.SetActive(false);
        ItemModel itemModel = playerPack.GetItemByIndex(PackType.Equip, (int)RoleEquipType.Wing);
        ItemModel itemModel = playerPack.GetItemByIndex(PackType.Equip, SpiritWeaponModel.WING_EQUIPINDEX);
        var config = WingRefineExpConfig.Get((int)itemModel.itemId);
        int _modelID = config.Model;
        if (itemModel.itemId == 3724)
@@ -629,7 +629,7 @@
    {
        WText.gameObject.SetActive(true);
        ItemModel itemModel = playerPack.GetItemByIndex(PackType.Equip, (int)RoleEquipType.Wing);
        ItemModel itemModel = playerPack.GetItemByIndex(PackType.Equip, SpiritWeaponModel.WING_EQUIPINDEX);
        if (itemModel.GetUseData((int)ItemUseDataKey.wingProgressValue) != null)
        {
@@ -691,7 +691,7 @@
        if (_Equipped == (int)RoleEquipType.Wing)
        {
            ItemModel itemModel = playerPack.GetItemByIndex(PackType.Equip, (int)RoleEquipType.Wing);
            ItemModel itemModel = playerPack.GetItemByIndex(PackType.Equip, SpiritWeaponModel.WING_EQUIPINDEX);
            ;
            int ItemColor = ItemLogicUtility.Instance.GetItemQuality(itemModel.itemId, itemModel.useDataDict);
            WingsBG.SetItemBackGround(ItemColor);
@@ -784,7 +784,7 @@
    {
        int MaxMaxOrder = 0;
        ItemModel itemModel = playerPack.GetItemByIndex(PackType.Equip, (int)RoleEquipType.Wing);
        ItemModel itemModel = playerPack.GetItemByIndex(PackType.Equip, SpiritWeaponModel.WING_EQUIPINDEX);
        if (itemModel != null)
        {
            WingRefineExpConfig wingRefineExpConfig = WingRefineExpConfig.Get(itemModel.itemId);
@@ -821,7 +821,7 @@
    List<int> ClassifyList = new List<int>();//存背包位置
    private void WingClassify()
    {
        ItemModel itemModel = playerPack.GetItemByIndex(PackType.Equip, (int)RoleEquipType.Wing);
        ItemModel itemModel = playerPack.GetItemByIndex(PackType.Equip, SpiritWeaponModel.WING_EQUIPINDEX);
        if (itemModel == null)
        {
            return;
@@ -887,7 +887,7 @@
    private int Sort2(int Index)
    {
        int Max = 0;
        ItemModel itemModel = playerPack.GetItemByIndex(PackType.Equip, (int)RoleEquipType.Wing);
        ItemModel itemModel = playerPack.GetItemByIndex(PackType.Equip, SpiritWeaponModel.WING_EQUIPINDEX);
        if (itemModel == null)
        {
            return 0;
Utility/VesselExtension.cs
@@ -1,6 +1,7 @@
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using System;
public static class VesselExtension
{
@@ -20,4 +21,85 @@
        return dictionary == null || dictionary.Count == 0;
    }
    public static T GetFirst<T>(this List<T> list)
    {
        if (list == null)
        {
            throw new ArgumentNullException("List is null.");
        }
        if (list.Count == 0)
        {
            Debug.Log("List count can't be zero.");
            return default(T);
        }
        return list[0];
    }
    public static T GetLast<T>(this List<T> list)
    {
        if (list == null)
        {
            throw new ArgumentNullException("List is null.");
        }
        if (list.Count == 0)
        {
            Debug.Log("List count can't be zero.");
            return default(T);
        }
        return list[list.Count - 1];
    }
    public static T GetFirst<T>(this T[] list)
    {
        if (list == null)
        {
            throw new ArgumentNullException("Array is null.");
        }
        if (list.Length == 0)
        {
            Debug.Log("Array count can't be zero.");
            return default(T);
        }
        return list[0];
    }
    public static T GetLast<T>(this T[] list)
    {
        if (list == null)
        {
            throw new ArgumentNullException("Array is null.");
        }
        if (list.Length == 0)
        {
            Debug.Log("Array count can't be zero.");
            return default(T);
        }
        return list[list.Length - 1];
    }
    public static T GetRandom<T>(this List<T> list)
    {
        if (list == null)
        {
            throw new ArgumentNullException("List is null.");
        }
        if (list.Count == 0)
        {
            Debug.Log("List count can't be zero.");
            return default(T);
        }
        var randomIndex = UnityEngine.Random.Range(0, list.Count);
        return list[randomIndex];
    }
}