diff --git a/Role/Attack.cs b/Role/Attack.cs index df1f556..d248cc1 100644 --- a/Role/Attack.cs +++ b/Role/Attack.cs @@ -70,12 +70,12 @@ public class Attack : MonoBehaviour return; } - /*if(bulletPrefab.GetComponent().myBulletType==BulletType.Spraying) + if (bulletPrefab.GetComponent().myBulletType == BulletType.Spraying) { - + GameObject BulletGamobj = GameObject.Instantiate(bulletPrefab, this.transform.root); return; } - */ + Vector2 direction = (targetRole.transform.position - transform.position).normalized;