Kayıt
27 Mayıs 2016
Mesajlar
2.139
Beğeniler
1.179
Şehir
Muğla
Takımı
Galatasaray

  • Merhaba arkadaşlar vsro için işinize yarayabilecek kodlara buradan ulaşabilirsiniz.Gördükçe eklemeler yapacağım iyi forumlar.
1.Moblardan istediğiniz eşyanın drobunu kaldırma ;
Kod:
USE SRO_VT_SHARD
GO
DELETE _RefDropItemAssign
FROM _RefDropItemAssign Drops
LEFT JOIN _RefObjCommon Objects
ON (Drops.RefItemID = Objects.ID)
WHERE CodeName128 like 'Itemın kodunu buraya yazacaksınız'

2.Mob slot değiştirme ;
Kod:
USE SRO_VT_SHARD
UPDATE [dbo].[Tab_RefTactics]SET dwObjID = replace(dwObjID, 'Eski Mob ID', 'Yeni Mob ID')WHERE dwObjID LIKE 'Eski Mob ID Tekrar';
print 'extraloob.com takipçileri için hazırlanmıştır.'

3.Mob ID bulma ;
Kod:
[COLOR=rgb(0, 0, 0)][FONT=Georgia]Jangandaki moblar : select * from _RefObjCommon where CodeName128 like '%MOB_CH%'
Donwhang'daki moblar 1: select * from _RefObjCommon where CodeName128 like '%MOB_WC%'
Donwhang'daki moblar 2: select * from _RefObjCommon where CodeName128 like '%MOB_OA%'
Hotandaki moblar : select * from _RefObjCommon where CodeName128 like '%MOB_KT%'
Karakoramdaki moblar : select * from _RefObjCommon where CodeName128 like '%MOB_KK%'
Taklamakan'daki moblar : select * from _RefObjCommon where CodeName128 like '%MOB_TK%'
Downhang Cave'deki moblar : select * from _RefObjCommon where CodeName128 like '%MOB_DH%'
Roc Mountain'deki moblar : select * from _RefObjCommon where CodeName128 like '%MOB_RM%'
Constantinople'deki moblar : select * from _RefObjCommon where CodeName128 like '%MOB_EU%'
Samarkand'daki moblar 1: select * from _RefObjCommon where CodeName128 like '%MOB_AM%'
Samarkand'daki moblar 2 : select * from _RefObjCommon where CodeName128 like '%MOB_CA%'
Jangan cave'deki moblar : select * from _RefObjCommon where CodeName128 like '%MOB_TQ%'
Alexandria'daki moblar : select * from _RefObjCommon where CodeName128 like '%MOB_SD%'
Jupiter'deki moblar : select * from _RefObjCommon where CodeName128 like '%MOB_JUPITER%'
Forgotten World'deki moblar : select * from _RefObjCommon where CodeName128 like '%MOB_GOD%'[/FONT][/COLOR]

4.Honor Rank bugunu fixleme ;
Kod:
[COLOR=rgb(0, 0, 0)][FONT=Georgia]USE SRO_VT_SHARD
TRUNCATE TABLE _TrainingCampHonorRank
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (1)
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (2)
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (3)
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (4)
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (5)
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (6)
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (7)
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (8)
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (9)
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (10)
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (11)
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (12)
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (13)
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (14)
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (15)
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (16)
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (17)
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (18)
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (19)
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (20)
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (21)
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (22)
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (23)
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (24)
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (25)
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (26)
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (27)
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (28)
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (29)
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (30)
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (31)
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (32)
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (33)
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (34)
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (35)
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (36)
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (37)
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (38)
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (39)
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (40)
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (41)
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (42)
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (43)
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (44)
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (45)
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (46)
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (47)
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (48)
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (49)
INSERT INTO _TrainingCampHonorRank(Ranking) VALUES (50)
exec _TRAINING_CAMP_UPDATEHONORRANK[/FONT][/COLOR]

5.Magic Pop rate düzenleme ;(@Rate=15 olan bölüme göre düzenleyiniz yani 20 yazarsanız 20x olur.)
Kod:
[COLOR=rgb(0, 0, 0)][FONT=Georgia]USE [SRO_VT_SHARD]
GO
DECLARE @Rate int
SET @Rate = 15
UPDATE dbo._RefGachaItemSet SET Ratio = Ratio*@Rate
WHERE Ratio*@Rate < 32768 -- 32767 max value for smallint[/FONT][/COLOR]

6.Tüm karakterlerin PK'lığını geçirme ;
Kod:
[COLOR=rgb(0, 0, 0)][FONT=Georgia]USE [SRO_VT_SHARD]
UPDATE _Char SET
DailyPK= 0,
TotalPK= 0,
PKPenaltyPoint= 0[/FONT][/COLOR]

