Skip to content

Instantly share code, notes, and snippets.

@JoelLarson
Last active December 30, 2020 08:59
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save JoelLarson/555a4e76b937858375fe1a9c0787da80 to your computer and use it in GitHub Desktop.
Save JoelLarson/555a4e76b937858375fe1a9c0787da80 to your computer and use it in GitHub Desktop.
Poweshell Script for patching in VSync for The Coin Game
## Selected mode
$SelectedMode="Potato"
## Do not edit below here
$GamePath = "C:\Program Files (x86)\Steam\steamapps\common\TheCoinGame\TheCoinGame_Data\globalgamemanagers"
$PatchableSettings=@{
"Potato" = 180392;
"Old Laptop" = 180524;
"Moms Desktop" = 180656;
"Old Gaming Rig" = 180792;
"Rocket Appliance" = 180928;
"Super Computer" = 181064;
"Super VSync" = 181196;
}
if ($PatchableSettings.ContainsKey($SelectedMode)) {
$Bytes = [System.IO.File]::ReadAllBytes($GamePath)
[System.IO.File]::WriteAllBytes($GamePath + ".original", $Bytes)
$Offset = $PatchableSettings[$SelectedMode]
# Patch the byte offset to turn vSyncCount to 1
$Bytes[$Offset] = 0x01
[System.IO.File]::WriteAllBytes($GamePath, $Bytes)
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment