You can post now and register later.
If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.
For wholesale clients
We understand that favorable terms are especially important when dealing with large volumes.
That’s why we offer a flexible system for wholesale clients we can discuss pricing and provide personalized solutions tailored to your needs.
With us, you get not only a reliable service but also support focused on long-term cooperation.
We value partners who operate at scale and do everything possible to make it convenient and profitable for you to grow together with Vibe SMS.
Website link — https://vibe-sms.net/
Our Telegram channel — https://t.me/vibe_sms
We ready to post first part of Patchnotes!
To avoid delaying the patch notes, we’ve decided to split them into two parts.
Right now, we’re publishing the patch notes focused on balance changes (skill changes).
In the second part, we’ll share details about gameplay updates, world changes, activities, and more.
- Patchnotes (last post on topic)
https://forum.lineage2dex.com/threads/16724/#post-72291
Question
HARDECORE
how do i get a player to sell anything in npc for 1 adena?
Note: There is the option to go item by item and set the price to 1. but that would bring me a lot of work, in the code there is an easier way?
long totalPrice = 0; // Proceed the sell for (UniqueItemHolder i : _items) { L2ItemInstance item = player.checkItemManipulation(i.getObjectId(), i.getCount(), "sell"); if ((item == null) || (!item.isSellable())) { continue; } long price = item.getReferencePrice() / 100; totalPrice += price * i.getCount(); if (((MAX_ADENA / i.getCount()) < price) || (totalPrice > MAX_ADENA)) { Util.handleIllegalPlayerAction(player, "Warning!! Character " + player.getName() + " of account " + player.getAccountName() + " tried to purchase over " + MAX_ADENA + " adena worth of goods.", Config.DEFAULT_PUNISH); return; } if (Config.ALLOW_REFUND) { item = player.getInventory().transferItem("Sell", i.getObjectId(), i.getCount(), player.getRefund(), player, merchant); } else { item = player.getInventory().destroyItem("Sell", i.getObjectId(), i.getCount(), player, merchant); } } player.addAdena("Sell", totalPrice, merchant, false); // Update current load as well StatusUpdate su = player.makeStatusUpdate(StatusUpdate.CUR_LOAD); player.sendPacket(su); player.sendPacket(new ExBuySellList(player, taxRate, true)); }
20 answers to this question
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.