protected override void Combo()
        {
            var q = Menu.Item(Menu.Name + ".combo.q").GetValue <bool>();
            var e = Menu.Item(Menu.Name + ".combo.e").GetValue <bool>();
            var r = _ultimate.IsActive(UltimateModeType.Combo);

            if (e && !Q.IsCharging && E.IsReady())
            {
                var target = TargetSelector.GetTarget(E);
                if (target != null)
                {
                    var stacks = W.Level == 0 &&
                                 Menu.Item(Menu.Name + ".combo.e-settings.stacks").GetValue <Slider>().Value > 0;
                    if (Menu.Item(Menu.Name + ".combo.e-settings.always").GetValue <bool>() || stacks ||
                        GetWStacks(target) >= Menu.Item(Menu.Name + ".combo.e-settings.stacks").GetValue <Slider>().Value ||
                        E.IsKillable(target) ||
                        CPrediction.Circle(E, target, E.GetHitChance("combo")).TotalHits >=
                        Menu.Item(Menu.Name + ".combo.e-settings.min").GetValue <Slider>().Value)
                    {
                        ELogic(target, E.GetHitChance("combo"));
                    }
                }
            }
            if (q && Q.IsReady())
            {
                var target = TargetSelector.GetTarget((Q.ChargedMaxRange + Q.Width) * 1.1f, Q.DamageType);
                if (target != null)
                {
                    var stacks = W.Level == 0 &&
                                 Menu.Item(Menu.Name + ".combo.q-settings.stacks").GetValue <Slider>().Value > 0;
                    if (Q.IsCharging || Menu.Item(Menu.Name + ".combo.q-settings.always").GetValue <bool>() ||
                        target.Distance(Player) > Orbwalking.GetRealAutoAttackRange(target) * 1.2f || stacks ||
                        GetWStacks(target) >= Menu.Item(Menu.Name + ".combo.q-settings.stacks").GetValue <Slider>().Value ||
                        CPrediction.Line(Q, target, Q.GetHitChance("combo")).TotalHits >=
                        Menu.Item(Menu.Name + ".combo.q-settings.min").GetValue <Slider>().Value || Q.IsKillable(target))
                    {
                        QLogic(
                            target, Q.GetHitChance("combo"),
                            Menu.Item(Menu.Name + ".combo.q-settings.fast-cast-min").GetValue <Slider>().Value);
                    }
                }
            }
            if (r && R.IsReady())
            {
                var target = TargetSelector.GetTarget(R);
                if (target != null)
                {
                    if (!RLogic(UltimateModeType.Combo, R.GetHitChance("combo"), target))
                    {
                        RLogicSingle(UltimateModeType.Combo, R.GetHitChance("combo"));
                    }
                }
            }
        }
 protected override void Harass()
 {
     if (!ResourceManager.Check("harass") && !Q.IsCharging)
     {
         return;
     }
     if (Menu.Item(Menu.Name + ".harass.e").GetValue <bool>() && !Q.IsCharging && E.IsReady())
     {
         var target = TargetSelector.GetTarget(E);
         if (target != null)
         {
             var stacks = W.Level == 0 &&
                          Menu.Item(Menu.Name + ".harass.e-settings.stacks").GetValue <Slider>().Value > 0;
             if (Menu.Item(Menu.Name + ".harass.e-settings.always").GetValue <bool>() || stacks ||
                 GetWStacks(target) >=
                 Menu.Item(Menu.Name + ".harass.e-settings.stacks").GetValue <Slider>().Value ||
                 E.IsKillable(target) ||
                 CPrediction.Circle(E, target, E.GetHitChance("harass")).TotalHits >=
                 Menu.Item(Menu.Name + ".combo.e-settings.min").GetValue <Slider>().Value)
             {
                 ELogic(target, E.GetHitChance("harass"));
             }
         }
     }
     if (Menu.Item(Menu.Name + ".harass.q").GetValue <bool>() && Q.IsReady())
     {
         var target = TargetSelector.GetTarget((Q.ChargedMaxRange + Q.Width) * 1.1f, Q.DamageType);
         if (target != null)
         {
             var stacks = W.Level == 0 &&
                          Menu.Item(Menu.Name + ".harass.q-settings.stacks").GetValue <Slider>().Value > 0;
             if (Q.IsCharging || Menu.Item(Menu.Name + ".harass.q-settings.always").GetValue <bool>() ||
                 target.Distance(Player) > Orbwalking.GetRealAutoAttackRange(target) * 1.2f || stacks ||
                 GetWStacks(target) >=
                 Menu.Item(Menu.Name + ".harass.q-settings.stacks").GetValue <Slider>().Value ||
                 Q.IsKillable(target) ||
                 CPrediction.Line(Q, target, Q.GetHitChance("harass")).TotalHits >=
                 Menu.Item(Menu.Name + ".harass.q-settings.min").GetValue <Slider>().Value)
             {
                 QLogic(
                     target, Q.GetHitChance("harass"),
                     Menu.Item(Menu.Name + ".harass.q-settings.fast-cast-min").GetValue <Slider>().Value);
             }
         }
     }
 }
