Merhaba, Hoşgeldin!

VSRO.org, Silkroad Online, Knight Online, Metin2 ve diğer çevrimiçi oyunlar için öncü bir yardım ve geliştirme platformudur. Misyonumuz, bilgi ve deneyim sahibi bireyleri, bilgiye ihtiyaç duyanlarla bir araya getirerek, zengin bir etkileşim ortamı yaratmak ve farklı bakış açılarını birleştirmektir. Topluluğumuzda güçlü bir işbirliği ve öğrenme kültürü oluşturarak, herkesin değerli katkılarda bulunmasını sağlıyoruz.

vSRO Çözüldü VSRO Ilk Baslangıç Her Char´da Kıyafet ile StartSilk

Katılım
6 Kas 2021
Mesajlar
37
Tepkime puanı
25
Puanları
8
Yaş
47
Konum
Angara
Türk Lirası
0.00₺
Selam Arkadaşlar,



Ilk Başlangıç icin her Char´da Kıyafet olsun mu + Kolyeler ? bunu AddNewChar´a kopyala ozaman...


Öncelikle buraya girmeniz gerek:

SRO_VT_SHARD -->Programmability--->Stored Procedures-->
_AddNewChar

AddNewChar Sağ Tiklayiniz ---> Modify basınız


Bu Örneğin icindeki kırmızı yazılı olanı kendi Tablonuza yükleyiniz, ardından "EXECUTE"´e basınız. Serveri yeniden baslat ve yeni Char Olustur görürsünz.



Kirmizi Olan: Kiyafetler
Yesil Olan: Silk
Mavi Olan: Ilk Para/Skillpoint Başlangıç


ÖRNEK:

