Пример #1
0
 private void OnBuffManagerBuff(object sender, BuffManagerArgs args)
 {
     try
     {
         if (W.IsReady())
         {
             if (args.UniqueId.Equals("w-immobile") && BestTargetOnlyManager.Check("w-immobile", W, args.Hero) &&
                 W.IsInRange(args.Position))
             {
                 W.Cast(args.Position);
             }
         }
     }
     catch (Exception ex)
     {
         Global.Logger.AddItem(new LogItem(ex));
     }
 }
Пример #2
0
 private void OnBuffManagerBuff(object sender, BuffManagerArgs args)
 {
     try
     {
         if (Q.IsReady())
         {
             if (args.UniqueId.Equals("q-immobile") && BestTargetOnlyManager.Check("q-immobile", Q, args.Hero) &&
                 Q.IsInRange(args.Hero))
             {
                 var best = BestQPosition(
                     args.Hero, GameObjects.EnemyHeroes.Select(e => e as Obj_AI_Base).ToList(), HitChance.High);
                 if (!best.Item2.Equals(Vector3.Zero) && best.Item1 >= 1)
                 {
                     Q.Cast(best.Item2);
                 }
             }
         }
     }
     catch (Exception ex)
     {
         Global.Logger.AddItem(new LogItem(ex));
     }
 }