Thread Tools Display Modes
12/31/21, 02:39 AM   #1
ThatOneGuy789
Join Date: Dec 2021
Posts: 2
MapPin XY to world XYZ

is there anyway to convert the XY to world XYZ?
  Reply With Quote
12/31/21, 05:26 AM   #2
Masteroshi430
 
Masteroshi430's Avatar
AddOn Author - Click to view addons
Join Date: Dec 2020
Posts: 185
Originally Posted by ThatOneGuy789 View Post
is there anyway to convert the XY to world XYZ?
You can't guess the Z , set it to 0...
  Reply With Quote
12/31/21, 05:43 AM   #3
votan
 
votan's Avatar
AddOn Author - Click to view addons
Join Date: Oct 2014
Posts: 577
LibGPS has that feature.
  Reply With Quote
01/01/22, 01:24 PM   #4
ThatOneGuy789
Join Date: Dec 2021
Posts: 2
Originally Posted by votan View Post
LibGPS has that feature.
what im wanting to do is if i set a player waypoint on the map it will return the X, Y, Z of that waypoint in the world space

i use GetMapPlayerWaypoint() to get that set waypoint which returns a normalized XY but from my testing Y is actually Z and not Y so im not understanding the conversion there.
  Reply With Quote
01/01/22, 04:44 PM   #5
Masteroshi430
 
Masteroshi430's Avatar
AddOn Author - Click to view addons
Join Date: Dec 2020
Posts: 185
Originally Posted by ThatOneGuy789 View Post
what im wanting to do is if i set a player waypoint on the map it will return the X, Y, Z of that waypoint in the world space

i use GetMapPlayerWaypoint() to get that set waypoint which returns a normalized XY but from my testing Y is actually Z and not Y so im not understanding the conversion there.
Why not
local x, y = gps:LocalToGlobal(GetMapPlayerWaypoint())
local z = 0
You can't guess the Z if you don't have the data anyway...
  Reply With Quote
01/02/22, 08:20 AM   #6
Baertram
Super Moderator
 
Baertram's Avatar
WoWInterface Super Mod
AddOn Author - Click to view addons
Join Date: Mar 2014
Posts: 4,964
Afaik a waypoint got no z info as it is just a point on the map, not respecting any height. Just x (left) and y (top) cordinates where the point was set.
  Reply With Quote

ESOUI » AddOns » AddOn Help/Support » MapPin XY to world XYZ


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