// Use this for initialization void OnTriggerEnter2D(Collider2D other) { if (!playerHealth.IsInvisible) { if (other.tag == "Player") { playerHealth.TakeHit(Attack_Damage); } } }