⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 universel.cs

📁 EBot source for the popular MMORPG World of Warcraft
💻 CS
📖 第 1 页 / 共 4 页
字号:
                MyProject.Forms.TimerForm.Wait500ms.Enabled = true;
                Clavier.SendTextToWoWChat("/cast " + MyProject.Forms.UniverselSettings.PetSpell4.Text);
                func.oldWait(0x7d0);
                Clavier.SendTextToWoWChat("/use" + MyProject.Forms.UniverselSettings.PetNourriture.Text);
                MyProject.Forms.CoolDown.PetNourriture.Enabled = true;
            }
            return 0;
        }

        public static object Combat()
        {
            MyProject.Forms.Config.BlackListGUID.AppendText("Killed target = " + GameObjects.MyTargetGUID.ToString() + "\r\n");
            string targetName = Main.TargetName;
            string text = MyProject.Forms.Main.PlayerLevel.Text;
            string str3 = MyProject.Forms.Main.PlayerExp.Text;
            int num4 = 0;
            int num3 = 0;
            int num2 = 0;
            int num6 = 1;
            int num8 = 0;
            int num7 = 0;
            int num5 = 0;
            int num = 0;
            if (MyProject.Forms.Config.Notifications.Checked)
            {
                MyProject.Forms.Main.NotifyIcon1.ShowBalloonTip(0x3e8, "eBot - Notification", "Attack : " + targetName, ToolTipIcon.Info);
            }
            CheckPet();
            if (MyProject.Forms.UniverselSettings.SendPet.Checked)
            {
                Clavier.SendPet();
                if (MyProject.Forms.UniverselSettings.PetActive4.Checked)
                {
                    func.logmsg("[COMBAT] Attente d'aggro du pet : " + MyProject.Forms.UniverselSettings.PetWaitAggro.Text + "s");
                    func.oldWait(Conversions.ToDouble(MyProject.Forms.UniverselSettings.PetWaitAggro.Text) * 1000.0);
                }
            }
            PreCombat();
            Clavier.AvancerUp();
            while (MyProject.Forms.Main.TargetHealthBar.Value == 0)
            {
                func.oldWait(1);
                if (Main.havetarget == 0)
                {
                    return 0;
                }
            }
            int targethealthamount = Main.targethealthamount;
            Bot.botcheckpull = 0;
            Bot.avancer = 0;
            MyProject.Forms.Main.CheckHealth.Enabled = true;
            MyProject.Forms.TimerForm.CheckWalkwaypointBlock.Enabled = true;
            Clavier.Send_Startattack();
            while (Main.havetarget == 1)
            {
                func.oldWait(1);
                if (((MyProject.Forms.Main.PlayerHealthBar.Value == 0) & (Conversions.ToDouble(MyProject.Forms.Main.Label15.Text) != 0.0)) & (Conversions.ToDouble(MyProject.Forms.Main.Label16.Text) != 0.0))
                {
                    Dead.boucle();
                    return 0;
                }
                Bot.face(Conversions.ToSingle(Bot.calculface(Main.targetx, Main.targety)));
                if (num5 == 0)
                {
                    if (Operators.ConditionalCompareObjectGreater(Main.targetdistance, CalculMinDistance(), false))
                    {
                        func.logmsg("[COMBAT] Cible trop loin, rapprochons nous ...");
                        func.resetkey();
                        func.oldWait(100);
                        while (Operators.ConditionalCompareObjectGreater(Main.targetdistance, CalculMinDistance(), false))
                        {
                            func.oldWait(1);
                            Bot.face(Conversions.ToSingle(Bot.calculface(Main.targetx, Main.targety)));
                            Clavier.AvancerDown();
                        }
                        Clavier.AvancerUp();
                        func.oldWait(100);
                    }
                    num5 = 1;
                }
                MyProject.Forms.TimerForm.CheckWalkwaypointBlock.Enabled = false;
                if (num4 == 0)
                {
                    MyProject.Forms.TimerForm.TimerCheckPull.Enabled = true;
                    func.logmsg("[COMBAT] Pull de la cible ...");
                    func.oldWait("10");
                    if (num3 == 0)
                    {
                        Pull();
                        num3 = 1;
                    }
                }
                if ((num2 == 0) && (Main.targethealthamount < targethealthamount))
                {
                    func.logmsg("[COMBAT] Pull r\x00e9ussi !");
                    MyProject.Forms.TimerForm.TimerCheckPull.Enabled = false;
                    func.oldWait("10");
                    num2 = 1;
                    num4 = 1;
                    Bot.botcheckpull = 0;
                }
                if (!MyProject.Forms.Main.CheckHealth.Enabled && ((Main.targethealthamount >= targethealthamount) & (num2 == 0)))
                {
                    func.oldWait(10);
                    func.logmsg("[COMBAT] Pull rat\x00e9, changeons de cible ...");
                    func.oldWait(100);
                    num6 = 0;
                    if (Main.havetarget == 1)
                    {
                        Clavier.Send_Cleartarget();
                    }
                }
                if (num2 == 1)
                {
                    if (num8 == 0)
                    {
                        Clavier.Send_Startattack();
                        num8 = 1;
                    }
                    if (num7 == 0)
                    {
                        func.logmsg("[COMBAT] D\x00e9but de la s\x00e9quence de spam ...");
                        num7 = 1;
                    }
                    if (((((MyProject.Forms.Config.Classes.Text != "Mage") & (MyProject.Forms.Config.Classes.Text != "Priest")) & (MyProject.Forms.Config.Classes.Text != "Warlock")) & (MyProject.Forms.Config.Classes.Text != "Druid")) & (MyProject.Forms.Config.Classes.Text != "Hunter"))
                    {
                        while (Operators.ConditionalCompareObjectGreater(Main.targetdistance, CalculMinDistanceCombat(), false))
                        {
                            func.oldWait(1);
                            Bot.face(Conversions.ToSingle(Bot.calculface(Main.targetx, Main.targety)));
                            Clavier.AvancerDown();
                        }
                    }
                    CombatLoop();
                }
                if (((MyProject.Forms.Main.PlayerHealthBar.Value == 0) & (Conversions.ToDouble(MyProject.Forms.Main.Label15.Text) != 0.0)) & (Conversions.ToDouble(MyProject.Forms.Main.Label16.Text) != 0.0))
                {
                    Dead.boucle();
                    return 0;
                }
            }
            if ((MyProject.Forms.Config.Classes.Text == "Druid") | (MyProject.Forms.Config.Classes.Text == "Rogue"))
            {
                Clavier.SendTextToWoWChat("/cancelform");
            }
            func.logmsg("[COMBAT] Combat termin\x00e9 !");
            MyProject.Forms.Main.mobskilled.Text = Conversions.ToString((double) (Conversions.ToDouble(MyProject.Forms.Main.mobskilled.Text) + 1.0));
            if (MyProject.Forms.Config.Notifications.Checked)
            {
                MyProject.Forms.Main.NotifyIcon1.ShowBalloonTip(0x3e8, "eBot - Notification", "Target killed : " + targetName, ToolTipIcon.Info);
            }
            if (MyProject.Forms.Config.BeepOnKill.Checked)
            {
                func.PlayWav(Application.StartupPath + @"\Sounds\Kill.wav");
            }
            while (num == 0)
            {
                MyProject.Forms.Main.CheckHealth.Enabled = false;
                func.oldWait(0x3e8);
                if (Main.havetarget == 0)
                {
                    if (MyProject.Forms.Config.Loot.Checked && (num6 >= 1))
                    {
                        Bot.walkforloot(Main.targetx, Main.targety);
                        MyProject.Forms.TimerForm.Loot.Enabled = true;
                        func.logmsg("[BOT] Loot");
                        Bot.loot();
                    }
                }
                else
                {
                    func.logmsg("[BOT] Aggro d\x00e9tect\x00e9 !");
                    Bot.combat();
                }
                Buff();
                if ((decimal.Compare(new decimal(MyProject.Forms.Main.PlayerHealthBar.Value), MyProject.Forms.Config.MinHealth.Value) < 0) | (decimal.Compare(new decimal(MyProject.Forms.Main.PlayerManaBar.Value), MyProject.Forms.Config.MinMana.Value) < 0))
                {
                    int num14;
                    func.oldWait(0x7d0);
                    int num16 = 0;
                    int num11 = 0;
                    int num12 = 0;
                    int num10 = 0;
                    func.logmsg("[COMBAT] Besoin de vie / mana ...");
                    int num13 = MyProject.Forms.Main.PlayerHealthBar.Value;
                    int pethealthamount = Main.pethealthamount;
                    if (MyProject.Forms.Config.Classes.Text == "Rogue")
                    {
                        num14 = 0;
                    }
                    else if (MyProject.Forms.Config.Classes.Text == "Warrior")
                    {
                        num14 = 0;
                    }
                    else if (MyProject.Forms.Config.Classes.Text == "DeathKnight")
                    {
                        num14 = 0;
                    }
                    else if (MyProject.Forms.Config.Classes.Text == "Druid")
                    {
                        num14 = 0;
                    }
                    else
                    {
                        num14 = 70;
                    }
                    while ((MyProject.Forms.Main.PlayerHealthBar.Value < 90) | (MyProject.Forms.Main.PlayerManaBar.Value < num14))
                    {
                        if (num10 == 0)
                        {
                            Heal();
                            num10 = 1;
                        }

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -