觸摸精靈 全屏圖片
-- 脚本描述
DESCRIPTION="snapshot";
-- 适用屏幕参数
SCREEN_RESOLUTION="480x800";
SCREEN_COLOR_BITS=4;
--"/mnt/sdcard0/lua/bmp"
-- 主入口
function main()
str=string.format("%s%d%s","/mnt/sdcard0/lua/bmp",getIndex(),".bmp");
--延时3000是为了防止截图时【播放开始】的字样挡住屏幕
mSleep(3000);
snapshotScreen(str);
end
function getIndex()
local file = io.open("/mnt/sdcard/snapshot/offset.txt","r");
local text = file:read();
local num = tonumber(text);
file:close();
file = io.open("/mnt/sdcard/snapshot/offset.txt","w");
file:write(num+1);
file:close();
return num;
end
DESCRIPTION="snapshot";
-- 适用屏幕参数
SCREEN_RESOLUTION="480x800";
SCREEN_COLOR_BITS=4;
--"/mnt/sdcard0/lua/bmp"
-- 主入口
function main()
str=string.format("%s%d%s","/mnt/sdcard0/lua/bmp",getIndex(),".bmp");
--延时3000是为了防止截图时【播放开始】的字样挡住屏幕
mSleep(3000);
snapshotScreen(str);
end
function getIndex()
local file = io.open("/mnt/sdcard/snapshot/offset.txt","r");
local text = file:read();
local num = tonumber(text);
file:close();
file = io.open("/mnt/sdcard/snapshot/offset.txt","w");
file:write(num+1);
file:close();
return num;
end
- function main()
- snapshotScreen(string.format("/mnt/sdcard0/lua%s.bmp",os.time()));
- mSleep(1000);
- end
留言
張貼留言