رد: Auto Event 'Ask And Questions' On Vsro Multi Tool
الناس الا عندها مشاكل و الايفنت مش شغال عندهم اعمل البروسيدور الاتنين دول و هيشتغل معاكم من غير مشاكل
كود PHP:
USE [DANGERSS]
GO
/****** Object: StoredProcedure [dbo].[_AutomaticTriviaEvent_1] Script Date: 7/4/2016 10:20:24 PM ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
/***************************************** Start System ***************************************************************/
--===================================================================
--------------------------------------/CREATE By Danger/-------------
--===================================================================
CREATE Procedure [dbo].[_AutomaticTriviaEvent_1]
as
BEGIN
DECLARE @Question Varchar (max)
select Top 1 @Question=[Question] from _AutomaticTrivia_Questions order by newid()
update _AutomaticTrivia_Questions set [service]=1 where Question=@Question
insert into DANGERSS..iLegend_Tool (Service,Type,Message,Date) values ('1','Notice','Automatic trivia event has started.[To answer PM [BOT] with Trivia:Answer]',GETDATE())
insert into DANGERSS..iLegend_Tool (Service,Type,Message,Date) values ('1','Notice',@Question,GETDATE())
IF (SELECT SERVICE FROM _AutomaticTrivia_Questions where question=@Question) = 1
BEGIN
insert into DANGERSS..iLegend_Tool (Service,Type,Message,Date) values ('1','Notice','Automatic trivia event has started without winners',GETDATE())
END
END
GO
/****** Object: StoredProcedure [dbo].[_AutomaticTriviaEvent_2] Script Date: 7/4/2016 10:21:08 PM ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
/***************************************** Start System ***************************************************************/
--===================================================================
--------------------------------------/CREATE By Danger/-------------
--===================================================================
CREATE Procedure [dbo].[_AutomaticTriviaEvent_2]
@SenderName VARCHAR(255),
@Message VARCHAR(255)
as
BEGIN
DECLARE @Answer Varchar(max) = (Select Answer from DANGERSS.dbo._AutomaticTrivia_Questions where [Service]='1')
DECLARE @CharID INT,@WinnerJID INT,@WinnerID INT,@Silk_Own INT,@Reward INT ,@RewardType int,@RewardCodeName int,@CharName int,@RewardCount int,@Reward2 Varchar(Max)
select @CharID=[CharID] from SRO_VT_SHARD.dbo._Char where CharName16 = @SenderNAme
select @WinnerJID=[UserJID] from SRO_VT_SHARD.dbo._User where CharID = @CharID
select @Silk_Own=[silk_own] from SRO_VT_ACCOUNT.dbo.SK_Silk where JID = @WinnerJID
select @Reward2= 10
select @Reward= 10
If (@Message=@Answer)
BEGIN
insert into DANGERSS..iLegend_Tool (Service,Type,Message,Date) values ('1','Notice',''+@SenderName+' has written '+@Answer+' and won this round.',GETDATE())
Update SRO_VT_ACCOUNT.dbo.SK_Silk SET silk_own = @Silk_Own + @Reward where JID = @WinnerJID
insert into DANGERSS..iLegend_Tool (Service,Type,Message,Date) values ('1','Notice','Automatic Trivia Event has ended.',GETDATE())
insert into DANGERSS..iLegend_Tool (Service,Type,target,Message,Date) values ('1','Private',@SenderName,'Congratulations, you won in the event and received '+@Reward2+' silks as reward.',GETDATE())
update _AutomaticTrivia_Questions set [Service]=0 where [Service]=1
Exec [SRO_VT_SHARD].[dbo].[_ADD_ITEM_EXTERN] @CharName,'ITEM_ETC_ARENA_COIN',@RewardCount,'100'
End
رد: Auto Event 'Ask And Questions' On Vsro Multi Tool
عندى مشكلة
السيستم شغال زى الفل
بس لما برد على الاكونت بالاجابة مش بيحصل اى حاجة خالص
و بيظهر فى البرنامج
Error 03 please report it to the developer
اقتباس:
USE [SRO_VT_SHARDLOG]
GO
/****** Object: StoredProcedure [dbo].[_AutomaticTriviaEvent_2] Script Date: 7/4/2016 10:21:08 PM ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
/***************************************** Start System ************************************************** *************/
--================================================== =================
--------------------------------------/CREATE By Danger/-------------
--================================================== =================
CREATE Procedure [dbo].[_AutomaticTriviaEvent_2]
@SenderName VARCHAR(255),
@Message VARCHAR(255)
as
BEGIN
DECLARE @Answer Varchar(max) = (Select Answer from SRO_VT_SHARDLOG.dbo._AutomaticTrivia_Questions where [Service]='1')
DECLARE @CharID INT,@WinnerJID INT,@WinnerID INT,@Silk_Own INT,@Reward INT ,@RewardType int,@RewardCodeName int,@CharName int,@RewardCount int,@Reward2 Varchar(Max)
select @CharID=[CharID] from SRO_VT_SHARD.dbo._Char where CharName16 = @SenderNAme
select @WinnerJID=[UserJID] from SRO_VT_SHARD.dbo._User where CharID = @CharID
select @Silk_Own=[silk_own] from SRO_VT_ACCOUNT.dbo.SK_Silk where JID = @WinnerJID
select @Reward2= 10
select @Reward= 10
If (@Message=@Answer)
BEGIN
insert into SRO_VT_SHARDLOG..iLegend_Tool (Service,Type,Message,Date) values ('1','Notice',''+@SenderName+' has written '+@Answer+' and won this round.',GETDATE())
Update SRO_VT_ACCOUNT.dbo.SK_Silk SET silk_own = @Silk_Own + @Reward where JID = @WinnerJID
insert into SRO_VT_SHARDLOG..iLegend_Tool (Service,Type,Message,Date) values ('1','Notice','Automatic Trivia Event has ended.',GETDATE())
insert into SRO_VT_SHARDLOG..iLegend_Tool (Service,Type,target,Message,Date) values ('1','Private',@SenderName,'Congratulations, you won in the event and received '+@Reward2+' silks as reward.',GETDATE())
update _AutomaticTrivia_Questions set [Service]=0 where [Service]=1
Exec [SRO_VT_SHARD].[dbo].[_ADD_ITEM_EXTERN] @SenderName,'ITEM_ETC_ARENA_COIN','10',0
End
END
GO
اقتباس:
USE [SRO_VT_SHARDLOG]
GO
/****** Object: StoredProcedure [dbo].[_AutomaticTriviaEvent_2] Script Date: 7/4/2016 10:21:08 PM ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
/***************************************** Start System ************************************************** *************/
--================================================== =================
--------------------------------------/CREATE By Danger/-------------
--================================================== =================
CREATE Procedure [dbo].[_AutomaticTriviaEvent_2]
@SenderName VARCHAR(255),
@Message VARCHAR(255)
as
BEGIN
DECLARE @Answer Varchar(max) = (Select Answer from SRO_VT_SHARDLOG.dbo._AutomaticTrivia_Questions where [Service]='1')
DECLARE @CharID INT,@WinnerJID INT,@WinnerID INT,@Silk_Own INT,@Reward INT ,@RewardType int,@RewardCodeName int,@CharName int,@RewardCount int,@Reward2 Varchar(Max)
select @CharID=[CharID] from SRO_VT_SHARD.dbo._Char where CharName16 = @SenderNAme
select @WinnerJID=[UserJID] from SRO_VT_SHARD.dbo._User where CharID = @CharID
select @Silk_Own=[silk_own] from SRO_VT_ACCOUNT.dbo.SK_Silk where JID = @WinnerJID
select @Reward2= 10
select @Reward= 10
If (@Message=@Answer)
BEGIN
insert into SRO_VT_SHARDLOG..iLegend_Tool (Service,Type,Message,Date) values ('1','Notice',''+@SenderName+' has written '+@Answer+' and won this round.',GETDATE())
Update SRO_VT_ACCOUNT.dbo.SK_Silk SET silk_own = @Silk_Own + @Reward where JID = @WinnerJID
insert into SRO_VT_SHARDLOG..iLegend_Tool (Service,Type,Message,Date) values ('1','Notice','Automatic Trivia Event has ended.',GETDATE())
insert into SRO_VT_SHARDLOG..iLegend_Tool (Service,Type,target,Message,Date) values ('1','Private',@SenderName,'Congratulations, you won in the event and received '+@Reward2+' silks as reward.',GETDATE())
update _AutomaticTrivia_Questions set [Service]=0 where [Service]=1
Exec [SRO_VT_SHARD].[dbo].[_ADD_ITEM_EXTERN] @SenderName,'ITEM_ETC_ARENA_COIN','10',0
End