Jump to content
  • 0
Myth

Refine NPC

Question

refine without elu,phracon,oridecon

 

1 click refine into there safety refine

 

izlude,131,148,4	script	Refiner	899,{mes "[Safety Refiner]";mes "Made by Lunar";mes "Would you like to refine all your items to their safety limit?";mes "I still require the items needed to refine.";if(select("Yes:No")==2) close;    for(set @i,1; @i!=11; set @i,@i+1) {        if(!getequipisenableref(@i)) continue;        switch(getequipweaponlv(@i)) {            case 0: callsub SafeRefine,985; break;            case 1: callsub SafeRefine,1010; break;            case 2: callsub SafeRefine,1011; break;            case 3:            case 4: callsub SafeRefine,984; break;        }    }close;SafeRefine:    mes "Success";    while (getequipisequiped(@i) && countitem(getarg(0)) && getequippercentrefinery(@i)==100) { delitem (getarg(0)),1; successrefitem @i; }    return;}

 

Share this post


Link to post
Share on other sites

5 answers to this question

Recommended Posts

  • 0
prontera,155,181,5	script	Sample	757,{while( .@x < 11 ){	if( getequipisenableref( .@x ) && getequipisequiped( .@x ) )		while( getequippercentrefinery( .@x ) == 100 )			successrefitem .@x;	.@x++;}end;}

Share this post


Link to post
Share on other sites
  • 0

Change this line:

    while (getequipisequiped(@i) && countitem(getarg(0)) && getequippercentrefinery(@i)==100) { delitem (getarg(0)),1; successrefitem @i; }

 

Into this:

    while (getequipisequiped(@i) && getequippercentrefinery(@i)==100) successrefitem @i;

 

And optionally delete all arguments passed to SafeRefine (do it if map server complains about unused arguments in the function).

Share this post


Link to post
Share on other sites
  • 0

Just remove any dialogues:

izlude,131,148,4	script	Refiner	899,{    for(set @i,1; @i!=11; set @i,@i+1) {        if(!getequipisenableref(@i)) continue;        switch(getequipweaponlv(@i)) {            case 0: callsub SafeRefine; break;            case 1: callsub SafeRefine; break;            case 2: callsub SafeRefine; break;            case 3:            case 4: callsub SafeRefine; break;        }    }close;SafeRefine:    mes "Success";    while (getequipisequiped(@i) && getequippercentrefinery(@i)==100) successrefitem @i;    return;}

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

×
×
  • Create New...

Important Information

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