This repository has been archived by the owner on Sep 28, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 8
In game level object header
Matt Greer edited this page Feb 11, 2022
·
7 revisions
The info on the level/object header in existing documents is not proving to be correct. Here is what I have found so far
This table based on one found in devtronic's doc
AA AA BB BB CD EE FG HH IJ KL MM
Block | Description | Notes |
---|---|---|
AA AA |
Level ID of the next area. (Big Endian) | untested |
BB BB |
Opponent ID of the next area. (Big Endian) | untested |
C |
Start position Y | see below |
D |
Map length, a nibble corresponds to a block of 256px, i.e. 0 = 256px, 1 = 512px etc ... | confirmed |
EE |
Start position X | see below |
F |
Scroll type | untested |
G |
Object set of this area | confirmed |
HH |
GFX | confirmed, but only the bottom 5 bits |
I |
Object set of the next area | untested |
J |
Music | untested |
K |
"Extra" color | untested |
L |
"Extra" type | untested |
MM |
Background | confirmed |
this is not pixels or tiles, and totally different from start y position in e-reader levels
according to SMA4Notes.txt (author unknown), the values map to this
value | y position | notes |
---|---|---|
0 | 18 | adds another 0F to the level. |
1 | 18 | |
2 | 5 | |
3 | 5 | |
4 | 0 | |
5 | 0 | |
6 | 16 | |
7 | 16 | |
8 | 4 | |
9 | 4 | |
A | 8 | |
B | 8 | |
C | 12 | |
D | 12 | |
E | 19 | |
F | 19 |
tested, and seems correct except every value is off by 6
this is not pixels or tiles, and is totally different from e-reader start x position
SMA4Notes.txt says
range | x position |
---|---|
00 - 1F, 80 - 9F | 01 |
20 - 3F, A0 - BF | 07 |
40 - 5F, C0 - DF | 0D |
60 - 7F, E0 - FF | 0 |
tested, and seems correct