cecilarmitais 262177377d Decomp seven DSE track-event handlers
Decompile from asm:

  DseTrackEvent_Invalid        0x0207191C
  DseTrackEvent_WaitSame       0x02071928
  DseTrackEvent_WaitDelta      0x02071934
  DseTrackEvent_Wait8          0x0207194C
  DseTrackEvent_Wait16         0x0207195C
  DseTrackEvent_Wait24         0x02071978
  DseTrackEvent_MainLoopBegin  0x02071A14

These are handlers in SMD_EVENTS_FUN_TABLE, dispatched by ParseDseEvent. No
new types are introduced: struct dse_track and struct dse_sub_loop already
exist in lib/DSE/include/dse.h, and every offset these functions touch lines up
with a named field there -- is_playing at 2, wait_ticks_left at 0xc,
previous_wait_ticks at 0x10, loop_start at 0x20.

The shared four-argument signature is read off the dispatcher rather than
guessed. ParseDseEvent loads the handler from SMD_EVENTS_FUN_TABLE and calls it
with r0 already advanced past the opcode byte, r1 its own first argument, r2 the
track, and r3 track->channel from offset 0x54; the returned r0 becomes the
track's new position. Its caller passes a sequence and that sequence's track at
offset 0xa8, which is what types the second parameter.

The second parameter is unused by all seven bodies, so their own bytes do not
constrain its type; it is typed from the dispatcher's call site, and the
handlers that do use it are still asm.

Six of these are contiguous and merge into one source file; MainLoopBegin sits
after WaitUntilFadeout and EndTrack, which remain asm, so it splits separately.

No comments are added to any pmd-sky file.

Authored by Claude (Opus 5) under human direction. Confirmed by a matching
build: build/pmdsky.us/pmdsky.us.nds: OK.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-16 14:31:22 -07:00
2026-08-16 14:31:22 -07:00
2026-07-31 18:03:24 -04:00
2026-08-16 14:31:22 -07:00
…
2026-08-01 12:46:55 -04:00
2026-07-16 07:36:58 -07:00
…
…
2026-08-16 14:31:22 -07:00
…
…
…

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:

For contacts and other pret projects, see pret.github.io.

Description
Decompilation of Pokémon Mystery Dungeon: Explorers of Sky
Readme 335 MiB
Languages
Assembly 66.3%
C 18%
C++ 7.1%
Boogie 4.3%
sed 1.5%
Other 2.8%