#1 - 2012/07/04 07:53:00 PMI'm trying to update Swindler Preventer. I have code to scan tooltips of items available from a merchant.
When the data is not yet available, Swindler Preventer causes the game to freeze, blocking the data from becoming available and causing WoW to lock up. This doesn't happen on live (that I know of).
If the data is already available (for instance, turn off addon, log in, talk to vendor, log out, turn on addon, log in, talk to vendor again) the addon runs exactly as intended.
Here's a picture example of what I mean by the data 'not loaded yet.'
With some debug, I notice that the MERCHANT_SHOW event happens every time you talk to a vendor and open the window, but the MERCHANT_UPDATE event fires a whole lot of times when you talk to a vendor that you don't have data yet, and then the data displays. My addon is coded to begin tooltip scanning on either event, but either event will cause the 'freeze' if there is no data.
Is this the intended format for MERCHANT_SHOW and MERCHANT_UPDATE, that it fires before the data is actually available? If so, I need to put in some 'lag compensation' or something. Or is there an event I can listen for that indicates the data is now loaded?