Yu-Gi-Oh! Duel Monsters II: Dark Duel Stories/RAM map

From Data Crystal
Jump to navigation Jump to search

Chip tiny.png The following article is a RAM map for Yu-Gi-Oh! Duel Monsters II: Dark Duel Stories.

SRAM

Address Size    Description
------- ----    -----------
 A000      4    Last PRNG seed
 A004      4    ?
 A008      1    Stage 5 opponent
                0x00 : Yami Yugi
                0x01 : Yami Bakura
                0x02 : Shadi
                0x03 : Ishizu Ishtar
 B7F0      1    SRAM block to read, for save recovery after a save failure
 B7F1     11    Date of build, and KONAMI string
 B7FF      1    Erase save file and start Debug New Game

WRAM

Address Size    Description
------- ----    -----------
 C920      1    ? (set by 3E:4076, called via rst 08 at 0:2D0E)
 D500    108    Card Illustration
 D5A0    720    Cards in trunk
 D875      1    Button pressed
                0x00 : None
                0x01 : A
                0x02 : B
                0x04 : Select
                0x08 : Start
                0x10 : →
                0x20 : ←
                0x40 : ↑
                0x80 : ↓
 D878      1    ?
 D87D      1    ?
 D885      2    P1 Life Points
 D888      2    CPU Life Points
 DB97      1    Save file block
 D8B7      2    Current Card ID ?
 DBB1      1    Music ID in Sound Debug Menu
 D8C4      1    Number of cards in Player's Deck - 1
 D8C5     80    Player's Deck
 D915     80    CPU's Deck
 D965      1    # of cards drawn by CPU
 D979      2    Current card_ID
 D981      1    Current Card Type ID (checked if < 20 by 1:4942 when accessing Password mode)
 D9D2     80    Player's shuffled Deck
 DA22      1    # of cards drawn by Player
 DA32     18    CPU's cards on the Field + card status
 DA47     18    Player's cards on the Field + card status
 DA6B      1    Field Column
 DA6C      1    Field Row
 DA6D      2    Current Card ID
 DA6F      1    Current Card status
                Bit 0: ATK / DEF position
                Bit 1: Is there a card in this zone
                Bit 2: (Card frozen, doesn't seem to be used)
                Bit 3: Card frozen
                Bit 4: Monster Level
                Bit 5: Monster Level
                Bit 6: ? (Indicates the monster has attacked ?)
                Bit 7: -
 DB16      4    PRNG
 DB1A      1    Min value for PRN
 DB1B      1    Max value for PRN
 DB1C      1    1-byte Pseudo-Random Number
 DB1D      1    Current selected menu (main menu)
 DB48      1    Bank #1 containing the Fusion table for Fusion Monster card #1
 DB49      1    Bank #2 containing the Fusion table for Fusion Monster card #1, can be different from wDB48 if the table is on two Banks
 DB4A      2    Pointer to the Fusion table
 DB4C      2    End of the Fusion table
 DB4E      2    Temporary copy of Fusion Monster card #1 ID
 DB50      2    Temporary copy of Fusion Monster card #2 ID
 DB87      1    CPU Deck ID
 DB88      1    ?
 DB96      1    Debug New Game
 DB97      1    Current SRAM block being written
 DB98      1    ?
 DBCF     44    Duel Records
 DBFB     44    Wins Records
 DC30      8    ?
 DC47      4    Copy of PRNG
 DC4F      1    ?
 DD07      1    ?
 DD1B     90    ?

HRAM

Address Size    Description
------- ----    -----------
 FFD9      2    Deck Capacity
 FFDB      1    bits 0-2 : Stores a Pseudo-Random Number in range [0;7] determined with (wDB1C & 7).
                bit 8 : whether or not Grandpa will give a card after battle. 1 out of 8 save files (determined by a call at the PRNG at SRAM creation) have a 1/256 probability to be set by subroutine 4:59E4
 FFDC      1    Stage 5 opponent
                0x00 : Yami Yugi
                0x01 : Yami Bakura
                0x02 : Shadi
                0x03 : Ishizu Ishtar
 FFDD      1    System running the game
                0x01 - Game Boy / Super Game Boy 1
                0x11 - Game Boy Color
                0xFF - Super Game Boy 2
 FFDE      1    System running the game
                0x00 - Game Boy Color
                0x01 - ?
                0x02 - Game Boy
                0x03 - Super Game Boy 2
 FFE4      1    ?