Patchnso Switch

From GameBrew
patchnso.py
Patchnsonx.png
General
Authortesnos6921
TypePC Utilities
Version2018
LicenseMixed
Last Updated2018/06/03
Links
Download
Website
Source

A simple script to patch the .text sections of nso files and reassemble them.

Here are some sample videos of what it can do:

User guide

Python 2.7, requires lz4 module to be installed.

Usage Instructions:

  • Using hactool, extract the exefs of your game.
  • Within the exefsdir, there should be "main" and "main.npdm" and possibly a few others.
  • "main" is the game's main nso, you can load it into IDA and create your own patches or go out and find some.
  • When you have your patches put them all in a file in this format: (all values should be in hex) location:codepatch
    • Example: 2E8:21008052
  • Then run "python patchnso.py main patch-file-here output-file-here".
  • Your patched file will appear and you can put it under /atmosphere/titles/title-id/exefs/ on your sd card, renamed back to "main", with the other files from your extracted exefs and you have now patched your game.

Sample patches

Some sample patches are included (made for Super Mario Odyssey Version 1.2.0) which you can try out. Make sure it is on the correct version.

Sample patches nclude:

  • Don't Lose Health.
  • Near-Zero Gravity for Normal Jumps.
  • Raise Coin Limit To 65536 (Untested).
  • High-Power Long Jump.
  • Hyper Walking Speed.
  • Stop Player From Dying (Allows walking on acid and lava) (Credit to SimonMKWii).
  • No Damage for Running out of Oxygen or Staying in Ice Water (Credit to SimonMKWii).

Credits

Thanks to switchbrew.org for docs and the atmosphere team for exefs patching so early.

External links

Advertising: