Hey,
After spending a few hours playing around with the DBC files, scouring Google for information, and a
lot of frustration, I've finally managed to create custom factions and have them work/behave as a normal faction would. I haven't tested everything about the custom factions yet, but I know enough to write-up this tutorial. Before I start typing out this guide, I will admit that I'm no expert on DBC editing and that some of this information
may be incorrect. If you know of any additional information, notice an error, etc.. just comment and I'll do my best to keep this thread updated. Oh, one last thing to note, I haven't tested
any of this with Horde characters or Horde-aligned factions, so some of this may be a bit different for them. If you encounter errors I suggest that you upload your
Faction.dbc and
FactionTemplate.dbc files somewhere and then post below with your problem and a link to the files.
There are a few things that you'll need before editing a DBC file. I've seen many different programs, and even more people recommending each program over every other program, but the vast majority either didn't work or corrupted the DBC files. I'll only be recommending the programs that work for me. So, before you continue reading, please
download this; it contains everything that I use. These programs will only work on Windows.
Just in case anyone wants to know what I'm running:
- Windows 8, x64 -- Home
- Debian 7 x32 -- Server
- TrinityCore -- Latest version as of 5/June/2014
- WoTLK 3.3.5a
Assuming that you've followed my instructions to download the
tools that we'll be using in this tutorial, lets begin!
The questions that you should ask yourself before creating a new faction are:
- What will the new faction be called?
- How can I describe the new faction?
- Is the faction part Alliance, Horde, Neutral, or Monsters?
- Who should the faction attack Horde players, Alliance players, or Monsters? Maybe all of them? Maybe just players?
- Who should the faction be friendly with? (Same races as who they should attack.)
- What is the faction comprised of? (Same races as who they should attack.)
- Should this faction be under a category of factions? If so, what category?
- Should the category of this faction, if there is one, be under another category?
- There are many more questions, but you should be able to figure them out for yourself when you start making factions. =P
The most difficult part about creating a faction is
not the DBC editing. The most difficult part of creating a faction is actually figuring out all of the questions listed above. The reason for this is because, once you create your factions and players start using them, any time you give a new MPQ patch to your players that updates and factions that the players have already encountered there is a
very high chance that the reputation pane will bug-out and stop displaying the faction or in some other way to all players that have already encountered it. I haven't completely explored this issue, but in my experience this bug occurs quite frequently if not always. My best suggestion would be to create all of the factions, the faction hierarchy, and have everything tested so that it's perfect before you ever give the patch to your users.
Tip:
When editing any files that can be packed into an MPQ file, you can just go into your Data/enUS/ folder and create a new folder, lets call it "patch-enUS-n.mpq", and place all of the files that you would place into the MPQ file in there. This is extremely useful if you don't want to keep on creating a new MPQ file every time you go to test new edits. When you release the edits you should place them into an MPQ file as it hides everything from the average user.
Credits to MyLilSuccy for this information.
If you already know how to edit DBC files, which I'm going to assume that most of the people reading this don't, then you can skip to the end of this post and check out my notes on the DBC files. Although I would recommend doing a quick read-through of the tutorial.

