mirror of
https://github.com/pret/pmd-sky.git
synced 2026-09-28 13:24:02 -05:00
4463a320b61b1018d96f12c8f90941c62a6edc2f
Decompile sub_02064F94, sub_02064FE4, sub_02064FFC and sub_02065014 from asm. All four merge into a new src/main_02064FFC.c; extracting them splits asm/main_0205EDA4.s, the trailing functions move verbatim into asm/main_02065050.s, the affected .inc files are regenerated, and main.lsf gains src/main_02064FFC.o and asm/main_02065050.o. The two remaining functions of the cluster, sub_02065050 and sub_0206549C, are now alone in that tail file. sub_02064FFC and sub_02065014 index the same 12-byte table. EVENTS already exists in the tree; its record type is declared here as struct unk_020A5488, named for the table's address. Worth knowing for anyone reading the diff against the asm: _020A5490 is a separate .global sitting at EVENTS + 8, inside the first record, so sub_02064FFC's literal pool entry reads .word _020A5490 in the target and EVENTS+0x8 from this source. Both resolve to the same address, which the matching build confirms. sub_02064F94 walks an array calling sub_0201E380, and sub_02064FE4 is a tail call into it. Their two argument structs have no global, so they take the address of the function that receives them -- struct unk_02064F94 and struct unk_02064FE4 -- per the placeholder convention. sub_0201E380 and _020AFC70 are still asm and have no header of their own, so both are declared alongside; move them if a better home appears. Nothing here is named for what it means. The structs and their fields are placeholders, and local names stay structural: data is a cursor over 4-byte records, count is the loop bound, value is the field the comparison reads. sub_0201E380's parameters are positional, since only its call site is understood and not the function itself. Anything more specific would be inferred from code two calls downstream rather than read off the asm. No comments are added to any pmd-sky file. Authored by Claude (Opus 4.8) under human direction. Confirmed by a matching build: build/pmdsky.us/pmdsky.us.nds: OK. Co-Authored-By: Claude Opus 4.8 <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%