Banner
Views: 827,416,337
Time:
9 users online: Amine Retro, Dan Drigues, ExONightZ, Ice Man, Infinity, PlagueRatofDoom, Steve Eric Jordan,  Tob, YourBoi - Guests: 62 - Bots: 74 Users: 44,265 (2,537 active)
Latest: healthnfitnessmagazine
Tip: If you edit level 0, make sure you also edit level 100. Both of them are used for the bonus game.Not logged in.
SM64 Memory Map
Displaying 186 out of 186 addresses. Show Waiting Addresses (9)
Filter
Link
Address
Hexadecimal number for a partial address. 8-digit number for a full address. Use - to denote a range. Use , to list more than one address.
Length
Type
Enable JavaScript to use multiple regions.
Region
Hold control to select multiple. Check "All" to select all at once.

Type
Context
Description
Separate each individual keyword with spaces. Surround a phrase with quotes to look for the exact phrase, or with / to use a PCRE regular expression. Prepend with - to exclude a keyword or phrase, with + to require a whole word or phrase, or with -+ to exclude a whole word or phrase. ? matches any character, * matches any amount of characters.
 
Per Page: 25 50 75 100 150 500 All
RAM Address Length Type Context Description Details
$80064F80 Unknown Misc. Global Segment 0x02 constant location - Contains image data for the hud symbols and other textures. The segment is allocated by a hardcoded routine on startup.
$8006C680 Unknown Misc. Global Table with segment-offset pointers to the HUD symbol textures. Since some of the HUD symbols were removed in the USA release, some of the slots are left empty:

8006C6CC 00000000 - J
8006C6E8 00000000 - Q
8006C6FC 00000000 - V
8006C704 00000000 - X
8006C70C 00000000 - Z

You can restore the old symbols by patching in the images from the Japanese ROM, and modifying the pointers in this table.
$8007E200 Unknown Misc. Global Segment 0x15
$8007EC20 Unknown Misc. Global Segment 0x04 - Contains the data for Mario's model
$800EB180 Unknown Misc. Global Segment 0x13 - Behavior script segment
$800EC5F8 52 bytes Behaviour Global Behavior script - Purple switch
$800ED3FC 32 bytes Behaviour Global Behavior script - Spinning exclamation point
$800EDBC8 12 bytes Behaviour Global Behavior script - Misc level architecture (eg the castle tower)
$800EDC24 44 bytes Behaviour Global Tree's behavior script
$800EE040 56 bytes Behaviour Global Mario's behavior script

00000000
10050000
11010100
11030001
23000000 002500A0
08000000
0C000000 802CB1C0
0C000000 8029CA58
0C000000 802CB264
09000000
$800EE2F4 56 bytes Behaviour Global Bob-omb's behavior script
$800F0860 Unknown Geometry Layout Global Mario's decompressed geo-layout script
$800F8C4C Unknown Geometry Layout Global Decompressed geo-layout script for signs
$8018D47C 554 bytes Geometry Layout Global Bob-omb's decompressed geo-layout
$80195C54 Unknown Geometry Layout Overworld Decompressed geo-layout script for the castle tower
$801C1000 Unknown Misc. Global Segment 0x09 constant location. All level mesh textures are loaded here by the 0x1A level script command.
$80207700 512 bytes Misc. Global Start of EEPROM and goes up to 0x80207900
$80277EE0 Unknown Routine Global Function that assigns ram segments

Arguments: A0 = segment number, A1 = ram address
Returns: V0 = 0x80-prefix-less ram address

Essentially just: *(uint32*)(0x8033B400 + segment_number << 2) = ram_address & 0x00FFFFFF;
$80277F50 Unknown Routine Global Segment-offset to true ram address converter
Arguments: A0 = segmented address
Returns: V0 = true ram address
$80278120 118 bytes Routine Global Function that seems to be a memory allocator. Basically finds a desired amount of free space in the heap and returns a pointer to the area.

Arguments: A0 = block size
Returns: V0 = ram address
$80278504 264 bytes Routine Global DmaCopy(u32 dst, u32 bottom, u32 top);
dst being the RAM offset! bottom is the beginning ROM offset to copy the bytes and top is the end.
Takes three arguments.

Example:
ADDIU SP, SP, $FFE8 ; -24 to stack. Aka, make space.
SW RA, $0014 (SP) ; Push return address to stack.
LUI A0, $8034 ; Upper half address.
ORI A0, A0, $269D ; Lower half address. A0 = $8034269D
LUI A1, $001C ; ROM offset start (bottom)
ORI A1, $0D60 ; Lower part, A1 = $001C0D60
LUI A2, $0020 ; ROM offset end (top)
JAL $80278504 ; Jump to subroutine DmaCopy
ORI A2, $00D1 ; Is executed before JAL. Lower half.
LW RA, $0014 (SP) ; Load back our lost return address.
JR RA ; Jump to return address.
ADDIU SP, SP, $0018 ; Restores stack. (+24)

DmaCopy basically copies data from ROM to RAM. dst is the destination (as RAM offset), bottom is the start (as ROM offset) which is copied to RAM and top is the end. So, in our above example bytes from $001C0D60 (ROM) to $002000D1 (ROM) into $8034269D (RAM).
$80278610 124 bytes Routine Global Function that loads data from rom into the heap and returns a ram pointer to the data.

