I have an Input Field and I want to input stuff into. Problem is, whenever I move over it with the controller, it auto-selects and I can’t move off it after.
I want to have a mode where I can move over it and to the buttons below and above, but only when I press the A button does it lock me into that field and allow me to use it, then when I press B it deselects and I can continue navigating the menu.
i don’t exactly know how to do this but here is a similar script I just wrote
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.UI;
public class Quitting : MonoBehaviour {
public Text QuitText;
private string QuitString = "Quitting";
void Update()
{
if (Input.GetKey("escape"))
{
StartCoroutine("WaitBeforeQuit");
QuitText.text = "QUITTING";
}
}
public IEnumerator WaitBeforeQuit()
{
yield return new WaitForSeconds(10);
if (Input.GetKey("escape"))
{
Debug.Log("Quit");
Application.Quit();
}
else
{
QuitText.text = "";
}
}
}