Ultimate Mortal Kombat 3 (Genesis)/Notes

From Data Crystal
Jump to navigation Jump to search

Chip tiny.png The following article is a Notes Page for Ultimate Mortal Kombat 3 (Genesis).

Archive structure

__________________________________
Offset | Size| Description
_______|_____|_____________________
   0-1 | Word| Compression method 
_______|_____|_____________________
   2-3 | Word| Compressed data size
_______|_____|_____________________
    4* | Byte| Data type
_______|_____|_____________________
  5..n |Bytes| compressed data
_______|_____|_____________________
  • This parameter is not used in compression method 3

Method 2-1: Unpacking graphics

Flag byte:
XXXXXXXX
1 - there is no compression, just copy one byte from the source to the receiver
0 - there is compression.

LZ:
1 XXX YYYY XXXXXXXX
| | | |
| | | 8 младших битов смещения строки (offset)
| | 4 бита, обозначающие длину строки (18 — длина строки)
| 3 старших бита смещения строки
код сжатия LZ

RLE:
01 YY YYYY AAAAAAAA
| | |
| | bytes of repetition
| 6 bits (66 - number of repetitions)
RLE compression code

RLE_plus_Arith:
00 YY YYYY AAAAAAAA
| | |
| | bytes of repetition
| 6 bits (66 - number of sequences) maximum 65 bytes
compression code - RLE + arithmetic progression

Method 2-2: Unpacking the Tile Map

It differs from the previous compression method only in that the highest bytes of the tile map (priority, palette number, reflection) are decompressed first, and then the lowest bytes. At the same time, after each write to the receiver, the receiver address is increased by two bytes. Also, during decompression of the low-order bytes, the lz string can be copied from the high-order bytes.

TODO

Method 1-1: Unpacking Graphics

EndOfDecompress:
0000 0000

TODO

Method 1-2: Unpacking the Tile map

It differs from the previous compression method only in that the highest bytes of the tile map (priority, palette number, reflection) are decompressed first, and then the lowest bytes. At the same time, after each write to the receiver, the receiver address is increased by two bytes. Also, during decompression of the low-order bytes, the lz string can be copied from the high-order bytes.

EndOfDecompress:
0000 0000 - must be written after compression of the low and high bytes

TODO

Method 3

very rare method

END Of Decompress:
0000 0000

TODO