Advertisement
FocusedWolf

Rust Binds

Jan 27th, 2014
1,045
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. ; Usage: 1. Install AutoHotKey.
  2. ;        2. Save this to "RustBinds.ahk".
  3. ;        3. Double click "RustBinds.ahk" to launch.
  4. ;
  5. ; Features: Arrow keys are binded to the first 4 hotbar items, but can be easily edited to be different.
  6. ;
  7. ; Fixes: Shift + Tab now works to display the Steam overlay.
  8. ;        Holding Escape or your inventory key will no longer spam the menus into and out of view until you let go.
  9.  
  10. #SingleInstance force
  11. process, priority, ,high
  12. SetBatchLines, -1
  13. SetKeyDelay, -1, -1
  14.  
  15. ; -------- Hotbar Binds For Arrow Keys --------
  16.  
  17. #IfWinActive PlayRust
  18. ~*Left::
  19.  
  20.     Send {blind}{1} ; Press the "1" button
  21.  
  22.     KeyWait, Left
  23.  
  24.     return
  25.  
  26. #IfWinActive PlayRust
  27. ~*Up::
  28.  
  29.     Send {blind}{2} ; Press the "2" button
  30.  
  31.     KeyWait, Up
  32.  
  33.     return
  34.  
  35. #IfWinActive PlayRust
  36. ~*Right::
  37.  
  38.     Send {blind}{3} ; Press the "3" button
  39.  
  40.     KeyWait, Right
  41.  
  42.     return
  43.  
  44. #IfWinActive PlayRust
  45. ~*Down::
  46.  
  47.     Send {blind}{4} ; Press the "4" button
  48.  
  49.     KeyWait, Down
  50.  
  51.     return
  52.  
  53. ; -------- Shift + Tab Fix --------
  54.  
  55. ; Fixes the issue with how hard it is to use Shift + Tab to display the Steam overlay.
  56. ; With this, from now on when you press Shift + Tab the menu will actually display easily.
  57.  
  58. #IfWinActive PlayRust
  59. *$+Tab::
  60.  
  61.     Send {blind}{Shift Down}
  62.     Send {blind}{Tab Down}
  63.  
  64.     Sleep, 50
  65.  
  66.     Send {blind}{Tab Up}
  67.     Send {blind}{Shift Up}
  68.  
  69.     KeyWait, Shift
  70.     KeyWait, Tab
  71.  
  72.     return
  73.  
  74. ; -------- Inventory and Escape Menu Fix --------
  75.  
  76. ; By default if you hold down Escape or Tab the game flickers those menu's in and out of view which can be annoying.
  77. ; So by detecting and preventing the repeat for these keys we can stop the flicker.
  78.  
  79. ; NOTE: Tab is the key i use to show the Inventory menu. Edit this hotkey if you used something else.
  80.  
  81. #IfWinActive PlayRust
  82. *$Tab::
  83.  
  84.     Send {blind}{Tab}
  85.  
  86.     KeyWait, Tab
  87.  
  88.     return
  89.  
  90. #IfWinActive PlayRust
  91. *$Escape::
  92.  
  93.     Send {blind}{Escape}
  94.  
  95.     KeyWait, Escape
  96.  
  97.     return
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement