Romhacking => Newcomer's Board => Topic started by: kenaku on June 18, 2020, 11:58:27 am

Title: Explanation about files inside PsP games
Post by: kenaku on June 18, 2020, 11:58:27 am
Hello, i just started romhacking and decided to go for PsP games, can someone explain to me what are certain files used for.

The files are:

-lib*** FILES

Specially the eboot.bin, inside those i have found in in-game text, pointer tables and text that looks like some kind of script, in English even in Japanese games, some goes like "initialize file system" or "startChat %d".
Title: Re: Explanation about files inside PsP games
Post by: FAST6191 on June 19, 2020, 09:07:32 am
eboot files are the main executables. While not best form many devs will never the less include scripts and graphics in them. What you found look a bit more like debug strings and system strings (think error messages, wifi related stuff, file system then probably going for saves).

UMD_DATA.BIN is data from the PSP ISO (UMD is the name of the disc format used by the PSP). Somewhat surprised to see such things but will contain the contents of the game. You might need to extract these further, and to use them some will want to pack them into isos with something like umdgen.

param.sfo is used by various playstations to define the parameters of what the game can do (hardware, speeds and certain other things). Not so useful for most ROM hacking purposes, and not really that useful for emulation or ROM running either.

prx is a type of executable ( ) but most normally see them as plugins to do various things.

lib is probably short for library and might be unique to that game.
Title: Re: Explanation about files inside PsP games
Post by: [Unknown] on July 04, 2020, 10:41:11 pm
In a typical PSP game:

 * UMD_DATA.BIN is essentially header data about the UMD (disc.)  It's mainly the disc ID.
 * PSP_GAME/PARAM.SFO contains key/value pairs.  Contains the text shown in the XMB, for example (which you may want to change for a translation.)  See PPSSPP's ParamSFO to parse, but it's simple:
 * PSP_GAME/SYSDIR/BOOT.BIN (not EBOOT which was already mentioned) is not actually used by official firmware and is often zero filled.  For games made for firmware < 3.00 it sometimes contains the original binary.  Mostly you should ignore this for hacking.
 * PSP_GAME/SYSDIR/UPDATE/ - do not confuse the EBOOT.BIN in here with the other one.  It's for on-disc firmware updates.  Same for PARAM.SFO.
 * PSP_GAME/USRDIR/ will typically contain files that are game-specific.  The directory structure and files included at that point are up to the game.
 * PSP_GAME/INSDIR/ will contain game defined files (usually DATA.BIN or similar) that would be installed on the memory stick if "Data Install" is selected.  Often encrypted to impede modding/cheating.

You'll often find the following files:

 * *.prx - essentially a DLL.  Most games use Sony official libraries for video playback etc.  Sometimes these are versions of libraries that were ultimately included in newer versions of firmware.  In rare cases (like Valkyrie Profile and some MGS games), games may use prx files to load parts of the game itself, such as battle scenes.  This is uncommon, though.

 * *.pmf (sometimes other extensions) - video file.
 * *.at3 - audio file.
 * *.png - probably obvious, image file.
 * *.gim - image file (usually embedded in other files.)
 * *.bin, *.pak, *.dat, etc. - game defined data format.  No standard.

You will very often find English text in ELFs (binaries) like EBOOT.BIN.  This is because it's compiled and contains logging messages from the original developers (isn't that nice of them?)  It may even contain C standard library error messages.