diff --git a/Vect.lua b/Vect.lua index cfe26e5..dcee7ce 100644 --- a/Vect.lua +++ b/Vect.lua @@ -38,6 +38,7 @@ Vect.defaults = { spellAuraDebug = false, allCDebug = false, selfCDRegister = false, + specdetection = false, target = { enabled = true, size = 27, diff --git a/Vect.toc b/Vect.toc index 95bec68..9238aad 100644 --- a/Vect.toc +++ b/Vect.toc @@ -6,7 +6,7 @@ ## DefaultState: Enabled ## OptionalDeps: Ace3 ## SavedVariables: VectDB -## Version: 0.75 +## Version: 0.9 embeds.xml data\global.lua diff --git a/data/options.lua b/data/options.lua index fde8b65..9ce963b 100644 --- a/data/options.lua +++ b/data/options.lua @@ -72,6 +72,18 @@ function Vect:SetDRPartEnabledOrDisabled(which, enable) end end +function Vect:isSpecDetectionEnabled() + local db = Vect.db.profile; + return db["specdetection"]; +end + +function Vect:setSpecDetectionEnabledorDisabled(enable) + local db = Vect.db.profile; + db["specdetection"] = enable; + --call the remapcooldowns, and then update + --self:ReassignCds(which); +end + --lock function Vect:isLocked() return Vect.db.profile["locked"]; diff --git a/data/optiontable.lua b/data/optiontable.lua index d745496..4cd9706 100644 --- a/data/optiontable.lua +++ b/data/optiontable.lua @@ -141,6 +141,16 @@ function Vect:getTargetandFocusOptions() set = function(_, v) Vect:setSortOrder("focus", v); end + }, + globalHeader = { + type = "header", name = "Global settings", order = 20 + }, + specdetectiontoggle = { + type = "toggle", name = "Spec Detection", desc = "Enable/Disable Spec Detection", order = 21, + get = function() return Vect:isSpecDetectionEnabled() end, + set = function(_, v) + Vect:setSpecDetectionEnabledorDisabled(v); + end } } return args;