Hey guys,
I'm looking to have a script that will allow me to press a single key over and over again but bind to many keys.
EG: Press {E} once and it will press {1}, press {E} again and then it will press {2} and so on, once it gets to say {5} the script will start again. Also if possible when I right click it starts the sequence from the beginning.
I have been able to make a sequence that automatically presses the keys when I press {E} however I want to be able to step it down each time I press {E},
Thank you.
Binding a key for a Sequence
Re: Binding a key for a Sequence
This is possible with a counting variable and an If statement.
You can use RButton::var:=0 to reset the variable, or you may want to use var:=1 and Send 1 if you want the right click to also do the action e normally does.
Code: Select all
var:=0 ; start this at zero
e::
var++ ; increments the variable by 1
If (var=1)
Send 1
else if (var=2)
Send 2
; add in 3 and 4, to make sure you understand what is going on
else if (var=5)
{
Send 5
var:=0 ; reset to zero
}
return
Re: Binding a key for a Sequence
Thank you so much
Who is online
Users browsing this forum: Ragnar and 343 guests