LibProcessable

14.8k Downloads

[Bug] enchantingBuilding is always false on PLAYER_LOGIN

Blazeflack opened this issue ยท 3 comments

commented

Version: 6
All other addons disabled: Yes.

For some reason it is not possible to iterate over C_Garrison.GetBuildings() on the PLAYER_LOGIN event. By adding print statements I've verified that C_Garrison.GetBuildings() does return a table (I did print(C_Garrison.GetBuildings()) ), but any iteration on that table seems to be completely ignored.

I tried changing the event to PLAYER_ENTERING_WORLD but that seems to suffer from the same issue.

As a result "enchantingBuilding" will always be false on initial login, even though you actually have the enchanting building. In order for the library to function correctly you need to do a /reload after logging in.

I can only imagine that Blizzard has some form of limitation in place, and if that is true then you might need to delay the iteration on C_Garrison.GetBuildings().

commented

I can verify that implementing a 5 second delay works. The delay can possibly be shorter.

commented

Test that and let me know if it works for you as well, seems like they changed something in 6.1.

commented

Yes, that seems to have fixed it.

Thank you.