public void Heal(float healamount) { Debug.Log("player was healed of " + healamount + " pv"); Debug.Log(health + " + " + healamount); health = health + healamount; uImanager.animator.SetTrigger("heal"); print("heal"); uImanager.Healsound(); if (health > maxhealth) { health = maxhealth; } //change la saturation du perso quand il prend des dégats meshRenderer.material.SetFloat("_saturation", health / maxhealth); uImanager.HpupdateUI(); }