Page 1 of 2

Skeleton files - Star Wars: Ep III - RotS (2005) [XBOX]

Posted: Mon May 25, 2020 12:30 pm
by SilesVyr
Hello, again...on this game, I noticed that in the game files, there is a .ban file in each folder of a character next to the 3d model. I "THINK" these .ban files are the skeletons of the characters but I don't know how to open them. If someone has the talent to examine them, it would be really nice :]
Link (.ban + .msh (3d models)): https://www.mediafire.com/file/xy1ddrqg ... s.rar/file

Thank you

Re: Skeleton files .BAN Star Wars: Ep III - RotS (2005) [XBOX]

Posted: Mon May 25, 2020 1:56 pm
by shakotay2
SilesVyr wrote: Mon May 25, 2020 12:30 pmI "THINK" these .ban files are the skeletons of the characters
Why do you think so? The first 3040 bytes block looks like so:

address 0x0:
66 10 39128 0 752 0 55702 16911 48172 1 24 0 3032 0 3080 0
3128 0 3176 0 3224 0 3272 0 3320 0 3368 0 3416 0 3464 0
3512 0 3560 0 3608 0 3656 0 3704 0 3752 0 3800 0 3848 0
3896 0 3944 0 3992 0 4040 0 4088 0 4136 0 4184 0 4232 0
4280 0 4328 0 4376 0 4424 0 4472 0 4520 0 4568 0 4616 0
4664 0 4712 0 4760 0 4808 0 4856 0 4904 0 4952 0 5000 0
...
address 0xa00:
33464 0 33512 0 33560 0 33608 0 33656 0 33704 0 33752 0 33800 0
33848 0 33896 0 33944 0 33992 0 34040 0 34088 0 34136 0 34184 0
34232 0 34280 0 34328 0 34376 0 34424 0 34472 0 34520 0 34568 0
34616 0 34664 0 34712 0 34760 0 34808 0 34856 0 34904 0 34952 0
35000 0 35048 0 35096 0 35144 0 35192 0 35240 0 35288 0 35336 0
35384 0 35432 0 35480 0 35528 0 35576 0 35624 0 35672 0 35720 0
35768 0 35816 0 35864 0 35912 0 35960 0 36008 0 36056 0 36104 0
36152 0 36200 0 36248 0 36296 0 36344 0 36392 0 36440 0 36488 0
36536 0 36584 0 36632 0 36680 0 36728 0 36776 0 36824 0 36872 0
36920 0 36968 0 37016 0 37064 0 37112 0 37160 0 37208 0 37256 0
37304 0 37352 0 37400 0 37448 0 37496 0 37544 0 37592 0 37640 0
37688 0 37736 0 37784 0 37832 0 37880 0 37928 0 37976 0 38024 0
38072 0 38120 0 38168 0 38216 0 38264 0 38312 0 38360 0 38408 0
38456 0 38504 0 38552 0 38600 0 38648 0 38696 0 38744 0 38792 0
38840 0 38888 0 38936 0 38984 0 39032 0 39080 0 20544 351 16146 0

Then follow blocks with many identical bytes. I don't see how to get valuable information/skeleton data (?) from the bytes with blue underlinings:
.
ban file_.png

Re: Skeleton files .BAN Star Wars: Ep III - RotS (2005) [XBOX]

Posted: Mon May 25, 2020 4:47 pm
by Bigchillghost
There're 752 offsets followed by the same amount of entries with the same stride 0x30 in the ban file. 752 bones for one model would sound insane for a 2005 game.
Obviously the bones are in the same file as the model.
anakinhooddown.gif

Re: Skeleton files .BAN Star Wars: Ep III - RotS (2005) [XBOX]

Posted: Mon May 25, 2020 6:16 pm
by Bigchillghost
Loading the skeleton via Noesis and the model via AMR:
anakinhooddown.jpg

Noesis code for this file:

Code: Select all

def noepyLoadModel(data, mdlList):
	bs = NoeBitStream(data)
	bs.seek(0x1A4A0, NOESEEK_ABS)
	boneCount = bs.readUInt()
	bones = []
	for i in range(0, boneCount):
		pos = bs.tell() + 0x20
		boneName = bs.readString()
		bs.seek(pos, NOESEEK_ABS)
		boneMat = NoeMat43.fromBytes(bs.readBytes(48)).transpose().inverse()
		bonePIndex = bs.readShort()
		bones.append(NoeBone(i, boneName, boneMat, None, bonePIndex))
	
	mdl = NoeModel()
	mdl.setBones(bones)
	mdlList.append(mdl)
	return 1

