Important information: this site is currently scheduled to go offline indefinitely by December 1st 2023.
If you wish to donate to attempt the preservation of tools and software somewhere else before it goes down, check the GoFundMe

FGDK3 animations and bones (PS2)

Post questions about game models here, or help out others!
Dogmander
advanced
Posts: 49
Joined: Tue Feb 02, 2021 2:03 am
Has thanked: 2 times
Been thanked: 2 times

FGDK3 animations and bones (PS2)

Post by Dogmander »

Hello everyone, I was wondering if anyone would want to take a quick look at this. For a while I've been working on reverse engineering the formats used by Frontier Developments' FGDK3 engine used in some of their older games. Models and textures have been easy to document but animations and bones are still a WIP. Here's what I have to share right now:

* Uses 3x3 Animation Matrice possibly? (mentioned within game's executable)
* Bone names are stored around 0003D3D0 (hex) within sample overlay
* Total size of animations is 155440?
* Animations at 25fps
Also, tool currently used for extraction operations https://github.com/20kdc/Gibbed.FGDK3/tree/armatures (armature branch of fork)
I'm not sure exactly where animation or bones are but I'm assuming they are stored as either a float32 or float64, not sure about the endianness
Image
Image
Thanks in advance!
You do not have the required permissions to view the files attached to this post.
User avatar
shakotay2
MEGAVETERAN
MEGAVETERAN
Posts: 4299
Joined: Fri Apr 20, 2012 9:24 am
Location: Nexus, searching for Jim Kirk
Has thanked: 1152 times
Been thanked: 2250 times

Re: FGDK3 animations and bones (PS2)

Post by shakotay2 »

How did you get the dog? A .dat file is required, the sample you uploaded is named 5.ovl (output from ExportPreload.exe, obviously).

Code: Select all

Gibbed.FGDK3
Usage: Gibbed.FGDK3.ExportPreload [OPTIONS]+ <PRELOAD.DAT> [output_path]

Options:
  -t, --target=VALUE         set target (dogs/zoo)
  -v, --verbose              be verbose
  -h, --help                 show this message and exit
btw: from my experience throwing in an animation data file usually leads to nothing

(Most if not any "working" animation threads start with the mesh, then the skeleton, then weights, then anims. Just my 2 cents.)
The weights part may be skipped in case you're satisfied with a moving skeleton as a first step.
Tuts: a) Bigchillghost, viewtopic.php?f=29&t=17889
b) Extracting simple models: http://forum.xentax.com/viewtopic.php?f=29&t=10894
"Quoting the whole thing. Would u ever stop this nonsense?"
Dogmander
advanced
Posts: 49
Joined: Tue Feb 02, 2021 2:03 am
Has thanked: 2 times
Been thanked: 2 times

Re: FGDK3 animations and bones (PS2)

Post by Dogmander »

The Preload.dat you mentioned comes from the root of the disc, and basically defines where the data in all of the overlays are stored, among other things. I got the dog by providing the program with preload.dat, dogs.dgf, and OVERLAY.zip, all from the root of the game disc. I can provide this files if needed, although I’ll need to upload them externally due to them being too big. The program currently outputs textures, gui text, and models from the overlays into png, txt, and dae/obj respectively. The current version of the program outputs dae while older versions did obj.
Dogmander
advanced
Posts: 49
Joined: Tue Feb 02, 2021 2:03 am
Has thanked: 2 times
Been thanked: 2 times

Re: FGDK3 animations and bones (PS2)

Post by Dogmander »

With the fork I sent in the OP, this one can partially parse bones, with their names and vert groups, although it isn’t complete and has some issues. The major thing is that in its current state it does not do bone positions and all bones are at the root, however vert groups somewhat work and moving the bones will effect some parts of the mesh, although some names are wrong and there is no parent/child layout yet.
Dogmander
advanced
Posts: 49
Joined: Tue Feb 02, 2021 2:03 am
Has thanked: 2 times
Been thanked: 2 times

Re: FGDK3 animations and bones (PS2)

Post by Dogmander »

shakotay2 wrote: Thu Dec 02, 2021 2:12 pm L, then anims. Just my 2 cents.)
The weights part may be skipped in case you're satisfied with a moving skeleton as a first step.
This is probably one of the main goals is to get proper bones position so they can be moved like normal.
Dogmander
advanced
Posts: 49
Joined: Tue Feb 02, 2021 2:03 am
Has thanked: 2 times
Been thanked: 2 times

