private static void Game_OnGameUpdate(EventArgs args) { //Update the combo and harass values. ChampionClass.ComboActive = Orbwalker.ActiveModesFlags.HasFlag(Orbwalker.ActiveModes.Combo); var vHarassManaPer = harass["HarassMana"].Cast <Slider>().CurrentValue; ChampionClass.HarassActive = Orbwalker.ActiveModesFlags.HasFlag(Orbwalker.ActiveModes.Harass) && ObjectManager.Player.ManaPercent >= vHarassManaPer; ChampionClass.ToggleActive = ObjectManager.Player.ManaPercent >= vHarassManaPer && !Orbwalker.ActiveModesFlags.HasFlag(Orbwalker.ActiveModes.Combo) && !ObjectManager.Player.LSIsRecalling(); var vLaneClearManaPer = HeroManager.Enemies.Find(e => e.LSIsValidTarget(2000) && !e.IsZombie) == null ? laneclear["LaneMana.Alone"].Cast <Slider>().CurrentValue : laneclear["LaneMana.Enemy"].Cast <Slider>().CurrentValue; ChampionClass.LaneClearActive = (Orbwalker.ActiveModesFlags.HasFlag(Orbwalker.ActiveModes.LaneClear) || Orbwalker.ActiveModesFlags.HasFlag(Orbwalker.ActiveModes.JungleClear)) && ObjectManager.Player.ManaPercent >= vLaneClearManaPer && laneclear["Lane.Enabled"].Cast <KeyBind>().CurrentValue; ChampionClass.JungleClearActive = false; if ((Orbwalker.ActiveModesFlags.HasFlag(Orbwalker.ActiveModes.LaneClear) || Orbwalker.ActiveModesFlags.HasFlag(Orbwalker.ActiveModes.JungleClear)) && jungleClear["Jungle.Enabled"].Cast <KeyBind>().CurrentValue) { List <Obj_AI_Base> mobs = MinionManager.GetMinions(ObjectManager.Player.Position, 1000, MinionTypes.All, MinionTeam.Neutral); if (mobs.Count > 0) { var minMana = jungleClear["Jungle.Mana.Enemy"].Cast <Slider>().CurrentValue; if (mobs[0].BaseSkinName.ToLower().Contains("baron") || mobs[0].BaseSkinName.ToLower().Contains("dragon") || mobs[0].Team() == Jungle.GameObjectTeam.Neutral) { minMana = jungleClear["Jungle.Mana.BigBoys"].Cast <Slider>().CurrentValue; } else if (mobs[0].Team() == (Jungle.GameObjectTeam)ObjectManager.Player.Team) { minMana = jungleClear["Jungle.Mana.Ally"].Cast <Slider>().CurrentValue; } else if (mobs[0].Team() != (Jungle.GameObjectTeam)ObjectManager.Player.Team) { minMana = jungleClear["Jungle.Mana.Enemy"].Cast <Slider>().CurrentValue; } if (ObjectManager.Player.ManaPercent >= minMana) { ChampionClass.JungleClearActive = true; } } } ChampionClass.Game_OnGameUpdate(args); UseSummoners(); var useItemModes = MenuActivator["UseItemsMode"].Cast <ComboBox>().CurrentValue; //Items if ( !((Orbwalker.ActiveModesFlags.HasFlag(Orbwalker.ActiveModes.Combo) && (useItemModes == 2 || useItemModes == 3)) || (Orbwalker.ActiveModesFlags.HasFlag(Orbwalker.ActiveModes.Harass) && (useItemModes == 1 || useItemModes == 3)))) { return; } var botrk = MenuActivator["BOTRK"].Cast <CheckBox>().CurrentValue; var ghostblade = MenuActivator["GHOSTBLADE"].Cast <CheckBox>().CurrentValue; var sword = MenuActivator["SWORD"].Cast <CheckBox>().CurrentValue; var muramana = MenuActivator["MURAMANA"].Cast <CheckBox>().CurrentValue; var target = Orbwalker.LastTarget as Obj_AI_Base; var smiteReady = (SmiteSlot != SpellSlot.Unknown && ObjectManager.Player.Spellbook.CanUseSpell(SmiteSlot) == SpellState.Ready); if (smiteReady && Orbwalker.ActiveModesFlags.HasFlag(Orbwalker.ActiveModes.Combo)) { Smiteontarget(target as AIHeroClient); } if (botrk) { if (target != null && target.Type == ObjectManager.Player.Type && target.ServerPosition.LSDistance(ObjectManager.Player.ServerPosition) < 550) { var hasCutGlass = Items.HasItem(3144); var hasBotrk = Items.HasItem(3153); if (hasBotrk || hasCutGlass) { var itemId = hasCutGlass ? 3144 : 3153; var damage = ObjectManager.Player.GetItemDamage(target, LeagueSharp.Common.Damage.DamageItems.Botrk); if (hasCutGlass || ObjectManager.Player.Health + damage < ObjectManager.Player.MaxHealth) { Items.UseItem(itemId, target); } } } } if (ghostblade && target != null && target.Type == ObjectManager.Player.Type && !ObjectManager.Player.HasBuff("ItemSoTD") && /*if Sword of the divine is not active */ Orbwalking.InAutoAttackRange(target)) { Items.UseItem(3142); } if (sword && target != null && target.Type == ObjectManager.Player.Type && !ObjectManager.Player.HasBuff("spectralfury") && /*if ghostblade is not active*/ Orbwalking.InAutoAttackRange(target)) { Items.UseItem(3131); } if (muramana && Items.HasItem(3042)) { if (target != null && ChampionClass.ComboActive && target.Position.LSDistance(ObjectManager.Player.Position) < 1200) { if (!ObjectManager.Player.HasBuff("Muramana")) { Items.UseItem(3042); } } else { if (ObjectManager.Player.HasBuff("Muramana")) { Items.UseItem(3042); } } } }