The Forgotten Realms

Would you like to react to this message? Create an account in a few clicks or log in to continue.

A Player Created Persistent NWN2 Role-Playing World


    Sifting through MDBs and DDSs

    Fyrekrest
    Fyrekrest
    Admin

    Posts : 346
    Join date : 2011-12-16
    Location : Vancouver, Canada
    20120102

    Sifting through MDBs and DDSs Empty Sifting through MDBs and DDSs

    Post  Fyrekrest

    Wow, this is one of the less-enjoyable parts of developing a world. Yep, I'm talking about sifting through all the MDBs and DDSs of the custom content that I'm planning to make use of. Since I plan to have the foundation of my world (read: scripts and haks compiled containing all the necessary and required custom content I plan to make use of) laid out soundly before I start "the fun stuff" (bringing it to life with NPCs and weaving adventures), this is one of the necessary evils.

    (As you read on, please understand that this post is written as I figure out how this process is done. Particulars such as a term I may use to define something may not be correct according to computer science. It is my intent to describe the process I used to achieve my goal, not a lesson in computer science nor programming!)

    For those that are not familiar with the various file extensions, .MDB and .DDS are two types that are common with 3D content. From what I gather, the .MDB is the file containing all the technical details, such as what the object is and what graphics are used on said object. The .DDS files are the 2D graphics which are applied to a 3D surface. The way I describe it to myself is that the .DDS file is applied over the .MDB, giving it visual details. (Like painting an otherwise invisible object)

    As I downloaded custom content, I combined it all into overly-large and messy haks. In all honestry, I never expected the haks to become so large nor so disorganized. I encountered a problem with one of the haks and when I was forced to sift through a hak that was over 1.6gb, I decided it was probably time to buckle down and get this chaos under better control to prevent having to endure the pain of trying to load a 1.6gb hak in nwn2packer. Trust me, it takes far, far too long (and my machine is relatively decent).

    As I hurriedly threw the haks together in my rush to get the project underway, there were many file naming conflicts. I figured I'd just have windows attach a numbered suffix to tell them apart, and away I'd go. Well, that didn't really work out as smoothly as I had hoped. So I was forced to sift through all the duplicate file names (which were duplicate files, just names) and had to figure out how to rename them. I had a feeling it would not be as simple as just left clicking and "Rename". Acting on the adage that "an ounce of prevention is worth a pound of cure", I did a bit of research and, lo and behold, I was correct; it wasn't going to be that easy. But, honestly, it's not that difficult either, just a bit more time consuming.

    Between a quick visit to the NWN2 IRC chat, the social.bioware forums and a few trips over to the vault, I pieced together that I needed to use a program called MDB Cloner (link). From what I understand (and trust me, I haven't looked too thoroughly) this also edits the contents of the file, instead of just the name.

    So, it was a matter of just firing up the program, a few clicks, and a few keystrokes!

    This is how the program looks:

    Sifting through MDBs and DDSs Mdbcloner1

    Note the highlighted areas; generally, those are the only items you'll really need to concern yourself with if you're simply renaming some MDB files so they all play nicely together.

    First, File > Load MDB and then locate your file and load it up. Now, change the numbered suffix in the MDB Name field. (Be sure to avoid duplicating another file name though. Know which numbers are available!) Click Save Clone. Unless you change the settings in MDB Cloner, the output folder should be the same as the original file. Ensure that your file was cloned (created under a different name) and then do what you like with the file you just cloned (I simply delete it).

    Example: since I allowed Windows to keep both files I was importing, and simply just apply the numbered suffix, I can tell the files I needed to change because they ended with (2) or (3). So I changed w_she_large72 (3).MDB to w_she_large105.MDB.

    For the most part, this is all I had to do. Some files, though, were a bit more work. Occasionally I'd find a *(2).DDS or *_t(2).DDS or *_n(2).DDS. A bit more research revealed that this would take a little bit more, but not too terribly much. Here's all I had to do:

    1. Determine which number I was going to assign the duplicate files to (the .DDS, _t.DDS and _n.DDS all receive the same number) and left click > "Rename" both the _t.DDS and _n.DDS to their new number. (example, "w_she_large72_n (2)" becomes "w_she_large106_n" and "w_she_large72_t (2)" becomes "w_she_large_106_t")
    2. Open the .DDS file in MDB Cloner normally, change the MDB Name to match (in our example, changed to "w_she_large106"). Before you hit Save Clone, though, you need to do one more step!

    Sifting through MDBs and DDSs Gimp_dds_edit01

    3. Attach the new .DDS files! There can be up to four different files you need to edit here, but these were the ones you just renamed in step 1 so you should be aware of what they are. Just input the correct names, and then Save Clone.

    All done!

    See? Not too terribly difficult once you know what to do, but it can be a bit tedious and time consuming, depending on how many duplicates you're dealing with. For me, there are far more duplicates than I would have cared for, but for the sake of achieving the ultimate goal that I have set for myself, I'm willing to grab a cup of coffee and sift through them all, one by one!
    Share this post on: reddit

    No Comment.


      Current date/time is Tue Oct 15, 2024 7:26 pm