Jump to content

Ghost of Tsushima Director's Cut (PC version) (.xpps .xmesh)


NielsGx

Recommended Posts

Posted (edited)

Before you do that I should provide H2O file names with leading zeroes, I guess. Such as ..._0001, ..._0002 instead of ..._1, ..._2.

You don't need to collect all 11 (12?) lods, btw. I just need one to maybe recognize a pattern in the numbering,

edit: updated the H2O zip in saturday's post (using leading zeroes in the names)

Edited by shak-otay
Link to comment
Share on other sites

3 hours ago, shak-otay said:

Good to hear. And yes, should be the lods. If you'd collect all meshes of one lod "level" and told me their numbers, .._1, .._17 or the like I could try to name them accordingly, if possible.

So to explain I made a table from A to .... are the description and from 1 to ... the lod level (I sorted the lods by amount of vertecies). Sometimes there is only one number in it, which means that LOD 0 was together and the corresponding LODs were separate models. The mesh 414 and 362 are missing because there was an error when exporting from hex2obj. But everything else worked and should be listed in the table unless I made a mistake.

LOD_Samurai.zip

3 hours ago, shak-otay said:

Before you do that I should provide H2O file names with leading zeroes, I guess. Such as ..._0001, ..._0002 instead of ..._1, ..._2.

You don't need to collect all 11 (12?) lods, btw. I just need one to maybe recognize a pattern in the numbering,

edit: updated the H2O zip in saturday's post (using leading zeroes in the names)

Bruh already did it hahaah

  • Thanks 1
Link to comment
Share on other sites

shak-otay could you try to get the information which texture is connected to a lower lod lvl? This would be very interesting maybe we can find out if there are extra textures for them in .xpps files

Link to comment
Share on other sites

Posted (edited)
15 hours ago, Dave2006 said:

shak-otay could you try to get the information which texture is connected to a lower lod lvl?

Hi, first of all thanks for the xlsx file! Good to know that there are 6 lods only (should have known it from the count of helmets sub meshes, haha).  Having 12 vest sub meshes should mean that there's color/texture file variations.

From adachi xpps I can see that there's 138 x the string "HASH" contained. So we need to find the hashing algo to identify the texture names.

If they don't use some "standard" hashing debugging of the game's exe will be required.

Then the names of the texture files need to be hashed and the resulting 16 bytes (= 256 bit) value to be found in the related xpps file.

edit: for the grouping of the lod's sub meshes of Shimura's armor- here's the H2O numbers of the helmets

42, 157, 207,  325, 412, 514

and the H2O numbers of the vests:

59, 68, 135, 188, 202, 222, 336, 373, 467, 485, 529, 571

As you can see: the numbers are pretty random. That's because not all of the 109 armor parts you've found have the full lod set.

Hopefully there's some id which marks a part. But where to search for it? In the xmesh or in the xpps file?

Edited by shak-otay
  • Like 1
Link to comment
Share on other sites

6 hours ago, shak-otay said:

 

From adachi xpps I can see that there's 138 x the string "HASH" contained. So we need to find the hashing algo to identify the texture names.

If they don't use some "standard" hashing debugging of the game's exe will be required.

 

image.png.1487baa371d4e023d70dbc38e5691c51.png

I also found this in adachi.xpps seems like theres definitly something with texture postiton, color usw. saved in the file. But im not into hex code. I want to learn it but dont really know where to start hahaha. 

6 hours ago, shak-otay said:

As you can see: the numbers are pretty random. That's because not all of the 109 armor parts you've found have the full lod set.

 

It usually looks pretty random, but with Lod 4 it is almost always a mesh with 2 digits. Like Helmet 65, rope helmet 25 ... Could be a coincidence but maybe not

  • Like 1
Link to comment
Share on other sites

Posted (edited)
On 5/28/2024 at 3:28 PM, Dave2006 said:

But im not into hex code. I want to learn it but dont really know where to start hahaha. 

I remember it was very hard at the beginning: learning for weeks, little progress. It needs some personal interest on a specific game to make your motivation explode, in my experience, hahaha.

Quote

It usually looks pretty random, but with Lod 4 it is almost always a mesh with 2 digits. Like Helmet 65, rope helmet 25 ... Could be a coincidence but maybe not

Well recognized, but I don't know whether this helps. Similar with lod 1 where the average of numbers might float around 350?

I will make a list with numbers versa vertexblock addresses and look for conspicuousness.

edit: no, I don't need to - guess, I found that ID already but didn't recognize it yesterday. Was wondering about it's maximum occurence of 105 - we have 109 parts, do we? Will check this.

edit 2: added adachi_costume, lod6 picture

 

------------

btw, working on adachi's costume. Some uv block sizes are 8 here.

IMPORTANT: just entering the parameters will NOT work!

Update to hex2obj_0.25a, if you haven't done so (0.25 had a bug with UVBsize=8).

You'll need to use this H2O file with special type 5:

(copy 6 lines to adachi_costume_465.h2o)

 

0x4aaaa9 15206
Vb1
08 99
0x4b2189 2967
020500
0x4bdb09 8

 

 

adachi_costume.jpg

