Exemplo n.º 1
0
        public override void Pulse()
        {
            if (stopwatch.ElapsedMilliseconds == 0)
            {
                stopwatch.Start();
                Log.WritePixelMagic("The Cooldown toggle button is now Active (Numpad0). The delay is set to 500ms ( 0.5 second )", Color.Black);
                return;
            }
            {
                if (DetectKeyPress.GetKeyState(DetectKeyPress.VK_NUMPAD0) < 0)
                {
                    if (stopwatch.ElapsedMilliseconds > 500)
                    {
                        combatRoutine.UseCooldowns = !combatRoutine.UseCooldowns;
                        stopwatch.Restart();
                    }
                }
                if (combatRoutine.Type == RotationType.SingleTarget)
                {
                    if (WoW.IsSpellInRange("Rupture") && WoW.IsInCombat)


                    {
                        if (UseCooldowns &&
                            WoW.CanCast("Kingsbane") && WoW.CurrentComboPoints <= 4 && WoW.Energy >= 35 && WoW.PlayerHasBuff("Envenom") && WoW.PlayerBuffTimeRemaining("Envenom") >= 1.5 &&
                            !WoW.IsSpellOnCooldown("Kingsbane") && WoW.TargetHasDebuff("Rupture") && WoW.TargetDebuffTimeRemaining("Rupture") >= 14 &&
                            (
                                WoW.SpellCooldownTimeRemaining("Vendetta") >= 10 ||
                                WoW.TargetHasDebuff("Vendetta")
                            ))
                        {
                            WoW.CastSpell("Kingsbane");
                            return;
                        }
                        if (!WoW.PlayerHasBuff("Vanish") && WoW.CanCast("Garrote") && WoW.Energy >= 45 && !WoW.TargetHasDebuff("Garrote") && !WoW.IsSpellOnCooldown("Garrote") && WoW.CurrentComboPoints <= 4 && WoW.IsSpellInRange("Garrote"))
                        {
                            WoW.CastSpell("Garrote");
                            return;
                        }
                        if (WoW.TargetHasDebuff("Vendetta") && WoW.CanCast("Fan Of Knives") && WoW.Energy >= 35 && WoW.PlayerHasBuff("FoK") && WoW.PlayerBuffStacks("FoK") == 30 && WoW.CurrentComboPoints <= 4)
                        {
                            WoW.CastSpell("Fan Of Knives");
                            return;
                        }
                        if (!WoW.PlayerHasBuff("Vanish") && WoW.CanCast("Garrote") && WoW.Energy >= 45 && WoW.TargetHasDebuff("Garrote") && WoW.TargetDebuffTimeRemaining("Garrote") <= 3 && WoW.CurrentComboPoints <= 4 && WoW.IsSpellInRange("Garrote"))
                        {
                            WoW.CastSpell("Garrote");
                            return;
                        }
                        if (WoW.CurrentComboPoints == 4 && WoW.Energy >= 25 && WoW.CanCast("Rupture") && !WoW.TargetHasDebuff("Rupture") && WoW.IsSpellInRange("Garrote"))
                        {
                            WoW.CastSpell("Rupture");
                            return;
                        }
                        if (WoW.CurrentComboPoints == 4 && WoW.Energy >= 25 && WoW.TargetHasDebuff("Rupture") && WoW.TargetDebuffTimeRemaining("Rupture") <= 6 && WoW.IsSpellInRange("Garrote"))
                        {
                            WoW.CastSpell("Rupture");
                            return;
                        }
                        if (WoW.CurrentComboPoints == 5 && WoW.Energy >= 25 && WoW.CanCast("Rupture") && !WoW.TargetHasDebuff("Rupture") && WoW.IsSpellInRange("Garrote"))
                        {
                            WoW.CastSpell("Rupture");
                            return;
                        }
                        if (WoW.CurrentComboPoints == 5 && WoW.Energy >= 25 && WoW.TargetHasDebuff("Rupture") && WoW.TargetDebuffTimeRemaining("Rupture") <= 6 && WoW.IsSpellInRange("Garrote"))
                        {
                            WoW.CastSpell("Rupture");
                            return;
                        }
                        if (!WoW.PlayerHasBuff("Vanish") && WoW.TargetHasDebuff("Toxins") && WoW.TargetDebuffTimeRemaining("Toxins") <= 1.5 && WoW.Energy >= 35 && WoW.CurrentComboPoints == 4 && WoW.CanCast("Envenom") && WoW.TargetHasDebuff("Rupture") && WoW.TargetDebuffTimeRemaining("Rupture") > 6 && WoW.IsSpellInRange("Garrote"))
                        {
                            WoW.CastSpell("Envenom");
                            return;
                        }
                        if (!WoW.PlayerHasBuff("Vanish") && WoW.TargetHasDebuff("Toxins") && WoW.TargetDebuffTimeRemaining("Toxins") <= 1.5 && WoW.Energy >= 35 && WoW.CurrentComboPoints == 5 && WoW.CanCast("Envenom") && WoW.TargetHasDebuff("Rupture") && WoW.TargetDebuffTimeRemaining("Rupture") > 6 && WoW.IsSpellInRange("Garrote"))
                        {
                            WoW.CastSpell("Envenom");
                            return;
                        }
                        if (WoW.TargetHasDebuff("Kingsbane") && WoW.TargetDebuffTimeRemaining("Rupture") >= 4 && WoW.Energy >= 35 && WoW.CurrentComboPoints >= 2 && WoW.PlayerHasBuff("Envenom") && WoW.PlayerBuffTimeRemaining("Envenom") <= 1.5)
                        {
                            WoW.CastSpell("Envenom");
                            Log.Write("Extend Envenom remaining");
                            return;
                        }
                        if (WoW.TargetHasDebuff("Kingsbane") && WoW.TargetDebuffTimeRemaining("Rupture") >= 4 && WoW.Energy >= 35 && WoW.CurrentComboPoints >= 2 && !WoW.PlayerHasBuff("Envenom"))
                        {
                            WoW.CastSpell("Envenom");
                            Log.Write("Getting Envenom up for kingsbane");
                            return;
                        }
                        if (!WoW.PlayerHasBuff("Vanish") && !WoW.TargetHasDebuff("Toxins") && WoW.Energy >= 35 && WoW.CurrentComboPoints == 4 && WoW.CanCast("Envenom") && WoW.TargetHasDebuff("Rupture") && WoW.TargetDebuffTimeRemaining("Rupture") > 6 && WoW.IsSpellInRange("Garrote"))
                        {
                            WoW.CastSpell("Envenom");
                            return;
                        }
                        if (!WoW.PlayerHasBuff("Vanish") && !WoW.TargetHasDebuff("Toxins") && WoW.Energy >= 35 && WoW.CurrentComboPoints == 5 && WoW.CanCast("Envenom") && WoW.TargetHasDebuff("Rupture") && WoW.TargetDebuffTimeRemaining("Rupture") > 6 && WoW.IsSpellInRange("Garrote"))
                        {
                            WoW.CastSpell("Envenom");
                            return;
                        }
                        if (!WoW.PlayerHasBuff("Vanish") && WoW.TargetHasDebuff("Toxins") && WoW.TargetHasDebuff("Vendetta") && WoW.Energy >= 140 && WoW.CurrentComboPoints >= 4 && WoW.CanCast("Envenom") && WoW.TargetHasDebuff("Rupture") && WoW.TargetDebuffTimeRemaining("Rupture") > 6 && WoW.IsSpellInRange("Garrote"))
                        {
                            WoW.CastSpell("Envenom");
                            return;
                        }
                        if (WoW.CanCast("Mutilate") && WoW.Energy >= 55 && WoW.CurrentComboPoints <= 3)
                        {
                            WoW.CastSpell("Mutilate");
                            return;
                        }
                        if (UseCooldowns && WoW.CanCast("Vendetta") &&
                            !WoW.IsSpellOnCooldown("Vendetta") &&
                            WoW.Energy <= 50
                            )
                        {
                            WoW.CastSpell("Vendetta");
                            return;
                        }

                        /*if (UseCooldowns &&
                         * WoW.CanCast("Vanish") &&
                         * WoW.CurrentComboPoints >= 5 &&
                         * WoW.Energy >= 25 && WoW.TargetHasDebuff("Vendetta") &&
                         * (
                         * WoW.TargetHasDebuff("Rupture") &&
                         * WoW.TargetDebuffTimeRemaining("Rupture") < 10
                         * )
                         * ) {
                         * WoW.CastSpell("Vanish");
                         * return;
                         * }*/
                        if (!WoW.PlayerHasBuff("Critbuff") && UseCooldowns && WoW.CurrentComboPoints == 5 && !WoW.IsSpellOnCooldown("Vanish") && WoW.Energy >= 35 && WoW.TargetHasDebuff("Vendetta"))
                        {
                            WoW.CastSpell("Vanish");
                            return;
                        }
                        if (UseCooldowns && WoW.CurrentComboPoints == 5 && WoW.PlayerHasBuff("Vanish") && WoW.Energy >= 35 && WoW.TargetHasDebuff("Vendetta"))
                        {
                            WoW.CastSpell("Rupture");
                            return;
                        }
                    }
                }


                if (combatRoutine.Type == RotationType.AOE || combatRoutine.Type == RotationType.SingleTargetCleave) // Do AoE Target Stuff here
                {
                    if (WoW.HasTarget && WoW.IsSpellInRange("Rupture") && WoW.IsInCombat)
                    {
                        if (WoW.Energy >= 35 && WoW.CurrentComboPoints <= 4 && WoW.CanCast("Fan Of Knives"))
                        {
                            WoW.CastSpell("Fan Of Knives");
                            return;
                        }
                        if (WoW.Energy >= 35 && WoW.CurrentComboPoints == 4 && WoW.TargetHealthPercent <= 35 && WoW.CanCast("Envenom"))
                        {
                            WoW.CastSpell("Envenom");
                            return;
                        }
                        if (WoW.Energy >= 35 && WoW.CurrentComboPoints == 5 && WoW.TargetHealthPercent <= 35 && WoW.CanCast("Envenom"))
                        {
                            WoW.CastSpell("Envenom");
                            return;
                        }
                        if (WoW.Energy >= 25 && WoW.CurrentComboPoints == 4 && WoW.TargetHealthPercent >= 36 && WoW.CanCast("Rupture") && !WoW.TargetHasDebuff("Rupture"))
                        {
                            WoW.CastSpell("Rupture");
                            return;
                        }
                        if (WoW.Energy >= 25 && WoW.CurrentComboPoints == 5 && WoW.TargetHealthPercent >= 36 && WoW.CanCast("Rupture") && !WoW.TargetHasDebuff("Rupture"))
                        {
                            WoW.CastSpell("Rupture");
                            return;
                        }
                        if (WoW.Energy >= 35 && WoW.CurrentComboPoints >= 4 && WoW.TargetHealthPercent >= 36 && WoW.TargetHasDebuff("Rupture") && WoW.CanCast("Envenom"))
                        {
                            WoW.CastSpell("Envenom");
                            return;
                        }
                        if (WoW.CanCast("Garrote") && WoW.Energy >= 45 && !WoW.TargetHasDebuff("Garrote") && !WoW.IsSpellOnCooldown("Garrote") && WoW.CurrentComboPoints <= 4 && WoW.IsSpellInRange("Garrote"))
                        {
                            WoW.CastSpell("Garrote");
                            return;
                        }
                    }
                }
            }
        }
        public override void Pulse()
        {
            if (combatRoutine.Type == RotationType.SingleTarget) // Do Single Target Stuff here
            {
                if (WoW.HasTarget && WoW.TargetIsEnemy && !WoW.PlayerIsChanneling && WoW.IsInCombat) //Pull need to do by yourself - to prevent a mess
                {
                    if (WoW.CanCast("Metamorphosis") && WoW.HealthPercent <= ConfigFile.ReadValue<int>("Demonhunter", "Metamorphosis Usage Percent"))
                    {
                        //Log.Write("Metamorphosis");
                        Log.Write("Health low < set % using CDs...", Color.Red);
                        WoW.CastSpell("Metamorphosis"); // Off the GCD no return needed
                    }
						
					if (WoW.TargetIsCastingAndSpellIsInterruptible) //interupt every spell with all we got
                    {
						if (WoW.CanCast("Consume Magic") && WoW.TargetPercentCast >= 60 && WoW.IsSpellInRange("Consume Magic"))
						{	
							WoW.CastSpell("Consume Magic");
							return;
						}
						
						if (Bloodelf && WoW.CanCast("Arcane Torrent") && WoW.IsSpellOnCooldown("Consume Magic") && WoW.TargetPercentCast >= 60 && WoW.IsSpellInRange("Soul Carver"))
						{	
							WoW.CastSpell("Arcane Torrent");
							return;
						}
						
						if (WoW.CanCast("Sigil of Silence") && WoW.IsSpellOnCooldown("Consume Magic") && (WoW.IsSpellOnCooldown("Arcane Torrent") || !Bloodelf) && WoW.IsSpellInRange("Soul Carver"))
						{	
							WoW.CastSpell("Sigil of Silence");
							return;
						}
                        
					}

                    if (WoW.CanCast("Fiery Brand") && WoW.IsSpellInRange("Fiery Brand") && !WoW.TargetHasDebuff("Fiery Demise"))
                    {
                        WoW.CastSpell("Fiery Brand");
                    }

                    if (WoW.CanCast("Soul Carver") && WoW.IsSpellInRange("Soul Carver") && WoW.SpellCooldownTimeRemaining("Fiery Brand") >= 10)
                    {
                        WoW.CastSpell("Soul Carver");
                        return;
                    }

                    if (WoW.CanCast("Spirit Bomb") && WoW.IsSpellInRange("Spirit Bomb") && WoW.PlayerHasBuff("Soul Fragments") && !WoW.TargetHasDebuff("Frailty"))
                    {
                        WoW.CastSpell("Spirit Bomb");
                        return;
                    }

                    if (WoW.CanCast("Sigil of Flame") && WoW.IsSpellInRange("Soul Carver") && WoW.TargetHasDebuff("Fiery Demise") && WoW.TargetDebuffTimeRemaining("Fiery Demise") >= 7)
                    {
                        WoW.CastSpell("Sigil of Flame");
                        return;
                    }

                    if (WoW.CanCast("Fel Eruption") && WoW.IsSpellInRange("Fel Eruption") && WoW.Pain >= 10 && WoW.TargetHasDebuff("Fiery Demise"))
                    {
                        WoW.CastSpell("Fel Eruption");
                        return;
                    }

                    if (WoW.CanCast("Soul Barrier") && WoW.Pain >= 10 && WoW.PlayerHasBuff("Soul Fragments") && WoW.PlayerBuffStacks("Soul Fragments") >= 4)
                    {
                        WoW.CastSpell("Soul Barrier");
                        return;
                    }

                    if (WoW.CanCast("Demon Spikes") && !WoW.PlayerHasBuff("Demon Spikes") && (WoW.Pain >= 92 || WoW.HealthPercent < 90 && WoW.Pain >= 20)) // to not waste cd and pain
                    {
                        WoW.CastSpell("Demon Spikes");
                    }
					
					if (WoW.IsSpellInRange("Soul Carver"))
					{
							if (WoW.CanCast("Soul Cleave") && ((WoW.Pain >= 30 && WoW.HealthPercent < 25) || (WoW.Pain >= 80 && WoW.HealthPercent < 50 && !WoW.CanCast("Demon Spikes"))
								|| (WoW.Pain >= 60 && WoW.HealthPercent < 50 && WoW.PlayerHasBuff("Demon Spikes"))))
								{
									WoW.CastSpell("Soul Cleave");
									return;
								}
								
							if (WoW.CanCast("Fracture") && ((WoW.Pain >= 20 && WoW.HealthPercent >= 50 && WoW.PlayerHasBuff("Demon Spikes"))
								|| (WoW.Pain >= 80 && WoW.HealthPercent >= 50 && !WoW.CanCast("Demon Spikes"))))
								{
									WoW.CastSpell("Fracture");
									return;
								}

						if (WoW.CanCast("Immolation Aura"))
						{
							WoW.CastSpell("Immolation Aura");
							return;
						}

						if (WoW.CanCast("Sigil of Flame"))
						{
							WoW.CastSpell("Sigil of Flame");
							return;
						}
					}

                    if (WoW.CanCast("Fel Eruption") && WoW.IsSpellInRange("Fel Eruption") && WoW.Pain >= 10)
                    {
                        WoW.CastSpell("Fel Eruption");
                        return;
                    }

                    if (WoW.CanCast("Sever") && WoW.IsSpellInRange("Soul Carver") && WoW.PlayerHasBuff("Metamorphosis")) // Pain Generator
                    {
                        WoW.CastSpell("Sever");
                        return;
                    }

                    if (WoW.CanCast("Shear") && WoW.IsSpellInRange("Soul Carver") && !WoW.PlayerHasBuff("Metamorphosis")) // Pain Generator
                    {
                        WoW.CastSpell("Shear");
                        return;
                    }
					
					if (WoW.CanCast("Throw Glaive") && !WoW.IsSpellInRange("Soul Carver") && WoW.IsSpellInRange("Throw Glaive")) //Need to implement range 30y for Throw Glaive spell 204157
                    {
                        WoW.CastSpell("Throw Glaive");
                        return;
                    }
                }
            }
            if (combatRoutine.Type == RotationType.AOE || combatRoutine.Type == RotationType.SingleTargetCleave)
            {
				if (WoW.HasTarget && WoW.TargetIsEnemy && !WoW.PlayerIsChanneling && WoW.IsInCombat) //Pull need to do by yourself - to prevent a mess
                {
                    if (WoW.CanCast("Metamorphosis") && WoW.HealthPercent <= ConfigFile.ReadValue<int>("Demonhunter", "Metamorphosis Usage Percent"))
                    {
                        //Log.Write("Metamorphosis");
                        Log.Write("Health low < set % using CDs...", Color.Red);
                        WoW.CastSpell("Metamorphosis"); // Off the GCD no return needed
                    }
						
					if (WoW.TargetIsCastingAndSpellIsInterruptible) //interupt every spell with all we got
                    {
						if (WoW.CanCast("Consume Magic") && WoW.TargetPercentCast >= 60 && WoW.IsSpellInRange("Consume Magic"))
						{	
							WoW.CastSpell("Consume Magic");
							return;
						}
						
						if (Bloodelf && WoW.CanCast("Arcane Torrent") && WoW.IsSpellOnCooldown("Consume Magic") && WoW.TargetPercentCast >= 60 && WoW.IsSpellInRange("Soul Carver"))
						{	
							WoW.CastSpell("Arcane Torrent");
							return;
						}
						
						if (WoW.CanCast("Sigil of Silence") && WoW.IsSpellOnCooldown("Consume Magic") && (WoW.IsSpellOnCooldown("Arcane Torrent") || !Bloodelf) && WoW.IsSpellInRange("Soul Carver"))
						{	
							WoW.CastSpell("Sigil of Silence");
							return;
						}
                        
					}

                    if (WoW.CanCast("Fiery Brand") && WoW.IsSpellInRange("Fiery Brand") && !WoW.TargetHasDebuff("Fiery Demise"))
                    {
                        WoW.CastSpell("Fiery Brand");
                    }

                    if (WoW.CanCast("Soul Carver") && WoW.IsSpellInRange("Soul Carver") && WoW.SpellCooldownTimeRemaining("Fiery Brand") >= 10)
                    {
                        WoW.CastSpell("Soul Carver");
                        return;
                    }

                    if (WoW.CanCast("Spirit Bomb") && WoW.IsSpellInRange("Spirit Bomb") && WoW.PlayerHasBuff("Soul Fragments") && !WoW.TargetHasDebuff("Frailty"))
                    {
                        WoW.CastSpell("Spirit Bomb");
                        return;
                    }

                    if (WoW.CanCast("Sigil of Flame") && WoW.IsSpellInRange("Soul Carver") && WoW.TargetHasDebuff("Fiery Demise") && WoW.TargetDebuffTimeRemaining("Fiery Demise") >= 7)
                    {
                        WoW.CastSpell("Sigil of Flame");
                        return;
                    }

                    if (WoW.CanCast("Fel Eruption") && WoW.IsSpellInRange("Fel Eruption") && WoW.Pain >= 10 && WoW.TargetHasDebuff("Fiery Demise"))
                    {
                        WoW.CastSpell("Fel Eruption");
                        return;
                    }

                    if (WoW.CanCast("Soul Barrier") && WoW.Pain >= 10 && WoW.PlayerHasBuff("Soul Fragments") && WoW.PlayerBuffStacks("Soul Fragments") >= 4)
                    {
                        WoW.CastSpell("Soul Barrier");
                        return;
                    }

                    if (WoW.CanCast("Demon Spikes") && !WoW.PlayerHasBuff("Demon Spikes") && (WoW.Pain >= 92 || WoW.HealthPercent < 90 && WoW.Pain >= 20)) // to not waste cd and pain
                    {
                        WoW.CastSpell("Demon Spikes");
                    }
					
					if (WoW.IsSpellInRange("Soul Carver"))
					{
						if (WoW.CanCast("Soul Cleave") && ((WoW.Pain >= 30 && WoW.HealthPercent < 25) || (WoW.Pain >= 80 && !WoW.CanCast("Demon Spikes"))
							|| (WoW.Pain >= 60 && WoW.PlayerHasBuff("Demon Spikes"))))
						{
							WoW.CastSpell("Soul Cleave");
							return;
						}

						if (WoW.CanCast("Immolation Aura"))
						{
							WoW.CastSpell("Immolation Aura");
							return;
						}

						if (WoW.CanCast("Sigil of Flame"))
						{
							WoW.CastSpell("Sigil of Flame");
							return;
						}
					}

                    if (WoW.CanCast("Fel Eruption") && WoW.IsSpellInRange("Fel Eruption") && WoW.Pain >= 10)
                    {
                        WoW.CastSpell("Fel Eruption");
                        return;
                    }

                    if (WoW.CanCast("Sever") && WoW.IsSpellInRange("Soul Carver") && WoW.PlayerHasBuff("Metamorphosis")) // Pain Generator
                    {
                        WoW.CastSpell("Sever");
                        return;
                    }

                    if (WoW.CanCast("Shear") && WoW.IsSpellInRange("Soul Carver") && !WoW.PlayerHasBuff("Metamorphosis")) // Pain Generator
                    {
                        WoW.CastSpell("Shear");
                        return;
                    }
					
					if (WoW.CanCast("Throw Glaive") && !WoW.IsSpellInRange("Soul Carver") && WoW.IsSpellInRange("Throw Glaive")) //Need to implement range 30y for Throw Glaive spell 204157
                    {
                        WoW.CastSpell("Throw Glaive");
                        return;
                    }
				}
            }
        }
