Work on Ascension Backport

This commit is contained in:
andrew6180
2024-05-17 15:08:08 -07:00
parent 5de2a04b8c
commit bb7e0d2c27
325 changed files with 26995 additions and 41741 deletions
@@ -1,42 +1,42 @@
DETAILS_STORAGE_VERSION = 6
function Details:CreateStorageDB()
DetailsDataStorage = {
VERSION = DETAILS_STORAGE_VERSION,
[14] = {}, --normal mode (raid)
[15] = {}, --heroic mode (raid)
[16] = {}, --mythic mode (raid)
["mythic_plus"] = {}, --(dungeons)
["saved_encounters"] = {}, --(a segment)
}
return DetailsDataStorage
end
local f = CreateFrame("frame", nil, UIParent)
f:Hide()
f:RegisterEvent("ADDON_LOADED")
f:SetScript("OnEvent", function(self, event, addonName)
if (addonName == "Details_DataStorage") then
DetailsDataStorage = DetailsDataStorage or Details:CreateStorageDB()
DetailsDataStorage.Data = {}
print("loaded...")
if (DetailsDataStorage.VERSION < DETAILS_STORAGE_VERSION) then
print("is outdated")
--> do revisions
if (DetailsDataStorage.VERSION < 6) then
print("outdated two, data wiped!")
table.wipe(DetailsDataStorage)
DetailsDataStorage = Details:CreateStorageDB()
end
end
if (Details and Details.debug) then
print("|cFFFFFF00Details! Storage|r: loaded!")
end
DETAILS_STORAGE_LOADED = true
end
end)
DETAILS_STORAGE_VERSION = 6
function Details:CreateStorageDB()
DetailsDataStorage = {
VERSION = DETAILS_STORAGE_VERSION,
[14] = {}, --normal mode (raid)
[15] = {}, --heroic mode (raid)
[16] = {}, --mythic mode (raid)
["mythic_plus"] = {}, --(dungeons)
["saved_encounters"] = {}, --(a segment)
}
return DetailsDataStorage
end
local f = CreateFrame("frame", nil, UIParent)
f:Hide()
f:RegisterEvent("ADDON_LOADED")
f:SetScript("OnEvent", function(self, event, addonName)
if (addonName == "Details_DataStorage") then
DetailsDataStorage = DetailsDataStorage or Details:CreateStorageDB()
DetailsDataStorage.Data = {}
print("loaded...")
if (DetailsDataStorage.VERSION < DETAILS_STORAGE_VERSION) then
print("is outdated")
--> do revisions
if (DetailsDataStorage.VERSION < 6) then
print("outdated two, data wiped!")
table.wipe(DetailsDataStorage)
DetailsDataStorage = Details:CreateStorageDB()
end
end
if (Details and Details.debug) then
print("|cFFFFFF00Details! Storage|r: loaded!")
end
DETAILS_STORAGE_LOADED = true
end
end)