7.Pill bugunu fixleme ;(SRO_VT_SHARD'a excute ediniz.)
Kod:
UPDATE _RefObjItem SET Param4='20000', Desc4_128='COOLTIME:0x000000C8' WHERE ID BETWEEN 5861 and 5864

8.+15'den +35'e kadar olan itemleri +15'de sabitleme ;
Kod:
[COLOR=rgb(0, 0, 0)][FONT=Georgia]USE SRO_VT_SHARD

UPDATE [dbo].[_Items]SET OptLevel = replace(OptLevel, '15', '15')WHERE OptLevel LIKE '15';
UPDATE [dbo].[_Items]SET OptLevel = replace(OptLevel, '16', '15')WHERE OptLevel LIKE '16';
UPDATE [dbo].[_Items]SET OptLevel = replace(OptLevel, '17', '15')WHERE OptLevel LIKE '17';
UPDATE [dbo].[_Items]SET OptLevel = replace(OptLevel, '18', '15')WHERE OptLevel LIKE '18';
UPDATE [dbo].[_Items]SET OptLevel = replace(OptLevel, '19', '15')WHERE OptLevel LIKE '19';
UPDATE [dbo].[_Items]SET OptLevel = replace(OptLevel, '20', '15')WHERE OptLevel LIKE '20';
UPDATE [dbo].[_Items]SET OptLevel = replace(OptLevel, '21', '15')WHERE OptLevel LIKE '21';
UPDATE [dbo].[_Items]SET OptLevel = replace(OptLevel, '22', '15')WHERE OptLevel LIKE '22';
UPDATE [dbo].[_Items]SET OptLevel = replace(OptLevel, '23', '15')WHERE OptLevel LIKE '23';
UPDATE [dbo].[_Items]SET OptLevel = replace(OptLevel, '24', '15')WHERE OptLevel LIKE '24';
UPDATE [dbo].[_Items]SET OptLevel = replace(OptLevel, '25', '15')WHERE OptLevel LIKE '25';
UPDATE [dbo].[_Items]SET OptLevel = replace(OptLevel, '26', '15')WHERE OptLevel LIKE '26';
UPDATE [dbo].[_Items]SET OptLevel = replace(OptLevel, '27', '15')WHERE OptLevel LIKE '27';
UPDATE [dbo].[_Items]SET OptLevel = replace(OptLevel, '28', '15')WHERE OptLevel LIKE '28';
UPDATE [dbo].[_Items]SET OptLevel = replace(OptLevel, '29', '15')WHERE OptLevel LIKE '29';
UPDATE [dbo].[_Items]SET OptLevel = replace(OptLevel, '30', '15')WHERE OptLevel LIKE '30';
UPDATE [dbo].[_Items]SET OptLevel = replace(OptLevel, '31', '15')WHERE OptLevel LIKE '31';
UPDATE [dbo].[_Items]SET OptLevel = replace(OptLevel, '32', '15')WHERE OptLevel LIKE '32';
UPDATE [dbo].[_Items]SET OptLevel = replace(OptLevel, '33', '15')WHERE OptLevel LIKE '33';
UPDATE [dbo].[_Items]SET OptLevel = replace(OptLevel, '34', '15')WHERE OptLevel LIKE '34';
UPDATE [dbo].[_Items]SET OptLevel = replace(OptLevel, '35', '15')WHERE OptLevel LIKE '35';[/FONT][/COLOR]

9.Karakterin çantasındaki itemi ve adetini öğrenme ;
Kod:
Use SRO_VT_SHARDSelect IT.ID64, IT.OptLevel As Plus, INV.CharID, Data, CH.CharName16, REF.CodeName128 From _RefObjCommon As REF
Right Join _Items As IT On IT.RefItemID = REF.ID
Right Join _Inventory As INV On INV.ItemID = IT.ID64
Right Join _Char as CH On CH.CharID = INV.CharIDWhere CodeName128 like '%aranacak item adı%'

10.Yeni guild açıldığında 5 level olarak başlatma ;
Kod:
[COLOR=rgb(0, 0, 0)][FONT=Georgia]USE [SRO_VT_SHARD]
GO
/****** Object: StoredProcedure [dbo].[_Guild_Create] Script Date: 08/16/2012 23:40:21 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO

—
ALTER PROCEDURE [dbo].[_Guild_Create]
  @guildName varchar(64),
  @createrID int
as
if (exists (select id from _Guild where Name =  @guildName))
begin
return -1000
end
if (exists (select CharID from _GuildMember where CharID =  @createrID))
begin
return -1001
end
begin transaction

declare  @guildID int
declare @FoundationDate smalldatetime

set @FoundationDate = GetDate()
insert _Guild(Name, Lvl, GatheredSP, FoundationDate,Alliance,Booty) values  @guildName, 5, 123456, @FoundationDate,0,0)
set  @guildID = @@identity

if (@@error <> 0 or @@rowcount = 0 or  @guildID = 0)
begin
rollback transaction
return -5
end
–???? ???? 0xffffffff !!
declare @rvalue int
exec @rvalue = _Guild_FnAddMember  @guildID,  @createrID, 0, @FoundationDate,0xffffffff
if (@@error <> 0 or @rvalue <= 0)
begin
rollback transaction
return @rvalue
end

— ?? ??? ????
exec @rvalue = _Guild_CreateChest_NoTX  @guildID
if (@@error <> 0 or @rvalue <= 0)
begin
rollback transaction
return @rvalue
end
commit transaction
return  @guildID[/FONT][/COLOR]

11.FGW Dc fix ;
Kod:
[COLOR=rgb(0, 0, 0)][FONT=Georgia]USE [SRO_VT_SHARD]
GO
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
ALTER   procedure [dbo].[_AddTimedJob]
@CharID            int,
@Category        tinyint,
@JobID            int,
@TimeToKeep    int,
@Data1            int,
@Data2            int,
--##begin due to develop composite item
@Data3            int,
@Data4            int,
@Data5            int,
@Data6            int,
@Data7            int,
@Data8            int,
@serial64        bigint,
@JID            int
--##end due to develop composite item
as
   if (not exists (select CharID from _Char with (nolock) where CharID = @CharID))
               return -1
           if  @TimeToKeep <= 0)
               return -2
           declare @NewJobID int
           set @NewJobID = 0
           --##JobID 1 = Guild // JobID 2 = Thief/Hunter/Trader
           --##If you want to only have one not both, then just modify the line below!
           --if (@JobID = 1 and @Category = 2 and @serial64=0) or (@JobID = 2 and @Category = 2 and @serial64=0)  --For Guild and CharJob    
    if (@JobID = 1 and @Category = 2 and @serial64=0)   --Only for Guild
           BEGIN
           set @CharID = 0    
           insert into _TimedJob(CharID,Category,JobID,TimeToKeep,Data1,Data2,Data3,Data4,Data5,Data6,Data7,Data8,Serial64,JID)
           values(@CharID, @Category, @JobID, @TimeToKeep, @Data1, @Data2, @Data3, @Data4, @Data5, @Data6, @Data7, @Data8, @serial64, @JID)
    
           END
           ELSE
           BEGIN
           --##begin due to develop composite item
           insert into _TimedJob(CharID,Category,JobID,TimeToKeep,Data1,Data2,Data3,Data4,Data5,Data6,Data7,Data8,Serial64,JID)
           values(@CharID, @Category, @JobID, @TimeToKeep, @Data1, @Data2, @Data3, @Data4, @Data5, @Data6, @Data7, @Data8, @serial64, @JID)
           END
           --##end due to develop composite item
           set @NewJobID = @@identity
           if (@@error <> 0 or @@rowcount = 0)
        
               return -3
    return @NewJobID[/FONT][/COLOR]

12.Char silinmeme hatasını fixleme ;
Kod:
[COLOR=rgb(0, 0, 0)][FONT=Georgia]USE [SRO_VT_SHARD]
GO
/****** Object:  StoredProcedure [dbo].[_DeleteCharPermanently_NoTX]    Script Date: 04/24/2012 18:32:38 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO


ALTER  PROCEDURE [dbo].[_DeleteCharPermanently_NoTX]
   @UserJID    int,
   @CharID    int
as
   ------------------------------------
   -- Inventory랑 그안에 가지고 있던 아이템들 날려버리자...
   ------------------------------------
   -------------- 펫 소환 아이템부터 일단 삭제 ----------------
   declare @ResuLt int
   declare @Slot tinyint
   declare @RefItemID int

   declare pc_inv_cursor cursor fast_forward for
   select inv.slot
   from _Inventory as inv join _Items as it on inv.ItemID = it.ID64
   where
   (inv.CharID = @CharID and inv.Slot >= 13 and inv.ItemID > 0) and     -- 장비창 제외하고 아이템 있는 순수 인벤토리 안에 들어있으며
   (it.Data <> 0)                                              and    -- 소환수를 가지고 있는
   (exists (select top 1 ID from _RefObjCommon where ID = it.RefItemID and TypeID1 = 3 and TypeID2 = 2)) -- 펫소환 아이템들 찾아줘~

   open pc_inv_cursor
   fetch next from pc_inv_cursor  into @slot
   while @@fetch_status = 0
   begin
           exec @ResuLt = _STRG_DEL_ITEM_NoTX 1, @CharID, @Slot
           if  @ResuLt < 0)
           begin
               close pc_inv_cursor
               deallocate pc_inv_cursor
               return @ResuLt
           end
                
           fetch next from pc_inv_cursor  into @Slot
   end

   close pc_inv_cursor
   deallocate pc_inv_cursor
   ------------------- 남은 아이템들 몽창 삭제  -------------------
   -- 아이템이 하나라도 있다면...
   if (exists (select top 1 itemID from _Inventory where CharID = @CharID AND ItemID <> 0))
   begin
       update _ItemPool Set InUse = 0
       from _ItemPool as pool join _Inventory as inv on pool.ItemID = Inv.ItemID
       where Inv.CharID = @CharID and Inv.ItemID <> 0
   end
   ----------- 아이템들 날렸으니 최종적으루 인벤토리 삭제  ------------
   delete from _Inventory where CharID = @CharID
   if (@@error <> 0)
   begin
       return -10001
   end

   --@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
   --        APPLY_AVATAR_SYSTEM (허승욱)
   --@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@

   ------------------- 남은 아바타 인벤토리 아이템들 몽창 삭제  -------------------
   -- 아이템이 하나라도 있다면...
   if (exists (select top 1 itemID from _InventoryForAvatar where CharID = @CharID AND ItemID <> 0))
   begin
       update _ItemPool Set InUse = 0
       from _ItemPool as pool join _InventoryForAvatar as InvAva on pool.ItemID = InvAva.ItemID
       where InvAva.CharID = @CharID and InvAva.ItemID <> 0
   end
   ----------- 아이템들 날렸으니 최종적으루 아바타 인벤토리 삭제  ------------
   delete from _InventoryForAvatar where CharID = @CharID
   if (@@error <> 0)
   begin
       return -10008
   end

   --@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
   --        APPLY_AVATAR_SYSTEM (허승욱)
   --@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@

   ------------------------------------
   -- COS 삭제
   ------------------------------------
/*
   declare @engaged_cos int
   set @engaged_cos = 0
   select @engaged_cos = EngagedCOS from _char with (nolock) where CharID = @CharID

   if  @engaged_cos = 0)
   begin
       -- 왜 발?하는 지 잘 ?르겠지만... 아주 드물게 COS 만 남아있는 경우가 있더라고... -_-;
       select @engaged_cos = ID from _CharCOS with (nolock) where OwnerCharID = @CharID
       if  @engaged_cos is null)
           set @engaged_cos = 0
   end
   if  @engaged_cos is not null and @engaged_cos <> 0)
   begin
       declare @Return_Del_COS int
       exec @Return_Del_COS = _DeleteCharCOS_NoTX  @CharID, @engaged_cos
       if (@Return_Del_COS < 0)
       begin
           return -10002
       end
   end
*/
   ------------------------------------
   -- Trijob 데이터 삭제
   ------------------------------------
   delete from _CharTrijob where CharID = @CharID
   ------------------------------------
   -- 스킬 삭제
   ------------------------------------
   delete _CharSkill where CharId = @CharID
   delete _CharSkillMastery where charID = @CharID
   ------------------------------------
   -- 퀘스트 삭제
   ------------------------------------
   delete _CharQuest where CharID = @CharID
   ------------------------------------
   -- 길드 멤버 삭제
   ------------------------------------
   -- !!! 만약 여기서 Guild 멤버 삭제가 일어나지 않으면 ShardManager 에서
   -- _Guild_DelMember 호출해 주도록 수정해야 한다! 지?은 그 과정은 Skip하고
   -- ??리에서 삭제만 일어나게 되어 있거덩...
   declare @guildID int
   set @guildID = 0
   select @guildID = GuildID from _char where charid = @CharID
   if  @guildID is not null and @guildID <> 0)
   begin
       if (not exists (select ID from _Guild where ID = @guildID))
       begin
           update _Char set GuildID = 0 where CharID = @CharID
       end
       else
       begin
           declare @Return_Del_GuildMember int
           exec @Return_Del_GuildMember = _Guild_DelMember_NoTX @guildID, @CharID
           if (@Return_Del_GuildMember < 0)
               return -10003
       end
   end

   --@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
   --        APPLY_MENTOR_SYSTEM (최인호)
   --@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
   DECLARE @CampID INT
   SET @CampID = 0
   SELECT @CampID = CampID FROM _TrainingCampMember WHERE CharID = @CharID
   IF (@CampID IS NOT NULL AND @CampID <> 0)
   BEGIN
       DECLARE @Ret_DelCampMember INT
       EXEC @Ret_DelCampMember = _TRAINING_CAMP_DELMEMBER @CampID, @CharID, 0
       IF (@Ret_DelCampMember < 0)
           RETURN -10007
   END

   -- 있으면 지워버리자~ 뭐.
   DELETE FROM _TrainingCampSubMentorHonorPoint WHERE CharID = @CharID

   -- 경험치 버프 레코드도~~ ㅋㅋ
   DELETE FROM _TrainingCampBuffStatus WHERE CampID = @CampID

   --@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
   --        APPLY_MENTOR_SYSTEM (최인호)
   --@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@

   -----------------------------------
   -- 친구 리스트 삭제 ( 나의 친구 리스트 + 친구의 친구 리스트중 나 )
   -----------------------------------
   -- 내 친구들..
   declare @FriendCharID    int
   declare @cursor_var     cursor

   set @cursor_var = cursor fast_forward
   for
   select FriendCharID
   from _Friend
   where CharID = @CharID

   open @cursor_var

   fetch next from @cursor_var into @FriendCharID

   while( @@FETCH_STATUS = 0 )
   begin
       delete _Friend where CharID = @FriendCharID and FriendCharID = @CharID

       fetch next from @cursor_var into @FriendCharID
   end
   close @cursor_var
   deallocate @cursor_var
   -- 나..
   delete _Friend where CharID = @CharID
   -----------------------------------
   -- 쪽지 삭제
   -----------------------------------
   delete _Memo where CharID = @CharID
   ------------------------------------
   -- TimedJob 삭제하기
   ------------------------------------
   delete _TimedJob where CharID = @CharID
   ------------------------------------
   -- Static Avatar 정보 삭제
   ------------------------------------
   delete from _staticavatar where charID = @charID
   ------------------------------------
   -- 귓말 블럭 정보 삭제
   ------------------------------------
   -- Hyperdash 2009. 9. 3 현재는 테이블이 없어 캐릭터 삭제가 되지 않음, 추후 UI 개선 1차 ?치가 될 경우에는 주석 해제 필
   delete from _BlockedWhisperers where OwnerID = @charID
   ------------------------------------
   -- _DeletedChar Entry 삭제
   ------------------------------------
   delete from _DeletedChar where CharID = @CharID
   if (@@error <> 0)
   begin
       return -10004
   end
   -- start by novice.
   DELETE FROM _User WHERE UserJID = @UserJID and CharID = @CharID
   -- finish by novice.

   ------------------------------------
   -- commit !!!
   ------------------------------------

   -- 클라이?트용 퀵슬롯 정보 저장 테이블 날리기!!!
   exec _RemoveClientConfig @CharID        -- by novice...... for saving client configurations...
   return @guildID[/FONT][/COLOR]

13. İtem silme ;
Kod:
[COLOR=rgb(0, 0, 0)][FONT=Georgia]USE [SRO_VT_SHARD]
GO
DECLARE @Codename128 VARCHAR(128)
SET @Codename128 = ‘İtem Id Giriniz ( Örnek: ITEM_CH_BOW_10_RARE )‘