USE [SRO_VT_SHARD]
GO
/****** Object: StoredProcedure [dbo].[_AddNewChar] Script Date: 04.12.2021 19:43:40 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
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

-- 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_A')
SET @RefMailID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_M_CLOTHES_01_BA_A')
SET @RefBootsID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_M_CLOTHES_01_FA_A')
SET @RefHatID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_M_CLOTHES_01_HA_A')
SET @RefPantsID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_M_CLOTHES_01_LA_A')
SET @RefShoulderID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_M_CLOTHES_01_SA_A')
SET @RefEarringID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_EARRING_01_A')
SET @RefNeckID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_NECKLACE_01_A')
SET @RefRingID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_RING_01_A')
END

--Male Heavy Armor Chinese
IF (@RefMailID = 3637) BEGIN
SET @RefHandID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_M_HEAVY_01_AA_A')
SET @RefMailID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_M_HEAVY_01_BA_A')
SET @RefBootsID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_M_HEAVY_01_FA_A')
SET @RefHatID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_M_HEAVY_01_HA_A')
SET @RefPantsID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_M_HEAVY_01_LA_A')
SET @RefShoulderID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_M_HEAVY_01_SA_A')
SET @RefEarringID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_EARRING_01_A')
SET @RefNeckID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_NECKLACE_01_A')
SET @RefRingID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_RING_01_A')
END

--Male Light Armor Chinese
IF (@RefMailID = 3640) BEGIN
SET @RefHandID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_M_LIGHT_01_AA_A')
SET @RefMailID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_M_LIGHT_01_BA_A')
SET @RefBootsID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_M_LIGHT_01_FA_A')
SET @RefHatID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_M_LIGHT_01_HA_A')
SET @RefPantsID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_M_LIGHT_01_LA_A')
SET @RefShoulderID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_M_LIGHT_01_SA_A')
SET @RefEarringID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_EARRING_01_A')
SET @RefNeckID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_NECKLACE_01_A')
SET @RefRingID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_RING_01_A')
END

--Female Clothes Chinese
IF (@RefMailID = 3652) BEGIN
SET @RefHandID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_W_CLOTHES_01_AA_A')
SET @RefMailID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_W_CLOTHES_01_BA_A')
SET @RefBootsID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_W_CLOTHES_01_FA_A')
SET @RefHatID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_W_CLOTHES_01_HA_A')
SET @RefPantsID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_W_CLOTHES_01_LA_A')
SET @RefShoulderID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_W_CLOTHES_01_SA_A')
SET @RefEarringID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_EARRING_01_A')
SET @RefNeckID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_NECKLACE_01_A')
SET @RefRingID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_RING_01_A')
END

--Female Heavy Armor Chinese
IF (@RefMailID = 3646) BEGIN
SET @RefHandID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_W_HEAVY_01_AA_A')
SET @RefMailID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_W_HEAVY_01_BA_A')
SET @RefBootsID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_W_HEAVY_01_FA_A')
SET @RefHatID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_W_HEAVY_01_HA_A')
SET @RefPantsID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_W_HEAVY_01_LA_A')
SET @RefShoulderID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_W_HEAVY_01_SA_A')
SET @RefEarringID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_EARRING_01_A')
SET @RefNeckID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_NECKLACE_01_A')
SET @RefRingID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_RING_01_A')
END

--Female Light Armor Chinese
IF (@RefMailID = 3649) BEGIN
SET @RefHandID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_W_LIGHT_01_AA_A')
SET @RefMailID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_W_LIGHT_01_BA_A')
SET @RefBootsID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_W_LIGHT_01_FA_A')
SET @RefHatID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_W_LIGHT_01_HA_A')
SET @RefPantsID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_W_LIGHT_01_LA_A')
SET @RefShoulderID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_W_LIGHT_01_SA_A')
SET @RefEarringID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_EARRING_01_A')
SET @RefNeckID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_NECKLACE_01_A')
SET @RefRingID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_CH_RING_01_A')
END

--Male Clothes Europe
IF (@RefMailID = 11623) BEGIN
SET @RefHandID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_M_CLOTHES_01_AA_A')
SET @RefMailID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_M_CLOTHES_01_BA_A')
SET @RefBootsID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_M_CLOTHES_01_FA_A')
SET @RefHatID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_M_CLOTHES_01_HA_A')
SET @RefPantsID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_M_CLOTHES_01_LA_A')
SET @RefShoulderID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_M_CLOTHES_01_SA_A')
SET @RefEarringID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_EARRING_01_A')
SET @RefNeckID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_NECKLACE_01_A')
SET @RefRingID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_RING_01_A')
END

--Male Heavy Armor Europe
IF (@RefMailID = 11617) BEGIN
SET @RefHandID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_M_HEAVY_01_AA_A')
SET @RefMailID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_M_HEAVY_01_BA_A')
SET @RefBootsID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_M_HEAVY_01_FA_A')
SET @RefHatID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_M_HEAVY_01_HA_A')
SET @RefPantsID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_M_HEAVY_01_LA_A')
SET @RefShoulderID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_M_HEAVY_01_SA_A')
SET @RefEarringID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_EARRING_01_A')
SET @RefNeckID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_NECKLACE_01_A')
SET @RefRingID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_RING_01_A')
END

--Male Light Armor Europe
IF (@RefMailID = 11620) BEGIN
SET @RefHandID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_M_LIGHT_01_AA_A')
SET @RefMailID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_M_LIGHT_01_BA_A')
SET @RefBootsID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_M_LIGHT_01_FA_A')
SET @RefHatID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_M_LIGHT_01_HA_A')
SET @RefPantsID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_M_LIGHT_01_LA_A')
SET @RefShoulderID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_M_LIGHT_01_SA_A')
SET @RefEarringID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_EARRING_01_A')
SET @RefNeckID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_NECKLACE_01_A')
SET @RefRingID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_RING_01_A')
END

--Female Clothes Europe
IF (@RefMailID = 11632) BEGIN
SET @RefHandID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_W_CLOTHES_01_AA_A')
SET @RefMailID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_W_CLOTHES_01_BA_A')
SET @RefBootsID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_W_CLOTHES_01_FA_A')
SET @RefHatID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_W_CLOTHES_01_HA_A')
SET @RefPantsID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_W_CLOTHES_01_LA_A')
SET @RefShoulderID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_W_CLOTHES_01_SA_A')
SET @RefEarringID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_EARRING_01_A')
SET @RefNeckID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_NECKLACE_01_A')
SET @RefRingID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_RING_01_A')
END

--Female Heavy Armor Europe
IF (@RefMailID = 11626) BEGIN
SET @RefHandID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_W_HEAVY_01_AA_A')
SET @RefMailID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_W_HEAVY_01_BA_A')
SET @RefBootsID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_W_HEAVY_01_FA_A')
SET @RefHatID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_W_HEAVY_01_HA_A')
SET @RefPantsID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_W_HEAVY_01_LA_A')
SET @RefShoulderID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_W_HEAVY_01_SA_A')
SET @RefEarringID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_EARRING_01_A')
SET @RefNeckID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_NECKLACE_01_A')
SET @RefRingID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_RING_01_A')
END

--Female Light Armor Europe
IF (@RefMailID = 11629) BEGIN
SET @RefHandID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_W_LIGHT_01_AA_A')
SET @RefMailID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_W_LIGHT_01_BA_A')
SET @RefBootsID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_W_LIGHT_01_FA_A')
SET @RefHatID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_W_LIGHT_01_HA_A')
SET @RefPantsID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_W_LIGHT_01_LA_A')
SET @RefShoulderID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_W_LIGHT_01_SA_A')
SET @RefEarringID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_EARRING_01_A')
SET @RefNeckID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_NECKLACE_01_A')
SET @RefRingID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_RING_01_A')
END

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

--Twohand Sword Europe
IF (@RefWeaponID = 10889) BEGIN
SET @RefWeaponID = (SELECT ID FROM _RefObjCommon WHERE CodeName128='ITEM_EU_TSWORD_01_A')
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))


SET NOCOUNT ON

DECLARE @Slot INT
DECLARE @temp INT

DECLARE @NewCharID INT
SET @NewCharID = 0


-----------------------------------------------------------------------------
-- 1. ij¸¯ÅÍ ½½·Ô ³Ñ¹ö°¡ validÇÑ °ÍÀÎÁö, ±×¸®°í ºó½½·ÔÀÌ ¸Â´ÂÁö ¸ÕÀú üũÇÑ´Ù.
-----------------------------------------------------------------------------

-- start by novice.
SELECT @temp = count(CharID) FROM _User WITH (NOLOCK) WHERE UserJID = @UserJID

IF (@temp >= 4)
BEGIN
-- ³أٹ¹« ¸¹أ€أڑ³آھ
RETURN -2
END

IF @temp = 0
INSERT INTO VSRO_ACCOUNT.dbo.SK_SILK (JID,Silk_own,Silk_point,Silk_gift)
VALUES (@UserJID, 800, 0,0)
-- 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, 45,
GetDate(), 1, 1, 10000000, 0, 500, 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,
*/

