|
|
分享一下我的宏,通过检测大写开关来做到随时停下,这样不影响打字。
- d1=14
- d2=13
- d3=14
- d4=10
- d5=8
- function OnEvent(event, arg, family)
- if (event == "MOUSE_BUTTON_PRESSED" and arg == 10) then
- t=0
- adfstart()
- while(IsKeyLockOn("capslock"))do
- adfloop()
- end
- end
- end
- function adfstart()
- PlayMacro("adf1")
- Sleep(50)
- PlayMacro("adf2")
- Sleep(50)
- PlayMacro("adf3")
- Sleep(50)
- PlayMacro("adf4")
- Sleep(50)
- PlayMacro("adf5")
- Sleep(50)
- Sleep(250)
- t=t+1
- t1=t
- t2=t
- t3=t
- t4=t
- t5=t
- end
- function adfloop()
- if(t1==d1) then
- PlayMacro("adf1")
- t1=0
- end
- Sleep(50)
- if(t2==d2) then
- PlayMacro("adf2")
- t2=0
- end
- Sleep(50)
- if(t3==d3) then
- PlayMacro("adf3")
- t3=0
- end
- Sleep(50)
- if(t4==d4) then
- PlayMacro("adf4")
- t4=0
- end
- Sleep(50)
- if(t5==d5) then
- PlayMacro("adf5")
- t5=0
- end
- Sleep(50)
- Sleep(50)
- Sleep(205)
- t1=t1+1
- t2=t2+1
- t3=t3+1
- t4=t4+1
- t5=t5+1
- end
复制代码 |
|