private void OnTriggerEnter2D(Collider2D collision) { if (collision != null && hitActive == true) { if (collision.tag == "Player") { Player_Health.reduceHealth(swordDamage); Debug.Log("Player Health: " + Player_Health.health); } } }
private void attackPlayer() { Player_Health.reduceHealth(bumpDamage); Debug.Log("Player Health: " + Player_Health.health); }