The rules have been updated, read them now: Rules!

[REQUEST] Transformers 2004 .VBIN and . ITF (PS2)

Post questions about game models here, or help out others!
User avatar
flarespire
veteran
Posts: 99
Joined: Sun Jul 24, 2011 12:30 am
Has thanked: 5 times
Been thanked: 3 times

[REQUEST] Transformers 2004 .VBIN and . ITF (PS2)

Post by flarespire » Sun May 26, 2013 1:08 pm

OK so from my own knowledge, i have been able to determine the possible options on what each of these file types are, the .VBIN most likely contains mesh and rigging data, as there is a quickbms script (found at http://ps23dformat.wikispaces.com/How+To+Extract+Models ), that allows you to convert the level geometry (GEOMETRY.MESH.VBIN) into several, kind of messed up .3ds files, however the current quickbms script only supports the .mesh.vbin files which only usualy includes the level geometry and not NPC's enemies or others gameplay 3d assets. The .ITF files are most likely texture files, as in the games files, there are a set of these after a .vbin, for example, JETSNIPER.VBIN would then be followed by several .ITF file like JETWING.ITF etc...

I have included two sample files for people to look at, but if more are needed and you own the game, the files TFA.ZIP and TFA2.ZIP can be opened in any archiving software and extracted, these contain all the relevant files for analysis.

Sample Files:
.VBIN: http://www.mediafire.com/download/ah4ll ... NIPER.VBIN
.ITF: http://www.mediafire.com/download/f0jb7 ... S_WING.ITF

I do hope someone picks this request up soon as I have done all i can with these files and i really want to see what they contain and if they are useable/convertable to a useable format.

User avatar
flarespire
veteran
Posts: 99
Joined: Sun Jul 24, 2011 12:30 am
Has thanked: 5 times
Been thanked: 3 times

Re: [REQUEST] Transformers 2004 .VBIN and . ITF (PS2)

Post by flarespire » Sun Jun 09, 2013 5:06 pm

Would someone kindly pick this up soon-ish? these formats have bee driving me mad and ive come no closer to an answer on how to convert/view em :(

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

Re: [REQUEST] Transformers 2004 .VBIN and . ITF (PS2)

Post by chrrox » Sun Jun 09, 2013 6:07 pm

have you attempted to convert them?
there is plain text labeling the parts of the file.
~PositionArray
this is followed by a series of floats.
then there is also
~IndexArray
followed by what looks to be faces.
would be a good learning experience for you try some of the tutorials in the tutorial section.

User avatar
flarespire
veteran
Posts: 99
Joined: Sun Jul 24, 2011 12:30 am
Has thanked: 5 times
Been thanked: 3 times

Re: [REQUEST] Transformers 2004 .VBIN and . ITF (PS2)

Post by flarespire » Sun Jun 09, 2013 6:54 pm

I have tried but my current knowledge of output formats is very limited, so the files i had output would cause errors in 3ds max and be essentially useless.
I need to do some more reading on how this works to better understand the process before I attempt it again, hence my asking on the forums if anyone can have a crack at it.

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

Re: [REQUEST] Transformers 2004 .VBIN and . ITF (PS2)

Post by chrrox » Sun Jun 09, 2013 6:57 pm


User avatar
flarespire
veteran
Posts: 99
Joined: Sun Jul 24, 2011 12:30 am
Has thanked: 5 times
Been thanked: 3 times

Re: [REQUEST] Transformers 2004 .VBIN and . ITF (PS2)

Post by flarespire » Sun Jun 09, 2013 7:03 pm

Thx for the link, im gonna read through that and attempt it again, but gonna leave this open in-case anyone does try.

User avatar
flarespire
veteran
Posts: 99
Joined: Sun Jul 24, 2011 12:30 am
Has thanked: 5 times
Been thanked: 3 times

Re: [REQUEST] Transformers 2004 .VBIN and . ITF (PS2)

Post by flarespire » Sun Jun 09, 2013 7:43 pm

OK I'm stuck, Ive got noesis to add the file type to its file listing using that tutorial, but I cant get beyond that it still recognizes it as an unknown file type. I dont know what to put as the header or how I should proceed with the script...
Chrrox if you can help me i would really appreciate it, this is what i have so far:

Code: Select all

#Noesis Python model import+export test module, imports/exports some data from/to a made-up format

from inc_noesis import *

import noesis

#rapi methods should only be used during handler callbacks
import rapi

#registerNoesisTypes is called by Noesis to allow the script to register formats.
#Do not implement this function in script files unless you want them to be dedicated format modules!
def registerNoesisTypes():
   handle = noesis.register("Transformers 2004 PS2", ".VBIN")
   noesis.setHandlerTypeCheck(handle, noepyCheckType)
   noesis.setHandlerLoadModel(handle, noepyLoadModel) #see also noepyLoadModelRPG
       #noesis.setHandlerWriteModel(handle, noepyWriteModel)
       #noesis.setHandlerWriteAnim(handle, noepyWriteAnim)
   noesis.logPopup()
       #print("The log can be useful for catching debug prints from preview loads.\nBut don't leave it on when you release your script, or it will probably annoy people.")
   return 1

NOEPY_HEADER = "464953487E5363656E654E6F64650001"

#check if it's this type based on the data
def noepyCheckType(data):
   bs = NoeBitStream(data)
   if len(data) < 16:
      return 0
   if bs.readBytes(16).decode("ASCII").rstrip("\0") != NOEPY_HEADER:
      return 0
   return 1       

#load the model
def noepyLoadModel(data, mdlList):
   ctx = rapi.rpgCreateContext()
   bs = NoeBitStream(data)
   rapi.rpgClearBufferBinds()   
   return 1

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

Re: [REQUEST] Transformers 2004 .VBIN and . ITF (PS2)

Post by chrrox » Sun Jun 09, 2013 7:52 pm

try this

Code: Select all

from inc_noesis import *
import noesis
import rapi

def registerNoesisTypes():
   handle = noesis.register("Transformers 2004 PS2", ".VBIN")
   noesis.setHandlerTypeCheck(handle, t2004CheckType)
   noesis.setHandlerLoadModel(handle, t2004LoadModel) #see also noepyLoadModelRPG
   noesis.logPopup()
   return 1

NOEPY_HEADER = "FISH"

#check if it's this type based on the data
def t2004CheckType(data):
   bs = NoeBitStream(data)
   if len(data) < 16:
      return 0
   if bs.readBytes(4).decode("ASCII").rstrip("\0") != NOEPY_HEADER:
      return 0
   return 1       

#load the model
def t2004LoadModel(data, mdlList):
   ctx = rapi.rpgCreateContext()
   bs = NoeBitStream(data)
   rapi.rpgClearBufferBinds()   
   return 1

User avatar
flarespire
veteran
Posts: 99
Joined: Sun Jul 24, 2011 12:30 am
Has thanked: 5 times
Been thanked: 3 times

Re: [REQUEST] Transformers 2004 .VBIN and . ITF (PS2)

Post by flarespire » Sun Jun 09, 2013 7:57 pm

Thanks Chrrox, that got it to recognise, if i get stuck again, ill ask for your assistance again ok?

User avatar
flarespire
veteran
Posts: 99
Joined: Sun Jul 24, 2011 12:30 am
Has thanked: 5 times
Been thanked: 3 times

Re: [REQUEST] Transformers 2004 .VBIN and . ITF (PS2)

Post by flarespire » Sun Jun 09, 2013 8:09 pm

How does this look? this is all still pretty new to me, so its gonna take me time to get used to.

Code: Select all

from inc_noesis import *
import noesis
import rapi

def registerNoesisTypes():
   handle = noesis.register("Transformers 2004 PS2", ".VBIN")
   noesis.setHandlerTypeCheck(handle, t2004CheckType)
   noesis.setHandlerLoadModel(handle, t2004LoadModel) #see also noepyLoadModelRPG
   noesis.logPopup()
   return 1

NOEPY_HEADER = "FISH"

#check if it's this type based on the data
def t2004CheckType(data):
   bs = NoeBitStream(data)
   if len(data) < 16:
      return 0
   if bs.readBytes(4).decode("ASCII").rstrip("\0") != NOEPY_HEADER:
      return 0
   return 1       

#load the model
def t2004LoadModel(data, mdlList):
   ctx = rapi.rpgCreateContext()
   bs = NoeBitStream(data)
   rapi.rpgClearBufferBinds()   
   return 1
   
   #load the model
def noepyLoadModel(data, mdlList):
   ctx = rapi.rpgCreateContext()
   bs = NoeBitStream(data)
   bs.seek(0x1C, NOESEEK_ABS) #Seek to header info
   hdrInfo = bs.read("iii")
   print(hdrInfo)
   bs.seek(0x32C, NOESEEK_REL) #Seek past junk
   VCount = bs.read("i")
   bs.seek(0x5AB4C, NOESEEK_REL) #Seek past junk
   FCount = bs.read("i")
   bs.seek(0x5AD44, NOESEEK_ABS) #Seek to File Start
   TexNames = []
   for i in range(0, hdrInfo[0]):
      TexNames.append (bs.readBytes(40).decode("ASCII").rstrip("\0"))
   print(TexNames)
   rapi.rpgClearBufferBinds()   
   return 1

User avatar
flarespire
veteran
Posts: 99
Joined: Sun Jul 24, 2011 12:30 am
Has thanked: 5 times
Been thanked: 3 times

Re: [REQUEST] Transformers 2004 .VBIN and . ITF (PS2)

Post by flarespire » Sun Jun 09, 2013 9:09 pm

Well, im at an impass, im not sure how to set the different addresses for the next part of the script up, as the .VBIN format is a little weird. Chrrox, if you could take a look it would really help me out and i may be able to understand what to do in the future.

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

Re: [REQUEST] Transformers 2004 .VBIN and . ITF (PS2)

Post by chrrox » Sun Jun 09, 2013 9:17 pm

need more samples.

User avatar
flarespire
veteran
Posts: 99
Joined: Sun Jul 24, 2011 12:30 am
Has thanked: 5 times
Been thanked: 3 times

Re: [REQUEST] Transformers 2004 .VBIN and . ITF (PS2)

Post by flarespire » Sun Jun 09, 2013 9:30 pm

chrrox wrote:need more samples.
ill send you the .ZIP's from the disc in a pm, the models are under the "ANIMATION" folder (extract both to the same dir)

User avatar
flarespire
veteran
Posts: 99
Joined: Sun Jul 24, 2011 12:30 am
Has thanked: 5 times
Been thanked: 3 times

Re: [REQUEST] Transformers 2004 .VBIN and . ITF (PS2)

Post by flarespire » Mon Jun 10, 2013 4:58 pm

In-case anyone else wants to take a crack at this, here is the BMS script to extract TFA.ZIP and TFA2.ZIP

Code: Select all

ComType deflate
Math test = 0 ;
GoTo 0x0 0 ;
SavePos base 0 ;
Do ;
GoTo base 0 ;
Get test Long 0 ;
If test = 101010256 ;
CleanExit ;
EndIF ;
GoTo base 0 ;
GoTo 0xA 0 SEEK_CUR ;
Get c Byte 0 ;
GoTo base 0 ;
GoTo 0x1C 0 SEEK_CUR ;
Get namelength Long 0 ;
GoTo base 0 ;
GoTo 0x2A 0 SEEK_CUR ;
Get toffset Long 0 ;
GetDString name namelength 0 ;
SavePos base 0 ;
GoTo toffset 0 ;
GoTo 0x12 0 SEEK_CUR ;
Get zsize Long 0 ;
Get size Long 0 ;
Get nz Short 0 ;
GoTo toffset 0 ;
GoTo 0x1E 0 SEEK_CUR ;
GoTo nz 0 SEEK_CUR ;
SavePos offset 0 ;
If c = 8 ;
CLOG name offset zsize size 0 ;
Else ;
Log name offset size 0 ;
EndIF ;
While test != 101010256 ;




If you want to get a hold of TFA.ZIP and TFA2.ZIP pm me OR copy it from the game disc/iso yourselves.
IMPORTANT: be sure to extract both files to the same directory!

User avatar
flarespire
veteran
Posts: 99
Joined: Sun Jul 24, 2011 12:30 am
Has thanked: 5 times
Been thanked: 3 times

Re: [REQUEST] Transformers 2004 .VBIN and . ITF (PS2)

Post by flarespire » Tue Jun 11, 2013 8:21 pm

Chrrox have you had any luck getting the offsets set up? I've tried numerous time and I haven't made any progress yet...

Post Reply