PSOBB Quest Assembler, Disassembler + Source


Staff member
UPDATE 6/15/2019:

- Fixed a crashing bug with quest_asm when a percent sign is inside of a string of a PASM script.
- Fixed a disassembly bug with quest_disasm when arguments are register values but the argument type isn't defined as a register in the asm.txt file (First seen in Gallon's Shop "particle2" command.)

UPDATE 5/23/2019

Updated again 5/23/2019 to fix a spacing issue when a function definition had a command after a "TAB" for quest_asm. Also fixed detection of HEX and STR functions when they're pushed as ARGS for quest_disasm.

Updated again 5/12/2019 to fix bug with STR and HEX with quest_asm.

OK, now the assembler and disassembler output and processing has been done again.

Now the disassembler exports .pasm files that can be directly imported into Qedit. (It also fixes the problem with va_start and va_end arguments not being written to the .pasm file.)

Also, the assembler will import .pasm files that are spaced as Qedit spaces them. (Though it's still less picky about spacing compared to Qedit.)

When the disassembler is ran, a file with the extension .pasm.header is also created, which contains the quest name, quest number, short and long descriptions.

If you run the disassembler against a .QST file instead of a .BIN file, it will also extract the .DAT file.

All three, the .pasm.header, .pasm, and .DAT are required for the assembler to create a compressed .QST for server use. If the .DAT file is missing, the assembler will only create a .BIN file.

You can download both the ASM and DISASM tool from

The source code for the disassembler is at

The source code for the assembler is at

Both the assembler and disassembler require asm.txt, which Qedit also recognizes, which can be found in the ZIP file above or you can just grab it from


P.S. The PRS library used in the .EXE and code was from the Sylverant server code. It's PRS library is free to use but I would never distribute it since it's not mine to distribute. If you need a PRS library, you can download it from
Last edited:


Thanks, this helped me figure out the .qst file format and where quest names etc. are located in .bin files.


Would you be willing to comment the code a bit or jot down some documentation here on the forums? I'm looking into .bin files again and I'm wondering what hex/str/... functions are for example. Str functions are functions like message, add_msg, window_msg,...? What does scriptOffset and binOfs exactly stand for?

I'm mainly trying to figure out which episode the quest is for and which map versions should be used (set_episode, BB_Map_Designate, map_designate, map_designate_ex,...).

Any help would be much appreciated.

And if you don't mind I'd like to add the information to this document:

Eventually I want to turn this into a wiki so anyone can contribute and all this info will easily be found in one place.


Staff member
Updated the disassembler to extract the .dat too.
EDIT: Updated again to make arguments pushed on the same line as the called procedure.
Last edited: