ZenHAX

Free Game Research Forum | Official QuickBMS support | twitter @zenhax | SSL HTTPS://zenhax.com
It is currently Sat May 15, 2021 10:19 am

All times are UTC




Post new topic  Reply to topic  [ 3 posts ] 
Author Message
 Post subject: EXG files by Experience
PostPosted: Thu Mar 18, 2021 5:31 pm 

Joined: Thu Mar 18, 2021 4:07 pm
Posts: 2
By Experience, I mean the Japanese game company, experience.co.jp
Their dungeon crawling games are the ones that get the most media exposure.

Here I have two image files (I believe) from their recent steam release of Saviors of Sapphire Wings.

Attachment:
ExgSamples.zip [2.08 MiB]
Downloaded 23 times


Through comparison, the following can be observed for an *.exg file.
The attachment town0001.exg will be used for demonstration.

4B ID: 45 58 47 72, "EXGr"
4B Count: 01 00 00 00, number of items, little-endian.*
4B Size: 2D A4 0E 00, size of item, little-endian.
28B Unknown: 10 13 00 00... Curiously, here, bytes 04~07 is always identical to bytes 0C~0F.
(the repetition of 80 07 40 04)
4B Zstd ID: 28 B5 2F FD, Zstd magic number?
NB of Data: A0 80 E0 1F...,
The bytes here plus 4 (the Zstd ID) should equal to the size mentioned earlier, that is,
if you jump 0x000EA42D from the start of Zstd ID, you should land at the end of the item.

*:The sample only has 1 item, what happens when there are more than 1?
For that, please refer to npc0100.exg
The count segment in that sample says 2, and fair enough, you can locate 2 sets
of Zstd ID bytes within that sample.
A single item consist of 4B Size, 28B Unknown, followed by 4B Zstd ID, and then data,
so an *.exg file can be generalized as:

4+4 Bytes, followed by
Array of (4+28+4+N) Bytes.

I have tried saving the Zstd+Data section to a binary, they open it with Peazip
(which supports Zstd), but it did not work.
(Or maybe that's not how a Zstd file is structured? I have no idea how Zstd works.)

Actually, the presence of the magic number only implies it could be Zstd, it could very well be
that it's simply a coincidence and Zstd has nothing to do with it.

Hope someone who is familiar with Zstd can take a look.


Top
   
PostPosted: Fri Mar 19, 2021 12:17 am 
User avatar

Joined: Mon Nov 23, 2020 6:01 pm
Posts: 46
You are correct, it is ZSTD. The attached QuickBMS script should extract the images and save as the appropriate format. Not sure if it detects the correct field for image type, but it seems to work with both your examples. If you find any files that don't work, post a sample and I'll have a look at it.


Attachments:
exg.txt [1.35 KiB]
Downloaded 26 times

_________________
"You now stand on the cusp of two realities, about to leave all that you know behind. I have called many mortals here in ages past to call forth judgement and test the spirit in the hearts of men."
Top
   
PostPosted: Fri Mar 19, 2021 7:21 am 

Joined: Thu Mar 18, 2021 4:07 pm
Posts: 2
Kudos DKDave!

Well the game does not support Win7 so I've already deleted it, since I did not expect a solution this quick...
I'll have to download it again before I can check for exceptions (about 2 gb or sth I think), and there're many files to test, but I think you've nailed it.

Thanks again!


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic  [ 3 posts ] 

All times are UTC


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Powered by phpBB® Forum Software © phpBB Limited