Total-RP / Storyline

A World of Warcraft add-on that improves the questing experience by replacing the default dialog frame by a more immersive frame with 3D models.
https://www.curseforge.com/wow/addons/storyline
14 stars 6 forks source link

Fix for weekly reputation quests #72

Closed Solanya closed 3 years ago

Solanya commented 3 years ago

Main focus of this PR is fixing the reputation choice for the weekly dungeon quests (and WQ event quest). I added the reward types directly to the currency reward arrays (similar to what was done in the items and currency objective ones) and am using those in the decorateCurrencyButton directly, so that currency choice buttons have a self.type == "choice" (previously was reward, which meant the test would fail).

The added condition on HandleModifiedItemClick is to avoid randomly showing the dressing room when Ctrl-clicking a currency, it'll just select it instead as if no modifier was used.

Finally, the added itemButtonsCount variable is there to fix the button names all being the same (as the array is not really 1D, the # operator didn't really count the amount of buttons already created, so I opted to keep count manually). It was only fixed because I thought it might have been part of the issue, but ended up being unrelated, but heh.

Andomar48 commented 3 years ago

Just tested with Trading Favors: Plaguefall and it works! Thanks for fixing this.