Browse Source

修改bug

lzx 1 day ago
parent
commit
b784413292

+ 1 - 1
Assets/Res/UI/HeroInformainPanel/ExpElixirItemWidget.prefab

@@ -689,7 +689,7 @@ RectTransform:
   m_AnchorMin: {x: 0, y: 1}
   m_AnchorMax: {x: 0, y: 1}
   m_AnchoredPosition: {x: 43.997498, y: -12.5}
-  m_SizeDelta: {x: 24, y: 23.1372}
+  m_SizeDelta: {x: 0, y: 23.1372}
   m_Pivot: {x: 0.5, y: 0.5}
 --- !u!222 &7796567445027890541
 CanvasRenderer:

+ 16 - 5
Assets/Scripts/GameUI/UI/DaoYouPanel/DaoYouInfoPanel.cs

@@ -596,11 +596,22 @@ namespace Fort23.Mono
             Text_Count.text = $"当前选择数量{count}";
             if (widgetItem1 != null && daoyouGiftConfig.ID != 0)
             {
-                Text_GiveGiftDesc.text = LanguageManager.Instance.Text(10289, daoyouGiftConfig.emotionValue,
-                    (daoyouGiftConfig.emotionValue * emotionConfig.hanganUpRate[0] *
-                     PlayerManager.Instance.gameConstantConfig.daolvfavoratePara * 0.01f * 0.001).ToString("0.0"),
-                    (daoyouGiftConfig.emotionValue * emotionConfig.hanganUpRate[1] *
-                     PlayerManager.Instance.gameConstantConfig.daolvfavoratePara * 0.01f * 0.001).ToString("0.0"));
+                if (_daoyouModelConfig.PreferGiftID.Contains(daoyouGiftConfig.ItemID))
+                {
+                    Text_GiveGiftDesc.text = LanguageManager.Instance.Text(10289, daoyouGiftConfig.emotionValue,
+                        (daoyouGiftConfig.emotionValue * emotionConfig.hanganUpRate[0] *
+                         PlayerManager.Instance.gameConstantConfig.daolvfavoratePara * 0.01f * 0.001).ToString("0.0"),
+                        (daoyouGiftConfig.emotionValue * emotionConfig.hanganUpRate[1] *
+                         PlayerManager.Instance.gameConstantConfig.daolvfavoratePara * 0.01f * 0.001).ToString("0.0"));
+                }
+                else
+                {
+                    Text_GiveGiftDesc.text = LanguageManager.Instance.Text(10289, daoyouGiftConfig.emotionValue,
+                        (daoyouGiftConfig.emotionValue * emotionConfig.hanganUpRate[0] * 0.001).ToString("0.0"),
+                        (daoyouGiftConfig.emotionValue * emotionConfig.hanganUpRate[1] * 0.001).ToString("0.0"));
+                }
+
+      
             }
             else if (widgetItem1 != null && daoyouGiftConfig.ID == 0)
             {

+ 58 - 55
Assets/Scripts/GameUI/UI/HeroInformationPanel/CaveMainPanel.cs

@@ -3,65 +3,68 @@ using Fort23.Core;
 
 namespace Fort23.Mono
 {
-	[UIBinding(prefab = "CaveMainPanel"  )]
-	public partial class CaveMainPanel : UIPanel
-	{
-		private void Init()
-		{
-			isAddStack = true;
-			IsShowAppBar = true;
-		}
-		protected override void AddEvent()
-		{
+    [UIBinding(prefab = "CaveMainPanel")]
+    public partial class CaveMainPanel : UIPanel
+    {
+        private void Init()
+        {
+            isAddStack = true;
+            IsShowAppBar = true;
+        }
 
-		}
-		protected override void DelEvent()
-		{
-			
-		}
+        protected override void AddEvent()
+        {
+        }
 
-		public override void Hide()
-		{
-			base.Hide();
-			AudioManager.Instance.PlayBGM("xunlongduobao.wav");
-		}
+        protected override void DelEvent()
+        {
+        }
 
-		public override void AddButtonEvent()
-		{
-			Btn_DaoLv.onClick.AddListener(() => { ImmortalBondPanel.OpenPanel(); });
-			
-			Btn_XiuLian.onClick.AddListener(() =>
-			{
-				 HeroInformationPanel.OpenPanel();
-			});
+        public override void Hide()
+        {
+            base.Hide();
+            AudioManager.Instance.PlayBGM("xunlongduobao.wav");
+        }
 
-		}
-		
-		public override CTask GetFocus()
-		{
-			AppBarPanel.OpenPanel(this);
-			TitlePanel.OpenPanel();
-			
-			if (PlayerGuideManager.Instance.GuideIsCanDo(6, 1))
-			{
-				PlayerGuideManager.Instance.NextGuide();
-			}
-		
-			return base.GetFocus();
-		}
+        public override void AddButtonEvent()
+        {
+            Btn_DaoLv.onClick.AddListener(() => { ImmortalBondPanel.OpenPanel(); });
 
-		public override CTask LoseFocus()
-		{
-			// TitlePanel.ClosePanel();
-			return base.LoseFocus();
-		}
+            Btn_XiuLian.onClick.AddListener(() => { HeroInformationPanel.OpenPanel(); });
+        }
 
-		public async static CTask<CaveMainPanel> OpenPanel()
-		{
-			CaveMainPanel heroInformationPanel = await UIManager.Instance.LoadAndOpenPanel<CaveMainPanel>(null);
-			AudioManager.Instance.PlayBGM("dongfu.mp3");
-			return heroInformationPanel;
-		}
+        public override CTask GetFocus()
+        {
+            AppBarPanel.OpenPanel(this);
+            TitlePanel.OpenPanel();
 
-	}
-}
+            if (PlayerGuideManager.Instance.GuideIsCanDo(6, 1))
+            {
+                PlayerGuideManager.Instance.NextGuide();
+            }
+
+            return base.GetFocus();
+        }
+
+        public override CTask LoseFocus()
+        {
+            // TitlePanel.ClosePanel();
+            return base.LoseFocus();
+        }
+
+        public async static CTask<CaveMainPanel> OpenPanel()
+        {
+            CaveMainPanel heroInformationPanel = await UIManager.Instance.LoadAndOpenPanel<CaveMainPanel>(null);
+            AudioManager.Instance.PlayBGM("dongfu.mp3");
+            return heroInformationPanel;
+        }
+
+        public async override CTask Close()
+        {
+            await UIManager.Instance.HideUIUIPanel<HeroInformationPanel>(isBreadcrumbBarPanel: false);
+            await UIManager.Instance.HideUIUIPanel<HeroBreakthroughPanel>(isBreadcrumbBarPanel: false);
+            await UIManager.Instance.HideUIUIPanel<SelectBreakthroughItemPanel>(isBreadcrumbBarPanel: false);
+            await base.Close();
+        }
+    }
+}

+ 1 - 0
Assets/Scripts/GameUI/UI/HeroInformationPanel/SelectBreakthroughItemPanel.cs

@@ -97,6 +97,7 @@ namespace Fort23.Mono
                 }
                 else
                 {
+                    Text_Affirm.text = "使用";
                     Btn_Affirm.gameObject.SetActive(true);
                     Btn_Cancel.gameObject.SetActive(true);
                     Text_NoEnough.gameObject.SetActive(true);