public Azir() : base("Azir", "SAutoCarry - Azir") { SoldierMgr.Initialize(this); Orbwalker.RegisterCanAttack(CanAttack); Orbwalker.RegisterCanOrbwalkTarget(CanOrbwalkTarget); OnCombo += Combo; OnHarass += Harass; OnLaneClear += LaneClear; OnUpdate += BeforeOrbwalk; }
private void Awake() { if (instance == null) { instance = this; DontDestroyOnLoad(gameObject); } else { Destroy(gameObject); } }
public bool ShouldCast(SpellSlot slot, Obj_AI_Hero target) { switch (slot) { case SpellSlot.Q: { if (ComboUseQOnlyOutOfRange && SoldierMgr.InAARange(target)) { return(false); } if (SoldierMgr.ActiveSoldiers.Count == 0) { return(false); } return(true); } case SpellSlot.W: { if (Spells[W].Instance.Ammo == 0) { return(false); } return(true); } case SpellSlot.E: { if (CalculateDamageW(target) - SCommon.Damage.AutoAttack.GetDamage(target) >= target.Health) { return(true); } return(false); } case SpellSlot.R: { if (CalculateDamageR(target) >= target.Health - 150) { return(true); } if (ObjectManager.Player.HealthPercent < ComboRMinHP) { return(true); } if (IsWallStunable(target.ServerPosition.To2D(), Spells[R].GetSPrediction(target).UnitPosition) && CalculateDamageR(target) >= target.Health / 2f) { return(true); } if (ComboRMinHit > 1 && Spells[R].GetAoeSPrediction().HitCount > ComboRMinHit) { return(true); } return(false); } } return(false); }
public static void Game_OnGameLoad() { //Verify Champion if (Player.ChampionName != "Azir") { return; } SoldierMgr.InitializeA(); //Spells _q = new LeagueSharp.Common.Spell(SpellSlot.Q, 1175); _q2 = new LeagueSharp.Common.Spell(SpellSlot.Q); _w = new LeagueSharp.Common.Spell(SpellSlot.W, 450); _e = new LeagueSharp.Common.Spell(SpellSlot.E, 1100); _r = new LeagueSharp.Common.Spell(SpellSlot.R, 250); _r2 = new LeagueSharp.Common.Spell(SpellSlot.R); _q.SetSkillshot(0.0f, 65, 1500, false, SkillshotType.SkillshotLine); _q.MinHitChance = LeagueSharp.Common.HitChance.Medium; //Menu instance _menu = MainMenu.AddMenu(Player.ChampionName, Player.ChampionName); //spell menu spellMenu = _menu.AddSubMenu("技能", "Spells"); spellMenu.Add("EQdelay", new Slider("EQ 延迟(人性化)", 100, 0, 300)); spellMenu.Add("EQmouse", new KeyBind("E Q 至鼠标", false, KeyBind.BindTypes.HoldActive, 'G')); spellMenu.Add("insec", new KeyBind("神推(选择的目标)", false, KeyBind.BindTypes.HoldActive, 'Y')); spellMenu.Add("insecmode", new ComboBox("神推模式", 0, "最近的友军", "最近的塔", "鼠标", "最后记录位置")); spellMenu.Add("insecpolar", new KeyBind("神推坐标记录", false, KeyBind.BindTypes.HoldActive, 'T')); //combo Combo = _menu.AddSubMenu("连招", "Combo"); Combo.Add("QC", new CheckBox("Q")); Combo.Add("WC", new CheckBox("W")); Combo.Add("donotqC", new CheckBox("保留 Q 如果目标在士兵范围内", false)); //Harass Harass = _menu.AddSubMenu("骚扰", "Harass"); Harass.Add("QH", new CheckBox("Q")); Harass.Add("WH", new CheckBox("W")); Harass.Add("donotqH", new CheckBox("保留 Q 如果目标在士兵范围内", false)); // AUTO _Auto = _menu.AddSubMenu("自动", "Auto"); _Auto.Add("RKS", new CheckBox("使用 R 其他")); _Auto.Add("RTOWER", new CheckBox("R 目标至塔")); _Auto.Add("RGAP", new CheckBox("R 防突击", false)); //Drawing Draw = _menu.AddSubMenu("线圈", "Drawing"); Draw.Add("drawQ", new CheckBox(drawQ)); Draw.Add("drawW", new CheckBox(drawW)); Draw.Add("drawInsec", new CheckBox(drawInsec)); GameObjects.Initialize(); Soldiers.AzirSoldier(); AzirCombo.Initialize(); AzirHarass.Initialize(); AzirFarm.Initialize(); JumpToMouse.Initialize(); Insec.Initialize(); //Listen to events Drawing.OnDraw += Drawing_OnDraw; Game.OnUpdate += Game_OnGameUpdate; Obj_AI_Base.OnSpellCast += Obj_AI_Base_OnDoCast; Obj_AI_Base.OnProcessSpellCast += Obj_AI_Base_OnProcessSpellCast; AntiGapcloser.OnEnemyGapcloser += AntiGapcloser_OnEnemyGapcloser; }
public static void Game_OnGameLoad() { //Verify Champion if (Player.ChampionName != "Azir") { return; } SoldierMgr.InitializeA(); //Spells _q = new LeagueSharp.Common.Spell(SpellSlot.Q, 1175); _q2 = new LeagueSharp.Common.Spell(SpellSlot.Q); _w = new LeagueSharp.Common.Spell(SpellSlot.W, 450); _e = new LeagueSharp.Common.Spell(SpellSlot.E, 1100); _r = new LeagueSharp.Common.Spell(SpellSlot.R, 250); _r2 = new LeagueSharp.Common.Spell(SpellSlot.R); _q.SetSkillshot(0.0f, 65, 1500, false, SkillshotType.SkillshotLine); _q.MinHitChance = LeagueSharp.Common.HitChance.Medium; //Menu instance _menu = MainMenu.AddMenu(Player.ChampionName, Player.ChampionName); //spell menu spellMenu = _menu.AddSubMenu("Spells", "Spells"); spellMenu.Add("EQdelay", new Slider("EQ lower delay", 100, 0, 300)); spellMenu.Add("EQmouse", new KeyBind("E Q to mouse", false, KeyBind.BindTypes.HoldActive, 'G')); spellMenu.Add("insec", new KeyBind("Insec Selected", false, KeyBind.BindTypes.HoldActive, 'Y')); spellMenu.Add("insecmode", new ComboBox("Insec Mode", 0, "nearest ally", "nearest turret", "mouse", "last key press")); spellMenu.Add("insecpolar", new KeyBind("Insec point key", false, KeyBind.BindTypes.HoldActive, 'T')); //combo Combo = _menu.AddSubMenu("Combo", "Combo"); Combo.Add("QC", new CheckBox("Q")); Combo.Add("WC", new CheckBox("W")); Combo.Add("donotqC", new CheckBox("Save Q if target in soldier's range", false)); //Harass Harass = _menu.AddSubMenu("Harass", "Harass"); Harass.Add("QH", new CheckBox("Q")); Harass.Add("WH", new CheckBox("W")); Harass.Add("donotqH", new CheckBox("Save Q if target in soldier's range", false)); // AUTO _Auto = _menu.AddSubMenu("Auto", "Auto"); _Auto.Add("RKS", new CheckBox("use R KS")); _Auto.Add("RTOWER", new CheckBox("R target to Tower")); _Auto.Add("RGAP", new CheckBox("R anti GAP", false)); //Drawing Draw = _menu.AddSubMenu("Drawing", "Drawing"); Draw.Add("drawQ", new CheckBox(drawQ)); Draw.Add("drawW", new CheckBox(drawW)); Draw.Add("drawInsec", new CheckBox(drawInsec)); GameObjects.Initialize(); Soldiers.AzirSoldier(); AzirCombo.Initialize(); AzirHarass.Initialize(); AzirFarm.Initialize(); JumpToMouse.Initialize(); Insec.Initialize(); //Listen to events Drawing.OnDraw += Drawing_OnDraw; Game.OnUpdate += Game_OnGameUpdate; Obj_AI_Base.OnSpellCast += Obj_AI_Base_OnDoCast; Obj_AI_Base.OnProcessSpellCast += Obj_AI_Base_OnProcessSpellCast; AntiGapcloser.OnEnemyGapcloser += AntiGapcloser_OnEnemyGapcloser; }