Esempio n. 1
0
        private async void Connection()
        {
            if (PS3.ConnectTarget())
            {
                if (PS3.AttachProcess())
                {
                    if (PS3.GetCurrentGame() == "Modern Warfare® 3")
                    {
                        await Dialog.ShowMessageAsync(this, Resources["success"].ToString(), $"{Resources["successAttached"]} \"{PS3.CurrentGame}\".");

                        IsAttached = true;
                        return;
                    }
                    else
                    {
                        await Dialog.ShowMessageAsync(this, Resources["wrongProcess"].ToString(), $"{Resources["currentProcess"]} \"{PS3.CurrentGame}\".");
                    }
                }
                else
                {
                    await Dialog.ShowMessageAsync(this, Resources["attachFailed"].ToString(), Resources["unableAttach"].ToString());
                }
            }
            else
            {
                await Dialog.ShowMessageAsync(this, Resources["connectFailed"].ToString(), Resources["unableConnect"].ToString());
            }
            IsAttached = false;
        }
Esempio n. 2
0
        /// <summary>
        /// Connect to PS3 console
        /// </summary>
        private void ConnectPS3()
        {
            try
            {
                if (PS3.ConnectTarget())
                {
                    if (PS3.AttachProcess())
                    {
                        IsConsoleConnected = true;
                        SetStatusConsole(PS3.GetConsoleName());
                        ConsoleType = "PS3";
                        EnableConsoleActions();

                        MenuItemConnectPS3CCAPI.Visible      = false;
                        MenuItemConnectPS3TMAPI.Visible      = false;
                        MenuItemConnectPS3Disconnect.Visible = true;

                        MenuItemConnectXBOX.Enabled = false;

                        if (!IsInGame())
                        {
                            NotifyMessagePS3("^2Hooked to AtomicX", "Successfully connected and attached!", "party_ready");
                        }

                        XtraMessageBox.Show(this, "Connected and attached to Black Ops II", "Success", MessageBoxButtons.OK, MessageBoxIcon.Information);
                    }
                    else
                    {
                        XtraMessageBox.Show(this, "Unable to attach to game process.", "Error", MessageBoxButtons.OK, MessageBoxIcon.Error);
                    }
                }
                else
                {
                    XtraMessageBox.Show(this, "Unable to connect to console.", "Error", MessageBoxButtons.OK, MessageBoxIcon.Error);
                }
            }
            catch (Exception ex)
            {
                XtraMessageBox.Show(this, "Unable to connect to console.\n\nError Message:\n" + ex.Message, "Error", MessageBoxButtons.OK, MessageBoxIcon.Error);
            }
        }
Esempio n. 3
0
        private async void Connect()
        {
            if (PS3.ConnectTarget())
            {
                if (PS3.AttachProcess())
                {
                    if (PS3.GetCurrentGame() == "Modern Warfare® 3")
                    {
                        await Dialog.ShowMessageAsync(this, "Success..", $"Succesfully attached to \"{PS3.CurrentGame}\".", MessageDialogStyle.Affirmative);

                        //IgrisMessageBox.Show($"Succesfully attached to \"{PS3.CurrentGame}\".", "Success..", MessageBoxButton.OK, MessageBoxImage.Information);
                        Status           = $"Attached to {PS3.CurrentGame}!";
                        IsAttached       = true;
                        StatsTypeEnabled = true;
                        return;
                    }
                    else
                    {
                        await Dialog.ShowMessageAsync(this, "Wrong process...", $"The process is \"{PS3.CurrentGame}\".", MessageDialogStyle.Affirmative);

                        Status = $"{PS3.CurrentGame} is a wrong process, immediate detachment!";
                        PS3.DetachProcess();
                    }
                }
                else
                {
                    await Dialog.ShowMessageAsync(this, "Attach failed..", "Unable to attach process.", MessageDialogStyle.Affirmative);

                    Status = "Attached to any process!";
                }
            }
            else
            {
                await Dialog.ShowMessageAsync(this, "Connect failed..", "Unable to connect to PS3.", MessageDialogStyle.Affirmative);

                Status = "Connected to any ps3!";
            }
            IsAttached = false;
        }