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 = '20' -- << 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
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 = '20' -- << 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
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 = '20' 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
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' 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