- Joined
- Jul 8, 2005
- Messages
- 3,167
- Reaction score
- 515
To add custom items into a server first of all you need to add the item you want into the item_db2.txt (not necessary, but it's preferred and recommended generally to add it in there)
Start with the item IDs starting at 18000 (or IDs of your choice that haven't been taken already, if it does have the same ID, there'll be a crash and both the items will be discarded if I'm right)
In the item_db2, for a headger item I'm assuming, you type:
18200,sprite name(name of the spr and act file), item name, item type( put in 5 for headgear),cost of item(optional),selling price of item,item weight,,def,,slot,job ( 0xFFFFFFFF for every job would be a good start),upper( 7 for all class types to use the item), gender (2 for both genders to wear the item), Location( 256 for top headgear, 512 for mid-gear, 1 for bottom gear),,level required to equip the item,refineable (1 for yes, 0 for no), ViewID,{ OnEquip script }
So, in short the script for the item would look something like this:
18200,(sprite name here),(item name here),5,,10,****,4,,4,0xFFFFFFFF,7,2,1,,1,1,400,{},{},{}
so the script above shows that the item's ID is 18200, is a headgear, sells at 10z, item weight is 10, gives +4 def, has 4 slots on the item, both genders can eqiup it, and it's view ID is 400 (you'll need that for later).
Now that the item is scripted for your server go into your data folder and put the custom sprites into these directories:
data\sprite\
Start with the item IDs starting at 18000 (or IDs of your choice that haven't been taken already, if it does have the same ID, there'll be a crash and both the items will be discarded if I'm right)
In the item_db2, for a headger item I'm assuming, you type:
18200,sprite name(name of the spr and act file), item name, item type( put in 5 for headgear),cost of item(optional),selling price of item,item weight,,def,,slot,job ( 0xFFFFFFFF for every job would be a good start),upper( 7 for all class types to use the item), gender (2 for both genders to wear the item), Location( 256 for top headgear, 512 for mid-gear, 1 for bottom gear),,level required to equip the item,refineable (1 for yes, 0 for no), ViewID,{ OnEquip script }
So, in short the script for the item would look something like this:
18200,(sprite name here),(item name here),5,,10,****,4,,4,0xFFFFFFFF,7,2,1,,1,1,400,{},{},{}
so the script above shows that the item's ID is 18200, is a headgear, sells at 10z, item weight is 10, gives +4 def, has 4 slots on the item, both genders can eqiup it, and it's view ID is 400 (you'll need that for later).
Now that the item is scripted for your server go into your data folder and put the custom sprites into these directories:
data\sprite\