Item Affixes and Probabilities
| Author |
Message |
|
Azraeil
Joined: Fri Jul 27, 2012 9:44 pm Posts: 13
|
 Item Affixes and Probabilities
I've recently been obsessed in trying to reverse engineer the loot rolling algorithm in D3 and have basically been trying to find more and more information about the properties themselves. I just found your site and I'm really glad something like this exists but I'm a little daunted at the complexity of it all. I suppose I'm not asking how it all works, but instead trying to get an idea of how different properties are rolled into an item. From what I've read, it seems that there are different affix tiers (alvl) throughout the game that can appear on items of equal or more ilvl. That part I can understand but what I'm not understanding is how an item, such as an ilvl 63 shoulder piece can have more than 100 of a different stat based on the tiers of affixes I've seen listed on your site. I'm under the assumption that an item can roll, say, a max roll of pure int and then a max roll of intvit to come up with a total of 200 int and 100 vit. That would be pretty remarkable but then can you also have another roll of pure vit? It's obvious that an item can roll two of the same stats under two distinct Mods (as you call them) based on the fact that 5 affix chest pieces have been crafted that have 6 properties rolled into them. Likewise, 7 affix chests have been crafted from 6 property patterns. Navigating to the Archon Spaulders page of your site ( http://d3inferno.com/items/_Shoulders_206.html) reveals that a bunch of different mod combinations exist, but I can't find any particular combination of them that make what I'm looking for. Based on the Mod Name category, I can see that it's possible to roll up to 100 Int (intellegence_item) and 100 Vit (vitality_item), and then a shoulder specific possibility of rolls which could provide another 65 int. But why only 65? Is there something I'm missing? The maximum possible int on a non-legendary set of shoulders is 200 -- ilvl 63 of course. (EDIT: After browsing the forums it seems that the 65 figure is innacurate as the max is actually 100 for this affix group) My goal here is to problematically determine, from a large sample size of items, affixes, and affix amounts, what the given probability of a particular roll is. As a secondary goal, I'm trying to determine what the probability of a "godlike" item dropping. At around the first of the month, I found myself a shoulder piece with 196 int, 172 vit, 45 resist all, and 16% gf and sold it for $250 on the RMAH, but just how likely is it to find something like that? What property rolls did it have? My third goal is to take those probabilities and come up with a value algorithm for gear, that is, to objectively determine the value of a piece of gear based on the likelihood of its existance.
|
| Fri Jul 27, 2012 9:46 pm |
|
 |
|
admin
Site Admin
Joined: Tue Aug 16, 2011 12:49 am Posts: 229
|
 Re: Item Affixes and Probabilities
Azraeil wrote: I just found your site and I'm really glad something like this exists but I'm a little daunted at the complexity of it all. I suppose I'm not asking how it all works, but instead trying to get an idea of how different properties are rolled into an item. From what I've read, it seems that there are different affix tiers (alvl) throughout the game that can appear on items of equal or more ilvl. That part I can understand but what I'm not understanding is how an item, such as an ilvl 63 shoulder piece can have more than 100 of a different stat based on the tiers of affixes I've seen listed on your site. I'm under the assumption that an item can roll, say, a max roll of pure int and then a max roll of intvit to come up with a total of 200 int and 100 vit. That would be pretty remarkable but then can you also have another roll of pure vit? It's obvious that an item can roll two of the same stats under two distinct Mods (as you call them) based on the fact that 5 affix chest pieces have been crafted that have 6 properties rolled into them. Likewise, 7 affix chests have been crafted from 6 property patterns. The ilvl (Item level) determines the maximum alvl (Affix level) that the item can spawn with. One interesting fact is that Rings and Amulets only go up to level 62, but the MPQ files have Affixes assigned to them up to 63. But those can never spawn since there are no ilvl 63 Rings and Amulets. An important thing to understand is that each Affix belongs to one (or two) Affix Groups. An item can only have one Affix from any given group. So for example, an item cannot have both "Dex 15" and "Dex 16" affixes. However, the combo-stat Affixes (e.g., DexInt) are not in the same Affix Group as the pure stat Affixes (e.g., Dex). That is why you can get stats higher than you expect. There's also another factor at work. For each pure dmg stat (Dex, Int, Str), there are three items that have a max of 200 rather than the normal 100. Those are: Dex: Boots and Gloves Int: Gloves and Helm Str: Belt and Shoulders So, for example, the maximum Dex on Boots is 300: 200 from Dex16, and another 100 from a combo stat DexVit XII Secondary, for example. Azraeil wrote: Navigating to the Archon Spaulders page of your site ( http://d3inferno.com/items/_Shoulders_206.html) reveals that a bunch of different mod combinations exist, but I can't find any particular combination of them that make what I'm looking for. Based on the Mod Name category, I can see that it's possible to roll up to 100 Int (intellegence_item) and 100 Vit (vitality_item), and then a shoulder specific possibility of rolls which could provide another 65 int. But why only 65? Is there something I'm missing? The maximum possible int on a non-legendary set of shoulders is 200 -- ilvl 63 of course. (EDIT: After browsing the forums it seems that the 65 figure is innacurate as the max is actually 100 for this affix group) The "65" is not inaccurate, but I agree that it is misleading. In this case, the "+65" max from Dexterity_Item on Shoulders is actually overwritten by the "+100" max from Dexterity_Item on Armor. Not sure why Blizzard did it that way. I am actually in the process of writing code that will show you the real maximums for each item type. I expect to have that done early next week. Azraeil wrote: My goal here is to problematically determine, from a large sample size of items, affixes, and affix amounts, what the given probability of a particular roll is. As a secondary goal, I'm trying to determine what the probability of a "godlike" item dropping. At around the first of the month, I found myself a shoulder piece with 196 int, 172 vit, 45 resist all, and 16% gf and sold it for $250 on the RMAH, but just how likely is it to find something like that? What property rolls did it have? My third goal is to take those probabilities and come up with a value algorithm for gear, that is, to objectively determine the value of a piece of gear based on the likelihood of its existance. Finding the probabilities for Affixes is hard by just looking at the AH because Affixes that are considered to be "not great" won't show up on the AH as much since folks will be more likely to vendor those items. I also don't know if all Affixes have an equal probability of spawning. In D2, not all Affixes had the same chance of spawning, although most did. From casual observation, it seems to me that Affixes with equal probability. Note that is a minimum Affix level that will spawn for an Item with a given ilvl. For an ilvl 63 item, I think the minimum spawnable alvl around 47. I actually have some AH data now, so I will have a closer look at that soon.
|
| Fri Jul 27, 2012 10:06 pm |
|
 |
