本文整理汇总了C#中Hero.Move方法的典型用法代码示例。如果您正苦于以下问题:C# Hero.Move方法的具体用法?C# Hero.Move怎么用?C# Hero.Move使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Hero
的用法示例。
在下文中一共展示了Hero.Move方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: Game_OnUpdate
public static void Game_OnUpdate(EventArgs args)
{
if (!Game.IsInGame) return;
_me = ObjectMgr.LocalHero;
if (_me == null || _me.ClassID != ClassID.CDOTA_Unit_Hero_Morphling)
{
return;
}
if (!_activated) return;
if ((_target == null || !_target.IsVisible) && !_me.IsChanneling())
_me.Move(Game.MousePosition);
if (_target == null || _me.Distance2D(_target) > 500)
_target = _me.ClosestToMouseTarget(1000);
//Skills & Items
waveform = _me.Spellbook.Spell1;
adapt = _me.Spellbook.Spell2;
eblade = _me.FindItem("item_ethereal_blade");
bkb = _me.FindItem("item_black_king_bar");
if (_target != null && _target.IsAlive && !_target.IsInvul())
{
if (!Utils.SleepCheck("Morph_Wait")) return;
var targetDistance = _me.Distance2D(_target);
var attackRange = 1000;
if (targetDistance <= attackRange && waveform != null && waveform.CanBeCasted() && Utils.SleepCheck("waveform"))
{
waveform.UseAbility(_target.Position);
Utils.Sleep(150 + Game.Ping, "waveform");
}
else if (bkb !=null && _bkbToggle && Utils.SleepCheck("BKB"))
{
bkb.UseAbility();
Utils.Sleep(150 + Game.Ping, "BKB");
}
else if (eblade != null && eblade.CanBeCasted() && Utils.SleepCheck("eblade"))
{
eblade.UseAbility(_target);
Utils.Sleep(150 + Game.Ping, "eblade");
}
else if (adapt != null && adapt.CanBeCasted() && Utils.SleepCheck("adapt"))
{
adapt.UseAbility(_target);
Utils.Sleep(150 + Game.Ping, "adapt");
}
}
}
示例2: CastIceWall
private static void CastIceWall(Hero me, Hero target, bool b, Ability icewall)
{
if (!b)
{
if (!me.CanMove() || !Utils.SleepCheck("icewallmove")) return;
var angle = me.FindAngleBetween(target.Position, true);
var point =
new Vector3(
(float)(target.Position.X -
200 *
Math.Cos(angle)),
(float)(target.Position.Y -
200 *
Math.Sin(angle)), 0);
me.Move(point);
Utils.Sleep(300, "icewallmove");
}
else
{
icewall.UseAbility();
_stage++;
Utils.Sleep(250, "StageCheck");
}
}
示例3: Tinker_In_Madness
//.........这里部分代码省略.........
glimmer.UseAbility(me);
Utils.Sleep(200 - Game.Ping, "glimmer");
}
else
elsecount += 1;
if (ghost != null && Ethereal == null && ghost.CanBeCasted() && Menu.Item("Items2: ").GetValue<AbilityToggler>().IsEnabled(ghost.Name) && Utils.SleepCheck("Rearm") && !Refresh.IsChanneling && Utils.SleepCheck("ghost"))
{
ghost.UseAbility();
Utils.Sleep(200 - Game.Ping, "ghost");
}
else
elsecount += 1;
if (Soulring != null && Soulring.CanBeCasted() && Menu.Item("Items: ").GetValue<AbilityToggler>().IsEnabled(Soulring.Name) && Utils.SleepCheck("Rearm") && !Refresh.IsChanneling && Utils.SleepCheck("soulring"))
{
Soulring.UseAbility();
Utils.Sleep(200 - Game.Ping, "soulring");
}
else
elsecount += 1;
if (Hex != null && Hex.CanBeCasted() && Menu.Item("Items: ").GetValue<AbilityToggler>().IsEnabled(Hex.Name) && magicimune && Utils.SleepCheck("Rearm") && !Refresh.IsChanneling && Utils.SleepCheck("Hex"))
{
Hex.UseAbility(target);
Utils.Sleep(200 - Game.Ping, "Hex");
}
else
elsecount += 1;
if (Laser != null && Laser.CanBeCasted() && Menu.Item("Skills: ").GetValue<AbilityToggler>().IsEnabled(Laser.Name) && magicimune && Utils.SleepCheck("Rearm") && !Refresh.IsChanneling && Utils.SleepCheck("laser"))
{
Utils.Sleep(400 - Game.Ping, "laser");
Laser.UseAbility(target);
}
else
elsecount += 1;
if (Ethereal != null && Ethereal.CanBeCasted() && Menu.Item("Items: ").GetValue<AbilityToggler>().IsEnabled(Ethereal.Name) && magicimune && Utils.SleepCheck("Rearm") && !Refresh.IsChanneling && Utils.SleepCheck("ethereal"))
{
Ethereal.UseAbility(target);
Utils.Sleep(400 - Game.Ping, "Ethereal");
if (Utils.SleepCheck("EtherealTime") && me.Distance2D(target) <= Ethereal.CastRange)
{
Utils.Sleep(((me.NetworkPosition.Distance2D(target.NetworkPosition) / 1200) * 1000) + 25, "EtherealTime");
Utils.Sleep(((me.NetworkPosition.Distance2D(target.NetworkPosition) / 1200) * 1000) + 200, "EtherealTime2");
}
}
else
elsecount += 1;
if (Dagon != null && Dagon.CanBeCasted() && !Ethereal.CanBeCasted() && Menu.Item("Items: ").GetValue<AbilityToggler>().IsEnabled("item_dagon") && magicimune && Utils.SleepCheck("Rearm") && Utils.SleepCheck("EtherealTime") && !Refresh.IsChanneling && Utils.SleepCheck("dagon"))
{
Dagon.UseAbility(target);
Utils.Sleep(350 - Game.Ping, "dagon");
}
else
elsecount += 1;
if (Rocket != null && Rocket.CanBeCasted() && Menu.Item("Skills: ").GetValue<AbilityToggler>().IsEnabled(Rocket.Name) && magicimune && Utils.SleepCheck("Rearm") && !Refresh.IsChanneling && Utils.SleepCheck("rocket"))
{
Rocket.UseAbility();
Utils.Sleep(500 - Game.Ping, "rocket");
if (Utils.SleepCheck("RocketTime") && me.Distance2D(target) <= Rocket.CastRange)
{
Utils.Sleep(((me.NetworkPosition.Distance2D(target.NetworkPosition) / 900) * 1000), "RocketTime");
Utils.Sleep(((me.NetworkPosition.Distance2D(target.NetworkPosition) / 900) * 1000) + 200, "RocketTime2");
}
}
else
elsecount += 1;
if (Shiva != null && Shiva.CanBeCasted() && Menu.Item("Items: ").GetValue<AbilityToggler>().IsEnabled(Shiva.Name) && magicimune && Utils.SleepCheck("Rearm") && !Refresh.IsChanneling && Utils.SleepCheck("shiva"))
{
Shiva.UseAbility();
Utils.Sleep(200 - Game.Ping, "shiva");
}
else
elsecount += 1;
if (elsecount == 9 && euls != null && euls.CanBeCasted() && Menu.Item("Items2: ").GetValue<AbilityToggler>().IsEnabled(euls.Name) && magicimune && Utils.SleepCheck("Rearm") && Utils.SleepCheck("EtherealTime2") && Utils.SleepCheck("RocketTime2") && Utils.SleepCheck("euls"))
{
euls.UseAbility(target);
Utils.Sleep(200 - Game.Ping, "euls");
}
else
elsecount += 1;
if (elsecount == 10 && Refresh != null && Refresh.CanBeCasted() && Menu.Item("Skills: ").GetValue<AbilityToggler>().IsEnabled(Refresh.Name) && !Refresh.IsChanneling && Utils.SleepCheck("Rearm") && Ready_for_refresh())
{
Refresh.UseAbility();
Utils.Sleep(1000, "Rearm");
}
else
{
if (!me.IsChanneling() && me.CanAttack() && Utils.SleepCheck("Rearm") && me.Distance2D(target) <= me.AttackRange)
Orbwalking.Orbwalk(target);
}
}
}
else
{
autoattack(false);
if (!me.IsChanneling() && Utils.SleepCheck("Rearm"))
me.Move(Game.MousePosition);
}
}
else
autoattack(false);
}
示例4: Game_OnGameWndProc
static void Game_OnGameWndProc(WndEventArgs args)
{
if (args.Msg != WM_KEYUP || args.WParam != 'O' || Game.IsChatOpen)
return;
// Deactivate script
// if (_pullCreep != null)
//{
// Console.WriteLine("Deactivated");
//_pullCreep = null;
// return;
//}
// Activate script
var player = ObjectMgr.LocalPlayer;
me = ObjectMgr.LocalHero;
if (player == null || player.Team == Team.Observer)
return;
switch (player.Team)
{
case Team.Radiant:
_startTime = StartTimeRadiant;
_attackTime = AttackTimeRadiant;
_route = StackRouteRadiant;
break;
case Team.Dire:
_startTime = StartTimeDire;
_attackTime = AttackTimeDire;
_route = StackRouteDire;
break;
default:
return;
}
// var units = player.Selection.ToList();
// _pullCreep = (Unit)units.FirstOrDefault(unit => unit is Unit && ((Unit)unit).IsControllable && ((Unit)unit).IsRanged);
if (me != null)
{
me.Move(_route.Last());
//_pullCreep.Move(_route.Last());
// _orderState = -1;
}
}
示例5: Universe
//.........这里部分代码省略.........
//black king bar
if ((bkb != null && Menu.Item("Items: ").GetValue<AbilityToggler>().IsEnabled(bkb.Name)) && bkb.CanBeCasted() && Utils.SleepCheck("bkb"))
{
bkb.UseAbility();
Utils.Sleep(150 + Game.Ping, "bkb");
}
//blink
if ((blink != null && Menu.Item("Items: ").GetValue<AbilityToggler>().IsEnabled(blink.Name)) && blink.CanBeCasted() && target.Position.Distance2D(me.Position) > 300 && Utils.SleepCheck("blink"))
{
blink.UseAbility(me.Distance2D(mousepos) < 1200 ? mousepos : new Vector3(me.NetworkPosition.X + 1150 * (float)Math.Cos(me.NetworkPosition.ToVector2().FindAngleBetween(mousepos.ToVector2(), true)), me.NetworkPosition.Y + 1150 * (float)Math.Sin(me.NetworkPosition.ToVector2().FindAngleBetween(mousepos.ToVector2(), true)), 100), false);
Utils.Sleep(150 + Game.Ping, "blink");
}
//orchid
if ((orchid != null && Menu.Item("Items: ").GetValue<AbilityToggler>().IsEnabled(orchid.Name)) && orchid.CanBeCasted() && (target.Position.Distance2D(me.Position) < 300) && Utils.SleepCheck("orchid"))
{
orchid.UseAbility(target);
Utils.Sleep(150 + Game.Ping, "orchid");
}
//dust
if ((dust != null && Menu.Item("Items: ").GetValue<AbilityToggler>().IsEnabled(dust.Name)) && dust.CanBeCasted() && Utils.SleepCheck("dust"))
{
dust.UseAbility();
Utils.Sleep(150 + Game.Ping, "dust");
}
//necronomicon
if ((necronomicon != null && Menu.Item("Items: ").GetValue<AbilityToggler>().IsEnabled(necronomicon.Name)) && necronomicon.CanBeCasted() && (target.Health > (target.MaximumHealth*0.20)) && (target.Position.Distance2D(me.Position) < 400) && Utils.SleepCheck("necronomicon"))
{
necronomicon.UseAbility();
Utils.Sleep(150 + Game.Ping, "necronomicon");
}
if ((necronomicon2 != null && Menu.Item("Items: ").GetValue<AbilityToggler>().IsEnabled(necronomicon2.Name)) && necronomicon2.CanBeCasted() && (target.Health > (target.MaximumHealth*0.20)) && (target.Position.Distance2D(me.Position) < 400) && Utils.SleepCheck("necronomicon2"))
{
necronomicon2.UseAbility();
Utils.Sleep(150 + Game.Ping, "necronomicon2");
}
if ((necronomicon3 != null && Menu.Item("Items: ").GetValue<AbilityToggler>().IsEnabled(necronomicon3.Name)) && necronomicon3.CanBeCasted() && (target.Health > (target.MaximumHealth*0.20)) && (target.Position.Distance2D(me.Position) < 400) && Utils.SleepCheck("necronomicon3"))
{
necronomicon3.UseAbility();
Utils.Sleep(150 + Game.Ping, "necronomicon3");
}
//thunder clap
if ((thunderclap != null && Menu.Item("Skills: ").GetValue<AbilityToggler>().IsEnabled(thunderclap.Name)) && thunderclap.CanBeCasted() && (target.Position.Distance2D(me.Position) < 300) && Utils.SleepCheck("thunderclap"))
{
thunderclap.UseAbility();
Utils.Sleep(150 + Game.Ping, "thunderclap");
}
//urn of shadow
if ((urn != null && Menu.Item("Items: ").GetValue<AbilityToggler>().IsEnabled(urn.Name)) && urn.CanBeCasted() && Utils.SleepCheck("urn"))
{
urn.UseAbility(target);
Utils.Sleep(150 + Game.Ping, "urn");
}
//medal
if ((medal != null && Menu.Item("Items: ").GetValue<AbilityToggler>().IsEnabled(medal.Name)) && medal.CanBeCasted() && (target.Position.Distance2D(me.Position) < 300) && Utils.SleepCheck("medal"))
{
medal.UseAbility(target);
Utils.Sleep(150 + Game.Ping, "medal");
}
//shiva
if ((shiva != null && Menu.Item("Items: ").GetValue<AbilityToggler>().IsEnabled(shiva.Name)) && shiva.CanBeCasted() && (target.Position.Distance2D(me.Position) <= 800) && Utils.SleepCheck("shiva"))
{
shiva.UseAbility();
Utils.Sleep(150 + Game.Ping, "shiva");
}
//manta
if ((manta != null && Menu.Item("Items: ").GetValue<AbilityToggler>().IsEnabled(manta.Name)) && manta.CanBeCasted() && (target.Position.Distance2D(me.Position) <= 450) && Utils.SleepCheck("manta"))
{
manta.UseAbility();
Utils.Sleep(150 + Game.Ping, "manta");
}
//ULTIMATE: PrimalSplit
if ((primalsplit != null && Menu.Item("Skills: ").GetValue<AbilityToggler>().IsEnabled(primalsplit.Name)) && primalsplit.CanBeCasted() && (target.Position.Distance2D(me.Position) < 500) && (target.Health > (target.MaximumHealth*0.35)) && !thunderclap.CanBeCasted() && !orchid.CanBeCasted() && !dust.CanBeCasted() && !necronomicon.CanBeCasted() && !necronomicon2.CanBeCasted() && !necronomicon3.CanBeCasted() && !urn.CanBeCasted() && !medal.CanBeCasted() && !shiva.CanBeCasted() && !manta.CanBeCasted() && activated && Utils.SleepCheck("primalsplit"))
{
primalsplit.UseAbility();
Utils.Sleep(1000 + Game.Ping, "primalsplit");
var primalstorm = ObjectMgr.GetEntities<Unit>().FirstOrDefault(unit => unit.ClassID == ClassID.CDOTA_Unit_Brewmaster_PrimalStorm && unit.IsAlive);
}
//Moving+Attaking
if (me.CanMove() && (target.Position.Distance2D(me.Position) > 200))
{
me.Move(mousepos, false);
}
if (me.CanMove() && (target.Position.Distance2D(me.Position) < 200))
{
me.Attack(target);
}
}
else
{
if (me.CanMove())
{
me.Move(mousepos, false);
}
}
}
}
}
示例6: Game_OnUpdate
//.........这里部分代码省略.........
if (canCancel)
{
if (target != null && !target.IsVisible && !Orbwalking.AttackOnCooldown(target))
{
target = me.ClosestToMouseTarget(0x3e8);
}
}
if (target != null && target.IsAlive && !target.IsInvul() && !target.IsIllusion)
{
int attackrange = 0x276;
if (me.CanAttack() && me.CanCast())
{
if (arrows != null && arrows.IsValid && arrows.CanBeCasted() &&me.CanCast() && Utils.SleepCheck("arrows"))
{
arrows.UseAbility(target);
Utils.Sleep(50, "arrows");
}
if (strafe != null && strafe.IsValid && strafe.CanBeCasted() && me.CanCast() && me.Distance2D(target) <= 720 &&
Utils.SleepCheck("strafe"))
{
strafe.UseAbility();
Utils.Sleep(50 + Game.Ping, "strafe");
}
if (creepR.Count > 0 && !me.Modifiers.ToList().Exists(x => x.Name == "modifier_clinkz_death_pact"))
{
var creepmax = creepR.MaxOrDefault(x => x.Health);
me.Spellbook.SpellR.UseAbility(creepmax);
}
if (medallion != null && medallion.IsValid && medallion.CanBeCasted() && Utils.SleepCheck("medallion") && menuValue.IsEnabled(medallion.Name))
{
medallion.UseAbility(target);
Utils.Sleep(50 + Game.Ping, "medallion");
}
if (solar != null && solar.IsValid && solar.CanBeCasted() && Utils.SleepCheck("solar") && menuValue.IsEnabled(solar.Name))
{
solar.UseAbility(target);
Utils.Sleep(50 + Game.Ping, "solar");
}
if (bkb != null && bkb.IsValid && bkb.CanBeCasted() && Utils.SleepCheck("bkb") && menuValue.IsEnabled(bkb.Name) && me.Distance2D(target) <= 720)
{
bkb.UseAbility();
Utils.Sleep(150 + Game.Ping, "bkb");
}
if (hex != null && hex.IsValid && hex.CanBeCasted() && Utils.SleepCheck("hex") && menuValue.IsEnabled(hex.Name))
{
hex.CastStun(target);
Utils.Sleep(250 + Game.Ping, "hex");
return;
}
if (orchid != null && orchid.IsValid && orchid.CanBeCasted() && Utils.SleepCheck("orchid") && menuValue.IsEnabled(orchid.Name))
{
orchid.CastStun(target);
Utils.Sleep(250 + Game.Ping, "orchid");
return;
}
if (arrows == null || arrows.CanBeCasted() || !Utils.SleepCheck("arrows")
|| !Menu.Item("orbwalk").GetValue<bool>() || !(me.Distance2D(target) <= attackrange))
{
}
else
{
Orbwalking.Orbwalk(target);
Utils.Sleep(Game.Ping + 150, "arrows");
}
if (me.IsAttacking() || !(me.Distance2D(target) >= attackrange)
|| !Utils.SleepCheck("follow"))
{
return;
}
me.Move(Game.MousePosition);
Utils.Sleep(150 + Game.Ping, "follow");
}
else if (Utils.SleepCheck("strafe") && !arrows.CanBeCasted() && Utils.SleepCheck("arrows"))
{
me.Attack(target);
Utils.Sleep(150, "strafe");
}
}
else
{
me.Move(Game.MousePosition);
}
}
}
示例7: ComboInAction
private static void ComboInAction(Hero me, Hero target)
{
if (!Utils.SleepCheck("nextAction")) return;
var duel = me.Spellbook.Spell4;
if (duel==null) return;
if (!duel.CanBeCasted(target)) return;
//var steal = me.Spellbook.Spell1;
var heal = me.Spellbook.Spell2;
var dagger = me.FindItem("item_blink");
var neededMana = me.Mana-duel.ManaCost;
var allitems = me.Inventory.Items.Where(x => x.CanBeCasted() && x.ManaCost <= neededMana);
var dpActivated =
target.Modifiers.Any(
x => x.Name == "modifier_slark_dark_pact" || x.Name == "modifier_slark_dark_pact_pulses");
var enumerable = allitems as Item[] ?? allitems.ToArray();
var itemOnTarget =
enumerable.FirstOrDefault(
x =>
x.Name == "item_abyssal_blade" || x.Name == "item_orchid" ||
x.Name == "item_heavens_halberd" || x.Name == "item_sheepstick" ||
x.Name == "item_urn_of_shadows" || x.Name == "item_medallion_of_courage" ||
x.Name == "item_solar_crest");
var itemWithOutTarget = enumerable.FirstOrDefault(
x =>
x.Name == "item_soul_ring" || (x.Name == "item_armlet" && !x.IsToggled) ||
x.Name == "item_mask_of_madness" || x.Name == "item_satanic" ||
x.Name == "item_blade_mail");
var itemOnMySelf = enumerable.FirstOrDefault(
x =>
x.Name == "item_mjollnir");
Item bkb = null;
if (_shoulUseBkb)
{
bkb = me.FindItem("item_black_king_bar");
}
var distance = me.Distance2D(target);
if (distance >= 1150)
{
me.Move(target.Position);
Utils.Sleep(200, "nextAction");
return;
}
if (itemOnMySelf != null && _buffme)
{
itemOnMySelf.UseAbility(me);
Utils.Sleep(50, "nextAction");
return;
}
if (itemWithOutTarget != null && _buffme)
{
if (itemWithOutTarget.Name == "item_armlet")
{
itemWithOutTarget.ToggleAbility();
Utils.Sleep(50, "nextAction");
return;
}
itemWithOutTarget.UseAbility();
Utils.Sleep(50, "nextAction");
return;
}
if (dagger != null && dagger.CanBeCasted())
{
if (!me.IsMagicImmune() && heal.CanBeCasted() && heal.ManaCost <= neededMana && _shoulUseHeal)
{
heal.UseAbility(me);
Utils.Sleep(500, "nextAction");
return;
}
var point = new Vector3(
(float)(target.Position.X - 60 * Math.Cos(me.FindAngleBetween(target.Position, true))),
(float)(target.Position.Y - 60 * Math.Sin(me.FindAngleBetween(target.Position, true))),
target.Position.Z);
dagger.UseAbility(point);
Utils.Sleep(50, "nextAction");
return;
}
if (distance>duel.CastRange)
{
me.Move(target.Position);
Utils.Sleep(200, "nextAction");
return;
}
if (itemOnTarget != null && !dpActivated && _debuffenemy)
{
itemOnTarget.UseAbility(target);
Utils.Sleep(50, "nextAction");
return;
}
if (_shoulUseBkb && bkb != null && bkb.CanBeCasted())
{
bkb.UseAbility();
}
duel.UseAbility(target);
Utils.Sleep(300, "nextAction");
}
示例8: JungleFarm
private static void JungleFarm(Hero me)
{
var s = JungleCamps.FindClosestCamp(me, Menu.Item("JungleFarm.TeamCheck").GetValue<bool>(),
Menu.Item("JungleFarm.Ancient").GetValue<bool>());
string name;
var enemyHeroes = Heroes.GetByTeam(me.GetEnemyTeam()).Where(x => x.IsAlive).ToList();
var dist = Menu.Item("JungleFarm.EscapeRange").GetValue<Slider>().Value;
if (Menu.Item("JungleFarm.EscapeFromAnyEnemyHero").GetValue<bool>() &&
enemyHeroes.Any(x => x.Distance2D(me) <= dist)) //escape from hero
{
var handle = me.Handle;
OrderStates[handle] = OrderState.Escape;
NeedHeal[handle] = true;
}
if (s == null)
{
s = JungleCamps.GetCamps.OrderBy(x => x.CampPosition.Distance2D(me)).FirstOrDefault();
if (s != null)
{
name = MeepoSet.Find(x => Equals(x.Hero, me)).Handle.ToString();
if (Utils.SleepCheck("MOVIER_jungle" + name))
{
me.Move(s.StackPosition);
Utils.Sleep(500, "MOVIER_jungle" + name);
}
}
return;
}
name = MeepoSet.Find(x => Equals(x.Hero, me)).Handle.ToString();
var anyMeepo =
MeepoSet.Where(
x =>
x.CurrentOrderState == OrderState.Jungle && x.IsAlive && x.Handle != me.Handle &&
x.Hero.Health >= Menu.Item("Escape.MinRange").GetValue<Slider>().Value)
.OrderBy(y => y.Hero.Distance2D(me))
.FirstOrDefault();
if (anyMeepo != null && me.Health <= 500 && anyMeepo.Hero.Distance2D(MyHero) <= 400 &&
CheckForChangedHealth(me))
{
if (!Utils.SleepCheck(name + "attack_test")) return;
Utils.Sleep(200, name + "attack_test");
var enemy =
ObjectManager.GetEntities<Unit>()
.FirstOrDefault(
x =>
x.IsAlive && x.IsVisible && x.Team != MyHero.Team && x.Distance2D(MyHero) <= 500 &&
!x.IsWaitingToSpawn);
if (enemy != null)
{
var creep = enemy.Position;
var ang = me.FindAngleBetween(creep, true);
var p = new Vector3((float) (me.Position.X - 250*Math.Cos(ang)),
(float) (me.Position.Y - 250*Math.Sin(ang)), 0);
me.Move(p);
}
me.Attack(anyMeepo.Hero, true);
return;
}
var mySet = MeepoSet.Find(x => Equals(x.Hero, me));
var w = mySet.SpellW;
if (w != null && Menu.Item("JungleFarm.AutoW").GetValue<bool>() && w.CanBeCasted())
{
var enemy =
ObjectManager
.GetEntities<Unit>(
)
.FirstOrDefault(
x =>
x.IsAlive && x.Health > 80 && x.IsVisible && x.Team != MyHero.Team &&
x.Distance2D(me) <= 375 &&
!x.IsWaitingToSpawn);
if (enemy != null && Utils.SleepCheck("jungle_farm_w" + name))
{
w.UseAbility(enemy.Position);
Utils.Sleep(1500, "jungle_farm_w_inCasting" + name);
Utils.Sleep(250, "jungle_farm_w" + name);
}
else if (enemy == null && !Utils.SleepCheck("jungle_farm_w_inCasting" + name) &&
Utils.SleepCheck("jungle_farm_w_stop" + name))
{
me.Stop();
Utils.Sleeps.Remove("jungle_farm_w_inCasting" + name);
Utils.Sleep(500, "jungle_farm_w_stop" + name);
}
}
if (!Utils.SleepCheck(name + "attack") || me.IsAttacking()) return;
Utils.Sleep(500, name + "attack");
me.Attack(s.CampPosition);
}
示例9: ComboInAction
private static void ComboInAction(Hero me, Hero target)
{
if (!Utils.SleepCheck("nextAction")) return;
var duel = me.Spellbook.Spell4;
if (duel==null) return;
if (!duel.CanBeCasted()) return;
var haras = me.Spellbook.Spell1;
var heal = me.Spellbook.Spell2;
var dagger = me.FindItem("item_blink");
var neededMana = me.Mana-duel.ManaCost;
var allitems = me.Inventory.Items.Where(x => x.CanBeCasted() && x.ManaCost <= neededMana);
var dpActivated =
target.Modifiers.Any(
x => x.Name == "modifier_slark_dark_pact" || x.Name == "modifier_slark_dark_pact_pulses");
var enumerable = allitems as Item[] ?? allitems.ToArray();
var isInvise = me.IsInvisible();
var itemOnTarget =
enumerable.FirstOrDefault(
x =>
x.Name == "item_abyssal_blade" || x.Name == "item_orchid" ||
x.Name == "item_heavens_halberd" || x.Name == "item_sheepstick" ||
x.Name == "item_urn_of_shadows" || x.Name == "item_medallion_of_courage" ||
x.Name == "item_solar_crest");
var itemWithOutTarget = enumerable.FirstOrDefault(
x =>
x.Name == "item_soul_ring" || (x.Name == "item_armlet" && !x.IsToggled) ||
x.Name == "item_mask_of_madness" || x.Name == "item_satanic" ||
x.Name == "item_blade_mail" || x.Name == "item_silver_edge" || x.Name == "item_invis_sword");
var itemOnMySelf = enumerable.FirstOrDefault(
x =>
x.Name == "item_mjollnir");
Item bkb = null;
if (Menu.Item("enabledAbilities").GetValue<AbilityToggler>().IsEnabled("item_black_king_bar"))
{
bkb = me.FindItem("item_black_king_bar");
}
var distance = me.Distance2D(target);
if (distance >= 1150)
{
me.Move(target.Position);
Utils.Sleep(200 + Game.Ping, "nextAction");
return;
}
if (Menu.Item("enabledAbilities").GetValue<AbilityToggler>().IsEnabled("legion_commander_overwhelming_odds") && haras != null && haras.CanBeCasted() && distance <= haras.CastRange)
{
haras.UseAbility(target.Position);
Utils.Sleep(300 + Game.Ping, "nextAction");
return;
}
if (!me.IsMagicImmune() && heal.CanBeCasted() && heal.ManaCost <= neededMana && Menu.Item("enabledAbilities").GetValue<AbilityToggler>().IsEnabled("legion_commander_press_the_attack"))
{
heal.UseAbility(me);
Utils.Sleep(200 + Game.Ping, "nextAction");
return;
}
if (itemOnMySelf != null && Menu.Item("buff").GetValue<bool>())
{
itemOnMySelf.UseAbility(me);
Utils.Sleep(50 + Game.Ping, "nextAction");
return;
}
if (itemWithOutTarget != null && Menu.Item("buff").GetValue<bool>())
{
if (itemWithOutTarget.Name == "item_armlet")
{
itemWithOutTarget.ToggleAbility();
Utils.Sleep(50 + Game.Ping, "nextAction");
return;
}
itemWithOutTarget.UseAbility();
Utils.Sleep(100 + Game.Ping, "nextAction");
return;
}
if (dagger != null && dagger.CanBeCasted() && !isInvise && Utils.SleepCheck("dagger"))
{
var point = new Vector3(
(float)(target.Position.X - 20 * Math.Cos(me.FindAngleBetween(target.Position, true))),
(float)(target.Position.Y - 20 * Math.Sin(me.FindAngleBetween(target.Position, true))),
target.Position.Z);
dagger.UseAbility(point);
Utils.Sleep(200 + Game.Ping, "dagger");
return;
}
if (distance > duel.CastRange + 100 && Utils.SleepCheck("moving"))
{
if (isInvise)
me.Attack(target);
else
me.Move(target.Position);
Utils.Sleep(150 + Game.Ping, "moving");
return;
}
if (itemOnTarget != null && !dpActivated && Menu.Item("debuff").GetValue<bool>() && !isInvise)
{
itemOnTarget.UseAbility(target);
//.........这里部分代码省略.........
示例10: ComboInAction
private static void ComboInAction(Hero me, Hero target)
{
if (!Utils.SleepCheck("nextAction")) return;
var ss = me.Spellbook.Spell1; //Shadow Strike
var blink = me.Spellbook.Spell2; //Blink
var scream = me.Spellbook.Spell3; //Scream of Pain
var sonic = me.Spellbook.Spell4; // Sonic Wave
Item orchid = null;
if (Menu.Item("enabledAbilities").GetValue<AbilityToggler>().IsEnabled("item_orchid"))
{
orchid = me.FindItem("item_orchid"); //Orchid [Silence]
}
Item hex = null;
if (Menu.Item("enabledAbilities").GetValue<AbilityToggler>().IsEnabled("item_sheepstick"))
{
hex = me.FindItem("item_sheepstick"); //Hex [Disable]
}
Item mask = null;
if (Menu.Item("enabledAbilities").GetValue<AbilityToggler>().IsEnabled("item_mask_of_madness"))
{
mask = me.FindItem("item_mask_of_madness"); //Mask of Madness [Attack Speed]
}
Item mjo = null;
if (Menu.Item("enabledAbilities").GetValue<AbilityToggler>().IsEnabled("item_mjollnir"))
{ mjo = me.FindItem("item_mjollnir"); //Mjollnir Buff [AoE lightning]
}
Item shivas = null;
if (Menu.Item("enabledAbilities").GetValue<AbilityToggler>().IsEnabled("item_shivas_guard"))
{
shivas = me.FindItem("item_shivas_guard"); //Shivas [AoE Slow]
}
var neededMana = me.Mana - sonic.ManaCost;
var allitems = me.Inventory.Items.Where(x => x.CanBeCasted() && x.ManaCost <= neededMana);
var enumerable = allitems as Item[] ?? allitems.ToArray();
var itemOnTarget =
enumerable.FirstOrDefault(
x =>
x.Name == "item_orchid");
var itemWithOutTarget = enumerable.FirstOrDefault(
x =>
x.Name == "item_shivas_guard");
var itemOnMySelf = enumerable.FirstOrDefault(
x =>
x.Name == "item_mjollnir");
Item bkb = null;
if (Menu.Item("enabledAbilities").GetValue<AbilityToggler>().IsEnabled("item_black_king_bar"))
{
bkb = me.FindItem("item_black_king_bar");
}
var distance = me.Distance2D(target); //Target Distance
var attackRange = 550; //Attack Range
if (distance >= 1350) //Move to Target if Distance too far to blink
{
me.Move(target.Position);
Utils.Sleep(200 + Game.Ping, "nextAction");
return;
}
#region Items
//Mjollnir
if (itemOnMySelf != null && Menu.Item("enabledAbilities").GetValue<AbilityToggler>().IsEnabled("item_mjollnir"))
{
itemOnMySelf.UseAbility(me);
Utils.Sleep(50 + Game.Ping, "nextAction");
return;
}
//Blink to Target
if (blink != null && !Menu.Item("harass").GetValue<bool>() && blink.CanBeCasted() && distance >= attackRange && Utils.SleepCheck("blink"))
{
var point = new Vector3(
(float)(target.Position.X - 20 * Math.Cos(me.FindAngleBetween(target.Position, true))),
(float)(target.Position.Y - 20 * Math.Sin(me.FindAngleBetween(target.Position, true))),
target.Position.Z);
blink.UseAbility(point);
Utils.Sleep(200 + Game.Ping, "blink");
return;
}
//Orchid & Hex
if (itemOnTarget != null && Menu.Item("enabledAbilities").GetValue<AbilityToggler>().IsEnabled("item_orchid"))
{
orchid.UseAbility(target);
Utils.Sleep(50 + Game.Ping, "nextAction");
return;
}
if (Menu.Item("enabledAbilities").GetValue<AbilityToggler>().IsEnabled("item_sheepstick") && hex !=null && hex.CanBeCasted() && Utils.SleepCheck("nextAction"))
{
hex.UseAbility(target);
Utils.Sleep(50 + Game.Ping, "nextAction");
return;
}
//Shivas Guard
if (itemWithOutTarget != null && Menu.Item("enabledAbilities").GetValue<AbilityToggler>().IsEnabled("item_shivas_guard"))
{
itemWithOutTarget.UseAbility();
Utils.Sleep(100 + Game.Ping, "nextAction");
return;
}
//BKB
if (Menu.Item("enabledAbilities").GetValue<AbilityToggler>().IsEnabled("item_black_king_bar") && bkb != null && bkb.CanBeCasted() && Utils.SleepCheck("bkb"))
{
bkb.UseAbility();
//.........这里部分代码省略.........
示例11: Execute
//.........这里部分代码省略.........
< ability.GetRadius(name)
&& target1.PredictedPosition()
.Distance2D(
target.PredictedPosition(
ability.FindCastPoint(NameManager.Name(ability))))
< ability.GetRadius(name))
{
if (Nuke.Cast(ability, target1, name))
{
Utils.Sleep(
Math.Max(ability.GetCastDelay(me, target1, abilityName: name), 0.2) * 1000,
"GlobalCasting");
Utils.Sleep(ability.GetHitDelay(target1, name) * 1000, "calculate");
Utils.Sleep(
Math.Max(
ability.GetCastDelay(
me,
target1,
useCastPoint: false,
abilityName: name),
0.15) * 1000 + Game.Ping,
// + (Math.Max(me.Distance2D(target) - ability.GetCastRange(name) - 50, 0)
// / me.MovementSpeed) * 1000,
"casting");
Utils.Sleep(
Math.Max(ability.GetCastDelay(me, target1, abilityName: name), 0.2) * 1000,
"cancelorder");
return true;
}
}
else if (target1 != null && target1.Equals(me))
{
if (Utils.SleepCheck("Ability.Move"))
{
me.Move(Game.MousePosition);
Utils.Sleep(100, "Ability.Move");
}
Utils.Sleep(200, "GlobalCasting");
return true;
}
}
return false;
}
if (!ability.CanHit(target, MyHeroInfo.Position, name) && category != "buff")
{
dealtDamage = 0;
if (name == "templar_assassin_meld")
{
if (!Nuke.Cast(ability, target, name) && Utils.SleepCheck("Ability.Move"))
{
AbilityMain.Me.Move(Game.MousePosition);
Utils.Sleep(100, "Ability.Move");
}
Utils.Sleep(200, "GlobalCasting");
return true;
}
if (name == "pudge_rot")
{
continue;
}
示例12: ComboInAction
//.........这里部分代码省略.........
Utils.Sleep(250, "StageCheck");
}
else if (eulmodif == null)
{
UseSpell(_spellForCast, target);
_stage++;
Utils.Sleep(250, "StageCheck");
}
}
else if (!Equals(_spellForCast, ss) && !Equals(_spellForCast, chaosmeteor))
{
UseSpell(_spellForCast, target);
_stage++;
Utils.Sleep(250, "StageCheck");
}
var timing = (Equals(_spellForCast, ss))
? 1.7
: (Equals(_spellForCast, chaosmeteor)) ? 1.3 : 0;
timing += Game.Ping / 1000 - 0.005;
//PrintInfo(timing.ToString(CultureInfo.InvariantCulture));
if (eulmodif != null && eulmodif.RemainingTime < timing)
{
UseSpell(_spellForCast, target);
_stage++;
Utils.Sleep(250, "StageCheck");
}
}
else if (Equals(_spellForCast, icewall))
{
var dist = me.Distance2D(target) <= 300;
if (!dist)
{
if (me.CanMove() && Utils.SleepCheck("icewallmove"))
{
var point =
new Vector3(
(float) (target.Position.X -
200*
Math.Cos(me.FindAngleBetween(target.Position, true))),
(float) (target.Position.Y -
200*
Math.Sin(me.FindAngleBetween(target.Position, true))), 0);
me.Move(point);
Utils.Sleep(300, "icewallmove");
}
}
else
{
_spellForCast.UseAbility();
_stage++;
Utils.Sleep(250, "StageCheck");
}
}
else
{
var tornadoMod = target.Modifiers.FirstOrDefault(x => x.Name == "modifier_invoker_tornado");
if (Equals(_spellForCast, deafblast))
{
if (tornadoMod != null &&
tornadoMod.RemainingTime <= me.Distance2D(target) / 1100 - .1 - Game.Ping / 1000)
{
UseSpell(_spellForCast, target);
_stage++;
Utils.Sleep(250, "StageCheck");
示例13: Tinker_In_Madness
//.........这里部分代码省略.........
Laser.UseAbility(target);
Utils.Sleep(200, "TimingToLinkens");
}
}
else if (Dagon != null && Dagon.CanBeCasted() && Menu.Item("Items: ").GetValue<AbilityToggler>().IsEnabled("item_dagon"))
{
if (Utils.SleepCheck("TimingToLinkens"))
{
Dagon.UseAbility(target);
Utils.Sleep(200, "TimingToLinkens");
}
}
else if (Hex != null && Hex.CanBeCasted() && Menu.Item("Items: ").GetValue<AbilityToggler>().IsEnabled(Hex.Name))
{
if (Utils.SleepCheck("TimingToLinkens"))
{
Hex.UseAbility(target);
Utils.Sleep(200, "TimingToLinkens");
}
}
}
else
{
uint elsecount = 0;
bool magicimune = (!target.IsMagicImmune() && !target.Modifiers.Any(x => x.Name == "modifier_eul_cyclone"));
if (Utils.SleepCheck("combo"))
{
// glimmer -> ghost -> soulring -> hex -> laser -> ethereal -> dagon -> rocket -> shivas -> euls -> refresh
if (glimmer != null && glimmer.CanBeCasted() && Menu.Item("Items2: ").GetValue<AbilityToggler>().IsEnabled(glimmer.Name) && Utils.SleepCheck("Rearm"))
glimmer.UseAbility(me);
else
elsecount += 1;
if (ghost != null && Ethereal == null && ghost.CanBeCasted() && Menu.Item("Items2: ").GetValue<AbilityToggler>().IsEnabled(ghost.Name) && Utils.SleepCheck("Rearm"))
ghost.UseAbility();
else
elsecount += 1;
if (Soulring != null && Soulring.CanBeCasted() && Menu.Item("Items: ").GetValue<AbilityToggler>().IsEnabled(Soulring.Name) && Utils.SleepCheck("Rearm"))
Soulring.UseAbility();
else
elsecount += 1;
if (Hex != null && Hex.CanBeCasted() && Menu.Item("Items: ").GetValue<AbilityToggler>().IsEnabled(Hex.Name) && magicimune && Utils.SleepCheck("Rearm"))
Hex.UseAbility(target);
else
elsecount += 1;
if (Laser != null && Laser.CanBeCasted() && Menu.Item("Skills: ").GetValue<AbilityToggler>().IsEnabled(Laser.Name) && magicimune && Utils.SleepCheck("Rearm"))
Laser.UseAbility(target);
else
elsecount += 1;
if (Ethereal != null && Ethereal.CanBeCasted() && Menu.Item("Items: ").GetValue<AbilityToggler>().IsEnabled(Ethereal.Name) && magicimune && Utils.SleepCheck("Rearm"))
{
Ethereal.UseAbility(target);
if (Utils.SleepCheck("EtherealTime") && me.Distance2D(target) <= Ethereal.CastRange)
Utils.Sleep((me.NetworkPosition.Distance2D(target.NetworkPosition) / 620) * 1000, "EtherealTime");
}
else
elsecount += 1;
if (Dagon != null && Dagon.CanBeCasted() && Menu.Item("Items: ").GetValue<AbilityToggler>().IsEnabled("item_dagon") && magicimune && Utils.SleepCheck("Rearm") && Utils.SleepCheck("EtherealTime"))
Dagon.UseAbility(target);
else
elsecount += 1;
if (Rocket != null && Rocket.CanBeCasted() && Menu.Item("Skills: ").GetValue<AbilityToggler>().IsEnabled(Rocket.Name) && magicimune && Utils.SleepCheck("Rearm"))
{
Rocket.UseAbility();
if (Utils.SleepCheck("RocketTime") && me.Distance2D(target) <= Rocket.CastRange)
Utils.Sleep((me.NetworkPosition.Distance2D(target.NetworkPosition) / 600) * 1000, "RocketTime");
}
else
elsecount += 1;
if (Shiva != null && Shiva.CanBeCasted() && Menu.Item("Items: ").GetValue<AbilityToggler>().IsEnabled(Shiva.Name) && magicimune && Utils.SleepCheck("Rearm"))
Shiva.UseAbility();
else
elsecount += 1;
if (elsecount == 9 && euls != null && euls.CanBeCasted() && Menu.Item("Items2: ").GetValue<AbilityToggler>().IsEnabled(euls.Name) && magicimune && Utils.SleepCheck("Rearm") && Utils.SleepCheck("EtherealTime") && Utils.SleepCheck("RocketTime"))
euls.UseAbility(target);
else
elsecount += 1;
if (elsecount == 10 && Refresh != null && Refresh.CanBeCasted() && Menu.Item("Skills: ").GetValue<AbilityToggler>().IsEnabled(Refresh.Name) && !Refresh.IsChanneling && Utils.SleepCheck("Rearm") && Ready_for_refresh())
{
Refresh.UseAbility();
Utils.Sleep(800, "Rearm");
}
else
{
if (!me.IsChanneling() && Utils.SleepCheck("Rearm") && me.Distance2D(target) <= me.AttackRange)
me.Attack(target);
}
Utils.Sleep(150, "combo");
}
}
}
else
{
autoattack(false);
if (!me.IsChanneling() && Utils.SleepCheck("Rearm"))
me.Move(Game.MousePosition);
}
}
else
autoattack(false);
}
示例14: Game_OnUpdate
//.........这里部分代码省略.........
if (// ethereal
ethereal != null
&& ethereal.CanBeCasted()
&& me.CanCast()
&& !target.IsLinkensProtected()
&& !target.IsMagicImmune()
&& Menu.Item("Items: ").GetValue<AbilityToggler>().IsEnabled(ethereal.Name)
&& Utils.SleepCheck("ethereal")
)
{
ethereal.UseAbility(target);
Utils.Sleep(200, "ethereal");
} // ethereal Item end
if (!ethereal.CanBeCasted() || ethereal == null || me.IsSilenced() || !Menu.Item("Items: ").GetValue<AbilityToggler>().IsEnabled(ethereal.Name))
{
if (
Q != null
&& Q.CanBeCasted()
&& me.CanCast()
&& me.Distance2D(target) < 1400
&& Menu.Item("Skills: ").GetValue<AbilityToggler>().IsEnabled(Q.Name)
&& Utils.SleepCheck("Q")
)
{
Q.UseAbility(target);
Utils.Sleep(200, "Q");
}
if (
R != null
&& R.CanBeCasted()
&& me.CanCast()
&& !target.HasModifier("modifier_skywrath_mystic_flare_aura_effect")
&& target.MovementSpeed <= 240
&& me.Position.Distance2D(target) < 1200
&& target.Health >= (target.MaximumHealth / 100 * Menu.Item("Healh").GetValue<Slider>().Value)
&& !target.HasModifier("modifier_item_blade_mail_reflect")
&& !target.HasModifier("modifier_skywrath_mystic_flare_aura_effect")
&& !target.HasModifier("modifier_obsidian_destroyer_astral_imprisonment_prison")
&& !target.HasModifier("modifier_puck_phase_shift")
&& !target.HasModifier("modifier_eul_cyclone")
&& !target.HasModifier("modifier_dazzle_shallow_grave")
&& !target.HasModifier("modifier_brewmaster_storm_cyclone")
&& !target.HasModifier("modifier_spirit_breaker_charge_of_darkness")
&& !target.HasModifier("modifier_shadow_demon_disruption")
&& !target.HasModifier("modifier_tusk_snowball_movement")
&& !target.IsMagicImmune()
&& (!target.FindSpell("abaddon_borrowed_time").CanBeCasted() && !target.HasModifier("modifier_abaddon_borrowed_time_damage_redirect"))
&& Menu.Item("Skills: ").GetValue<AbilityToggler>().IsEnabled(R.Name)
&& Utils.SleepCheck("R"))
{
R.UseAbility(Prediction.InFront(target, 100));
Utils.Sleep(330, "R");
}
if (// SoulRing Item
soulring != null
&& soulring.CanBeCasted()
&& me.CanCast()
&& me.Health >= (me.MaximumHealth * 0.5)
&& me.Mana <= R.ManaCost
&& Menu.Item("Items: ").GetValue<AbilityToggler>().IsEnabled(soulring.Name)
)
{
示例15: Working
//.........这里部分代码省略.........
if (me.Distance2D(target) <= 500)
{
if (dust != null && dust.CanBeCasted() && Utils.SleepCheck("dust") && dust != null && Menu.Item("Consume Items").GetValue<AbilityToggler>().IsEnabled(dust.Name))
{
dust.UseAbility();
Utils.Sleep(100, "dust");
}
else if (sentry != null && sentry.CanBeCasted() && Utils.SleepCheck("sentry") && sentry != null && Menu.Item("Consume Items").GetValue<AbilityToggler>().IsEnabled(sentry.Name))
{
sentry.UseAbility(me.Position);
Utils.Sleep(100, "sentry");
}
}
}
uint elsecount = 1;
if (Utils.SleepCheck("combo"))
{
if (blademail != null && blademail.Cooldown <= 0 && Menu.Item("Defensive Items").GetValue<AbilityToggler>().IsEnabled(blademail.Name) && me.Mana - blademail.ManaCost >= 75)
blademail.UseAbility();
else
elsecount += 1;
if (satanic != null && satanic.Cooldown <= 0 && me.Health <= me.MaximumHealth * 0.5 && Menu.Item("Defensive Items").GetValue<AbilityToggler>().IsEnabled(satanic.Name))
satanic.UseAbility();
else
elsecount += 1;
if (crimson != null && crimson.Cooldown <= 0 && Menu.Item("Consume Items").GetValue<AbilityToggler>().IsEnabled(crimson.Name))
crimson.UseAbility();
else
elsecount += 1;
if (buckler != null && buckler.Cooldown <= 0 && Menu.Item("Consume Items").GetValue<AbilityToggler>().IsEnabled(buckler.Name) && me.Mana - buckler.ManaCost >= 75)
buckler.UseAbility();
else
elsecount += 1;
if (lotusorb != null && lotusorb.Cooldown <= 0 && Menu.Item("Defensive Items").GetValue<AbilityToggler>().IsEnabled(lotusorb.Name) && me.Mana - lotusorb.ManaCost >= 75)
lotusorb.UseAbility(me);
else
elsecount += 1;
if (mjollnir != null && mjollnir.Cooldown <= 0 && Menu.Item("Ofensive Items").GetValue<AbilityToggler>().IsEnabled(mjollnir.Name) && me.Mana - mjollnir.ManaCost >= 75)
mjollnir.UseAbility(me);
else
elsecount += 1;
if (armlet != null && !armlet.IsToggled && Menu.Item("Ofensive Items").GetValue<AbilityToggler>().IsEnabled(armlet.Name) && Utils.SleepCheck("armlet"))
{
armlet.ToggleAbility();
Utils.Sleep(300, "armlet");
}
else
elsecount += 1;
if (madness != null && madness.Cooldown <= 0 && Menu.Item("Ofensive Items").GetValue<AbilityToggler>().IsEnabled(madness.Name) && me.Mana - madness.ManaCost >= 75)
madness.UseAbility();
else
elsecount += 1;
if (Heal != null && Heal.Level > 0 && Heal.Cooldown <= 0 && Menu.Item("Skills").GetValue<AbilityToggler>().IsEnabled(Heal.Name) && !me.IsMagicImmune() && me.Mana - Heal.ManaCost >= 75)
Heal.UseAbility(me);
else
elsecount += 1;
if (bkb != null && bkb.Cooldown <= 0 && Menu.Item("Defensive Items").GetValue<AbilityToggler>().IsEnabled(bkb.Name) && (!Heal.CanBeCasted() || Heal == null))
bkb.UseAbility();
else
elsecount += 1;
if (blink != null && blink.Cooldown <= 0 && me.Distance2D(target) <= 1300 && me.Distance2D(target) >= 200 && Menu.Item("Ofensive Items").GetValue<AbilityToggler>().IsEnabled(blink.Name))
blink.UseAbility(target.Position);
else
elsecount += 1;
if (abyssal != null && abyssal.Cooldown <= 0 && Menu.Item("Ofensive Items").GetValue<AbilityToggler>().IsEnabled(abyssal.Name) && me.Mana - abyssal.ManaCost >= 75)
abyssal.UseAbility(target);
else
elsecount += 1;
if (urn != null && urn.CurrentCharges > 0 && Menu.Item("Ofensive Items").GetValue<AbilityToggler>().IsEnabled(urn.Name))
urn.UseAbility(target);
else
elsecount += 1;
if (solar != null && solar.CanBeCasted() && Menu.Item("Ofensive Items").GetValue<AbilityToggler>().IsEnabled(solar.Name))
solar.UseAbility(target);
else
elsecount += 1;
if (medallion != null && medallion.CanBeCasted() && Menu.Item("Ofensive Items").GetValue<AbilityToggler>().IsEnabled(medallion.Name))
medallion.UseAbility(target);
else
elsecount += 1;
if (Duel != null && Duel.Cooldown <= 0 && !target.IsLinkensProtected() && !target.Modifiers.Any(x => x.Name == "modifier_abaddon_borrowed_time") && Utils.SleepCheck("Duel") && elsecount == 16)
{
Duel.UseAbility(target);
Utils.Sleep(100, "Duel");
}
else
me.Attack(target,false);
Utils.Sleep(150, "combo");
}
}
}
}
}
else
{
if(me.IsAlive && !me.IsChanneling())
me.Move(Game.MousePosition,false);
}
}
}