Arguments: A0 = rom start address, A1 = rom end address, A2 = allocation size (seems mostly unused?)
Returns: V0 = pointer to data after being loaded into ram
$802787D8 216 bytes Routine Global Function that loads MIO0 files into ram segments.
Arguments: A0 = ram segment number, A1 = rom address start, A2 = rom address end
$802792C0 84 bytes Routine Global EEPROM Save file checksum calculation routine
Arguments: A0 = address of buffer, A1 = buffer size, A2 = ? 00004441
Returns: 2 byte checksum to V0
$8027F4E0 164 bytes Routine Global MIO0 decoder
Arguments: A0 = pointer to mio0 file (in RAM), A1 = destination address for the decompressed file
$8029E27C Unknown Routine Global Distance From Object: Calculates the distance of 2 objects

Arguments: A0 = object 1 ptr, A1 = object 2 ptr
Returns: F0 = distance between objects (float)

This function only checks the X and Z positions of the two objects. The Y position is not taken into account.
$8029EDCC 88 bytes Routine Global Function that spawns an object at another object's location

Arguments: A0 = pointer to relative object, A1 = graphics id, A2 = behavior segment offset
Returns: V0 = pointer to the newly spawned object
$802A3754 68 bytes Routine Global IsMarioGroundPounding function

Detects if Mario is ground-pounding the current object.

No parameters. Returns V0 = 1 if true, and V0 = 0 if false.
$802A3CFC 56 bytes Routine Global IsMarioStepping function

This function detects if Mario is on-top of the current object. This function is used in many places like in the cap switches.

Takes no parameters.

Returns V0 = 1 if Mario is stepping on the object, otherwise V0 will return 0.
$802D62D8 Unknown Routine Global Hud number printing function

Arguments: A0 = x, A1 = y, A2 = pointer to ascii format string, A3 = number value

The format string argument is very similar to the one used in C's 'printf' function.
http://www.cplusplus.com/reference/cstdio/printf/
$802D6554 Unknown Routine Global HUD Symbol printing function - Prints an ascii string to the screen.
Arguments: A0 = int x, A1 = int y, A2 = pointer to ascii string
$802D6858 56 bytes Routine Global Function that converts ascii chars to sm64 chars.

Arguments: A0 = ascii byte
Returns: V0 = sm64 byte
$802DB498 584 bytes Routine Global Function that prints animated red coins to the screen

Arguments: A0 = x, A1 = y
$802E2CF0 160 bytes Routine Global Function that prints the camera images in the bottom right corner of the screen. (The lakitu, camera, mario, and X symbols)

Arguments: A0 = int x, A1 = int y, A2 = segment-offset to raw image data
$802E2E58 258 bytes Routine Global Function that prints the little yellow C button symbols when zooming in and out
Arguments: A0 = int left, A1 = int bottom, A2 = segment offset pointer to raw image
$802E6AF8 Unknown Routine Global Object behavior function - explode! (and spawn a coin)
Args: none
Returns: none
$802F3C9F 1 byte Misc. Global 1UP Modifier, change 0x01 to value of lives you want Mario to get when collecting a 1UP.
$803223B0 220 bytes Routine Global OSTime osGetTime(void);
void osSetTime(OSTime time);

Calling the osGetTime function returns the time since the last cold reset, expressed in units of CPU count register cycles. Regardless of whether the system is NTSC or PAL, this counter increments at 46.875 MHz, with 1 cycle equal to approximately 21.33 nanoseconds. When the counter reaches its maximum value, it returns to zero and continues to increment. (Since the real time counter has a length of 64 bits, unless the counter value is changed by calling osSetTime it will take more than 10,000 years for the counter to reach its maximum value and return to zero.)

The osSetTime function is used to set the value of the real time counter.

Note that the OSTime type is defined as u64 (unsigned long long), so you should specify "%llu" for the conversion format if you are going to output this type of numerical value with a printf function.

**Note**:
Since the VI Manager performs timer management, you must activate the VI Manager with osCreateViManager before using this function.
$80322640 100 bytes Routine Global void osViSetEvent(OSMesgQueue *mq, OSMesg msg, u32 retraceCount);

Arguments

mq
Message queue address (0x8033AF78)
msg
Message announced when vertical retrace occurs
retraceCount
Retrace count

This function registers the specified message queue and message in the VI manager. The program can thus receive the message (msg) announced by the message queue (mq)) from the VI manager when a vertical retrace occurs. The send cycle for the message is changed according to the value set in the retrace count (retraceCount). For instance, while the cycle is 60Hz when this is set to 1, it becomes a low speed 30Hz when it is set to 2, decreasing the frequency at which the application receives the vertical retrace announcement (message send cycle = 60Hz/retrace count).

Return Values
None.

##Precautions##
Execute this function after setting the display mode (see osViSetMode).
$80322F70 380 bytes Routine Global void osCreateViManager(OSPri pri);

The VI manager is a system thread that must be created and invoked at the beginning of the application. To do this, call osCreateViManager() for the VI manager to allow vertical retrace interrupt to occur at an early stage. Usually, this priority should be set to OS_PRIORITY_VIMGR. The VI manager is designed to service both the VI interrupt (OS_EVENT_VI) and CPU counter interrupt(OS_EVENT_COUNTER) in the most efficient manner. Each interrupting event can be performed using osViSetEvent or osSetTimer.

Return Values:
None.
$803232D0 96 bytes Routine Global void osViSetMode(OSViMode *mode);

Arguments

mode
VI mode

