diff --git a/Modules/actionbars.lua b/Modules/actionbars.lua index 4ea524a..e66d46b 100644 --- a/Modules/actionbars.lua +++ b/Modules/actionbars.lua @@ -49,38 +49,38 @@ module.optionsTable = { type = "header", name = "Buttons", }, - extraButtons = { - order = 7, - type = "toggle", - name = "Extra Buttons", - desc = "Moves the 12th button on each of the right side actionbars down to the bottom bars. WIP: Not working yet", - width = "full", - }, + -- extraButtons = { + -- order = 7, + -- type = "toggle", + -- name = "Extra Buttons", + -- desc = "Moves the 12th button on each of the right side actionbars down to the bottom bars. WIP: Not working yet", + -- width = "full", -- WIP + -- }, hideMacroNames = { order = 8, type = "toggle", name = "Hide Macro Names", width = "full", }, - hideKeyBinds = { - order = 9, - type = "toggle", - name = "Hide Key Binds", - width = "full", - }, - shortKeybindText = { - order = 10, - type = "toggle", - name = "Short Key Bind Text", - desc = "(e.g. 'Mousewheel Up' -> 'WU')", - width = "full", - }, - altKeybindFont = { - order = 11, - type = "toggle", - name = "Alternate Key Bind Font", - width = "full", - }, + -- hideKeyBinds = { + -- order = 9, + -- type = "toggle", + -- name = "Hide Key Binds", + -- width = "full", + -- }, + -- shortKeybindText = { + -- order = 10, + -- type = "toggle", + -- name = "Short Key Bind Text", + -- desc = "(e.g. 'Mousewheel Up' -> 'WU')", + -- width = "full", + -- }, + -- altKeybindFont = { + -- order = 11, + -- type = "toggle", + -- name = "Alternate Key Bind Font", + -- width = "full", + -- }, } local eventHandler = CreateFrame("Frame", nil, UIParent) @@ -184,87 +184,87 @@ function module:OnLoad() tinsert(buttons, _G["MultiBarRightButton"..i]) end - if db.hideKeyBinds then - local function updateHotkeys(self) - self.HotKey:Hide() - end + -- if db.hideKeyBinds then + -- local function updateHotkeys(self) + -- self.HotKey:Hide() + -- end - for _, button in pairs(buttons) do - hooksecurefunc(button, "UpdateHotkeys", updateHotkeys) - end + -- for _, button in pairs(buttons) do + -- hooksecurefunc(button, "UpdateHotkeys", updateHotkeys) + -- end - hooksecurefunc("ActionButton_UpdateRangeIndicator", updateHotkeys) - hooksecurefunc("PetActionButton_SetHotkeys", updateHotkeys) - end + -- hooksecurefunc("ActionButton_UpdateRangeIndicator", updateHotkeys) + -- hooksecurefunc("PetActionButton_SetHotkeys", updateHotkeys) + -- end - if db.shortKeybindText then - local function updateHotkeys(self) - local hotkey = self.HotKey - local text = hotkey:GetText() + -- if db.shortKeybindText then + -- local function updateHotkeys(self) + -- local hotkey = self.HotKey + -- local text = hotkey:GetText() - text = gsub(text, "(s%-)", "S") - text = gsub(text, "(a%-)", "A") - text = gsub(text, "(c%-)", "C") - text = gsub(text, "(st%-)", "C") + -- text = gsub(text, "(s%-)", "S") + -- text = gsub(text, "(a%-)", "A") + -- text = gsub(text, "(c%-)", "C") + -- text = gsub(text, "(st%-)", "C") - for i = 1, 30 do - text = gsub(text, _G["KEY_BUTTON"..i], "M"..i) - end + -- for i = 1, 30 do + -- text = gsub(text, _G["KEY_BUTTON"..i], "M"..i) + -- end - for i = 1, 9 do - text = gsub(text, _G["KEY_NUMPAD"..i], "Nu"..i) - end + -- for i = 1, 9 do + -- text = gsub(text, _G["KEY_NUMPAD"..i], "Nu"..i) + -- end - text = gsub(text, KEY_NUMPADDECIMAL, "Nu.") - text = gsub(text, KEY_NUMPADDIVIDE, "Nu/") - text = gsub(text, KEY_NUMPADMINUS, "Nu-") - text = gsub(text, KEY_NUMPADMULTIPLY, "Nu*") - text = gsub(text, KEY_NUMPADPLUS, "Nu+") + -- text = gsub(text, KEY_NUMPADDECIMAL, "Nu.") + -- text = gsub(text, KEY_NUMPADDIVIDE, "Nu/") + -- text = gsub(text, KEY_NUMPADMINUS, "Nu-") + -- text = gsub(text, KEY_NUMPADMULTIPLY, "Nu*") + -- text = gsub(text, KEY_NUMPADPLUS, "Nu+") - text = gsub(text, KEY_MOUSEWHEELUP, "WU") - text = gsub(text, KEY_MOUSEWHEELDOWN, "WD") - text = gsub(text, KEY_NUMLOCK, "NuL") - text = gsub(text, KEY_PAGEUP, "PU") - text = gsub(text, KEY_PAGEDOWN, "PD") - text = gsub(text, KEY_SPACE, "_") - text = gsub(text, KEY_INSERT, "Ins") - text = gsub(text, KEY_HOME, "Hm") - text = gsub(text, KEY_DELETE, "Del") - text = gsub(text, "Capslock", "Caps") + -- text = gsub(text, KEY_MOUSEWHEELUP, "WU") + -- text = gsub(text, KEY_MOUSEWHEELDOWN, "WD") + -- text = gsub(text, KEY_NUMLOCK, "NuL") + -- text = gsub(text, KEY_PAGEUP, "PU") + -- text = gsub(text, KEY_PAGEDOWN, "PD") + -- text = gsub(text, KEY_SPACE, "_") + -- text = gsub(text, KEY_INSERT, "Ins") + -- text = gsub(text, KEY_HOME, "Hm") + -- text = gsub(text, KEY_DELETE, "Del") + -- text = gsub(text, "Capslock", "Caps") - hotkey:SetText(text) - end + -- hotkey:SetText(text) + -- end - for _, button in pairs(buttons) do - hooksecurefunc(button, "UpdateHotkeys", updateHotkeys) - end + -- for _, button in pairs(buttons) do + -- hooksecurefunc(button, "UpdateHotkeys", updateHotkeys) + -- end - hooksecurefunc("ActionButton_UpdateRangeIndicator", updateHotkeys) - hooksecurefunc("PetActionButton_SetHotkeys", updateHotkeys) - end + -- hooksecurefunc("ActionButton_UpdateRangeIndicator", updateHotkeys) + -- hooksecurefunc("PetActionButton_SetHotkeys", updateHotkeys) + -- end - if db.altKeybindFont then - -- RANGE_INDICATOR = "*" + -- if db.altKeybindFont then + -- -- RANGE_INDICATOR = "*" - local function updateHotkeys(self) - local hotkey = self.HotKey - local text = hotkey:GetText() + -- local function updateHotkeys(self) + -- local hotkey = self.HotKey + -- local text = hotkey:GetText() - if not self.XarModded then - self.XarModded = true - hotkey:SetFontObject("Game11Font_o1") - hotkey:ClearAllPoints() - hotkey:SetPoint("TOPRIGHT", -1, -3) - end - end + -- if not self.XarModded then + -- self.XarModded = true + -- hotkey:SetFontObject("Game11Font_o1") + -- hotkey:ClearAllPoints() + -- hotkey:SetPoint("TOPRIGHT", -1, -3) + -- end + -- end - for _, button in pairs(buttons) do - hooksecurefunc(button, "UpdateHotkeys", updateHotkeys) - end + -- for _, button in pairs(buttons) do + -- hooksecurefunc(button, "UpdateHotkeys", updateHotkeys) + -- end - hooksecurefunc("ActionButton_UpdateRangeIndicator", updateHotkeys) - hooksecurefunc("PetActionButton_SetHotkeys", updateHotkeys) - end + -- hooksecurefunc("ActionButton_UpdateRangeIndicator", updateHotkeys) + -- hooksecurefunc("PetActionButton_SetHotkeys", updateHotkeys) + -- end if db.hideMacroNames then for _, button in pairs(buttons) do diff --git a/Modules/interface.lua b/Modules/interface.lua index 5c86365..4e66c5e 100644 --- a/Modules/interface.lua +++ b/Modules/interface.lua @@ -9,7 +9,6 @@ module.defaultSettings = { hideGlow = false, hideEffects = false, hideZoom = false, - scrollZoom = false, sellGrays = false, repair = false, dampeningDisplay = false, @@ -88,13 +87,6 @@ module.optionsTable = { name = "Hide Zoom Buttons", width = "full", }, - scrollZoom = { - order = 11, - type = "toggle", - name = "Enable Scroll Wheel Zooming", - desc = "Zoom in & out on minimap using mousewheel", - width = "full", - }, header_automation = { order = 12, type = "header", @@ -139,7 +131,6 @@ function module:XaryuSettings() db.hideGlow = true db.hideEffects = true db.hideZoom = true - db.scrollZoom = true db.sellGrays = true db.repair = true db.dampeningDisplay = true @@ -161,37 +152,46 @@ function module:OnLoad() end if db.hideBags then - MicroButtonAndBagsBar:Hide() + -- Hide backpack symbol + MainMenuBarBackpackButton:Hide() + -- Hide toggle + BagBarExpandToggle:Hide() + -- Loop through all bag buttons + for i = 0, 3 do + local bagButton = _G["CharacterBag"..i.."Slot"] + bagButton:Hide() + end + -- Hide reagent bag + CharacterReagentBag0Slot:Hide() + end if db.hideMicroButtons then - local tframe = CreateFrame("FRAME") - tframe:Hide() - - hooksecurefunc("UpdateMicroButtonsParent", function() - for i=1, #MICRO_BUTTONS do - _G[MICRO_BUTTONS[i]]:SetParent(tframe) - end - end) - - UpdateMicroButtonsParent(tframe) + local micro_buttons_to_hide = { + "CharacterMicroButton", + "SpellbookMicroButton", + "TalentMicroButton", + "AchievementMicroButton", + "QuestLogMicroButton", + "GuildMicroButton", + "LFDMicroButton", + "CollectionsMicroButton", + "EJMicroButton", + "StoreMicroButton", + "MainMenuMicroButton" + } + -- Hide all micro buttons - Character, Spellbook, Talent, Achievement, Quest, Guild, LFD, Collections, Store, MainMenu + for i = 1, #micro_buttons_to_hide do + local button = _G[micro_buttons_to_hide[i]] + button:SetScript("OnShow", button.Hide) + button.Show = function () end + button:Hide() + end end if db.hideZoom then - MinimapZoomIn:Hide() - MinimapZoomOut:Hide() - end - - if db.scrollZoom then - Minimap:EnableMouseWheel(true) - - Minimap:SetScript("OnMouseWheel", function(self, arg1) - if arg1 > 0 then - Minimap_ZoomIn() - else - Minimap_ZoomOut() - end - end) + Minimap.ZoomIn:SetAlpha(0) + Minimap.ZoomOut:SetAlpha(0) end SetCVar("ffxGlow", db.hideGlow and 0 or 1) diff --git a/Modules/unitframes.lua b/Modules/unitframes.lua index 8145538..936afb3 100644 --- a/Modules/unitframes.lua +++ b/Modules/unitframes.lua @@ -78,8 +78,8 @@ module.optionsTable = { type = "select", name = "Style", values = { - "Elite", "Rare", + "Elite", "Rare Elite", }, set = function(info, val) @@ -117,15 +117,23 @@ function module:OnLoad() end if db.hidePvpIcons then - PlayerPVPIcon:SetAlpha(0) - PlayerPrestigeBadge:SetAlpha(0) - PlayerPrestigePortrait:SetAlpha(0) - TargetFrameTextureFramePVPIcon:SetAlpha(0) - TargetFrameTextureFramePrestigeBadge:SetAlpha(0) - TargetFrameTextureFramePrestigePortrait:SetAlpha(0) - FocusFrameTextureFramePVPIcon:SetAlpha(0) - FocusFrameTextureFramePrestigeBadge:SetAlpha(0) - FocusFrameTextureFramePrestigePortrait:SetAlpha(0) + -- Set contextuals + local playerFrameTargetContextual = PlayerFrame_GetPlayerFrameContentContextual() + local targetFrameContextual = TargetFrame.TargetFrameContent.TargetFrameContentContextual + -- TargetFrame.TargetFrameContent.TargetFrameContentContextual.PrestigePortrait:SetAlpha(0) + --local targetFrameTargetContextual = TargetFrame_GetTargetFrameContentContextual(); + -- Self + playerFrameTargetContextual.PVPIcon:SetAlpha(0) + playerFrameTargetContextual.PrestigePortrait:SetAlpha(0) + playerFrameTargetContextual.PrestigeBadge:SetAlpha(0) + -- Target frames + --TargetFrame.TargetFrameContent.TargetFrameContentContextual.PVPIcon:SetAlpha(0) + TargetFrame.TargetFrameContent.TargetFrameContentContextual.PrestigePortrait:SetAlpha(0) + TargetFrame.TargetFrameContent.TargetFrameContentContextual.PrestigeBadge:SetAlpha(0) + -- Focus frames + --TargetFrame.FocusFrame.PVPIcon:SetAlpha(0) + --TargetFrame.FocusFrame.PrestigePortrait:SetAlpha(0) + --TargetFrame.FocusFrame.PrestigeBadge:SetAlpha(0) end if db.combatIndicator then @@ -192,10 +200,22 @@ function module.SetChainStyle() local chain = db.chainStyle if chain == 1 then -- Rare - PlayerFrameTexture:SetTexture("Interface\\TargetingFrame\\UI-TargetingFrame-Rare") + -- Set rare texture to player frame + PlayerFrame.PlayerFrameContainer.FrameTexture:SetAtlas("ui-hud-unitframe-target-portraiton-boss-rare-silver", TextureKitConstants.UseAtlasSize); + PlayerFrame.PlayerFrameContainer.FrameTexture:SetTexCoord(1, 0, 1, 0); + + PlayerFrame.PlayerFrameContainer.FrameTexture:SetPoint("TOPLEFT", 11, -8); elseif chain == 2 then -- Elite - PlayerFrameTexture:SetTexture("Interface\\TargetingFrame\\UI-TargetingFrame-Elite") + -- Set rare texture to player frame + PlayerFrame.PlayerFrameContainer.FrameTexture:SetAtlas("UI-HUD-UnitFrame-Target-PortraitOn-Boss-Gold", TextureKitConstants.UseAtlasSize); + PlayerFrame.PlayerFrameContainer.FrameTexture:SetTexCoord(1, 0, 1, 0); + + PlayerFrame.PlayerFrameContainer.FrameTexture:SetPoint("TOPLEFT", 11, -8); elseif chain == 3 then -- Rare Elite - PlayerFrameTexture:SetTexture("Interface\\TargetingFrame\\UI-TargetingFrame-Rare-Elite") + -- Set rare texture to player frame + PlayerFrame.PlayerFrameContainer.FrameTexture:SetAtlas("UI-HUD-UnitFrame-Target-PortraitOn-Boss-Gold-Winged", TextureKitConstants.UseAtlasSize); + PlayerFrame.PlayerFrameContainer.FrameTexture:SetTexCoord(1, 0, 1, 0); + + PlayerFrame.PlayerFrameContainer.FrameTexture:SetPoint("TOPLEFT", -8, -8); end end \ No newline at end of file diff --git a/XarMods.toc b/XarMods_Mainline.toc similarity index 65% rename from XarMods.toc rename to XarMods_Mainline.toc index 185a406..0b15f4f 100644 --- a/XarMods.toc +++ b/XarMods_Mainline.toc @@ -1,6 +1,6 @@ -## Interface: 90205 +## Interface: 100002 ## Title: |cff00c0ffXarMods|r -## Author: Stako +## Author: Stako, Hamsti ## Version: 1.2 ## SavedVariables: XarModsDB diff --git a/XarMods_Wrath.toc b/XarMods_Wrath.toc new file mode 100644 index 0000000..0b15f4f --- /dev/null +++ b/XarMods_Wrath.toc @@ -0,0 +1,7 @@ +## Interface: 100002 +## Title: |cff00c0ffXarMods|r +## Author: Stako, Hamsti +## Version: 1.2 +## SavedVariables: XarModsDB + +XarMods.xml