Exemplo n.º 3
0
        public override void Pulse() // Updated for Legion (tested and working for single target)
        {
            AddonCreationPulse();
            PlayerStats();
            AoEStuff();
            if (WoW.IsInCombat && !WoW.PlayerHasBuff("Mount"))
            {
                SelectRotation();
            }

            if (combatRoutine.Type == RotationType.SingleTarget) // Do Single Target Stuff here
            {
                if (WoW.HasTarget && WoW.TargetIsEnemy && WoW.IsInCombat && !WoW.PlayerIsCasting && !WoW.PlayerHasBuff("Mount"))
                {
                    if (WoW.CurrentSoulShards >= 1 &&
                        WoW.WasLastCasted("Unstable Affliction") &&
                        WoW.CanCast("Reap Souls") &&
                        WoW.IsSpellInRange("Agony") &&
                        !WoW.PlayerIsCasting &&
                        !WoW.PlayerHasBuff("Deadwind Harvester") &&
                        WoW.PlayerHasBuff("Tormented Souls"))
                    {
                        WoW.CastSpell("Reap Souls");
                        Thread.Sleep(200);
                        return;
                    }

                    if ((!WoW.TargetHasDebuff("Agony") || WoW.TargetDebuffTimeRemaining("Agony") <= 5.4) &&
                        (!WoW.PlayerIsChanneling || WoW.TargetDebuffTimeRemaining("Agony") <= 1.5) &&
                        WoW.CanCast("Agony") &&
                        WoW.IsSpellInRange("Agony"))
                    {
                        WoW.CastSpell("Agony");
                        return;
                    }

                    if ((WoW.CurrentSoulShards >= 3 || WoW.WasLastCasted("Unstable Affliction") &&
                         !WoW.IsMoving &&
                         WoW.CanCast("Unstable Affliction") &&
                         WoW.IsSpellInRange("Agony")))
                    {
                        WoW.CastSpell("Unstable Affliction");
                        Thread.Sleep(200);
                        return;
                    }

                    if (WoW.CanCast("Life Tap") && !WoW.PlayerIsChanneling && CharInfo.T2 == 3 && !WoW.PlayerHasBuff("Empowered Life Tap"))
                    {
                        WoW.CastSpell("Life Tap");
                        return;
                    }

                    if ((!WoW.TargetHasDebuff("Corruption") || WoW.TargetDebuffTimeRemaining("Corruption") <= 4.2) &&
                        (!WoW.PlayerIsChanneling || WoW.TargetDebuffTimeRemaining("Corruption") <= 1) &&
                        WoW.CanCast("Corruption") &&
                        WoW.IsSpellInRange("Agony"))
                    {
                        WoW.CastSpell("Corruption");
                        return;
                    }

                    if ((!WoW.TargetHasDebuff("Siphon Life") || WoW.TargetDebuffTimeRemaining("Siphon Life") <= 4.2) &&
                        (!WoW.PlayerIsChanneling || WoW.TargetDebuffTimeRemaining("Siphon Life") <= 1) &&
                        CharInfo.T4 == 1 &&
                        WoW.CanCast("Siphon Life") &&
                        WoW.IsSpellInRange("Agony"))
                    {
                        WoW.CastSpell("Siphon Life");
                        return;
                    }

                    /*if (WoW.TargetHasDebuff("Unstable Affliction1") && WoW.TargetHasDebuff("Unstable Affliction2")
                    || (WoW.TargetHasDebuff("Unstable Affliction1") && WoW.TargetHasDebuff("Unstable Affliction3"))
                    || (WoW.TargetHasDebuff("Unstable Affliction1") && WoW.TargetHasDebuff("Unstable Affliction4"))
                    || (WoW.TargetHasDebuff("Unstable Affliction1") && WoW.TargetHasDebuff("Unstable Affliction5"))
                    || (WoW.TargetHasDebuff("Unstable Affliction2") && WoW.TargetHasDebuff("Unstable Affliction3"))
                    || (WoW.TargetHasDebuff("Unstable Affliction2") && WoW.TargetHasDebuff("Unstable Affliction4"))
                    || (WoW.TargetHasDebuff("Unstable Affliction2") && WoW.TargetHasDebuff("Unstable Affliction5"))
                    || (WoW.TargetHasDebuff("Unstable Affliction3") && WoW.TargetHasDebuff("Unstable Affliction4"))
                    || (WoW.TargetHasDebuff("Unstable Affliction3") && WoW.TargetHasDebuff("Unstable Affliction5"))
                    || (WoW.TargetHasDebuff("Unstable Affliction4") && WoW.TargetHasDebuff("Unstable Affliction5"))
                    ||  && !WoW.PlayerIsCasting
                    ||  && WoW.CanCast("Reap Souls")
                    ||  && !WoW.PlayerHasBuff("Deadwind Harvester")
                    ||  && WoW.PlayerHasBuff("Tormented Souls"))
                    || {
                    ||  WoW.CastSpell("Reap Souls");
                    ||  return;
                    || }*/



                    if (WoW.CanCast("Reap Souls") && !WoW.PlayerIsCasting && !WoW.PlayerHasBuff("Deadwind Harvester") && WoW.PlayerHasBuff("Tormented Souls"))
                    {
                        WoW.CastSpell("Reap Souls");
                        return;
                    }

                    if (WoW.CanCast("Felhunter") && CharInfo.T6 == 2 && !WoW.IsSpellOnCooldown("Felhunter") && WoW.IsSpellInRange("Agony") && !WoW.PlayerIsChanneling && !WoW.PlayerIsCasting)
                    {
                        WoW.CastSpell("Felhunter");
                        return;
                    }

                    if (WoW.CanCast("Unstable Affliction") && !WoW.IsMoving && CharInfo.T2 == 1 && !WoW.IsMoving && WoW.IsSpellInRange("Unstable Affliction") && !WoW.PlayerIsChanneling && WoW.CurrentSoulShards >= 1 &&
                        (!WoW.TargetHasDebuff("Unstable Affliction1") || !WoW.TargetHasDebuff("Unstable Affliction2") || !WoW.TargetHasDebuff("Unstable Affliction3") || !WoW.TargetHasDebuff("Unstable Affliction4") || !WoW.TargetHasDebuff("Unstable Affliction5") ||
                         (WoW.TargetDebuffTimeRemaining("Unstable Affliction1") <= 1.5) || (WoW.TargetDebuffTimeRemaining("Unstable Affliction2") <= 1.5) || (WoW.TargetDebuffTimeRemaining("Unstable Affliction3") <= 1.5) ||
                         (WoW.TargetDebuffTimeRemaining("Unstable Affliction4") <= 1.5) || (WoW.TargetDebuffTimeRemaining("Unstable Affliction5") <= 1.5)))
                    {
                        WoW.CastSpell("Unstable Affliction");
                        Thread.Sleep(200);
                        return;
                    }

                    if (WoW.IsInCombat && WoW.Mana < 70 && WoW.HealthPercent > 70 && WoW.CanCast("Life Tap"))
                    {
                        WoW.CastSpell("Life Tap");
                        return;
                    }

                    if (WoW.CanCast("Haunt") && CharInfo.T1 == 1 && !WoW.IsSpellOnCooldown("Haunt") && WoW.IsSpellInRange("Agony") && !WoW.PlayerIsChanneling && !WoW.PlayerIsCasting && !WoW.IsMoving)
                    {
                        WoW.CastSpell("Haunt");
                        return;
                    }

                    if (WoW.CanCast("Drain Soul") && WoW.IsSpellInRange("Agony") && !WoW.PlayerIsChanneling && !WoW.PlayerIsCasting && !WoW.IsMoving)
                    {
                        WoW.CastSpell("Drain Soul");
                        return;
                    }
                }
            }
            if (combatRoutine.Type == RotationType.AOE)
            {
                if (WoW.HasTarget && WoW.TargetIsEnemy && WoW.IsInCombat && !WoW.PlayerIsChanneling && !WoW.PlayerIsCasting && !WoW.PlayerHasBuff("Mount")) // Do AOE stuff here
                {
                    if (WoW.CanCast("Agony") && WoW.IsSpellInRange("Agony") && WoW.TargetHasDebuff("Seed of Corruption") && (!WoW.TargetHasDebuff("Agony") || (WoW.TargetDebuffTimeRemaining("Agony") <= 5.4)))
                    {
                        WoW.CastSpell("Agony");
                        return;
                    }

                    if (WoW.CanCast("Corruption") && WoW.IsSpellInRange("Agony") && WoW.TargetHasDebuff("Seed of Corruption") && (!WoW.TargetHasDebuff("Corruption") || (WoW.TargetDebuffTimeRemaining("Corruption") <= 4.2)))
                    {
                        WoW.CastSpell("Corruption");
                        return;
                    }

                    if (WoW.CanCast("Seed of Corruption") && WoW.IsSpellInRange("Agony") && !WoW.TargetHasDebuff("Seed of Corruption") && !WoW.IsMoving && WoW.CurrentSoulShards >= 1)
                    {
                        WoW.CastSpell("Seed of Corruption");
                        return;
                    }
                }
            }
            if (combatRoutine.Type == RotationType.SingleTargetCleave)
            {
                // Do Single Target Cleave stuff here if applicable else ignore this one
            }
        }
        public override void Pulse()
        {
            if (combatRoutine.Type == RotationType.SingleTarget) /* Singel Target Rotation*/
            {
                if (WoW.HasTarget && WoW.TargetIsEnemy && WoW.HasTarget && WoW.IsInCombat && WoW.HealthPercent <= 20)
                /* Defensive Cooldowns */
                {
                    if (WoW.IsMoving && WoW.CanCast("UnendingResolve"))
                    {
                        WoW.CastSpell("UnendingResolve");
                        return;
                    }

                    if (!WoW.IsMoving && WoW.CanCast("UnendingResolve"))
                    {
                        WoW.CastSpell("UnendingResolve");
                        return;
                    }

                    if (!WoW.IsMoving && WoW.CanCast("DrainLife"))
                    {
                        WoW.CastSpell("DrainLife");
                        return;
                    }
                }

                if (WoW.IsInCombat && Control.ModifierKeys == Keys.Shift && !WoW.PlayerIsCasting)
                /* Havoc on mouseover target, create macro to use: #showtooltip /cast [target=mouseover,harm,exists,nodead] Havoc; Havoc */
                {
                    WoW.CastSpell("Havoc");
                    return;
                }

                if (WoW.HasTarget && WoW.TargetIsEnemy && !WoW.IsMoving && WoW.IsInCombat) /* What to do when we are NOT moving */
                {
                    if (!WoW.PlayerIsCasting && !WoW.PlayerIsChanneling && !WoW.TargetHasDebuff("AuraImmolate"))
                    {
                        if (WoW.HasTarget && WoW.CanCast("DimRift") && WoW.PlayerSpellCharges("DimRift") == 3)
                        {
                            WoW.CastSpell("DimRift");
                            return;
                        }

                        if (!WoW.WasLastCasted("Immolate") && WoW.CanCast("Immolate"))
                        {
                            WoW.CastSpell("Immolate");
                            return;
                        }
                    }

                    if (!WoW.PlayerIsCasting && !WoW.PlayerIsChanneling && WoW.TargetHasDebuff("AuraImmolate"))
                    {
                        if (WoW.HasTarget && WoW.CanCast("DimRift") && WoW.PlayerSpellCharges("DimRift") == 3)
                        {
                            WoW.CastSpell("DimRift");
                            return;
                        }

                        if (WoW.TargetDebuffTimeRemaining("AuraImmolate") >= 10 && WoW.CanCast("Conflagrate"))
                        {
                            WoW.CastSpell("Conflagrate");
                            return;
                        }

                        if (WoW.TargetDebuffTimeRemaining("AuraImmolate") <= 4.2 && !WoW.WasLastCasted("Immolate") && WoW.CanCast("Immolate"))
                        {
                            WoW.CastSpell("Immolate");
                            return;
                        }

                        if (WoW.TargetDebuffTimeRemaining("AuraImmolate") >= 10 && WoW.PlayerSpellCharges("Conflagrate") == 1 && WoW.WasLastCasted("Conflagrate") && WoW.CanCast("Conflagrate"))
                        {
                            WoW.CastSpell("Conflagrate");
                            return;
                        }

                        if (WoW.PlayerHasBuff("AuraConflagrateBuff") && WoW.TargetHasDebuff("AuraChaosBolt") && WoW.CanCast("Conflagrate") && WoW.CurrentSoulShards <= 4 &&
                            WoW.CanCast("Conflagrate"))
                        {
                            WoW.CastSpell("Conflagrate");
                            return;
                        }

                        if (WoW.CanCast("Conflagrate") && WoW.PlayerSpellCharges("Conflagrate") == 2 && !WoW.WasLastCasted("Immolate") && WoW.CurrentSoulShards <= 4)
                        {
                            WoW.CastSpell("Conflagrate");
                            return;
                        }

                        if (WoW.HasTarget && WoW.CanCast("ServiceImp") && WoW.CurrentSoulShards >= 1)
                        {
                            WoW.CastSpell("ServiceImp");
                            return;
                        }

                        /* Summon Infernal on the target but its an AOE ground Spell. I'm not able to code that: */
                        /* Summon DoomGuard if LordOfFlames debuff is up*/

                        if (WoW.HasTarget && WoW.CanCast("DoomGuard"))
                        /*Since I can't do the Infernal check, I just summon DoomGuard*/
                        {
                            WoW.CastSpell("DoomGuard");
                            return;
                        }

                        if (WoW.CanCast("ChaosBolt") /* && !WoW.WasLastCasted("ChaosBolt")  */ && WoW.CurrentSoulShards > 3)
                        {
                            WoW.CastSpell("ChaosBolt");
                            return;
                        }

                        if (WoW.HasTarget && WoW.CanCast("DimRift") && WoW.PlayerSpellCharges("DimRift") <= 2)
                        {
                            WoW.CastSpell("DimRift");
                            return;
                        }

                        if (WoW.CanCast("ChaosBolt") && WoW.CurrentSoulShards >= 2)
                        {
                            WoW.CastSpell("ChaosBolt");
                            return;
                        }

                        if (WoW.CanCast("Incinerate") && WoW.WasLastCasted("ChaosBolt")
                            /*&& WoW.HasDebuff("AuraChaosBolt")*/)
                        {
                            WoW.CastSpell("Incinerate");
                            return;
                        }

                        if (WoW.CanCast("Incinerate") && WoW.CurrentSoulShards <= 1)
                        {
                            WoW.CastSpell("Incinerate");
                            return;
                        }

                        if (WoW.CanCast("Incinerate") && WoW.TargetHasDebuff("AuraChaosBolt") && WoW.TargetDebuffTimeRemaining("AuraChaosBolt") >= 2 && WoW.CurrentSoulShards <= 3)
                        {
                            WoW.CastSpell("Incinerate");
                            return;
                        }
                    }
                }

                if (WoW.HasTarget && WoW.TargetIsEnemy && WoW.IsMoving && WoW.IsInCombat)
                /* What to do when we are moving */
                {
                    if (!WoW.PlayerIsCasting && !WoW.PlayerIsChanneling && WoW.HasTarget && WoW.CanCast("DimRift"))
                    {
                        WoW.CastSpell("DimRift");
                        return;
                    }

                    if (!WoW.PlayerIsCasting && !WoW.PlayerIsChanneling && WoW.CanCast("Conflagrate"))
                    {
                        WoW.CastSpell("Conflagrate");
                    }
                }
            }
        }
