From cba0f34cacddb395271f04d29ac7263f05ab39ec Mon Sep 17 00:00:00 2001
From: client_linchunjie <461730578@qq.com>
Date: 星期一, 24 十二月 2018 10:31:43 +0800
Subject: [PATCH] 5367 【前端】【1.4】聚魂功能开发(添加UI特效)

---
 System/GatheringSoul/GatheringSoulModel.cs |   16 ++++++++++++++++
 1 files changed, 16 insertions(+), 0 deletions(-)

diff --git a/System/GatheringSoul/GatheringSoulModel.cs b/System/GatheringSoul/GatheringSoulModel.cs
index 62ace26..537c20a 100644
--- a/System/GatheringSoul/GatheringSoulModel.cs
+++ b/System/GatheringSoul/GatheringSoulModel.cs
@@ -20,6 +20,7 @@
         public Dictionary<int, List<int>> gatherSoulPropertys { get; private set; }
 
         public List<int> packIndexs { get; private set; }
+        public List<int> topBestSoulIndexs = new List<int>();
         public List<GatherSoulItem> resolveItems { get; private set; }
 
         public int holeCount
@@ -46,6 +47,11 @@
         public int coreHole { get; private set; }
 
         public int autoResolveRemainCount { get; private set; }
+
+        public bool serverInited { get; private set; }
+
+        public event Action<PackType, int> prepareResolveEvent;
+
 
         public event Action<int> gatherSoulHoleRefresh;
         public event Action gatherSoulHolesRefresh;
@@ -88,12 +94,15 @@
 
         public void OnBeforePlayerDataInitialize()
         {
+            serverInited = false;
             packIndexs.Clear();
+            topBestSoulIndexs.Clear();
             gatherSoulHoleDict.Clear();
         }
 
         public void OnPlayerLoginOk()
         {
+            serverInited = true;
             CheckAutoResolve();
             UpdateRedpoint();
         }
@@ -234,6 +243,7 @@
         public void RefreshGatherSoulPack()
         {
             packIndexs.Clear();
+            topBestSoulIndexs.Clear();
             List<int> emptyHoles;
             if (ExistEmptyHole(out emptyHoles))
             {
@@ -359,6 +369,7 @@
             {
                 packIndexs.RemoveAt(removeList[i]);
             }
+            topBestSoulIndexs.AddRange(packIndexs);
         }
 
         public bool ExistEmptyHole(out List<int> list)
@@ -784,6 +795,11 @@
             {
                 return;
             }
+            if (prepareResolveEvent != null)
+            {
+                prepareResolveEvent(item.placeType == 0 ? PackType.rptGatherSoul : PackType.rptInterimPack,
+                    item.index);
+            }
             SendResolvePack(new ushort[1] { (ushort)item.index }, false);
         }
 

--
Gitblit v1.8.0