Ok lets see what we can do:
With this you no need use any scripts all what you need to do is follow this steps.
Change Siege Ritual day and time
1) go to MSSQL database character -> Programmability
__a) expand Function
__b) expand Scalar-valued Functions
Go to dbo.FN.GetDungeonRegistTime (click right mouse button and select Modify)
Here we can change when we can start Siege Ritual -8 is how many days before we can start Siege Ritual 17:00:00 its hour
[Only registered and activated users can see links. Click Here To Register...]
After change press Execute or press F5
Change Date and time for Siege Battle
2) -||-
__a) -||-
__b) Press right mouse button on dbo.GetSiegeStartBinTime and select Modify
[Only registered and activated users can see links. Click Here To Register...]
After change press Execute or press F5
Now run your server login to your account with GM character.
use command /gm siegestart now and then use command /gm siegeend now
For Sunday start:
USE [CHARACTER]
GO
/****** Object: UserDefinedFunction [dbo].[FN_GetSiegeStartBinTime] Script Date: 25.10.2020 01:31:12 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
/************************************************** ****************************
이 름 : dbo.FN_GetSiegeStartBinTime
설 명 : 다음 공성전 시작일자를 반환한다.
예 제 : select dbo.FN_GetSiegeStartTime --//반환값 : 0x23E52D6C
수정내역:
Ver Date Author Description
--------- ---------- --------------- -----------------------------------
1.0 2006-05-05 Han Ji Wook 1. 초기생성
1.1 2006-05-11 Han Ji Wook 1. 다음공성전 시작시간 변경 >> 2주후 일요일
1.2 2009-12-22 Park Chanik 1. 공성 2010년 에러 관련 변경
************************************************** ****************************/
ALTER FUNCTION [dbo].[FN_GetSiegeStartBinTime]
(
@i_GetDate DATETIME
) RETURNS VARBINARY(4)
AS
BEGIN
DECLARE @v_siege_start_time VARBINARY(4)
DECLARE @v_siege_start_date VARCHAR(14)
--// 다음공성전 시작시간 Default Setting : 일요일 9시
SELECT @v_siege_start_date = CONVERT(VARCHAR(10), DATEADD(d, 8-DATEPART(dw, @i_GetDate), @i_GetDate), 112) + '210000'
-- 2009년 12월 22일 변경
-- CAST(SUBSTRING(@v_siege_start_date,4,1) AS INT)* 100000000 ---> CAST(SUBSTRING(@v_siege_start_date,3,2) AS INT)* 100000000
SELECT @v_siege_start_time = CAST(SUBSTRING(@v_siege_start_date,3,2) AS INT) * 100000000
+ CAST(SUBSTRING(@v_siege_start_date,5,2) AS INT) * 1000000
+ CAST(SUBSTRING(@v_siege_start_date,7,2) AS INT) * 10000
+ CAST(SUBSTRING(@v_siege_start_date,9,2) AS INT) * 100
+ CAST(SUBSTRING(@v_siege_start_date,11,2) AS INT)
IF DATALENGTH(@v_siege_start_time) <> 4
BEGIN
SELECT @v_siege_start_time = 0x00000000
END
RETURN @v_siege_start_time
END
For Saturday:
USE [CHARACTER]
GO
/****** Object: UserDefinedFunction [dbo].[FN_GetSiegeStartBinTime] Script Date: 25.10.2020 01:31:12 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
/************************************************** ****************************
이 름 : dbo.FN_GetSiegeStartBinTime
설 명 : 다음 공성전 시작일자를 반환한다.
예 제 : select dbo.FN_GetSiegeStartTime --//반환값 : 0x23E52D6C
수정내역:
Ver Date Author Description
--------- ---------- --------------- -----------------------------------
1.0 2006-05-05 Han Ji Wook 1. 초기생성
1.1 2006-05-11 Han Ji Wook 1. 다음공성전 시작시간 변경 >> 2주후 일요일
1.2 2009-12-22 Park Chanik 1. 공성 2010년 에러 관련 변경
************************************************** ****************************/
ALTER FUNCTION [dbo].[FN_GetSiegeStartBinTime]
(
@i_GetDate DATETIME
) RETURNS VARBINARY(4)
AS
BEGIN
DECLARE @v_siege_start_time VARBINARY(4)
DECLARE @v_siege_start_date VARCHAR(14)
--// 다음공성전 시작시간 Default Setting : 일요일 9시
SELECT @v_siege_start_date = CONVERT(VARCHAR(10), DATEADD(d, 7-DATEPART(dw, @i_GetDate), @i_GetDate), 112) + '210000'
-- 2009년 12월 22일 변경
-- CAST(SUBSTRING(@v_siege_start_date,4,1) AS INT)* 100000000 ---> CAST(SUBSTRING(@v_siege_start_date,3,2) AS INT)* 100000000
SELECT @v_siege_start_time = CAST(SUBSTRING(@v_siege_start_date,3,2) AS INT) * 100000000
+ CAST(SUBSTRING(@v_siege_start_date,5,2) AS INT) * 1000000
+ CAST(SUBSTRING(@v_siege_start_date,7,2) AS INT) * 10000
+ CAST(SUBSTRING(@v_siege_start_date,9,2) AS INT) * 100
+ CAST(SUBSTRING(@v_siege_start_date,11,2) AS INT)
IF DATALENGTH(@v_siege_start_time) <> 4
BEGIN
SELECT @v_siege_start_time = 0x00000000
END
RETURN @v_siege_start_time
END
8 - Sunday
7 - Saturday
6 - Friday
5 - Thursday
4 - Wednesday
3 - Tuesday
2 - Monday
With this you no need use any scripts all what you need to do is follow this steps.
Change Siege Ritual day and time
1) go to MSSQL database character -> Programmability
__a) expand Function
__b) expand Scalar-valued Functions
Go to dbo.FN.GetDungeonRegistTime (click right mouse button and select Modify)
Here we can change when we can start Siege Ritual -8 is how many days before we can start Siege Ritual 17:00:00 its hour
[Only registered and activated users can see links. Click Here To Register...]
After change press Execute or press F5
Change Date and time for Siege Battle
2) -||-
__a) -||-
__b) Press right mouse button on dbo.GetSiegeStartBinTime and select Modify
[Only registered and activated users can see links. Click Here To Register...]
After change press Execute or press F5
Now run your server login to your account with GM character.
use command /gm siegestart now and then use command /gm siegeend now
For Sunday start:
USE [CHARACTER]
GO
/****** Object: UserDefinedFunction [dbo].[FN_GetSiegeStartBinTime] Script Date: 25.10.2020 01:31:12 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
/************************************************** ****************************
이 름 : dbo.FN_GetSiegeStartBinTime
설 명 : 다음 공성전 시작일자를 반환한다.
예 제 : select dbo.FN_GetSiegeStartTime --//반환값 : 0x23E52D6C
수정내역:
Ver Date Author Description
--------- ---------- --------------- -----------------------------------
1.0 2006-05-05 Han Ji Wook 1. 초기생성
1.1 2006-05-11 Han Ji Wook 1. 다음공성전 시작시간 변경 >> 2주후 일요일
1.2 2009-12-22 Park Chanik 1. 공성 2010년 에러 관련 변경
************************************************** ****************************/
ALTER FUNCTION [dbo].[FN_GetSiegeStartBinTime]
(
@i_GetDate DATETIME
) RETURNS VARBINARY(4)
AS
BEGIN
DECLARE @v_siege_start_time VARBINARY(4)
DECLARE @v_siege_start_date VARCHAR(14)
--// 다음공성전 시작시간 Default Setting : 일요일 9시
SELECT @v_siege_start_date = CONVERT(VARCHAR(10), DATEADD(d, 8-DATEPART(dw, @i_GetDate), @i_GetDate), 112) + '210000'
-- 2009년 12월 22일 변경
-- CAST(SUBSTRING(@v_siege_start_date,4,1) AS INT)* 100000000 ---> CAST(SUBSTRING(@v_siege_start_date,3,2) AS INT)* 100000000
SELECT @v_siege_start_time = CAST(SUBSTRING(@v_siege_start_date,3,2) AS INT) * 100000000
+ CAST(SUBSTRING(@v_siege_start_date,5,2) AS INT) * 1000000
+ CAST(SUBSTRING(@v_siege_start_date,7,2) AS INT) * 10000
+ CAST(SUBSTRING(@v_siege_start_date,9,2) AS INT) * 100
+ CAST(SUBSTRING(@v_siege_start_date,11,2) AS INT)
IF DATALENGTH(@v_siege_start_time) <> 4
BEGIN
SELECT @v_siege_start_time = 0x00000000
END
RETURN @v_siege_start_time
END
For Saturday:
USE [CHARACTER]
GO
/****** Object: UserDefinedFunction [dbo].[FN_GetSiegeStartBinTime] Script Date: 25.10.2020 01:31:12 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
/************************************************** ****************************
이 름 : dbo.FN_GetSiegeStartBinTime
설 명 : 다음 공성전 시작일자를 반환한다.
예 제 : select dbo.FN_GetSiegeStartTime --//반환값 : 0x23E52D6C
수정내역:
Ver Date Author Description
--------- ---------- --------------- -----------------------------------
1.0 2006-05-05 Han Ji Wook 1. 초기생성
1.1 2006-05-11 Han Ji Wook 1. 다음공성전 시작시간 변경 >> 2주후 일요일
1.2 2009-12-22 Park Chanik 1. 공성 2010년 에러 관련 변경
************************************************** ****************************/
ALTER FUNCTION [dbo].[FN_GetSiegeStartBinTime]
(
@i_GetDate DATETIME
) RETURNS VARBINARY(4)
AS
BEGIN
DECLARE @v_siege_start_time VARBINARY(4)
DECLARE @v_siege_start_date VARCHAR(14)
--// 다음공성전 시작시간 Default Setting : 일요일 9시
SELECT @v_siege_start_date = CONVERT(VARCHAR(10), DATEADD(d, 7-DATEPART(dw, @i_GetDate), @i_GetDate), 112) + '210000'
-- 2009년 12월 22일 변경
-- CAST(SUBSTRING(@v_siege_start_date,4,1) AS INT)* 100000000 ---> CAST(SUBSTRING(@v_siege_start_date,3,2) AS INT)* 100000000
SELECT @v_siege_start_time = CAST(SUBSTRING(@v_siege_start_date,3,2) AS INT) * 100000000
+ CAST(SUBSTRING(@v_siege_start_date,5,2) AS INT) * 1000000
+ CAST(SUBSTRING(@v_siege_start_date,7,2) AS INT) * 10000
+ CAST(SUBSTRING(@v_siege_start_date,9,2) AS INT) * 100
+ CAST(SUBSTRING(@v_siege_start_date,11,2) AS INT)
IF DATALENGTH(@v_siege_start_time) <> 4
BEGIN
SELECT @v_siege_start_time = 0x00000000
END
RETURN @v_siege_start_time
END
8 - Sunday
7 - Saturday
6 - Friday
5 - Thursday
4 - Wednesday
3 - Tuesday
2 - Monday