Exemplo n.º 1
0
        public static void QCast(Obj_AI_Hero enemy)
        {
            switch (Initializer.Config.Item("q.type", true).GetValue <StringList>().SelectedIndex)
            {
            case 0:
                Q.Cast(Game.CursorPos);
                break;

            case 1:
                Utilities.ECast(enemy, Q);
                break;
            }
        }
Exemplo n.º 2
0
        private void LucianOnSpellCast(Obj_AI_Base sender, GameObjectProcessSpellCastEventArgs args)
        {
            if (sender.IsMe && Orbwalking.IsAutoAttack(args.SData.Name) && args.Target is AIHeroClient && args.Target.IsValid)
            {
                if (Utilities.Enabled("lucian.combo.start.e"))
                {
                    if (!E.IsReady() && Q.IsReady() && Utilities.Enabled("lucian.q.combo") &&
                        ObjectManager.Player.Distance(args.Target.Position) < Q.Range &&
                        Initializer.Orbwalker.ActiveMode == Orbwalking.OrbwalkingMode.Combo && ObjectManager.Player.Buffs.Any(buff => buff.Name != "lucianpassivebuff"))
                    {
                        Q.CastOnUnit(((AIHeroClient)args.Target));
                    }

                    if (!E.IsReady() && W.IsReady() && Utilities.Enabled("lucian.w.combo") &&
                        ObjectManager.Player.Distance(args.Target.Position) < W.Range &&
                        Initializer.Orbwalker.ActiveMode == Orbwalking.OrbwalkingMode.Combo && ObjectManager.Player.Buffs.Any(buff => buff.Name != "lucianpassivebuff"))
                    {
                        if (Utilities.Enabled("lucian.disable.w.prediction"))
                        {
                            W.Cast(((AIHeroClient)args.Target).Position);
                        }
                        else
                        {
                            if (W.GetPrediction(((AIHeroClient)args.Target)).Hitchance >= HitChance.Medium)
                            {
                                W.Cast(((AIHeroClient)args.Target).Position);
                            }
                        }
                    }
                    if (E.IsReady() && Utilities.Enabled("lucian.e.combo") &&
                        ObjectManager.Player.Distance(args.Target.Position) < Q2.Range &&
                        Initializer.Orbwalker.ActiveMode == Orbwalking.OrbwalkingMode.Combo && ObjectManager.Player.Buffs.Any(buff => buff.Name != "lucianpassivebuff"))
                    {
                        switch (Initializer.Config.Item("lucian.e.mode", true).GetValue <StringList>().SelectedIndex)
                        {
                        case 0:
                            Utilities.ECast(((AIHeroClient)args.Target), E);
                            break;

                        case 1:
                            E.Cast(Game.CursorPos);
                            break;
                        }
                    }
                }
                else
                {
                    if (Q.IsReady() && Utilities.Enabled("lucian.q.combo") &&
                        ObjectManager.Player.Distance(args.Target.Position) < Q.Range &&
                        Initializer.Orbwalker.ActiveMode == Orbwalking.OrbwalkingMode.Combo && ObjectManager.Player.Buffs.Any(buff => buff.Name != "lucianpassivebuff"))
                    {
                        Q.CastOnUnit(((AIHeroClient)args.Target));
                    }
                    if (W.IsReady() && Utilities.Enabled("lucian.w.combo") &&
                        ObjectManager.Player.Distance(args.Target.Position) < W.Range &&
                        Initializer.Orbwalker.ActiveMode == Orbwalking.OrbwalkingMode.Combo && ObjectManager.Player.Buffs.Any(buff => buff.Name != "lucianpassivebuff") &&
                        W.GetPrediction(((AIHeroClient)args.Target)).Hitchance >= HitChance.Medium)
                    {
                        W.Cast(((AIHeroClient)args.Target).Position);
                    }
                    if (E.IsReady() && Utilities.Enabled("lucian.e.combo") &&
                        ObjectManager.Player.Distance(args.Target.Position) < Q2.Range &&
                        Initializer.Orbwalker.ActiveMode == Orbwalking.OrbwalkingMode.Combo && ObjectManager.Player.Buffs.Any(buff => buff.Name != "lucianpassivebuff"))
                    {
                        switch (Initializer.Config.Item("lucian.e.mode", true).GetValue <StringList>().SelectedIndex)
                        {
                        case 0:
                            Utilities.ECast(((AIHeroClient)args.Target), E);
                            break;

                        case 1:
                            E.Cast(Game.CursorPos);
                            break;
                        }
                    }
                }
            }
            else if (sender.IsMe && Orbwalking.IsAutoAttack(args.SData.Name) && args.Target is Obj_AI_Minion && args.Target.IsValid && ((Obj_AI_Minion)args.Target).Team == GameObjectTeam.Neutral &&
                     ObjectManager.Player.ManaPercent > Utilities.Slider("lucian.clear.mana"))
            {
                if (Q.IsReady() && Utilities.Enabled("lucian.q.jungle") &&
                    ObjectManager.Player.Distance(args.Target.Position) < Q.Range &&
                    Initializer.Orbwalker.ActiveMode == Orbwalking.OrbwalkingMode.LaneClear && ObjectManager.Player.Buffs.Any(buff => buff.Name != "lucianpassivebuff"))
                {
                    Q.CastOnUnit(((Obj_AI_Minion)args.Target));
                }
                if (W.IsReady() && Utilities.Enabled("lucian.w.jungle") &&
                    ObjectManager.Player.Distance(args.Target.Position) < W.Range &&
                    Initializer.Orbwalker.ActiveMode == Orbwalking.OrbwalkingMode.LaneClear && ObjectManager.Player.Buffs.Any(buff => buff.Name != "lucianpassivebuff"))
                {
                    W.Cast(((Obj_AI_Minion)args.Target).Position);
                }
                if (E.IsReady() && Utilities.Enabled("lucian.e.jungle") &&
                    ((Obj_AI_Minion)args.Target).IsValidTarget(1000) &&
                    Initializer.Orbwalker.ActiveMode == Orbwalking.OrbwalkingMode.LaneClear && ObjectManager.Player.Buffs.Any(buff => buff.Name != "lucianpassivebuff"))
                {
                    E.Cast(Game.CursorPos);
                }
            }
        }