Jump to content
  • 0

help Auto Announce


Question

Posted

I'm trying to make an auto announcer script base on my War times.

-	script	WarAnnounce	-1,{
OnInit:

//WAR START
if ( ( gettime(4)==0  && gettime(3)==21 ) || ( gettime(4)==2 && gettime(3)==21 ) || ( gettime(4)==4 && gettime(3)==21) || ( gettime(4)==6 && gettime(3)==21) ){ announce "The War of Emperium has begun! Please go to War Base (@go 36) to warp to WoE Castle!",0; end; }

if ( ( gettime(4)==1  && gettime(3)==21 ) || ( gettime(4)==3 && gettime(3)==21 ) || ( gettime(4)==5 && gettime(3)==21) ){ announce "The Baby War of Emperium has begun! Please go to War Base (@go 36) to warp to Baby WoE Castle!",0; end; }

if( gettime(3) == 19 ){ announce "The King of Emperium has begun! Please go to War Base (@go 36) to warp to KoE Castle!",0; end; }

//WAR END
if ( ( gettime(4)==0  && gettime(3)==22 ) || ( gettime(4)==2 && gettime(3)==22 ) || ( gettime(4)==4 && gettime(3)==22) || ( gettime(4)==6 && gettime(3)==22) ){ announce "The War of Emperium is over!",0; end; }

if ( ( gettime(4)==1  && gettime(3)==22 ) || ( gettime(4)==3 && gettime(3)==22 ) || ( gettime(4)==5 && gettime(3)==22) ){ announce "The Baby War of Emperium is over!",0; end; }

if( gettime(3) == 20 ){	announce "The King of Emperium is over!",0; end; }
}

No error and no announce. /pif

What do I miss here?

2 answers to this question

Recommended Posts

Posted

OnInit only run once ....during the server startup...

change it to

OnMinute

Well, that's easy.

-    script    WarAnnounce    -1,{
OnMinute00:

//WAR START
if ( ( gettime(4)==0  && gettime(3)==21 ) || ( gettime(4)==2 && gettime(3)==21 ) || ( gettime(4)==4 && gettime(3)==21) || ( gettime(4)==6 && gettime(3)==21) ){ announce "The War of Emperium has begun! Please go to War Base (@go 36) to warp to WoE Castle!",0; end; }

if ( ( gettime(4)==1  && gettime(3)==21 ) || ( gettime(4)==3 && gettime(3)==21 ) || ( gettime(4)==5 && gettime(3)==21) ){ announce "The Baby War of Emperium has begun! Please go to War Base (@go 36) to warp to Baby WoE Castle!",0; end; }

if( gettime(3) == 19 ){ announce "The King of Emperium has begun! Please go to War Base (@go 36) to warp to KoE Castle!",0; end; }

//WAR END
if ( ( gettime(4)==0  && gettime(3)==22 ) || ( gettime(4)==2 && gettime(3)==22 ) || ( gettime(4)==4 && gettime(3)==22) || ( gettime(4)==6 && gettime(3)==22) ){ announce "The War of Emperium is over!",0; end; }

if ( ( gettime(4)==1  && gettime(3)==22 ) || ( gettime(4)==3 && gettime(3)==22 ) || ( gettime(4)==5 && gettime(3)==22) ){ announce "The Baby War of Emperium is over!",0; end; }

if( gettime(3) == 20 ){    announce "The King of Emperium is over!",0; end; }
}

Done. Problem fixed.

Thank you so much.

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.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...