how get get input for username / password in scene

created a login screen. how do i get a blinking cursor in the username field for player to enter string there.

i know how to get input for console. just not sure how to get the cursor onthe sceen in a graphic scene.

how that question makes sense.

You can use a GUI.TextField to get the input string from the user and GUIStyle for the looks of it. It handles all the typing stuff right away for you.

public class BlinkingCursor : MonoBehaviour {

	private float m_TimeStamp;
	private bool cursor = false;
	private string cursorChar = "";
	private int maxStringLength = 24;

        void update() {
             if (Time.time - m_TimeStamp >= 0.5)
       		{
       			m_TimeStamp = Time.time;
       			if (cursor == false)
       			{
                                cursor = true;
       				if (enteredString.Length < maxStringLength)
       				{
       					cursorChar += "_";
       				}
       			}
       			else
       			{
       				cursor = false;
       				if (cursorChar.Length != 0)
       				{
       					cursorChar = cursorChar.Substring(0, cursorChar.Length - 1);
       				}
       			}
       		}
        }
}

Credit to Joseph Quigley