I'm looking for a help on decompression algo from an old DOS game.
I've spend several hours of debugging with DOSBOX just to find it and to unsuccessfully rewrite it to my tool.
This is only small part(beginning) of whole code.
Code: Select all
xor cl, cl - iteration loop
mov ax, [si] - 1st and 2nd byte from compressed data
mov dx, [si+1] - 2nd and 3rd byte from compressed data
shr dx, cl
shr ax, cl
or ah, dl
shr dx, 1
shr ax, 1
pushf
or ah, dl
inc cl
and cl, 7 - only 7 times
jnz short loc_29F16
inc si
call sub_29FCF
popf
jnb short loc_29F21
stosb - store decompressed byte
There are also only two constants used 0x1fff 0x3ff.
Any idea what type of algorithm is it?

