I’ve made it different, but looks more easy to me that way, is it more resources costly that way?
private void Update()
{
if (healthComponent.GetHealthPoint() < healthComponent.GetMaxHealthPoints())
canvas.gameObject.SetActive(true);
forground.localScale = new Vector3(healthComponent.GetFraction(), 1, 1);
if (healthComponent.IsDead())
D