It's simple, it's ugly, but it works.
1. Change both F22 in the code to your desired hotkey (i recommend using a macro button on your mouse)
2. Hold down the key and move mouse to scroll up/down/left/right
Code: Select all
F22::
T = 150 ; move treshold sideways
T2 = 70 ; move treshold vertical
MouseGetPos, x0, y0
while getkeystate("F22", "p")
{
MouseGetPos, x, y
if (x0-x > T) {
x0 := x0-T
sendinput, {WheelRight}
}
if (x0-x < -T) {
x0 := x0+T
sendinput, {WheelLeft}
}
if (y0-y > T2) {
y0 := y0-T2
sendinput, {WheelDown}
}
if (y0-y < -T2) {
y0 := y0+T2
sendinput, {WheelUp}
}
sleep, 20
}
return