Ace3 DB Profile not copying over existing values
Hello!
I'm trying to finish up my addon with adding profile functionality and I'm pretty sure it's almost good too. The only issue is when I use the copy profile functionality, the values from the profile I'm trying to copy from aren't being applied to the profile of the character that's currently logged in. core.lua Lua Code:
config.lua Lua Code:
defaults.lua Lua Code:
Any ideas? |
EDIT: Sorry, forgot to add the contents of my defaults.lua file.
EDIT2: I think I'm now realizing my error in that I was using Ace3.db.char when I should have been using Ace3.db.profile. Though, I'm noticing that it's not creating a profile for each character I logon to automatically anymore and just using "Default". I also have to reload my UI when I added a new profile for my addon to read it. EDIT3: I fixed EDIT2's issue by removing "true" from Line 8 in core.lua. However, I'm noticing an error that's occurring when loading the addon for the first time and the SavedVariables file doesn't exist yet where it's saying that there's an error trying to load said file. Reloading the UI fixes the issue, but that shouldn't be required to do. Any ideas why that's happening? |
Your functions are stored in the Ace3 namespace.
They should be in your own? Edit: ups, nvm I See Ace3 is local for you. But I'd guess this might kick you in the but somewhere. |
AceDB-3.0 only writes to the saved variables if the user makes a change from the default value; otherwise it is a series of mostly empty tables.
I do not see an options table being registered, and why are you registering your profiles like that? That is very weird. |
All times are GMT -6. The time now is 11:32 PM. |
vBulletin © 2024, Jelsoft Enterprises Ltd
© 2004 - 2022 MMOUI