WoWInterface

WoWInterface (https://www.wowinterface.com/forums/index.php)
-   General Authoring Discussion (https://www.wowinterface.com/forums/forumdisplay.php?f=20)
-   -   Login/reload event order (https://www.wowinterface.com/forums/showthread.php?t=49821)

Duugu 08-30-14 08:35 PM

Login/reload event order
 
Hey all

I've discovered a strange behavior with the event order during the login/load process.
A simple addon with only one frame and the events below registered does fire the events in different orders.

Login in while out of combat and /reload in combat:
VARIABLES_LOADED
PLAYER_LOGIN
PLAYER_ENTERING_WORLD
SPELLS_CHANGED

So far so good.

Login in while in combat:
SPELLS_CHANGED
PLAYER_LOGIN
PLAYER_ENTERING_WORLD
PLAYER_REGEN_DISABLED
SPELLS_CHANGED
VARIABLES_LOADED

VARIABLES_LOADED is the last event that is fired? Wtf?

Seerah 08-30-14 08:46 PM

http://wowpedia.org/Events_that_fire...during_loading
Quote:

Since Patch 3.0.2, VARIABLES_LOADED has not been a reliable part of the addon loading process. It is now fired only in response to CVars, Keybindings and other associated "Blizzard" variables being loaded, and may therefore be delayed until after PLAYER_ENTERING_WORLD. The event may still be useful to override positioning data stored in layout-cache.txt.
/edit: if you're looking for an event that fires when your addon's saved variables have loaded, that event is ADDON_LOADED.

semlar 08-30-14 08:48 PM

VARIABLES_LOADED fires in response to cvar and keybind information becoming available, it has no set order to occur in the loading process.

Duugu 08-30-14 08:53 PM

d'oh

Such an old change. And I've not realized it it until today. :D

Thanks to both of you.

[e]
Seems as I should move from wowwiki to wowpedia.

Talyrius 08-30-14 08:59 PM

Quote:

Originally Posted by Duugu (Post 296124)
Seems as I should move from wowwiki to wowpedia.

Indeed. ;)


All times are GMT -6. The time now is 06:04 AM.

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