Example #1
0
 private void FixedUpdate()
 {
     GetComponent <Text>().text = $"{_health.GetPercentage()}%";
 }
Example #2
0
 private void Update()
 {
     GetComponent <Text>().text = String.Format("{0:0}%", health.GetPercentage());
 }
Example #3
0
 private string ComposeHealthText()
 {
     return(String.Format("{0:0}%", health.GetPercentage()));
 }
Example #4
0
 private void Update()
 {
     healthValue.text = String.Format("{0:0}%", health.GetPercentage());
 }