Files
itgmania212121/BackgroundEffects/StretchNoLoop.lua
T

22 lines
487 B
Lua
Raw Normal View History

2013-07-18 17:41:00 -04:00
local Color1 = color(Var "Color1");
local t = Def.ActorFrame {
LoadActor(Var "File1") .. {
OnCommand=function(self)
self:xy(SCREEN_CENTER_X,SCREEN_CENTER_Y)
self:scale_or_crop_background()
self:diffuse(Color1)
if self.loop ~= nil then
self:loop(false)
-- make videos start at beginning to prevent sticking on last frame
self:position(0)
end
self:effectclock("music")
end;
2013-07-18 17:41:00 -04:00
GainFocusCommand=cmd(play);
LoseFocusCommand=cmd(pause);
};
};
return t;