This function lets you set the current VI Mode. It supports a total of 56 modes, those break down in 14 NTSC modes, 14 PAL modes, 14 MPAL modes and 14 full-screen display PAL (FPAL) modes. The attributes of each mode, such as interlace and non-interlace, 16-bit color pixels and 32-bit color pixels, low-resolution and high-resolution, etc., can be set. In addition, the resolution can be dropped or images can be rescaled in order to increase rendering speed.
The last 4 characters of the symbol name (LPN1, etc.) comprise the following codes.

1st character:
H = High resolution
L = Low resolution

2nd Character:
A = Anti-aliasing
P = Point sampling

3rd Character
Low resolution N = Non-interlaced
F = Interlaced

High resolution N = Normal interlaced
F = Deflickered interlaced

4th Character 1 = 16-bit pixel size
2 = 32-bit pixel size

(Modes have yet to be found in the ROM)
$803233B0 432 bytes Routine Global void osViSetSpecialFeatures(u32 func);

Sets special VI functions.

Argument

func
Turn special VI function ON/OFF:

OS_VI_GAMMA_ON 0x0001 (Default: ON)
OS_VI_GAMMA_OFF 0x0002
OS_VI_GAMMA_DITHER_ON 0x0004 (Default: ON)
OS_VI_GAMMA_DITHER_OFF 0x0008
OS_VI_DIVOT_ON 0x0010 (Default: ON)
OS_VI_DIVOT_OFF 0x0020
OS_VI_DITHER_FILTER_ON 0x0040 (16bit-default): ON
OS_VI_DITHER_FILTER_OFF 0x0080 (32bit-default): OFF

##Precautions##
osViSetMode returns all of the function settings set with osViSetSpecialFeatures to their default values according to the display mode specified in the argument.
$80325310 Unknown Misc. Global Cosine function

Arguments: F12 = input angle (in radians)
Returns: F0 = resulting value
$80325480 Unknown Routine Global Sine function

Arguments: F12 = input angle (in radians)
Returns: F0 = resulting value
$803273F0 40 bytes Routine Global memcpy(u32 dst, u32 src, u32 num);

Copies bytes in the RAM from one location to another.

Arguments:
A0 = Pointer to RAM destination to copy to.
A1 = Pointer to RAM source to copy from.
A2 = Number of bytes to copy.

Returns:
V0 = Pointer to RAM desitination
$8032741C 36 bytes Routine Global strlen (char * str)

Gets the length of an ascii string.

A0 = pointer to string
V0 = length of string

Example: "Hello World!" would return 12.
$80327444 60 bytes Routine Global strchr (char * str, u8 character);

returns a pointer to the first instance of 'character'

A0 = pointer to string
A1 = ASCII character to be located.
V0 = pointer to the first occurrence. If no matching character was found, then V0 will return 0.

Example:
A0 = "Hello World!"
A1 = 0x57 ('W')

will return "World!"
$803284B0 224 bytes Routine Global Function used to load sounds and Mario's animation sequences into ram on the fly.

Args:A0 = (always 0?), A1 = rom address, A2 = destination ram address, A3 = block size
Returns: V0 = 0 (success); V0 = -1 (fail)
$8032D5E4 4 bytes Pointer Global Pointer that contains the pointer to the first controller structure.
$8032DDCC 4 bytes Pointer Global Pointer to the current area struct pointer.
$8032DF00 4 bytes Misc. Global Pointer to current object as used by the geo-layout script rendering system. An ASM routine reads the object pointer at this address, and then writes the pointer into a geo-layout's object pointer slot.
$80331620 1 byte Misc. Global Current level's act number
$80338388 2 bytes Misc. Global Format string for number of lives in the HUD - "%d"
$803383A0 2 bytes Misc. Global Format string for the number of stars in the HUD
$803383A4 1 byte Misc. Global Format string for HUD beta keys; "/" or 0x2F
$8033B079 1 byte Misc. Global Result of function osEepromProbe(). Read this byte to check if the eeprom has been loaded properly. This value should be 0x01.

0x00 = No eeprom loaded
0x01 = 4K-EEPROM loaded
0x02 = 16K-EEPROM loaded
$8033B176 2 bytes Misc. Global Mario hat flags
$8033B17C 4 bytes Misc. Global Mario's current action
$8033B17C 4 bytes Misc. Global Mario's previous action
$8033B188 2 bytes Misc. Global Mario's animation phase (unsigned short int)
$8033B18A 2 bytes Misc. Global Mario's animation cycle counter. Game also uses this to determine how sleepy Mario is.
$8033B218 2 bytes Misc. Global Mario's current coins.
$8033B21C 1 byte Misc. Global Number of beta keys
$8033B21D 1 byte Misc. Global Number of lives
$8033B21E 2 bytes Misc. Global Mario's power - upper byte is the value and the lower byte works like a decimal.
$8033B220 1 byte Misc. Global Mario Y offset from the ground (signed char)
$8033B222 1 byte Misc. Global Amount of time to apply 'hurting' effect to Mario's power
$8033B223 1 byte Misc. Global Amount of time to apply 'healing' effect to Mario's power (unsigned char)
$8033B226 2 bytes Misc. Global Displayed power number (signed short int)
$8033B264 2 bytes Misc. Global Number for displayed stars (signed short int aka Halfword).
$8033B400 128 bytes Misc. Global The segments table - Segment descriptions:
0x00 Miscellaneous, Constant 0

Graphics segments:
0x01 Master display lists?
0x02 Textures which are always available
0x03 ?
0x04 Mario graphics (geo+textures)
0x05
0x06
0x07
0x08 Object textures
0x09 Level mesh textures
0x0A
0x0B
0x0D
0x0E
0x0F

