Download
(9 Kb)
Download
Updated: 10/30/23 03:43 AM
Compatibility:
Endless Archive (9.2.5)
base-game patch (9.1.5)
Necrom (9.0.0)
Scribes of Fate (8.3.5)
Firesong (8.2.5)
Lost Depths (8.1.5)
High Isle (8.0.0)
Updated:10/30/23 03:43 AM
Created:03/10/22 12:01 PM
Monthly downloads:1,453
Total downloads:55,307
Favorites:22
MD5:
LibAchievementsArchive  Popular! (More than 5000 hits)
Version: 1.2.1.3
by: code65536 [More]
Since Update 33 has been released, it is no longer possible to archive your character-specific achievements. If you had not already archived your data, this library will be of no use to you. This library now exists to provide access to the character-specific achievement data that users had archived prior to Update 33.




This is a library to efficiently archive all character-specific achievement data prior to the elimination of character-specific achievements in Update 33.


What this does... and doesn't do

This library is designed specifically for the purpose of preserving and providing access to character-specific achievement data. As such, it differs from other addons in a few ways:
  • The data is stored as efficiently as possible. The game itself stored achievement data very efficiently, packing all progress information into a single 64-bit field. Similarly, this library stores data using bitfields, resulting in efficient long-term storage of this data.
  • This is a library, and as such, it provides functions that other addons can use to access archived data. It does not make any changes to the user interface or provide any user interface of its own. The intent is for this library to comprehensively archive the data and make this data easily accessible for use by other addons that may come along in the future.


List of addons that can use this library

For addon developers

Please read the LibAchievementsArchive Developer Reference. For sample code, the Historical Achievement Credit addon is a relatively simple addon that demonstrates both the usage of LibAchievementsArchive and the modification of the non-gamepad achievements UI.


How do I archive my data?

Simply install this library and log into each character prior to Update 33. Each character's achievement data will be scanned when you log onto that character and whenever that character makes any progress with an achievement. The process is instant (takes a small fraction of a second to complete), silent (you will not see any messages about it), and seamless.

For obvious reasons, this achievement scanning feature will automatically disable itself after Update 33's release, after which point, the data will no longer be updated or changed.

It is recommended that users make a backup for their LibAchievementsArchive.lua file found in their SavedVariables folder, as there is no way to reacquire this data if it is somehow lost (e.g., due to hardware failure, etc.) after Update 33 has gone live.
  • Version 1.2.1 (2022/03/14)
    • LibAchievementsArchive will now fail more gracefully and not generate a Lua error if an addon tries to use it before it has fully loaded

  • Version 1.2.0 (2022/03/13)
    • For addon developers: GetValidCharacterIds can now be called with an optional onlyCurrentServerAndAccount parameter

  • Version 1.1.0 (2022/03/11)
    • For addon developers: GetCharacterInformation will now assume the current character's ID if none is supplied

  • Version 1.0.0 (2022/03/10)
    • Initial version
Optional Files (0)


Archived Files (6)
File Name
Version
Size
Uploader
Date
1.2.1.2
9kB
code65536
03/11/23 07:53 AM
1.2.1.1
9kB
code65536
09/24/22 04:23 PM
1.2.1
9kB
code65536
03/14/22 09:12 AM
1.2.0
9kB
code65536
03/13/22 07:04 AM
1.1.0
8kB
code65536
03/11/22 10:12 AM
1.0.0
7kB
code65536
03/10/22 12:01 PM


Post A Reply Comment Options
Unread 03/14/22, 10:24 AM  
[Daniel]

Forum posts: 1
File comments: 133
Uploads: 0
Originally Posted by code65536
So, the problem here is that silvereyes' Character Achievements is working by overriding the game's existing achievement functions. This is a dangerous thing to do, since it means that every addon that accesses the game's achievements is suddenly using LAA without realizing that they are, and on top of that, CA is doing the function override when CA's files are read, and not waiting for an addon loaded event.
Ah-ha! That's good thinking!

I relogged into the game after disabling CA, but keeping LAA enabled... and no issues/errors!

Should I post some of this discussion over in the CA comments, or might you have a more direct communication path with silvereyes?

