public void AgeValueChangeCheck() { if (p != null) { p.SetAge(Mathf.RoundToInt(ageSlider.value)); ageText.text = "Age: " + p.GetAge(); } }