Re: Skeleton files .BAN ? Star Wars: Ep III - RotS (2005) [XBOX]

Posted: Mon May 25, 2020 7:16 pm
by SilesVyr
It's awesome! So by examining the animation files .bnm you think it could work?

Links: https://www.mediafire.com/file/khctmops ... s.rar/file

Re: Skeleton files .BAN ? Star Wars: Ep III - RotS (2005) [XBOX]

Posted: Tue May 26, 2020 3:23 pm
by Bigchillghost
Thing is, I don't deal with animation data.

Re: Skeleton files .BAN ? Star Wars: Ep III - RotS (2005) [XBOX]

Posted: Tue May 26, 2020 4:18 pm
by SilesVyr
Thing is, I don't deal with animation data.
okay that's not a problem. Just how did you find the skeleton? I will do the same thing for the other characters

Re: Skeleton files .BAN ? Star Wars: Ep III - RotS (2005) [XBOX]

Posted: Thu May 28, 2020 6:01 pm
by Bigchillghost
Here's a Noesis script that'll import the meshes and the skeletons from the msh samples you uploaded.

Re: Skeleton files .BAN ? Star Wars: Ep III - RotS (2005) [XBOX]

Posted: Thu May 28, 2020 8:35 pm
by SilesVyr
Here's a Noesis script that'll import the meshes and the skeletons from the msh samples you uploaded. Bone weights are not handled yet.
Thank you so much! :]

edit: here are .msh files that don't work, thank you for your time and attention :)
link: https://www.mediafire.com/file/394rxlqg ... t.rar/file

Re: Skeleton files .BAN ? Star Wars: Ep III - RotS (2005) [XBOX]

Posted: Fri May 29, 2020 5:50 pm
by Bigchillghost
Script updated at the same post.

Re: Skeleton files .BAN ? Star Wars: Ep III - RotS (2005) [XBOX]

Posted: Fri May 29, 2020 6:20 pm
by SilesVyr
Awesome! :D

Re: Skeleton files .BAN ? Star Wars: Ep III - RotS (2005) [XBOX]

Posted: Sat Jul 11, 2020 6:00 pm
by SilesVyr
Hello!,
there are some .msh that bug or don't work with the plugin. There are also .msh levels files which have a lot of 3d models (small).

I also have a question, is the rigging information for the characters in the .msh files?

Thank you again! :)

Samples: https://www.mediafire.com/file/dy622tp9 ... 2.rar/file

Re: Skeleton files .BAN ? Star Wars: Ep III - RotS (2005) [XBOX]

Posted: Mon Jul 13, 2020 6:16 am
by Bigchillghost
SilesVyr wrote: Sat Jul 11, 2020 6:00 pm I also have a question, is the rigging information for the characters in the .msh files?
Of course, they just weren't handled back then though.
SilesVyr wrote: Sat Jul 11, 2020 6:00 pm there are some .msh that bug or don't work with the plugin. There are also .msh levels files which have a lot of 3d models (small).
Script updated at the same post. Skin info is supported now.
weightTest.png
Tested on all samples found in this thread up to now and everything works fine.

Re: Skeleton files .BAN ? Star Wars: Ep III - RotS (2005) [XBOX]

Posted: Mon Jul 13, 2020 10:11 am
by SilesVyr
Thank you so much, levels files work very well! (just maybe 1 or 2 missing polygon, but it can be fixed by hand)
There are just the last .msh files that do not work: (hope it will not create other bug :mrgreen: )
https://www.mediafire.com/file/zj15gryz ... t.rar/file

Thank you again! :D

Re: Skeleton files .BAN ? Star Wars: Ep III - RotS (2005) [XBOX]

Posted: Mon Jul 13, 2020 11:41 am
by Bigchillghost
SilesVyr wrote: Mon Jul 13, 2020 10:11 am levels files work very well! (just maybe 1 or 2 missing polygon, but it can be fixed by hand)
The script now handles triangle/triangle strip encoding correctly so it's unlikely to miss anything.
SilesVyr wrote: Mon Jul 13, 2020 10:11 am There are just the last .msh files that do not work: (hope it will not create other bug :mrgreen: )
Patch done.