演示视频
抖音:https://v.douyin.com/iY1d7TuC/
b站
案例代码
实现了自动关闭app开屏广告
仅学习使用!
var thread = threads.start(function() {
while (true) {
sleep(100);
var currentApp = currentPackage();
var appName = app.getAppName(currentApp);
const keys = ['跳过'];
const apps = ['波点音乐', '知乎', '哔哩哔哩', '网易云音乐']
//log(appName)
if (apps.indexOf(appName) == -1) {
continue
}
for (let key of keys) {
if (textContains(key).exists()) {
var targetB = textContains(key).findOne().bounds();
click(targetB.centerX(), targetB.centerY());
click(targetB.centerX(), targetB.centerY());
toastLog('在' + appName + '上点击了跳过');
break;
}
}
}
});