Пример #1
0
        public static void OnPlayAnimation(Obj_AI_Base sender, Obj_AI_BasePlayAnimationEventArgs args)
        {
            if (sender == null || !sender.IsMe)
            {
                return;
            }

            switch (args.Animation)
            {
            case "Spell3":
                if (Extension.CurrentMode == Mode.Tornado)
                {
                    SpellConfig.SetSkill(Mode.DashingTornado);
                }
                else
                {
                    SpellConfig.SetSkill(Mode.Dashing);

                    DelayAction.Queue(1000,
                                      () =>
                    {
                        SpellConfig.SetSkill(Mode.Normal);
                    },
                                      new CancellationToken(false));
                }
                break;
            }
        }
Пример #2
0
 /// <summary>
 ///     Called on animation trigger.
 /// </summary>
 /// <param name="sender">The sender.</param>
 /// <param name="args">The <see cref="Obj_AI_BasePlayAnimationEventArgs" /> instance containing the event data.</param>
 private static void OnPlayAnimation(Obj_AI_Base sender, Obj_AI_BasePlayAnimationEventArgs args)
 {
     if (sender.IsMe)
     {
         Console.WriteLine("----------------------------------------------");
         Console.WriteLine($"Animation Name: {args.Animation}");
         Console.WriteLine("----------------------------------------------");
     }
 }
Пример #3
0
        private static void Obj_AI_Base_OnPlayAnimation(Obj_AI_Base sender, Obj_AI_BasePlayAnimationEventArgs e)
        {
            var sphere = sender as Obj_AI_Minion;

            if (sphere != null && sphere.UnitSkinName == _sphereName && sphere.CheckTeam())
            {
                if (e.Animation == "Death")
                {
                    _spheres.RemoveAll(i => i.NetworkId == sphere.NetworkId);
                }
            }
        }
Пример #4
0
        private static void OnPlayAnimation(Obj_AI_Base sender, Obj_AI_BasePlayAnimationEventArgs Args)
        {
            if (!sender.IsMe || Orbwalker.Mode == OrbwalkingMode.None)
            {
                return;
            }

            if (Args.Animation == "Spell1" || Args.Animation == "Spell2")
            {
                Me.IssueOrder(OrderType.MoveTo, Game.CursorPos);
            }
        }
Пример #5
0
 /// <summary>
 ///     Called on animation trigger.
 /// </summary>
 /// <param name="sender">The sender.</param>
 /// <param name="args">The <see cref="Obj_AI_BasePlayAnimationEventArgs" /> instance containing the event data.</param>
 public void OnPlayAnimation(Obj_AI_Base sender, Obj_AI_BasePlayAnimationEventArgs args)
 {
     if (sender != null &&
         sender.IsMe &&
         ImplementationClass.IOrbwalker.Mode != OrbwalkingMode.None)
     {
         if (args.Animation.Equals("Spell1") || args.Animation.Equals("Spell2"))
         {
             UtilityClass.Player.IssueOrder(OrderType.MoveTo, Game.CursorPos);
         }
     }
 }
Пример #6
0
 private static void OnPlayAnimation(Obj_AI_Base sender, Obj_AI_BasePlayAnimationEventArgs Args)
 {
     try
     {
         if (sender.IsMe)
         {
             if (Args.Animation == "Spell3")
             {
                 YasuolastETime = Game.TickCount;
                 isYasuoDashing = true;
             }
         }
     }
     catch (Exception ex)
     {
         Console.WriteLine("Error in MyEventManager.OnPlayAnimation." + ex);
     }
 }
Пример #7
0
        public static void OnPlayAnimation(Obj_AI_Base sender, Obj_AI_BasePlayAnimationEventArgs args)
        {
            if (sender == null || !sender.IsMe)
            {
                return;
            }

            switch (args.Animation)
            {
            case "Spell3":
                SpellConfig.SecondE = false;
                break;

            case "Spell3b":
                SpellConfig.SecondE = true;
                DelayAction.Queue(300, () => SpellConfig.SecondE = false, new CancellationToken(false));
                break;
            }
        }
Пример #8
0
        private static void OnPlayAnimation(Obj_AI_Base sender, Obj_AI_BasePlayAnimationEventArgs Args)
        {
            var riven = sender as Obj_AI_Hero;

            if (riven == null || riven.Team == ObjectManager.GetLocalPlayer().Team || riven.ChampionName != "Riven" || !riven.IsValid)
            {
                return;
            }


            if (Menu["Block" + riven.ChampionName.ToLower()]["BlockSpell" + SpellSlot.Q.ToString()] != null &&
                Menu["Block" + riven.ChampionName.ToLower()]["BlockSpell" + SpellSlot.Q.ToString()].Enabled)
            {
                if (Args.Animation.ToLower() == "spell1c")
                {
                    RivenQTime  = Utils.GameTimeTickCount;
                    RivenQRange = riven.HasBuff("RivenFengShuiEngine") ? 225f : 150f;
                }
            }
        }