EDIT:
I did post there, and after your LAA update and a CA update, no more errors and addons are working well.
Last edited by [Daniel] : 03/14/22 at 11:19 AM.
Report comment to moderator  
Reply With Quote
Unread 03/14/22, 10:17 AM  
code65536
AddOn Author - Click to view AddOns

Forum posts: 21
File comments: 371
Uploads: 40
Originally Posted by [Daniel
]
Originally Posted by code65536
That means some addon tried to use LAA before LAA had fully loaded, since it tried to access something that LAA initializes only after LAA receives its EVENT_ADD_ON_LOADED event. I can add a check to make have it fail more gracefully in this event.
Thank you for looking into this! Some additional feedback post login.

Would the failing gracefully allow these 4 addons to load? Two examples:

1) When I try show RareFisherTracker UI, it triggers another popup (I assume because it has no data to work with)

2) Whereas Skyshards didn't even load/start at all... as I no longer see skyshards on the Cyrodyl map, no longer have skyshard filters on the map, and no longer see Skyshards in the "Addon Settings" section.

I thought maybe I could /reloadui now that everything was loaded... but it just repeated the errors after restarting the addons from scratch.

EDIT 1:
Is there a way to make your library load first? Hmm, but even if that were doable, that wouldn't guarantee your library would have completed it's loading. Hmm, might need to look into addon managers... maybe there is a way to load a base set, and then load more afterwards without a /reloadui?

EDIT 2:
I thought I'd try disabling LibAchievementArchive to see what would happen, and upon a /reloadui there were no error popups, the fish tracker UI loaded on toggle, and skyshards behaved normally in all respects.
So, the problem here is that silvereyes' Character Achievements is working by overriding the game's existing achievement functions. This is a dangerous thing to do, since it means that every addon that accesses the game's achievements is suddenly using LAA without realizing that they are, and on top of that, CA is doing the function override when CA's files are read, and not waiting for an addon loaded event.
Report comment to moderator  
Reply With Quote
Unread 03/14/22, 09:26 AM  
[Daniel]

Forum posts: 1
File comments: 133
Uploads: 0
Originally Posted by code65536
That means some addon tried to use LAA before LAA had fully loaded, since it tried to access something that LAA initializes only after LAA receives its EVENT_ADD_ON_LOADED event. I can add a check to make have it fail more gracefully in this event.
Thank you for looking into this! Some additional feedback post login.

Would the failing gracefully allow these 4 addons to load? Two examples:

1) When I try show RareFisherTracker UI, it triggers another popup (I assume because it has no data to work with)
stack traceback:
user:/AddOns/RareFishTracker/RareFishWindow100017.lua:645: in function 'RFT.ToggleWindow'
:1: in function '(main chunk)'\n<Locals> keybind = \"RARE_FISH_TRACKER_TOGGLE\" </Locals>
2) Whereas Skyshards didn't even load/start at all... as I no longer see skyshards on the Cyrodyl map, no longer have skyshard filters on the map, and no longer see Skyshards in the "Addon Settings" section.

I thought maybe I could /reloadui now that everything was loaded... but it just repeated the errors after restarting the addons from scratch.

EDIT 1:
Is there a way to make your library load first? Hmm, but even if that were doable, that wouldn't guarantee your library would have completed it's loading. Hmm, might need to look into addon managers... maybe there is a way to load a base set, and then load more afterwards without a /reloadui?

EDIT 2:
I thought I'd try disabling LibAchievementArchive to see what would happen, and upon a /reloadui there were no error popups, the fish tracker UI loaded on toggle, and skyshards behaved normally in all respects.
Last edited by [Daniel] : 03/14/22 at 10:13 AM.
Report comment to moderator  
Reply With Quote
Unread 03/14/22, 09:07 AM  
code65536
AddOn Author - Click to view AddOns

Forum posts: 21
File comments: 371
Uploads: 40
Originally Posted by [Daniel
]post update, I am receiving four error popups upon loading into my characters... the errors all start with "/AddOns/LibAchievementsArchive/Internal.lua:219: attempt to index a nil value", but reference other addons... for example, here is the complete message for RareFishTracker:


The other addons I am receiving similar error-popups for are DungeonTracker, SkyShards, and Urich's Skill Point Finder. I can provide error popup details for all the involved addons if that would be helpful, but thought I'd conserve space here.

