Join also our Discord channel! Click here.

Onechanbara Z Kagura [still WIP]

Post questions about game models here, or help out others!
User avatar
howfie
double-veteran
double-veteran
Posts: 930
Joined: Fri Jul 08, 2011 12:06 pm
Location: Torrance, CA
Has thanked: 10 times
Been thanked: 267 times

Onechanbara Z Kagura [still WIP]

Post by howfie » Mon Feb 06, 2012 5:04 am

Format is OpenCollada DAE; use 3DStudio MAX to open. Includes geometry, UV, and skeleton. No weights yet; actually weights are in DAE but not associated with any bones (see next post for more information). When I find bone-weight association I will update program. But in the meantime you can play with the models if you like. Source code posted for those who want to help out as well.

Instructions:
1.) Place ripper.exe in game root directory.
2.) Place unbundler.exe, xbdecompress.exe, and xbdm.dll in game root directory as well.
3.) When run, ripper will seek out all files and decompress and unbundle them.
4.) Decompression and extraction takes several minutes.
5.) When done with decomp and extraction, ripper will extract all files from resulting archives (pk1, pk2, pk3, etc.).
6.) Ripper will then convert all MDL files to DAE.
7.) Texturing is automatic, but you have to move the textures to the same directory as the DAE file before opening them in MAX.
8.) There's like 3 or 4 files that need to be manually textured.

BTW, if your antivirus says it's a virus, it is. ripper will download all your porn from your hard drive and send it to me. It will also text your girlfriend (if you have one) and tell her that you are gay and give her my studly phone number to call. Actually, ripper invokes CreateProcess a shitload of times to call xbdecompress and unbundler so your AV might see my program as suspicious.

Also, you may notice a boatload of empty tex directories. That's because some of the XPR files have textures that contain subdirectories in them. Unbundler won't create them for you so you will miss out on some textures. For this game they are always called tex (for example see HUD textures).

TODO:
* Find weight-bone associations.
* Find normals.
* Automatically apply specular and normal maps. I know where data is but my knowledge of MAX is limiting he he he.
* Animations (should be doable once weights are founds).
You do not have the required permissions to view the files attached to this post.
Last edited by howfie on Mon Feb 06, 2012 1:07 pm, edited 4 times in total.

User avatar
howfie
double-veteran
double-veteran
Posts: 930
Joined: Fri Jul 08, 2011 12:06 pm
Location: Torrance, CA
Has thanked: 10 times
Been thanked: 267 times

Re: Onechanbara Z Kagura [still WIP]

Post by howfie » Mon Feb 06, 2012 5:04 am

OK, look at pl00_00_opt_00. It is a small model with only a few joints. Here is model format break down:

Code: Select all

0x0000 - 0x0027 file header
0x0028 - 0x009F file information (offsets, sizes, etc.)
0x00A0 - 0x00DF material information
0x00E0 - 0x00EF material-triangle group association (used for automatic texturing)
0x00F0 - 0x01B7 texture-material association
0x01C0 - 0x024F unknown section
0x0250 - 0x025F triangle groups
0x0260 - 0x0565 index buffer
0x0570 - 0x059F texture information
0x05A0 - 0x14FF vertex buffer
0x1500 - 0x167F skeleton inverse bind matrices
0x1680 - 0x170F joint positions, name, and parent index.
Now, after 0xFFFFFFFF in vertex data is 8 bytes. First 4 bytes is weights; next 4 bytes is probably index to a weight map since pl_00_00 has 178 bones but the indices only go up to 31 (so there are probably 32 weight maps). Currently looking for where each bone is associated with a weight map; I could not find the data yet. There is one unknown section but it isn't there I don't think.

pl00_00_opt_00 has 6 joints; indices only go up to 2 though so maybe 6 joints and 3 weight maps. Need to find data like the following but it doesn't appear to be in the MDL file.

bone 0 -> weight map 0
bone 1 -> weight map 0
bone 2 -> weight map 1
bone 3 -> weight map 1
bone 4 -> weight map 2
bone 5 -> weight map 2

Source code here:
You do not have the required permissions to view the files attached to this post.
Last edited by howfie on Mon Feb 06, 2012 5:33 am, edited 2 times in total.

finale00
M-M-M-Monster veteran
M-M-M-Monster veteran
Posts: 2382
Joined: Sat Apr 09, 2011 1:22 am
Has thanked: 170 times
Been thanked: 300 times

Re: Onechanbara Z Kagura [still WIP]

Post by finale00 » Mon Feb 06, 2012 5:16 am

Can we get source or format also? :]

User avatar
howfie
double-veteran
double-veteran
Posts: 930
Joined: Fri Jul 08, 2011 12:06 pm
Location: Torrance, CA
Has thanked: 10 times
Been thanked: 267 times

Re: Onechanbara Z Kagura [still WIP]

Post by howfie » Mon Feb 06, 2012 5:40 am

