Jump to content
  • 0

Automated TimerStart on NPC.


realRO

Question


  • Group:  Members
  • Topic Count:  29
  • Topics Per Day:  0.01
  • Content Count:  84
  • Reputation:   0
  • Joined:  12/24/13
  • Last Seen:  

I wanted to start my event every Wednesday 11:00 ends at 11:30 and 20:00 ends  20:30.

 

Here's what I put. Looks like every wednesday 11:00 it is not starting:

 

-	script	KoE	-1,{
OnInit:
	disablenpc "The King#KoE";
	disablenpc "Get Your Prize Here#KoE";
	bindatcmd "koe", strnpcinfo(0)+"::Oncommand", 99,99;
	end;
Oncommand:
	if ( compare( .@atcmd_parameters$, "on" ) ) goto L_start;
	else if ( compare( .@atcmd_parameters$, "off" ) ) goto L_end;
	else {
		dispbottom "type - '@koe on' to start the event";
		dispbottom "type - '@koe off' to end the event";
	}
	end;
L_start:
OnWed2000:
OnWed1100:
	gvgon "guild_vs1";
	announce "The King of Emperium Hill has begun!", bc_all;
	.start = 1;
	enablenpc "The King#KoE";
	disablenpc "Get Your Prize Here#KoE";
	$koegid = 0;
	donpcevent "::OnRevKoE";
	maprespawnguildid "guild_vs1", $koegid, 7;
	monster "guild_vs1",49,49,"EMPERIUM",1288,1,"KoE::OnEmpDead";
	end;		
L_end:
OnWed2030:
OnWed1130:
	gvgoff "guild_vs1";
	announce "The King of Emperium Hill is over!", bc_all;

 

Link to comment
Share on other sites

3 answers to this question

Recommended Posts

  • 0

  • Group:  Members
  • Topic Count:  15
  • Topics Per Day:  0.00
  • Content Count:  520
  • Reputation:   64
  • Joined:  11/19/11
  • Last Seen:  

50 minutes ago, realRO said:

I wanted to start my event every Wednesday 11:00 ends at 11:30 and 20:00 ends  20:30.

 

Here's what I put. Looks like every wednesday 11:00 it is not starting:

 


-	script	KoE	-1,{
OnInit:
	disablenpc "The King#KoE";
	disablenpc "Get Your Prize Here#KoE";
	bindatcmd "koe", strnpcinfo(0)+"::Oncommand", 99,99;
	end;
Oncommand:
	if ( compare( .@atcmd_parameters$, "on" ) ) goto L_start;
	else if ( compare( .@atcmd_parameters$, "off" ) ) goto L_end;
	else {
		dispbottom "type - '@koe on' to start the event";
		dispbottom "type - '@koe off' to end the event";
	}
	end;
L_start:
OnWed2000:
OnWed1100:
	gvgon "guild_vs1";
	announce "The King of Emperium Hill has begun!", bc_all;
	.start = 1;
	enablenpc "The King#KoE";
	disablenpc "Get Your Prize Here#KoE";
	$koegid = 0;
	donpcevent "::OnRevKoE";
	maprespawnguildid "guild_vs1", $koegid, 7;
	monster "guild_vs1",49,49,"EMPERIUM",1288,1,"KoE::OnEmpDead";
	end;		
L_end:
OnWed2030:
OnWed1130:
	gvgoff "guild_vs1";
	announce "The King of Emperium Hill is over!", bc_all;

 

Try these..

 

OnClock1100:
OnClock2000:
	if(gettime(4) == 3){ // 3 = Wed
		gvgon "guild_vs1";
		announce "The King of Emperium Hill has begun!", bc_all;
		.start = 1;
		enablenpc "The King#KoE";
		disablenpc "Get Your Prize Here#KoE";
		$koegid = 0;
		donpcevent "::OnRevKoE";
		maprespawnguildid "guild_vs1", $koegid, 7;
		monster "guild_vs1",49,49,"EMPERIUM",1288,1,"KoE::OnEmpDead";
	}
	end;
			
L_end:
OnClock1130:
OnClock2030:
	if(gettime(4) == 3){ // 3 = Wed
		gvgoff "guild_vs1";
		announce "The King of Emperium Hill is over!", bc_all;
	}
	end;

 

Edited by Sryx
Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  29
  • Topics Per Day:  0.01
  • Content Count:  84
  • Reputation:   0
  • Joined:  12/24/13
  • Last Seen:  

1 minute ago, Sryx said:

Try these..

 


OnClock1100:
OnClock2000:
	if(gettime(4) == 3){ // 3 = Wed
		gvgon "guild_vs1";
		announce "The King of Emperium Hill has begun!", bc_all;
		.start = 1;
		enablenpc "The King#KoE";
		disablenpc "Get Your Prize Here#KoE";
		$koegid = 0;
		donpcevent "::OnRevKoE";
		maprespawnguildid "guild_vs1", $koegid, 7;
		monster "guild_vs1",49,49,"EMPERIUM",1288,1,"KoE::OnEmpDead";
		end;
	}
			
L_end:
OnClock1130:
OnClock2030:
	if(gettime(4) == 3){ // 3 = Wed
		gvgoff "guild_vs1";
		announce "The King of Emperium Hill is over!", bc_all;
	}

 

Hi thank you for your reply, would you mind sharing me on how to check this fast without waiting the Wednesday date or changing my current Timezone?

Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  15
  • Topics Per Day:  0.00
  • Content Count:  520
  • Reputation:   64
  • Joined:  11/19/11
  • Last Seen:  

3 minutes ago, realRO said:

Hi thank you for your reply, would you mind sharing me on how to check this fast without waiting the Wednesday date or changing my current Timezone?


 

1. Change the 3 to the current day of your server ( 0 = Sun to 6 = Sat )

2. Advance the OnClock to your server time ( 10 mins or more )

Edited by Sryx
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...