View Single Post
03/06/17, 10:30 PM   #3
Phinix
 
Phinix's Avatar
AddOn Author - Click to view addons
Join Date: Apr 2014
Posts: 186
The version number on your saved variable declaration should only change when you have made significant changes to the data format and WANT the user's saved variables to reset. This is the version of your saved vars database and is separate from your addon version. You will rarely if ever need to change this. Every time you do, the addon's saved variables will reset on the next load. (Actually all the old settings are still there in the same saved variables file under the old version number.)

To use Dungeon Tracker as an example, change this when you update:
Code:
local DTAddon = _G['DTAddon']
local L = DTAddon:GetLanguage()
DTAddon.Name = 'DungeonTracker'
DTAddon.Author = '|c66ccffPhinix|r'
DTAddon.Version = '1.02a'
Don't change this unless you WANT saved vars to reset:
Code:
DTAddon.SV = ZO_SavedVars:New(DTAddon.Name, 1.0, 'CharacterSettings', DTAddon.SVarDefaultC)
DTAddon.ASV = ZO_SavedVars:NewAccountWide(DTAddon.Name, 1.0, 'AccountSettings', DTAddon.SVarDefaultA)
Also remember to update the version in your manifest .txt file. You don't even technically NEED a version number in your LUA files anywhere.

Last edited by Phinix : 03/06/17 at 10:34 PM.
  Reply With Quote