public void Run() { var killableRendTarget = HeroManager.Enemies.FirstOrDefault(enemy => enemy.IsValidTarget(Variables.spells[SpellSlot.E].Range) && KalistaE.CanBeRendKilled(enemy)); if (killableRendTarget != null && (killableRendTarget.NetworkId != Variables.Orbwalker.GetTarget().NetworkId) && (Environment.TickCount - LastCastTime > 250)) { Variables.spells[SpellSlot.E].Cast(); LastCastTime = Environment.TickCount; } }
public void Run() { var minions = GameObjects.EnemyMinions.Where( minion => minion.IsValidTarget(Variables.spells[SpellSlot.E].Range) && minion.HasRend() && KalistaE.CanBeRendKilled(minion)); var heroWithRendStack = HeroManager.Enemies.Where( target => target.IsValidTarget(Variables.spells[SpellSlot.E].Range) && target.HasRend() && target.GetRendBuff().Count >= 3).OrderByDescending(KalistaE.GetRendDamage).FirstOrDefault(); if (heroWithRendStack != null && minions.Any() && heroWithRendStack.Distance(ObjectManager.Player) < Orbwalking.GetRealAutoAttackRange(null) * 1.4f && (Environment.TickCount - LastCastTime > 250) && heroWithRendStack.HealthPercent >= 35) { Variables.spells[SpellSlot.E].Cast(); LastCastTime = Environment.TickCount; } }