Starships (PC/iOS) Assets.bin unpack
-
- Posts: 11
- Joined: Mon Apr 26, 2021 9:38 pm
Starships (PC/iOS) Assets.bin unpack
Hello!
In this topic I want to learn how to extract files from 2 archives I have.
Maybe this topic become kind of a tutorial, with time.
I will write here what I have done and results, and some wisdom people will guide me to which tutorial I should step next.
Point 0. What I have
There is 2 archives. Lets call them assets1.bin and assets2.bin.
assets1.bin - was in a game files. 650 mb
assets2.bin - was inside a simple game archive. 500 mb
Point 1. What have been done firstly
Searching in the internet. Gave 0 results, source is not popular game.
Internal Total Commander unpacker. 0
Dragon Unpacker. 0
Point 2. Quick BMS start page
Dowloaded all the scripts. Go to searching by key words.
Opened assets1.bin with hex.
First 4 hex is: 5C 08 3F 07
Second 4 hex is: 25 0C 00 00
Searching - no match.
Opened assets2.bin with hex.
First 4 hex is: 5C 08 3F 07
Second 4 hex is: 31 0C 00 00
Searching - no match.
With spaces and without.
From the top part of both files I can see to signs: GSUBM and DYNA
May be this info will help in future.
Point 3. Where to start?
I have opened several qbms scripts and found that inside of them is not to much code.
For example:
age_of_empires_3.bms
company_heroes.bms
heroes_might_magic_3.bms
I think it's should be possible to make the same for my archives.
So, which tutorial or research I should start at?
In this topic I want to learn how to extract files from 2 archives I have.
Maybe this topic become kind of a tutorial, with time.
I will write here what I have done and results, and some wisdom people will guide me to which tutorial I should step next.
Point 0. What I have
There is 2 archives. Lets call them assets1.bin and assets2.bin.
assets1.bin - was in a game files. 650 mb
assets2.bin - was inside a simple game archive. 500 mb
Point 1. What have been done firstly
Searching in the internet. Gave 0 results, source is not popular game.
Internal Total Commander unpacker. 0
Dragon Unpacker. 0
Point 2. Quick BMS start page
Dowloaded all the scripts. Go to searching by key words.
Opened assets1.bin with hex.
First 4 hex is: 5C 08 3F 07
Second 4 hex is: 25 0C 00 00
Searching - no match.
Opened assets2.bin with hex.
First 4 hex is: 5C 08 3F 07
Second 4 hex is: 31 0C 00 00
Searching - no match.
With spaces and without.
From the top part of both files I can see to signs: GSUBM and DYNA
May be this info will help in future.
Point 3. Where to start?
I have opened several qbms scripts and found that inside of them is not to much code.
For example:
age_of_empires_3.bms
company_heroes.bms
heroes_might_magic_3.bms
I think it's should be possible to make the same for my archives.
So, which tutorial or research I should start at?
Last edited by MonikaZEN on Wed May 12, 2021 6:00 am, edited 1 time in total.
-
- Site Admin
- Posts: 12984
- Joined: Wed Jul 30, 2014 9:32 pm
Re: Assets.bin unpack, my experience
I guess it's much more simple to specifiy the name of the game and provide the files for analysis.
-
- Posts: 11
- Joined: Mon Apr 26, 2021 9:38 pm
Re: Assets.bin unpack, my experience
[spoiler]Starships by Sid Meier
assets1.bin (PC version)
assets2.bin (iPad version)
[/spoiler]
P.S. Is it possible to make a !spoiler BBcode?
assets1.bin (PC version)
assets2.bin (iPad version)
[/spoiler]
P.S. Is it possible to make a !spoiler BBcode?
Last edited by MonikaZEN on Wed May 12, 2021 5:57 am, edited 1 time in total.
-
- Site Admin
- Posts: 12984
- Joined: Wed Jul 30, 2014 9:32 pm
Re: Assets.bin unpack, my experience
Here is the script for quickbms:
http://aluigi.org/bms/sid_starships.bms
The format is very simple as visible from the script.
There is no "spoiler" mod on the forum and there is no need to mask the name of the game.
http://aluigi.org/bms/sid_starships.bms
The format is very simple as visible from the script.
There is no "spoiler" mod on the forum and there is no need to mask the name of the game.
-
- Posts: 11
- Joined: Mon Apr 26, 2021 9:38 pm
Re: Assets.bin unpack, my experience
Holy Lightning Speedster! That was fast.
What measures can I perform to obtain a normal names of files?
What measures can I perform to obtain a normal names of files?
-
- Site Admin
- Posts: 12984
- Joined: Wed Jul 30, 2014 9:32 pm
Re: Assets.bin unpack, my experience
You need all the original filenames (usually captured via hooking/debugging) and then figuring out what's the CRC algorithm used on them.
So, no, there is no way.
So, no, there is no way.
-
- Posts: 11
- Joined: Mon Apr 26, 2021 9:38 pm
Re: Assets.bin unpack, my experience
You mean that the archive itself does not contain such information, and that is why - no way?aluigi wrote:*** no way.
fnv32 is a hash function: https://en.wikipedia.org/wiki/Fowler–Noll–Vo_hash_functionEkey wrote:fnv32
1. How can I be sure that this case uses fnv32?
2. If so - is it possible to use reversed fnv32 function on current hashed names to gain original names?
I can provide near of 95% of original file names.
-
- Site Admin
- Posts: 12984
- Joined: Wed Jul 30, 2014 9:32 pm
Re: Assets.bin unpack, my experience
If you have almost all the file names (the whole relative path) then it's easy to do the job since there is a command of quickbms for doing that, something like the following to replace the current 'string NAME p "%08x." NAME_CRC':
Code: Select all
namecrc NAME NAME_CRC "names.txt" 32 "" "32 0 0 38 0 1"
-
- Posts: 561
- Joined: Tue Oct 13, 2015 1:26 pm
Re: Assets.bin unpack, my experience
If Ekey said it is, then it is.MonikaZEN wrote:1. How can I be sure that this case uses fnv32?
No, this is mathematically impossible. See this topic and you will understand how Hash + FileNameList + QuickBMS works, then you should be able to do the same with your case.MonikaZEN wrote:2. If so - is it possible to use reversed fnv32 function on current hashed names to gain original names?
-
- Posts: 11
- Joined: Mon Apr 26, 2021 9:38 pm
Re: Assets.bin unpack, my experience
aluigi wrote:If you have almost all the file names (the whole relative path)
Pity but no. I can retrieve only last part of relative file path. File name without path.
Delutto wrote:See this topic and you will understand how Hash + FileNameList + QuickBMS works, then you should be able to do the same with your case.
Thanks. I have read this thread. As I can understand:
1. Ekey deciphered the algo as Murmur 2 and created an FPHook (dinput8).
FPHook extracts full file path of used file from RAM to log. (full path file list)
2. Delutto, you, using algo, created a File Names Compare Hash List.
And a tool (Frostpunk_DAT_Tool), which not only unpack but same time compare a hashed names from the list and replace the orginal path of files.
In case of fnv32 algo QBMS will automatically compare hash names with file paths. Am I right?
If so, then my case need FPHook analog.
Where should I start to make FPHook for steam version of Starships64.exe?
Am I need a tutorial for a debugger to start with?
-
- Site Admin
- Posts: 12984
- Joined: Wed Jul 30, 2014 9:32 pm
Re: Assets.bin unpack, my experience
MonikaZEN wrote:In case of fnv32 algo QBMS will automatically compare hash names with file paths. Am I right?
Exactly, by using the instruction I provided in my previous post and creating a file called names.txt with all the file names (as expected by the game), one per line.
-
- Posts: 11
- Joined: Mon Apr 26, 2021 9:38 pm
-
- Posts: 1383
- Joined: Sat Aug 09, 2014 2:34 pm
Re: Starships (PC/iOS) Assets.bin unpack
I was wrong about fnv32, I checked the iOS version more closely and I conclude that the file hashing algorithm is CRC32 with polynomial 0xEDB88320.
Unfortunately, I do not have this game in Steam to check the PC version and make a hook. I can try to do this for the pirated version (not sure if it will be works in Steam version).
Unfortunately, I do not have this game in Steam to check the PC version and make a hook. I can try to do this for the pirated version (not sure if it will be works in Steam version).
-
- Posts: 11
- Joined: Mon Apr 26, 2021 9:38 pm
Re: Starships (PC/iOS) Assets.bin unpack
Ekey wrote:Unfortunately, I do not have this game in Steam to check the PC version and make a hook. I can try to do this for the pirated version (not sure if it will be works in Steam version).
It's OK. Conversely I can use the version on which you will make a research.
-
- Posts: 11
- Joined: Mon Apr 26, 2021 9:38 pm
Re: Starships (PC/iOS) Assets.bin unpack
Ekey wrote:Done
Thanks alot! Works good and simple.
P.S. Read your personal message, please.
-
- Posts: 11
- Joined: Mon Apr 26, 2021 9:38 pm
Re: Starships (PC/iOS) Assets.bin unpack
Every file type is opens but 3dx.
Should I start a thread in 3D/2D models branch, or this question is easy enough to stay it here?
Example:
Raider, Corvette
I have tried the programs called Rhino/Blender to open the 3dx files - return false
https://3d-convert.com/en/ - This also 0.
Should I start a thread in 3D/2D models branch, or this question is easy enough to stay it here?
Example:
Raider, Corvette
I have tried the programs called Rhino/Blender to open the 3dx files - return false
https://3d-convert.com/en/ - This also 0.