chadness 1 Posted January 20 (edited) hello everyone i would like to ask how to put announce if the item reach level 7 it will be announce in the whole server thanks in advance Edited January 21 by chadness Quote Share this post Link to post Share on other sites
0 cook1e 6 Posted January 20 Go to npc/merchants/refine.txt search for successrefitem [email protected]; below add if (getequiprefinerycnt([email protected]) >= 7) announce strcharinfo(0)+" has refined "+getequipname([email protected])+" to +"+getequiprefinerycnt([email protected])+"!",0; it would be like this successrefitem [email protected]; if (getequiprefinerycnt([email protected]) >= 7) announce strcharinfo(0)+" has refined "+getequipname([email protected])+" to +"+getequiprefinerycnt([email protected])+"!",0; Quote Share this post Link to post Share on other sites
0 sader1992 581 Posted January 20 (edited) the answer is above ^ just replace >= with == for only +7 Edited January 20 by sader1992 Quote Share this post Link to post Share on other sites
0 Haruka Mayumi 212 Posted January 20 I would recommend to use find on all files the successrefitem and add the code after it.. a little note is that if the player use WEAPON REFINE of whitesmith. the announce won't show up since that would be source side Quote Share this post Link to post Share on other sites
0 sader1992 581 Posted January 20 you can try src edit the command it self , would be easier then searching for every place it used in Quote Share this post Link to post Share on other sites
0 chadness 1 Posted January 20 2 hours ago, cook1e said: Go to npc/merchants/refine.txt search for successrefitem [email protected]; below add if (getequiprefinerycnt([email protected]) >= 7) announce strcharinfo(0)+" has refined "+getequipname([email protected])+" to +"+getequiprefinerycnt([email protected])+"!",0; it would be like this successrefitem [email protected]; if (getequiprefinerycnt([email protected]) >= 7) announce strcharinfo(0)+" has refined "+getequipname([email protected])+" to +"+getequiprefinerycnt([email protected])+"!",0; thanks to this ill try it now Quote Share this post Link to post Share on other sites
0 chadness 1 Posted January 20 6 hours ago, sader1992 said: you can try src edit the command it self , would be easier then searching for every place it used in where exactly sir in src? Quote Share this post Link to post Share on other sites
0 chadness 1 Posted January 20 7 hours ago, Haruka Mayumi said: I would recommend to use find on all files the successrefitem and add the code after it.. a little note is that if the player use WEAPON REFINE of whitesmith. the announce won't show up since that would be source side the code above? Quote Share this post Link to post Share on other sites
0 chadness 1 Posted January 20 7 hours ago, sader1992 said: the answer is above ^ just replace >= with == for only +7 double == sign sir? Quote Share this post Link to post Share on other sites
0 chadness 1 Posted January 20 8 hours ago, cook1e said: Go to npc/merchants/refine.txt search for successrefitem [email protected]; below add if (getequiprefinerycnt([email protected]) >= 7) announce strcharinfo(0)+" has refined "+getequipname([email protected])+" to +"+getequiprefinerycnt([email protected])+"!",0; it would be like this successrefitem [email protected]; if (getequiprefinerycnt([email protected]) >= 7) announce strcharinfo(0)+" has refined "+getequipname([email protected])+" to +"+getequiprefinerycnt([email protected])+"!",0; no error but no announced Quote Share this post Link to post Share on other sites
0 Slammer 115 Posted January 20 2 hours ago, chadness said: no error but no announced refine.txt use this. maybe can help Quote Share this post Link to post Share on other sites
0 cook1e 6 Posted January 20 4 hours ago, Slammer said: refine.txt use this. maybe can help If this one doesnt help you. Try this. refine.txt 1 Quote Share this post Link to post Share on other sites
0 WhiteEagle 33 Posted January 20 Just as an idea, how about adding a filter? Lv.1 and 2 weapons would also trigger the announce and Lv.1 is safe till +7. Just change this: if (getequiprefinerycnt(.@part) >= 7) announce strcharinfo(0)+" has refined "+getequipname(.@part)+" to +"+getequiprefinerycnt(.@part)+"!",0; To this: if (getequiprefinerycnt(.@part) >= 7) { if (.@part == EQI_GARMENT || .@part == EQI_HEAD_TOP || .@part == EQI_SHOES || .@part == EQI_ARMOR) { announce strcharinfo(0)+" has refined ["+getequipname(.@part)+"] to +"+getequiprefinerycnt(.@part)+"!",0; } if (getequipweaponlv(.@part) >= 3 ) { announce strcharinfo(0)+" has refined the weapon ["+getequipname(.@part)+"] to +"+getequiprefinerycnt(.@part)+"!",0; } } Quote Share this post Link to post Share on other sites
0 chadness 1 Posted January 21 its working but i wish theres no selection of refining just the announcement Quote Share this post Link to post Share on other sites
0 chadness 1 Posted January 21 (edited) 10 hours ago, cook1e said: If this one doesnt help you. Try this. refine.txt 38.88 kB · 3 downloads can you make the +8 +9 +10 also ? Edited January 21 by chadness Quote Share this post Link to post Share on other sites
0 WhiteEagle 33 Posted January 21 2 hours ago, chadness said: can you make the +8 +9 +10 also ? The Announce comes every time something is refined to +7 or higher. That means also +8, +9,+10. Quote Share this post Link to post Share on other sites
0 Slammer 115 Posted February 19 On 1/21/2021 at 1:56 PM, chadness said: can you make the +8 +9 +10 also ? here you go weapon lv 1 +8 or high weapon lv 2 +7 or high weapon lv 3 +6 or high weapon lv 4 +5 or high and armor/acc/headgear +5 they will annouce refine_announce.txt 1 Quote Share this post Link to post Share on other sites
0 chadness 1 Posted February 20 On 2/19/2021 at 8:35 AM, Slammer said: here you go weapon lv 1 +8 or high weapon lv 2 +7 or high weapon lv 3 +6 or high weapon lv 4 +5 or high and armor/acc/headgear +5 they will annouce refine_announce.txt 40.97 kB · 4 downloads thankyou sir how about if the weapon or armors or headgear failed is there also an announcer? Quote Share this post Link to post Share on other sites
0 Slammer 115 Posted February 20 3 hours ago, chadness said: thankyou sir how about if the weapon or armors or headgear failed is there also an announcer? here you go... Quote function script refinemain { disable_items; [email protected]_name$ = getarg(0); [email protected] = getarg(1); mes "["+ [email protected]_name$ +"]"; mes "I'm the Armsmith."; mes "I can refine all kinds of weapons, armor and equipment, so let me"; mes "know what you want me to refine."; next; setarray [email protected][1], EQI_HEAD_TOP, EQI_ARMOR, EQI_HAND_L, EQI_HAND_R, EQI_GARMENT, EQI_SHOES, EQI_ACC_L, EQI_ACC_R, EQI_HEAD_MID, EQI_HEAD_LOW; for([email protected] = 1; [email protected]<getarraysize([email protected]); [email protected]) { if(getequipisequiped([email protected][[email protected]])) { [email protected]$ = [email protected]$ + F_getpositionname([email protected][[email protected]]) + "-[" + getequipname([email protected][[email protected]]) + "]"; [email protected] = 1; } [email protected]$ = [email protected]$ + ":"; } if ([email protected] == 0) { mes "["+ [email protected]_name$ +"]"; mes "I don't think I can refine any items you have..."; close; } [email protected] = [email protected][select([email protected]$)]; if(!getequipisequiped([email protected])) { //custom check mes "["+ [email protected]_name$ +"]"; mes "You're not wearing"; mes "anything there that"; mes "I can refine."; emotion ET_FRET; close; } //Check if the item is refinable... if(!getequipisenableref([email protected])) { mes "["+ [email protected]_name$ +"]"; mes "I don't think I can"; mes "refine this item at all..."; close; } //Check to see if the items is already +10 if(getequiprefinerycnt([email protected]) >= 10) { mes "["+ [email protected]_name$ +"]"; mes "I can't refine this"; mes "any more. This is as"; mes "refined as it gets!"; close; } [email protected] = getequipid([email protected]); // save id of the item [email protected] = getequiprefinerycnt([email protected]); //save refinery count setarray [email protected][0], getequipcardid([email protected],0), getequipcardid([email protected],1), getequipcardid([email protected],2), getequipcardid([email protected],3); [email protected] = getequiprefinecost([email protected], REFINE_COST_NORMAL, REFINE_ZENY_COST); [email protected] = getequiprefinecost([email protected], REFINE_COST_NORMAL, REFINE_MATERIAL_ID); switch (getequipweaponlv([email protected])) { case 1: [email protected] = 7; break; case 2: [email protected] = 6; break; case 3: [email protected] = 5; break; case 4: default: [email protected] = 4; break; } // If the VIP system is enabled, the prices for non-VIP players are considerably higher. if (VIP_SCRIPT && !vip_status(VIP_STATUS_ACTIVE)) { switch(getequipweaponlv([email protected])) { case 0: [email protected] = [email protected] * 10; break; case 1: [email protected] = [email protected] * 40; break; case 2: [email protected] = [email protected] * 50; break; case 3: [email protected] = [email protected] * 2; break; case 4: [email protected] = [email protected] * 2; break; case 5: [email protected] = [email protected] * 10; break; } } if([email protected] != 1) { mes "["+ [email protected]_name$ +"]"; mes "To refine this I need"; mes "one ^003366"+getitemname([email protected])+"^000000 and"; mes "a service fee of " + [email protected] + " Zeny."; mes "Do you really wish to continue?"; next; if(select("Yes:No") == 2){ mes "["+ [email protected]_name$ +"]"; mes "Yeah..."; mes "There's no need to"; mes "rush. Take your time."; close; } if(getequippercentrefinery([email protected]) < 100) { mes "["+ [email protected]_name$ +"]"; mes "Oh no! If I continue to"; mes "refine this, there's a risk it could"; switch([email protected]) { case 985: mes "be destroyed! That means that ^FF0000this equipment^000000, and ^FF0000any cards^000000 or special properties added to this armor, ^FF0000will be gone^000000."; break; default: mes "be destroyed, and you'd ^FF0000lose the weapon^000000, any ^FF0000cards in the weapon^000000,"; mes "or any added special properties."; break; } next; mes "["+getarg(0)+"]"; mes "I can't make it any clearer."; mes "Once a weapon is destroyed,"; mes "there's no getting it back."; mes "You really have a chance to"; mes "^FF0000lose this weapon^000000 forever."; mes "Do you still want to refine?"; next; if(select("Yes:No") == 2){ mes "["+ [email protected]_name$ +"]"; mes "I completely agree..."; mes "I might be a great refiner, but sometimes even I make mistakes."; close; } } if((countitem([email protected]) < 1) || (Zeny < [email protected])) { mes "["+ [email protected]_name$ +"]"; mes "You don't seem to have"; mes "enough Zeny or "+getitemname([email protected])+"..."; mes "Go get some more. I'll be"; mes "here all day if you need me."; close; } Zeny = [email protected]; delitem [email protected],1; // anti-hack if (callfunc("F_IsEquipIDHack", [email protected], [email protected]) || callfunc("F_IsEquipCardHack", [email protected], [email protected][0], [email protected][1], [email protected][2], [email protected][3]) || callfunc("F_IsEquipRefineHack", [email protected], [email protected])) { mes "["+ [email protected]_name$ +"]"; emotion ET_FRET; mes "Wait a second..."; mes "Do you think I'm stupid?!"; mes "You switched the item while I wasn't looking! Get out of here!"; close; } if(getequippercentrefinery([email protected]) <= rand(100)) { announce strcharinfo(0)+" has failed refined a "+getequipname([email protected])+"+"+getequiprefinerycnt([email protected])+" to "+getequipname([email protected])+"+"+(getequiprefinerycnt([email protected])+1)+"!",0; failedrefitem [email protected]; mes "["+ [email protected]_name$ +"]"; emotion (!rand(5))?ET_MONEY:ET_HUK; [email protected] = rand(1,3); if ([email protected] == 1) { mes "OH! MY GOD!"; mes "Damn it! Not again!"; mes "I'm terribly sorry, but you know practice does make perfect."; mes "Um, right? Heh heh..."; } else if([email protected] == 2) { mes "Nooooooo!"; mes "It broke!"; mes "I-I'm sorry!"; } else { mes "Crap!"; mes "It couldn't take"; mes "much more tempering!"; mes "Sorry about this..."; } close; } mes "["+getarg(0)+"]"; successrefitem [email protected]; if (getequiprefinerycnt([email protected]) >= 8 && getequipweaponlv([email protected]) == 1){ announce strcharinfo(0)+" has refined weapon "+getequipname([email protected])+" to +"+getequiprefinerycnt([email protected])+"!",0;} else if (getequiprefinerycnt([email protected]) >= 7 && getequipweaponlv([email protected]) == 2){ announce strcharinfo(0)+" has refined weapon "+getequipname([email protected])+" to +"+getequiprefinerycnt([email protected])+"!",0;} else if (getequiprefinerycnt([email protected]) >= 6 && getequipweaponlv([email protected]) == 3){ announce strcharinfo(0)+" has refined weapon "+getequipname([email protected])+" to +"+getequiprefinerycnt([email protected])+"!",0;} else if (getequiprefinerycnt([email protected]) >= 5 && getequipweaponlv([email protected]) == 4){ announce strcharinfo(0)+" has refined weapon "+getequipname([email protected])+" to +"+getequiprefinerycnt([email protected])+"!",0;} else if (getequiprefinerycnt([email protected]) >= 5) && ([email protected] == EQI_GARMENT || [email protected] == EQI_HEAD_TOP || [email protected] == EQI_SHOES || [email protected] == EQI_ARMOR){ announce strcharinfo(0)+" has refined armor "+getequipname([email protected])+" to +"+getequiprefinerycnt([email protected])+"!",0;} emotion ET_SMILE; [email protected] = rand(1,3); if ([email protected] == 1) { mes "Perfect!"; mes "Heh heh!"; mes "Once again,"; mes "flawless work"; mes "from the master~"; } else if([email protected] == 2) { mes "Success...!"; mes "Yet again, my amazing"; mes "talent truly dazzles"; mes "and shines today."; } else { mes "Heh heh!"; mes "I'm all done."; mes "No doubt, my work is"; mes "to your satisfaction."; mes "Sheer, utter perfection~"; } close; } // New Refining Functions ======================== if ([email protected] < [email protected]) { mes "["+ [email protected]_name$ +"]"; mes "I can refine this to the safe limit or a desired number of times. It's your choice."; next; [email protected] = select("To the safe limit, please.","I'll decide how many times.","I've changed my mind..."); } else [email protected] = 2; switch([email protected]){ case 1: [email protected] = [email protected] - [email protected]; break; case 2: next; mes "["+ [email protected]_name$ +"]"; mes "How many times would you like me to refine your item?"; next; input [email protected]; [email protected] = [email protected] + [email protected]; if ([email protected] < 1 || [email protected] > 10) { mes "["+ [email protected]_name$ +"]"; mes "I can't refine this item that many times."; close; } if([email protected] > [email protected]) { [email protected] = [email protected] - [email protected]; mes "["+ [email protected]_name$ +"]"; mes "This will try to refine the equipment " + [email protected] + " times past the safe limit. Your equipment may be destroyed... is that ok?"; next; if(select("Yes...","No...") == 2){ mes "["+ [email protected]_name$ +"]"; mes "You said so... So be it."; close; } } break; case 3: next; mes "["+ [email protected]_name$ +"]"; mes "You said so... So be it."; close; } [email protected] = [email protected] * [email protected]; mes "["+ [email protected]_name$ +"]"; mes "That will cost you " + [email protected] + " " + getitemname([email protected]) + " and " + [email protected] + " Zeny. Is that ok?"; next; if(select("Yes","No...") == 2){ mes "["+ [email protected]_name$ +"]"; mes "You said so... So be it."; close; } if(countitem([email protected]) < [email protected] || Zeny < [email protected]) { mes "["+ [email protected]_name$ +"]"; mes "Is that all you got? Unfortunately I can't work for you at a lower price. Try putting yourself in my shoes."; close; } Zeny = Zeny - [email protected]; delitem [email protected],[email protected]; while([email protected]){ if (getequipisequiped([email protected]) == 0) { mes "["+ [email protected]_name$ +"]"; mes "Look here... you don't have any items on..."; close; } // anti-hack if (callfunc("F_IsEquipIDHack", [email protected], [email protected]) || callfunc("F_IsEquipCardHack", [email protected], [email protected][0], [email protected][1], [email protected][2], [email protected][3]) || callfunc("F_IsEquipRefineHack", [email protected], [email protected]) || ([email protected] == 1 && getequippercentrefinery([email protected]) < 100)) { mes "["+ [email protected]_name$ +"]"; mes "Clang... No, but did you imagine I could be so stupid?!"; mes "You changed it..."; mes "Get out before I stun you with my Hammer!!"; close; } mes "Clang, clang!!!"; if([email protected] == 2 && getequippercentrefinery([email protected]) <= rand(100)) { failedrefitem [email protected]; announce strcharinfo(0)+" has failed refined a "+getequipname([email protected])+"+"+getequiprefinerycnt([email protected])+" to "+getequipname([email protected])+"+"+(getequiprefinerycnt([email protected])+1)+"!",0; emotion ET_HUK; mes "["+ [email protected]_name$ +"]"; mes "WAHHHH!!! I'm so sorry... I warned you this could happen..."; [email protected] = [email protected] - 1; if([email protected] == 0) close; mes "Here's the unused Zeny and materials back..."; getitem [email protected],[email protected]; [email protected] = [email protected] * [email protected]; Zeny = Zeny + [email protected]; close; } successrefitem [email protected]; if (getequiprefinerycnt([email protected]) >= 8 && getequipweaponlv([email protected]) == 1){ announce strcharinfo(0)+" has refined weapon "+getequipname([email protected])+" to +"+getequiprefinerycnt([email protected])+"!",0;} else if (getequiprefinerycnt([email protected]) >= 7 && getequipweaponlv([email protected]) == 2){ announce strcharinfo(0)+" has refined weapon "+getequipname([email protected])+" to +"+getequiprefinerycnt([email protected])+"!",0;} else if (getequiprefinerycnt([email protected]) >= 6 && getequipweaponlv([email protected]) == 3){ announce strcharinfo(0)+" has refined weapon "+getequipname([email protected])+" to +"+getequiprefinerycnt([email protected])+"!",0;} else if (getequiprefinerycnt([email protected]) >= 5 && getequipweaponlv([email protected]) == 4){ announce strcharinfo(0)+" has refined weapon "+getequipname([email protected])+" to +"+getequiprefinerycnt([email protected])+"!",0;} else if (getequiprefinerycnt([email protected]) >= 5) && ([email protected] == EQI_GARMENT || [email protected] == EQI_HEAD_TOP || [email protected] == EQI_SHOES || [email protected] == EQI_ARMOR){ announce strcharinfo(0)+" has refined armor "+getequipname([email protected])+" to +"+getequiprefinerycnt([email protected])+"!",0;} emotion ET_BEST; [email protected] = [email protected] - 1; [email protected] = getequiprefinerycnt([email protected]); next; } mes "["+ [email protected]_name$ +"]"; mes "All finished... Come again soon."; close; } 1 Quote Share this post Link to post Share on other sites
0 chadness 1 Posted February 20 4 hours ago, Slammer said: here you go... thanks alot sir i will try this later Quote Share this post Link to post Share on other sites
hello everyone i would like to ask how to put announce if the item reach level 7 it will be announce in the whole server thanks in advance
Edited by chadnessShare this post
Link to post
Share on other sites