adachi_costume_vest.png

Adachi_costume_lod6.jpg

Edited by shak-otay
  • Like 1
Link to comment
Share on other sites

Posted (edited)

Separated the lods- was easier than expected.

When using the "File/SaveAs Mmesh" feature to process multiple H2O files 
to create obj files from them there's some technical hurdle with lods.

Say, the lod number is included like so: shimura_samurai_armor.xmesh_1_0000.h2o
Where _1 means 'lod 1' and _0000 is the number of the resulting mesh.

If you chose one of the _1 files in hex2obj only lod 1 is processed.
That's intended.

>>> What's not intended is: for each lod H2O starts from zero 
    for generating the obj file number.

So it's required to move the created obj files into a separate directoy.
(Otherwise H2O refuses to overwrite an existing obj file.)
------------------------------------------------------------------------
You can load them with the load_multi_obj_blender2.69.py per lod.
    But you need to adjust the folder name in the script, such as \\lod1
    (or \\lod2, and so on)

(If you want to load all lods simply copy all lod folders into a parent folder
 and copy its name into the script.) 

 

 

 

Shimura Lod1_and_6.jpg

shimura_samurai_armor.xmesh_1-6-H2O.zip

Edited by shak-otay
  • Like 1
  • Thanks 1
Link to comment
Share on other sites

On 5/28/2024 at 8:52 AM, shak-otay said:

From adachi xpps I can see that there's 138 x the string "HASH" contained. So we need to find the hashing algo to identify the texture names.

If they don't use some "standard" hashing debugging of the game's exe will be required.

Then the names of the texture files need to be hashed and the resulting 16 bytes (= 256 bit) value to be found in the related xpps file.

I talked with a guy on Discord about it. Like i said dont know really much about this for now but maybe you can get some infos out of it:rev1.png.918089d6f2b49b1e32ad2781882f17a5.png

Screenshot2024-05-30012053.thumb.png.7c510c5ee0161a383363f2af0e8d49c6.png

Here is link to the video he sent: https://streamable.com/vwq2jf

  • Like 1
Link to comment
Share on other sites

Posted (edited)

Thanks, but that's about decompresssing, not the hash function I spoke of? (Hashing uses compression.)

Also I don't owe the game to check it.

You might search in the exe file for the string SHA ("Secure Hash Algorithm") to maybe find the type of SHA they're using, (It's not MD5, because that produces 128-bit outputs.)

Edited by shak-otay
Link to comment
Share on other sites

3 hours ago, shak-otay said:

Thanks, but that's about decompresssing, not the hash function I spoke of? (Hashing uses compression.)

Also I don't owe the game to check it.

You might search in the exe file for the string SHA ("Secure Hash Algorithm") to maybe find the type of SHA they're using, (It's not MD5, because that produces 128-bit outputs.)

https://streamable.com/hrodha thats all i could find related to SHA but this looks more server sided for me. If you want me to i can upload the games .exe for you

  • Like 1
Link to comment
Share on other sites

Posted (edited)
2 hours ago, Dave2006 said:

If you want me to i can upload the games .exe for you

Thanks, but it must be loadable by a debugger (WinDbg, x65dbg, Gidhra, whatever), so all dlls required, too, probably.

So you need to copy the exe and the dlls into a separate folder and test whether the exe can be run by a debugger.

But that works in rare cases only. Most game exes require game data to run without crashing.

Or: you could search for the string hash in the exe file.

edit: well, just checked the hashes in bandit.xpps, they consist of 22 bytes = 176 bits

Couldn't find any generator - there's some for 160 bits (SHA-1 and MD5, afaics).

So it's very likely they used a proprietary hashing algo. Or they reduced a 256 bits hash to 176 bits, who knows?

