private void LogicE() { if (Player.Mana > RMANA + EMANA && Config.Item("autoE").GetValue <bool>()) { foreach (var enemy in Program.Enemies.Where(enemy => enemy.IsValidTarget(E.Range) && !OktwCommon.CanMove(enemy) && Game.Time - grabTime > 1)) { E.Cast(enemy.Position, true); return; } if (Config.Item("telE").GetValue <bool>()) { foreach (var Object in ObjectManager.Get <Obj_AI_Base>().Where(Obj => Obj.Distance(Player.ServerPosition) < E.Range && Obj.Team != Player.Team && (Obj.HasBuff("teleport_target", true) || Obj.HasBuff("Pantheon_GrandSkyfall_Jump", true)))) { E.Cast(Object.Position); } } if (Program.Combo && Player.IsMoving && Config.Item("comboE").GetValue <bool>() && Player.Mana > RMANA + EMANA + WMANA) { var t = TargetSelector.GetTarget(E.Range, TargetSelector.DamageType.Physical); if (t.IsValidTarget(E.Range) && E.GetPrediction(t).CastPosition.Distance(t.Position) > 200 && (int)E.GetPrediction(t).Hitchance == 5) { if (t.HasBuffOfType(BuffType.Slow) || OktwCommon.CountEnemiesInRangeDeley(E.GetPrediction(t).CastPosition, 250, E.Delay) > 1) { Program.CastSpell(E, t); debug("E slow"); } else { if (E.GetPrediction(t).CastPosition.Distance(t.Position) > 200) { if (Player.Position.Distance(t.ServerPosition) > Player.Position.Distance(t.Position)) { if (t.Position.Distance(Player.ServerPosition) < t.Position.Distance(Player.Position)) { Program.CastSpell(E, t); } } else { if (t.Position.Distance(Player.ServerPosition) > t.Position.Distance(Player.Position)) { Program.CastSpell(E, t); } } } } } } } }