Heres my Script
Code: Select all
#NoEnv ; Cyka
; #Warn ; Blyat
SendMode Input ; Idi
SetWorkingDir %A_ScriptDir% ; Nahui
#NoEnv
SendMode, Input
SetBatchLines -1
CoordMode, Mouse, Screen
mouseXY(x, y){
DllCall("mouse_event",uint,1,int,x,int,y,uint,0,int,0)
}
strafe(left){
moveCount := 5
sleepInterval := 1
relativeMove := 600
if(left){
key := "a"
move := -relativeMove
} else {
key := "d"
move := relativeMove
}
Send, {Blind}{%key% down}
DllCall("Sleep", "UInt", 5)
Loop, %moveCount% {
mouseXY(move, 0)
DllCall("Sleep", "UInt", sleepInterval)
}
Send, {Blind}{%key% up}
}
*LButton::
while getkeystate("LButton","P") {
strafe(false)
strafe(true)
}
return
~Home::Suspend
return
Esc::ExitApp