public void MyUpdate() { laser.MyUpdate(); flameThrower.MyUpdate(); mLauncher.MyUpdate(); hDash.MyUpdate(); absorb.MyUpdate(); percentage = Mathf.Clamp01(stamina / 100); if (stamina < 0) { stamina = 0; } ConstantGainStamina(); ConstantGainLife(); staminaMat.SetFloat("Vector1_8DF954C3", percentage); }