Jump to content

Noob needs help


Recommended Posts

Hi. I'm trying to make a script that will spam a certain keystroke in a program I have. I will usually be AFK when this does this. Anyway, I sometimes get Xfire messages and all kinds of other popups that would cause that window to be deselected. Is there a function that I could use to select the process then hit the keystroke?

Here is my script:

WinWaitActive("World of Warcraft")
                
          
HotKeySet("{PAUSE}", "Start")
HotKeySet("!{PAUSE}","Quit")

TogglePause()
                  
func Start()
HotKeySet("{PAUSE}")
HotKeySet("{PAUSE}", "TogglePause")
ToolTip('Script Started.',0,0)
While 1
Send("{SPACE}")
Sleep(Random(120000,240000))
WEnd
EndFunc

Func TogglePause()
ToolTip('Script Stopped.',0,0)
HotKeySet("{PAUSE}")
HotKeySet("{PAUSE}", "Start")
While 1
sleep(100)
WEnd
EndFunc

func Quit()
Exit
EndFunc
Link to comment
Share on other sites

can u explain a little bit more?

do u have pop-ups and u want to hit a key when ever a pop-up is active?

or what?

[quote]Baby you're all that I want, When you're lyin' here in my armsI'm findin' it hard to believe, We're in heavenAnd love is all that I need , And I found it there in your heartIt isn't too hard to see, We're in heaven .Bryan Adams[/quote].............................................................................[u]AUTOIT[/u]

Link to comment
Share on other sites

Well I need the keystroke to happen when the WOW window/process is active. When I get a message in Xfire, the xfire message box becomes the active window, therefore the WOW window is no longer the active window and the script cannot work. Even a way to make it so that WOW doesn't have to be the active window to make this keystroke would be great, I just don't know how to do that.

And no, all I need is for that space to be hit every 3 minutes. It's to keep my WOW character from going AFK.

Edited by liltechdude
Link to comment
Share on other sites

you should be using these

WinWaitActive

ProcessExists

WinActivate

Send

check the help file for the above commands

Edited by star2

[quote]Baby you're all that I want, When you're lyin' here in my armsI'm findin' it hard to believe, We're in heavenAnd love is all that I need , And I found it there in your heartIt isn't too hard to see, We're in heaven .Bryan Adams[/quote].............................................................................[u]AUTOIT[/u]

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...