• Unfortunately, we have experienced significant hard drive damage that requires urgent maintenance and rebuilding. The forum will be a state of read only until we install our new drives and rebuild all the configurations needed. Please follow our Facebook page for updates, we will be back up shortly! (The forum could go offline at any given time due to the nature of the failed drives whilst awaiting the upgrades.) When you see an Incapsula error, you know we are in the process of migration.

<common_drop_adjustment> and <prob> ?

Newbie Spellweaver
Joined
Mar 4, 2023
Messages
5
Reaction score
0
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.
 
Newbie Spellweaver
Joined
Sep 27, 2013
Messages
55
Reaction score
24
<common_drop_group_idx> = 0, 1, 2
<common_drop_adjustment> = chance

<item> = dropitem
<prob> = chanceItem
int rnd;
int t_COUNT = 0;
long nItemAdjust;
for (<common_drop>)
{
for (<item>) {
rnd = Rnd.get(0, 10000000);
nItemAdjust = 100 * (chance * chanceItem / 100) / 100;
if (t_COUNT <= rnd && rnd< (nItemAdjust + t_COUNT)) {
add(dropitem);
}
t_COUNT += nItemAdjust;
}
}

This is how item drop works.
 
Upvote 0
Junior Spellweaver
Joined
Apr 23, 2021
Messages
106
Reaction score
15
<common_drop_group_idx> = 0, 1, 2
<common_drop_adjustment> = chance

<item> = dropitem
<prob> = chanceItem
int rnd;
int t_COUNT = 0;
long nItemAdjust;
for (<common_drop>)
{
for (<item>) {
rnd = Rnd.get(0, 10000000);
nItemAdjust = 100 * (chance * chanceItem / 100) / 100;
if (t_COUNT <= rnd && rnd< (nItemAdjust + t_COUNT)) {
add(dropitem);
}
t_COUNT += nItemAdjust;
}
}

This is how item drop works.
yeh. just identify the custom item separetly int to give target item specific droprate
 
Upvote 0
Skilled Illusionist
Joined
Apr 1, 2022
Messages
359
Reaction score
398
<common_drop_group_idx> = 0, 1, 2
<common_drop_adjustment> = chance

<item> = dropitem
<prob> = chanceItem
int rnd;
int t_COUNT = 0;
long nItemAdjust;
for (<common_drop>)
{
for (<item>) {
rnd = Rnd.get(0, 10000000);
nItemAdjust = 100 * (chance * chanceItem / 100) / 100;
if (t_COUNT <= rnd && rnd< (nItemAdjust + t_COUNT)) {
add(dropitem);
}
t_COUNT += nItemAdjust;
}
}

This is how item drop works.
Taha example Weapon:
100 x (29700 x 1291 / 100) / 100
100 x 383.427 / 100

Taha example Stigma:
100 x (24 x 67257/ 100) / 100
100 x 1.614.168 / 100

I see no logic XD 383427 from 10000000 = 3,83427%
The point of 100 x 383427 / 100 is useless or? this is 383427, so no different, if you multipliy with 100 and divide with 100 you will have the same output, or i`m blind?

I´ve tried this now for some months, but my finish is everytime the same. 3,8% on an Tahabata Weapon in DP on an 4.6 client is to low i think. Nearly 4 Weapons on 100 runs? sounds a bit weird or? Im trying to rebuild this system, bcs the normal one from any AL/NG java server is bad in my opinion.
What about the level from the npc? maybe inside the calculate too? or the Rating? Maybe player/npcs leveldiff also in calculation?

btw, there are 14 weapons inside the dropgroup, maybe multiply with the amount of items inside the drop? so 3,83427 x 14 = 53,67978?? Sounds a bit better, but will this work on any? No do the same with Stigma 16,14168 x 44 = 710,23392 ......
sound bad again XD
 
Last edited:
Upvote 0
Junior Spellweaver
Joined
Apr 23, 2021
Messages
106
Reaction score
15
does it really require that difficult serie of numbers to define maths, i have not seen or worked on this game source so im quite guest in this section
 
Upvote 0
Skilled Illusionist
Joined
Apr 1, 2022
Messages
359
Reaction score
398
all good, but maybe some other guys are interested in rebuild the retail drop mechanic, me included. So ive tried different calculations, but all my trys was incorrect an some points :D
If you not interested in this mechanic and in this game do not feel addressed :)
This was simply an example that the calc some posts above cant work for 100%
 
Upvote 0
Skilled Illusionist
Joined
Apr 1, 2022
Messages
359
Reaction score
398
So. No news about the drop? Anyone can help maybe? I have an npc template running like the 4.6 pts with all common drop inside, but cant find the correct math for the drops.
common_drop_adjustment * item_drop_chance will not work, same with multiply with level or / 10 / 100 and any other calculation, i think im blind :D i cant find the issue, i try to rebuild the 4.6 pts dropsystem. Is there a multplier for Eternal/Fabled/Heroic gear? idk, pls if anyone has an idea pls help a bit.



And ItemRate:

Code:
listId    group_name                itemId        count    chance
10170    IDLF1_WEAPON_N_E1_50A    100000768    1        1291
10170    IDLF1_WEAPON_N_E1_50A    100200702    1        1291
10170    IDLF1_WEAPON_N_E1_50A    100100581    1        1291
10170    IDLF1_WEAPON_N_E1_50A    100900591    1        1291
10170    IDLF1_WEAPON_N_E1_50A    101300564    1        1291
10170    IDLF1_WEAPON_N_E1_50A    101500605    1        1291
10170    IDLF1_WEAPON_N_E1_50A    101700620    1        1291
10170    IDLF1_WEAPON_N_E1_50A    100600636    1        1291
10170    IDLF1_WEAPON_N_E1_50A    100500602    1        1291
10170    IDLF1_WEAPON_N_E1_50A    115000860    1        1935
 
Last edited:
Upvote 0
Skilled Illusionist
Joined
Apr 1, 2022
Messages
359
Reaction score
398
So, my update:
Drop is working, but it looks like stuff like Manastones and other things need an extra multiplier, with these calc above a Rare manastone in verteron has 1,6% chance. And what is about "massiveLooting" inside the pts server binary? anyone has an Idea?
Im on a great way to rebuild the drop now, but something is missing. Lookes like some npc's has an
<commond_drop_adjustment>-1</commond_drop_adjustment> inside the first common_drop index, maybe massiveLooting? So it needs another calculate i think. With "commonDropAdjustment * itemProb / 100" all npcs without the <commond_drop_adjustment>-1</commond_drop_adjustment> has very low dropchance on anything, set it to "commonDropAdjustment * itemProb / 10" will work better, but Manastones are still a problem at the moment and /10 wont work for bosses with "-1" They will drop as example Tahabata weapon for 60% and higher, with /100 only 6 % with the totalCount drop from the groups above.

Anyone has maybe some more info about this?
 
Upvote 0
Back
Top