View Single Post
04/27/22, 02:03 AM   #2
Baertram
Super Moderator
 
Baertram's Avatar
WoWInterface Super Mod
AddOn Author - Click to view addons
Join Date: Mar 2014
Posts: 4,991
Not that I know off. There are a lot of these deferred init codings, especially in GamepadMode: Inventory lists etc. first init as you open them the 1st time

But even in keyboard mode there are some of them, like the Campaigns and the Dungeons list (Groupfinder), the worldmap (to read some POI data etc).

So you could need to add a scene/fragment StateChange callback, check for newState == SCENE(_FRAGMENT)_SHOWN and then react on it.

Maybe (meanwhile) there are some *_MANAGER globals which one is able to use to get the data by other means, like the "collectibles" got the ZO_COLLECTIBLE_DATA_MANAGER

-> CAMPAIGN_BROWSER_MANAGER (if this is the correct one, it is a ZO_Callback object so you can register a callback here too as it is doing stuff, e.g.
CAMPAIGN_BROWSER_MANAGER:RegisterCallback("OnCampaignDataUpdated", function() ... end) )


If this does not help try to open the menu of the campaigns by calling the same code that the keybind does, and then register the scene/fragment callback to see when it is finally SCENE_SHOWN -> run your code then

Last edited by Baertram : 04/27/22 at 02:08 AM.
  Reply With Quote