UPDATE _Inventory SET ItemID = 0
FROM _Inventory
JOIN _Items ON _Items.ID64 = _Inventory.ItemID
JOIN _RefObjCommon ON _Items.RefItemID = _RefObjCommon.ID
WHERE _RefObjCommon.CodeName128 = @Codename128

UPDATE _Chest SET ItemID = 0
FROM _Chest
JOIN _Items ON _Items.ID64 = _Chest.ItemID
JOIN _RefObjCommon ON _Items.RefItemID = _RefObjCommon.ID
WHERE _RefObjCommon.CodeName128 = @Codename128

UPDATE _GuildChest SET ItemID = 0
FROM _GuildChest
JOIN _Items ON _Items.ID64 = _GuildChest.ItemID
JOIN _RefObjCommon ON _Items.RefItemID = _RefObjCommon.ID
WHERE _RefObjCommon.CodeName128 = @Codename128

UPDATE _InvCOS SET ItemID = 0
FROM _InvCOS
JOIN _Items ON _Items.ID64 = _InvCOS.ItemID
JOIN _RefObjCommon ON _Items.RefItemID = _RefObjCommon.ID
WHERE _RefObjCommon.CodeName128 = @Codename128[/FONT][/COLOR]

14.Karakter ismi değiştirme ;
Kod:
USE SRO_VT_SHARD
UPDATE [dbo].[_Char] SET CharName16=’Yeni Char İsmi‘ where CharName16=’Eski Char İsmi‘

15.Karakter level düşürme ;
Kod:
[COLOR=rgb(0, 0, 0)][FONT=Georgia]USE SRO_VT_SHARD

UPDATE [dbo].[_Char] SET CurLevel=’Düşürülecek Level‘ where CharName16=’Char İsmi‘[/FONT][/COLOR]

16.Bir itemi tüm oyunculardan silme ;
Kod:
[COLOR=rgb(0, 0, 0)][FONT=Georgia]USE [SRO_VT_SHARD]
Exec [Dbo].[_SEEK_N_DESTROY_ITEM] [‘İtem Kodu‘ ][/FONT][/COLOR]