The rest of this will be a simple explanation of how to add a new faction category called
New (Master Faction) and a faction called
Test Alliance Faction.
-----------------------------------------------------------------------------------------------------------------------------------
Now that you've downloaded the
tools and have a folder of clean, unedited, DBC files to work with and revert to incase of any unforeseen errors, lets begin!
The first thing that you need to do is copy
Faction.dbc and
FactionTemplate.dbc from your folder of clean DBC files into
/Tools/DBCUtil/ and double-click on
DBCUtil.exe. Next you must go to
/Tools/CSVed/ and double-click
CSVed.exe to open the program. You should open two instances of
CSVed.exe to make this a bit easier. Now click File and then go open
Faction.dbc.csv in
/Tools/DBCUtil/, if you have a second instance of
CSVed.exe running you should open
FactionTemplate.dbc.csv in it. I'll be assuming that you have two instances of
CSVed.exe open with one of the files in each, if you don't then you may need to read through this tutorial twice to complete it.
This next step needs to be repeated in both instances of
CSVed.exe, do it twice in each instance. Scroll to the bottom of the file, right-click on the last row, select
Copy Selected Record(s), left-click on the last row, now right-click on the last row, and select
Paste Record(s) below Cursor Pos. Now we will proceed by editing
Faction.dbc.csv, we will get to
FactionTemplate.dbc.csv later on. For an explanation on what each column represents,
please refer to my notes as I will not be explaining every value we're going to insert in this part of the tutorial. Double-click on the second-last row to open up the
edit form window and type in the following values, for any columns not listed below just leave them blank. When you're finished editing the columns you need to click
Apply Changes in the bottom-left corner of the
edit form window.
- Column 1 - 1161
- Column 2 - 105
- Column 3 - 1100
- Column 4 - 690
- Column 5 - 0x1
- Column 17 - 0x10
- Column 19 - 1162
- Column 24 - Test Alliance Faction
- Column 41 - Test Description - Test Alliance Faction
Now double-click on the last row and fill in these values:
- Column 1 - 1162
- Column 2 - -1
- Column 3 - 1791
- Column 24 - New (Master Faction)
Now click
File, then
Save, and then close this instance of
CSVed.exe. In the remaining instance of
CSVed.exe double-click on the second-last row and fill in these values:
- Column 1- 2237
- Column 2 - 1161
- Column 4 - 3
- Column 5 - 2
- Column 6 - 12
- Column 11 - 1162
Now apply those changes and double-click on the last row and fill in these values:
- Column 1 - 2238
- Column 2 - 1162
Save all of the changes above just like we did the first time and then exit
CSVed.exe. Now go into
/Tools/DBCUtil/ and, one-by-one, drag Faction.dbc.csv and
FactionTemplate.dbc.csv onto
DBCUtil.exe, if the .dbc files are still there delete them first. The second last step is to copy
Faction.dbc and
FactionTemplate.dbc into your server/bin/dbc/ folder and restart your server.
The final step is to create the MPQ file. Goto
/Tools/mpqediten64/ and create a folder called
Modified Files, then within that folder create another folder called
DBCFilesClient, then paste
Faction.dbc and
FactionTemplate.dbc into
/Tools/mpqediten64/Modified Files/DBCFilesClient/. Now go back up to
/Tools/mpqediten64/ and double-click
MPQEditor.exe, then click
New MPQ, enter the name as
patch-# (I'll use
patch-5), then click
Next, and then select
Build the MPQ archive from a file or directory and enter the path to
/Tools/mpqediten64/Modified Files/, now just keep clicking
Next until the
MPQ is created, then you can exit the program and copy
patch-#.mpq into your
/WoW/Data/ folder. After that just restart your server and test out the new factions.
Proof that this works:
Link to the fullsize image.
Link to the fullsize image. Please ignore the
Scarlet Factions and
New (Master Faction) parts of the faction hierarchy, they aren't currently part of this tutorial.
If you want to stay up-to-date with my latest tutorials or if you just want an easier way to view all of my tutorials and releases in one place then take a look
at my blog.
-----------------------------------------------------------------------------------------------------------------------------------
My notes on the DBC files:
Faction.dbc- Column 1 - Unique row ID.
- Column 2 - Unique rep ID, just make sure no other factions use the number and then forget about it. I haven't found any use for it, it just has to be unique. Use -1 if you don't want players to be able to gain reputation with the faction, this will also cause the faction not to show-up on the reputation pane.
- Column 3 - Sets who the faction is allied with. If Horde-aligned use (Untested) 690, else if Alliance-aligned use 1100, else if Neutral use (Untested) 1791.
- Column 4 - Sets who the faction is at war with. If Horde-aligned use (Untested) 1100, else if Alliance-aligned use 690, (Untested) else if Neutral use 0.
- Column 5 - Use 0x1, I believe this says to show the faction name in the tooltip. You can only see the tooltip if you're allied to the NPC. (Ex: Horde only see faction names on Horde NPCs) For Horde try using 0x2.
- Column 11 - Starting rep when faction is encountered?
- Column 12 - Lowest possible rep?
- Column 13 - Something to do with rep probably.
- Column 15 - See notes further down the post.
- Column 17 - See notes further down the post.
- Column 19 - Parent faction, points to a row in Faction.dbc.
- Column 24 - Faction Name
- Column 41 - Description (Shows up in the reputation pane of the character screen in-game.)
FactionTemplate.dbc- Column 1 - Unique row ID.
- Column 2 - Points to a row in Faction.dbc.
- Column 4 - What type of faction are we? (For Alliance use 3. For horde use 5. For monsters use 8.)
- Column 5 - What type of factions are we allied with? (For alliance use 2. For horde use 4. For monsters use 8 if allied with other monsters, else use 0.)
- Column 6 - What type of factions are we at war with? (For alliance use 12. For horde use 10. For monsters use 7. If you don't want NPCs of the faction attacking monsters, subtract 8 from the number.)
- Column 11 - Parent faction, points to a row in Faction.dbc.
All columns not listed in my notes were left at their default values. A few of the columns do certain things, but I don't want to spend another 8 hours trying to figure out how they work.
When editing your new factions to change names, data, etc... there is
always a very high chance that any characters that had reputation/knew the faction before your latest edit will bug out and not show the faction in the reputation pane of their character screens. Be absolutely certain about what you're creating and what you have created before you release these patches to your users as it would be a terrible loss to have to delete an old character just for a small faction update.
When creating a faction hierarchy like I have in the second picture above, you just need to create a faction, in Faction.dbc, with a unique ID in Column 2, add in a name for the faction, and leave out the description as you can't view it in-game. Now just reference my notes on the Columns above and add the faction you just created as the parent of whatever factions that you want listed under the faction you just created.
Major Update:After a solid three hours of trying to get the "At War" button on the reputation pane of the character screen to be unselect/unclickable I've managed do document the previously unknown Columns 15 and 17 of
Faction.dbc. I cannot guarantee this information for a Horde-aligned faction or Horde characters, but I strongly believe that it is the same on both factions. Whenever I mention Humans just replace that with Orcs and whenever I mention the other races, just group them together and switch for the other faction's races.
It seems that Columns 15 and 17 only affect the reputation pane of the character screen, and that Column 15 applies to all non-human races whereas Column 17 specifically applies to humans. (The same should be true for Horde races)
Column 15:- 0x0 - Default Value
- 0x1 - Faction shows up on character creation of Dwarves, Night Elves, Gnomes, and Draenei.
- 0x2 - No change from 0x0 as far as I've seen.
- 0x4 - Hides the faction, in the reputation pane of the character screen, from Dwarves, Night Elves, Gnomes, and Draenei.
- 0x8 - Same as 0x4.
- 0x10 - Greys out the "At War" button from the faction on the description pane of the reputation pane, for Dwarves, Night Elves, Gnomes, and Draenei.
- 0x16 - Same as 0x4.
- Any multiples above 0x16 such as 0x32 and above seems to be extremly buggy.
- Other values probably exist, but I only went by multiples of two. You may be able to add them together like all other flags, but I haven't tested that. Ex: 0x1 + 0x10 = 0x11 Shows up on char creation & has "At War" greyed out.
Column 17:- 0x0 - Default Value
- 0x1 - Faction shows up on character creation of Humans.
- 0x2 - No change from 0x0 as far as I've seen.
- 0x4 - Hides the faction, in the reputation pane of the character screen, from Humans.
- 0x8 - Same as 0x4.
- 0x10 - Greys out the "At War" button from the faction on the description pane of the reputation pane, for Humans.
- 0x16 - Same as 0x4.
- Any multiples above 0x16 such as 0x32 and above seems to be extremly buggy.
- Other values probably exist, but I only went by multiples of two. You may be able to add them together like all other flags, but I haven't tested that. Ex: 0x1 + 0x10 = 0x11 Shows up on char creation & has "At War" greyed out.
-----------------------------------------------------------------------------------------------------------------------------------
Edit ~ 18/Apr/2014:
- Added an additional note on faction hierarchies in the notes section.
- Improved the pre-tutorial section of this post.
- Confirmed my suspicions about a few Columns in Faction.dbc after finding this tutorial.
- Added two notes below the images.
- Edited a few notes, starting work on a rewrite of the tutorial.
- Finished rewriting the pre-tutorial section.
- Removed some incorrect information in my notes.
- Discovered some previously, as far as I know, unknown information about Columns 15 & 17 of the Faction.dbc file. If someone could get in touch of the TrinityCore team and have them update their Wiki with this information, that would probably help out a lot of people. See my notes section for the documentation.
- Editing the tutorial now, it should be ready for use in about an hour.