by mezzo » Tue Jun 17, 2008 8:16 pm
everything in a virtual world has coordinates.
lets just call them X/Y and Z.
It would be insane for an MMORPG to constantly calculate the distance between all these objects and send them to every client for every object.
As it hardly makes sence for your game client to know what the distance is between your player character and an object on the other side of the 'virtual world'.
Which means that 9 chances out of 10, your game client will only calculate the distance between you and relevant objects.
Now how does it calculate distance ? It uses your player coordinates and the enemies coordinate to do the math.
So to make a long story short(er), you will first need to search for your
own coordinates (x,y,z) and then work from there. Your coordinates will most likely be 3 floats.
- No thanks, I already have a penguin -