Ejemplo n.º 1
0
        private void LogoutPlayer()
        {
            var character = Character;

            using (var scope = Db.CreateTransaction())
            {
                _player.Save();
                character.ZoneId       = _zone.Id;
                character.ZonePosition = _player.CurrentPosition;

                _player.RemoveFromZone();
                _player.SetSession(None);

                _sessionManager.DeselectCharacter(character);
                scope.Complete();
            }

            Disconnect();
            OnStopped();
        }