ghoost82 / podextract

Extract Terminal Reality POD and EPD archive files

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Extraction issues (+ data decompression success)

hgdagon opened this issue · comments

Reserved
Currently testing all games. There are issues with every game. Will update when done testing.

Update

Slight update, if anyone happens to keep an eye on this: Seems like all the byte 128 errors are resolved by #2 . Currently testing data decompression.

Update2

So, data decompression works... on certain streams only. Will fill this issue soon. I'm almost done.

@jopadan Can i get a hand on this?

I have been looking into Wipeout: The Game on the Nintendo Wii and it appears to use Terminal Reality's POD5 Archive format. There is a 574 byte LANGUAGE.POD file that fails to extract with an error similar to what this issue was called originally. I get a similar error when trying to extract the rest of the .POD files which also have the POD5 format.

It seems the problem was two-fold in my case. A specific read call on line 193 makes use of an arc object when no such object exists. Renaming the object to pod_file allowed the 574-byte file to extract. The larger files still failed to load, which I fixed by using a change from #2 and making the tool decode the iso-8859-1 format instead of ASCII.

Recently testing this tool I found the same problems related to language too, instead of trying to extract immediately I did try to list the files inside before (POD3 in my case) and was able to detect the issues converting during the "ASCII" decode process , that affected the listing process (-l or -ll) as well the extraction process (-x).

'ascii' codec can't decode byte 0xf5 in position 36: ordinal not in range(128)

Trying to fix the decoding ("ASCII") for some PODS caused an issue to not decode other PODS that previously were fine.
Then instead, I used a different approach to fix all PODs. Instead of treating the string variable as a string, I treat it as bytes purely and just look inside the chunk if there are some null characters to grab the first portion:

def _get_c_string(self, string):
        return string[0:string.find('\0'.encode('ascii'))]

and the list and extraction for all the pods were a success.

UPDATE:
In this way, one still can rely on UTF-8 default encoding.