本文整理汇总了C#中Spell.Skillshot.IsInRange方法的典型用法代码示例。如果您正苦于以下问题:C# Spell.Skillshot.IsInRange方法的具体用法?C# Spell.Skillshot.IsInRange怎么用?C# Spell.Skillshot.IsInRange使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Spell.Skillshot
的用法示例。
在下文中一共展示了Spell.Skillshot.IsInRange方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: LaneClear
/// <summary>
/// Does LaneClear
/// </summary>
private static void LaneClear()
{
Q = new Spell.Skillshot(SpellSlot.Q, 1175, SkillShotType.Linear, 250, 70, 1300)
{
AllowedCollisionCount = 1
};
//E = new Spell.Skillshot(SpellSlot.E, 1200, SkillShotType.Circular, 250, 280, 950);
//R = new Spell.Skillshot(SpellSlot.R, 3300, SkillShotType.Circular, 1000, 190, int.MaxValue);
var useQ = LaneClearMenu["useQ"].Cast<CheckBox>().CurrentValue;
var useE = LaneClearMenu["useE"].Cast<CheckBox>().CurrentValue;
var useR = LaneClearMenu["useR"].Cast<CheckBox>().CurrentValue;
var useQs = LaneClearMenu["useQs"].Cast<Slider>().CurrentValue;
var useEs = LaneClearMenu["useEs"].Cast<Slider>().CurrentValue;
var useRs = LaneClearMenu["useRs"].Cast<Slider>().CurrentValue;
if (useQ && Q.IsReady() && ManaManager(SpellSlot.Q))
{
var target = EntityManager.MinionsAndMonsters.EnemyMinions.Where(t => t.IsValidTarget() && Q.IsInRange(t));
var pred = EntityManager.MinionsAndMonsters.GetLineFarmLocation(target, Q.Width, (int)Q.Range);
if (pred.HitNumber >= useQs)
{
Q.Cast(pred.CastPosition);
}
}
if (useE && E.IsReady() && ManaManager(SpellSlot.E) && LuxEObject == null)
{
var target = EntityManager.MinionsAndMonsters.GetLaneMinions(
EntityManager.UnitTeam.Enemy,
Player.Instance.ServerPosition,
E.Radius);
var pred = EntityManager.MinionsAndMonsters.GetCircularFarmLocation(target, E.Width, (int)E.Range);
if (pred.HitNumber >= useEs)
{
E.Cast(pred.CastPosition);
}
}
if (useE && E.IsReady() && LuxEObject != null)
{
var target =
EntityManager.MinionsAndMonsters.EnemyMinions.Where(
t => t.IsValidTarget() && t.Distance(LuxEObject.Position) <= LuxEObject.BoundingRadius);
if (target.Any() && LuxEObject != null)
{
E2.Cast();
}
}
if (!useR || !R.IsReady() || !ManaManager(SpellSlot.R))
{
return;
}
var rTarget = EntityManager.MinionsAndMonsters.GetLaneMinions(
EntityManager.UnitTeam.Enemy,
Player.Instance.ServerPosition,
R.Radius);
if (rTarget == null)
{
return;
}
var rPrediction = EntityManager.MinionsAndMonsters.GetLineFarmLocation(rTarget, R.Width, (int)R.Range);
if (rPrediction.HitNumber >= useRs)
{
R.Cast(rPrediction.CastPosition);
}
}