READ THE RULES: Click here

Follow us on Facebook: https://www.facebook.com/xentax/ :)

Septerra Core Files Decompression [AM0, CH1, LV2, TX0]

Read or post about compression. And decompression. Or ask questions how to decompress your files.
Post Reply
Researchman
mega-veteran
mega-veteran
Posts: 314
Joined: Fri Jun 11, 2010 12:08 pm
Has thanked: 78 times
Been thanked: 21 times

Septerra Core Files Decompression [AM0, CH1, LV2, TX0]

Post by Researchman » Fri Sep 07, 2012 8:08 pm

Thanks to aluigi .db archives was unpacked - viewtopic.php?f=10&t=4809&start=15

However, unpacked files have internal compression, which is not very strong. Part of files can be like a container, which have resource complex - graphics, sounds, etc.

AM0 - sprites and animations.
CH1 - character data.
LV2 - level data resources.
TX0 - texts.

Plus two files - 000001e4.gv0 and 000002e8.il0.

Stuns unpack Deflate and LZO data from files.
Try use .PAS sources of LZSS and LZW compression, but without success.

Think what files have LZ-like or RLE-like compression.

Files can be send throught PM.

Researchman
mega-veteran
mega-veteran
Posts: 314
Joined: Fri Jun 11, 2010 12:08 pm
Has thanked: 78 times
Been thanked: 21 times

Re: Septerra Core Files Decompression [AM0, CH1, LV2, TX0]

Post by Researchman » Tue Jan 22, 2013 4:31 pm

Unpacked data from demo-version of the game - http://www.mediafire.com/?98b8op5ueoc5k1m

Without .DAT(.MOV files) and .VSS(.MP3 files) files.

JustDragonflies
ultra-n00b
Posts: 1
Joined: Sun Mar 24, 2013 2:50 pm
Been thanked: 1 time

Re: Septerra Core Files Decompression [AM0, CH1, LV2, TX0]

Post by JustDragonflies » Mon Mar 25, 2013 12:52 pm

I've made a start with decoding the TX0 files and through analysing the executable I found out the following.

The first 16 bytes make up the header of the file. The bytes after that contain the offset table referencing the items in the data section, which is the last section.

Header

Code: Select all

0..3   -> Header, always 'TX00'.
4..7   -> Number of entries
8..11  -> Size (in bytes) of the data section
12..15 -> Dummy, always seems to be 1
Using the number of entries provided in the header you can read the 12 byte structures of the offset table which contain the following data.

Offset Table (x times 12 byte entries)

Code: Select all

 0..3   -> Offset from begin of file
 4..7   -> Length
 8..11  -> Unknown, probably an ID
Using these headers you can read the actual data stored. But the data that comes out isn't ASCII, so perhaps there is a form encryption or compression going on, but I haven't been able to identify it yet. @ResearchMan are you certain that the files contain texts, or could it be something else.

I've written a quick/dirty program which decodes the files of which I included an example (the PDF file).

EDIT:
Well it definitely contains text. When you XOR the bytes with 0x60 you get something rather readable. You also need to add the value 2 for bytes in the range of 62..88 (after XOR). The value FF (before XOR) stands for a space. There are still some characters which aren't translating correctly, I will investigate further.

EDIT 2:
I've made a dump of the memory of the game while it was running to see whether the texts get decoded, which isn't the case. So either the texts get decoded on the fly when needed, or the bytes reference a position inside a font graphic, which is more likely I think, because besides the XOR 0x60, there doesn't seem to be a pattern for decoding the other characters (like numbers, quotes, etc...). I will create a translation table and post it here later on. I will also cleanup my source code and put it on Github or something.
You do not have the required permissions to view the files attached to this post.

XDarkx
ultra-n00b
Posts: 2
Joined: Thu May 26, 2011 5:26 pm

Re: Septerra Core Files Decompression [AM0, CH1, LV2, TX0]

Post by XDarkx » Wed Apr 01, 2015 6:36 pm

JustDragonflies wrote:I've made a start with decoding the TX0 files and through analysing the executable I found out the following.

The first 16 bytes make up the header of the file. The bytes after that contain the offset table referencing the items in the data section, which is the last section.

Header

Code: Select all

0..3   -> Header, always 'TX00'.
4..7   -> Number of entries
8..11  -> Size (in bytes) of the data section
12..15 -> Dummy, always seems to be 1
Using the number of entries provided in the header you can read the 12 byte structures of the offset table which contain the following data.

Offset Table (x times 12 byte entries)

Code: Select all

 0..3   -> Offset from begin of file
 4..7   -> Length
 8..11  -> Unknown, probably an ID
Using these headers you can read the actual data stored. But the data that comes out isn't ASCII, so perhaps there is a form encryption or compression going on, but I haven't been able to identify it yet. @ResearchMan are you certain that the files contain texts, or could it be something else.

I've written a quick/dirty program which decodes the files of which I included an example (the PDF file).

.
Sorry for revive.
Anyway, Interesting description, as I use this to translate the game texts to another language eg Spanish and convert it again, is possible? I always wanted this.

Giovarco
n00b
Posts: 10
Joined: Thu Sep 17, 2015 5:17 pm

Re: Septerra Core Files Decompression [AM0, CH1, LV2, TX0]

Post by Giovarco » Mon Sep 10, 2018 4:43 pm

Hello again, 7 year into the future!

Sorry for the necropost, but are there news over here? Did someone try to look into this matter again? I cannot help technically, but I have time to translate.

Best,

Giovarco

Giovarco
n00b
Posts: 10
Joined: Thu Sep 17, 2015 5:17 pm

Re: Septerra Core Files Decompression [AM0, CH1, LV2, TX0]

Post by Giovarco » Mon Sep 10, 2018 5:15 pm

Giovarco wrote:Hello again, 7 year into the future!

Sorry for the necropost, but are there news over here? Did someone try to look into this matter again? I cannot help technically, but I have time to translate.

Best,

Giovarco
I found this: https://github.com/FileFormatTools/jRip ... pterraCore

I think that this contains the solutions of our problems!

Giovarco
n00b
Posts: 10
Joined: Thu Sep 17, 2015 5:17 pm

Re: Septerra Core Files Decompression [AM0, CH1, LV2, TX0]

Post by Giovarco » Wed Sep 12, 2018 5:02 pm

Giovarco wrote:
Giovarco wrote:Hello again, 7 year into the future!

Sorry for the necropost, but are there news over here? Did someone try to look into this matter again? I cannot help technically, but I have time to translate.

Best,

Giovarco
I found this: https://github.com/FileFormatTools/jRip ... pterraCore

I think that this contains the solutions of our problems!
Up!

I took a look to JRipper. Inside TX0.vb, you can read "To decrypt TX0 files you must first XOR 96 and then increment uppercase letters +2 (i.e A = C, B = D)".

Can someone kindly check?

Post Reply