Advertisement
Guest User

ctap script for autohotkey

a guest
Mar 12th, 2014
410
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.39 KB | None | 0 0
  1. ;List of Keynnames can be found here: [url=http://www.autohotkey.com/docs/KeyList.htm]http://www.autohotkey.com/docs/KeyList.htm[/url]
  2.  
  3. #IfWinActive Team Fortress 2
  4. {
  5. ;*******EDIT IN BETWEEN*******
  6. ;needs to be the key you bound +duck to ingame
  7. duckkey = LCtrl
  8.  
  9. ;needs to be the key you bound +jump to ingame (Can't be a duckjump script key)
  10. jumpkey = Space
  11.  
  12. ;needs to be the key you bound +attack to ingame only when manualfire is 0
  13. attackkey = LButton
  14.  
  15. ;is the key that will suspend the whole script if you go another Class for example and need the key for something else
  16. suspendkey = F11
  17.  
  18. ;is the key to perform the ctap
  19. ctapkey = RButton
  20.  
  21. ;set this to 1 if you want to fire manually
  22. manualfire = 1
  23.  
  24. ;sets the delay between pressing and releasing duck 150 seems to be close to the limit where you dont lose velocity. Guess lower numbers could work. 1000 = 1 second
  25. duckdelay = 150
  26.  
  27. ;*******EDIT IN BETWEEN*******
  28.  
  29. Hotkey, %suspendkey%, SUSPEND
  30.  
  31. If manualfire = 1
  32. {
  33. Hotkey, %ctapkey%, CTAPNOFIRE
  34. }
  35. else
  36. {
  37. Hotkey, %ctapkey%, CTAP
  38. }
  39. }
  40. return
  41.  
  42. CTAP:
  43. Send {%duckkey% down}
  44. Sleep %duckdelay%
  45. Send {%duckkey% up}
  46. Send {%jumpkey% down}
  47. Send {%jumpkey% up}
  48. Send {%attackkey% down}
  49. Send {%attackkey% up}
  50. return
  51.  
  52. CTAPNOFIRE:
  53. Send {%duckkey% down}
  54. Sleep %duckdelay%
  55. Send {%duckkey% up}
  56. Send {%jumpkey% down}
  57. Send {%jumpkey% up}
  58. return
  59.  
  60. SUSPEND:
  61. suspend
  62. return
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement