private static LocalPlayer Me
{
get { return ObjectManager.Me; }
}
public static void FaceTarget(WoWUnit target)
{
if (!Me.IsSafelyFacing(target, 70f) && !Me.IsMoving && target != null)
{
target.Face();
}
}
public static void MovetoLos(WoWUnit target)
{
if (!target.InLineOfSpellSight && target != Me)//InLineOfSpellsight is better than the odd one because here we can make sure that we are in a "real" LOS
{
Navigator.MoveTo(target.Location);
}
}
public static void Movetotarget(WoWPoint targetlocation, bool stopinrange, float range)
{
if (stopinrange && Me.Location.Distance(targetlocation) + 0.6f < range)
{
Navigator.PlayerMover.MoveStop();
}
else if (!Me.WithinInteractRange || !Me.IsWithinMeleeRange ||
Me.Location.Distance(targetlocation) + 0.6f > range)
{
Navigator.MoveTo(targetlocation);
}
}