Is this an issue with LibAchievementsArchive, or that these four addons require updates to allow them to work with the new "global achievements" and/or to work with LibAchievementsArchive?

It was odd to find SkyShards because my understanding is that these ramained per character achievements.
That means some addon tried to use LAA before LAA had fully loaded, since it tried to access something that LAA initializes only after LAA receives its EVENT_ADD_ON_LOADED event. I can add a check to make have it fail more gracefully in this event.
Report comment to moderator  
Reply With Quote
Unread 03/14/22, 09:01 AM  
[Daniel]

Forum posts: 1
File comments: 133
Uploads: 0
post update, I am receiving four error popups upon loading into my characters... the errors all start with "/AddOns/LibAchievementsArchive/Internal.lua:219: attempt to index a nil value", but reference other addons... for example, here is the complete message for RareFishTracker:
stack traceback:
user:/AddOns/LibAchievementsArchive/Internal.lua:219: in function 'Internal.DecodeCharacterData'
<Locals> charId = 8796093045922199 </Locals>
user:/AddOns/LibAchievementsArchive/Internal.lua:309: in function 'Internal.ReadData'
<Locals> charId = 8796093045922199, achievementId = 471, result = [table:1]{progress = 0, timestamp = 0}, key = [table:2]{1 = 1} </Locals>
user:/AddOns/LibAchievementsArchive/Public.lua:23: in function 'Public.ArchivedIsAchievementComplete'
<Locals> charId = 8796093045922199, achievementId = 471 </Locals>
user:/AddOns/CharacterAchievements/classes/Data.lua:80: in function 'Data:GetInfo'
<Locals> self = [table:3]{}, achievementId = 471, name = \"Glenumbra Angler\", description = \"Catch all 12 rare fish in Glen...\", points = 5, icon = \"/esoui/art/icons/crafting_slau...\", completed = F, date = \"\", time = \"\" </Locals>
(tail call): ?
user:/AddOns/RareFishTracker/RareFishTracker100017.lua:70: in function 'RFT.ScanAchievementsById'
<Locals> id = 471 </Locals>
user:/AddOns/RareFishTracker/RareFishTracker100017.lua:221: in function 'RFT.Init'
<Locals> commonDefaults = [table:4]{}, tracked = [table:5]{471 = T}, _ = 3, achs = [table:6]{1 = 471}, _ = 1, ach = 471 </Locals>
user:/AddOns/RareFishTracker/RareFishTracker100017.lua:241: in function '(anonymous)'
<Locals> event = 65536, addon = \"RareFishTracker\" </Locals>
The other addons I am receiving similar error-popups for are DungeonTracker, SkyShards, and Urich's Skill Point Finder. I can provide error popup details for all the involved addons if that would be helpful, but thought I'd conserve space here.

Is this an issue with LibAchievementsArchive, or that these four addons require updates to allow them to work with the new "global achievements" and/or to work with LibAchievementsArchive? If so, it's odd to find SkyShards having issues because my understanding is that these remained per character achievements... but that doesn't mean ESO/ZOS didn't introduce changes to not make it happy.
Last edited by [Daniel] : 03/14/22 at 09:08 AM.
Report comment to moderator  
Reply With Quote
Unread 03/14/22, 06:26 AM  
silvereyes
 
silvereyes's Avatar
AddOn Author - Click to view AddOns

Forum posts: 66
File comments: 384
Uploads: 17
Re: How can we see our stored data ?

Originally Posted by Rishikesa108
If I install the library and the related addon, if I log in & out all my characters... how shall I see my character history after Update 33 ? How can I use the stored data ? Thanks
The related addon shows backed up data right in the journal UI in-game. If the current character completed the achievement and was archived by LibAchievementsArchive, then that achievement shows up as a character-specific achievement in Update 33 when the Character Achievements addon is installed.
Report comment to moderator  
Reply With Quote
Unread 03/13/22, 06:23 PM  
code65536
AddOn Author - Click to view AddOns

Forum posts: 21
File comments: 371
Uploads: 40
Re: How can we see our stored data ?

