SM64 N64 Memory Map
By James S.
You can email me at james.boshikoopa@gmail.com
This is a list of the location of important variables for the different versions of the game. I will update it as I confirm the use, size, etc of more variables. The variables are listed here as they are in memory (RAM), in order of address. All address values are in hex as are any values that start with 0x.
PAL=UK version
NTSC=USA version
JAP ORG=Original Japanese
JAP SE=Japanese Shindou Edition
GFX ID=graphic ID, an index value that selects what graphic is to be used for an object to be spawned. f/p=floating-point value.
Zoom control of title screen Mario head (32-bit) 0x00000000=default (not zoomed). 0x00000001=zoomed out. 0x00000002=zoomed out even more.
PAL 800EC8C4
Selected star number (8-bit) Used only for star select screen
PAL 801A7530
How many stars to choose from (8-bit) Used only for star select screen
PAL 801B8E42
Level select enable flag (8-bit) Enable level select if=0x01
PAL 802F973C NTSC 8032D58C JAP ORG 8032C64C JAP SE 8030CCBC
Sound display enable flag (8-bit) Enable sound display if=0x01
PAL 802F9744 NTSC 8032D594
Debug display 1 enable flag (8-bit) Enable debug display 1 if=0x01
PAL 802F9748 NTSC 8032D598
Pointer to 1P controller data (32-bit) Pointer to 1P controller data such as what buttons are pressed.
PAL 802F9794 NTSC 8032D5E4
Pointer to 2P controller data (32-bit) Pointer to 2P controller data such as what buttons are pressed.
PAL 802F9798 NTSC 8032D5E8
Screen width (16-bit) Used during end credits, simulates a window on the 3D world. Sized from the screen's centre.
PAL 802F9D00 NTSC 8032DB30
Screen height (16-bit) Used during end credits, simulates a window on the 3D world. Sized from the screen's centre.
PAL 802F9D02 NTSC 8032DB32
Screen horizontal position (16-bit) Used during end credits, simulates a window on the 3D world.
PAL 802F9D08 NTSC 8032DB38
Screen vertical position (16-bit) Used during end credits, simulates a window on the 3D world.
PAL 802F9D0A NTSC 8032DB3A
Pointer to start of list of pointers to graphic structures (32-bit)
PAL 802F9F94
Unused screen area colour (32-bit) Colour of unused area of screen when resized or moved to form a window. Lower 12 bits are RGB? (?=unknown). Used during end credits, normally black.
PAL 802F9FB0 NTSC 8032DDE0
Level number (16-bit) Number that represents what level is being played.
PAL 802F9FC8
How many bars to display for sound display (16-bit) =0x0000 1 bar above lower blue bar. 0x0001 2 bars, one above lower yellow bar and other above lower orange bar.
PAL 802FA0F0
Type of debug 2 display select (8-bit) Selects what data is to be displayed using values from 0x00 to 0x05
PAL 802FD054 NTSC 80330E94 JAP ORG 8032FF34 JAP SE 803105C4
Message to display (16-bit) Used by Toads, signposts, etc. Equals 0xFFFF when there is no message to show.
PAL 802FD644
Work elevator (Hazy maze cave) current action (8-bit) What the elevator is doing such as moving and what direction, etc.
PAL 802FED54 NTSC 803327A4
Mario's world X position (f/p 32-bit)
PAL 8030946C NTSC 8033B1AC
Mario's world Y position (f/p 32-bit)
PAL 80309470 NTSC 8033B1B0
Mario's world Z position (f/p 32-bit)
PAL 80309474 NTSC 8033B1B4
Mario's speed (f/p 32-bit)
PAL 80309484 NTSC 8033B1C4
Number of stars collected (16-bit)
PAL 803094DA NTSC 8033B21A
Display Ü at right of screen (keys in JAP versions, glitched up characters in NTSC version) (8-bit) Display Ü character(s) using values from 0x01 to 0x06
PAL 803094DC NTSC 8033B21C JAP ORG 80339EAC JAP SE 8031DA6C
Mario's lives (8-bit)
PAL 803094DD NTSC 8033B21D
Mario's health (16-bit)
PAL 803094DE NTSC 8033B21E
Raise Mario above or lower him below the ground (16-bit) Higher values place Mario above ground, lower values put him below the ground. Usual value is 0x00BD.
PAL 803094E0 NTSC 8033B220
Start of list of segment start address pointers (each pointer is 32-bit)
PAL 803096C8 NTSC 8033B400
Start of list of pointers to graphic structures (each pointer is 32-bit)
PAL 80309790 NTSC 8033B4D0
Pointer to level collision data (32-bit) As calculated from the segment/offset value from the 0x2E level command.
PAL 80309BD4
Music number (16-bit) Which music track to play (does not change music instantly, and affects most areas).
PAL 80309C04 NTSC 8033B944
Camera control type (16-bit) Selects normal, canon, end credits camera movement and others.
PAL 8030A7FE
Debug display 2 enable flag (32-bit) Enable debug display 2 if=0x00000001
PAL 8030AE90 NTSC 8033D260 JAP ORG 8033BEF0 JAP SE 8031F420
Spawn debug mode enable flag (16-bit) Enable spawn debug mode which uses D-pad if=0x0001 and Type of debug 2 display select=0x03.
PAL 8030AF0E NTSC 8033D2DE JAP ORG 8033BF6E
Behaviour update enable? (32-bit) Used by signposts, and when talking someone, to stop other objects from being updated according to their behaviours. Various bit values freeze all objects except Mario or all objects including Mario.
PAL 8030B0B0 NTSC 8033D480
First of 240 object structures (each object structure is 608 bytes long)
PAL 8030B0B8
Pointer to Mario object (32-bit) Where the Mario object is in memory
PAL 8032ED88 NTSC 8033B1F8 Also 80361158
Pointer to object being updated (32-bit) Which object the game is currently updating
PAL 8032ED90 NTSC 80361160
Pointer to what part of behaviour script is being processed (32-bit)
PAL 8032ED94
Speed of moving parts (speed mode) in Tick tock clock? (16-bit)
PAL 8032EE88
Pointer to level command that is currently being executed (32-bit)
PAL 80386BA8 NTSC 8038BE28
All content of this and related pages is copyright (c) James S. 2003-2009