Ejemplo n.º 1
0
        public SOEClient(SOEConnectionManager manager, IPEndPoint client)
        {
            // Manager and server
            Server = manager.Server;
            Manager = manager;
            Client = client;
            DataChannel = new SOEDataChannel(this);

            // Session
            SessionStarted = false;
            Encryptable = false;
            Compressable = true;

            Encrypted = false;

            // This client is new
            Interact();
        }
Ejemplo n.º 2
0
        public SOEClient(SOEConnectionManager manager, IPEndPoint client)
        {
            // Manager and server
            Server      = manager.Server;
            Manager     = manager;
            Client      = client;
            DataChannel = new SOEDataChannel(this);

            // Session
            SessionStarted = false;
            Encryptable    = false;
            Compressable   = true;

            Encrypted = false;

            // This client is new
            Interact();
        }
Ejemplo n.º 3
0
        public SOEServer(int port, string protocol = "SOE")
        {
            // Log
            Log("Initiating server on port: {0}", port);

            // UDP Listener
            UdpClient = new UdpClient(port);
            Port      = port;

            // Server components
            ConnectionManager = new SOEConnectionManager(this);
            Protocol          = new SOEProtocol(this, protocol);

            IncomingPackets  = new ConcurrentQueue <SOEPendingPacket>();
            IncomingMessages = new ConcurrentQueue <SOEPendingMessage>();

            // Initialize our message handlers
            Log("Initializing message handlers");
            MessageHandlers.Initialize();
            Log("Initiated server");
        }
Ejemplo n.º 4
0
        public SOEServer(int port, string protocol="SOE")
        {
            // Log
            Log("Initiating server on port: {0}", port);

            // UDP Listener
            UdpClient = new UdpClient(port);
            Port = port;

            // Server components
            ConnectionManager = new SOEConnectionManager(this);
            Protocol = new SOEProtocol(this, protocol);

            IncomingPackets = new ConcurrentQueue<SOEPendingPacket>();
            IncomingMessages = new ConcurrentQueue<SOEPendingMessage>();

            // Initialize our message handlers
            Log("Initializing message handlers");
            MessageHandlers.Initialize();
            Log("Initiated server");
        }