{
  "added_at": "2026-11-02",
  "additional_evidence_urls": [
    "https://github.com/mattcurrie/mgbdis/blob/95d951a9881a0d7ff1a42a94d1be175da92b1777/README.md#L35-L45",
    "https://github.com/mattcurrie/mgbdis/blob/95d951a9881a0d7ff1a42a94d1be175da92b1777/mgbdis.py#L1314-L1331",
    "https://github.com/mattcurrie/mgbdis/blob/95d951a9881a0d7ff1a42a94d1be175da92b1777/mgbdis.py#L1235-L1261",
    "https://github.com/mattcurrie/mgbdis/blob/95d951a9881a0d7ff1a42a94d1be175da92b1777/test/Makefile",
    "https://github.com/mattcurrie/mgbdis/blob/95d951a9881a0d7ff1a42a94d1be175da92b1777/.github/workflows/test.yml",
    "https://github.com/mattcurrie/mgbdis/tree/95d951a9881a0d7ff1a42a94d1be175da92b1777/test",
    "https://github.com/mattcurrie/mgbdis/blob/95d951a9881a0d7ff1a42a94d1be175da92b1777/LICENSE",
    "https://github.com/mattcurrie/mgbdis/releases/tag/v3.0"
  ],
  "category": "game-analysis",
  "description_en": "Python disassembler that turns a Game Boy or Game Boy Color ROM, including multi-bank ROMs, into RGBDS-compatible assembly plus a Makefile that reassembles it, so the rebuilt ROM can be compared with the input. An optional .sym file beside the ROM supplies labels and marks code, data, text, padding and 1bpp/2bpp tile-image blocks; images are written as PNG files that rgbgfx converts back, text can use custom character maps, and hardware registers get hardware.inc names. The README explains that SM83 instructions vary in length and data is interleaved with code, so marked code blocks keep it from disassembling mid-instruction.",
  "description_zh": "用 Python 编写的反汇编器，可把 Game Boy 或 Game Boy Color ROM（包括多存储体 ROM）转换为与 RGBDS 兼容的汇编代码，并生成用于重新汇编的 Makefile，以便将重建出的 ROM 与输入文件比对。ROM 旁可放置同名 .sym 文件，用来提供标签，并标出代码、数据、文本、填充以及 1bpp/2bpp 图块图像区段；图像会输出为 PNG，再由 rgbgfx 转换回去，文本可使用自定义字符映射，硬件寄存器则采用 hardware.inc 中的名称。README 解释说，SM83 指令长度不一，且数据与代码交错存放，因此需要标出代码区段，避免从指令中间开始反汇编。",
  "entry_url": "https://awesomerea.org/resources/mgbdis/",
  "entry_url_zh": "https://awesomerea.org/zh/resources/mgbdis/",
  "evidence_url": "https://github.com/mattcurrie/mgbdis/blob/95d951a9881a0d7ff1a42a94d1be175da92b1777/README.md",
  "group": "tools",
  "id": "mgbdis",
  "json_url": "https://awesomerea.org/resources/mgbdis/record.json",
  "kind": "tool",
  "markdown_url": "https://awesomerea.org/resources/mgbdis/index.md",
  "markdown_url_zh": "https://awesomerea.org/zh/resources/mgbdis/index.md",
  "name": "mgbdis",
  "name_zh": "mgbdis Game Boy ROM 反汇编器",
  "record_type": "resource",
  "relationship": "foundation",
  "requirements": [
    "Latest release at review: v3.0, published 2025-04-22; the reviewed master commit of 2026-07-31 is 15 commits ahead of that tag and still reports version 3.0. It is a single Python script that needs Python 3.6+, and the generated assembly targets RGBDS v0.8.0 or later, whose rgbasm, rgblink, rgbfix and rgbgfx the generated Makefile calls. Options control hexadecimal case, indentation, operand alignment and mnemonic variants, and a --tiny mode handles unbanked 32 KiB ROMs.",
    "The input is a ROM file the user supplies, optionally with a same-named .sym file; the repository ships no game ROMs. It bundles PyPNG's png.py and a copy of gbdev's hardware.inc, and its only test ROM is assembled during testing from the project's own assembly sources. The README suggests generating code-block symbol files with the author's separate Beaten Dying Moon emulator, which records the instructions actually executed.",
    "GitHub Actions installs the latest RGBDS release, builds the test ROM, disassembles it, diffs the output against committed expected files, then reassembles the disassembly and compares it byte for byte with the test ROM. This checks the tool on its own fixture, not on commercial games. The README notes that RGBDS inserts a NOP after STOP, so a STOP not followed by NOP is emitted as a data byte, and calls the tool slow on large ROMs.",
    "MIT license; png.py carries its own MIT notice. mgbdis produces assembly rather than C, and labels and block boundaries come from the analyst's symbol file."
  ],
  "requirements_zh": [
    "审阅时的最新发布版为 v3.0，发布于 2025-04-22；所审阅的 master 分支提交日期为 2026-07-31，比该标签多 15 个提交，版本号仍为 3.0。它是一个单独的 Python 脚本，需要 Python 3.6+；生成的汇编代码面向 RGBDS v0.8.0 或更高版本，生成的 Makefile 会调用其中的 rgbasm、rgblink、rgbfix 和 rgbgfx。命令行选项可控制十六进制大小写、缩进、操作数对齐和助记符写法，--tiny 模式用于不分存储体的 32 KiB ROM。",
    "输入是使用者自备的 ROM 文件，可另附同名 .sym 文件；仓库不附带任何游戏 ROM。仓库内置 PyPNG 的 png.py 和 gbdev 的 hardware.inc 副本，唯一的测试 ROM 在测试时由项目自己的汇编源码构建而成。README 建议用作者另行开发的 Beaten Dying Moon 模拟器生成代码区段符号文件，该模拟器会记录实际执行过的指令。",
    "GitHub Actions 会安装最新的 RGBDS 发布版，构建测试 ROM 并将其反汇编，把输出与仓库中提交的预期文件逐一比对，再重新汇编反汇编结果，与测试 ROM 逐字节比较。这只是在项目自带样本上检验工具，并未覆盖商业游戏。README 指出，RGBDS 会在 STOP 后自动插入 NOP，因此原 ROM 中后面不是 NOP 的 STOP 会输出为数据字节；README 还说明该工具处理大型 ROM 时速度较慢。",
    "采用 MIT 许可；png.py 附有其自身的 MIT 声明。mgbdis 输出的是汇编代码而非 C 代码，标签和区段边界来自分析者编写的符号文件。"
  ],
  "targets": [
    "binary",
    "game"
  ],
  "url": "https://github.com/mattcurrie/mgbdis",
  "verification": "source-reviewed",
  "verified_at": "2026-10-27"
}
