Пример #1
0
        public static Composite CreateShamanElementalInstancePullAndCombat()
        {
            return(new PrioritySelector(
                       Safers.EnsureTarget(),
                       Movement.CreateMoveToLosBehavior(),
                       Movement.CreateFaceTargetBehavior(),
                       Spell.WaitForCast(true),
                       Helpers.Common.CreateInterruptSpellCast(ret => StyxWoW.Me.CurrentTarget),

                       Common.CreateShamanImbueMainHandBehavior(Imbue.Flametongue),

                       Spell.BuffSelf("Lightning Shield"),
                       Spell.BuffSelf("Spiritwalker's Grace", ret => StyxWoW.Me.IsMoving && StyxWoW.Me.Combat),

                       Spell.BuffSelf("Elemental Mastery", ret => StyxWoW.Me.Combat),

                       Totems.CreateTotemsInstanceBehavior(),

                       new Decorator(
                           ret => Unit.UnfriendlyUnitsNearTarget(10f).Count() >= 3,
                           new PrioritySelector(
                               new Action(act => { Logger.WriteDebug("performing aoe behavior"); return RunStatus.Failure; }),
                               Spell.CastOnGround("Earthquake", ret => StyxWoW.Me.CurrentTarget.Location),
                               Spell.Cast("Chain Lightning", ret => Clusters.GetBestUnitForCluster(Unit.UnfriendlyUnitsNearTarget(15f), ClusterType.Chained, 12))
                               )),

                       Spell.Buff("Flame Shock", true),
                       Spell.Cast("Lava Burst"),
                       Spell.Cast("Earth Shock",
                                  ret => StyxWoW.Me.HasAura("Lightning Shield", 5) &&
                                  StyxWoW.Me.CurrentTarget.GetAuraTimeLeft("Flame Shock", true).TotalSeconds > 3),
                       Spell.Cast("Unleash Elements",
                                  ret => StyxWoW.Me.IsMoving &&
                                  !StyxWoW.Me.HasAura("Spiritwalker's Grace") &&
                                  Common.IsImbuedForDPS(StyxWoW.Me.Inventory.Equipped.MainHand)),
                       Spell.Cast("Chain Lightning", ret => Unit.UnfriendlyUnitsNearTarget(10f).Count() >= 2),
                       Spell.Cast("Lightning Bolt"),
                       Movement.CreateMoveToTargetBehavior(true, 35f)
                       ));
        }