Originally Posted by Rishikesa108
If I install the library and the related addon, if I log in & out all my characters... how shall I see my character history after Update 33 ? How can I use the stored data ? Thanks
This library just preserves the data and makes that data available in a way that's usable by other addons.

At the moment, there isn't much in the way of showing this data in a friendly way to users--silvereyes' addon is currently the only front-end available--largely because writing those kinds of front-ends take time, but because of the time-sensitive nature of the backing up of the data, getting the back-end released took priority.

And if you are comfortable with Lua code, you could use this library's APIs (documented in the dev reference) to manually look up each character's data.
Report comment to moderator  
Reply With Quote
Unread 03/13/22, 05:13 PM  
Rishikesa108

Forum posts: 9
File comments: 40
Uploads: 0
How can we see our stored data ?

If I install the library and the related addon, if I log in & out all my characters... how shall I see my character history after Update 33 ? How can I use the stored data ? Thanks
Report comment to moderator  
Reply With Quote
Unread 03/13/22, 04:17 PM  
baratron

Forum posts: 1
File comments: 30
Uploads: 0
Originally Posted by code65536
The information is stored based on each character's unique numeric ID, which are unique across servers (every NA character has an ID that starts with 8796, and every EU character has an ID that starts with 8798).

I personally play on multiple accounts, on both NA and EU. LibAchievementsArchive was designed from the ground up to correctly handle this sort of thing, so there's no need to worry about conflicts arising from your situation.
I see it now:
Code:
    ["characters"] = 
    {
        ["8798292046391087"] = "EU,@baratron,Alix de Feu",
        ["8796093033432515"] = "NA,@baratron,Alix de Feu",
etc.

Thank you so much for being on the ball here! I really appreciate it.
Report comment to moderator  
Reply With Quote
Unread 03/13/22, 03:58 PM  
code65536
AddOn Author - Click to view AddOns

Forum posts: 21
File comments: 371
Uploads: 40
Originally Posted by baratron
Hi, do we know what happens if a player has multiple characters of the same name? I play on both PC-NA and PC-EU, and I have three identically-named characters on each server. Since the servers no longer use separate clients, I've had a few problems with addons getting confused between the PC-NA and EU version of the character, but none of them have been important enough for me to care - THIS is genuinely important!
The information is stored based on each character's unique numeric ID, which are unique across servers (every NA character has an ID that starts with 8796, and every EU character has an ID that starts with 8798).

I personally play on multiple accounts, on both NA and EU. LibAchievementsArchive was designed from the ground up to correctly handle this sort of thing, so there's no need to worry about conflicts arising from your situation.
Last edited by code65536 : 03/13/22 at 03:59 PM.
Report comment to moderator  
Reply With Quote
Unread 03/13/22, 03:55 PM  
code65536
AddOn Author - Click to view AddOns

Forum posts: 21
File comments: 371
Uploads: 40
Originally Posted by Carande
If you deactivate the add-on, no further achievements will be logged. We are still losing any future achievements for individual toons. Am I missing something? I would like to see the individual achievements continued....and thank you for this!
That's correct. This is intended to preserve existing character-specific achievements. It's not really feasible to track new progress after AwA launches. This is really intended for people who have built a lot of history with their existing characters and want to preserve that history.
Report comment to moderator  
Reply With Quote
Unread 03/13/22, 03:41 PM  
baratron

Forum posts: 1
File comments: 30
Uploads: 0
Hi, do we know what happens if a player has multiple characters of the same name? I play on both PC-NA and PC-EU, and I have three identically-named characters on each server. Since the servers no longer use separate clients, I've had a few problems with addons getting confused between the PC-NA and EU version of the character, but none of them have been important enough for me to care - THIS is genuinely important!
Report comment to moderator  
Reply With Quote
Unread 03/13/22, 12:29 PM  
Carande

Forum posts: 4
File comments: 14
Uploads: 0
If you deactivate the add-on, no further achievements will be logged. We are still losing any future achievements for individual toons. Am I missing something? I would like to see the individual achievements continued....and thank you for this!
Report comment to moderator  
Reply With Quote
Post A Reply



Category Jump:

Support AddOn Development!

You have just downloaded by the author . If you like this AddOn why not consider supporting the author? This author has set up a donation account. Donations ensure that authors can continue to develop useful tools for everyone.