Jump to content
  • 0

Refiner / Unrefine check


Winter1992

Question


  • Group:  Members
  • Topic Count:  25
  • Topics Per Day:  0.01
  • Content Count:  60
  • Reputation:   0
  • Joined:  11/08/15
  • Last Seen:  

Any one can help me? how to edit this here is my script. then i want to put this modification on that so that the refiner will check if the item can refine or not 

gonryun,177,118,3    script    Instant +10 TCG    950,{

mes "What item do you want to be refined?";
next;
set @refine,.equip_part[select(getequipname(.equip_part[0]),
                getequipname(.equip_part[1]), // shoes
                getequipname(.equip_part[2]), // muffler
                getequipname(.equip_part[3]), // lower gear
                getequipname(.equip_part[4]), // mid gear
                getequipname(.equip_part[5]), // headgear
                getequipname(.equip_part[6]), // armor
                getequipname(.equip_part[7]), // shield
                getequipname(.equip_part[8]), // weapon
                getequipname(.equip_part[9]))-1];

if(countitem(7227) < 1) {
mes "You are missing:";
mes ""+((countitem(7227) < 1)?"1 TCG Cards":"")+"";
close;
}

if(getequiprefinerycnt(@refine) >= 7) {
mes "+10 Item cannot be refined anymore.";
close;
}
else { 
delitem 7227,1;
successrefitem @refine,10;
mes "Clang Clang! Success!";
close;

}


OnInit:

    setarray .equip_part[1],2,3,5,6,7,8,9;

}


where should i put this code?? 

(!getequipisenableref(@part)) {
        mes "Go find another Blacksmith. You can't refine this thing.";
        close;
    }
 

Link to comment
Share on other sites

2 answers to this question

Recommended Posts

  • 0

  • Group:  Members
  • Topic Count:  39
  • Topics Per Day:  0.01
  • Content Count:  615
  • Reputation:   201
  • Joined:  11/09/11
  • Last Seen:  

Above the else... But @part needs to change to @refine

Link to comment
Share on other sites

  • 0

  • Group:  Content Moderator
  • Topic Count:  55
  • Topics Per Day:  0.02
  • Content Count:  1676
  • Reputation:   702
  • Joined:  12/21/14
  • Last Seen:  

also it would be better to organize your script 

gonryun,177,118,3	script	Instant +10 TCG	950,{
	disable_items;
	mes "What item do you want to be refined?";
	next;
	for(.@i=1;.@i<getarraysize(.pos);++.@i){
		if(getequipisequiped(.pos[.@i])){
			.@equips$ += F_getpositionname(.pos[.@i]) + " [ " + getequipname(.pos[.@i]) + " ]";
		}
		.@equips$ += ":";
	}
	.@part = .pos[select(.@equips$)];
	if(!getequipisenableref(.@part)) {
		mes "Go find another Blacksmith. You can't refine this thing.";
		close;
	}
	if(countitem(7227) < 1) {
		mes "You are missing 1 TCG Cards";
		close;
	}
	if(getequiprefinerycnt(.@part) >= 7){
		mes "+10 Item cannot be refined anymore.";
		close;
	}else{ 
		delitem 7227,1;
		successrefitem .@part,10;
		mes "Clang Clang! Success!";
		close;
	}
end;
OnInit:
	setarray .pos[1],EQI_HEAD_TOP, EQI_ARMOR, EQI_HAND_L, EQI_HAND_R, EQI_GARMENT, EQI_SHOES, EQI_HEAD_MID, EQI_HEAD_LOW;
end;
}

 

Link to comment
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.   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.

×
×
  • Create New...