示例#1
0
        public bool Disconnect()
        {
            if (!XboxUtils.IsConnected())
            {
                return(true);
            }

            try
            {
                string consoleName = XboxUtils.GetConsoleName();
                XboxUtils.Disconnect();
                XboxUtils.ConfirmMessage("Successfully disconnected from console: " + consoleName);
                return(true);
            }
            catch (Exception exception)
            {
                XboxUtils.ErrorMessage(exception.Message);
                return(false);
            }
        }