Re: FGDK3 animations and bones (PS2)

Post by Dogmander »

Update! I've uploaded the files you'll need here. Note that the archive I sent only includes the 5.ovl, and not any of the other overlays in the overlay.zip. If needed, I can provide the full overlay.zip if required.
User avatar
shakotay2
MEGAVETERAN
MEGAVETERAN
Posts: 4299
Joined: Fri Apr 20, 2012 9:24 am
Location: Nexus, searching for Jim Kirk
Has thanked: 1152 times
Been thanked: 2250 times

Re: FGDK3 animations and bones (PS2)

Post by shakotay2 »

Dogmander wrote: Thu Dec 02, 2021 9:26 pmI got the dog by providing the program with preload.dat, dogs.dgf, and OVERLAY.zip
Understand. (So there's no separate "dogs.dat"?)

The "program" is ExportPreload.exe? (Just to be sure. :D )
Dogmander wrote: Thu Dec 02, 2021 9:26 pmThe program currently outputs textures, gui text, and models from the overlays
questions: 1) I still don't understand the workflow of ExportPreload.exe: when this exe creates an .ovl file why is it required to provide it with OVERLAY.zip? :?
2) "models from the overlays"? So there's the dog's model (data) in 5.ovl? (looks to me as if it contained animation data and bone names)
Note that the archive I sent only includes the 5.ovl,
The one from your opening post?
(btw, "https://file.io/cytKZXxxoES0", it says "The file you requested has been deleted".)

preload.dat, dogs.dgf are huge, aren't they?
What I'd need for a start is just the mesh data (and skeleton data) from the dog.
Tuts: a) Bigchillghost, viewtopic.php?f=29&t=17889
b) Extracting simple models: http://forum.xentax.com/viewtopic.php?f=29&t=10894
"Quoting the whole thing. Would u ever stop this nonsense?"
Dogmander
advanced
Posts: 49
Joined: Tue Feb 02, 2021 2:03 am
Has thanked: 2 times
Been thanked: 2 times

Re: FGDK3 animations and bones (PS2)

Post by Dogmander »

shakotay2 wrote: Fri Dec 03, 2021 9:21 am
Dogmander wrote: Thu Dec 02, 2021 9:26 pmI got the dog by providing the program with preload.dat, dogs.dgf, and OVERLAY.zip
Understand. (So there's no separate "dogs.dat"?)

The "program" is ExportPreload.exe? (Just to be sure. :D )
Dogmander wrote: Thu Dec 02, 2021 9:26 pmThe program currently outputs textures, gui text, and models from the overlays
questions: 1) I still don't understand the workflow of ExportPreload.exe: when this exe creates an .ovl file why is it required to provide it with OVERLAY.zip? :?
2) "models from the overlays"? So there's the dog's model (data) in 5.ovl? (looks to me as if it contained animation data and bone names)
Note that the archive I sent only includes the 5.ovl,
The one from your opening post?
(btw, "https://file.io/cytKZXxxoES0", it says "The file you requested has been deleted".)

preload.dat, dogs.dgf are huge, aren't they?
What I'd need for a start is just the mesh data (and skeleton data) from the dog.
Answers to your questions, no, there is no dogs.dat, all games using this engine have the file named that. Yes, the program is named ExportPreload.exe. You are required to provide it in the overlay.zip as normally that is how all the ovl files are stored together on the game disc. Yes, the overlays have model data, even if it isn’t clear apparent when looking at it, as well as other types of game resources. The files aren’t that big, all together they are around 1mb (not including all of the other ovls, only 5.ovl). I’ll send you links to what you’ll need when I’m at my computer, as I’m sending this from my phone.
Dogmander
advanced
Posts: 49
Joined: Tue Feb 02, 2021 2:03 am
Has thanked: 2 times
Been thanked: 2 times

Re: FGDK3 animations and bones (PS2)

Post by Dogmander »

This repo I created a while back has a few useful things that you might want to take a look at. https://github.com/Dogmander/dogs-life-docs
Here are the downloads, I created multiple download sources just incase one of them doesn't work.
https://filebin.net/o4ck4rlezg8ddih2
https://gofile.io/d/KI9wxC
Dogmander
advanced
Posts: 49
Joined: Tue Feb 02, 2021 2:03 am
Has thanked: 2 times
Been thanked: 2 times

Re: FGDK3 animations and bones (PS2)

Post by Dogmander »

