How to Create New Factions

by Valkryst

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:

Assuming that you've followed my instructions to download the tools that we'll be using in this tutorial, lets begin!

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 once in the instance with Faction.dbc.csv open and again in the instance with FactionTemplate.dbc.csv open. 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 near the end of this post 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.

Now double-click on the last row and fill in these values:

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:

Now apply those changes and double-click on the last row and fill in these values:

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. Go to /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:

Please ignore the Scarlet Factions and New (Master Faction) parts of the faction hierarchy, they aren't currently part of this tutorial.


Faction.dbc

FactionTemplate.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:

Any multiples above 0x16 such as 0x32 and above seems to be extremely 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:

Any multiples above 0x16 such as 0x32 and above seems to be extremely 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.

New Information on the Faction.dbc file:

Faction.dbc:

Columns 3, 4, 5, and 6 are all race masks when converted to binary. For example, Faction 81 (Thunderbluff) has values of 130, 1101, 16, and 0x20 respectively. 130 in binary is 10000010 and is read from right to left and are as follows:

  • Human
  • Orc
  • Dwarf
  • Night Elf
  • Undead
  • Tauren
  • Gnome
  • Troll
  • Goblin
  • Blood Elf
  • Draenei

So 10000010 has a 1 for Orc and Troll. Therefore, the value of 130 in field 3 means it's setting the Thunderbluff reputation for Orcs and Trolls. 1101 to binary is 10001001101. This is flagging the alliance characters (Human, Dwarf, Night Elf, Gnome, and Draenei. The 16 is 10000, which is for Undead. The 0x20 is for Tauren. I think my values here may be off for one because I'm almost certain I edited out the Blood Elf race mask on my project

Columns 3, 4, 5, and 6 are set by their respective values in columns 11, 12, 13, and 14. Columns 7, 8, 9, and 10 are also race masks, but I'm not sure what field they interact with. I presume it's 15, 16, 17, and 18.

So using the above, field 3 with a value of 130 is defining the race mask of Orcs and Trolls. Field 11 says that these races start with 3100 reputation with Thunderbluff (100 reputation into friendly). Field 4 with a value of 1101 defines the alliance races and says they are all at -42000 reputation (hated) with Thunderbluff. Field 5 with a value of 16 defines that Undead start with 500 reputation from field 13 whilst field 6 defines Tauren starting with 4000 reputation from field 14.

- Credits to kojak488 of Modcraft for this information.