end |
return info |
end |
local function bfa_func() |
if(C_Map and C_Map.GetPlayerMapPosition) then |
local mapID = C_Map.GetBestMapForUnit("player") |
if(mapID) then |
return C_Map.GetPlayerMapPosition(mapID,"player") |
end |
else |
local x,y = GetPlayerMapPosition("player") |
return { |
['x'] = x, |
['y'] = y |
} |
end |
end |
local function setPlayerCoords() |
local tab = bfa_func() |
if(tab) then |
local x,y = tab['x'],tab['y'] |
local function setPlayerCoords(mapID,x,y) |
playerCoords = "-, -" |
mapID = C_Map.GetBestMapForUnit("player") |
if(mapID) then |
x,y = C_Map.GetPlayerMapPosition(mapID,"player"):GetXY() |
if(x) then |
if(y) then |
playerCoords = format("%.1f, %.1f", x*100, y*100) |