The best idea I can think of is like so:

  • Get a small xpps file (bandit.xpps has 62 x HASH contained, that's too many) and a texture name associated with it, if any.
  • Then use an online hash generator (176 bits ) on the texture name
  • Search for the created hash bytes in said xpps file.
  • If there's no result hash the texture name without its extension. (well, they usually always hash without ext, do they?)
Edited by shak-otay
Link to comment
Share on other sites

Posted (edited)
1 hour ago, shak-otay said:

Thanks, but it must be loadable by a debugger (WinDbg, x65dbg, Gidhra, whatever), so all dlls required, too, probably.

So you need to copy the exe and the dlls into a separate folder and test whether the exe can be run by a debugger.

But that works in rare cases only. Most game exes require game data to run without crashing.

Or: you could search for the string hash in the exe file.

edit: well, just checked the hashes in bandit.xpps, they consist of 22 bytes = 176 bits

Couldn't find any generator - there's some for 160 bits (SHA-1 and MD5, afaics).

So it's very likely they used a proprietary hashing algo. Or they reduced a 256 bits hash to 176 bits, who knows?

The best idea I can think of is like so:

  • Get a small xpps file (bandit.xpps has 62 x HASH contained, that's too many) and a texture name associated with it, if any.
  • Then use an online hash generator (176 bits ) on the texture name
  • Search for the created hash bytes in said xpps file.
  • If there's no result hash the texture name without its extension. (well, they usually always hash without ext, do they?)

First you were right with the .exe this wont work.

6Ÿ¯±”¹‰=†ª²To4 thats the HASH for a part of the Unburdened Heart Samurai Clan armor bc i changed this 16bytes HASH with 1 of the adachi.xpps HASH and it when i switched to this armor ingame (every other armor worked) my game crashed so i will try to find the right texture now.

Edited by Dave2006
Link to comment
Share on other sites

Posted (edited)

Here's some kenji H2Os. Be prepared to have to delete one weird sub mesh at least.

Also the count of created obj starts from zero with each lod.

IMPORTANT: thus you have to move your created obj files after each File\SaveAs Mmesh

You have been warned.

https://imgbox.com/QQ1qtKGt

edit: H2O zips deleted from attachment. Use Make_H2O-GoT to create them.

edit: finally I got the full table for kenji; [vCnt], check required:

0: 77 50 22 6f 79 60 52 01 00 00 00 00 11 20 07 1068 6 2106 4 2108 1056 [264] 2112 
0: 16 71 7e 37 ab 65 55 03 2c 25 00 00 11 20 07 1232 6 466 4 468 236 [59] 472 
1: 6a 34 51 f9 42 fa 55 03 3c 2d 00 00 11 20 08 6 522 4 524 4 524 [62] 528 
2: ad d9 da 95 9b 48 68 03 50 37 00 00 11 20 07 536 6 618 4 620 312 [78] 624 
3: 27 3a 49 9e b9 e7 1e 06 20 42 00 00 11 20 07 708 6 930 4 932 468 [117] 936 
4: ba a3 af 60 28 65 27 0f 4c 52 00 00 11 20 07 612 6 290 4 292 148 [37] 296 
5: cd 8e 59 99 46 c9 ad 0f 7c 57 00 00 11 20 08 6 74 4 76 4 76 [19] 80 
6: cb 40 35 fd 38 f1 3f 12 fc 58 00 00 11 20 07 160 6 330 4 332 168 [42] 336 
7: 4e 59 9d e9 0e 79 67 18 b4 5e 00 00 11 20 07 888 6 1746 4 1748 876 [219] 1752 
...
373: 96 e9 ea ff 98 57 72 e0 d8 02 74 00 00 04 07 3664 6 3866 4 3868 1936 [484] 3872 
374: 37 24 78 e2 f8 6b 59 e5 d8 4c 74 00 00 04 07 8848 6 5482 4 5484 2744 [686] 5488 
375: 7b 97 98 01 17 33 7d ec 98 bd 74 00 00 04 07 33368 6 28458 4 28460 14232 [3558] 28464 
376: 80 46 df bc 4a ad a0 ec f8 f1 76 00 00 04 07 14460 6 274 4 276 140 [35] 280 
377: 83 60 5c 22 8a 15 d3 ec 3c f7 76 00 00 04 08 6 322 4 324 4 324 [81] 328 
378: 17 0a 95 01 93 2a fd ec 44 fe 76 00 00 04 07 320 6 202 4 204 104 [26] 208 
379: 2d ac 8d 51 ba 99 4c f7 20 02 77 00 00 04 07 33740 6 28522 4 28524 14264 [3566] 28528 
380: dc e9 94 7c fc 06 79 f7 44 43 79 00 00 04 07 59008 6 39778 4 39780 19892 [4973] 39784 
--, index stop at 0.
381: 13 ad db ba 06 00 00 00 20 00 00 00 00 11 *f0 

EoTab: 4351

 

Edited by shak-otay
  • Thanks 1
Link to comment
Share on other sites

Posted (edited)

Released Make_H2O-GoT for H2O creation:

Make_H2O-GoT

edit: I feel finished, somehow. Some weird meshes remaining, for example H2O file 288 for reiko's hair,

0x6b4e13 15323
Vb1
08 99
0x6bc5df 9988
020500
0x6e361f 4

First line and lower three lines must be corrected like so:

0x6b4e13 17144

...

6C4BCF 9988

020500

6d83f3 8

reiko, hair, correction of H2O no 288

Edited by shak-otay
  • Like 1
Link to comment
Share on other sites

  • 2 weeks later...

Heyas.  Just wondering if it's at all possible to extract the psarc files from a Digital Copy (ps store) of GoT from the ps5 or a non jailbroken ps4  ? Would really appreciate any advice or nudge in right direction.  tia !  I am a reverser as well, predominantly of animation & to some extent meshes, so could lend a hand

Edited by loomy
clarity
Link to comment
Share on other sites

  • 1 month later...
On 6/1/2024 at 2:51 PM, shak-otay said:

Released Make_H2O-GoT for H2O creation:

Make_H2O-GoT

edit: I feel finished, somehow. Some weird meshes remaining, for example H2O file 288 for reiko's hair,

0x6b4e13 15323
Vb1
08 99
0x6bc5df 9988
020500
0x6e361f 4

First line and lower three lines must be corrected like so:

0x6b4e13 17144

...

6C4BCF 9988

020500

6d83f3 8

reiko, hair, correction of H2O no 288

Are you still working on the models?

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...