|
Azraeil
Joined: Fri Jul 27, 2012 9:44 pm Posts: 13
|
 Re: Item Affixes and Probabilities
To determine the probability distribution, I'll be focusing on crafted goods. You're absolutely correct is saying that we can't rely on the AH as the data won't really come without sample bias.
|
| Fri Jul 27, 2012 10:10 pm |
|
 |
|
admin
Site Admin
Joined: Tue Aug 16, 2011 12:49 am Posts: 229
|
 Re: Item Affixes and Probabilities
Azraeil wrote: To determine the probability distribution, I'll be focusing on crafted goods. You're absolutely correct is saying that we can't rely on the AH as the data won't really come without sample bias. Yeah, that sounds like the best approach. When I get some time, I will also publish Affix data on the 20k+ auction info I have. That data will need to be taken with a grain of salt, but the sample sizes might be large enough to notice if there are any weird patterns.
|
| Sat Jul 28, 2012 5:09 am |
|
 |
|
j9y7a7
Joined: Tue Jun 26, 2012 4:22 pm Posts: 11
|
 Re: Item Affixes and Probabilities
Azraeil wrote: My goal here is to problematically determine, from a large sample size of items, affixes, and affix amounts, what the given probability of a particular roll is. As a secondary goal, I'm trying to determine what the probability of a "godlike" item dropping. Being able to answer the first problem certainly implies being able to answer the second. There is one twist to this particular detail. As we can see from the auction house item format, the actual stat values within a particular affix range is not stored explicitly with the item (this is in contrast with the affixes themselves). Instead, a random 32 bit seed value is stored and all the stat values are then rolled (or, rather, calculated) deterministically within the given range from this seed. This is done using a pseudo random number generator (PRG) and has interesting implications. For one, since this PRG is a function, it will never increase entropy. That means the PRG can output at most 2^32 different sequences of pseudo random numbers. Hence it can at most roll this many different combinations of values for a given set of affixes. I'm not sure if there are combinations of affixes that require more than these 32 bits of entropy, but I've seen some that are very close to 32 bits. It is clear that if there is one combination that exceeds these 32 bits not all combinations can be rolled, and if we are very unlucky, this is the perfect combination. On the other hand, since the PRG is not perfect, it might even be the case that it cannot generate some combinations that require less than 32 bits of entropy. Given that, the real question is: does a particular stat roll even exist? The good news is that we can determine this with a little bit of effort. Loosely speaking, given a set of affixes, you would have to enumerate all permutations of this set as a sequence and then try all possible seed values to check if that yields the stat combination in question. The first part is necessary, because we don't know how the affixes are generated; but their order is significant for the whole process. For a 6 affix item this would be 6! = 720 sequences. Enumerating all seeds and checking for one particular stat combo takes less than 30 seconds on my old hardware, so this process seems very feasible to me.
|
| Sat Jul 28, 2012 9:19 am |
|
 |