17.Başlangıçta karaktere builde göre item giydirme ;
Kod:
USE [SRO_VT_SHARD]
GO
/****** Object:  StoredProcedure [dbo].[_AddNewChar]    Script Date: 18.04.2016 14:01:11 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER OFF
GO
ALTER   PROCEDURE [dbo].[_AddNewChar]
@UserJID   INT,
--@CharSlot   INT,
@RefCharID   INT,
@CharName   varchar (64),
@CharScale   tinyINT,
@StartRegionID  INT,
@StartPos_X   real,
@StartPos_Y   real,
@StartPos_Z   real,
@DefaultTeleport INT,
@RefMailID   INT,
@RefPantsID   INT,
@RefBootsID   INT,
@RefWeaponID  INT,
@RefShield   INT,
@DurMail   tinyINT,
@DurPants   tinyINT,
@DurBoots   tinyINT,
@DurWeapon   tinyINT,
@DurShield   tinyINT,
@DefaultArrow  INT
AS

SET NOCOUNT ON

    DECLARE @Slot  INT 
    DECLARE @temp  INT 
     
    DECLARE @NewCharID  INT 
    SET @NewCharID = 0 

-- Initial Equip Edit by LemoniscooL
DECLARE @RefHandID INT
DECLARE @RefHatID INT
DECLARE @RefShoulderID INT
DECLARE @RefEarringID INT
DECLARE @RefRingID INT
DECLARE @RefNeckID INT
DECLARE @DurHand INT
DECLARE @DurHat INT
DECLARE @DurShoulder INT
DECLARE @DurEarring INT
DECLARE @DurRing INT
DECLARE @DurNeck INT

--Male Clothes Chinese
IF (@RefMailID = 3643) BEGIN
    SET @RefHandID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_M_CLOTHES_01_AA_C_RARE')
    SET @RefMailID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_M_CLOTHES_01_BA_C_RARE')
    SET @RefBootsID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_M_CLOTHES_01_FA_C_RARE')
    SET @RefHatID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_M_CLOTHES_01_HA_C_RARE')
    SET @RefPantsID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_M_CLOTHES_01_LA_C_RARE')
    SET @RefShoulderID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_M_CLOTHES_01_SA_C_RARE')
    SET @RefEarringID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_EARRING_01_C_RARE')
    SET @RefNeckID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_NECKLACE_01_C_RARE')
    SET @RefRingID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_RING_01_C_RARE')
END

--Male Heavy Armor Chinese
IF (@RefMailID = 3637) BEGIN
    SET @RefHandID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_M_HEAVY_01_AA_C_RARE')
    SET @RefMailID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_M_HEAVY_01_BA_C_RARE')
    SET @RefBootsID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_M_HEAVY_01_FA_C_RARE')
    SET @RefHatID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_M_HEAVY_01_HA_C_RARE')
    SET @RefPantsID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_M_HEAVY_01_LA_C_RARE')
    SET @RefShoulderID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_M_HEAVY_01_SA_C_RARE')
    SET @RefEarringID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_EARRING_01_C_RARE')
    SET @RefNeckID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_NECKLACE_01_C_RARE')
    SET @RefRingID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_RING_01_C_RARE')
END

--Male Light Armor Chinese
IF (@RefMailID = 3640) BEGIN
    SET @RefHandID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_M_LIGHT_01_AA_C_RARE')
    SET @RefMailID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_M_LIGHT_01_BA_C_RARE')
    SET @RefBootsID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_M_LIGHT_01_FA_C_RARE')
    SET @RefHatID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_M_LIGHT_01_HA_C_RARE')
    SET @RefPantsID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_M_LIGHT_01_LA_C_RARE')
    SET @RefShoulderID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_M_LIGHT_01_SA_C_RARE')
    SET @RefEarringID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_EARRING_01_C_RARE')
    SET @RefNeckID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_NECKLACE_01_C_RARE')
    SET @RefRingID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_RING_01_C_RARE')
END

--Female Clothes Chinese
IF (@RefMailID = 3652) BEGIN
    SET @RefHandID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_W_CLOTHES_01_AA_C_RARE')
    SET @RefMailID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_W_CLOTHES_01_BA_C_RARE')
    SET @RefBootsID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_W_CLOTHES_01_FA_C_RARE')
    SET @RefHatID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_W_CLOTHES_01_HA_C_RARE')
    SET @RefPantsID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_W_CLOTHES_01_LA_C_RARE')
    SET @RefShoulderID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_W_CLOTHES_01_SA_C_RARE')
    SET @RefEarringID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_EARRING_01_C_RARE')
    SET @RefNeckID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_NECKLACE_01_C_RARE')
    SET @RefRingID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_RING_01_C_RARE')
END

--Female Heavy Armor Chinese
IF (@RefMailID = 3646) BEGIN
    SET @RefHandID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_W_HEAVY_01_AA_C_RARE')
    SET @RefMailID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_W_HEAVY_01_BA_C_RARE')
    SET @RefBootsID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_W_HEAVY_01_FA_C_RARE')
    SET @RefHatID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_W_HEAVY_01_HA_C_RARE')
    SET @RefPantsID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_W_HEAVY_01_LA_C_RARE')
    SET @RefShoulderID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_W_HEAVY_01_SA_C_RARE')
    SET @RefEarringID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_EARRING_01_C_RARE')
    SET @RefNeckID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_NECKLACE_01_C_RARE')
    SET @RefRingID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_RING_01_C_RARE')
END

--Female Light Armor Chinese
IF (@RefMailID = 3649) BEGIN
    SET @RefHandID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_W_LIGHT_01_AA_C_RARE')
    SET @RefMailID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_W_LIGHT_01_BA_C_RARE')
    SET @RefBootsID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_W_LIGHT_01_FA_C_RARE')
    SET @RefHatID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_W_LIGHT_01_HA_C_RARE')
    SET @RefPantsID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_W_LIGHT_01_LA_C_RARE')
    SET @RefShoulderID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_W_LIGHT_01_SA_C_RARE')
    SET @RefEarringID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_EARRING_01_C_RARE')
    SET @RefNeckID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_NECKLACE_01_C_RARE')
    SET @RefRingID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_RING_01_C_RARE')
END

--Male Clothes Europe
IF (@RefMailID = 11623) BEGIN
    SET @RefHandID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_M_CLOTHES_01_AA_C_RARE')
    SET @RefMailID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_M_CLOTHES_01_BA_C_RARE')
    SET @RefBootsID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_M_CLOTHES_01_FA_C_RARE')
    SET @RefHatID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_M_CLOTHES_01_HA_C_RARE')
    SET @RefPantsID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_M_CLOTHES_01_LA_C_RARE')
    SET @RefShoulderID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_M_CLOTHES_01_SA_C_RARE')
    SET @RefEarringID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_EARRING_01_C_RARE')
    SET @RefNeckID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_NECKLACE_01_C_RARE')
    SET @RefRingID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_RING_01_C_RARE')
END

--Male Heavy Armor Europe
IF (@RefMailID = 11617) BEGIN
    SET @RefHandID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_M_HEAVY_01_AA_C_RARE')
    SET @RefMailID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_M_HEAVY_01_BA_C_RARE')
    SET @RefBootsID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_M_HEAVY_01_FA_C_RARE')
    SET @RefHatID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_M_HEAVY_01_HA_C_RARE')
    SET @RefPantsID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_M_HEAVY_01_LA_C_RARE')
    SET @RefShoulderID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_M_HEAVY_01_SA_C_RARE')
    SET @RefEarringID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_EARRING_01_C_RARE')
    SET @RefNeckID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_NECKLACE_01_C_RARE')
    SET @RefRingID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_RING_01_C_RARE')
END

--Male Light Armor Europe
IF (@RefMailID = 11620) BEGIN
    SET @RefHandID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_M_LIGHT_01_AA_C_RARE')
    SET @RefMailID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_M_LIGHT_01_BA_C_RARE')
    SET @RefBootsID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_M_LIGHT_01_FA_C_RARE')
    SET @RefHatID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_M_LIGHT_01_HA_C_RARE')
    SET @RefPantsID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_M_LIGHT_01_LA_C_RARE')
    SET @RefShoulderID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_M_LIGHT_01_SA_C_RARE')
    SET @RefEarringID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_EARRING_01_C_RARE')
    SET @RefNeckID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_NECKLACE_01_C_RARE')
    SET @RefRingID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_RING_01_C_RARE')
END

--Female Clothes Europe
IF (@RefMailID = 11632) BEGIN
    SET @RefHandID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_W_CLOTHES_01_AA_C_RARE')
    SET @RefMailID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_W_CLOTHES_01_BA_C_RARE')
    SET @RefBootsID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_W_CLOTHES_01_FA_C_RARE')
    SET @RefHatID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_W_CLOTHES_01_HA_C_RARE')
    SET @RefPantsID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_W_CLOTHES_01_LA_C_RARE')
    SET @RefShoulderID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_W_CLOTHES_01_SA_C_RARE')
    SET @RefEarringID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_EARRING_01_C_RARE')
    SET @RefNeckID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_NECKLACE_01_C_RARE')
    SET @RefRingID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_RING_01_C_RARE')
END

--Female Heavy Armor Europe
IF (@RefMailID = 11626) BEGIN
    SET @RefHandID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_W_HEAVY_01_AA_C_RARE')
    SET @RefMailID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_W_HEAVY_01_BA_C_RARE')
    SET @RefBootsID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_W_HEAVY_01_FA_C_RARE')
    SET @RefHatID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_W_HEAVY_01_HA_C_RARE')
    SET @RefPantsID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_W_HEAVY_01_LA_C_RARE')
    SET @RefShoulderID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_W_HEAVY_01_SA_C_RARE')
    SET @RefEarringID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_EARRING_01_C_RARE')
    SET @RefNeckID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_NECKLACE_01_C_RARE')
    SET @RefRingID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_RING_01_C_RARE')
END

--Female Light Armor Europe
IF (@RefMailID = 11629) BEGIN
    SET @RefHandID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_W_LIGHT_01_AA_C_RARE')
    SET @RefMailID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_W_LIGHT_01_BA_C_RARE')
    SET @RefBootsID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_W_LIGHT_01_FA_C_RARE')
    SET @RefHatID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_W_LIGHT_01_HA_C_RARE')
    SET @RefPantsID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_W_LIGHT_01_LA_C_RARE')
    SET @RefShoulderID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_W_LIGHT_01_SA_C_RARE')
    SET @RefEarringID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_EARRING_01_C_RARE')
    SET @RefNeckID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_NECKLACE_01_C_RARE')
    SET @RefRingID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_RING_01_C_RARE')
END

--Shield Chinese
IF (@RefShield = 10886) BEGIN
    SET @RefShield = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_SHIELD_01_C_RARE')
END

--Shield Europe
IF (@RefShield = 10896) BEGIN
    SET @RefShield = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_SHIELD_01_C_RARE')
END

--Blade Chinese
IF (@RefWeaponID = 3633) BEGIN
    SET @RefWeaponID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_BLADE_01_C_RARE')
END

--Bow Chinese
IF (@RefWeaponID = 3636) BEGIN
    SET @RefWeaponID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_BOW_01_C_RARE')
END

--Spear Chinese
IF (@RefWeaponID = 3634) BEGIN
    SET @RefWeaponID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_SPEAR_01_C_RARE')
END

--Sword Chinese
IF (@RefWeaponID = 3632) BEGIN
    SET @RefWeaponID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_SWORD_01_C_RARE')
END

--Glavie Chinese
IF (@RefWeaponID = 3635) BEGIN
    SET @RefWeaponID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_TBLADE_01_C_RARE')
END

--Axe Europe
IF (@RefWeaponID = 10890) BEGIN
    SET @RefWeaponID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_AXE_01_C_RARE')
END

--XBow Europe
IF (@RefWeaponID = 10891) BEGIN
    SET @RefWeaponID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_CROSSBOW_01_C_RARE')
END

--Dagger Europe
IF (@RefWeaponID = 10887) BEGIN
    SET @RefWeaponID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_DAGGER_01_C_RARE')
END

--Darkstaff Europe
IF (@RefWeaponID = 10892) BEGIN
    SET @RefWeaponID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_DARKSTAFF_01_C_RARE')
END

--Harp Europe
IF (@RefWeaponID = 10894) BEGIN
    SET @RefWeaponID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_HARP_01_C_RARE')
END

--Cleric Rod Europe
IF (@RefWeaponID = 10895) BEGIN
    SET @RefWeaponID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_STAFF_01_C_RARE')
END

--Sword Europe
IF (@RefWeaponID = 10888) BEGIN
    SET @RefWeaponID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_SWORD_01_C_RARE')
END

--Staff Europe
IF (@RefWeaponID = 10893) BEGIN
    SET @RefWeaponID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_TSTAFF_01_C_RARE')
END

--Twohand Sword Europe
IF (@RefWeaponID = 10889) BEGIN
    SET @RefWeaponID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_TSWORD_01_C_RARE')
END

--Select Durability
SET @DurHand = (Select Dur_L from _RefObjItem where ID in (Select Link from _RefObjCommon where ID = @RefHandID))
SET @DurMail = (Select Dur_L from _RefObjItem where ID in (Select Link from _RefObjCommon where ID = @RefMailID))
SET @DurBoots = (Select Dur_L from _RefObjItem where ID in (Select Link from _RefObjCommon where ID = @RefBootsID))
SET @DurHat = (Select Dur_L from _RefObjItem where ID in (Select Link from _RefObjCommon where ID = @RefHatID))
SET @DurPants = (Select Dur_L from _RefObjItem where ID in (Select Link from _RefObjCommon where ID = @RefPantsID))
SET @DurShoulder = (Select Dur_L from _RefObjItem where ID in (Select Link from _RefObjCommon where ID = @RefShoulderID))
SET @DurWeapon = (Select Dur_L from _RefObjItem where ID in (Select Link from _RefObjCommon where ID = @RefWeaponID))
SET @DurShield = (Select Dur_L from _RefObjItem where ID in (Select Link from _RefObjCommon where ID = @RefShield))
SET @DurEarring = (Select Dur_L from _RefObjItem where ID in (Select Link from _RefObjCommon where ID = @RefEarringID))
SET @DurRing = (Select Dur_L from _RefObjItem where ID in (Select Link from _RefObjCommon where ID = @RefRingID))
SET @DurNeck = (Select Dur_L from _RefObjItem where ID in (Select Link from _RefObjCommon where ID = @RefNeckID))
-- Initial Equip Edit by LemoniscooL

--set @StartRegionID=25000
-----------------------------------------------------------------------------
-- 1. ??? ?? ??? valid? ???, ??? ???? ??? ?? ????.
-----------------------------------------------------------------------------

    -- start by novice. 
    SELECT @temp = count(CharID) FROM _User WITH (NOLOCK) WHERE UserJID = @UserJID 
   
    IF (@temp >= 4) 
    BEGIN 
        -- ³Ê¹« ¸¹ÀÚ³ª 
        RETURN -2 
    END 
    -- finish by novice. 

    ----------------------------------------------------------------------------- 
    -- 2. ij¸¯ÅÍ Ãß°¡Çϱâ 
    ----------------------------------------------------------------------------- 
    IF (@CharScale > 68) -- 0100 0100 --> 68 ÀÌ´Ù! 
    BEGIN 
        -- ij¸¯ÅÍ »ý¼º ½ÇÆÐ! ½ºÄÉÀÏ °ªÀÌ ÀÌ»óÇÏ´Ù!  
        RETURN -3 
    END

    EXEC @temp = _IsExistingCharName @CharName 
    IF (@temp <> 0) 
    BEGIN 
        -- ÀÌ¹Ì »ç¿ëÁßÀÎ À̸§À̶ó´Âµ¥? 
        RETURN -4 
    END 

BEGIN TRANSACTION

    -- Àδø½Ã½ºÅÛÀÌ Àû¿ëµÇ¸é¼ ¸¶Áö¸·¿¡ WorldID¿Í 1°ªÀ» ´õ ³Ö¾î ÁÖ¾ú´Ù!
    INSERT INTO _Char (RefObjID, CharName16, Scale, Strength, Intellect, LatestRegion,PosX, PosY, PosZ, AppointedTeleport, InventorySize,
                LastLogout, CurLevel, MaxLevel, RemainGold, RemainStatPoint, RemainSkillPoint, HP, MP, JobLvl_Trader, JobLvl_Hunter, JobLvl_Robber, WorldID)
    VALUES (@RefCharID, @CharName, @CharScale, 20, 20, @StartRegionID, @StartPos_X, @StartPos_Y, @StartPos_Z, @DefaultTeleport, 109,
                GetDate(), 1, 1, 5000000, 0, 3000000, 200,200, 1, 1, 1, 1)

    SET @NewCharID = @@IDENTITY 
    IF (@@ERROR <> 0 OR @@ROWCOUNT = 0) 
    BEGIN 
        -- ij¸¯ÅÍ »ý¼º ½ÇÆÐ! 
        ROLLBACK TRANSACTION 
        RETURN -5 
    END 
    -- start by novice. 
    -- ÀÌÁ¦ Slot ¾È¾´´Ù.. ±×³É Insert ¸¸.. 
    INSERT INTO _User VALUES (@UserJID, @NewCharID) 
    -- finish by novice. 


     ----------------------------------------------------------------------------- 
     -- 3-1. Àåºñ ½½·Ô ä¿ì±â 
     -- [Àκ¥Å丮 ½½·Ô 96°³] + [Àåºñ½½·Ô 13°³] <- Àκ¥Å丮 È®Àå ¼ºñ½º ÈÄ 48°³¿¡¼ 96°³·Î Áõ°¡!!!(woos0)
     ----------------------------------------------------------------------------- 
     --PATCH WARNING!!!PATCH WARNING!!!PATCH WARNING!!!PATCH WARNING!!!PATCH WARNING!!!PATCH WARNING!!!PATCH WARNING!!!PATCH WARNING!!!PATCH WARNING!!! 
     INSERT INTO _Inventory(CharID, Slot, ItemID) 
      SELECT @NewCharID, cnt, 0 
       FROM _RefDummySlot with( nolock )
        WHERE cnt < 109 

   
    IF (@@ERROR <> 0) 
    BEGIN 
        -- Àκ¥Å丮 »ý¼º ½ÇÆÐ! 
        ROLLBACK TRANSACTION 
        RETURN -7  
    END 
-- PATCH WARNING!!!PATCH WARNING!!!PATCH WARNING!!!PATCH WARNING!!!PATCH WARNING!!!PATCH WARNING!!!PATCH WARNING!!!PATCH WARNING!!!PATCH WARNING!!!

-- ???? ??? ???? ?? ????...
/* ?? ???  ???? ??.
  0: EQUIP_SLOT_HELM
  1: EQUIP_SLOT_MAIL,
  2: EQUIP_SLOT_SHOULDERGUARD,
  3: EQUIP_SLOT_GAUNTLET,
  4: EQUIP_SLOT_PANTS,
  5: EQUIP_SLOT_BOOTS,
  6: EQUIP_SLOT_WEAPON,
  7: EQUIP_SLOT_SHIELD or ARROW,
  8: EQUIP_SLOT_EARRING,
  9: EQUIP_SLOT_NECKLACE,
10: EQUIP_SLOT_L_RING,
11: EQUIP_SLOT_R_RING,
*/