DECLARE @ItemID BIGINT
SET @ItemID = 0
-- Chest
IF (@RefMailID <> 0) BEGIN
EXEC @ItemID = _FN_ADD_INITIAL_EQUIP @NewCharID, 1, @RefMailID, @DurMail

update _Items
set MagParamNum = 6,
MagParam1 = 12884901893,
MagParam2 = 12884901899,
MagParam3 = 85899346048,
MagParam4 = 257698037840,
MagParam5 = 128849019020,
MagParam6 = 128849019032,
MagParam7 = 0,
MagParam8 = 0,
MagParam9 = 0
where ID64 = @ItemID

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

update _Items
set MagParamNum = 4,
MagParam1 = 12884901893,
MagParam2 = 12884901899,
MagParam3 = 85899346048,
MagParam4 = 257698037840,
MagParam5 = 0,
MagParam6 = 0,
MagParam7 = 0,
MagParam8 = 0,
MagParam9 = 0
where ID64 = @ItemID

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

update _Items
set MagParamNum = 6,
MagParam1 = 12884901893,
MagParam2 = 12884901899,
MagParam3 = 85899346048,
MagParam4 = 257698037840,
MagParam5 = 128849019020,
MagParam6 = 128849019032,
MagParam7 = 0,
MagParam8 = 0,
MagParam9 = 0
where ID64 = @ItemID

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

update _Items
set MagParamNum = 4,
MagParam1 = 12884901893,
MagParam2 = 12884901899,
MagParam3 = 85899346048,
MagParam4 = 257698037840,
MagParam5 = 0,
MagParam6 = 0,
MagParam7 = 0,
MagParam8 = 0,
MagParam9 = 0
where ID64 = @ItemID

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

update _Items
set MagParamNum = 6,
MagParam1 = 12884901893,
MagParam2 = 12884901899,
MagParam3 = 85899346048,
MagParam4 = 257698037840,
MagParam5 = 128849019020,
MagParam6 = 128849019032,
MagParam7 = 0,
MagParam8 = 0,
MagParam9 = 0
where ID64 = @ItemID


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

update _Items
set MagParamNum = 4,
MagParam1 = 12884901893,
MagParam2 = 12884901899,
MagParam3 = 85899346048,
MagParam4 = 257698037840,
MagParam5 = 0,
MagParam6 = 0,
MagParam7 = 0,
MagParam8 = 0,
MagParam9 = 0
where ID64 = @ItemID

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

update _Items
set MagParamNum = 5,
MagParam1 = 12884901893,
MagParam2 = 12884901899,
MagParam3 = 85899346012,
MagParam4 = 257698037840,
MagParam5 = 150323855464,
MagParam6 = 0,
MagParam7 = 0,
MagParam8 = 0,
MagParam9 = 0
where ID64 = @ItemID

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

