ElvUI does things differently than I am used to seeing. My first hurdle is that an ElVUI plugin does not have a ## SavedVariables: MyaddonDB line in the ToC. The second is an extension of a lack of an SV line. Normally I would use
Code: Select all
function EPDBC:Initialize()
LEP:RegisterPlugin(addonName, EPDBC.InsertOptions)
EPDBC:StartUp()
end
function EPDBC:InsertOptions()
if E.Options.args.EPDBC == nil then
E.Options.args.EPDBC = EPDBC:GetOptions()
E.Options.args.EPDBC.profiles = LibStub("AceDBOptions-3.0"):GetOptionsTable(self.db)
end
end
But of course, without the SV line, self.db is meaningless. I tried looking at BenikUI's code, but couldn't figure it out, other than nodding to myself that it is very different. How is this done with ElvUI?