Пример #9
0
        public static void OnPlayAnimation(Obj_AI_Base sender, Obj_AI_BasePlayAnimationEventArgs args)
        {
            if (sender == null || !sender.IsMe)
            {
                return;
            }

            switch (args.Animation)
            {
            case "Spell1a":
                Extensions.CurrentQCount = 2;     // Q1
                break;

            case "Spell1b":
                Extensions.CurrentQCount = 3;     // Q2
                break;

            case "Spell1c":
                Extensions.CurrentQCount = 1;     // Q3
                break;
            }
        }
Пример #10
0
        private static void OnPlayAnimation(Obj_AI_Base sender, Obj_AI_BasePlayAnimationEventArgs Args)
        {
            try
            {
                if (sender.IsMe)
                {
                    //var time = 0;
                    bool cancel = false;

                    switch (Args.Animation)
                    {
                    case "Spell1a":
                        cancel    = true; //MiscMenu["FlowersRiven.MiscMenu.Q1Delay"].Value;
                        qStack    = 1;
                        lastQTime = Game.TickCount;
                        break;

                    case "Spell1b":
                        cancel    = true; //MiscMenu["FlowersRiven.MiscMenu.Q2Delay"].Value;
                        qStack    = 2;
                        lastQTime = Game.TickCount;
                        break;

                    case "Spell1c":
                        cancel    = true; //MiscMenu["FlowersRiven.MiscMenu.Q3Delay"].Value;
                        qStack    = 0;
                        lastQTime = Game.TickCount;
                        break;

                    default:
                        cancel = false;
                        break;
                    }

                    if (FleeMenu["FlowersRiven.FleeMenu.FleeKey"].As <MenuKeyBind>().Enabled ||
                        FleeMenu["FlowersRiven.FleeMenu.WallJumpKey"].As <MenuKeyBind>().Enabled)
                    {
                        return;
                    }

                    if (cancel == true)
                    {
                        //var delay1 = 400 + delay3;
                        //var delay2 = Game.Ping + delay3;
                        var delay3 = 1000 / (ObjectManager.GetLocalPlayer().AttackSpeedMod * 3.75);
                        //var delay4 = ObjectManager.GetLocalPlayer().AttackSpeedMod * 12;
                        //var delay5 = Game.Ping - Me.GetSpell(SpellSlot.Q).Level * 2;
                        //var delay6 = ObjectManager.GetLocalPlayer().AttackSpeedMod;
                        //var delay7 = 1 / ObjectManager.GetLocalPlayer().AttackSpeedMod;
                        //var delay8 = ObjectManager.GetLocalPlayer().AttackDelay;
                        //var delay9 = 1 / ObjectManager.GetLocalPlayer().AttackDelay;
                        //var delay10 = ObjectManager.GetLocalPlayer().AttackCastDelay;
                        //var delay11 = 1 / ObjectManager.GetLocalPlayer().AttackCastDelay;

                        //Console.WriteLine("Delay1: " + delay1);
                        //Console.WriteLine("Delay2: " + delay2);
                        //Console.WriteLine("Delay3: " + delay3);
                        //Console.WriteLine("Delay4: " + delay4);
                        //Console.WriteLine("Delay5: " + delay5);
                        //Console.WriteLine("Delay6: " + delay6);
                        //Console.WriteLine("Delay7: " + delay7);
                        //Console.WriteLine("Delay8: " + delay8);
                        //Console.WriteLine("Delay9: " + delay9);
                        //Console.WriteLine("Delay10: " + delay10);
                        //Console.WriteLine("Delay11: " + delay11);

                        var time = qStack != 0
                            ? (int)(delay3 + (Game.Ping > 50 ? Game.Ping : 50) + Me.GetSpell(SpellSlot.Q).Level * 2)
                            : (int)
                                   (delay3 + (Game.Ping > 50 ? Game.Ping : 50) +
                                    ((Game.Ping > 50 ? Game.Ping : 50) + Me.GetSpell(SpellSlot.Q).Level * 2));

                        // Console.WriteLine(time);
                        if (MiscMenu["FlowersRiven.MiscMenu.SemiCancel"].Enabled || Orbwalker.Mode != OrbwalkingMode.None)
                        {
                            if (MiscMenu["FlowersRiven.MiscMenu.CalculatePing"].Enabled)
                            {
                                if (time - Game.Ping > 0)
                                {
                                    DelayAction.Queue(time - Game.Ping, Cancel);
                                }
                                else
                                {
                                    DelayAction.Queue(1, Cancel);
                                }
                            }
                            else
                            {
                                DelayAction.Queue(time, Cancel);
                            }
                        }
                    }
                }
            }
            catch (Exception ex)
            {
                Console.WriteLine("Error in MyEventManager.OnPlayAnimation." + ex);
            }
        }
Пример #11
0
 /// <summary>
 /// Called when [play animation].
 /// </summary>
 /// <param name="sender">The sender.</param>
 /// <param name="e">The <see cref="Obj_AI_BasePlayAnimationEventArgs"/> instance containing the event data.</param>
 protected virtual void OnPlayAnimation(Obj_AI_Base sender, Obj_AI_BasePlayAnimationEventArgs e)
 {
     return;
 }