From 905b075e1e6980f3c22eac6d39c102ff2a933eab Mon Sep 17 00:00:00 2001 From: px5m9o7hn <3092715829@qq.com> Date: Sun, 3 Nov 2024 21:21:44 +0800 Subject: [PATCH] ADD file via upload --- 4.js | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) create mode 100644 4.js diff --git a/4.js b/4.js new file mode 100644 index 0000000..1186a06 --- /dev/null +++ b/4.js @@ -0,0 +1,33 @@ +// 初始化点赞速度,默认1秒 +let likeSpeed = 1000; + +// 创建悬浮窗口 +let window = floaty.window( + + + + + +); + +// 设置悬浮窗位置为屏幕中央 +window.setPosition(300, 1200); // 调整位置,使窗口在中央 + +window.speedBar.setOnSeekBarChangeListener({ + onProgressChanged: function (seekBar, progress, fromUser) { + likeSpeed = progress; // 将进度值直接用于点赞速度 + window.speedText.setText("速度:" + likeSpeed + "毫秒"); + } +}); + +function autoLike() { + while (true) { + click(600 / 2, 2000 / 2); // 双击屏幕中间点赞 + sleep(100); + click(600 / 2, 2000 / 2); + sleep(likeSpeed); // 根据滑动条设置的速度控制点赞间隔 + } +} + +// 启动自动点赞功能 +autoLike(); \ No newline at end of file