Beispiel #1
0
        public void IPC_TearDown()
        {
            IPCManager.Instance.Destroy();

            Driver.Dispose();
            RemoteDriver.Dispose();
            Stream.Dispose();
        }
Beispiel #2
0
 void IDisposable.Dispose()
 {
     Flush();
     if (_stream != null && !_leaveOpen)
     {
         _stream.Dispose();
     }
 }
Beispiel #3
0
 public virtual void Dispose()
 {
     SendStream.Dispose();
     m_sendStreamEvent.Dispose();
     ReceiveStream.Dispose();
     m_networkIDToObject.Clear();
     m_objectToNetworkID.Clear();
     m_proxyToTarget.Clear();
 }
Beispiel #4
0
        public virtual void Dispose()
        {
            MyTrace.Send(TraceWindow.Multiplayer, "Multiplayer closed");
            m_voxelMapData = null;
            MyNetworkReader.ClearHandler(MyMultiplayer.ControlChannel);
            SyncLayer.TransportLayer.Clear();
            MyNetworkReader.Clear();

            m_sendPhysicsStream.Dispose();
            ReplicationLayer.Dispose();

            MyMultiplayer.Static = null;
        }
Beispiel #5
0
        protected virtual void Dispose(bool disposing)
        {
            // If you need thread safety, use a lock around these
            // operations, as well as in your methods that use the resource.
            if (!_disposed)
            {
                if (disposing)
                {
                    if (client != null)
                    {
                        client.CloseConnection(client.GetSystemAddressFromIndex(0), true, 0);
                        client.Dispose();
                    }
                    if (socketDescriptor != null)
                    {
                        socketDescriptor.Dispose();
                    }
                    if (receiveBitStream != null)
                    {
                        receiveBitStream.Dispose();
                    }
                    if (sentBitStream != null)
                    {
                        sentBitStream.Dispose();
                    }
                }

                client           = null;
                socketDescriptor = null;
                receiveBitStream = null;
                sentBitStream    = null;


                _disposed = true;
            }
        }
 public void Dispose()
 {
     m_LocalDriver.Dispose();
     m_LocalBitStream.Dispose();
 }
 public void Dispose()
 {
     bitStream.Reset();
     bitStream.Dispose();
 }