mirror of
https://github.com/Leahnaya/TheKingsRace.git
synced 2026-08-22 18:34:32 -05:00
Updated a lot of text to tmp and updated title
This commit is contained in:
@@ -14,9 +14,13 @@ public class ConnectButtons : MonoBehaviour {
|
||||
public GameObject ErrorPanel;
|
||||
public Text ErrorText;
|
||||
|
||||
public GameObject ipAddressObject;
|
||||
public InputField ipAddressField;
|
||||
public TMP_InputField playerNameField;
|
||||
|
||||
public GameObject hostButton;
|
||||
public GameObject joinButton;
|
||||
|
||||
private int connectionTimeoutTime = 5;
|
||||
|
||||
void Start() {
|
||||
@@ -79,6 +83,19 @@ public class ConnectButtons : MonoBehaviour {
|
||||
StartCoroutine(checkIsConnectedClient());
|
||||
}
|
||||
|
||||
public void ToggleIPAddress(){
|
||||
if(ipAddressObject.active){
|
||||
ipAddressObject.SetActive(false);
|
||||
hostButton.SetActive(true);
|
||||
joinButton.SetActive(true);
|
||||
}
|
||||
else{
|
||||
ipAddressObject.SetActive(true);
|
||||
hostButton.SetActive(false);
|
||||
joinButton.SetActive(false);
|
||||
}
|
||||
}
|
||||
|
||||
IEnumerator checkIsConnectedClient() {
|
||||
yield return new WaitForSecondsRealtime(connectionTimeoutTime);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user