Register for your free account! | Forgot your password?

Go Back   elitepvpers > Popular Games > Silkroad Online > SRO Private Server
You last visited: Today at 22:29

  • Please register to post and access all features, it's quick, easy and FREE!

Advertisement



HOW TO ADD ITEM TO NPC...

Discussion on HOW TO ADD ITEM TO NPC... within the SRO Private Server forum part of the Silkroad Online category.

Closed Thread
 
Old   #1

 
devdash's Avatar
 
elite*gold: 14
Join Date: Feb 2016
Posts: 1,607
Received Thanks: 445
Exclamation HOW TO ADD ITEM TO NPC...

hello everyone <3
i have 2 questions i really need answer for it
1. how can i add bloodline key " Roc's Gate Key " to Accessroy shop hotan Tab2
2. how can i add ADV SOX B AND NORMAL B to Arena manager NPC Tab2
i have been looking for those 2 topics since 24 days ago
Thanks for READING.
devdash is offline  
Old 01/23/2018, 18:55   #2
 
elite*gold: 0
Join Date: Dec 2017
Posts: 13
Received Thanks: 8
Quote:
Originally Posted by alydandy View Post
hello everyone <3
i have 2 questions i really need answer for it
1. how can i add bloodline key " Roc's Gate Key " to Accessroy shop hotan Tab2
2. how can i add ADV SOX B AND NORMAL B to Arena manager NPC Tab2
i have been looking for those 2 topics since 24 days ago
Thanks for READING.
Use this query just Edit inside EDIT and EDIT END
Quote:
USE SRO_VT_SHARD
Declare @ItemID int
Declare @yourPrice int
Declare @WhichTAB varchar(74)

EDIT

SET @ItemID = 23 /* The Item ID of the Item you want to add to the NPC*/
SET @yourPrice = 5000 /* The price per Unit */
SET @WhichTAB = 'STORE_CH_POTION_TAB1' /* To which Tab at which NPC you want to add the Item*/

EDIT END

/* Codename instead of the ID */
Declare @CodeName varchar (74) SET @CodeName = (SELECT CodeName128 FROM _RefObjCommon WHERE ID = @ItemID)

/* Which Itemdata.txt is affected in the Media.pk2*/
Declare @newItemID varchar(5)
Declare @lastPrice varchar(25) SET @lastPrice = (SELECT Price FROM _RefObjCommon WHERE ID = @ItemID)
Declare @yourPriceCHAR varchar(25) SET @yourPriceCHAR = @yourPrice
IF (@ItemID < 5000) SET @newItemID = 5000
else if (@ItemID < 10000) SET @newItemID = 10000
else if (@ItemID < 15000) SET @newItemID = 15000
else if (@ItemID < 20000) SET @newItemID = 20000
else if (@ItemID < 25000) SET @newItemID = 25000
else if (@ItemID < 30000) SET @newItemID = 30000
else if (@ItemID < 35000) SET @newItemID = 35000
else if (@ItemID < 40000) SET @newItemID = 40000
else SET @newItemID = 45000
print ''
print @CodeName + ' from Media\server_dep\silkroad\textdata\itemdata_'+@new ItemID+'.txt'
print 'Change the current Price of '+@lastPrice+' to '+@yourPriceCHAR+' at the itemdata_'+@newItemID+'. (For the visual Price ingame)'
/*END which Itemdata.txr*/

/*for _RefObjCommon Price*/
UPDATE _RefObjCommon SET Price = @yourPrice WHERE ID = @ItemID

