AutoHotkey Community

It is currently May 27th, 2012, 12:28 pm

All times are UTC [ DST ]




Post new topic Reply to topic  [ 22 posts ]  Go to page Previous  1, 2
Author Message
 Post subject:
PostPosted: January 26th, 2009, 12:46 am 
Offline

Joined: November 4th, 2008, 9:23 am
Posts: 1045
So, if the first one works, great - it's the "best" solution.

Here would be that code incorporated into the script.

Code:
#SingleInstance Force
#NoEnv

XButton2::
{
   Loop
   {
       if !getKeyState("XButton2")
       {
           break
       }

      Send, {Click}
      Sleep, 175
   }

    return
}


All I did is remove the second parameter in the getKeyState fuction - the mode. I also added a return statement that I seem to have forgetten :D

_________________
As always, if you have any further questions, don't hesitate to ask.

Add OOP to your scripts via the Class Library. Check out my scripts.


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: January 26th, 2009, 12:53 am 
Offline

Joined: January 13th, 2009, 10:25 pm
Posts: 14
animeaime wrote:
So, if the first one works, great - it's the "best" solution.

Here would be that code incorporated into the script.

Code:
#SingleInstance Force
#NoEnv

XButton2::
{
   Loop
   {
       if !getKeyState("XButton2")
       {
           break
       }

      Send, {Click}
      Sleep, 175
   }

    return
}


All I did is remove the second parameter in the getKeyState fuction - the mode. I also added a return statement that I seem to have forgetten :D


I really hope it works, but I get an error msg when I use this one it says missing "}" in line 5


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: January 26th, 2009, 1:03 am 
Offline

Joined: November 4th, 2008, 9:23 am
Posts: 1045
You didn't copy the entire thing - it missed the last line. I get that error if I remove the last line.

Count the braces - do they match up?

_________________
As always, if you have any further questions, don't hesitate to ask.

Add OOP to your scripts via the Class Library. Check out my scripts.


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: January 26th, 2009, 1:07 am 
Offline

Joined: January 13th, 2009, 10:25 pm
Posts: 14
animeaime wrote:
You didn't copy the entire thing - it missed the last line. I get that error if I remove the last line.

Count the braces - do they match up?


Ah sorry, my bad

but sadly it doesn't work.. The button just stops working ingame ;(

its weird because the script can read it but the game can't but once I use other buttons they work fine

06 000 h d 0.84 XButton2 Call of Duty 4
06 000 a u 0.34 XButton2
06 000 h d 0.06 XButton2


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: January 26th, 2009, 1:09 am 
Offline

Joined: November 4th, 2008, 9:23 am
Posts: 1045
ummm... if the game can't read it, then I'm at a lost - sorry.

_________________
As always, if you have any further questions, don't hesitate to ask.

Add OOP to your scripts via the Class Library. Check out my scripts.


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: January 26th, 2009, 1:17 am 
Offline

Joined: January 13th, 2009, 10:25 pm
Posts: 14
animeaime wrote:
ummm... if the game can't read it, then I'm at a lost - sorry.


Don't worry mate, it's clearly my drivers but I can't play with out them.. I guess I'll have to figure something else out.

Anywho good karma, you're awesome as always. Give me a pm if you ever need anything ^^


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: January 26th, 2009, 1:20 am 
Offline

Joined: November 4th, 2008, 9:23 am
Posts: 1045
Thanks, will do. Take care.

_________________
As always, if you have any further questions, don't hesitate to ask.

Add OOP to your scripts via the Class Library. Check out my scripts.


Report this post
Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 22 posts ]  Go to page Previous  1, 2

All times are UTC [ DST ]


Who is online

Users browsing this forum: chaosad, Exabot [Bot], Google Feedfetcher, jrav and 19 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