Exemplo n.º 1
0
        private void OnNetDisconnect(object?sender, NetDisconnectedArgs args)
        {
            DebugTools.Assert(RunLevel > ClientRunLevel.Initialize);

            PlayerLeaveServer?.Invoke(this, new PlayerEventArgs(_playMan.LocalPlayer?.Session));

            LastDisconnectReason = args.Reason;
            GameStoppedReset();
        }
Exemplo n.º 2
0
        private void OnNetDisconnect(object sender, NetChannelArgs args)
        {
            Debug.Assert(RunLevel > ClientRunLevel.Initialize);

            PlayerLeaveServer?.Invoke(this, new PlayerEventArgs(_playMan.LocalPlayer.Session));

            _stateManager.RequestStateChange <MainScreen>();

            _playMan.Shutdown();
            Reset();
        }
Exemplo n.º 3
0
        private void OnNetDisconnect(object?sender, NetDisconnectedArgs args)
        {
            DebugTools.Assert(RunLevel > ClientRunLevel.Initialize);

            PlayerLeaveServer?.Invoke(this, new PlayerEventArgs(_playMan.LocalPlayer?.Session));

            LastDisconnectReason = args.Reason;

            _gameStates.Reset();
            _playMan.Shutdown();
            _entityManager.Shutdown();
            _mapManager.Shutdown();
            _discord.ClearPresence();
            Reset();
        }