Exemplo n.º 5
0
        public override void Pulse()
        {
            {
                if (combatRoutine.Type == RotationType.SingleTarget)
                {
                    if (WoW.IsSpellInRange("Rupture") && WoW.IsInCombat && !WoW.IsMounted)
                    {
                        if (UseCooldowns &&
                            WoW.CanCast("Kingsbane") && WoW.CurrentComboPoints <= 4 && WoW.Energy >= 35 && WoW.PlayerHasBuff("Envenom") && WoW.PlayerBuffTimeRemaining("Envenom") >= 150 &&
                            !WoW.IsSpellOnCooldown("Kingsbane") && WoW.TargetHasDebuff("Rupture") && WoW.TargetDebuffTimeRemaining("Rupture") >= 1400 &&
                            (
                                WoW.SpellCooldownTimeRemaining("Vendetta") >= 1000 ||
                                WoW.TargetHasDebuff("Vendetta")
                            ))
                        {
                            WoW.CastSpell("Kingsbane");
                            return;
                        }
                        if (!WoW.PlayerHasBuff("Vanish") && WoW.CanCast("Toxic Blade") && WoW.Energy >= 20 && !WoW.IsSpellOnCooldown("Toxic Blade") && WoW.CurrentComboPoints <= 4 && WoW.IsSpellInRange("Garrote") && WoW.Talent(6) == 1)
                        {
                            WoW.CastSpell("Toxic Blade");
                            return;
                        }
                        if (!WoW.PlayerHasBuff("Vanish") && WoW.CanCast("Exsanguinate") && WoW.Energy >= 25 && !WoW.IsSpellOnCooldown("Exsanguinate") && WoW.IsSpellInRange("Garrote") && WoW.Talent(6) == 3)
                        {
                            WoW.CastSpell("Exsanguinate");
                            return;
                        }
                        if (!WoW.PlayerHasBuff("Vanish") && WoW.CanCast("Garrote") && WoW.Energy >= 45 && !WoW.TargetHasDebuff("Garrote") && !WoW.IsSpellOnCooldown("Garrote") && WoW.CurrentComboPoints <= 4 && WoW.IsSpellInRange("Garrote"))
                        {
                            WoW.CastSpell("Garrote");
                            return;
                        }
                        if (WoW.TargetHasDebuff("Vendetta") && WoW.CanCast("Fan Of Knives") && WoW.Energy >= 35 && WoW.PlayerHasBuff("FoK") && WoW.PlayerBuffStacks("FoK") == 30 && WoW.CurrentComboPoints <= 4)
                        {
                            WoW.CastSpell("Fan Of Knives");
                            return;
                        }
                        if (!WoW.PlayerHasBuff("Vanish") && WoW.CanCast("Garrote") && WoW.Energy >= 45 && WoW.TargetHasDebuff("Garrote") && WoW.TargetDebuffTimeRemaining("Garrote") <= 300 && WoW.CurrentComboPoints <= 4 && WoW.IsSpellInRange("Garrote"))
                        {
                            WoW.CastSpell("Garrote");
                            return;
                        }
                        if (WoW.CurrentComboPoints == 4 && WoW.Energy >= 25 && WoW.CanCast("Rupture") && !WoW.TargetHasDebuff("Rupture") && WoW.IsSpellInRange("Garrote"))
                        {
                            WoW.CastSpell("Rupture");
                            return;
                        }
                        if (WoW.CurrentComboPoints == 4 && WoW.Energy >= 25 && WoW.TargetHasDebuff("Rupture") && WoW.TargetDebuffTimeRemaining("Rupture") <= 600 && WoW.IsSpellInRange("Garrote"))
                        {
                            WoW.CastSpell("Rupture");
                            return;
                        }
                        if (WoW.CurrentComboPoints == 5 && WoW.Energy >= 25 && WoW.CanCast("Rupture") && !WoW.TargetHasDebuff("Rupture") && WoW.IsSpellInRange("Garrote"))
                        {
                            WoW.CastSpell("Rupture");
                            return;
                        }
                        if (WoW.CurrentComboPoints == 5 && WoW.Energy >= 25 && WoW.TargetHasDebuff("Rupture") && WoW.TargetDebuffTimeRemaining("Rupture") <= 600 && WoW.IsSpellInRange("Garrote"))
                        {
                            WoW.CastSpell("Rupture");
                            return;
                        }
                        if (!WoW.PlayerHasBuff("Vanish") && WoW.TargetHasDebuff("Toxins") && WoW.TargetDebuffTimeRemaining("Toxins") <= 150 && WoW.Energy >= 35 && WoW.CurrentComboPoints == 4 && WoW.CanCast("Envenom") && WoW.TargetHasDebuff("Rupture") && WoW.TargetDebuffTimeRemaining("Rupture") > 600 && WoW.IsSpellInRange("Garrote"))
                        {
                            WoW.CastSpell("Envenom");
                            return;
                        }
                        if (!WoW.PlayerHasBuff("Vanish") && WoW.TargetHasDebuff("Toxins") && WoW.TargetDebuffTimeRemaining("Toxins") <= 150 && WoW.Energy >= 35 && WoW.CurrentComboPoints == 5 && WoW.CanCast("Envenom") && WoW.TargetHasDebuff("Rupture") && WoW.TargetDebuffTimeRemaining("Rupture") > 600 && WoW.IsSpellInRange("Garrote"))
                        {
                            WoW.CastSpell("Envenom");
                            return;
                        }
                        if (WoW.TargetHasDebuff("Kingsbane") && WoW.TargetDebuffTimeRemaining("Rupture") >= 400 && WoW.Energy >= 35 && WoW.CurrentComboPoints >= 2 && WoW.PlayerHasBuff("Envenom") && WoW.PlayerBuffTimeRemaining("Envenom") <= 150)
                        {
                            WoW.CastSpell("Envenom");
                            Log.Write("Extend Envenom remaining");
                            return;
                        }
                        if (WoW.TargetHasDebuff("Kingsbane") && WoW.TargetDebuffTimeRemaining("Rupture") >= 400 && WoW.Energy >= 35 && WoW.CurrentComboPoints >= 2 && !WoW.PlayerHasBuff("Envenom"))
                        {
                            WoW.CastSpell("Envenom");
                            Log.Write("Getting Envenom up for kingsbane");
                            return;
                        }
                        if (!WoW.PlayerHasBuff("Vanish") && !WoW.TargetHasDebuff("Toxins") && WoW.Energy >= 35 && WoW.CurrentComboPoints == 4 && WoW.CanCast("Envenom") && WoW.TargetHasDebuff("Rupture") && WoW.TargetDebuffTimeRemaining("Rupture") > 600 && WoW.IsSpellInRange("Garrote"))
                        {
                            WoW.CastSpell("Envenom");
                            return;
                        }
                        if (!WoW.PlayerHasBuff("Vanish") && !WoW.TargetHasDebuff("Toxins") && WoW.Energy >= 35 && WoW.CurrentComboPoints == 5 && WoW.CanCast("Envenom") && WoW.TargetHasDebuff("Rupture") && WoW.TargetDebuffTimeRemaining("Rupture") > 600 && WoW.IsSpellInRange("Garrote"))
                        {
                            WoW.CastSpell("Envenom");
                            return;
                        }
                        if (!WoW.PlayerHasBuff("Vanish") && WoW.TargetHasDebuff("Toxins") && WoW.TargetHasDebuff("Vendetta") && WoW.Energy >= 140 && WoW.CurrentComboPoints >= 4 && WoW.CanCast("Envenom") && WoW.TargetHasDebuff("Rupture") && WoW.TargetDebuffTimeRemaining("Rupture") > 600 && WoW.IsSpellInRange("Garrote"))
                        {
                            WoW.CastSpell("Envenom");
                            return;
                        }
                        if (WoW.CanCast("Mutilate") && WoW.Energy >= 55 && WoW.CurrentComboPoints <= 3)
                        {
                            WoW.CastSpell("Mutilate");
                            return;
                        }
                        if (UseCooldowns && WoW.CanCast("Vendetta") &&
                            !WoW.IsSpellOnCooldown("Vendetta") &&
                            WoW.Energy <= 50
                            )
                        {
                            WoW.CastSpell("Vendetta");
                            return;
                        }

                        /*if (UseCooldowns &&
                         * WoW.CanCast("Vanish") &&
                         * WoW.CurrentComboPoints >= 5 &&
                         * WoW.Energy >= 25 && WoW.TargetHasDebuff("Vendetta") &&
                         * (
                         * WoW.TargetHasDebuff("Rupture") &&
                         * WoW.TargetDebuffTimeRemaining("Rupture") < 10
                         * )
                         * ) {
                         * WoW.CastSpell("Vanish");
                         * return;
                         * }*/
                        if (!WoW.PlayerHasBuff("Critbuff") && UseCooldowns && WoW.CurrentComboPoints == 5 && !WoW.IsSpellOnCooldown("Vanish") && WoW.Energy >= 35 && WoW.TargetHasDebuff("Vendetta"))
                        {
                            WoW.CastSpell("Vanish");
                            return;
                        }
                        if (UseCooldowns && WoW.CurrentComboPoints == 5 && WoW.PlayerHasBuff("Vanish") && WoW.Energy >= 35 && WoW.TargetHasDebuff("Vendetta"))
                        {
                            WoW.CastSpell("Rupture");
                            return;
                        }
                        if (UseCooldowns && WoW.CanCast("Berserk") && !WoW.IsSpellOnCooldown("Berserk") && WoW.TargetHasDebuff("Vendetta") && WoW.PlayerRace == "Troll")
                        {
                            WoW.CastSpell("Berserk");
                            return;
                        }
                    }
                }


                if (combatRoutine.Type == RotationType.AOE || combatRoutine.Type == RotationType.SingleTargetCleave) // Do AoE Target Stuff here
                {
                    if (WoW.HasTarget && WoW.IsSpellInRange("Rupture") && WoW.IsInCombat && !WoW.IsMounted)
                    {
                        if (WoW.Energy >= 35 && WoW.CurrentComboPoints <= 4 && WoW.CanCast("Fan Of Knives"))
                        {
                            WoW.CastSpell("Fan Of Knives");
                            return;
                        }
                        if (!WoW.PlayerHasBuff("Vanish") && WoW.CanCast("Toxic Blade") && WoW.Energy >= 20 && !WoW.IsSpellOnCooldown("Toxic Blade") && WoW.CurrentComboPoints <= 4 && WoW.IsSpellInRange("Garrote") && WoW.Talent(6) == 1)
                        {
                            WoW.CastSpell("Toxic Blade");
                            return;
                        }
                        if (!WoW.PlayerHasBuff("Vanish") && WoW.CanCast("Exsanguinate") && WoW.Energy >= 25 && !WoW.IsSpellOnCooldown("Exsanguinate") && WoW.IsSpellInRange("Garrote") && WoW.Talent(6) == 3)
                        {
                            WoW.CastSpell("Exsanguinate");
                            return;
                        }
                        if (WoW.Energy >= 35 && WoW.CurrentComboPoints == 4 && WoW.TargetHealthPercent <= 35 && WoW.CanCast("Envenom"))
                        {
                            WoW.CastSpell("Envenom");
                            return;
                        }
                        if (WoW.Energy >= 35 && WoW.CurrentComboPoints == 5 && WoW.TargetHealthPercent <= 35 && WoW.CanCast("Envenom"))
                        {
                            WoW.CastSpell("Envenom");
                            return;
                        }
                        if (WoW.Energy >= 25 && WoW.CurrentComboPoints == 4 && WoW.TargetHealthPercent >= 36 && WoW.CanCast("Rupture") && !WoW.TargetHasDebuff("Rupture"))
                        {
                            WoW.CastSpell("Rupture");
                            return;
                        }
                        if (WoW.Energy >= 25 && WoW.CurrentComboPoints == 5 && WoW.TargetHealthPercent >= 36 && WoW.CanCast("Rupture") && !WoW.TargetHasDebuff("Rupture"))
                        {
                            WoW.CastSpell("Rupture");
                            return;
                        }
                        if (WoW.Energy >= 35 && WoW.CurrentComboPoints >= 4 && WoW.TargetHealthPercent >= 36 && WoW.TargetHasDebuff("Rupture") && WoW.CanCast("Envenom"))
                        {
                            WoW.CastSpell("Envenom");
                            return;
                        }
                        if (WoW.CanCast("Garrote") && WoW.Energy >= 45 && !WoW.TargetHasDebuff("Garrote") && !WoW.IsSpellOnCooldown("Garrote") && WoW.CurrentComboPoints <= 4 && WoW.IsSpellInRange("Garrote"))
                        {
                            WoW.CastSpell("Garrote");
                            return;
                        }
                        if (UseCooldowns && WoW.CanCast("Berserk") && !WoW.IsSpellOnCooldown("Berserk"))
                        {
                            WoW.CastSpell("Berserk");
                            return;
                        }
                    }
                }
            }
        }