-- Initial Equip Edit by LemoniscooL
DECLARE @ItemID BIGINT
SET @ItemID = 0
-- Chest
IF (@RefMailID <> 0) BEGIN
    EXEC @ItemID =  _FN_ADD_INITIAL_EQUIP @NewCharID, 1, @RefMailID, @DurMail
    IF (@ItemID <= 0) BEGIN
        ROLLBACK TRANSACTION
        RETURN -8
    END
END
-- Hand
IF (@RefHandID <> 0) BEGIN
    EXEC @ItemID =  _FN_ADD_INITIAL_EQUIP @NewCharID, 3, @RefHandID, @DurHand
    IF (@ItemID <= 0) BEGIN
        ROLLBACK TRANSACTION
        RETURN -8
    END
END
-- Hat
IF (@RefHatID <> 0) BEGIN
    EXEC @ItemID =  _FN_ADD_INITIAL_EQUIP @NewCharID, 0, @RefHatID, @DurHat
    IF (@ItemID <= 0) BEGIN
        ROLLBACK TRANSACTION
        RETURN -8
    END
END
-- Shoulder
IF (@RefShoulderID <> 0) BEGIN
    EXEC @ItemID =  _FN_ADD_INITIAL_EQUIP @NewCharID, 2, @RefShoulderID, @DurShoulder
    IF (@ItemID <= 0) BEGIN
        ROLLBACK TRANSACTION
        RETURN -8
    END
END
-- Pants
IF (@RefPantsID <> 0) BEGIN
    EXEC @ItemID =  _FN_ADD_INITIAL_EQUIP @NewCharID, 4, @RefPantsID, @DurPants
    IF (@ItemID <= 0) BEGIN
        ROLLBACK TRANSACTION
        RETURN -9
    END
END
-- Boots
IF (@RefBootsID <> 0) BEGIN
    EXEC @ItemID =  _FN_ADD_INITIAL_EQUIP @NewCharID, 5, @RefBootsID, @DurBoots
    IF (@ItemID <= 0) BEGIN
        ROLLBACK TRANSACTION
        RETURN -10
    END
END
-- Weapon
IF (@RefWeaponID <> 0) BEGIN
    EXEC @ItemID =  _FN_ADD_INITIAL_EQUIP @NewCharID, 6, @RefWeaponID, @DurWeapon
    IF (@ItemID <= 0) BEGIN
        ROLLBACK TRANSACTION
        RETURN -11
    END
END
-- Shield
IF (@RefShield <> 0) BEGIN
    EXEC @ItemID =  _FN_ADD_INITIAL_EQUIP @NewCharID, 7, @RefShield, @DurShield
    IF (@ItemID <= 0) BEGIN
        ROLLBACK TRANSACTION
        RETURN -12
    END
END
-- Arror/Bolt
IF (@DefaultArrow <> 0) BEGIN
    EXEC @ItemID =  _FN_ADD_INITIAL_EQUIP @NewCharID, 7, @DefaultArrow, 250
    IF (@ItemID <= 0) BEGIN
        ROLLBACK TRANSACTION
        RETURN -13
    END
END
-- Earring
IF (@RefEarringID <> 0) BEGIN
    EXEC @ItemID =  _FN_ADD_INITIAL_EQUIP @NewCharID, 9, @RefEarringID, @DurEarring
    IF (@ItemID <= 0) BEGIN
        ROLLBACK TRANSACTION
        RETURN -8
    END
END
-- Ring 1
IF (@RefRingID <> 0) BEGIN
    EXEC @ItemID =  _FN_ADD_INITIAL_EQUIP @NewCharID, 11, @RefRingID, @DurRing
    IF (@ItemID <= 0) BEGIN
        ROLLBACK TRANSACTION
        RETURN -8
    END
END
-- Ring 2
IF (@RefRingID <> 0) BEGIN
    EXEC @ItemID =  _FN_ADD_INITIAL_EQUIP @NewCharID, 12, @RefRingID, @DurRing
    IF (@ItemID <= 0) BEGIN
        ROLLBACK TRANSACTION
        RETURN -8
    END
END
-- Necklace
IF (@RefNeckID <> 0) BEGIN
    EXEC @ItemID =  _FN_ADD_INITIAL_EQUIP @NewCharID, 10, @RefNeckID, @DurNeck
    IF (@ItemID <= 0) BEGIN
        ROLLBACK TRANSACTION
        RETURN -8
    END
END
-- Initial Equip Edit by LemoniscooL

     ----------------------------------------------------------------------------- 
     -- 3-2. ¾Æ¹ÙŸ Inventory ½½·Ô ä¿ì±â 
     -- [¾Æ¹ÙŸ Àκ¥Å丮 ½½·Ô 5°³]
     -- APPLY_AVATAR_SYSTEMÀÌ Àû¿ëµÇ¸é¼ Ãß°¡µÇ´Â ºÎºÐ
     ----------------------------------------------------------------------------- 
     --PATCH WARNING!!!PATCH WARNING!!!PATCH WARNING!!!PATCH WARNING!!!PATCH WARNING!!!PATCH WARNING!!!PATCH WARNING!!!PATCH WARNING!!!PATCH WARNING!!! 
     INSERT INTO _InventoryForAvatar(CharID, Slot, ItemID) 
      SELECT @NewCharID, cnt, 0
       FROM _RefDummySlot with( nolock )
        WHERE cnt < 5

   
    IF (@@ERROR <> 0) 
    BEGIN 
        -- ¾Æ¹ÙŸ Àκ¥Å丮 »ý¼º ½ÇÆÐ! 
        ROLLBACK TRANSACTION 
        RETURN -14
    END 
    --PATCH WARNING!!!PATCH WARNING!!!PATCH WARNING!!!PATCH WARNING!!!PATCH WARNING!!!PATCH WARNING!!!PATCH WARNING!!!PATCH WARNING!!!PATCH WARNING!!! 
   
    ----------------------------------------------------------------------------- 
    -- default skill³Ö¾îÁÖ±â 
    ----------------------------------------------------------------------------- 
    DECLARE @country tinyINT 
    EXEC @country = _GetObjCountry @RefCharID 
    
    INSERT INTO _CharSkillMastery (CharID, MasteryID, Level) 
    SELECT @NewCharID, MasteryID, 0 
    FROM _RefCharDefault_SkillMastery  with(nolock)
    WHERE Race = @country or Race = 3 
    IF (@@error <> 0) 
    BEGIN 
        ROLLBACK TRANSACTION 
        RETURN -15 
    END 
    INSERT INTO _CharSkill (CharID,SkillID,Enable) 
    SELECT @NewCharID, SkillID, 1 
    FROM  _RefCharDefault_Skill  with(nolock)
    WHERE Race = @country or Race = 3 
    IF (@@error <> 0) 
    BEGIN 
        ROLLBACK TRANSACTION 
        RETURN -16 
    END 
    ----------------------------------------------------------------------------- 
    -- ±âº» Äù½ºÆ® ³Ö¾îÁÖ±â
    ----------------------------------------------------------------------------- 
    INSERT INTO _CharQuest (CharID, QuestID, Status, AchievementCount, StartTime, EndTime, QuestData1, QuestData2) 
    SELECT @NewCharID, ID, 1, 0, getdate(), getdate(), 0, 0 
    FROM _RefQuest
    WHERE CodeName in (SELECT CodeName FROM _RefCharDefault_Quest  with(nolock) WHERE (Race = @country or Race = 3) and RequiredLevel = 1 and Service = 1)
    IF (@@error <> 0)
    BEGIN
        ROLLBACK TRANSACTION 
        RETURN -17 
    END
    ----------------------------------------------------------------------------- 
    -- Static Avatar Initial Record ³Ö±â 
    ----------------------------------------------------------------------------- 
    INSERT INTO _StaticAvatar(CharID) values(@NewCharID) 
    IF (@@ERROR <> 0) 
    BEGIN 
        ROLLBACK TRANSACTION 
        RETURN -18 
    END  
   
    ----------------------------------------------------------------------------- 
    -- Trijob ä¿ö³Ö±â!!!!! 
    ----------------------------------------------------------------------------- 
    INSERT INTO _CharTrijob VALUES (@NewCharID, 0, 1, 0, 0, 0) 
    IF (@@ERROR <> 0) 
    BEGIN 
        -- Àκ¥Å丮 »ý¼º ½ÇÆÐ! 
        ROLLBACK TRANSACTION 
        RETURN -19 
    END  
   
    ----------------------------------------------------------------------------- 
    -- CharList¿¡ ID ³Ö¾îÁÖ±â 
    ----------------------------------------------------------------------------- 
    INSERT _CharNameList VALUES(@CharName, @NewCharID) 
UPDATE _Items SET OptLevel=5 WHERE ID64 IN (SELECT ItemID FROM _Inventory WHERE Slot BETWEEN 0 AND 12 AND Slot Not LIKE '8' AND CharID=@NewCharID)
exec _ADD_ITEM_EXTERN @CharName,'ITEM_EVENT_RENT_REVERSE_RETURN_SCROLL',50,1
exec _ADD_ITEM_EXTERN @CharName,'ITEM_ETC_ARCHEMY_POTION_SPEED_11',10,1
exec _ADD_ITEM_EXTERN @CharName,'ITEM_MALL_HP_SUPERSET_5_BAG',1000,1
exec _ADD_ITEM_EXTERN @CharName,'ITEM_MALL_MP_SUPERSET_5_BAG',1000,1
exec _ADD_ITEM_EXTERN @CharName,'ITEM_COS_MAXIGAME_KARA_SPOT_RABBIT_SCROLL_7D',1,1
  exec _ADD_ITEM_EXTERN @CharName,'PLAYER1_PREMIUM',1,1

--exec _ADD_ITEM_EXTERN @CharName,'ITEM_MALL_RESURRECTION_SCROLL',50,1
--exec _ADD_ITEM_EXTERN @CharName,'ITEM_EVENT_GLOBAL_CHATTING',50,1
--exec _ADD_ITEM_EXTERN @CharName,'ITEM_EVENT_COS_P_MYOWON_SCROLL',1,0
    IF (@RefCharID >= 1907 AND @RefCharID <= 1919) -- MALE CH
    BEGIN
    exec _ADD_ITEM_EXTERN @CharName,'ITEM_EVENT_AVATAR_M_NASRUN',1,0
END
ELSE     IF (@RefCharID >= 14875 AND @RefCharID <= 14887) -- MALE EU
    BEGIN
    exec _ADD_ITEM_EXTERN @CharName,'ITEM_EVENT_AVATAR_M_NASRUN',1,0
