Luz.Net.WebRtcNetwork.Connect C# (CSharp) Method

Connect() public method

Connects to the given name or address.
public Connect ( string name ) : ConnectionId
name string The address identifying the server
return Luz.ULib.Net.ConnectionId
        public ConnectionId Connect(string name)
        {
            //until fully supported -> block connecting to others while running a server
            if (this.mIsServer == true)
            {
                UnityEngine.Debug.LogError("Can't create outgoing connections while in server mode!");
                return ConnectionId.INVALID;
            }

            ConnectionId id = new ConnectionId();
            id.id = (short)UnityWebRtcNetworkConnect(mReference, name);
            return id;
        }