Page 2 of 10

Re: Far Cry Primal models

Posted: Thu Jan 19, 2017 6:16 pm
by daemon1
FartingSquirrel wrote:Wow, cool. So, that means the texts are editable now, and only a repacking method is needed for them?
That means I unpacked the file and I can open it. I don't know if you have any tools to edit it.

Check it yourself: http://www112.zippyshare.com/v/pYdElWqe/file.html

Re: Far Cry Primal models

Posted: Thu Jan 19, 2017 6:40 pm
by FartingSquirrel
Oh, alright. But actually, I can't even unpack the .bin with GibbedDunia. Well, probably I'm doing something wrong, but Gibbed.Dunia2.ConvertBinaryObject.exe isn't supposed to unpack it?

Re: Far Cry Primal models

Posted: Thu Jan 19, 2017 7:22 pm
by daemon1
FartingSquirrel wrote:Oh, alright. But actually, I can't even unpack the .bin with GibbedDunia. Well, probably I'm doing something wrong, but Gibbed.Dunia2.ConvertBinaryObject.exe isn't supposed to unpack it?
I have no idea. Never used GibbedDunia. I could unpack it myself thats all I know.

Good news :) I now have all 200k+ files unpacked from primal_main 6gig file with names.
Thats quite a lot of files. What do you want me to do with the tool? Maybe add some filter? Do you really need them all unpacked?

Re: Far Cry Primal models

Posted: Thu Jan 19, 2017 9:04 pm
by daemon1
ok this is first test. This tool (with dictionary) will unpack all compressed files from fat/dat pairs. Dictionary includes all names for primal_main. Other files will be extracted names as hashes.

https://mega.nz/#!YY5UgagB!waUFhD03EACg ... heZ6HN63ds

That means uncompressed files (and there are many of them) will not be extracted for now. They are all tiny, no more than 1k in size.

Re: Far Cry Primal models

Posted: Thu Jan 19, 2017 9:42 pm
by volfin
xbt textures seem to be identical to FarCry 2/3/4. Model format is however changed. Probably not by much. I'll start working on an importer. :)

Re: Far Cry Primal models

Posted: Thu Jan 19, 2017 9:44 pm
by daemon1
are you going to export with bones? because if not, i will do it

Re: Far Cry Primal models

Posted: Thu Jan 19, 2017 10:10 pm
by SoldierTODD
I apologize if I interfere in your conversation, if you write a script, do, please, the ability to import and animation.


P.S. Sorry for my English, I use a translator.

Re: Far Cry Primal models

Posted: Fri Jan 20, 2017 1:15 am
by volfin
daemon1 wrote:are you going to export with bones? because if not, i will do it
yes, skeleton import is already done

Image

As for animation import, I've never seen that animation importing has been done for any Far Cry game, so i'm doubtful on that. if someone else wants to figure out animations, be my guest.

Edit: mesh now imports too:

Image

No UVs yet. but it's progressing rapidly. Format is like 90% similar to FarCry 4.

Re: Far Cry Primal models

Posted: Fri Jan 20, 2017 7:26 am
by volfin
nearly done. I have model, skeleton, UVs, and multiple materials all working. Bone weights still has a problem I need to work out, but I'll get it done.

Image

As you see though, there's another problem. High rez textures are not being extracted. all of the texture are 128x128 or smaller. I'm wondering if this is because of the block on uncompressed files. High rez textures may not be compressed since the DDS format is already a compressed format.

Image

I'm reading the UV offset and scale directly from the model file. nevertheless there seems to be some slight offset always present. I'll probably just end up hard coding in a correction, since it seems to be the same for every model. Strange though. :o

Re: Far Cry Primal models

Posted: Fri Jan 20, 2017 12:11 pm
by bouvrie
volfin wrote:As you see though, there's another problem. High rez textures are not being extracted. all of the texture are 128x128 or smaller.
Huh? I opened a texture for the Mammoth, and it was def larger than 128x128. Did you open the texture having 'LOD0' in its filename?

Re: Far Cry Primal models

Posted: Fri Jan 20, 2017 12:52 pm
by SoldierTODD
volfin wrote:As for animation import, I've never seen that animation importing has been done for any Far Cry game, so i'm doubtful on that.
Sorry, what then is the use of 3D models of the skeleton, but without the animation?



P.S. Just me 3D model without animation unsuitable.

Re: Far Cry Primal models

Posted: Fri Jan 20, 2017 5:01 pm
by daemon1
volfin wrote:High rez textures are not being extracted. all of the texture are 128x128 or smaller. I'm wondering if this is because of the block on uncompressed files. High rez textures may not be compressed since the DDS format is already a compressed format.
DDS has constant compression rate. So a big red square can still be 1MB in size, and compressing into about 100 bytes with zip or any other compressor. Thats why DDS textures are usually compressed in archives.

Highres textures must be in primal_main_hd_tex file, I didnt check for names for that archive yet.

Re: Far Cry Primal models

Posted: Fri Jan 20, 2017 7:04 pm
by volfin
bouvrie wrote:
volfin wrote:As you see though, there's another problem. High rez textures are not being extracted. all of the texture are 128x128 or smaller.
Huh? I opened a texture for the Mammoth, and it was def larger than 128x128. Did you open the texture having 'LOD0' in its filename?
Ok yes, for the mammoth there are LOD0 files. but for some reason there are none for the tiger:
Image

I guess I picked a bad test choice. But still strange it has none.
SoldierTODD wrote:Sorry, what then is the use of 3D models of the skeleton, but without the animation?
I'm guessing you're new around here, but out of thousands of games that models have been extracted for, I can only think of about 5 that ever had animations extracted as well. The *points* are many reasons, a few of being:
- Collection (XNALara fans)
- reuse (Source Film Maker, Gmod, insertion into other games)
- learning (my personal favorite, I have always been interested in the techniques used to keep poly count down and to achieve various visual effects)
and probably others.

Sure getting animations would be nice. But generally, the work involved in extracting them is far above their value. To me anyway. But as I said, maybe someone else wil tackle this. I saw someone worked out the Metal Gear Solid V animations recently (first time in years I've seen It done I might add.)

Re: Far Cry Primal models

Posted: Fri Jan 20, 2017 7:14 pm
by daemon1
volfin wrote:I saw someone worked out the Metal Gear Solid V animations recently (first time in years I've seen It done I might add.)
Yeah it was me ;)

In 2016 I reversed animations for:

- Overwatch
- the whole Call of Duty series
- Bioshock Infinite Morpheme
- MGSV

I didn't think it was so rare. Difficult formats (such as MGSV) are hard to do, but simple ones must take not much time.

Re: Far Cry Primal models

Posted: Fri Jan 20, 2017 7:44 pm
by volfin
daemon1 wrote:
volfin wrote:I saw someone worked out the Metal Gear Solid V animations recently (first time in years I've seen It done I might add.)
Yeah it was me ;)

In 2016 I reversed animations for:

- Overwatch
- the whole Call of Duty series
- Bioshock Infinite Morpheme
- MGSV

I didn't think it was so rare. Difficult formats (such as MGSV) are hard to do, but simple ones must take not much time.
Nice, I didn't know about some of those.
It is pretty rare. For a long time games were using Havok for animation, so they were stored in HKX files, which were nearly impossible to figure out (nearly). I'm starting to notice publishers are moving away from Havok for animation more. So it may become simpler. And not all have the skills to isolate actual game code to reverse the format, I know I don't. :) All I do is from direct examination of the data itself. And when I examine animation, all I see is an ocean of floats. :lol: