advanced_refiner.txt 6.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200
  1. //===== rAthena Script =======================================
  2. //= Advanced Refiner
  3. //===== By: ==================================================
  4. //= Euphy
  5. //===== Current Version: =====================================
  6. //= 1.0
  7. //===== Compatible With: =====================================
  8. //= rAthena Project
  9. //===== Description: =========================================
  10. //= [Official Conversion]
  11. //= Refiner that uses Enriched ores to increase upgrade success.
  12. //= After a conversation with Doddler, it's been established that
  13. //= the advanced refiner works similar the the "Bubble Gum" item.
  14. //= The success percentage is not "increased" however, if it fails
  15. //= You get a second try. This tries twice at the same time,
  16. //= effectively giving you a re-roll on your attempt.
  17. //===== Additional Comments: =================================
  18. //= 1.0 Added Malangdo Refiner "Holink". [Euphy]
  19. //============================================================
  20. // Main NPC :: mal_jerun
  21. //============================================================
  22. malangdo,221,174,6 script Holink#mal_cash 559,{
  23. disable_items;
  24. mes "[Holink]";
  25. mes "I am the meow~ Blacksmith Holink~";
  26. mes "Master of refining, Holink~";
  27. mes "I am the special cat Holink who learned from Morroc~";
  28. mes "My daughter is so proud of me, Holink~";
  29. mes "What should Holink~ refine today?";
  30. next;
  31. setarray .@position$[1],"Head","Body","Left Hand","Right Hand","Robe","Shoes","Accessory 1","Accessory 2","Head 2","Head 3";
  32. set .@menu$,"";
  33. for(set .@i,1; .@i<=10; set .@i,.@i+1)
  34. set .@menu$, .@menu$+((getequipisequiped(.@i))?getequipname(.@i):.@position$[.@i]+"-[Empty]")+":";
  35. set .@part, select(.@menu$);
  36. if (!getequipisequiped(.@part)) {
  37. mes "[Holink]";
  38. switch(.@part) {
  39. case 1:
  40. mes "My teacher Aragam said meow~";
  41. mes "There's no cure for stupidity...";
  42. break;
  43. case 2:
  44. mes "There's nothing to see here, meow!!";
  45. break;
  46. case 3:
  47. mes "Meow? What do you want me to do with this left hand...?";
  48. break;
  49. case 4:
  50. mes "Meow? What do you want me to do with this right hand...?";
  51. break;
  52. case 5:
  53. mes "Meow? You don't have anything on.";
  54. break;
  55. case 6:
  56. mes "Kyang~! Do not mess with my sensitive olfactory, meow~.";
  57. break;
  58. case 7:
  59. case 8:
  60. mes "Meow? Where is the accessory?";
  61. break;
  62. case 9:
  63. case 10:
  64. mes "Meow? You talking about the other head parts, meow?~";
  65. break;
  66. }
  67. close;
  68. }
  69. if (!getequipisenableref(.@part)) {
  70. mes "[Holink]";
  71. mes "Even Aragam can't refine such a thing, meow.";
  72. close;
  73. }
  74. if (getequiprefinerycnt(.@part) >= 10) {
  75. mes "[Holink]";
  76. mes "Meow~ Perfect refining. Did Aragam do this, meow?~";
  77. close;
  78. }
  79. mes "[Holink]";
  80. switch(getequipweaponlv(.@part)) {
  81. default:
  82. case 0: // Armor
  83. set .@price,15000;
  84. set .@material,7619; //Enriched_Elunium
  85. set .@type$,"armor";
  86. mes "You have chosen an armor, meow~";
  87. break;
  88. case 1: // Level 1 Weapon
  89. set .@price,500;
  90. set .@material,7620; //Enriched_Oridecon
  91. set .@type$,"weapon";
  92. mes "A level 1 weapon...?";
  93. break;
  94. case 2: // Level 2 Weapon
  95. set .@price,2000;
  96. set .@material,7620; //Enriched_Oridecon
  97. set .@type$,"weapon";
  98. mes "Meow, a level 2 weapon...?";
  99. break;
  100. case 3: // Level 3 Weapon
  101. set .@price,20000;
  102. set .@material,7620; //Enriched_Oridecon
  103. set .@type$,"weapon";
  104. mes "Meow Meow~~ A level 3 weapon~~";
  105. break;
  106. case 4: // Level 4 Weapon
  107. set .@price,50000;
  108. set .@material,7620; //Enriched_Oridecon
  109. set .@type$,"weapon";
  110. mes "Me-Meow!... A level 4 weapon...!";
  111. mes "I've only seen it twice while";
  112. mes "learning from Aragam... Me-Meow!!";
  113. break;
  114. }
  115. mes "You need ^ff9999"+getitemname(.@material)+"^000000 and ^ff9999"+.@price+"^000000 Zeny for this refine, meow~";
  116. mes "Want to continue, meow?~";
  117. next;
  118. if(select("Yes!!:No!!") == 2) {
  119. mes "[Holink]";
  120. mes "Kyack!!";
  121. mes "You don't belive in refine master Holink, meow?~";
  122. close;
  123. }
  124. if (getequippercentrefinery(.@part) < 100) {
  125. mes "[Holink]";
  126. mes "Meow!!";
  127. if (.@type$ == "armor")
  128. mes "This armor was already refined so many times, meow.";
  129. else {
  130. mes "Danger. Danger~";
  131. mes "This weapon was refined a lot, meow~";
  132. next;
  133. mes "[Holink]";
  134. }
  135. mes "You might break it if you continue";
  136. mes "to try refining this item further, meow.";
  137. next;
  138. mes "[Holink]";
  139. mes "Once the "+.@type$+" is broken, you can";
  140. mes "never use it again, meow. Not to mention... all current";
  141. mes "^ff0000cards and enchantments will vanish for sure^000000.";
  142. mes "You still want to try, meow~?";
  143. next;
  144. if(select("Yes, I do!!:Forget about it!!") == 2) {
  145. mes "[Holink]";
  146. mes "Meow! Wise choice, meow.";
  147. mes "But!!";
  148. mes "I am not happy to see you doubting the refine master Holink, meow~";
  149. close;
  150. }
  151. }
  152. if (countitem(.@material) == 0 || Zeny < .@price) {
  153. mes "[Holink]";
  154. mes "You don't have the ingredients.";
  155. mes "You need ^ff9999"+getitemname(.@material)+"^000000 and ^ff9999"+.@price+"^000000 Zeny, meow~";
  156. mes "Go get it, meow~";
  157. close;
  158. }
  159. delitem .@material,1;
  160. set Zeny, Zeny-.@price;
  161. if (getequippercentrefinery(.@part) > rand(100) || getequippercentrefinery(.@part) > rand(100)) {
  162. successrefitem .@part;
  163. mes "[Holink]";
  164. mes "Me~ Me~ Meow! Fun fun refining~";
  165. next;
  166. emotion e_kis;
  167. mes "[Holink]";
  168. mes "Perfect!! Perfect, meow!!";
  169. mes "I am the disciple of the refining wizard Aragam~";
  170. mes "Holink!!";
  171. mes "Another day of successful refining, meow!!";
  172. close;
  173. }
  174. failedrefitem .@part;
  175. mes "[Holink]";
  176. mes "Meo~ Meow~ Kyaaak!!";
  177. next;
  178. switch(rand(1,5)) {
  179. case 1: emotion e_sob; break;
  180. case 2: emotion e_swt2; break;
  181. case 3: emotion e_wah; break;
  182. case 4: emotion e_hmm; break;
  183. case 5: emotion e_lv2; break;
  184. }
  185. mes "[Holink]";
  186. mes "Meow!! Aaaaakk~~!!!!";
  187. mes "Kyaaak!! I have failed, meow!!";
  188. next;
  189. mes "[Holink]";
  190. mes "......";
  191. mes "......";
  192. mes "All~ Everything~ Broken, meow...";
  193. next;
  194. mes "[Holink]";
  195. mes "Meow.... Master Aragam once said,";
  196. mes "learn from your failures...";
  197. mes "Human, this one failure will be the beginning of your success in the future.";
  198. close;
  199. }