END
ELSE     IF (@RefCharID >= 1920 AND @RefCharID <= 1931) -- FEMALE CH
    BEGIN
    exec _ADD_ITEM_EXTERN @CharName,'ITEM_EVENT_AVATAR_W_NASRUN',1,0
END
ELSE     IF (@RefCharID >= 14888 AND @RefCharID <= 14900) -- FEMALE EU
    BEGIN
    exec _ADD_ITEM_EXTERN @CharName,'ITEM_EVENT_AVATAR_W_NASRUN',1,0
END


     
    -- Quick Slot Á¤º¸ ÀúÀå¿ë!!! 
    exec _AddNewClientConfig @NewCharID  -- by novice...... for saving client configurations... 

COMMIT TRANSACTION 
   
RETURN @NewCharID

18.Karakter adı ile silk verme ;
Kod:
use sro_vt_account

declare @SilkMiktari int = 'Eklenecek Silk Miktari'  -- Hesabın sahip olduğu silk miktarının üstüne ekleme yapar (girdiğiniz miktar kadar)..
declare @CharName varchar(50) = 'Charın Tam Adı'  -- Charın adı eksiksiz ve tam bir biçimde olmalıdır..

UPDATE dbo.SK_Silk
SET silk_own = silk_own + @SilkMiktari
WHERE JID = (Select UserJID from SRO_VT_SHARD.._user where CharID=
(Select CharID from SRO_VT_SHARD.._char where CharName16=@CharName))
19. Account ID ile silk verme ;
Kod:
use sro_vt_account

declare @SilkMiktari int = 'Eklenecek Silk Miktari'  -- Hesabın sahip olduğu silk miktarının üstüne ekleme yapar (girdiğiniz miktar kadar)..
declare @UserID varchar(25) = 'Account ID'  -- Hesaba girişte yazdığınız ID yi buraya yazın

UPDATE dbo.SK_Silk
SET silk_own = silk_own + @SilkMiktari
WHERE JID = (Select JID from tb_user where StrUserID=@UserID)

20.Unique elite kaldırma ;
Kod:
USE SRO_VT_SHARD

declare @uniq1 varchar (64) = 'MOB_CH_TIGERWOMAN_L3' -- skilleri alınacak
declare @UniQ2 varchar (64) = 'MOB_CH_TIGERWOMAN' -- skilleri değişecek
declare @id1 int = (select link from _RefObjCommon where CodeName128 = @uniq1)
declare @id2 int = (select link from _RefObjCommon where CodeName128 = @UniQ2)
declare @skill1 int = (select DefaultSkill_1 from _RefObjChar where ID = @id1)
declare @skill2 int = (select DefaultSkill_2 from _RefObjChar where ID = @id1)
declare @skill3 int = (select DefaultSkill_3 from _RefObjChar where ID = @id1)
declare @skill4 int = (select DefaultSkill_4 from _RefObjChar where ID = @id1)
declare @skill5 int = (select DefaultSkill_5 from _RefObjChar where ID = @id1)
declare @skill6 int = (select DefaultSkill_6 from _RefObjChar where ID = @id1)
declare @skill7 int = (select DefaultSkill_7 from _RefObjChar where ID = @id1)
declare @skill8 int = (select DefaultSkill_8 from _RefObjChar where ID = @id1)
declare @skill9 int = (select DefaultSkill_9 from _RefObjChar where ID = @id1)
declare @skill10 int = (select DefaultSkill_10 from _RefObjChar where ID = @id1)




update _RefObjChar set
DefaultSkill_1 = @skill1,
DefaultSkill_2 = @skill2,
DefaultSkill_3 = @skill3,
DefaultSkill_4 = @skill4,
DefaultSkill_5 = @skill5,
DefaultSkill_6 = @skill6,
DefaultSkill_7 = @skill7,
DefaultSkill_8 = @skill8,
DefaultSkill_9 = @skill9,
DefaultSkill_10 = @skill10 where ID=@id2

21.Npc taşıma ;
Kod:
USE SRO_VT_SHARD /*DATABASE ISMI*/

DECLARE @charname1 VARCHAR (30)
DECLARE @NPCPOS VARCHAR (MAX)
DECLARE @ID INT
DECLARE @TACTICSID INT

SET @charname1 = 'Ultimate' -- NPC NİN KOCAĞI YERDEKİ CHAR İSMİ
SET @NPCPOS = 'NPC_SINAN1' -- NPC NİN KODU

DECLARE @regiON1 INT SET @regiON1 = (SELECT (LatestRegion) FROM _Char WHERE CharName16 = @charname1)
DECLARE @posX1 INT SET @posX1 = (SELECT (POSX) FROM _Char WHERE CharName16 = @charname1)
DECLARE @posY1 INT SET @posY1 = (SELECT (POSY) FROM _Char WHERE CharName16 = @charname1)
DECLARE @posZ1 INT SET @posZ1 = (SELECT (POSZ) FROM _Char WHERE CharName16 = @charname1)
SET @ID = (SELECT ID FROM _RefObjCommon WHERE CodeName128=@NPCPOS)
SET @TACTICSID =(SELECT dwTacticsID FROM Tab_RefTactics WHERE dwObjID=@ID)

UPDATE Tab_RefNest SET fLocalPosX= @posX1,fLocalPosY= @posY1,fLocalPosZ= @posZ1,nRegionDBID= @regiON1 WHERE dwTacticsID=@TACTICSID

22.Job ödül verme ;(SRO_VT_LOG'a AddLogChar altına AS'dan sonra ekleyiniz.)
Kod:
IF(@EventID=6 and (select Level from SRO_VT_SHARD.._CharTrijob where CharID = @CharID )=7) --7 = LEVEL
BEGIN
declare @Charname16 varchar(64) = (select Charname16 from SRO_VT_SHARD.._Char where CharID = @CharID)
Update SRO_VT_SHARD.._CharTrijob SET Level=1,Exp=0,Contribution=0 where CharID=@CharID
exec SRO_VT_SHARD.dbo._ADD_ITEM_EXTERN @Charname16,'VERILECEK ITEM KODU',1,0 -- 1 = ADET, 0 = ARTI DEĞERİ
END

