当前位置: 首页>>代码示例>>C#>>正文


C# AIHeroClient.IsFacing方法代码示例

本文整理汇总了C#中AIHeroClient.IsFacing方法的典型用法代码示例。如果您正苦于以下问题:C# AIHeroClient.IsFacing方法的具体用法?C# AIHeroClient.IsFacing怎么用?C# AIHeroClient.IsFacing使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在AIHeroClient的用法示例。


在下文中一共展示了AIHeroClient.IsFacing方法的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: OnGapcloser

        private static void OnGapcloser(AIHeroClient sender, Gapcloser.GapcloserEventArgs e)
        {
            if (!sender.IsEnemy || !Config.Settings.AntiGapcloser.AntiGap || Player.Instance.IsRecalling()) return;

            foreach (
                var ally in
                    EntityManager.Heroes.Allies.Where(ally => sender.IsFacing(ally) && Q.IsInRange(sender.Position)))
            {
                if (Config.Settings.Humanizer.QCastDelayEnabled)
                {
                    Core.DelayAction(() => { Q.Cast(Q.GetPrediction(sender).CastPosition); },
                        Config.Settings.Humanizer.QRndmDelay
                            ? new Random().Next(250, Config.Settings.Humanizer.QCastDelay)
                            : Config.Settings.Humanizer.QCastDelay);
                }
                else
                {
                    Q.Cast(Q.GetPrediction(sender).CastPosition);
                }
            }
        }
开发者ID:FireBuddy,项目名称:elobuddy,代码行数:21,代码来源:Events.cs

示例2: GapCloser

        private static void GapCloser(AIHeroClient sender, Gapcloser.GapcloserEventArgs e)
        {
            var antigap = MiscMenu["nasus.enable.antigap"].Cast<CheckBox>().CurrentValue;

                if (antigap && W.IsReady() && sender.IsValidTarget(W.Range) && sender.IsFacing(Player))
                    W.Cast(sender);
        }
开发者ID:impressivekayle,项目名称:Elobuddy-Addons,代码行数:7,代码来源:Program.cs

示例3: OnPossibleToInterrupt

 private static void OnPossibleToInterrupt(AIHeroClient unit, InterruptableSpell spell)
 {
     if (Player.IsDead || !getCheckBoxItem(miscMenu, "EQ") ||
         !getCheckBoxItem(miscMenu, unit.ChampionName + "_" + spell.Slot) || !Q.IsReady())
     {
         return;
     }
     if (E.CanCast(unit) && Player.Mana >= Q.Instance.SData.Mana + E.Instance.SData.Mana)
     {
         var predE = E.GetPrediction(unit);
         if (predE.Hitchance >= E.MinHitChance &&
             E.Cast(
                 predE.UnitPosition.LSExtend(Player.ServerPosition, -E.Width/(unit.IsFacing(Player) ? 2 : 1)),
                 getCheckBoxItem(miscMenu, "Packet")) &&
             Q.Cast(predE.UnitPosition, getCheckBoxItem(miscMenu, "Packet")))
         {
             return;
         }
     }
     foreach (var flag in
         Flag.Where(i => Q2.WillHit(unit, i.ServerPosition)))
     {
         Q.Cast(flag.ServerPosition, getCheckBoxItem(miscMenu, "Packet"));
     }
 }
开发者ID:,项目名称:,代码行数:25,代码来源:

示例4: Gapcloser_OnGapcloser

        /// <summary>
        /// Gapcloses whenever possible.
        /// </summary>
        /// <param name="sender">Enemy</param>
        /// <param name="e">The Arguments</param>
        static void Gapcloser_OnGapcloser(AIHeroClient sender, Gapcloser.GapcloserEventArgs e)
        {
            var gapR = InterruptMenu["gapR"].Cast<CheckBox>().CurrentValue;

            if (gapR && sender.IsValidTarget() && sender.IsFacing(PlayerInstance))
            {
                var pred = R.GetPrediction(sender);

                if (pred.HitChance == HitChance.High)
                {
                    R.Cast(sender.Position);
                }
            }
        }
开发者ID:Drenferalis,项目名称:EloBuddy,代码行数:19,代码来源:Program.cs

示例5: OnInterruptableTarget

        /// <summary>
        ///     Called when there is an interruptible target.
        /// </summary>
        /// <param name="sender">The sender.</param>
        /// <param name="args">The <see cref="Interrupter2.InterruptableTargetEventArgs" /> instance containing the event data.</param>
        private void OnInterruptableTarget(AIHeroClient sender, Interrupter2.InterruptableTargetEventArgs args)
        {
            if (!getCheckBoxItem(miscMenu, "Interrupter") || !sender.IsFacing(this.Player) || !sender.LSIsValidTarget(this.R.Range))
            {
                return;
            }

            this.R.Cast(sender);
        }
开发者ID:yMeliodasNTD,项目名称:PortAIO,代码行数:14,代码来源:EatMyCass.cs

示例6: ECast

        private static void ECast(AIHeroClient target)
        {
            if (!target.IsValidTarget(E.Range) || !E.IsReady()) return;
            var prediction = E.GetPrediction(target);
            var pos = prediction.CastPosition;

            if (pos.Distance(_Player.Position) < E.Range &&
                prediction.HitChance >= HitChance.Medium)
            {
                if (_Player.IsFacing(target) && target.IsFacing(_Player))
                {
                    E.Cast(pos.Extend(_Player.Position, 300).To3D());
                }
                else if (_Player.IsFacing(target) && !target.IsFacing(_Player))
                {
                    E.Cast(pos.Extend(_Player.Position, 150).To3D());
                }
                else if (!_Player.IsFacing(target) && target.IsFacing(_Player))
                {
                    E.Cast(pos.Extend(_Player.Position, 300).To3D());
                }
            }
        }
开发者ID:AnneFrankGotRekt,项目名称:EloBuddy,代码行数:23,代码来源:Brain.cs


注:本文中的AIHeroClient.IsFacing方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。