Exemplo n.º 6
0
        public override void Pulse() // Updated for Legion (tested and working for single target)
        {
            if (WoW.CanCast("Healthstone") && WoW.ItemCount("Healthstone") >= 1 && !WoW.ItemOnCooldown("Healthstone") && WoW.HealthPercent <= 60 && WoW.HealthPercent != 0 && WoW.IsInCombat)
            {
                WoW.CastSpell("Healthstone");
                return;
            }
            if (combatRoutine.Type == RotationType.SingleTarget) // Do Single Target Stuff here
            {
                if (WoW.HasTarget && WoW.TargetIsEnemy && WoW.IsInCombat && !WoW.PlayerIsCasting && !WoW.IsMounted)
                {
                    if ((!WoW.TargetHasDebuff("Agony") || WoW.TargetDebuffTimeRemaining("Agony") <= 540) &&
                        (!WoW.PlayerIsChanneling || WoW.TargetDebuffTimeRemaining("Agony") <= 150) &&
                        WoW.CanCast("Agony") &&
                        WoW.IsSpellInRange("Agony"))
                    {
                        WoW.CastSpell("Agony");
                        return;
                    }
                    if ((WoW.CurrentSoulShards >= 3 || (WoW.CurrentSoulShards >= 2 && WoW.WasLastCasted("Unstable Affliction"))) &&
                        !WoW.IsMoving &&
                        WoW.CanCast("Unstable Affliction") &&
                        WoW.IsSpellInRange("Agony") && WoW.TargetHasDebuff("Agony") && WoW.TargetHasDebuff("Corruption"))
                    {
                        WoW.CastSpell("Unstable Affliction");
                        Thread.Sleep(200);
                        return;
                    }
                    if ((WoW.TargetHasDebuff("Unstable Affliction1") && WoW.TargetHasDebuff("Unstable Affliction2") ||
                         WoW.TargetHasDebuff("Unstable Affliction1") && WoW.TargetHasDebuff("Unstable Affliction3") ||
                         WoW.TargetHasDebuff("Unstable Affliction1") && WoW.TargetHasDebuff("Unstable Affliction4") ||
                         WoW.TargetHasDebuff("Unstable Affliction1") && WoW.TargetHasDebuff("Unstable Affliction5") ||
                         WoW.TargetHasDebuff("Unstable Affliction2") && WoW.TargetHasDebuff("Unstable Affliction3") ||
                         WoW.TargetHasDebuff("Unstable Affliction2") && WoW.TargetHasDebuff("Unstable Affliction4") ||
                         WoW.TargetHasDebuff("Unstable Affliction2") && WoW.TargetHasDebuff("Unstable Affliction5") ||
                         WoW.TargetHasDebuff("Unstable Affliction3") && WoW.TargetHasDebuff("Unstable Affliction4") ||
                         WoW.TargetHasDebuff("Unstable Affliction3") && WoW.TargetHasDebuff("Unstable Affliction5") ||
                         WoW.TargetHasDebuff("Unstable Affliction4") && WoW.TargetHasDebuff("Unstable Affliction5") ||
                         WoW.PlayerBuffStacks("Reap Souls") >= 12) &&
                        !WoW.PlayerIsCasting &&
                        WoW.CanCast("Reap Souls") &&
                        !WoW.PlayerHasBuff("Deadwind Harvester") &&
                        WoW.PlayerHasBuff("Tormented Souls") && WoW.TargetHasDebuff("Agony") && WoW.TargetHasDebuff("Corruption"))
                    {
                        WoW.CastSpell("Reap Souls");
                        return;
                    }
                    if (WoW.CanCast("Phantom") && WoW.IsSpellInRange("Agony") && !WoW.PlayerIsChanneling && !WoW.PlayerIsCasting && !WoW.IsMoving && WoW.TargetHasDebuff("Agony") && WoW.TargetHasDebuff("Corruption"))
                    {
                        WoW.CastSpell("Phantom");
                        return;
                    }

                    /*if (WoW.IsSpellInRange("Agony") && WoW.CanCast("Trinket") &&!WoW.ItemOnCooldown("Trinket") && WoW.TargetHasDebuff("Agony") && WoW.TargetHasDebuff("Corruption"))
                     * {
                     *      WoW.CastSpell("Trinket");
                     *      return;
                     * }*/
                    if (WoW.CanCast("Berserk") && UseCooldowns && !WoW.IsSpellOnCooldown("Berserk") && WoW.PlayerRace == "Troll")
                    {
                        WoW.CastSpell("Berserk");
                        return;
                    }
                    if (WoW.CanCast("Life Tap") && !WoW.PlayerIsChanneling && WoW.Talent(2) == 3 && !WoW.PlayerHasBuff("Empowered Life Tap"))
                    {
                        WoW.CastSpell("Life Tap");
                        return;
                    }
                    if ((!WoW.TargetHasDebuff("Corruption") || WoW.TargetDebuffTimeRemaining("Corruption") <= 420) &&
                        (!WoW.PlayerIsChanneling || WoW.TargetDebuffTimeRemaining("Corruption") <= 150) &&
                        WoW.CanCast("Corruption") &&
                        WoW.IsSpellInRange("Agony"))
                    {
                        WoW.CastSpell("Corruption");
                        return;
                    }
                    if ((!WoW.TargetHasDebuff("Siphon Life") || WoW.TargetDebuffTimeRemaining("Siphon Life") <= 420) &&
                        (!WoW.PlayerIsChanneling || WoW.TargetDebuffTimeRemaining("Siphon Life") <= 150) &&
                        WoW.Talent(4) == 1 &&
                        WoW.CanCast("Siphon Life") &&
                        WoW.IsSpellInRange("Agony") && WoW.TargetHasDebuff("Agony") && WoW.TargetHasDebuff("Corruption"))
                    {
                        WoW.CastSpell("Siphon Life");
                        return;
                    }
                    if (WoW.CanCast("Unstable Affliction") && WoW.TargetHasDebuff("Agony") && WoW.TargetHasDebuff("Corruption") && !WoW.IsMoving && WoW.Talent(2) == 1 && !WoW.IsMoving && WoW.IsSpellInRange("Unstable Affliction") && !WoW.PlayerIsChanneling && WoW.CurrentSoulShards >= 1 &&
                        (!WoW.TargetHasDebuff("Unstable Affliction1") || !WoW.TargetHasDebuff("Unstable Affliction2") || !WoW.TargetHasDebuff("Unstable Affliction3") || !WoW.TargetHasDebuff("Unstable Affliction4") || !WoW.TargetHasDebuff("Unstable Affliction5") ||
                         (WoW.TargetDebuffTimeRemaining("Unstable Affliction1") <= 150) || (WoW.TargetDebuffTimeRemaining("Unstable Affliction2") <= 150) || (WoW.TargetDebuffTimeRemaining("Unstable Affliction3") <= 150) ||
                         (WoW.TargetDebuffTimeRemaining("Unstable Affliction4") <= 150) || (WoW.TargetDebuffTimeRemaining("Unstable Affliction5") <= 150)))
                    {
                        WoW.CastSpell("Unstable Affliction");
                        Thread.Sleep(200);
                        return;
                    }
                    if (WoW.IsInCombat && WoW.Mana < 70 && WoW.HealthPercent > 70 && WoW.CanCast("Life Tap"))
                    {
                        WoW.CastSpell("Life Tap");
                        return;
                    }
                    if (WoW.CanCast("Drain Soul") && WoW.IsSpellInRange("Agony") && !WoW.PlayerIsChanneling && !WoW.PlayerIsCasting && !WoW.IsMoving && WoW.TargetHasDebuff("Agony") && WoW.TargetHasDebuff("Corruption"))
                    {
                        WoW.CastSpell("Drain Soul");
                        return;
                    }
                }
            }
            if (combatRoutine.Type == RotationType.AOE)
            {
                if (WoW.HasTarget && WoW.TargetIsEnemy && WoW.IsInCombat && !WoW.PlayerIsChanneling && !WoW.PlayerIsCasting && !WoW.IsMounted) // Do AOE stuff here
                {
                    if (WoW.CanCast("Agony") && WoW.IsSpellInRange("Agony") && WoW.TargetHasDebuff("Seed of Corruption") && (!WoW.TargetHasDebuff("Agony") || (WoW.TargetDebuffTimeRemaining("Agony") <= 540)))
                    {
                        WoW.CastSpell("Agony");
                        return;
                    }

                    if (WoW.CanCast("Corruption") && WoW.IsSpellInRange("Agony") && WoW.TargetHasDebuff("Seed of Corruption") && (!WoW.TargetHasDebuff("Corruption") || (WoW.TargetDebuffTimeRemaining("Corruption") <= 420)))
                    {
                        WoW.CastSpell("Corruption");
                        return;
                    }
                    if (WoW.CanCast("Seed of Corruption") && WoW.IsSpellInRange("Agony") && !WoW.TargetHasDebuff("Seed of Corruption") && !WoW.IsMoving && WoW.CurrentSoulShards >= 1 && !WoW.WasLastCasted("Seed of Corruption"))
                    {
                        WoW.CastSpell("Seed of Corruption");
                        return;
                    }
                    if (WoW.CanCast("Drain Soul") && WoW.IsSpellInRange("Agony") && !WoW.PlayerIsChanneling && !WoW.PlayerIsCasting && !WoW.IsMoving && WoW.TargetHasDebuff("Agony") && WoW.TargetHasDebuff("Corruption"))
                    {
                        WoW.CastSpell("Drain Soul");
                        return;
                    }
                }
            }
        }
        public override void Pulse() // Updated for Legion (tested and working for single target)
        {
            if (WoW.IsInCombat && Control.IsKeyLocked(Keys.Scroll) && !WoW.TargetIsPlayer && !WoW.IsMounted)
            {
                SelectRotation(4, 9999, 1);
            }

            //Dark Pact
            if (WoW.CanCast("Dark Pact") &&
                WoW.Talent(5) == 3 &&
                WoW.HealthPercent <= 30 &&
                !WoW.IsMounted)
            {
                WoW.CastSpell("Dark Pact");
                return;
            }

            //Shadowfury
            if (DetectKeyPress.GetKeyState(DetectKeyPress.VK_LMENU) < 0 &&
                WoW.Talent(3) == 3 &&
                !WoW.IsMoving &&
                WoW.CanCast("Shadowfury"))
            {
                WoW.CastSpell("Shadowfury");
                return;
            }

            if (UseCooldowns)
            {
                if (WoW.HasTarget && WoW.TargetIsEnemy && !WoW.PlayerIsChanneling && WoW.IsInCombat && !WoW.PlayerIsCasting && !WoW.IsMounted)
                {
                    //Doomguard
                    if (WoW.CanCast("Doomguard") &&
                        (WoW.Talent(6) == 0 || WoW.Talent(6) == 2 || WoW.Talent(6) == 3) &&
                        WoW.CurrentSoulShards >= 1 &&
                        WoW.IsSpellInRange("Doom"))
                    {
                        WoW.CastSpell("Doomguard");
                        return;
                    }

                    //Grimoire of Service
                    if (WoW.CanCast("Grimoire: Felguard") &&
                        WoW.Talent(6) == 2 &&
                        WoW.CurrentSoulShards >= 1 &&
                        WoW.IsSpellInRange("Doom"))
                    {
                        WoW.CastSpell("Grimoire: Felguard");
                        return;
                    }

                    //Soul Harvest
                    if (WoW.CanCast("Soul Harvest") &&
                        WoW.Talent(4) == 3 &&
                        !WoW.IsMoving &&
                        WoW.IsSpellInRange("Doom") &&
                        (WoW.PlayerHasBuff("Bloodlust") || WoW.PlayerHasBuff("Time Warp") || WoW.PlayerHasBuff("Netherwinds") || WoW.PlayerHasBuff("Drums of War") || WoW.PlayerHasBuff("Heroism")))
                    {
                        WoW.CastSpell("Soul Harvest");
                        return;
                    }
                }
            }

            if (combatRoutine.Type == RotationType.SingleTarget) // Do Single Target Stuff here
            {
                if (WoW.HasTarget && WoW.TargetIsEnemy && !WoW.PlayerIsChanneling && WoW.IsInCombat && !WoW.PlayerIsCasting && !WoW.IsMounted)
                {
                    if ((!WoW.TargetHasDebuff("Doom") || WoW.TargetDebuffTimeRemaining("Doom") <= 150) &&
                        WoW.CanCast("Doom") &&
                        WoW.IsSpellInRange("Doom"))
                    {
                        WoW.CastSpell("Doom");
                        return;
                    }

                    if (WoW.CanCast("Darkglare") &&
                        WoW.Talent(7) == 1 &&
                        WoW.CurrentSoulShards >= 1 &&
                        WoW.IsSpellInRange("Doom"))
                    {
                        WoW.CastSpell("Darkglare");
                        return;
                    }

                    if (WoW.CanCast("Call Dreadstalkers") &&
                        (WoW.CurrentSoulShards >= 2 || WoW.TargetHasDebuff("Demonic Calling")) &&
                        WoW.IsSpellInRange("Doom") &&
                        !WoW.IsMoving)
                    {
                        WoW.CastSpell("Call Dreadstalkers");
                        return;
                    }

                    if (WoW.CanCast("Hand of Guldan") &&
                        WoW.CurrentSoulShards >= 4 &&
                        WoW.IsSpellInRange("Doom") &&
                        !WoW.IsMoving)
                    {
                        WoW.CastSpell("Hand of Guldan");
                        return;
                    }

                    if (WoW.CanCast("Demonic Empowerment") &&
                        !WoW.IsMoving &&
                        !WoW.WasLastCasted("Demonic Empowerment") &&
                        (!WoW.PetHasBuff("Demonic Empowerment") || WoW.PetBuffTimeRemaining("Demonic Empowerment") <= 1.5 ||
                         WoW.WasLastCasted("Call Dreadstalkers") || WoW.WasLastCasted("Grimoire: Felguard") || WoW.WasLastCasted("Doomguard") || WoW.WasLastCasted("Hand of Guldan")))
                    {
                        WoW.CastSpell("Demonic Empowerment");
                        Thread.Sleep(1000);
                        return;
                    }

                    if (WoW.CanCast("Talkiels Consumption") &&
                        WoW.PetHasBuff("Demonic Empowerment") &&
                        WoW.PetBuffTimeRemaining("Demonic Empowerment") >= 2 &&
                        WoW.DreadstalkersCount >= 1 &&
                        WoW.IsSpellInRange("Doom") &&
                        !WoW.IsMoving)
                    {
                        WoW.CastSpell("Talkiels Consumption");
                        return;
                    }

                    if (WoW.CanCast("Felstorm") &&
                        WoW.PetHasBuff("Demonic Empowerment") &&
                        WoW.PetBuffTimeRemaining("Demonic Empowerment") >= 6 &&
                        WoW.IsSpellInRange("Doom"))
                    {
                        WoW.CastSpell("Felstorm");
                        return;
                    }

                    if (WoW.CanCast("Shadowflame") &&
                        WoW.Talent(1) == 2 &&
                        !WoW.TargetHasDebuff("Shadowflame") &&
                        WoW.CanCast("Shadowflame") &&
                        WoW.IsSpellInRange("Doom"))
                    {
                        WoW.CastSpell("Shadowflame");
                        return;
                    }

                    if (WoW.CanCast("Life Tap") &&
                        WoW.Mana < 60 &&
                        WoW.HealthPercent > 50)
                    {
                        WoW.CastSpell("Life Tap");
                        return;
                    }

                    if (WoW.CanCast("Demonwrath") &&
                        WoW.Mana > 60 &&
                        WoW.IsMoving)
                    {
                        WoW.CastSpell("Demonwrath");
                        return;
                    }

                    if ((WoW.CanCast("Shadow Bolt") || WoW.CanCast("Demonbolt")) &&
                        WoW.IsSpellInRange("Doom") &&
                        !WoW.IsMoving)
                    {
                        WoW.CastSpell("Shadow Bolt");
                        WoW.CastSpell("Demonbolt");
                        return;
                    }
                }
            }
            if (combatRoutine.Type == RotationType.AOE)
            {
                if (WoW.HasTarget && WoW.TargetIsEnemy && !WoW.PlayerIsChanneling && WoW.IsInCombat && !WoW.PlayerIsCasting && !WoW.IsMounted)
                {
                    if (WoW.CanCast("Hand of Guldan") &&
                        WoW.CurrentSoulShards >= 4 &&
                        WoW.IsSpellInRange("Doom") &&
                        !WoW.IsMoving)
                    {
                        WoW.CastSpell("Hand of Guldan");
                        return;
                    }

                    if (WoW.CanCast("Implosion") &&
                        WoW.Talent(2) == 3 &&
                        WoW.WildImpsCount >= 1 &&
                        WoW.IsSpellInRange("Doom"))
                    {
                        WoW.CastSpell("Implosion");
                        return;
                    }

                    if (WoW.CanCast("Darkglare") &&
                        WoW.Talent(7) == 1 &&
                        WoW.CurrentSoulShards >= 1 &&
                        WoW.IsSpellInRange("Doom"))
                    {
                        WoW.CastSpell("Darkglare");
                        return;
                    }

                    if (WoW.CanCast("Demonic Empowerment") &&
                        WoW.CanCast("Felstorm") &&
                        !WoW.IsMoving &&
                        !WoW.WasLastCasted("Demonic Empowerment") &&
                        (!WoW.PetHasBuff("Demonic Empowerment") || WoW.PetBuffTimeRemaining("Demonic Empowerment") <= 6))
                    {
                        WoW.CastSpell("Demonic Empowerment");
                        Thread.Sleep(2000);
                        return;
                    }

                    if (WoW.CanCast("Felstorm") &&
                        WoW.PetHasBuff("Demonic Empowerment") &&
                        WoW.PetBuffTimeRemaining("Demonic Empowerment") >= 6 &&
                        WoW.IsSpellInRange("Doom"))
                    {
                        WoW.CastSpell("Felstorm");
                        return;
                    }

                    if (WoW.CanCast("Life Tap") &&
                        WoW.Mana < 60 &&
                        WoW.HealthPercent > 50)
                    {
                        WoW.CastSpell("Life Tap");
                        return;
                    }

                    if (WoW.CanCast("Demonwrath") &&
                        WoW.Mana > 60)
                    {
                        WoW.CastSpell("Demonwrath");
                        return;
                    }
                }
            }

            if (combatRoutine.Type == RotationType.SingleTargetCleave)
            {
                // Do Single Target Cleave stuff here if applicable else ignore this one
            }
        }
        public override void Pulse()
        {
            if (combatRoutine.Type == RotationType.SingleTarget) // Do Single Target Stuff here
            {
                if (WoW.HasTarget && WoW.TargetIsEnemy && WoW.IsInCombat)
                {
                    if (WoW.PlayerHasBuff("Stealth") || WoW.PlayerHasBuff("Subterfuge") || WoW.PlayerHasBuff("Shadow Dance"))
                    {
                        if (WoW.CanCast("Symbols of Death") && WoW.Energy >= 35 && (!WoW.PlayerHasBuff("Symbols of Death") || WoW.PlayerBuffTimeRemaining("Symbols of Death") <= 10))
                        {
                            WoW.CastSpell("Symbols of Death");
                            return;
                        }

                        /*	if (WoW.CanCast("Shadow Blades") && WoW.Cooldown && WoW.HasBuff("Symbols of Death"))
                         *  {
                         *
                         *      WoW.CastSpellByName("Shadow Blades");
                         *      return;
                         *  } */

                        /*	if(WoW.CanCast("Goremaw's Bite") && WoW.CurrentComboPoints <= 3 && WoW.IsSpellInRange("Goremaw's Bite"))
                         *  {
                         *
                         *      WoW.CastSpellByName("Goremaw's Bite");
                         *      return;
                         *  } */

                        if (WoW.CanCast("Nightblade") && WoW.CurrentComboPoints >= 5 && WoW.Energy >= 25 &&
                            (!WoW.TargetHasDebuff("Nightblade") || WoW.TargetDebuffTimeRemaining("Nightblade") <= 4) && WoW.IsSpellInRange("Nightblade"))
                        {
                            WoW.CastSpell("Nightblade");
                            return;
                        }

                        if (WoW.CanCast("Eviscerate") && WoW.CurrentComboPoints >= 5 && WoW.Energy >= 35 && WoW.TargetHasDebuff("Nightblade") && WoW.IsSpellInRange("Eviscerate"))

                        {
                            WoW.CastSpell("Eviscerate");
                            return;
                        }

                        if (WoW.CanCast("Shadowstrike") && WoW.CurrentComboPoints < 6 && WoW.Energy >= 40 && WoW.IsSpellInRange("Shadowstrike"))
                        {
                            WoW.CastSpell("Shadowstrike");
                            return;
                        }
                    }


                    if (WoW.CanCast("Shadow Blades") && WoW.HasTarget && WoW.PlayerHasBuff("Symbols of Death") && WoW.IsSpellInRange("Eviscerate"))
                    {
                        WoW.CastSpell("Shadow Blades");
                        return;
                    }

                    if (WoW.CanCast("Shadow Dance") && (!WoW.PlayerHasBuff("Stealth") || !WoW.PlayerHasBuff("Shadow Dance") || !WoW.PlayerHasBuff("Subterfuge")) && WoW.Energy >= 55 &&
                        (WoW.PlayerSpellCharges("Shadow Dance") == 3 && WoW.CurrentComboPoints <= 3 || WoW.PlayerSpellCharges("Shadow Dance") == 2 && WoW.CurrentComboPoints <= 1) &&
                        WoW.IsSpellInRange("Eviscerate"))
                    {
                        WoW.CastSpell("Shadow Dance");
                        return;
                    }

                    if (WoW.CanCast("Goremaw's Bite") && WoW.CurrentComboPoints <= 2 && WoW.Energy <= 50 && WoW.IsSpellInRange("Goremaw's Bite") && WoW.IsSpellInRange("Eviscerate"))
                    {
                        WoW.CastSpell("Goremaw's Bite");
                        return;
                    }

                    if (WoW.CanCast("Nightblade") && WoW.CurrentComboPoints >= 5 && WoW.Energy >= 25 && (!WoW.TargetHasDebuff("Nightblade") || WoW.TargetDebuffTimeRemaining("Nightblade") <= 4) &&
                        WoW.IsSpellInRange("Eviscerate"))
                    {
                        WoW.CastSpell("Nightblade");
                        return;
                    }

                    if (WoW.CanCast("Eviscerate") && WoW.CurrentComboPoints >= 5 && WoW.Energy >= 35 && WoW.TargetHasDebuff("Nightblade") && WoW.IsSpellInRange("Eviscerate"))
                    {
                        WoW.CastSpell("Eviscerate");
                        return;
                    }

                    if (WoW.CanCast("Backstab") && WoW.CurrentComboPoints < 6 && WoW.Energy >= 55 && WoW.IsSpellInRange("Eviscerate"))
                    {
                        WoW.CastSpell("Backstab");
                        return;
                    }
                }
            }

            if (combatRoutine.Type == RotationType.AOE || combatRoutine.Type == RotationType.SingleTargetCleave) // Do AoE Target Stuff here
            {
                if ((WoW.HasTarget || UseCooldowns) && WoW.TargetIsEnemy && WoW.IsInCombat)
                {
                    if (WoW.PlayerHasBuff("Stealth") || WoW.PlayerHasBuff("Subterfuge") || WoW.PlayerHasBuff("Shadow Dance"))
                    {
                        if (WoW.CanCast("Symbols of Death") && WoW.Energy >= 35 && (!WoW.PlayerHasBuff("Symbols of Death") || WoW.PlayerBuffTimeRemaining("Symbols of Death") <= 10))
                        {
                            WoW.CastSpell("Symbols of Death");
                            return;
                        }

                        /*	if (WoW.CanCast("Shadow Blades") && WoW.Cooldown && WoW.HasBuff("Symbols of Death"))
                         *  {
                         *
                         *      WoW.CastSpellByName("Shadow Blades");
                         *      return;
                         *  } */

                        /*	if(WoW.CanCast("Goremaw's Bite") && WoW.CurrentComboPoints <= 3 && WoW.IsSpellInRange("Goremaw's Bite"))
                         *  {
                         *
                         *      WoW.CastSpellByName("Goremaw's Bite");
                         *      return;
                         *  } */

                        if (WoW.CanCast("Nightblade") && WoW.CurrentComboPoints >= 5 && WoW.Energy >= 25 &&
                            (!WoW.TargetHasDebuff("Nightblade") || WoW.TargetDebuffTimeRemaining("Nightblade") <= 4) && WoW.IsSpellInRange("Nightblade"))
                        {
                            WoW.CastSpell("Nightblade");
                            return;
                        }

                        if (WoW.CanCast("Eviscerate") && WoW.CurrentComboPoints >= 5 && WoW.Energy >= 35 && WoW.TargetHasDebuff("Nightblade") && WoW.IsSpellInRange("Eviscerate"))

                        {
                            WoW.CastSpell("Eviscerate");
                            return;
                        }

                        if (WoW.CanCast("Shadowstrike") && WoW.CurrentComboPoints < 6 && WoW.Energy >= 40 && WoW.IsSpellInRange("Shadowstrike"))
                        {
                            WoW.CastSpell("Shadowstrike");
                            return;
                        }

                        if (WoW.CanCast("Shuriken Storm") && WoW.CurrentComboPoints < 6 && WoW.Energy >= 35 && WoW.IsSpellInRange("Eviscerate"))
                        {
                            WoW.CastSpell("Shuriken Storm");
                            return;
                        }
                    }


                    if (WoW.CanCast("Shadow Blades") && WoW.HasTarget && WoW.PlayerHasBuff("Symbols of Death") && WoW.IsSpellInRange("Eviscerate"))
                    {
                        WoW.CastSpell("Shadow Blades");
                        return;
                    }

                    if (WoW.CanCast("Shadow Dance") && (!WoW.PlayerHasBuff("Stealth") || !WoW.PlayerHasBuff("Shadow Dance") || !WoW.PlayerHasBuff("Subterfuge")) &&
                        (WoW.PlayerSpellCharges("Shadow Dance") == 3 && WoW.CurrentComboPoints <= 3 || WoW.PlayerSpellCharges("Shadow Dance") == 2 && WoW.CurrentComboPoints <= 1) &&
                        WoW.IsSpellInRange("Eviscerate"))
                    {
                        WoW.CastSpell("Shadow Dance");
                        return;
                    }

                    if (WoW.CanCast("Goremaw's Bite") && WoW.CurrentComboPoints <= 2 && WoW.Energy <= 50 && WoW.IsSpellInRange("Goremaw's Bite") && WoW.IsSpellInRange("Eviscerate"))
                    {
                        WoW.CastSpell("Goremaw's Bite");
                        return;
                    }

                    if (WoW.CanCast("Nightblade") && WoW.CurrentComboPoints >= 5 && WoW.Energy >= 25 && (!WoW.TargetHasDebuff("Nightblade") || WoW.TargetDebuffTimeRemaining("Nightblade") <= 4) &&
                        WoW.IsSpellInRange("Eviscerate"))
                    {
                        WoW.CastSpell("Nightblade");
                        return;
                    }

                    if (WoW.CanCast("Eviscerate") && WoW.CurrentComboPoints >= 5 && WoW.Energy >= 35 && WoW.TargetHasDebuff("Nightblade") && WoW.IsSpellInRange("Eviscerate"))
                    {
                        WoW.CastSpell("Eviscerate");
                        return;
                    }

                    if (WoW.CanCast("Shuriken Storm") && WoW.CurrentComboPoints < 6 && WoW.Energy >= 35 && WoW.IsSpellInRange("Eviscerate"))
                    {
                        WoW.CastSpell("Shuriken Storm");
                    }
                }
            }
        }
        public override void Pulse() // Updated for Legion (tested and working for single target)
        {
            if (WoW.IsInCombat && Control.IsKeyLocked(Keys.Scroll) && !WoW.TargetIsPlayer && !WoW.IsMounted)
            {
                SelectRotation(4, 9999, 1);
            }

            if (combatRoutine.Type == RotationType.SingleTarget) // Do Single Target Stuff here
            {
                if (WoW.HasTarget && WoW.TargetIsEnemy && WoW.IsInCombat && !WoW.PlayerIsCasting && !WoW.IsMounted)
                {
                    if ((!WoW.TargetHasDebuff("Agony") || WoW.TargetDebuffTimeRemaining("Agony") <= 540) &&
                        (!WoW.PlayerIsChanneling || WoW.TargetDebuffTimeRemaining("Agony") <= 150) &&
                        WoW.CanCast("Agony") &&
                        WoW.IsSpellInRange("Agony"))
                    {
                        WoW.CastSpell("Agony");
                        return;
                    }

                    if ((WoW.CurrentSoulShards >= 3 || (WoW.CurrentSoulShards >= 2 && WoW.WasLastCasted("Unstable Affliction"))) &&
                        !WoW.IsMoving &&
                        WoW.CanCast("Unstable Affliction") &&
                        WoW.IsSpellInRange("Agony"))
                    {
                        WoW.CastSpell("Unstable Affliction");
                        Thread.Sleep(200);
                        return;
                    }

                    if ((WoW.TargetHasDebuff("Unstable Affliction1") && WoW.TargetHasDebuff("Unstable Affliction2") ||
                         WoW.TargetHasDebuff("Unstable Affliction1") && WoW.TargetHasDebuff("Unstable Affliction3") ||
                         WoW.TargetHasDebuff("Unstable Affliction1") && WoW.TargetHasDebuff("Unstable Affliction4") ||
                         WoW.TargetHasDebuff("Unstable Affliction1") && WoW.TargetHasDebuff("Unstable Affliction5") ||
                         WoW.TargetHasDebuff("Unstable Affliction2") && WoW.TargetHasDebuff("Unstable Affliction3") ||
                         WoW.TargetHasDebuff("Unstable Affliction2") && WoW.TargetHasDebuff("Unstable Affliction4") ||
                         WoW.TargetHasDebuff("Unstable Affliction2") && WoW.TargetHasDebuff("Unstable Affliction5") ||
                         WoW.TargetHasDebuff("Unstable Affliction3") && WoW.TargetHasDebuff("Unstable Affliction4") ||
                         WoW.TargetHasDebuff("Unstable Affliction3") && WoW.TargetHasDebuff("Unstable Affliction5") ||
                         WoW.TargetHasDebuff("Unstable Affliction4") && WoW.TargetHasDebuff("Unstable Affliction5") ||
                         WoW.PlayerBuffStacks("Reap Souls") >= 12) &&
                        !WoW.PlayerIsCasting &&
                        WoW.CanCast("Reap Souls") &&
                        !WoW.PlayerHasBuff("Deadwind Harvester") &&
                        WoW.PlayerHasBuff("Tormented Souls"))
                    {
                        WoW.CastSpell("Reap Souls");
                        return;
                    }

                    if (WoW.CanCast("Life Tap") && !WoW.PlayerIsChanneling && WoW.Talent(2) == 3 && !WoW.PlayerHasBuff("Empowered Life Tap"))
                    {
                        WoW.CastSpell("Life Tap");
                        return;
                    }

                    if ((!WoW.TargetHasDebuff("Corruption") || WoW.TargetDebuffTimeRemaining("Corruption") <= 420) &&
                        (!WoW.PlayerIsChanneling || WoW.TargetDebuffTimeRemaining("Corruption") <= 150) &&
                        WoW.CanCast("Corruption") &&
                        WoW.IsSpellInRange("Agony"))
                    {
                        WoW.CastSpell("Corruption");
                        return;
                    }

                    if ((!WoW.TargetHasDebuff("Siphon Life") || WoW.TargetDebuffTimeRemaining("Siphon Life") <= 420) &&
                        (!WoW.PlayerIsChanneling || WoW.TargetDebuffTimeRemaining("Siphon Life") <= 150) &&
                        WoW.Talent(4) == 1 &&
                        WoW.CanCast("Siphon Life") &&
                        WoW.IsSpellInRange("Agony"))
                    {
                        WoW.CastSpell("Siphon Life");
                        return;
                    }

                    if (WoW.CanCast("Felhunter") && WoW.Talent(6) == 2 && !WoW.IsSpellOnCooldown("Felhunter") && WoW.IsSpellInRange("Agony") && !WoW.PlayerIsChanneling && !WoW.PlayerIsCasting)
                    {
                        WoW.CastSpell("Felhunter");
                        return;
                    }

                    if (WoW.CanCast("Unstable Affliction") && !WoW.IsMoving && WoW.Talent(2) == 1 && !WoW.IsMoving && WoW.IsSpellInRange("Unstable Affliction") && !WoW.PlayerIsChanneling && WoW.CurrentSoulShards >= 1 &&
                        (!WoW.TargetHasDebuff("Unstable Affliction1") || !WoW.TargetHasDebuff("Unstable Affliction2") || !WoW.TargetHasDebuff("Unstable Affliction3") || !WoW.TargetHasDebuff("Unstable Affliction4") || !WoW.TargetHasDebuff("Unstable Affliction5") ||
                         (WoW.TargetDebuffTimeRemaining("Unstable Affliction1") <= 150) || (WoW.TargetDebuffTimeRemaining("Unstable Affliction2") <= 150) || (WoW.TargetDebuffTimeRemaining("Unstable Affliction3") <= 150) ||
                         (WoW.TargetDebuffTimeRemaining("Unstable Affliction4") <= 150) || (WoW.TargetDebuffTimeRemaining("Unstable Affliction5") <= 150)))
                    {
                        WoW.CastSpell("Unstable Affliction");
                        Thread.Sleep(200);
                        return;
                    }

                    if (WoW.IsInCombat && WoW.Mana < 70 && WoW.HealthPercent > 70 && WoW.CanCast("Life Tap"))
                    {
                        WoW.CastSpell("Life Tap");
                        return;
                    }

                    if (WoW.CanCast("Haunt") && WoW.Talent(1) == 1 && !WoW.IsSpellOnCooldown("Haunt") && WoW.IsSpellInRange("Agony") && !WoW.PlayerIsChanneling && !WoW.PlayerIsCasting && !WoW.IsMoving)
                    {
                        WoW.CastSpell("Haunt");
                        return;
                    }

                    if (WoW.CanCast("Drain Soul") && WoW.IsSpellInRange("Agony") && !WoW.PlayerIsChanneling && !WoW.PlayerIsCasting && !WoW.IsMoving)
                    {
                        WoW.CastSpell("Drain Soul");
                        return;
                    }
                }
            }
            if (combatRoutine.Type == RotationType.AOE)
            {
                if (WoW.HasTarget && WoW.TargetIsEnemy && WoW.IsInCombat && !WoW.PlayerIsChanneling && !WoW.PlayerIsCasting && !WoW.IsMounted) // Do AOE stuff here
                {
                    if (WoW.CanCast("Agony") && WoW.IsSpellInRange("Agony") && WoW.TargetHasDebuff("Seed of Corruption") && (!WoW.TargetHasDebuff("Agony") || (WoW.TargetDebuffTimeRemaining("Agony") <= 540)))
                    {
                        WoW.CastSpell("Agony");
                        return;
                    }

                    if (WoW.CanCast("Corruption") && WoW.IsSpellInRange("Agony") && WoW.TargetHasDebuff("Seed of Corruption") && (!WoW.TargetHasDebuff("Corruption") || (WoW.TargetDebuffTimeRemaining("Corruption") <= 420)))
                    {
                        WoW.CastSpell("Corruption");
                        return;
                    }

                    if (WoW.CanCast("Seed of Corruption") && WoW.IsSpellInRange("Agony") && !WoW.TargetHasDebuff("Seed of Corruption") && !WoW.IsMoving && WoW.CurrentSoulShards >= 1)
                    {
                        WoW.CastSpell("Seed of Corruption");
                        return;
                    }
                }
            }
            if (combatRoutine.Type == RotationType.SingleTargetCleave)
            {
                // Do Single Target Cleave stuff here if applicable else ignore this one
            }
        }
