Hamza FiGo |
20-10-2014 04:33 PM |
استفسار بخصوص Scroll remove advanced
انا عملت 3 سكرولات تمام واشتغلو تمام وكل حاجة
Remove advanced elixir- Change char name - Reset stat points
بس لما عملت الاسكرولات دي حصل باج في الــ FGW لما حد يدخل بيجيلة DC
شيلت الــ Procedures بتاعتها وحطيت بتاعتي الاصلية الـ FGW اشتغلت تمام
سؤالي بقا اية المشكلة في الـ Procedures دي اللي في _AddTimedJob
كود:
USE [SRO_VT_SHARD]
GO
/****** Object: StoredProcedure [dbo].[_AddTimedJob] Script Date: 12/28/2013 22:12:00 ******/
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(@JobID = '45000')
BEGIN
declare @CharName16 varchar(64)
Select @CharName16=CharName16 from _Char where CharID = @CharID
Update _Char Set CharName16 = '@'+ @CharName16 Where CharID = @CharID
END
if(@JobID = '45001')
begin
declare @Strength int
declare @Intellect int
declare @MaxLevel int
declare @RemainStatPoint int
select @MaxLevel = MaxLevel from _Char where CharID = @CharID
set @RemainStatPoint = (@MaxLevel*3)-3
set @MaxLevel = @MaxLevel+19
UPDATE _Char SET Strength=@MaxLevel, Intellect=@MaxLevel, RemainStatPoint=@RemainStatPoint WHERE CharID=@CharID
end
if(@JobID = '34005')
begin
Update _Char Set DailyPK = 0 Where CharID = @CharID
Update _Char Set TotalPK = 0 Where CharID = @CharID
Update _Char Set PKPenaltyPoint = 0 Where CharID = @CharID
end
if(@JobID= '55000')
begin
declare @TotalSP int
declare @TotalSPMastery int
SELECT @TotalSP = SUM(_RefSkill.ReqLearn_SP) FROM _RefSkill, _CharSkill WHERE _RefSkill.ID=_CharSkill.SkillID AND _CharSkill.CharID=@CharID AND _RefSkill.ReqCommon_MasteryLevel1 <= '130'
SELECT @TotalSPMastery = SUM(_RefLevel.Exp_M) FROM _CharSkillMastery, _RefLevel WHERE _RefLevel.Lvl=_CharSkillMastery.Level AND _CharSkillMastery.CharID=@CharID AND _CharSkillMastery.Level <= '130'
UPDATE _Char SET RemainSkillPoint=RemainSkillPoint+@TotalSP+@TotalSPMastery+200000 WHERE CharID=@CharID
DELETE _CharSkill FROM _RefSkill, _CharSkill WHERE _RefSkill.ID=_CharSkill.SkillID AND _CharSkill.CharID=@CharID AND _RefSkill.ReqCommon_MasteryLevel1 <= '130' AND _RefSkill.ID NOT IN (1,70,40,2,8421,9354,9355,11162,9944,8419,8420,11526,10625)
UPDATE _CharSkillMastery SET Level='0' WHERE CharID=@CharID AND Level <= '130'
end
if(@JobID= '34038')
begin
Update _Items Set MagParamNum = 0, MagParam1 = NULL, MagParam2 = NULL, MagParam3 = NULL, MagParam4 = NULL, MagParam5 = NULL, MagParam6 = NULL, MagParam7 = NULL, MagParam8 = NULL, MagParam9 = NULL, MagParam10 = NULL, MagParam11 = NULL, MagParam12 = NULL where ID64 in (select ItemID from _Inventoryforavatar where CharID = @CharID and Slot between 0 and 2 and ItemID>0)
end
if(@JobID= '34003') --
begin
Select @CharName16=CharName16 from _Char where CharID = @CharID
begin
DELETE FROM _BindingOptionWithItem where nItemDBID IN (SELECT ItemID FROM _Inventory
WHERE CharID=@CharID) and bOptType=2
end
end
if(@JobID = '45010')---gift---
begin
declare @tradenum int
declare @gift varchar(128)
set @gift =('ITEM_ETC_SD_TOKEN_02')
SET @tradenum =(SELECT ABLECOUNT from _CharTrijobSafeTrade where CharID =@CharID )
if (@tradenum >=1)
begin
select @CharName16 =CharName16 from _Char where CharID=@CharID
exec _ADD_ITEM_EXTERN @CharName16,@gift,10,1
update _CharTrijobSafeTrade set AbleCount =0 where CharID =@CharID
end
end
if
(@JobID= '99999')
BEGIN
DECLARE @CharName Varchar (MAX)
Select @CharName16=CharName16 from _Char where CharID = @CharID
Begin
DELETE FROM _TimedJob WHERE Data2 between 1 AND 11000 AND CharID = @CharID
end
end
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
insert into _TimedJob(CharID,Category,JobID,TimeToKeep,Data1,Data2,Data3,Data4,Data5,Data6,Data7,Data8,Serial64,JID)
values(@CharID, @Category, @JobID, 1, @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
دي Procedures بتاعت che9299 . دلوقتي الاسكرولات مش شغال علشان لازم اضيف البروسيدجر
اية المشكلة فيها ومالها ومال الـ FGW
شكرا
|