Jump to content
  • 0

npc that adds slot into glasses


Question

3 answers to this question

Recommended Posts

  • 0
Posted
function	script	F_MesItemInfo	{
    .@item = getarg(0);
    return sprintf("<ITEM>%s<INFO>%d</INFO></ITEM>", getitemname(.@item), .@item);
}

prontera,155,185,5	script	skdfjhskdf	1_F_MARIA,{
	if ( !countitem(2201) ) {
		mes "I need a "+ F_MesItemInfo(2201);
		close;
	}
	if ( Zeny < 1000 ) {
		mes "you don't have a thousand zeny";
		close;
	}
	disable_items;
	mes "Are you sure you want to exchange your sunglasses into slotted on in 1/10 chance ?";
	next;
	if ( select ( "Yes", "No" ) == 2 ) close;
	if ( !countitem(2201) ) { // just a double check
		mes "I need a "+ F_MesItemInfo(2201);
		close;
	}
	if ( Zeny < 1000 ) {
		mes "you don't have a thousand zeny";
		close;
	}
	Zeny -= 1000;
	if ( rand(100) < 10 ) {
		delitem 2201, 1;
		getitem 2202, 1;
		mes "your "+ F_MesItemInfo(2201) +" now has slot";
		emotion ET_BEST;
	}
	else {
		delitem 2201, 1;
		mes "it fails";
		emotion ET_SORRY;
	}
	close;
}

script_commands.txt is your best friend

  • 0
Posted
prontera,155,185,5	script	skdfjhskdf	1_F_MARIA,{
	if ( !countitem(2201) ) {
		mes "I need a sunglasses";
		close;
	}
	disable_items;
	mes "Are you sure you want to exchange your sunglasses into slotted on in 1/10 chance ?";
	next;
	if ( select ( "Yes", "No" ) == 2 ) close;
	if ( !countitem(2201) ) { // just a double check
		mes "I need a sunglasses";
		close;
	}
	if ( rand(100) < 10 ) {
		delitem 2201, 1;
		getitem 2202, 1;
		mes "your sunglasses now has slot";
	}
	else {
		delitem 2201, 1;
		mes "it fails";
	}
	close;
}

 

  • MVP 1
  • 0
Posted
6 hours ago, AnnieRuru said:

prontera,155,185,5	script	skdfjhskdf	1_F_MARIA,{
	if ( !countitem(2201) ) {
		mes "I need a sunglasses";
		close;
	}
	disable_items;
	mes "Are you sure you want to exchange your sunglasses into slotted on in 1/10 chance ?";
	next;
	if ( select ( "Yes", "No" ) == 2 ) close;
	if ( !countitem(2201) ) { // just a double check
		mes "I need a sunglasses";
		close;
	}
	if ( rand(100) < 10 ) {
		delitem 2201, 1;
		getitem 2202, 1;
		mes "your sunglasses now has slot";
	}
	else {
		delitem 2201, 1;
		mes "it fails";
	}
	close;
}

 

very good . I want him to order a thousand zenys. and tells me how I put emotion when the process fails..: )

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