News:

Herr Otto Partz says you're all nothing but pipsqueaks!

Main Menu

PES File Format

Started by w4kfu, March 25, 2013, 08:35:41 PM

Previous topic - Next topic

w4kfu

So I started reverse the real "game.exe", and found that restunts don't know how to handle this type of files (*.PES)
This file format use a common scheme used in image file compression, first pass is huffman decompression, then RLE decompression.
After they do an "unflip" on pixels for some images, and expand image data to 8bits. After all this, we can extract easily image like follow :

Image gallery for the file SCRED.PES : http://w4kfu.com/misc/stunts/SDCRED_gallery/

Image gallery for the file SDTEDIT.PES : http://w4kfu.com/misc/stunts/SDTEDIT_gallery/

dstien will add my work to stressed and restunts as soon as possible.

dreadnaut

#1
Track item masks, that's nice! Thanks!

Although there are some artifacts left. E.g., this image should be a brown windmill, like the one in this palette:

w4kfu

You are right, and it is now fix :)

Duplode

Excellent! :) ESH icons were the main data formats yet to be described. Only a fuller account of music and sound effect data is missing now, IIRC. To point out one low-hanging fruit: as the track element to editor selection grid correspondence is defined by pbox in TEDIT.RES, being able to edit the icons makes it possible to add the ghost cars (like the one available in Track Blaster) to the regular editor's palette.

dstien

Beyond excellent! ;D
7 related functions now ported in restunts.

arturbmallmann

I know I'm digging up this post, but it costed to me to found where was the information about what kind of decompression was necessary to open the files. I think would be interesting that someone put this information on the Stunts Wiki(If already was there, sorry, but I don`t found it there).

Duplode

Quote from: arturbmallmann on March 08, 2017, 11:00:40 PM
I know I'm digging up this post, but it costed to me to found where was the information about what kind of decompression was necessary to open the files. I think would be interesting that someone put this information on the Stunts Wiki(If already was there, sorry, but I don`t found it there).

Indeed, that should be documented -- as a section in Resource file format, or perhaps in a separate article to also cover compression in the executable.

Daniel3D

Quote from: w4kfu on March 25, 2013, 08:35:41 PM
dstien will add my work to stressed and restunts as soon as possible.
I can't really open the files with stressed, am I correct in assuming this was not added? Or do I need to open the chunk as something different than Bitmap.
PES and ESH seem to be supported.
Edison once said,
"I have not failed 10,000 times,
I've successfully found 10,000 ways that will not work."
---------
Currently running over 20 separate instances of Stunts or 4D Sports Driving.

Daniel3D

#8
I googled a bit and found w4kfu his Git.

https://github.com/w4kfu/Stunts

After reading his documentation, I realized that Samuel (w4kfu) did manage to unpack the pes files and extract the images, but his tool is unable to reverse it.
So PES (esh) files can not be modded yet.

That is unfortunate for me because I thought of altering some scenery for the Ferrari edition (tribune and pit lane boxes in expense of joe's diner and the garage)
and the tile images of the track editor are in a PES file.
Edison once said,
"I have not failed 10,000 times,
I've successfully found 10,000 ways that will not work."
---------
Currently running over 20 separate instances of Stunts or 4D Sports Driving.