Jump to content
  • 0
Sign in to follow this  
karazu

delete certain items when entering the map.

Question

Hello is it possible to delete some items when entering/warping in this specific map?

 

 

like when I have a Red Potion and Blue Potion in my Inventory or Cart  and then I will enter in that map those items are  automatically deleted?






 

Share this post


Link to post
Share on other sites

5 answers to this question

Recommended Posts

  • 0

Supports multiple items and multiple maps configuration ( check the OnInit part ) :

-	script	Sample	-1,{	OnPCLoadMapEvent:		getmapxy .@map$, .@xx, .@yy, 0;		for ( .@x = 0; .@x < getarraysize(.Maps$); .@x++ ) {			for ( .@y = 0; .@y < .size; .@y++ ) {				if ( .@map$ == .Maps$[.@x] && countitem(.item_id[.@y]) ) {					dispbottom "Item " +getitemname(.item_id[.@y])+ " (" +countitem(.item_id[.@y])+ ") was deleted on your inventory";					delitem .item_id[.@y], countitem(.item_id[.@y]);				}			}		}		end;	OnInit:		setarray .Maps$[0],"prontera","payon","geffen";		setarray .item_id[0],501,502;		.size = getarraysize(.item_id);		for ( .@i = 0; .@i < getarraysize(.Maps$); .@i++ )			 setmapflag .Maps$[.@i], mf_loadevent;		end;}
Edited by Patskie

Share this post


Link to post
Share on other sites
  • 0

Why ur so great? Hahahah.. Any way, can u make me a simple warper like it will check if u have this specific item, if u click it, the npc will let you choose where part of the map u want to he teleported? For example north south east west of prontera

Share this post


Link to post
Share on other sites
  • 0

It would be great if you post all your request at your topic description so that people who will help you out will not re-write their initial script. :P

Share this post


Link to post
Share on other sites
  • 0

i used this script of Sir 

Patskie

, delete item on inventory works fine,

but delete item in cart wont work :D

Edited by ShankS

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×
×
  • Create New...

Important Information

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