first commit
This commit is contained in:
commit
761b95080f
404 files changed
+312608
No files matched your search
@@ -0,0 +1,20 @@
|
||||
-- 示例 1:无限找图点击
|
||||
-- 用法:把要点击的按钮截图(F11 框选截图)保存到 images/start.png,再运行本脚本
|
||||
-- 热键:F8 启动队列 / F9 暂停 / F10 停止;鼠标甩到左上角 (0,0) 紧急停止
|
||||
|
||||
log("开始找图循环")
|
||||
|
||||
while true do
|
||||
local x, y = findImage("images/start.png", 0.85)
|
||||
|
||||
if x >= 0 then
|
||||
moveTo(x, y)
|
||||
delay(80)
|
||||
leftClick()
|
||||
log("已点击 (" .. x .. "," .. y .. ")")
|
||||
delayRandom(600, 1200)
|
||||
else
|
||||
log("未找到图片,1 秒后重试")
|
||||
delay(1000)
|
||||
end
|
||||
end
|
||||
Reference in new issue
Block a user