- global profiles got a revamp, now you can select which profile is used on all characters.

- you also can overwrite the global profile on any ton by just selecting a profile for that character.
This commit is contained in:
Tercioo
2016-02-08 15:02:06 -02:00
parent efbe5a9945
commit 742dd3983d
6 changed files with 203 additions and 67 deletions
+18 -2
View File
@@ -320,10 +320,26 @@ function _detalhes:LoadConfig()
--> profile
local unitname = UnitName ("player")
--> fix for old versions
if (type (_detalhes.always_use_profile) == "string") then
_detalhes.always_use_profile_name = _detalhes.always_use_profile
_detalhes.always_use_profile = true
end
--> check for "always use this profile"
if (_detalhes.always_use_profile and type (_detalhes.always_use_profile) == "string") then
_detalhes_database.active_profile = _detalhes.always_use_profile
if (_detalhes.always_use_profile and not _detalhes.always_use_profile_exception [unitname]) then
local profile_name = _detalhes.always_use_profile_name
if (profile_name and _detalhes:GetProfile (profile_name)) then
_detalhes_database.active_profile = profile_name
end
end
--> old version
-- if (_detalhes.always_use_profile and type (_detalhes.always_use_profile) == "string") then
-- _detalhes_database.active_profile = _detalhes.always_use_profile
-- end
--> character first run
if (_detalhes_database.active_profile == "") then