Custom item - Multisell how not to sell/trade/drop item or change sell price

Support for the latest build of L2J Server, get help here with installations, upgrades, problems.
Do not post bugs reports here, use viewforum.php?f=77 instead.
There is no support for other server builds than the official provided by l2jserver.com
Forum rules
READ NOW: L2j Forums Rules of Conduct
Post Reply
paris
Posts: 12
Joined: Wed Jun 10, 2015 7:23 am

Custom item - Multisell how not to sell/trade/drop item or change sell price

Post by paris »

Hi guys,

I have a custom NPC to sell hair accessories, It is working perfect.
Sample of a piece of my custom multisell XML:

Code: Select all

 <!-- antharas slayer -->
 <item>
    <ingredient id="57" count="50000"/>
    <production id="8568" count="1"/>
  </item>
  <!-- valakas slayer -->
 <item>
    <ingredient id="57" count="50000"/>
    <production id="8567" count="1"/>
  </item>
The problem is, my players are buying my accesories from my custom NPC adena $50K and then they sell it to the grocer by adena $3KK

My two questions are:

- How can I setup the items sold by my custom NPC to sell price adena $0?
- How can I setup the items sold by my custom NPC to no sell/no drop/ no trade?


Kind regards.
User avatar
CostyKiller
Posts: 220
Joined: Mon Aug 10, 2009 11:48 pm
Location: Romania

Re: Custom item - Multisell how not to sell/trade/drop item or change sell price

Post by CostyKiller »

Hello!

1. You can set the price in the items you want to 0 in items xmls.

Code: Select all

<set name="price" val="0" />
2. You can add these values to the items you want in items xmls.

Code: Select all

<set name="is_tradable" val="false" />
<set name="is_dropable" val="false" />
<set name="is_sellable" val="false" />
paris
Posts: 12
Joined: Wed Jun 10, 2015 7:23 am

Re: Custom item - Multisell how not to sell/trade/drop item or change sell price

Post by paris »

Thanks,

But, what if I want no sell/trade/drop for items only sold by my custom NPC?
Changing the data/stats/items xml will change items globally.

Best regards
User avatar
Avanael92
Advanced User
Advanced User
Posts: 189
Joined: Thu Aug 07, 2014 5:26 pm
Location: Germany

Re: Custom item - Multisell how not to sell/trade/drop item or change sell price

Post by Avanael92 »

You could try to give them an custom ID (in custom.xml) without changing the items globally. Then just simply add values whether it should be sellable or not and add this custom item to your shop :)
Last edited by Avanael92 on Tue Aug 04, 2015 4:55 pm, edited 2 times in total.
sahar
Posts: 582
Joined: Mon Jun 20, 2011 2:40 pm
Contact:

Re: Custom item - Multisell how not to sell/trade/drop item or change sell price

Post by sahar »

As Avanael92 said you can create a custom clone of the items you want to sell and then you'll achieve what you want.
I say simply quit it and don't even bother getting in such complex situation, using custom items has some known bugs.
Post Reply