void OnTriggerEnter2D(Collider2D hitInfo) { Ace enemy = hitInfo.GetComponent <Ace>(); if (enemy != null) { Destroy(gameObject); enemy.TakeDamage(damage); } }