Example #1
0
        private void Dispose(bool Disposing)
        {
            if (!this.mDisposed && Disposing)
            {
                this.mDisposed = true;
                try
                {
                    base.Shutdown(SocketShutdown.Both);
                    base.Close();
                    base.Dispose();
                }
                catch { }

                Array.Clear(this.mDataBuffer, 0, this.mDataBuffer.Length);
                this.mDataBuffer                = null;
                this.mDataReceivedCallback      = null;
                this.mRouteReceivedDataCallback = null;
                PhoenixEnvironment.GetConnectionManager().DropConnection(this.mID);
                TcpAuthorization.FreeConnection(this.mIP);
                if (PhoenixEnvironment.GetConfig().data["emu.messages.connections"] == "1")
                {
                    Console.WriteLine(string.Concat(new object[] { ">> Connection Dropped [", this.mID, "] from [", this.ipAddress, "]" }));
                }
            }
        }
Example #2
0
        /// <summary>
        /// Starts the connection, prepares the received data buffer and waits for data.
        /// </summary>
        public void Start(RouteReceivedDataCallback dataRouter)
        {
            mDataBuffer                = new byte[RECEIVEDATA_BUFFER_SIZE];
            mDataReceivedCallback      = new AsyncCallback(DataReceived);
            mRouteReceivedDataCallback = dataRouter;

            WaitForData();
        }
Example #3
0
 internal void Start(RouteReceivedDataCallback dataRouter)
 {
     this.mDataBuffer                = new byte[0x400];
     this.mDataReceivedCallback      = new AsyncCallback(this.DataReceived);
     this.mDataSentCallback          = new AsyncCallback(this.DataSent);
     this.mRouteReceivedDataCallback = dataRouter;
     this.WaitForData();
 }
Example #4
0
        /// <summary>
        ///   Starts the Connection, prepares the received data buffer and waits for data.
        /// </summary>
        internal void Start()
        {
            _dataBuffer = new byte[ReceivedataBufferSize];
            _dataReceivedCallback = new AsyncCallback(DataReceived);
            _routeReceivedDataCallback = new RouteReceivedDataCallback(HandleConnectionData);


            Habbo = new Habbo(this);
            WaitForData();
        }
Example #5
0
        /// <summary>
        /// Starts the connection, prepares the received data buffer and waits for data.
        /// </summary>
        public void Start()
        {
            mDataBuffer                = new byte[RECEIVEDATA_BUFFER_SIZE];
            mDataReceivedCallback      = new AsyncCallback(DataReceived);
            mRouteReceivedDataCallback = new IonTcpConnection.RouteReceivedDataCallback(HandleConnectionData);


            this.mUser = new User(this);
            this.mUser.StartLoggedInValues(this);
            WaitForData();
        }
Example #6
0
        /// <summary>
        ///   Starts the Connection, prepares the received data buffer and waits for data.
        /// </summary>
        internal void Start()
        {
            _dataBuffer = new byte[ReceivedataBufferSize];
            _dataReceivedCallback = new AsyncCallback(DataReceived);
            _routeReceivedDataCallback = new RouteReceivedDataCallback(HandleConnectionData);

            Habbo = new Habbo(this);
            WaitForData();
        }
Example #7
0
        /// <summary>
        /// Starts the connection, prepares the received data buffer and waits for data.
        /// </summary>
        public void Start()
        {
            mDataBuffer = new byte[RECEIVEDATA_BUFFER_SIZE];
            mDataReceivedCallback = new AsyncCallback(DataReceived);
            mRouteReceivedDataCallback = new IonTcpConnection.RouteReceivedDataCallback(HandleConnectionData);

            this.mUser = new User(this);
            this.mUser.StartLoggedInValues(this);
            WaitForData();
        }
        public void Start(RouteReceivedDataCallback DataRouter)
        {
            this.Buffer = new byte[RCV_BUFFER_SIZE];
            this.DataReceivedCallback = new AsyncCallback(DataReceived);
            this.RouteDataCallback = DataRouter;

            WaitForData();
        }
Example #9
0
        /// <summary>
        /// Starts the connection, prepares the received data buffer and waits for data.
        /// </summary>
        public void Start(RouteReceivedDataCallback dataRouter)
        {
            mDataBuffer = new byte[RECEIVEDATA_BUFFER_SIZE];
            mDataReceivedCallback = new AsyncCallback(DataReceived);
            mRouteReceivedDataCallback = dataRouter;

            WaitForData();
        }
Example #10
0
        private void Dispose(bool Disposing)
        {
            if (!this.mDisposed && Disposing)
            {
                this.mDisposed = true;
                try
                {
                    base.Shutdown(SocketShutdown.Both);
                    base.Close();
                    base.Dispose();
                }
                catch { }

                Array.Clear(this.mDataBuffer, 0, this.mDataBuffer.Length);
                this.mDataBuffer = null;
                this.mDataReceivedCallback = null;
                this.mRouteReceivedDataCallback = null;
                PhoenixEnvironment.GetConnectionManager().DropConnection(this.mID);
                TcpAuthorization.FreeConnection(this.mIP);
                if (PhoenixEnvironment.GetConfig().data["emu.messages.connections"] == "1")
                {
                    Console.WriteLine(string.Concat(new object[] { ">> Connection Dropped [", this.mID, "] from [", this.ipAddress, "]" }));
                }
            }
        }
Example #11
0
 internal void Start(RouteReceivedDataCallback dataRouter)
 {
     this.mDataBuffer = new byte[0x400];
     this.mDataReceivedCallback = new AsyncCallback(this.DataReceived);
     this.mDataSentCallback = new AsyncCallback(this.DataSent);
     this.mRouteReceivedDataCallback = dataRouter;
     this.WaitForData();
 }