View Single Post
11/04/18, 12:44 AM   #6
MasterLenman
Join Date: Oct 2016
Posts: 2
Originally Posted by ZOS_DanBatson View Post
The new signature for that function is:

GetPOIMapInfo(zoneIndex, poiIndex) return normalizedX, normalizedZ, poiPinType, icon, isShownInCurrentMap, linkedCollectibleIsLocked, isDiscovered, isNearby

isDiscovered and isNearby were added.

Now instead of obfuscating POIs you haven't seen, we let the API know about it (where it is, which icon, etc) and we provide whether or not it's discovered and whether or not it's nearby to determine whether or not we want to show it on the map. For the purposes of addons, you can make your own determinations about what POIs you show and how (primarily using isShownInCurrentMap, isDiscovered, and isNearby), but you no longer need to cache off your own position and icon information.

If the zoneIndex and poiIndex are good, you should no longer be getting back INVALID for the poiPinType. To mirror the old behavior, in the past if isDiscovered was false and isNearby was false, poiPinType would have been INVALID.

Lua Code:
  1. local normalizedX, normalizedZ, poiPinType, icon, isShownInCurrentMap, linkedCollectibleIsLocked, isDiscovered, isNearby = GetPOIMapInfo(zoneIndex, poiIndex)
  2. local unknown = not (isDiscovered or isNearby)
Thanks for the detailed response and explanation! It's working fine now in Destinations.
  Reply With Quote