From 87b962e643fdbfba0a40e688ef561e6327ede275 Mon Sep 17 00:00:00 2001
From: client_Wu Xijin <364452445@qq.com>
Date: 星期三, 12 九月 2018 10:56:13 +0800
Subject: [PATCH] Merge branch 'master' of http://192.168.0.87:10010/r/snxxz_scripts

---
 System/Dogz/DogzItemCell.cs                                                                 |    1 
 System/BlastFurnace/PrayDrugCell.cs.meta                                                    |   12 +
 Core/NetworkPackage/ClientPack/ClientToMapServer/CA5_Function/CA514_tagCMPrayElixir.cs      |   16 ++
 System/BlastFurnace/PrayforDrugWin.cs.meta                                                  |   12 +
 System/BlastFurnace/PrayforDrugWin.cs                                                       |  116 ++++++++++++++
 Core/NetworkPackage/DTCFile/ServerPack/HA3_Function/DTCA321_tagMCPrayElixirResult.cs        |   21 ++
 Core/NetworkPackage/DTCFile/ServerPack/HA3_Function/DTCA321_tagMCPrayElixirResult.cs.meta   |   12 +
 Core/NetworkPackage/ServerPack/HA3_Function/HA321_tagMCPrayElixirResult.cs                  |   19 ++
 System/Rune/RuneMosaicWin.cs                                                                |   30 +++
 Core/GameEngine/DataToCtl/PackageRegedit.cs                                                 |    1 
 System/BlastFurnace/PrayForDurgModel.cs                                                     |  116 ++++++++++++++
 System/BlastFurnace/PrayForDurgModel.cs.meta                                                |   12 +
 System/WindowBase/ModelCenter.cs                                                            |    1 
 Core/NetworkPackage/ServerPack/HA3_Function/HA321_tagMCPrayElixirResult.cs.meta             |   12 +
 System/BlastFurnace/LingDanTips.cs                                                          |    5 
 System/BlastFurnace/PrayDrugCell.cs                                                         |   55 ++++++
 Core/NetworkPackage/ClientPack/ClientToMapServer/CA5_Function/CA514_tagCMPrayElixir.cs.meta |   12 +
 System/Rune/RuneModel.cs                                                                    |   10 
 18 files changed, 454 insertions(+), 9 deletions(-)

diff --git a/Core/GameEngine/DataToCtl/PackageRegedit.cs b/Core/GameEngine/DataToCtl/PackageRegedit.cs
index dcc2338..fef4fc3 100644
--- a/Core/GameEngine/DataToCtl/PackageRegedit.cs
+++ b/Core/GameEngine/DataToCtl/PackageRegedit.cs
@@ -164,6 +164,7 @@
         Register(typeof(HA309_tagMCEquipPartSuiteLVInfo), typeof(DTCA309_tagMCEquipPartSuiteLVInfo));   //寰楀埌濂楄鏁版嵁
         Register(typeof(HA814_tagMCMakeItemAnswer), typeof(DTCA814_tagMCMakeItemAnswer));   //寰楀埌鍚堟垚缁撴灉鍥炲簲
         Register(typeof(HA317_tagMCAllEquipAttrActiveInfo), typeof(DTCA317_tagMCAllEquipAttrActiveInfo));   //寰楀埌婵�娲诲叏韬槦绾у拰鍏ㄨ韩寮哄寲鐨勪俊鎭�
+        Register(typeof(HA321_tagMCPrayElixirResult), typeof(DTCA321_tagMCPrayElixirResult)); //绁堢涓硅嵂缁撴灉
 
         #region 鑳屽寘
         Register(typeof(H0724_tagRolePackCanUseCount), typeof(DTC0724_tagRolePackCanUseCount));
diff --git a/Core/NetworkPackage/ClientPack/ClientToMapServer/CA5_Function/CA514_tagCMPrayElixir.cs b/Core/NetworkPackage/ClientPack/ClientToMapServer/CA5_Function/CA514_tagCMPrayElixir.cs
new file mode 100644
index 0000000..e47c730
--- /dev/null
+++ b/Core/NetworkPackage/ClientPack/ClientToMapServer/CA5_Function/CA514_tagCMPrayElixir.cs
@@ -0,0 +1,16 @@
+using UnityEngine;
+using System.Collections;
+
+// A5 14 祈福丹药 #tagCMPrayElixir

