Jump to content
  • 0
Sign in to follow this  
jimboy09232

Hello sir help how to add blocklist id number in Item giver npc

Question

Hi sir here's the script

 

how can I block 5377 , 5374 and godlikes items in this script 

I mean how to add restricted items in this script.

 

 

prontera,209,229,5    script    Item Giver    106,{
mes "[item Giver]";
mes "Please input the ITEM NUMBER that you want to receive.";
mes " ";
mes "You could use @ii <item name> to look for it or browse at ratemyserver.net";
input .@itemnum;
next;
mes "[item Giver]";
mes "How many pieces of this item do you want to receive?";
input .@itemcount;
next;
mes "[item Giver]";
mes "Here you go! Come again!";
getitem .@itemnum,.@itemcount;
close;
end;
}

 

Share this post


Link to post
Share on other sites

1 answer to this question

Recommended Posts

  • 0

something like this using if .@item equals your id.

 

 

prontera,209,229,5    script    Item Giver    106,{
mes "[Item Giver]";
mes "Please input the ITEM NUMBER that you want to receive.";
mes " ";
mes "You could use @ii <item name> to look for it or browse at ratemyserver.net";
input .@itemnum;
next;
 
if (.@itemnum == 5377 || .@itemnum == 5374) {
mes "[Item Giver]";
mes "You cannot use " + getitemname(.@itemnum) + ".";
close;
}

else {
next;
mes "[Item Giver]";
mes "How many pieces of this item do you want to receive?";
input .@itemcount;
next;
mes "[Item Giver]";
mes "Here you go! Come again!";
getitem .@itemnum,.@itemcount;
close;
end;
}
}

 

Also if you want, instead of "How many pieces of this item do you want to receive, you can do the following to show the name.

mes "How many pieces of " + getitemname(.@itemnum) + " do you want to receive?";

Edited by True Zeal

Share this post


Link to post
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.   Restore formatting

  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.

Loading...
Sign in to follow this  

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.