/* for _RefPackageItem */
IF EXISTS (SELECT CodeName128 FROM _RefPackageItem WHERE CodeName128 = 'Package_'+@CodeName)
BEGIN
print 'Already added @ RefPackageItem/.txt!'
END
ELSE BEGIN
Declare @SN varchar(74) SET @SN = (SELECT NameStrID128 FROM _RefObjCommon WHERE ID = @ItemID)
Declare @DESC varchar(74) SET @Desc = (SELECT DescStrID128 FROM _RefObjCommon WHERE ID = @ItemID)
Declare @DDJ varchar(74) SET @DDJ = (SELECT AssocFileIcon128 FROM _RefObjCommon WHERE ID = @ItemID)
INSERT INTO _RefPackageItem (Service,Country,CodeName128,SaleTag,ExpandTerm,Na meStrID,DescStrID,AssocFileIcon,Param1,Param1_Desc 128,Param2,Param2_Desc128,Param3,Param3_Desc128,Pa ram4,Param4_Desc128)
VALUES (1,15,'PACKAGE_'+@CodeName,0,'EXPAND_TERM_ALL',@SN ,@Desc,@DDJ,-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx')
Declare @TOPID varchar (10) SET @TOPID = (SELECT MAX(ID) FROM _RefPackageItem)
print ''
print 'Add the following line @ refpackageitem.txt'
print '1 15 '+@TOPID+' PACKAGE_'+@CodeName+' 0 EXPAND_TERM_ALL '+@SN+' '+@DESC+' '+@DDJ+' -1 xxx -1 xxx -1 xxx -1 xxx'
print ''
END

/* for _RefPricePolicyOfItem */
IF EXISTS (SELECT RefPackageItemCodeName FROM _RefPricePolicyOfItem WHERE RefPackageItemCodeName = 'Package_'+@CodeName AND PaymentDevice = 1 AND Cost = @yourPrice)
BEGIN
print 'Already added @ RefPricePolicyOfItem/.txt!'
END
ELSE BEGIN
INSERT INTO _RefPricePolicyOfItem (Service,Country,RefPackageItemCodeName,PaymentDev ice,PreviousCost,Cost,Param1,Param1_Desc128,Param2 ,Param2_Desc128,Param3,Param3_Desc128,Param4,Param 4_Desc128)
VALUES (1,15,'PACKAGE_'+@CodeName,1,0,@yourPrice,-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx')
Declare @NEWPRICE varchar(15) SET @NEWPRICE = @yourPrice
print ''
print 'Add the following line @ refpricepolicyofitem.txt'
print '1 15 PACKAGE_'+@CodeName+' 1 0 '+@NEWPRICE+' -1 xxx -1 xxx -1 xxx -1 xxx'
print ''
END

/* for _RefShopGoods */
IF EXISTS (SELECT RefPackageItemCodeName FROM _RefShopGoods WHERE RefPackageItemCodeName = 'Package_'+@CodeName AND RefTabCodeName = @WhichTAB)
BEGIN
print 'Already added @ RefShopGoods/.txt!'
END
ELSE BEGIN
Declare @newSLOTINDEX varchar(15) SET @newSLOTINDEX = (SELECT MAX(SlotIndex) FROM _RefShopGoods WHERE RefTabCodeName = @WhichTAB)+1
INSERT INTO _RefShopGoods (Service,Country,RefTabCodeName,RefPackageItemCode Name,SlotIndex,Param1,Param1_Desc128,Param2,Param2 _Desc128,Param3,Param3_Desc128,Param4,Param4_Desc1 28)
VALUES (1,15,@WhichTAB,'PACKAGE_'+@CodeName,@newSLOTINDEX ,-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx')
print ''
print 'Add the following line @ refshopgoods.txt'
print '1 15 '+@WhichTAB+' '+'PACKAGE_'+@CodeName+' '+@newSLOTINDEX+' -1 xxx -1 xxx -1 xxx -1 xxx'
print ''
END

/* for _RefScrapOfPackageItem */
IF EXISTS (SELECT RefPackageItemCodeName FROM _RefScrapOfPackageItem WHERE RefPackageItemCodeName = 'Package_'+@CodeName AND RefItemCodeName = @CodeName)
BEGIN
print 'Already added @ RefScrapOfPackageItem/.txt!'
END
ELSE BEGIN
INSERT INTO _RefScrapOfPackageItem (Service,Country,RefPackageItemCodeName,RefItemCod eName,OptLevel,Variance,Data,MagParamNum,MagParam1 ,MagParam2,MagParam3,MagParam4,MagParam5,MagParam6 ,MagParam7,MagParam8,MagParam9,MagParam10,MagParam 11,MagParam12,Param1,Param1_Desc128,Param2,Param2_ Desc128,Param3,Param3_Desc128,Param4,Param4_Desc12 8)
VALUES (1,15,'PACKAGE_'+@CodeName,@CodeName,0,0,0,0,0,0,0 ,0,0,0,0,0,0,0,0,0,-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx')
Declare @ScrapIndex varchar(15)
SET @ScrapIndex = (SELECT MAX([Index]) FROM _RefScrapOfPackageItem WHERE RefItemCodeName = @CodeName)
print ''
print 'Add the following line @ refscrapofpackageitem.txt'
print '1 15 '+'PACKAGE_'+@CodeName+' '+@CodeName+' 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 -1 xxx -1 xxx -1 xxx -1 xxx '+@ScrapIndex
print ''
END
print ''
print ''
print 'Done! Welcome alydandy :P'
heropt is offline  
Thanks
1 User
Old 01/23/2018, 19:13   #3

 
devdash's Avatar
 
elite*gold: 14
Join Date: Feb 2016
Posts: 1,607
Received Thanks: 445
Quote:
Originally Posted by heropt View Post
Use this query just Edit inside EDIT and EDIT END
so what should i do exactly with that query ? i mean i have to do something with media side too, right ? i mean ur query will just edit SQL, so what about Media ?
and what should i edit on the query exactly ? can u color it with deffrent color and explain please ? make ur answer better please....
thanks for ur answer <3
devdash is offline  
Old 01/23/2018, 19:24   #4
 
elite*gold: 0
Join Date: Dec 2017
Posts: 13
Received Thanks: 8
query to media

Quote:
Originally Posted by alydandy View Post
so what should i do exactly with that query ? i mean i have to do something with media side too, right ? i mean ur query will just edit SQL, so what about Media ?
and what should i edit on the query exactly ? can u color it with deffrent color and explain please ? make ur answer better please....
thanks for ur answer <3
this query will auto generate the needed lines for u insert in Media.pk2(Client Side)

Inside a query u maybe need edit or not

EDIT

USE SRO_VT_SHARD /*Change SRO_VT_SHARD to your database name
SET @ID = 23 /* The Item ID of the Item you want to add to the NPC*/
SET @Price = 5000 /* The price per Unit */
SET @TAB = 'STORE_CH_POTION_TAB1' /* To which Tab at which NPC you want to add the Item*/

EDIT END
heropt is offline  
Thanks
1 User
Old 01/23/2018, 19:36   #5

 
devdash's Avatar
 
elite*gold: 14
Join Date: Feb 2016
Posts: 1,607
Received Thanks: 445
Quote:
Originally Posted by heropt View Post
this query will auto generate the needed lines for u insert in Media.pk2(Client Side)
hmmmm i can't understand you still (
okay look u seems really nice guy that wants to help me so take this
this is the console code for the item that i want to add to Accessroy shop Hotan Tab2 Ch/EU
Code Console for the item: ITEM_QNO_RM_MEETROC_6_01
Price: 1b "1000000000"
u can give me Query to Edit SQL with it and File to import for Media so i make sure there's no crash or something cuz i know everything have to be edit on SQL and Media

Quote:
Originally Posted by heropt View Post
this query will auto generate the needed lines for u insert in Media.pk2(Client Side)

Inside a query u maybe need edit or not

EDIT

USE SRO_VT_SHARD /*Change SRO_VT_SHARD to your database name
SET @ID = 23 /* The Item ID of the Item you want to add to the NPC*/
SET @Price = 5000 /* The price per Unit */
SET @TAB = 'STORE_CH_POTION_TAB1' /* To which Tab at which NPC you want to add the Item*/

EDIT END
now i understand ur query exactly and that's good , but what about Media side ? i will get crash if i didn't do anything about it
devdash is offline  
Old 01/23/2018, 20:08   #6
 
elite*gold: 0
Join Date: Dec 2017
Posts: 13
Received Thanks: 8
i don't remember very well the right NPC name i dont have here db to test

so execute this query and send me result's

Quote:
use sro_vt_shard
SELECT * FROM _RefObjCommon WHERE CodeName128 like 'NPC_KT_%'
heropt is offline  
Thanks
1 User
Old 01/23/2018, 20:15   #7

 
devdash's Avatar
 
elite*gold: 14
Join Date: Feb 2016
Posts: 1,607
Received Thanks: 445
Quote:
Originally Posted by heropt View Post
i don't remember very well the right NPC name i dont have here db to test

so execute this query and send me result's
is that what u want ?
FOR EU : STORE_KT_ACCESSORY_EU_TAB2
FOR CH : STORE_KT_ACCESSORY_TAB2
i need to add it on those 2 pages on Eu and on CH , with slot number 2 in Tab2
devdash is offline  
Old 01/23/2018, 20:22   #8
 
elite*gold: 0
Join Date: Dec 2017
Posts: 13
Received Thanks: 8
u have team viewer i can config that for u....
heropt is offline  
Thanks
1 User
Old 01/23/2018, 20:27   #9

 
devdash's Avatar
 
elite*gold: 14
Join Date: Feb 2016
Posts: 1,607
Received Thanks: 445
Quote:
Originally Posted by heropt View Post
u have team viewer i can config that for u....
yes i do, but are u pro in this ? i mean i can't lose everything now so are u sure u wont do any mistaks ? cuz if u do , i will not be able to fix it later...iam so newbie , add me on Discord so we can connect..ALY AL-BATAL#8125
devdash is offline  
Old 01/23/2018, 20:35   #10
 
elite*gold: 0
Join Date: Dec 2017
Posts: 13
Received Thanks: 8
lol what a PRO services for u PAID services ?
PAID services dosen't mean PRO Workers
anyway bro i know what im do but...
Do you know The difference between a master and a beginner is that the master has failed more times than the beginner has ever tried....
heropt is offline  
Old 01/23/2018, 20:36   #11

 
devdash's Avatar
 
elite*gold: 14
Join Date: Feb 2016
Posts: 1,607
Received Thanks: 445
Quote:
Originally Posted by heropt View Post
u have team viewer i can config that for u....
iam waiting..........

Quote:
Originally Posted by heropt View Post
lol what a PRO services for u PAID services ?
PAID services dosen't mean PRO Workers
anyway bro i know what im do but...
Do you know The difference between a master and a beginner is that the master has failed more times than the beginner has ever tried....
nice one
okay lets just do it
add me on discord so i can send to u the Teamviwer pw..

Quote:
Originally Posted by heropt View Post
lol what a PRO services for u PAID services ?
PAID services dosen't mean PRO Workers
anyway bro i know what im do but...
Do you know The difference between a master and a beginner is that the master has failed more times than the beginner has ever tried....
did i say anything wrong to you ?...
anyway Thanks for ur answers man seriously u are a good example of good people.
guys help me please i still need help on this topic...
devdash is offline  
Old 01/27/2018, 08:36   #12


 
Spidy.'s Avatar
 
elite*gold: 1
Join Date: Oct 2012
Posts: 8,423
Received Thanks: 3,242
please use normal font next time.
Spidy. is offline  
Closed Thread


Similar Threads Similar Threads
looking for coder to add soul item npc and dmg- add npc
07/09/2011 - CO2 Private Server - 0 Replies
hey im looking for a coder that could add a npc which sells full dragon soul sets +12 -7 255 hp 2 soc for specific classes e.g. for a tro you would buy a soul set which has weapons armor coro necky boots armor and so on also i need a npc where you can buy dmg - to your equips for tortoise gems



All times are GMT +1. The time now is 22:30.


Powered by vBulletin®
Copyright ©2000 - 2026, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.
This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

Support | Contact Us | FAQ | Advertising | Privacy Policy | Terms of Service | Abuse
Copyright ©2026 elitepvpers All Rights Reserved.