diff --git a/mods/dark-ui-elements.lua b/mods/dark-ui-elements.lua index 0847b2b..1236c2c 100644 --- a/mods/dark-ui-elements.lua +++ b/mods/dark-ui-elements.lua @@ -119,6 +119,9 @@ local function AddSpecialBackground(frame, w, h, x, y) end local function DarkenFrame(frame, r, g, b, a) + -- dont't do anything if disabled + if not ShaguTweaks.DarkMode then return end + -- set defaults if not r and not g and not b then r, g, b, a = module.color.r, module.color.g, module.color.b, module.color.a @@ -167,6 +170,9 @@ local function DarkenFrame(frame, r, g, b, a) end end +-- register darken frame to global +ShaguTweaks.DarkenFrame = DarkenFrame + module.enable = function(self) local name, original, r, g, b local hookBuffButton_Update = BuffButton_Update