PSF builder python script ? by Squaresoft74 at 10:54 PM EDT on September 12, 2018
Hello,
This one is mainly for Nisto if ever willing to help.

Could you make/share a python script that would automatically build PSF files by simply dropping a folder that would contain a "Driver.exe" , Bgmxxx.seq, Bgmxxx.vh and Bgmxxx.vb files.

Something similar to your mkpsf.py from your mgs_psfkit.

That would be very appreciated and a huge time saver since i'm currently assembling everything via PSFLab and that is a long, repetitive and boring process.

Many thanks.
by Nisto at 3:20 PM EDT on September 13, 2018
Can you upload some files? I also need the VH/VB/SEQ addresses.
by Squaresoft74 at 4:02 PM EDT on September 13, 2018
Sure here you go:
http://rgho.st/private/74rKDSWxP/ba667cd75e64740f49984e85eeac5bf4

0x80100000 (SEQ)
0x80120000 (VAB Header)
0x80140000 (VAB Body)

Maybe you could make this section adjustable for other drivers that would use different import addresses ?

It's a proper rip of Pandemonium! using a recycled pQES driver that i patched to match the game's original reverb settings.
(I used no$psx's SPU I/O Map to get the values).

I saw someone attempted to rip that game, using VGMToolbox i guess, but it's not good at all:
http://psf.joshw.info/p/Pandemonium!%20[Magical%20Hoppers]%20(1996-10-31)%20(Toys%20For%20Bob)%20(Crystal%20Dynamics).7z

You might notice that .seq files have a bit of extra (useless) data at their ends that i left on purpose because PSFLab won't properly import them if they're not 32bits multiple in size (Correct me if i'm using the wrong definition, i'm no expert).
Doesn't seem to affect playback but it's just not "clean" to me.

Would be neat if your script could bypass this "requirement" since i like to have proper raw files extracted.

Thank you for your help.
by Nisto at 5:36 PM EDT on September 13, 2018
How's this?

https://gist.github.com/Nisto/181017e480ed2551a66fec4a5f113bb4

Let me know if it needs any improvements.
by Squaresoft74 at 11:10 AM EDT on September 14, 2018
Huge thanks for this script Nisto !
It works perfectly with everything i tried so far.

It will definitely make things faster for my PSF ripping needs and bring back motivation to make some more. :)

Got any mail address where i can contact you ?
by Nisto at 1:33 PM EDT on September 14, 2018
Glad I could help.

You can contact me at:


edited 1:33 PM EDT September 14, 2018
by Squaresoft74 at 11:31 PM EDT on September 24, 2018
As it curently is the script is fine for:
Bmg01.seq, Bmg01.vb, Bmg01.vh -> Bmg01.psf
Bmg02.seq, Bmg02.vb, Bmg02.vh -> Bmg02.psf
etc...

Now in case data are arranged by "pack" where sequences use the same VAB like for example:

Bmg01.vb, Bmg01.vh, X amount of sequences files.
Bmg02.vb, Bmg02.vh, X amount of sequences files.
etc...

I'd like to have them extracted such as:
Bmg01.vb, Bmg01.vh, Bmg01-01.seq, Bmg01-02.seq,Bmg01-03.seq, etc...
Bmg02.vb, Bmg02.vh, Bmg02-01.seq, Bmg02-02.seq,Bmg02-03.seq, etc...
etc...
(i have that part done already).

And from that get the script to build:
Bmg01-01.psf, Bmg01-02.psf,Bmg01-03.psf, etc...
Bmg02-01.psf, Bmg02-02.psf,Bmg02-03.psf, etc...
etc...

Is it possible to add that "feature" and giving you choice to output as .psf or minipsf ?

edited 3:50 AM EDT September 25, 2018
by Nisto at 8:33 PM EDT on September 26, 2018
Here: https://gist.github.com/Nisto/431792c1b645525b9cc60c2fa1b4c532

It's not a work of art by any means, but it gets the job done.

One important note: if you want to make miniPSFs, avoid scattering VH/VB data across the driver/SEQ region. Otherwise you will overwrite the driver/SEQ data, since the data inbetween is zero-filled.

The loading order for miniPSFs looks like this:

1. the PSF specified by the "_lib" tag
2. the minipsf file
3-x. additional libraries

So, being that the minipsf will contain the SEQ data (2), the bank data (3) would overwrite the SEQ data if you had these parameters:

VH address: 0x80100000
SEQ address: 0x80120000
VB address: 0x80140000

This isn't the case for the project you sent me by e-mail, where the SEQ region precedes both the VH and VB regions, so it'll work fine.

This is by design and not a limitation of the script per se.
by Squaresoft74 at 1:57 PM EDT on September 28, 2018
Thank you very much Nisto !
I really appreciate and will make a good use of it.


Go to Page 0

Search this thread

Show all threads

Reply to this thread:

User Name Tags:

bold: [b]bold[/b]
italics: [i]italics[/i]
emphasis: [em]emphasis[/em]
underline: [u]underline[/u]
small: [small]small[/small]
Link: [url=http://www.google.com]Link[/url]

[img=https://www.hcs64.com/images/mm1.png]
Password
Subject
Message

HCS Forum Index
Halley's Comet Software
forum source