Add new 5.1 default theme Lambda

I'd like to thank everyone who made this possible;, including but not
limited to Riakodoadm, MrThatKid, kyzentun, Luizsan, JoseVarelaP,
everyone else who provided feedback and bug reports.
This commit is contained in:
ListenerJubatus
2017-08-08 01:07:34 -06:00
parent 4c5319c888
commit f257f19dad
1015 changed files with 17245 additions and 3865 deletions
@@ -1,58 +1,84 @@
local t = Def.ActorFrame {};
local t = Def.ActorFrame {}
local function Update(self)
local c = self:GetChildren();
local bps = GAMESTATE:GetSongBPS() or 1
c.TextureStripe:texcoordvelocity(bps/3,0);
end
local function IsVisible()
local r = Screen.String("HeaderText");
return string.len(r) > 0 and true or false
end
t[#t+1] = Def.Quad {
InitCommand=cmd(vertalign,top;zoomto,SCREEN_WIDTH+1,50;diffuse,color("#161616"));
-- Base bar diffuse,color("#1C1C1B");diffusebottomedge,color("#333230");
t[#t+1] = Def.ActorFrame {
InitCommand=cmd(vertalign,top),
OnCommand=function(self)
self:addy(-104):decelerate(0.5):addy(104)
end,
OffCommand=cmd(sleep,0.175;decelerate,0.4;addy,-105),
Def.Quad {
InitCommand=cmd(vertalign,top;zoomto,SCREEN_WIDTH,96),
OnCommand=function(self)
self:diffuse(ScreenColor(SCREENMAN:GetTopScreen():GetName())):diffusetopedge(ColorDarkTone(ScreenColor(SCREENMAN:GetTopScreen():GetName()))):diffusealpha(0.8)
end
},
LoadActor("_shade") .. {
InitCommand=cmd(vertalign,top;zoomto,SCREEN_WIDTH,96),
OnCommand=function(self)
self:diffuse(ScreenColor(SCREENMAN:GetTopScreen():GetName())):diffusetopedge(ColorDarkTone(ScreenColor(SCREENMAN:GetTopScreen():GetName()))):diffusealpha(0.8):faderight(1)
end
},
-- Shadow
Def.Quad {
InitCommand=cmd(vertalign,top;zoomto,SCREEN_WIDTH,8;y,96),
OnCommand=cmd(diffuse,Color("Black");fadebottom,1;diffusealpha,0.6)
}
}
t[#t+1] = LoadActor("_texture stripe") .. {
Name="TextureStripe";
InitCommand=cmd(x,-SCREEN_CENTER_X-8;y,-2;horizalign,left;vertalign,top;zoomto,320,50;customtexturerect,0,0,(320/2)/8,50/32);
OnCommand=cmd(texcoordvelocity,2,0;skewx,-0.0575;diffuse,color("#594300");diffuserightedge,color("#59430000"));
};
t[#t+1] = LoadActor("Header") .. {
InitCommand=cmd(y,1;vertalign,top;zoomtowidth,SCREEN_WIDTH+1;diffuse,color("#ffd400"));
OnCommand=cmd(croptop,46/60);
};
t[#t+1] = LoadFont("Common Bold") .. {
Name="HeaderShadow";
Text=Screen.String("HeaderText");
InitCommand=cmd(x,-SCREEN_CENTER_X+26;y,28;zoom,1;horizalign,left;maxwidth,200);
OnCommand=cmd(visible,IsVisible();skewx,-0.125;diffuse,BoostColor(color("#ffd40077"),0.375););
-- Diamond
t[#t+1] = Def.ActorFrame {
InitCommand=cmd(x,-SCREEN_CENTER_X+76;y,SCREEN_TOP+30),
OnCommand=cmd(addx,-110;sleep,0.3;decelerate,0.7;addx,110),
OffCommand=cmd(decelerate,0.175;addx,-110),
-- Diamond BG
Def.Quad {
InitCommand=cmd(vertalign,top;zoomto,54,54;rotationz,45),
OnCommand=function(self)
self:diffuse(ColorLightTone(ScreenColor(SCREENMAN:GetTopScreen():GetName())))
end
},
-- Symbol selector
Def.Sprite {
Name="HeaderDiamondIcon",
InitCommand=cmd(horizalign,center;y,18;x,-20;diffusealpha,0.8),
OnCommand=function(self)
local screen = SCREENMAN:GetTopScreen():GetName()
if FILEMAN:DoesFileExist("Themes/"..THEME:GetCurThemeName().."/Graphics/ScreenWithMenuElements header/"..screen.." icon.png") then
self:Load(THEME:GetPathG("","ScreenWithMenuElements header/"..screen.." icon"))
-- Little workaround so not every other options menu has the "graphic missing" icon.
elseif string.find(screen, "Options") then
self:Load(THEME:GetPathG("","ScreenWithMenuElements header/ScreenOptionsService icon"))
else
print("iconerror: file does not exist")
self:Load(THEME:GetPathG("","ScreenWithMenuElements header/Generic icon"))
end
end
}
}
-- Text
t[#t+1] = LoadFont("Common Header") .. {
Name="HeaderTitle",
Text=Screen.String("HeaderText"),
InitCommand=cmd(zoom,1.0;x,-SCREEN_CENTER_X+110;y,49;horizalign,left;diffuse,color("#ffffff");shadowlength,1;skewx,-0.1),
OnCommand=cmd(diffusealpha,0;sleep,0.5;smooth,0.3;diffusealpha,0.8),
UpdateScreenHeaderMessageCommand=function(self,param)
self:settext(param.Header);
end;
};
self:settext(param.Header)
end,
OffCommand=cmd(smooth,0.175;diffusealpha,0)
}
t[#t+1] = Def.Quad {
Name="Underline";
InitCommand=cmd(x,-SCREEN_CENTER_X+24-4;y,36;horizalign,left);
OnCommand=cmd(stoptweening;diffuse,color("#ffd400");shadowlength,2;shadowcolor,BoostColor(color("#ffd40077"),0.25);linear,0.25;zoomtowidth,192;fadeleft,8/192;faderight,0.5;
visible,string.len( Screen.String("HeaderText") ) > 0 );
};
-- t[#t+1] = LoadFont("Common Condensed") .. {
-- Name="HeaderSubTitle";
-- Text=Screen.String("HeaderSubText");
-- InitCommand=cmd(zoom,0.8;x,-SCREEN_CENTER_X+110;y,70;horizalign,left;diffuse,color("#ffffff");shadowlength,1;skewx,-0.1);
-- OnCommand=cmd(diffusealpha,0;sleep,0.55;smooth,0.3;diffusealpha,0.75;);
-- UpdateScreenHeaderMessageCommand=function(self,param)
-- self:settext(param.Header);
-- end;
-- OffCommand=cmd(smooth,0.3;diffusealpha,0;);
-- };
t[#t+1] = LoadFont("Common Bold") .. {
Name="HeaderText";
Text=Screen.String("HeaderText");
InitCommand=cmd(x,-SCREEN_CENTER_X+24;y,26;zoom,1;horizalign,left;shadowlength,0;maxwidth,200);
OnCommand=cmd(visible,IsVisible();skewx,-0.125;diffuse,color("#ffd400"););
UpdateScreenHeaderMessageCommand=function(self,param)
self:settext(param.Header);
end;
};
t.BeginCommand=function(self)
self:SetUpdateFunction( Update );
end
return t
return t