AutoHotkey Community

It is currently May 27th, 2012, 1:07 am

All times are UTC [ DST ]




Post new topic Reply to topic  [ 3 posts ] 
Author Message
PostPosted: January 7th, 2010, 2:07 am 
Offline

Joined: January 7th, 2010, 2:05 am
Posts: 1
#Persistent
#InstallKeybdHook
SetKeyDelay, 75, 75
; increase responsiveness
;#MaxThreadsPerHotkey 20
;#MaxThreadsBuffer on

F4::
Loop, 2
{

Send {F11}
Send {F12}
Sleep 250
Send {F11}
Send {F12}
Sleep 250
Send {F11}
Send {F12}
Sleep 250
Send {F11}
Send {F12}
Sleep 250
Send {F11}
Send {F12}
Sleep 250
Send {F11}
Send {F12}
Sleep 250
Send {F11}
Send {F12}
Sleep 250
Send {F11}
Send {F12}
Sleep 250
Send {F11}
Send {F12}
Sleep 250

}
Return

Here's the current script I use but basically what I would like to do is by pushing F4 to activate the script I would like it to continuously hit F11 and F12 with those delays until I push F4 again. Is this possible and if so can you please write up what the script would look like?

[ Moderator!: Moved from Scripts and Functions ]


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: January 7th, 2010, 4:24 am 
Offline

Joined: June 28th, 2007, 1:08 am
Posts: 662
1. Please post questions in the ask for help forum, but only after....

2. Use the search feature of the forum.

Also,

3. Please post any code you have inside code tags. This makes it easier for others to read your post, and looks much nicer.

Your request is probably one of the most commonly asked (and answered) questions in the ask for help section. Search for auto-fire, auto-repeat, BF2 scripts, or anything along those lines.

I know it probably isn't one of those exactly, but the script will be nearly identical to what you want. It is simply firing off a set of commands in succession until you tell it to quit.


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: January 7th, 2010, 4:39 am 
Offline

Joined: October 26th, 2009, 6:29 am
Posts: 362
Haha your lucky i'm in a helpful mood.
But please in the future post in the "Ask For Help" forum.

Code:
F4::
If Toggle=Off
{
 Toggle=On
 GoTo,Repeat
}
If Toggle=On
 Toggle=Off
Return

Repeat:
While Toggle=On
{
 Send,{F11}{F12}
 Sleep,250
}
Return

*UNTESTED*

_________________
Check out the new AHK forum competition!


Report this post
Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 3 posts ] 

All times are UTC [ DST ]


Who is online

Users browsing this forum: Google [Bot], Leef_me, WillTroll and 25 guests


You can post new topics in this forum
You can reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Powered by phpBB® Forum Software © phpBB Group