Files
itgmania212121/BackgroundEffects/Checkerboard1File2x2.lua
T
2013-07-01 21:00:52 -04:00

46 lines
1.0 KiB
Lua

local Color1 = color(Var "Color1");
local a = LoadActor(Var "File1") .. {
OnCommand=function(self)
self:cropto(SCREEN_WIDTH / 2);
self:zoomtoheight(SCREEN_HEIGHT / 2);
self:diffuse(Color1);
self:effectclock("music");
end;
GainFocusCommand=function(self)
self:play();
end;
LoseFocusCommand=function(self)
self:pause();
end;
};
local t = Def.ActorFrame {
a .. {
OnCommand = function(self)
self:x(scale(1, 0, 4, SCREEN_LEFT, SCREEN_RIGHT));
self:y(scale(1, 0, 4, SCREEN_TOP, SCREEN_BOTTOM));
end;
};
a .. {
OnCommand = function(self)
self:x(scale(3, 0, 4, SCREEN_LEFT, SCREEN_RIGHT));
self:y(scale(1, 0, 4, SCREEN_TOP, SCREEN_BOTTOM));
end;
};
a .. {
OnCommand = function(self)
self:x(scale(1, 0, 4, SCREEN_LEFT, SCREEN_RIGHT));
self:y(scale(3, 0, 4, SCREEN_TOP, SCREEN_BOTTOM));
end;
};
a .. {
OnCommand = function(self)
self:x(scale(3, 0, 4, SCREEN_LEFT, SCREEN_RIGHT));
self:y(scale(3, 0, 4, SCREEN_TOP, SCREEN_BOTTOM));
end;
};
};
return t;