private void OnTriggerEnter(Collider other) { if (other.gameObject.CompareTag(OwnerTag) && Ability.BaseDamage > 0) { return; } if (!other.gameObject.CompareTag(OwnerTag) && Ability.BaseDamage > 0) { return; } Component comp = other.gameObject.GetComponent(typeof(IDamageable)); if (comp == null) { return; } GameFuncs.ChangeHealth(other, comp, Ability); Destroy(gameObject); }