AutoHotkey Homepage AutoHotkey Community
Let's help each other out
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Hi looking for some help with a script...

 
Reply to topic    AutoHotkey Community Forum Index -> Ask for Help
View previous topic :: View next topic  
Author Message
Hydropwnix



Joined: 07 Jan 2010
Posts: 1

PostPosted: Thu Jan 07, 2010 1:07 am    Post subject: Hi looking for some help with a script... Reply with quote

#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 ]
Back to top
View user's profile Send private message
Elesar



Joined: 28 Jun 2007
Posts: 622
Location: Somewhere around 35 12N 101 49W

PostPosted: Thu Jan 07, 2010 3:24 am    Post subject: Reply with quote

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.
Back to top
View user's profile Send private message
Ace Coder



Joined: 26 Oct 2009
Posts: 361

PostPosted: Thu Jan 07, 2010 3:39 am    Post subject: Reply with quote

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!
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    AutoHotkey Community Forum Index -> Ask for Help All times are GMT
Page 1 of 1

 
Jump to:  
You can post new topics in this forum
You can reply to topics in this forum


Powered by phpBB © 2001, 2005 phpBB Group