The convention for naming object files in the decompiler is challenging for a few reasons.
Some object files appear multiple times and are identical. There are 2832 object files, but only 2135 unique object files.
There are commonly code and art-group files with the same name in the same DGO
There are object files located outside of DGOs (STR, TXT)
There are object files that are included multiple times in different DGOs. Sometimes they are the same and sometimes they are slightly different.
We want a stable naming scheme which gives all object file the same names on different platforms, even when doing a partial decompilation.
We need to generate build files that can be given to the OpenGOAL compiler for the compilation order of files, and which files go in which DGOs.
The current implementation handles this and generates a "map file" that can be used when doing a partial decompilation to keep the naming the same. But the implementation is really confusing and it's hard to convince myself that it's correct.
We can get away with ignoring this issue for a while since all the engine code is located in a single DGO and has no weird duplicates, but I want to clean this up when we starting going through level data.
The convention for naming object files in the decompiler is challenging for a few reasons.
The current implementation handles this and generates a "map file" that can be used when doing a partial decompilation to keep the naming the same. But the implementation is really confusing and it's hard to convince myself that it's correct.
We can get away with ignoring this issue for a while since all the engine code is located in a single DGO and has no weird duplicates, but I want to clean this up when we starting going through level data.