Kirby's Dream Land/RAM map

From Data Crystal
Jump to navigation Jump to search

Chip tiny.png The following article is a RAM map for Kirby's Dream Land.

So very stubbly.
This page is rather stubbly and could use some expansion.
Are you a bad enough dude to rescue this article?
Address Function
0xC000 - 0xC09F On-Screen Sprite Info, 4 bytes each(y position, x position, tile #, and other attributes). Copied to Object Attribute Memory (0xFE00 - 0xFE9F).
0xCA00 - 0xCAA3 Block solidity for the current level ($00 = air, $01 = semi-solid platform, $02 = solid block, $03 = solid block, $04 = star block with white bg behind it, $05 = star block with black bg behind it, $06 = water, $07 = spikes, $08 = spikes, $09 = solid platform, ...)
0xCB00 - 0xCD94 Level tilemap updates array

Each entry is 6 bytes and corresponds to a block of 2x2 tiles in VRAM tilemap:

  • +$00 : high byte of tilemap address (or $00 to indicate the array ends)
  • +$01 : low byte of tilemap address
  • +$02 : tile id of top-left tile in the block (tilemap address + $00)
  • +$03 : tile id of top-right tile in the block (tilemap address + $01)
  • +$04 : tile id of bottom-left tile in the block (tilemap address + $20)
  • +$05 : tile id of bottom-right tile in the block (tilemap address + $21)
0xD02C Game State ($01 = normal, $05 = drinking a bottle, $06 = warpstar or dying...)
0xD053 Visual Scroll X. This only affects where tiles are drawn.
0xD054 Kirby's X position sub-pixels
0xD055 Visual Scroll Y. This only affects where tiles are drawn.
0xD056 Kirby's Y position sub-pixels
0xD05C Kirby's Actual X position relative the screen. Setting the value past $4C when not at the right edge of a level may cause issues with the game's collision detection.
0xD05D Kirby's Actual Y position relative to the screen
0xD066 Kirby's Inhale Timer. Set at $00 and incrementing at every frame when inhaling. Freezes when stopping inhaling.
0xD06F - 0xD073 Score Displayed (100000s place, 10000s place, 1000s place, 100s place, 10s place)
0xD074 - 0xD075 Kirby X Speed (in pixels and sub-pixels)
0xD076 - 0xD077 Kirby X Speed Maximum ($01.33 (1.2) px/frame for regular movement, $00.C0 (0.75) px/frame for flying, $00.A8 (0.66) px/frame for underwater)
0xD078 - 0xD079 Kirby Y Speed (in pixels and sub-pixels)
0xD07A - 0xD07B Kirby Y Speed Maximum ($02.00 (2.0) px/frame for regular movement, $00.CC (0.8) px/frame for flying)
0xD080 Background Brightness/Contrast. Copied to BGP hardware register (0xFF47).
0xD081 Sprite Brightness/Contrast.
0xD086 Kirby's Current Health
0xD089 Lives
0xD08B - 0xD08D Score divided by 10 (capped at $01869F which is 99999 in decimal, it will display 999990 points)
0xD093 Boss's Current Health
0xDE02 Something to do with parts of the music
0xDE06 - 0xDE19 Copied to sound registers (0xFF10 - 0xFF23)