Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #NoEnv
- SendMode Input
- ~Space:: ;Use the space key to quickly toggle the script on & off
- Hotkey, ~LButton, toggle
- If toggle != 1
- {
- toggle := 1 ; Will beep if it is set to on
- SoundPlay *64 ;Good because it plays over primary speakers. Others tend to play on motherboard speakers. It's 2008 many computers no longer have motherboard speakers!
- }
- else
- {
- toggle := 0 ; Will beep if it is set to off
- SoundPlay *64 ;Good because it plays over primary speakers. Others tend to play on motherboard speakers. It's 2008 many computers no longer have motherboard speakers!
- }
- _auto := true
- ~LButton::autofire()
- ~^LButton::autofire()
- Code:
- \::suspend ;/ key completely suspends the script
- autofire()
- {
- global _auto
- if _auto
- {
- {
- Loop
- {
- if GetKeyState("LButton", "P")
- {
- Test1 := A_Index ;Test1 = A variable that carries outside of the loop, A_Index = how many times this specific loop has run.
- SendInput {LButton DownTemp}
- Sleep, 148 ;Time to wait in MS
- SendInput {LButton Up}
- Sleep, 148 ;Time to wait in MS
- }
- else
- break
- }
- } ;; loop
- } ;; if
- } ;; autofire()
- mouseXY(x,y)
- {
- DllCall("mouse_event",uint,1,int,x,int,y,uint,0,int,0)
- }
- return
- ;;;;;;
- ;;; End script
Add Comment
Please, Sign In to add comment