 |
AutoHotkey Community Let's help each other out
|
| View previous topic :: View next topic |
| Author |
Message |
FPS fantatic ! Guest
|
Posted: Sun Oct 16, 2005 3:26 pm Post subject: Help, hotkeying 1 key too 4 keystrokes with delays between? |
|
|
IM trying to set up my NumpadEnd so it sets of a string of keystrokes with delays at certain points. (to help with a game)
im a novice to this program. Ive set some simply stuff up like 1 or 2 hotkeys but thats it.
this is the code ive got so far (to give you a idea what im trying to do)
NumpadEnd::
send, {j}
Sleep, 100
Send, {Up 2}
Sleep, 80
Send, {RCtrl}
Sleep, 20
Send, {LShift}
The j is my jump key in the game. I need the delay before the next set of key presses because i need to reach a certain jump height before the rest of the sequence comes into affect. (rougly 1 secound i think)
The next thing is Up pressed twise very fast. This is to perform a mid air dash. While im in the middle of a dash keystrokes are ignored by the game. So thats why i need a delay after the dash. Im guessing here but im thinking just less then a secound is needed before the next keystroke comes in.
RCtrl is attack. I need the attack to come stright after the dash. Problem is through how do i make it so RCtrl is pressed once like a normal keystroke. I tried {RCtrl down) and it stays pressed in for the entire game(keeps attacking) and {RCtrl Up} is no good cuz that does nothing.
I need a very short delay after the RCtrl Key stroke. (if i can get a keystroke)
The last key in the sequence is LShift which i have the same problem with as RCtrl. Lshift is block in my game.
The code above does not even make my character jump. Hell it seems to do nothing.
NumpadEnd::send {j}
will make my guy jump but thats it lol i cant seem to get past that unless i put stuff in like Lctrl down which sets my guy to autofire which ant what i want.
So im trying to get a code together so my character.
Jumps into the air then Dashes and Attacks stright after the dash with a Block almost at the same time as the attack.
Any help or codes would be great  |
|
| Back to top |
|
 |
Hotfoot
Joined: 14 Sep 2005 Posts: 21
|
Posted: Sun Oct 16, 2005 7:13 pm Post subject: |
|
|
Your code seems to be on the right track. You need a 'return' at the end of the sequence of commands for your hotkey -- if you have more than one line for your hotkey sequence. And the sleep timing is in milliseconds. So 1 second is 1000. Try this:
| Code: |
NumpadEnd::
send, {j}
Sleep, 1000
Send, {Up 2}
Sleep, 800
Send, {RCtrl}
Sleep, 200
Send, {LShift}
return
|
|
|
| Back to top |
|
 |
|
|
You can post new topics in this forum You can reply to topics in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|