From 061b35f7f5424cabf6701f28c55c35024d3b19af Mon Sep 17 00:00:00 2001
From: hch <305670599@qq.com>
Date: 星期二, 30 九月 2025 11:58:31 +0800
Subject: [PATCH] 10 【武将】武将系统-测试bug2
---
Main/Component/UI/Common/LongPressButton.cs | 7 +++++++
Main/System/HeroUI/HeroTrainWin.cs | 3 ++-
Main/System/HeroUI/HeroUIManager.cs | 24 +++++++++++++-----------
3 files changed, 22 insertions(+), 12 deletions(-)
diff --git a/Main/Component/UI/Common/LongPressButton.cs b/Main/Component/UI/Common/LongPressButton.cs
index 3cb9cf1..d5ce059 100644
--- a/Main/Component/UI/Common/LongPressButton.cs
+++ b/Main/Component/UI/Common/LongPressButton.cs
@@ -75,6 +75,13 @@
{
if (m_IsButtonDown)
{
+ if (!this.interactable || !this.IsActive() || !this.enabled)
+ {
+ // 濡傛灉鎸夐挳涓嶅彲鐢紝鍒欏彇娑堥暱鎸夌姸鎬�
+ m_IsButtonDown = false;
+ m_LongPress = false;
+ return;
+ }
m_PressTime += Time.deltaTime;
if (m_PressTime < m_LongPressCheckTime)
{
diff --git a/Main/System/HeroUI/HeroTrainWin.cs b/Main/System/HeroUI/HeroTrainWin.cs
index 103d004..9859c31 100644
--- a/Main/System/HeroUI/HeroTrainWin.cs
+++ b/Main/System/HeroUI/HeroTrainWin.cs
@@ -429,7 +429,7 @@
{
lvupBtnText.text = Language.Get("L1110");
lvupBtn.SetInteractable(false);
- lvupMoneyIcon.SetActive(false);
+ lvupMoneyText.SetActive(false);
}
}
@@ -792,6 +792,7 @@
redpointLVUP.SetActive(true);
return;
}
+ return;
}
}
diff --git a/Main/System/HeroUI/HeroUIManager.cs b/Main/System/HeroUI/HeroUIManager.cs
index b0f8634..0380453 100644
--- a/Main/System/HeroUI/HeroUIManager.cs
+++ b/Main/System/HeroUI/HeroUIManager.cs
@@ -163,21 +163,22 @@
return hero.heroLevel >= GetMaxLV(hero.Quality);
}
- //绐佺牬闄愬埗鐨勬渶楂樼瓑绾�; 瀛樺湪绐佺牬绛夌骇鍙兘鏇村鐨勬儏鍐碉紝涓嶄竴瀹氭彁渚涚瓑绾т笂闄�
+ //绐佺牬闄愬埗鐨勬渶楂樼瓑绾�; 濡傛灉瀛樺湪绐佺牬绛夌骇鍚庝笉鑳藉啀鍗囩骇鏄瓥鍒掗厤缃棶棰�
public int GetMaxLVByBreakLV(int quality, int breakLevel)
{
- for (int i = breakLevel; i >= 0; i--)
- {
- var config = HeroQualityBreakConfig.GetQualityBreakConfig(quality, i);
- if (config == null)
- {
- continue;
- }
- return config.LVMax;
- }
- return 0;
+ // for (int i = breakLevel; i >= 0; i--)
+ // {
+ // var config = HeroQualityBreakConfig.GetQualityBreakConfig(quality, i);
+ // if (config == null)
+ // {
+ // continue;
+ // }
+ // return config.LVMax;
+ // }
+ return HeroQualityBreakConfig.GetQualityBreakConfig(quality, breakLevel).LVMax;
}
+ //鏄惁杈惧埌鍥犵獊鐮撮檺鍒剁殑鏈�楂樼骇
public bool IsLVMaxByBreakLevel(HeroInfo hero)
{
return hero.heroLevel == GetMaxLVByBreakLV(hero.Quality, hero.breakLevel);
@@ -416,6 +417,7 @@
{
return 3;
}
+ return 0;
}
}
--
Gitblit v1.8.0