WoWInterface

WoWInterface (https://www.wowinterface.com/forums/index.php)
-   WoD Beta archived threads (https://www.wowinterface.com/forums/forumdisplay.php?f=151)
-   -   ZONE_CHANGED_NEW_AREA new behaviour (https://www.wowinterface.com/forums/showthread.php?t=49953)

cremetorte 09-21-14 05:54 AM

ZONE_CHANGED_NEW_AREA new behaviour
 
Hi,

before 6.0 i could catch the event ZONE_CHANGED_NEW_AREA and do

local zoneInfo = EJ_GetCurrentInstance();

Unfortunately in 6.X zoneInfo is the old InstanceID. So i had to work around this and delay my function so that the correct InstanceID was returned.

thought that would be nice to know

semlar 09-21-14 10:23 AM

EJ_GetCurrentInstance relies on what the world map is set to, you may have to call SetMapToCurrentZone() beforehand for accurate results.

cremetorte 09-21-14 12:05 PM

thank you, it works and honestly i think it fits better than my workaround.

just for my information: where do you get such knowledge ? i mean that some Events rely on other functions to provide correct data

semlar 09-21-14 12:16 PM

I only know that it relies on the map through experimentation when I was working on an addon that used encounter journal functions.

I tried a few maps without EJ bosses on them and they all return 0 for the instance, then when I opened the map to valley of the four winds it returned 322 because it has a world boss on it.


All times are GMT -6. The time now is 10:41 AM.

vBulletin © 2024, Jelsoft Enterprises Ltd
© 2004 - 2022 MMOUI