我如何做到这一点,所以当我按住鼠标左键并按住“ L”键,然后放开鼠标左键时,它将返回到自动单击脚本
谢谢。
EnablePrimaryMouseButtonEvents(true);
function OnEvent(event, arg)
if IsMouseButtonPressed(1) then
repeat
PressKey("L")
Sleep(math.random(15, 45))
ReleaseKey("L")
Sleep(math.random(15, 45))
until not IsMouseButtonPressed(1)
end
end
EnablePrimaryMouseButtonEvents(true)
function OnEvent(event, arg)
if event == "MOUSE_BUTTON_PRESSED" and arg == 1 then
repeat
PressKey("L")
Sleep(math.random(15, 45))
while IsModifierPressed("lalt") do
Sleep(10)
end
ReleaseKey("L")
Sleep(math.random(15, 45))
until not IsMouseButtonPressed(1)
end
end