[Tutorial] Adding Affixes and Getting them to Drop

Upon request, here is a tutorial on making new affixes and getting them to drop in Grim Dawn! Sorry about the images potentially breaking tables in advance, looks like timg doesn’t work here.

Building your Affix and Affix Table

The first step to making a new Affix is creating a new affix table as shown below. Here, I’ve copied an existing affix table and renamed it for easy sorting. It is in here that we will eventually put the new affixes and start making some changes.

Next, we create our first affix, in this case, a new Rare Suffix. I’ve renamed the file to something that will also be able to sort and not get lost amid all the other preexisting affixes.

There are a few key things that can be changed:

FileDescription: - This will help you find it in the Asset Editor a lot more easily. Here, I’ve indicated that it is a new affix, the name it will have, and what level it will be (I later edited it to 15 from 20)
lootRandomizerName: This is the pointer to the tag file so that it gets the right name. More on that below.
lootRandomizerJitter: The % variance, up and down, that will be applied to the affix bonuses. The bigger the %, the wider range it will be.
lootRandomizerCost: This gets applied to the affix and goes in to the calculation for how much it will cost or sell for. Not 100% sure of the full formula, so I generally compare with other affixes.
levelRequirement: The min level needed for the item that this gets applied to.

Next, before we get too far, you want to update your Tag file in Text_EN to make sure that the affix’s name actually shows up in game. As shown below, I’ve created a new tag file that I am using for all my new additions so that it doesn’t interfere with the existing tag file. Here, I’ve set the tag for my new affix to be called “of Irzen’s Pyre” since it will be a Suffix. You can also see the groundwork for some of the Random Epics I’ve been using as test files

You will want to make sure to have the asset created in your mod folder by right clicking your tag file and selecting ‘Auto-Create’. If you get an error about and existing file, go to the ‘Assets’ tag and delete the older tag file there.

So, now I start adding the actual bonuses to the affix. To make sure you’ve removed all the old bonuses, you can sort by the righthand most column and scroll down to see all currently defined bonuses. After removing or editing those, you can add whatever you would like. The different types of bonuses that can be added and changed can be broken down on the lefthand side.

Below, I’ve made is so that this affix will give a 4% bonus to Spirit (I balanced this number down later), a 10% chance to do 20% more elemental damage, a 10% Burn and 10% Burn Duration modifier, and a Energy Leech DoT. I will probably tone more of these numbers down, but I general compare against existing affixes and Epics at the level I am making it for and go from there.

Skipping ahead, I created the other 4 levels of my affix in 15 level increments, ending at lvl 75. The easiest way to do this and keep consistent numbers was to comp the ‘a’ file, rename it to ‘b’ and adjust the stats. then ‘b’ to ‘c’, and so on. After that I go back to the affix tables area, the new suffix table I created in this case, and add all of my new affixes to it, setting the level ranges as appropriate.

Keep in mind, these suffix tables have a limit of 100 entries, so at 5 levels per affix , you can fix 20 new affix types in per table. Building off of that, when it comes to adding the affix tables to items (more on that below), you are limited to 10 per affix type, so 10 normal prefix tables, 10 normal suffix tables, 10 rare prefix tables, and 10 rare suffix tables. Been trying to get around this limitation by having nested tables (tables referring to other tables below it), but I haven’t been having any luck so far.

Getting it to drop in game - Loot Tables

Below is an example of a normal item and how it rolls suffixes. Each ‘randomizer’ as indicated on the left side points to a prefix or suffix table as defined on the right.

To test my new affix, I’ve created a dynamic loot table that is referenced by loot tables further up the chain (I can get into further depth a bit later). Basically, it makes it so that the critter I kill to test my drops, a player summoned raven that is killable (thanks rorschachrev!), will drop the items on this dynamic table. It is on the dynamic table that we control what affixes are rolled and the chance to get a rare affix vs a normal affix, or a combination of the two.

To be continued below since I hit my image limit for this post!

Very nice and detailed tutorial! And images are just fine, everything is simple to follow.

To close things out. Loot name, in the last screenshot of my above post, is the dbr file of the item that is to be dropped. That item can have its own innate bonuses as well.

To make sure that we see the affix applied to the items for testing, I am making it so that the items will always spawn with just a Rare Suffix and make sure that the only suffix table available is the one with the ones I created.

At this point, the affix will spawn in game on the items specified. Below are some examples of it applied to some Random Uniques and a normal item

The energy leech numbers are a lot higher than I was planning for at just level 15, so those will need to be tuned down to more reasonable levels.

Now that the items have shown to be spawnable in game without any glaring issues in regards to actually dropping or the bonuses being applied correctly, it can be circulated in to the normal loot tables.

To do this, the suffix table will be applied like the above test case but put in to an open rareSuffix slot in the Dynamic Loot Table of the types of equipment that you want to have a chance to spawn it by giving it a chance (aka weight) to apply that is similar to the other rareSuffix tables selected.

To see how items drop from enemies and chests, you will want to follow the steps downward from what should be dropping it down to the item details themselves.

