Skip to content

Instantly share code, notes, and snippets.

@marvk
Last active March 25, 2020 00:08
Show Gist options
  • Save marvk/ee14e8cec77c57764e6d2293be4b0a0a to your computer and use it in GitHub Desktop.
Save marvk/ee14e8cec77c57764e6d2293be4b0a0a to your computer and use it in GitHub Desktop.
PigFarm Script
$F20::
Sleep := 10
NumRight := 4
CntInner := 20
DistRight := 5
NumLeft := NumRight * 2
DistLeft := DistRight * -1
While GetKeyState("F20","P") {
Loop %NumRight% {
Loop %CntInner% {
DllCall("mouse_event", uint, 1, int, DistRight, int, 0, uint, 0, int, 0)
Sleep, %Sleep%
}
Click
}
Loop %NumLeft% {
Loop %CntInner% {
DllCall("mouse_event", uint, 1, int, DistLeft, int, 0, uint, 0, int, 0)
Sleep, %Sleep%
}
Click
}
Loop %NumRight% {
Loop %CntInner% {
DllCall("mouse_event", uint, 1, int, DistRight, int, 0, uint, 0, int, 0)
Sleep, %Sleep%
}
Click
}
}
Return
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment