public void GetDamage(int inpDamage) { if (inpDamage <= 0) { return; } if (HP > 0) { changingColor = true; HP -= inpDamage; if (HP <= 0) { monsterController.Die(value); } monsterController.ChangeHealthBar((float)HP / (float)startHP); } }