public bool Initialize() { // Set configuration Config.UDPListenPort = 0; Config.MaximumClients = 10; SDKJsonResult result = Create(); if (result.Failed()) { Console.WriteLine("Unable to create socket: {0}", result.ToString()); return result.Good(); } MyClientConnection conn = new MyClientConnection(this); result = Connect( conn, Constants.TONK_TEST_SERVER_IP, Constants.UDPServerPort); if (result.Failed()) { Console.Write("Unable to connect: {0}", result.ToString()); } else { TestTools.SendPreconnectData(conn); } return result.Good(); }
public bool Initialize() { // Set configuration Config.UDPListenPort = Constants.UDPServerPort; Config.MaximumClients = 10; SDKJsonResult result = Create(); if (result.Failed()) { Console.WriteLine("Unable to create socket: {0}", result); return(result.Good()); } return(result.Good()); }