+

+public class CA514_tagCMPrayElixir : GameNetPackBasic {

+

+    public CA514_tagCMPrayElixir () {

+        combineCmd = (ushort)0x03FE;

+        _cmd = (ushort)0xA514;

+    }

+

+    public override void WriteToBytes () {

+    }

+

+}

diff --git a/Core/NetworkPackage/ClientPack/ClientToMapServer/CA5_Function/CA514_tagCMPrayElixir.cs.meta b/Core/NetworkPackage/ClientPack/ClientToMapServer/CA5_Function/CA514_tagCMPrayElixir.cs.meta
new file mode 100644
index 0000000..af2ba62
--- /dev/null
+++ b/Core/NetworkPackage/ClientPack/ClientToMapServer/CA5_Function/CA514_tagCMPrayElixir.cs.meta
@@ -0,0 +1,12 @@
+fileFormatVersion: 2
+guid: 5bde2875341bd7c49962b151d98e4195
+timeCreated: 1536719781
+licenseType: Pro
+MonoImporter:
+  serializedVersion: 2
+  defaultReferences: []
+  executionOrder: 0
+  icon: {instanceID: 0}
+  userData: 
+  assetBundleName: 
+  assetBundleVariant: 
diff --git a/Core/NetworkPackage/DTCFile/ServerPack/HA3_Function/DTCA321_tagMCPrayElixirResult.cs b/Core/NetworkPackage/DTCFile/ServerPack/HA3_Function/DTCA321_tagMCPrayElixirResult.cs
new file mode 100644
index 0000000..6c55840
--- /dev/null
+++ b/Core/NetworkPackage/DTCFile/ServerPack/HA3_Function/DTCA321_tagMCPrayElixirResult.cs
@@ -0,0 +1,21 @@
+using UnityEngine;
+using System.Collections;
+using Snxxz.UI;
+// A3 21 祈福丹药结果 #tagMCPrayElixirResult
+
+
+
+public class DTCA321_tagMCPrayElixirResult : DtcBasic {
+
+    PrayForDurgModel prayModel { get { return ModelCenter.Instance.GetModel<PrayForDurgModel>(); } }
+
+    public override void Done(GameNetPackBasic vNetPack) {
+
+        base.Done(vNetPack);
+
+        HA321_tagMCPrayElixirResult vNetData = vNetPack as HA321_tagMCPrayElixirResult;
+        prayModel.SetPrayResult(vNetData);
+    }
+
+}
+
diff --git a/Core/NetworkPackage/DTCFile/ServerPack/HA3_Function/DTCA321_tagMCPrayElixirResult.cs.meta b/Core/NetworkPackage/DTCFile/ServerPack/HA3_Function/DTCA321_tagMCPrayElixirResult.cs.meta
new file mode 100644
index 0000000..16ba390
--- /dev/null
+++ b/Core/NetworkPackage/DTCFile/ServerPack/HA3_Function/DTCA321_tagMCPrayElixirResult.cs.meta
@@ -0,0 +1,12 @@
+fileFormatVersion: 2
+guid: 0388f4972c8e8d84c93f7797c0ce87a2
+timeCreated: 1536719781
+licenseType: Pro
+MonoImporter:
+  serializedVersion: 2
+  defaultReferences: []
+  executionOrder: 0
+  icon: {instanceID: 0}
+  userData: 
+  assetBundleName: 
+  assetBundleVariant: 
diff --git a/Core/NetworkPackage/ServerPack/HA3_Function/HA321_tagMCPrayElixirResult.cs b/Core/NetworkPackage/ServerPack/HA3_Function/HA321_tagMCPrayElixirResult.cs
new file mode 100644
index 0000000..e2e6d65
--- /dev/null
+++ b/Core/NetworkPackage/ServerPack/HA3_Function/HA321_tagMCPrayElixirResult.cs
@@ -0,0 +1,19 @@
+using UnityEngine;
+using System.Collections;
+
+// A3 21 祈福丹药结果 #tagMCPrayElixirResult