23.Honor Rank kapatma ;
Kod:
USE [SRO_VT_SHARD]
GO
/****** Object:  StoredProcedure [dbo].[_TRAINING_CAMP_CREATE]    Script Date: 07.02.2017 01:00:00 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO

ALTER PROCEDURE [dbo].[_TRAINING_CAMP_CREATE]
@CreaterID INT
AS

24.Honor Rank açma ;
Kod:
USE [SRO_VT_SHARD]
GO
/****** Object:  StoredProcedure [dbo].[_TRAINING_CAMP_CREATE]    Script Date: 06.05.2016 05:33:07 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO

ALTER PROCEDURE [dbo].[_TRAINING_CAMP_CREATE]
@CreaterID INT
AS
SET NOCOUNT ON

IF EXISTS (SELECT CharID FROM _TrainingCampMember WHERE CharID = @CreaterID)
BEGIN
RETURN -1001
END

DECLARE @CampID INT
DECLARE @FoundationDate SMALLDATETIME
SET @FoundationDate = GETDATE()

BEGIN TRANSACTION

DECLARE @HonorPoint INT
SET @HonorPoint = 0
SELECT @HonorPoint = HonorPoint FROM _TrainingCampSubMentorHonorPoint WHERE CharID = @CreaterID

IF @HonorPoint <> 0
BEGIN
DELETE FROM _TrainingCampSubMentorHonorPoint WHERE  CharID = @CreaterID
IF (@@ERROR <> 0 OR @@ROWCOUNT = 0)
BEGIN
ROLLBACK TRANSACTION
RETURN -6
END
END

INSERT INTO _TrainingCamp (CreationDate, Rank, GraduateCount, EvaluationPoint,  LatestEvaluationDate, CommentTitle, Comment )
VALUES ( @FoundationDate, 5, 0, 0,  @FoundationDate, '', '')

SET @CampID = @@IDENTITY

IF (@@ERROR <> 0 OR @@ROWCOUNT = 0 OR @CampID = 0)
BEGIN
ROLLBACK TRANSACTION
RETURN -7
END

DECLARE @Ret INT
EXEC @Ret = _TrainingCamp_FnAddMember  @CampID, @CreaterID, @HonorPoint
IF (@@ERROR <> 0 OR @Ret <= 0)
BEGIN
ROLLBACK TRANSACTION
RETURN @Ret
END

COMMIT TRANSACTION

SET NOCOUNT OFF

RETURN @CampID

25.Honor Rank sıfırlama ;
Kod:
truncate table _TrainingCampMember
truncate table _TrainingCampSubMentorHonorPoint
update _TrainingCampHonorRank set CampID = NULL, Rank = NULL
truncate table _TrainingCampBuffStatus
delete from _TrainingCamp

26.Guild player sınırı koyma ;
Kod:
USE [SRO_VT_SHARD]
GO
/****** Object:  StoredProcedure [dbo].[_Guild_FnAddMember]    Script Date: 15.06.2014 11:08:20 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER OFF
GO




ALTER PROCEDURE [dbo].[_Guild_FnAddMember]
@guildID        int,
@MemberID     int,
@MemberClass    tinyint,
@joinDate     smalldatetime,
@permission     int

as
Declare @LiMiT int = '24' -- << Userr Limit Credits by $Apollo
    if (exists (select CharID from _GuildMember where CharID = @MemberID))
    begin
        return -1001
    end


    declare @MemberName    varchar(64)
    declare @curLevel    tinyint
    select @MemberName = CharName16, @curLevel = CurLevel from _Char with (nolock) where CharID = @MemberID
    if (@@error <> 0 or @@rowcount = 0)
    begin
        return -1
    end
    if (exists (select CharID from _GuildMember with (nolock) where GuildID = @guildID and CharID = @MemberID))
    begin
        return -2
    end

        declare @ReFObjID int
    select @ReFObjID = RefObjID from _Char with (nolock) where CharID = @MemberID

    if (@@error <> 0 or @@rowcount = 0)
    begin
        return -5
    end






    declare @siegeAuthority tinyint
    set @siegeAuthority = 0


    if @MemberClass = 0  -- ±æ¸¶ÀÌ¸é °ø¼º±ÇÇÑÀ» commander·Î ¼¼ÆÃ! ±× ¿Ü´Â ÀÏ¹Ý member·Î ¼¼ÆÃÇÑ´Ù.
    begin
        set @siegeAuthority = 1
    end
    Declare @GC int = (Select COUNT(*) from _GuildMember where GuildID = @guildID )
   if @GC  <= @LiMiT begin
    insert _GuildMember values @guildID, @MemberID, @MemberName, @MemberClass, @curLevel, 0, @joinDate @permission, 0, 0, 0, null, @ReFObjID, @siegeAuthority)
    end
    if (@@error <> 0 or @@rowcount = 0)
    begin
        return -3
    end

       if @GC  <= @LiMiT begin
    update _Char Set GuildID = @guildID where CharID = @MemberID
    end
    if (@@error <> 0 or @@rowcount = 0)
    begin
        return -4
    end
    return 1

27.Shard DB sıfırlama ;
Kod:
USE [SRO_VT_SHARD]
GO
delete from _Guild where ID > 0
truncate table _OpenMarket
truncate table _CharSkill
truncate table _CharSkillMastery
truncate table _GuildMember
truncate table _BlockedWhisperers
truncate table _Inventory
truncate table _InventoryForAvatar
truncate table _InventoryForLinkedStorage
truncate table _TrainingCampMember
truncate table _TrainingCampSubMentorHonorPoint
truncate table _TrainingCampHonorRank
truncate table _TrainingCampBuffStatus
delete from _TrainingCamp
truncate table _StaticAvatar
truncate table _User
truncate table _Friend
truncate table _Memo
truncate table _TimedJob
truncate table _CharTrijobSafeTrade
delete from _CharTrijob
truncate table _InvCOS
delete from _CharCOS where ID > 0
delete from _Char where charid > 0
truncate table _Chest
truncate table _ChestInfo
truncate table _ItemPool
delete from _Items where ID64 > 0
delete from _AccountJID
truncate table _GuildChest
update _AlliedClans set Ally1 = 0, Ally2 = 0, Ally3 = 0, Ally4 = 0, Ally5 = 0, Ally6 = 0, Ally7 = 0, Ally8 = 0
truncate table _GuildWar
delete from _AlliedClans where ID > 0
truncate table _CharNameList
truncate table _CharQuest
truncate table _ClientConfig
truncate table _DeletedChar

28.Unique süre ayarlama (süreleri saniye olarak ayarlamalısınız örneğin 5dk istiyorsanız 300 olarak yazmanız gerekir ona göre Update Tab_RefNest Set dwDelayTimeMin=1800 ve dwDelayTimeMax=3600 bilgilerini değiştirmelisinz bu haliyle 1800-3600sn aralığında çıkar uniqueler);
Kod:
--Tiger Girl
Update Tab_RefNest Set dwDelayTimeMin=1800 , dwDelayTimeMax=3600 WHERE dwTacticsID = (SELECT dwTacticsID FROM Tab_RefTactics WHERE dwObjID =
(SELECT ID FROM _RefObjCommon WHERE Codename128 like 'MOB_CH_TIGERWOMAN'))
--Uruchi
Update Tab_RefNest Set dwDelayTimeMin=1800 , dwDelayTimeMax=3600 WHERE dwTacticsID = (SELECT dwTacticsID FROM Tab_RefTactics
WHERE dwObjID =
(SELECT ID FROM _RefObjCommon WHERE Codename128 like 'MOB_OA_URUCHI'))
--Isyutaru
Update Tab_RefNest Set dwDelayTimeMin=2400 , dwDelayTimeMax=4500 WHERE dwTacticsID = (SELECT dwTacticsID FROM Tab_RefTactics WHERE dwObjID =
(SELECT ID FROM _RefObjCommon WHERE Codename128 like 'MOB_KK_ISYUTARU'))
--Lord Yarkan:
Update Tab_RefNest Set dwDelayTimeMin=3000 , dwDelayTimeMax=4500 WHERE dwTacticsID = (SELECT dwTacticsID FROM Tab_RefTactics WHERE dwObjID =
(SELECT ID FROM _RefObjCommon WHERE Codename128 like 'MOB_TK_BONELORD'))
--Demon Shaitan
Update Tab_RefNest Set dwDelayTimeMin=3600 , dwDelayTimeMax=4500 WHERE dwTacticsID = (SELECT dwTacticsID FROM Tab_RefTactics WHERE dwObjID =
(SELECT ID FROM _RefObjCommon WHERE Codename128 like 'MOB_RM_TAHOMET'))
--Cerberus
Update Tab_RefNest Set dwDelayTimeMin=1800 , dwDelayTimeMax=3600 WHERE dwTacticsID = (SELECT dwTacticsID FROM Tab_RefTactics WHERE dwObjID =
(SELECT ID FROM _RefObjCommon WHERE Codename128 like 'MOB_EU_KERBEROS'))
--Captain ivy
Update Tab_RefNest Set dwDelayTimeMin=1800 , dwDelayTimeMax=3600 WHERE dwTacticsID = (SELECT dwTacticsID FROM Tab_RefTactics WHERE dwObjID =
(SELECT ID FROM _RefObjCommon WHERE Codename128 like 'MOB_AM_IVY'))

29.F1 Bug fix ;
Kod:
USE [SRO_VT_SHARD]
GO
UPDATE _RefCharDefault_Quest SET Service = 1
delete from _CHARQUEST where QuestID = 1
INSERT INTO _CharQuest (CharID, QuestID, Status,AchievementCount,StartTime,EndTime,QuestData1,QuestData2) SELECT CharID, 1,5,0, '2012-04-13 20:44:00','2012-04-13 20:44:00',31458135,0 FROM _CHAR where CharID > 0

30.Mob Rate düzenleme (Not: minLevel her zaman MaxLevel'den düşük olmalıdır.

MaxSpawnCount hakkında;
Solo slotlar için 5,
LTP slotları için, 7
Party slotları için 10 idealdir.

Daha fazlasını yapmanız sunucunuzda lag oluşumuna sebebiyet verecektir.) ;
Kod:
Use SRO_VT_SHARD
declare @minLevel int = 74 -- Minimum mob level.
declare @MaxLevel int = 76 -- Maximum mob level.
declare @MaxSpawnCount int = 9 -- Spawn rate (Suggested; Maximum 12)


update Tab_RefNest
set dwMaxTotalCount = @MaxSpawnCount
from Tab_RefNest as A
inner join Tab_RefTactics as B
on A.dwTacticsID = B.dwTacticsID
inner join _RefObjCommon as C
on B.dwObjID = C.ID
inner join _RefObjChar as D
on C.Link = D.ID
where D.Lvl between @minLevel and @MaxLevel and CodeName128 like 'MOB%' and Rarity = 0 and dwMaxTotalCount > 0

31.Wizard Skill bug fixleme;
Kod:
USE SRO_VT_SHARD
update _RefSkill set Service = '0' where Basic_Code like 'SKILL_EU_STAFF_BASE_01'
update _CharSkill set Enable = '0' where SkillID like '9944'

32.Çöpleri droptan kaldırma;
Kod:
USE [SRO_VT_SHARD]
GO

UPDATE dbo._RefDropItemAssign
SET Service = 0
WHERE RefItemID BETWEEN 6679 AND 5414

UPDATE dbo._RefDropItemAssign
SET Service = 0
WHERE RefItemID BETWEEN 6082 AND 6371

UPDATE dbo._RefDropItemAssign
SET Service = 0
WHERE RefItemID BETWEEN 10501 AND 10527

UPDATE dbo._RefDropItemAssign
SET Service = 0
WHERE RefItemID BETWEEN 11499 AND 11668

UPDATE dbo._RefDropItemAssign
SET Service = 0
WHERE RefItemID BETWEEN 12554 AND 12569

33.Job ve Guild ceza kaldırma;
Kod:
USE [SRO_VT_SHARD]
GO
/******By Jangan ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO

ALTER   procedure [dbo].[_AddTimedJob]
@CharID            int,
@Category        tinyint,
@JobID            int,
@TimeToKeep    int,
@Data1            int,
@Data2            int,
--##begin due to develop composite item
@Data3            int,
@Data4            int,
@Data5            int,
@Data6            int,
@Data7            int,
@Data8            int,
@Serial64        bigint,
@JID            int
--##end due to develop composite item
as
    if (not exists (select CharID from _Char with (nolock) where CharID = @CharID))
                return -1
            if (@TimeToKeep <= 0)
                return -2
            declare @NewJobID int
            set @NewJobID = 0

            --##JobID 1 = Guild // JobID 2 = Thief/Hunter/Trader
            --##If you want to only have one not both, then just modify the line below!
            if (@JobID = 1 or @JobID = 2)
            BEGIN
                return -1
            END
            ELSE
            BEGIN
            --##begin due to develop composite item
            insert into _TimedJob(CharID,Category,JobID,TimeToKeep,Data1,Data2,Data3,Data4,Data5,Data6,Data7,Data8,Serial64,JID)
            values(@CharID, @Category, @JobID, @TimeToKeep, @Data1, @Data2, @Data3, @Data4, @Data5, @Data6, @Data7, @Data8, @Serial64, @JID)
            END
            --##end due to develop composite item
            set @NewJobID = @@identity
            if (@@error <> 0 or @@rowcount = 0)
             
                return -3
     return @NewJobID

34.Uniquelere "has appeared" yazısını ekleme;
Kod:
USE [SRO_VT_SHARD]
GO
UPDATE dbo._RefObjCommon SET Rarity = 3 WHERE CodeName128 = 'MOB_CH_TIGERWOMAN'
UPDATE dbo._RefObjCommon SET Rarity = 3 WHERE CodeName128 = 'MOB_EU_KERBEROS'
UPDATE dbo._RefObjCommon SET Rarity = 3 WHERE CodeName128 = 'MOB_AM_IVY'
UPDATE dbo._RefObjCommon SET Rarity = 3 WHERE CodeName128 = 'MOB_OA_URUCHI'
UPDATE dbo._RefObjCommon SET Rarity = 3 WHERE CodeName128 = 'MOB_KK_ISYUTARU'
UPDATE dbo._RefObjCommon SET Rarity = 3 WHERE CodeName128 = 'MOB_TK_BONELORD'
UPDATE dbo._RefObjCommon SET Rarity = 3 WHERE CodeName128 = 'MOB_RM_TAHOMET'
UPDATE dbo._RefObjCommon SET Rarity = 3 WHERE CodeName128 = 'MOB_TQ_WHITESNAKE'
UPDATE dbo._RefObjCommon SET Rarity = 3 WHERE CodeName128 = 'MOB_RM_ROC'
UPDATE dbo._RefObjCommon SET Rarity = 3 WHERE CodeName128 = 'MOB_SD_SETH'
UPDATE dbo._RefObjCommon SET Rarity = 3 WHERE CodeName128 = 'MOB_SD_SPHINX'
UPDATE dbo._RefObjCommon SET Rarity = 3 WHERE CodeName128 = 'MOB_SD_HORUS'
UPDATE dbo._RefObjCommon SET Rarity = 3 WHERE CodeName128 = 'MOB_SD_NEITH'
UPDATE dbo._RefObjCommon SET Rarity = 3 WHERE CodeName128 = 'MOB_SD_ISIS'
UPDATE dbo._RefObjCommon SET Rarity = 3 WHERE CodeName128 = 'MOB_SD_ERIS'
UPDATE dbo._RefObjCommon SET Rarity = 3 WHERE CodeName128 = 'MOB_SD_APIS'
UPDATE dbo._RefObjCommon SET Rarity = 3 WHERE CodeName128 = 'MOB_RM_DEVILSAYTAN'
UPDATE dbo._RefObjCommon SET Rarity = 3 WHERE CodeName128 = 'MOB_TQ_BLACKSNAKE'
UPDATE dbo._RefObjCommon SET Rarity = 3 WHERE CodeName128 = 'MOB_GM_T46'
UPDATE dbo._RefObjCommon SET Rarity = 3 WHERE CodeName128 = 'MOB_GM_GETZ'
UPDATE dbo._RefObjCommon SET Rarity = 3 WHERE CodeName128 = 'MOB_JUPITER_THE_EARTH1'
UPDATE dbo._RefObjCommon SET Rarity = 3 WHERE CodeName128 = 'MOB_JUPITER_THE_EARTH2'
UPDATE dbo._RefObjCommon SET Rarity = 3 WHERE CodeName128 = 'MOB_JUPITER_DARK_DOG'
UPDATE dbo._RefObjCommon SET Rarity = 3 WHERE CodeName128 = 'MOB_JUPITER_DARK_DOG2'
UPDATE dbo._RefObjCommon SET Rarity = 3 WHERE CodeName128 = 'MOB_SD_SEKHMET_3'
UPDATE dbo._RefObjCommon SET Rarity = 3 WHERE CodeName128 = 'MOB_SD_SEKHMET_2'
UPDATE dbo._RefObjCommon SET Rarity = 3 WHERE CodeName128 = 'MOB_SD_SEKHMET_STR'
UPDATE dbo._RefObjCommon SET Rarity = 3 WHERE CodeName128 = 'MOB_SD_APIS'
UPDATE dbo._RefObjCommon SET Rarity = 3 WHERE CodeName128 = 'MOB_SD_ERIS'
UPDATE dbo._RefObjCommon SET Rarity = 3 WHERE CodeName128 = 'MOB_SD_HORUS'
UPDATE dbo._RefObjCommon SET Rarity = 3 WHERE CodeName128 = 'MOB_SD_HORUS_2'
UPDATE dbo._RefObjCommon SET Rarity = 3 WHERE CodeName128 = 'MOB_SD_HORUS_3'
UPDATE dbo._RefObjCommon SET Rarity = 3 WHERE CodeName128 = 'MOB_SD_OSIRIS'
UPDATE dbo._RefObjCommon SET Rarity = 3 WHERE CodeName128 = 'MOB_SD_OSIRIS_2'
UPDATE dbo._RefObjCommon SET Rarity = 3 WHERE CodeName128 = 'MOB_SD_OSIRIS_3'

35.FGW Envy çıkmama sorununu fixleme;
Kod:
USE [SRO_VT_SHARD]

GO --/*Fix Envy*/

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '41540'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '41550'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '41560'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '41570'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '41580'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '41590'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '42460'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '42470'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '42480'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '42490'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '42500'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '42510'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '42520'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '42530'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '43420'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '43430'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '43440'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '43450'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '43460'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '43470'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '43480'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '43490'
36.FGW Boss Unique çıkmama fixleme;
Kod:
USE [SRO_VT_SHARD]

