mirror of
https://github.com/NovaSquirrel/NovaTheSquirrel.git
synced 2026-01-16 23:13:17 +01:00
1
Level headers
NovaSquirrel edited this page 2016-07-18 07:22:43 -04:00
0 1 2 3 4 5 6 .D.MMMMM XXXXXXXX SSSSYYYY AAAAAAAA BBBBBBBB CCCCCCCC DDDDDDDD D = If 1, player starts facing left M = Background music; use the MusicTracks scope X = Starting X position S = Number of screens in the level Y = Starting Y position A,B,C,D = Sprite graphics slots. 7 8 9 10 11 llllllll LLLLLLLL ssssssss SSSSSSSS CCCCCCCC l = Low byte of level data pointer L = High byte of level data pointer s = Low byte of sprite list pointer S = High byte of sprite list pointer C = Level background color
After these 12 bytes is a list of graphical resources (palettes and background tilesets) used by the level, terminated with a $ff. This list gets written to LevelUploadList.
After the graphical upload list is a 16-bit big endian word that places scrolling barriers between screens:
Bits: a b c d e f g h i j k l m n o L Screens: 0|1|2|3|4|5|6|7|8|9|A|B|C|D|E|F
The L bit doesn't correspond to a scroll boundary, and if it's 1 it instead signals that the level wants to link some screens together vertically. These links are in this format:
....NNNN TTTTBBBB N = Number of screens minus one T = Screen number the top edge links to, relative to this one B = Screen number the bottom edge links to, relative to this one
These two bytes repeat until 16 screens have been specified.