sinshar wrote:lightningzero wrote:shinshar can you post yours as an example? i don't even care if it's buggy or unfinished, another example would be nice to help me learn
Yeah, when i get home i will post what i got for navigating I am using Wyvernx's functions to get the direction and then i just wrote a little bit of Code to navigate to the mob.
as for who was saying since we have x,y,z what more do we need. We don't **need** anythning more, but if someone less mathmaticly challenged then myself could write a simple nagivateTo(XY) function it would be sweet.
or even a NavigateTO_FROM(TOX,TOY, FROMX,FROMY) kinda thing would be sweet,
I will attempt it when i get home, but, Know this.. im' the suck at sin and cosin. so... if it drives you off a cliff don't hold me responsible
Sure I understand.
The simplest of all algoritms from muving from currentloc to wanted loc would be to just first consider the X loc, and then move until it matches the X loc, then consider the Y loc and move until that matches too, and youl be there.
of course, the better algoritm would involve a little simple math. When you know the difference between currentlocX and wanted locX and difference between currentY and wantedY, you make a simple pythagoras computation. That will give you the exact angle you need to turn to in order to get to where you want (and it will also give you the distance, allthough it would probably be better to continously check your loc to see if you have reached your target rather than relying on the distance).
Its pretty simple math, but I understnad it can be daunting to delve into for beginners. I will gladly post an effective algoritm for this as soon as exhume gets its autoit compatability. WyvernX briefly mentioned this was soon to come, and I code ten times slower in VBscript