+

+public class HA321_tagMCPrayElixirResult : GameNetPackBasic {

+    public uint ItemID;    // 物品ID

+    public byte PrayCnt;    // 今日祈福次数

+

+    public HA321_tagMCPrayElixirResult () {

+        _cmd = (ushort)0xA321;

+    }

+

+    public override void ReadFromBytes (byte[] vBytes) {

+        TransBytes (out ItemID, vBytes, NetDataType.DWORD);

+        TransBytes (out PrayCnt, vBytes, NetDataType.BYTE);

+    }

+

+}

diff --git a/Core/NetworkPackage/ServerPack/HA3_Function/HA321_tagMCPrayElixirResult.cs.meta b/Core/NetworkPackage/ServerPack/HA3_Function/HA321_tagMCPrayElixirResult.cs.meta
new file mode 100644
index 0000000..ef301a1
--- /dev/null
+++ b/Core/NetworkPackage/ServerPack/HA3_Function/HA321_tagMCPrayElixirResult.cs.meta
@@ -0,0 +1,12 @@
+fileFormatVersion: 2
+guid: 047cdded69879da4181bd2c1bbd0e426
+timeCreated: 1536719781
+licenseType: Pro
+MonoImporter:
+  serializedVersion: 2
+  defaultReferences: []
+  executionOrder: 0
+  icon: {instanceID: 0}
+  userData: 
+  assetBundleName: 
+  assetBundleVariant: 
diff --git a/System/BlastFurnace/LingDanTips.cs b/System/BlastFurnace/LingDanTips.cs
index 6bd330d..fb989e3 100644
--- a/System/BlastFurnace/LingDanTips.cs
+++ b/System/BlastFurnace/LingDanTips.cs
@@ -49,6 +49,7 @@
 
         [SerializeField]
         private Button _makeDanBtn;
+        [SerializeField] Button prayDurgBtn;
 
         [SerializeField] FurnaceFireChooseWin ChooseWin;
         [SerializeField] UIEffect bgEffect;
@@ -95,6 +96,10 @@
             _danDrugCtrl.lockType = EnhanceLockType.KeepVertical;
             _toggleGroup = _danDrugCtrl.GetComponent<ToggleGroup>();
             _makeDanBtn.onClick.AddListener(OnClickMakeDan);
+            prayDurgBtn.AddListener(()=>
+            {
+                WindowCenter.Instance.Open<PrayforDrugWin>();
+            });
             FurnaceModel.RefreshStoveModelEvent += RefreshStoveModel;
             FurnaceModel.RefreshAddSpecMatEvent += SetSpecMatItemCell;
             _randomLineCtrl.OnRefreshCell += RefreshRandomLineCell;
