Beispiel #1
0
 public void StopClient()
 {
     OnStopClient();
     if (LogFilter.logDebug)
     {
         Debug.Log("NetworkManager StopClient");
     }
     isNetworkActive = false;
     if (client != null)
     {
         client.Disconnect();
         client.Shutdown();
         client = null;
     }
     StopMatchMaker();
     ClientScene.DestroyAllClientObjects();
     if (m_OfflineScene != string.Empty)
     {
         ClientChangeScene(m_OfflineScene, forceReload: false);
     }
 }
Beispiel #2
0
        public void StopClient()
        {
            OnStopClient();

            if (LogFilter.logDebug)
            {
                Debug.Log("NetworkManager StopClient");
            }
            isNetworkActive = false;
            if (client != null)
            {
                // only shutdown this client, not ALL clients.
                client.Disconnect();
                client.Shutdown();
                client = null;
            }
            StopMatchMaker();

            ClientScene.DestroyAllClientObjects();
            if (m_OfflineScene != "")
            {
                ClientChangeScene(m_OfflineScene, false);
            }
        }
        public void StopClient()
        {
            OnStopClient();

            if (LogFilter.logDebug)
            {
                Debug.Log("NetworkManager StopClient");
            }
            isNetworkActive = false;
            if (client != null)
            {
                // only shutdown this client, not ALL clients.
                client.Disconnect();
                client.Shutdown();
                client = null;
            }

            ClientScene.DestroyAllClientObjects();
            if (!string.IsNullOrEmpty(m_OfflineScene))
            {
                ClientChangeScene(m_OfflineScene, false);
            }
            CleanupNetworkIdentities();
        }