For example, on this zombie’s equipment table below you would follow the loot tables in the middle section down. It would go from the Master Table for ‘miscall_a’, which contains a chance for all normal equipment types in the game to spawn, into a particular item type’s Loot Table, so (as seen in the master table dbr) ‘lt_hands’ for example. In thereyou would see what Dynamic Loot Tables you need to modify. Once in the right Dynamic Loot Tables, you would the Suffix Table dbr as an option to the randomizers as seen above.

Hope that helps and would be loot makers. If any parts need to be expanded on, please let me know. As I get further along on my mod, I will add new sections about using the Global Chance options to have a % chance for two effects to kick off at the same time, or a chance for one of several effects to trigger.


Thank you!

So it was just the initial equipement for monsters after all!

thank you! this is really helpful

But I have only one question:o

you are limited to 10 per affix type, so 10 normal prefix tables, 10 normal suffix tables, 10 rare prefix tables, and 10 rare suffix tables. Been trying to get around this limitation by having nested tables (tables referring to other tables below it), but I haven’t been having any luck so far.

Do you sure that nested tables works?
I tried to set a table B, which have weight of 99999 in table A

But I never see the prefixs in table B.
(I can see other prefixs in table A:confused:)

Awesome write up for that. I wonder if there are any enterprising modders who have attempted to whip up a .net app to automate some of this creation…hmmm…seems like a lot of moving parts can be consolidated.

Never did get it to work after lots of testing, ran in to the same thing you did

Something like that would definitely be fantastic as that is kinda what I am running in to now when it comes to implementation. Items are similar since all their effects on them and affixes are hand set rather than a reference point to a table so I have to do lots of comparisons to existing gear and affixes to try and make sure they arent too strong or too weak.

Awesome tutorial. Explained a ton for me. I had 2 questions that would help to clear some stuff up for me. (Also apologies for bumping up a 6-year old post lol)

  1. You mentioned for affix tables on items that there are normal and rare tables. What is the difference between a “normal” prefix/suffix and a “rare” one? Is normal for magic yellow items and rare the green ones? Or is it related to something else completely different?
  2. In your 7th image (niFe91M) showing you adding the suffixes to the suffix table, I noticed that the max and min levels for each “tier” of suffix overlap. Is that standard? I’m just curious if having, for instance, “suffix 1a” in the table with a max level of 30 and “suffix 1b” with a min level of 30 would cause any complications or if it’s fine for them to share a level like that.

Hi! Glad the tutorial came in handy so much later. I ended up not really finishing my mod because of some of the limitations as to how many affixes and new items could be put in and also the immense numerical balancing that would be needed for all the various stats.

To your questions, dusting off some of my old notes:

  1. The ‘Rare’ affixes are the ones that tend to make items Green since they add more powerful stats and skills usually. For example “of Menhir’s Wall” and “of Ulzuin’s Flame” suffixes or the “Warrior’s” and “Magi’s” prefixes that would fall under the rare categories and affix tables.

  2. For the overlap of the max vs min between tiers, I forget what the in game affix tier splits are, but there shouldn’t be any complications other than the potential that at level 30 (or at similar tier splits), an item would basically have a 50/50 shot of getting the T1 vs T2 version of the affix. Doing, for example 15-30 and then 31-45, or something along those lines probably makes more sense. Don’t 100% recall my rationale for doing that so I’d recommend seeing what the current versions of base-game affix tier level breaks look like.

I’ve played the game since the expansions came out but haven’t fired up the editor since back in the day, so not sure if there was a re-architecturing of some of the tables to have more space or if the same limitations of space are even more severe with all the new expansion content.

Awesome, thanks so much for the reply and the info. I think a few things are actually slightly more lenient based on what I am seeing? I can’t say for 100% because I don’t trust myself to ever fully comprehend what the heck I’m looking at in Asset Manager but the mention you made of a “limit of 100 entries” seems to have increased to 120, and the limit of “10 per affix type” seems to have increased to 18. At least that’s what I think I’m seeing from the files I’ve been messing with, but I wouldn’t take anything I say as fact cause this whole GD modding thing I’ve started has felt like Rocket Science mixed with Brain Surgery and my own brain is absolute mush lol.

Yea, I looked back through one of my old files and saw that a template from an existing affix file did have the first T1 to T2 overlap, but then the T3 and T4 ones were exact, so like 1-40, then, 40-49, 50-54, and the like, so at those overlap threshold levels, the only real ‘bad’ thing that might happen is that the pool of affixes would be huge and the chance of getting a good one in the higher tier diluted by the lower tiers.

Good to hear they expanded the max entries, gives a lot more real estate to create new items, which makes sense with everything they added in the expansions. The most I ever did in Grim Dawn was making some new unique items and made it so they rolled affixes, and played around with the visual effects creator. Trying to figure out how I was going to try and balance all the stats on the affixes and items out and test them all was a bit too daunting so if there is any other advice I can give, it is to plan things in smaller, more achievable chunks.

Here is some of the stuff I still had kicking around my old design docs. Was able to re-use a bunch of it for a magic item mod I made for the Tales of Maj’Eyal roguelike:

Wow very organized! I’m definitely doing things in sections, but even a single section of modding can be fairly overwhelming depending on the focus. You’ve got some really cool item ideas there, I hope I can come up with similar neat items for my mod. :grinning: