示例#1
0
        public static async Task <bool> Combat()
        {
            if (BotManager.Current.IsAutonomous)
            {
                if (Core.Me.HasTarget)
                {
                    Movement.NavigateToUnitLos(Core.Me.CurrentTarget, 23);
                }
            }

            if (!Core.Me.HasTarget || !Core.Me.CurrentTarget.ThoroughCanAttack())
            {
                return(false);
            }

            if (await CustomOpenerLogic.Opener())
            {
                return(true);
            }

            if (MachinistSettings.Instance.UseFlamethrower && Core.Me.HasAura(Auras.Flamethrower))
            {
                // First check movement otherwise Flamethrower can be executed whereas you are moving
                if (MovementManager.IsMoving)
                {
                    return(false);
                }

                if (!MachinistSettings.Instance.UseFlamethrower)
                {
                    return(true);
                }

                if (Core.Me.EnemiesInCone(8) >= MachinistSettings.Instance.FlamethrowerEnemyCount)
                {
                    return(true);
                }
            }

            //oGCDs

            //Utility
            if (await Utility.Tactician())
            {
                return(true);
            }
            if (await PhysicalDps.ArmsLength(MachinistSettings.Instance))
            {
                return(true);
            }
            if (await PhysicalDps.SecondWind(MachinistSettings.Instance))
            {
                return(true);
            }
            if (await Utility.HeadGraze())
            {
                return(true);
            }

            if (Weaving.GetCurrentWeavingCounter() < 2)
            {
                //Pets
                if (await Pet.RookQueen())
                {
                    return(true);
                }
                if (await Pet.RookQueenOverdrive())
                {
                    return(true);
                }

                //Cooldowns
                if (await Cooldowns.Wildfire())
                {
                    return(true);
                }
                if (await Cooldowns.Hypercharge())
                {
                    return(true);
                }
                if (await Cooldowns.Reassemble())
                {
                    return(true);
                }
                if (await Cooldowns.BarrelStabilizer())
                {
                    return(true);
                }

                //oGCDs
                if (await SingleTarget.GaussRound())
                {
                    return(true);
                }
                if (await MultiTarget.Ricochet())
                {
                    return(true);
                }
            }

            //GCDs - Top Hypercharge Priority
            if (await MultiTarget.AutoCrossbow())
            {
                return(true);
            }
            if (await SingleTarget.HeatBlast())
            {
                return(true);
            }

            //Use On CD
            if (await MultiTarget.BioBlaster())
            {
                return(true);
            }
            if (await SingleTarget.Drill())
            {
                return(true);
            }
            if (await SingleTarget.HotAirAnchor())
            {
                return(true);
            }
            if (await MultiTarget.Flamethrower())
            {
                return(true);
            }
            if (await MultiTarget.SpreadShot())
            {
                return(true);
            }

            //Default Combo

            if (Core.Me.ClassLevel > 58)
            {
                if (Spells.Drill.Cooldown.TotalMilliseconds > 100)
                {
                    if (await SingleTarget.HeatedCleanShot())
                    {
                        return(true);
                    }
                    if (await SingleTarget.HeatedSlugShot())
                    {
                        return(true);
                    }
                }
            }
            else
            {
                if (await SingleTarget.HeatedCleanShot())
                {
                    return(true);
                }
                if (await SingleTarget.HeatedSlugShot())
                {
                    return(true);
                }
            }

            return(await SingleTarget.HeatedSplitShot());
        }
示例#2
0
        public static async Task <bool> Combat()
        {
            if (BotManager.Current.IsAutonomous)
            {
                if (Core.Me.HasTarget)
                {
                    Movement.NavigateToUnitLos(Core.Me.CurrentTarget, 20 + Core.Me.CurrentTarget.CombatReach);
                }
            }

            if (await Casting.TrackSpellCast())
            {
                return(true);
            }

            await Casting.CheckForSuccessfulCast();

            BardRoutine.RefreshVars();

            if (!Core.Me.HasTarget || !Core.Me.CurrentTarget.ThoroughCanAttack())
            {
                return(false);
            }

            if (await CustomOpenerLogic.Opener())
            {
                return(true);
            }

            if (BardRoutine.GlobalCooldown.CanWeave())
            {
                // Utility
                if (await Utility.RepellingShot())
                {
                    return(true);
                }
                if (await Utility.WardensPaean())
                {
                    return(true);
                }
                if (await Utility.NaturesMinne())
                {
                    return(true);
                }
                if (await Utility.Troubadour())
                {
                    return(true);
                }
                if (await PhysicalDps.ArmsLength(BardSettings.Instance))
                {
                    return(true);
                }
                if (await PhysicalDps.SecondWind(BardSettings.Instance))
                {
                    return(true);
                }
                if (await PhysicalDps.Interrupt(BardSettings.Instance))
                {
                    return(true);
                }

                // Damage
                if (await SingleTarget.LastPossiblePitchPerfectDuringWM())
                {
                    return(true);
                }
                if (await Songs.LetMeSingYouTheSongOfMyPeople())
                {
                    return(true);
                }
                if (await Cooldowns.RagingStrikes())
                {
                    return(true);
                }
                if (await Cooldowns.BattleVoice())
                {
                    return(true);
                }
                if (await Cooldowns.RadiantFinale())
                {
                    return(true);
                }
                if (await Cooldowns.Barrage())
                {
                    return(true);
                }
                if (await SingleTarget.PitchPerfect())
                {
                    return(true);
                }
                if (await Aoe.RainOfDeathDuringMagesBallard())
                {
                    return(true);
                }
                if (await SingleTarget.BloodletterInMagesBallard())
                {
                    return(true);
                }
                if (await SingleTarget.EmpyrealArrow())
                {
                    return(true);
                }
                if (await SingleTarget.Sidewinder())
                {
                    return(true);
                }
                if (await Aoe.RainOfDeath())
                {
                    return(true);
                }
                if (await SingleTarget.Bloodletter())
                {
                    return(true);
                }
            }

            if (await DamageOverTime.IronJawsOnCurrentTarget())
            {
                return(true);
            }
            if (await DamageOverTime.SnapShotIronJawsOnCurrentTarget())
            {
                return(true);
            }
            if (await SingleTarget.StraightShotAfterBarrage())
            {
                return(true);
            }
            if (await DamageOverTime.WindbiteOnCurrentTarget())
            {
                return(true);
            }
            if (await DamageOverTime.VenomousBiteOnCurrentTarget())
            {
                return(true);
            }
            if (await Aoe.BlastArrow())
            {
                return(true);
            }
            if (await Aoe.ApexArrow())
            {
                return(true);
            }
            if (await Aoe.ShadowBite())
            {
                return(true);
            }
            if (await DamageOverTime.IronJawsOnOffTarget())
            {
                return(true);
            }
            if (await DamageOverTime.WindbiteOnOffTarget())
            {
                return(true);
            }
            if (await DamageOverTime.VenomousBiteOnOffTarget())
            {
                return(true);
            }
            if (await Aoe.LadonsBite())
            {
                return(true);
            }
            if (await SingleTarget.StraightShot())
            {
                return(true);
            }
            return(await SingleTarget.HeavyShot());
        }
