View Single Post
06-17-18, 01:02 PM   #5
Rilgamon
Premium Member
 
Rilgamon's Avatar
Premium Member
AddOn Author - Click to view addons
Join Date: Sep 2009
Posts: 822
Lua Code:
  1. local mapID = C_Map.GetBestMapForUnit("player")
  2. local px, py = C_Map.GetPlayerMapPosition(mapID, "player"):GetXY()
When you use it that way make sure that mapID has a value.
mapID can be undefined while using portals.
__________________
The cataclysm broke the world ... and the pandas could not fix it!
  Reply With Quote