Force Unleashed 2 DLC

Extraction and unpacking of game archives and compression, encryption, obfuscation, decoding of unknown files
nightwolf1982
Posts: 22
Joined: Fri Dec 07, 2018 12:24 am

Force Unleashed 2 DLC

Post by nightwolf1982 »

New here, been digging into the old Force Unleashed 2 DLC. After more than a year, and with some help from shakotay2 at xentax, I've finally managed to find a way to hex reverse models from the PS3 DLC; but I'd still like to figure out a way to extract the full gto files.

To that end , I've figured out that the animation, model and texture files are contained in a set of CLUSTER files (CPU#.CLUSTER, GPU#.CLUSTER) which are all tied together somehow with a TEST.LEVELPACKMETADATA (LPMD) file.

This is what I've figured out about the LPMD files so far:

Code: Select all

0x00 = 4c504d44 - LPMD Magic
0x04 = 0000000b - Version?
0x08 = ???? - 0047b000 for all of the Player Outfits
0x0c = ???? - 07dc0000 for the Endor1 and Endor2 files, 00f19999 for all of the Player Outfits
0x10 = ????
0x14 = 00000034
0x18 = 00000001
0x1c = Hex Address 28 bytes from ENUS
0x30 = ????
0x34 = 00000000
0x38 = ffffffc7
0x3c = ????
0x40 = ????
0x44 = Hex Address 68 bytes from STRG / 84 bytes from the string table
0x48 = ????
0x4c = 00000000

0x50 = f0e0d413 - Found throughout two sections of the file, immediately before and after the ENUS section
       
       f934f180 - Found Before and after ENUS; lines up with f0e0d413; Always appears 28 bytes before "GPU" and immediately after "GPU"

       1d9e31ba - Found before and after ENUS; lines up with f0e0d413; Always appears after "LCPU", "SCPU", and "SGPU"

ENUS - Address varies from file to file

   Unit32 - ENUS
   Unit32 - File Count
   Unit32 - File Number
   Unit32 - ? - Can be 0x00 or 0x01
   Unit32 - 0x02
   Unit32 - File Size
   Unit32 - Pad
   Unit32 - Pad
   Unit32 - ?
   Unit32 - ?
   Unit32 - ?

Immediately after the STRG table, there are data blocks for each CLUSTER file, including the full path and name of the file.


Unfortunately, that's as far as I've gotten.

links for samples:
ackbar:
https://drive.google.com/open?id=1GR83G ... OSHhl_dPMO
bloodarmour:
https://drive.google.com/open?id=1-BAYk ... 74_2rDr-un
sith starkiller:
https://drive.google.com/open?id=1yX7ZJ ... 0if9O2Z4S0
aluigi
Site Admin
Posts: 12984
Joined: Wed Jul 30, 2014 9:32 pm

Re: Force Unleashed 2 DLC

Post by aluigi »

What a terrible format but at least I have been able to extract the data.
http://aluigi.org/bms/force_unleashed_2.bms

Only the "kcap" files are not parsed because it would mean to extract an extracted file, they are probably rare.
Acewell
Posts: 706
Joined: Fri Aug 08, 2014 1:06 am

[PS3] Star Wars: The Force Unleashed 2 DLC

Post by Acewell »

awesome, the files are extracted but the names are not applied,
is this intentional or was a problem with the assignments? :)
aluigi
Site Admin
Posts: 12984
Joined: Wed Jul 30, 2014 9:32 pm

Re: Force Unleashed 2 DLC

Post by aluigi »

There are no names in the index corresponding to the files.
You have names in ENUS, yes, but they are just a few while the files are a lot.
Acewell
Posts: 706
Joined: Fri Aug 08, 2014 1:06 am

[PS3] Star Wars: The Force Unleashed 2 DLC

Post by Acewell »

the last "dummy" in your first loop is the relative offset to the beginning of the file name in the STRG table.
they are not always sequential, the offsets could shift around but each entry in table1 has a different offset.
there is a name for each file, according to the string printout only the dds and gto files have duplicate names,
CRC1 and CRC2 values but they are of different sizes, which possibly contains the missing header info.
for example the dds have a file 24 bytes and another of the same name with 174848 bytes,
i believe if you append the duplicates you will have complete files to work from, same for the L/SCPU types. :)

