rom-weaver

Bake cheat codes into a ROM

Write Game Genie or GameShark/Pro Action Replay codes permanently into a ROM with rom-weaver patch apply --code, so the effect is there without a cheat device or an emulator cheat list.

Bake one code

rom-weaver patch apply --input game.nes --code SXIOPO --output game-coded.nes

--code is treated as a patch: the codes are applied to the ROM and the result is written to --output. Your input file is not changed.

Bake several codes

Repeat the flag:

rom-weaver patch apply \
  --input game.nes \
  --code SXIOPO \
  --code AEKPTZ \
  --output game-coded.nes

Say which console or scheme a code is for

rom-weaver works both out from the ROM header and the code's shape. Pin them when it cannot:

rom-weaver patch apply \
  --input game.bin \
  --code 00A2-01F5 \
  --code-system genesis \
  --code-kind game-genie \
  --output game-coded.bin

--code-system accepts nes, snes, genesis, and gameboy. --code-kind accepts auto (the default), game-genie, and gameshark/par.

Combine codes with a patch

--code works alongside --patch, so a hack and a code can land in one run:

rom-weaver patch apply \
  --input game.nes \
  --patch translation.bps \
  --code SXIOPO \
  --output game-final.nes

Prove what you produced

Hash the result so you can tell the baked ROM apart from the clean one later:

rom-weaver checksum --input game-coded.nes --algo sha256

Keep the clean ROM. A patch author's checksum refers to the unbaked file, so a later patch will refuse the baked one.