Thread Tools Display Modes
Prev Previous Post   Next Post Next
02/27/15, 03:30 AM   #1
circonian
AddOn Author - Click to view addons
Join Date: May 2014
Posts: 613
Exact Waypoint Loc

I'm trying to figure out a way to keep track of different waypoint locations (that will be set on mapPin locations).
First I started by using the tooltip text of the mapPin, so that I would know which pin I had placed a waypoint at. But then ran into problems where some addons that create custom pins have multiple mapPins with the same name. I then thought I would also check the x/y coordinates, but ran into another problem.

When I set a waypoint and then call GetMapPlayerWaypoint() the coordinates are not the same:


My only guess is that it is doing some kind of scaling for the map size or it has something to do with the MAP_TYPE_LOCATION_CENTERED (but I could find no other MAP_TYPE_LOCATION to use). I am ? guessing that the waypoint texture is getting centered on the coordinates that I am setting the waypoint at, but GetMapPlayerWaypoint() is returning coordinates to the TOPLEFT of the waypoint?

Either way that makes the waypoint coordinates no good since I do not know what coordinates the waypoint that I set will end up with.

I could do some math and just guesstimate how close the pin is to the coordinates I set and if its "close" just accept that its probably the same point. But if the difference in coordinates is due to some kind of map size scaling, trying to decide what "close" is becomes harder since every map may have different scaling.

I was just curious if anyone knows a better way or if there is some way to force it to set the waypoint at the location I specify so GetMapPlayerWaypoint() will return the exact same coordinates.

Last edited by circonian : 02/27/15 at 03:38 AM.
  Reply With Quote
 

ESOUI » Developer Discussions » General Authoring Discussion » Exact Waypoint Loc


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off