From bd0ba263761a866ca0d698169d2d83b6a11c35e7 Mon Sep 17 00:00:00 2001
From: CoderM <coderm@qq.com>
Date: Thu, 10 Dec 2020 17:04:37 +0800
Subject: [PATCH] CoderM: 增加SDKJSON处理

---
 Assets/Scripts/ActionGameFramework/Health/DamageCollider.cs |   14 +++-----------
 1 files changed, 3 insertions(+), 11 deletions(-)

diff --git a/Assets/Scripts/ActionGameFramework/Health/DamageCollider.cs b/Assets/Scripts/ActionGameFramework/Health/DamageCollider.cs
index 139ca35..b39d49a 100644
--- a/Assets/Scripts/ActionGameFramework/Health/DamageCollider.cs
+++ b/Assets/Scripts/ActionGameFramework/Health/DamageCollider.cs
@@ -52,23 +52,15 @@
 
             // 非Agent不参与碰撞:
             var agent = this.gameObject.GetComponent<Agent>();
-            if (agent == null)
+            if (agent == null || agent.isDead)
                 return;
-            
+
             BallisticProjectile ballistic = c.gameObject.GetComponent<BallisticProjectile>();
-
-            if (ballistic.IsHitEnemy)
-            {
-                Debug.Log("--------------------- 已发生过碰撞 ---------------------");
-                return;
-            }
-
-            ballistic.IsHitEnemy = true;
 
             LazyLoad();
 
             BallisticAttack ballisticAttack = damager.GetComponent<BallisticAttack>();
-            ballisticAttack.DealDamage((Targetable)damageableBehaviour);
+            ballisticAttack.DealDamage((Targetable)damageableBehaviour, damager.IsEnhancedBullet);
 
             damager.HasDamaged(c.transform.position, damageableBehaviour.configuration.alignmentProvider);
         }

--
Gitblit v1.9.1