Patching DLLs (hex edits)
bicarus edited this page 2026-01-15 01:54:03 -08:00

Option 1) Using Built-in Patches

Spice2x can apply patches to the DLL using the Patches tab in the UI.

For a handful of old game versions, some useful patches are build into spice and will load automatically. These built-in patches have not been updated since around 2021, and will not be updated in this fork.

However, as you can see below, you can use other sources online to obtain newer patches.

Option 2) Importing patches from a URL

Caution

You are downloading code from an online source. It is theoretically possible for patches to contain malware. Only use trusted sites and use at your own risk!

  1. Open spicecfg.exe
  2. Go to Patches tab
  3. Click on Import from URL.
  4. Enter the base URL for the patcher.

A remote source can be specified from which spice2x can fetch patches. The URL to be given is the base-URL of the patcher website. Given the URL, spice2x will automatically download patches and save them into the patches folder.

Help! I'm having trouble importing patches from an URL

99% of the time, it's because the patcher site you provided doesn't have patches for the game version. Try another URL.

If you need to debug mysterious failures, launch with spice.exe -cfg in the command line and check the log messages for error codes from the winhttp library.

If you're using vanilla Windows 7 image without any Windows updates, you'll most likely need to enable TLS 1.1/1.2 to import patches over HTTPS.

Help! My patches aren't being applied

Launch spicecfg.exe. Open the patches tab. Make sure that the datecode and modules path are identical to what you see in log.txt when you launch the game. If these are mismatched, then patches won't be applied.

If you are using batch scripts to launch games, make sure you are using the same -modules parameter when you launch spicecfg.exe as you would for spice.exe or spice64.exe.

You can also open the overlay in-game and apply patches on the fly. Make sure you press the Save button and restart the game as needed.

This is often an issue for GITADORA players as they switch between two sets of prop XML files (one set for guitar, another for drums).

Option 3) Reading from custom JSON files on disk

Spice2x looks for specific files to fetch the patches from. It looks for patches in the following files, in order:

  • patches\{peIdentifier}.json (See PE Identifier)
  • patches\patches.json
  • patches.json (i.e., right next to spicecfg.exe)
  • {modulePath}\patches.json (i.e., right next to DLLs in the modules directory)
  • ..\patches.json (i.e., in the parent directory of spice.exe)
  • built in patches.json embedded into the binary

First file found in the order above will be used, ignoring the rest.

Option 4) Online patchers

Use Bemani Patcher or other similar sites.

Hard Apply Patches

While not required, patches may need to be written to the module in certain circumstances. With the Hard Apply option, spice2x writes the patches to the module after making a backup to {module}.bak.

I'm a developer and need to know the format for patches.json

See this page.

Using patch "profiles"

As of version 24-09-14 you can use -patchcfgpath option in the command line to specify the path to patch config JSON file. You need to specify this option in the command line for both spicecfg.exe and spice(64).exe, as usual. This way, you can have multiple "profiles" for auto-apply patches; e.g., if you want different set of patches automatically applied for online matching config vs. local play.

What about Unity games?

In general, patches are not supported for Unity-based games (QuizKnock, MFG, Polaris Chord...). Spice's patch system is built to make small modifications to small number of binaries. Most of the game logic is in managed code for Unity-based games, so the patches aren't trivial. Please look to binary replacements and third party tools for patching.

Credits

Github user KuuaDev for contributing this documentation.