When a monster dies in the game, it gives items. I want to exploit the xml to find the percentage chance for a given item. I have a very telling example that prevents me from theorizing because every time I have an idea, it is the counter-example.
This is the xml of the mob in question
https://pastebin.com/h1H3B992
I want to know what he drops and at what rate
what I already know is that an item defined with
<item>junk_elementalfire_55</item>
<item_count>1</item_count>
<prob>1000000</prob>
You can see the <prob> that gives the probability. I'll tell you, by looking at other items I know that the max value is 10,000,000, and that an item that has a proba at 10,000,000 has a 100% chance of dropping.
So far so easy.
Now, you can see that there is a second section of the xml called <common_drops>
Instead of referencing a single item, it references a group of items. Imagine that the mob can drop a weapon, but that in the possible weapons we have "bow" "sword" "lance". So we create a group called "weapon" and one weapon among all will be chosen at random. In this case, only one item of the group can be dropped
Example:
<common_drop>WeaponDropGroup</common_drop>
<common_drop_adjustment>63000</common_drop_adjustment>
<common_drop_group_idx>0</common_drop_group_idx>
Note the "common_drop_adjustment".
These groups are defined in another file I have access to and are quite simple
The problem is that the calculation of their loot rate is not really obvious
https://pastebin.com/fZJSG1F1
Here are the 3 groups that correspond to the mob above
in a group, we find the <prob> tag which can still go up to 10 000 000
We're getting to the end, I promise
My conundrum is that the drop of an item from the IDCATACOMB_WEAPON\_A\_N\_E1\_55B group found in game is around 5% while the drop of an item from the IDCATACOMB_ACCESSORY\_BELT\_A\_N\_L1\_55A group is 100% (or at least very close)
And I can't seem to put together the numbers for common_drop and prob to arrive at this result
I've messed around with the data, I can't see the logic. If you have a clue that I forgot to explore, I'd love to hear from you.
This is the xml of the mob in question
https://pastebin.com/h1H3B992
I want to know what he drops and at what rate
what I already know is that an item defined with
<item>junk_elementalfire_55</item>
<item_count>1</item_count>
<prob>1000000</prob>
You can see the <prob> that gives the probability. I'll tell you, by looking at other items I know that the max value is 10,000,000, and that an item that has a proba at 10,000,000 has a 100% chance of dropping.
So far so easy.
Now, you can see that there is a second section of the xml called <common_drops>
Instead of referencing a single item, it references a group of items. Imagine that the mob can drop a weapon, but that in the possible weapons we have "bow" "sword" "lance". So we create a group called "weapon" and one weapon among all will be chosen at random. In this case, only one item of the group can be dropped
Example:
<common_drop>WeaponDropGroup</common_drop>
<common_drop_adjustment>63000</common_drop_adjustment>
<common_drop_group_idx>0</common_drop_group_idx>
Note the "common_drop_adjustment".
These groups are defined in another file I have access to and are quite simple
The problem is that the calculation of their loot rate is not really obvious
https://pastebin.com/fZJSG1F1
Here are the 3 groups that correspond to the mob above
in a group, we find the <prob> tag which can still go up to 10 000 000
We're getting to the end, I promise
My conundrum is that the drop of an item from the IDCATACOMB_WEAPON\_A\_N\_E1\_55B group found in game is around 5% while the drop of an item from the IDCATACOMB_ACCESSORY\_BELT\_A\_N\_L1\_55A group is 100% (or at least very close)
And I can't seem to put together the numbers for common_drop and prob to arrive at this result
I've messed around with the data, I can't see the logic. If you have a clue that I forgot to explore, I'd love to hear from you.