Пример #1
0
        public Ahri()
        {
            ShopSequence = "3340:Buy,1056:Buy,2003:StartHpPot,1052:Buy,1033:Buy,1057:Buy,1052:Buy,3108:Buy,3001:Buy,1001:Buy,3020:Buy,1052:Buy,2003:StopHpPot,1052:Buy,3108:Buy,1052:Buy,3802:Buy,3165:Buy,1026:Buy,1052:Buy,3135:Buy,1058:Buy,1056:Sell,1026:Buy,3089:Buy,1052:Buy,3113:Buy,3285:Buy";

            Gapcloser.OnGapcloser += (sender, args) =>
            {
                if (_R.State == SpellState.Ready && args.Type != Gapcloser.GapcloserType.Targeted)
                {
                    _R.Cast(AutoWalker.p.GetNearestTurret(false).ServerPosition);
                }
            };
        }
Пример #2
0
        private void Game_OnUpdate(System.EventArgs args)
        {
            var target = EntityManager.Heroes.Enemies.OrderBy(x => x.Health).ThenBy(x => x.Distance(Player.Instance)).FirstOrDefault();

            if (target == null)
            {
                return;
            }
            if (_E.State == SpellState.Ready && _E.IsInRange(target))
            {
                _E.Cast();
            }
            if (_Q.State == SpellState.Ready && _Q.IsInRange(target))
            {
                _Q.Cast(target);
            }
        }
Пример #3
0
        public static void OnSkillShotDetected_OnDetect(DetectedSkillshotData args)
        {
            if (args.Caster == null || !args.Caster.IsEnemy || !args.WillHit(Player.Instance) || !Program.SubMenu["enabled"].Cast <CheckBox>().CurrentValue)
            {
                return;
            }

            var hero   = args.Caster as AIHeroClient;
            var player = Player.Instance;

            #region Skillshots

            foreach (var shot in Shots.Where(shot => args.Data.MissileName == shot))
            {
                if (player.BaseSkinName == "Zyra")
                {
                    W = new Spell.SimpleSkillshot(SpellSlot.W);
                    E = new Spell.SimpleSkillshot(SpellSlot.E);
                    {
                        if (hero != null && W.IsReady() && E.IsReady())
                        {
                            W.Cast((Vector3)player.ServerPosition.Extend(hero.ServerPosition, 80));
                            E.Cast((Vector3)player.ServerPosition.Extend(hero.ServerPosition, 80));
                        }
                    }
                }

                if (player.BaseSkinName == "Sivir")
                {
                    E = new Spell.Active(SpellSlot.E);
                    {
                        if (hero != null && E.IsReady())
                        {
                            E.Cast();
                        }
                    }
                }

                if (player.BaseSkinName == "Heimerdinger")
                {
                    Q = new Spell.SimpleSkillshot(SpellSlot.Q);
                    {
                        if (hero != null && Q.IsReady())
                        {
                            Q.Cast((Vector3)player.ServerPosition.Extend(hero.ServerPosition, 80));
                        }
                    }
                }

                if (player.BaseSkinName == "Leblanc")
                {
                    R  = new Spell.Active(SpellSlot.R);
                    R1 = new Spell.SimpleSkillshot(SpellSlot.R);
                    {
                        if (hero != null && R.IsReady())
                        {
                            if (player.Spellbook.Spells[3].Name == "LeblancR")
                            {
                                R.Cast();
                                R1.Cast((Vector3)player.ServerPosition.Extend(hero.ServerPosition, 80));
                            }
                            else
                            {
                                R1.Cast((Vector3)player.ServerPosition.Extend(hero.ServerPosition, 80));
                            }
                        }
                    }
                }

                if (player.BaseSkinName == "Shaco")
                {
                    W = new Spell.SimpleSkillshot(SpellSlot.W);
                    {
                        if (hero != null && W.IsReady())
                        {
                            W.Cast((Vector3)player.ServerPosition.Extend(hero.ServerPosition, 80));
                        }
                    }
                }

                if (player.BaseSkinName == "Fiora")
                {
                    W = new Spell.SimpleSkillshot(SpellSlot.W);
                    {
                        if (hero != null && W.IsReady())
                        {
                            W.Cast(hero.ServerPosition);
                        }
                    }
                }

                if (player.BaseSkinName == "Fizz")
                {
                    W = new Spell.Active(SpellSlot.E);
                    {
                        if (hero != null && E.IsReady() && E.ToggleState != 1)
                        {
                            E.Cast();
                        }
                    }
                }

                if (player.BaseSkinName == "Malzahar")
                {
                    W = new Spell.SimpleSkillshot(SpellSlot.W);
                    {
                        if (hero != null && W.IsReady())
                        {
                            W.Cast((Vector3)player.ServerPosition.Extend(hero.ServerPosition, 80));
                        }
                    }
                }

                if (player.BaseSkinName == "MonkeyKing")
                {
                    W = new Spell.Active(SpellSlot.W);
                    {
                        if (hero != null && W.IsReady())
                        {
                            W.Cast();
                        }
                    }
                }

                if (player.BaseSkinName == "Yasuo")
                {
                    W = new Spell.SimpleSkillshot(SpellSlot.W);
                    {
                        if (hero != null && W.IsReady())
                        {
                            W.Cast((Vector3)player.ServerPosition.Extend(hero.ServerPosition, 5));
                        }
                    }
                }

                if (player.BaseSkinName == "Nocturne")
                {
                    E = new Spell.Active(SpellSlot.E);
                    {
                        if (hero != null && E.IsReady())
                        {
                            E.Cast();
                        }
                    }
                }
            }

            #endregion

            #region Hooks

            foreach (var hook in Hooks.Where(hook => args.Data.MissileName == hook))
            {
                if (player.BaseSkinName == "Zyra")
                {
                    W = new Spell.SimpleSkillshot(SpellSlot.W);
                    E = new Spell.SimpleSkillshot(SpellSlot.E);
                    {
                        if (hero != null && W.IsReady() && E.IsReady())
                        {
                            W.Cast((Vector3)player.ServerPosition.Extend(hero.ServerPosition, 80));
                            E.Cast((Vector3)player.ServerPosition.Extend(hero.ServerPosition, 80));
                        }
                    }
                }

                if (player.BaseSkinName == "Sivir")
                {
                    E = new Spell.Active(SpellSlot.E);
                    {
                        if (hero != null && E.IsReady())
                        {
                            E.Cast();
                        }
                    }
                }

                if (player.BaseSkinName == "Anivia")
                {
                    W = new Spell.SimpleSkillshot(SpellSlot.W);
                    {
                        if (hero != null && W.IsReady())
                        {
                            Core.DelayAction(() => W.Cast((Vector3)player.ServerPosition.Extend(hero.ServerPosition, 50)), (int)player.Distance(hero) / 2);
                        }
                    }
                }

                if (player.BaseSkinName == "Heimerdinger")
                {
                    Q = new Spell.SimpleSkillshot(SpellSlot.Q);
                    {
                        if (hero != null && Q.IsReady())
                        {
                            Q.Cast((Vector3)player.ServerPosition.Extend(hero.ServerPosition, 80));
                        }
                    }
                }

                if (player.BaseSkinName == "Leblanc")
                {
                    R  = new Spell.Active(SpellSlot.R);
                    R1 = new Spell.SimpleSkillshot(SpellSlot.R);
                    {
                        if (hero != null && R.IsReady())
                        {
                            if (player.Spellbook.Spells[3].Name == "LeblancR")
                            {
                                R.Cast();
                                R1.Cast((Vector3)player.ServerPosition.Extend(hero.ServerPosition, 80));
                            }
                            else
                            {
                                R1.Cast((Vector3)player.ServerPosition.Extend(hero.ServerPosition, 50));
                            }
                        }
                    }
                }

                if (player.BaseSkinName == "Shaco")
                {
                    W = new Spell.SimpleSkillshot(SpellSlot.W);
                    {
                        if (hero != null && W.IsReady())
                        {
                            W.Cast((Vector3)player.ServerPosition.Extend(hero.ServerPosition, 80));
                        }
                    }
                }

                if (player.BaseSkinName == "Fiora")
                {
                    W = new Spell.SimpleSkillshot(SpellSlot.W);
                    {
                        if (hero != null && W.IsReady())
                        {
                            W.Cast(hero.ServerPosition);
                        }
                    }
                }

                if (player.BaseSkinName == "Fizz")
                {
                    E = new Spell.Active(SpellSlot.E);
                    {
                        if (hero != null && E.IsReady() && E.ToggleState != 1)
                        {
                            E.Cast();
                        }
                    }
                }

                if (player.BaseSkinName == "Malzahar")
                {
                    W = new Spell.SimpleSkillshot(SpellSlot.W);
                    {
                        if (hero != null && W.IsReady())
                        {
                            W.Cast((Vector3)player.ServerPosition.Extend(hero.ServerPosition, 80));
                        }
                    }
                }

                if (player.BaseSkinName == "Trundle")
                {
                    E = new Spell.SimpleSkillshot(SpellSlot.E, 1000);
                    {
                        if (hero != null && E.IsReady())
                        {
                            Core.DelayAction(() => E.Cast((Vector3)player.ServerPosition.Extend(hero.ServerPosition, 50)), (int)player.Distance(hero) / 2);
                        }
                    }
                }

                if (player.BaseSkinName == "MonkeyKing")
                {
                    W = new Spell.Active(SpellSlot.W);
                    {
                        if (hero != null && W.IsReady())
                        {
                            W.Cast();
                        }
                    }
                }

                if (player.BaseSkinName == "Yasuo")
                {
                    W = new Spell.SimpleSkillshot(SpellSlot.W);
                    {
                        if (hero != null && W.IsReady())
                        {
                            W.Cast((Vector3)player.ServerPosition.Extend(hero.ServerPosition, 5));
                        }
                    }
                }

                if (player.BaseSkinName == "Nocturne")
                {
                    E = new Spell.Active(SpellSlot.E);
                    {
                        if (hero != null && E.IsReady())
                        {
                            E.Cast();
                        }
                    }
                }
            }

            #endregion
        }