coa.28: fix login scan in 9 DataStore modules (the 'data not saved' root cause)
release / release (push) Successful in 5s
release / release (push) Successful in 5s
Quests, Achievements, Reputations, Pets, Stats, Skills, Crafts, Spells, Talents all had the ghost-gated PLAYER_ALIVE scan (DEBUG 2025-07-21 leftover): they only scanned when the player died and released spirit, so their data never populated on a normal login. Now scan once per session at login (addon.coaScannedThisSession guard), matching the earlier DataStore_Characters/_Inventory fix. This is why reputations/recipes/quests/pets/etc were 'not saved'.
This commit is contained in:
@@ -338,7 +338,7 @@ function addon:OnEnable()
|
||||
-- CoA: use a Lua constant, not GetAddOnMetadata — TOC metadata is cached at game launch
|
||||
-- and does NOT refresh on /reload, so the .toc version looked stale ("still .18"). A Lua
|
||||
-- constant re-evaluates on every /reload, giving a truthful loaded-code version. Bump with the .toc.
|
||||
AltoholicFrameName:SetText("Altoholic |cFFFFFFFF3.3.002b-coa.27|r")
|
||||
AltoholicFrameName:SetText("Altoholic |cFFFFFFFF3.3.002b-coa.28|r")
|
||||
|
||||
local realm = GetRealmName()
|
||||
local player = UnitName("player")
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
## Author: Thaoky, Telkar-RG
|
||||
## X-Edited-By: Exiles (Sub-Net) — florian.berthold@sub-net.at
|
||||
## Version: 3.3.002b-coa.27
|
||||
## Version: 3.3.002b-coa.28
|
||||
## X-Category: Inventory, Tradeskill, Mail
|
||||
## X-Localizations: enUS, frFR, zhCN, zhTW, deDE, koKR, esES, esMX, ruRU
|
||||
## X-Website: http://wow.curse.com/downloads/wow-addons/details/altoholic.aspx
|
||||
|
||||
@@ -235,7 +235,8 @@ end
|
||||
-- *** EVENT HANDLERS ***
|
||||
function addon:PLAYER_ALIVE()
|
||||
-- print("DataStore_Achievements.lua") -- DEBUG 2025 07 21
|
||||
if not UnitIsGhost("player") then return end -- only scan if player released spirit and went to graveyard
|
||||
if addon.coaScannedThisSession then return end -- CoA: scan once at login (was ghost-gated, so data never saved on a normal login - the cause of "data not saved")
|
||||
addon.coaScannedThisSession = true
|
||||
|
||||
ScanAllAchievements()
|
||||
ScanProgress()
|
||||
|
||||
@@ -546,7 +546,8 @@ end
|
||||
-- *** Event Handlers ***
|
||||
local function OnPlayerAlive()
|
||||
-- print("DataStore_Crafts.lua") -- DEBUG 2025 07 21
|
||||
if not UnitIsGhost("player") then return end -- only scan if player released spirit and went to graveyard
|
||||
if addon.coaScannedThisSession then return end -- CoA: scan once at login (was ghost-gated, so data never saved on a normal login - the cause of "data not saved")
|
||||
addon.coaScannedThisSession = true
|
||||
|
||||
ScanProfessionLinks()
|
||||
end
|
||||
|
||||
@@ -46,7 +46,8 @@ end
|
||||
-- *** Event Handlers ***
|
||||
local function OnPlayerAlive()
|
||||
-- print("DataStore_Pets.lua") -- DEBUG 2025 07 21
|
||||
if not UnitIsGhost("player") then return end -- only scan if player released spirit and went to graveyard
|
||||
if addon.coaScannedThisSession then return end -- CoA: scan once at login (was ghost-gated, so data never saved on a normal login - the cause of "data not saved")
|
||||
addon.coaScannedThisSession = true
|
||||
|
||||
ScanCompanions("CRITTER")
|
||||
ScanCompanions("MOUNT")
|
||||
|
||||
@@ -177,7 +177,8 @@ end
|
||||
-- *** Event Handlers ***
|
||||
local function OnPlayerAlive()
|
||||
-- print("DataStore_Quests.lua") -- DEBUG 2025 07 21
|
||||
if not UnitIsGhost("player") then return end -- only scan if player released spirit and went to graveyard
|
||||
if addon.coaScannedThisSession then return end -- CoA: scan once at login (was ghost-gated, so data never saved on a normal login - the cause of "data not saved")
|
||||
addon.coaScannedThisSession = true
|
||||
|
||||
ScanQuests()
|
||||
end
|
||||
|
||||
@@ -177,7 +177,8 @@ end
|
||||
-- *** EVENT HANDLERS ***
|
||||
function addon:PLAYER_ALIVE()
|
||||
-- print("DataStore_Reputations.lua") -- DEBUG 2025 07 21
|
||||
if not UnitIsGhost("player") then return end -- only scan if player released spirit and went to graveyard
|
||||
if addon.coaScannedThisSession then return end -- CoA: scan once at login (was ghost-gated, so data never saved on a normal login - the cause of "data not saved")
|
||||
addon.coaScannedThisSession = true
|
||||
|
||||
ScanReputations()
|
||||
end
|
||||
|
||||
@@ -239,7 +239,8 @@ end
|
||||
-- *** EVENT HANDLERS ***
|
||||
function addon:PLAYER_ALIVE()
|
||||
-- print("DataStore_Skills.lua") -- DEBUG 2025 07 21
|
||||
if not UnitIsGhost("player") then return end -- only scan if player released spirit and went to graveyard
|
||||
if addon.coaScannedThisSession then return end -- CoA: scan once at login (was ghost-gated, so data never saved on a normal login - the cause of "data not saved")
|
||||
addon.coaScannedThisSession = true
|
||||
|
||||
ScanSkills()
|
||||
end
|
||||
|
||||
@@ -105,7 +105,8 @@ end
|
||||
-- *** EVENT HANDLERS ***
|
||||
function addon:PLAYER_ALIVE()
|
||||
-- print("DataStore_Spells.lua") -- DEBUG 2025 07 21
|
||||
if not UnitIsGhost("player") then return end -- only scan if player released spirit and went to graveyard
|
||||
if addon.coaScannedThisSession then return end -- CoA: scan once at login (was ghost-gated, so data never saved on a normal login - the cause of "data not saved")
|
||||
addon.coaScannedThisSession = true
|
||||
|
||||
ScanSpells()
|
||||
end
|
||||
|
||||
@@ -156,7 +156,8 @@ end
|
||||
-- *** EVENT HANDLERS ***
|
||||
function addon:PLAYER_ALIVE()
|
||||
-- print("DataStore_Stats.lua") -- DEBUG 2025 07 21
|
||||
if not UnitIsGhost("player") then return end -- only scan if player released spirit and went to graveyard
|
||||
if addon.coaScannedThisSession then return end -- CoA: scan once at login (was ghost-gated, so data never saved on a normal login - the cause of "data not saved")
|
||||
addon.coaScannedThisSession = true
|
||||
|
||||
ScanStats()
|
||||
end
|
||||
|
||||
@@ -419,7 +419,8 @@ end
|
||||
-- *** EVENT HANDLERS ***
|
||||
function addon:PLAYER_ALIVE()
|
||||
-- print("DataStore_Talents.lua") -- DEBUG 2025 07 21
|
||||
if not UnitIsGhost("player") then return end -- only scan if player released spirit and went to graveyard
|
||||
if addon.coaScannedThisSession then return end -- CoA: scan once at login (was ghost-gated, so data never saved on a normal login - the cause of "data not saved")
|
||||
addon.coaScannedThisSession = true
|
||||
|
||||
ScanTalents()
|
||||
ScanTalentReference()
|
||||
|
||||
Reference in New Issue
Block a user