0GPU - represents image data (a 24 byte file (possibly a header) always preceeds this)
LCPU - represents lowres gto model data? (always a smaller data size than SCPU)
SCPU - represents highres gto model data?
00000000 - represents .animations files
nightwolf1982
Posts: 22
Joined: Fri Dec 07, 2018 12:24 am

Re: Force Unleashed 2 DLC

Post by nightwolf1982 »

Been doing some more digging

Code: Select all

0x00 = 4c504d44 - LPMD Magic
0x04 = 0000000b - Version?
0x08 = ???? - 0047b000 for all of the Player Outfits
0x0c = ???? - 07dc0000 for the Endor1 and Endor2 files, 00f19999 for all of the Player Outfits
0x10 = Total number of entries before ENUS featuring f0e0d413, f934f180, and 1d9e31ba
0x14 = 00000034
0x18 = 00000001
0x1c = Hex Address 28 bytes from ENUS
0x20 = ???? - 00000003 for all of the Player Outfits, 0000000e for Endor1, 00000012 for Endor2
0x24 = Hex Address for the last File ID in the ENUS Section
0x28 = ????
0x2c = ???? - 00000001 for all of the Player Outfits, 0000000e for Endor1, 00000011 for Endor2
0x30 = ????
0x34 = 00000000
0x38 = ffffffc7 End of Header?
0x3c = Total number of entries after ENUS featuring f0e0d413, f934f180, and 1d9e31ba
0x40 = ????
0x44 = Hex Address 68 bytes from STRG, Start of data block entries
0x48 = ????
0x4c = 00000000

       f0e0d413 - Found throughout two sections of the file, immediately before and after the ENUS section
       
       f934f180 - Found before and after ENUS; lines up with f0e0d413; Always appears 24 bytes before"GPU" and immediately after "GPU"

       1d9e31ba - Found before and after ENUS; lines up with f0e0d413; Always appears after "LCPU", "SCPU", and "SGPU"

ENUS - Address varies from file to file

   Unit32 - ENUS
   Unit32 - File Count
   Unit32 - CLUSTER File ID
   Unit32 - Can be 0x00 or 0x01
   Unit32 - 0x02
   Unit32 - CLUSTER File Size
   Unit32 - Pad
   Unit32 - Pad
   Unit32 - ?
   Unit32 - Number of Files in CLUSTER
   Unit32 - ?

Immediately after the STRG table, there are data blocks for each CLUSTER file, including the full path and name of the file.


Biggest update is the value at 0x3c, which refers to the second table after the ENUS.

I think Acewell is onto something. The textures are stored as raw data, with no headers (that I can see, anyway) And I know the gto files are broken up, since the actual gto entries in the CLUSTER files are missing significant parts of their data. (Face Indices, material info, etc...)
Alvar007
Posts: 2
Joined: Sat Apr 20, 2019 4:52 pm

Re: Force Unleashed 2 DLC

Post by Alvar007 »

Hello there! Are there any news on this? I would really like to get the Darth Malak model. If it's not possible this way, maybe @nightwolf1982 could you hex reverse it like you did with Jedi Leia please? This really is a unique high quality model not available anywhere else. Thanks.
nightwolf1982
Posts: 22
Joined: Fri Dec 07, 2018 12:24 am

Re: Force Unleashed 2 DLC

Post by nightwolf1982 »

Not much new data, but there was something interesting I spotted. When the data sections featuring the f0e0d413 entries are lined up by byte length (28 bytes before ENUS, 12 bytes after ENUS), the data appears to be arranged in sequential order (LPMD01.jpg, LPMD02.jpg)


Unfortunately, I don't think there'll be much more progress on this as there just doesn't seem to be any interest.
Alvar007
Posts: 2
Joined: Sat Apr 20, 2019 4:52 pm

Re: Force Unleashed 2 DLC

Post by Alvar007 »

Aww man, it would be such a shame to lose this models. Even if you cannot extract the full .gto files, can you at least hex reverse him like you did with Jedi Leia? I can rig the model on my own.