Jump to content

Recommended Posts

  • 2 weeks later...
Posted

Original topic and code here: link

Idea: link

 

When you use the skill vending there would be a menu that will pop up and you will choose what type of vending system do you like.

• Zeny - You will purchase items using zeny..

• Cashpoints - purchase items using cashpoints

• Item(your desired item) - purchase item using your desired items..(Example: TCG-7227)

You can enable or disable the cash / item in file db/item_vending.txt

attachicon.gif5.PNG

Vending title can be looks like: "[ITEM_ID] name"

attachicon.gif2.PNG

Version 1.8 preview:

attachicon.gif3.PNG

Changelog

Version 1.4:

  • Added support file 'item_vending.txt' for vending currency items ( Suggest by V e r T i g O )
  • Some fixes
  • @reloaditemdb command will uprate item_vending.txt
  • Max item in item_vending.txt is 98 ( default MAX_INVENTORY-2 ) 1 for zeny, 2 for cash, 98 for your items.
Version 1.5:
  • Now you can enable or disable Zeny/Cash in item_vending.txt. Just add/remove ID 30000 for Zeny or ID 30001 fo Cash Points
  • Removed battle_config.enable_cash_vending
  • Max items returned to MAX_INVENTORY
Version 1.6:
  • Now you can turn on or turn off Extended Vending System ( see conf/battle/items.conf )
  • Now, if your file item_vending.txt contains only 1 item the Select Window will be skipped
Version 1.7:
  • If file item_vending.txt is empty currency will be Zeny by default
  • Added two configs to file conf/battle/items.conf
Version 1.8:
  • Added option for more info about buying ( see version 1.8 preview)
  • Added option for add/remove ITEM_ID name from vending board ( Suggest by Pneuma )
  • All settings moved from conf/battle/items.conf to conf/battle/feature.conf

conf/battle/feature.conf

// Extended Vending System [Lilith]

// Enable or disable extended vending system? (Note 1)

extended_vending: yes

// Show currency's name in vending board? (Note 1)

show_item_vending: yes

// Show more info about buying? (Note 1)

ex_vending_info: yes

// Item ID for Zeny. Set to 0 if you don't want use Zeny.

item_zeny: 30000

// Item ID for Cash. Set to 0 if you don't want use Cash.

item_cash: 30001

db/item_vending.txt

// Specific items for Vending System

// Format: ItemID

// Max items is equal MAX_INVENTORY ( 100 by default )

// TCG Card

7227

// Mithril Coin

674

// Silver Coin

675

// Bronze Coin

673

Modify your client data files:

idnum2itemdisplaynametable.txt

idnum2itemresnametable.txt

30000#Zeny#

30001#Cash#

Enjoy.

New:

rAthena only: attachicon.gifExtendedVendingSystem_1.8.1.patch

attachicon.gifExtendedVendingSystem_1.8.patch

Old:

how do i patch it?

  • 2 weeks later...
Posted

db/item_vending.txt


    
    

Quote

// Specific items for Vending System
// Format: ItemID
// Max items is equal MAX_INVENTORY ( 100 by default )

// TCG Card
7227
// Mithril Coin
674
// Silver Coin
675
// Bronze Coin
673

Posted

Added git rev 11580.

 

Why git rev?

Because svn is outdated revision.

 

example of this.

 

// @autoloottype
1480: Item type not found.
1481: You're already autolooting this item type.
1482: Your autoloottype list has all item types. You can remove some items with @autoloottype -<type name or ID>.
1483: Autolooting item type: '%s' {%d}
1484: You're currently not autolooting this item type.
1485: Removed item type: '%s' {%d} from your autoloottype list.
1486: To add an item type to the list, use "@aloottype +<type name or ID>". To remove an item type, use "@aloottype -<type name or ID>".
1487: Type List: healing = 0, usable = 2, etc = 3, weapon = 4, armor = 5, card = 6, petegg = 7, petarmor = 8, ammo = 10
1488: "@aloottype reset" will clear your autoloottype list.
1489: Your autoloottype list is empty.
1490: Item types on your autoloottype list:
1491: Your autoloottype list has been reset.

git rev 11580 ExtendedVendingSystem_1.8.10.patch

Posted

I have issue when compiling in centos!

Visual c in my test server, same version is good, no warnings, no errors, everything is working properly!

d43c.png

 

 

but when doing the same, in my dedicated server, I got errors in this two lines, even using the same files in the same revision, thats weird

 

 

s0zz.png
those lines,  dont know wht to change here to fix it    REV 17181
 
            pc_paycash(sd,(int)z,0, LOG_TYPE_VENDING);
            pc_getcash(vsd,(int)z,0, LOG_TYPE_VENDING);
Posted

whenever someone purchases an item zeny, a discount is made in the amount that the seller will receive, how do I remove this function?

do mean tax?

 

how do I remove the taxes?

Posted (edited)
 

I have issue when compiling in centos!

Visual c in my test server, same version is good, no warnings, no errors, everything is working properly!

d43c.png

 

 

but when doing the same, in my dedicated server, I got errors in this two lines, even using the same files in the same revision, thats weird

 

 

s0zz.png
those lines,  dont know wht to change here to fix it    REV 17181
 
            pc_paycash(sd,(int)z,0, LOG_TYPE_VENDING);
            pc_getcash(vsd,(int)z,0, LOG_TYPE_VENDING);

 

try to add ,vsd on the last part.

        pc_paycash(sd,(int)z,0, LOG_TYPE_VENDING,sd);

            pc_getcash(vsd,(int)z,0, LOG_TYPE_VENDING,vsd);

Edited by solid2005
Posted (edited)

try to add ,vsd on the last part.

        pc_paycash(sd,(int)z,0, LOG_TYPE_VENDING,sd);

            pc_getcash(vsd,(int)z,0, LOG_TYPE_VENDING,vsd);

 

 

 

Same error, too many arguments.

this only happens in pay_cash and get_cash function and only happen if I compile, the up server, using Putty program

for some reason, sql its not making the object  vending.o

 

dprw.png
Edited by iraciz

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...