UPDATE 2: The "second flag byte" does not actually aim for a specific byte, it aims for a section of bytes, which is then repeated. If the third byte's value (repeat) is lower than the second byte, only the segment determined by the former repeats, starting from the first byte of the segment. If the third byte's value is higher than the second byte, the section determined by the latter repeats, completely or partially.
Here's a crudely drawn picture crudely explaining how the thing works.
I've tried to manually decompress one of the files (not the one linked in the first post), only to obtain partial success.
On another note, if the "flag" value is mentioned twice in a row, both don't function as flags; the code stays as it is.
Oh, and can someone please move this to the Game Archive category? Thanks