General purpose segments:
0x10
0x11
0x12
0x13 Behavior script bank
0x14 Level scripts
0x15 Level scripts
0x16 Geo layouts (pre-decompression)
0x17 Geo layouts (pre-decompression)
0x18 ? (points to nothing)
0x19 Unused
0x1A Unused
0x1B Unused
0x1C Unused
0x1D Unused
0x1E Unused
0x1F Unused
$8033C600 4 bytes Misc. Global Pointer to current collision triangle that mario is standing on/above
$8033D488 145920 bytes Misc. Global Level object linked list - 240 slots for level object structs, each of which are 0x260 bytes. (Goombas, Toads, Signs, Mario, etc)

Struct offsets: (Not completely accurate)
003 Camera relativity
004 Pointer to previous object
008 Pointer to next object
00C Pointer to ?? (some type of schema? Data has a pointer to mario's object in it)
014 Pointer to model layout script
020 X position (copy)
024 Y position (copy)
028 Z position (copy)
03C Pointer to animation data
054 X rotation
058 Y rotation
05C Z rotation
060 Pointer to an object (?)
064 Pointer to list of objects (?)
068 Pointer to ?? (self when mario's object)
070 Interaction from colliding object
074 ?
075 Object link status?
076 Collision with object status
078 Pointer to an object (?) (usually Mario's)
07C Pointer to an object (?)
0A0 X position
0A4 Y position
0A8 Z position
0AC X momentum
0B0 Y momentum
0B4 Z momentum
0F0 Model layout script case parameter
120 Segmented pointer to animation data (?)
130 Interaction
144 Interaction index (dialogue and spawn table indexes)
154 Frame counter
164 X position anchor
168 Y position anchor
16C Z position anchor
17C Model transparency
180 Interaction parameter (number of coins, damage dealt)
188 Interaction parameter ? (door warps)
19C Render distance
1C0 Pointer to level collision data that the object is standing on
1CC Pointer to behavior script (active)
1D0 Pointer to behavior script (active)
1F8 Collision sphere width
1FC Collision sphere height
20C Pointer to behavior script (initial)
21C Pointer to collision polygon
25C Pointer to model script table?
$80361150 4 bytes Pointer Global Pointer to next empty object for the game to use (behavior script engine variable)
$80361158 4 bytes Pointer Global Another pointer to the current Mario object (behavior script engine variable)
$80361160 4 bytes Pointer Global Pointer to current object as used by the behavior processing system.
All behavior ASM routines use the pointer at this address + struct offsets to make changes to level objects.
Refer to the Level object linked list for a list of struct offsets.
$80361164 4 bytes Pointer Global Pointer to the current behavior script command that the game is processing
$80361170 4 bytes Misc. Global Current # of triangles in the collision map. (static collision + collision created by objects)
$80361178 4 bytes Misc. Global Number of triangles in static collision map.
$80361184 4 bytes Pointer Global Pointer to current level's water settings
$8038B8B0 240 bytes Pointer Global The level script jump table; a list of pointers to level script command functions:
0x00 8037E2C4
0x01 8037E388
0x02 8037E404
0x03 8037E47C
0x04 8037E4FC
0x05 8037E580
0x06 8037E5B8
0x07 8037E620
0x08 8037E650
0x09 8037E6D4
0x0A 8037E780
0x0B 8037E7F8
0x0C 8037E878
0x0D 8037E8E8
0x0E 8037E988
0x0F 8037EA18
0x10 8037EA70
0x11 8037EA98
0x12 8037EB04
0x13 8037EB98
0x14 8037EBD4
0x15 8037EC14
0x16 8037EC54
0x17 8037ECA4
0x18 8037ECF8
0x19 8037ED48
0x1A 8037EDF8
0x1B 8037EE48
0x1C 8037EEA8
0x1D 8037EF00
0x1E 8037EF70
0x1F 8037F010
0x20 8037F130
0x21 8037F164
0x22 8037F214
0x23 8037F2A4
0x24 8037F45C
0x25 8037F36C
0x26 8037F67C
0x27 8037F994
0x28 8037F790
0x29 80380014
0x2A 8038007C
0x2B 803800BC
0x2C 80380160
0x2D 803801A0
0x2E 8037FE94
0x2F 8037FF14
0x30 80380274
0x31 8037F920
0x32 8038024C
0x33 803801E0
0x34 8037FDE4
0x35 8037FE2C
0x36 80380300
0x37 8038039C
0x38 803803EC
0x39 8037FF94
0x3A 8037FB18
0x3B 8037FC38
0x3C 80380434
$8038B9B0 220 bytes Pointer Global The behavior script jump table; a list of pointers to behavior script command functions:
0x00 803854CC
0x01 8038425C
0x02 803841B8
0x03 80384224
0x04 8038438C
0x05 80384450
0x06 803844C0
0x07 80384554
0x08 803845E8
0x09 80384634
0x0A 80384188
0x0B 803841A0
0x0C 80384678
0x0D 80384C5C
0x0E 803846D0
0x0F 80384CF0
0x10 8038475C
0x11 80384D70
0x12 80384E04
0x13 803849F8
0x14 80384854
0x15 80384928
0x16 80384AB4
0x17 80384B90
0x18 8038503C
0x19 803850CC
0x1A 80385084
0x1B 80383F24
0x1C 80383F94
0x1D 80384164
0x1E 80384F8C
0x1F 80385114
0x20 803851D0
0x21 80383EE4
0x22 80383E5C
0x23 8038528C
0x24 8038546C
0x25 803842E4
0x26 803843E0
0x27 80384E9C
0x28 80384F08
0x29 803840B4
0x2A 803856A0
0x2B 803853AC
0x2C 8038401C
0x2D 80385700
0x2E 8038531C
0x2F 8038575C
0x30 8038586C
0x31 803857A0
0x32 803857E4
0x33 80385A60
0x34 80385B4C
0x35 80383EA0
0x36 803847D4
0x37 80385AF0
$8038BE28 4 bytes Pointer Global Pointer to the current level script command that the game is processing.
$8038EEA0 2 bytes Misc. Global Max number of triangles for collision map. 2,300 in vanilla SM64 and increased to 32,767 by the SM64 Editor. Set by function 0x80383340
$8038F800 460800 bytes Misc. Global The Framebuffer. Occupies the range starting from $8038F800 to $803FFFFF. This region is constantly being overwritten, so you cannot modify any of the data directly.
ROM Address Length Type Description Details
$90000000 4 bytes Misc. Initial PI BSD Domain 1 register settings; [80][3][7][12][40]

[80] Endianess indicator

PI BSD Domain 1 registers:
[3] Release
[7] Pages
[12] Pulse width
[40] Latency
$90000004 4 bytes Misc. Clock rate setting; 0000000:F
$90000008 4 bytes Misc. Entry point; 80246000
$9000000C 4 bytes Misc. Release; 00001444
$90000010 8 bytes Misc. ROM Checksum; 63 5A 2B FF 8B 02 23 26
$90000018 8 bytes Misc. Unknown use / 0000000000000000
$90000020 20 bytes Misc. ROM Name; "SUPER MARIO 64" followed by 5 spaces.
$90000034 4 bytes Misc. Unknown use; 00000000
$90000038 4 bytes Misc. Media format; 0000004E / "N" (Cartridge)
$9000003C 2 bytes Misc. Cartridge ID; "SM" / 534D
$9000003E 1 byte Misc. Country code; "E" / 45 (USA)
$9000003F 1 byte Misc. Version; 00
$90000040 4032 bytes Routine Bootstrap code; from 90000040 to 90001000
$90000584 492 bytes Misc. Boot and final checksum comparison routine.

The final checksum comparison can be removed by NOPing the BNE instructions at 9000066C and 90000678.
$90108A40 48400 bytes Misc. MIO0 File 00 (RAM segment 0x02)
HUD and other common textures
$90114750 78432 bytes Misc. MIO0 File 01 (RAM segment 0x04)
Mario's model
$90201088 316 bytes Geometry Layout Bob-omb's geo-layout
$90219E00 22208 bytes Bank Behavior script bank
$9021B278 52 bytes Behaviour Purple switch's behavior script
$9021CCC0 56 bytes Behaviour Mario's Behavior.
It has three function calls, which are called as RAM offset:

21CCD8 08 00 00 00 - Start Loop
21CCDC 0C 00 00 00 80 2C B1 C0 - JAL $802CB1C0
21CCE4 0C 00 00 00 80 29 CA 58 - JAL $8029CA58
21CCEC 0C 00 00 00 80 2C B2 64 - JAL $802CB264
21CCF4 09 00 00 00

0x0C commands: (JAL, but quite different here. The RAM Offset is done through LB(Load Byte))

[0C] [00 00 00] [80 XX XX XX]

[0]= 0C is the Command Byte.
[1,2,3]= Always zero, unused?

[4,5,6,7]= The offset in RAM of the ASM function.

0x0C commands do call ASM Funtions found in RAM.

The functions are "looped" because of the 0x08 command and ends with 0x09 command. 0x08 starts a loop, is called every frame. And 0x09 jumps back to the beginning of the loop.

You can use ASM Function "0C 00 00 00 80 2C B1 C0" to inject your own code, as this is an unused debug function in mario's behavior. For this, you calculate the ROM offset of 802CB1C0. For every RAM offset between $80246000 and $80330000 you subtract $80245000 of the RAM offset. $802CB1C0-$80245000 = $861C0 (ROM offset). In $861C0 you put in your code. (Remember to make place for the stack and push your return address to the stack, in case you call a subroutine)
$9021CF74 56 bytes Behaviour Bob-omb's behavior script
$9021E52C 44 bytes Behaviour Goomba Behaviour.

00 05 00 00<------ Loop for an amount of time, where the time is 0 and loop is infinite.

11 01 20 49 <---- Object's flag

1E 00 00 00 <---- Does nothing?

27 26 00 00 08 01 DA 4C <---- Animation Command, load textures with the 0xFD command in the display list, animate with 0x0E command in geo layout, I.e 0E 00 00 0A 80 XX XX XX, 0E <--- Command, 00 00 0A <---- Number of frames of anim. 80 XX XX XX- Ram Bank.

2D 00 00 00 <----Initiates pos.

30 00 00 00 00 28 FE 70 FF CE 03 E8 03 E8 00 00 00 00 00 00 <----- Allocates gravity

0C 00 00 00 80 2F F4 08 <---- Ram Pointer(Subtract 0x80245000 to get position) Equivalent to the JAL, command, as 0X0C is 0C 00 00 00 80 2F F4 08, JAL is JAL $802FF408

08 00 00 00 <---- Loops behavior, Commands( I.e 0x0F, 0x0C)has to be in it to get looped.

0C 00 00 00 80 2F F9 6C <---- Same as 0C 00 00 00 80 2F F4 08

09 00 00 00 <--- END loop/script.
$903828C0 4240 bytes Level Data Haunted House level layout script
$90395C90 1712 bytes Level Data Cool Cool Mountain level layout script
$903CF0D0 7408 bytes Level Data Inside Castle level layout script
$903E6A00 3248 bytes Level Data Hazy Maze Cave level layout script
$903FB990 2336 bytes Level Data Shifting Sand Land level layout script
$90405A60 1360 bytes Level Data Bob-Omb's Battlefield level layout script
$9040E840 1328 bytes Level Data Snow Man's land level layout script
$90419F90 2000 bytes Level Data Wet Dry World level layout script
$90423B20 2992 bytes Level Data Jolly Roger Bay level layout script
$9042C6E0 2112 bytes Level Data Tiny Huge Island level layout script
$90437400 1136 bytes Level Data Tick Tock Clock level layout script
$9044A140 2688 bytes Level Data Rainbow Road level layout script
$904545E0 2080 bytes Level Data Castle Grounds level layout script
$9045BF60 1696 bytes Level Data Bowser 1 Course level layout script
$90461220 688 bytes Level Data Vanish Cap level layout script
$9046A840 2128 bytes Level Data Bowser's Fire Sea level layout script
$9046C1A0 512 bytes Level Data Secret Aquarium level layout script
$90477D00 1952 bytes Level Data Bowser 3 Course level layout script
$9048C9B0 3968 bytes Level Data Lethal Lava Land level layout script
$90495A60 1584 bytes Level Data Dire Dire Docks level layout script
$9049DA50 3264 bytes Level Data Whomp's Fortress level layout script
$904AC4B0 192 bytes Level Data Thank You cake picture at the end level layout script
$904AF670 704 bytes Level Data Castle Courtyard level layout script
$904B7F10 448 bytes Level Data Peach's Secret Slide level layout script
$904BE9E0 592 bytes Level Data Metal Cap level layout script
$904C2700 544 bytes Level Data Wing Cap level layout script
$904C41C0 352 bytes Level Data Bowser 1 Battle Platform level layout script
$904CD930 672 bytes Level Data Rainbow Clouds Bonus level layout script
$904CE9F0 528 bytes Level Data Bowser 2 Battle Platform level layout script
$904D14F0 1056 bytes Level Data Bowser 3 Battle Platform level layout script
$904EB1F0 3600 bytes Level Data Tall Tall Mountain level layout script
$907CC6C0 211264 bytes Misc. 'FF' Padding
Regs Address Length Type Description Details
$4040000 4 bytes SP Register SP_MEM_ADDR_REG - Master, SP Memory Address (Read/Write) ---- ---- ---- ---- ---s aaaa aaaa aaaa aaaaaaaaaaaa = DMEM/IMEM address s = Memory select 0 = DMEM 1 = IMEM
$4040004 4 bytes SP Register SP_DRAM_ADDR_REG - Slave, SP DRAM DMA Address (Read/Write) ---- ---- aaaa aaaa aaaa aaaa aaaa aaaa aaaaaaaaaaaaaaaaaaaaaaaa = RDRAM address
$4040008 4 bytes SP Register SP_RD_LEN_REG - SP Read DMA Length (Read/Write) ssss ssss ssss cccc cccc llll llll llll llllllllllll = Length cccccccc = Count ssssssssssss = Skip Direction: I/DMEM <- RDRAM
$404000C 4 bytes SP Register SP_WR_LEN_REG - SP Write DMA Length (Read/Write) ssss ssss ssss cccc cccc llll llll llll llllllllllll = Length cccccccc = Count ssssssssssss = Skip Direction: I/DMEM -> RDRAM
$4040010 4 bytes SP Register SP_STATUS_REG - SP Status (Read) ---- ---- ---- ---- -765 4321 0isF fBbh h = Halt b = Broke B = DMA busy f = DMA full F = I/O full s = Single step i = Interrupt on break 0-7 = Signal N set
$4040010 4 bytes SP Register SP_STATUS_REG - SP Status (Write) ---- ---L lKkJ jGgF fEeC cAaD dSsI ibHh h/H = Clear/Set halt b = Clear broke i/I = Clear/Set intr s/S = Clear sstep d/D = Clear intr on break a/A = Clear/Set signal 0 c/C = Clear/Set signal 1 e/E = Clear/Set signal 2 f/F = Clear/Set signal 3 g/G = Clear/Set signal 4 j/J = Clear/Set signal 5 k/K = Clear/Set signal 6 l/L = Clear/Set signal 7
$4040014 4 bytes SP Register SP_DMA_FULL_REG - SP DMA Full (Read) ---- ---- ---- ---- ---- ---- ---- ---f f = DMA full
$4040018 4 bytes SP Register SP_DMA_BUSY_REG - SP DMA Busy (Read) ---- ---- ---- ---- ---- ---- ---- ---b b = DMA busy
$404001C 4 bytes SP Register SP_SEMAPHORE_REG - SP Semaphore (Read) ---- ---- ---- ---- ---- ---- ---- ---s s = Semaphore flag (set on read)
$404001C 4 bytes SP Register SP_SEMAPHORE_REG - SP Semaphore (Write) ---- ---- ---- ---- ---- ---- ---- ---s s = Clear semaphore flag
$4080000 4 bytes SP Register SP_PC_REG - SP PC (Read) ---- ---- ---- ---- ---- ---- -fff fdgc c = BIST check g = BIST go d = BIST done ffff = BIST fail
$4080000 4 bytes SP Register SP_PC_REG - SP PC (Write) ---- ---- ---- ---- ---- ---- ---- -Cgc c = BIST check g = BIST go C = BIST clear
$4080004 4 bytes SP Register SP_IBIST_REG - SP IMEM BIST REG (Read/Write) ---- ---- ---- ---- ---- pppp pppp pppp p = Program counter
$4100000 4 bytes DP Command Register DPC_START_REG - DP CMD DMA Start (Read/Write) ---- ---- ssss ssss ssss ssss ssss ssss ssssssssssssssssssssssss = DMEM/RDRAM start address
$4100004 4 bytes DP Command Register DPC_END_REG - DP CMD DMA End (Read/Write) ---- ---- eeee eeee eeee eeee eeee eeee eeeeeeeeeeeeeeeeeeeeeeee = DMEM/RDRAM end address
$4100008 4 bytes DP Command Register DPC_CURRENT_REG - DP CMD DMA End (Read) ---- ---- cccc cccc cccc cccc cccc cccc cccccccccccccccccccccccc = DMEM/RDRAM current address
$410000C 4 bytes DP Command Register DPC_STATUS_REG - DP CMD Status (Read) ---- ---- ---- ---- ---- -sed bcpt gFfx x = xbus_dmem_dma f = Freeze F = Flush g = Start gclk t = tmem busy p = Pipe busy c = Command busy b = cbuf busy d = DMA busy e = End valid s = Start valid
$410000C 4 bytes DP Command Register DPC_STATUS_REG - DP CMD Status (Write) ---- ---- ---- ---- ---- --oc ptLl FfXx x/X = Clear/Set xbus_dmem_dma f/F = Clear/Set freeze l/L = Clear/set flush t = Clear tmem ctr p = Clear pipe ctr c = Clear cmd ctr o = Clear clock ctr
$4100010 4 bytes DP Command Register DPC_CLOCK_REG - DP Clock Counter (Read) ---- ---- cccc cccc cccc cccc cccc cccc cccccccccccccccccccccccc = Clock counter
$4100014 4 bytes DP Command Register DPC_BUFBUSY_REG - DP Buffer Busy Counter (Read) ---- ---- cccc cccc cccc cccc cccc cccc cccccccccccccccccccccccc = Buffer busy counter
$4100018 4 bytes DP Command Register DPC_PIPEBUSY_REG - DP Pipe Busy Counter (Read) ---- ---- cccc cccc cccc cccc cccc cccc cccccccccccccccccccccccc = Pipe busy counter
$410001C 4 bytes DP Command Register DPC_TMEM_REG - DP TMEM Load Counter (Read) ---- ---- cccc cccc cccc cccc cccc cccc cccccccccccccccccccccccc = TMEM load counter
$4200000 4 bytes DP Span Register DPS_TBIST_REG - DP tmem BIST (Read) ---- ---- ---- ---- ---- -fff ffff fdgc c = BIST check g = BIST go d = BIST done ffffffff = BIST fail
$4200000 4 bytes DP Span Register DPS_TBIST_REG - DP tmem BIST (Write) ---- ---- ---- ---- ---- ---- ---- -Cgc c = BIST check g = BIST go C = BIST clear
$4200004 4 bytes DP Span Register DPS_TEST_MODE_REG - DP Span Test Mode (Read/Write) ---- ---- ---- ---- ---- ---- ---- ---e e = Span buffer test access enable
$4200008 4 bytes DP Span Register DPS_BUFTEST_ADDR_REG - DP Span Buffer Test Address (Read/Write) ---- ---- ---- ---- ---- ---- -bbb bbbb bbbbbbb = Address bits
$420000C 4 bytes DP Span Register DPS_BUFTEST_DATA_REG - DP Span Buffer Test Data (Read/Write) dddd dddd dddd dddd dddd dddd dddd dddd dddddddddddddddddddddddddddddddd = Span buffer data
$4300000 4 bytes MIPS Interface Register MI_INIT_MODE_REG or MI_MODE_REG - MI Init Mode (Read) ---- ---- ---- ---- ---- --rt mlll llll lllllll = Init length m = Init mode t = ebus test mode r = RDRAM reg mode
$4300000 4 bytes MIPS Interface Register MI_INIT_MODE_REG or MI_MODE_REG - MI Init Mode (Write) ---- ---- ---- ---- --Rr dTtI illl llll lllllll = Init length i/I = Clear/Set init mode t/T = Clear/Set ebus test mode d = Clear DP interrupt r/R = Clear/Set RDRAM reg mode
$4300004 4 bytes MIPS Interface Register MI_VERSION_REG or MI_NOOP_REG - MI version (Read) ssss ssss dddd dddd aaaa aaaa iiii iiii iiiiiiii = I/O aaaaaaaa = RAC dddddddd = RDP ssssssss = RSP Project64 1.4: 0x02020102
$4300008 4 bytes MIPS Interface Register MI_INTR_REG - MI Interrupt (Read) ---- ---- ---- ---- ---- ---- --fe dcba a = SP interrupt b = SI interrupt c = AI interrupt d = VI interrupt e = PI interrupt f = DP interrupt
$430000C 4 bytes MIPS Interface Register MI_INTR_MASK_REG - MI Interrupt Mask (Read) ---- ---- ---- ---- ---- ---- --fe dcba a = SP interrupt mask b = SI interrupt mask c = AI interrupt mask d = VI interrupt mask e = PI interrupt mask f = DP interrupt mask
$430000C 4 bytes MIPS Interface Register MI_INTR_MASK_REG - MI Interrupt Mask (Write) ---- ---- ---- ---- ---- FfEe DdCc BbAa a/A = Clear/Set SP interrupt mask b/B = Clear/Set SI interrupt mask c/C = Clear/Set AI interrupt mask d/D = Clear/Set VI interrupt mask e/E = Clear/Set PI interrupt mask f/F = Clear/Set DP interrupt mask
$4400000 4 bytes Video Interface Register VI_STATUS_REG or VI_CONTROL_REG - VI Status/Control (Read/Write) ---- ---- ---- ---- rrrr R-aa Rs0D gdtt tt = Type (Pixel Size) 00 = Blank (no data, no sync) 01 = Reserved 10 = 5/5/5/3 (16-bit) 11 = 8/8/8/8 (32-bit) d = Gamma Dither Enable (normally on, unless "special effect") g = Gamma Enable (normally on, unless MGEG/JPEG) D = DIVOT Enable (normally on if antialiased unless decal lines) 0 = Reserved, always off s = Serrate (always on if interlaced, off if not) R = Reserved - diagnostics only aa = Antialias mode 00 = Antialias and resample (always fetch extra lines) 01 = Antialias and resample (fetch extra lines if needed) 10 = Resamply only (treat as all fully covered) 11 = Neither (replicate pixels, no interpolation) rrrr = Reserved
$4400004 4 bytes Video Interface Register VI_ORIGIN_REG or VI_DRAM_ADDR_REG - VI Origin (Read/Write) ---- ---- oooo oooo oooo oooo oooo oooo oooooooooooooooooooooooo = Frame buffer origin in bytes
$4400008 4 bytes Video Interface Register VI_WIDTH_REG or VI_H_WIDTH_REG - VI Width (Read/Write) ---- ---- ---- ---- ---- wwww wwww wwww wwwwwwwwwwww = Frame buffer line width in pixels
$440000C 4 bytes Video Interface Register VI_INTR_REG or VI_V_INTR_REG - VI Vertical Intr (Read/Write) ---- ---- ---- ---- ---- --ii iiii iiii iiiiiiiiii = Interrupt when current half-line = V_INTR
$4400010 4 bytes Video Interface Register VI_CURRENT_REG or VI_V_CURRENT_LINE_REG - VI Current Vertical Line (Read/Write) ---- ---- ---- ---- ---- --ll llll llll llllllllll = Current half line, sampled once per line (the LSB of V_CURRENT is constant within a field, and interlaced modes give the field number - which is constant for non-interlaced modes) Any write to this register will clear the interrupt line.
$4400014 4 bytes Video Interface Register VI_BURST_REG or VI_TIMING_REG - VI Video Timing (Read/Write) --ss ssss ssss vvvv cccc cccc hhhh hhhh hhhhhhhh = Horizontal sync width in pixels cccccccc = Color burst width in pixels vvvv = Vertical sync width in half-lines ssssssssss = Start of color burst in pixels from horizontal sync
$4400018 4 bytes Video Interface Register VI_V_SYNC_REG - VI Vertical Sync (Read/Write) ---- ---- ---- ---- ---- --ll llll llll llllllllll = Number of half-lines per field
$440001C 4 bytes Video Interface Register VI_H_SYNC_REG - VI Horizontal Sync (Read/Write) ---- ---- ---- ---l llll dddd dddd dddd dddddddddddd = Total duration of a line in 1/4 pixels lllll = A 5-bit leap pattern used for PAL only (h_sync_period)
$4400020 4 bytes Video Interface Register VI_LEAP_REG or VI_H_SYNC_LEAP_REG - VI Horizontal Sync Leap (Read/Write) ---- hhhh hhhh hhhh ---- hhhh hhhh hhhh hhhhhhhhhhhh = Identical to h_sync_period
$4400024 4 bytes Video Interface Register VI_H_START_REG or VI_H_VIDEO_REG - VI Horizontal Video (Read/Write) ---- --ss ssss ssss ---- --ee eeee eeee eeeeeeeeee = End of active video in screen pixels ssssssssss = Start of active video in screen pixels
$4400028 4 bytes Video Interface Register VI_V_START_REG or VI_V_VIDEO_REG - VI Vertical Video (Read/Write) ---- --ss ssss ssss ---- --ee eeee eeee eeeeeeeeee = End of active video in screen half-lines ssssssssss = Start of active video in screen half-lines
$440002C 4 bytes Video Interface Register VI_V_BURST_REG - VI Vertical Burst (Read/Write) ---- --ss ssss ssss ---- --ee eeee eeee eeeeeeeeee = End of color burst enable in half-lines ssssssssss = Start of color burst enable in half-lines
$4400030 4 bytes Video Interface Register VI_X_SCALE_REG - VI X Scale (Read/Write) ---- oooo oooo oooo ---- ssss ssss ssss ssssssssssss = 1/horizontal scale up factor (2.10 format) oooooooooooo = Horizontal subpixel offset (2.10 format)
$4400034 4 bytes Video Interface Register VI_Y_SCALE_REG - VI Y Scale (Read/Write) ---- oooo oooo oooo ---- ssss ssss ssss ssssssssssss = 1/Vertical scale up factor (2.10 format) oooooooooooo = Vertical subpixel offset (2.10 format)
Per Page: 25 50 75 100 150 500 All

The purpose of this site is not to distribute copyrighted material, but to honor one of our favourite games.

Copyright © 2005 - 2020 - SMW Central
Legal Information - Privacy Policy - Link To Us


Total queries: 22

Menu

Follow Us On

  • YouTube
  • Twitch
  • Twitter

Affiliates

  • Super Mario Bros. X Community
  • ROMhacking.net
  • Mario Fan Games Galaxy