Skip to content

Extracting Some NDS Roms Misnumbers Overlays #16

@Jawshoeuh

Description

@Jawshoeuh

Bug Report

Extracting/Unpacking NDS files where the file id doesn't match the overlay id causes the overlays to be mislabeled/misnumbered.

What's the issue you encountered?

While some (possibly most) NDS files have the file id match the overlay id, Pokémon Mystery Dungeon: Blue Rescue Team does not. The entries for overlays 0-5 in y9.bin have been included as an example:
00 00 00 00 60 19 14 02 40 47 02 00 A0 04 00 00 10 5E 16 02 14 5E 16 02 _00 00 00 00_ 00 00 00 00 01 00 00 00 60 19 14 02 40 0E 08 00 60 08 00 00 90 25 1C 02 94 25 1C 02 **05 00 00 00** 00 00 00 00 02 00 00 00 60 19 14 02 80 4B 00 00 C0 0E 00 00 04 64 14 02 08 64 14 02 **07 00 00 00** 00 00 00 00 03 00 00 00 40 65 16 02 20 00 00 00 00 00 00 00 40 65 16 02 44 65 16 02 **09 00 00 00** 00 00 00 00 04 00 00 00 40 65 16 02 20 00 00 00 00 00 00 00 40 65 16 02 44 65 16 02 **0B 00 00 00** 00 00 00 00 05 00 00 00 40 65 16 02 60 5B 00 00 00 00 00 00 98 C0 16 02 9C C0 16 02 **0D 00 00 0**0 00 00 00 00
'overlay_0001.bin' has a file id of 5 and ends up being named 'overlay_0005.bin'.

Unpacking and then repacking the NDS file seems to works fine since it uses the overlay id as the file id.

How can the issue be reproduced?

Unpack any rom that has the file id not match the overlay id.

Environment?

N/A

Additional context?

N/A

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions