Deep Rock Galactic – Autosprint

Using AutoHotkey to create a script that causes Dwarves to kick their stubby legs into high gear at all times!

Why do I need to make a script to sprint?

I can press shift!Dwarves don’t always know whats good for them. For example, they don’t always sprint everywhere. I guess some might think that’s for dirty leafeating elves, but it does save your ♥ from Glyphids.

In DRG there is no penalty for sprinting. You don’t have endurance, and you don’t lose accuracy while sprinting because… you can’t sprint while performing any other action. So I don’t see why there is any reason for it to not be on by default. I find it annoying to constantly press shift after attacking, or shooting, or whatever else I just did. So I made a script to do it for me!

For that, you will need AutoHotkey (or to download in .exe of the script, which I do not know how to post here).

What is AutoHotkey?

AutoHotkey (AHK) is a nifty program that lets you remap keys on your computer, create, macros, and do a whole lot more through scripts. They can be fairly easy to write, even for non-programmers, and there’s plenty of resources online on how to use it.

Technically, you don’t need AutoHotkey to run an .exe created by it, but I don’t know how to upload my .exe so you will have to compile my script yourself to make one.

I have created useful scripts for quite a few games, usually where I found controls to be clunky or redundant.

The Script

To use this script, you will need to have the following settings adjusted in your game. Sprint must be mapped to sprint, and needs to be set to “Hold” in your controls. NumLock will turn the script on and off once the program is running.

To get the script running, download AHK, create a new file with the .ahk extension (mine is called DRGautosprint.ahk), and copy the script below into it. Double click on it to run it, and make sure numlock is on to get your Dwarf moving! If the script isn’t working, try hitting shift once or twice and make your Dwarf do a swing or two. It should fix itself!

Everything below this point is your script, copy and paste it into a .ahk file.

#NoEnv ; Recommended for performance and compatibility with future AutoHotkey releases.
; #Warn ; Enable warnings to assist with detecting common errors.
SendMode Input ; Recommended for new scripts due to its superior speed and reliability.
SetWorkingDir %A_ScriptDir% ; Ensures a consistent starting directory.

;Sprint=Shift
;Set Sprint to “Hold” in controls.
;Use NumLock to turn script on and off.

#If GetKeyState(“NumLock”,”T”)
~w::
If !(GetKeyState(“LButton”,”P”)||GetKeyState(“RButton”,”P”)||GetKeyState(“Tab”,”P”)){
Send {Shift Up}
Send {Shift Down}
}
Return
~w Up::Send {Shift Up}
~LButton::
If GetKeyState(“w”,”P”)
Send {Shift Up}
Return
~LButton Up::
If (GetKeyState(“w”,”P”)&& !(GetKeyState(“LButton”,”P”)||GetKeyState(“RButton”,”P”)||GetKeyState(“Tab”,”P”))){
Send {Shift Up}
Send {Shift Down}
}
Return
~RButton Up::
If (GetKeyState(“w”,”P”)&& !(GetKeyState(“LButton”,”P”)||GetKeyState(“RButton”,”P”)||GetKeyState(“Tab”,”P”))){
Send {Shift Up}
Send {Shift Down}
}
Return
~Shift Up::
If (GetKeyState(“w”,”P”)&& !(GetKeyState(“LButton”,”P”)||GetKeyState(“RButton”,”P”)||GetKeyState(“Tab”,”P”)))
Send {Shift Down}
Return
Tab::
Send {Shift Up}
Send {Tab Down}
Return
~Tab Up::
Sleep 100
If (GetKeyState(“w”,”P”)&& !(GetKeyState(“LButton”,”P”)||GetKeyState(“RButton”,”P”)||GetKeyState(“Tab”,”P”))){
Send {Shift Up}
Send {Shift Down}
}
Return
#If

Created by skeletalhammer

1 Comment

  1. Hey, does it still work? I’ve set it up like you said in the tutorial above but when I toggle NumLock on / off it does nothing…

Leave a Reply

Your email address will not be published.


*