diff --git a/SVUI_!Core/system/core.lua b/SVUI_!Core/system/core.lua
index 392dfe9..6c35704 100644
--- a/SVUI_!Core/system/core.lua
+++ b/SVUI_!Core/system/core.lua
@@ -246,6 +246,7 @@ SV.defaults = {
},
["general"] = {
["loginmessage"] = true,
+ ["logincredits"] = true,
["cooldown"] = true,
["saveDraggable"] = false,
["taintLog"] = false,
@@ -873,7 +874,9 @@ function SV:Initialize()
collectgarbage("collect");
- self.Timers:ExecuteTimer(self.FlashTitle, 10)
+ if self.db.general.logincredits then
+ self.Timers:ExecuteTimer(self.RollCredits, 10)
+ end
end
--[[
##########################################################
diff --git a/SVUI_!Core/system/credits.lua b/SVUI_!Core/system/credits.lua
index 55e1437..2bed9af 100644
--- a/SVUI_!Core/system/credits.lua
+++ b/SVUI_!Core/system/credits.lua
@@ -60,12 +60,16 @@ The Wowinterface Community
local CreditFrame = _G["SVUI_CreditFrame"];
CreditFrame.Title = _G["SVUI_CreditFrameTitle"];
CreditFrame.List = _G["SVUI_CreditFrameList"];
+local TitleFrame = _G["SVUI_SuperTitleFrame"];
+TitleFrame.Title = _G["SVUI_SuperTitleFrameTitle"];
+TitleFrame.List = _G["SVUI_SuperTitleFrameList"];
local playerName = UnitName("player");
+local playerClass = UnitClass("player");
SV.Credits = {};
SV.Credits["author"] = {
- "Munglunch",
+ playerName,
};
SV.Credits["council"] = {
@@ -102,7 +106,10 @@ SV.Credits["community"] = {
"Shinzou", "Autolykus", "Taotao", "ColorsGaming", "Necroo"
};
-local ROLLED_CREDITS = 1;
+local WEEKDAY, MONTHNUM, DAYNUM, YEARNUM = CalendarGetDate();
+local ISSUE_TEXT = ("Issue: #%d, Volume: #%d"):format(DAYNUM, MONTHNUM);
+local EPISODE_TEXT;
+local ROLLED_CREDITS = 6;
local DELAY = 0;
local CREDITS_DATA = {
{"Produced By: ", "council"},
@@ -112,21 +119,100 @@ local CREDITS_DATA = {
{"Written and Directed By: ", "author"},
};
+local FLAVOR_TITLES = {
+ "The Adventures Of...", "The Legend Of...", "They Call Me...", "The Amazing...", "Tales Of..."
+};
+
+local FLAVOR_TEXTS = {
+ {"%s Of Legend", "The Notorious %s", "Do The %s Dance", "%s: 1, Everyone else: 0", "Chronicles of the %s"},
+ {"Chronicles of the %s %s", "Super %s %s", "The Notorious %s %s"}
+};
+
+local function RollCredits()
+ ROLLED_CREDITS = 1;
+ CreditFrame:CallBack()
+end
+
+local function ShowIssueString()
+ local flavorKey = random(1,2);
+ local flavorList = FLAVOR_TEXTS[flavorKey];
+ local flavorPattern = flavorList[random(1, #flavorList)]
+ if(flavorKey == 1) then
+ EPISODE_TEXT = flavorPattern:format(playerClass)
+ else
+ local currentGroup = GetActiveSpecGroup()
+ local currentSpec = GetSpecialization(false, false, currentGroup);
+ local specText = currentSpec and select(2, GetSpecializationInfo(currentSpec)) or nil
+ if(not specText) then
+ EPISODE_TEXT = "A Day In The Life..."
+ else
+ EPISODE_TEXT = flavorPattern:format(specText, playerClass)
+ end
+ end
+ CreditFrame:SetAlpha(0);
+ CreditFrame:Show();
+ CreditFrame.Title:SetText(ISSUE_TEXT);
+ CreditFrame.List:SetText(EPISODE_TEXT);
+end
+
+local function KillCredits()
+ TitleFrame:SetScript("OnUpdate", nil)
+ TitleFrame:Hide()
+ CreditFrame:SetScript("OnUpdate", nil)
+ CreditFrame:Hide()
+end
+
+local function TitleFrame_OnUpdate(self, elapsed)
+ DELAY = DELAY + elapsed
+ if(DELAY < 3) then return end
+ if(DELAY <= 3.5) then
+ self:FadeOut(1);
+ elseif(DELAY >= 7) then
+ DELAY = 0
+ self:SetScript("OnUpdate", nil)
+ end
+end
+
+local function InitTitleFrame_OnUpdate(self, elapsed)
+ DELAY = DELAY + elapsed
+ if(DELAY < 3) then return end
+ if(DELAY <= 3.5) then
+ self:FadeOut(1);
+ elseif(DELAY > 6 and DELAY <= 7) then
+ ShowIssueString()
+ CreditFrame:FadeIn(1);
+ elseif(DELAY > 9.5 and DELAY <= 10.5) then
+ CreditFrame:FadeOut(1);
+ elseif(DELAY > 14) then
+ DELAY = 0
+ self:SetScript("OnUpdate", nil)
+ RollCredits()
+ end
+end
+
local function CreditFrame_OnUpdate(self, elapsed)
DELAY = DELAY + elapsed
if(DELAY < 3) then return end
if(DELAY <= 3.5) then
- CreditFrame:FadeOut(1,1,0,true);
+ self:FadeOut(1);
elseif(DELAY >= 7) then
DELAY = 0
self:SetScript("OnUpdate", nil)
- if(self.CallBack) then
- self:CallBack()
- end
+ self:CallBack()
end
end
-function CreditFrame:ShowMessage(title, text)
+function TitleFrame:ShowTitle(title, text)
+ self:SetAlpha(0);
+ self:Show();
+ self.Title:SetText(title);
+ self.List:SetText(text);
+ self:FadeIn(1);
+ DELAY = 0;
+ self:SetScript("OnUpdate", TitleFrame_OnUpdate)
+end
+
+function CreditFrame:ShowCredit(title, text)
self:SetAlpha(0);
self:Show();
self.Title:SetText(title);
@@ -136,15 +222,14 @@ function CreditFrame:ShowMessage(title, text)
self:SetScript("OnUpdate", CreditFrame_OnUpdate)
end
-local CreditFrame_CallBack = function(self)
+function CreditFrame:CallBack()
if(ROLLED_CREDITS <= 5) then
local credit = CREDITS_DATA[ROLLED_CREDITS]
local list = SV.Credits[credit[2]];
local name = list and list[random(1, #list)] or credit[2];
ROLLED_CREDITS = ROLLED_CREDITS + 1;
- self:ShowMessage(credit[1], name);
+ self:ShowCredit(credit[1], name);
else
- self.CallBack = nil;
self:Hide();
end
end
@@ -157,14 +242,21 @@ function SV:PrintCredits()
return PRINTED_TEMPLATE:format(investors, contributors, community)
end
-function SV:FlashTitle()
- CreditFrame:ShowMessage("The Adventures of...", playerName);
+function SV:RollCredits()
+ DELAY = 0;
+ SV.Events:On("SPECIAL_FRAMES_CLOSED", KillCredits, true);
+ TitleFrame:SetAlpha(0);
+ TitleFrame:Show();
+ local titleKey = random(1,#FLAVOR_TITLES)
+ local titlePattern = FLAVOR_TITLES[titleKey]
+ TitleFrame:ShowTitle(titlePattern, playerName);
+ TitleFrame.List:SetText(playerName);
+ TitleFrame:FadeIn(1);
+ TitleFrame:SetScript("OnUpdate", InitTitleFrame_OnUpdate);
end
-local function RollCredits()
- ROLLED_CREDITS = 1;
- CreditFrame.CallBack = CreditFrame_CallBack;
- CreditFrame:CallBack()
+function SV:FlashTitle(text1, text2)
+ TitleFrame:ShowTitle(text1, text2);
end
SV:AddSlashCommand("credits", "Display some randomly selected SVUI credits", RollCredits);
diff --git a/SVUI_!Core/xml/widgets.xml b/SVUI_!Core/xml/widgets.xml
index 2bebae3..b4f1cc4 100644
--- a/SVUI_!Core/xml/widgets.xml
+++ b/SVUI_!Core/xml/widgets.xml
@@ -1,24 +1,77 @@
<Ui xmlns="http://www.blizzard.com/wow/ui/">
+ <Font name="SVUI_Font_Super_Text" inherits="SVUI_Font_Number" virtual="true">
+ <Shadow>
+ <Offset>
+ <AbsDimension x="2" y="-2"/>
+ </Offset>
+ <Color r="0" g="0" b="0" a="0.5"/>
+ </Shadow>
+ <FontHeight>
+ <AbsValue val="22"/>
+ </FontHeight>
+ </Font>
+ <Font name="SVUI_Font_Super_Title" inherits="SVUI_Font_Number_Huge" virtual="true">
+ <Shadow>
+ <Offset>
+ <AbsDimension x="2" y="-2"/>
+ </Offset>
+ <Color r="0" g="0" b="0" />
+ </Shadow>
+ <FontHeight>
+ <AbsValue val="128"/>
+ </FontHeight>
+ </Font>
+
+ <Frame name="SVUI_SuperTitleFrame" frameStrata="DIALOG" hidden="true">
+ <Size x="40" y="40"/>
+ <Anchors>
+ <Anchor point="LEFT" relativePoint="CENTER" x="90" y="-50" />
+ </Anchors>
+ <Layers>
+ <Layer level="ARTWORK">
+
+ <FontString name="$parentList" font="SVUI_Font_Super_Title">
+ <Color r="1" g="0.5" b="0" a="0.85"/>
+ <Anchors>
+ <Anchor point="LEFT" x="0" y="0" />
+ </Anchors>
+ <Shadow>
+ <Offset>
+ <AbsDimension x="2" y="-2"/>
+ </Offset>
+ <Color r="0" g="0" b="0" />
+ </Shadow>
+ </FontString>
+
+ <FontString name="$parentTitle" inherits="SVUI_Font_Super_Text">
+ <Color r="1" g="1" b="0" a="0.85"/>
+ <Anchors>
+ <Anchor point="BOTTOMLEFT" relativeTo="$parentList" relativePoint="TOPLEFT" x="0" y="6" />
+ </Anchors>
+ </FontString>
+ </Layer>
+ </Layers>
+ </Frame>
<Frame name="SVUI_CreditFrame" frameStrata="DIALOG" hidden="true">
<Size x="40" y="40"/>
<Anchors>
- <Anchor point="RIGHT" x="-100" y="-100" />
+ <Anchor point="LEFT" relativePoint="CENTER" x="130" y="-50" />
</Anchors>
<Layers>
<Layer level="ARTWORK">
<FontString name="$parentList" font="SystemFont_Shadow_Outline_Huge2">
- <Color r="1" g="1" b="1" a="0.85"/>
+ <Color r="1" g="1" b="1" a="0.65"/>
<Anchors>
- <Anchor point="RIGHT" x="0" y="0" />
+ <Anchor point="LEFT" x="0" y="0" />
</Anchors>
</FontString>
<FontString name="$parentTitle" inherits="SystemFont_Shadow_Large">
- <Color r="1" g="1" b="1" a="0.85"/>
+ <Color r="1" g="1" b="1" a="0.65"/>
<Anchors>
- <Anchor point="BOTTOMRIGHT" relativeTo="$parentList" relativePoint="TOP" x="0" y="0" />
+ <Anchor point="BOTTOMLEFT" relativeTo="$parentList" relativePoint="TOPLEFT" x="0" y="6" />
</Anchors>
</FontString>
</Layer>
diff --git a/SVUI_!Options/SVUI_!Options.lua b/SVUI_!Options/SVUI_!Options.lua
index 79d70da..ccee6b2 100644
--- a/SVUI_!Options/SVUI_!Options.lua
+++ b/SVUI_!Options/SVUI_!Options.lua
@@ -500,8 +500,15 @@ SV.Options.args.Core = {
get = function(j)return SV.db.general.loginmessage end,
set = function(j,value)SV.db.general.loginmessage = value end
},
- saveDraggable = {
+ LoginCredits = {
order = 2,
+ type = 'toggle',
+ name = L['Login Credits'],
+ get = function(j)return SV.db.general.logincredits end,
+ set = function(j,value)SV.db.general.logincredits = value end
+ },
+ saveDraggable = {
+ order = 3,
type = "toggle",
name = L["Save Draggable"],
desc = L["Save the positions of draggable frames when they are moved. NOTE: THIS WILL OVERRIDE BLIZZARD FRAME SNAPPING!"],
@@ -509,7 +516,7 @@ SV.Options.args.Core = {
set = function(j,value)SV.db.general.saveDraggable = value; SV:StaticPopup_Show("RL_CLIENT") end
},
cooldownText = {
- order = 3,
+ order = 4,
type = "toggle",
name = L['Cooldown Text'],
desc = L["Display cooldown text on anything with the cooldown spiral."],
@@ -517,7 +524,7 @@ SV.Options.args.Core = {
set = function(j,value)SV.db.general.cooldown = value; SV:StaticPopup_Show("RL_CLIENT")end
},
texture = {
- order = 4,
+ order = 5,
type = "group",
name = L["Textures"],
guiInline = true,
@@ -546,7 +553,7 @@ SV.Options.args.Core = {
}
},
colors = {
- order = 5,
+ order = 6,
type = "group",
name = L["Colors"],
guiInline = true,
@@ -603,7 +610,7 @@ SV.Options.args.Core = {
}
},
loot = {
- order = 6,
+ order = 7,
type = "toggle",
name = L['Loot Frame'],
desc = L['Enable/Disable the loot frame.'],
@@ -611,7 +618,7 @@ SV.Options.args.Core = {
set = function(j,value)SV.db.general.loot = value;SV:StaticPopup_Show("RL_CLIENT")end
},
lootRoll = {
- order = 7,
+ order = 8,
type = "toggle",
name = L['Loot Roll'],
desc = L['Enable/Disable the loot roll frame.'],
@@ -619,7 +626,7 @@ SV.Options.args.Core = {
set = function(j,value)SV.db.general.lootRoll = value;SV:StaticPopup_Show("RL_CLIENT")end
},
lootRollWidth = {
- order = 8,
+ order = 9,
type = 'range',
width = "full",
name = L["Roll Frame Width"],
@@ -630,7 +637,7 @@ SV.Options.args.Core = {
set = function(a,b) SV.db.general.lootRollWidth = b; end,
},
lootRollHeight = {
- order = 9,
+ order = 10,
type = 'range',
width = "full",
name = L["Roll Frame Height"],
diff --git a/SVUI_Auras/SVUI_Auras.lua b/SVUI_Auras/SVUI_Auras.lua
index 90a6c30..1576730 100644
--- a/SVUI_Auras/SVUI_Auras.lua
+++ b/SVUI_Auras/SVUI_Auras.lua
@@ -556,7 +556,6 @@ function MOD:Load()
local CB_WIDTH = (CB_HEIGHT / maxShown) + 4;
if(SVUI_MinimapFrame) then
- HOLDER_OFFSET = -32;
CB_HEIGHT = SVUI_MinimapFrame:GetHeight() - 50;
end