internal static void Combo(bool useq, bool usew, bool usee, bool user) { if (useq && Lib.Spellbook["Q"].IsReady()) { var qtarget = TargetSelector.GetTarget(Lib.Spellbook["Q"].Range, DamageType.Physical); if (qtarget == null) { return; } if (CanQ(qtarget) && Lib.Player.CanMove) { Lib.Spellbook["Q"].Cast(); if (Config["rmenu"].GetValue <MenuBool>("autoblade").Enabled) { AutoQBlade(qtarget); } } } if (usew && Lib.Spellbook["W"].IsReady()) { var wtarget = TargetSelector.GetTarget(Lib.Spellbook["W"].Range); if (wtarget == null) { return; } if (wtarget.IsValidTarget(Lib.Spellbook["W"].Range)) { if (Variables.GameTimeTickCount - LastDunkTimeStamp >= 500) { Lib.Spellbook["W"].CastOnUnit(wtarget); } } } if (usee && Lib.Spellbook["E"].IsReady()) { var etarget = TargetSelector.GetTarget(Lib.Spellbook["E"].Range); if (etarget == null) { return; } if (etarget.IsValidTarget()) { if (etarget.Distance(Lib.Player.PreviousPosition) > 250) { if (Lib.Player.CountAllyHeroesInRange(1000) >= 1) { Lib.Spellbook["E"].Cast(etarget.PreviousPosition); } if (Lib.RDmg(etarget, PassiveCount(etarget)) - Lib.Hemorrhage(etarget, 1) >= etarget.Health) { Lib.Spellbook["E"].Cast(etarget.PreviousPosition); } if (Lib.Spellbook["W"].IsReady()) { Lib.Spellbook["E"].Cast(etarget.PreviousPosition); } if (Lib.Player.GetAutoAttackDamage(etarget) + Lib.Hemorrhage(etarget, 3) * 3 >= etarget.Health) { Lib.Spellbook["E"].Cast(etarget.PreviousPosition); } } } } if (user && Lib.Spellbook["R"].IsReady()) { var unit = TargetSelector.GetTarget(Lib.Spellbook["R"].Range, DamageType.True); if (unit == null) { return; } if (unit.IsValidTarget(Lib.Spellbook["R"].Range)) { if (!unit.HasBuffOfType(BuffType.Invulnerability) && !unit.HasBuffOfType(BuffType.SpellShield)) { if (Lib.RDmg(unit, PassiveCount(unit)) + RModifier >= unit.Health + Lib.Hemorrhage(unit, 1) + MordeShield(unit)) { if (!unit.IsInvulnerable) { if (!unit.HasBuff("kindredrnodeathbuff")) { Lib.Spellbook["R"].CastOnUnit(unit); } } } } } } }
internal static void Combo(bool useq, bool usew, bool usee, bool user) { if (useq && Lib.Spellbook["Q"].IsReady()) { if (CanQ(TargetSelector.GetTarget(Lib.Spellbook["E"].Range, TargetSelector.DamageType.Physical))) { Lib.Spellbook["Q"].Cast(); } } if (usew && Lib.Spellbook["W"].IsReady()) { var wtarget = TargetSelector.GetTarget(Lib.Spellbook["E"].Range, TargetSelector.DamageType.Physical); if (wtarget.IsValidTarget(Lib.Spellbook["W"].Range) && !wtarget.IsZombie) { if (wtarget.Distance(Lib.Player.ServerPosition) <= 200 && Lib.WDmg(wtarget) >= wtarget.Health) { if (Utils.GameTimeTickCount - LastDunkTimeStamp >= 500) { Lib.Spellbook["W"].Cast(); } } } } if (usee && Lib.Spellbook["E"].IsReady()) { var etarget = TargetSelector.GetTarget(Lib.Spellbook["E"].Range, TargetSelector.DamageType.Physical); if (etarget.IsValidTarget()) { if (etarget.Distance(Lib.Player.ServerPosition) > 250) { if (Lib.Player.CountAlliesInRange(1000) >= 1) { Lib.Spellbook["E"].Cast(etarget.ServerPosition); } if (Lib.RDmg(etarget, PassiveCount(etarget)) - Lib.Hemorrhage(etarget, 1) >= etarget.Health) { Lib.Spellbook["E"].Cast(etarget.ServerPosition); } if (Lib.Spellbook["Q"].IsReady() || Lib.Spellbook["W"].IsReady()) { Lib.Spellbook["E"].Cast(etarget.ServerPosition); } if (Lib.Player.GetAutoAttackDamage(etarget) + Lib.Hemorrhage(etarget, 3) * 3 >= etarget.Health) { Lib.Spellbook["E"].Cast(etarget.ServerPosition); } } } } if (user && Lib.Spellbook["R"].IsReady()) { var unit = TargetSelector.GetTarget(Lib.Spellbook["E"].Range, TargetSelector.DamageType.Physical); if (unit.IsValidTarget(Lib.Spellbook["R"].Range) && !unit.IsZombie) { if (!unit.HasBuffOfType(BuffType.Invulnerability) && !unit.HasBuffOfType(BuffType.SpellShield)) { if (Lib.RDmg(unit, PassiveCount(unit)) + RModifier >= unit.Health + Lib.Hemorrhage(unit, 1) + MordeShield(unit)) { if (!TargetSelector.IsInvulnerable(unit, TargetSelector.DamageType.True)) { if (!unit.HasBuff("kindredrnodeathbuff")) { Lib.Spellbook["R"].CastOnUnit(unit); } } } } } } }
internal static void Game_OnUpdate(EventArgs args) { if (ObjectManager.Player.IsDead) { return; } if (Lib.Spellbook["E"].IsReady() && Config["rmenu"].GetValue <MenuBool>("tpcancel").Enabled) { var etarget = TargetSelector.GetTarget(Lib.Spellbook["E"].Range); if (etarget == null) { return; } if (etarget.IsValidTarget() && etarget.HasBuff("Teleport")) { if (etarget.Distance(Lib.Player.PreviousPosition) > 250) { Lib.Spellbook["E"].Cast(etarget.PreviousPosition); } } } if (IgniteSlot.IsReady() && Config["rmenu"].GetValue <MenuBool>("useIgn").Enabled) { var igtarget = TargetSelector.GetTarget(Lib.Player.GetRealAutoAttackRange(), DamageType.True); if (igtarget == null) { return; } var Ignitedmg = Damage.GetSummonerSpellDamage(ObjectManager.Player, igtarget, SummonerSpell.Ignite); if (igtarget.Health < Ignitedmg) { //Cast Ignite } } if (Lib.Spellbook["R"].IsReady() && Config["rmenu"].GetValue <MenuBool>("ksr").Enabled) { foreach (var unit in GameObjects.EnemyHeroes.Where(ene => ene.IsValidTarget(Lib.Spellbook["R"].Range))) { if (unit == null) { return; } if (unit.CountEnemyHeroesInRange(1200) <= 1 && Config["rmenu"].GetValue <MenuBool>("ksr1").Enabled) { if (Lib.RDmg(unit, PassiveCount(unit)) + RModifier + Lib.Hemorrhage(unit, PassiveCount(unit)) >= unit.Health + MordeShield(unit)) { if (!TargetSelector.GetTarget(Lib.Spellbook["R"].Range, DamageType.True).IsInvulnerable) { if (!unit.HasBuff("kindredrnodeathbuff")) { Lib.Spellbook["R"].CastOnUnit(unit); } } } } if (Lib.RDmg(unit, PassiveCount(unit)) + RModifier >= unit.Health + Lib.Hemorrhage(unit, 1) + MordeShield(unit)) { if (!TargetSelector.GetTarget(Lib.Spellbook["R"].Range, DamageType.True).IsInvulnerable) { if (!unit.HasBuff("kindredrnodeathbuff")) { Lib.Spellbook["R"].CastOnUnit(unit); } } } } } switch (Orbwalker.ActiveMode) { case OrbwalkerMode.Combo: Combo(Config["cmenu"].GetValue <MenuBool>("useq").Enabled, Config["cmenu"].GetValue <MenuBool>("usew").Enabled, Config["cmenu"].GetValue <MenuBool>("usee").Enabled, Config["rmenu"].GetValue <MenuBool>("user").Enabled); break; case OrbwalkerMode.Harass: Harass(); break; case OrbwalkerMode.LaneClear: Clear(); break; case OrbwalkerMode.LastHit: LastHit(); break; } if (Config["cmenu"].GetValue <MenuKeyBind>("caste").Active) { Orbwalker.Orbwalk(null, Game.CursorPos); Combo(false, false, true, false); } }
internal static void Game_OnUpdate(EventArgs args) { if (Config.Item("useHPot").GetValue <bool>() && Config.Item("useHPotV").GetValue <Slider>().Value > Lib.Player.HealthPercent) { if (Items.HasItem(HealthPot.Id) && Items.CanUseItem(HealthPot.Id) && !ObjectManager.Player.HasBuff("RegenerationPotion", true) && !ObjectManager.Player.IsRecalling()) { HealthPot.Cast(); } } if (Config.Item("useMPot").GetValue <bool>() && Config.Item("useMPotV").GetValue <Slider>().Value > Lib.Player.ManaPercent) { if (Items.HasItem(ManaPot.Id) && Items.CanUseItem(ManaPot.Id) && !ObjectManager.Player.HasBuff("ManaRegeneration", true) && !ObjectManager.Player.IsRecalling() && !ObjectManager.Player.InFountain() && !ObjectManager.Player.HasBuff("FlaskOfCrystalWater") && !ObjectManager.Player.HasBuff("ItemCrystalFlask")) { ManaPot.Cast(); } } if (Config.Item("useCFlask").GetValue <bool>() && Config.Item("useCFlaskH").GetValue <Slider>().Value > Lib.Player.HealthPercent || Config.Item("useCFlaskM").GetValue <Slider>().Value > Lib.Player.ManaPercent) { if (Items.HasItem(CrystalFlask.Id) && Items.CanUseItem(CrystalFlask.Id) && !ObjectManager.Player.HasBuff("RegenerationPotion", true) && !ObjectManager.Player.IsRecalling() && !ObjectManager.Player.InFountain() && !ObjectManager.Player.HasBuff("FlaskOfCrystalWater") && !ObjectManager.Player.HasBuff("ItemCrystalFlask")) { CrystalFlask.Cast(); } } if (Lib.Spellbook["E"].IsReady() && Config.Item("tpcancel").GetValue <bool>()) { var etarget = TargetSelector.GetTarget(Lib.Spellbook["E"].Range, TargetSelector.DamageType.Physical); if (etarget.IsValidTarget() && etarget.HasBuff("Teleport")) { if (etarget.Distance(Lib.Player.ServerPosition) > 250) { Lib.Spellbook["E"].Cast(etarget.ServerPosition); } } } if (IgniteSlot.IsReady() && Config.Item("useIgn").GetValue <bool>()) { var etarget = TargetSelector.GetTarget(Lib.Spellbook["R"].Range, TargetSelector.DamageType.Physical); var Ignitedmg = Damage.GetSummonerSpellDamage(ObjectManager.Player, etarget, Damage.SummonerSpell.Ignite); if (etarget.Health < Ignitedmg) { //Cast Ignite } } if (Lib.Spellbook["R"].IsReady() && Config.Item("ksr").GetValue <bool>()) { foreach (var unit in HeroManager.Enemies.Where(ene => ene.IsValidTarget(Lib.Spellbook["R"].Range) && !ene.IsZombie)) { if (unit.CountEnemiesInRange(1200) <= 1 && Config.Item("ksr1").GetValue <bool>()) { if (Lib.RDmg(unit, PassiveCount(unit)) + RModifier + Lib.Hemorrhage(unit, PassiveCount(unit)) >= unit.Health + MordeShield(unit)) { if (!TargetSelector.IsInvulnerable(unit, TargetSelector.DamageType.True)) { if (!unit.HasBuff("kindredrnodeathbuff")) { Lib.Spellbook["R"].CastOnUnit(unit); } } } } if (Lib.RDmg(unit, PassiveCount(unit)) + RModifier >= unit.Health + Lib.Hemorrhage(unit, 1) + MordeShield(unit)) { if (!TargetSelector.IsInvulnerable(unit, TargetSelector.DamageType.True)) { if (!unit.HasBuff("kindredrnodeathbuff")) { Lib.Spellbook["R"].CastOnUnit(unit); } } } } } switch (Orbwalker.ActiveMode) { case Orbwalking.OrbwalkingMode.Combo: Combo(Config.Item("useq").GetValue <bool>(), Config.Item("usew").GetValue <bool>(), Config.Item("usee").GetValue <bool>(), Config.Item("user").GetValue <bool>()); break; case Orbwalking.OrbwalkingMode.Mixed: Harass(); break; } if (Config.Item("caste").GetValue <KeyBind>().Active) { Orbwalking.Orbwalk(null, Game.CursorPos); Combo(false, false, true, false); } }