Page 1 of 1

Potential error in MQ's Location routine...

Posted: Thu Apr 24, 2003 7:05 pm
by NealThorpayt
Greetings Constructs,

I have found what appears to be an error in the Location function in EQLib.cpp. The X and Y coordinates are transposed.

The line is question is:

Code: Select all

	sprintf(szMsg,"Your Location is %3.2f, %3.2f, %3.2f, and are heading %s.", pChar->Y, pChar->X, pChar->Z, szHeading[Angle]);
I believe it should be:

Code: Select all

	sprintf(szMsg,"Your Location is %3.2f, %3.2f, %3.2f, and are heading %s.", pChar->X, pChar->Y, pChar->Z, szHeading[Angle]);
End of line...

Posted: Thu Apr 24, 2003 7:37 pm
by kaz
it is actually correct, eq transposes the Y and X coordinates internally before displaying them to the user interface (like with the eqversion of loc)

Posted: Thu Apr 24, 2003 8:09 pm
by NealThorpayt
Greetings Constructs,

Well, I would assume that the X axis is the East-West axis and the Y axis is the North-South axis. I don't believe there is any way of telling if the programmers intended the structure locations to be X or Y in that there is no debugging information. So, assuming my axis are correct, then the current struct for _SPAWNINFO needs to have the Location function changed as I specified.

End of line...