I'm using the latest version: 2.0-a136-feda41f4
on V1 working:
Code: Select all
...
~LButton::
if GetKeyState("LButton") {
Keywait, LButton, t.8
if (ErrorLevel=1 and LClick=0) {
RandomSleep(1,20) ;random sleep function
SendInput, e
LClick=1
}
}
Code: Select all
...
~LButton:: {
if GetKeyState("LButton", "P") {
Keywait "LButton", "T.8"
if (Keywait=1 and LClick=0) {
RandomSleep(1,20) ;random sleep function
SendInput "e"
LClick=1
}
}
}
Instead of "ErrorLevel" I put it to check the Keywait function, as it says in the V2 documentation.
But I think I'm doing it wrong, because even with the mouse pressed for more than 8 milliseconds it doesn't pass the second if
If I remove "Keywait=1" and leave only the "LClick=0" check it passes, but doesn't wait for the 8 millisecond time, it passes as soon as it clicks.
Every help is welcome!