本文整理汇总了C#中GameObjectProcessSpellCastEventArgs.IsAutoAttack方法的典型用法代码示例。如果您正苦于以下问题:C# GameObjectProcessSpellCastEventArgs.IsAutoAttack方法的具体用法?C# GameObjectProcessSpellCastEventArgs.IsAutoAttack怎么用?C# GameObjectProcessSpellCastEventArgs.IsAutoAttack使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类GameObjectProcessSpellCastEventArgs
的用法示例。
在下文中一共展示了GameObjectProcessSpellCastEventArgs.IsAutoAttack方法的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: Obj_AI_Base_OnSpellCast
static void Obj_AI_Base_OnSpellCast(Obj_AI_Base sender, GameObjectProcessSpellCastEventArgs args)
{
if (sender.IsMe && args.IsAutoAttack() && Orbwalker.ActiveModesFlags.HasFlag(Orbwalker.ActiveModes.Combo))
{
var target = args.Target as AIHeroClient;
if (target != null && )
}
}
示例2: OnSpellCast
private static void OnSpellCast(Obj_AI_Base sender, GameObjectProcessSpellCastEventArgs args)
{
if (sender.IsMe)
{
if (args.IsAutoAttack())
{
if (Orbwalker.ActiveModesFlags != Orbwalker.ActiveModes.None)
{
if (ShouldAA)
{
Orbwalker.ResetAutoAttack();
if (Player.Instance.IsInAutoAttackRange(args.Target as AttackableUnit))
{
Player.IssueOrder(GameObjectOrder.AttackTo, args.Target);
}
ShouldAA = false;
return;
}
if (ShouldQ)
{
SpellManager.Q.Cast();
Orbwalker.ResetAutoAttack();
if (Player.Instance.IsInAutoAttackRange(args.Target as AttackableUnit) )
{
Player.IssueOrder(GameObjectOrder.AttackTo, args.Target);
}
ShouldAA = true;
ShouldQ = false;
return;
}
}
}
if (args.Slot == SpellSlot.Q)
{
Orbwalker.ResetAutoAttack();
}
}
}
示例3: Obj_AI_Base_OnProcessSpellCast
private static void Obj_AI_Base_OnProcessSpellCast(Obj_AI_Base sender, GameObjectProcessSpellCastEventArgs args)
{
var target = args.Target as Obj_AI_Base;
var senderHero = sender as AIHeroClient;
if (args.IsAutoAttack()) return;
if (senderHero != null && senderHero.IsEnemy)
{
if (target != null && target.IsAlly)
{
var targettedSpell = new TargetSpell(target, senderHero, senderHero.Hero, args.Slot);
TargettedSpells.Add(targettedSpell);
Core.DelayAction(() => TargettedSpells.Remove(targettedSpell), 80);
}
}
}
示例4: Obj_AI_Base_OnSpellCast
static void Obj_AI_Base_OnSpellCast(Obj_AI_Base sender, GameObjectProcessSpellCastEventArgs args)
{
//Chat.Print(args.IsAutoAttack());
if (sender.IsMe && args.IsAutoAttack() && Hydra != null && Hydra.IsReady() && args.Target is AIHeroClient)
{
Hydra.Cast();
}
}
示例5: AfterAttack
private static void AfterAttack(Obj_AI_Base sender, GameObjectProcessSpellCastEventArgs args)
{
if (!sender.IsMe) return;
if (args.SData.Name == "ItemTitanicHydraCleave")
{
// because we want another auto after this
Orbwalker.ResetAutoAttack();
return;
}
if (!args.IsAutoAttack()) return;
Utils.Debug("ondos " + Core.GameTickCount);
var target = args.Target as AttackableUnit;
if (Orbwalker.ActiveModesFlags != Orbwalker.ActiveModes.None && target != null && target.IsValidTarget())
{
if (!Q.IsReady() && CanCastHydra())
Hydra.Cast();
if (Cooldown(Player.Spells[0]) > 1.0f && !W.IsReady() && CanCastTitan())
Titan.Cast();
lastAA = Core.GameTickCount;
if (Orbwalker.ActiveModesFlags.HasFlag(Orbwalker.ActiveModes.Combo) || Orbwalker.ActiveModesFlags.HasFlag(Orbwalker.ActiveModes.JungleClear))
{
if ((Orbwalker.ActiveModesFlags.HasFlag(Orbwalker.ActiveModes.Combo)))
{
if (QNum >= 1 && W.IsReady())
{
var target2 = (ComboTarget != null && ComboTarget.IsValidTarget(WRange)) ? ComboTarget :
TargetSelector.GetTarget(WRange, DamageType.Physical, null, true);
if (target2 != null && target2.IsValidTarget() && CanCastTitan())
{
Titan.Cast();
Player.IssueOrder(GameObjectOrder.AttackUnit, target2);
return;
}
if (target2 != null && target2.IsValidTarget() && !CanCastHydra())
{
Player.CastSpell(SpellSlot.W);
return;
}
if (CanCastHydra())
{
Hydra.Cast();
return;
}
if (R.IsReady() && R.Name != R1)
{
var enemy = EntityManager.Heroes.Enemies.FirstOrDefault(h => (h.Distance(Player.Instance) < R.Range - 50) && RDamage(h) > h.Health && h.IsValidTarget());
if (enemy != null)
{
forceR2 = true;
R2Target = enemy;
Core.DelayAction(() => forceR2 = false, 750);
}
}
}
}
if (Orbwalker.ActiveModesFlags.HasFlag(Orbwalker.ActiveModes.JungleClear))
{
if (QNum >= 1 && W.IsReady())
{
var target2 = (JCTarget != null && JCTarget.IsValidTarget(WRange)) ? JCTarget : EntityManager.MinionsAndMonsters.GetJungleMonsters(null, WRange, true).FirstOrDefault();
if (target2 != null && target2.IsValidTarget() && CanCastTitan())
{
Titan.Cast();
Player.IssueOrder(GameObjectOrder.AttackUnit, target2);
return;
}
if (target2 != null && target2.IsValidTarget() && !CanCastHydra())
{
Player.CastSpell(SpellSlot.W);
return;
}
if (CanCastHydra())
Hydra.Cast();
}
}
if (Mode != Orbwalker.ActiveModes.None && target.IsValidTarget(Q.Range) && target.IsValid && !target.IsDead && !target.IsZombie)
{
if (Q.IsReady())
{
Player.CastSpell(SpellSlot.Q, target.Position);
return;
}
}
if (Cooldown(Player.Spells[0]) > 1.0f && W.IsReady() && Player.Instance.CountEnemiesInRange(WRange) > 0)
{
Player.CastSpell(SpellSlot.W);
return;
}
}
}
}
示例6: Obj_AI_Base_OnSpellCast
static void Obj_AI_Base_OnSpellCast(Obj_AI_Base sender, GameObjectProcessSpellCastEventArgs args)
{
if (sender.IsMe && args.IsAutoAttack())
debugDictionary["OLD"] = Core.GameTickCount+"";
}
示例7: ChecarSendoatacado
internal static void ChecarSendoatacado(Obj_AI_Base sender, GameObjectProcessSpellCastEventArgs args)
{
if (!Multi["AtvSeg"].Cast<KeyBind>().CurrentValue) return;
if (sender.IsMe)
{
if (args.IsAutoAttack()) return;
UltCast = Environment.TickCount;
if (Environment.TickCount <= UltCast + 300 || Environment.TickCount <= UltClick + 500)
{
args.Process = false;
}
}
if (sender.Distance(Eu) >= 1300 || !sender.IsEnemy) return;
if (args.Target == null) return;
if (!sender.IsEnemy || !args.Target.IsMe) return;
if (Orbwalker.ActiveModesFlags != Orbwalker.ActiveModes.None)
{
Orbwalker.ActiveModesFlags = Orbwalker.ActiveModes.None;
}
Fugir = true;
MeAtacou = sender;
}