Solved! How do I read existing .DLG files in .D format?
BCaesar
Member Posts: 480
Near Infinity is great for reading the dialogs and trees, but I would like to be able to read the existing DLG files in .D format to help me figure out how to write things. Supposedly WeiDU can decompile .DLG files into .D files so one can read them, but even following the guide I can't get it to work.
Any suggestions? What's the best way to read in-game dialogs?
Thank you.
Any suggestions? What's the best way to read in-game dialogs?
Thank you.
Post edited by BCaesar on
0
Comments
Just place the weidu executable in the game folder (the one with the CHITIN.KEY file for the game) and run it from the command line with the name of the DLG file you want to decompile.
For example, to decompile Minsc's joined dialog file, MINSCJ.DLG:
weidu.exe minscj.dlg
or on OSX:
./weidu minscj.dlg
You can use NI to determine the name of the DLG file you want to decompile.
I type:
weidu.exe mazzyj.dlg
and I press Enter, and all I get are the lists or more options (since it says Press Enter for more options). Every time I press enter it gives me more options until is closes. It doesn't recognize what I'm typing.
So I tried opening WeiDU with the Command Prompt instead but I can't figure out that either. It's in C:\GOG Games\Baldur's Gate II - Enhanced Edition\weidu.exe
So I open the command prompt and it says C:\Users\Brandon>
I type cd\ and press enter and it goes to C:\>
Then after the C:\> I type GOG_Games\Baldur's_Gate_II_-_Enhanced_Edition\weidu.exe and it says it cannot find the path specified. I tried it with spaces instead of underscores and that didn't work. MS_DOS mode is not my thing. The only thing I ever learned how to do on it was play Warcraft I and II and Syndicate, and while after all these years I still remember the commands to run those on my friends computer, I'm having no luck with WeiDU. Any help?
If you simply want to inspect dialogs in WeiDU's .D format then you can decompile the .DLG files with the weidu binary following the instructions posted by @AstroBryGuy .
Assuming the game is located in C:\GOG Games\Baldur's Gate II - Enhanced Edition you can use the following command to navigate into the game folder:
cd /d "C:\GOG Games\Baldur's Gate II - Enhanced Edition"
To decompile Minsc's interjection dialogs, execute
weidu.exe minscj.dlg
If WeiDU gives you an error message about not having a language set, use this command first to set the language (English in this case):
weidu.exe --use-lang en_us
As described in previous posts you have to start a command prompt, change into the game directory and execute weidu with the desired arguments.
Edit: Use weidu.exe directly and not any of the setup-xxx.exe files. These files trigger elevated privileges and therefore execute in a separate environment.
For anyone else reading this who wants step-by-step instructions here's exactly what I did (in case you have no experience with command prompt, ms-dos mode, etc.)
First I clicked on the windows icon in the lower left corner of the screen and searched for Command Prompt.
Then I opened Command Prompt and I typed: cd /d "C:\GOG Games\Baldur's Gate II - Enhanced Edition"
The stuff inside the quotes is the path to BG2 on my computer. Yours could be different depending on where and how you bought and downloaded the game. However if you copy weidu.exe into your BG2 folder (the folder that has the chitin.key file) and then open weidu, at the top it will tell you where it is. Whatever it says at the top is what you type inside the quotes, minus the last /weidu.exe
Then I typed: weidu.exe bmazzy.dlg and hit enter, and mazzy's banter file in .D format was created in my BG2 folder.