2012-06-18 19:01:16 -07:00
|
|
|
local Color1 = color(Var "Color1");
|
|
|
|
|
local Color2 = color(Var "Color2");
|
|
|
|
|
|
|
|
|
|
local t = Def.ActorFrame {};
|
|
|
|
|
|
|
|
|
|
t[#t+1] = LoadActor(Var "File1") .. {
|
2015-02-05 00:37:08 -07:00
|
|
|
OnCommand=function(self)
|
|
|
|
|
self:x(SCREEN_CENTER_X):y(SCREEN_CENTER_Y):scale_or_crop_background():diffuse(Color1):effectclock("music")
|
|
|
|
|
-- Explanation in StretchNoLoop.lua.
|
|
|
|
|
if self.GetTexture then
|
|
|
|
|
self:GetTexture():rate(self:GetParent():GetUpdateRate())
|
|
|
|
|
end
|
|
|
|
|
end,
|
2013-07-18 17:41:00 -04:00
|
|
|
GainFocusCommand=cmd(play);
|
|
|
|
|
LoseFocusCommand=cmd(pause);
|
2012-06-18 19:01:16 -07:00
|
|
|
};
|
|
|
|
|
|
|
|
|
|
if Var("File2") ~= nil then
|
|
|
|
|
t[#t+1] = LoadActor(Var("File2")) .. {
|
2015-02-05 00:37:08 -07:00
|
|
|
OnCommand=function(self)
|
|
|
|
|
self:x(SCREEN_CENTER_X):y(SCREEN_CENTER_Y):scale_or_crop_background():diffuse(Color2):effectclock("music"):linear(1):diffusealpha(0)
|
|
|
|
|
-- Explanation in StretchNoLoop.lua.
|
|
|
|
|
if self.GetTexture then
|
|
|
|
|
self:GetTexture():rate(self:GetParent():GetUpdateRate())
|
|
|
|
|
end
|
|
|
|
|
end,
|
2013-07-18 17:41:00 -04:00
|
|
|
GainFocusCommand=cmd(play);
|
|
|
|
|
LoseFocusCommand=cmd(pause);
|
2012-06-18 19:01:16 -07:00
|
|
|
};
|
|
|
|
|
end;
|
|
|
|
|
|
|
|
|
|
return t;
|