Exemplo n.º 10
0
        public override void Pulse()
        {
            //Talent Checker
            string currentTalents = WoW.Talent(1) + "" + WoW.Talent(2) + "" + WoW.Talent(3) + "" + WoW.Talent(4) + "" + WoW.Talent(5) + "" + WoW.Talent(6) + "" + WoW.Talent(7);

            if (WoW.Talent(3) != 2 && WoW.Talent(3) != 1)
            {
                Log.Write("Talents are not 1322322", Color.Green);
                return;
            }


            if (combatRoutine.Type == RotationType.SingleTarget)             // Do Single Target Stuff here
            {
                //Build one: Rend
                if (WoW.Talent(3) == 2 && WoW.IsSpellInRange("Slam") && WoW.TargetIsEnemy && WoW.IsInCombat && WoW.CountEnemyNPCsInRange < 8)

                {
                    if (WoW.TargetHealthPercent > 20)
                    {
                        if (WoW.CanCast("Rend") &&
                            !WoW.TargetHasDebuff("Rend") || WoW.TargetDebuffTimeRemaining("Rend") <= 30)
                        {
                            WoW.CastSpell("Rend");
                        }

                        if (WoW.CanCast("Colossus Smash") && !WoW.PlayerHasBuff("Shattered Defenses") &&
                            !WoW.IsSpellOnCooldown("Colossus Smash"))
                        {
                            WoW.CastSpell("Colossus Smash");
                        }

                        //MS
                        if (WoW.CanCast("Mortal Strike") && !WoW.IsSpellOnCooldown("Mortal Strike") && WoW.PlayerHasBuff("Shattered Defenses"))
                        {
                            WoW.CastSpell("Mortal Strike");
                        }
                        //Slam
                        if (WoW.CanCast("Slam") && WoW.Rage >= 18 && WoW.IsSpellOnCooldown("Colossus Smash") && !WoW.PlayerHasBuff("Shattered Defenses") && WoW.CountEnemyNPCsInRange == 1)
                        {
                            WoW.CastSpell("Slam");
                            return;
                        }
                        if (WoW.Rage >= 36 && WoW.CountEnemyNPCsInRange >= 2)
                        {
                            if (WoW.CanCast("Cleave") && !WoW.PlayerHasBuff("Cleave") && !WoW.IsSpellOnCooldown("Cleave") && WoW.IsSpellOnCooldown("Colossus Smash") && !WoW.PlayerHasBuff("Shattered Defenses"))
                            {
                                WoW.CastSpell("Cleave");
                                return;
                            }

                            if (WoW.CanCast("Whirlwind") && WoW.IsSpellOnCooldown("Colossus Smash") && !WoW.PlayerHasBuff("Shattered Defenses") && WoW.IsSpellOnCooldown("Cleave"))
                            {
                                WoW.CastSpell("Whirlwind");
                                return;
                            }
                        }
                        if (WoW.CanCast("Execute") && WoW.IsSpellOverlayed("Execute"))
                        {
                            WoW.CastSpell("Execute");
                            return;
                        }
                    }
                    if (WoW.TargetHealthPercent <= 20)
                    {
                        //MS if you have EP x2 and SD
                        if (WoW.CanCast("Mortal Strike") &&
                            !WoW.IsSpellOnCooldown("Mortal Strike") &&
                            WoW.PlayerHasBuff("Shattered Defenses") &&
                            WoW.TargetHasDebuff("Executioner’s Precision") &&
                            WoW.TargetDebuffStacks("Executioner’s Precision") == 2)
                        {
                            WoW.CastSpell("Mortal Strike");
                            return;
                        }
                        //CS if no SD
                        if (WoW.CanCast("Colossus Smash") && !WoW.PlayerHasBuff("Shattered Defenses") &&
                            !WoW.IsSpellOnCooldown("Colossus Smash"))
                        {
                            WoW.CastSpell("Colossus Smash");
                            return;
                        }
                        // Execute
                        if (WoW.CanCast("Execute"))
                        {
                            WoW.CastSpell("Execute");
                            return;
                        }
                        //OP if talented
                    }
                }

                //end of rend
                if (WoW.Talent(5) == 1)
                {
                }
                //Build two: Trauma/FoB


                if (WoW.CountEnemyNPCsInRange >= 8)
                {
                    if (WoW.CanCast("Cleave") && !WoW.PlayerHasBuff("Cleave") && !WoW.IsSpellOnCooldown("Cleave"))
                    {
                        WoW.CastSpell("Cleave");
                        return;
                    }
                    if (WoW.CanCast("Whirlwind") && WoW.Rage > 27 && WoW.IsSpellOnCooldown("Cleave"))
                    {
                        WoW.CastSpell("Whirlwind");
                        return;
                    }
                }
            }

            if (combatRoutine.Type == RotationType.AOE)
            {
                // AOE stuff here
            }
            if (combatRoutine.Type == RotationType.Cleave)
            {
                // Do Single Target Cleave stuff here if applicable else ignore this one
            }
        }
