From b6012660fb854274539a032294bb9dbb0b75053c Mon Sep 17 00:00:00 2001
From: hch <305670599@qq.com>
Date: 星期三, 26 十一月 2025 22:14:29 +0800
Subject: [PATCH] 0312 优化武将遣散,图鉴跳转,引导升星武将定位
---
Main/System/HeroUI/HeroDeleteWin.cs | 21 ++++++++++++++++++++-
1 files changed, 20 insertions(+), 1 deletions(-)
diff --git a/Main/System/HeroUI/HeroDeleteWin.cs b/Main/System/HeroUI/HeroDeleteWin.cs
index 94da638..0fd6a4f 100644
--- a/Main/System/HeroUI/HeroDeleteWin.cs
+++ b/Main/System/HeroUI/HeroDeleteWin.cs
@@ -41,6 +41,10 @@
HeroUIManager.Instance.SortHeroDeleteList();
heroSelectBehaviour.Display(0, HeroUIManager.Instance.selectHeroDeleteListJob, HeroUIManager.Instance.selectHeroDeleteListCountry, SelectJobCountry);
RefreshEmptyTip();
+
+ //澶栭儴閫変腑
+ HeroUIManager.Instance.SelectDeleteHero(HeroManager.Instance.GetHero(HeroUIManager.Instance.jumpDeleteHeroGuid));
+
CreateScroller();
}
@@ -51,6 +55,7 @@
PackManager.Instance.RefreshItemLockEvent -= RefreshItemLockEvent;
ItemLogicUtility.Instance.OnGetItemShowEvent -= OnGetItemShowEvent;
HeroUIManager.Instance.selectDeleteHeroList.Clear();
+ HeroUIManager.Instance.jumpDeleteHeroGuid = "";
}
void CreateScroller()
@@ -64,6 +69,7 @@
}
}
scroller.Restart();
+ scroller.JumpIndex(FindJumpIndexByHero(HeroUIManager.Instance.jumpDeleteHeroGuid));
}
void OnRefreshCell(ScrollerDataType type, CellView cell)
@@ -236,8 +242,21 @@
}
void OnGetItemShowEvent()
- {
+ {
HeroUIManager.Instance.SortHeroDeleteList();
CreateScroller();
}
+
+
+ int FindJumpIndexByHero(string guid)
+ {
+ var hero = HeroManager.Instance.GetHero(guid);
+ if (hero == null)
+ return -1;
+ if (hero.Quality > HeroUIManager.Instance.jumpDeleteHeroQuality && !HeroUIManager.Instance.isJumpDeleteHero)
+ {
+ return -1;
+ }
+ return HeroUIManager.Instance.heroDeleteSortList.IndexOf(guid) / 5 - 1;
+ }
}
\ No newline at end of file
--
Gitblit v1.8.0