public void JoinGameRelay() { if (networkManagerObject) { connectedPlayersCanvas.SetActive(true); NetworkedGameManager_Script nm = networkManagerObject.GetComponent <NetworkedGameManager_Script>(); nm.SetIpAddress(GameObject.Find("IP Input Field").GetComponent <InputField>().text); nm.SetPort(); nm.StartClient(); } }
public void JoinGameRelay() { if (networkManagerObject) { NetworkedGameManager_Script nm = networkManagerObject.GetComponent <NetworkedGameManager_Script>(); nm.SetIpAddress(GameObject.Find("IP Input Field").GetComponent <InputField>().text); nm.SetPort(); nm.StartClient(); startJoinPanelObject.SetActive(false); ipFieldObject.GetComponent <InputField>().text = nm.networkAddress.ToString(); ipFieldObject.GetComponent <InputField>().interactable = false; cancelConnectionButtonObject.SetActive(true); connectedPlayersCanvas.SetActive(true); } }