[FF7] Scene.bin Lookup Table updater

  • Thread starter Thread starter kruci
  • Start date Start date
Status
Not open for further replies.
K

kruci

Guest
Here program witch I made, becouse we needed it.

What it does:
Update Scene.bin Lookup table in unpacked 3rd file of kernel.bin. Update is based on header data from scene.bin

Why it does it:
if you change scene.bin, headers can differ. You can see mosters in bad places, other monster instead boss,.... So Lookup table is not actual to current scene.bin. It need update.

What it need:
Scene.bin
unapcked 3rd file of kernel.bin

How to use:
ff7StoK [Scene.bin] [unpacked 3rd file of kernel.bin]
default file names are scene.bin and kernel.bin2
it doesnt care if that are not right files

example:
ff7StoK
;try open files scene.bin and kernel.bin2, if found, update kernel.bin2 based on data in scene.bin

ff7StoK SOMEfilename
;try open files SOMEfilename and kernel.bin2, if found, update kernel.bin2 based on data in SOMEfilename

ff7StoK SOMEfilename SomeFilename2
;try open files SOMEfilename and SomeFilename2, if found, update SomeFilename2 based on data in SOMEfilename

output:
none if succesfull
some error message if error.

bugs:
currently none

Where:
here http://kruci.wz.cz/ff7stok.7z
or zip here http://kruci.wz.cz/ff7stok.zip

Tech info:
https://www.ff7catalog.com/posts/50719/
https://www.ff7catalog.com/posts/56789/

technical update:
in original scene.bin last block has 11files
in original 3rd file of kernel.bin is for last block F5h-FFh
but this mean according to links above FF minus F5=10files or F5 to FE files (10files)
(FF minus 0 = 255files, files from 0 to FE = 255files, but scene.bin has 256files)
so last is FFh instead of "100h".

last file of scene.bin(256th file) contain only FFh chars.(5,251-256 are same)


I can release source code too, if anyone wants, but this program is simply.
 
Last edited:
Hi, thank you so much, but, can you explain to me on how to use that?

I tryied with the command promt and I just can't get how to use it,
my PC doesn't even recognize the extension (me too xDD) or something @_@

Pleaseee! Thank youu! ^^U
 
ah do you think ff7stock.7z?
7z is archive which you need uncompress www.7-zip.org.
I wanted give it to zip archive, but accidently I used 7z, so now is there zip too.
 
Last edited:
I still can't do a thing, And the "zip" is the same as the other file @_@

Or maybe I'm so silly XD
 
I still can't do a thing, And the "zip" is the same as the other file @_@
7z, and zip are compressed files, so you must unpack them to get files inside.
 
I tried to run your program, kruci.

First let me just explain a little better to other potential users how to run it because your instructions, with all due respect, are very hard to understand.

The user can simply unzip the .EXE file (ff7StoK.exe) in the main FF7 directory. Then copy paste the modified Scene.bin and the original kernel.bin (ambiguous here: you wrote "kernel.bin2" which does not exist but I guess you meant "kernel.bin" instead? I am asking because there is also a kernel2.bin making things all the more confusing) to the same directory.

The copied kernel.bin will need to have the "Read Only" tag unchecked by right clicking on it and choosing "Properties".

Then from the Command window, you will write:"ff7StoK.exe scene.bin kernel.bin"

I did that and the program patched the kernel.bin without any error message.

The problem is that as I run the game, the computer just locks forcing me to a hard reboot.

Please, kruci, could you just try and make my  Scene.bin work on your installation?

I would be very greateful if you could test it for me since from my side I seem I can't make it work right.

If you could do this favour to me, please just tell me and I will send you a PM with the link to my modified SCENE.BIN

Thanks a lot!
 
I think you were suppose to mantually extract the 3rd file and then decompress it.    After wards you run the program using the scene.bin and the uncompressed file 3. 

I ran the program this way and it didn't change a single thing on my file so i'm guessing my scene file didn't grow in size or cause any programve after small amounts of tweaking.
 
Oh okay, then it's even more complicated than I thought. How do I extract the third file of the Kernel.bin?
 
recreate scene.bin with Sceneexplorer
recreate kernel.bin with ff7dec(extract, update third file)
ff7dec here https://www.ff7catalog.com/threads/4091/

and ff7dec need fix...
you must get gunzip (there is not gunzip, but gzip renamed to gunzip)
or create bat file
gunzip.bat
containing
gzip -d %1 %2
this will work as gunzip, but of course there must be gzip. And of course you must delete/rename gunzip.exe.
 
Last edited:
ff7dec is bin file extractor(gzip bin files), so it should extract all those types. And I think that kernel.bin is same on PC and PSX version.
 
how to create updated kernel.bin

you need scene.bin
you need unpacked 3rd file of kernel.bin, usualy named kernel.bin2

if you have those two files, you only need run ff7stok, no need of parameters(if you dont rename scene.bin or kernel.bin2)


how to get kernel.bin2

get ff7dec
here: http://lasyan3.free.fr/otherstools/ff7_gzip.zip
or here: http://spinningcone.com/ff/stormmedia/projects/ff7_gzip.zip
(topic how decompile kernel.bin https://www.ff7catalog.com/threads/4091/)

BUT FF7dec has error. This error is gunzip, gunzip there dont unpack, unless parameter -d is given.
So get gunzip. Or create gunzip.bat.

Creating gunzip.bat
(delete or rename gunzip.exe)
create gunzip.bat (create empty file, rename to gunzip.bat)
edit gunzip.bat and give there: gzip -d %1 %2
Code: [Select]
Code:
gzip -d %1 %2
save gunzip.bat

(or create TXT file, then rename,...)

how to decompile kernel.bin
(topic how decompile kernel.bin https://www.ff7catalog.com/threads/4091/)
its comand line program
Use this command to decompile kernel.bin:
Code: [Select]
Code:
ff7dec d kernel.bin
(or create BAT file, similar way as above, only give ff7dec d kernel.bin to file(example kerneldecompile.bat), save)
now in same directory as kenrle.bin should be files, kernel.bin0, kernel.bin1, kernel.bin2, ...

how to compile
Use this command to compile kernel.bin:
Code: [Select]
Code:
ff7dec e kernel.bin
(or create BAT file, similar way as above, only give ff7dec d kernel.bin to file(kernelcompile.bat), save)


Quick review, if you created BAT files, and you have scene.bin and kernel.bin, and followed way above:
Run kerneldecompile.bat
Run FF7stok.exe
Run kernelcompile.bat

or of course create BAT file with
Code: [Select]
Code:
kerneldecompile.batFF7stok.exekernelcompile.bat
and run only this bat file...
 
oops i downloaded that but i though it was gzip not dec.

is there a version of this program that will compress all 27 kernel files instead of stopping at 21, so that it can be used for the psx version.

It decompiles perfectly but when compiling it wont compiles kernel.bin21 to 26.
 
Last edited:
ARMs: I have in plans making a generic program to export/import files from GZIP-Bin archives, so it'll do what you want. Stay tuned :).
 
is there a version of this program that will compress all 27 kernel files instead of stopping at 21, so that it can be used for the psx version.

It decompiles perfectly but when compiling it wont compiles kernel.bin21 to 26.
FF7dec
I dont have this problem when using ff7dec on kernel.bin, it looks like it works good, unpack/pack all 27 files.. tested only on PC kernel.bin, changed only part2...
 
Status
Not open for further replies.
Back
Top