Exemplo n.º 11
0
        // Pulse Rotation
        public override void Pulse()
        {
            if (WoW.CanCast("Moonkin Form") && !WoW.PlayerHasBuff("Moonkin Form") && WoW.HasTarget && WoW.TargetIsEnemy && !WoW.IsMounted && !WoW.PlayerHasBuff("Travel Form") && !WoW.PlayerHasBuff("Bear Form") && !WoW.PlayerHasBuff("Cat Form"))
            {
                WoW.CastSpell("Moonkin Form");
                return;
            }

            if (WoW.CanCast("Celestial Alignment") && WoW.HasBossTarget && WoW.IsInCombat || WoW.CanCast("Celestial Alignment") && WoW.IsInCombat && UseCooldowns)
            {
                WoW.CastSpell("Celestial Alignment");
                return;
            }

            if (combatRoutine.Type == RotationType.SingleTarget)  // Do Single Target Stuff here
            {
                Log.Write("Doing Singletarget", Color.Red);

                if (WoW.HasTarget && WoW.TargetIsEnemy && WoW.IsInCombat)
                {
                    if (WoW.CanCast("Solar Beam") && WoW.TargetIsCastingAndSpellIsInterruptible && WoW.TargetPercentCast > 35)
                    {
                        WoW.CastSpell("Solar Beam");
                        return;
                    }

                    if (WoW.CanCast("Starsurge") && WoW.CurrentAstralPower > 70)
                    {
                        WoW.CastSpell("Starsurge");
                        return;
                    }

                    if (WoW.CanCast("Moonfire") && !WoW.TargetHasDebuff("Moonfire") || WoW.TargetDebuffTimeRemaining("Moonfire") < 300)
                    {
                        WoW.CastSpell("Moonfire");
                        return;
                    }

                    if (WoW.CanCast("Sunfire") && !WoW.TargetHasDebuff("Sunfire") && WoW.LastSpell != "Sunfire" || WoW.TargetDebuffTimeRemaining("Sunfire") < 300)
                    {
                        WoW.CastSpell("Sunfire");
                        return;
                    }

                    if (WoW.CanCast("Lunar Strike") && WoW.LastSpell != "Lunar Strike" && WoW.PlayerBuffTimeRemaining("Lunar Empowerment") > GCD && !WoW.IsMoving || WoW.CanCast("Lunar Strike") && WoW.PlayerBuffTimeRemaining("Lunar Empowerment") > GCD && !WoW.IsMoving && WoW.PlayerBuffStacks("Lunar Empowerment") >= 2)
                    {
                        WoW.CastSpell("Lunar Strike");
                        return;
                    }

                    if (WoW.CanCast("Solar Wrath") && WoW.PlayerBuffTimeRemaining("Solar Empowerment") > GCD && !WoW.IsMoving || WoW.CanCast("Solar Wrath") && WoW.CurrentAstralPower < 85 && !WoW.IsMoving || WoW.CanCast("Solar Wrath") && WoW.PlayerBuffTimeRemaining("Solar Empowerment") > GCD && !WoW.IsMoving && WoW.PlayerBuffStacks("Solar Empowerment") >= 2)
                    {
                        WoW.CastSpell("Solar Wrath");
                        return;
                    }

                    if (WoW.CanCast("Rejuv") && WoW.HealthPercent < 85 && !WoW.PlayerHasBuff("Rejuv") && !WoW.IsMounted && !WoW.PlayerHasBuff("Travel Form"))
                    {
                        WoW.CastSpell("Rejuv");
                        return;
                    }

                    if (WoW.CanCast("Regrowth") && WoW.HealthPercent < 50 && !WoW.IsMoving)
                    {
                        WoW.CastSpell("Regrowth");
                        return;
                    }
                }
            }

            if (combatRoutine.Type == RotationType.SingleTargetCleave)
            {
            }

            if (combatRoutine.Type == RotationType.AOE)
            {
                Log.Write("Doing AOE", Color.Red);

                if (WoW.HasTarget && WoW.TargetIsEnemy && WoW.IsInCombat)
                {
                    if (WoW.CanCast("Starfall") && !WoW.PlayerHasBuff("Starfall") && WoW.CurrentAstralPower > 85)
                    {
                        //WoW.CastSpell("Starfall");
                        WoW.CastSpellOnMe("Starfall");
                        return;
                    }

                    if (WoW.CanCast("Starsurge") && WoW.CurrentAstralPower > 40)
                    {
                        WoW.CastSpell("Starsurge");
                        return;
                    }

                    if (WoW.CanCast("Moonfire") && !WoW.TargetHasDebuff("Moonfire") || WoW.TargetDebuffTimeRemaining("Moonfire") < 300)
                    {
                        WoW.CastSpell("Moonfire");
                        return;
                    }

                    if (WoW.CanCast("Sunfire") && !WoW.TargetHasDebuff("Sunfire") || WoW.TargetDebuffTimeRemaining("Sunfire") < 300)
                    {
                        WoW.CastSpell("Sunfire");
                        return;
                    }

                    if (WoW.CanCast("Lunar Strike") && WoW.LastSpell != "Lunar Strike" && WoW.PlayerBuffTimeRemaining("Lunar Empowerment") > GCD && !WoW.IsMoving)
                    {
                        WoW.CastSpell("Lunar Strike");
                        return;
                    }

                    if (WoW.CanCast("Solar Wrath") && WoW.PlayerBuffTimeRemaining("Solar Empowerment") > GCD && !WoW.IsMoving || WoW.CanCast("Solar Wrath") && WoW.CurrentAstralPower < 85 && !WoW.IsMoving)
                    {
                        WoW.CastSpell("Solar Wrath");
                        return;
                    }

                    if (WoW.CanCast("Rejuv") && WoW.HealthPercent < 85 && !WoW.PlayerHasBuff("Rejuv") && WoW.IsInCombat)
                    {
                        WoW.CastSpell("Rejuv");
                        return;
                    }

                    if (WoW.CanCast("Regrowth") && WoW.HealthPercent < 50 && !WoW.IsMoving && WoW.IsInCombat)
                    {
                        WoW.CastSpell("Regrowth");
                        return;
                    }
                }
            }
        }
        public override void Pulse()
        {
            if (combatRoutine.Type == RotationType.SingleTarget) // Do Single Target Stuff here
            {
                if (WoW.HasTarget && WoW.TargetIsEnemy && WoW.IsInCombat)
                {
                    if (WoW.CanCast("Rupture") && WoW.CurrentComboPoints >= 5 && WoW.Energy >= 25 &&
                        (!WoW.TargetHasDebuff("Rupture") || WoW.TargetHasDebuff("Rupture") && WoW.TargetDebuffTimeRemaining("Rupture") < 5))
                    {
                        WoW.CastSpell("Rupture");
                        return;
                    }
                    if (WoW.CanCast("Vendetta") && !WoW.IsSpellOnCooldown("Vendetta") && WoW.Energy <= 50)
                    {
                        WoW.CastSpell("Vendetta");
                        return;
                    }
                    if (WoW.CanCast("Vanish") && WoW.CurrentComboPoints >= 6 && WoW.Energy >= 25 &&
                        (!WoW.TargetHasDebuff("Rupture") || WoW.TargetHasDebuff("Rupture") && WoW.TargetDebuffTimeRemaining("Rupture") < 5))
                    {
                        WoW.CastSpell("Vanish");
                        return;
                    }
                    if (WoW.CanCast("Rupture") && WoW.CurrentComboPoints >= 6 && WoW.Energy >= 25 && WoW.PlayerHasBuff("Stealth") &&
                        (WoW.TargetHasDebuff("Rupture") && WoW.TargetDebuffTimeRemaining("Rupture") < 5 || !WoW.TargetHasDebuff("Rupture")))
                    {
                        WoW.CastSpell("Rupture");
                        return;
                    }
                    if (WoW.CanCast("Garrote") && WoW.Energy >= 45 && (!WoW.TargetHasDebuff("Garrote") || WoW.TargetHasDebuff("Garrote") && WoW.TargetDebuffTimeRemaining("Garrote") < 3))
                    {
                        WoW.CastSpell("Garrote");
                        return;
                    }
                    if (WoW.CanCast("Kingsbane") && !WoW.IsSpellOnCooldown("Kingsbane") && (WoW.SpellCooldownTimeRemaining("Vendetta") >= 10 || WoW.TargetHasDebuff("Vendetta")))
                    {
                        WoW.CastSpell("Kingsbane");
                        return;
                    }
                    if (WoW.CanCast("Envenom") && WoW.Energy >= 35 && !WoW.PlayerHasBuff("Envenom") && WoW.CurrentComboPoints >= 3 && WoW.TargetHasDebuff("Rupture") &&
                        WoW.TargetDebuffTimeRemaining("Rupture") >= 10 && (!WoW.PlayerHasBuff("Elaborate Planning") || WoW.PlayerBuffTimeRemaining("Elaborate Planning") <= 2.0))
                    {
                        WoW.CastSpell("Envenom");
                        return;
                    }
                    if (WoW.CanCast("Mutilate") && WoW.Energy >= 55 && WoW.CurrentComboPoints <= 5 && WoW.PlayerBuffTimeRemaining("Elaborate Planning") >= 2.1)
                    {
                        WoW.CastSpell("Mutilate");
                        return;
                    }
                }
            }

            if (combatRoutine.Type == RotationType.AOE || combatRoutine.Type == RotationType.SingleTargetCleave) // Do AoE Target Stuff here
            {
                if (WoW.HasTarget && WoW.TargetIsEnemy && WoW.IsInCombat)
                {
                    if (WoW.CanCast("Rupture") && WoW.CurrentComboPoints >= 5 && WoW.Energy >= 25 &&
                        (!WoW.TargetHasDebuff("Rupture") || WoW.TargetHasDebuff("Rupture") && WoW.TargetDebuffTimeRemaining("Rupture") < 5))
                    {
                        WoW.CastSpell("Rupture");
                        return;
                    }
                    if (WoW.CanCast("Vendetta") && !WoW.IsSpellOnCooldown("Vendetta") && WoW.Energy <= 50)
                    {
                        WoW.CastSpell("Vendetta");
                        return;
                    }
                    if (WoW.CanCast("Vanish") && WoW.CurrentComboPoints >= 6 && WoW.Energy >= 25 &&
                        (!WoW.TargetHasDebuff("Rupture") || WoW.TargetHasDebuff("Rupture") && WoW.TargetDebuffTimeRemaining("Rupture") < 5))
                    {
                        WoW.CastSpell("Vanish");
                        return;
                    }
                    if (WoW.CanCast("Rupture") && WoW.CurrentComboPoints >= 6 && WoW.Energy >= 25 && WoW.PlayerHasBuff("Stealth") &&
                        (WoW.TargetHasDebuff("Rupture") && WoW.TargetDebuffTimeRemaining("Rupture") < 5 || !WoW.TargetHasDebuff("Rupture")))
                    {
                        WoW.CastSpell("Rupture");
                        return;
                    }
                }
                if (WoW.CanCast("Garrote") && WoW.Energy >= 45 && (!WoW.TargetHasDebuff("Garrote") || WoW.TargetHasDebuff("Garrote") && WoW.TargetDebuffTimeRemaining("Garrote") < 3))
                {
                    WoW.CastSpell("Garrote");
                    return;
                }
                if (WoW.CanCast("Kingsbane") && !WoW.IsSpellOnCooldown("Kingsbane") && (WoW.SpellCooldownTimeRemaining("Vendetta") >= 10 || WoW.TargetHasDebuff("Vendetta")))
                {
                    WoW.CastSpell("Kingsbane");
                    return;
                }
                if (WoW.CanCast("Envenom") && WoW.Energy >= 35 && !WoW.PlayerHasBuff("Envenom") && WoW.CurrentComboPoints >= 3 && WoW.TargetHasDebuff("Rupture") &&
                    WoW.TargetDebuffTimeRemaining("Rupture") >= 10 && (!WoW.PlayerHasBuff("Elaborate Planning") || (WoW.PlayerBuffTimeRemaining("Elaborate Planning") <= 2.0)))
                {
                    WoW.CastSpell("Envenom");
                    return;
                }
                if (WoW.CanCast("Fan of Knives") && WoW.Energy >= 35 && !WoW.TargetHasDebuff("Agonizing Poison"))
                {
                    WoW.CastSpell("Fan of Knives");
                    return;
                }
                if (WoW.CanCast("Fan of Knives") && WoW.Energy >= 35 && WoW.TargetHasDebuff("Agonizing Poison") && WoW.TargetDebuffStacks("Agonizing Poison") <= 4)
                {
                    WoW.CastSpell("Fan of Knives");
                    return;
                }
                if (WoW.CanCast("Fan of Knives") && WoW.Energy >= 35 && WoW.TargetHasDebuff("Agonizing Poison") && WoW.TargetDebuffTimeRemaining("Agonizing Poison") < 2)
                {
                    WoW.CastSpell("Fan of Knives");
                    return;
                }
                if (WoW.CanCast("Mutilate") && WoW.Energy >= 55 && WoW.CurrentComboPoints <= 5)
                {
                    WoW.CastSpell("Mutilate");
                }
            }
        }
