private void Game_OnUpdate(EventArgs args) { if (!azir.Spells.R.IsReady()) { return; } var insecPoint = new Vector3(0, 2, 3); if (Clickposition == new Vector3(0, 0, 0)) { insecPoint = Game.CursorPos; } else { insecPoint = Clickposition; } if (!azir.Menu.GetMenu.Item("inseckey").GetValue <KeyBind>().Active) { steps = Steps.firstCalcs; soldier = null; return; } azir.Orbwalk(Game.CursorPos); if (!insecPoint.IsValid()) { return; } var target = TargetSelector.GetSelectedTarget(); if (target == null) { return; } if (!target.IsValidTarget() || target.IsZombie) { steps = Steps.firstCalcs; return; } var insecPos = new Vector3(0, 0, 0); if (Clickposition == new Vector3(0, 0, 0)) { insecPos = Game.CursorPos; } else { insecPos = insecPoint; } var postoGo = target.ServerPosition; switch (steps) { case Steps.firstCalcs: if (target.Distance(HeroManager.Player) <= azir.Spells.W.Range + azir.Spells.Q.Range - 100) { steps = Steps.jump; } break; case Steps.jump: if (HeroManager.Player.ServerPosition.Distance(postoGo) <= 220) { steps = Steps.R; } else { azir._modes._jump.updateLogicJumpInsec(postoGo); } break; case Steps.R: if (azir.Hero.Distance(target) < 220) { var tower = ObjectManager.Get <Obj_AI_Turret>().FirstOrDefault(it => it.IsValidTarget(1000)); if (tower != null) { azir.Spells.R.Cast(tower.ServerPosition); steps = Steps.firstCalcs; } else { azir.Spells.R.Cast(insecPoint); steps = Steps.firstCalcs; } } break; } }
protected override void Combo() { bool useE = RootMenu["combo"]["usee"].Enabled; bool useW = RootMenu["combo"]["usew"].Enabled; bool useQ = RootMenu["combo"]["useq"].Enabled; bool useQAA = RootMenu["combo"]["qaa"].Enabled; if (useE) { var target = Extensions.GetBestEnemyHeroTargetInRange(E.Range - 80); if (target.IsValidTarget()) { if (target.IsValidTarget(E.Range) && target.Distance(Player) > 300) { if (target != null) { E.Cast(Vector3Extensions.To2D(target.ServerPosition) .Extend(Vector3Extensions.To2D(Player.ServerPosition), -150).To3D()); } } } } if (useW) { var target = Extensions.GetBestEnemyHeroTargetInRange(W.Range); if (target.IsValidTarget()) { if (target.IsValidTarget(RootMenu["combo"]["wmin"].As <MenuSlider>().Value)) { if (target != null) { W.Cast(Vector3Extensions.To2D(Player.ServerPosition).Extend(Vector3Extensions.To2D(target.ServerPosition), 300).To3D()); } } } } if (useQ) { var target = Extensions.GetBestEnemyHeroTargetInRange(Q.Range); if (target.IsValidTarget()) { if (target.IsValidTarget(Q.Range) && !useQAA) { if (target != null) { Q.Cast(); } } } } if (RootMenu["combo"]["user"].Enabled && Player.HealthPercent() <= RootMenu["combo"]["health"].As <MenuSlider>().Value) { var target = Extensions.GetBestEnemyHeroTargetInRange(R.Range); if (target.IsValidTarget()) { if (target.IsValidTarget(R.Range)) { var meow = TargetSelector.GetSelectedTarget(); if (target != null) { if (meow != null) { R.Cast(meow); } switch (RootMenu["combo"]["mode"].As <MenuList>().Value) { case 0: foreach (var ally in GameObjects.EnemyHeroes.Where( x => x.Distance(Player) <= R.Range && x != null) .OrderByDescending(x => x.TotalAttackDamage)) { if (ally != null && !ally.IsDead && !RootMenu["blacklist"][ally.ChampionName.ToLower()].Enabled) { R.Cast(target); } } break; case 1: foreach (var ally in GameObjects.EnemyHeroes.Where( x => x.Distance(Player) <= R.Range && x != null) .OrderByDescending(x => x.TotalAbilityDamage)) { if (ally != null && !ally.IsDead && !RootMenu["blacklist"][ally.ChampionName.ToLower()].Enabled) { R.Cast(ally); } } break; case 2: foreach (var ally in GameObjects.EnemyHeroes.Where( x => x.Distance(Player) <= R.Range && x != null) .OrderByDescending(x => x.MaxHealth)) { if (ally != null && !ally.IsDead && !RootMenu["blacklist"][ally.ChampionName.ToLower()].Enabled) { R.Cast(ally); } } break; case 3: foreach (var ally in GameObjects.EnemyHeroes.Where( x => x.Distance(Player) <= R.Range && x != null) .OrderByDescending(x => x.Armor)) { if (ally != null && !ally.IsDead && !RootMenu["blacklist"][ally.ChampionName.ToLower()].Enabled) { R.Cast(ally); } } break; } } } } } }
protected override void Game_OnGameUpdate(EventArgs args) { //check if player is dead if (Player.IsDead) { return; } SmartKs(); if (menu.Item("escape", true).GetValue <KeyBind>().Active) { OrbwalkManager.Orbwalk(null, Game.CursorPos); Escape(); } else if (menu.Item("ComboActive", true).GetValue <KeyBind>().Active) { Combo(); } else if (menu.Item("insec", true).GetValue <KeyBind>().Active) { OrbwalkManager.Orbwalk(null, Game.CursorPos); _insecTarget = TargetSelector.GetSelectedTarget(); if (_insecTarget != null) { if (_insecTarget.HasBuffOfType(BuffType.Knockup) || _insecTarget.HasBuffOfType(BuffType.Knockback)) { if (Player.ServerPosition.Distance(_insecTarget.ServerPosition) < 200) { R2.Cast(_rVec); } } Insec(); } } else if (menu.Item("qeCombo", true).GetValue <KeyBind>().Active) { var soldierTarget = TargetSelector.GetTarget(900, TargetSelector.DamageType.Magical); OrbwalkManager.Orbwalk(null, Game.CursorPos); CastQe(soldierTarget, "Null"); } else { if (menu.Item("LaneClearActive", true).GetValue <KeyBind>().Active) { Farm(); } if (menu.Item("HarassActive", true).GetValue <KeyBind>().Active) { Harass(); } if (menu.Item("HarassActiveT", true).GetValue <KeyBind>().Active) { Harass(); } if (menu.Item("wAtk", true).GetValue <bool>()) { AutoAtk(); } } }
private void Combo() { AIHeroClient target = getTarget(); if (target == null) { return; } if (config.Item("selected").GetValue <bool>()) { target = CombatHelper.SetTarget(target, TargetSelector.GetSelectedTarget()); orbwalker.ForceTarget(target); } var cmbDmg = GetComboDamage(target); if (config.Item("useItems").GetValue <bool>()) { ItemHandler.UseItems(target, config, cmbDmg); } if (config.Item("useq", true).GetValue <bool>() && Q.IsReady() && target.IsValidTarget() && !justJumped) { if (Program.IsSPrediction) { Q.SPredictionCast(target, HitChance.High); return; } else { var targQ = Q.GetPrediction(target); if (Q.Range - 100 > targQ.CastPosition.Distance(player.Position) && targQ.Hitchance >= HitChance.High) { Q.Cast(targQ.CastPosition); return; } } } if (config.Item("usew", true).GetValue <bool>() && W.IsReady() && !justJumped && (cmbDmg + player.GetAutoAttackDamage(target) > target.Health || player.Mana > Q.Instance.SData.Mana * 2)) { if (Program.IsSPrediction) { W.SPredictionCast(target, HitChance.High); return; } else { var tarPered = W.GetPrediction(target); if (W.Range - 80 > tarPered.CastPosition.Distance(player.Position)) { W.CastIfHitchanceEquals(target, HitChance.High); return; } } } if (R.IsReady() && !justJumped) { var dist = player.Distance(target); if (config.Item("user", true).GetValue <bool>() && !justQ && !Q.CanCast(target) && !justW && !W.CanCast(target) && !CombatHelper.CheckCriticalBuffs(target) && config.Item("usermin", true).GetValue <Slider>().Value < dist && 3000 > dist && target.Health < R.GetDamage(target) * 0.7 && target.CountAlliesInRange(600) < 1) { R.CastIfHitchanceEquals(target, HitChance.High); } if (target.CountAlliesInRange(700) > 0) { R.CastIfWillHit(target, config.Item("usertf", true).GetValue <Slider>().Value); } } bool canKill = cmbDmg > target.Health; if (config.Item("usee", true).GetValue <bool>() && E.IsReady() && ((config.Item("useekill", true).GetValue <bool>() && canKill) || (!config.Item("useekill", true).GetValue <bool>() && (target.CountEnemiesInRange(1200) <= target.CountAlliesInRange(1200) && player.Health > target.Health && TargetSelector.GetPriority(target) >= 2f) || canKill))) { var bestPositons = (from pos in CombatHelper.PointsAroundTheTarget(target.Position, 750) .Where( p => !p.IsWall() && p.IsValid() && p.Distance(player.Position) < E.Range && p.Distance(target.Position) < 680 && !p.UnderTurret(true)) let mob = ObjectManager.Get <Obj_AI_Base>() .Where( m => m.IsEnemy && m.IsValidTarget() && m.Distance(target.Position) < 750 && m.BaseSkinName != target.BaseSkinName) .OrderBy(m => m.Distance(pos)) .FirstOrDefault() where (mob != null && mob.Distance(pos) > pos.Distance(target.Position) + 80) || (mob == null) select pos).ToList(); CastE(bestPositons, target); } var ignitedmg = (float)player.GetSummonerSpellDamage(target, Damage.SummonerSpell.Ignite); bool hasIgnite = player.Spellbook.CanUseSpell(player.GetSpellSlot("SummonerDot")) == SpellState.Ready; if (config.Item("useIgnite", true).GetValue <bool>() && ignitedmg > target.Health && hasIgnite && !player.IsChannelingImportantSpell() && !justQ && !Q.CanCast(target) && !justW && !W.CanCast(target) && !justJumped) { player.Spellbook.CastSpell(player.GetSpellSlot("SummonerDot"), target); } }
private static void Game_OnGameUpdate(EventArgs args) { try { if (ObjectManager.Player.IsDead || ObjectManager.Player.IsRecalling()) { return; } /*if (MyMenu.Menu.Item("bSharpOn").GetValue<KeyBind>().Active) * { * Misc.Orbwalk(Game.CursorPos); * * var t = TargetSelector.GetTarget(1000 + spells[Spells.W].Range, TargetSelector.DamageType.Physical); * if (t != null) * { * BubbaSharp.BubbKushGo(t); * } * }*/ if ((doubleClickReset <= Environment.TickCount) && (clickCount != 0)) { doubleClickReset = float.MaxValue; clickCount = 0; } if (clickCount >= 2) { resetTime = Environment.TickCount + 3000; InsecManager.ClicksecEnabled = true; InsecManager.InsecClickPos = Game.CursorPos; clickCount = 0; } if ((resetTime <= Environment.TickCount) && !MyMenu.Menu.Item("InsecEnabled").GetValue <KeyBind>().Active && InsecManager.ClicksecEnabled) { InsecManager.ClicksecEnabled = false; } if (q2Timer <= Environment.TickCount) { q2Done = false; } if ((Misc.GetMenuItem("insecMode") ? TargetSelector.GetSelectedTarget() : TargetSelector.GetTarget(spells[Spells.Q].Range, TargetSelector.DamageType.Physical)) == null) { InsecManager.insecComboStep = InsecManager.InsecComboStepSelect.None; } if (MyMenu.Menu.Item("starCombo").GetValue <KeyBind>().Active) { StarCombo(); } if (MyMenu.Menu.Item("ElLeeSin.Wardjump").GetValue <KeyBind>().Active) { Wardmanager.WardjumpToMouse(); } switch (Orbwalker.ActiveMode) { case Orbwalking.OrbwalkingMode.Combo: Combo(); break; case Orbwalking.OrbwalkingMode.LaneClear: LaneClear(); JungleClear(); break; case Orbwalking.OrbwalkingMode.Mixed: Harass(); break; } if (Misc.GetMenuItem("ElLeeSin.Ignite.KS") && igniteSlot != SpellSlot.Unknown) { var newTarget = TargetSelector.GetTarget(600f, TargetSelector.DamageType.True); if (newTarget != null && ((ObjectManager.Player.Spellbook.CanUseSpell(igniteSlot) == SpellState.Ready) && (ObjectManager.Player.GetSummonerSpellDamage(newTarget, Damage.SummonerSpell.Ignite) > newTarget.Health))) { ObjectManager.Player.Spellbook.CastSpell(igniteSlot, newTarget); } } if (MyMenu.Menu.Item("InsecEnabled").GetValue <KeyBind>().Active) { if (Misc.GetMenuItem("insecOrbwalk")) { Misc.Orbwalk(Game.CursorPos); } var newTarget = Misc.GetMenuItem("insecMode") ? (TargetSelector.GetSelectedTarget() ?? TargetSelector.GetTarget( spells[Spells.Q].Range, TargetSelector.DamageType.Physical)) : TargetSelector.GetTarget( spells[Spells.Q].Range, TargetSelector.DamageType.Physical); if (newTarget != null) { InsecManager.InsecCombo(newTarget); } } else { InsecManager.isNullInsecPos = true; wardJumped = false; } if (Orbwalker.ActiveMode != Orbwalking.OrbwalkingMode.Combo) { InsecManager.insecComboStep = InsecManager.InsecComboStepSelect.None; } if (MyMenu.Menu.Item("ElLeeSin.Insec.UseInstaFlash").GetValue <KeyBind>().Active) { var target = TargetSelector.GetTarget(spells[Spells.R].Range, TargetSelector.DamageType.Physical); if (target == null) { return; } if (spells[Spells.R].IsReady() && !target.IsZombie && (ObjectManager.Player.Spellbook.CanUseSpell(flashSlot) == SpellState.Ready) && target.IsValidTarget(spells[Spells.R].Range)) { spells[Spells.R].CastOnUnit(target); } } if (spells[Spells.R].IsReady() && Misc.GetMenuItem("ElLeeSin.Combo.New") && !MyMenu.Menu.Item("InsecEnabled").GetValue <KeyBind>().Active && !MyMenu.Menu.Item("ElLeeSin.Wardjump").GetValue <KeyBind>().Active && !MyMenu.Menu.Item("ElLeeSin.Insec.UseInstaFlash").GetValue <KeyBind>().Active) { KnockUp(); } if (spells[Spells.R].IsReady() && Misc.GetMenuItem("ElLeeSin.Combo.New.R.Kill") && !MyMenu.Menu.Item("InsecEnabled").GetValue <KeyBind>().Active && !MyMenu.Menu.Item("ElLeeSin.Wardjump").GetValue <KeyBind>().Active && !MyMenu.Menu.Item("ElLeeSin.Insec.UseInstaFlash").GetValue <KeyBind>().Active) { KnockUpKill(); } } catch (Exception e) { Console.WriteLine("An error occurred: '{0}'", e); } }
internal static void InitSpellCast(Obj_AI_Base sender, GameObjectProcessSpellCastEventArgs Args) { if (sender == null || !sender.IsMe || Args.SData == null) { return; } switch (Args.SData.Name) { case "ItemTiamatCleave": switch (Orbwalker.ActiveMode) { case Orbwalking.OrbwalkingMode.Combo: if (!HeroManager.Enemies.Any(x => x.DistanceToPlayer() <= W.Range)) { return; } if (Menu.GetBool("ComboW") && W.IsReady()) { W.Cast(); } break; case Orbwalking.OrbwalkingMode.Burst: var ForcusTarget = TargetSelector.GetSelectedTarget(); var fortarget = ForcusTarget; if (fortarget != null && !fortarget.IsDead && !fortarget.IsZombie) { if (W.IsReady() && fortarget.IsValidTarget(W.Range)) { W.Cast(true); } } break; case Orbwalking.OrbwalkingMode.Mixed: if (!HeroManager.Enemies.Any(x => x.DistanceToPlayer() <= W.Range)) { return; } if (Menu.GetBool("HarassW") && W.IsReady()) { W.Cast(true); } break; case Orbwalking.OrbwalkingMode.LaneClear: if (Menu.GetBool("JungleClearW") && W.IsReady()) { var mobs = MinionManager.GetMinions(Me.Position, W.Range, MinionTypes.All, MinionTeam.Neutral); if (mobs.Any()) { W.Cast(true); } } break; } break; case "RivenTriCleave": switch (Orbwalker.ActiveMode) { case Orbwalking.OrbwalkingMode.Combo: SpellManager.CastItem(true); if (Menu.GetBool("ComboR") && R.IsReady() && R.Instance.Name == "RivenFengShuiEngine") { var target = TargetSelector.GetSelectedTarget() ?? TargetSelector.GetTarget(R.Range, TargetSelector.DamageType.Physical); if (target.IsValidTarget(R.Range)) { SpellManager.R2Logic(target); } } break; case Orbwalking.OrbwalkingMode.Burst: SpellManager.CastItem(true); if (R.IsReady() && R.Instance.Name == "RivenFengShuiEngine") { var ForcusTarget = TargetSelector.GetSelectedTarget(); if (ForcusTarget.IsValidTarget(R.Range)) { R.Cast(ForcusTarget.Position, true); } } break; } break; case "RivenTriCleaveBuffer": switch (Orbwalker.ActiveMode) { case Orbwalking.OrbwalkingMode.Combo: if (Menu.GetBool("ComboR") && R.IsReady() && R.Instance.Name == "RivenFengShuiEngine") { var target = TargetSelector.GetSelectedTarget() ?? TargetSelector.GetTarget(R.Range, TargetSelector.DamageType.Physical); if (target.IsValidTarget(R.Range)) { SpellManager.R2Logic(target); } } break; case Orbwalking.OrbwalkingMode.Burst: if (R.IsReady() && R.Instance.Name == "RivenFengShuiEngine") { var ForcusTarget = TargetSelector.GetSelectedTarget(); if (ForcusTarget.IsValidTarget(R.Range)) { R.Cast(ForcusTarget.Position, true); } } break; } break; case "RivenMartyr": if ((Orbwalking.isCombo || Orbwalking.isBurst) && HeroManager.Enemies.Any(x => x.DistanceToPlayer() <= 400)) { SpellManager.CastItem(true); } break; case "RivenFeint": if (!R.IsReady()) { return; } switch (Orbwalker.ActiveMode) { case Orbwalking.OrbwalkingMode.Combo: var target = TargetSelector.GetSelectedTarget() ?? TargetSelector.GetTarget(R.Range, TargetSelector.DamageType.Physical); if (target.IsValidTarget(R.Range)) { switch (R.Instance.Name) { case "RivenFengShuiEngine": if (Menu.GetKey("R1Combo")) { if (target.DistanceToPlayer() <= 500 && HeroManager.Enemies.Any(x => x.DistanceToPlayer() <= 500)) { R.Cast(true); } } break; case "RivenIzunaBlade": SpellManager.R2Logic(target); break; } } break; case Orbwalking.OrbwalkingMode.Burst: if (TargetSelector.GetSelectedTarget().IsValidTarget(R.Range)) { switch (R.Instance.Name) { case "RivenFengShuiEngine": R.Cast(); break; case "RivenIzunaBlade": var ForcusTarget = TargetSelector.GetSelectedTarget(); if (ForcusTarget.IsValidTarget(R.Range)) { R.Cast(ForcusTarget.Position, true); } break; } } break; } break; case "RivenIzunaBlade": switch (Orbwalker.ActiveMode) { case Orbwalking.OrbwalkingMode.Combo: var target = TargetSelector.GetSelectedTarget() ?? TargetSelector.GetTarget(R.Range, TargetSelector.DamageType.Physical); if (target != null && target.IsValidTarget()) { if (Q.IsReady() && target.IsValidTarget(Q.Range)) { SpellManager.CastQ(target); } else if (W.IsReady() && target.IsValidTarget(W.Range)) { W.Cast(); } } break; case Orbwalking.OrbwalkingMode.Burst: var ForcusTarget = TargetSelector.GetSelectedTarget(); if (ForcusTarget.IsValidTarget()) { if (ForcusTarget.IsValidTarget(Q.Range)) { SpellManager.CastQ(ForcusTarget); } else if (ForcusTarget.IsValidTarget(W.Range) && W.IsReady()) { W.Cast(); } } break; } break; } }
public static void Combo() { if (Selected()) { var target = TargetSelector.GetSelectedTarget(); CheckE(target); float a = Player.Distance(target.Position); if (a > Q.Range && a <= 1200) { if (R.IsReady() && Rstate != 4 && W.IsReady() && Wstate != 2 && Menu.Item("Use W Combo").GetValue <bool>()) { W.Cast(Player.Position.Extend(target.Position, 600)); } } if (a <= Q.Range) { if (Ecol == 1) { if (W.IsReady() && Wstate != 2) { useW(); useQ(); useR(); useE(); } if (!W.IsReady() && Wstate == 1 && R.IsReady() && Rstate == 2) { useR(); useQ(); useE(); useW(); } else { useQ(); useR(); useE(); useW(); } } if (Ecol == 0) { useQ(); useR(); useE(); if (!(R.IsReady() && Rstate == 1)) { useW(); } } } } else { var target = TargetSelector.GetTarget(Q.Range, TargetSelector.DamageType.Magical); if (target != null) { CheckE(target); if (Ecol == 1) { if (W.IsReady() && Wstate != 2) { useW(); useQ(); useR(); useE(); } if (!W.IsReady() && Wstate == 1 && R.IsReady() && Rstate == 2) { useR(); useQ(); useE(); useW(); } else { useQ(); useR(); useE(); useW(); } } if (Ecol == 0) { useQ(); useR(); useE(); if (!(R.IsReady() && Rstate == 1)) { useW(); } } } else { var target1 = TargetSelector.GetTarget(1200, TargetSelector.DamageType.Magical); if (target1 != null) { if (R.IsReady() && Rstate != 4 && W.IsReady() && Wstate != 2 && Menu.Item("Use W Combo").GetValue <bool>()) { W.Cast(Player.Position.Extend(target1.Position, 600)); } } } } }
/// <summary> /// insec debug (rectangle alert) /// </summary> public static void InsecDebug() { if (TargetSelector.GetSelectedTarget().IsValidTarget(Spells.Q2.Range)) { var xx = new Geometry.Rectangle(ObjectManager.Player.Position.To2D(), TargetSelector.GetSelectedTarget().Position.To2D(), 50); xx.ToPolygon().Draw(Color.Gold, 3); var xy = new Geometry.Rectangle(TargetSelector.GetSelectedTarget().Position.To2D(), Insec.InsecPositions(TargetSelector.GetSelectedTarget()).To2D(), 50); xy.ToPolygon().Draw(Color.Azure, 3); Render.Circle.DrawCircle(InsecPositions(TargetSelector.GetSelectedTarget()), 50, Color.Gold, 3); } }
public static void ClickInsec() { if (Program.Config.Item("obj.usage").GetValue <bool>()) { if (Program.Config.Item("flash.usage").GetValue <bool>()) { AIHeroClient selectedTarget = TargetSelector.GetSelectedTarget(); var wardjumpflashrange = Spells.W.Range + 424; var insecpos = InsecPositions(TargetSelector.GetSelectedTarget()); var insecposex = InsecPositions(TargetSelector.GetSelectedTarget()) .Extend(ObjectManager.Player.Position, wardjumpflashrange); var obj = ObjectManager.Get <Obj_AI_Base>().Where(x => x.IsEnemy && x.IsValidTarget(Spells.Q.Range) && x.Distance(insecpos) < wardjumpflashrange && x.Distance(insecpos) > 20 && Spells.Q.GetPrediction(x).Hitchance >= HitChance.High && !x.Name.ToLower().Contains("turret") && x.Name != TargetSelector.GetSelectedTarget().Name) .OrderBy(o => o.Distance(insecposex)).FirstOrDefault(x => x.Health > Spells.Q.GetDamage(x)); if (obj != null) { if (Spells.Q.CanCast(obj)) { Spells.Q.Cast(obj); } if (Spells.Q.Instance.Name != "BlindMonkQOne" && Spells.Q2.IsReady()) { Spells.Q2.Cast(); } if (!Spells.Q.IsReady() && !Spells.Q2.IsReady() && Spells.W.IsReady() && Spells.W.Instance.Name == "BlindMonkWOne") { WardJump.HikiJump(obj.Position.Extend(selectedTarget.Position, 424)); } if (!Spells.Q.IsReady() && !Spells.Q2.IsReady() && Spells.W.Instance.Name != "BlindMonkWOne" && Spells.R.CanCast(selectedTarget)) { LeagueSharp.Common.Utility.DelayAction.Add(30, () => ObjectManager.Player.Spellbook.CastSpell(ObjectManager.Player.GetSpellSlot("SummonerFlash"), insecpos)); } if (!Spells.Q.IsReady() && !Spells.Q2.IsReady() && Spells.W.Instance.Name != "BlindMonkWOne" && Spells.R.CanCast(selectedTarget)) { Spells.R.CastOnUnit(selectedTarget); } } else { AIHeroClient selectedTargetx = TargetSelector.GetSelectedTarget(); if (selectedTargetx != null && Spells.Q.GetPrediction(selectedTargetx).Hitchance >= HitChance.High) { if (Spells.Q.CanCast(selectedTargetx) && Spells.Q.GetPrediction(selectedTargetx).Hitchance > HitChance.High) { Spells.Q.Cast(selectedTargetx); } if (Spells.Q.Instance.Name != "BlindMonkQOne" && Spells.Q2.IsReady()) { Spells.Q2.Cast(); } if (!Spells.Q.IsReady() && !Spells.Q2.IsReady() && Spells.W.IsReady() && Spells.W.Instance.Name == "BlindMonkWOne") { InsecTo(selectedTargetx); } if (!Spells.Q.IsReady() && !Spells.Q2.IsReady() && Spells.W.Instance.Name != "BlindMonkWOne" && Spells.R.CanCast(selectedTargetx)) { Spells.R.CastOnUnit(selectedTargetx); } } } } else { AIHeroClient selectedTarget = TargetSelector.GetSelectedTarget(); var insecpos = InsecPositions(TargetSelector.GetSelectedTarget()); var obj = ObjectManager.Get <Obj_AI_Base>().Where(x => x.IsEnemy && x.IsValidTarget(Spells.Q.Range) && x.Distance(insecpos) < Spells.W.Range && x.Distance(insecpos) > 20 && Spells.Q.GetPrediction(x).Hitchance >= HitChance.High && x.Name != TargetSelector.GetSelectedTarget().Name) .OrderBy(o => o.Distance(insecpos)).FirstOrDefault(x => x.Health > Spells.Q.GetDamage(x)); if (obj != null) { if (Spells.Q.CanCast(obj)) { Spells.Q.Cast(obj); } if (Spells.Q.Instance.Name != "BlindMonkQOne" && Spells.Q2.IsReady()) { Spells.Q2.Cast(); } if (!Spells.Q.IsReady() && !Spells.Q2.IsReady() && Spells.W.IsReady() && Spells.W.Instance.Name == "BlindMonkWOne") { WardJump.HikiJump(insecpos); } if (!Spells.Q.IsReady() && !Spells.Q2.IsReady() && Spells.W.Instance.Name != "BlindMonkWOne" && Spells.R.CanCast(selectedTarget)) { Spells.R.CastOnUnit(selectedTarget); } } else { AIHeroClient selectedTargetx = TargetSelector.GetSelectedTarget(); if (selectedTargetx != null && Spells.Q.GetPrediction(selectedTargetx).Hitchance >= HitChance.High) { if (Spells.Q.CanCast(selectedTargetx) && Spells.Q.GetPrediction(selectedTargetx).Hitchance > HitChance.High) { Spells.Q.Cast(selectedTargetx); } if (Spells.Q.Instance.Name != "BlindMonkQOne" && Spells.Q2.IsReady()) { Spells.Q2.Cast(); } if (!Spells.Q.IsReady() && !Spells.Q2.IsReady() && Spells.W.IsReady() && Spells.W.Instance.Name == "BlindMonkWOne") { InsecTo(selectedTargetx); } if (!Spells.Q.IsReady() && !Spells.Q2.IsReady() && Spells.W.Instance.Name != "BlindMonkWOne" && Spells.R.CanCast(selectedTargetx)) { Spells.R.CastOnUnit(selectedTargetx); } } } } } else { AIHeroClient selectedTarget = TargetSelector.GetSelectedTarget(); var insecpos = InsecPositions(TargetSelector.GetSelectedTarget()); var obj = ObjectManager.Get <Obj_AI_Base>().Where(x => x.IsEnemy && x.IsValidTarget(Spells.Q.Range) && x.Distance(insecpos) < 400 && x.Distance(insecpos) > 20 && Spells.Q.GetPrediction(x).Hitchance >= HitChance.High && x.Name != TargetSelector.GetSelectedTarget().Name) .OrderBy(o => o.Distance(insecpos)).FirstOrDefault(); if (selectedTarget != null && Spells.Q.GetPrediction(selectedTarget).Hitchance >= HitChance.High) { if (Spells.Q.CanCast(selectedTarget) && Spells.Q.GetPrediction(selectedTarget).Hitchance > HitChance.High) { Spells.Q.Cast(selectedTarget); } if (Spells.Q.Instance.Name != "BlindMonkQOne" && Spells.Q2.IsReady()) { Spells.Q2.Cast(); } if (!Spells.Q.IsReady() && !Spells.Q2.IsReady() && Spells.W.IsReady() && Spells.W.Instance.Name == "BlindMonkWOne") { InsecTo(selectedTarget); } if (!Spells.Q.IsReady() && !Spells.Q2.IsReady() && Spells.W.Instance.Name != "BlindMonkWOne" && Spells.R.CanCast(selectedTarget)) { Spells.R.CastOnUnit(selectedTarget); } } } }
public static void Init() { if (ObjectManager.Player.IsDead) { return; } if (EzrealMenu.Config.Item("ezreal.q.draw").GetValue <Circle>().Active&& EzrealSpells.Q.IsReady()) { Render.Circle.DrawCircle(ObjectManager.Player.Position, EzrealSpells.Q.Range, EzrealMenu.Config.Item("ezreal.q.draw").GetValue <Circle>().Color); } if (EzrealMenu.Config.Item("ezreal.w.draw").GetValue <Circle>().Active&& EzrealSpells.W.IsReady()) { Render.Circle.DrawCircle(ObjectManager.Player.Position, EzrealSpells.W.Range, EzrealMenu.Config.Item("ezreal.w.draw").GetValue <Circle>().Color); } if (EzrealMenu.Config.Item("ezreal.e.draw").GetValue <Circle>().Active&& EzrealSpells.E.IsReady()) { Render.Circle.DrawCircle(ObjectManager.Player.Position, EzrealSpells.E.Range, EzrealMenu.Config.Item("ezreal.e.draw").GetValue <Circle>().Color); } if (EzrealMenu.Config.Item("ezreal.r.draw").GetValue <Circle>().Active&& EzrealSpells.R.IsReady()) { Render.Circle.DrawCircle(ObjectManager.Player.Position, EzrealSpells.R.Range, EzrealMenu.Config.Item("ezreal.r.draw").GetValue <Circle>().Color); } if (!Helper.EEnabled("ezreal.disable.catch")) { var selectedtarget = TargetSelector.GetSelectedTarget(); if (selectedtarget != null) { var playerposition = Drawing.WorldToScreen(ObjectManager.Player.Position); var enemyposition = Drawing.WorldToScreen(selectedtarget.Position); if (Helper.EEnabled("ezreal.catch.line")) { if (Catcher.GapcloseCalculte(selectedtarget, EzrealSpells.E) < 0 && Catcher.Calculate(selectedtarget) < 0) { Drawing.DrawLine(playerposition, enemyposition, 2, Color.LawnGreen); } if (Catcher.GapcloseCalculte(selectedtarget, EzrealSpells.E) > 0 && Catcher.Calculate(selectedtarget) > 0) { Drawing.DrawLine(playerposition, enemyposition, 2, Color.Red); } if (Catcher.GapcloseCalculte(selectedtarget, EzrealSpells.E) < 0 && Catcher.Calculate(selectedtarget) > 0) { Drawing.DrawLine(playerposition, enemyposition, 2, Color.Orange); } } if (Helper.EEnabled("ezreal.catch.circle")) { if (Catcher.GapcloseCalculte(selectedtarget, EzrealSpells.E) < 0 && Catcher.Calculate(selectedtarget) < 0) { Render.Circle.DrawCircle(selectedtarget.Position, 100, Color.LawnGreen); } if (Catcher.GapcloseCalculte(selectedtarget, EzrealSpells.E) > 0 && Catcher.Calculate(selectedtarget) > 0) { Render.Circle.DrawCircle(selectedtarget.Position, 100, Color.Red); } if (Catcher.GapcloseCalculte(selectedtarget, EzrealSpells.E) < 0 && Catcher.Calculate(selectedtarget) > 0) { Render.Circle.DrawCircle(selectedtarget.Position, 100, Color.Orange); } } if (Helper.EEnabled("ezreal.catch.text")) { if (Catcher.GapcloseCalculte(selectedtarget, EzrealSpells.E) < 0 && Catcher.Calculate(selectedtarget) < 0) { Drawing.DrawText(playerposition.X, playerposition.Y, Color.LawnGreen, "Catch (Time): " + (int)Catcher.Calculate(selectedtarget)); if (EzrealSpells.E.IsReady()) { Drawing.DrawText(playerposition.X - 20, playerposition.Y - 20, Color.LawnGreen, "Catch With Gapclose (Time): " + (int)Catcher.GapcloseCalculte(selectedtarget, EzrealSpells.E)); } } if (Catcher.GapcloseCalculte(selectedtarget, EzrealSpells.E) > 0 && Catcher.Calculate(selectedtarget) > 0) { Drawing.DrawText(playerposition.X, playerposition.Y, Color.Red, "Catch (Time): " + (int)Catcher.Calculate(selectedtarget)); if (EzrealSpells.E.IsReady()) { Drawing.DrawText(playerposition.X - 20, playerposition.Y - 20, Color.Red, "Catch With Gapclose (Time): " + (int)Catcher.GapcloseCalculte(selectedtarget, EzrealSpells.E)); } } if (Catcher.GapcloseCalculte(selectedtarget, EzrealSpells.E) < 0 && Catcher.Calculate(selectedtarget) > 0) { Drawing.DrawText(playerposition.X, playerposition.Y, Color.Orange, "Catch (Time): " + (int)Catcher.Calculate(selectedtarget)); if (EzrealSpells.E.IsReady()) { Drawing.DrawText(playerposition.X - 20, playerposition.Y - 20, Color.Orange, "Catch With Gapclose (Time): " + (int)Catcher.GapcloseCalculte(selectedtarget, EzrealSpells.E)); } } } } } }
/// <summary> /// Object usage debug (cirlces) /// </summary> public static void ObjectUsageDebug() { if (TargetSelector.GetSelectedTarget() == null) { return; } AIHeroClient selectedTarget = TargetSelector.GetSelectedTarget(); var insecpos = InsecPositions(TargetSelector.GetSelectedTarget()); var obj = ObjectManager.Get <Obj_AI_Base>().Where(x => x.IsEnemy && x.IsValidTarget(Spells.Q.Range) && x.Distance(insecpos) < 400 && x.Distance(insecpos) > 20 && Spells.Q.GetPrediction(x).Hitchance >= HitChance.High && x.Name != TargetSelector.GetSelectedTarget().Name) .OrderBy(o => o.Distance(insecpos)).FirstOrDefault(); if (selectedTarget != null && obj != null && (obj.Team == GameObjectTeam.Neutral || obj.IsMinion || obj.IsChampion()) && (Spells.Q.GetPrediction(selectedTarget).Hitchance < HitChance.High || Spells.Q.GetPrediction(selectedTarget).Hitchance == HitChance.Collision || Spells.Q.GetPrediction(selectedTarget).Hitchance == HitChance.Impossible)) { Render.Circle.DrawCircle(obj.Position, 100, Color.Gold); } }
private void UseSpells(bool useQ, bool useW, bool useE, bool useR, string source) { var range = E.IsReady() ? E.Range : Q.Range; var focusSelected = menu.Item("selected", true).GetValue <bool>(); Obj_AI_Hero target = TargetSelector.GetTarget(range, TargetSelector.DamageType.Magical); if (TargetSelector.GetSelectedTarget() != null) { if (focusSelected && TargetSelector.GetSelectedTarget().Distance(Player.ServerPosition) < range) { target = TargetSelector.GetSelectedTarget(); } } int dfgMode = menu.Item("DFGMode", true).GetValue <StringList>().SelectedIndex; bool hasMana = ManaCheck2(); float dmg = GetComboDamage(target); var waitW = menu.Item("waitW", true).GetValue <bool>(); if (source == "Harass" && !HasMana("Harass")) { return; } if (useW && target != null && Player.Distance(target.Position) <= W.Range && W.IsReady()) { if (menu.Item("wPoke", true).GetValue <KeyBind>().Active) { var pred = W.GetPrediction(target); if (pred.Hitchance == HitChance.Immobile || IsStunned(target)) { W.Cast(target.ServerPosition, packets()); } } else { PredictionOutput pred = Prediction.GetPrediction(target, 1.25f); if (pred.Hitchance >= HitChance.High && W.IsReady()) { W.Cast(pred.CastPosition, packets()); } } } if (useE && target != null && E.IsReady() && Player.Distance(target.Position) < E.Range) { if (!waitW || W.IsReady()) { CastE(target); return; } } //DFG if (target != null && dfgMode == 0 && source == "Combo" && hasMana) { ActiveItems.Target = target; //see if killable if (dmg > target.Health - 50) { ActiveItems.KillableTarget = true; } if ((menu.Item("DontDFG" + target.BaseSkinName, true) != null && menu.Item("DontDFG" + target.BaseSkinName, true).GetValue <bool>() == false)) { ActiveItems.UseTargetted = true; } } //Q if (useQ && Q.IsReady() && Player.Distance(target.Position) <= Q.Range && target != null) { Q.CastOnUnit(target, packets()); } //R if (target != null && R.IsReady()) { useR = rTarget(target) && useR; if (useR) { CastR(target, dmg); } } }
private void Combo() { Obj_AI_Hero target = TargetSelector.GetTarget(E.Range, TargetSelector.DamageType.Magical); if (target == null) { if (maoR) { if (!turnOff) { turnOff = true; Utility.DelayAction.Add(2600, () => turnOffUlt()); } } return; } if (config.Item("selected", true).GetValue <bool>()) { target = CombatHelper.SetTarget(target, TargetSelector.GetSelectedTarget()); orbwalker.ForceTarget(target); } var manaperc = player.Mana / player.MaxMana * 100; if (player.HasBuff("MaokaiSapMagicMelee") && player.Distance(target) < Orbwalking.GetRealAutoAttackRange(target) + 75) { return; } if (config.Item("useItems").GetValue <bool>()) { ItemHandler.UseItems(target, config, ComboDamage(target)); } if (config.Item("useq", true).GetValue <bool>() && Q.CanCast(target) && !player.IsWindingUp && ((config.Item("useqroot", true).GetValue <bool>() && (!target.HasBuffOfType(BuffType.Snare) && !target.HasBuffOfType(BuffType.Stun) && !target.HasBuffOfType(BuffType.Suppression))) || !config.Item("useqroot", true).GetValue <bool>()) && !W.CanCast(target)) { Q.Cast(target); } if (config.Item("usew", true).GetValue <bool>()) { if (config.Item("blocke", true).GetValue <bool>() && player.Distance(target) < W.Range && W.IsReady() && E.CanCast(target)) { E.Cast(target); CastR(target); Utility.DelayAction.Add(100, () => W.Cast(target)); } else if (W.CanCast(target)) { CastR(target); W.Cast(target); } } if (config.Item("usee", true).GetValue <bool>() && E.CanCast(target)) { if (!config.Item("blocke", true).GetValue <bool>() || config.Item("blocke", true).GetValue <bool>() && !W.IsReady()) { E.Cast(target); } } if (R.IsReady()) { bool enoughEnemies = config.Item("user", true).GetValue <Slider>().Value <= player.CountEnemiesInRange(R.Range - 50); Obj_AI_Hero targetR = TargetSelector.GetTarget(R.Range, TargetSelector.DamageType.Magical); if (maoR && targetR != null && ((config.Item("rks", true).GetValue <bool>() && (Damage.GetSpellDamage(player, targetR, SpellSlot.R) + player.CalcDamage(target, Damage.DamageType.Magical, maoRStack)) > targetR.Health) || manaperc < config.Item("rmana", true).GetValue <Slider>().Value || (!enoughEnemies && player.Distance(targetR) > R.Range - 50))) { R.Cast(); } if (targetR != null && !maoR && manaperc > config.Item("rmana", true).GetValue <Slider>().Value&& (enoughEnemies || R.IsInRange(targetR))) { R.Cast(); } } var ignitedmg = (float)player.GetSummonerSpellDamage(target, Damage.SummonerSpell.Ignite); bool hasIgnite = player.Spellbook.CanUseSpell(player.GetSpellSlot("SummonerDot")) == SpellState.Ready; if (config.Item("useIgnite").GetValue <bool>() && ignitedmg > target.Health && hasIgnite && !E.CanCast(target)) { player.Spellbook.CastSpell(player.GetSpellSlot("SummonerDot"), target); } }
private void Combo() { var target = TargetSelector.GetSelectedTarget() ?? TargetSelector.GetTarget(R.Range, TargetSelector.DamageType.Physical); if (CheckTarget(target, R.Range)) { if (Menu.Item("ComboE", true).GetValue <bool>() && E.IsReady() && target.IsValidTarget(700) && E.GetPrediction(target).CollisionObjects.Count == 0 && E.CanCast(target) && !Me.IsWindingUp) { E.Cast(target); } if (Menu.Item("ComboQ", true).GetValue <bool>() && Q.IsReady() && target.IsValidTarget(Q.Range) && target.DistanceToPlayer() >= Menu.Item("ComboQRange", true).GetValue <Slider>().Value&& !Me.IsWindingUp) { Q.CastTo(target); } if (target.Health <= Q.GetDamage(target) + E.GetDamage(target) + Me.GetAutoAttackDamage(target) + 20 && E.CanCast(target) && Menu.Item("ComboE", true).GetValue <bool>() && E.IsReady() && Menu.Item("ComboQ", true).GetValue <bool>() && Q.IsReady() && !Me.IsWindingUp) { E.Cast(target); Q.Cast(target); } if (Menu.Item("ComboW", true).GetValue <bool>() && W.IsReady() && target.IsValidTarget(W.Range) && W.Instance.Ammo >= Menu.Item("ComboWCount", true).GetValue <Slider>().Value) { if (Utils.TickCount - LastWTime > 1500) { if (target.IsFacing(Me)) { if (target.IsMelee && target.DistanceToPlayer() < 250) { W.Cast(Me, true); } else if (target.IsValidTarget(W.Range)) { W.CastTo(target); } } else { W.Cast(W.GetPrediction(target).CastPosition + Vector3.Normalize(target.ServerPosition - Me.ServerPosition) * 150, true); } } } if (Menu.Item("ComboR", true).GetValue <bool>() && R.IsReady() && Utils.TickCount - LastQTime > 2500) { if (Menu.Item("ComboRSafe", true).GetValue <bool>() && (Me.UnderTurret(true) || Me.CountEnemiesInRange(1000) > 2)) { return; } if (!target.IsValidTarget(R.Range)) { return; } if (target.DistanceToPlayer() < Menu.Item("ComboRRange", true).GetValue <Slider>().Value) { return; } if (target.Health + target.HPRegenRate * 3 > R.GetDamage(target)) { return; } var RCollision = LeagueSharp.Common.Collision .GetCollision(new List <Vector3> { target.ServerPosition }, new PredictionInput { Delay = R.Delay, Radius = R.Width, Speed = R.Speed, Unit = Me, UseBoundingRadius = true, Collision = true, CollisionObjects = new[] { CollisionableObjects.Heroes, CollisionableObjects.YasuoWall } }) .Any(x => x.NetworkId != target.NetworkId); if (RCollision) { return; } R.CastOnUnit(target, true); } } }
private void Game_OnUpdate(EventArgs args) { var starget = TargetSelector.GetSelectedTarget(); if (Menu.Item("MH").GetValue <KeyBind>().Active) { if (Orbwalker.ActiveMode != Orbwalking.OrbwalkingMode.Mixed) { if (Q.IsReadyPerfectly()) { if (starget != null && Player.Position.Distance(starget.Position) <= Q.Range) { if (!starget.IsZombie) { Q.Cast(); } } else { var target = TargetSelector.GetTarget(Q.Range, Q.DamageType); if (target != null) { Q.Cast(); } } } } } if (Orbwalking.CanMove(20)) { switch (Orbwalker.ActiveMode) { case Orbwalking.OrbwalkingMode.Flee: { if (Menu.Item("FE").GetValue <bool>()) { if (E.IsReadyPerfectly()) { E.Cast(Game.CursorPos); } } } break; case Orbwalking.OrbwalkingMode.LastHit: break; case Orbwalking.OrbwalkingMode.Mixed: { if (Menu.Item("HE1").GetValue <bool>()) { if (E.IsReadyPerfectly() && !Player.HasBuff("renektonsliceanddicedelay")) { if (starget != null && Player.Position.Distance(starget.Position) <= E.Range + W.Range) { if (!starget.IsZombie) { var minions = MinionManager.GetMinions(starget.Position, Player.Position.Distance(starget.Position)).FirstOrDefault(x => x.IsValidTarget(E.Range)); if (minions != null) { if (minions.Position.Distance(starget.Position) <= W.Range) { E.Cast(minions); } else { if (starget.Position.Distance(Player.Position) <= E.Range) { E.Cast(starget); } } } else { if (starget.Position.Distance(Player.Position) <= E.Range) { E.Cast(starget); } } } } else { var target = TargetSelector.GetTarget(E.Range + W.Range, TargetSelector.DamageType.Physical); if (target != null) { var minions = MinionManager.GetMinions(target.Position, Player.Position.Distance(target.Position)).FirstOrDefault(x => x.IsValidTarget(E.Range)); if (minions != null) { if (minions.Position.Distance(target.Position) <= W.Range) { E.Cast(minions); } else { if (target.Position.Distance(Player.Position) <= E.Range) { E.Cast(target); } } } else { if (target.Position.Distance(Player.Position) <= E.Range) { E.Cast(target); } } } } } } if (Menu.Item("HW").GetValue <bool>()) { if (W.IsReadyPerfectly()) { if (starget != null && Player.Position.Distance(starget.Position) <= W.Range) { if (!starget.IsZombie) { W.Cast(); castTitan(); LeagueSharp.Common.Utility.DelayAction.Add(10, () => EloBuddy.Player.IssueOrder(GameObjectOrder.AttackUnit, starget)); LeagueSharp.Common.Utility.DelayAction.Add(20, () => castTiamat()); } } else { var target = TargetSelector.GetTarget(W.Range, W.DamageType); if (target != null) { W.Cast(); castTitan(); LeagueSharp.Common.Utility.DelayAction.Add(10, () => EloBuddy.Player.IssueOrder(GameObjectOrder.AttackUnit, starget)); LeagueSharp.Common.Utility.DelayAction.Add(20, () => castTiamat()); } } } } if (Menu.Item("HQ").GetValue <bool>()) { if (Q.IsReadyPerfectly()) { if (W.Instance.State == SpellState.Cooldown || W.Instance.State == SpellState.NotLearned) { if (starget != null && Player.Position.Distance(starget.Position) <= Q.Range) { if (!starget.IsZombie) { Q.Cast(); } } else { var target = TargetSelector.GetTarget(Q.Range, Q.DamageType); if (target != null) { Q.Cast(); } } } } } if (Menu.Item("HE3").GetValue <bool>()) { if (Menu.Item("HE2").GetValue <KeyBind>().Active) { if (E.IsReadyPerfectly() && Player.HasBuff("renektonsliceanddicedelay")) { if (!Q.IsReadyPerfectly() && !W.IsReadyPerfectly()) { var tower = ObjectManager.Get <Obj_Turret>().FirstOrDefault(x => x.IsAlly); if (tower.Position.Distance(blue) < tower.Position.Distance(red)) { E.Cast(blue); } else { E.Cast(red); } } } } else { if (E.IsReadyPerfectly() && Player.HasBuff("renektonsliceanddicedelay")) { if (!Q.IsReadyPerfectly() && !W.IsReadyPerfectly()) { if (starget != null && Player.Position.Distance(starget.Position) <= E.Range) { if (!starget.IsZombie) { E.Cast(starget); } } else { var target = TargetSelector.GetTarget(E.Range, E.DamageType); if (target != null) { E.Cast(target); } } } } } } } break; case Orbwalking.OrbwalkingMode.LaneClear: { if (Q.IsReadyPerfectly()) { if (Menu.Item("LCQ").GetValue <bool>()) { var target = MinionManager.GetMinions(Q.Range).FirstOrDefault(x => x.IsValidTarget(Q.Range)); if (target != null) { Q.Cast(); } } if (Menu.Item("JCQ").GetValue <bool>()) { var target = MinionManager.GetMinions(Q.Range, MinionTypes.All, MinionTeam.Neutral, MinionOrderTypes.MaxHealth).FirstOrDefault(x => x.IsValidTarget(Q.Range)); if (target != null) { Q.Cast(); } } } } break; case Orbwalking.OrbwalkingMode.Combo: { if (Menu.Item("CQ").GetValue <bool>()) { if (Q.IsReadyPerfectly()) { if (starget != null && Player.Position.Distance(starget.Position) <= Q.Range) { if (!starget.IsZombie) { Q.Cast(); castTiamat(); } } else { var target = TargetSelector.GetTarget(Q.Range, Q.DamageType); if (target != null) { Q.Cast(); castTiamat(); } } } } if (Menu.Item("CW").GetValue <bool>()) { if (W.IsReadyPerfectly()) { if (starget != null && Player.Position.Distance(starget.Position) <= W.Range) { if (!starget.IsZombie) { W.Cast(); castTitan(); LeagueSharp.Common.Utility.DelayAction.Add(10, () => EloBuddy.Player.IssueOrder(GameObjectOrder.AttackUnit, starget)); LeagueSharp.Common.Utility.DelayAction.Add(20, () => castTiamat()); } } else { var target = TargetSelector.GetTarget(W.Range, W.DamageType); if (target != null) { W.Cast(); castTitan(); LeagueSharp.Common.Utility.DelayAction.Add(10, () => EloBuddy.Player.IssueOrder(GameObjectOrder.AttackUnit, target)); LeagueSharp.Common.Utility.DelayAction.Add(20, () => castTiamat()); } } } } } break; case Orbwalking.OrbwalkingMode.None: break; } } if (Menu.Item("CR").GetValue <bool>()) { if (Player.HealthPercent <= Menu.Item("CH").GetValue <Slider>().Value) { if (!Player.HasBuff("Recall")) { if (R.IsReadyPerfectly()) { R.Cast(); } } } } Killsteal(); }
private static void Combo() { var target = TargetSelector.GetSelectedTarget() ?? myOrbwalker.GetTarget() as AIHeroClient; if (ComboOption.UseE && E.IsReady() && !Q.IsCharging) { if (target == null || !target.IsValidTarget()) { target = TargetSelector.GetTarget(E.Range, TargetSelector.DamageType.Physical); } if (target.IsValidTarget(E.Range) && GetBuffCount(target) >= ComboOption.GetSlider("ComboPassive") || W.Level == 0 || target.Health < E.GetDamage(target) + GetWDmg(target) || !Orbwalker.InAutoAttackRange(target)) { SpellManager.PredCast(E, target, true); return; } } if (ComboOption.UseQ && Q.IsReady()) { if (target == null || !target.IsValidTarget()) { target = TargetSelector.GetTarget(1600f, TargetSelector.DamageType.Physical); } if (target.IsValidTarget(1600f)) { if (Q.IsCharging) { if (target.IsValidTarget(Q.ChargedMaxRange)) { SpellManager.PredCast(Q, target); return; } } else { if (GetBuffCount(target) >= ComboOption.GetSlider("ComboPassive") || W.Level == 0 || target.Health < Q.GetDamage(target) + GetWDmg(target)) { if (target.IsValidTarget(Q.Range)) { SpellManager.PredCast(Q, target); } else { Q.StartCharging(); } return; } } } else { foreach (var t in ObjectManager.Heroes.Enemies.Where(x => !x.IsDead && !x.IsZombie && x.IsValidTarget(1600f))) { if (Q.IsCharging) { if (t.IsValidTarget(Q.ChargedMaxRange)) { SpellManager.PredCast(Q, target); return; } } else { if (GetBuffCount(t) >= ComboOption.GetSlider("ComboPassive") || W.Level == 0 || t.Health < Q.GetDamage(t) + GetWDmg(t)) { if (t.IsValidTarget(Q.Range)) { SpellManager.PredCast(Q, t); } else { Q.StartCharging(); } return; } } } } } if (ComboOption.UseR && R.IsReady()) { if (target == null || !target.IsValidTarget()) { target = TargetSelector.GetTarget(R.Range, TargetSelector.DamageType.Physical); } if (target.IsValidTarget(R.Range) && ComboOption.GetBool("ComboRSolo") && Me.CountEnemiesInRange(1000) <= 2) { if (target.Health + target.HPRegenRate * 2 < R.GetDamage(target) + W.GetDamage(target) + (E.IsReady() ? E.GetDamage(target) : 0) + (Q.IsReady() ? Q.GetDamage(target) : 0) + Me.GetAutoAttackDamage(target) * 3) { SpellManager.PredCast(R, target); return; } } var rPred = R.GetPrediction(target, true); if (rPred.AoeTargetsHitCount >= ComboOption.GetSlider("ComboRCount") || Me.CountEnemiesInRange(R.Range) >= ComboOption.GetSlider("ComboRCount")) { SpellManager.PredCast(R, target); } } }
public static void Drawing_OnDraw(EventArgs args) { var newTarget = Program.ParamBool("insecMode") ? TargetSelector.GetSelectedTarget() : TargetSelector.GetTarget( Program.spells[Program.Spells.Q].Range + 200, TargetSelector.DamageType.Physical); if (Program.ClicksecEnabled) { Render.Circle.DrawCircle(Program.InsecClickPos, 100, Color.Gold); } var playerPos = Drawing.WorldToScreen(ObjectManager.Player.Position); if (Program.ParamBool("ElLeeSin.Draw.Insec.Text")) { Drawing.DrawText(playerPos.X, playerPos.Y + 40, Color.White, "Flash Insec enabled"); } //&& Program.spells[Program.Spells.R].IsReady() if (Program.ParamBool("Draw.Insec.Lines")) { if (newTarget != null && newTarget.IsVisible && newTarget.IsValidTarget() && !newTarget.IsDead && Program.Player.Distance(newTarget) < 3000) { Vector2 targetPos = Drawing.WorldToScreen(newTarget.Position); Drawing.DrawLine( Program.InsecLinePos.X, Program.InsecLinePos.Y, targetPos.X, targetPos.Y, 3, Color.Gold); Drawing.DrawText( Drawing.WorldToScreen(newTarget.Position).X - 40, Drawing.WorldToScreen(newTarget.Position).Y + 10, Color.White, "Selected Target"); Drawing.DrawCircle(Program.GetInsecPos(newTarget), 100, Color.Gold); } } if (!Program.ParamBool("DrawEnabled")) { return; } foreach (var t in ObjectManager.Get <Obj_AI_Hero>()) { if (t.HasBuff("BlindMonkQOne") || t.HasBuff("blindmonkqonechaos")) { Drawing.DrawCircle(t.Position, 200, Color.Red); } } if (InitMenu.Menu.Item("ElLeeSin.Wardjump").GetValue <KeyBind>().Active && Program.ParamBool("ElLeeSin.Draw.WJDraw")) { Render.Circle.DrawCircle(Program.JumpPos.To3D(), 20, Color.Red); Render.Circle.DrawCircle(Program.Player.Position, 600, Color.Red); } if (Program.ParamBool("ElLeeSin.Draw.Q")) { Render.Circle.DrawCircle( Program.Player.Position, Program.spells[Program.Spells.Q].Range - 80, Program.spells[Program.Spells.Q].IsReady() ? Color.LightSkyBlue : Color.Tomato); } if (Program.ParamBool("ElLeeSin.Draw.W")) { Render.Circle.DrawCircle( Program.Player.Position, Program.spells[Program.Spells.W].Range - 80, Program.spells[Program.Spells.W].IsReady() ? Color.LightSkyBlue : Color.Tomato); } if (Program.ParamBool("ElLeeSin.Draw.E")) { Render.Circle.DrawCircle( Program.Player.Position, Program.spells[Program.Spells.E].Range - 80, Program.spells[Program.Spells.E].IsReady() ? Color.LightSkyBlue : Color.Tomato); } if (Program.ParamBool("ElLeeSin.Draw.R")) { Render.Circle.DrawCircle( Program.Player.Position, Program.spells[Program.Spells.R].Range - 80, Program.spells[Program.Spells.R].IsReady() ? Color.LightSkyBlue : Color.Tomato); } }
public override void Game_OnGameUpdate(EventArgs args) { if (LaneClearActive) { var vMinions = MinionManager.GetMinions(Player.Position, Orbwalking.GetRealAutoAttackRange(null)); foreach (var minions in vMinions.Where( minions => minions.HasBuff("QuinnW") && (minions.Health <(Player.GetAutoAttackDamage(minions) + PassiveMarkDamage(minions)) || minions.Health> (Player.GetAutoAttackDamage(minions) + PassiveMarkDamage(minions)) + (20 + Player.Level * 2)))) { Orbwalker.ForceTarget(minions); } } if (!ComboActive) { Orbwalker.SetAttack(true); Orbwalker.SetMovement(true); return; } var useQ = GetValue <bool>("UseQ" + (ComboActive ? "C" : "H")); var useE = GetValue <bool>("UseE" + (ComboActive ? "C" : "H")); var useR = GetValue <bool>("UseR"); var useET = GetValue <bool>("UseET" + (ComboActive ? "C" : "H")); var manE = GetValue <KeyBind>("ManualE").Active; if (Player.IsMelee()) { if (IsValorMode()) { if (useR) { var vTarget = TargetSelector.GetTarget(R.Range, TargetSelector.DamageType.Physical); if (vTarget != null) { CalculateValorDamage(); if (vTarget.Health >= ValorMinDamage && vTarget.Health <= ValorMaxDamage) { R.Cast(); } } } if (Q.IsReady() && useQ) { var t = TargetSelector.GetTarget(275, TargetSelector.DamageType.Physical); if (t != null && (AttackReadiness > 0.2 && AttackReadiness < 0.75)) { Q.Cast(); } } } var targetLoc = Game.CursorPos; YTarget = (TargetSelector.GetSelectedTarget() != null && TargetSelector.GetSelectedTarget().Distance(Game.CursorPos) <= GetValue <Slider>("Cirsize").Value) ? TargetSelector.GetSelectedTarget() : TargetSelector.GetTarget( GetValue <Slider>("Cirsize").Value, TargetSelector.DamageType.Physical, true, null, Game.CursorPos); Orbwalker.ForceTarget(YTarget); Orbwalker.SetMovement(false); if (YTarget.IsValidTarget()) { Orbwalker.SetAttack( Orbwalker.GetTarget().IsValidTarget() && Orbwalker.GetTarget().NetworkId == YTarget.NetworkId); if (Orbwalking.CanMove(50)) { if (!Orbwalker.InAutoAttackRange(YTarget)) { var pLoc = Prediction.GetPrediction(YTarget, 0.1f, 175, 600).UnitPosition; MoveTo(pLoc, Orbwalking.GetRealAutoAttackRange(YTarget) / 2); } else { MoveByTarget(YTarget); } } if (E.IsReady() && (useE || manE) && Player.Distance3D(YTarget) > 350) { E.CastOnUnit(YTarget); } } else { MoveTo(targetLoc, 100); Orbwalker.SetAttack(false); } } else { Orbwalker.SetAttack(true); Orbwalker.SetMovement(true); var targ = HeroManager.Enemies.Where(enemy => enemy.IsValidTarget() && Orbwalking.InAutoAttackRange(enemy) && enemy.HasBuff("QuinnW")).OrderBy(PhysHealth) .FirstOrDefault(); Orbwalker.ForceTarget(targ); if (E.IsReady() && (useE || manE)) { var vTarget = Orbwalker.GetTarget() as Obj_AI_Hero ?? TargetSelector.GetTarget(E.Range, TargetSelector.DamageType.Physical); if (vTarget != null && !IsHePantheon(vTarget) && (Player.Distance3D(vTarget) > Orbwalking.GetRealAutoAttackRange(vTarget) || (AttackReadiness > 0.2 && AttackReadiness < 0.75))) { if (!useET) { E.CastOnUnit(vTarget); } else if (!vTarget.UnderTurret()) { E.CastOnUnit(vTarget); } } } if (Q.IsReady() && useQ) { var t = HeroManager.Enemies.Where(enemy => enemy.IsValidTarget(Q.Range) && (GetValue <StringList>("Blind" + enemy.ChampionName).SelectedIndex == 1 || enemy.HealthPercent <= GetValue <Slider>("BlindD").Value || !BlindTargetNear(enemy))).OrderBy(PhysHealth) .FirstOrDefault(); if (t != null && (Player.Distance3D(t) > Orbwalking.GetRealAutoAttackRange(t) || (AttackReadiness > 0.2 && AttackReadiness < 0.75))) { Q.Collision = false; var chance = Q.GetPrediction(t).Hitchance; if (chance >= HitChance.VeryHigh) { Q.Collision = true; CastSpellAoEShot(Q, t, 100); } } } Drawing.DrawText( Drawing.WorldToScreen(Player.Position)[0] + 50, Drawing.WorldToScreen(Player.Position)[1] - 20, Color.Yellow, "lol"); } }
private void RLogic() { AIHeroClient target = null; if (TargetSelector.GetSelectedTarget() != null && TargetSelector.GetSelectedTarget().DistanceToPlayer() <= Menu.GetSlider("rMenuMax")) { target = TargetSelector.GetSelectedTarget(); } else { target = TargetSelector.GetTarget(R.Range, TargetSelector.DamageType.Physical); } if (R.IsReady() && target.Check(R.Range)) { switch (R.Instance.Name) { case "JhinR": if (Menu.GetKey("rMenuSemi")) { if (R.Cast(R.GetPrediction(target).UnitPosition)) { rShotTarget = target; return; } } if (!Menu.GetBool("rMenuAuto")) { return; } if (Menu.GetBool("rMenuCheck") && Me.CountEnemiesInRange(800f) > 0) { return; } if (target.DistanceToPlayer() <= Menu.GetSlider("rMenuMin")) { return; } if (target.DistanceToPlayer() > Menu.GetSlider("rMenuMax")) { return; } if (target.Health > Me.GetSpellDamage(target, SpellSlot.R) * Menu.GetSlider("rMenuKill")) { return; } if (IsSpellHeroCollision(target, R)) { return; } if (R.Cast(R.GetPrediction(target).UnitPosition)) { rShotTarget = target; } break; case "JhinRShot": var selectTarget = TargetSelector.GetSelectedTarget(); if (selectTarget != null && selectTarget.IsValidTarget(R.Range) && InRCone(selectTarget)) { if (Menu.GetKey("rMenuSemi")) { AutoUse(rShotTarget); SpellManager.PredCast(R, rShotTarget); return; } if (Menu.GetBool("ComboR") && Orbwalker.ActiveMode == Orbwalking.OrbwalkingMode.Combo) { AutoUse(rShotTarget); SpellManager.PredCast(R, rShotTarget); return; } if (!Menu.GetBool("rMenuAuto")) { return; } AutoUse(rShotTarget); SpellManager.PredCast(R, rShotTarget); return; } foreach ( var t in HeroManager.Enemies.Where(x => x.IsValidTarget(R.Range) && InRCone(x)) .OrderBy(x => x.Health)) { if (Menu.GetKey("rMenuSemi")) { AutoUse(t); SpellManager.PredCast(R, t); return; } if (Menu.GetBool("ComboR") && Orbwalker.ActiveMode == Orbwalking.OrbwalkingMode.Combo) { AutoUse(t); SpellManager.PredCast(R, t); return; } if (!Menu.GetBool("rMenuAuto")) { return; } AutoUse(t); SpellManager.PredCast(R, t); return; } break; } } }
private static void Game_OnUpdate(EventArgs args) { if (Environment.TickCount - RAutoTick >= 200 && BadaoJhinHelper.UseRAuto() && BadaoMainVariables.R.Instance.SData.Name == "JhinRShot") { RAutoTick = Environment.TickCount; if (BadaoJhinHelper.AutoRTargetAuto()) { var target = TargetSelector.GetTarget(BadaoMainVariables.R.Range, TargetSelector.DamageType.Physical, true, HeroManager.Enemies.Where(x => x.IsValid && !BadaoChecker.BadaoInTheCone( x.Position.To2D(), ObjectManager.Player.Position.To2D(), ObjectManager.Player.Position.To2D() + ObjectManager.Player.Direction.To2D().Normalized().Perpendicular() * BadaoMainVariables.R.Range, 60))); if (target.BadaoIsValidTarget()) { RAutoTarget = target; } } else if (BadaoJhinHelper.AutoRTargetNearMouse()) { var target = HeroManager.Enemies.Where(x => x.BadaoIsValidTarget(BadaoMainVariables.R.Range) && BadaoChecker.BadaoInTheCone( x.Position.To2D(), ObjectManager.Player.Position.To2D(), ObjectManager.Player.Position.To2D() + ObjectManager.Player.Direction.To2D().Normalized().Perpendicular() * BadaoMainVariables.R.Range, 60)) .OrderBy(x => x.Distance(Game.CursorPos)).FirstOrDefault(); if (target.BadaoIsValidTarget()) { RAutoTarget = target; } } else if (BadaoJhinHelper.AutoRTargetSelected()) { var target = TargetSelector.GetSelectedTarget(); if (target.BadaoIsValidTarget(BadaoMainVariables.R.Range) && BadaoChecker.BadaoInTheCone( target.Position.To2D(), ObjectManager.Player.Position.To2D(), ObjectManager.Player.Position.To2D() + ObjectManager.Player.Direction.To2D().Normalized().Perpendicular() * BadaoMainVariables.R.Range, 60)) { RAutoTarget = target; } } } // auto ping if (BadaoJhinHelper.UseAutoPingKillable()) { if (BadaoMainVariables.R.IsReady() && BadaoMainVariables.R.Instance.SData.Name != "JhinRShot") { foreach (var hero in HeroManager.Enemies .Where(x => x.BadaoIsValidTarget(BadaoMainVariables.R.Range) && BadaoJhinHelper.GetRdamage(x) >= x.Health)) { BadaoJhinPing.Ping(hero.Position.To2D()); break; } } } //JhinR if (BadaoJhinHelper.UseRAuto() && BadaoMainVariables.R.Instance.SData.Name == "JhinRShot") { if (BadaoJhinHelper.AutoRModeAuto()) { if (RAutoTarget.BadaoIsValidTarget()) { BadaoMainVariables.R.Cast(RAutoTarget); } } } if (BadaoMainVariables.R.Instance.SData.Name == "JhinRShot") { return; } if (BadaoJhinHelper.UseAutoKS()) { foreach (var hero in HeroManager.Enemies.Where(x => x.BadaoIsValidTarget(BadaoMainVariables.W.Range))) { if (BadaoMainVariables.W.IsReady() && BadaoJhinHelper.GetWDamage(hero) >= hero.Health) { var x = BadaoMainVariables.W.GetPrediction(hero).CastPosition; var y = BadaoMainVariables.W.GetPrediction(hero).CollisionObjects; if (!y.Any(z => z.IsChampion()) && ObjectManager.Player.Distance(x) <= BadaoMainVariables.W.Range) { if (BadaoMainVariables.W.Cast(x)) { break; } } } if (BadaoMainVariables.Q.IsReady() && BadaoJhinHelper.GetQDamage(hero) >= hero.Health && hero.BadaoIsValidTarget(BadaoMainVariables.Q.Range)) { BadaoMainVariables.Q.Cast(hero); } } } if (!BadaoJhinHelper.CanAutoMana()) { return; } if (BadaoJhinHelper.UseWAutoTrap()) { foreach (var hero in HeroManager.Enemies.Where(x => x.BadaoIsValidTarget(BadaoMainVariables.W.Range))) { var x = BadaoMainVariables.W.GetPrediction(hero).CastPosition; var y = BadaoMainVariables.W.GetPrediction(hero).CollisionObjects; if (!y.Any(z => z.IsChampion()) && ObjectManager.Player.Distance(x) <= BadaoMainVariables.W.Range && BadaoJhinPassive.JhinTrap.Any(i => i.Distance(x) <= 100)) { if (BadaoMainVariables.W.Cast(x)) { break; } } } } if (BadaoJhinHelper.UseWAuto()) { foreach (var hero in HeroManager.Enemies.Where(x => x.BadaoIsValidTarget(BadaoMainVariables.W.Range))) { if ((hero.HasBuffOfType(BuffType.Slow) || hero.HasBuffOfType(BuffType.Charm) || hero.HasBuffOfType(BuffType.Snare)) && BadaoJhinHelper.HasJhinPassive(hero)) { var x = BadaoMainVariables.W.GetPrediction(hero).CastPosition; var y = BadaoMainVariables.W.GetPrediction(hero).CollisionObjects; if (!y.Any(z => z.IsChampion()) && ObjectManager.Player.Distance(x) <= BadaoMainVariables.W.Range) { if (BadaoMainVariables.W.Cast(x)) { break; } } } } } }
protected Obj_AI_Hero GetTargetFocus(float range) { var focusSelected = menu.Item("selected", true).GetValue <bool>(); if (TargetSelector.GetSelectedTarget() != null) { if (focusSelected && TargetSelector.GetSelectedTarget().Distance(Player.ServerPosition) < range + 100 && TargetSelector.GetSelectedTarget().Type == GameObjectType.obj_AI_Hero) { //Game.PrintChat("Focusing: " + TargetSelector.GetSelectedTarget().Name); return(TargetSelector.GetSelectedTarget()); } } return(null); }
private static void OnGameUpdate(EventArgs args) { try { if (Player.IsDead) { return; } if (MainMenu._MainMenu.Item("Flee").GetValue <KeyBind>().Active) { Player.IssueOrder(GameObjectOrder.MoveTo, Game.CursorPos); // 커서방향 이동 if (_W.IsReady() && Player.Spellbook.GetSpell(SpellSlot.W).Name == "LeblancSlide") { _W.Cast(Game.CursorPos, true); } if (_R.IsReady() && Player.Spellbook.GetSpell(SpellSlot.R).Name == "LeblancSlideM") { _R.Cast(Game.CursorPos, true); } } if (MainMenu._MainMenu.Item("ERCC").GetValue <KeyBind>().Active) // ERCC { Player.IssueOrder(GameObjectOrder.MoveTo, Game.CursorPos); // 커서방향 이동 var ETarget = TargetSelector.GetTarget(_E.Range, TargetSelector.DamageType.Magical); if (_E.IsReady() && ETarget != null && Environment.TickCount > ERTIME) { _E.CastIfHitchanceEquals(ETarget, HitChance.Low, true); } else if (ETarget != null && _R.IsReady() && Player.Spellbook.GetSpell(SpellSlot.R).Name == "LeblancSoulShackleM" && Environment.TickCount > ERTIME) { _R.CastIfHitchanceEquals(ETarget, HitChance.Low, true); } } // Pet if (MainMenu._MainMenu.Item("Pet").GetValue <bool>() && Player.Pet != null && Player.Pet.IsValid && !Player.Pet.IsDead) { var Enemy = ObjectManager.Get <Obj_AI_Hero>().OrderBy(x => x.Distance(Player)).FirstOrDefault(x => x.IsEnemy && !x.IsDead); Random Ran = new Random(); var PetLocate = Player.ServerPosition.Extend(Enemy.ServerPosition, Ran.Next(150, 300)); PetLocate.X = PetLocate.X + Ran.Next(0, 20); PetLocate.Y = PetLocate.Y + Ran.Next(0, 20); PetLocate.Z = PetLocate.Z + Ran.Next(0, 20); if (PetTime < Environment.TickCount) { Player.IssueOrder(GameObjectOrder.MovePet, PetLocate); PetTime = TickCount(750); } } if (MainMenu._MainMenu.Item("KUse_Q").GetValue <bool>() && _Q.IsReady()) { var QTarget = TargetSelector.GetTarget(_Q.Range, TargetSelector.DamageType.Magical); if (QTarget == null) { return; } if (QTarget.Health <= _Q.GetDamage(QTarget)) { _Q.Cast(QTarget, true); return; } } if (MainMenu._MainMenu.Item("KUse_W").GetValue <bool>() && _W.IsReady() && Player.Spellbook.GetSpell(SpellSlot.W).Name == "LeblancSlide") { var WTarget = TargetSelector.GetTarget(_W.Range, TargetSelector.DamageType.Magical); if (WTarget == null) { return; } if (WTarget.Health <= _W.GetDamage(WTarget)) { _W.Cast(WTarget.ServerPosition, true); return; } } if (MainMenu._MainMenu.Item("KUse_E").GetValue <bool>() && _E.IsReady()) { var ETarget = TargetSelector.GetTarget(_E.Range, TargetSelector.DamageType.Magical); if (ETarget == null) { return; } if (ETarget.Health <= _E.GetDamage(ETarget)) { _E.CastIfHitchanceEquals(ETarget, HitChance.Low, true); return; } } if (MainMenu._MainMenu.Item("KUse_Q2").GetValue <bool>() && _R.IsReady() && Player.Spellbook.GetSpell(SpellSlot.R).Name == "LeblancChaosOrbM") { var QTarget = TargetSelector.GetTarget(_Q.Range, TargetSelector.DamageType.Magical); if (QTarget == null) { return; } if (QTarget.Health <= _Q.GetDamage(QTarget)) { _R.Cast(QTarget, true); return; } } if (MainMenu._MainMenu.Item("KUse_W2").GetValue <bool>() && _R.IsReady() && Player.Spellbook.GetSpell(SpellSlot.R).Name == "LeblancSlideM") { var QTarget = TargetSelector.GetTarget(_W.Range, TargetSelector.DamageType.Magical); if (QTarget == null) { return; } if (QTarget.Health <= _W.GetDamage(QTarget)) { _R.Cast(QTarget.ServerPosition, true); return; } } if (MainMenu._MainMenu.Item("KUse_E2").GetValue <bool>() && _R.IsReady() && Player.Spellbook.GetSpell(SpellSlot.R).Name == "LeblancSoulShackleM") { var QTarget = TargetSelector.GetTarget(_E.Range, TargetSelector.DamageType.Magical); if (QTarget == null) { return; } if (QTarget.Health <= _E.GetDamage(QTarget)) { _R.CastIfHitchanceEquals(QTarget, HitChance.Low, true); return; } } if (MainMenu._MainMenu.Item("CKey").GetValue <KeyBind>().Active) // Combo { var QTarget = TargetSelector.GetTarget(_Q.Range, TargetSelector.DamageType.Magical); var WTarget = TargetSelector.GetTarget(_W.Range, TargetSelector.DamageType.Magical); var ETarget = TargetSelector.GetTarget(_E.Range, TargetSelector.DamageType.Magical); var TargetSel = TargetSelector.GetSelectedTarget(); if (QTarget == null && WTarget == null && ETarget == null) { return; } // Q if (QTarget != null && MainMenu._MainMenu.Item("CUse_Q").GetValue <bool>() && _Q.IsReady() && Player.Spellbook.GetSpell(SpellSlot.Q).Name == "LeblancChaosOrb" ) { ReturnTime = TickCount(1000); _Q.Cast(QTarget, true); return; } if (Player.Level > 5 && TargetSel == null && MainMenu._MainMenu.Item("ComboMode").GetValue <KeyBind>().Active) // teamcombo { // W if (WTarget != null && MainMenu._MainMenu.Item("CUse_W").GetValue <bool>() && _W.IsReady() && Player.Spellbook.GetSpell(SpellSlot.W).Name == "LeblancSlide" ) { _W.Cast(WTarget.ServerPosition, true); return; } // W2 if (WTarget != null && MainMenu._MainMenu.Item("CUse_W2").GetValue <bool>() && _R.IsReady() && Player.Spellbook.GetSpell(SpellSlot.R).Name == "LeblancSlideM") { _R.Cast(WTarget.ServerPosition, true); return; } } // Q2 if (QTarget != null && MainMenu._MainMenu.Item("CUse_Q2").GetValue <bool>() && _R.IsReady() && Player.Spellbook.GetSpell(SpellSlot.R).Name == "LeblancChaosOrbM" ) { _R.Cast(QTarget, true); return; } // W if (WTarget != null && MainMenu._MainMenu.Item("CUse_W").GetValue <bool>() && _W.IsReady() && Player.Spellbook.GetSpell(SpellSlot.W).Name == "LeblancSlide" ) { _W.Cast(WTarget.ServerPosition, true); return; } // W2 if (WTarget != null && MainMenu._MainMenu.Item("CUse_W2").GetValue <bool>() && _R.IsReady() && Player.Spellbook.GetSpell(SpellSlot.R).Name == "LeblancSlideM") { _R.Cast(WTarget.ServerPosition, true); return; } // E if (ETarget != null && MainMenu._MainMenu.Item("CUse_E").GetValue <bool>() && _E.IsReady() && Player.Spellbook.GetSpell(SpellSlot.E).Name == "LeblancSoulShackle" && Player.Spellbook.GetSpell(SpellSlot.R).Name != "LeblancSlideM" ) { _E.CastIfHitchanceEquals(ETarget, Hitchance("CUseE_Hit"), true); return; } // E2 if (ETarget != null && MainMenu._MainMenu.Item("CUse_E2").GetValue <bool>() && _E.IsReady() && Player.Spellbook.GetSpell(SpellSlot.E).Name == "LeblancSoulShackleM" ) { _R.CastIfHitchanceEquals(ETarget, Hitchance("CUseE_Hit"), true); return; } // WReturn if (ETarget.Buffs.Find(buff => (buff.Name == "LeblancSoulShackle" || buff.Name == "LeblancSoulShackleM") && buff.IsValidBuff()) == null && MainMenu._MainMenu.Item("CUse_WReturn").GetValue <bool>() && _W.IsReady() && Player.Spellbook.GetSpell(SpellSlot.W).Name == "leblancslidereturn" && !_Q.IsReady() && !_R.IsReady() && ReturnTime < Environment.TickCount) { _W.Cast(true); return; } // WR Return if (ETarget.Buffs.Find(buff => (buff.Name == "LeblancSoulShackle" || buff.Name == "LeblancSoulShackleM") && buff.IsValidBuff()) == null && MainMenu._MainMenu.Item("CUse_W2Return").GetValue <bool>() && _W.IsReady() && Player.Spellbook.GetSpell(SpellSlot.R).Name == "leblancslidereturnm" && !_Q.IsReady() && !_W.IsReady() && ReturnTime < Environment.TickCount) { _R.Cast(true); return; } } if ((MainMenu._MainMenu.Item("HKey").GetValue <KeyBind>().Active || MainMenu._MainMenu.Item("AHToggle").GetValue <bool>()) && MainMenu._MainMenu.Item("AManarate").GetValue <Slider>().Value < Player.ManaPercent) // Harass { var QTarget = TargetSelector.GetTarget(_Q.Range, TargetSelector.DamageType.Magical); var WTarget = TargetSelector.GetTarget(_W.Range, TargetSelector.DamageType.Magical); var ETarget = TargetSelector.GetTarget(_E.Range, TargetSelector.DamageType.Magical); // Q if (QTarget != null && MainMenu._MainMenu.Item("AUse_Q").GetValue <bool>() && _Q.IsReady() && Player.Spellbook.GetSpell(SpellSlot.Q).Name == "LeblancChaosOrb" ) { _Q.Cast(QTarget, true); return; } // W if (WTarget != null && MainMenu._MainMenu.Item("AUse_W").GetValue <bool>() && _W.IsReady() && Player.Spellbook.GetSpell(SpellSlot.W).Name == "LeblancSlide" ) { _W.Cast(WTarget.ServerPosition, true); return; } // E if (ETarget != null && MainMenu._MainMenu.Item("AUse_E").GetValue <bool>() && _E.IsReady() && Player.Spellbook.GetSpell(SpellSlot.E).Name == "LeblancSoulShackle" ) { _E.CastIfHitchanceEquals(ETarget, Hitchance("CUseE_Hit"), true); return; } // WW if (WTarget != null && MainMenu._MainMenu.Item("AUse_W").GetValue <bool>() && _W.IsReady() && Player.Spellbook.GetSpell(SpellSlot.W).Name == "leblancslidereturn" ) { _W.Cast(true); return; } } } catch (Exception e) { //Console.Write(e); //Game.PrintChat("FreshLeBlanc is not working. plz send message by KorFresh (Code 4)"); } }
private static void GodHand(Obj_AI_Base target) { if (TargetSelector.GetSelectedTarget() != null && _target.Distance(_player.Position) > 1000) { return; } if (target.IsValidTarget() && q.IsReady()) { var prediction = q.GetPrediction(target); if (_menu.Item("combokey").GetValue <KeyBind>().Active) { if ((target.Distance(_player.Position) > _menu.Item("dneeded").GetValue <Slider>().Value) && (target.Distance(_player.Position) < _menu.Item("dneeded2").GetValue <Slider>().Value)) { if (_menu.Item("dograb" + target.SkinName).GetValue <StringList>().SelectedIndex == 0) { return; } if (prediction.Hitchance >= HitChance.High && _menu.Item("hitchance").GetValue <StringList>().SelectedIndex == 2) { q.Cast(prediction.CastPosition); } else if (prediction.Hitchance >= HitChance.Medium && _menu.Item("hitchance").GetValue <StringList>().SelectedIndex == 1) { q.Cast(prediction.CastPosition); } else if (prediction.Hitchance >= HitChance.Low && _menu.Item("hitchance").GetValue <StringList>().SelectedIndex == 0) { q.Cast(prediction.CastPosition); } } } } foreach ( var e in ObjectManager.Get <Obj_AI_Hero>() .Where( e => e.IsValidTarget(q.Range) && _menu.Item("dograb" + e.SkinName).GetValue <StringList>().SelectedIndex == 2)) { if (e.Distance(_player.Position) > _menu.Item("dneeded").GetValue <Slider>().Value) { var prediction = q.GetPrediction(e); if (prediction.Hitchance == HitChance.Immobile && _menu.Item("immobile").GetValue <bool>()) { q.Cast(prediction.CastPosition); } if (prediction.Hitchance == HitChance.Dashing && _menu.Item("dashing").GetValue <bool>()) { q.Cast(prediction.CastPosition); } } } }
private static void UseSpells(bool useQ, bool useW, bool useE, bool useR, string Source) { var range = W.IsReady() ? W.Range : E.Range; var focusSelected = menu.Item("selected").GetValue <bool>(); Obj_AI_Hero target = TargetSelector.GetTarget(range, TargetSelector.DamageType.Magical); if (TargetSelector.GetSelectedTarget() != null) { if (focusSelected && TargetSelector.GetSelectedTarget().Distance(Player.ServerPosition) < range) { target = TargetSelector.GetSelectedTarget(); } } bool hasmana = manaCheck(); int IgniteMode = menu.Item("igniteMode").GetValue <StringList>().SelectedIndex; var qReset = menu.Item("qReset").GetValue <bool>(); //Q if (useQ && Q.IsReady() && Player.Distance(target) <= 300 && !qReset) { Q.Cast(); } //E if (useE && target != null && E.IsReady() && Player.Distance(target) < E.Range) { E.Cast(target); return; } //Ignite if (target != null && menu.Item("ignite").GetValue <bool>() && IgniteSlot != SpellSlot.Unknown && Player.Spellbook.CanUseSpell(IgniteSlot) == SpellState.Ready && Source == "Combo" && hasmana) { if (IgniteMode == 0 && GetComboDamage(target) > target.Health) { Player.Spellbook.CastSpell(IgniteSlot, target); } } //W if (useW && target != null && W.IsReady() && Player.Distance(target) <= W.Range && W.GetPrediction(target).Hitchance >= HitChance.High) { W.Cast(target, packets()); } //R if (useR && target != null && R.IsReady()) { if (!Player.HasBuff("yorickreviveallyguide", true)) { foreach ( Obj_AI_Hero ally in ObjectManager.Get <Obj_AI_Hero>() .Where(x => Player.Distance(x) < R.Range && x.IsAlly && !x.IsDead)) { castR(target, ally); } } } }
private static void Obj_AI_Base_OnProcessSpellCast(Obj_AI_Base sender, GameObjectProcessSpellCastEventArgs args) { try { if (!sender.IsMe) { return; } switch (args.Slot) { case SpellSlot.Q: if (!args.SData.Name.ToLower().Contains("one")) { isInQ2 = true; } break; case SpellSlot.W: if (args.SData.Name.ToLower().Contains("one")) { LastW = Environment.TickCount; } break; } switch (args.SData.Name.ToLower()) { case "blindmonkqone": castQAgain = false; LeagueSharp.Common.Utility.DelayAction.Add(2900, () => { castQAgain = true; }); break; case "blindmonkqtwo": waitingForQ2 = true; LastQ2 = Environment.TickCount; LeagueSharp.Common.Utility.DelayAction.Add(2900, () => { CheckQ = true; }); LeagueSharp.Common.Utility.DelayAction.Add(3000, () => { waitingForQ2 = false; }); break; case "blindmonkrkick": InsecManager.insecComboStep = InsecManager.InsecComboStepSelect.None; break; } if (spells[Spells.R].IsReady() && (ObjectManager.Player.Spellbook.CanUseSpell(flashSlot) == SpellState.Ready)) { var target = Misc.GetMenuItem("insecMode") ? TargetSelector.GetSelectedTarget() : TargetSelector.GetTarget( spells[Spells.R].Range, TargetSelector.DamageType.Physical); if (target == null) { return; } if (args.SData.Name.Equals("BlindMonkRKick", StringComparison.InvariantCultureIgnoreCase) && MyMenu.Menu.Item("ElLeeSin.Insec.UseInstaFlash").GetValue <KeyBind>().Active) { LeagueSharp.Common.Utility.DelayAction.Add( 80, () => ObjectManager.Player.Spellbook.CastSpell(flashSlot, InsecManager.GetInsecPos(target))); } } if (args.SData.Name.Equals("summonerflash", StringComparison.InvariantCultureIgnoreCase) && (InsecManager.insecComboStep != InsecManager.InsecComboStepSelect.None)) { var target = Misc.GetMenuItem("insecMode") ? TargetSelector.GetSelectedTarget() : TargetSelector.GetTarget( spells[Spells.Q].Range, TargetSelector.DamageType.Physical); if (target == null) { return; } InsecManager.insecComboStep = InsecManager.InsecComboStepSelect.Pressr; LeagueSharp.Common.Utility.DelayAction.Add(80, () => spells[Spells.R].CastOnUnit(target)); } foreach (var buff in buffNames) { if (buff.Equals(args.SData.Name.ToLower(), StringComparison.InvariantCultureIgnoreCase)) { PassiveStacks = 2; lastSpellCastTime = Environment.TickCount; } } } catch (Exception e) { Console.WriteLine("An error occurred: '{0}'", e); } }
private static void Combo() { var target = TargetSelector.GetSelectedTarget() ?? TargetSelector.GetTarget(800f, TargetSelector.DamageType.Physical); if (CheckTarget(target)) { if (target.Health * 1.2 < ComboDamage(target) && Menu.Item("ComboYoumuu", true).GetValue <bool>() && Items.HasItem(3142) && Items.CanUseItem(3142) && target.DistanceToPlayer() > 400) { Items.UseItem(3142); } if (target.Health < ComboDamage(target) && Menu.Item("ComboIgnite", true).GetValue <bool>() && Ignite != SpellSlot.Unknown && Ignite.IsReady()) { Me.Spellbook.CastSpell(Ignite, target); } ItemsUse(false, Menu.Item("ComboTiamat", true).GetValue <bool>(), Menu.Item("ComboHydra", true).GetValue <bool>()); if (Menu.Item("ComboPassive", true).GetValue <bool>()) { ForcusAttack(target); } if (Menu.Item("ComboQ", true).GetValue <bool>() && Q.IsReady()) { CastQ(target); } if (Menu.Item("ComboR", true).GetValue <bool>() && R.IsReady() && target.IsValidTarget(R.Range)) { if (Menu.Item("ComboRSolo", true).GetValue <bool>()) { if (Me.CountEnemiesInRange(1000) <= 2) { foreach ( var x in HeroManager.Enemies.Where( x => x.IsValidTarget(R.Range) && x.Health <= ComboDamage(x) + SpellManager.GetPassiveDamage(x, 4))) { R.CastOnUnit(x); } } } if (Menu.Item("ComboRTeam", true).GetValue <bool>()) { if (Me.CountEnemiesInRange(1000) > 2 && Me.CountAlliesInRange(1000) > 1) { foreach ( var x in HeroManager.Enemies.Where( x => x.IsValidTarget(R.Range) && x.Health <= ComboDamage(x) + SpellManager.GetPassiveDamage(x, 4) + Me.GetAutoAttackDamage(x) * 3)) { R.CastOnUnit(x); } } } } } }