The VG Resource

Full Version: Breath of fire IV Model and Texture Extraction help wanted [file and script included]
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hi Guys.

Using the following script from Xentax that was made a few years back I was able to extract no-name files (no file extensions either) from an emi file.

Here is a link to the emi file and to the files extracted from it.

https://mega.nz/#F!RxNSQACC!hG4142CrfNfyD7n52HZhcQ

Here is the mex/quickbms script.

Code:
# MexScript for EMI files from Breath Of Fire 4
# By Mr.Mouse
# ----------------------------
# First get the Number of files (FN)
ImpType SFileSize ;
Get FN Long 0 ;
Get U1 Long 0 ;
GetDString ID 8 0 ;
# The ID string is "MATH_LAB"
# Very well, now prepare some padding calculations
# Each data stream (data section) is padded up to
# 0x800 blocks.
Set B Long 2048 ;
Set A Long FN ;
Math A *= 16 ;
Math A += 16 ;
Set C Long A ;
Math C /= B ;
Math C *= 2048 ;
Math C += 2048 ;
Set Off Long C ;
# Good, now we have calculated the Offset of the
# first file. Let's start reading the file info for each file
# in the archive!
For T = 1 To FN ;
SavePos FSO 0 ;
Get FS Long 0 ;
Get U2 Long 0 ;
Get ID2 Long 0 ;
Get U3 Int 0 ;
Get END Int 0 ;
Log "" Off FS 0 FSO ;
# Need to perform padding calculations to get to the
# offset of the next file (if any)
Math FS /= 2048 ;
Math FS *= 2048 ;
Math FS += 2048 ;
Math Off += FS ;
Next T ;
# There! That did the trick!


Its an old script and I'm not good at this sort of thing, so there might be a way to get file extensions and filenames that I don't know of.

I tried PSXPrev on the files, and it says its found 3 models but nothing shows up, and it says there are a few textures, but they're just kind of junk and swizzled, so things might still be a bit compressed.

I'd really appreciate if someone could help take this apart, I really want to extract the 3D models and textures for the environments and then retexture them with more modern textures for fun.

Thankyou to anyone who can help.