Skip to content

dialog.tlk question

rw1954rw1954 Member Posts: 24
I'm using DLTCEP to edit the dialog files, and it works fine, but I'm having a hard time finding certain pieces of dialog due to the cryptic nature of the file names. On the first level of Irenicus's dungeon, for example, I can't locate the files for Malaaq (the djinn in the flask), the three dryads (Ulene, Cania and Elyme) or the Tortured Ones (creatures in tanks, like Rielev). Does anyone know a way to locate these files, other than reading through hundreds of dialog trees?

Comments

  • rapsam2003rapsam2003 Member Posts: 1,636
    Doesn't DLTCEP have a search function for dialog files?
  • Abdel_AdrianAbdel_Adrian Member Posts: 430
    First off, you shouldn't use DLTCEP to edit the dialog.tlk. I'm speaking from experience and it causes more problems than anything; learning to use WeiDU to edit the dialog.tlk is not only a lot easier and faster, but it allows others to use your changes and can easily be reversed without corrupting the dialog.tlk.
    Okay, now with that out of the way, be sure you create a hard-link with your dialog.tlk to your game directory (the folder with the chitin.key). Refer to this thread: https://forums.beamdog.com/discussion/6950/player-how-to-getting-mods-to-work-on-bgee/p1

    If you create a hard-link and refresh the dialog in DLTCEP, you might have slightly better luck finding the specific string you're looking for. I hope this helps.
  • lansounetlansounet Member Posts: 1,182
    You can research a specific creature by its name, its attached dualogue file info is stored in the creature info. That is true for all creatures except joinable NPCs who have several dialogue files which can be found in INTERDIA.2DA and PDIALOG.2DA
  • rw1954rw1954 Member Posts: 24
    Thanks, Iansounet. The search command for creature names solved the problem (so far). I do have a question regarding the other dialog files you mentioned, INTERDIA.2DA and PDIALOG.2DA. Is it possible to edit them with DLTCEP? If so, how do I get DLTCEP to open those files?
    Thanks also to Abdel_Adrian. I appreciate the advice, but I just started learning how to use DLTCEP, and I really don't want to open a new can of worms right now. I will look into it though. Thanks.
  • rapsam2003rapsam2003 Member Posts: 1,636
    edited April 2016
    rw1954 said:

    Thanks also to Abdel_Adrian. I appreciate the advice, but I just started learning how to use DLTCEP, and I really don't want to open a new can of worms right now. I will look into it though. Thanks.

    A word of warning, if you will: I also recently (as in, a few weeks ago) began learning to use the tools for IE mod development, such as DLTCEP and NearInfinity and so on and so forth. One thing I discovered is that using DLTCEP or NearInfinity to edit the dialog.tlk file can actually run the risk of corrupting the dialog.tlk. I had to use the Beamdog installer to repair my installation a few times before I stopped being stubborn and started using WeiDU.
    The other thing is, WeiDU is much more "friendly". If you use DLTCEP or NearInfinity to edit the dialog.tlk file, then you're only editing the dialog entries on your system. If you publish your mod assuming, for instance, that dialog.tlk entry #35000 is available...well, there's no guarantee that another mod isn't already using that entry. WeiDU appends to the dialog.tlk and tells the game files which entries belong to what, which means you don't have to worry about which entries are available or not. I advise looking into WeiDU and the use of .tra files.

    I hardly claim to be an expert at the use of WeiDU, but I have managed to release an alpha of a mod already. So, I'd say I know at least a bit about the dangers of what I speak of.
  • UlbUlb Member Posts: 295
    While what @rapsam2003 wrote is all true I just want to add that personally I have never had NearInfinity corrupt a single dialogue.tlk file for me in over 10 years of using it. I still use it a lot when messing around in my own installations, though obviously weidu is the way to go for anything you want to publish or use on more than one installation.
  • rapsam2003rapsam2003 Member Posts: 1,636
    edited April 2016
    Ulb said:

    While what @rapsam2003 wrote is all true I just want to add that personally I have never had NearInfinity corrupt a single dialogue.tlk file for me in over 10 years of using it. I still use it a lot when messing around in my own installations, though obviously weidu is the way to go for anything you want to publish or use on more than one installation.

    Well, I had it corrupt the dialog.tlk a total of 3 times. I don't know if what I was doing was not recommended use or what happened. However, research on NearInfinity seems to show that it's not a tool designed to keep your game's integrity safe. You use NI or DLTCEP at your own risk. WeiDU is designed to keep your game's integrity safe, on the other hand.
  • Abdel_AdrianAbdel_Adrian Member Posts: 430
    NI or DLTCEP aren't horrible choices if you just want to edit a single string, fix a typo, or otherwise create something that can't be published, but definitely when writing your own mod from scratch with the intention of publishing, WeiDU is a life-saver. When I first started, I also had the mentality that WeiDU was difficult and I would just focus on learning DLTCEP to start...it was a waste of time, if I could go back I would start with WeiDU earlier. It serves the same function much more elegantly.
  • argent77argent77 Member Posts: 3,478
    You can corrupt the dialog.tlk when you select the wrong character encoding. The Enhanced Editions use UTF-8 while the original games use specific ANSI encodings, depending on the game language. NI uses autodetection by default, but you can also manually select a specific character encoding at your own risk.

    Btw, WeiDU can corrupt the dialog.tlk as easily as all the other resource editors if you're not careful. It's the modders' responsibility to make sure that their mods are free of (the more serious) bugs. I would still advice to use WeiDU for manipulating the dialog.tlk.
  • rw1954rw1954 Member Posts: 24
    Thanks, guys. To be more specific, I am only changing dialog, and I do not intend to publish. I also have an old computer with an old OS, and I'm using the original BG version (4 CD's + ToB), not BGEE. I tried using Near Infinity and Weidu, and they don't work for me, but DLTCEP has been working just fine.

    To repeat my last question, is it possible to access the pdialog.2da and interdia.2da files using DLTCEP? If so, how do I get the program to open those files? Thanks.
  • Abdel_AdrianAbdel_Adrian Member Posts: 430
    rw1954 said:

    I am only changing dialog, and I do not intend to publish.

    We all understand this, we just want to help you do it better.
    rw1954 said:

    I tried using Near Infinity and Weidu, and they don't work for me, but DLTCEP has been working just fine.

    There *should* be versions of WeiDU and NI that work. These really are amazing tools and it doesn't hurt to find a version that works on the original games.
    rw1954 said:

    is it possible to access the pdialog.2da and interdia.2da files using DLTCEP? If so, how do I get the program to open those files?

    Yes, this is what DLTCEP actually does. I think you're slightly confusing dialogs though. Dialog.tlk has every string reference in the game; this is what WeiDU edits seamlessly, but DLTCEP very easily corrupts, even if you don't intend to publish. Dialog.tlk has all the lines of text, which means that somewhere it includes "Malaaq (the djinn in the flask), the three dryads (Ulene, Cania and Elyme) or the Tortured Ones (creatures in tanks, like Rielev)." But only the lines of text, not the dialogs. Now those other files, pdialog.2da and interdia.2da, are completely unrelated. Those involve npc interactions. But you can easily access and edit them with DLTCEP by clicking Edit > Tables (2da). The actual dialog trees for the conversations you mentioned are in completely different files with specific names for the npcs, but you can begin your search by clickling Edit > Dialog (DLG). But if you actually edit it in DLTCEP, you're going to have a bad time. It's just not a good tool for strings/dialogs. You can edit 2da's though.


  • rw1954rw1954 Member Posts: 24
    Thanks for the information. I have more questions...
    Regarding DLTCEP: The 2DA files don't seem to have the information I was looking for. So far the only problem I'm having is finding all the dialog. Using the creature search command has helped a lot, but there are still certain top lines that I just can't find. Examples:
    Jaheira: This place is not a friendly one...
    (she says this unprompted after Brus leads the party to the Copper Coronet)
    Anomen: These pathetic skirmishes...
    (he says this unprompted seemingly at random)
    Regarding NI and Weidu: Assuming I can find older versions of these programs, how can I tell which version will work best on my computer? Are there guidelines? Should I just use the oldest one available?
  • rapsam2003rapsam2003 Member Posts: 1,636
    edited April 2016
    rw1954 said:

    Thanks for the information. I have more questions...
    Regarding DLTCEP: The 2DA files don't seem to have the information I was looking for.

    2DA files are literally just table files. 2DA files are not designed in the way that you're thinking.
    rw1954 said:

    Regarding NI and Weidu: Assuming I can find older versions of these programs, how can I tell which version will work best on my computer? Are there guidelines? Should I just use the oldest one available?

    Why would you want to use older versions of these? You would lose so much functionality by doing so...
  • Abdel_AdrianAbdel_Adrian Member Posts: 430
    @rw1954 The 2da files are not going to have the information you're looking for, you want to be looking at .DLG files.
    The best NI & WeiDU versions to use for original BG are the last versions released before BGEE. The change logs will make it clear which version first worked on BGEE, grab the version before that. But it's also not a bad idea to buy BGEE on a sale so you have more mod capability.
  • rw1954rw1954 Member Posts: 24
    Thanks again, but no go. I was able to find and download older versions of NI and Weidu, but I still can't install either program. The NI download contains nothing but .class files, no executables, and the Weidu download is similar. Obviously I'm missing something here. NI and Weidu may be better programs, but compared to DLTCEP they're definitely less user friendly, since I can't even get them to work. Another potential problem, at least with NI, is the Java requirement. I have Java, but I have no idea how old it is. It's old enough that the Java web site can't tell me what version it is. Based on past experience I'd be surprised if the latest versions of Java worked on my computer. On the other hand, DLTCEP was easy to install, and despite my antiquated technology it's working fine. For someone more knowledgeable, getting NI or Weidu to work with the resources I have might be possible, but to me it just seems like a big pain in the ass that would probably end in failure, so even though DLTCEP may not be the best option, so far it's the only one that works, and under the circumstances I'm resigned to the fact that it may be the only option I have.

    Again, the only real problem I'm having with DLTCEP is locating certain dialog files. The cryptic naming system is quite frustrating, and even with the creature search command there are some lines of dialog that I just can't find. Is there any way to solve this file ID problem?

    PS - If anyone knows (or can find) the location of the top level actor lines that I mentioned in my last post, could you please tell me? I've wasted a lot of time trying to locate them, and I'd appreciate the assist.
  • IsayaIsaya Member, Translator (NDA) Posts: 752
    edited April 2016
    If you see class stuff when you try to run Near Infinity, that's because you let your archiver (Zip, whatever) open .jar files as if they were archives (well, they are, actually). To cancel this association, the easiest way is to reinstall the Java runtime environment so that it take over handling of jar files. Otherwise you have to tweak the .jar file extension association and point to Java SE platform (maybe javaw or javaws in your Java installation) to run them.
    Usually you can check the Java version with the software it added to the control panel.

    WeiDU is not something you install. You just extract the archive content and use weidu.exe from the command line after copying it in the game folder. WeiDU is very efficient for dialog handling. For instance, a simple command would extract any dialog you want to check under a specific text format with .d extension. For instance, to extract Aerie's meeting dialog:
    weidu AERIE.DLG
    There is a learning curve to understand the "language" used to build a dialog, but it's not complicated when you extract existing files.

    Interjections from the group characters reacting to someone else line are found in xxxxJ.dlg file, xxxx being the name of the group character in a somehow shortened form. To find the exact name, open pdialog.2da file. It lists the file names for dialogs associated to characters that can join the group.
  • rw1954rw1954 Member Posts: 24
    I appreciate your advice, Isaya, but I have no idea what you're talking about. Phrases like "runtime environment" and "Java SE platform" are meaningless to me. You might as well be speaking elvish. As I explained, my knowledge is sketchy at best, and my resources are obsolete. That's why I'm trying to keep this project very simple. I just want to locate lines of dialog so I can change them. I obviously don't have the experience to mess around with programs like NI or Weidu. Maybe if I could get them to work I'd have better luck (I'm good with languages), but based on your comments I seriously doubt I have the knowledge needed to even install them. Luckily DLTCEP is so user friendly I can actually use it. I've changed hundreds of lines of dialog, and I haven't had a single problem so far. So I'm inclined to follow the path of least resistance and stick with the devil I know. Again, my only problem is finding specific dialog files. There are numerous text files that I'd like to edit, but I can't locate them, and searching through the entire archive is a monumental task. I tried referring to the .2DA files, as you suggested, but I can't make any sense of the data. All I get are columns and rows of zeroes. What I need is a way to input game data, like the top level actor line that starts a certain dialog and which actor said it, and get the name of the text file that contains it. If I had that, I'd be doing fine. Anyone know how to do that?
Sign In or Register to comment.