From 40a39cee0bcb5451a78508fd65159a0ffa5e714e Mon Sep 17 00:00:00 2001
From: client_Wu Xijin <364452445@qq.com>
Date: 星期二, 04 九月 2018 16:58:44 +0800
Subject: [PATCH] Merge branch 'master' of http://192.168.0.87:10010/r/snxxz_scripts

---
 System/MainInterfacePanel/TaskListTip.cs |   47 +++++++++++++++++++----------------------------
 1 files changed, 19 insertions(+), 28 deletions(-)

diff --git a/System/MainInterfacePanel/TaskListTip.cs b/System/MainInterfacePanel/TaskListTip.cs
index 37be57d..079668c 100644
--- a/System/MainInterfacePanel/TaskListTip.cs
+++ b/System/MainInterfacePanel/TaskListTip.cs
@@ -198,31 +198,9 @@
 
         private void MainCardLevelChange(int _id)
         {
-            TaskScheduling();
-            bool IsDefault = true;
-            var State = taskmodel.GetTaskStatus(_id);
-            if (State == PlayerTaskDatas.TaskStatus.CardLevel)
-            {
-                IsDefault = false;
-            }
-            if (IsDefault)
-            {
-                foreach (var key in taskmodel.MainTaskDic.Keys)
-                {
-                    if (taskmodel.MainTaskDic[key].MissionState != 3)
-                    {
-                        taskmodel.GetNowTaskID = key;
-                    }
-                }
-            }
-            else
-            {
-                if (_list.Count > 0)
-                {
-                    taskmodel.GetNowTaskID = _list[0];
-                }
-            }
+            TaskScheduling();    
             TheTaskToGenerate();
+            TaskJump(_id);
         }
 
         private void SetLength()
@@ -350,11 +328,13 @@
         void OnTaskToDelete(int _IdTask)//浠诲姟鐨勫垹闄�
         {
             var inDungeon = IsDungeon();
+            TaskScheduling();
             if (WindowCenter.Instance.CheckOpen<MainInterfaceWin>() && !inDungeon)
             {
-                LodingDelTask(_IdTask);
+                TheTaskToGenerate();//浠诲姟鍒楄〃闇�瑕侀噸鏂版帓鍒楅噸鏂板埛鏂拌祴鍊�
+               // LodingDelTask(_IdTask);
             }
-            TaskScheduling();
+           
         }
 
 
@@ -442,9 +422,20 @@
             return mapConfig != null && mapConfig.MapFBType != 0;
         }
 
-        private void TaskJump()
+        private void TaskJump(int TaskID=0)
         {
-            int type = _list.IndexOf(taskmodel.GetNowTaskID);
+            int type = 0;
+            if (TaskID == 0)
+            {
+                type= _list.IndexOf(taskmodel.GetNowTaskID);
+            }
+            else
+            {
+                if (_list.Contains(TaskID))
+                {
+                    type = _list.IndexOf(TaskID);
+                }           
+            }
             if (_list.Count <= 2 || type <= 0)
             {
                 m_ScrollRect.verticalNormalizedPosition = 1;

--
Gitblit v1.8.0