July 31, 20187 yr how to write in C++ format the usual follow path like quester profile. I need it for create quester profile(RunCode). So the bot ran to the nearest point and not the starting point of the code. if I write this: wManager.Wow.Bot.Tasks.GoToTask.ToPosition(p1); wManager.Wow.Bot.Tasks.GoToTask.ToPosition(p2); wManager.Wow.Bot.Tasks.GoToTask.ToPosition(p...); wManager.Wow.Bot.Tasks.GoToTask.ToPosition(pN); the bot will always start from the first point of the route.
August 1, 20187 yr Hello, https://wrobot.eu/forums/topic/9047-wrobot-doesnt-use-the-recorded-path/?do=findComment&comment=42126
August 1, 20187 yr Author 1 hour ago, Droidz said: Hello, When I use the code, bot running into first position, how to do what bot run to the nearby point?
August 1, 20187 yr Author In the one step I create many actions with many conditions. Goto follow path + use stealth + use item + again follow path... + ... . Me so feel more comfortable than a large number of steps in quest profile
August 1, 20187 yr //bad pseudo code: bool reachedP1 = false; if(!reachedP1) { wManager.Wow.Bot.Tasks.GoToTask.ToPosition(p1); } //p1 is reached here if(ObjectManager.Me.Position.DistanceTo(p1) < 5) { reachedP1 = true; } wManager.Wow.Bot.Tasks.GoToTask.ToPosition(p2); wManager.Wow.Bot.Tasks.GoToTask.ToPosition(p...); wManager.Wow.Bot.Tasks.GoToTask.ToPosition(pN); But keep in mind, you have to do this in full C# quest. NOT just overrideCSharpPulse! Or else it will go to P1 over and over, because everytime it sets reachedP1 to false in the start. If you want to use this in OverrideCSharpPulse, you have to use Var API, like here: Instead of just using boolean you will do if(Var.GetVar<bool>("reachedP1") == null) { Var.SetVar("reachedP1", false); } if(!Var.GetVar<bool>("reachedP1")) { GoToTask.ToPos(p1); //if close code Var.SetVar("reachedP1", true); } It's all a bit pseudo code but you get the idea
August 6, 20187 yr Author On 8/1/2018 at 1:09 PM, Droidz said: why not use quest type followpath? var path = new List<Vector3>() { new Vector3(891.3235, -259.2199, -45, "None"), new Vector3(881.2866, -271.8759, -45, "None"), new Vector3(880.6079, -280.9656, -45, "None"), new Vector3(888.381, -293.3022, -45, "None"), new Vector3(890.4747, -304.1179, -45, "None"), }; var min = path[0]; for(int i = 0; i < path.Count; i++) { if(ObjectManager.Me.Position.DistanceTo(min) < ObjectManager.Me.Position.DistanceTo(path)) min = path; else if(i > 0) path.Remove(path); } foreach(var p in path) wManager.Wow.Bot.Tasks.GoToTask.ToPosition(p); Bot run to 2nd point in the path.Why it don't work? Write please working code for Bot go to min distance in the path.
August 6, 20187 yr overrideCSharpPulse The method inside this gets called OVER AND OVER by wRobot (basically anytime the quester pulse state is called). If you initialize the path list inside that mehod, its state gets reset every time wRobot restarts the state... See my explanation above
August 6, 20187 yr Author 2 hours ago, Matenia said: overrideCSharpPulse The method inside this gets called OVER AND OVER by wRobot (basically anytime the quester pulse state is called). If you initialize the path list inside that mehod, its state gets reset every time wRobot restarts the state... See my explanation above //bad pseudo code: bool reachedP1 = false; if(!reachedP1) { wManager.Wow.Bot.Tasks.GoToTask.ToPosition(p1); } //p1 is reached here if(ObjectManager.Me.Position.DistanceTo(p1) < 5) { reachedP1 = true; } wManager.Wow.Bot.Tasks.GoToTask.ToPosition(p2); wManager.Wow.Bot.Tasks.GoToTask.ToPosition(p...); wManager.Wow.Bot.Tasks.GoToTask.ToPosition(pN); If I put the pause and after start bot again running to p1 if he stay < 5 yards from p1. Do you can write code like Droidz wrote for WRobot in Quester Follow path?
May 8, 20196 yr Sorry for reviving this thread. But i've got the same problem and i'm not sure how to solve it. I need to create a follow path analog with C#. The question is, is it possible to create an instance of QuestFollowPathClass with preset Path, IsCompleteWhenAtLastPath, and other parameters, hold it file and then just call it from the code with something like MyFollowPathQuest.Pulse() ? Let's say even call it from the same file. It's not a library question.
May 9, 20196 yr 15 hours ago, Findeh said: Sorry for reviving this thread. But i've got the same problem and i'm not sure how to solve it. I need to create a follow path analog with C#. The question is, is it possible to create an instance of QuestFollowPathClass with preset Path, IsCompleteWhenAtLastPath, and other parameters, hold it file and then just call it from the code with something like MyFollowPathQuest.Pulse() ? Let's say even call it from the same file. It's not a library question. Hello, yes use code like: wManager.Wow.Helpers.Quest.QuesterCurrentContext.QuestsClasses["MyQuestClassName"].Pulse() (replace MyQuestClassName by you quest name (name used in steps))
Create an account or sign in to comment