private void CheckConnection(Server server)
    {
        // Send discovery message to servers to see if there is a response back.
        IPAddress ipAddress = IPAddress.Parse(server.details.ipaddress);
        ushort    port      = ushort.Parse(server.details.port);

        NetworkDiscovery.SendDiscoveryRequest(new IPEndPoint(ipAddress, port));
    }
    public void CheckAllConnections()
    {
        foreach (Server server in this.serverListItems)
        {
            server.item.SetIsConnected(false);

            IPAddress ipAddress = IPAddress.Parse(server.details.ipaddress);
            ushort    port      = ushort.Parse(server.details.port);
            NetworkDiscovery.SendDiscoveryRequest(new IPEndPoint(ipAddress, port));
        }
    }
    public void LookupServer()
    {
        // parse IP and port

        IPAddress ip   = IPAddress.Parse(m_lookupServerIP);
        ushort    port = ushort.Parse(m_lookupServerPort);

        // input is ok
        // send discovery request

        m_timeWhenLookedUpServer = Time.realtimeSinceStartup;

        m_lookupServer = new IPEndPoint(ip, port);

        NetworkDiscovery.SendDiscoveryRequest(m_lookupServer);
    }