diff --git a/System/BlastFurnace/PrayDrugCell.cs b/System/BlastFurnace/PrayDrugCell.cs
new file mode 100644
index 0000000..a5da5fe
--- /dev/null
+++ b/System/BlastFurnace/PrayDrugCell.cs
@@ -0,0 +1,55 @@
+锘縰sing UnityEngine;
+using UnityEngine.UI;
+using EnhancedUI.EnhancedScroller;
+using TableConfig;
+
+namespace Snxxz.UI
+{
+    public class PrayDrugCell : MonoBehaviour
+    {
+        [SerializeField] CommonItemBaisc itemBaisc;
+        [SerializeField] UIEffect effect;
+
+        ItemTipsModel tipsModel { get { return ModelCenter.Instance.GetModel<ItemTipsModel>(); } }
+        PrayForDurgModel prayModel { get { return ModelCenter.Instance.GetModel<PrayForDurgModel>(); } }
+
+        public void SetDisplayModel(int itemId)
+        {
+            ItemConfig itemConfig = Config.Instance.Get<ItemConfig>(itemId);
+            if(itemConfig == null)
+            {
+                itemBaisc.gameObject.SetActive(false);
+                if(effect.IsPlaying)
+                {
+                    effect.Stop();
+                }
+            }
+            else
+            {
+                int effectId = prayModel.GetEffectIdById(itemId);
+                if(effectId != 0)
+                {
+                    effect.effect = effectId;
+                    effect.Play();
+                }
+                else
+                {
+                    if(effect.IsPlaying)
+                    {
+                        effect.Stop();
+                    }
+                }
+
+                itemBaisc.gameObject.SetActive(true);
+                ItemCellModel cellModel = new ItemCellModel(itemId);
+                itemBaisc.Init(cellModel);
+                itemBaisc.cellBtn.RemoveAllListeners();
+                itemBaisc.cellBtn.AddListener(()=>
+                {
+                    ItemAttrData attrData = new ItemAttrData(itemId);
+                    tipsModel.SetItemTipsModel(attrData);
+                });
+            }
+        }
+    }
+}
diff --git a/System/BlastFurnace/PrayDrugCell.cs.meta b/System/BlastFurnace/PrayDrugCell.cs.meta
new file mode 100644
index 0000000..3733141
--- /dev/null
+++ b/System/BlastFurnace/PrayDrugCell.cs.meta
@@ -0,0 +1,12 @@
+fileFormatVersion: 2
+guid: cf5babd996559ba41b01936b0a94c660
+timeCreated: 1536667518
+licenseType: Pro
+MonoImporter:
+  serializedVersion: 2
+  defaultReferences: []
+  executionOrder: 0
+  icon: {instanceID: 0}
+  userData: 
+  assetBundleName: 
+  assetBundleVariant: 
diff --git a/System/BlastFurnace/PrayForDurgModel.cs b/System/BlastFurnace/PrayForDurgModel.cs
new file mode 100644
index 0000000..8c34c6f
--- /dev/null
+++ b/System/BlastFurnace/PrayForDurgModel.cs
@@ -0,0 +1,116 @@
+锘縰sing LitJson;
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using TableConfig;
+
+namespace Snxxz.UI
+{
+    public class PrayForDurgModel : Model
+    {
+        BlastFurnaceModel blastModel { get { return ModelCenter.Instance.GetModel<BlastFurnaceModel>(); } }
+        PlayerPackModel playerPack { get { return ModelCenter.Instance.GetModel<PlayerPackModel>(); } }
+        Dictionary<int, int> prayDrugDict = new Dictionary<int, int>(); //涓硅嵂id 鐗规晥id
+   
+        public override void Init()
+        {
+            SetPrayDrugCondi();
+            SetPrayDrugDict();
+        }
+
+        public override void UnInit()
+        {
+           
+        }
+
+        #region 璇诲彇鏈湴閰嶇疆
+        public int costMoney { get; private set; }
+        public int everyDayNum { get; private set; }
+        private void SetPrayDrugCondi()
+        {
+            FuncConfigConfig func = Config.Instance.Get<FuncConfigConfig>("GodAlchemy");
+            costMoney = int.Parse(func.Numerical2);
+            everyDayNum = int.Parse(func.Numerical3);
+        }
+        /// <summary>
+        /// 寰楀埌鎵�鏈夌姹備腹鑽暟鎹�
+        /// </summary>
+        private Dictionary<int, int> SetPrayDrugDict()
+        {
+            FuncConfigConfig funcConfig = Config.Instance.Get<FuncConfigConfig>("GodAlchemyShow");
+            JsonData jsonData = JsonMapper.ToObject(funcConfig.Numerical1);
+            prayDrugDict.Clear();
+            if (jsonData.IsArray)
+            {
+                for (int i = 0; i < jsonData.Count; i++)
+                {
+                    if (jsonData[i].IsArray)
+                    {
+                        int itemId = int.Parse(jsonData[i][0].ToString());
+                        if (jsonData[i].Count > 1)
+                        {
+                            int effectId = int.Parse(jsonData[i][1].ToString());
+                            prayDrugDict.Add(itemId, effectId);
+                        }
+                        else
+                        {
+                            prayDrugDict.Add(itemId, 0);
+                        }
+                    }
+                }
+            }
+            return prayDrugDict;
+        }
+        #endregion
+
+        #region 鍗忚
+        public int itemId { get; private set; }
+        public int alreadyPrayNum { get; private set;}
+        public void SetPrayResult(HA321_tagMCPrayElixirResult elixirResult)
+        {
+            itemId = (int)elixirResult.ItemID;
+            alreadyPrayNum = elixirResult.PrayCnt;
+        }
+
+        public void SendPrayElixir()
+        {
+            CA514_tagCMPrayElixir prayElixir = new CA514_tagCMPrayElixir();
+            GameNetSystem.Instance.SendInfo(prayElixir);
+        }
+        #endregion
+
+        List<int> prayIdlist = new List<int>();
+        public List<int> GetPrayDruglist()
+        {
+            prayIdlist.Clear();
+            List<AlchemyConfig> configs = blastModel.alchemyModellist;
+            foreach(var key in prayDrugDict.Keys)
+            {
+                for (int i = 0; i < configs.Count; i++)
+                {
+                    if (blastModel.StoveLV >= configs[i].BlastFurnaceLV)
+                    {
+                        List<int> idlist = blastModel.GetPreviewMakeDruglist(configs[i]).Keys.ToList();
+                        if(idlist.Contains(key))
+                        {
+                            AttrFruitConfig fruitConfig = Config.Instance.Get<AttrFruitConfig>(key);
+                            if (!playerPack.IsReachMaxUseDrug(fruitConfig))
+                            {
+                                prayIdlist.Add(key);
+                            }
+                            break;
+                        }
+                    }
+                }
+            }
+            return prayIdlist;
+        }
+
+        public int GetEffectIdById(int drugId)
+        {
+            int effectId = 0;
+            prayDrugDict.TryGetValue(drugId,out effectId);
+            return effectId;
+        }
+    }
+}
diff --git a/System/BlastFurnace/PrayForDurgModel.cs.meta b/System/BlastFurnace/PrayForDurgModel.cs.meta
new file mode 100644
index 0000000..984db45
--- /dev/null
+++ b/System/BlastFurnace/PrayForDurgModel.cs.meta
@@ -0,0 +1,12 @@
+fileFormatVersion: 2
+guid: 9daef4307100edf43a11679d8c407d48
+timeCreated: 1536671165
+licenseType: Pro
+MonoImporter:
+  serializedVersion: 2
+  defaultReferences: []
+  executionOrder: 0
+  icon: {instanceID: 0}
+  userData: 
+  assetBundleName: 
+  assetBundleVariant: 
diff --git a/System/BlastFurnace/PrayforDrugWin.cs b/System/BlastFurnace/PrayforDrugWin.cs
new file mode 100644
index 0000000..20d4420
--- /dev/null
+++ b/System/BlastFurnace/PrayforDrugWin.cs
@@ -0,0 +1,116 @@
+锘縰sing System;
+using UnityEngine;
+using UnityEngine.UI;
+using System.Collections.Generic;
+
+namespace Snxxz.UI
+{
+    public class PrayforDrugWin : Window
+    {
+        [SerializeField] ScrollerController ctrl;
+        [SerializeField] Button prayBtn;
+        [SerializeField] Text costText;
+        [SerializeField] Button closeBtn;
+        [Header("鏈�澶ф牸瀛愭暟")]
+        [SerializeField] int gridCount = 100;
+        [Header("姣忚鏁伴噺")]
+        [SerializeField] int columnCout = 5;
+
+        PrayForDurgModel PrayModel { get { return ModelCenter.Instance.GetModel<PrayForDurgModel>(); } }
+        List<int> praylist;
+
+        protected override void BindController()
+        {
+            ctrl.OnRefreshCell += RefreshPrayDrug;
+        }
+
+        protected override void AddListeners()
+        {
+            closeBtn.AddListener(CloseClick);
+            prayBtn.AddListener(ClickPrayBtn);
+        }
+
+        protected override void OnPreOpen()
+        {
+            praylist = PrayModel.GetPrayDruglist();
+            UpdatePrayPack();
+        }
+
+        protected override void OnAfterOpen()
+        {
+
+        }
+
+        protected override void OnPreClose()
+        {
+
+        }
+
+        protected override void OnAfterClose()
+        {
+
+        }
+
+        private void SetDisplayUI()
+        {
+            costText.text = PrayModel.costMoney.ToString();
+        }
+
+
+        private void ClickPrayBtn()
+        {
+            if(PrayModel.alreadyPrayNum >= PrayModel.everyDayNum)
+            {
+                MessageWin.Inst.ShowFixedTip("浠婃棩绁堢娆℃暟宸叉弧");
+                return;
+            }
+
+            if(UIHelper.GetMoneyCnt(1) >= (ulong)PrayModel.costMoney)
+            {
+                PrayModel.SendPrayElixir();
+            }
+            else
+            {
+                WindowCenter.Instance.Open<RechargeTipWin>();
+            }
+        }
+
+        private void UpdatePrayPack()
+        {
+            if (ctrl.GetNumberOfCells(ctrl.m_Scorller) == 0)
+            {
+                ctrl.Refresh();
+                var _line = gridCount / columnCout;
+                for (int i = 0; i < _line; i++)
+                {
+                    ctrl.AddCell(ScrollerDataType.Header, i);
+                }
+                ctrl.Restart();
+            }
+            else
+            {
+                ctrl.m_Scorller.RefreshActiveCellViews();
+            }
+        }
+
+        private void RefreshPrayDrug(ScrollerDataType type, CellView cell)
+        {
+            var _line = cell.index;
+            int length = cell.transform.childCount;
+            for (int i = 0; i < length; i++)
+            {
+                var _index = _line * length + i;
+                PrayDrugCell prayCell = cell.transform.GetChild(i).GetComponent<PrayDrugCell>();
+                if(_index < praylist.Count)
+                {
+                    prayCell.SetDisplayModel(praylist[_index]);
+                }
+                else
+                {
+                    prayCell.SetDisplayModel(0);
+                }
+               
+            }
+        }
+    }
+}
diff --git a/System/BlastFurnace/PrayforDrugWin.cs.meta b/System/BlastFurnace/PrayforDrugWin.cs.meta
new file mode 100644
index 0000000..5b1ea68
--- /dev/null
+++ b/System/BlastFurnace/PrayforDrugWin.cs.meta
@@ -0,0 +1,12 @@
+fileFormatVersion: 2
+guid: e78dc3625a4636348b8ef7501bdb51a2
+timeCreated: 1536667028
+licenseType: Pro
+MonoImporter:
+  serializedVersion: 2
+  defaultReferences: []
+  executionOrder: 0
+  icon: {instanceID: 0}
+  userData: 
+  assetBundleName: 
+  assetBundleVariant: 
diff --git a/System/Dogz/DogzItemCell.cs b/System/Dogz/DogzItemCell.cs
index 4b3e648..92e1ec5 100644
--- a/System/Dogz/DogzItemCell.cs
+++ b/System/Dogz/DogzItemCell.cs
@@ -15,7 +15,6 @@
         {
             dogzModel.GetDogzItemList();
             ItemModel model = null;
-            DebugEx.Log("Display:" + index + "鏁版嵁闀垮害锛�" + dogzModel.dogzItemList.Count);
             if (index < dogzModel.dogzItemList.Count)
             {
                 model = dogzModel.dogzItemList[index];
diff --git a/System/Rune/RuneModel.cs b/System/Rune/RuneModel.cs
index a8f35fa..ca97fe7 100644
--- a/System/Rune/RuneModel.cs
+++ b/System/Rune/RuneModel.cs
@@ -691,10 +691,6 @@
                     }
                 }
             }
