N> NPC timer to itself - HOT Support (Smoking Hot)

here is a pseudo since I didn't master yet npc scripting,,,

onInit:noregister = 0;end;onRegister:if( noregister == 0)//start registerend;onTeamWin:noregister = 1;//starttimerend;onTimer15000:noregister = 0;end; 


default_ani_meow.gif


 
you must use . in prefix (npc variable) or mapserv will throw an error (npc script use <none prefix> for permanent variable attached to the character)

and there is already a timer in the script, it's better with a sleep here

Code:
    set @partymembercount,$@members;    announce "Thanks for playing",0;+	set .npc_delay, 1;+	sleep 900000;+	set .npc_delay, 0;    end;
Code:
    if ( $@start == 1 ) {        mes "The Sign Ups are currently unavailable because a match is in progress. Don't hesitate to try again in a few minutes!";        close;    }+	if ( .npc_delay ) {+		mes "you must wait";+		close;+	}    if ( @partymembercount == $@members ) {
 
Back
Top