mirror of
https://github.com/pret/pmd-sky.git
synced 2026-09-28 13:24:02 -05:00
7658e4f92effe8eabce2ba75c4abed75da3fbf1a
Located as five groups of ten before any matching was attempted, then all fifty matched, then one build, then one commit. overlay_04/06 global accessors 10 ov04_0233CA80 .. ov06_0233CAA8 hardware register bit-fields 10 sub_02009BE8 .. sub_02009D20 save reset / play timer 10 sub_020483B8 .. sub_0204F9E0 sound veneers + window accessors 10 sub_02017C90 .. sub_02030A74 dungeon fixed-room / item 10 CloseFixedBin .. GenerateStandardItem Every group is a contiguous run at a file head or tail, so extract_function merges each function into an adjacent source instead of splitting a .s. None of the fifty carries a region conditional -- checked per function, not per file -- so US alone verifies this commit. Twelve of the fifty are interworking tail-call veneers (ldr ip, =f; bx ip). That falls straight out of an ordinary forwarding call, and survives both argument reordering (GenerateStandardItem) and a computed argument (sub_020483B8). Nothing in the tree had a veneer decompiled, so the shape was proven on one before the other forty-nine were written. Their parameter lists are guesses: a veneer forwards registers untouched, so the emitted code is identical for any arity and the match constrains nothing. sub_020483D8 returns its callee's result. It sat at 40 through five spellings with the pointer one register low; the target never reuses r0 after the call because that value is the return value. Adding `return ok;` gives 0, and the return is invisible in the asm because the value is already in place. Two type corrections found by probing: the Are*Allowed family compares the dungeon id unsigned (bcc, not blt -- 200 signed), and the register setters need a u32 intermediate, since a u16 local forces a lsl/lsr truncation the target lacks (615). New placeholder structs: unk_0233F660, unk_0233EEE0, unk_020AFEF4, unk_02030A50. src/main_02017C80.c's existing PlaySeByIdVolume(s32, s32) declaration is kept in preference to this commit's; both affected functions were re-scored against it and still match. Authored by Claude (Opus 5) under human direction. All fifty verified at score 0. Confirmed by a matching build: build/pmdsky.us/pmdsky.us.nds: OK. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
…
…
…
…
…
Pokémon Mystery Dungeon: Explorers of Sky
This is a WIP disassembly of Pokémon Mystery Dungeon: Explorers of Sky. For instructions on how to set up the repository, please read INSTALL.md. For information on how to contribute changes, see CONTRIBUTING.md.
This repository builds the following ROMs:
- pmdsky.us.nds
sha1: 5fa96ca8d8dd6405d6cd2bad73ed68bc73a9d152 - pmdsky.eu.nds
sha1: c838a5adf1ed32d2da8454976e5b1a1aa189c139 - pmdsky.jp.nds
sha1: 7785138dd343b6f2d0f2c9cadc26b4aa927161d7
For contacts and other pret projects, see pret.github.io.
Description
Languages
Assembly
66.3%
C
18%
C++
7.1%
Boogie
4.3%
sed
1.5%
Other
2.8%