示例#3
0
        public static async Task <bool> Combat()
        {
            if (BotManager.Current.IsAutonomous)
            {
                if (Core.Me.HasTarget)
                {
                    Movement.NavigateToUnitLos(Core.Me.CurrentTarget, 20 + Core.Me.CurrentTarget.CombatReach);
                }
            }

            if (!Core.Me.HasTarget || !Core.Me.CurrentTarget.ThoroughCanAttack())
            {
                return(false);
            }

            if (await CustomOpenerLogic.Opener())
            {
                return(true);
            }

            if (MachinistSettings.Instance.UseFlamethrower && Core.Me.HasAura(Auras.Flamethrower))
            {
                // First check movement otherwise Flamethrower can be executed whereas you are moving
                if (MovementManager.IsMoving)
                {
                    return(false);
                }

                if (!MachinistSettings.Instance.UseFlamethrower)
                {
                    return(true);
                }

                if (Core.Me.EnemiesInCone(8) >= MachinistSettings.Instance.FlamethrowerEnemyCount)
                {
                    return(true);
                }
            }

            if (ActionResourceManager.Machinist.OverheatRemaining != TimeSpan.Zero)
            {
                if (MachinistRoutine.GlobalCooldown.CanWeave(1))
                {
                    //Utility
                    if (await PhysicalDps.ArmsLength(MachinistSettings.Instance))
                    {
                        return(true);
                    }
                    if (await PhysicalDps.Interrupt(MachinistSettings.Instance))
                    {
                        return(true);
                    }

                    //Pets
                    if (await Pet.RookQueen())
                    {
                        return(true);
                    }

                    //Cooldowns
                    if (await Cooldowns.BarrelStabilizer())
                    {
                        return(true);
                    }

                    //oGCDs
                    if (await SingleTarget.GaussRound())
                    {
                        return(true);
                    }
                    if (await MultiTarget.Ricochet())
                    {
                        return(true);
                    }

                    //Cooldowns
                    if (await Cooldowns.Reassemble())
                    {
                        return(true);
                    }
                }
            }
            else
            {
                if (MachinistRoutine.GlobalCooldown.CanWeave())
                {
                    //Utility
                    if (await Utility.Tactician())
                    {
                        return(true);
                    }
                    if (await PhysicalDps.ArmsLength(MachinistSettings.Instance))
                    {
                        return(true);
                    }
                    if (await PhysicalDps.SecondWind(MachinistSettings.Instance))
                    {
                        return(true);
                    }
                    if (await PhysicalDps.Interrupt(MachinistSettings.Instance))
                    {
                        return(true);
                    }

                    //Pets
                    if (await Pet.RookQueen())
                    {
                        return(true);
                    }
                    if (await Pet.RookQueenOverdrive())
                    {
                        return(true);
                    }

                    //Cooldowns
                    if (await Cooldowns.Wildfire())
                    {
                        return(true);
                    }
                    if (await Cooldowns.Hypercharge())
                    {
                        return(true);
                    }
                    if (await Cooldowns.Reassemble())
                    {
                        return(true);
                    }
                    if (await Cooldowns.BarrelStabilizer())
                    {
                        return(true);
                    }

                    //oGCDs
                    if (await SingleTarget.GaussRound())
                    {
                        return(true);
                    }
                    if (await MultiTarget.Ricochet())
                    {
                        return(true);
                    }
                }
            }

            //GCDs - Top Hypercharge Priority
            if (await MultiTarget.AutoCrossbow())
            {
                return(true);
            }
            if (await SingleTarget.HeatBlast())
            {
                return(true);
            }

            //Use On CD
            if (await MultiTarget.ChainSaw())
            {
                return(true);
            }
            if (await MultiTarget.BioBlaster())
            {
                return(true);
            }
            if (await SingleTarget.Drill())
            {
                return(true);
            }
            if (await SingleTarget.HotAirAnchor())
            {
                return(true);
            }
            if (await MultiTarget.Flamethrower())
            {
                return(true);
            }
            if (await MultiTarget.Scattergun())
            {
                return(true);
            }

            //Default Combo
            if (await SingleTarget.HeatedCleanShot())
            {
                return(true);
            }
            if (await SingleTarget.HeatedSlugShot())
            {
                return(true);
            }

            return(await SingleTarget.HeatedSplitShot());
        }
示例#4
0
        public static async Task <bool> Execute()
        {
            Group.UpdateAllies();

            if (Core.Me.IsCasting)
            {
                return(true);
            }

            if (await Casting.TrackSpellCast())
            {
                return(true);
            }

            await Casting.CheckForSuccessfulCast();

            Globals.InParty       = PartyManager.IsInParty;
            Globals.PartyInCombat = Globals.InParty && Utilities.Combat.Enemies.Any(r => r.TaggerType == 2) || Core.Me.InCombat;
            Utilities.Routines.Bard.RefreshVars();

            if (!Core.Me.HasTarget || !Core.Me.CurrentTarget.ThoroughCanAttack())
            {
                return(false);
            }

            if (await CustomOpenerLogic.Opener())
            {
                return(true);
            }

            if (BotManager.Current.IsAutonomous)
            {
                if (Core.Me.HasTarget)
                {
                    Movement.NavigateToUnitLos(Core.Me.CurrentTarget, 20);
                }
            }

            if (Weaving.GetCurrentWeavingCounter() < 2 && Spells.HeavyShot.Cooldown.TotalMilliseconds > 650 + BaseSettings.Instance.UserLatencyOffset)
            {
                // Utility
                if (await Utility.RepellingShot())
                {
                    return(true);
                }
                if (await Utility.WardensPaean())
                {
                    return(true);
                }
                if (await Utility.NaturesMinne())
                {
                    return(true);
                }
                if (await Utility.Troubadour())
                {
                    return(true);
                }
                if (await PhysicalDps.ArmsLength(BardSettings.Instance))
                {
                    return(true);
                }
                if (await PhysicalDps.SecondWind(BardSettings.Instance))
                {
                    return(true);
                }
                if (await Utility.HeadGraze())
                {
                    return(true);
                }

                // Damage
                if (await SingleTarget.LastPossiblePitchPerfectDuringWM())
                {
                    return(true);
                }
                if (await Songs.LetMeSingYouTheSongOfMyPeople())
                {
                    return(true);
                }
                if (await Cooldowns.BattleVoice())
                {
                    return(true);
                }
                if (await Cooldowns.RagingStrikes())
                {
                    return(true);
                }
                if (await Cooldowns.Barrage())
                {
                    return(true);
                }
                if (await SingleTarget.PitchPerfect())
                {
                    return(true);
                }
                if (await Aoe.RainOfDeathDuringMagesBallard())
                {
                    return(true);
                }
                if (await SingleTarget.BloodletterInMagesBallard())
                {
                    return(true);
                }
                if (await SingleTarget.EmpyrealArrow())
                {
                    return(true);
                }
                if (await Aoe.ShadowBite())
                {
                    return(true);
                }
                if (await SingleTarget.Sidewinder())
                {
                    return(true);
                }
                if (await Aoe.RainOfDeath())
                {
                    return(true);
                }
                if (await SingleTarget.Bloodletter())
                {
                    return(true);
                }
            }

            if (await SingleTarget.StraightShotAfterBarrage())
            {
                return(true);
            }
            if (await DamageOverTime.IronJawsOnCurrentTarget())
            {
                return(true);
            }
            if (await DamageOverTime.SnapShotIronJawsOnCurrentTarget())
            {
                return(true);
            }
            if (await DamageOverTime.WindbiteOnCurrentTarget())
            {
                return(true);
            }
            if (await DamageOverTime.VenomousBiteOnCurrentTarget())
            {
                return(true);
            }
            if (await Aoe.ApexArrow())
            {
                return(true);
            }
            if (await DamageOverTime.IronJawsOnOffTarget())
            {
                return(true);
            }
            if (await DamageOverTime.WindbiteOnOffTarget())
            {
                return(true);
            }
            if (await DamageOverTime.VenomousBiteOnOffTarget())
            {
                return(true);
            }
            if (await Aoe.QuickNock())
            {
                return(true);
            }
            if (await SingleTarget.StraightShot())
            {
                return(true);
            }
            return(await SingleTarget.HeavyShot());
        }