Exemplo n.º 13
0
 private void SurvivalRotation()
 {
     WoW.CastSpell("Immolation Aura", !WoW.IsSpellOnCooldown("Immolation Aura"));
     WoW.CastSpell("Spirit Bomb", !WoW.IsSpellOnCooldown("Spirit Bomb") && WoW.PlayerHasBuff("Soul Fragments") && (!WoW.TargetHasDebuff("Frailty") || WoW.TargetDebuffTimeRemaining("Frailty") <= 200));
     WoW.CastSpell("Soul Cleave", WoW.PlayerHealthPercent < 80 && !WoW.PlayerHasBuff("Soul Fragments") && WoW.Pain >= 70);
     WoW.CastSpell("Soul Carver", !WoW.IsSpellOnCooldown("Soul Carver") && WoW.TargetHasDebuff("Frailty") && WoW.TargetDebuffTimeRemaining("Frailty") > 1000);
     WoW.CastSpell("Sigil of Flame", !WoW.IsSpellOnCooldown("Sigil of Flame") && !WoW.TargetHasDebuff("Sigil of Flame"));
     if (WoW.Pain < 70)
     {
         WoW.CastSpell("Shear", !WoW.PlayerHasBuff("Metamorphasis"));
         WoW.CastSpell("Sever", WoW.PlayerHasBuff("Metamorphasis"));
     }
     WoW.CastSpell("Soul Cleave", WoW.PlayerHealthPercent < 35);
     WoW.CastSpell("Fracture", true);
 }
