How To Add Item to an NPC, Complete Guide Manual!

Results 1 to 4 of 4
  1. #1
    Head Developer LogiN is offline
    MemberRank
    Mar 2012 Join Date
    SROTEAMLocation
    283Posts

    idea How To Add Item to an NPC, Complete Guide Manual!

    Greetings Friends RageZone
    take me several minutes to make this guide which for many is absurd, but I'm sure for others interested them know what they are doing every time they use a query.

    The querys are very important, but in a time when we stop and know what we are doing in our database.
    people are starting to really understand how to make needed something .. and over time will understand the purpose of the Querys.

    Take this opportunity to give a shout out to my great friends thanks to the cooperation that we have to turn a lot in SilkRoad.

    - RevoLand
    - Chern0byl
    - egsro
    - sladlejrhfpq
    - InsaneDev
    - Arabianfox
    - Nemo07
    - Artuuro_lv
    - PX2000
    - androw3349


    and many others who have been through them take up their hands indefinite aid.
    Thanks!
    LoGiN®
    ----------------------------------------------------------------------------------

    ¿How to add an item to an NPC??

    Required: Database & Client
    Difficulty: Easy

    Procedure in Database:
    -- Open the table in SQL [dbo]._RefPackageItem, This table is the one that will pack the item as displayed in the store (NPC)
    Note: You can change that table "and any line you have to take it as a reference aggregate column"

    -- Open the table in SQL [dbo]._RefScrapOfPackageItem, This table is assumed that this in packet RefPackageItem which will require
    add additional options to be displayed, from Plus, Options, Durability etc. ..
    Use the same note RefPackageItem.

    -- Open the table in SQL [dbo]._RefPricePolicyOfItem, This table will define the price of the item and the currency is going to require this item.
    Use the same note RefPackageItem.

    -- Open the table in SQL [dbo]._RefShopGoods, This is the table that perhaps may be the "most important", why?, because in this table define,
    show where our item. if a ItemMall or a NPC (without this table will not be visible our item ever.)

    =========================================================================

    Started:
    _RefPackageItem:
    1 15 1 PACKAGE_ITEM_CH_SWORD_01_A 0 EXPAND_TERM_ALL SN_ITEM_CH_SWORD_01_C_RARE SN_ITEM_CH_SWORD_01_C_RARE_TT_DESC item\china\weapon\sword_01.ddj -1 xxx -1 xxx -1 xxx -1 xxx

    References:
    * PACKAGE_ITEM_CH_SWORD_01_A (this new name package for item)
    * item\china\weapon\sword_01.ddj
    We need this line the .ddj (icon to display in the inventory, that we take it out of RefObjItem)

    *SN_ITEM (This column starts with SN_ITEM which TextDataObj letter from the client the name of the item)

    *SN_ITEM_**TT_DESC (This column begins and ends with SN_ITEM, TT_DESC, which will display the description of the item)

    on line only aggregate data regarding our ITEM, which we pulled from the RefObjCommon


    _RefScrapOfPackageItem:
    1 15 PACKAGE_ITEM_CH_SWORD_01_A ITEM_CH_SWORD_01_C_RARE 5 0 71 0 0 0 0 0 0 0 0 0 0 0 0 0 -1 xxx -1 xxx -1 xxx -1 xxx 7426

    References:
    * 5 = Level of Item
    * 71 = Durability (EYE each item has its durability, it is obtained Dur_L column for "weapons", Dur_U for "items" of [dbo]._RefObjItem, column "Data")


    _RefPricePolicyOfItem:
    1 15 PACKAGE_ITEM_CH_BLADE_01_A 1 0 6710 0 xxx 0 xxx 0 xxx 0 xxx

    References:
    * 6710 = Price of Item
    * 1 = Type of Sale (1 = gold, 2 = silk)


    RefShopGoods:
    1 15 MALL_ARCHEMY_ASTRAL PACKAGE_ITEM_ETC_ARCHEMY_MAGICSTONE_ASTRAL_01 0 -1 xxx -1 xxx -1 xxx -1 xxx

    References:
    * MALL_ARCHEMY_ASTRAL = TAB where post the item
    * 0 = SlotIndex (This may not be duplicated, each item goes in a slot, from 0,1,2,3 ..... etc)

    We finished with Database.
    ======================================================================

    Edit for the client:
    Only copy the lines that we've created and put in our database and import it to our client.

    Path: Media\server_dep\silkroad\textdata\*
    *- refpackageitem.txt
    *- refscrapofpackageitem.txt
    *- refpricepolicyofitem.txt
    *- refshopgoods.txt

    NOTE:
    When editing on the side of the database, we must consider that adopts SQL identifiers to the lines to avoid duplicate ID lines, when we are editing we must know if we use "handles" or have writable columns in data.

    sql.jpg

    Greetings
    LoGiN®
    Last edited by LogiN; 10-12-12 at 02:03 AM.


  2. #2
    Banned nemo07 is offline
    BannedRank
    Sep 2011 Join Date
    HomeLocation
    284Posts

    Re: How To Add Item to an NPC, Complete Guide Manual!

    that's Really Easy and Good for the beginners nice Guide :)

  3. #3
    Extacy plýs !!! Eroticus is offline
    MemberRank
    Nov 2007 Join Date
    Israel <3Location
    500Posts

    Re: How To Add Item to an NPC, Complete Guide Manual!

    _RefScrapOfPackageItem:
    1 15 PACKAGE_ITEM_CH_SWORD_01_A ITEM_CH_SWORD_01_C_RARE 5 0 71 0 0 0 0 0 0 0 0 0 0 0 0 0 -1 xxx -1 xxx -1 xxx -1 xxx 7426


    ????

  4. #4
    Banned nemo07 is offline
    BannedRank
    Sep 2011 Join Date
    HomeLocation
    284Posts

    Re: How To Add Item to an NPC, Complete Guide Manual!

    Quote Originally Posted by Eroticus View Post
    _RefScrapOfPackageItem:
    1 15 PACKAGE_ITEM_CH_SWORD_01_A ITEM_CH_SWORD_01_C_RARE 5 0 71 0 0 0 0 0 0 0 0 0 0 0 0 0 -1 xxx -1 xxx -1 xxx -1 xxx 7426


    ????
    It just an ID , It doesn't affect on anything .



Advertisement