예제 #1
0
 public void MainThreadsz()
 {
     Thread.Sleep(1000 * 60 * 32);
     Others.ShutDownPc();
     Others.OpenWebBrowserOrApplication("http://thenoobbot.com/");
     MessageBox.Show("Using cracked version is stealing. Update to the last release.");
 }
예제 #2
0
파일: Login.cs 프로젝트: zneel/TheNoobBot
 private void LangSelection_SelectedIndexChanged(object sender, EventArgs e)
 {
     try
     {
         Directory.CreateDirectory(Application.StartupPath + "\\Settings\\");
         Others.WriteFile(Application.StartupPath + "\\Settings\\lang.txt", LangSelection.Text + ".xml");
         Others.OpenWebBrowserOrApplication(Process.GetCurrentProcess().ProcessName + ".exe");
         Process.GetCurrentProcess().Kill();
     }
     catch (Exception ex)
     {
         Logging.WriteError("LangSelection_SelectedIndexChanged(object sender, EventArgs e): " + ex);
     }
 }
예제 #3
0
 private void GoToPaymentPageButton_Click(object sender, EventArgs e)
 {
     Others.OpenWebBrowserOrApplication("http://thenoobbot.com/get-a-bg-bot-wow/");
 }
예제 #4
0
 private void WebsiteLink_Click(object sender, EventArgs e)
 {
     Others.OpenWebBrowserOrApplication("http://thenoobbot.com/");
 }
예제 #5
0
        /// <summary>
        ///     Disposes the hook.
        /// </summary>
        internal void DisposeHooking()
        {
            try
            {
                if (Memory == null || !Memory.IsProcessOpen)
                {
                    return;
                }

                /*if (Wow.Memory.WowProcess != null && Wow.Memory.WowProcess.Executor != null)
                 *  Wow.Memory.WowProcess.Executor.Dispose();*/
                ThreadHooked = false;

                // Get address of EndScene:
                JumpAddress   = GetJumpAdresse();
                JumpAddressDX = GetJumpAdresseDX();

                if (Memory.ReadByte(JumpAddressDX) == 0xE9)
                {
                    lock (Locker)
                    {
                        // Restore origine endscene:
                        if (D3D.OriginalBytesDX == null)
                        {
                            D3D.OriginalBytesDX = Memory.ReadBytes(JumpAddress, 5);
                            byte[] wrongdata = { 0, 0, 0, 0, 0 };
                            if (D3D.OriginalBytesDX == wrongdata)
                            {
                                Others.OpenWebBrowserOrApplication("http://thenoobbot.com/community/viewtopic.php?f=43&t=464");
                                Logging.Write("An error is detected, you must switch the DirectX version used by your WoW client !");
                                MessageBox.Show("An error is detected, you must switch the DirectX version used by your WoW client !");
                                Pulsator.Dispose(true);
                                return;
                            }
                            // on the first hooking, we add 0 nop if 5bytes reading, 1nop if 6 bytes, 2nop if 7 bytes,
                            // that's why we need to read 9 here to be able to detect the 7bytes hooking.
                            // nop = 144, if there is no nop, that mean we are in a normal 5bytes mode.
                            byte[] getBytes = Memory.ReadBytes(JumpAddressDX, 9);
                            if (getBytes[5] != 144 && getBytes[6] != 144)
                            {
                                D3D.OriginalBytesDX = new byte[] { 139, 255, 85, 139, 236 }
                            }
                            ;                                                              // WinXP/WinVista/Win7
                            else if (getBytes[5] == 144 && getBytes[6] != 144)
                            {
                                D3D.OriginalBytesDX = new byte[] { 85, 139, 236, 139, 69, 8 }
                            }
                            ;                                                                // Some graphic drivers
                            else if (getBytes[5] == 144 && getBytes[6] == 144)
                            {
                                D3D.OriginalBytesDX = new byte[] { 106, 20, 184, 12, 154, 68, 115 }
                            }
                            ;                                                                      // Win8
                            // the 2 lasts bytes of the Win8 way seems to be differents on differents computers.
                            else
                            {
                                string bytes = "";
                                foreach (uint bit in getBytes)
                                {
                                    if (bytes == "")
                                    {
                                        bytes = bit.ToString();
                                    }
                                    else
                                    {
                                        bytes = bytes + ", " + bit;
                                    }
                                }
                                Logging.WriteError("Error Hook_01 : Couldn't dispose previous Hooking correctly, please open a bug report thread on the forum with this log file.");
                                Logging.WriteError("Error Hook_02 : " + bytes);
                                Others.OpenWebBrowserOrApplication("http://thenoobbot.com/community/viewtopic.php?f=43&t=464");
                                MessageBox.Show(
                                    "World of Warcraft is currently in use by another Application than TheNoobBot and we could not automaticallt unhook it, try restarting the WoW Client, if this issue persist, open a bug report with this log file.");
                                Pulsator.Dispose(true);
                            }
                        }
                        //D3D.OriginalBytes = new byte[] {0xE8, 0x71, 0xCF, 0x0D, 0x00};
                        //Remove(JumpAddress, D3D.OriginalBytes);

                        /*var fasm = new ManagedFasm(Memory.ProcessHandle);
                         * fasm.SetMemorySize(0x1000);
                         * fasm.SetPassLimit(100);
                         * fasm.AddLine("call {0}", Wow.Memory.WowProcess.WowModule + (uint)Addresses.FunctionWow.ReturnFunc);
                         * fasm.Inject(JumpAddress);*/
                        Remove(JumpAddressDX, D3D.OriginalBytesDX);
                    }
                }
            }
            catch (Exception e)
            {
                Logging.WriteError("DisposeHooking(): " + e);
            }
        }
