The "new" theme is handled.

This commit is contained in:
Jason Felds
2013-07-02 18:22:43 -04:00
parent f373dd9add
commit 2d5d45e365
11 changed files with 212 additions and 95 deletions
+15 -4
View File
@@ -1,15 +1,26 @@
local t = Def.ActorFrame {}; local t = Def.ActorFrame {};
-- --
t[#t+1] = Def.ActorFrame { t[#t+1] = Def.ActorFrame {
InitCommand=cmd(Center); InitCommand=function(self)
self:Center();
end;
-- --
Def.Quad { Def.Quad {
InitCommand=cmd(zoomto,SCREEN_WIDTH,SCREEN_HEIGHT;diffuse,Color.Black;diffusealpha,0); InitCommand=function(self)
StartTransitioningCommand=cmd(decelerate,0.125;diffusealpha,1); self:zoomto(SCREEN_WIDTH, SCREEN_HEIGHT);
self:diffuse(Color.Black);
self:diffusealpha(0);
end;
StartTransitioningCommand=function(self)
self:decelerate(0.125);
self:diffusealpha(1);
end;
}; };
-- Sounds -- Sounds
LoadActor(THEME:GetPathS(Var "LoadingScreen","cancel")) .. { LoadActor(THEME:GetPathS(Var "LoadingScreen","cancel")) .. {
StartTransitioningCommand=cmd(play); StartTransitioningCommand=function(self)
self:play();
end;
}; };
}; };
-- --
+12 -3
View File
@@ -1,11 +1,20 @@
local t = Def.ActorFrame {}; local t = Def.ActorFrame {};
-- --
t[#t+1] = Def.ActorFrame { t[#t+1] = Def.ActorFrame {
InitCommand=cmd(Center); InitCommand=function(self)
self:Center();
end;
-- --
Def.Quad { Def.Quad {
InitCommand=cmd(zoomto,SCREEN_WIDTH,SCREEN_HEIGHT;diffuse,Color.Black;diffusealpha,1); InitCommand=function(self)
StartTransitioningCommand=cmd(smooth,0.2;diffusealpha,0); self:zoomto(SCREEN_WIDTH, SCREEN_HEIGHT);
self:diffuse(Color.Black);
self:diffusealpha(1);
end;
StartTransitioningCommand=function(self)
self:smooth(0.2);
self:diffusealpha(0);
end;
}; };
}; };
-- --
+11 -3
View File
@@ -1,11 +1,19 @@
local t = Def.ActorFrame {}; local t = Def.ActorFrame {};
-- --
t[#t+1] = Def.ActorFrame { t[#t+1] = Def.ActorFrame {
InitCommand=cmd(Center); InitCommand=function(self)
self:Center();
-- --
Def.Quad { Def.Quad {
InitCommand=cmd(zoomto,SCREEN_WIDTH,SCREEN_HEIGHT;diffuse,Color.Black;diffusealpha,0); InitCommand=function(self)
StartTransitioningCommand=cmd(decelerate,0.25;diffusealpha,1); self:zoomto(SCREEN_WIDTH, SCREEN_HEIGHT);
self:diffuse(Color.Black);
self:diffusealpha(0);
end;
StartTransitioningCommand=function(self)
self:decelerate(0.25);
self:diffusealpha(1);
end;
}; };
}; };
-- --
@@ -1,40 +1,60 @@
local t = Def.ActorFrame {}; local t = Def.ActorFrame {};
-- Background Color -- Background Color
t[#t+1] = Def.ActorFrame { t[#t+1] = Def.ActorFrame {
InitCommand=cmd(Center); InitCommand=function(self)
-- self:Center();
Def.Quad { end;
InitCommand=cmd(zoomto,SCREEN_WIDTH,SCREEN_HEIGHT;diffuse,color("#005185")); --
}; Def.Quad {
InitCommand=function(self)
self:zoomto(SCREEN_WIDTH, SCREEN_HEIGHT);
self:diffuse(color("#005185"));
end;
};
}; };
-- Additive Tint -- Additive Tint
t[#t+1] = Def.ActorFrame { t[#t+1] = Def.ActorFrame {
InitCommand=cmd(Center); InitCommand=function(self)
-- self:Center();
Def.Quad { end;
InitCommand=cmd(zoomto,SCREEN_WIDTH,SCREEN_HEIGHT;fadetop,1;blend,"BlendMode_Add";diffusealpha,0.2); --
} Def.Quad {
InitCommand=function(self)
self:zoomto(SCREEN_WIDTH, SCREEN_HEIGHT);
self:fadetop(1);
self:blend("BlendMode_Add");
self:diffusealpha(0.2);
end;
}
}; };
-- Textures Frame -- Textures Frame
t[#t+1] = Def.ActorFrame { t[#t+1] = Def.ActorFrame {
InitCommand=cmd(Center); InitCommand=function(self)
-- Scanline self:Center();
LoadActor("_texture scanline") .. { end;
InitCommand=cmd(zoomto,SCREEN_WIDTH,SCREEN_HEIGHT;
customtexturerect,0,0,SCREEN_WIDTH/16,SCREEN_HEIGHT/32; -- Scanline
diffuse,Color.Black; LoadActor("_texture scanline") .. {
diffusealpha,0.25; InitCommand=function(self)
); self:zoomto(SCREEN_WIDTH, SCREEN_HEIGHT);
}; self:customtexturerect(0, 0, SCREEN_WIDTH / 16, SCREEN_HEIGHT / 32);
-- Checkerboard self:diffuse(Color.Black);
LoadActor("_texture checkerboard") .. { self:diffusealpha(0.25);
InitCommand=cmd(zoomto,SCREEN_WIDTH,SCREEN_HEIGHT; end;
customtexturerect,0,0,SCREEN_WIDTH/64,SCREEN_HEIGHT/64; };
texcoordvelocity,0.5,0;
diffuse,Color.Black; -- Checkerboard
diffusealpha,0.25; LoadActor("_texture checkerboard") .. {
); InitCommand=function(self)
}; self:zoomto(SCREEN_WIDTH, SCREEN_HEIGHT);
self:customtexturerect(0, 0, SCREEN_WIDTH / 64, SCREEN_HEIGHT / 64);
self:texcoordvelocity(0.5, 0);
self:diffuse(Color.Black);
self:diffusealpha(0.25);
end;
};
}; };
-- --
@@ -1,8 +1,11 @@
return Def.ActorFrame { return Def.ActorFrame {
Def.Quad { Def.Quad {
InitCommand=cmd(zoomto,48,24;diffuse,PlayerColor(PLAYER_1)); InitCommand=function(self)
}; self:zoomto(48, 24);
LoadFont("Common Normal") .. { self:diffuse(PlayerColor(PLAYER_1));
Text="P1"; end;
}; };
LoadFont("Common Normal") .. {
Text="P1";
};
}; };
@@ -4,16 +4,34 @@ local t = Def.ActorFrame {};
-- --
t[#t+1] = Def.ActorFrame { t[#t+1] = Def.ActorFrame {
Def.Quad { Def.Quad {
InitCommand=cmd(zoomto,96,24;diffuse,Color.White); InitCommand=function(self)
GainFocusCommand=cmd(diffuseshift;effectcolor2,Color.White;effectcolor1,Color.Blue); self:zoomto(96, 24);
LoseFocusCommand=cmd(stopeffect;); self:diffuse(Color.White);
DisabledCommand=cmd(stopeffect;diffuse,color("0.5,0.5,0.5,1")); end;
EnabledCommand=cmd(stopeffect;diffuse,Color.White); GainFocusCommand=function(self)
self:diffuseshift();
self:effectcolor2(Color.White);
self:effectcolor1(Color.Blue);
end;
LoseFocusCommand=function(self)
self:stopeffect();
end;
DisabledCommand=function(self)
self:stopeffect();
self:diffuse(color("0.5,0.5,0.5,1"));
end;
EnabledCommand=function(self)
self:stopeffect();
self:diffuse(Color.White);
end;
}; };
-- --
LoadFont("Common Normal") .. { LoadFont("Common Normal") .. {
Text=gc:GetText(); Text=gc:GetText();
InitCommand=cmd(diffuse,Color.Black;zoom,0.675); InitCommand=function(self)
self:diffuse(Color.Black);
self:zoom(0.675);
end;
}; };
}; };
return t return t
@@ -4,7 +4,10 @@ local t = Def.ActorFrame {};
-- --
t[#t+1] = Def.ActorFrame { t[#t+1] = Def.ActorFrame {
Def.Quad { Def.Quad {
InitCommand=cmd(zoomto,96,24;diffuse,Color.White); InitCommand=function(self)
self:zoomto(96, 24);
self:diffuse(Color.White);
end;
}; };
}; };
return t return t
@@ -1,14 +1,30 @@
local t = Def.ActorFrame{ local t = Def.ActorFrame{
InitCommand=cmd(fov,70); InitCommand=function(self)
self:fov(70);
end;
LoadActor("_arrow")..{ LoadActor("_arrow")..{
InitCommand=cmd(x,225;); InitCommand=function(self)
OnCommand=cmd(wag;effectmagnitude,0,0,16;effectperiod,2.5;); self:x(225);
end;
OnCommand=function(self)
self:wag();
self:effectmagnitude(0, 0, 16);
self:effectperiod(2.5);
end;
}; };
LoadActor("_text"); LoadActor("_text");
LoadActor("_text")..{ LoadActor("_text")..{
Name="TextGlow"; Name="TextGlow";
InitCommand=cmd(blend,Blend.Add;diffusealpha,0.05;); InitCommand=function(self)
OnCommand=cmd(glowshift;effectperiod,2.5;effectcolor1,color("1,1,1,0.25");effectcolor2,color("1,1,1,1");); self:blend(Blend.Add);
self:diffusealpha(0.05);
end;
OnCommand=function(self)
self:glowshift();
self:effectperiod(2.5);
self:effectcolor1(color("1,1,1,0.25"));
self:effectcolor2(color("1,1,1,1"));
end;
}; };
}; };
@@ -1,6 +1,13 @@
return Def.ActorFrame { return Def.ActorFrame {
InitCommand=cmd(x,SCREEN_CENTER_X;y,SCREEN_BOTTOM); InitCommand=function(self)
self:x(SCREEN_CENTER_X);
self:y(SCREEN_BOTTOM);
end;
Def.Quad { Def.Quad {
InitCommand=cmd(vertalign,bottom;zoomto,SCREEN_WIDTH,32;diffuse,Color.Black); InitCommand=function(
self:vertalign(bottom);
self:zoomto(SCREEN_WIDTH, 32);
self:diffuse(Color.Black);
end;
}; };
}; };
@@ -1,10 +1,21 @@
return Def.ActorFrame { return Def.ActorFrame {
-- Default BG -- Default BG
Def.Quad { Def.Quad {
InitCommand=cmd(vertalign,bottom;zoomto,SCREEN_WIDTH,60;diffuse,Color.Black;diffusealpha,0.65); InitCommand=function(self)
self:vertalign(bottom);
self:zoomto(SCREEN_WIDTH, 60);
self:diffuse(Color.Black);
self:diffusealpha(0.65);
end;
}; };
-- Highlight -- Highlight
Def.Quad { Def.Quad {
InitCommand=cmd(vertalign,bottom;zoomto,SCREEN_WIDTH,1;diffuse,Color.Blue;fadeleft,1;y,-58); InitCommand=function(self)
self:vertalign(bottom);
self:zoomto(SCREEN_WIDTH, 1);
self:diffuse(Color.Blue);
self:fadeleft(1);
self:y(-58);
end;
}; };
}; };
@@ -1,10 +1,21 @@
return Def.ActorFrame { return Def.ActorFrame {
-- Default BG -- Default BG
Def.Quad { Def.Quad {
InitCommand=cmd(vertalign,top;zoomto,SCREEN_WIDTH,48;diffuse,Color.Black;diffusealpha,0.65); InitCommand=function(self)
self:vertalign(top);
self:zoomto(SCREEN_WIDTH, 48);
self:diffuse(Color.Black);
self:diffusealpha(0.65);
end;
}; };
-- Highlight -- Highlight
Def.Quad { Def.Quad {
InitCommand=cmd(vertalign,top;zoomto,SCREEN_WIDTH,1;diffuse,Color.Blue;faderight,1;y,46); InitCommand=function(self)
self:vertalign(top);
self:zoomto(SCREEN_WIDTH, 1);
self:diffuse(Color.Blue);
self:faderight(1);
self:y(46);
end;
}; };
}; };