diff --git a/SVUI_!Core/system/funstuff.lua b/SVUI_!Core/system/funstuff.lua index a1e851b..edadeb9 100644 --- a/SVUI_!Core/system/funstuff.lua +++ b/SVUI_!Core/system/funstuff.lua @@ -310,54 +310,69 @@ local COMIX_DATA = { {0.75,1,0.75,1} }, { - {220, 210, 50, -50, 220, 210, -1, 5}, - {230, 210, 50, 5, 280, 210, -5, 1}, - {280, 160, 1, 50, 280, 210, -1, 5}, - {220, 210, 50, -50, 220, 210, -1, 5}, - {210, 190, 50, 50, 220, 210, -1, 5}, - {220, 210, 50, -50, 220, 210, -1, 5}, - {230, 210, 50, 5, 280, 210, -5, 1}, - {280, 160, 1, 50, 280, 210, -1, 5}, - {220, 210, 50, -50, 220, 210, -1, 5}, - {210, 190, 50, 50, 220, 210, -1, 5}, - {220, 210, 50, -50, 220, 210, -1, 5}, - {230, 210, 50, 5, 280, 210, -5, 1}, - {280, 160, 1, 50, 280, 210, -1, 5}, - {220, 210, 50, -50, 220, 210, -1, 5}, - {210, 190, 50, 50, 220, 210, -1, 5}, - {210, 190, 50, 50, 220, 210, -1, 5} + {220, 210, 20, -20, 220, 210, -1, 5}, + {230, 210, 20, 5, 280, 210, -5, 1}, + {280, 160, 1, 20, 280, 210, -1, 5}, + {220, 210, 20, -20, 220, 210, -1, 5}, + {210, 190, 20, 20, 220, 210, -1, 5}, + {220, 210, 20, -20, 220, 210, -1, 5}, + {230, 210, 20, 5, 280, 210, -5, 1}, + {280, 160, 1, 20, 280, 210, -1, 5}, + {220, 210, 20, -20, 220, 210, -1, 5}, + {210, 190, 20, 20, 220, 210, -1, 5}, + {220, 210, 20, -20, 220, 210, -1, 5}, + {230, 210, 20, 5, 280, 210, -5, 1}, + {280, 160, 1, 20, 280, 210, -1, 5}, + {220, 210, 20, -20, 220, 210, -1, 5}, + {210, 190, 20, 20, 220, 210, -1, 5}, + {210, 190, 20, 20, 220, 210, -1, 5} } }; SV.Comix.Ready = true; -function SV.Comix:LaunchPopup() +--/script SVUI.Comix:LaunchPremium() +function SV.Comix:LaunchPremium() self.Ready = false + local coords, step1_x, step1_y, step2_x, step2_y, size, offsets; + local key = random(1, 16); + coords = COMIX_DATA[1][key]; + if(not coords) then return end + offsets = COMIX_DATA[2][key] + step1_x = offsets[1] * 0.1; + step1_y = offsets[2] * 0.1; + step2_x = (offsets[5] * 0.1) + offsets[3]; + step2_y = (offsets[6] * 0.1) + offsets[4]; + self.Premium.tex:SetTexCoord(coords[1],coords[2],coords[3],coords[4]) + self.Premium.bg.tex:SetTexCoord(coords[1],coords[2],coords[3],coords[4]) + -- self.Premium.anim[1]:SetOffset(offsets[1],offsets[2]) + -- self.Premium.anim[2]:SetOffset(offsets[3],offsets[4]) + self.Premium.anim[1]:SetOffset(step1_x, step1_y); + self.Premium.anim[2]:SetOffset(offsets[3],offsets[4]); + self.Premium.anim[3]:SetOffset(0,0) + -- self.Premium.bg.anim[1]:SetOffset(offsets[5],offsets[6]) + -- self.Premium.bg.anim[2]:SetOffset(offsets[7],offsets[8]) + self.Premium.bg.anim[1]:SetOffset(step2_x, step2_y); + self.Premium.bg.anim[2]:SetOffset(offsets[7],offsets[8]); + self.Premium.bg.anim[3]:SetOffset(0,0) + + self.Premium.anim:Play() + self.Premium.bg.anim:Play() +end +--/script SVUI.Comix:LaunchPopup() +function SV.Comix:LaunchPopup() + self.Ready = false local coords, step1_x, step1_y, step2_x, step2_y, size, offsets; local rng = random(0, 32); local key = random(1, 16); coords = COMIX_DATA[1][key]; if(not coords) then return end - if((rng > 30) and (SV.db.FunStuff.comix == '1')) then - if(rng == 31) then - offsets = COMIX_DATA[2][key] - self.Premium.tex:SetTexCoord(coords[1],coords[2],coords[3],coords[4]) - self.Premium.bg.tex:SetTexCoord(coords[1],coords[2],coords[3],coords[4]) - self.Premium.anim[1]:SetOffset(offsets[1],offsets[2]) - self.Premium.anim[2]:SetOffset(offsets[3],offsets[4]) - self.Premium.anim[3]:SetOffset(0,0) - self.Premium.bg.anim[1]:SetOffset(offsets[5],offsets[6]) - self.Premium.bg.anim[2]:SetOffset(offsets[7],offsets[8]) - self.Premium.bg.anim[3]:SetOffset(0,0) - self.Premium.anim:Play() - self.Premium.bg.anim:Play() - elseif(rng == 32) then - ComixToastyPanelBG.anim[2]:SetOffset(256, -256) - ComixToastyPanelBG.anim[2]:SetOffset(0, 0) - ComixToastyPanelBG.anim:Play() - PlaySoundFile([[Interface\AddOns\SVUI_!Core\assets\sounds\toasty.mp3]]) - end + if((rng == 32) and (SV.db.FunStuff.comix == '1')) then + ComixToastyPanelBG.anim[2]:SetOffset(256, -256) + ComixToastyPanelBG.anim[2]:SetOffset(0, 0) + ComixToastyPanelBG.anim:Play() + PlaySoundFile([[Interface\AddOns\SVUI_!Core\assets\sounds\toasty.mp3]]) elseif(rng < 24) then step1_x = random(-150, 150); if(step1_x > -20 and step1_x < 20) then step1_x = step1_x * 3 end @@ -636,7 +651,7 @@ local function InitializeFunStuff() comix.Premium = _G["SVUI_ComixPopup3"] comix.Basic:SetParent(SV.Screen) - comix.Basic:SetSize(128,128) + comix.Basic:SetSize(100,100) comix.Basic.tex:SetTexCoord(0,0.25,0,0.25) SV.Animate:Kapow(comix.Basic, true, true) comix.Basic:SetAlpha(0) @@ -644,7 +659,7 @@ local function InitializeFunStuff() comix.Basic.anim[2]:SetScript("OnFinished", Comix_OnUpdate) comix.Deluxe:SetParent(SV.Screen) - comix.Deluxe:SetSize(128,128) + comix.Deluxe:SetSize(100,100) comix.Deluxe.tex:SetTexCoord(0,0.25,0,0.25) SV.Animate:RandomSlide(comix.Deluxe, true) comix.Deluxe:SetAlpha(0) @@ -652,13 +667,17 @@ local function InitializeFunStuff() comix.Deluxe.anim[3]:SetScript("OnFinished", Comix_OnUpdate) comix.Premium:SetParent(SV.Screen) + comix.Premium:SetSize(96,96); comix.Premium.tex:SetTexCoord(0,0.25,0,0.25) + --comix.Premium.tex:SetBlendMode('ADD') SV.Animate:RandomSlide(comix.Premium, true) comix.Premium:SetAlpha(0) comix.Premium:Show() comix.Premium.anim[3]:SetScript("OnFinished", Comix_OnUpdate) + comix.Premium.bg:SetSize(96,96); comix.Premium.bg.tex:SetTexCoord(0,0.25,0,0.25) + comix.Premium.bg.tex:SetBlendMode('ADD') SV.Animate:RandomSlide(comix.Premium.bg, false) comix.Premium.bg:SetAlpha(0) comix.Premium.bg.anim[3]:SetScript("OnFinished", Comix_OnUpdate) diff --git a/SVUI_!Options/SVUI_!Options.lua b/SVUI_!Options/SVUI_!Options.lua index 4d8dd1d..31ec2d7 100644 --- a/SVUI_!Options/SVUI_!Options.lua +++ b/SVUI_!Options/SVUI_!Options.lua @@ -56,7 +56,7 @@ local DockableAddons = { ["Recount"] = L["Recount"], ["TinyDPS"] = L["TinyDPS"], ["Omen"] = L["Omen"], - --["Details"] = L["Details"] + ["Details"] = L["Details"] }; local NONE = _G.NONE; diff --git a/SVUI_Maps/SVUI_Maps.lua b/SVUI_Maps/SVUI_Maps.lua index f425182..a7e4ff1 100644 --- a/SVUI_Maps/SVUI_Maps.lua +++ b/SVUI_Maps/SVUI_Maps.lua @@ -732,7 +732,7 @@ function MOD:RefreshMiniMap() --SV.Dock.TopRight:SetSize(MM_WIDTH, (MM_HEIGHT + 4)) end - self.InfoTop.Text:SetSize(MM_WIDTH,28) + --self.InfoTop.Text:SetSize(MM_WIDTH,28) self.InfoBottom.Text:SetSize(MM_WIDTH,32) self:RefreshZoneText() @@ -883,15 +883,20 @@ function MOD:Load() local mwfont = SV.media.font.narrator - self.InfoTop:SetPoint("TOPLEFT", self.Holder, "TOPLEFT", 2, -2) - self.InfoTop:SetSize(100, 22) + self.InfoTop:SetPoint("TOPLEFT", self.Holder, "TOPLEFT", 4, -4) + --self.InfoTop:SetSize(100, 22) self.InfoTop:SetStyle("Frame") self.InfoTop:SetPanelColor("yellow") self.InfoTop:SetBackdropColor(1, 1, 0, 1) self.InfoTop:SetFrameLevel(Minimap:GetFrameLevel() + 2) self.InfoTop.Text:SetShadowColor(0, 0, 0, 0.3) - self.InfoTop.Text:SetShadowOffset(2, -2) + self.InfoTop.Text:SetShadowOffset(2, -2); + + self.InfoTop.Panel:ClearAllPoints(); + self.InfoTop.Panel:SetPoint("TOPLEFT", self.InfoTop.Text, "TOPLEFT", -4, 4); + self.InfoTop.Panel:SetPoint("BOTTOMRIGHT", self.InfoTop.Text, "BOTTOMRIGHT", 4, -4); + self.InfoTop.Panel:SetAttribute("panelLocked", true); self.InfoBottom:SetPoint("BOTTOMRIGHT", self.Holder, "BOTTOMRIGHT", 2, -3) self.InfoBottom:SetSize(MM_WIDTH, 28) diff --git a/SVUI_Maps/SVUI_Maps.xml b/SVUI_Maps/SVUI_Maps.xml index e1e7556..c88817f 100644 --- a/SVUI_Maps/SVUI_Maps.xml +++ b/SVUI_Maps/SVUI_Maps.xml @@ -133,13 +133,17 @@ </Frame> <Frame name="SVUI_MinimapInfoTop" parent="Minimap"> - <Size x="100" y="22"/> + <Size x="18" y="18"/> <Anchors> - <Anchor point="TOPLEFT" relativeTo="SVUI_MinimapFrame" relativePoint="TOPLEFT" x="2" y="-2" /> + <Anchor point="TOPLEFT" relativeTo="SVUI_MinimapFrame" relativePoint="TOPLEFT" x="4" y="-4" /> </Anchors> <Layers> <Layer level="ARTWORK"> - <FontString parentKey="Text" inherits="SVUI_Font_MinimapInfo" text="Meanwhile" justifyH="CENTER" justifyV="MIDDLE" setAllPoints="true" /> + <FontString parentKey="Text" inherits="SVUI_Font_MinimapInfo" text="Meanwhile" justifyH="CENTER" justifyV="MIDDLE"> + <Anchors> + <Anchor point="TOPLEFT" relativeTo="$parent" relativePoint="TOPLEFT" x="2" y="-2" /> + </Anchors> + </FontString> </Layer> </Layers> </Frame> diff --git a/SVUI_Skins/Loader.lua b/SVUI_Skins/Loader.lua index 977ff0e..e3a6ded 100644 --- a/SVUI_Skins/Loader.lua +++ b/SVUI_Skins/Loader.lua @@ -128,7 +128,7 @@ SV.defaults[Schema] = { ['Bugsack'] = true, ['Clique'] = true, ['Cooline'] = true, - --['Details'] = true, + ['Details'] = true, ['DBM'] = true, ['DXE'] = true, ['LightHeaded'] = true, diff --git a/SVUI_Skins/components/addons/Details.lua b/SVUI_Skins/components/addons/Details.lua index 2b7110f..3db6d18 100644 --- a/SVUI_Skins/components/addons/Details.lua +++ b/SVUI_Skins/components/addons/Details.lua @@ -20,15 +20,21 @@ STYLE (IN DEVELOPMENT) ########################################################## ]]-- local function StyleDetails() - assert(_detalhes, "AddOn Not Loaded") + assert(DetailsBaseFrame1, "AddOn Not Loaded") - local _detalhes = _G._detalhes local Loc = LibStub ("AceLocale-3.0"):GetLocale("Details") - local details_frame = _detalhes.baseframe; - if(details_frame) then - details_frame:RemoveTextures(); - details_frame:SetStyle("Frame", "Transparent"); + for i=1, 10 do + local details_frame = _G['DetailsBaseFrame'..i]; + if(details_frame) then + DetailsBaseFrame1:RemoveTextures(); + DetailsBaseFrame1:SetStyle("Frame", "Transparent"); + end + -- local up_frame = _G['DetailsUpFrameInstance'..i]; + -- if(up_frame) then + -- up_frame:RemoveTextures(); + -- up_frame:SetStyle("Frame", "Transparent"); + -- end end end --[[ diff --git a/SVUI_Skins/components/docklet.lua b/SVUI_Skins/components/docklet.lua index f2eba66..3bc028d 100644 --- a/SVUI_Skins/components/docklet.lua +++ b/SVUI_Skins/components/docklet.lua @@ -303,18 +303,17 @@ end ]]-- --/script print(table.tostring(_detailhes)) DOCK_EMBEDS["Details"] = function(self) - if((not IsAddOnLoaded("Details")) or (not _G._detalhes)) then return false end - + --print('Details') + if(not IsAddOnLoaded("Details")) then return false end + --print('Loaded') local width = self:GetWidth() local height = SV.Dock.BottomRight.Window:GetHeight(); - local _detalhes = _G._detalhes; - local details_window = _detalhes.baseframe; - if(details_window) then - details_window:ClearAllPoints() - details_window:SetParent(self) - details_window:SetSize(width, height) - details_window:SetPoint("BOTTOM", self, "BOTTOM", 0, 0) - self.Framelink = details_window + if(DetailsBaseFrame1) then + DetailsBaseFrame1:ClearAllPoints() + DetailsBaseFrame1:SetParent(self) + DetailsBaseFrame1:SetSize(width, height) + DetailsBaseFrame1:SetPoint("BOTTOM", self, "BOTTOM", 0, 0) + self.Framelink = DetailsBaseFrame1 return true else return false @@ -407,6 +406,15 @@ function MOD:SetEmbedHandlers() end function MOD:RegisterAddonDocklets() + if(self:FindDockables()) then + self.Docklet:SetDocked(true); + self.Docklet:Enable(); + else + self.Docklet:Disable(); + self.Docklet:SetDocked(false); + return + end + local embed1,embed2,enabled1,enabled2 = RequestEmbedded(); local addon1, addon2, extraTip = "", "", ""; local active1, active2 = false, false; @@ -442,12 +450,6 @@ function MOD:RegisterAddonDocklets() active1, addon1 = self.Docklet.Dock1:EmbedAddon(embed1) end - if(self:FindDockables()) then - self.Docklet:Enable(); - else - self.Docklet:Disable(); - end - if(active1 or active2) then if(active2) then extraTip = TIP_RIGHT_PATTERN:format(addon2) @@ -487,7 +489,7 @@ function MOD:GetDockables() end end else - if(IsAddOnLoaded(addon) and (not test1:find(key)) and (not test2:find(key))) then + if(IsAddOnLoaded(addon) and (not test1:find(addon)) and (not test2:find(addon))) then if(not allowed1) then tinsert(t,{ title = "Set Primary", divider = true }); allowed1 = true; @@ -512,7 +514,7 @@ function MOD:GetDockables() end end else - if(IsAddOnLoaded(addon) and (not test1:find(key)) and (not test2:find(key))) then + if(IsAddOnLoaded(addon) and (not test1:find(addon)) and (not test2:find(addon))) then if(not allowed2) then tinsert(t,{ title = "Set Secondary", divider = true }); allowed2 = true;