Hi, I got two questions..
First, is there a way to get the location of your target? like a function that returns x,y and z values.. or even better to get the location of the nearest unit of a specific id number.
And 2nd, is there a function that makes your character move to a location without depending of the waypoints? Ty
That code is in between waypoint tags which means it would move to that point first then execute the code. It may not have something targeted when executing that code.
Try putting that code between onLoad tags instead so it gets executed immediately. Then target something first before loading the waypoint file. eg.
it worked when I put it in <OnLoad>. But it still doesnt work when I have it in a waypoint:S. I think I know what the problem is tho: When it got to the waypoint before it executed any code it printed "Clearing target" in the micromacro program. Any idea how I can remove that?
I also noticed now when I tried the moveTo that it doesnt work and I get this error:
...rom/classes/player.lua/player.lua:1150: attemp to index local 'waypoint' (a number value)
WhiteTiger wrote:it worked when I put it in <OnLoad>. But it still doesnt work when I have it in a waypoint:S. I think I know what the problem is tho: When it got to the waypoint before it executed any code it printed "Clearing target" in the micromacro program. Any idea how I can remove that?
At this point I think we need to ask, why do you want to know the coordinates of your target and what do you intend to do with them?
Please consider making a small donation to me to support my continued contributions to the bot and this forum. Thank you. Donate
I check all posts before reading PMs. So if you want a fast reply, don't PM me but post a topic instead. PM me for private or personal topics only.