trinity_in,166,143,2 script ArmorCraftsman58,{ disable_items; deletearray @inventorylist_id[0], getarraysize(@inventorylist_id); getinventorylist; mes "[Armor Craftsman]"; mes "I've been studying ways to improve armor to increase its real capacity.";next; mes "[Armor Craftsman]"; mes "Enchant is an amazing ability blowing a mysterious power hidden in a space of armor.";next; mes "[Armor Craftsman]"; mes "One minute, please, I will check your items.";for(set.@i,0;.@i<=@inventorylist_count;set.@i,.@i+1){for(set.@j,0;.@j< getarraysize(.armaduras);set.@j,.@j+1){if((@inventorylist_id[.@i]>0)&&(.armaduras[.@j]>0)&&(@inventorylist_id[.@i]==.armaduras[.@j])){if(countitem(@inventorylist_id[.@i])>=2){next; mes "[Armor Craftsman]"; mes "I notice that you more of a (a) "+getitemname(@inventorylist_id[.@i])+" in your inventory.";next; mes "[Armor Craftsman]"; mes "For the spell to occur with total security, ie no risk of damaging your item ask you to carry only one of each armor type.";next; mes "[Armor Craftsman]"; mes "Well, remove these armor parts of your inventory and get back here with me!"; mes "I will await your return!"; close;}else{if(@inventorylist_attribute[.@i]){next; mes "[Armor Craftsman]"; mes "I see that you have a broken armor ..."; mes "To perform this procedure, you must bring me the items in perfect condition, ok?"; close;}else{set.@k,.@k+1;set.@menu$,.@menu$+getitemname(@inventorylist_id[.@i])+(getiteminfo(@inventorylist_id[.@i],10)?" [1]:":":");set.@armadlista[.@k],@inventorylist_id[.@i];set.@refine[.@k],@inventorylist_refine[.@i];set.@carta[.@k],@inventorylist_card1[.@i];set.@runa[.@k],@inventorylist_card4[.@i];set.@j,getarraysize(.armaduras);}}}} sleep2 1;}next; mes "[Armor Craftsman]";if(!.@k){ mes "Hmm? There is nothing to be enchanted!"; mes "Please come with only ONE device to enchant."; close;}else{ mes "Choose one of the armors listed below so we can progressir with this enchantment.";next;set.@armadesc,select(.@menu$+"Nothing."); mes "[Armor Craftsman]";if(.@armadesc>.@k){ mes "Please come back when you have some interest in enchant your armor."; close;}else{ mes "I will now check if you have some rune to enchant your armor."; mes " "; mes "One minute, please.";set.@menu$,"";set.@j,0;for(set.@i,0;.@i< getarraysize(.runas);set.@i,.@i+1){if(countitem(.runas[.@i])){set.@j,.@j+1;set.@menu$,.@menu$+getitemname(.runas[.@i])+":";set.@runalista[.@j],.runas[.@i];} sleep2 1;}next; mes "[Armor Craftsman]";if(!.@j){ mes "You must bring me some rune power to do the spell."; close;}else{ mes "What kind of enchantment you want to this armor?";next;set.@runaesc,select(.@menu$+"Nothing.");if(.@runaesc>.@j){ mes "[Armor Craftsman]"; mes "Please come back when you have some interest in enchanting your armor."; close;}else{ mes "[Armor Craftsman]";if(.@runa[.@armadesc]) mes "(a) "+getitemname(.@armadlista[.@armadesc])+" already has a charming "+getitemname(.@runa[.@armadesc])+", if you enchant this item with "+getitemname(.@runalista[.@runaesc])+" that consume and ancient enchantment will be missed.";else mes "This spell will cost A "+getitemname(.@runalista[.@runaesc])+".";next;if(select("Hmm .. Let me think about it.: Go ahead.")==1){ mes "[Armor Craftsman]"; mes "Well, I can not blame him. My cost is not of the lower, but I need to pay for my studies and efforts, right?"; mes "Have a nice day."; close;}else{ mes "[Armor Craftsman]"; mes "So, an adventurer willing to increase its power, huh?"; mes "Well, let the enchantment"; pcblockmove getcharid(3),1; close2; delitem .@runalista[.@runaesc],1; delitem .@armadlista[.@armadesc],1; specialeffect 873; specialeffect 865; sleep2 6000; specialeffect 44; sleep2 1000; getitem2 .@armadlista[.@armadesc],1,1,.@refine[.@armadesc],0,.@carta[.@armadesc],0,0,.@runalista[.@runaesc]; pcblockmove getcharid(3),0;end;}}}}}OnInit: setarray .armaduras[0],20178,20181,2307,13450,2309,2314,2316,2321,2325,2327,2328,2330,2332,2334,2335,2341,2344,2346,2348,2350,2337,2386,2394,2395,2396,2311,2318,2319,2320,2308,2310,2315,2317,2322,2324,2326,2331,2333,2336,2342,2345,2347,2349,2351,2364,2365,2391,2374,2375,2376,2377,2378,2379,2380,2381,2382,2387,2388,2389,2390; setarray .runas[0],26000,26027,26037,26038,26039;end;}
Instead adding the armors on
setarray .armaduras[0]
the npc will detect if the item is armor [equipped on : 16]
Hi,
Could someone edit this script?
Instead adding the armors on
setarray .armaduras[0]
the npc will detect if the item is armor [equipped on : 16]
Thanks in Advance.
Script: http://pastebin.com/Rq6B3By9
Share this post
Link to post
Share on other sites