本文整理汇总了C#中AIHeroClient.IsDashable方法的典型用法代码示例。如果您正苦于以下问题:C# AIHeroClient.IsDashable方法的具体用法?C# AIHeroClient.IsDashable怎么用?C# AIHeroClient.IsDashable使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类AIHeroClient
的用法示例。
在下文中一共展示了AIHeroClient.IsDashable方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: UseQ
internal bool UseQ(AIHeroClient target, HitChance minhc = HitChance.Medium, bool UseQ1 = true, bool UseQ2 = true)
{
if (target == null)
{
return false;
}
var tready = TornadoReady;
if ((tready && !UseQ2) || !tready && !UseQ1)
{
return false;
}
//Avoid casting Q if E in range and Tornado ready :o
if (tready && Spells[E].IsReady() && target.IsDashable() && ((GetBool("Combo.UseE", YasuoMenu.ComboM) && GetBool("Combo.ETower", YasuoMenu.ComboM) && GetKeyBind("Misc.TowerDive", YasuoMenu.MiscM)) || !GetDashPos(target).PointUnderEnemyTurret()))
{
Initalization.Yasuo.CastE(target);
return false;
}
if (tready && Yasuo.LSIsDashing())
{
if (GetBool("Combo.NoQ2Dash", YasuoMenu.ComboM) || !(ETarget is AIHeroClient))
{
return false;
}
}
Spell sp = tready ? Spells[Q2] : Spells[Q];
PredictionOutput pred = sp.GetPrediction(target);
if (pred.Hitchance >= minhc)
{
return sp.Cast(pred.CastPosition);
}
return false;
}
示例2: UseQ
internal bool UseQ(AIHeroClient target, HitChance minhc = HitChance.Medium, bool UseQ1 = true, bool UseQ2 = true)
{
if (target == null)
{
return false;
}
if (Yasuo.LSIsDashing() || InDash)
{
return false;
}
var tready = TornadoReady;
if ((tready && !UseQ2) || !tready && !UseQ1)
{
return false;
}
if (GetMode() == Modes.Beta && !ShouldNormalQ(target))
{
if (tready && GetBool("Combo.UseEQ", YasuoMenu.ComboM))
{
if (Spells[E].IsReady() && target.IsDashable(500))
{
var dashPos = GetDashPos(target);
if (dashPos.To3D().CountEnemiesInRange(QRadius) >= 1)
{
//Cast E to trigger EQ
if (GetBool("Misc.saveQ4QE", YasuoMenu.MiscM) && isHealthy && GetBool("Combo.UseE", YasuoMenu.ComboM) &&
(GetBool("Combo.ETower", YasuoMenu.ComboM) || GetKeyBind("Misc.TowerDive", YasuoMenu.MiscM) ||
!GetDashPos(target).PointUnderEnemyTurret()))
{
return Spells[E].CastOnUnit(target);
}
}
}
}
}
else
{
LeagueSharp.Common.Spell sp = tready ? Spells[Q2] : Spells[Q];
PredictionOutput pred = sp.GetPrediction(target);
if (pred.Hitchance >= minhc)
{
return sp.Cast(pred.CastPosition);
}
}
return false;
}
示例3: CastENew
internal void CastENew(AIHeroClient target)
{
if (!SpellSlot.E.IsReady() || Yasuo.LSIsDashing() || InDash)
{
return;
}
var minionsinrange = ObjectManager.Get<Obj_AI_Minion>().Any(x => x.IsDashable());
if (target == null || !target.IsInRange(minionsinrange ? Spells[E].Range * 2 : Spells[E].Range))
{
target = TargetSelector.GetTarget(minionsinrange ? Spells[E].Range * 2 : Spells[E].Range,
DamageType.Physical);
}
if (target != null && TowerCheck(target, true))
{
var dist = Yasuo.LSDistance(target);
var pctOutOfRange = dist / Yasuo.AttackRange * 100;
if (pctOutOfRange > 0.8f)
{
if (target.IsDashable())
{
if (target.ECanKill())
{
return;
}
if (TornadoReady && target.IsInRange(Spells[E].Range) && targInKnockupRadius(target))
{
Spells[E].CastOnUnit(target);
}
//Stay in range
else if (pctOutOfRange > 0.8f)
{
var bestminion = ObjectManager.Get<Obj_AI_Base>()
.Where(x =>
x.IsDashable()
&& GetDashPos(x).IsCloser(target) && TowerCheck(x, true))
.MinOrDefault(x => GetDashPos(x).LSDistance(target));
var shouldETarget = bestminion == null || GetDashPos(target).Distance(target) <
GetDashPos(bestminion).LSDistance(target);
if (shouldETarget && GetDashPos(target).IsCloser(target))
{
Spells[E].CastOnUnit(target);
}
else if (bestminion != null)
{
Spells[E].CastOnUnit(bestminion);
}
}
}
else
{
var minion = ObjectManager.Get<Obj_AI_Minion>()
.Where(x => x.IsDashable() && x.IsCloser(target) && TowerCheck(x, true))
.MinOrDefault(x => GetDashPos(x).LSDistance(target));
if (minion != null)
{
Spells[E].CastOnUnit(minion);
}
}
}
}
}
示例4: ShouldNormalQ
internal bool ShouldNormalQ(AIHeroClient target)
{
var pos = GetDashPos(target);
return QLeftPCT <= 30 || !TowerCheck(pos, true) || !target.IsDashable(Spells[E].Range * 3) || !targInKnockupRadius(pos.To3D());
}
示例5: CastEOld
internal void CastEOld(AIHeroClient target, bool force = false)
{
var minionsinrange = ObjectManager.Get<Obj_AI_Minion>().Any(x => x.IsDashable());
if (target == null || !target.IsInRange(minionsinrange ? Spells[E].Range * 2 : Spells[E].Range))
{
target = TargetSelector.GetTarget(minionsinrange ? Spells[E].Range * 2 : Spells[E].Range, DamageType.Physical);
}
if (target != null)
{
if (SpellSlot.E.IsReady() && isHealthy && target.LSDistance(Yasuo) >= 0.30 * Yasuo.AttackRange)
{
if (TornadoReady && ((GetBool("Combo.ETower", YasuoMenu.ComboM) && GetKeyBind("Misc.TowerDive", YasuoMenu.MiscM)) || !GetDashPos(target).PointUnderEnemyTurret()))
{
Spells[E].CastOnUnit(target);
return;
}
if (DashCount >= 1 && GetDashPos(target).IsCloser(target) && target.IsDashable() &&
(GetBool("Combo.ETower", YasuoMenu.ComboM) || GetKeyBind("Misc.TowerDive", YasuoMenu.MiscM) || !GetDashPos(target).PointUnderEnemyTurret()))
{
Spells[E].CastOnUnit(target);
return;
}
if (DashCount == 0)
{
var bestminion =
ObjectManager.Get<Obj_AI_Base>()
.Where(
x =>
x.IsDashable()
&& GetDashPos(x).IsCloser(target) &&
(GetBool("Combo.ETower", YasuoMenu.ComboM) || GetKeyBind("Misc.TowerDive", YasuoMenu.MiscM) || !GetDashPos(x).PointUnderEnemyTurret()))
.OrderBy(x => Vector2.Distance(GetDashPos(x), target.ServerPosition.LSTo2D()))
.FirstOrDefault();
if (bestminion != null)
{
Spells[E].CastOnUnit(bestminion);
}
else if (target.IsDashable() && GetDashPos(target).IsCloser(target) && (GetBool("Combo.ETower", YasuoMenu.ComboM) || GetKeyBind("Misc.TowerDive", YasuoMenu.MiscM) || !GetDashPos(target).PointUnderEnemyTurret()))
{
Spells[E].CastOnUnit(target);
}
}
else
{
var minion =
ObjectManager.Get<Obj_AI_Base>()
.Where(x => x.IsDashable() && GetDashPos(x).IsCloser(target) && (GetBool("Combo.ETower", YasuoMenu.ComboM) || GetKeyBind("Misc.TowerDive", YasuoMenu.MiscM) || !GetDashPos(x).PointUnderEnemyTurret()))
.OrderBy(x => GetDashPos(x).LSDistance(target.ServerPosition)).FirstOrDefault();
if (minion != null && GetDashPos(minion).IsCloser(target))
{
Spells[E].CastOnUnit(minion);
}
}
}
}
}