【发布时间】:2021-12-04 14:17:27
【问题描述】:
我最近在修复我的 Logitech autoclicker 脚本以删除代码中的错误时得到了一些帮助,现在 logitech ghub 似乎认为代码是有效的,除了每次我尝试使用它时,我得到的最多就是单击它而不是在我按住左键时每 20-80 毫秒点击 1 次。 提前感谢任何能够提供帮助的人
代码如下:
EnablePrimaryMouseButtonEvents(true);
function OnEvent(event,arg)
if IsKeyLockOn("capslock") then
if IsMouseButtonPressed(3) then
repeat
if IsMouseButtonPressed(1) then
repeat
PressAndReleaseMouseButton(1)
Sleep(math.random(20,60))
until not IsMouseButtonPressed(1)
end
until not IsMouseButtonPressed(3)
end
end
end
【问题讨论】:
-
如果您松开鼠标按钮 1 并在按住鼠标按钮 3 的同时再次单击它会发生什么?