THX a lot for this script and all WORK Great JOB MAN
Works on MsSQL 2000 + Windows XP Pro x32 +SP3
Quote:
USE [Character]
GO
/****** Object: UserDefinedFunction [dbo].[FN_BinDateToDateTime] Script Date: 01/10/2010 19:35:14 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER OFF
GO
/************************************************** ****************************
이 름 : dbo.FN_BinDateToDateTime
설 명 : Binary Date를 DateTime 형식으로 반환한다.
반환값 :
수정내역:
Ver Date Author Description
--------- ---------- --------------- ------------------------------------
1.0 2006-05-05 Han Ji Wook 1. 초기생성
2.0 2010-01-10 ADM-Cyrax/Darth Nerd
************************************************** ****************************/
ALTER FUNCTION [dbo].[FN_BinDateToDateTime] (
@i_bin_time binary(4)
) RETURNS datetime
AS
BEGIN
DECLARE @v_datetime datetime
DECLARE @v_strAux varchar(20)
DECLARE @v_strtime varchar(20)
SET @v_strAux = CAST(CAST(@i_bin_time as int) as varchar(20))
IF len(@v_strAux) = 7
SELECT @v_strtime = '20100' + CAST(CAST(@i_bin_time as int) as varchar(20))
ELSE
IF len(@v_strAux) = 8
SELECT @v_strtime = '2010' + CAST(CAST(@i_bin_time as int) as varchar(20))
ELSE
SELECT @v_strtime = '201' + CAST(CAST(@i_bin_time as int) as varchar(20))
SELECT @v_strtime = SUBSTRING(@v_strtime,1,4)
+'-'+SUBSTRING(@v_strtime,5,2)
+'-'+SUBSTRING(@v_strtime,7,2)
+' '+SUBSTRING(@v_strtime,9,2)
+':'+SUBSTRING(@v_strtime,11,2)
SELECT @v_datetime = CAST(@v_strtime as datetime)
RETURN @v_datetime
END
Ok DF is WORK but how to start siege, when i put command in game /gm siegestart 21:00
then Dekaronserver.exe crash
How to add auto start in SQL Query?? or just use this
SET @v_strDate1=dbo.FN_BinDateToDateTime(@v_siege_star t_time)
DECLARE @P1 varchar(13)
SET @P1=NULL
DECLARE @P2 varchar(33)
SET @P2=NULL
DECLARE @P3 varchar(25)
SET @P3=NULL
DECLARE @P4 varbinary(4)
SET @P4=NULL
DECLARE @P5 varbinary(4)
SET @P5=NULL
DECLARE @P6 varbinary(4)
SET @P6=NULL
DECLARE @P7 varbinary(4)
SET @P7=NULL
DECLARE @P8 varbinary(4)
SET @P8=NULL
DECLARE @P9 varbinary(4)
SET @P9=NULL
DECLARE @P10 varbinary(4)
SET @P10=NULL
DECLARE @P11 varbinary(2)
SET @P11=NULL
DECLARE @P12 varbinary(2)
SET @P12=NULL
DECLARE @P13 varbinary(2)
SET @P13=NULL
DECLARE @P14 int
SET @P14=NULL
DECLARE @P15 int
SET @P15=NULL
DECLARE @P16 varbinary(4)
SET @P16=NULL
DECLARE @P17 varbinary(996)
SET @P17=NULL
DECLARE @P18 varbinary(996)
SET @P18=NULL
DECLARE @P19 varbinary(1000)
SET @P19=NULL
DECLARE @P20 int
SET @P20=NULL
EXEC SP_SIEGE_INFO_R 1, @P1 output, @P2 output, @P3 output, @P4 output, @P5 output, @P6 output, @P7 output, @P8 output, @P9 output, @P10 output, @P11 output, @P12 output, @P13 output, @P14 output, @P15 output, @P16 output, @P17 output, @P18 output, @P19 output, @P20 output
SELECT @P1, @P2, @P3, @P4, @P5, @P6,@v_strDate1
i write how to use
1) Use This
Quote:
USE [Character]
GO
/****** Object: UserDefinedFunction [dbo].[FN_BinDateToDateTime] Script Date: 01/10/2010 19:35:14 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER OFF
GO
/************************************************** ****************************
이 름 : dbo.FN_BinDateToDateTime
설 명 : Binary Date를 DateTime 형식으로 반환한다.
반환값 :
수정내역:
Ver Date Author Description
--------- ---------- --------------- ------------------------------------
1.0 2006-05-05 Han Ji Wook 1. 초기생성
2.0 2010-01-10 ADM-Cyrax/Darth Nerd
************************************************** ****************************/
ALTER FUNCTION [dbo].[FN_BinDateToDateTime] (
@i_bin_time binary(4)
) RETURNS datetime
AS
BEGIN
DECLARE @v_datetime datetime
DECLARE @v_strAux varchar(20)
DECLARE @v_strtime varchar(20)
SET @v_strAux = CAST(CAST(@i_bin_time as int) as varchar(20))
IF len(@v_strAux) = 7
SELECT @v_strtime = '20100' + CAST(CAST(@i_bin_time as int) as varchar(20))
ELSE
IF len(@v_strAux) = 8
SELECT @v_strtime = '2010' + CAST(CAST(@i_bin_time as int) as varchar(20))
ELSE
SELECT @v_strtime = '201' + CAST(CAST(@i_bin_time as int) as varchar(20))
SELECT @v_strtime = SUBSTRING(@v_strtime,1,4)
+'-'+SUBSTRING(@v_strtime,5,2)
+'-'+SUBSTRING(@v_strtime,7,2)
+' '+SUBSTRING(@v_strtime,9,2)
+':'+SUBSTRING(@v_strtime,11,2)
SELECT @v_datetime = CAST(@v_strtime as datetime)
RETURN @v_datetime
END
Server: Msg 2627, Level 14, State 1, Line 39
Violation of PRIMARY KEY constraint 'PK_GUILD_INFO'. Cannot insert duplicate key in object 'GUILD_INFO'.
The statement has been terminated.
Server: Msg 2627, Level 14, State 1, Line 42
Violation of PRIMARY KEY constraint 'PK_SIEGE_INFO'. Cannot insert duplicate key in object 'SIEGE_INFO'.
The statement has been terminated.
Server: Msg 2627, Level 14, State 1, Line 39
Violation of PRIMARY KEY constraint 'PK_GUILD_INFO'. Cannot insert duplicate key in object 'GUILD_INFO'.
The statement has been terminated.
Server: Msg 2627, Level 14, State 1, Line 42
Violation of PRIMARY KEY constraint 'PK_SIEGE_INFO'. Cannot insert duplicate key in object 'SIEGE_INFO'.
The statement has been terminated.
(1 row(s) affected)
(1 row(
this i get lawl...
If you do not have a clean database, I would advise me to clear all entries. Somewhere here on the forum I saw a file from the SQL scripts. Errors show what you take from here is that the database already exist, such records had the same problem as I did reborn. cleared the database and did everything again and now everything works. If I had more time it will give you a clean and efficient database of active and DF Siege + reborn. But I need more time.
Please help siege script 08/31/2010 - Dekaron Private Server - 27 Replies when i run siege script i got this error msg.
Msg 241, Level 16, State 1, Procedure SP_SIEGE_START_TIME_U, Line 52
Conversion failed when converting date and/or time from character string.
Why i try to run siege srcipt again ? !!!
cuz i got this error.
http://upic.me/i/gb/siegeerror.jpg
NEW ERROR SIEGE LOOK! 08/21/2010 - Dekaron Private Server - 9 Replies http://img713.imageshack.us/img713/1224/siegeerror .jpg
yo guys can you help me ?? O.O idk how fix some ideas ??
thanks
Siege error 02/19/2010 - Dekaron Private Server - 4 Replies http://www.imagesforme.com/upload/b48b9fa5.jpg
i followed this tutorial
http://www.elitepvpers.com/forum/2moons-pserver-ho sting/426175-release-temporary-maybe-official-fix- siege-df-errors.html
script to siege! 01/07/2010 - Dekaron Private Server - 41 Replies this is the full script to siege enjoy!
DECLARE @v_siege_no char(10)
DECLARE @guild_code varchar(10)
DECLARE @v_strDate varchar(10)
DECLARE @v_regdate varchar(10)
DECLARE @v_strChannel varchar(2)
DECLARE @i_bychannel tinyint
DECLARE @o_dwDungeonRegistTime varbinary(4)
[HELP]Siege error 08/23/2009 - Dekaron Private Server - 11 Replies well, i added the thing at query analyzer.
into the server section/master.
Then i go ingame and give in /gm siegestart 5:00
then i look to dbmon:
http://i26.tinypic.com/i4n5ed.jpg