Rarity

Rarity

17M Downloads

Fake achievement popups contain a duplicate icon after the 9.1 update

rdw-software opened this issue ยท 3 comments

commented

Source: Discord

got a bit lucky this morning and noticed that the achievement display seems to be a bit off after the 9.1 release duplicating the icon on the right hand side

commented

They changed how the achievement popup works: https://www.townlong-yak.com/framexml/live/AlertFrameSystems.lua#297

The copy/paste monstrosity Rarity uses is no longer compatible; particularly they're using a texture atlas explicitly now and assign the texture to its corners, similar to how frames are positioned. We used the texture coordinates directly, which apparently no longer works.

Also, the patch notes said something about supporting two lines of text in the achievement toast. I need to look into this more, but it should be possible to adapt our achievement toast to do whatever it is they're doing once I understand how it works.

commented

We're looking at understanding two variations of the same function here, each being approximately 90-100 LOC. Since both are equally poorly written but not overly long, the best approach should be to refactor both and then apply the difference in the texture assignment parts to our cleaned-up version. It shouldn't be a significant change once it's isolated.

While I can make out what parts to change (roughly) right now, I fear there will be unexpected side effects if I ignore the rest, since it's rather convoluted and interwoven. So... This will have to wait for another day. I'm sure looking at it with fresh eyes will give me a better idea of what their spaghetti code is really doing.

commented

I managed to remove the duplicate icon; apparently the textures were changed and so the coordinates we assigned were simply off. The background has also doubled in size, but since that's the standard achievement frame look & feel now (to account for long achievement names), and we have many items with long items as well, I'll leave it as-is.

The alternative would be to ship the old texture with the addon, but then it might look off. I prefer the consistency, though, so I won't be doing that.