update _Items
set MagParamNum = 4,
MagParam1 = 12884901893,
MagParam2 = 12884901899,
MagParam3 = 257698037840,
MagParam4 = 150323855476,
MagParam5 = 0,
MagParam6 = 0,
MagParam7 = 0,
MagParam8 = 0,
MagParam9 = 0
where ID64 = @ItemID

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

update _Items
set MagParamNum = 7,
MagParam1 = 12884901899,
MagParam2 = 12884901893,
MagParam3 = 21474836509,
MagParam4 = 21474836503,
MagParam5 = 21474836497,
MagParam6 = 21474836515,
MagParam7 = 21474836521,
MagParam8 = 0,
MagParam9 = 0
where ID64 = @ItemID

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

update _Items
set MagParamNum = 7,
MagParam1 = 12884901893,
MagParam2 = 12884901899,
MagParam3 = 21474836509,
MagParam4 = 21474836503,
MagParam5 = 21474836497,
MagParam6 = 21474836515,
MagParam7 = 21474836521,
MagParam8 = 0,
MagParam9 = 0
where ID64 = @ItemID

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

update _Items
set MagParamNum = 7,
MagParam1 = 12884901899,
MagParam2 = 12884901893,
MagParam3 = 21474836509,
MagParam4 = 21474836503,
MagParam5 = 21474836497,
MagParam6 = 21474836515,
MagParam7 = 21474836521,
MagParam8 = 0,
MagParam9 = 0
where ID64 = @ItemID

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

update _Items
set MagParamNum = 7,
MagParam1 = 12884901893,
MagParam2 = 12884901899,
MagParam3 = 21474836509,
MagParam4 = 21474836503,
MagParam5 = 21474836497,
MagParam6 = 21474836515,
MagParam7 = 21474836521,
MagParam8 = 0,
MagParam9 = 0
where ID64 = @ItemID

IF (@ItemID <= 0) BEGIN
ROLLBACK TRANSACTION
RETURN -8
END
END


-----------------------------------------------------------------------------
-- 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

-----------------------------------------------------------------------------
-- Event 2018 exp sp
-----------------------------------------------------------------------------
insert into _TimedJob ( [CharID],[Category],[JobID],[TimeToKeep],[Data1],[Data2] ,[Data3],[Data4],[Data5],[Data6],[Data7],[Data8],[Serial64],[JID])
values (@NewCharID,10,47986,1885696629,1885696629,250,0,0,0,0,0,0,72339069015894980,0)
insert _TimedJob ( [CharID],[Category],[JobID],[TimeToKeep],[Data1],[Data2] ,[Data3],[Data4],[Data5],[Data6],[Data7],[Data8],[Serial64],[JID])
values (@NewCharID,10,47987,1885696629,1886614133,250,0,0,0,0,0,0,72339069015894980,0)
-----------------------------------------------------------------------------

-----------------------------------------------------------------------------
-- CharList¿¡ ID ³Ö¾îÁÖ±â
-----------------------------------------------------------------------------
INSERT _CharNameList VALUES(@CharName, @NewCharID)
UPDATE _Char SET RemainGold=0, RemainSkillPoint=1000 , AppointedTeleport= 41947 WHERE _Char.CharID = @NewCharID
exec _ADD_ITEM_EXTERN @CharName,'ITEM_ETC_E060118_60EXP_HELP',1,1
exec _ADD_ITEM_EXTERN @CharName,'ITEM_ETC_E060118_100EXP_HELP',1,1
exec _ADD_ITEM_EXTERN @CharName,'ITEM_ETC_SCROLL_RETURN_NEWBIE_01',20,1
exec _ADD_ITEM_EXTERN @CharName,'ITEM_ETC_SPEED_UP_BASIC',20,1

SELECT @temp = count(CharID) FROM _User WITH (NOLOCK) WHERE UserJID = @UserJID
IF (@temp = 1)
BEGIN
exec _ADD_ITEM_EXTERN @CharName,'ITEM_EVENT_BOLT',1000,0
exec _ADD_ITEM_EXTERN @CharName,'ITEM_EVENT_QUIVER',1000,0
exec _ADD_ITEM_EXTERN @CharName,'ITEM_EVENT_AVATAR_M_NASRUN',1,0
exec _ADD_ITEM_EXTERN @CharName,'ITEM_EVENT_AVATAR_W_NASRUN',1,0


--Founder name For 1st char on acc
END

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

COMMIT TRANSACTION

RETURN @NewCharID

 
Geri
Üst Alt