Skip to content
View in the app

A better way to browse. Learn more.

ResHax

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.
Help us keep the site running.

Help with bms script creation

Featured Replies

  • Author
  • Localization

Kratos9999, posted Tue Jan 17, 2017 7:37 pm (20266)


Hi everyone, I want to know if someone can tell me what is wrong in this bms script, I have no experience in creation of scripts, this is my first attempt:
#script for fatal frame 2 ps2 img_bd.bin

endian big

get archiveSize long
get fileCount long
get null long
for i = 0 < fileCount
getdstring name 0x8
log NAME OFFSET SIZE
next i

I am trying to make an script to extract the files inside of a archive, here is a link with the sample of archive and some screenshots of my failed attempt in extract the files: https://drive.google.com/file/d/0B24D4L ... p=drivesdk

What is wrong and why the
supposed files extracted in
the image are 0kb in size?
  • Author
  • Localization

aluigi, posted Wed Jan 18, 2017 12:40 pm (20271)


Why don't you use a simple format to make practice with the bms language? :)

Additionally where you got that structure you used in your script? It's completely unrelated with the format, like if it has been copied somewhere else.

What you have there is a raw container and NOT an archive, which means that the information are probably stored in another file.
It's just a sequence of files aligned to 2048 bytes.

In short there is no way to extract data from img_bd.bin itself.

The only script available on my website about this game is the following:
http://aluigi.org/bms/fatal_frame.bms
But I don't know if there is a way to get the files from img_db.bin.
  • Author
  • Localization

Kratos9999, posted Wed Jan 18, 2017 1:07 pm (20272)


I used as base an tutorial for quickbms that I have found in net. You mean that information
can be in a TOC file, I did
not find a toc file for img_
db.bin. Can that TIM3 name
at the beginning of the file
be a header for the tim2
files? I thought so, but I'm
not sure. I tried the script
you posted, but it did not
work
  • Author
  • Localization

Kratos9999, posted Wed Jan 18, 2017 5:59 pm (20276)


Hi aluigi, I made some modifications in my script and got the files in the image, however, I think there is more files inside the img_bd.bin, manys, pss videos, audio files, tim2, and others. But this files don't appear.
I think it was already a
breakthrough I get these
files, do you think I'm too
far from making the script
properly extract all files?
THIS IS the script edited:

#script for fatal frame 2 ps2 img_bd.bin

endian big

get archiveSize long
get FILES long
get fileSize long
get fileCount long
for i = 0 < files
get offset long
get size long
SavePos FILEOFF
log "" OFFSET SIZE
next i
  • Author
  • Localization

aluigi, posted Wed Jan 18, 2017 6:41 pm (20279)


I guess you completely ignored what I wrote.
Oh well, time is yours :)
  • Author
  • Localization

Kratos9999, posted Wed Jan 18, 2017 6:50 pm (20281)


I don't understand, my script is wrong, or there is no way to extract the files?
  • Author
  • Localization

aluigi, posted Wed Jan 18, 2017 7:03 pm (20283)


There is no way to extract the files because there is no index, so your script is wrong because it tries to read fields that don't exist.
  • Author
  • Localization

Kratos9999, posted Wed Jan 18, 2017 7:11 pm (20287)


So must there is a toc file for this img_bd.bin, but it seems that is hidden in game iso, there are some hidden files in iso. It is possible to make an script to extract hidden files in filesystem ISO-9660?
  • Author
  • Localization

aluigi, posted Wed Jan 18, 2017 7:48 pm (20290)


Mah, it looks strange.
Anyway in the Fatal Frame game on which I worked, the filenames were stored in lfm_order.bin and the big archive contained also the TOC.
I have no idea why img_bd.bin is so different.
Guest
This topic is now closed to further replies.

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.