Did you send a reply but deleted it? I received a notification saying you posted a reply but I don't see it and when clicking on it, it states it doesn't exist. If you simply weren't ready or something of the likes that's fine.
User avatar
shakotay2
MEGAVETERAN
MEGAVETERAN
Posts: 4299
Joined: Fri Apr 20, 2012 9:24 am
Location: Nexus, searching for Jim Kirk
Has thanked: 1152 times
Been thanked: 2250 times

Re: FGDK3 animations and bones (PS2)

Post by shakotay2 »

yeah, had a problem using parameters for debugging but after dozens of attempts I found this to work:
-tdogs Preload.dat D:\\tmp\\unp

(Will take some time, C# is not my preferred coding language, hopefully I'll get the skeleton at least.)
Tuts: a) Bigchillghost, viewtopic.php?f=29&t=17889
b) Extracting simple models: http://forum.xentax.com/viewtopic.php?f=29&t=10894
"Quoting the whole thing. Would u ever stop this nonsense?"
Dogmander
advanced
Posts: 49
Joined: Tue Feb 02, 2021 2:03 am
Has thanked: 2 times
Been thanked: 2 times

Re: FGDK3 animations and bones (PS2)

Post by Dogmander »

Alright, sounds good. Hope that all is well. :)
User avatar
shakotay2
MEGAVETERAN
MEGAVETERAN
Posts: 4299
Joined: Fri Apr 20, 2012 9:24 am
Location: Nexus, searching for Jim Kirk
Has thanked: 1152 times
Been thanked: 2250 times

Re: FGDK3 animations and bones (PS2)

Post by shakotay2 »

Dogmander wrote: Sat Dec 04, 2021 1:15 am Alright, sounds good. Hope that all is well. :)
Yeah, thanks. Hope all's fine for you, too.

Rick's source code, btw, is written excellently (https://github.com/gibbed/Gibbed.FGDK3).
The parenting of bones seems to be missing, though. So no bones' hierarchy shown in blender.
But since I'm not familiar with the .dae format it's a long way to go.
So far I checked the collection of vertex, weights and face data. Seems to be ok (surprise :D ).

But the .dae files I get from the compiled project are faulty - I have no idea, where my fault could be (only change were some additional Console.WriteLine()):

Code: Select all

          <Name_array id="Armature_m0-skin-joints-array" count="43">
Root
AutoExporterJoint27
AutoExporterJoint10
AutoExporterJoint11
AutoExporterJoint28
AutoExporterJoint43
AutoExporterJoint5
AutoExporterJoint12
AutoExporterJoint20
AutoExporterJoint8
AutoExporterJoint30
AutoExporterJoint31
AutoExporterJoint42
AutoExporterJoint41
AutoExporterJoint40
It's not a matter of the paramters since I get the same error when I drag n' drop PRELOAD.DAT onto the compiled exe file.
.

shape_0_lod0.dae created using the exe from your zip, with correct bone names:

Code: Select all

          <Name_array id="Armature_m0-skin-joints-array" count="64">
_world_
_root_
Between_the_eyes_dummy
Bip01
Bip01_Head
Bip01_L_Calf
Bip01_L_Clavicle
Bip01_L_Finger0
Bip01_L_Foot
Bip01_L_Forearm
Bip01_L_Hand
Bip01_L_Thigh
Bip01_L_Toe0
Bip01_L_UpperArm
Bip01_Neck
...
Last edited by shakotay2 on Mon Dec 06, 2021 10:15 pm, edited 1 time in total.
Tuts: a) Bigchillghost, viewtopic.php?f=29&t=17889
b) Extracting simple models: http://forum.xentax.com/viewtopic.php?f=29&t=10894
"Quoting the whole thing. Would u ever stop this nonsense?"
Dogmander
advanced
Posts: 49
Joined: Tue Feb 02, 2021 2:03 am
Has thanked: 2 times
Been thanked: 2 times

Re: FGDK3 animations and bones (PS2)

Post by Dogmander »

Good to hear back. If need be, you could switch to have it use a different output format, COLLADA was chose as it supported bones (unlike OBJ) and it doesn’t have the format differences that FBX has.
Dogmander
advanced
Posts: 49
Joined: Tue Feb 02, 2021 2:03 am
Has thanked: 2 times
Been thanked: 2 times

Re: FGDK3 animations and bones (PS2)

Post by Dogmander »

Just checking in, what's the haps? I'm still here, thankfully. :)
Post Reply