AutoHotkey Community

It is currently May 27th, 2012, 2:40 am

All times are UTC [ DST ]




Post new topic Reply to topic  [ 5 posts ] 
Author Message
 Post subject: 180 degree turn in-game
PostPosted: November 22nd, 2009, 9:59 am 
i'm trying to make a script to make a 180 degree turn in a first person shooter known as urban terror. i know it's possible because i've seen a demo of someone doing it, and they said they used autohotkey. i tried their script, but that didn't work because we probably have different screen resolutions and i'm doing something wrong.
so, i tried making it myself.
since my screen is 1280x800 and the first value of mousemove is x, i tried:
g::mousemove, 640, 0, 0, R
it appears to move to random positions, doesn't work too well. see, what i think might be the problem is, is that the crosshair in game is always in the center, i'm not sure if autohotkey recognizes that as the current mouse position.
anyway, could i get some help please?


Report this post
Top
  
Reply with quote  
 Post subject:
PostPosted: November 22nd, 2009, 2:45 pm 
Offline

Joined: July 18th, 2006, 12:18 pm
Posts: 403
It all depends on your sensitivity in game. exacly how many seconds or milliseconds does it take to 180 in the game with your current mouse settings?


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: November 22nd, 2009, 7:56 pm 
Offline

Joined: September 2nd, 2006, 6:39 am
Posts: 279
Location: Scotland
Code:
xVar := 640
SpeedVar := 0
up::xVar += 10
Down::xVar -= 10
Right := SpeedVar++
Left := SpeedVar--
Enter::FileAppend, xvar = %xvar% `n SpeedVar = %SpeedVar%, C:\somefile.txt
g::mousemove, %xvar%, 0, %Speedvar%, R


I havent used ahk for a long time but i think this should work.

Just play around with the values until you find some that work and then press enter to save them to a file.


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: November 27th, 2009, 6:53 am 
how many ms it takes to turn 180 in game depends on how fast i move the mouse obviously... and yes all mouseaccel is off. as for the second post, thanks a ton, but i'm not sure which values exactly i tweak. would you mind simplifying?


Report this post
Top
  
Reply with quote  
 Post subject:
PostPosted: November 27th, 2009, 7:09 am 
nvm i played with that a bit, and i get what youre saying.
the other values are just for editing it on the fly. anyway, it's still going off in random directions.


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

All times are UTC [ DST ]


Who is online

Users browsing this forum: Alpha Bravo, rbrtryn 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