Exemple #3
0
        private void SetupMenu()
        {
            try
            {
                SFXMenu = new Menu(Global.Name, "sfx", true);

                Menu = new Menu(Global.Prefix + Player.ChampionName, SFXMenu.Name + "." + Player.ChampionName, true);

                DrawingManager.AddToMenu(Menu.AddSubMenu(new Menu("Drawings", Menu.Name + ".drawing")), this);

                TargetSelector.AddToMenu(SFXMenu.AddSubMenu(new Menu("Target Selector", SFXMenu.Name + ".ts")));

                Orbwalker = new Orbwalking.Orbwalker(SFXMenu.AddSubMenu(new Menu("Orbwalker", SFXMenu.Name + ".orb")));
                KillstealManager.AddToMenu(SFXMenu.AddSubMenu(new Menu("Killsteal", SFXMenu.Name + ".killsteal")));
                ItemManager.AddToMenu(SFXMenu.AddSubMenu(new Menu("Items", SFXMenu.Name + ".items")), ItemFlags);
                SummonerManager.AddToMenu(SFXMenu.AddSubMenu(new Menu("Summoners", SFXMenu.Name + ".summoners")));

                InfoMenu.AddToMenu(SFXMenu.AddSubMenu(new Menu("Info", SFXMenu.Name + ".info")));

                DebugMenu.AddToMenu(SFXMenu, Spells);

                Menu.AddToMainMenu();
                SFXMenu.AddToMainMenu();

                try
                {
                    AddToMenu();
                }
                catch (Exception ex)
                {
                    Global.Logger.AddItem(new LogItem(ex));
                }
            }
            catch (Exception ex)
            {
                Global.Logger.AddItem(new LogItem(ex));
            }
        }
        protected override void OnPostUpdate()
        {
            Orbwalker.SetAttack(!Q.IsCharging);
            if (_ultimate.IsActive(UltimateModeType.Assisted) && R.IsReady())
            {
                if (_ultimate.ShouldMove(UltimateModeType.Assisted))
                {
                    Orbwalking.MoveTo(Game.CursorPos, Orbwalker.HoldAreaRadius);
                }

                if (!RLogic(UltimateModeType.Assisted, R.GetHitChance("combo"), TargetSelector.GetTarget(R)))
                {
                    RLogicSingle(UltimateModeType.Assisted, R.GetHitChance("combo"));
                }
            }

            if (_ultimate.IsActive(UltimateModeType.Auto) && R.IsReady())
            {
                if (!RLogic(UltimateModeType.Auto, R.GetHitChance("combo"), TargetSelector.GetTarget(R)))
                {
                    RLogicSingle(UltimateModeType.Auto, R.GetHitChance("combo"));
                }
            }
        }