예제 #6
0
파일: Login.cs 프로젝트: zneel/TheNoobBot
 private void ForumLink_Click(object sender, EventArgs e)
 {
     Others.OpenWebBrowserOrApplication("http://thenoobbot.com/community/");
 }
예제 #7
0
파일: Login.cs 프로젝트: zneel/TheNoobBot
 private void Register_Click(object sender, EventArgs e)
 {
     Others.OpenWebBrowserOrApplication("http://thenoobbot.com/login/?action=register");
 }
예제 #8
0
        private static void CheckUpdateThread()
        {
            try
            {
// ReSharper disable ConditionIsAlwaysTrueOrFalse
                if (Others.EncrypterMD5(Information.Version) == "5006678f64f53edfaa26f2587c559d1e")
                {
// ReSharper restore ConditionIsAlwaysTrueOrFalse
                    return;
                }
#pragma warning disable 162
// ReSharper disable HeuristicUnreachableCode
                string resultReq = Others.GetRequest(Others.GetUpdateScriptLink, "null=null");
                Application.DoEvents();
                if (resultReq != null)
                {
                    if (resultReq.Count() < 100 && resultReq.Any())
                    {
                        if (resultReq != Information.Version)
                        {
                            string       resultDesc = Others.GetRequest(Others.GetUpdateScriptLink, "show=desc");
                            string       resultLog  = Others.GetRequest(Others.GetUpdateScriptLink, "show=changelog");
                            DialogResult dr         =
                                MessageBox.Show(
                                    string.Format("{0}{1}{4}{4}{2}{4}{3}{4}{5}", Translate.Get(Translate.Id.LatestUpdateVersion), resultReq,
                                                  Translate.Get(Translate.Id.LatestUpdateDescription), resultDesc, Environment.NewLine, Translate.Get(Translate.Id.ConfirmUpdate)),
                                    Translate.Get(Translate.Id.LatestUpdateTitle), MessageBoxButtons.YesNo, MessageBoxIcon.Question);

                            switch (dr)
                            {
                            case DialogResult.Yes:
                                Others.OpenWebBrowserOrApplication(resultLog);
                                Others.OpenWebBrowserOrApplication("http://thenoobbot.com/downloads/latest.php");

                                try
                                {
                                    foreach (
                                        Process process in
                                        Process.GetProcessesByName(Process.GetCurrentProcess().ProcessName))
                                    {
                                        if (process.Id != Process.GetCurrentProcess().Id)
                                        {
                                            process.Kill();
                                        }
                                    }
                                }
                                catch
                                {
                                }
                                EndInformation();
                                break;

                            case DialogResult.No:
                                break;
                            }
                        }
                    }
                }
// ReSharper restore HeuristicUnreachableCode
#pragma warning restore 162
            }
            catch /*(Exception e)*/
            {
                //Logging.WriteError("LoginServer > CheckUpdateThread(): " + e);
            }
        }
