Skip to content

Instantly share code, notes, and snippets.

@vadimstasiev
Created September 17, 2020 12:12
Show Gist options
  • Save vadimstasiev/84e0af0dd5ce254802cf318039aa5c58 to your computer and use it in GitHub Desktop.
Save vadimstasiev/84e0af0dd5ce254802cf318039aa5c58 to your computer and use it in GitHub Desktop.
Creating custom launcher to set custom process affinity for a given game or program

Notes

This is using powershell 7, I haven't tested with the regular one, but feel free to do so, just swap 'pwsh' with 'powershell' Must also install the ProcessPriority PowerShell module, from: https://github.com/pcgeek86/ProcessPriority

  • To install it just run: Install-Module -Name ProcessPriority -Scope CurrentUser -Force
@echo off
start ./witcher3.exe
echo waiting for the game to start
timeout /T 30
pwsh.exe -Command "& { Set-ProcessPriority -Name witcher3.exe -Priority AboveNormal}"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment