From fbea95ff1d813328f13ad7a3ece021d2271f093a Mon Sep 17 00:00:00 2001
From: yyl <yyl>
Date: 星期四, 27 十一月 2025 15:43:11 +0800
Subject: [PATCH] 125 战斗 击晕支持

---
 Main/System/Battle/Skill/SkillBase.cs |   55 ++++++++++++++++++++++++++++++++++++++++++++++++++-----
 1 files changed, 50 insertions(+), 5 deletions(-)

diff --git a/Main/System/Battle/Skill/SkillBase.cs b/Main/System/Battle/Skill/SkillBase.cs
index c60313e..50fc65b 100644
--- a/Main/System/Battle/Skill/SkillBase.cs
+++ b/Main/System/Battle/Skill/SkillBase.cs
@@ -252,11 +252,9 @@
                 hintConfig = DamageNumConfig.Get(BattleConst.BattleChaseAttack);
             }
             
-            if (hintConfig != null)
-            {
-                caster.heroInfoBar.ShowTips(((char)hintConfig.prefix).ToString(), true, false, 1.25f);
-                // Debug.Break();
-            }
+            Hint(caster, hintConfig);
+
+
         }
 
         // 楂樹寒鎵�鏈夋湰娆℃妧鑳界浉鍏崇殑鐩爣
@@ -285,6 +283,14 @@
                 Debug.LogError("寮哄埗缁撴潫鎶�鑳� 鏆傛椂涓嶆敮鎸佸叾浠栫殑鏂瑰紡閲婃斁 鏈夐渶姹俻lease鑱旂郴绛栧垝 鎶�鑳絠d:" + skillConfig.SkillID + " cast position " + skillConfig.CastPosition);
                 ForceFinished();
                 break;
+        }
+    }
+
+    protected void Hint(BattleObject battleObject, DamageNumConfig hintConfig)
+    {
+        if (hintConfig != null)
+        {
+            battleObject.heroInfoBar.ShowTips(((char)hintConfig.prefix).ToString(), true, false, 1.25f);
         }
     }
 
@@ -633,6 +639,45 @@
                 OnHitEachTargetEx(_hitIndex, exTarget, hurtEx);
             }
         }
+
+        if (0 == _hitIndex)
+        {
+            bool needhint = false;
+
+            for (int i = 0; i < hitList.Count; i++)
+            {
+                var hurt = hitList[i];
+
+                //8-鍑绘檿
+                if ((hurt.AttackTypes & (int)DamageType.Stunned) == (int)DamageType.Stunned)
+                {
+                    needhint = true;
+                    break;
+                }
+
+                for (int j = 0; j < hurt.HurtListEx?.Length; j++)
+                {
+                    var hurtex = hurt.HurtListEx[j];
+                    //8-鍑绘檿
+                    if ((hurtex.AttackTypes & (int)ServerDamageType.Stunned) == (int)ServerDamageType.Stunned)
+                    {
+                        needhint = true;
+                        break;
+                    }
+                }
+
+                if (needhint)
+                    break;
+            }
+
+            if (needhint)
+            {
+                DamageNumConfig hintConfig = DamageNumConfig.Get(BattleConst.BattleStun);
+                Hint(caster, hintConfig);
+            }
+        }
+
+        
     }
 
     // 澶勭悊鍗曚釜鐩爣琚懡涓�:搴旂敤浼ゅ鍜屾柦娉曡�呮晥鏋�

--
Gitblit v1.8.0