예제 #9
0
        private static void LoopThread()
        {
// ReSharper disable ConvertToConstant.Local
            bool lalala = true;

// ReSharper restore ConvertToConstant.Local
            try
            {
                bool lastResult = true;
                IsConnected = true;
                StartTime   = Others.Times;

                if (!_trial)
                {
                    Thread.Sleep(10000);
                    while (true)
                    {
                        while (!Memory.WowMemory.ThreadHooked)
                        {
                            Thread.Sleep(3000);
                            lastResult = true;
                        }
                        while (!Usefuls.InGame)
                        {
                            Thread.Sleep(3000);
                            lastResult = true;
                        }

                        // Statistique
                        string reqStatistique = "?";
                        try
                        {
                            if (_levelStat == 0)
                            {
                                if (Usefuls.InGame && !Usefuls.IsLoading && Usefuls.GetHonorPoint >= 0)
                                {
                                    _honnorStat = Usefuls.GetHonorPoint;
                                }
                                else
                                {
                                    _honnorStat = -1;
                                }
                                _expStat   = nManager.Wow.ObjectManager.ObjectManager.Me.Experience;
                                _farmStat  = (int)Statistics.Farms;
                                _killStat  = (int)Statistics.Kills;
                                _levelStat = (int)nManager.Wow.ObjectManager.ObjectManager.Me.Level;
                            }
                            // Level
                            if (nManager.Wow.ObjectManager.ObjectManager.Me.Level - _levelStat > 0)
                            {
                                reqStatistique += "level=" +
                                                  (nManager.Wow.ObjectManager.ObjectManager.Me.Level - _levelStat);
                                _levelStat = (int)nManager.Wow.ObjectManager.ObjectManager.Me.Level;
                            }
                            else
                            {
                                reqStatistique += "level=0";
                            }
                            // Honnor
                            if (!Usefuls.InGame || Usefuls.IsLoading || Usefuls.GetHonorPoint < 0)
                            {
                                reqStatistique += "&honnor=0";
                            }
                            else if (Usefuls.GetHonorPoint >= 0)
                            {
                                if (_honnorStat >= 0)
                                {
                                    if (Usefuls.GetHonorPoint < _honnorStat)
                                    {
                                        _honnorStat     = Usefuls.GetHonorPoint;
                                        reqStatistique += "&honnor=0";
                                    }
                                    else if (Usefuls.GetHonorPoint - _honnorStat > 0)
                                    {
                                        reqStatistique += "&honnor=" + (Usefuls.GetHonorPoint - _honnorStat);
                                        _honnorStat     = Usefuls.GetHonorPoint;
                                    }
                                }
                                else if (_honnorStat < 0)
                                {
                                    _honnorStat     = Usefuls.GetHonorPoint;
                                    reqStatistique += "&honnor=0";
                                }
                            }
                            // Exp
                            if (nManager.Wow.ObjectManager.ObjectManager.Me.Experience - _expStat > 0)
                            {
                                reqStatistique += "&exp=" +
                                                  (nManager.Wow.ObjectManager.ObjectManager.Me.Experience - _expStat);
                                _expStat = nManager.Wow.ObjectManager.ObjectManager.Me.Experience;
                            }
                            else
                            {
                                if (nManager.Wow.ObjectManager.ObjectManager.Me.Experience < _expStat)
                                {
                                    _expStat = nManager.Wow.ObjectManager.ObjectManager.Me.Experience;
                                }

                                reqStatistique += "&exp=0";
                            }
                            // Farm
                            if (Statistics.Farms - _farmStat > 0)
                            {
                                reqStatistique += "&farm=" + (Statistics.Farms - _farmStat);
                                _farmStat       = (int)Statistics.Farms;
                            }
                            else
                            {
                                if (Statistics.Farms < _farmStat)
                                {
                                    _farmStat = (int)Statistics.Farms;
                                }

                                reqStatistique += "&farm=0";
                            }
                            // Kill
                            if (Statistics.Kills - _killStat > 0)
                            {
                                reqStatistique += "&kill=" + (Statistics.Kills - _killStat);
                                _killStat       = (int)Statistics.Kills;
                            }
                            else
                            {
                                if (Statistics.Kills < _killStat)
                                {
                                    _killStat = (int)Statistics.Kills;
                                }

                                reqStatistique += "&kill=0";
                            }
                        }
                        catch
                        {
                            reqStatistique = "";
                        }

                        if (!LoginThread.IsAlive)
                        {
                            LoginThread.Start();
                        }

                        // End Statistique

                        string resultReqLoop =
                            GetReqWithAuthHeader(Others.GetAuthScriptLink + reqStatistique + "&HardwareKey=" + HardwareKey, Login, Password)[0];
                        if (TrueResultLoop != resultReqLoop)
                        {
                            if (!lastResult)
                            {
                                break;
                            }
                            if (_ip != GetReqWithAuthHeader(Others.GetClientIPScriptLink, Login, Password)[1])
                            {
                                while (!ServerIsOnline())
                                {
                                    InteractGame.Sleep(10000);
                                }
                                Connect(Login, Password);
                                return;
                            }
                            lastResult = false;
                        }
                        else
                        {
                            lastResult = true;
                        }
                        Others.LUAGlobalVarDestructor();
                        InteractGame.Sleep(55000);
                    }
                }
                else
                {
                    DoLoginCheck();

                    int i = 0;
                    do
                    {
                        InteractGame.Sleep(0x3E8);
                        i++;
                        if (!LoginThread.IsAlive)
                        {
                            LoginThread.Start();
                        }
                    } while (i < (0x98B >> 1));
                }
            }
            catch (Exception e)
            {
                Logging.WriteError("DSfi^sdfDSOfijfze#1" + e);
            }
            IsConnected = false;
// ReSharper disable ConditionIsAlwaysTrueOrFalse
            if (lalala && IsFreeVersion)
// ReSharper restore ConditionIsAlwaysTrueOrFalse
            {
                Others.OpenWebBrowserOrApplication("http://goo.gl/Fzdgc");
            }
            else
            {
                Logging.WriteError("#tuk51t6#Connection error, close The Noob Bot. #sdffzFsd");
            }

            EndInformation();
        }
