Forum > Tools

[TOOL] WDBX Editor

(1/5) > >>

barncastle:
A project I started initially to learn how DBC files worked that eventually turned into this and thought it was worth a share.

This editor has full support for reading and saving all release versions of DBC, DB2, WDB and ADB. This does include support for both Legion DB2 and ADB files and works with all variants (header flags) of these.

Like the other editors I've used a definition based system whereby definitions tell the editor how to interpret each file's columns - this is a lot more reliable than guessing column types but does mean the definitions must be maintained. So far, I've mapped almost all expansions with MoP being ~50% complete, WoD being ~95% complete and everything else being 99%+ (excluding column names).

Link to the source can be found here.

Features:

* Full support of release versions of DBC, DB2, WDB and ADB (WCH3 and WCH4 are not supported as I deem them depreciated)
* Opening and having open multiple files regardless of type and build
* Open DBC/DB2 files from both MPQ archives and CASC directories
* Save single (to file) and save all (to folder)
* Standard CRUD operations as well as go to, copy row, paste row, undo and redo
* Hide, show and sort columns
* A relatively powerful column filter system (similar to boolean search)
* Displaying and editing columns in hex (numeric columns only)
* Exporting to a SQL database, SQL file, CSV file and MPQ archives
* Importing from a SQL database and a CSV file
* An Excel style Find and Replace
* Shortcuts for common tasks using common shortcut key combinations
* A help file to try and cover off some of the pitfalls and caveats of the program (needs some work)
Tools:

* Definition editor for maintaining the definitions
* WotLK Item Import to remove the dreaded red question mark from custom items
* WDB5 Parser which is an attempt to automatically parse the structure of WDB5 files
Things to Note:

* You need .Net 4.6.1 installed (download)
* Importing gives you the option to import; new rows, changed and new rows and to override all data
* Exporting to MPQ allows you to append to an existing archive or to create a new one
* Currently any SQL import must have identical columns to the file's definition
* Legion ADB files MUST have the DB2 counterpart open before as required information is stored in the DB2 file. The program will prioritise DB2 if DB2 and ADB are opened at the same time
* The WDB5 Parser works surprisingly well thanks to the new field structure data however it does trip up on inline strings so definitions may need to be validated manually
* Undo, redo and copy data history are lost when changing the current file
* Everything is stored in memory so if your PC is ancient the program will crash attempting to read hundreds of files at once!
Credits go to Ladislav Zezula for the awesome StormLib and thanks to all those that contribute to the WoWDev wiki. I've also patched the definitions together for various sources across the internet, there are too many to name, but thanks to all.

Change Log:

V 1.0.1
The following things have been changed/added:


* Added a FileSystemWatcher so that definitions are reloaded as soon as any definition file is saved meaning the application no longer needs to be restarted
* The program now functions correctly if set as the default program for files (thanks to Skarn for this suggestion)
* Find and Replace now uses a lookup table so is much faster
* Specific errors have been refined and made more human
* The program now no longer stops importing if a string is not found in the string table and instead writes "String not found" in the cell's value. This is an attempt to combat some incorrectly modified DB2 files I've come across
* Definitions have been updated for WoD 6.2.4 which is at ~98% now
* A fair amount of optimisation and tinkering
After some advice from Marlamin, Schlumpf and Amaroth I'm going to put the source on git in the coming week so that others can contribute and make this program better!

V 1.0.2

The following things have been changed/added:


* WCH7 (the new Legion ADB format) is now supported for both reading and writing
* A range of bugs and issues have been resolved
* Have added some options to the CSV import to fix erroneous source data:

* Option 1 (default): Increment Ids so none are duplicated
* Option 2: Take the newest record of the duplicated Ids
* The DataGridView has been overhauled meaning it is slightly faster, more memory efficient and now has a cache and state system implemented
* Undo/Redo has been rebuilt and now triggers on all events properly

* Note: Undo/Redo history is still lost on changing file
* Deleting 25+ rows at once is a permanent action (cannot be undone), due to BindingSource + DataGridView performance limitations, and are prompted to complete this action
* New rows now have default values based on their value type and value types are now enforced
* Added a new option to the column filter to hide all empty columns (the eye button)
* Added a clear row right click option which sets the row to default values
* Added the ability to insert a row with a specific Id provided it doesn't exist (Edit Menu/Ctrl + I)
* Added a new line shortcut to avoid having to scroll to the bottom of the grid (Edit Menu/Ctrl + N)
* Have updated the Legion definitions after some issues with WCH7 structures
A big thanks to UncleChristiof and Skarn for ideas, bugs and usability issues!

V 1.0.3

The following things have been changed/added:

The following things have been changed/added:

* WCH8 (the new Legion ADB format) is now supported for both reading and writing
* Save As (F12) has been added meaning Save doesn't prompt for file location
* SQL exprt now works with all "sql_mode"s
* SQL import now automatically fixes NULL values
* Datagrid context menu has been added to all cells as well row headers
* Supports opening multiple selected files at once
* Supports drag and drop files to open (based on Windows permissions)
* Added JSON as an export type
* Added version check based on Github releases
The application now runs as a single instance when launched in GUI mode. This means any files opened thereafter are sent to the running instance instead of opening the application multiple times. In certain situations this is not ideal, so a button has been added to the Load Definition screen which will open a new instance of the application for all files waiting to be loaded.

A range of command line arguments have been added (this is still early stages). This is the beginning of providing an interface so tasks can be automated/invoked via batch scripts and external programs.
Commands currently include (see the help file for more information):

* Console Mode which opens the software in a console session
* Extract which will extract all DBC/DB2 files from a MPQ archive or CASC directory based on a filter string
* Export which exports a specific file to CSV, JSON or SQL
* SQL dump which dumps a file's data directly into a MySQL database table
Thanks to Luzifix for helping with development



X-Post to other site: http://www.model-changing.net/files/file/82-wdbx-editor/

Uthil:
Great tool, going to test and see differences from the old classic MyDBC. Keep it up.

Marlamin:
I hope you consider open sourcing this. Too many amazing tools like this one have been abandoned and eventually lost to format changes.

barncastle:

--- Quote from: "Marlamin" ---I hope you consider open sourcing this. Too many amazing tools like this one have been abandoned and eventually lost to format changes.
--- End quote ---

Thanks for the compliment! My long term goal is to release the source although this will be after I've finished tinkering and provided it turns out to be a worthwhile tool (haven't had much too much feedback yet) as it needs a bit of refactoring.

That being said; if you do use it and notice any issues, sticking points or missing features let me know!

schlumpf:

--- Quote from: "barncastle" ---Thanks for the compliment! My long term goal is to release the source although this will be after I've finished tinkering and provided it turns out to be a worthwhile tool (haven't had much too much feedback yet) as it needs a bit of refactoring.
--- End quote ---

Just on a side note: There rarely, if ever, was anything coming out of refactoring and making code nice before releasing it. In my experience, pushing earlier is better. Even if people don't fork it or anything, there might still be those reading the code, giving helpful comments and such.

Navigation

[0] Message Index

[#] Next page

Go to full version