GO --/*Fix Boss Uniques*/

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '43580'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '43590'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '43600'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '43610'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '43620'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '43630'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '43640'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '43650'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '43660'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '43670'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '43680'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '43690'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '43700'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '43710'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '43720'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '43730'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '43740'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '43750'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '43760'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '43770'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '43780'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '43790'

37.FGW Treasure Box çıkmama fixleme;
Kod:
USE [SRO_VT_SHARD]

GO --/*For Treasure Box*/

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '41600'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '41610'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '41620'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '41630'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '41640'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '41650'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '42540'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '42550'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '42560'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '42570'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '42580'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '42590'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '42600'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '42610'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '43500'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '43510'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '43520'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '43530'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '43540'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '43550'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '43560'

UPDATE Tab_RefNest SET dwMaxTotalCount = 1 WHERE dwTacticsID LIKE '43570'

38.Togui kapılarını açma;
Kod:
USE [SRO_VT_SHARD]
GO
update _RefEventZone set Service = 0 where ZoneName like '%GATE_TOGUI%'

39.Togui kapılarını kapatma;
Kod:
USE [SRO_VT_SHARD]
GO
update _RefEventZone set Service = 1 where ZoneName like '%GATE_TOGUI%'

40.Bütün karakterlerin skillerini sıfırlama;
Kod:
USE [SRO_VT_SHARD] 
GO 
update _ClientConfig 
set Data = '0' 
DELETE FROM [dbo].[_CharSkill] 
      WHERE  SKillID NOT LIKE '1' and  SKillID NOT LIKE '2' and  SKillID NOT LIKE '40' 
      and  SKillID NOT LIKE '70' and  SKillID NOT LIKE '8421' and  SKillID NOT LIKE '8419' 
      and  SKillID NOT LIKE '8420' and  SKillID NOT LIKE '9354' and  SKillID NOT LIKE '9355' 
      and  SKillID NOT LIKE '9944' and  SKillID NOT LIKE '10625' and  SKillID NOT LIKE '11162' 
      and  SKillID NOT LIKE '11526' 
GO  

UPDATE [dbo].[_CharSkillMastery] 
   SET  
      [Level] = '0' 


--- 
UPDATE [dbo].[_Char] 
  SET RemainSkillPoint = RemainSkillPoint + @GiveSP 
  WHERE CharName16 = @CharName

41.Website Online Sayısını 2x gösterme;
USE [SRO_VT_ACCOUNT]
GO
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
ALTER PROCEDURE [dbo].[_AddCurrentUserCount]
@nShardID INT,
@nUserCount INT,
@dLogDate DATETIME
AS
SET @nUserCount=@nUserCount*2
BEGIN
INSERT INTO _ShardCurrentUser (nShardID, nUserCount, dLogDate) VALUES (@nShardID, @nUserCount, @dLogDate)
END

42.Bütün karakterlerin skillerini sıfırlama;
USE [SRO_VT_SHARD]
GO
update _ClientConfig
set Data = '0'
DELETE FROM [dbo].[_CharSkill]
WHERE SKillID NOT LIKE '1' and SKillID NOT LIKE '2' and SKillID NOT LIKE '40'
and SKillID NOT LIKE '70' and SKillID NOT LIKE '8421' and SKillID NOT LIKE '8419'
and SKillID NOT LIKE '8420' and SKillID NOT LIKE '9354' and SKillID NOT LIKE '9355'
and SKillID NOT LIKE '9944' and SKillID NOT LIKE '10625' and SKillID NOT LIKE '11162'
and SKillID NOT LIKE '11526'
GO

UPDATE [dbo].[_CharSkillMastery]
SET
[Level] = '0'


---
UPDATE [dbo].[_Char]
SET RemainSkillPoint = RemainSkillPoint + @GiveSP
WHERE CharName16 = @CharName

43.Invertoyda ve Ustunuzdeki tum item ID lerini bulma
USE [SRO_VT_SHARD]
/**** ItemIDKod *****/
SELECT
[dbo].[_Inventory].[CharID],
[dbo].[_Char].[CharName16],
[dbo].[_Inventory].[Slot],
[dbo].[_Inventory].[ItemID],
[dbo].[_Items].[RefItemID],
[dbo].[_Items].[OptLevel],
[dbo].[_RefObjCommon].[CodeName128]
FROM [dbo].[_Inventory]
JOIN [dbo].[_Char] ON [dbo].[_Inventory].[CharID] = [dbo].[_Char].[CharID]
JOIN [dbo].[_Items] ON [dbo].[_Inventory].[ItemID] = [dbo].[_Items].[ID64]
JOIN [dbo].[_RefObjCommon] ON [dbo].[_Items].[RefItemID] = [dbo].[_RefObjCommon].[ID]
WHERE [dbo].[_Char].[CharName16] like'NickYazin'
ORDER BY[dbo].[_Char].[CharName16]ASC,[dbo].[_Inventory].[Slot]ASC;

44.NPC Taşıma(NPC yi taşıyacağınız yere bir char götürüp kod da düzenlenmesi gereken yerleri düzenleyip excute yapınız.)
USE SRO_VT_SHARD /*DATABASE ISMI*/

DECLARE @charname1 VARCHAR (30)
DECLARE @NPCPOS VARCHAR (MAX)
DECLARE @ID INT
DECLARE @TACTICSID INT

SET @charname1 = 'Ultimate' -- NPC NİN KOCAĞI YERDEKİ CHAR İSMİ
SET @NPCPOS = 'NPC_SINAN1' -- NPC NİN KODU

DECLARE @regiON1 INT SET @regiON1 = (SELECT (LatestRegion) FROM _Char WHERE CharName16 = @charname1)
DECLARE @posX1 INT SET @posX1 = (SELECT (POSX) FROM _Char WHERE CharName16 = @charname1)
DECLARE @posY1 INT SET @posY1 = (SELECT (POSY) FROM _Char WHERE CharName16 = @charname1)
DECLARE @posZ1 INT SET @posZ1 = (SELECT (POSZ) FROM _Char WHERE CharName16 = @charname1)
SET @ID = (SELECT ID FROM _RefObjCommon WHERE CodeName128=@NPCPOS)
SET @TACTICSID =(SELECT dwTacticsID FROM Tab_RefTactics WHERE dwObjID=@ID)

UPDATE Tab_RefNest SET fLocalPosX= @posX1,fLocalPosY= @posY1,fLocalPosZ= @posZ1,nRegionDBID= @regiON1 WHERE dwTacticsID=@TACTICSID

:footer:
 
Son düzenleme:

ExcI

a better world
Kayıt
17 Kasım 2016
Mesajlar
3.186
Beğeniler
468

  • Merhaba arkadaşlar vsro için işinize yarayabilecek kodlara buradan ulaşabilirsiniz.Gördükçe eklemeler yapacağım iyi forumlar.
1.Moblardan istediğiniz eşyanın drobunu kaldırma ;
Kod:
USE SRO_VT_SHARD
GO
DELETE _RefDropItemAssign
FROM _RefDropItemAssign Drops
LEFT JOIN _RefObjCommon Objects
ON (Drops.RefItemID = Objects.ID)
WHERE CodeName128 like 'Itemın kodunu buraya yazacaksınız'
.
.
.
.


teşekkür tosun
 
Yukarı Alt