From f14b36734626d63cb25b6997e6cf611ee3d0fd24 Mon Sep 17 00:00:00 2001 From: Jousway Date: Wed, 3 Apr 2013 19:50:52 +0200 Subject: [PATCH] <@Jousway> I should just add my cdtitle resizer to sm5 default theme and piss the entire comunity off ;) <~freem> yes <~freem> didn't holo just say add it to default <&holo> do it up in before everyone hates me haha --- .../ScreenSelectMusic overlay.lua | 46 +++++++++++++++++++ Themes/default/metrics.ini | 3 +- 2 files changed, 48 insertions(+), 1 deletion(-) create mode 100644 Themes/default/BGAnimations/ScreenSelectMusic overlay.lua diff --git a/Themes/default/BGAnimations/ScreenSelectMusic overlay.lua b/Themes/default/BGAnimations/ScreenSelectMusic overlay.lua new file mode 100644 index 0000000000..1976e4de5e --- /dev/null +++ b/Themes/default/BGAnimations/ScreenSelectMusic overlay.lua @@ -0,0 +1,46 @@ +--I'ma call it the fuck you people with fucking huge cdtitles script, With Love - Jousway +local t = Def.ActorFrame { + + Def.Sprite { + Name="CDTitle"; + InitCommand=cmd(x,SCREEN_CENTER_X-43;y,SCREEN_TOP+210); + OnCommand=cmd(draworder,106;shadowlength,1;zoom,0.75;diffusealpha,1;zoom,0;bounceend,0.35;zoom,0.75;spin;effectmagnitude,0,180,0); + }; + +}; + +local function Update(self) + local song = GAMESTATE:GetCurrentSong(); + local cdtitle = self:GetChild("CDTitle"); + local height = cdtitle:GetHeight(); + local width = cdtitle:GetWidth(); + + if song then + if song:HasCDTitle() then + cdtitle:visible(true); + cdtitle:Load(song:GetCDTitlePath()); + else + cdtitle:visible(false); + end; + else + cdtitle:visible(false); + end; + + if height >= 70 and width >= 70 then + if height >= width then + cdtitle:zoom(70/height); + else + cdtitle:zoom(70/width); + end; + elseif height >= 70 then + cdtitle:zoom(70/height); + elseif width >= 70 then + cdtitle:zoom(70/width); + else + cdtitle:zoom(1); + end; + +end; + +t.InitCommand=cmd(SetUpdateFunction,Update); +return t--]] diff --git a/Themes/default/metrics.ini b/Themes/default/metrics.ini index 431171a52e..319b4c3be3 100644 --- a/Themes/default/metrics.ini +++ b/Themes/default/metrics.ini @@ -1040,7 +1040,8 @@ CDTitleX=SCREEN_CENTER_X-160+90 CDTitleY=SCREEN_TOP+160+(36/2)+8 CDTitleFrontCommand=diffuse,color('0.5,0.5,0.5,1');cullmode,'CullMode_Front' CDTitleBackCommand=cullmode,'CullMode_Back' -CDTitleOnCommand=draworder,106;shadowlength,1;zoom,0.75;diffusealpha,1;zoom,0;bounceend,0.35;zoom,0.75;spin;effectmagnitude,0,180,0; +#CDTitleOnCommand=draworder,106;shadowlength,1;zoom,0.75;diffusealpha,1;zoom,0;bounceend,0.35;zoom,0.75;spin;effectmagnitude,0,180,0; +CDTitleOnCommand=diffusealpha,0 CDTitleOffCommand=bouncebegin,0.15;zoomx,0; # #