示例#5
0
        public static async Task <bool> Combat()
        {
            Utilities.Routines.Ninja.RefreshVars();
            //Logger.Write("Ninki:" + Utilities.Routines.Ninja.ninki);
            if (BotManager.Current.IsAutonomous)
            {
                Movement.NavigateToUnitLos(Core.Me.CurrentTarget, 3 + Core.Me.CurrentTarget.CombatReach);
            }

            if (!SpellQueueLogic.SpellQueue.Any())
            {
                SpellQueueLogic.InSpellQueue = false;
            }

            if (SpellQueueLogic.SpellQueue.Any())
            {
                if (await SpellQueueLogic.SpellQueueMethod())
                {
                    return(true);
                }
            }

            if (!Core.Me.HasTarget || !Core.Me.CurrentTarget.ThoroughCanAttack())
            {
                return(false);
            }

            if (await CustomOpenerLogic.Opener())
            {
                return(true);
            }

            if (!Core.Me.HasTarget || !Core.Me.CurrentTarget.ThoroughCanAttack())
            {
                return(false);
            }

            if (await PhysicalDps.Interrupt(NinjaSettings.Instance))
            {
                return(true);
            }

            //if (Core.Me.HasAura(Auras.TenChiJin))
            //{
            //    Logger.Error("Capturd TCJ");
            //    //Let's check which TCJ we will do. 1=Suiton/2-Doton
            //    if (Utilities.Routines.Ninja.AoeEnemies5Yards > 1 && Utilities.Routines.Ninja.TCJState == 0 && !Core.Me.HasAura(Auras.Doton))
            //    {
            //        Utilities.Routines.Ninja.TCJState = 2;
            //    }
            //    if (Utilities.Routines.Ninja.AoeEnemies5Yards < 2 && Utilities.Routines.Ninja.TCJState == 0)
            //    {
            //        Utilities.Routines.Ninja.TCJState = 1;
            //    }

            //    if (Utilities.Routines.Ninja.TCJState == 1)
            //    {
            //        if (Casting.LastSpell == Spells.Chi)
            //        {
            //            Utilities.Routines.Ninja.TCJState = 0;
            //            return await Spells.Jin.Cast(Core.Me.CurrentTarget);
            //        }

            //        if (Casting.LastSpell == Spells.Ten)
            //        {
            //            return await Spells.Chi.Cast(Core.Me.CurrentTarget);
            //        }

            //        return await Spells.Ten.Cast(Core.Me.CurrentTarget);
            //    }

            //    if (Utilities.Routines.Ninja.TCJState == 2)
            //    {
            //        if (Casting.LastSpell == Spells.Jin)
            //        {
            //            Utilities.Routines.Ninja.TCJState = 0;
            //            return await Spells.Chi.Cast(Core.Me);
            //        }

            //        if (Casting.LastSpell == Spells.Ten)
            //        {
            //            return await Spells.Jin.Cast(Core.Me.CurrentTarget);
            //        }

            //        return await Spells.Ten.Cast(Core.Me.CurrentTarget);
            //    }
            //}
            if (Ninjutsu.ForceRaiton())
            {
                return(true);
            }
            if (Spells.SpinningEdge.Cooldown.TotalMilliseconds > 650)
            {
                //Utility Force Toggle
                if (await PhysicalDps.ArmsLength(NinjaSettings.Instance))
                {
                    return(true);
                }
                if (await Utility.SecondWindForce())
                {
                    return(true);
                }
                if (await Utility.ShadeShift())
                {
                    return(true);
                }
                if (await Utility.TrueNorth())
                {
                    return(true);
                }
                if (await Utility.Feint())
                {
                    return(true);
                }
                if (await Utility.BloodBath())
                {
                    return(true);
                }

                if (await PhysicalDps.SecondWind(NinjaSettings.Instance))
                {
                    return(true);
                }

                //if (await PhysicalDps.SecondWind(NinjaSettings.Instance)) return true;
                if (await SingleTarget.TrickAttack())
                {
                    return(true);
                }
                if (await Ninjutsu.TenChiJin())
                {
                    return(true);
                }
                if (await Buff.Meisui())
                {
                    return(true);
                }
                //if (await Buff.TrueNorth()) return true;
                //if (await Buff.ShadeShift()) return true;
                if (await Buff.Bunshin())
                {
                    return(true);
                }
                if (await SingleTarget.Assassinate())
                {
                    return(true);
                }
                if (await Aoe.HellfrogMedium())
                {
                    return(true);
                }
                if (await SingleTarget.Bhavacakra())
                {
                    return(true);
                }
                if (await SingleTarget.Mug())
                {
                    return(true);
                }
                if (await Buff.Kassatsu())
                {
                    return(true);
                }
                if (await SingleTarget.DreamWithinADream())
                {
                    return(true);
                }
            }
            if (await SingleTarget.ShadowFang())
            {
                return(true);
            }

            //Ninjutsu
            if (NinjutsuCheck())
            {
                if (Ninjutsu.Huton())
                {
                    return(true);
                }
                if (Ninjutsu.GokaMekkyaku())
                {
                    return(true);
                }
                if (Ninjutsu.Doton())
                {
                    return(true);
                }
                if (Ninjutsu.Katon())
                {
                    return(true);
                }
                if (Ninjutsu.Suiton())
                {
                    return(true);
                }
                if (Ninjutsu.HyoshoRanryu())
                {
                    return(true);
                }
                if (Ninjutsu.Raiton())
                {
                    return(true);
                }
                //if (Ninjutsu.FumaShuriken()) return true;
            }

            if (await Aoe.HakkeMujinsatsu())
            {
                return(true);
            }
            if (await Aoe.DeathBlossom())
            {
                return(true);
            }
            if (await SingleTarget.ArmorCrush())
            {
                return(true);
            }
            if (await SingleTarget.AeolianEdge())
            {
                return(true);
            }
            if (await SingleTarget.GustSlash())
            {
                return(true);
            }
            return(await SingleTarget.SpinningEdge());
        }