View Single Post
10-26-22, 06:27 AM   #1
Pandabull
A Defias Bandit
Join Date: Oct 2022
Posts: 3
WoW 10.0 - GUILDBANKFRAME_OPENED/CLOSED Events

::EDIT::
I have found the C_GuildBank list, but it just shows the events still exist, the game just doesnt fire them anymore when opening and closing the guild bank.



Hi All,

I am a little bit lost. I have a mod that I am maintaining that needs to know when the Guild Bank frame is opened and closed (it's a guild tax mod). Previously in 9.2.7 the game would always fire GUILDBANKFRAME_OPENED when the guild bank is opened and GUILDBANKFRAME_CLOSED when the guild bank frame is closed.

I hooked to those events because I found checking if the guild bank frame was visible was very unreliable as many addons that change the guild bank frame might also change its name (I found this for either bartender4 or Bagnon I cant remember which).

Since 10.0.0 however those events still appear to exist as I can still register for them without getting an error, also they are not on the below list as removed.

https://wowpedia.fandom.com/wiki/Pat....0/API_changes

However suddenly the game just doesnt fire those events when the guild bank opens. I have noticed that it does fire ADDON_LOADED with arg[1] being Blizzard_GuildBankUI, but if a mod overrides the default guild bank frame that likely wont fire off anymore. It also appears to always fire GUILDBANKBAGSLOTS_CHANGED every time the guild bank is opened. But nothing is fired when it closes

So now I have no idea how to reiably hook up to knowing when the guild bank is opened or closed as if I use the GuildBankFrame:IsVisible() check, if there is a mod that has replaced the default that will not work as the frame is likely a different name.

Does anyone have any clues as to how to reliably detect when the guild bank is opened and closed?

Once I get this part fixed I will likely upload it to Curse or WoWInterface (or both). For those who might want to see what the addon currently looks like, I have attached 2 screengrabs. It supports communication through the addon channel for officers to see players other than themselves tax status, auto deposit on bank open with prompt, paying outstanding taxes for a character you deleted or left the guild on (from a character in the guild still obviously). It calculates tax from loot, quest rewards, vendor sales, and AH sales. It also supports offering a player that cannot afford their tax to pay an instalment instead (based off a set percent of the character's current gold total). The rate and instalment percentages are configured using the guild info, or can be overriden by officers that can edit the Officer Note of any one player with different values.

Anyway, I would really appreciate some assistance if anyone know the new way in 10.0.0 how to reliably detect the guild bank opening and closing. For instance, I am fairly new to addon coding, and I have not really played with the C_ functions and the G_ globals, so I am not sure if it could be reflected anywhere in those as I am yet to find a list of those functions to look through.

Thanks in advance.
Attached Thumbnails
Click image for larger version

Name:	TBG-Main.PNG
Views:	137
Size:	559.5 KB
ID:	9753  Click image for larger version

Name:	TBG-Audit.PNG
Views:	83
Size:	438.8 KB
ID:	9754  

Last edited by Pandabull : 10-26-22 at 06:54 AM. Reason: Found C_GuildBank list.
  Reply With Quote