Page 1 of 1

Sell (Shops/Adena)

Posted: Wed Jun 26, 2013 5:52 pm
by t102030
L2J Revision Number: 6039
L2JDP Revision Number: 9837

Where i can edit to shops dont give adena for any item sold?
I thought I'd set the price of all items to 0, but that would take too long.

Another way?

Re: Sell (Shops/Adena)

Posted: Wed Jun 26, 2013 6:20 pm
by BiggBoss
Buylist is fast, it just 3 queries to set the sell and buy price to 0 (UPDATE).

For multisell, you would have to go to Multisell.java, search for parseEntry function and comment ( /* */ ) the code that parses ingredients. However, for this last one, i dunno if there is any check for ingredient-less items that could be triggered when shopping.

Re: Sell (Shops/Adena)

Posted: Wed Jun 26, 2013 6:29 pm
by UnAfraid
t102030 wrote:L2J Revision Number: latest
L2JDP Revision Number: latest
latest is not valid revision number!
BiggBoss wrote:Buylist is fast, it just 3 queries to set the sell and buy price to 0 (UPDATE).

For multisell, you would have to go to Multisell.java, search for parseEntry function and comment ( /* */ ) the code that parses ingredients. However, for this last one, i dunno if there is any check for ingredient-less items that could be triggered when shopping.
Buylist is on xml since Changeset 6039

Re: Sell (Shops/Adena)

Posted: Wed Jun 26, 2013 6:30 pm
by BiggBoss
UnAfraid wrote:
BiggBoss wrote:Buylist is fast, it just 3 queries to set the sell and buy price to 0 (UPDATE).

For multisell, you would have to go to Multisell.java, search for parseEntry function and comment ( /* */ ) the code that parses ingredients. However, for this last one, i dunno if there is any check for ingredient-less items that could be triggered when shopping.
Buylist is on xml since Changeset 6039
oh lol

Re: Sell (Shops/Adena)

Posted: Wed Jun 26, 2013 6:31 pm
by t102030
I guess I did not explain right.

What I want is that when the player is selling items (Retail shops, etc.) he did not receive adena.


@ UnAfraid

Editing topic with this informations. Sorry!

EDIT: Topic updated.

Please Help me!

Re: Sell (Shops/Adena)

Posted: Wed Jun 26, 2013 6:37 pm
by BiggBoss
RequestSellItem.java

Replace this

Code: Select all

 for (ItemHolder i : _items)        {            L2ItemInstance item = player.checkItemManipulation(i.getObjectId(), i.getCount(), "sell");            if ((item == null) || (!item.isSellable()))            {                continue;            }                        long price = item.getReferencePrice() / 2;            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); 
To this

Code: Select all

 for (ItemHolder i : _items){    L2ItemInstance item = player.checkItemManipulation(i.getObjectId(), i.getCount(), "sell");    if ((item == null) || (!item.isSellable()))    {        continue;    }    item = player.getInventory().destroyItem("Sell", i.getObjectId(), i.getCount(), player, merchant);} 

Re: Sell (Shops/Adena)

Posted: Wed Jun 26, 2013 7:36 pm
by xban1x
BiggBoss making a come back? :P

Re: Sell (Shops/Adena)

Posted: Wed Jun 26, 2013 7:42 pm
by BiggBoss
finals comming :evil:

Re: Sell (Shops/Adena)

Posted: Wed Jun 26, 2013 9:33 pm
by t102030
Thanks BigBoss!!

I love you ♥♥♥♥ :3