Exemplo n.º 14
0
        public override void Pulse()
        {
            //Combat Time
            if (CombatTime.IsRunning && !WoW.IsInCombat)
            {
                CombatTime.Reset();
            }
            if (!CombatTime.IsRunning && WoW.IsInCombat)
            {
                CombatTime.Start();
            }

            //Dreadstalkers Time Remaining (12000 ms) (EXPERIMENTAL)
            if (DreadstalkersTime.IsRunning && WoW.DreadstalkersCount == 0)
            {
                DreadstalkersTime.Reset();
            }
            if (!DreadstalkersTime.IsRunning && WoW.DreadstalkersCount >= 1)
            {
                DreadstalkersTime.Start();
            }

            //Imp Time Remaining (12000 ms) (EXPERIMENTAL)
            if (ImpTime.IsRunning && WoW.WildImpsCount == 0)
            {
                ImpTime.Reset();
            }
            if (!ImpTime.IsRunning && WoW.WildImpsCount >= 1)
            {
                ImpTime.Start();
            }

            var DreadstalkersRemainingDuration = Convert.ToSingle((12000f - DreadstalkersTime.ElapsedMilliseconds) / 1000f);
            var ImpsRemainingDuration          = Convert.ToSingle((12000f - ImpTime.ElapsedMilliseconds) / 1000f + OneFiveCast);

            // Single Target Rotation
            if (combatRoutine.Type == RotationType.SingleTarget)
            {
                // Normal Rotation
                if (WoW.HasTarget && WoW.TargetIsEnemy && WoW.IsInCombat && !WoW.PlayerIsCasting)
                {
                    Log.Write("Imp Time: " + ImpsRemainingDuration, Color.DarkViolet);
                    Log.Write("Dread Time: " + DreadstalkersRemainingDuration, Color.DarkViolet);
                    //Implosion (if talent)
                    if (WoW.CanCast("Implosion") && Implosion && WoW.IsSpellInRange("Doom"))
                    {
                        if (ImpsRemainingDuration <= SBExecuteTime && WoW.PlayerHasBuff("DemonicSynergy"))
                        {
                            WoW.CastSpell("Implosion");
                            return;
                        }
                        if (WoW.LastSpell == "HandOfGuldan" && WoW.WildImpsCount == 1 && WoW.PlayerHasBuff("DemonicSynergy"))
                        {
                            WoW.CastSpell("Implosion");
                            return;
                        }
                    }

                    //Shadowflame (if talent)
                    if (WoW.CanCast("Shadowflame") && Shadowflame && WoW.IsSpellInRange("Doom") && WoW.TargetHasDebuff("Shadowflame") &&
                        WoW.TargetDebuffTimeRemaining("Shadowflame") < TwoSecondCast + 2)
                    {
                        WoW.CastSpell("Shadowflame");
                        return;
                    }

                    //Service Pet (if talent)
                    if (WoW.CanCast("GrimoireFelguard") && GrimoireOfService && WoW.IsSpellInRange("Doom") && WoW.CurrentSoulShards >= 1 && boss)
                    {
                        WoW.CastSpell("GrimoireFelguard");
                        empowered = false;
                        return;
                    }

                    // Doomguard
                    if (WoW.CanCast("Doomguard") && WoW.CurrentSoulShards >= 1 && boss && WoW.IsSpellInRange("Doom"))
                    {
                        WoW.CastSpell("Doomguard");
                        empowered = false;
                        return;
                    }

                    //Felstorm
                    if (WoW.CanCast("Felstorm") && WoW.HasPet && WoW.PetHasBuff("DemonicEmpowerment"))
                    {
                        WoW.CastSpell("Felstorm");
                        return;
                    }

                    //Call Dreadstalkers (if NOT talent Summon Darkglare)
                    if (WoW.CanCast("CallDreadstalkers") && !SummonDarkglare && (WoW.CurrentSoulShards >= 2 || WoW.PlayerHasBuff("DemonicCalling")) && WoW.IsSpellInRange("Doom") &&
                        (!WoW.IsMoving || WoW.PlayerHasBuff("Norgannon")))
                    {
                        WoW.CastSpell("CallDreadstalkers");
                        empowered = false;
                        DreadstalkersTime.Restart();
                        return;
                    }

                    //Hand Of Guldan (if NOT talent Summon Darkglare)
                    if (WoW.CanCast("HandOfGuldan") && !SummonDarkglare && WoW.LastSpell != "HandOfGuldan" && WoW.CurrentSoulShards >= 4 && WoW.IsSpellInRange("Doom") &&
                        (!WoW.IsMoving || WoW.PlayerHasBuff("Norgannon")))
                    {
                        WoW.CastSpell("HandOfGuldan");
                        empowered = false;
                        threeimps = false;
                        ImpTime.Restart();
                        return;
                    }

                    //Summon Darkglare (if talent)
                    if (WoW.CanCast("SummonDarkglare") && SummonDarkglare && WoW.CurrentSoulShards >= 1 && WoW.TargetHasDebuff("Doom") && WoW.IsSpellInRange("Doom") &&
                        (!WoW.IsMoving || WoW.PlayerHasBuff("Norgannon")))
                    {
                        if (WoW.LastSpell == "HandOfGuldan" || WoW.LastSpell == "CallDreadstalkers")
                        {
                            WoW.CastSpell("SummonDarkglare");
                            Log.Write("1", Color.Red);
                            empowered = false;
                            return;
                        }
                        if (WoW.SpellCooldownTimeRemaining("CallDreadstalkers") > 5 && WoW.CurrentSoulShards < 3)
                        {
                            WoW.CastSpell("SummonDarkglare");
                            Log.Write("2", Color.Red);
                            empowered = false;
                            return;
                        }
                        if (WoW.SpellCooldownTimeRemaining("CallDreadstalkers") <= gcd && WoW.CurrentSoulShards >= 3)
                        {
                            WoW.CastSpell("SummonDarkglare");
                            Log.Write("3", Color.Red);
                            empowered = false;
                            return;
                        }
                        if (WoW.SpellCooldownTimeRemaining("CallDreadstalkers") <= gcd && WoW.CurrentSoulShards >= 1 && WoW.PlayerHasBuff("DemonicCalling"))
                        {
                            WoW.CastSpell("SummonDarkglare");
                            Log.Write("4", Color.Red);
                            empowered = false;
                            return;
                        }
                    }

                    //Call Dreadstalkers (if talent Summon Darkglare)
                    if (WoW.CanCast("CallDreadstalkers") && SummonDarkglare && (WoW.CurrentSoulShards >= 2 || WoW.PlayerHasBuff("DemonicCalling")) && WoW.IsSpellInRange("Doom") &&
                        (!WoW.IsMoving || WoW.PlayerHasBuff("Norgannon")))
                    {
                        if (WoW.SpellCooldownTimeRemaining("SummonDarkglare") <= TwoSecondCast && WoW.CurrentSoulShards >= 3)
                        {
                            WoW.CastSpell("CallDreadstalkers");
                            empowered = false;
                            DreadstalkersTime.Restart();
                            return;
                        }
                        if (WoW.SpellCooldownTimeRemaining("SummonDarkglare") <= TwoSecondCast && WoW.CurrentSoulShards >= 1 && WoW.PlayerHasBuff("DemonicCalling"))
                        {
                            WoW.CastSpell("CallDreadstalkers");
                            empowered = false;
                            DreadstalkersTime.Restart();
                            return;
                        }
                    }

                    //Hand Of Guldan
                    if (WoW.CanCast("HandOfGuldan") && WoW.LastSpell != "HandOfGuldan" && WoW.CurrentSoulShards >= 3 && WoW.LastSpell == "CallDreadstalkers" && WoW.IsSpellInRange("Doom") &&
                        (!WoW.IsMoving || WoW.PlayerHasBuff("Norgannon")))
                    {
                        WoW.CastSpell("HandOfGuldan");
                        empowered = false;
                        threeimps = true;
                        ImpTime.Restart();
                        return;
                    }

                    //Hand Of Guldan (if talent Summon Darkglare)
                    if (WoW.CanCast("HandOfGuldan") && SummonDarkglare && WoW.LastSpell != "HandOfGuldan" && WoW.CurrentSoulShards >= 5 &&
                        WoW.SpellCooldownTimeRemaining("SummonDarkglare") <= OneFiveCast && WoW.IsSpellInRange("Doom") && (!WoW.IsMoving || WoW.PlayerHasBuff("Norgannon")))
                    {
                        WoW.CastSpell("HandOfGuldan");
                        threeimps = false;
                        empowered = false;
                        ImpTime.Restart();
                        return;
                    }

                    //Hand Of Guldan (if talent Summon Darkglare)
                    if (WoW.CanCast("HandOfGuldan") && SummonDarkglare && WoW.LastSpell != "HandOfGuldan" && WoW.CurrentSoulShards >= 4 && WoW.SpellCooldownTimeRemaining("SummonDarkglare") > 2 &&
                        WoW.IsSpellInRange("Doom") && (!WoW.IsMoving || WoW.PlayerHasBuff("Norgannon")))
                    {
                        WoW.CastSpell("HandOfGuldan");
                        threeimps = false;
                        empowered = false;
                        ImpTime.Restart();
                        return;
                    }

                    //Demonic Empowerment (if last spell was Hand Of Guldan)
                    if (WoW.CanCast("DemonicEmpowerment") && WoW.LastSpell == "HandOfGuldan" && WoW.LastSpell != "DemonicEmpowerment" && WoW.IsSpellInRange("Doom") &&
                        (!WoW.IsMoving || WoW.PlayerHasBuff("Norgannon")))
                    {
                        WoW.CastSpell("DemonicEmpowerment");
                        empowered = true;
                        return;
                    }

                    //Demonic Empowerment
                    if (WoW.CanCast("DemonicEmpowerment") && (!empowered || !WoW.PetHasBuff("DemonicEmpowerment")) && WoW.LastSpell != "DemonicEmpowerment" && WoW.IsSpellInRange("Doom") &&
                        (!WoW.IsMoving || WoW.PlayerHasBuff("Norgannon")))
                    {
                        WoW.CastSpell("DemonicEmpowerment");
                        empowered = true;
                        return;
                    }

/*
 *                                      //Doom (if NOT talent Hand of Doom)
 *                                      if(WoW.CanCast("Doom") && (!WoW.TargetHasDebuff("Doom") || WoW.TargetDebuffTimeRemaining("Doom") < 5) && WoW.IsSpellInRange("Doom"))
 *                                      {
 *                                              WoW.CastSpell("Doom");
 *                                              return;
 *                                      }
 *
 *                                      //Soul Harvest
 *                                      if(WoW.CanCast("SoulHarvest") && WoW.IsSpellInRange("Doom"))
 *                                      {
 *                                              WoW.CastSpell("SoulHarvest");
 *                                              return;
 *                                      }
 */
                    //Shadowflame (if talent)
                    if (WoW.CanCast("Shadowflame") && Shadowflame && WoW.IsSpellInRange("Doom") && WoW.PlayerSpellCharges("Shadowflame") == 2)
                    {
                        WoW.CastSpell("Shadowflame");
                        return;
                    }

                    //Thal'kiel's Consumption
                    if (WoW.CanCast("TK") && WoW.DreadstalkersCount >= 1 && DreadstalkersRemainingDuration > TwoSecondCast && ((WoW.WildImpsCount >= 1 && !threeimps) || WoW.WildImpsCount >= 2) &&
                        ImpsRemainingDuration > TwoSecondCast && WoW.IsSpellInRange("Doom") && (!WoW.IsMoving || WoW.PlayerHasBuff("Norgannon")))
                    {
                        WoW.CastSpell("TK");
                        return;
                    }

                    //Life Tap
                    if (WoW.CanCast("LifeTap") && WoW.Mana <= 30)
                    {
                        WoW.CastSpell("LifeTap");
                        return;
                    }

                    //Demonwrath (if moving)
                    if (WoW.CanCast("Demonwrath") && WoW.IsMoving && !WoW.PlayerHasBuff("Norgannon"))
                    {
                        WoW.CastSpell("Demonwrath");
                        return;
                    }

                    //Demonbolt (if talent)
                    if (WoW.CanCast("Demonbolt") && Demonbolt && WoW.IsSpellInRange("Doom") && (!WoW.IsMoving || WoW.PlayerHasBuff("Norgannon")))
                    {
                        WoW.CastSpell("Demonbolt");
                        return;
                    }

                    //Shadowbolt (if NOT Demonbolt talent)
                    if (WoW.CanCast("Shadowbolt") && !Demonbolt && WoW.IsSpellInRange("Doom") && (!WoW.IsMoving || WoW.PlayerHasBuff("Norgannon")))
                    {
                        WoW.CastSpell("Demonbolt");
                        return;
                    }

                    //Life Tap
                    if (WoW.CanCast("LifeTap") && WoW.Mana < 100)
                    {
                        WoW.CastSpell("LifeTap");
                        return;
                    }
                }
            }

            // AoE Rotation
            if (combatRoutine.Type == RotationType.AOE)
            {
                Log.Write("Imp Time: " + ImpsRemainingDuration, Color.DarkViolet);
                // AoE Rotation
                if (WoW.HasTarget && WoW.TargetIsEnemy && WoW.IsInCombat && !WoW.PlayerIsCasting)
                {
                    //Implosion (if talent)
                    if (WoW.CanCast("Implosion") && Implosion && WoW.IsSpellInRange("Doom"))
                    {
                        if (ImpsRemainingDuration <= SBExecuteTime && WoW.PlayerHasBuff("DemonicSynergy"))
                        {
                            WoW.CastSpell("Implosion");
                            return;
                        }
                        if (WoW.LastSpell == "HandOfGuldan" && WoW.WildImpsCount == 1 && WoW.PlayerHasBuff("DemonicSynergy"))
                        {
                            WoW.CastSpell("Implosion");
                            return;
                        }
                        if (WoW.WildImpsCount == 1 && ImpsRemainingDuration <= SBExecuteTime)
                        {
                            WoW.CastSpell("Implosion");
                            return;
                        }
                        if (WoW.LastSpell == "HandOfGuldan" && WoW.WildImpsCount == 1)
                        {
                            WoW.CastSpell("Implosion");
                            return;
                        }
                    }

                    //Shadowflame (if talent)
                    if (WoW.CanCast("Shadowflame") && Shadowflame && WoW.IsSpellInRange("Doom") && WoW.TargetHasDebuff("Shadowflame") &&
                        WoW.TargetDebuffTimeRemaining("Shadowflame") < TwoSecondCast + 2)
                    {
                        WoW.CastSpell("Shadowflame");
                        return;
                    }

                    //Felstorm
                    if (WoW.CanCast("Felstorm") && WoW.HasPet && WoW.PetHasBuff("DemonicEmpowerment"))
                    {
                        WoW.CastSpell("Felstorm");
                        return;
                    }

                    //Call Dreadstalkers (if NOT talent Summon Darkglare or Implosion)
                    if (WoW.CanCast("CallDreadstalkers") && !SummonDarkglare && (WoW.CurrentSoulShards >= 2 || WoW.PlayerHasBuff("DemonicCalling")) && !Implosion && WoW.IsSpellInRange("Doom") &&
                        (!WoW.IsMoving || WoW.PlayerHasBuff("Norgannon")))
                    {
                        WoW.CastSpell("CallDreadstalkers");
                        empowered = false;
                        DreadstalkersTime.Restart();
                        return;
                    }

                    //Hand Of Guldan (if NOT talent Summon Darkglare)
                    if (WoW.CanCast("HandOfGuldan") && !SummonDarkglare && WoW.LastSpell != "HandOfGuldan" && WoW.CurrentSoulShards >= 4 && WoW.IsSpellInRange("Doom") &&
                        (!WoW.IsMoving || WoW.PlayerHasBuff("Norgannon")))
                    {
                        WoW.CastSpell("HandOfGuldan");
                        empowered = false;
                        threeimps = false;
                        ImpTime.Restart();
                        return;
                    }

                    //Summon Darkglare (if talent)
                    if (WoW.CanCast("SummonDarkglare") && SummonDarkglare && WoW.CurrentSoulShards >= 1 && WoW.TargetHasDebuff("Doom") && WoW.IsSpellInRange("Doom") &&
                        (!WoW.IsMoving || WoW.PlayerHasBuff("Norgannon")))
                    {
                        if (WoW.LastSpell == "HandOfGuldan" || WoW.LastSpell == "CallDreadstalkers")
                        {
                            WoW.CastSpell("SummonDarkglare");
                            Log.Write("1", Color.Red);
                            empowered = false;
                            return;
                        }
                        if (WoW.SpellCooldownTimeRemaining("CallDreadstalkers") > 5 && WoW.CurrentSoulShards < 3)
                        {
                            WoW.CastSpell("SummonDarkglare");
                            Log.Write("2", Color.Red);
                            empowered = false;
                            return;
                        }
                        if (WoW.SpellCooldownTimeRemaining("CallDreadstalkers") <= gcd && WoW.CurrentSoulShards >= 3)
                        {
                            WoW.CastSpell("SummonDarkglare");
                            Log.Write("3", Color.Red);
                            empowered = false;
                            return;
                        }
                        if (WoW.SpellCooldownTimeRemaining("CallDreadstalkers") <= gcd && WoW.CurrentSoulShards >= 1 && WoW.PlayerHasBuff("DemonicCalling"))
                        {
                            WoW.CastSpell("SummonDarkglare");
                            Log.Write("4", Color.Red);
                            empowered = false;
                            return;
                        }
                    }

                    //Call Dreadstalkers (if talent Summon Darkglare and not Implosion)
                    if (WoW.CanCast("CallDreadstalkers") && SummonDarkglare && (WoW.CurrentSoulShards >= 2 || WoW.PlayerHasBuff("DemonicCalling")) && !Implosion && WoW.IsSpellInRange("Doom") &&
                        (!WoW.IsMoving || WoW.PlayerHasBuff("Norgannon")))
                    {
                        if (WoW.SpellCooldownTimeRemaining("SummonDarkglare") <= TwoSecondCast && WoW.CurrentSoulShards >= 3)
                        {
                            WoW.CastSpell("CallDreadstalkers");
                            empowered = false;
                            DreadstalkersTime.Restart();
                            return;
                        }
                        if (WoW.SpellCooldownTimeRemaining("SummonDarkglare") <= TwoSecondCast && WoW.CurrentSoulShards >= 1 && WoW.PlayerHasBuff("DemonicCalling"))
                        {
                            WoW.CastSpell("CallDreadstalkers");
                            empowered = false;
                            DreadstalkersTime.Restart();
                            return;
                        }
                    }

                    //Hand Of Guldan
                    if (WoW.CanCast("HandOfGuldan") && WoW.LastSpell != "HandOfGuldan" && WoW.CurrentSoulShards >= 3 && WoW.LastSpell == "CallDreadstalkers" && WoW.IsSpellInRange("Doom") &&
                        (!WoW.IsMoving || WoW.PlayerHasBuff("Norgannon")))
                    {
                        WoW.CastSpell("HandOfGuldan");
                        empowered = false;
                        threeimps = true;
                        ImpTime.Restart();
                        return;
                    }

                    //Hand Of Guldan (if talent Summon Darkglare)
                    if (WoW.CanCast("HandOfGuldan") && SummonDarkglare && WoW.LastSpell != "HandOfGuldan" && WoW.CurrentSoulShards >= 5 &&
                        WoW.SpellCooldownTimeRemaining("SummonDarkglare") <= OneFiveCast && WoW.IsSpellInRange("Doom") && (!WoW.IsMoving || WoW.PlayerHasBuff("Norgannon")))
                    {
                        WoW.CastSpell("HandOfGuldan");
                        threeimps = false;
                        empowered = false;
                        ImpTime.Restart();
                        return;
                    }

                    //Hand Of Guldan (if talent Summon Darkglare)
                    if (WoW.CanCast("HandOfGuldan") && SummonDarkglare && WoW.LastSpell != "HandOfGuldan" && WoW.CurrentSoulShards >= 4 && WoW.SpellCooldownTimeRemaining("SummonDarkglare") > 2 &&
                        WoW.IsSpellInRange("Doom") && (!WoW.IsMoving || WoW.PlayerHasBuff("Norgannon")))
                    {
                        WoW.CastSpell("HandOfGuldan");
                        threeimps = false;
                        empowered = false;
                        ImpTime.Restart();
                        return;
                    }

                    //Demonic Empowerment (if last spell was Hand Of Guldan)
                    if (WoW.CanCast("DemonicEmpowerment") && WoW.LastSpell == "HandOfGuldan" && WoW.LastSpell != "DemonicEmpowerment" && WoW.IsSpellInRange("Doom") &&
                        (!WoW.IsMoving || WoW.PlayerHasBuff("Norgannon")))
                    {
                        WoW.CastSpell("DemonicEmpowerment");
                        empowered = true;
                        return;
                    }

                    //Demonic Empowerment
                    if (WoW.CanCast("DemonicEmpowerment") && (!empowered || !WoW.PetHasBuff("DemonicEmpowerment")) && WoW.LastSpell != "DemonicEmpowerment" && WoW.IsSpellInRange("Doom") &&
                        (!WoW.IsMoving || WoW.PlayerHasBuff("Norgannon")))
                    {
                        WoW.CastSpell("DemonicEmpowerment");
                        empowered = true;
                        return;
                    }

/*
 *                                      //Doom (if NOT talent Hand of Doom)
 *                                      if(WoW.CanCast("Doom") && (!WoW.TargetHasDebuff("Doom") || WoW.TargetDebuffTimeRemaining("Doom") < 5) && WoW.IsSpellInRange("Doom"))
 *                                      {
 *                                              WoW.CastSpell("Doom");
 *                                              return;
 *                                      }
 *
 *                                      //Soul Harvest
 *                                      if(WoW.CanCast("SoulHarvest") && WoW.IsSpellInRange("Doom"))
 *                                      {
 *                                              WoW.CastSpell("SoulHarvest");
 *                                              return;
 *                                      }
 */
                    //Shadowflame (if talent)
                    if (WoW.CanCast("Shadowflame") && Shadowflame && WoW.IsSpellInRange("Doom") && WoW.PlayerSpellCharges("Shadowflame") == 2)
                    {
                        WoW.CastSpell("Shadowflame");
                        return;
                    }

                    //Thal'kiel's Consumption
                    if (WoW.CanCast("TK") && ((WoW.DreadstalkersCount >= 1 && DreadstalkersRemainingDuration > TwoSecondCast) || Implosion) &&
                        ((WoW.WildImpsCount >= 1 && !threeimps) || WoW.WildImpsCount >= 2) && ImpsRemainingDuration > TwoSecondCast && WoW.IsSpellInRange("Doom") &&
                        (!WoW.IsMoving || WoW.PlayerHasBuff("Norgannon")))
                    {
                        WoW.CastSpell("TK");
                        return;
                    }

                    //Life Tap
                    if (WoW.CanCast("LifeTap") && WoW.Mana <= 30)
                    {
                        WoW.CastSpell("LifeTap");
                        return;
                    }

                    //Demonwrath
                    if (WoW.CanCast("Demonwrath") && !WoW.PlayerIsChanneling)
                    {
                        WoW.CastSpell("Demonwrath");
                        return;
                    }

                    //Life Tap
                    if (WoW.CanCast("LifeTap") && WoW.Mana < 100 && !WoW.PlayerIsChanneling)
                    {
                        WoW.CastSpell("LifeTap");
                    }
                }
            }
        }