Hello I'm creating a custom drop for Assis 374, I'm a customer but no one helped me there
Well this code works perfectly until going to level 81 the dropes are all tripled does anyone help me?
// Herbs.
if (getTemplate().getDropHerbGroup() > 0)
{
for (DropCategory cat : HerbDropData.getInstance().getHerbDroplist(getTemplate().getDropHerbGroup()))
{
final IntIntHolder item = calculateCategorizedHerbItem(cat, levelModifier);
if (item != null)
{
if (Config.AUTO_LOOT_HERBS)
player.addItem("Loot", item.getId(), 1, this, true);
else
{
// If multiple similar herbs drop, split them and make a unique drop per item.
final int count = item.getValue();
if (count > 1)
{
item.setValue(1);
for (int i = 0; i < count; i++)
dropItem(player, item);
}
else
dropItem(player, item);
}
}
}
}
+
+ // Drop All Monsters
+ if ((Config.ALLOW_GLOBAL_DROP) && ((this instanceof Monster)))
+ {
+ int levelMobMin = 0;
+ for (int i = 1; i < 81; i++)
+ {
+ levelMobMin = player.getLevel() - 8;
+ if (i > 10)
+ {
+ if (player.getLevel() == i && getLevel() < levelMobMin)
+ return;
+ }
+ }
+ dropItem(player, Config.GLOBAL_DROP_ITEMS);
+ }
}
+
+ private void dropItem(Player player, Map<Integer, List<Integer>> droplist)
+ {
+ Integer key;
+ Integer chance;
+ Integer min;
+ Integer max;
+ Integer itemMin;
+ Integer itemMax;
+ Integer count;
+ Integer rnd;
+ for (Entry<Integer, List<Integer>> entry : droplist.entrySet())
+ {
+ key = entry.getKey();
+ List<Integer> valueList = entry.getValue();
+
+ chance = valueList.get(0);
+ min = valueList.get(1);
+ max = valueList.get(2);
+
+ if (getLevel() > 9)
+ {
+ itemMin = getLevel() * min / 5;
+ itemMax = getLevel() * max / 6;
+ }
+ else
+ {
+ itemMin = min;
+ itemMax = max;
+ }
+ count = Rnd.get(itemMin, itemMax);
+
+ rnd = Rnd.get(100);
+
+ if (rnd < chance)
+ {
+ IntIntHolder item = new IntIntHolder(key, count);
+ if (Config.AUTO_LOOT)
+ player.doAutoLoot(this, item);
+ else
+ dropItem(player, item);
+ }
+ }
+ }
+
/**
* Drop reward item.
* @param mainDamageDealer The player who made highest damage.
* @param holder The ItemHolder.
* @return the dropped item instance.
*/
public ItemInstance dropItem(Player mainDamageDealer, IntIntHolder holder)
{
# Select o item for drop all monster
# Example : Itemid,chance,min,max;Itemid,chance,min,max
DropSystemItems = 9210,80,2,4;9211,70,1,3;9212,60,2,5;9213,40,3,5;9214,30,1,3;9215,50,2,3;9216,20,2,4
L2Elixir – Patch 4 Is Live!
We’re working non-stop, day and night, to deliver the best possible quality and bring back what made L2Elixir special. This project is built with passion, not shortcuts — for the old-school players who remember, and the new ones who want to experience it properly. Thank you for being part of the journey. Together, we’re making L2Elixir great again ❤️ The legends never fade.
⚙️ General
Enabled Class Change service (same class type only)
ALT + B → Services → Character Development
Enabled Shift + Click on Treasure Chests Players can now identify real chests (Adena, scroll drops) and use Key / Unlock
Event deaths now cancel only debuffs, All self buffs are preserved, fixes issues with Root and similar effects
Bladedancer class can now log in even when Max Clients (2) is reached. Since an active Bladedancer is not available for every damage dealer and some players tried to abuse this via VPN or a second PC, this feature was added to keep things fair. protections applies, requires testing!
🎒 Items
Crystallizing enchanted items now gives the correct increased crystal amount (retail-like behavior)
Removed Agathion Seal Bracelet: Rudolph from Santa rewards (Gracia Final item)
Added Dualsword Craft Stamp into Milestone Exchange list
🧙 Skills
Fixed Banish Undead lethal chance
Hot Springs Malaria and similar effects now level up faster while being attacked
Warning: This guy is a big scammer, trying to sell everything, advertising for servers etc.
That's his mail address evgesha.nrnr@gmail.com , stay away!
@Atom @Celestine
Warning: This guy is a big scammer, trying to sell everything, advertising for servers etc.
That's his mail address evgesha.nrnr@gmail.com , stay away!
@Celestine
@Atom
Question
l2jkain
Hello I'm creating a custom drop for Assis 374, I'm a customer but no one helped me there
Well this code works perfectly until going to level 81 the dropes are all tripled does anyone help me?
# Select o item for drop all monster
# Example : Itemid,chance,min,max;Itemid,chance,min,max
DropSystemItems = 9210,80,2,4;9211,70,1,3;9212,60,2,5;9213,40,3,5;9214,30,1,3;9215,50,2,3;9216,20,2,4
4 answers to this question
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now