-            if (OnRefreshRuneHole != null)
-            {
-                OnRefreshRuneHole();
-            }
             for (int i = 0; i < RUNE_HOLE_COUNT; i++)
             {
                 if (!serverInited)
@@ -702,7 +698,7 @@
                     break;
                 }
                 int k = 1 << i;
-                var oldOpen = (holeState & k) == k;
+                var oldOpen = (oldHoleState & k) == k;
                 if (!oldOpen && IsRuneHoleOpen(i))
                 {
                     if (openNewHoleEvent != null)
@@ -711,6 +707,10 @@
                     }
                 }
             }
+            if (OnRefreshRuneHole != null)
+            {
+                OnRefreshRuneHole();
+            }
             UpdateRedpoint();
             UpdateBreakRedpoint();
             UpdateSpecialHoleRedpoint();
diff --git a/System/Rune/RuneMosaicWin.cs b/System/Rune/RuneMosaicWin.cs
index 66369ec..f49d32c 100644
--- a/System/Rune/RuneMosaicWin.cs
+++ b/System/Rune/RuneMosaicWin.cs
@@ -67,6 +67,8 @@
         }
 
         bool m_IsRuneLvUp = false;
+        int m_SpecialHoleUnlocking = -1;
+        Coroutine m_CacheCoroutine;
         #region Built-in
         protected override void BindController()
         {
@@ -102,6 +104,7 @@
             m_ContainerSpecial.gameObject.SetActive(false);
             OpenOrCloseSelect(false);
             model.sltRuneHole = -1;
+            m_SpecialHoleUnlocking = -1;
             foreach (var _hole in runeHoleDatas)
             {
                 _hole.SetSelect(false);
@@ -123,6 +126,14 @@
             model.OnRefreshRuneHole -= OnRuneHoleRefresh;
             model.OnRefreshRuneExp -= OnUpdateRuneHoleInfo;
             model.openNewHoleEvent -= OpenNewHoleEvent;
+
+            m_SpecialHoleUnlocking = -1;
+
+            if (m_CacheCoroutine != null)
+            {
+                StopCoroutine(m_CacheCoroutine);
+                m_CacheCoroutine = null;
+            }
         }
 
         protected override void OnAfterClose()
@@ -134,8 +145,17 @@
         {
             if (model.IsSpeicalHole(hole))
             {
-
+                m_SpecialHoleUnlocking = hole;
+                EffectMgr.Instance.PlayUIEffect(3068, 2500, runeHoleDatas[hole].Container.parent, false);
+                m_CacheCoroutine = StartCoroutine(Co_RefreshHole());
             }
+        }
+
+        IEnumerator Co_RefreshHole()
+        {
+            yield return WaitingForSecondConst.WaitMS800;
+            m_SpecialHoleUnlocking = -1;
+            OnRuneHoleRefresh();
         }
 
         private void UnlockSpecialHole()
@@ -227,7 +247,7 @@
 
         void OnRuneHoleClick(int _hole)
         {
-            if (model.IsRuneHoleOpen(_hole))
+            if (model.IsRuneHoleOpen(_hole) && m_SpecialHoleUnlocking != _hole)
             {
                 for (int i = 0; i < runeHoleDatas.Count; i++)
                 {
@@ -284,6 +304,10 @@
             model.runeLevelUpRedpoint.state = RedPointState.None;
             model.runeReplaceRedpoint.state = RedPointState.None;
             if (model.sltRuneHole == -1 || !model.IsRuneHoleOpen(model.sltRuneHole))
+            {
+                return;
+            }
+            if (model.sltRuneHole == m_SpecialHoleUnlocking)
             {
                 return;
             }
@@ -403,7 +427,7 @@
             for (int i = 0; i < runeHoleDatas.Count; i++)
             {
                 RuneData data = model.GetHoleRune(i);
-                runeHoleDatas[i].SetRuneHole(!model.IsRuneHoleOpen(i));
+                runeHoleDatas[i].SetRuneHole(!model.IsRuneHoleOpen(i) || m_SpecialHoleUnlocking == i);
                 if (data == null || !model.IsRuneHoleOpen(i))
                 {
                     runeHoleDatas[i].Display(0, 0);
diff --git a/System/WindowBase/ModelCenter.cs b/System/WindowBase/ModelCenter.cs
index f9268e0..c548095 100644
--- a/System/WindowBase/ModelCenter.cs
+++ b/System/WindowBase/ModelCenter.cs
@@ -192,6 +192,7 @@
             RegisterModel<TreasureSoulModel>();
             RegisterModel<FairyGrabBossModel>();
             RegisterModel<GodBeastModel>();
+            RegisterModel<PrayForDurgModel>();
             inited = true;
         }
 

--
Gitblit v1.8.0