January 31, 201610 yr Basicly currently the problem is that it follows tank in combat and all if going too far doing fine but if tank goes out of line of sight (behind tree, hill or something) it'll just stand there like mushroom in shit. Any ideas how to improve this? For some reason with MovementManager.MoveTo(tank) it requires straight line to the target without anything on its way #region Tank too far bool tankfar() { WoWPlayer tank = getTanks().First(); while (tank.GetDistance > 15) { MovementManager.MoveTo(tank); } MovementManager.StopMove(); return false; } #endregion
February 1, 201610 yr Hello, To stop to go to tank if it is out of view you can use this code: #region Tank too far bool tankfar() { WoWPlayer tank = getTanks().First(); while (tank.IsValid && tank.GetDistance > 15 && !wManager.Wow.Helpers.TraceLine.TraceLineGo(tank.Position)) { MovementManager.MoveTo(tank); System.Threading.Thread.Sleep(50); } MovementManager.StopMove(); return false; } #endregion To generate path and go to tank you can use code like this: #region Tank too far bool tankfar() { WoWPlayer tank = getTanks().First(); if (tank.IsValid && tank.GetDistance > 15) { wManager.Wow.Bot.Tasks.GoToTask.ToPositionAndIntecractWith(new WoWUnit(tank.GetBaseAddress), -1, false, context => Conditions.InGameAndConnectedAndAliveAndProductStartedNotInPause && tank.GetDistance > 15); } MovementManager.StopMove(); return false; } #endregion
Create an account or sign in to comment