Difference between revisions of "Sonic Jam 6"
From Sonic Retro
Line 6: | Line 6: | ||
|- | |- | ||
|0x1430 | |0x1430 | ||
− | |Array which contains music numbers for each map (WORD ARRAY) | + | |Array which contains music numbers for each map (WORD ARRAY). |
| | | | ||
|- | |- | ||
|0x0ad2 | |0x0ad2 | ||
− | |Demo properties (structure array, 0xe bytes long) | + | |Demo properties (structure array, 0xe bytes long). |
| | | | ||
*0 (w), Level map number | *0 (w), Level map number | ||
Line 21: | Line 21: | ||
|- | |- | ||
|0x0dde | |0x0dde | ||
− | |Level map world-level number (structure array, 0x4 bytes long) | + | |Level map world-level number (structure array, 0x4 bytes long). |
| | | | ||
*0 (w), World number tile | *0 (w), World number tile | ||
Line 28: | Line 28: | ||
|- | |- | ||
|0xff0096 | |0xff0096 | ||
− | |Number of seconds left (unsigned short) | + | |Number of seconds left (unsigned short). |
|- | |- | ||
|76543210 | |76543210 | ||
− | |Joystick Bitmap | + | |Joystick Bitmap. |
|SACBRLDU | |SACBRLDU | ||
|- | |- | ||
|0xff001a | |0xff001a | ||
− | |Buttons pressed on joypad (follows bitmap above) (BYTE) | + | |Buttons pressed on joypad (follows bitmap above) (BYTE). |
|- | |- | ||
|0xff001c | |0xff001c | ||
− | |Buttons pressed on joypad (bits set only when button is pressed for the first time after being released) (BYTE) | + | |Buttons pressed on joypad (bits set only when button is pressed for the first time after being released) (BYTE). |
|- | |- | ||
|0xff0042 | |0xff0042 | ||
− | |Number of current level map (WORD) | + | |Number of current level map (WORD). |
|- | |- | ||
|0x00 | |0x00 | ||
Line 158: | Line 158: | ||
|- | |- | ||
|0xff00a4 | |0xff00a4 | ||
− | |Water level flag (0x0000 = disabled, 0x0001 = enabled) | + | |Water level flag (0x0000 = disabled, 0x0001 = enabled). |
− | |If this is enabled, you swim, otherwise you don't (WORD) | + | |If this is enabled, you swim, otherwise you don't (WORD). |
|- | |- | ||
|0xff008a | |0xff008a | ||
− | |'???' level flag (WORD) | + | |'???' level flag (WORD). |
|- | |- | ||
|0x0002 | |0x0002 | ||
Line 168: | Line 168: | ||
|- | |- | ||
|0xff0092 | |0xff0092 | ||
− | |Number of coins (WORD) | + | |Number of coins (WORD). |
|- | |- | ||
|0xff0094 | |0xff0094 | ||
− | |Number of lives (WORD) | + | |Number of lives (WORD). |
|- | |- | ||
|0xff00ba | |0xff00ba | ||
− | |Number of lives "mirror" (WORD) | + | |Number of lives "mirror" (WORD). |
|This exists likely due to sloppy programming. At a place it's set to the number of lives you get when you start a new game, and then copied to 0xff0094 (the usual lives address). Other places in the game only copy from this to '0094 or the other way around. It is not updated when lives become 0, as the game won't run the code to copy '0094 back to '00ba then. All the checks on lives take place on '0094, so you don't need to care about this one. | |This exists likely due to sloppy programming. At a place it's set to the number of lives you get when you start a new game, and then copied to 0xff0094 (the usual lives address). Other places in the game only copy from this to '0094 or the other way around. It is not updated when lives become 0, as the game won't run the code to copy '0094 back to '00ba then. All the checks on lives take place on '0094, so you don't need to care about this one. | ||
|- | |- | ||
Line 200: | Line 200: | ||
|- | |- | ||
|ROM:00000B18 | |ROM:00000B18 | ||
− | |title_screen_check_buttons CODE XREF: sub_84E+15C�p | + | |title_screen_check_buttons CODE XREF: sub_84E+15C�p. |
|- | |- | ||
|ROM:00000B18 | |ROM:00000B18 | ||
− | |btst #5,(word_FF001C).l ; Check {{C}} button | + | |btst #5,(word_FF001C).l ; Check {{C}} button. |
|- | |- | ||
|ROM:00000B20 | |ROM:00000B20 | ||
− | |bne.w loc_B4C ; If it's pressed, branch | + | |bne.w loc_B4C ; If it's pressed, branch. |
|- | |- | ||
|ROM:00000B24 | |ROM:00000B24 | ||
− | |btst #7,(word_FF001C).l ; Check {{Start}} button | + | |btst #7,(word_FF001C).l ; Check {{Start}} button. |
|- | |- | ||
|ROM:00000B2C | |ROM:00000B2C | ||
− | |bne.w loc_B4C ; If it's pressed, branch | + | |bne.w loc_B4C ; If it's pressed, branch. |
|- | |- | ||
|ROM:00000B30 | |ROM:00000B30 | ||
− | |btst #6,(word_FF001C).l ; Check {{A}} button | + | |btst #6,(word_FF001C).l ; Check {{A}} button. |
|- | |- | ||
|ROM:00000B38 | |ROM:00000B38 | ||
− | |bne.w loc_B4C ;If it's pressed, branch | + | |bne.w loc_B4C ;If it's pressed, branch. |
|- | |- | ||
|ROM:00000B3C | |ROM:00000B3C | ||
− | |btst #4,(word_FF001C).l ; Check {{B}} button | + | |btst #4,(word_FF001C).l ; Check {{B}} button. |
|- | |- | ||
|ROM:00000B44 | |ROM:00000B44 | ||
− | |bne.w loc_B4C ; If it's pressed, branch | + | |bne.w loc_B4C ; If it's pressed, branch. |
|- | |- | ||
|ROM:00000B48 | |ROM:00000B48 | ||
− | |bra.w locret_B6A ; No button pressed, branch to this other one | + | |bra.w locret_B6A ; No button pressed, branch to this other one. |
|} | |} | ||
{{SCHGuides}} | {{SCHGuides}} | ||
[[Category:Sonic Community Hacking Guide]] | [[Category:Sonic Community Hacking Guide]] |
Revision as of 15:42, 28 October 2008
This is the Sonic Community Hacking Guide for Sonic Jam 6. The Guide is based on notes by Shibunoa which can be found here. This guide was built with the [f1] version in mind.
Offset | Description | Note |
---|---|---|
0x1430 | Array which contains music numbers for each map (WORD ARRAY). | |
0x0ad2 | Demo properties (structure array, 0xe bytes long). |
|
0x0dde | Level map world-level number (structure array, 0x4 bytes long). |
|
0xff0096 | Number of seconds left (unsigned short). | |
76543210 | Joystick Bitmap. | SACBRLDU |
0xff001a | Buttons pressed on joypad (follows bitmap above) (BYTE). | |
0xff001c | Buttons pressed on joypad (bits set only when button is pressed for the first time after being released) (BYTE). | |
0xff0042 | Number of current level map (WORD). | |
0x00 | Level 1-1 | |
0x01 | Level 1-2 | |
0x02 | Level 1-1 Bonus | |
0x03 | Level 1-3 | |
0x04 | Level 1-4 | |
0x05 | Level 1-2 Bonus | |
0x06 | Level 2-1 | |
0x07 | Level 2-2 | |
0x08 | Level 2-3 | |
0x09 | Level 2-4 | |
0x0A | Level 3-1 | |
0x0B | Level 3-2 | |
0x0C | Level 3-3 | |
0x0D | Level 3-4 | |
0x0E | Level 4-1 | |
0x0F | Level 4-2 | |
0x10 | Level 4-3 | |
0x11 | Level 4-4 | |
0x12 | Level 5-1 | |
0x13 | Level 5-2 | |
0x14 | Level 5-3 | |
0x15 | Level 5-4 | |
0x16 | Level 6-1 | |
0x17 | Level 6-2 | |
0x18 | Level 6-3 | |
0x19 | Level 6-4 | |
0x1A | Level 7-1 | |
0x1B | Level 7-2 | |
0x1C | Level 7-3 | |
0x1D | Level 7-4 | |
0x1E | Level 8-1 | |
0x1F | Level 8-2 | |
0x20 | Level 8-3 | |
0x21 | Level 8-4 | |
0x22 | Level 8-4 Pipe #1 | |
0x23 | Level 8-4 Pipe #2 | |
0x24 | Level 8-4 Water Part | |
0x25 | Level 8-4 Final | |
0xff00a4 | Water level flag (0x0000 = disabled, 0x0001 = enabled). | If this is enabled, you swim, otherwise you don't (WORD). |
0xff008a | '???' level flag (WORD). | |
0x0002 | Continuing level, when you go into a pipe, continue the level and don't treat it as a seperate level. | |
0xff0092 | Number of coins (WORD). | |
0xff0094 | Number of lives (WORD). | |
0xff00ba | Number of lives "mirror" (WORD). | This exists likely due to sloppy programming. At a place it's set to the number of lives you get when you start a new game, and then copied to 0xff0094 (the usual lives address). Other places in the game only copy from this to '0094 or the other way around. It is not updated when lives become 0, as the game won't run the code to copy '0094 back to '00ba then. All the checks on lives take place on '0094, so you don't need to care about this one. |
0xff7140 | Character sprite X position on screen (WORD) (in genesis format, 0 = 0x80). | |
0xff7142 | Character sprite Y position on screen (WORD) (in genesis format, 0 = 0x80). |
Title Screen
Offset | Description |
---|---|
0xff008a | 'Go away from title screen and play game' flag (0x0000 = false, 0x0001 true) (WORD). Set when either , , or are pressed. |
0x84e | is the title screen loop ? |