derdennis
New Member
- Joined
- Dec 25, 2013
- Messages
- 28
- Reaction score
- 0
i build up this little combat routine "without" any moving to target string but if i get a target, the bot moves automatic in attack range.
i cant find a way to disable automove at all.
here is the plugin, feel free to use:
i cant find a way to disable automove at all.
here is the plugin, feel free to use:
Code:
using System;
using System.Drawing;
using System.Windows.Forms;
using System.Threading;
using System.Collections.Generic;
using System.Linq;
using ArcheBuddy.Bot.Classes;
namespace Follower{
public class Archery : Core
{
public static string GetPluginAuthor()
{
return "derdennis";
}
public static string GetPluginVersion()
{
return "0.1";
}
public static string GetPluginDescription()
{
return "Archery for Primeval";
}
public void UseSkillAndWait(string skillName, bool selfTarget = false)
{
while (me.isCasting || me.isGlobalCooldown)
Thread.Sleep(50);
if (!UseSkill(skillName, true, selfTarget))
while (me.isCasting || me.isGlobalCooldown)
Thread.Sleep(50);
}
public void PluginRun()
{
while(true)
{
while(me.target == null)
{
Thread.Sleep(50);
}
while(me.target != null && isAttackable(me.target))
// combat start
{
if (angle(me.target, me) > 45 && angle(me.target, me) < 315)
// autoface target
{
TurnDirectly(me.target);
}
if(dist(me.target) <= 9 && skillCooldown("Overwhelm") == 0 && skillCooldown("Shadowsmite") == 0 && skillCooldown("Drop Back") == 0)
{
UseSkillAndWait("Overwhelm");
Log("Used: Overwhelm");
Thread.Sleep(100);
UseSkillAndWait("Shadowsmite");
Log("Used: Shadowsmite");
Thread.Sleep(100);
UseSkillAndWait("Drop Back");
Log("Used: Drop Back");
}
if (skillCooldown("Toxic Shot") == 0)
{
UseSkillAndWait("Toxic Shot");
Log("Used: Toxic Shot");
Thread.Sleep(100);
}
if (skillCooldown("Stalker's Mark") == 0)
{
UseSkillAndWait("Stalker's Mark");
Log("Used: Stalker's Mark");
Thread.Sleep(100);
}
if (skillCooldown("Charged Bolt") == 0)
{
UseSkillAndWait("Charged Bolt");
Log("Used: Charged Bolt");
Thread.Sleep(100);
}
if (skillCooldown("Piercing Shot") == 0)
{
UseSkillAndWait("Piercing Shot");
Log("Used: Piercing Shot");
Thread.Sleep(100);
}
if (skillCooldown("Endless Arrows") == 0)
{
UseSkillAndWait("Endless Arrows");
Log("Used: Endless Arrows");
Thread.Sleep(100);
}
}
}
}
}
}