Jump to content

Question

Posted
 
help to make this script
 
every 3-hours NPC will be available again
 
Broadcast if the room is available, to notify the players if
the summon room is already available.
 
Requirements to Summon Thanatos are the 4 Fragments:
Agony, Despair, Sorrow, Hatred.
 
Only 1 player can enter. 
 
help me please

help please :(

3 answers to this question

Recommended Posts

Posted


prontera,155,165,5 script Sample#thanatos 757,{

mes "Summon Thanatos ?";

mes " ";

mes "You need:";

for ( .@i = 0; .@i < .required_item_size; .@i++ ) {

mes " > "+getitemname( .required_item[.@i] );

if ( !countitem( .required_item[.@i] ) )

.@fail++;

}

if ( select( "Take it","Cancel" ) == 1 ) {

if ( getmapusers( .map$ ) ) {

mes "Someone already inside it.";

}

else if ( !.@fail ) {

for ( .@i = 0; .@i < .required_item_size; .@i++ )

delitem .required_item[.@i],1;

warp .map$,0,0;

killmonsterall .map$;

monster .map$,0,0,"--ja--",1708,1;

}

else {

mes "You didnt meet the requirement.";

}

}

close;

OnInit:

.map$ = "evt_coke";

setarray .required_item,

7436,

7437,

7438,

7439;

.required_item_size = getarraysize( .required_item );

getmapxy( .@npc_map$,.@npc_x,.@npc_y,1 );

setmapflagnosave( .map$,.@npc_map$,.@npc_x,.@npc_y );

end;

}

Posted (edited)
prontera,155,165,5	script	Sample#thanatos	757,{
	mes "Summon Thanatos ?";
	mes " ";
	mes "You need:";
	for ( .@i = 0; .@i < .required_item_size; .@i++ ) {
		mes " > "+getitemname( .required_item[.@i] );
		if ( !countitem( .required_item[.@i] ) )
			.@fail++;
	}
	if ( select( "Take it","Cancel" ) == 1 ) {
		if ( getmapusers( .map$ ) ) {
			mes "Someone already inside it.";
		}
		else if ( !.@fail ) {
			for ( .@i = 0; .@i < .required_item_size; .@i++ )
				delitem .required_item[.@i],1;
			warp .map$,0,0;
			killmonsterall .map$;
			monster .map$,0,0,"--ja--",1708,1;
		}
		else {
			mes "You didnt meet the requirement.";
		}
	}
	close;
	
	OnInit:
		.map$ = "evt_coke";
		setarray .required_item,
			7436,
			7437,
			7438,
			7439;
		.required_item_size = getarraysize( .required_item );
		
		getmapxy( .@npc_map$,.@npc_x,.@npc_y,1 );
		setmapflagnosave( .map$,.@npc_map$,.@npc_x,.@npc_y );
		end;
}

sir emistry thankyou for this sir can you set it every 3hours before the npc can show again ?

Edited by Kariton Revolution

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...