Hi. So i have this small function it called from gui button.“SaveP” part is working fine,but part with Input not working at all.I don’t have any errors it’s just not working.What am I doing wrong here? Thank you.
public void OnSavebutton()
{
//InputF = GameObject.Find ("CarNameEnter");
SaveP.SetActive (true);
if (Input.GetKeyDown (KeyCode.Return)) {
InputField inp = InputF.GetComponent<InputField> ();
CarName = inp.text;
test = true;
}
}