Index: C:/Documents and Settings/Paraskevas/workspace/L2_GameServer_c4/java/net/sf/l2j/gameserver/model/actor/instance/L2PcInstance.java =================================================================== --- C:/Documents and Settings/Paraskevas/workspace/L2_GameServer_c4/java/net/sf/l2j/gameserver/model/actor/instance/L2PcInstance.java (revision 2199) +++ C:/Documents and Settings/Paraskevas/workspace/L2_GameServer_c4/java/net/sf/l2j/gameserver/model/actor/instance/L2PcInstance.java (working copy) @@ -3425,15 +3425,16 @@ dropLimit = Config.PLAYER_DROP_LIMIT; } - if (dropPercent > 0 && Rnd.get(100) < dropPercent) + int dropCount = 0; + while (dropPercent > 0 && Rnd.get(100) < dropPercent && dropCount < dropLimit) { + int itemDropPercent = 0; List nonDroppableList = new FastList(); List nonDroppableListPet = new FastList(); nonDroppableList = Config.KARMA_LIST_NONDROPPABLE_ITEMS; nonDroppableListPet = Config.KARMA_LIST_NONDROPPABLE_ITEMS; - int dropCount = 0; for (L2ItemInstance itemDrop : getInventory().getItems()) { // Don't drop @@ -3448,13 +3449,13 @@ if (itemDrop.isEquipped()) { // Set proper chance according to Item type of equipped Item - dropPercent = itemDrop.getItem().getType2() == L2Item.TYPE2_WEAPON ? dropEquipWeapon : dropEquip; + itemDropPercent = itemDrop.getItem().getType2() == L2Item.TYPE2_WEAPON ? dropEquipWeapon : dropEquip; getInventory().unEquipItemInSlotAndRecord(itemDrop.getEquipSlot()); } - else dropPercent = dropItem; // Item in inventory + else itemDropPercent = dropItem; // Item in inventory // NOTE: Each time an item is dropped, the chance of another item being dropped gets lesser (dropCount * 2) - if (Rnd.get(100) < dropPercent - (dropCount * 2)) + if (Rnd.get(100) < itemDropPercent) { dropItem("DieDrop", itemDrop, killer, true); @@ -3464,7 +3465,8 @@ _log.warning(getName() + " dropped id = " + itemDrop.getItemId() + ", count = " + itemDrop.getCount()); dropCount++; - if (dropCount >= dropLimit) break; + dropPercent = (3*dropPercent)/4; // this 3/4 might need adjustment + break; } } }