Skip to content

Filename Extraction

philyeahz edited this page Sep 10, 2018 · 7 revisions

There are many hardcoded filenames inside the executable itself.

How files get loaded

Hardcoded files get loaded when needed. Some files have references to other files that are not hardcoded. In this case when the reference gets read the loader task gets this reference filename and searches for this filename in the TAD files. When the file has been found the TAC file gets opened, the file will be read into an buffer and the TAC file will be closed which frees the file handle.

Audio Filenames

The audio filenames are hardcoded and will be extracted from the executable.

Common Filenames

This one is a bit more tricky because filenames get only searched when they are needed and there are only a limited amount of hardcoded filenames. The plan is to extract all the hardcoded filenames for the common file and open them up to see their references to other files.

assetremapping.json

This file holds an hash collision table which holds the filenames of the .rmp files.

.rmp files

These files are the result of the assetremapping.json. They are build by the ContHashMD5, ContHashTex and the FileSize.

.ui files

These files hold all the textures for the UI.

sdtextureoverride.json

This file holds many texture filenames which overwrite the textures from the disk.

Disk Filenames

The disk filenames (and parts of some filenames) are hardcoded inside the executable an get build (appended) to create the full filenames. Because this is tedious work to extract those parts and build them together, we use the real disk images and extract all filenames from these. With these filenames we can then create all the hashes and search for all the existing ones inside the disk TAD file.

Shader Filenames

The shader filenames are hardcoded and will be extracted from the executable.

Clone this wiki locally