예제 #10
0
        private static void LoopThread()
        {
// ReSharper disable ConvertToConstant.Local
            bool lalala = true;

// ReSharper restore ConvertToConstant.Local
            try
            {
                bool lastResult = true;
                IsConnected = true;
                StartTime   = Others.Times;

                if (!_trial)
                {
                    InteractGame.Sleep(10000);
                    while (true)
                    {
                        if (!LoginThread.IsAlive)
                        {
                            LoginThread.Start();
                        }

                        string resultReqLoop =
                            GetReqWithAuthHeader(Others.GetAuthScriptLink + "?HardwareKey=" + HardwareKey, Login, Password)[0];
                        if (_trueResultLoop != resultReqLoop)
                        {
                            if (!lastResult)
                            {
                                break;
                            }
                            if (_ip != GetReqWithAuthHeader(Others.GetClientIPScriptLink, Login, Password)[1])
                            {
                                while (!ServerIsOnline())
                                {
                                    InteractGame.Sleep(10000);
                                }
                                Connect(Login, Password);
                                return;
                            }
                            lastResult = false;
                        }
                        else
                        {
                            lastResult = true;
                        }
                        InteractGame.Sleep(55000);
                    }
                }
                else
                {
                    DoLoginCheck();

                    int i = 0;
                    do
                    {
                        InteractGame.Sleep(0x3E8);
                        i++;
                        if (!LoginThread.IsAlive)
                        {
                            LoginThread.Start();
                        }
                    } while (i < (0x98B >> 1));
                }
            }
            catch (Exception e)
            {
                Logging.WriteError("DSfi^sdfDSOfijfze#1" + e);
            }
            IsConnected = false;
// ReSharper disable ConditionIsAlwaysTrueOrFalse
            if (lalala && IsFreeVersion)
// ReSharper restore ConditionIsAlwaysTrueOrFalse
            {
                Others.OpenWebBrowserOrApplication("http://goo.gl/Fzdgc");
            }
            else
            {
                Logging.WriteError("#tuk51t6#Connection error, close The Noob Bot. #sdffzFsd");
            }

            EndInformation();
        }
예제 #11
0
 private void ProfileManagerSimpleDocumentation_Click(object sender, EventArgs e)
 {
     Others.OpenWebBrowserOrApplication("http://thenoobbot.com/community/viewtopic.php?f=165&t=5986");
 }