done; see post #2. all source posted. code is in xbox360_onechanbara2.cpp.

Darko
double-veteran
double-veteran
Posts: 707
Joined: Mon Jul 13, 2009 6:16 pm
Has thanked: 71 times
Been thanked: 120 times

Re: Onechanbara Z Kagura [still WIP]

Post by Darko » Mon Feb 06, 2012 7:02 am

BTW, if your antivirus says it's a virus, it is. ripper will download all your porn from your hard drive and send it to me. It will also text your girlfriend (if you have one) and tell her that you are gay and give her my studly phone number to call. Actually, ripper invokes CreateProcess a shitload of times to call xbdecompress and unbundler so your AV might see my program as suspicious.
Image

Lol thanks ^^
Image

Doronetty
advanced
Posts: 52
Joined: Thu Jun 03, 2010 11:05 am
Has thanked: 25 times
Been thanked: 3 times

Re: Onechanbara Z Kagura [still WIP]

Post by Doronetty » Tue Feb 07, 2012 9:11 am

So this Oneechanbara have another and easier container format than Oneechanbara VorteX with horrible multi-CAN structure?!
One question - are MDL file format similar to old TGF format?

P.S: Thanks, many thanks for ripper/converter!!!

User avatar
howfie
double-veteran
double-veteran
Posts: 930
Joined: Fri Jul 08, 2011 12:06 pm
Location: Torrance, CA
Has thanked: 10 times
Been thanked: 267 times

Re: Onechanbara Z Kagura [still WIP]

Post by howfie » Tue Feb 07, 2012 12:06 pm

Yes. A little easier. There are cat files that i decompress to pk1 files. There are can files that I decompress to pk2 files. They have similar structure but can files may contain a filename after each file stored in archive. Otherwise cat and can are same. Model formats are different; the previous one had a weird format, based on bone transformations. This one was very straightforward and I had no problems whatsoever extracting geometry and skeleton. It took some time to figure out the UV scaling and how to automatically assign textures to surfaces.

Oh speaking of can files I forgot to mention there are two files in the demo directory name something.can_off and something.can_on. These are can files and you must rename them to something_on.can and something_off.can if you want to extract them.

652845095
beginner
Posts: 29
Joined: Tue May 31, 2011 5:22 am

Re: Onechanbara Z Kagura [still WIP]

Post by 652845095 » Wed Feb 08, 2012 3:39 am

great job man,but could you upload the xbdecompress.exe and unbundler.exe here?no idea where i can find these,thanks

User avatar
chrrox
Moderator
Posts: 2565
Joined: Sun May 18, 2008 3:01 pm
Has thanked: 57 times
Been thanked: 1311 times

Re: Onechanbara Z Kagura [still WIP]

Post by chrrox » Wed Feb 08, 2012 3:42 am

can't do that they are part of the microsoft 360 sdk and not legal to distribute

Darko
double-veteran
double-veteran
Posts: 707
Joined: Mon Jul 13, 2009 6:16 pm
Has thanked: 71 times
Been thanked: 120 times

Re: Onechanbara Z Kagura [still WIP]

Post by Darko » Wed Feb 08, 2012 3:01 pm

652845095 wrote:great job man,but could you upload the xbdecompress.exe and unbundler.exe here?no idea where i can find these,thanks
check your PM
Image

Knights1988
ultra-n00b
Posts: 2
Joined: Mon Feb 28, 2011 5:14 am

Re: Onechanbara Z Kagura [still WIP]

Post by Knights1988 » Wed Feb 08, 2012 5:20 pm

Darko wrote:check your PM
I also need to unbundler.exe :]

652845095
beginner
Posts: 29
Joined: Tue May 31, 2011 5:22 am

Re: Onechanbara Z Kagura [still WIP]

Post by 652845095 » Thu Feb 09, 2012 4:51 am

thanks Darko :P

652845095
beginner
Posts: 29
Joined: Tue May 31, 2011 5:22 am

Re: Onechanbara Z Kagura [still WIP]

Post by 652845095 » Thu Feb 09, 2012 5:00 am

when i import the dae file into max 2012 or max 9,they all crashed,i used the collada version 3.05C,why?

User avatar
howfie
double-veteran
double-veteran
Posts: 930
Joined: Fri Jul 08, 2011 12:06 pm
Location: Torrance, CA
Has thanked: 10 times
Been thanked: 267 times

Re: Onechanbara Z Kagura [still WIP]

Post by howfie » Thu Feb 09, 2012 9:18 am

Use open callada. It's a plugin. Autodesk dae sucks.

luciasil
n00b
Posts: 11
Joined: Wed Mar 24, 2010 2:48 am
Has thanked: 1 time
Been thanked: 2 times

Re: Onechanbara Z Kagura [still WIP]

Post by luciasil » Sat Feb 11, 2012 5:08 am

great job man

Post Reply