예제 #1
0
    public void OnDisconnected(string strReason, Network.Connection connection)
    {
        this.connectionQueue.RemoveConnection(connection);
        ConnectionAuth.OnDisconnect(connection);
        SteamServer.EndSession(connection.userid);
        EACServer.OnLeaveGame(connection);
        BasePlayer basePlayer = connection.player as BasePlayer;

        if (basePlayer)
        {
            Interface.CallHook("OnPlayerDisconnected", basePlayer, strReason);
            basePlayer.OnDisconnected();
        }
    }
예제 #2
0
    public void OnDisconnected(string strReason, Network.Connection connection)
    {
        this.connectionQueue.RemoveConnection(connection);
        ConnectionAuth.OnDisconnect(connection);
        Global.get_SteamServer().get_Auth().EndSession((ulong)connection.userid);
        EACServer.OnLeaveGame(connection);
        BasePlayer player = connection.player as BasePlayer;

        if (!Object.op_Implicit((Object)player))
        {
            return;
        }
        Interface.CallHook("OnPlayerDisconnected", (object)player, (object)strReason);
        player.OnDisconnected();
    }
예제 #3
0
        public void OUT_OnDisconnected(string reason, Connection conn)
        {
            if (BaseClient?.IsConnected() == true)
            {
                ConsoleSystem.LogWarning("[VirtualServer]: Соеденение с игровым клиентом разорвано: " + reason);
                BaseClient?.Disconnect(reason, false);
                if (BaseClient != null & BaseClient.Connection != null)
                {
                    BaseClient.Connection.decryptIncoming = false;
                    BaseClient.Connection.encryptOutgoing = false;
                }
                NetworkManager.Instance.OnDisconnected();

                ConnectionInformation = null;
                LastEntityNUM         = 0;
            }
            EACServer.OnLeaveGame(conn);
        }