الموقع العربي الاول للعبة Silkroad Online

الموقع العربي الاول للعبة Silkroad Online (https://silkroad4arab.com/vb/index.php)
-   قسم الشروحات و البرامج المستخدمة في عمل السيرفرات الخاصة (https://silkroad4arab.com/vb/forumdisplay.php?f=289)
-   -   الان و حصريا علي سلك رود عمل NPC في 3mint Query (https://silkroad4arab.com/vb/showthread.php?t=474505)

ღ♥Alexandria♥ღ 04-01-2013 06:12 AM

الان و حصريا علي سلك رود عمل NPC في 3mint Query
 
http://www8.0zz0.com/2012/12/04/15/316384074.jpeg

السلام عليكم ورحمة الله وبركاته

الان و حصريا علي سلك رود عمل NPC في 3mint Query




كود PHP:

DECLARE @CHARNAME VARCHAR (30
DECLARE @
NPCNAME VARCHAR (30
DECLARE @
ADDNEW VARCHAR (30
DECLARE @
GAMEWORDID INT 
SET 
@CHARNAME 'DW' --U Char Name 
SET 
@NPCNAME '1' --U NPC NAME 
SET 
@GAMEWORDID --IMPORTANTGET GAMEWORLD ID FROM THE LOCALY U WANT ADD THE NPC NORMAL CITYs 
SET 
@ADDNEW 'NPC' 
-- 
IF @
ADDNEW 'NPC' BEGIN 
DECLARE @MAXLINK VARCHAR (30) = (SELECT MAX (IDFROM _RefObjChar)+
DECLARE @MAXCOMMONID VARCHAR (30) = (SELECT MAX (IDFROM _RefObjCommon)+
SET IDENTITY_INSERT _RefObjCommon ON 
INSERT INTO _RefObjCommon 
(Service,ID,CodeName128,ObjName128,OrgObjCodeName128,NameStrID128,DescStrID128,CashItem,Bionic,TypeID1,TypeID2,TypeID3,TypeID4,DecayTime,Country 
,Rarity,CanTrade,CanSell,CanBuy,CanBorrow,CanDrop,CanPick,CanRepair,CanRevive,CanUse,CanThrow,Price,CostRepair,CostRevive,CostBorrow,KeepingFee,SellPrice,ReqLevelType1,ReqLevel1,ReqLevelType2,ReqLevel2,ReqLevelType3,ReqLevel3,ReqLevelType4,ReqLevel4,MaxContain,RegionID,Dir,OffsetX,OffsetY,OffsetZ,Speed1,Speed2,Scale,BCHeight,BCRadius 
,EventID,AssocFileObj128,AssocFileDrop128,AssocFileIcon128,AssocFile1_128,AssocFile2_128,LinkVALUES 
(1,@MAXCOMMONID,'NPC_'+@NPCNAME,'xxx','xxx','SN_NPC_'+@NPCNAME,'xxx',0,1,1,2,2,0,5000,3,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,-1,0,-1,0,-1,0,-1,0,-1,0,0,0,0,0,0,0,100,0,0,0,'npc\npc\chinawoman_Noblegirl_event.bsr','xxx','xxx','xxx','xxx',@MAXLINK
SET IDENTITY_INSERT _RefObjCommon OFF 
SET IDENTITY_INSERT _RefObjChar ON 
INSERT INTO _RefObjChar 
(ID,Lvl,CharGender,MaxHP,MaxMP,ResistFrozen,ResistFrostbite,ResistBurn,ResistEShock,ResistPoison,ResistZombie,ResistSleep,ResistRoot,ResistSlow,ResistFear 
,ResistMyopia,ResistBlood,ResistStone,ResistDark,ResistStun,ResistDisea,ResistChaos,ResistCsePD,ResistCseMD,ResistCseSTR,ResistCseINT,ResistCseHP,ResistCseMP,Resist24,ResistBomb,Resist26 
,Resist27,Resist28,Resist29,Resist30,Resist31,Resist32,InventorySize,CanStore_TID1,CanStore_TID2,CanStore_TID3,CanStore_TID4,CanBeVehicle,CanControl,DamagePortion,MaxPassenger,AssocTactics,PD,MD,PAR,MAR,ER,BR,HR,CHR 
,ExpToGive,CreepType,Knockdown,KO_RecoverTime,DefaultSkill_1,DefaultSkill_2,DefaultSkill_3,DefaultSkill_4,DefaultSkill_5,DefaultSkill_6,DefaultSkill_7,DefaultSkill_8,DefaultSkill_9,DefaultSkill_10,TextureType,Except_1 
,Except_2,Except_3,Except_4,Except_5,Except_6,Except_7,Except_8,Except_9,Except_10,LinkVALUES 
(@MAXLINK,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,336860180,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
SET IDENTITY_INSERT _RefObjChar OFF 
SET IDENTITY_INSERT _RefShop ON 
DECLARE @ShopID VARCHAR (30) = (SELECT MAX (IDFROM _RefShop)+
INSERT INTO _RefShop 
(Service,Country,ID,CodeName128,Param1,Param1_Desc128,Param2,Param2_Desc128,Param3,Param3_Desc128,Param4,Param4_Desc128
VALUES (1,15,@ShopID,'STORE_'+@NPCNAME,-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx'
SET IDENTITY_INSERT _RefShop OFF 
SET IDENTITY_INSERT _RefShopGroup ON 
DECLARE @ShopGroupID VARCHAR (30) = (SELECT MAX (IDFROM _RefShopGroup)+
INSERT INTO _RefShopGroup 
(Service,Country,ID,CodeName128,RefNPCCodeName,Param1,Param1_Desc128,Param2,Param2_Desc128,Param3,Param3_Desc128,Param4,Param4_Desc128
VALUES (1,15,@ShopGroupID,'GROUP_STORE_'+@NPCNAME,'NPC_'+@NPCNAME,-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx'
SET IDENTITY_INSERT _RefShopGroup OFF 
SET IDENTITY_INSERT _RefShopItemGroup ON 
DECLARE @ShopItemID VARCHAR (30) = (SELECT MAX (GROUPIDFROM _RefShopItemGroup)+
INSERT INTO _RefShopItemGroup 
(Service,GroupID,CodeName128,StrID128_Group
VALUES (1,@ShopItemID,'STORE_'+@NPCNAME+'_GROUP1','SN_STORE_'+@NPCNAME+'_GROUP1'
SET IDENTITY_INSERT _RefShopItemGroup OFF 
SET IDENTITY_INSERT _RefShopTab ON 
DECLARE @ShopTabID VARCHAR (30)= (SELECT MAX (IDFROM _RefShopTab)+
INSERT INTO _RefShopTab 
(Service,Country,ID,CodeName128,RefTabGroupCodeName,StrID128_Tab
VALUES (1,15,@ShopTabID,'STORE_'+@NPCNAME+'_TAB1','STORE_'+@NPCNAME+'_GROUP1','SN_TAB_WEAPON'
SET IDENTITY_INSERT _RefShopTab OFF 
SET IDENTITY_INSERT _RefShopTabGroup ON 
DECLARE @ShopTabGroupID VARCHAR (30) = (SELECT MAX (IDFROM _RefShopTabGroup)+
INSERT INTO _RefShopTabGroup 
(Service,Country,ID,CodeName128,StrID128_Group
VALUES (1,15,@ShopTabGroupID,'STORE_'+@NPCNAME+'_GROUP1','SN_STORE_'+@NPCNAME+'_GROUP1'
SET IDENTITY_INSERT _RefShopTabGroup OFF 
INSERT INTO _RefMappingShopGroup VALUES 
(1,15,'GROUP_STORE_'+@NPCNAME,'STORE_'+@NPCNAME
INSERT INTO _RefMappingShopWithTab VALUES (1,15,'STORE_'+@NPCNAME,'STORE_'+@NPCNAME+'_GROUP1'
DECLARE @
TACTICSID INT SET @TACTICSID = (SELECT MAX (dwTacticsIDFROM Tab_RefTactics)+10 
INSERT INTO Tab_RefTactics VALUES 
(@TACTICSID,@MAXCOMMONID,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,'NPC_'+@NPCNAME
BEGIN
DECLARE @HIVEID INT  SET @HIVEID = (SELECT MAX (dwHiveIDFROM Tab_RefHive)+
INSERT INTO Tab_RefHive VALUES 
(@HIVEID,0,0,0,0,0,0,@GAMEWORDID,2,'NPC_'+@NPCNAME
END
BEGIN
DECLARE @REGION VARCHAR (30SET @REGION = (SELECT (LatestRegionFROM _Char WHERE CharName16 = @CHARNAME
DECLARE @
POSX VARCHAR (30SET @POSX = (SELECT (POSXFROM _Char WHERE CharName16 = @CHARNAME
DECLARE @
POSY VARCHAR (30SET @POSY = (SELECT (POSYFROM _Char WHERE CharName16 = @CHARNAME
DECLARE @
POSZ VARCHAR (30SET @POSZ = (SELECT (POSZFROM _Char WHERE CharName16 = @CHARNAME
DECLARE @
NESTID INT SET @NESTID = (SELECT MAX (dwNestIDFROM Tab_RefNest)+
INSERT INTO Tab_RefNest VALUES 
(@NESTID,@HIVEID,@TACTICSID,@REGION,@POSX,@POSY,@POSZ,0,0,0,0,0,0,1,0,1,0
END
PRINT 'add this line to characterdata_45000 @ server_dep\silkroad\textdata' 
PRINT '' 
PRINT '1    '+@MAXCOMMONID+'    '+@NPCNAME+'    xxx    xxx    '+'SN_NPC_'+@NPCNAME+'    xxx    0    1    1    2    2    0    5000    3    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    -1    0    -1    0    -1    0    -1    0    -1    0    0    0    0    0    0    0    100    0    0    0    npc\npc\chinawoman_Noblegirl_event.bsr    xxx    xxx    xxx    xxx    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    336860180    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0' 
PRINT '' 
PRINT 'Add this line to refshop.txt @ server_dep\silkroad\textdata' 
PRINT '' 
PRINT '1    15    '+@SHOPID+'    '+'STORE_'+@NPCNAME+'    -1    xxx    -1    xxx    -1    xxx    -1    xxx' 
PRINT '' 
PRINT 'Add this line to refshopgroup.txt @ server_dep\silkroad\textdata' 
PRINT '' 
PRINT '1    15    '+@SHOPGROUPID+'    '+'GROUP_STORE_'+@NPCNAME+'    '+'NPC_'+@NPCNAME+'    -1    xxx    -1    xxx    -1    xxx    -1    xxx' 
PRINT '' 
PRINT 'Add this line to shopgroupdata.txt @ server_dep\silkroad\textdata' 
PRINT '' 
PRINT '1    '+@SHOPITEMID+'    '+'STORE_'+@NPCNAME+'_GROUP1    '+'SN_STORE_'+@NPCNAME+'_GROUP1' 
PRINT '' 
PRINT 'Add this line to refshoptab.txt @ server_dep\silkroad\textdata' 
PRINT '' 
PRINT '1    15    '+@SHOPTABID+'    '+'STORE_'+@NPCNAME+'_TAB1    '+'STORE_'+@NPCNAME+'_GROUP1     SN_TAB_WEAPONS' 
PRINT '' 
PRINT 'Add this line to refshoptabgroup.txt @ server_dep\silkroad\textdata' 
PRINT '' 
PRINT '1    15    '+@SHOPTABGROUPID+'    '+'STORE_'+@NPCNAME+'_GROUP1    '+'SN_STORE_'+@NPCNAME+'_GROUP1' 
PRINT '' 
PRINT 'Add this line to refmappingshopgroup.txt @ server_dep\silkroad\textdata' 
PRINT '' 
PRINT '1    15    '+'GROUP_STORE_'+@NPCNAME+'    '+'STORE_'+@NPCNAME 
PRINT '' 
PRINT 'Add this line to refmappingshopwithtab.txt @ server_dep\silkroad\textdata' 
PRINT '' 
PRINT '1    15    '+'STORE_'+@NPCNAME+'    '+'STORE_'+@NPCNAME+'_GROUP1' 
PRINT '' 
PRINT 'A New NPC Has ADD Succesfuly Restart U Server and Login in '+@CHARNAME
END 

كود PHP:

ECLARE @CHARNAME VARCHAR (30)
DECLARE @
NPCNAME VARCHAR (30)
DECLARE @
ADDNEW VARCHAR (30)
DECLARE @
TABNAME VARCHAR (30)
DECLARE @
TABNUMBER VARCHAR (30
DECLARE @
TABNEW VARCHAR (30)
DECLARE @
GROUPNUMBER VARCHAR (30
DECLARE @
GROUPNEW VARCHAR (30)
--
SET @ADDNEW 'TAB' -- 'NPC' to add a new npc'TAB' for add a new Tab'GROUP' for add a new group!
SET @CHARNAME '[GM] Alexandria' --U Char Name
SET 
@NPCNAME 'Silkroad' --U NPC NAME
SET 
@GROUPNUMBER  1
SET 
@TABNUMBER 4
SET 
@TABNAME 'TEST'
--
IF @
TABNUMBER 2 SET @TABNEW '_TAB2'
IF @TABNUMBER 3 SET @TABNEW '_TAB3'
IF @TABNUMBER 4 SET @TABNEW '_TAB4'
IF @GROUPNUMBER 1 SET @GROUPNEW '_GROUP1'
IF @GROUPNUMBER  2 SET @GROUPNEW '_GROUP2'
IF @GROUPNUMBER  3 SET @GROUPNEW '_GROUP3'
IF @GROUPNUMBER  4 SET @GROUPNEW '_GROUP4'
IF @GROUPNUMBER  5 SET @GROUPNEW '_GROUP5'
IF @GROUPNUMBER  6 SET @GROUPNEW '_GROUP6'
IF @ADDNEW 'TAB' BEGIN
SET IDENTITY_INSERT _RefShopTab ON
DECLARE @ShopTabID VARCHAR (30SET @ShopTabID = (SELECT MAX (IDFROM _RefShopTab)+1
INSERT INTO _RefShopTab 
(Service,Country,ID,CodeName128,RefTabGroupCodeName,StrID128_Tab)
VALUES (1,15,@ShopTabID,'STORE_'+@NPCNAME+@TABNEW,'STORE_'+@NPCNAME+@GROUPNEW,'SN_'+@TABNAME)
SET IDENTITY_INSERT _RefShopTab OFF
PRINT ''
PRINT 'New Tab added Sucessfully add this new line to refshoptab.txt @ server_dep\silkroad\textdata' 
PRINT '1    15    '+@SHOPTABID+'    STORE_'+@NPCNAME+@TABNEW+'    STORE_'+@NPCNAME+@GROUPNEW+'     SN_TAB_'+@TABNAME
END 

كود PHP:

DECLARE @CHARNAME VARCHAR (30)
DECLARE @
NPCNAME VARCHAR (30)
DECLARE @
ADDNEW VARCHAR (30)
DECLARE @
GROUPNUMBER VARCHAR (30
DECLARE @
GROUPNEW VARCHAR (30)
SET @CHARNAME '[GM] Alexandria' --U Char Name
SET 
@NPCNAME 'Silkroad' --U NPC NAME
SET 
@GROUPNUMBER  2
SET 
@ADDNEW 'GROUP'
--
IF @
GROUPNUMBER  2 SET @GROUPNEW '_GROUP2'
IF @GROUPNUMBER  3 SET @GROUPNEW '_GROUP3'
IF @GROUPNUMBER  4 SET @GROUPNEW '_GROUP4'
IF @GROUPNUMBER  5 SET @GROUPNEW '_GROUP5'
IF @GROUPNUMBER  6 SET @GROUPNEW '_GROUP6'
IF @ADDNEW 'GROUP' BEGIN 
SET IDENTITY_INSERT _RefShopTabGroup ON
DECLARE @ShopTabGroupID VARCHAR (30SET @ShopTabGroupID = (SELECT MAX (IDFROM _RefShopTabGroup)+1
INSERT INTO _RefShopTabGroup 
(Service,Country,ID,CodeName128,StrID128_Group)
VALUES (1,15,@ShopTabGroupID,'STORE_'+@NPCNAME+@GROUPNEW,'SN_STORE_'+@NPCNAME+@GROUPNEW)
SET IDENTITY_INSERT _RefShopTabGroup OFF
INSERT INTO _RefMappingShopWithTab VALUES 
(1,15,'STORE_'+@NPCNAME,'STORE_'+@NPCNAME+@GROUPNEW)
PRINT 
''
PRINT 'New Group Added Succesfully '
PRINT 'add this new line to refshoptabgroup.txt @ server_dep\silkroad\textdata'
PRINT '1    15    '+@SHOPTABGROUPID+'    STORE_'+@NPCNAME+@GROUPNEW+'    SN_STORE_'+@NPCNAME+@GROUPNEW
PRINT ''
PRINT 'add this new line to refmappingshopwithtab.txt @ server_dep\silkroad\textdata'
PRINT '1    15    STORE_'+@NPCNAME+'    STORE_'+@NPCNAME+@GROUPNEW
END 

هناه كلو في وحد


كود PHP:

DECLARE @CHARNAME VARCHAR (30)
DECLARE @
NPCNAME VARCHAR (30)
DECLARE @
ADDNEW VARCHAR (30)
DECLARE @
TABNAME VARCHAR (30)
DECLARE @
TABNUMBER VARCHAR (30
DECLARE @
TABNEW VARCHAR (30)
DECLARE @
GROUPNUMBER VARCHAR (30
DECLARE @
GROUPNEW VARCHAR (30)
DECLARE @
GAMEWORDID INT

SET 
@ADDNEW 'NPC' -- 'NPC' to add a new npc'TAB' for add a new Tab'GROUP' for add a new group!
SET @CHARNAME '[GM] ALEXANDRIA' --U Char Name
SET 
@NPCNAME 'SILKROAD' --U NPC NAME
SET 
@GAMEWORDID --IMPORTANTGET GAMEWORLD ID FROM THE LOCALY U WANT ADD THE NPC NORMAL CITYs 1
SET 
@GROUPNUMBER  1
SET 
@TABNUMBER 2
SET 
@TABNAME 'DRESS'

--
IF @
ADDNEW 'NPC' BEGIN
DECLARE @MAXLINK VARCHAR (30) = (SELECT MAX (IDFROM _RefObjChar)+1
DECLARE @MAXCOMMONID VARCHAR (30) = (SELECT MAX (IDFROM _RefObjCommon)+1
SET IDENTITY_INSERT _RefObjCommon ON
INSERT INTO _RefObjCommon 
(Service,ID,CodeName128,ObjName128,OrgObjCodeName128,NameStrID128,DescStrID128,CashItem,Bionic,TypeID1,TypeID2,TypeID3,TypeID4,DecayTime,Country
,Rarity,CanTrade,CanSell,CanBuy,CanBorrow,CanDrop,CanPick,CanRepair,CanRevive,CanUse,CanThrow,Price,CostRepair,CostRevive,CostBorrow,KeepingFee,SellPrice,ReqLevelType1,ReqLevel1,ReqLevelType2,ReqLevel2,ReqLevelType3,ReqLevel3,ReqLevelType4,ReqLevel4,MaxContain,RegionID,Dir,OffsetX,OffsetY,OffsetZ,Speed1,Speed2,Scale,BCHeight,BCRadius
,EventID,AssocFileObj128,AssocFileDrop128,AssocFileIcon128,AssocFile1_128,AssocFile2_128,LinkVALUES
(1,@MAXCOMMONID,'NPC_'+@NPCNAME,'xxx','xxx','SN_NPC_'+@NPCNAME,'xxx',0,1,1,2,2,0,5000,3,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,-1,0,-1,0,-1,0,-1,0,-1,0,0,0,0,0,0,0,100,0,0,0,'npc\npc\chinawoman_Noblegirl_event.bsr','xxx','xxx','xxx','xxx',@MAXLINK)
SET IDENTITY_INSERT _RefObjCommon OFF
SET IDENTITY_INSERT _RefObjChar ON
INSERT INTO _RefObjChar 
(ID,Lvl,CharGender,MaxHP,MaxMP,ResistFrozen,ResistFrostbite,ResistBurn,ResistEShock,ResistPoison,ResistZombie,ResistSleep,ResistRoot,ResistSlow,ResistFear
,ResistMyopia,ResistBlood,ResistStone,ResistDark,ResistStun,ResistDisea,ResistChaos,ResistCsePD,ResistCseMD,ResistCseSTR,ResistCseINT,ResistCseHP,ResistCseMP,Resist24,ResistBomb,Resist26
,Resist27,Resist28,Resist29,Resist30,Resist31,Resist32,InventorySize,CanStore_TID1,CanStore_TID2,CanStore_TID3,CanStore_TID4,CanBeVehicle,CanControl,DamagePortion,MaxPassenger,AssocTactics,PD,MD,PAR,MAR,ER,BR,HR,CHR
,ExpToGive,CreepType,Knockdown,KO_RecoverTime,DefaultSkill_1,DefaultSkill_2,DefaultSkill_3,DefaultSkill_4,DefaultSkill_5,DefaultSkill_6,DefaultSkill_7,DefaultSkill_8,DefaultSkill_9,DefaultSkill_10,TextureType,Except_1
,Except_2,Except_3,Except_4,Except_5,Except_6,Except_7,Except_8,Except_9,Except_10,LinkVALUES
(@MAXLINK,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,336860180,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0)
SET IDENTITY_INSERT _RefObjChar OFF
SET IDENTITY_INSERT _RefShop ON
DECLARE @ShopID VARCHAR (30) = (SELECT MAX (IDFROM _RefShop)+1
INSERT INTO _RefShop 
(Service,Country,ID,CodeName128,Param1,Param1_Desc128,Param2,Param2_Desc128,Param3,Param3_Desc128,Param4,Param4_Desc128)
VALUES (1,15,@ShopID,'STORE_'+@NPCNAME,-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx')
SET IDENTITY_INSERT _RefShop OFF
SET IDENTITY_INSERT _RefShopGroup ON
DECLARE @ShopGroupID VARCHAR (30) = (SELECT MAX (IDFROM _RefShopGroup)+1
INSERT INTO _RefShopGroup 
(Service,Country,ID,CodeName128,RefNPCCodeName,Param1,Param1_Desc128,Param2,Param2_Desc128,Param3,Param3_Desc128,Param4,Param4_Desc128)
VALUES (1,15,@ShopGroupID,'GROUP_STORE_'+@NPCNAME,'NPC_'+@NPCNAME,-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx')
SET IDENTITY_INSERT _RefShopGroup OFF
SET IDENTITY_INSERT _RefShopItemGroup ON
DECLARE @ShopItemID VARCHAR (30) = (SELECT MAX (GROUPIDFROM _RefShopItemGroup)+1
INSERT INTO _RefShopItemGroup 
(Service,GroupID,CodeName128,StrID128_Group)
VALUES (1,@ShopItemID,'STORE_'+@NPCNAME+'_GROUP1','SN_STORE_'+@NPCNAME+'_GROUP1')
SET IDENTITY_INSERT _RefShopItemGroup OFF
SET IDENTITY_INSERT _RefShopTab ON
DECLARE @ShopTabID VARCHAR (30)= (SELECT MAX (IDFROM _RefShopTab)+1
INSERT INTO _RefShopTab 
(Service,Country,ID,CodeName128,RefTabGroupCodeName,StrID128_Tab)
VALUES (1,15,@ShopTabID,'STORE_'+@NPCNAME+'_TAB1','STORE_'+@NPCNAME+'_GROUP1','SN_TAB_WEAPON')
SET IDENTITY_INSERT _RefShopTab OFF
SET IDENTITY_INSERT _RefShopTabGroup ON
DECLARE @ShopTabGroupID VARCHAR (30) = (SELECT MAX (IDFROM _RefShopTabGroup)+1
INSERT INTO _RefShopTabGroup 
(Service,Country,ID,CodeName128,StrID128_Group)
VALUES (1,15,@ShopTabGroupID,'STORE_'+@NPCNAME+'_GROUP1','SN_STORE_'+@NPCNAME+'_GROUP1')
SET IDENTITY_INSERT _RefShopTabGroup OFF
INSERT INTO _RefMappingShopGroup VALUES 
(1,15,'GROUP_STORE_'+@NPCNAME,'STORE_'+@NPCNAME)
INSERT INTO _RefMappingShopWithTab VALUES (1,15,'STORE_'+@NPCNAME,'STORE_'+@NPCNAME+'_GROUP1')
DECLARE @
TACTICSID INT SET @TACTICSID = (SELECT MAX (dwTacticsIDFROM Tab_RefTactics)+10
INSERT INTO Tab_RefTactics VALUES
(@TACTICSID,@MAXCOMMONID,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,'NPC_'+@NPCNAME)
DECLARE @
HIVEID INT  SET @HIVEID = (SELECT MAX (dwHiveIDFROM Tab_RefHive)+1
INSERT INTO Tab_RefHive VALUES
(@HIVEID,0,0,0,0,0,0,@GAMEWORDID,2,'NPC_'+@NPCNAME)
DECLARE @
REGION VARCHAR (30SET @REGION = (SELECT (LatestRegionFROM _Char WHERE CharName16 = @CHARNAME)
DECLARE @
POSX VARCHAR (30SET @POSX = (SELECT (POSXFROM _Char WHERE CharName16 = @CHARNAME)
DECLARE @
POSY VARCHAR (30SET @POSY = (SELECT (POSYFROM _Char WHERE CharName16 = @CHARNAME)
DECLARE @
POSZ VARCHAR (30SET @POSZ = (SELECT (POSZFROM _Char WHERE CharName16 = @CHARNAME)
DECLARE @
NESTID INT SET @NESTID = (SELECT MAX (dwNestIDFROM Tab_RefNest)+1
INSERT INTO Tab_RefNest VALUES
(@NESTID,@HIVEID,@TACTICSID,@REGION,@POSX,@POSY,@POSZ,0,0,0,0,0,0,1,0,1,0)
PRINT 
'add this line to characterdata_45000 @ server_dep\silkroad\textdata'
PRINT ''
PRINT '1    '+@MAXCOMMONID+'    '+@NPCNAME+'    xxx    xxx    '+'SN_NPC_'+@NPCNAME+'    xxx    0    1    1    2    2    0    5000    3    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    -1    0    -1    0    -1    0    -1    0    -1    0    0    0    0    0    0    0    100    0    0    0    npc\npc\chinawoman_Noblegirl_event.bsr    xxx    xxx    xxx    xxx    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    336860180    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0'
PRINT ''
PRINT 'Add this line to refshop.txt @ server_dep\silkroad\textdata'
PRINT ''
PRINT '1    15    '+@SHOPID+'    '+'STORE_'+@NPCNAME+'    -1    xxx    -1    xxx    -1    xxx    -1    xxx'
PRINT ''
PRINT 'Add this line to refshopgroup.txt @ server_dep\silkroad\textdata'
PRINT ''
PRINT '1    15    '+@SHOPGROUPID+'    '+'GROUP_STORE_'+@NPCNAME+'    '+'NPC_'+@NPCNAME+'    -1    xxx    -1    xxx    -1    xxx    -1    xxx'
PRINT ''
PRINT 'Add this line to shopgroupdata.txt @ server_dep\silkroad\textdata'
PRINT ''
PRINT '1    '+@SHOPITEMID+'    '+'STORE_'+@NPCNAME+'_GROUP1    '+'SN_STORE_'+@NPCNAME+'_GROUP1'
PRINT ''
PRINT 'Add this line to refshoptab.txt @ server_dep\silkroad\textdata'
PRINT ''
PRINT '1    15    '+@SHOPTABID+'    '+'STORE_'+@NPCNAME+'_TAB1    '+'STORE_'+@NPCNAME+'_GROUP1     SN_TAB_WEAPONS'
PRINT ''
PRINT 'Add this line to refshoptabgroup.txt @ server_dep\silkroad\textdata'
PRINT ''
PRINT '1    15    '+@SHOPTABGROUPID+'    '+'STORE_'+@NPCNAME+'_GROUP1    '+'SN_STORE_'+@NPCNAME+'_GROUP1'
PRINT ''
PRINT 'Add this line to refmappingshopgroup.txt @ server_dep\silkroad\textdata'
PRINT ''
PRINT '1    15    '+'GROUP_STORE_'+@NPCNAME+'    '+'STORE_'+@NPCNAME
PRINT ''
PRINT 'Add this line to refmappingshopwithtab.txt @ server_dep\silkroad\textdata'
PRINT ''
PRINT '1    15    '+'STORE_'+@NPCNAME+'    '+'STORE_'+@NPCNAME+'_GROUP1'
PRINT ''
PRINT 'A New NPC Has ADD Succesfuly Restart U Server and Login in '+@CHARNAME
END
IF @TABNUMBER 2 SET @TABNEW 'STORE_'+@NPCNAME+'_TAB2'
IF @TABNUMBER 3 SET @TABNEW 'STORE_'+@NPCNAME+'_TAB3'
IF @TABNUMBER 4 SET @TABNEW 'STORE_'+@NPCNAME+'_TAB4'
IF @GROUPNUMBER  2 SET @GROUPNEW '_GROUP2'
IF @GROUPNUMBER  3 SET @GROUPNEW '_GROUP3'
IF @GROUPNUMBER  4 SET @GROUPNEW '_GROUP4'
IF @GROUPNUMBER  5 SET @GROUPNEW '_GROUP5'
IF @GROUPNUMBER  6 SET @GROUPNEW '_GROUP6'
IF @ADDNEW 'GROUP' BEGIN 
SET IDENTITY_INSERT _RefShopTabGroup ON
SET 
@ShopTabGroupID = (SELECT MAX (IDFROM _RefShopTabGroup)+1
INSERT INTO _RefShopTabGroup 
(Service,Country,ID,CodeName128,StrID128_Group)
VALUES (1,15,@ShopTabGroupID,'STORE_'+@NPCNAME+@GROUPNEW,'SN_STORE_'+@NPCNAME+@GROUPNEW)
SET IDENTITY_INSERT _RefShopTabGroup OFF
INSERT INTO _RefMappingShopWithTab VALUES 
(1,15,'STORE_'+@NPCNAME,'STORE_'+@NPCNAME+@GROUPNEW)
PRINT 
''
PRINT 'New Group Added Succesfully '
PRINT 'add this new line to refshoptabgroup.txt @ server_dep\silkroad\textdata'
PRINT '1    15    '+@SHOPTABGROUPID+'    STORE_'+@NPCNAME+@GROUPNEW+'    SN_STORE_'+@NPCNAME+@GROUPNEW
PRINT ''
PRINT 'add this new line to refmappingshopwithtab.txt @ server_dep\silkroad\textdata'
PRINT '1    15    STORE_'+@NPCNAME+'    STORE_'+@NPCNAME+@GROUPNEW

END

IF @ADDNEW 'TAB' BEGIN
IF @GROUPNUMBER 1 SET @GROUPNEW '_GROUP1'
SET IDENTITY_INSERT _RefShopTab ON
SET 
@ShopTabID = (SELECT MAX (IDFROM _RefShopTab)+1
INSERT INTO _RefShopTab 
(Service,Country,ID,CodeName128,RefTabGroupCodeName,StrID128_Tab)
VALUES (1,15,@ShopTabID,@TABNEW,'STORE_'+@NPCNAME+@GROUPNEW,'SN_'+@TABNAME)
SET IDENTITY_INSERT _RefShopTab OFF
PRINT ''
PRINT 'New Tab added Sucessfully add this new line to refshoptab.txt @ server_dep\silkroad\textdata' 
PRINT '1    15    '+@SHOPTABID+'    STORE_'+@NPCNAME+@TABNEW+'    STORE_'+@NPCNAME+@GROUPNEW+'     SN_TAB_'+@TABNAME
END
IF @TABNUMBER 4 BEGIN
PRINT '@TABNUMBER value does not exist. u must add 2 , 3 OR 4 Tabs Per NPC!'
END
IF @GROUPNUMBER 8 BEGIN
PRINT '@GROUPNUMBER value does not exist. u must add  1 , 2 , 3 , 4 , 5 , 6 , 7 OR 8 Groups!'
END
IF @ADDNEW '' BEGIN
PRINT '@ADDNEW value does not exist. u must set values NPC , TAB , GROUP'
END 


nesrelshark 04-01-2013 06:48 AM

تمام الله ينور عليك

ღ♥Alexandria♥ღ 04-01-2013 06:49 AM

اقتباس:

المشاركة الأصلية كتبت بواسطة nesrelshark (المشاركة 4501603)
تمام الله ينور عليك

ِشكران

و انشاء الله في الحسن من كده :]

$Waxy 04-01-2013 09:19 AM

شغال

ღ♥Alexandria♥ღ 04-01-2013 09:35 AM

اقتباس:

المشاركة الأصلية كتبت بواسطة $Waxy (المشاركة 4501642)
شغال

ِشكرا

Ultra Games 04-01-2013 10:05 AM

Thanks

[GM]Tormentor 04-01-2013 05:51 PM

شكرا على الموضوع بس بصرحة انا مش فهموا

kingahmed696 04-01-2013 06:03 PM

اقتباس:

المشاركة الأصلية كتبت بواسطة mneam001 (المشاركة 4501591)
http://www8.0zz0.com/2012/12/04/15/316384074.jpeg

السلام عليكم ورحمة الله وبركاته

الان و حصريا علي سلك رود عمل npc في 3mint query




كود PHP:

declare @charname varchar (30
declare @
npcname varchar (30
declare @
addnew varchar (30
declare @
gamewordid int 
set 
@charname 'dw' --u char name 
set 
@npcname '1' --u npc name 
set 
@gamewordid --importantGet gameworld id from the localy u want add the npc normal citys 
set 
@addnew 'npc' 
-- 
if @
addnew 'npc' begin 
declare @maxlink varchar (30) = (select max (idfrom _refobjchar)+
declare @maxcommonid varchar (30) = (select max (idfrom _refobjcommon)+
set identity_insert _refobjcommon on 
insert into _refobjcommon 
(service,id,codename128,objname128,orgobjcodename128,namestrid128,descstrid128,cashitem,bionic,typeid1,typeid2,typeid3,typeid4,decaytime,country 
,rarity,cantrade,cansell,canbuy,canborrow,candrop,canpick,canrepair,canrevive,canuse,canthrow,price,costrepair,costrevive,costborrow,keepingfee,sellprice,reqleveltype1,reqlevel1,reqleveltype2,reqlevel2,reqleveltype3,reqlevel3,reqleveltype4,reqlevel4,maxcontain,regionid,dir,offsetx,offsety,offsetz,speed1,speed2,scale,bcheight,bcradius 
,eventid,assocfileobj128,assocfiledrop128,assocfileicon128,assocfile1_128,assocfile2_128,linkvalues 
(1,@maxcommonid,'npc_'+@npcname,'xxx','xxx','sn_npc_'+@npcname,'xxx',0,1,1,2,2,0,5000,3,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,-1,0,-1,0,-1,0,-1,0,-1,0,0,0,0,0,0,0,100,0,0,0,'npc\npc\chinawoman_noblegirl_event.bsr','xxx','xxx','xxx','xxx',@maxlink
set identity_insert _refobjcommon off 
set identity_insert _refobjchar on 
insert into _refobjchar 
(id,lvl,chargender,maxhp,maxmp,resistfrozen,resistfrostbite,resistburn,resisteshock,resistpoison,resistzombie,resistsleep,resistroot,resistslow,resistfear 
,resistmyopia,resistblood,resiststone,resistdark,resiststun,resistdisea,resistchaos,resistcsepd,resistcsemd,resistcsestr,resistcseint,resistcsehp,resistcsemp,resist24,resistbomb,resist26 
,resist27,resist28,resist29,resist30,resist31,resist32,inventorysize,canstore_tid1,canstore_tid2,canstore_tid3,canstore_tid4,canbevehicle,cancontrol,damageportion,maxpassenger,assoctactics,pd,md,par,mar,er,br,hr,chr 
,exptogive,creeptype,knockdown,ko_recovertime,defaultskill_1,defaultskill_2,defaultskill_3,defaultskill_4,defaultskill_5,defaultskill_6,defaultskill_7,defaultskill_8,defaultskill_9,defaultskill_10,texturetype,except_1 
,except_2,except_3,except_4,except_5,except_6,except_7,except_8,except_9,except_10,linkvalues 
(@maxlink,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,336860180,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
set identity_insert _refobjchar off 
set identity_insert _refshop on 
declare @shopid varchar (30) = (select max (idfrom _refshop)+
insert into _refshop 
(service,country,id,codename128,param1,param1_desc128,param2,param2_desc128,param3,param3_desc128,param4,param4_desc128
values (1,15,@shopid,'store_'+@npcname,-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx'
set identity_insert _refshop off 
set identity_insert _refshopgroup on 
declare @shopgroupid varchar (30) = (select max (idfrom _refshopgroup)+
insert into _refshopgroup 
(service,country,id,codename128,refnpccodename,param1,param1_desc128,param2,param2_desc128,param3,param3_desc128,param4,param4_desc128
values (1,15,@shopgroupid,'group_store_'+@npcname,'npc_'+@npcname,-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx'
set identity_insert _refshopgroup off 
set identity_insert _refshopitemgroup on 
declare @shopitemid varchar (30) = (select max (groupidfrom _refshopitemgroup)+
insert into _refshopitemgroup 
(service,groupid,codename128,strid128_group
values (1,@shopitemid,'store_'+@npcname+'_group1','sn_store_'+@npcname+'_group1'
set identity_insert _refshopitemgroup off 
set identity_insert _refshoptab on 
declare @shoptabid varchar (30)= (select max (idfrom _refshoptab)+
insert into _refshoptab 
(service,country,id,codename128,reftabgroupcodename,strid128_tab
values (1,15,@shoptabid,'store_'+@npcname+'_tab1','store_'+@npcname+'_group1','sn_tab_weapon'
set identity_insert _refshoptab off 
set identity_insert _refshoptabgroup on 
declare @shoptabgroupid varchar (30) = (select max (idfrom _refshoptabgroup)+
insert into _refshoptabgroup 
(service,country,id,codename128,strid128_group
values (1,15,@shoptabgroupid,'store_'+@npcname+'_group1','sn_store_'+@npcname+'_group1'
set identity_insert _refshoptabgroup off 
insert into _refmappingshopgroup values 
(1,15,'group_store_'+@npcname,'store_'+@npcname
insert into _refmappingshopwithtab values (1,15,'store_'+@npcname,'store_'+@npcname+'_group1'
declare @
tacticsid int set @tacticsid = (select max (dwtacticsidfrom tab_reftactics)+10 
insert into tab_reftactics values 
(@tacticsid,@maxcommonid,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,'npc_'+@npcname
begin
declare @hiveid int  set @hiveid = (select max (dwhiveidfrom tab_refhive)+
insert into tab_refhive values 
(@hiveid,0,0,0,0,0,0,@gamewordid,2,'npc_'+@npcname
end
begin
declare @region varchar (30set @region = (select (latestregionfrom _char where charname16 = @charname
declare @
posx varchar (30set @posx = (select (posxfrom _char where charname16 = @charname
declare @
posy varchar (30set @posy = (select (posyfrom _char where charname16 = @charname
declare @
posz varchar (30set @posz = (select (poszfrom _char where charname16 = @charname
declare @
nestid int set @nestid = (select max (dwnestidfrom tab_refnest)+
insert into tab_refnest values 
(@nestid,@hiveid,@tacticsid,@region,@posx,@posy,@posz,0,0,0,0,0,0,1,0,1,0
end
print 'add this line to characterdata_45000 @ server_dep\silkroad\textdata' 
print '' 
print '1    '+@maxcommonid+'    '+@npcname+'    xxx    xxx    '+'sn_npc_'+@npcname+'    xxx    0    1    1    2    2    0    5000    3    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    -1    0    -1    0    -1    0    -1    0    -1    0    0    0    0    0    0    0    100    0    0    0    npc\npc\chinawoman_noblegirl_event.bsr    xxx    xxx    xxx    xxx    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    336860180    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0' 
print '' 
print 'add this line to refshop.txt @ server_dep\silkroad\textdata' 
print '' 
print '1    15    '+@shopid+'    '+'store_'+@npcname+'    -1    xxx    -1    xxx    -1    xxx    -1    xxx' 
print '' 
print 'add this line to refshopgroup.txt @ server_dep\silkroad\textdata' 
print '' 
print '1    15    '+@shopgroupid+'    '+'group_store_'+@npcname+'    '+'npc_'+@npcname+'    -1    xxx    -1    xxx    -1    xxx    -1    xxx' 
print '' 
print 'add this line to shopgroupdata.txt @ server_dep\silkroad\textdata' 
print '' 
print '1    '+@shopitemid+'    '+'store_'+@npcname+'_group1    '+'sn_store_'+@npcname+'_group1' 
print '' 
print 'add this line to refshoptab.txt @ server_dep\silkroad\textdata' 
print '' 
print '1    15    '+@shoptabid+'    '+'store_'+@npcname+'_tab1    '+'store_'+@npcname+'_group1     sn_tab_weapons' 
print '' 
print 'add this line to refshoptabgroup.txt @ server_dep\silkroad\textdata' 
print '' 
print '1    15    '+@shoptabgroupid+'    '+'store_'+@npcname+'_group1    '+'sn_store_'+@npcname+'_group1' 
print '' 
print 'add this line to refmappingshopgroup.txt @ server_dep\silkroad\textdata' 
print '' 
print '1    15    '+'group_store_'+@npcname+'    '+'store_'+@npcname 
print '' 
print 'add this line to refmappingshopwithtab.txt @ server_dep\silkroad\textdata' 
print '' 
print '1    15    '+'store_'+@npcname+'    '+'store_'+@npcname+'_group1' 
print '' 
print 'a new npc has add succesfuly restart u server and login in '+@charname
end 

كود PHP:

eclare @charname varchar (30)
declare @
npcname varchar (30)
declare @
addnew varchar (30)
declare @
tabname varchar (30)
declare @
tabnumber varchar (30
declare @
tabnew varchar (30)
declare @
groupnumber varchar (30
declare @
groupnew varchar (30)
--
set @addnew 'tab' -- 'npc' to add a new npc'tab' for add a new tab'group' for add a new group!
Set @charname '[gm] alexandria' --u char name
set 
@npcname 'silkroad' --u npc name
set 
@groupnumber  1
set 
@tabnumber 4
set 
@tabname 'test'
--
if @
tabnumber 2 set @tabnew '_tab2'
if @tabnumber 3 set @tabnew '_tab3'
if @tabnumber 4 set @tabnew '_tab4'
if @groupnumber 1 set @groupnew '_group1'
if @groupnumber  2 set @groupnew '_group2'
if @groupnumber  3 set @groupnew '_group3'
if @groupnumber  4 set @groupnew '_group4'
if @groupnumber  5 set @groupnew '_group5'
if @groupnumber  6 set @groupnew '_group6'
if @addnew 'tab' begin
set identity_insert _refshoptab on
declare @shoptabid varchar (30set @shoptabid = (select max (idfrom _refshoptab)+1
insert into _refshoptab 
(service,country,id,codename128,reftabgroupcodename,strid128_tab)
values (1,15,@shoptabid,'store_'+@npcname+@tabnew,'store_'+@npcname+@groupnew,'sn_'+@tabname)
set identity_insert _refshoptab off
print ''
print 'new tab added sucessfully add this new line to refshoptab.txt @ server_dep\silkroad\textdata' 
print '1    15    '+@shoptabid+'    store_'+@npcname+@tabnew+'    store_'+@npcname+@groupnew+'     sn_tab_'+@tabname
end 

كود PHP:

declare @charname varchar (30)
declare @
npcname varchar (30)
declare @
addnew varchar (30)
declare @
groupnumber varchar (30
declare @
groupnew varchar (30)
set @charname '[gm] alexandria' --u char name
set 
@npcname 'silkroad' --u npc name
set 
@groupnumber  2
set 
@addnew 'group'
--
if @
groupnumber  2 set @groupnew '_group2'
if @groupnumber  3 set @groupnew '_group3'
if @groupnumber  4 set @groupnew '_group4'
if @groupnumber  5 set @groupnew '_group5'
if @groupnumber  6 set @groupnew '_group6'
if @addnew 'group' begin 
set identity_insert _refshoptabgroup on
declare @shoptabgroupid varchar (30set @shoptabgroupid = (select max (idfrom _refshoptabgroup)+1
insert into _refshoptabgroup 
(service,country,id,codename128,strid128_group)
values (1,15,@shoptabgroupid,'store_'+@npcname+@groupnew,'sn_store_'+@npcname+@groupnew)
set identity_insert _refshoptabgroup off
insert into _refmappingshopwithtab values 
(1,15,'store_'+@npcname,'store_'+@npcname+@groupnew)
print 
''
print 'new group added succesfully '
print 'add this new line to refshoptabgroup.txt @ server_dep\silkroad\textdata'
print '1    15    '+@shoptabgroupid+'    store_'+@npcname+@groupnew+'    sn_store_'+@npcname+@groupnew
print ''
print 'add this new line to refmappingshopwithtab.txt @ server_dep\silkroad\textdata'
print '1    15    store_'+@npcname+'    store_'+@npcname+@groupnew
end 

هناه كلو في وحد


كود PHP:

declare @charname varchar (30)
declare @
npcname varchar (30)
declare @
addnew varchar (30)
declare @
tabname varchar (30)
declare @
tabnumber varchar (30
declare @
tabnew varchar (30)
declare @
groupnumber varchar (30
declare @
groupnew varchar (30)
declare @
gamewordid int

set 
@addnew 'npc' -- 'npc' to add a new npc'tab' for add a new tab'group' for add a new group!
Set @charname '[gm] alexandria' --u char name
set 
@npcname 'silkroad' --u npc name
set 
@gamewordid --importantGet gameworld id from the localy u want add the npc normal citys 1
set 
@groupnumber  1
set 
@tabnumber 2
set 
@tabname 'dress'

--
if @
addnew 'npc' begin
declare @maxlink varchar (30) = (select max (idfrom _refobjchar)+1
declare @maxcommonid varchar (30) = (select max (idfrom _refobjcommon)+1
set identity_insert _refobjcommon on
insert into _refobjcommon 
(service,id,codename128,objname128,orgobjcodename128,namestrid128,descstrid128,cashitem,bionic,typeid1,typeid2,typeid3,typeid4,decaytime,country
,rarity,cantrade,cansell,canbuy,canborrow,candrop,canpick,canrepair,canrevive,canuse,canthrow,price,costrepair,costrevive,costborrow,keepingfee,sellprice,reqleveltype1,reqlevel1,reqleveltype2,reqlevel2,reqleveltype3,reqlevel3,reqleveltype4,reqlevel4,maxcontain,regionid,dir,offsetx,offsety,offsetz,speed1,speed2,scale,bcheight,bcradius
,eventid,assocfileobj128,assocfiledrop128,assocfileicon128,assocfile1_128,assocfile2_128,linkvalues
(1,@maxcommonid,'npc_'+@npcname,'xxx','xxx','sn_npc_'+@npcname,'xxx',0,1,1,2,2,0,5000,3,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,-1,0,-1,0,-1,0,-1,0,-1,0,0,0,0,0,0,0,100,0,0,0,'npc\npc\chinawoman_noblegirl_event.bsr','xxx','xxx','xxx','xxx',@maxlink)
set identity_insert _refobjcommon off
set identity_insert _refobjchar on
insert into _refobjchar 
(id,lvl,chargender,maxhp,maxmp,resistfrozen,resistfrostbite,resistburn,resisteshock,resistpoison,resistzombie,resistsleep,resistroot,resistslow,resistfear
,resistmyopia,resistblood,resiststone,resistdark,resiststun,resistdisea,resistchaos,resistcsepd,resistcsemd,resistcsestr,resistcseint,resistcsehp,resistcsemp,resist24,resistbomb,resist26
,resist27,resist28,resist29,resist30,resist31,resist32,inventorysize,canstore_tid1,canstore_tid2,canstore_tid3,canstore_tid4,canbevehicle,cancontrol,damageportion,maxpassenger,assoctactics,pd,md,par,mar,er,br,hr,chr
,exptogive,creeptype,knockdown,ko_recovertime,defaultskill_1,defaultskill_2,defaultskill_3,defaultskill_4,defaultskill_5,defaultskill_6,defaultskill_7,defaultskill_8,defaultskill_9,defaultskill_10,texturetype,except_1
,except_2,except_3,except_4,except_5,except_6,except_7,except_8,except_9,except_10,linkvalues
(@maxlink,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,336860180,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0)
set identity_insert _refobjchar off
set identity_insert _refshop on
declare @shopid varchar (30) = (select max (idfrom _refshop)+1
insert into _refshop 
(service,country,id,codename128,param1,param1_desc128,param2,param2_desc128,param3,param3_desc128,param4,param4_desc128)
values (1,15,@shopid,'store_'+@npcname,-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx')
set identity_insert _refshop off
set identity_insert _refshopgroup on
declare @shopgroupid varchar (30) = (select max (idfrom _refshopgroup)+1
insert into _refshopgroup 
(service,country,id,codename128,refnpccodename,param1,param1_desc128,param2,param2_desc128,param3,param3_desc128,param4,param4_desc128)
values (1,15,@shopgroupid,'group_store_'+@npcname,'npc_'+@npcname,-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx')
set identity_insert _refshopgroup off
set identity_insert _refshopitemgroup on
declare @shopitemid varchar (30) = (select max (groupidfrom _refshopitemgroup)+1
insert into _refshopitemgroup 
(service,groupid,codename128,strid128_group)
values (1,@shopitemid,'store_'+@npcname+'_group1','sn_store_'+@npcname+'_group1')
set identity_insert _refshopitemgroup off
set identity_insert _refshoptab on
declare @shoptabid varchar (30)= (select max (idfrom _refshoptab)+1
insert into _refshoptab 
(service,country,id,codename128,reftabgroupcodename,strid128_tab)
values (1,15,@shoptabid,'store_'+@npcname+'_tab1','store_'+@npcname+'_group1','sn_tab_weapon')
set identity_insert _refshoptab off
set identity_insert _refshoptabgroup on
declare @shoptabgroupid varchar (30) = (select max (idfrom _refshoptabgroup)+1
insert into _refshoptabgroup 
(service,country,id,codename128,strid128_group)
values (1,15,@shoptabgroupid,'store_'+@npcname+'_group1','sn_store_'+@npcname+'_group1')
set identity_insert _refshoptabgroup off
insert into _refmappingshopgroup values 
(1,15,'group_store_'+@npcname,'store_'+@npcname)
insert into _refmappingshopwithtab values (1,15,'store_'+@npcname,'store_'+@npcname+'_group1')
declare @
tacticsid int set @tacticsid = (select max (dwtacticsidfrom tab_reftactics)+10
insert into tab_reftactics values
(@tacticsid,@maxcommonid,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,'npc_'+@npcname)
declare @
hiveid int  set @hiveid = (select max (dwhiveidfrom tab_refhive)+1
insert into tab_refhive values
(@hiveid,0,0,0,0,0,0,@gamewordid,2,'npc_'+@npcname)
declare @
region varchar (30set @region = (select (latestregionfrom _char where charname16 = @charname)
declare @
posx varchar (30set @posx = (select (posxfrom _char where charname16 = @charname)
declare @
posy varchar (30set @posy = (select (posyfrom _char where charname16 = @charname)
declare @
posz varchar (30set @posz = (select (poszfrom _char where charname16 = @charname)
declare @
nestid int set @nestid = (select max (dwnestidfrom tab_refnest)+1
insert into tab_refnest values
(@nestid,@hiveid,@tacticsid,@region,@posx,@posy,@posz,0,0,0,0,0,0,1,0,1,0)
print 
'add this line to characterdata_45000 @ server_dep\silkroad\textdata'
print ''
print '1    '+@maxcommonid+'    '+@npcname+'    xxx    xxx    '+'sn_npc_'+@npcname+'    xxx    0    1    1    2    2    0    5000    3    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    -1    0    -1    0    -1    0    -1    0    -1    0    0    0    0    0    0    0    100    0    0    0    npc\npc\chinawoman_noblegirl_event.bsr    xxx    xxx    xxx    xxx    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    336860180    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0    0'
print ''
print 'add this line to refshop.txt @ server_dep\silkroad\textdata'
print ''
print '1    15    '+@shopid+'    '+'store_'+@npcname+'    -1    xxx    -1    xxx    -1    xxx    -1    xxx'
print ''
print 'add this line to refshopgroup.txt @ server_dep\silkroad\textdata'
print ''
print '1    15    '+@shopgroupid+'    '+'group_store_'+@npcname+'    '+'npc_'+@npcname+'    -1    xxx    -1    xxx    -1    xxx    -1    xxx'
print ''
print 'add this line to shopgroupdata.txt @ server_dep\silkroad\textdata'
print ''
print '1    '+@shopitemid+'    '+'store_'+@npcname+'_group1    '+'sn_store_'+@npcname+'_group1'
print ''
print 'add this line to refshoptab.txt @ server_dep\silkroad\textdata'
print ''
print '1    15    '+@shoptabid+'    '+'store_'+@npcname+'_tab1    '+'store_'+@npcname+'_group1     sn_tab_weapons'
print ''
print 'add this line to refshoptabgroup.txt @ server_dep\silkroad\textdata'
print ''
print '1    15    '+@shoptabgroupid+'    '+'store_'+@npcname+'_group1    '+'sn_store_'+@npcname+'_group1'
print ''
print 'add this line to refmappingshopgroup.txt @ server_dep\silkroad\textdata'
print ''
print '1    15    '+'group_store_'+@npcname+'    '+'store_'+@npcname
print ''
print 'add this line to refmappingshopwithtab.txt @ server_dep\silkroad\textdata'
print ''
print '1    15    '+'store_'+@npcname+'    '+'store_'+@npcname+'_group1'
print ''
print 'a new npc has add succesfuly restart u server and login in '+@charname
end
if @tabnumber 2 set @tabnew 'store_'+@npcname+'_tab2'
if @tabnumber 3 set @tabnew 'store_'+@npcname+'_tab3'
if @tabnumber 4 set @tabnew 'store_'+@npcname+'_tab4'
if @groupnumber  2 set @groupnew '_group2'
if @groupnumber  3 set @groupnew '_group3'
if @groupnumber  4 set @groupnew '_group4'
if @groupnumber  5 set @groupnew '_group5'
if @groupnumber  6 set @groupnew '_group6'
if @addnew 'group' begin 
set identity_insert _refshoptabgroup on
set 
@shoptabgroupid = (select max (idfrom _refshoptabgroup)+1
insert into _refshoptabgroup 
(service,country,id,codename128,strid128_group)
values (1,15,@shoptabgroupid,'store_'+@npcname+@groupnew,'sn_store_'+@npcname+@groupnew)
set identity_insert _refshoptabgroup off
insert into _refmappingshopwithtab values 
(1,15,'store_'+@npcname,'store_'+@npcname+@groupnew)
print 
''
print 'new group added succesfully '
print 'add this new line to refshoptabgroup.txt @ server_dep\silkroad\textdata'
print '1    15    '+@shoptabgroupid+'    store_'+@npcname+@groupnew+'    sn_store_'+@npcname+@groupnew
print ''
print 'add this new line to refmappingshopwithtab.txt @ server_dep\silkroad\textdata'
print '1    15    store_'+@npcname+'    store_'+@npcname+@groupnew

end

if @addnew 'tab' begin
if @groupnumber 1 set @groupnew '_group1'
set identity_insert _refshoptab on
set 
@shoptabid = (select max (idfrom _refshoptab)+1
insert into _refshoptab 
(service,country,id,codename128,reftabgroupcodename,strid128_tab)
values (1,15,@shoptabid,@tabnew,'store_'+@npcname+@groupnew,'sn_'+@tabname)
set identity_insert _refshoptab off
print ''
print 'new tab added sucessfully add this new line to refshoptab.txt @ server_dep\silkroad\textdata' 
print '1    15    '+@shoptabid+'    store_'+@npcname+@tabnew+'    store_'+@npcname+@groupnew+'     sn_tab_'+@tabname
end
if @tabnumber 4 begin
print '@tabnumber value does not exist. U must add 2 , 3 or 4 tabs per npc!'
end
if @groupnumber 8 begin
print '@groupnumber value does not exist. U must add  1 , 2 , 3 , 4 , 5 , 6 , 7 or 8 groups!'
end
if @addnew '' begin
print '@addnew value does not exist. U must set values npc , tab , group'
end 


شكرا يا باشا بس لما تكون ناقل حاجة ابقي قول انها منقولة

ღ♥Alexandria♥ღ 27-01-2013 06:15 PM

ِشكرا

xxxlitaxxx 27-01-2013 06:26 PM

انت جربتها واشتغلت تمام ؟! انا جربتها مرتين وفى كل مره مش شغاله

ღ♥Alexandria♥ღ 27-01-2013 06:33 PM

في حاجه في الsql لزم تفتحه

Badass 27-01-2013 08:25 PM

يعني ده بيعمل ادد لل npc طب فين واسمو إيه؟

ღ♥Alexandria♥ღ 27-01-2013 08:27 PM

مكن السم Alexandria[GM]

Badass 27-01-2013 08:37 PM

اقتباس:

المشاركة الأصلية كتبت بواسطة mneam001 (المشاركة 4530403)
مكن السم Alexandria[GM]

يا باشا بقولك عايز اغير معكنو واسمو المكان علي إنت بتقول الي هو بجدل الاسم ده علي هو Char Name!:bigeyedsmiley:

El_safa71980 27-01-2013 08:38 PM

شكرا وجارى التجربه


الساعة الآن 11:08 AM.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions, Inc.