diff --git a/Interface/AddOns/SVUI/packages/actionbar/SVBar.lua b/Interface/AddOns/SVUI/packages/actionbar/SVBar.lua index db6f9bf..e1e7e0d 100644 --- a/Interface/AddOns/SVUI/packages/actionbar/SVBar.lua +++ b/Interface/AddOns/SVUI/packages/actionbar/SVBar.lua @@ -1039,57 +1039,61 @@ end do local function SetStanceBarButtons() - local maxForms = GetNumShapeshiftForms(); - local currentForm = GetShapeshiftForm(); - local maxButtons = NUM_STANCE_SLOTS; - local texture, name, isActive, isCastable, _; - for i = 1, maxButtons do - local button = _G["SVUI_StanceBarButton"..i] - local icon = _G["SVUI_StanceBarButton"..i.."Icon"] - local cd = _G["SVUI_StanceBarButton"..i.."Cooldown"] - if i <= maxForms then - texture, name, isActive, isCastable = GetShapeshiftFormInfo(i) - if texture == "Interface\\Icons\\Spell_Nature_WispSplode" and MOD.db.Stance.style == "darkenInactive" then - _, _, texture = GetSpellInfo(name) - end - icon:SetTexture(texture) - if texture then - cd:SetAlpha(1) - else - cd:SetAlpha(0) - end - if isActive then - StanceBarFrame.lastSelected = button:GetID() - if maxForms == 1 then - button:SetChecked(1) - else - if button.checked then button.checked:SetTexture(0, 0.5, 0, 0.2) end - button:SetBackdropBorderColor(0.4, 0.8, 0) - button:SetChecked(MOD.db.Stance.style ~= "darkenInactive") - end - else - if maxForms == 1 or currentForm == 0 then - button:SetChecked(0) - else - button:SetBackdropBorderColor(0, 0, 0) - button:SetChecked(MOD.db.Stance.style == "darkenInactive") - if button.checked then - button.checked:SetAlpha(1) - if MOD.db.Stance.style == "darkenInactive" then - button.checked:SetTexture(0, 0, 0, 0.75) + local maxForms = GetNumShapeshiftForms(); + local currentForm = GetShapeshiftForm(); + local maxButtons = NUM_STANCE_SLOTS; + local texture, name, isActive, isCastable, _; + for i = 1, maxButtons do + local button = _G["SVUI_StanceBarButton"..i] + local icon = _G["SVUI_StanceBarButton"..i.."Icon"] + local cd = _G["SVUI_StanceBarButton"..i.."Cooldown"] + if i <= maxForms then + texture, name, isActive, isCastable = GetShapeshiftFormInfo(i) + if texture == "Interface\\Icons\\Spell_Nature_WispSplode" and MOD.db.Stance.style == "darkenInactive" then + _, _, texture = GetSpellInfo(name) + end + + icon:SetTexture(texture) + + if texture then + cd:SetAlpha(1) + else + cd:SetAlpha(0) + end + + if isActive then + StanceBarFrame.lastSelected = button:GetID() + + if maxForms > 1 then + if button.checked then button.checked:SetTexture(0, 0.5, 0, 0.2) end + button:SetBackdropBorderColor(0.4, 0.8, 0) + end + icon:SetVertexColor(1, 1, 1) + button:SetChecked(1) else - button.checked:SetTexture(1, 1, 1, 0.25) + if maxForms > 1 and currentForm > 0 then + button:SetBackdropBorderColor(0, 0, 0) + if button.checked then + button.checked:SetAlpha(1) + end + if MOD.db.Stance.style == "darkenInactive" then + icon:SetVertexColor(0.25, 0.25, 0.25) + else + icon:SetVertexColor(1, 1, 1) + end + end + + button:SetChecked(0) + end + if isCastable then + icon:SetDesaturated(false) + button:SetAlpha(1) + else + icon:SetDesaturated(true) + button:SetAlpha(0.4) end - end end - end - if isCastable then - icon:SetVertexColor(1.0, 1.0, 1.0) - else - icon:SetVertexColor(0.4, 0.4, 0.4) - end end - end end local function UpdateShapeshiftForms(self, event) @@ -1119,9 +1123,7 @@ do MOD:RefreshBar("Stance") - if event == "UPDATE_SHAPESHIFT_FORMS" then - SetStanceBarButtons() - end + SetStanceBarButtons() if not C_PetBattles.IsInBattle() or ready then if maxForms == 0 then UnregisterStateDriver(stanceBar, "show") diff --git a/Interface/AddOns/SVUI/packages/bag/SVBag.lua b/Interface/AddOns/SVUI/packages/bag/SVBag.lua index 21b1c2f..2d16231 100644 --- a/Interface/AddOns/SVUI/packages/bag/SVBag.lua +++ b/Interface/AddOns/SVUI/packages/bag/SVBag.lua @@ -190,19 +190,15 @@ end CORE FUNCTIONS ########################################################## ]]-- -function MOD:GetContainerFrame(e) - if type(e) == "boolean" and e == true then - return MOD.BankFrame - elseif type(e) == "number" then - if MOD.BankFrame then - for f, g in ipairs(MOD.BankFrame.BagIDs) do - if g == e then - return MOD.BankFrame - end - end - end +function MOD:GetContainerFrame(isBank, isReagent) + if(type(isBank) == "boolean" and isBank == true) then + if(type(isReagent) == "boolean" and isReagent == true and self.ReagentFrame) then + return self.ReagentFrame + elseif(self.BankFrame) then + return self.BankFrame + end end - return MOD.BagFrame + return self.BagFrame end function MOD:DisableBlizzard() @@ -345,9 +341,9 @@ function MOD:FlushSlotFading(this) end end -function MOD:Layout(isBank) +function MOD:Layout(isBank, isReagent) if SV.db.SVBag.enable ~= true then return; end - local f = MOD:GetContainerFrame(isBank); + local f = MOD:GetContainerFrame(isBank, isReagent); if not f then return; end local buttonSize = isBank and MOD.db.bankSize or MOD.db.bagSize; local buttonSpacing = 8; @@ -395,7 +391,8 @@ function MOD:Layout(isBank) end f.ContainerHolder:Size(((buttonSize + buttonSpacing) * (isBank and i - 1 or i)) + buttonSpacing, buttonSize + (buttonSpacing * 2)) if isBank then - BankFrameItemButton_Update(f.ContainerHolder[i])BankFrameItemButton_UpdateLocked(f.ContainerHolder[i]) + BankFrameItemButton_Update(f.ContainerHolder[i]) + BankFrameItemButton_UpdateLocked(f.ContainerHolder[i]) end f.ContainerHolder[i]:Size(buttonSize) f.ContainerHolder[i]:ClearAllPoints() @@ -405,8 +402,10 @@ function MOD:Layout(isBank) f.ContainerHolder[i]:SetPoint("LEFT", lastContainerButton, "RIGHT", buttonSpacing, 0) end lastContainerButton = f.ContainerHolder[i]; - end + end + local numSlots = GetContainerNumSlots(bagID); + if numSlots > 0 then if not f.Bags[bagID] then f.Bags[bagID] = NewFrame("Frame", f:GetName().."Bag"..bagID, f); @@ -479,7 +478,7 @@ function MOD:Layout(isBank) if f.Bags[bagID] then f.Bags[bagID].numSlots = numSlots; end - if self.isBank then + if(self.isBank and not self.isReagent) then if self.ContainerHolder[i] then BankFrameItemButton_Update(self.ContainerHolder[i]) BankFrameItemButton_UpdateLocked(self.ContainerHolder[i]) @@ -496,7 +495,10 @@ function MOD:RefreshBags() end if MOD.BankFrame then MOD:Layout(true) - end + end + if MOD.ReagentFrame then + MOD:Layout(true, true) + end end function MOD:UpdateGoldText() @@ -567,7 +569,13 @@ function MOD:ModifyBags() local anchor, x, y = self.db.bank.point, self.db.bank.xOffset, self.db.bank.yOffset self.BankFrame:ClearAllPoints() self.BankFrame:Point(anchor, parent, anchor, x, y) - end + end + if self.ReagentFrame then + local parent = docked and LeftSuperDock or SV.UIParent + local anchor, x, y = self.db.bank.point, self.db.bank.xOffset, self.db.bank.yOffset + self.ReagentFrame:ClearAllPoints() + self.ReagentFrame:Point(anchor, parent, anchor, x, y) + end end do @@ -784,7 +792,7 @@ do for _, id in ipairs(self.BagIDs) do local numSlots = GetContainerNumSlots(id) if(not self.Bags[id] and numSlots ~= 0 or self.Bags[id] and numSlots ~= self.Bags[id].numSlots) then - MOD:Layout(self.isBank) + MOD:Layout(self.isBank, self.isReagent) return end if(SV.db.SVGear.misc.setoverlay) then @@ -798,7 +806,7 @@ do self:RefreshBagSlots(...) elseif(event == "BAG_UPDATE_COOLDOWN") then self:RefreshCD() - elseif(event == "PLAYERBANKSLOTS_CHANGED") then + elseif(event == "PLAYERBANKSLOTS_CHANGED" or event == "PLAYERREAGENTBANKSLOTS_CHANGED") then self:RefreshBagsSlots() end end @@ -901,6 +909,25 @@ do end end end + if(MOD.ReagentFrame) then + container = MOD.ReagentFrame + for _,id in ipairs(container.BagIDs) do + numSlots = GetContainerNumSlots(id) + if(SV.db.SVGear.misc.setoverlay) then + for i=1,numSlots do + if container.Bags[id] and container.Bags[id][i] then + UpdateEquipmentInfo(container.Bags[id][i], id, i) + end + end + else + for i=1,numSlots do + if(container.Bags[id] and container.Bags[id][i] and container.Bags[id][i].equipmentinfo) then + container.Bags[id][i].equipmentinfo:SetText() + end + end + end + end + end end function MOD:MakeBags() @@ -914,22 +941,28 @@ do frame.RefreshBagsSlots = MOD.RefreshBagsSlots; frame.RefreshBagSlots = MOD.RefreshBagSlots; frame.RefreshCD = MOD.RefreshCD; + frame:RegisterEvent("ITEM_LOCK_CHANGED") frame:RegisterEvent("ITEM_UNLOCKED") frame:RegisterEvent("BAG_UPDATE_COOLDOWN") frame:RegisterEvent("BAG_UPDATE") frame:RegisterEvent("EQUIPMENT_SETS_CHANGED") frame:RegisterEvent("PLAYERBANKSLOTS_CHANGED") + frame:RegisterEvent("PLAYERREAGENTBANKSLOTS_CHANGED") frame:SetMovable(true) + frame:RegisterForDrag("LeftButton", "RightButton") frame:RegisterForClicks("AnyUp") + frame:SetScript("OnDragStart", Container_OnDragStart) frame:SetScript("OnDragStop", Container_OnDragStop) frame:SetScript("OnClick", Container_OnClick) frame:SetScript("OnEnter", Container_OnEnter) frame:SetScript("OnLeave", Token_OnLeave) frame:SetScript("OnEvent", Container_OnEvent) + frame.isBank = false; + frame.isReagent = false; frame:Hide() frame.bottomOffset = 32; frame.topOffset = 65; @@ -989,7 +1022,7 @@ do frame.sortButton.ttText = L["Sort Bags"] frame.sortButton:SetScript("OnEnter", Tooltip_Show) frame.sortButton:SetScript("OnLeave", Tooltip_Hide) - local Sort_OnClick = MOD:RunSortingProcess(MOD.Sort, "bags") + local Sort_OnClick = (SV.___interface >= 60000) and SortBankBags or MOD:RunSortingProcess(MOD.Sort, "bags") frame.sortButton:SetScript("OnClick", Sort_OnClick) frame.stackButton = NewFrame("Button", nil, frame) @@ -1067,23 +1100,28 @@ do self.BagFrame = frame end - function MOD:MakeBank() - local bagName = "SVUI_BankContainerFrame" + function MOD:MakeBank(isReagent) + local bagName = isReagent and "SVUI_ReagentContainerFrame" or "SVUI_BankContainerFrame" + local otherName = isReagent and "SVUI_BankContainerFrame" or "SVUI_ReagentContainerFrame" local uisCount = #UISpecialFrames + 1; local bagsCount = #self.BagFrames + 1; + local frame = NewFrame("Button", bagName, SV.UIParent) - frame:SetPanelTemplate("Container") + frame:SetPanelTemplate(isReagent and "Action" or "Container") frame:SetFrameStrata("HIGH") frame.RefreshSlot = MOD.RefreshSlot; frame.RefreshBagsSlots = MOD.RefreshBagsSlots; frame.RefreshBagSlots = MOD.RefreshBagSlots; frame.RefreshCD = MOD.RefreshCD; + frame:RegisterEvent("ITEM_LOCK_CHANGED") frame:RegisterEvent("ITEM_UNLOCKED") frame:RegisterEvent("BAG_UPDATE_COOLDOWN") frame:RegisterEvent("BAG_UPDATE") frame:RegisterEvent("EQUIPMENT_SETS_CHANGED") frame:RegisterEvent("PLAYERBANKSLOTS_CHANGED") + frame:RegisterEvent("PLAYERREAGENTBANKSLOTS_CHANGED") + frame:SetMovable(true) frame:RegisterForDrag("LeftButton", "RightButton") frame:RegisterForClicks("AnyUp") @@ -1093,12 +1131,15 @@ do frame:SetScript("OnEnter", Container_OnEnter) frame:SetScript("OnLeave", Token_OnLeave) frame:SetScript("OnEvent", Container_OnEvent) + frame.isBank = true; + frame.isReagent = isReagent; frame:Hide() frame.bottomOffset = 8; frame.topOffset = 60; frame.BagIDs = {-1, 5, 6, 7, 8, 9, 10, 11} frame.Bags = {} + frame.closeButton = NewFrame("Button", bagName.."CloseButton", frame, "UIPanelCloseButton") frame.closeButton:Point("TOPRIGHT", -4, -4) frame.holderFrame = NewFrame("Frame", nil, frame) @@ -1117,7 +1158,7 @@ do frame.sortButton.ttText = L["Sort Bags"] frame.sortButton:SetScript("OnEnter", Tooltip_Show) frame.sortButton:SetScript("OnLeave", Tooltip_Hide) - local Sort_OnClick = MOD:RunSortingProcess(MOD.Sort, "bank") + local Sort_OnClick = (SV.___interface >= 60000) and SortReagentBankBags or MOD:RunSortingProcess(MOD.Sort, "bank") frame.sortButton:SetScript("OnClick", Sort_OnClick) frame.stackButton = NewFrame("Button", nil, frame) @@ -1179,11 +1220,37 @@ do end frame.purchaseBagButton:SetScript("OnClick", PurchaseBtn_OnClick) - frame:SetScript("OnHide", CloseBankFrame) - UISpecialFrames[uisCount] = "SVUI_BankContainerFrame"; + if(SV.___interface >= 60000) then + frame.swapButton = NewFrame("Button", nil, frame) + frame.swapButton:Point("TOPRIGHT", frame, "TOPRIGHT", -10, -10) + frame.swapButton:Size(25, 25) + frame.swapButton:SetNormalTexture(ICON_BAGS) + StyleBagToolButton(frame.swapButton) + frame.swapButton.ttText = isReagent and L["View Bank"] or L["View Reagents"] + frame.swapButton:SetScript("OnEnter", Tooltip_Show) + frame.swapButton:SetScript("OnLeave", Tooltip_Hide) + frame.swapButton:SetScript("OnClick", function() + _G[otherName]:Show() + _G[bagName]:Hide() + end) + frame:SetScript("OnHide", function() + if(not _G[otherName] or not _G[otherName]:IsShown()) then + CloseBankFrame() + end + end) + else + frame:SetScript("OnHide", CloseBankFrame) + end + + UISpecialFrames[uisCount] = bagName; self.BagFrames[bagsCount] = frame - self.BankFrame = frame + + if(isReagent) then + self.ReagentFrame = frame + else + self.BankFrame = frame + end end end @@ -1248,7 +1315,10 @@ do MOD.BagFrame:Hide() if(MOD.BankFrame) then MOD.BankFrame:Hide() - end + end + if(MOD.ReagentFrame) then + MOD.ReagentFrame:Hide() + end if(BreakStuffHandler and BreakStuffButton and BreakStuffButton.icon) then BreakStuffHandler:MODIFIER_STATE_CHANGED() BreakStuffHandler.ReadyToSmash = false @@ -1278,11 +1348,17 @@ do end function MOD:BANKFRAME_OPENED() + local hasReagent = (SV.___interface >= 60000) if not MOD.BankFrame then - MOD:MakeBank() + MOD:MakeBankOrReagent() MOD:ModifyBags() - end - MOD:Layout(true) + end + if(hasReagent and not MOD.ReagentFrame) then + MOD:MakeBankOrReagent(true) + MOD:ModifyBags() + MOD.ReagentFrame:Hide() + end + MOD:Layout(true, hasReagent) MOD.BankFrame:Show() MOD.BankFrame:RefreshBagsSlots() MOD.BagFrame:Show() @@ -1291,8 +1367,12 @@ do end function MOD:BANKFRAME_CLOSED() - if not MOD.BankFrame then return end - MOD.BankFrame:Hide() + if(MOD.BankFrame) then + MOD.BankFrame:Hide() + end + if(MOD.ReagentFrame) then + MOD.ReagentFrame:Hide() + end end function SetBagHooks() diff --git a/Interface/AddOns/SVUI/packages/unit/elements/auras.lua b/Interface/AddOns/SVUI/packages/unit/elements/auras.lua index aa8c2f0..e5ae83c 100644 --- a/Interface/AddOns/SVUI/packages/unit/elements/auras.lua +++ b/Interface/AddOns/SVUI/packages/unit/elements/auras.lua @@ -164,24 +164,26 @@ end local UpdateAuraTimer = function(self, elapsed) self.expiration = self.expiration - elapsed; - if(self.nextUpdate > 0) then - self.nextUpdate = self.nextUpdate - elapsed; - return - end - if(self.expiration <= 0) then + + if(self.expiration <= 0) then self:SetScript("OnUpdate", nil) if(self.text:GetFont()) then self.text:SetText("") end return - end + end + + if(self.nextUpdate > 0) then + self.nextUpdate = self.nextUpdate - elapsed; + return + end local expires = self.expiration; local calc, timeLeft = 0, 0; local timeFormat; if expires < 60 then - if expires >= 4 then + if expires >= 4 then timeLeft = floor(expires) timeFormat = "|cffffff00%d|r" self.nextUpdate = 0.51 @@ -245,13 +247,12 @@ local PostUpdateAuraIcon = function(self, unit, button, index, offset) button.spell = name button.isStealable = isStealable if expiration and duration ~= 0 then - if not button:GetScript('OnUpdate') then + if(not button:GetScript('OnUpdate')) then button.expirationTime = expiration button.expiration = expiration - GetTime() button.nextUpdate = -1 button:SetScript('OnUpdate', UpdateAuraTimer) - end - if button.expirationTime ~= expiration then + elseif(button.expirationTime ~= expiration) then button.expirationTime = expiration button.expiration = expiration - GetTime() button.nextUpdate = -1 diff --git a/Interface/AddOns/SVUI/scripts/mounts.lua b/Interface/AddOns/SVUI/scripts/mounts.lua index 890dd3e..01b0ced 100644 --- a/Interface/AddOns/SVUI/scripts/mounts.lua +++ b/Interface/AddOns/SVUI/scripts/mounts.lua @@ -16,6 +16,7 @@ S U P E R - V I L L A I N - U I By: Munglunch # LOCALIZED LUA FUNCTIONS ########################################################## ]]-- +if(select(4, GetBuildInfo()) >= 60000) then return end; --[[ GLOBALS ]]-- local _G = _G; local unpack = _G.unpack; @@ -344,6 +345,11 @@ local function SetMountCheckButtons() scrollFrame:HookScript("OnMouseWheel", Update_MountCheckButtons) scrollBar:HookScript("OnValueChanged", Update_MountCheckButtons) UpdateCurrentMountSelection() + + if(SV.___interface >= 60000) then + MountListener:RegisterEvent("MOUNT_JOURNAL_USABILITY_CHANGED") + end + MountListener:RegisterEvent("COMPANION_LEARNED") MountListener:RegisterEvent("COMPANION_UNLEARNED") MountListener:RegisterEvent("COMPANION_UPDATE") diff --git a/Interface/AddOns/SVUI/scripts/reactions.lua b/Interface/AddOns/SVUI/scripts/reactions.lua index 5c2f0a3..b44cd1d 100644 --- a/Interface/AddOns/SVUI/scripts/reactions.lua +++ b/Interface/AddOns/SVUI/scripts/reactions.lua @@ -40,6 +40,17 @@ LOCALS (from ShestakUI by:Shestak) ]]-- local toon = UnitName("player"); +local ReactionEmotes = { + "SALUTE", + "THANK", + "DRINK" +} + +local function Thanks_Emote(sourceName) + local index = random(1,#ReactionEmotes) + DoEmote(ReactionEmotes[index], sourceName) +end + local Reactions = { Woot = { [29166] = true, [20484] = true, [61999] = true, @@ -125,12 +136,12 @@ local function rng() return random(1,6) end local SAPPED_MESSAGE = { - "Oh Hell No... {rt8}SAPPED{rt8}", - "{rt8}SAPPED{rt8}", + "Oh Hell No ... {rt8}SAPPED{rt8}", + "{rt8}SAPPED{rt8} ...Someone's about to get slapped!", "Mother Fu... {rt8}SAPPED{rt8}", - "{rt8}SAPPED{rt8}", + "{rt8}SAPPED{rt8} ...How cute", "{rt8}SAPPED{rt8} ...Ain't Nobody Got Time For That!", - "{rt8}SAPPED{rt8}" + "Uh-Oh... {rt8}SAPPED{rt8}" } local ChatLogHandler = CreateFrame("Frame") local ChatLogHandler_OnEvent = function(self, event, ...) @@ -142,7 +153,8 @@ local ChatLogHandler_OnEvent = function(self, event, ...) if ((spellID == 6770) and (destName == toon) and (subEvent == "SPELL_AURA_APPLIED" or subEvent == "SPELL_AURA_REFRESH")) then local msg = SAPPED_MESSAGE[rng()] SendChatMessage(msg, "SAY") - DEFAULT_CHAT_FRAME:AddMessage("Sapped by: "..(sourceName or "(unknown)")) + SV:AddonMessage("Sapped by: "..sourceName) + DoEmote("CRACK", sourceName) elseif(subEvent == "SPELL_INTERRUPT" and sourceGUID == UnitGUID("player") and IsInGroup()) then SendChatMessage(INTERRUPTED.." "..destName..": "..GetSpellLink(otherSpellID), MsgTest()) end @@ -151,13 +163,15 @@ local ChatLogHandler_OnEvent = function(self, event, ...) if(SV.db.system.woot) then for key, value in pairs(Reactions.Woot) do if spellID == key and value == true and destName == toon and sourceName ~= toon and (subEvent == "SPELL_AURA_APPLIED" or subEvent == "SPELL_CAST_SUCCESS") then - SendChatMessage(L["Thanks for "]..GetSpellLink(spellID)..", "..sourceName, "WHISPER", nil, sourceName) + Thanks_Emote(sourceName) + --SendChatMessage(L["Thanks for "]..GetSpellLink(spellID)..", "..sourceName, "WHISPER", nil, sourceName) print(GetSpellLink(spellID)..L[" received from "]..sourceName) end end end if(SV.db.system.lookwhaticando) then + local outbound; local spells = Reactions.LookWhatICanDo local _, _, difficultyID = GetInstanceInfo() if(difficultyID ~= 0 and subEvent == "SPELL_CAST_SUCCESS") then @@ -165,9 +179,14 @@ local ChatLogHandler_OnEvent = function(self, event, ...) for i, spells in pairs(spells) do if(spellID == spells) then if(destName == nil) then - SendChatMessage(format(L["%s used a %s."], sourceName, GetSpellLink(spellID)), MsgTest()) + outbound = (L["%s used a %s."]):format(sourceName, GetSpellLink(spellID)) else - SendChatMessage(format(L["%s used a %s."], sourceName, GetSpellLink(spellID).." -> "..destName), MsgTest()) + outbound = (L["%s used a %s."]):format(sourceName, GetSpellLink(spellID).." -> "..destName) + end + if(SV.db.system.reactionChat) then + SendChatMessage(outbound, MsgTest()) + else + print(outbound) end end end @@ -176,9 +195,14 @@ local ChatLogHandler_OnEvent = function(self, event, ...) for i, spells in pairs(spells) do if(spellID == spells) then if(destName == nil) then - SendChatMessage(format(L["%s used a %s."], sourceName, GetSpellLink(spellID)), MsgTest()) + outbound = (L["%s used a %s."]):format(sourceName, GetSpellLink(spellID)) else - SendChatMessage(GetSpellLink(spellID).." -> "..destName, MsgTest()) + outbound = GetSpellLink(spellID).." -> "..destName + end + if(SV.db.system.reactionChat) then + SendChatMessage(outbound, MsgTest()) + else + print(outbound) end end end @@ -191,50 +215,65 @@ local ChatLogHandler_OnEvent = function(self, event, ...) if not UnitInRaid(sourceName) and not UnitInParty(sourceName) then return end local sourceName = format(sourceName:gsub("%-[^|]+", "")) + local thanks, outbound = false if subEvent == "SPELL_CAST_SUCCESS" then -- Feasts if (spellID == 126492 or spellID == 126494) then - SendChatMessage(string.format(L["%s has prepared a %s - [%s]."], sourceName, GetSpellLink(spellID), SPELL_STAT1_NAME), MsgTest(true)) + outbound = (L["%s has prepared a %s - [%s]."]):format(sourceName, GetSpellLink(spellID), SPELL_STAT1_NAME) elseif (spellID == 126495 or spellID == 126496) then - SendChatMessage(string.format(L["%s has prepared a %s - [%s]."], sourceName, GetSpellLink(spellID), SPELL_STAT2_NAME), MsgTest(true)) + outbound = (L["%s has prepared a %s - [%s]."]):format(sourceName, GetSpellLink(spellID), SPELL_STAT2_NAME) elseif (spellID == 126501 or spellID == 126502) then - SendChatMessage(string.format(L["%s has prepared a %s - [%s]."], sourceName, GetSpellLink(spellID), SPELL_STAT3_NAME), MsgTest(true)) + outbound = (L["%s has prepared a %s - [%s]."]):format(sourceName, GetSpellLink(spellID), SPELL_STAT3_NAME) elseif (spellID == 126497 or spellID == 126498) then - SendChatMessage(string.format(L["%s has prepared a %s - [%s]."], sourceName, GetSpellLink(spellID), SPELL_STAT4_NAME), MsgTest(true)) + outbound = (L["%s has prepared a %s - [%s]."]):format(sourceName, GetSpellLink(spellID), SPELL_STAT4_NAME) elseif (spellID == 126499 or spellID == 126500) then - SendChatMessage(string.format(L["%s has prepared a %s - [%s]."], sourceName, GetSpellLink(spellID), SPELL_STAT5_NAME), MsgTest(true)) + outbound = (L["%s has prepared a %s - [%s]."]):format(sourceName, GetSpellLink(spellID), SPELL_STAT5_NAME) elseif (spellID == 104958 or spellID == 105193 or spellID == 126503 or spellID == 126504 or spellID == 145166 or spellID == 145169 or spellID == 145196) then - SendChatMessage(string.format(L["%s has prepared a %s."], sourceName, GetSpellLink(spellID)), MsgTest(true)) + outbound = (L["%s has prepared a %s - [%s]."]):format(sourceName, GetSpellLink(spellID)) -- Refreshment Table elseif spellID == 43987 then - SendChatMessage(string.format(L["%s has prepared a %s."], sourceName, GetSpellLink(spellID)), MsgTest(true)) + outbound = (L["%s has prepared a %s."]):format(sourceName, GetSpellLink(spellID)) -- Ritual of Summoning elseif spellID == 698 then - SendChatMessage(string.format(L["%s is casting %s. Click!"], sourceName, GetSpellLink(spellID)), MsgTest(true)) + outbound = (L["%s is casting %s. Click!"]):format(sourceName, GetSpellLink(spellID)) -- Piccolo of the Flaming Fire elseif spellID == 18400 then - SendChatMessage(string.format(L["%s used a %s."], sourceName, GetSpellLink(spellID)), MsgTest(true)) + outbound = (L["%s used a %s."]):format(sourceName, GetSpellLink(spellID)) end + if(outbound) then thanks = true end elseif subEvent == "SPELL_SUMMON" then -- Repair Bots if Reactions.Bots[spellID] then - SendChatMessage(string.format(L["%s has put down a %s."], sourceName, GetSpellLink(spellID)), MsgTest(true)) + outbound = (L["%s has put down a %s."]):format(sourceName, GetSpellLink(spellID)) + thanks = true end elseif subEvent == "SPELL_CREATE" then -- Ritual of Souls and MOLL-E if (spellID == 29893 or spellID == 54710) then - SendChatMessage(string.format(L["%s has put down a %s."], sourceName, GetSpellLink(spellID)), MsgTest(true)) + outbound = (L["%s has put down a %s."]):format(sourceName, GetSpellLink(spellID)) + thanks = true -- Toys elseif Reactions.Toys[spellID] then - SendChatMessage(string.format(L["%s has put down a %s."], sourceName, GetSpellLink(spellID)), MsgTest(true)) + outbound = (L["%s has put down a %s."]):format(sourceName, GetSpellLink(spellID)) -- Portals elseif Reactions.Portals[spellID] then - SendChatMessage(string.format(L["%s is casting %s."], sourceName, GetSpellLink(spellID)), MsgTest(true)) + outbound = (L["%s is casting %s."]):format(sourceName, GetSpellLink(spellID)) end elseif subEvent == "SPELL_AURA_APPLIED" then -- Turkey Feathers and Party G.R.E.N.A.D.E. if (spellID == 61781 or ((spellID == 51508 or spellID == 51510) and destName == toon)) then - SendChatMessage(string.format(L["%s used a %s."], sourceName, GetSpellLink(spellID)), MsgTest(true)) + outbound = (L["%s used a %s."]):format(sourceName, GetSpellLink(spellID)) + end + end + + if(outbound) then + if(SV.db.system.reactionChat) then + SendChatMessage(outbound, MsgTest(true)) + else + print(outbound) + end + if(thanks and sourceName) then + Thanks_Emote(sourceName) end end end diff --git a/Interface/AddOns/SVUI/system/common.lua b/Interface/AddOns/SVUI/system/common.lua index 1ac79ac..ddf89cb 100644 --- a/Interface/AddOns/SVUI/system/common.lua +++ b/Interface/AddOns/SVUI/system/common.lua @@ -1314,16 +1314,22 @@ local function SetEditboxTemplate(self, x, y) if self.RightTex then Die(self.RightTex) end if self.MiddleTex then Die(self.MiddleTex) end - CreatePanelTemplate(self, "Inset", false, true, 1, x, y) + CreatePanelTemplate(self, "Inset", true, true, 1, x, y) local globalName = self:GetName(); if globalName then if _G[globalName.."Left"] then Die(_G[globalName.."Left"]) end if _G[globalName.."Middle"] then Die(_G[globalName.."Middle"]) end if _G[globalName.."Right"] then Die(_G[globalName.."Right"]) end - if _G[globalName.."Mid"] then Die(_G[globalName.."Mid"]) end - if globalName:find("Silver") or globalName:find("Copper") then - self.Panel:SetPoint("BOTTOMRIGHT", -12, -2) + if _G[globalName.."Mid"] then Die(_G[globalName.."Mid"]) end + + if globalName:find("Silver") or globalName:find("Copper") or globalName:find("Gold") then + self.Panel:SetPoint("TOPLEFT", -3, 1) + if globalName:find("Silver") or globalName:find("Copper") then + self.Panel:SetPoint("BOTTOMRIGHT", -12, -2) + else + self.Panel:SetPoint("BOTTOMRIGHT", -2, -2) + end end end end diff --git a/Interface/AddOns/SVUI/system/database.lua b/Interface/AddOns/SVUI/system/database.lua index 0b8cda1..664d061 100644 --- a/Interface/AddOns/SVUI/system/database.lua +++ b/Interface/AddOns/SVUI/system/database.lua @@ -76,7 +76,8 @@ CONFIGS["system"] = { ["questWatch"] = true, ["woot"] = true, ["pvpinterrupt"] = true, - ["lookwhaticando"] = false, + ["lookwhaticando"] = false, + ["reactionChat"] = false, ["sharingiscaring"] = false, ["arenadrink"] = true, ["stupidhat"] = true, diff --git a/Interface/AddOns/SVUI_ArtOfWar/SVUI_ArtOfWar.lua b/Interface/AddOns/SVUI_ArtOfWar/SVUI_ArtOfWar.lua index f1968fe..5680891 100644 --- a/Interface/AddOns/SVUI_ArtOfWar/SVUI_ArtOfWar.lua +++ b/Interface/AddOns/SVUI_ArtOfWar/SVUI_ArtOfWar.lua @@ -76,7 +76,112 @@ LOCAL FUNCTIONS local function HeadsUpAlarm(...) if not CombatText_AddMessage then return end CombatText_AddMessage(...) -end +end +--[[ +########################################################## +MUNGLUNCH's FAVORITE EMOTE GENERATOR +########################################################## +]]-- +local SpecialEmotes = { + "ROFL", + "CACKLE", + "GIGGLE", + "GRIN", + "SMIRK", + "MOON", + "LICK", + "YAWN", + "FLEX", + "TICKLE", + "TAUNT", + "SHOO", + "PRAY", + "SPIT", + "MOCK", + "GLOAT", + "PITY", + "VIOLIN", + "BYE", +} + +local LowHealthPlayerEmotes = { + "ROFL", + "CACKLE", + "GIGGLE", + "GRIN", + "SMIRK", + "MOON", + "LICK", + "YAWN", + "BITE", + "NOSEPICK" +} + +local LowHealthTargetEmotes = { + "ROFL", + "CACKLE", + "FLEX", + "TICKLE", + "TAUNT", + "SHOO", + "PRAY", + "SPIT", + "MOCK", + "GLOAT", + "PITY", + "VIOLIN", + "BYE", +} + +local KOSEmotes = { + "THREATEN", + "CRACK", + "POINT", + "GRIN", + "SMIRK", + "TAUNT", + "CHICKEN" +} + +local StealthEmotes = { + "CURIOUS", + "EYE", + "GASP", + "GAZE", + "MOCK", + "NOSEPICK", + "PEER", + "POINT", + "READY", + "STARE", + "TAP", +} + + +function SVUIEmote() + local index = random(1,#SpecialEmotes) + DoEmote(SpecialEmotes[index]) +end + +local function LowHealth_PlayerEmote() + local index = random(1,#LowHealthPlayerEmotes) + DoEmote(LowHealthPlayerEmotes[index]) +end + +local function LowHealth_TargetEmote() + local index = random(1,#LowHealthTargetEmotes) + DoEmote(LowHealthTargetEmotes[index]) +end + +local function KOS_Emote() + local index = random(1,#KOSEmotes) + DoEmote(KOSEmotes[index]) +end + +local function Stealth_Emote(name) + local index = random(1,#StealthEmotes) + DoEmote(StealthEmotes[index], name) +end --[[ ########################################################## CORE FUNCTIONS @@ -241,9 +346,11 @@ local function EnemyAlarm(name, class, colors, kos) end end -local function StealthAlarm(name) - local msg = ("%s Detected!"):format(name); +local function StealthAlarm(spell, name) + local msg = ("%s Detected!"):format(spell); HeadsUpAlarm(msg, CombatText_StandardScroll, 1, 0.5, 0); + print(("%s has %sed nearby!"):format(name, spell)) + Stealth_Emote(name) end function PLUGIN:UpdateSummary() @@ -479,7 +586,7 @@ function PLUGIN:COMBAT_LOG_EVENT_UNFILTERED(event, timestamp, event, _, srcGUID, local srcType = GetSourceType(srcGUID) if(srcType and (srcType == 0 or srcType == 8) and isHostile) then if(event == "SPELL_AURA_APPLIED" and (spellName == L["Stealth"] or spellName == L["Prowl"])) then - StealthAlarm(spellName) + StealthAlarm(spellName, srcName) end if(dstGUID == playerGUID) then PLUGIN.HitBy = srcGUID @@ -522,6 +629,7 @@ function PLUGIN:EventDistributor(event, ...) end if(SVAOW_Cache[guid]) then HeadsUpAlarm("Kill On Sight!", CombatText_StandardScroll, 1, 0, 0, "crit") + KOS_Emote() end end elseif(event == "PLAYER_DEAD") then @@ -838,75 +946,6 @@ local Switch_OnClick = function(self, button) end --[[ ########################################################## -MUNGLUNCH's FAVORITE EMOTE GENERATOR -########################################################## -]]-- -local SpecialEmotes = { - "ROFL", - "CACKLE", - "GIGGLE", - "GRIN", - "SMIRK", - "MOON", - "LICK", - "YAWN", - "FLEX", - "TICKLE", - "TAUNT", - "SHOO", - "PRAY", - "SPIT", - "MOCK", - "GLOAT", - "PITY", - "VIOLIN", - "BYE", -} - -local LowHealthPlayerEmotes = { - "ROFL", - "CACKLE", - "GIGGLE", - "GRIN", - "SMIRK", - "MOON", - "LICK", - "YAWN", - "BITE" -} - -local LowHealthTargetEmotes = { - "ROFL", - "CACKLE", - "FLEX", - "TICKLE", - "TAUNT", - "SHOO", - "PRAY", - "SPIT", - "MOCK", - "GLOAT", - "PITY", - "VIOLIN", - "BYE", -} - -function SVUIEmote() - local index = random(1,#SpecialEmotes) - DoEmote(SpecialEmotes[index]) -end - -local function LowHealth_PlayerEmote() - local index = random(1,#LowHealthPlayerEmotes) - DoEmote(LowHealthPlayerEmotes[index]) -end - -local function LowHealth_TargetEmote() - local index = random(1,#LowHealthTargetEmotes) - DoEmote(LowHealthTargetEmotes[index]) -end ---[[ -########################################################## BUILD FUNCTION ########################################################## ]]-- diff --git a/Interface/AddOns/SVUI_StyleOMatic/SVUI_StyleOMatic.lua b/Interface/AddOns/SVUI_StyleOMatic/SVUI_StyleOMatic.lua index eac7d11..d87bed5 100644 --- a/Interface/AddOns/SVUI_StyleOMatic/SVUI_StyleOMatic.lua +++ b/Interface/AddOns/SVUI_StyleOMatic/SVUI_StyleOMatic.lua @@ -794,8 +794,7 @@ CONFIGS[SCHEMA] = { ["AtlasLoot"] = true, ["SexyCooldown"] = true, ["Lightheaded"] = true, - ["Outfitter"] = true, - ["WeakAuras"] = true, + ["Outfitter"] = true, ["Quartz"] = true, ["TomTom"] = true, ["TinyDPS"] = true, diff --git a/Interface/AddOns/SVUI_StyleOMatic/addons/auctionhouse.lua b/Interface/AddOns/SVUI_StyleOMatic/addons/auctionhouse.lua index 2a79c6f..ed8797a 100644 --- a/Interface/AddOns/SVUI_StyleOMatic/addons/auctionhouse.lua +++ b/Interface/AddOns/SVUI_StyleOMatic/addons/auctionhouse.lua @@ -52,16 +52,7 @@ local AuctionBidButtons = { "AuctionsStackSizeMaxButton", "AuctionsNumStacksMaxButton", } -local AuctionMoneyFields = { - "BrowseBidPriceSilver", - "BrowseBidPriceCopper", - "BidBidPriceSilver", - "BidBidPriceCopper", - "StartPriceSilver", - "StartPriceCopper", - "BuyoutPriceSilver", - "BuyoutPriceCopper" -} + local AuctionTextFields = { "BrowseName", "BrowseMinLevel", @@ -71,7 +62,15 @@ local AuctionTextFields = { "AuctionsStackSizeEntry", "AuctionsNumStacksEntry", "StartPriceGold", - "BuyoutPriceGold" + "BuyoutPriceGold", + "BrowseBidPriceSilver", + "BrowseBidPriceCopper", + "BidBidPriceSilver", + "BidBidPriceCopper", + "StartPriceSilver", + "StartPriceCopper", + "BuyoutPriceSilver", + "BuyoutPriceCopper" } --[[ ########################################################## @@ -199,18 +198,10 @@ local function AuctionStyle() end end - for _,field in pairs(AuctionTextFields)do + for _,field in pairs(AuctionTextFields)do _G[field]:SetEditboxTemplate() _G[field]:SetTextInsets(-1, -1, -2, -2) - end - - for _,field in pairs(AuctionMoneyFields)do - local frame = _G[field] - frame:SetEditboxTemplate() - frame.Panel:Point("TOPLEFT", -2, 1) - frame.Panel:Point("BOTTOMRIGHT", -12, -1) - frame:SetTextInsets(-1, -1, -2, -2) - end + end BrowseMaxLevel:Point("LEFT", BrowseMinLevel, "RIGHT", 8, 0) AuctionsStackSizeEntry.Panel:SetAllPoints() diff --git a/Interface/AddOns/SVUI_StyleOMatic/addons/guild.lua b/Interface/AddOns/SVUI_StyleOMatic/addons/guild.lua index f8f0c63..c88d0c6 100644 --- a/Interface/AddOns/SVUI_StyleOMatic/addons/guild.lua +++ b/Interface/AddOns/SVUI_StyleOMatic/addons/guild.lua @@ -288,7 +288,6 @@ local function GuildFrameStyle() end STYLE:ApplyWindowHolder(GuildFrame) - GuildLevelFrame:Die() STYLE:ApplyCloseButtonStyle(GuildMemberDetailCloseButton) STYLE:ApplyCloseButtonStyle(GuildFrameCloseButton) @@ -334,20 +333,24 @@ local function GuildFrameStyle() GuildRecruitmentHealerButton.checkButton:SetCheckboxTemplate(true) GuildRecruitmentDamagerButton.checkButton:SetCheckboxTemplate(true) - GuildXPFrame:ClearAllPoints() - GuildXPFrame:Point("TOP", GuildFrame, "TOP", 0, -40) - GuildFactionBar:RemoveTextures() GuildFactionBar.progress:SetTexture([[Interface\AddOns\SVUI\assets\artwork\Template\DEFAULT]]) GuildFactionBar:SetPanelTemplate("Inset") GuildFactionBar.Panel:Point("TOPLEFT", GuildFactionBar.progress, "TOPLEFT", -1, 1) GuildFactionBar.Panel:Point("BOTTOMRIGHT", GuildFactionBar, "BOTTOMRIGHT", 1, 1) - GuildXPBar:RemoveTextures() - GuildXPBar.progress:SetTexture([[Interface\AddOns\SVUI\assets\artwork\Template\DEFAULT]]) - GuildXPBar:SetPanelTemplate("Inset") - GuildXPBar.Panel:Point("TOPLEFT", GuildXPBar, "TOPLEFT", -1, -3) - GuildXPBar.Panel:Point("BOTTOMRIGHT", GuildXPBar, "BOTTOMRIGHT", 0, 1) + if(SV.___interface < 60000) then + GuildLevelFrame:Die() + + GuildXPFrame:ClearAllPoints() + GuildXPFrame:Point("TOP", GuildFrame, "TOP", 0, -40) + + GuildXPBar:RemoveTextures() + GuildXPBar.progress:SetTexture([[Interface\AddOns\SVUI\assets\artwork\Template\DEFAULT]]) + GuildXPBar:SetPanelTemplate("Inset") + GuildXPBar.Panel:Point("TOPLEFT", GuildXPBar, "TOPLEFT", -1, -3) + GuildXPBar.Panel:Point("BOTTOMRIGHT", GuildXPBar, "BOTTOMRIGHT", 0, 1) + end GuildLatestPerkButton:RemoveTextures() GuildLatestPerkButtonIconTexture:SetTexCoord(0.1, 0.9, 0.1, 0.9) diff --git a/Interface/AddOns/SVUI_StyleOMatic/addons/petjournal.lua b/Interface/AddOns/SVUI_StyleOMatic/addons/petjournal.lua index 44fd2b5..fc5b18d 100644 --- a/Interface/AddOns/SVUI_StyleOMatic/addons/petjournal.lua +++ b/Interface/AddOns/SVUI_StyleOMatic/addons/petjournal.lua @@ -95,6 +95,7 @@ local function PetJournalStyle() STYLE:ApplyTabStyle(PetJournalParentTab1) STYLE:ApplyTabStyle(PetJournalParentTab2) STYLE:ApplyCloseButtonStyle(PetJournalParentCloseButton) + MountJournal:RemoveTextures() MountJournal.LeftInset:RemoveTextures() MountJournal.RightInset:RemoveTextures() @@ -104,6 +105,7 @@ local function PetJournalStyle() MountJournalListScrollFrame:RemoveTextures() MountJournalMountButton:SetButtonTemplate() MountJournalSearchBox:SetEditboxTemplate() + STYLE:ApplyScrollFrameStyle(MountJournalListScrollFrameScrollBar) MountJournal.MountDisplay:SetFixedPanelTemplate("Comic") @@ -244,6 +246,24 @@ local function PetJournalStyle() PetJournalPetCardXPBar:RemoveTextures() PetJournalPetCardXPBar:SetPanelTemplate('Default') PetJournalPetCardXPBar:SetStatusBarTexture([[Interface\AddOns\SVUI\assets\artwork\Template\DEFAULT]]) + + if(SV.___interface >= 60000) then + STYLE:ApplyTabStyle(PetJournalParentTab3) + ToyBox:RemoveTextures() + ToyBoxProgressBar:SetPanelTemplate("Bar", true) + ToyBoxSearchBox:SetEditboxTemplate() + ToyBoxFilterButton:SetButtonTemplate() + STYLE:ApplyDropdownStyle(ToyBoxFilterDropDown) + ToyBoxIconsFrame:SetBasicPanel() + + for i = 1, 18 do + local gName = ("ToySpellButton%d"):format(i) + local button = _G[gName] + if(button) then + button:SetButtonTemplate() + end + end + end end --[[ ########################################################## diff --git a/Interface/AddOns/SVUI_StyleOMatic/addons/thirdparty/WeakAuras.lua b/Interface/AddOns/SVUI_StyleOMatic/addons/thirdparty/WeakAuras.lua deleted file mode 100644 index 57616d2..0000000 --- a/Interface/AddOns/SVUI_StyleOMatic/addons/thirdparty/WeakAuras.lua +++ /dev/null @@ -1,82 +0,0 @@ ---[[ -############################################################################## -_____/\\\\\\\\\\\____/\\\________/\\\__/\\\________/\\\__/\\\\\\\\\\\_ # - ___/\\\/////////\\\_\/\\\_______\/\\\_\/\\\_______\/\\\_\/////\\\///__ # - __\//\\\______\///__\//\\\______/\\\__\/\\\_______\/\\\_____\/\\\_____ # - ___\////\\\__________\//\\\____/\\\___\/\\\_______\/\\\_____\/\\\_____ # - ______\////\\\________\//\\\__/\\\____\/\\\_______\/\\\_____\/\\\_____ # - _________\////\\\______\//\\\/\\\_____\/\\\_______\/\\\_____\/\\\_____ # - __/\\\______\//\\\______\//\\\\\______\//\\\______/\\\______\/\\\_____ # - _\///\\\\\\\\\\\/________\//\\\________\///\\\\\\\\\/____/\\\\\\\\\\\_# - ___\///////////___________\///___________\/////////_____\///////////_# -############################################################################## -S U P E R - V I L L A I N - U I By: Munglunch # -############################################################################## -########################################################## -LOCALIZED LUA FUNCTIONS -########################################################## -]]-- ---[[ GLOBALS ]]-- -local _G = _G; -local unpack = _G.unpack; -local select = _G.select; -local pairs = _G.pairs; -local string = _G.string; ---[[ STRING METHODS ]]-- -local format = string.format; ---[[ -########################################################## -GET ADDON DATA -########################################################## -]]-- -local SV, L = unpack(SVUI); -local STYLE = _G.StyleVillain; ---[[ -########################################################## -WEAKAURAS -########################################################## -]]-- -local ProxyCreateFunc = function() return end -local ProxyModifyFunc = function() return end - -local function Style_WeakAuras(frame) - if not frame.Panel then - STYLE:ApplyFrameStyle(frame,"Transparent") - frame.icon.OldAlpha = frame.icon.SetAlpha - frame.icon.SetAlpha = function(self, ...) - frame.icon.OldAlpha(self, ...) - frame.Panel:SetAlpha(...) - end - end - SV:AddCD(frame.cooldown) - frame.icon:SetTexCoord(0.1,0.9,0.1,0.9) - frame.icon.SetTexCoord = SV.fubar -end - -local function Create_WeakAuras(parent, data) - local region = ProxyCreateFunc(parent, data) - Style_WeakAuras(region) - return region -end - -local function Modify_WeakAuras(parent, region, data) - ProxyModifyFunc(parent, region, data) - Style_WeakAuras(region) -end - -local function StyleWeakAuras() - assert(WeakAuras, "AddOn Not Loaded") - - ProxyCreateFunc = WeakAuras.regionTypes.icon.create - ProxyModifyFunc = WeakAuras.regionTypes.icon.modify - - WeakAuras.regionTypes.icon.create = Create_WeakAuras - WeakAuras.regionTypes.icon.modify = Modify_WeakAuras - - for weakAura, _ in pairs(WeakAuras.regions) do - if WeakAuras.regions[weakAura].regionType == 'icon' then - Style_WeakAuras(WeakAuras.regions[weakAura].region) - end - end -end -STYLE:SaveAddonStyle("WeakAuras", StyleWeakAuras, nil, true) \ No newline at end of file diff --git a/Interface/AddOns/SVUI_StyleOMatic/addons/thirdparty/_load.xml b/Interface/AddOns/SVUI_StyleOMatic/addons/thirdparty/_load.xml index aa9bc3a..2e19d58 100644 --- a/Interface/AddOns/SVUI_StyleOMatic/addons/thirdparty/_load.xml +++ b/Interface/AddOns/SVUI_StyleOMatic/addons/thirdparty/_load.xml @@ -24,5 +24,4 @@ <Script file='TomTom.lua'/> <Script file='TradeSkillDW.lua'/> <Script file='VEM.lua'/> - <Script file='WeakAuras.lua'/> </Ui> \ No newline at end of file diff --git a/Interface/AddOns/SVUI_StyleOMatic/addons/worldmap.lua b/Interface/AddOns/SVUI_StyleOMatic/addons/worldmap.lua index a903bd7..e9f259a 100644 --- a/Interface/AddOns/SVUI_StyleOMatic/addons/worldmap.lua +++ b/Interface/AddOns/SVUI_StyleOMatic/addons/worldmap.lua @@ -28,6 +28,7 @@ local function AdjustMapLevel() WorldMapArchaeologyDigSites:SetFrameLevel(6) WorldMapArchaeologyDigSites:SetFrameStrata('DIALOG') end + local function WorldMap_SmallView() WorldMapFrame.Panel:ClearAllPoints() WorldMapFrame.Panel:SetAllPoints(WorldMapFrame) @@ -35,6 +36,7 @@ local function WorldMap_SmallView() WorldMapFrame.backdrop:Point("TOPLEFT", WorldMapFrame.Panel, 2, 2) WorldMapFrame.backdrop:Point("BOTTOMRIGHT", WorldMapFrame.Panel, 2, -2) end + local function WorldMap_FullView() WorldMapFrame.Panel:ClearAllPoints() WorldMapFrame.Panel:Point("TOPLEFT", WorldMapDetailFrame, "TOPLEFT", -12, 70) @@ -43,6 +45,7 @@ local function WorldMap_FullView() WorldMapFrame.backdrop:Point("TOPLEFT", WorldMapFrame.Panel, 2, 2) WorldMapFrame.backdrop:Point("BOTTOMRIGHT", WorldMapFrame.Panel, 2, -2) end + local function WorldMap_QuestView() WorldMap_FullView() if not WorldMapQuestDetailScrollFrame.Panel then @@ -74,21 +77,32 @@ local function WorldMap_QuestView() WorldMapQuestScrollFrame.spellTex:Size(520, 1033) WorldMapQuestScrollFrame.spellTex:SetTexCoord(0, 1, 0.02, 1) end -end +end + local function WorldMap_OnShow() WorldMapFrame:RemoveTextures() if not SV.db.SVMap.tinyWorldMap then BlackoutWorld:SetTexture(0, 0, 0, 1) else BlackoutWorld:SetTexture(0,0,0,0) - end - if WORLDMAP_SETTINGS.size == WORLDMAP_FULLMAP_SIZE then - WorldMap_FullView() - elseif WORLDMAP_SETTINGS.size == WORLDMAP_WINDOWED_SIZE then - WorldMap_SmallView() - elseif WORLDMAP_SETTINGS.size == WORLDMAP_QUESTLIST_SIZE then - WorldMap_QuestView() - end + end + + if(SV.___interface >= 60000) then + if WORLDMAP_SETTINGS.size == WORLDMAP_FULLMAP_SIZE then + WorldMap_FullView() + elseif WORLDMAP_SETTINGS.size == WORLDMAP_WINDOWED_SIZE then + WorldMap_SmallView() + end + else + if WORLDMAP_SETTINGS.size == WORLDMAP_FULLMAP_SIZE then + WorldMap_FullView() + elseif WORLDMAP_SETTINGS.size == WORLDMAP_WINDOWED_SIZE then + WorldMap_SmallView() + elseif WORLDMAP_SETTINGS.size == WORLDMAP_QUESTLIST_SIZE then + WorldMap_QuestView() + end + end + WorldMapFrameAreaLabel:SetFontTemplate(nil, 50, "OUTLINE") WorldMapFrameAreaLabel:SetShadowOffset(2, -2) WorldMapFrameAreaLabel:SetTextColor(0.90, 0.8294, 0.6407) @@ -114,35 +128,46 @@ local function WorldMapStyle() if SV.db.SVStyle.blizzard.enable ~= true or SV.db.SVStyle.blizzard.worldmap ~= true then return end WorldMapFrame:SetFrameLevel(2) + STYLE:ApplyScrollFrameStyle(WorldMapQuestScrollFrameScrollBar) STYLE:ApplyScrollFrameStyle(WorldMapQuestDetailScrollFrameScrollBar, 4) STYLE:ApplyScrollFrameStyle(WorldMapQuestRewardScrollFrameScrollBar, 4) - WorldMapFrame:SetPanelTemplate("Transparent") + + WorldMapFrame:SetBasicPanel() WorldMapFrame.Panel:SetFrameLevel(1) WorldMapFrame.backdrop = CreateFrame("Frame", nil, WorldMapFrame) WorldMapFrame.backdrop:SetAllPoints(WorldMapFrame) WorldMapFrame.backdrop:SetFrameLevel(0) WorldMapFrame.backdrop:SetPanelTemplate("Action"); + WorldMapDetailFrame:SetFrameLevel(4) - WorldMapArchaeologyDigSites:SetFrameLevel(6) - WorldMapDetailFrame:SetPanelTemplate("Inset") + WorldMapDetailFrame:SetBasicPanel() WorldMapDetailFrame.Panel:SetFrameLevel(3) - STYLE:ApplyCloseButtonStyle(WorldMapFrameCloseButton) - STYLE:ApplyCloseButtonStyle(WorldMapFrameSizeDownButton) - STYLE:ApplyCloseButtonStyle(WorldMapFrameSizeUpButton) + + WorldMapArchaeologyDigSites:SetFrameLevel(6) + WorldMapFrameSizeDownButton:SetFrameLevel(999) WorldMapFrameSizeUpButton:SetFrameLevel(999) WorldMapFrameCloseButton:SetFrameLevel(999) + + STYLE:ApplyCloseButtonStyle(WorldMapFrameCloseButton) + STYLE:ApplyCloseButtonStyle(WorldMapFrameSizeDownButton) + STYLE:ApplyCloseButtonStyle(WorldMapFrameSizeUpButton) + STYLE:ApplyDropdownStyle(WorldMapLevelDropDown) STYLE:ApplyDropdownStyle(WorldMapZoneMinimapDropDown) STYLE:ApplyDropdownStyle(WorldMapContinentDropDown) STYLE:ApplyDropdownStyle(WorldMapZoneDropDown) STYLE:ApplyDropdownStyle(WorldMapShowDropDown) - WorldMapZoomOutButton:SetButtonTemplate() - WorldMapTrackQuest:SetCheckboxTemplate(true) + + if(SV.___interface < 60000) then + WorldMapZoomOutButton:SetButtonTemplate() + WorldMapTrackQuest:SetCheckboxTemplate(true) + hooksecurefunc("WorldMapFrame_SetFullMapView", WorldMap_FullView) + hooksecurefunc("WorldMapFrame_SetQuestMapView", WorldMap_QuestView) + end + WorldMapFrame:HookScript("OnShow", WorldMap_OnShow) - hooksecurefunc("WorldMapFrame_SetFullMapView", WorldMap_FullView) - hooksecurefunc("WorldMapFrame_SetQuestMapView", WorldMap_QuestView) hooksecurefunc("WorldMap_ToggleSizeUp", WorldMap_OnShow) BlackoutWorld:SetParent(WorldMapFrame.backdrop) end