|
Azraeil
Joined: Fri Jul 27, 2012 9:44 pm Posts: 13
|
 Re: Item Affixes and Probabilities
Very interesting...
I suppose that does bring up some good points, but the end result I feel may still model a probability distribution. While not necessarily programmatic in the approach, I still feel that analyzing distribution curves will give a good idea of how rare or not a particular set of affixes is.
Of course, the programmatic option is quite appealing. I'm assuming that we have access to the stat calculation formula as you're implying that it is calculated client side which would also imply that it would be relatively easy to create a database of all possible rolls given an item with a certain criteria. I wonder how large such a database would be? I'm not really much a programmer, but I just know that I've got to be missing something. 2^32 isn't a very large number at all and as you said before calculating whether or not a particular stat combination can exist is just the beginning.
How many 6 affix chest armors can exist with over 250 vitality and 190 dexterity? What percentage of the total? These thoughts please me.
In fact, given this knowledge, there's almost no reason at all to calculate any probability distributions with any sample size except to validate what the programmatic approach can reveal to us.
|
| Sat Jul 28, 2012 6:03 pm |
|
 |
|
admin
Site Admin
Joined: Tue Aug 16, 2011 12:49 am Posts: 229
|
 Re: Item Affixes and Probabilities
j9y7a7 wrote: There is one twist to this particular detail. As we can see from the auction house item format, the actual stat values within a particular affix range is not stored explicitly with the item (this is in contrast with the affixes themselves). Instead, a random 32 bit seed value is stored and all the stat values are then rolled (or, rather, calculated) deterministically within the given range from this seed. This is done using a pseudo random number generator (PRG) and has interesting implications. FYI, the "random generator" function in question is similar (or might even be the same) as the one that was used in D2. My AH scanner uses the "seed" to correctly determine all of the Attribute values of the items. I haven't looked at probability distributions since rolling good Affixes is sooo much more important than having a "good" seed (for the most part). The other thing to keep in mind is that there really is no such thing as a "good" or "bad" seed since a given seed might give you a "bad" value when you roll 101-199, but give you a perfect value if the range in question was 151-199. In this regard, the order of the Affixes matters since you roll them in order. Personally, I don't think it is possible to effectively quantify the probability distributions based on seed analysis. I think that you are better off looking at the Affixes and then just using random probability distributions to build your model.
|
| Sat Jul 28, 2012 7:36 pm |
|
 |
|
Azraeil
Joined: Fri Jul 27, 2012 9:44 pm Posts: 13
|
 Re: Item Affixes and Probabilities
Ok, I suppose I'm not understanding what an item's data consists of.
Seed and then rolls for each affix? I think that's what I was missing before in trying to determine the complexity of the system.
Do you have any documentation of that system I could review?
|
| Sat Jul 28, 2012 10:03 pm |
|
 |
|
admin
Site Admin
Joined: Tue Aug 16, 2011 12:49 am Posts: 229
|
 Re: Item Affixes and Probabilities
Azraeil wrote: Seed and then rolls for each affix? I think that's what I was missing before in trying to determine the complexity of the system. Items are fully defined by their affixes and the random seed. The "random number generator function" isn't actually random. A given seed will always generate the same values. In fact, when the game client receives AH data from the server, the Attribute values aren't sent, only the seed and affixes are. Azraeil wrote: Do you have any documentation of that system I could review? The rules are a little complex. But the basic concept is that the basic item stats are rolled (e.g., armor), and then each Affix is rolled in order.
|
| Sun Jul 29, 2012 11:03 pm |
|
 |
|
Azraeil
Joined: Fri Jul 27, 2012 9:44 pm Posts: 13
|
 Re: Item Affixes and Probabilities
So the AH provides a seed and a set of affixes. It's from the PRNG that the affix values are rolled from in order with each affix. When you say affix, are you referring to properties such as DexVit or the individual Dex and the individual Vit? I suppose I really just want to see the function that takes that data and turns it into a human readable form. I'll see if I can find the D2 one online somewhere...
Also, are the rolls a uniform distribution? Are they modified out of the PRNG in any way before they become dex, vit, crit, etc?
I'm currently under the assumption that the item is given a seed and a list of properties which are then determined with a random uniform distribution. If that's the case, reverse engineering probability distributions wouldn't really be possible before the properties themselves are assigned before they are calculated by the client.
|
| Sun Jul 29, 2012 11:30 pm |
|
 |
|
Who is online |
Users browsing this forum: No registered users and 0 guests |
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot post attachments in this forum
|
|