/*
软件作者:https://xuhss.com/oxox/pro
*/
"auto";
var 好友验证信息 = "AutoJs自动添加群好友";
var 延迟 = 500;
launchApp("QQ");
sleep(500);
if(currentActivity() != "com.tencent.mobileqq.activity.TroopMemberListActivity"){
toast("请打开要加的群的聊天窗口");
openGroupMemberList();
}
var added = {};
while(true){
var list = className("AbsListView").findOne();
var count = list.childCount();
for(var i = 0; i < count; i++){
var child = list.child(i);
if(!child || child.className() != "android.widget.FrameLayout"){
continue;
}
if(!isGroupMember(child) || isMyself(child)){
continue;
}
child.child(0).click();
sleep(500);
addAsFriend();
sleep(延迟);
}
list.scrollForward();
}
function isGroupMember(child){
var tvName = child.findOne(id("tv_name"));
if(!tvName){
return false;
}
log(tvName.text());
return tvName.text() != "Baby Q";
}
function isMyself(child){
var i = child.findOne(text("我"));
if(!i){
return false;
}
return i.id() && !i.id().endsWith("tv_name");
}
function addAsFriend(){
var qq = getQQ();
toast(qq);
if(added[qq]){
while(!click("返回"));
return;
}
added[qq] = true;
if(click("加好友")){
sleep(800);
setText(0, 好友验证信息);
while(!click("发送"));
sleep(800);
if(click("取消")){
sleep(400);
}
while(!back());
}else{
while(!back());
}
}
function getQQ(){
var qq = textMatches("\\d{5,12}").findOne().text();
return qq;
}
function openGroupMemberList(){
desc("群资料卡").click();
var groupMemberCountView = textEndsWith("名成员").findOne();
var groupMemberCount = parseInt(/\d+/.exec(groupMemberCountView.text())[0]);
groupMemberCountView.parent().click();
sleep(groupMemberCount * 4);
}
没有合适的资源?快使用搜索试试~ 我知道了~
AutoJs源码-QQ加群成员脚本(2)
![preview](https://csdnimg.cn/release/downloadcmsfe/public/img/white-bg.ca8570fa.png)
共1个文件
js:1个
![preview-icon](https://csdnimg.cn/release/downloadcmsfe/public/img/scale.ab9e0183.png)
需积分: 4 0 下载量 123 浏览量
2022-11-15
02:12:29
上传
评论
收藏 1KB 7Z 举报
温馨提示
AutoJs源码-QQ加群成员脚本(2)。本资源购买前提醒:本源码都是实际autojs项目模板,安装好autojs直接运行即可打开。1、支持低版本autojs。2、资源仅供学习与参考,请勿用于商业用途,否则产生的一切后果将由您自己承担!。3、安装过程详见具体资源,不会使用autojs谨慎下载
资源推荐
资源详情
资源评论
![thumb](https://img-home.csdnimg.cn/images/20210720083646.png)
![thumb](https://img-home.csdnimg.cn/images/20210720083646.png)
![thumb](https://img-home.csdnimg.cn/images/20210720083646.png)
![thumb](https://img-home.csdnimg.cn/images/20210720083646.png)
![thumb](https://img-home.csdnimg.cn/images/20210720083646.png)
![thumb](https://img-home.csdnimg.cn/images/20210720083646.png)
![thumb](https://img-home.csdnimg.cn/images/20210720083646.png)
![thumb](https://img-home.csdnimg.cn/images/20210720083646.png)
![thumb](https://img-home.csdnimg.cn/images/20210720083646.png)
![thumb](https://img-home.csdnimg.cn/images/20210720083646.png)
![thumb](https://img-home.csdnimg.cn/images/20210720083646.png)
![thumb](https://img-home.csdnimg.cn/images/20210720083646.png)
![thumb](https://img-home.csdnimg.cn/images/20210720083646.png)
![thumb](https://img-home.csdnimg.cn/images/20210720083646.png)
![thumb](https://img-home.csdnimg.cn/images/20210720083646.png)
![thumb](https://img-home.csdnimg.cn/images/20210720083646.png)
![thumb](https://img-home.csdnimg.cn/images/20210720083646.png)
![thumb](https://img-home.csdnimg.cn/images/20210720083646.png)
![thumb](https://img-home.csdnimg.cn/images/20210720083646.png)
![thumb](https://img-home.csdnimg.cn/images/20210720083646.png)
![thumb](https://img-home.csdnimg.cn/images/20210720083646.png)
![thumb](https://img-home.csdnimg.cn/images/20210720083646.png)
![thumb](https://img-home.csdnimg.cn/images/20210720083646.png)
![thumb](https://img-home.csdnimg.cn/images/20210720083646.png)
![thumb](https://img-home.csdnimg.cn/images/20210720083646.png)
![thumb](https://img-home.csdnimg.cn/images/20210720083646.png)
![thumb](https://img-home.csdnimg.cn/images/20210720083646.png)
![thumb](https://img-home.csdnimg.cn/images/20210720083646.png)
收起资源包目录
![package](https://csdnimg.cn/release/downloadcmsfe/public/img/package.f3fc750b.png)
![file-type](https://csdnimg.cn/release/download/static_files/pc/images/minetype/UNKNOWN.png)
共 1 条
- 1
资源评论
![avatar-default](https://csdnimg.cn/release/downloadcmsfe/public/img/lazyLogo2.1882d7f4.png)
![avatar](https://profile-avatar.csdnimg.cn/default.jpg!1)
[虚幻私塾】
- 粉丝: 335
- 资源: 1558
上传资源 快速赚钱
我的内容管理 展开
我的资源 快来上传第一个资源
我的收益
登录查看自己的收益我的积分 登录查看自己的积分
我的C币 登录后查看C币余额
我的收藏
我的下载
下载帮助
![voice](https://csdnimg.cn/release/downloadcmsfe/public/img/voice.245cc511.png)
![center-task](https://csdnimg.cn/release/downloadcmsfe/public/img/center-task.c2eda91a.png)
安全验证
文档复制为VIP权益,开通VIP直接复制
![dialog-icon](https://csdnimg.cn/release/downloadcmsfe/public/img/green-success.6a4acb44.png)