Skip to content

Commit

Permalink
Adds support for the "/grail eraseAndReloadCompletedQuests" slash com…
Browse files Browse the repository at this point in the history
…mand.
  • Loading branch information
smaitch committed Oct 14, 2019
1 parent 15ab73d commit 623ea83
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions Grail/Grail.lua
Original file line number Diff line number Diff line change
Expand Up @@ -467,6 +467,7 @@
-- Removes call to load Blizzard_ArtifactUI since ElvUI has problems.
-- Makes it so holiday codes for quests do not cause Lua errors in Classic, though still do not work as there is no Classic calendar.
-- Adds support for Mechagnome and Vulpera races.
-- Adds support for the "/grail eraseAndReloadCompletedQuests" slash command.
--
-- Known Issues
--
Expand Down Expand Up @@ -1467,6 +1468,14 @@ experimental = false, -- currently this implementation does not reduce memory si
self.questStatuses = {}
self:_CoalesceDelayedNotification("Status", 0)
end)
self:RegisterSlashOption("eraseAndReloadCompletedQuests", "|cFF00FF00eraseAndReloadCompletedQuests|r => reloads the completed quest list from Blizzard erasing the current list", function()
GrailDatabasePlayer["completedQuests"] = {}
QueryQuestsCompleted()
-- And the following code is the same as the clearstatuses command...
wipe(self.questStatuses)
self.questStatuses = {}
self:_CoalesceDelayedNotification("Status", 0)
end)

if self.capabilities.usesAchievements then
frame:RegisterEvent("ACHIEVEMENT_EARNED") -- e.g., quest 29452 can be gotten if certain achievements are complete
Expand Down

0 comments on commit 623ea83

Please sign in to comment.