Guest User

Untitled

a guest
Jun 21st, 2018
81
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 44.81 KB | None | 0 0
  1.  
  2. #include "Main.h"
  3.  
  4. void Packets::Gema_de_Diamante(int clientid, int SrcSlot, int DstSlot)
  5. {
  6. Atualizar *p;
  7. MOB *player = (MOB*)GetMobFromIndex(clientid);
  8. static int ExtremeDiamante[114] = {2451, 2455, 2459, 2463, 2467, 2471, 2475, 2479, 2483, 2487, 2491, 2511, 2515, 2519, 2523, 2527, 2531, 2535, 2539, 2543, 2547, 2551, 2571, 2575, 2579, 2583, 2587, 2591, 2595, 2599, 2603, 2607, 2611, 2631, 2635, 2639, 2643, 2647, 2651, 2655, 2659, 2663, 2667, 2671, 2691, 2695, 2699, 2703, 2707, 2711, 2715, 2719, 2723, 2727, 2731, 2751, 2755, 2759, 2763, 2767, 2771, 2775, 2779, 2783, 2787, 2791, 2811, 2815, 2819, 2823, 2827, 2831, 2835, 2839, 2843, 2847, 2851, 2855, 2859, 2863, 2871, 2875, 2879, 2883, 2887, 2891, 2895, 2911, 2915, 2919, 2923, 2927, 2931, 2935, 3601, 3605, 3621, 3625, 3641, 3645, 3661, 3665, 3681, 3685, 3701, 3705, 3721, 3725, 3729, 3733, 3761, 3765, 3781, 3785};
  9. static int ExtremeEsmeralda[114] = {2452, 2456, 2460, 2464, 2468, 2472,2476, 2480, 2484, 2488, 2492, 2512, 2516, 2520, 2524, 2528, 2532, 2536, 2540, 2544, 2548, 2552, 2572, 2576, 2580, 2584, 2588, 2592, 2596, 2600, 2604, 2608, 2612, 2632, 2636, 2640, 2644, 2648, 2652, 2656, 2660, 2664, 2668, 2672, 2692, 2696, 2700, 2704, 2708, 2712, 2716, 2720, 2724, 2728, 2732, 2752, 2756, 2760, 2764, 2768, 2772, 2776, 2780, 2784, 2788, 2792, 2812, 2816, 2820, 2824, 2828, 2832, 2836, 2840, 2844, 2848, 2852, 2856, 2860, 2864, 2872, 2876, 2880, 2884, 2888, 2892, 2896, 2912, 2916, 2920, 2924, 2928, 2932, 2936, 3602, 3606, 3622, 3626, 3642, 3646, 3662, 3666, 3682, 3686, 3702, 3706, 3722, 3726, 3730, 3734, 3762, 3766, 3782, 3786};
  10. static int ExtremeCoral[114] = {2453, 2457, 2461, 2465, 2469, 2473, 2477, 2481,2485, 2489, 2493, 2513, 2517, 2521, 2525, 2529, 2533, 2537, 2541, 2545, 2549, 2553, 2573, 2577, 2581, 2585, 2589, 2593, 2597, 2601, 2605, 2609, 2613, 2633, 2637, 2641, 2645, 2649, 2653, 2657, 2661, 2665, 2669, 2673, 2693, 2697, 2701, 2705, 2709, 2713, 2717, 2721, 2725, 2729, 2733, 2753, 2757, 2761, 2765, 2769, 2773, 2777, 2781, 2785, 2789, 2793, 2813, 2817, 2821, 2825, 2829, 2833, 2837, 2841, 2845, 2849, 2853, 2857, 2861, 2865, 2873, 2877, 2881, 2885, 2889, 2893, 2897, 2913, 2917, 2921, 2925, 2929, 2933, 2937, 3603, 3607, 3623, 3627, 3643, 3647, 3663, 3667, 3683, 3687, 3703, 3707, 3723, 3727, 3731, 3735, 3763, 3767, 3783, 3787};
  11. static int ExtremeGarnet[114] = {2454, 2458,2462, 2466, 2470, 2474,2478, 2482, 2486, 2490, 2494, 2514, 2518, 2522, 2526, 2530, 2534, 2538, 2542, 2546, 2550, 2554, 2574, 2578, 2582, 2586, 2590, 2594, 2598, 2602, 2606, 2610, 2614, 2634, 2638, 2642, 2646, 2650, 2654, 2658, 2662, 2666, 2670, 2674, 2694, 2698, 2702, 2706, 2710, 2714, 2718, 2722, 2726, 2730, 2734, 2754, 2758, 2762, 2766, 2770, 2774, 2778, 2782, 2786, 2790, 2794, 2814, 2818, 2822, 2826, 2830, 2834, 2838, 2842, 2846, 2850, 2854, 2858, 2862, 2866, 2874, 2878, 2882, 2886, 2890, 2894, 2898, 2914, 2918, 2922, 2926, 2930, 2934, 2938, 3604, 3608, 3624, 3628, 3644, 3648, 3664, 3668, 3684, 3688, 3704, 3708, 3724, 3728, 3732, 3736, 3764, 3768, 3784, 3788};
  12. int refinação11 = player->Equip[DstSlot].EF1;
  13. int refinação12 = player->Equip[DstSlot].EFV1;
  14. int refinação21 = player->Equip[DstSlot].EF2;
  15. int refinação22 = player->Equip[DstSlot].EFV2;
  16. int refinação31 = player->Equip[DstSlot].EF3;
  17. int refinação32 = player->Equip[DstSlot].EFV3;
  18. if(((DstSlot > 0) && (DstSlot < 6)) || ((DstSlot > 6) && (DstSlot < 9)) || (DstSlot > 15))
  19. {
  20. if((player->Equip[DstSlot].Index >= 3500 && player->Equip[DstSlot].Index <= 3507) || player->Equip[DstSlot].Index == 3303)
  21. {
  22. p->SendClientMsg(clientid,"Uso inadequado.");
  23. p->SendALL(clientid);
  24. return;
  25. }
  26. else
  27. {
  28. if((refinação11 == 43) || (refinação11 >= 116 && refinação11 <= 125))
  29. {
  30. if(refinação12 <= 9)
  31. {
  32. p->SendClientMsg(clientid,"Uso inadequado.");
  33. p->SendALL(clientid);
  34. return;
  35. }
  36. else if(refinação12 < 234)// +10
  37. {
  38. player->Equip[DstSlot].EFV1 = 230;
  39. p->SendItens(clientid,DstSlot);
  40. }
  41. else if(refinação12 < 238)// +11
  42. {
  43. player->Equip[DstSlot].EFV1 = 234;
  44. p->SendItens(clientid,DstSlot);
  45. }
  46. else if(refinação12 < 242)// +12
  47. {
  48. player->Equip[DstSlot].EFV1 = 238;
  49. p->SendItens(clientid,DstSlot);
  50. }
  51. else if(refinação12 < 246)// +13
  52. {
  53. player->Equip[DstSlot].EFV1 = 242;
  54. p->SendItens(clientid,DstSlot);
  55. }
  56. else if(refinação12 < 250)// +14
  57. {
  58. player->Equip[DstSlot].EFV1 = 246;
  59. p->SendItens(clientid,DstSlot);
  60. }
  61. else if(refinação12 < 254)// +15
  62. {
  63. player->Equip[DstSlot].EFV1 = 250;
  64. p->SendItens(clientid,DstSlot);
  65. }
  66. else
  67. {
  68. p->SendClientMsg(clientid,"Uso inadequado.");
  69. p->SendALL(clientid);
  70. return;
  71. }
  72. p->DeleteItem(clientid,SrcSlot);
  73. return;
  74. }
  75. else if((refinação21 == 43) || (refinação21 >= 116 && refinação21 <= 125))
  76. {
  77. if(refinação22 <= 9)
  78. {
  79. p->SendClientMsg(clientid,"Uso inadequado.");
  80. p->SendALL(clientid);
  81. return;
  82. }
  83. else if(refinação22 < 234)// +10
  84. {
  85. player->Equip[DstSlot].EFV1 = 230;
  86. p->SendItens(clientid,DstSlot);
  87. }
  88. else if(refinação22 < 238)// +11
  89. {
  90. player->Equip[DstSlot].EFV1 = 234;
  91. p->SendItens(clientid,DstSlot);
  92. }
  93. else if(refinação22 < 242)// +12
  94. {
  95. player->Equip[DstSlot].EFV1 = 238;
  96. p->SendItens(clientid,DstSlot);
  97. }
  98. else if(refinação22 < 246)// +13
  99. {
  100. player->Equip[DstSlot].EFV1 = 242;
  101. p->SendItens(clientid,DstSlot);
  102. }
  103. else if(refinação22 < 250)// +14
  104. {
  105. player->Equip[DstSlot].EFV1 = 246;
  106. p->SendItens(clientid,DstSlot);
  107. }
  108. else if(refinação22 < 254)// +15
  109. {
  110. player->Equip[DstSlot].EFV1 = 250;
  111. p->SendItens(clientid,DstSlot);
  112. }
  113. else
  114. {
  115. p->SendClientMsg(clientid,"Uso inadequado.");
  116. p->SendALL(clientid);
  117. return;
  118. }
  119. p->DeleteItem(clientid,SrcSlot);
  120. return;
  121. }
  122. else if((refinação31 == 43) || (refinação31 >= 116 && refinação31 <= 125))
  123. {
  124. if(refinação32 <= 9)
  125. {
  126. p->SendClientMsg(clientid,"Uso inadequado.");
  127. p->SendALL(clientid);
  128. return;
  129. }
  130. else if(refinação32 < 234)// +10
  131. {
  132. player->Equip[DstSlot].EFV1 = 230;
  133. p->SendItens(clientid,DstSlot);
  134. }
  135. else if(refinação32 < 238)// +11
  136. {
  137. player->Equip[DstSlot].EFV1 = 234;
  138. p->SendItens(clientid,DstSlot);
  139. }
  140. else if(refinação32 < 242)// +12
  141. {
  142. player->Equip[DstSlot].EFV1 = 238;
  143. p->SendItens(clientid,DstSlot);
  144. }
  145. else if(refinação32 < 246)// +13
  146. {
  147. player->Equip[DstSlot].EFV1 = 242;
  148. p->SendItens(clientid,DstSlot);
  149. }
  150. else if(refinação32 < 250)// +14
  151. {
  152. player->Equip[DstSlot].EFV1 = 246;
  153. p->SendItens(clientid,DstSlot);
  154. }
  155. else if(refinação32 < 254)// +15
  156. {
  157. player->Equip[DstSlot].EFV1 = 250;
  158. p->SendItens(clientid,DstSlot);
  159. }
  160. else
  161. {
  162. p->SendClientMsg(clientid,"Uso inadequado.");
  163. p->SendALL(clientid);
  164. return;
  165. }
  166. p->DeleteItem(clientid,SrcSlot);
  167. return;
  168. }
  169. else
  170. {
  171. p->SendClientMsg(clientid,"Uso inadequado.");
  172. p->SendALL(clientid);
  173. return;
  174. }
  175. }
  176. }
  177. else if(DstSlot == 6)// Arma
  178. {
  179. for(int i=0;i<114;i++)
  180. if(player->Equip[DstSlot].Index == ExtremeDiamante[i])
  181. {
  182. player->Equip[DstSlot].Index = player->Equip[DstSlot].Index;
  183. }
  184. else if(player->Equip[DstSlot].Index == ExtremeEsmeralda[i])
  185. {
  186. player->Equip[DstSlot].Index -= 1;
  187. }
  188. else if(player->Equip[DstSlot].Index == ExtremeCoral[i])
  189. {
  190. player->Equip[DstSlot].Index -= 2;
  191. }
  192. else if(player->Equip[DstSlot].Index == ExtremeGarnet[i])
  193. {
  194. player->Equip[DstSlot].Index -= 3;
  195. }
  196. if((refinação11 == 43) || (refinação11 >= 116 && refinação11 <= 125))
  197. {
  198. if(refinação12 <= 9)
  199. {
  200. p->SendItens(clientid,DstSlot);
  201. }
  202. else if(refinação12 < 234)// +10
  203. {
  204. player->Equip[DstSlot].EFV1 = 230;
  205. p->SendItens(clientid,DstSlot);
  206. }
  207. else if(refinação12 < 238)// +11
  208. {
  209. player->Equip[DstSlot].EFV1 = 234;
  210. p->SendItens(clientid,DstSlot);
  211. }
  212. else if(refinação12 < 242)// +12
  213. {
  214. player->Equip[DstSlot].EFV1 = 238;
  215. p->SendItens(clientid,DstSlot);
  216. }
  217. else if(refinação12 < 246)// +13
  218. {
  219. player->Equip[DstSlot].EFV1 = 242;
  220. p->SendItens(clientid,DstSlot);
  221. }
  222. else if(refinação12 < 250)// +14
  223. {
  224. player->Equip[DstSlot].EFV1 = 246;
  225. p->SendItens(clientid,DstSlot);
  226. }
  227. else if(refinação12 < 254)// +15
  228. {
  229. player->Equip[DstSlot].EFV1 = 250;
  230. p->SendItens(clientid,DstSlot);
  231. }
  232. else
  233. {
  234. p->SendClientMsg(clientid,"Uso inadequado.");
  235. p->SendALL(clientid);
  236. return;
  237. }
  238. p->DeleteItem(clientid,SrcSlot);
  239. return;
  240. }
  241. else if((refinação21 == 43) || (refinação21 >= 116 && refinação21 <= 125))
  242. {
  243. if(refinação22 <= 9)
  244. {
  245. p->SendItens(clientid,DstSlot);
  246. }
  247. else if(refinação22 < 234)// +10
  248. {
  249. player->Equip[DstSlot].EFV1 = 230;
  250. p->SendItens(clientid,DstSlot);
  251. }
  252. else if(refinação22 < 238)// +11
  253. {
  254. player->Equip[DstSlot].EFV1 = 234;
  255. p->SendItens(clientid,DstSlot);
  256. }
  257. else if(refinação22 < 242)// +12
  258. {
  259. player->Equip[DstSlot].EFV1 = 238;
  260. p->SendItens(clientid,DstSlot);
  261. }
  262. else if(refinação22 < 246)// +13
  263. {
  264. player->Equip[DstSlot].EFV1 = 242;
  265. p->SendItens(clientid,DstSlot);
  266. }
  267. else if(refinação22 < 250)// +14
  268. {
  269. player->Equip[DstSlot].EFV1 = 246;
  270. p->SendItens(clientid,DstSlot);
  271. }
  272. else if(refinação22 < 254)// +15
  273. {
  274. player->Equip[DstSlot].EFV1 = 250;
  275. p->SendItens(clientid,DstSlot);
  276. }
  277. else
  278. {
  279. p->SendClientMsg(clientid,"Uso inadequado.");
  280. p->SendALL(clientid);
  281. return;
  282. }
  283. p->DeleteItem(clientid,SrcSlot);
  284. return;
  285. }
  286. else if((refinação31 == 43) || (refinação31 >= 116 && refinação31 <= 125))
  287. {
  288. if(refinação32 <= 9)
  289. {
  290. p->SendItens(clientid,DstSlot);
  291. }
  292. else if(refinação32 < 234)// +10
  293. {
  294. player->Equip[DstSlot].EFV1 = 230;
  295. p->SendItens(clientid,DstSlot);
  296. }
  297. else if(refinação32 < 238)// +11
  298. {
  299. player->Equip[DstSlot].EFV1 = 234;
  300. p->SendItens(clientid,DstSlot);
  301. }
  302. else if(refinação32 < 242)// +12
  303. {
  304. player->Equip[DstSlot].EFV1 = 238;
  305. p->SendItens(clientid,DstSlot);
  306. }
  307. else if(refinação32 < 246)// +13
  308. {
  309. player->Equip[DstSlot].EFV1 = 242;
  310. p->SendItens(clientid,DstSlot);
  311. }
  312. else if(refinação32 < 250)// +14
  313. {
  314. player->Equip[DstSlot].EFV1 = 246;
  315. p->SendItens(clientid,DstSlot);
  316. }
  317. else if(refinação32 < 254)// +15
  318. {
  319. player->Equip[DstSlot].EFV1 = 250;
  320. p->SendItens(clientid,DstSlot);
  321. }
  322. else
  323. {
  324. p->SendClientMsg(clientid,"Uso inadequado.");
  325. p->SendALL(clientid);
  326. return;
  327. }
  328. p->DeleteItem(clientid,SrcSlot);
  329. return;
  330. }
  331. else
  332. {
  333. p->SendClientMsg(clientid,"Uso inadequado.");
  334. p->SendALL(clientid);
  335. return;
  336. }
  337. }
  338. else
  339. {
  340. p->SendClientMsg(clientid,"Uso inadequado.");
  341. p->SendALL(clientid);
  342. return;
  343. }
  344. return;
  345. }
  346. void Packets::Gema_de_Esmeralda(int clientid, int SrcSlot, int DstSlot)
  347. {
  348. Atualizar *p;
  349. MOB *player = (MOB*)GetMobFromIndex(clientid);
  350. static int ExtremeDiamante[114] = {2451, 2455, 2459, 2463, 2467, 2471, 2475, 2479, 2483, 2487, 2491, 2511, 2515, 2519, 2523, 2527, 2531, 2535, 2539, 2543, 2547, 2551, 2571, 2575, 2579, 2583, 2587, 2591, 2595, 2599, 2603, 2607, 2611, 2631, 2635, 2639, 2643, 2647, 2651, 2655, 2659, 2663, 2667, 2671, 2691, 2695, 2699, 2703, 2707, 2711, 2715, 2719, 2723, 2727, 2731, 2751, 2755, 2759, 2763, 2767, 2771, 2775, 2779, 2783, 2787, 2791, 2811, 2815, 2819, 2823, 2827, 2831, 2835, 2839, 2843, 2847, 2851, 2855, 2859, 2863, 2871, 2875, 2879, 2883, 2887, 2891, 2895, 2911, 2915, 2919, 2923, 2927, 2931, 2935, 3601, 3605, 3621, 3625, 3641, 3645, 3661, 3665, 3681, 3685, 3701, 3705, 3721, 3725, 3729, 3733, 3761, 3765, 3781, 3785};
  351. static int ExtremeEsmeralda[114] = {2452, 2456, 2460, 2464, 2468, 2472,2476, 2480, 2484, 2488, 2492, 2512, 2516, 2520, 2524, 2528, 2532, 2536, 2540, 2544, 2548, 2552, 2572, 2576, 2580, 2584, 2588, 2592, 2596, 2600, 2604, 2608, 2612, 2632, 2636, 2640, 2644, 2648, 2652, 2656, 2660, 2664, 2668, 2672, 2692, 2696, 2700, 2704, 2708, 2712, 2716, 2720, 2724, 2728, 2732, 2752, 2756, 2760, 2764, 2768, 2772, 2776, 2780, 2784, 2788, 2792, 2812, 2816, 2820, 2824, 2828, 2832, 2836, 2840, 2844, 2848, 2852, 2856, 2860, 2864, 2872, 2876, 2880, 2884, 2888, 2892, 2896, 2912, 2916, 2920, 2924, 2928, 2932, 2936, 3602, 3606, 3622, 3626, 3642, 3646, 3662, 3666, 3682, 3686, 3702, 3706, 3722, 3726, 3730, 3734, 3762, 3766, 3782, 3786};
  352. static int ExtremeCoral[114] = {2453, 2457, 2461, 2465, 2469, 2473, 2477, 2481,2485, 2489, 2493, 2513, 2517, 2521, 2525, 2529, 2533, 2537, 2541, 2545, 2549, 2553, 2573, 2577, 2581, 2585, 2589, 2593, 2597, 2601, 2605, 2609, 2613, 2633, 2637, 2641, 2645, 2649, 2653, 2657, 2661, 2665, 2669, 2673, 2693, 2697, 2701, 2705, 2709, 2713, 2717, 2721, 2725, 2729, 2733, 2753, 2757, 2761, 2765, 2769, 2773, 2777, 2781, 2785, 2789, 2793, 2813, 2817, 2821, 2825, 2829, 2833, 2837, 2841, 2845, 2849, 2853, 2857, 2861, 2865, 2873, 2877, 2881, 2885, 2889, 2893, 2897, 2913, 2917, 2921, 2925, 2929, 2933, 2937, 3603, 3607, 3623, 3627, 3643, 3647, 3663, 3667, 3683, 3687, 3703, 3707, 3723, 3727, 3731, 3735, 3763, 3767, 3783, 3787};
  353. static int ExtremeGarnet[114] = {2454, 2458,2462, 2466, 2470, 2474,2478, 2482, 2486, 2490, 2494, 2514, 2518, 2522, 2526, 2530, 2534, 2538, 2542, 2546, 2550, 2554, 2574, 2578, 2582, 2586, 2590, 2594, 2598, 2602, 2606, 2610, 2614, 2634, 2638, 2642, 2646, 2650, 2654, 2658, 2662, 2666, 2670, 2674, 2694, 2698, 2702, 2706, 2710, 2714, 2718, 2722, 2726, 2730, 2734, 2754, 2758, 2762, 2766, 2770, 2774, 2778, 2782, 2786, 2790, 2794, 2814, 2818, 2822, 2826, 2830, 2834, 2838, 2842, 2846, 2850, 2854, 2858, 2862, 2866, 2874, 2878, 2882, 2886, 2890, 2894, 2898, 2914, 2918, 2922, 2926, 2930, 2934, 2938, 3604, 3608, 3624, 3628, 3644, 3648, 3664, 3668, 3684, 3688, 3704, 3708, 3724, 3728, 3732, 3736, 3764, 3768, 3784, 3788};
  354. int refinação11 = player->Equip[DstSlot].EF1;
  355. int refinação12 = player->Equip[DstSlot].EFV1;
  356. int refinação21 = player->Equip[DstSlot].EF2;
  357. int refinação22 = player->Equip[DstSlot].EFV2;
  358. int refinação31 = player->Equip[DstSlot].EF3;
  359. int refinação32 = player->Equip[DstSlot].EFV3;
  360. if(((DstSlot > 0) && (DstSlot < 6)) || ((DstSlot > 6) && (DstSlot < 9)) || (DstSlot > 15))
  361. {
  362. if((player->Equip[DstSlot].Index >= 3500 && player->Equip[DstSlot].Index <= 3507) || player->Equip[DstSlot].Index == 3303)
  363. {
  364. p->SendClientMsg(clientid,"Uso inadequado.");
  365. p->SendALL(clientid);
  366. return;
  367. }
  368. else
  369. {
  370. if((refinação11 == 43) || (refinação11 >= 116 && refinação11 <= 125))
  371. {
  372. if(refinação12 <= 9)
  373. {
  374. p->SendClientMsg(clientid,"Uso inadequado.");
  375. p->SendALL(clientid);
  376. return;
  377. }
  378. else if(refinação12 < 234)// +10
  379. {
  380. player->Equip[DstSlot].EFV1 = 231;
  381. p->SendItens(clientid,DstSlot);
  382. }
  383. else if(refinação12 < 238)// +11
  384. {
  385. player->Equip[DstSlot].EFV1 = 235;
  386. p->SendItens(clientid,DstSlot);
  387. }
  388. else if(refinação12 < 242)// +12
  389. {
  390. player->Equip[DstSlot].EFV1 = 239;
  391. p->SendItens(clientid,DstSlot);
  392. }
  393. else if(refinação12 < 246)// +13
  394. {
  395. player->Equip[DstSlot].EFV1 = 243;
  396. p->SendItens(clientid,DstSlot);
  397. }
  398. else if(refinação12 < 250)// +14
  399. {
  400. player->Equip[DstSlot].EFV1 = 247;
  401. p->SendItens(clientid,DstSlot);
  402. }
  403. else if(refinação12 < 254)// +15
  404. {
  405. player->Equip[DstSlot].EFV1 = 251;
  406. p->SendItens(clientid,DstSlot);
  407. }
  408. else
  409. {
  410. p->SendClientMsg(clientid,"Uso inadequado.");
  411. p->SendALL(clientid);
  412. return;
  413. }
  414. p->DeleteItem(clientid,SrcSlot);
  415. return;
  416. }
  417. else if((refinação21 == 43) || (refinação21 >= 116 && refinação21 <= 125))
  418. {
  419. if(refinação22 <= 9)
  420. {
  421. p->SendClientMsg(clientid,"Uso inadequado.");
  422. p->SendALL(clientid);
  423. return;
  424. }
  425. else if(refinação22 < 234)// +10
  426. {
  427. player->Equip[DstSlot].EFV1 = 231;
  428. p->SendItens(clientid,DstSlot);
  429. }
  430. else if(refinação22 < 238)// +11
  431. {
  432. player->Equip[DstSlot].EFV1 = 235;
  433. p->SendItens(clientid,DstSlot);
  434. }
  435. else if(refinação22 < 242)// +12
  436. {
  437. player->Equip[DstSlot].EFV1 = 239;
  438. p->SendItens(clientid,DstSlot);
  439. }
  440. else if(refinação22 < 246)// +13
  441. {
  442. player->Equip[DstSlot].EFV1 = 243;
  443. p->SendItens(clientid,DstSlot);
  444. }
  445. else if(refinação22 < 250)// +14
  446. {
  447. player->Equip[DstSlot].EFV1 = 247;
  448. p->SendItens(clientid,DstSlot);
  449. }
  450. else if(refinação22 < 254)// +15
  451. {
  452. player->Equip[DstSlot].EFV1 = 251;
  453. p->SendItens(clientid,DstSlot);
  454. }
  455. else
  456. {
  457. p->SendClientMsg(clientid,"Uso inadequado.");
  458. p->SendALL(clientid);
  459. return;
  460. }
  461. p->DeleteItem(clientid,SrcSlot);
  462. return;
  463. }
  464. else if((refinação31 == 43) || (refinação31 >= 116 && refinação31 <= 125))
  465. {
  466. if(refinação32 <= 9)
  467. {
  468. p->SendClientMsg(clientid,"Uso inadequado.");
  469. p->SendALL(clientid);
  470. return;
  471. }
  472. else if(refinação32 < 234)// +10
  473. {
  474. player->Equip[DstSlot].EFV1 = 231;
  475. p->SendItens(clientid,DstSlot);
  476. }
  477. else if(refinação32 < 238)// +11
  478. {
  479. player->Equip[DstSlot].EFV1 = 235;
  480. p->SendItens(clientid,DstSlot);
  481. }
  482. else if(refinação32 < 242)// +12
  483. {
  484. player->Equip[DstSlot].EFV1 = 239;
  485. p->SendItens(clientid,DstSlot);
  486. }
  487. else if(refinação32 < 246)// +13
  488. {
  489. player->Equip[DstSlot].EFV1 = 243;
  490. p->SendItens(clientid,DstSlot);
  491. }
  492. else if(refinação32 < 250)// +14
  493. {
  494. player->Equip[DstSlot].EFV1 = 248;
  495. p->SendItens(clientid,DstSlot);
  496. }
  497. else if(refinação32 < 254)// +15
  498. {
  499. player->Equip[DstSlot].EFV1 = 251;
  500. p->SendItens(clientid,DstSlot);
  501. }
  502. else
  503. {
  504. p->SendClientMsg(clientid,"Uso inadequado.");
  505. p->SendALL(clientid);
  506. return;
  507. }
  508. p->DeleteItem(clientid,SrcSlot);
  509. return;
  510. }
  511. else
  512. {
  513. p->SendClientMsg(clientid,"Uso inadequado.");
  514. p->SendALL(clientid);
  515. return;
  516. }
  517. }
  518. }
  519. else if(DstSlot == 6)// Arma
  520. {
  521. for(int i=0;i<114;i++)
  522. if(player->Equip[DstSlot].Index == ExtremeDiamante[i])
  523. {
  524. player->Equip[DstSlot].Index += 1;
  525. }
  526. else if(player->Equip[DstSlot].Index == ExtremeEsmeralda[i])
  527. {
  528. player->Equip[DstSlot].Index = player->Equip[DstSlot].Index;
  529. }
  530. else if(player->Equip[DstSlot].Index == ExtremeCoral[i])
  531. {
  532. player->Equip[DstSlot].Index -= 1;
  533. }
  534. else if(player->Equip[DstSlot].Index == ExtremeGarnet[i])
  535. {
  536. player->Equip[DstSlot].Index -= 2;
  537. }
  538. if((refinação11 == 43) || (refinação11 >= 116 && refinação11 <= 125))
  539. {
  540. if(refinação12 <= 9)
  541. {
  542. p->SendItens(clientid,DstSlot);
  543. }
  544. else if(refinação12 < 234)// +10
  545. {
  546. player->Equip[DstSlot].EFV1 = 231;
  547. p->SendItens(clientid,DstSlot);
  548. }
  549. else if(refinação12 < 238)// +11
  550. {
  551. player->Equip[DstSlot].EFV1 = 235;
  552. p->SendItens(clientid,DstSlot);
  553. }
  554. else if(refinação12 < 242)// +12
  555. {
  556. player->Equip[DstSlot].EFV1 = 239;
  557. p->SendItens(clientid,DstSlot);
  558. }
  559. else if(refinação12 < 246)// +13
  560. {
  561. player->Equip[DstSlot].EFV1 = 243;
  562. p->SendItens(clientid,DstSlot);
  563. }
  564. else if(refinação12 < 250)// +14
  565. {
  566. player->Equip[DstSlot].EFV1 = 247;
  567. p->SendItens(clientid,DstSlot);
  568. }
  569. else if(refinação12 < 254)// +15
  570. {
  571. player->Equip[DstSlot].EFV1 = 251;
  572. p->SendItens(clientid,DstSlot);
  573. }
  574. else
  575. {
  576. p->SendClientMsg(clientid,"Uso inadequado.");
  577. p->SendALL(clientid);
  578. return;
  579. }
  580. p->DeleteItem(clientid,SrcSlot);
  581. return;
  582. }
  583. else if((refinação21 == 43) || (refinação21 >= 116 && refinação21 <= 125))
  584. {
  585. if(refinação22 <= 9)
  586. {
  587. p->SendItens(clientid,DstSlot);
  588. }
  589. else if(refinação22 < 234)// +10
  590. {
  591. player->Equip[DstSlot].EFV1 = 231;
  592. p->SendItens(clientid,DstSlot);
  593. }
  594. else if(refinação22 < 238)// +11
  595. {
  596. player->Equip[DstSlot].EFV1 = 235;
  597. p->SendItens(clientid,DstSlot);
  598. }
  599. else if(refinação22 < 242)// +12
  600. {
  601. player->Equip[DstSlot].EFV1 = 239;
  602. p->SendItens(clientid,DstSlot);
  603. }
  604. else if(refinação22 < 246)// +13
  605. {
  606. player->Equip[DstSlot].EFV1 = 243;
  607. p->SendItens(clientid,DstSlot);
  608. }
  609. else if(refinação22 < 250)// +14
  610. {
  611. player->Equip[DstSlot].EFV1 = 247;
  612. p->SendItens(clientid,DstSlot);
  613. }
  614. else if(refinação22 < 254)// +15
  615. {
  616. player->Equip[DstSlot].EFV1 = 251;
  617. p->SendItens(clientid,DstSlot);
  618. }
  619. else
  620. {
  621. p->SendClientMsg(clientid,"Uso inadequado.");
  622. p->SendALL(clientid);
  623. return;
  624. }
  625. p->DeleteItem(clientid,SrcSlot);
  626. return;
  627. }
  628. else if((refinação31 == 43) || (refinação31 >= 116 && refinação31 <= 125))
  629. {
  630. if(refinação32 <= 9)
  631. {
  632. p->SendItens(clientid,DstSlot);
  633. }
  634. else if(refinação32 < 234)// +10
  635. {
  636. player->Equip[DstSlot].EFV1 = 231;
  637. p->SendItens(clientid,DstSlot);
  638. }
  639. else if(refinação32 < 238)// +11
  640. {
  641. player->Equip[DstSlot].EFV1 = 235;
  642. p->SendItens(clientid,DstSlot);
  643. }
  644. else if(refinação32 < 242)// +12
  645. {
  646. player->Equip[DstSlot].EFV1 = 239;
  647. p->SendItens(clientid,DstSlot);
  648. }
  649. else if(refinação32 < 246)// +13
  650. {
  651. player->Equip[DstSlot].EFV1 = 243;
  652. p->SendItens(clientid,DstSlot);
  653. }
  654. else if(refinação32 < 250)// +14
  655. {
  656. player->Equip[DstSlot].EFV1 = 247;
  657. p->SendItens(clientid,DstSlot);
  658. }
  659. else if(refinação32 < 254)// +15
  660. {
  661. player->Equip[DstSlot].EFV1 = 251;
  662. p->SendItens(clientid,DstSlot);
  663. }
  664. else
  665. {
  666. p->SendClientMsg(clientid,"Uso inadequado.");
  667. p->SendALL(clientid);
  668. return;
  669. }
  670. p->DeleteItem(clientid,SrcSlot);
  671. return;
  672. }
  673. else
  674. {
  675. p->SendClientMsg(clientid,"Uso inadequado.");
  676. p->SendALL(clientid);
  677. return;
  678. }
  679. }
  680. else
  681. {
  682. p->SendClientMsg(clientid,"Uso inadequado.");
  683. p->SendALL(clientid);
  684. return;
  685. }
  686. return;
  687. }
  688. void Packets::Gema_de_Coral(int clientid, int SrcSlot, int DstSlot)
  689. {
  690. Atualizar *p;
  691. MOB *player = (MOB*)GetMobFromIndex(clientid);
  692. static int ExtremeDiamante[114] = {2451, 2455, 2459, 2463, 2467, 2471, 2475, 2479, 2483, 2487, 2491, 2511, 2515, 2519, 2523, 2527, 2531, 2535, 2539, 2543, 2547, 2551, 2571, 2575, 2579, 2583, 2587, 2591, 2595, 2599, 2603, 2607, 2611, 2631, 2635, 2639, 2643, 2647, 2651, 2655, 2659, 2663, 2667, 2671, 2691, 2695, 2699, 2703, 2707, 2711, 2715, 2719, 2723, 2727, 2731, 2751, 2755, 2759, 2763, 2767, 2771, 2775, 2779, 2783, 2787, 2791, 2811, 2815, 2819, 2823, 2827, 2831, 2835, 2839, 2843, 2847, 2851, 2855, 2859, 2863, 2871, 2875, 2879, 2883, 2887, 2891, 2895, 2911, 2915, 2919, 2923, 2927, 2931, 2935, 3601, 3605, 3621, 3625, 3641, 3645, 3661, 3665, 3681, 3685, 3701, 3705, 3721, 3725, 3729, 3733, 3761, 3765, 3781, 3785};
  693. static int ExtremeEsmeralda[114] = {2452, 2456, 2460, 2464, 2468, 2472,2476, 2480, 2484, 2488, 2492, 2512, 2516, 2520, 2524, 2528, 2532, 2536, 2540, 2544, 2548, 2552, 2572, 2576, 2580, 2584, 2588, 2592, 2596, 2600, 2604, 2608, 2612, 2632, 2636, 2640, 2644, 2648, 2652, 2656, 2660, 2664, 2668, 2672, 2692, 2696, 2700, 2704, 2708, 2712, 2716, 2720, 2724, 2728, 2732, 2752, 2756, 2760, 2764, 2768, 2772, 2776, 2780, 2784, 2788, 2792, 2812, 2816, 2820, 2824, 2828, 2832, 2836, 2840, 2844, 2848, 2852, 2856, 2860, 2864, 2872, 2876, 2880, 2884, 2888, 2892, 2896, 2912, 2916, 2920, 2924, 2928, 2932, 2936, 3602, 3606, 3622, 3626, 3642, 3646, 3662, 3666, 3682, 3686, 3702, 3706, 3722, 3726, 3730, 3734, 3762, 3766, 3782, 3786};
  694. static int ExtremeCoral[114] = {2453, 2457, 2461, 2465, 2469, 2473, 2477, 2481,2485, 2489, 2493, 2513, 2517, 2521, 2525, 2529, 2533, 2537, 2541, 2545, 2549, 2553, 2573, 2577, 2581, 2585, 2589, 2593, 2597, 2601, 2605, 2609, 2613, 2633, 2637, 2641, 2645, 2649, 2653, 2657, 2661, 2665, 2669, 2673, 2693, 2697, 2701, 2705, 2709, 2713, 2717, 2721, 2725, 2729, 2733, 2753, 2757, 2761, 2765, 2769, 2773, 2777, 2781, 2785, 2789, 2793, 2813, 2817, 2821, 2825, 2829, 2833, 2837, 2841, 2845, 2849, 2853, 2857, 2861, 2865, 2873, 2877, 2881, 2885, 2889, 2893, 2897, 2913, 2917, 2921, 2925, 2929, 2933, 2937, 3603, 3607, 3623, 3627, 3643, 3647, 3663, 3667, 3683, 3687, 3703, 3707, 3723, 3727, 3731, 3735, 3763, 3767, 3783, 3787};
  695. static int ExtremeGarnet[114] = {2454, 2458,2462, 2466, 2470, 2474,2478, 2482, 2486, 2490, 2494, 2514, 2518, 2522, 2526, 2530, 2534, 2538, 2542, 2546, 2550, 2554, 2574, 2578, 2582, 2586, 2590, 2594, 2598, 2602, 2606, 2610, 2614, 2634, 2638, 2642, 2646, 2650, 2654, 2658, 2662, 2666, 2670, 2674, 2694, 2698, 2702, 2706, 2710, 2714, 2718, 2722, 2726, 2730, 2734, 2754, 2758, 2762, 2766, 2770, 2774, 2778, 2782, 2786, 2790, 2794, 2814, 2818, 2822, 2826, 2830, 2834, 2838, 2842, 2846, 2850, 2854, 2858, 2862, 2866, 2874, 2878, 2882, 2886, 2890, 2894, 2898, 2914, 2918, 2922, 2926, 2930, 2934, 2938, 3604, 3608, 3624, 3628, 3644, 3648, 3664, 3668, 3684, 3688, 3704, 3708, 3724, 3728, 3732, 3736, 3764, 3768, 3784, 3788};
  696. int refinação11 = player->Equip[DstSlot].EF1;
  697. int refinação12 = player->Equip[DstSlot].EFV1;
  698. int refinação21 = player->Equip[DstSlot].EF2;
  699. int refinação22 = player->Equip[DstSlot].EFV2;
  700. int refinação31 = player->Equip[DstSlot].EF3;
  701. int refinação32 = player->Equip[DstSlot].EFV3;
  702. if(((DstSlot > 0) && (DstSlot < 6)) || ((DstSlot > 6) && (DstSlot < 9)) || (DstSlot > 15))
  703. {
  704. if((player->Equip[DstSlot].Index >= 3500 && player->Equip[DstSlot].Index <= 3507) || player->Equip[DstSlot].Index == 3303)
  705. {
  706. p->SendClientMsg(clientid,"Uso inadequado.");
  707. p->SendALL(clientid);
  708. return;
  709. }
  710. else
  711. {
  712. if((refinação11 == 43) || (refinação11 >= 116 && refinação11 <= 125))
  713. {
  714. if(refinação12 <= 9)
  715. {
  716. p->SendClientMsg(clientid,"Uso inadequado.");
  717. p->SendALL(clientid);
  718. return;
  719. }
  720. else if(refinação12 < 234)// +10
  721. {
  722. player->Equip[DstSlot].EFV1 = 232;
  723. p->SendItens(clientid,DstSlot);
  724. }
  725. else if(refinação12 < 238)// +11
  726. {
  727. player->Equip[DstSlot].EFV1 = 236;
  728. p->SendItens(clientid,DstSlot);
  729. }
  730. else if(refinação12 < 242)// +12
  731. {
  732. player->Equip[DstSlot].EFV1 = 240;
  733. p->SendItens(clientid,DstSlot);
  734. }
  735. else if(refinação12 < 246)// +13
  736. {
  737. player->Equip[DstSlot].EFV1 = 244;
  738. p->SendItens(clientid,DstSlot);
  739. }
  740. else if(refinação12 < 250)// +14
  741. {
  742. player->Equip[DstSlot].EFV1 = 248;
  743. p->SendItens(clientid,DstSlot);
  744. }
  745. else if(refinação12 < 254)// +15
  746. {
  747. player->Equip[DstSlot].EFV1 = 252;
  748. p->SendItens(clientid,DstSlot);
  749. }
  750. else
  751. {
  752. p->SendClientMsg(clientid,"Uso inadequado.");
  753. p->SendALL(clientid);
  754. return;
  755. }
  756. p->DeleteItem(clientid,SrcSlot);
  757. return;
  758. }
  759. else if((refinação21 == 43) || (refinação21 >= 116 && refinação21 <= 125))
  760. {
  761. if(refinação22 <= 9)
  762. {
  763. p->SendClientMsg(clientid,"Uso inadequado.");
  764. p->SendALL(clientid);
  765. return;
  766. }
  767. else if(refinação22 < 234)// +10
  768. {
  769. player->Equip[DstSlot].EFV1 = 232;
  770. p->SendItens(clientid,DstSlot);
  771. }
  772. else if(refinação22 < 238)// +11
  773. {
  774. player->Equip[DstSlot].EFV1 = 236;
  775. p->SendItens(clientid,DstSlot);
  776. }
  777. else if(refinação22 < 242)// +12
  778. {
  779. player->Equip[DstSlot].EFV1 = 240;
  780. p->SendItens(clientid,DstSlot);
  781. }
  782. else if(refinação22 < 246)// +13
  783. {
  784. player->Equip[DstSlot].EFV1 = 244;
  785. p->SendItens(clientid,DstSlot);
  786. }
  787. else if(refinação22 < 250)// +14
  788. {
  789. player->Equip[DstSlot].EFV1 = 248;
  790. p->SendItens(clientid,DstSlot);
  791. }
  792. else if(refinação22 < 254)// +15
  793. {
  794. player->Equip[DstSlot].EFV1 = 252;
  795. p->SendItens(clientid,DstSlot);
  796. }
  797. else
  798. {
  799. p->SendClientMsg(clientid,"Uso inadequado.");
  800. p->SendALL(clientid);
  801. return;
  802. }
  803. p->DeleteItem(clientid,SrcSlot);
  804. return;
  805. }
  806. else if((refinação31 == 43) || (refinação31 >= 116 && refinação31 <= 125))
  807. {
  808. if(refinação32 <= 9)
  809. {
  810. p->SendClientMsg(clientid,"Uso inadequado.");
  811. p->SendALL(clientid);
  812. return;
  813. }
  814. else if(refinação32 < 234)// +10
  815. {
  816. player->Equip[DstSlot].EFV1 = 232;
  817. p->SendItens(clientid,DstSlot);
  818. }
  819. else if(refinação32 < 238)// +11
  820. {
  821. player->Equip[DstSlot].EFV1 = 236;
  822. p->SendItens(clientid,DstSlot);
  823. }
  824. else if(refinação32 < 242)// +12
  825. {
  826. player->Equip[DstSlot].EFV1 = 240;
  827. p->SendItens(clientid,DstSlot);
  828. }
  829. else if(refinação32 < 246)// +13
  830. {
  831. player->Equip[DstSlot].EFV1 = 244;
  832. p->SendItens(clientid,DstSlot);
  833. }
  834. else if(refinação32 < 250)// +14
  835. {
  836. player->Equip[DstSlot].EFV1 = 248;
  837. p->SendItens(clientid,DstSlot);
  838. }
  839. else if(refinação32 < 254)// +15
  840. {
  841. player->Equip[DstSlot].EFV1 = 252;
  842. p->SendItens(clientid,DstSlot);
  843. }
  844. else
  845. {
  846. p->SendClientMsg(clientid,"Uso inadequado.");
  847. p->SendALL(clientid);
  848. return;
  849. }
  850. p->DeleteItem(clientid,SrcSlot);
  851. return;
  852. }
  853. else
  854. {
  855. p->SendClientMsg(clientid,"Uso inadequado.");
  856. p->SendALL(clientid);
  857. return;
  858. }
  859. }
  860. }
  861. else if(DstSlot == 6)// Arma
  862. {
  863. for(int i=0;i<114;i++)
  864. if(player->Equip[DstSlot].Index == ExtremeDiamante[i])
  865. {
  866. player->Equip[DstSlot].Index += 2;
  867. }
  868. else if(player->Equip[DstSlot].Index == ExtremeEsmeralda[i])
  869. {
  870. player->Equip[DstSlot].Index += 1;
  871. }
  872. else if(player->Equip[DstSlot].Index == ExtremeCoral[i])
  873. {
  874. player->Equip[DstSlot].Index = player->Equip[DstSlot].Index;
  875. }
  876. else if(player->Equip[DstSlot].Index == ExtremeGarnet[i])
  877. {
  878. player->Equip[DstSlot].Index -= 1;
  879. }
  880. if((refinação11 == 43) || (refinação11 >= 116 && refinação11 <= 125))
  881. {
  882. if(refinação12 <= 9)
  883. {
  884. p->SendItens(clientid,DstSlot);
  885. }
  886. else if(refinação12 < 234)// +10
  887. {
  888. player->Equip[DstSlot].EFV1 = 232;
  889. p->SendItens(clientid,DstSlot);
  890. }
  891. else if(refinação12 < 238)// +11
  892. {
  893. player->Equip[DstSlot].EFV1 = 236;
  894. p->SendItens(clientid,DstSlot);
  895. }
  896. else if(refinação12 < 242)// +12
  897. {
  898. player->Equip[DstSlot].EFV1 = 240;
  899. p->SendItens(clientid,DstSlot);
  900. }
  901. else if(refinação12 < 246)// +13
  902. {
  903. player->Equip[DstSlot].EFV1 = 244;
  904. p->SendItens(clientid,DstSlot);
  905. }
  906. else if(refinação12 < 250)// +14
  907. {
  908. player->Equip[DstSlot].EFV1 = 248;
  909. p->SendItens(clientid,DstSlot);
  910. }
  911. else if(refinação12 < 254)// +15
  912. {
  913. player->Equip[DstSlot].EFV1 = 252;
  914. p->SendItens(clientid,DstSlot);
  915. }
  916. else
  917. {
  918. p->SendClientMsg(clientid,"Uso inadequado.");
  919. p->SendALL(clientid);
  920. return;
  921. }
  922. p->DeleteItem(clientid,SrcSlot);
  923. return;
  924. }
  925. else if((refinação21 == 43) || (refinação21 >= 116 && refinação21 <= 125))
  926. {
  927. if(refinação22 <= 9)
  928. {
  929. p->SendClientMsg(clientid,"Uso inadequado.");
  930. p->SendALL(clientid);
  931. return;
  932. }
  933. else if(refinação22 < 234)// +10
  934. {
  935. player->Equip[DstSlot].EFV1 = 232;
  936. p->SendItens(clientid,DstSlot);
  937. }
  938. else if(refinação22 < 238)// +11
  939. {
  940. player->Equip[DstSlot].EFV1 = 236;
  941. p->SendItens(clientid,DstSlot);
  942. }
  943. else if(refinação22 < 242)// +12
  944. {
  945. player->Equip[DstSlot].EFV1 = 240;
  946. p->SendItens(clientid,DstSlot);
  947. }
  948. else if(refinação22 < 246)// +13
  949. {
  950. player->Equip[DstSlot].EFV1 = 244;
  951. p->SendItens(clientid,DstSlot);
  952. }
  953. else if(refinação22 < 250)// +14
  954. {
  955. player->Equip[DstSlot].EFV1 = 248;
  956. p->SendItens(clientid,DstSlot);
  957. }
  958. else if(refinação22 < 254)// +15
  959. {
  960. player->Equip[DstSlot].EFV1 = 252;
  961. p->SendItens(clientid,DstSlot);
  962. }
  963. else
  964. {
  965. p->SendClientMsg(clientid,"Uso inadequado.");
  966. p->SendALL(clientid);
  967. return;
  968. }
  969. p->DeleteItem(clientid,SrcSlot);
  970. return;
  971. }
  972. else if((refinação31 == 43) || (refinação31 >= 116 && refinação31 <= 125))
  973. {
  974. if(refinação32 <= 9)
  975. {
  976. p->SendClientMsg(clientid,"Uso inadequado.");
  977. p->SendALL(clientid);
  978. return;
  979. }
  980. else if(refinação32 < 234)// +10
  981. {
  982. player->Equip[DstSlot].EFV1 = 232;
  983. p->SendItens(clientid,DstSlot);
  984. }
  985. else if(refinação32 < 238)// +11
  986. {
  987. player->Equip[DstSlot].EFV1 = 236;
  988. p->SendItens(clientid,DstSlot);
  989. }
  990. else if(refinação32 < 242)// +12
  991. {
  992. player->Equip[DstSlot].EFV1 = 240;
  993. p->SendItens(clientid,DstSlot);
  994. }
  995. else if(refinação32 < 246)// +13
  996. {
  997. player->Equip[DstSlot].EFV1 = 244;
  998. p->SendItens(clientid,DstSlot);
  999. }
  1000. else if(refinação32 < 250)// +14
  1001. {
  1002. player->Equip[DstSlot].EFV1 = 248;
  1003. p->SendItens(clientid,DstSlot);
  1004. }
  1005. else if(refinação32 < 254)// +15
  1006. {
  1007. player->Equip[DstSlot].EFV1 = 252;
  1008. p->SendItens(clientid,DstSlot);
  1009. }
  1010. else
  1011. {
  1012. p->SendClientMsg(clientid,"Uso inadequado.");
  1013. p->SendALL(clientid);
  1014. return;
  1015. }
  1016. p->DeleteItem(clientid,SrcSlot);
  1017. return;
  1018. }
  1019. else
  1020. {
  1021. p->SendClientMsg(clientid,"Uso inadequado.");
  1022. p->SendALL(clientid);
  1023. return;
  1024. }
  1025. }
  1026. else
  1027. {
  1028. p->SendClientMsg(clientid,"Uso inadequado.");
  1029. p->SendALL(clientid);
  1030. return;
  1031. }
  1032. return;
  1033. }
  1034. void Packets::Gema_de_Garnet(int clientid, int SrcSlot, int DstSlot)
  1035. {
  1036. Atualizar *p;
  1037. MOB *player = (MOB*)GetMobFromIndex(clientid);
  1038. static int ExtremeDiamante[114] = {2451, 2455, 2459, 2463, 2467, 2471, 2475, 2479, 2483, 2487, 2491, 2511, 2515, 2519, 2523, 2527, 2531, 2535, 2539, 2543, 2547, 2551, 2571, 2575, 2579, 2583, 2587, 2591, 2595, 2599, 2603, 2607, 2611, 2631, 2635, 2639, 2643, 2647, 2651, 2655, 2659, 2663, 2667, 2671, 2691, 2695, 2699, 2703, 2707, 2711, 2715, 2719, 2723, 2727, 2731, 2751, 2755, 2759, 2763, 2767, 2771, 2775, 2779, 2783, 2787, 2791, 2811, 2815, 2819, 2823, 2827, 2831, 2835, 2839, 2843, 2847, 2851, 2855, 2859, 2863, 2871, 2875, 2879, 2883, 2887, 2891, 2895, 2911, 2915, 2919, 2923, 2927, 2931, 2935, 3601, 3605, 3621, 3625, 3641, 3645, 3661, 3665, 3681, 3685, 3701, 3705, 3721, 3725, 3729, 3733, 3761, 3765, 3781, 3785};
  1039. static int ExtremeEsmeralda[114] = {2452, 2456, 2460, 2464, 2468, 2472,2476, 2480, 2484, 2488, 2492, 2512, 2516, 2520, 2524, 2528, 2532, 2536, 2540, 2544, 2548, 2552, 2572, 2576, 2580, 2584, 2588, 2592, 2596, 2600, 2604, 2608, 2612, 2632, 2636, 2640, 2644, 2648, 2652, 2656, 2660, 2664, 2668, 2672, 2692, 2696, 2700, 2704, 2708, 2712, 2716, 2720, 2724, 2728, 2732, 2752, 2756, 2760, 2764, 2768, 2772, 2776, 2780, 2784, 2788, 2792, 2812, 2816, 2820, 2824, 2828, 2832, 2836, 2840, 2844, 2848, 2852, 2856, 2860, 2864, 2872, 2876, 2880, 2884, 2888, 2892, 2896, 2912, 2916, 2920, 2924, 2928, 2932, 2936, 3602, 3606, 3622, 3626, 3642, 3646, 3662, 3666, 3682, 3686, 3702, 3706, 3722, 3726, 3730, 3734, 3762, 3766, 3782, 3786};
  1040. static int ExtremeCoral[114] = {2453, 2457, 2461, 2465, 2469, 2473, 2477, 2481,2485, 2489, 2493, 2513, 2517, 2521, 2525, 2529, 2533, 2537, 2541, 2545, 2549, 2553, 2573, 2577, 2581, 2585, 2589, 2593, 2597, 2601, 2605, 2609, 2613, 2633, 2637, 2641, 2645, 2649, 2653, 2657, 2661, 2665, 2669, 2673, 2693, 2697, 2701, 2705, 2709, 2713, 2717, 2721, 2725, 2729, 2733, 2753, 2757, 2761, 2765, 2769, 2773, 2777, 2781, 2785, 2789, 2793, 2813, 2817, 2821, 2825, 2829, 2833, 2837, 2841, 2845, 2849, 2853, 2857, 2861, 2865, 2873, 2877, 2881, 2885, 2889, 2893, 2897, 2913, 2917, 2921, 2925, 2929, 2933, 2937, 3603, 3607, 3623, 3627, 3643, 3647, 3663, 3667, 3683, 3687, 3703, 3707, 3723, 3727, 3731, 3735, 3763, 3767, 3783, 3787};
  1041. static int ExtremeGarnet[114] = {2454, 2458,2462, 2466, 2470, 2474,2478, 2482, 2486, 2490, 2494, 2514, 2518, 2522, 2526, 2530, 2534, 2538, 2542, 2546, 2550, 2554, 2574, 2578, 2582, 2586, 2590, 2594, 2598, 2602, 2606, 2610, 2614, 2634, 2638, 2642, 2646, 2650, 2654, 2658, 2662, 2666, 2670, 2674, 2694, 2698, 2702, 2706, 2710, 2714, 2718, 2722, 2726, 2730, 2734, 2754, 2758, 2762, 2766, 2770, 2774, 2778, 2782, 2786, 2790, 2794, 2814, 2818, 2822, 2826, 2830, 2834, 2838, 2842, 2846, 2850, 2854, 2858, 2862, 2866, 2874, 2878, 2882, 2886, 2890, 2894, 2898, 2914, 2918, 2922, 2926, 2930, 2934, 2938, 3604, 3608, 3624, 3628, 3644, 3648, 3664, 3668, 3684, 3688, 3704, 3708, 3724, 3728, 3732, 3736, 3764, 3768, 3784, 3788};
  1042. int refinação11 = player->Equip[DstSlot].EF1;
  1043. int refinação12 = player->Equip[DstSlot].EFV1;
  1044. int refinação21 = player->Equip[DstSlot].EF2;
  1045. int refinação22 = player->Equip[DstSlot].EFV2;
  1046. int refinação31 = player->Equip[DstSlot].EF3;
  1047. int refinação32 = player->Equip[DstSlot].EFV3;
  1048. if(((DstSlot > 0) && (DstSlot < 6)) || ((DstSlot > 6) && (DstSlot < 9)) || (DstSlot > 15))
  1049. {
  1050. if((player->Equip[DstSlot].Index >= 3500 && player->Equip[DstSlot].Index <= 3507) || player->Equip[DstSlot].Index == 3303)
  1051. {
  1052. p->SendClientMsg(clientid,"Uso inadequado.");
  1053. p->SendALL(clientid);
  1054. return;
  1055. }
  1056. else
  1057. {
  1058. if((refinação11 == 43) || (refinação11 >= 116 && refinação11 <= 125))
  1059. {
  1060. if(refinação12 <= 9)
  1061. {
  1062. p->SendClientMsg(clientid,"Uso inadequado.");
  1063. p->SendALL(clientid);
  1064. return;
  1065. }
  1066. else if(refinação12 < 234)// +10
  1067. {
  1068. player->Equip[DstSlot].EFV1 = 233;
  1069. p->SendItens(clientid,DstSlot);
  1070. }
  1071. else if(refinação12 < 238)// +11
  1072. {
  1073. player->Equip[DstSlot].EFV1 = 237;
  1074. p->SendItens(clientid,DstSlot);
  1075. }
  1076. else if(refinação12 < 242)// +12
  1077. {
  1078. player->Equip[DstSlot].EFV1 = 241;
  1079. p->SendItens(clientid,DstSlot);
  1080. }
  1081. else if(refinação12 < 246)// +13
  1082. {
  1083. player->Equip[DstSlot].EFV1 = 245;
  1084. p->SendItens(clientid,DstSlot);
  1085. }
  1086. else if(refinação12 < 250)// +14
  1087. {
  1088. player->Equip[DstSlot].EFV1 = 249;
  1089. p->SendItens(clientid,DstSlot);
  1090. }
  1091. else if(refinação12 < 254)// +15
  1092. {
  1093. player->Equip[DstSlot].EFV1 = 253;
  1094. p->SendItens(clientid,DstSlot);
  1095. }
  1096. else
  1097. {
  1098. p->SendClientMsg(clientid,"Uso inadequado.");
  1099. p->SendALL(clientid);
  1100. return;
  1101. }
  1102. p->DeleteItem(clientid,SrcSlot);
  1103. return;
  1104. }
  1105. else if((refinação21 == 43) || (refinação21 >= 116 && refinação21 <= 125))
  1106. {
  1107. if(refinação22 <= 9)
  1108. {
  1109. p->SendClientMsg(clientid,"Uso inadequado.");
  1110. p->SendALL(clientid);
  1111. return;
  1112. }
  1113. else if(refinação22 < 234)// +10
  1114. {
  1115. player->Equip[DstSlot].EFV1 = 233;
  1116. p->SendItens(clientid,DstSlot);
  1117. }
  1118. else if(refinação22 < 238)// +11
  1119. {
  1120. player->Equip[DstSlot].EFV1 = 237;
  1121. p->SendItens(clientid,DstSlot);
  1122. }
  1123. else if(refinação22 < 242)// +12
  1124. {
  1125. player->Equip[DstSlot].EFV1 = 241;
  1126. p->SendItens(clientid,DstSlot);
  1127. }
  1128. else if(refinação22 < 246)// +13
  1129. {
  1130. player->Equip[DstSlot].EFV1 = 245;
  1131. p->SendItens(clientid,DstSlot);
  1132. }
  1133. else if(refinação22 < 250)// +14
  1134. {
  1135. player->Equip[DstSlot].EFV1 = 249;
  1136. p->SendItens(clientid,DstSlot);
  1137. }
  1138. else if(refinação22 < 254)// +15
  1139. {
  1140. player->Equip[DstSlot].EFV1 = 253;
  1141. p->SendItens(clientid,DstSlot);
  1142. }
  1143. else
  1144. {
  1145. p->SendClientMsg(clientid,"Uso inadequado.");
  1146. p->SendALL(clientid);
  1147. return;
  1148. }
  1149. p->DeleteItem(clientid,SrcSlot);
  1150. return;
  1151. }
  1152. else if((refinação31 == 43) || (refinação31 >= 116 && refinação31 <= 125))
  1153. {
  1154. if(refinação32 <= 9)
  1155. {
  1156. p->SendClientMsg(clientid,"Uso inadequado.");
  1157. p->SendALL(clientid);
  1158. return;
  1159. }
  1160. else if(refinação32 < 234)// +10
  1161. {
  1162. player->Equip[DstSlot].EFV1 = 233;
  1163. p->SendItens(clientid,DstSlot);
  1164. }
  1165. else if(refinação32 < 238)// +11
  1166. {
  1167. player->Equip[DstSlot].EFV1 = 237;
  1168. p->SendItens(clientid,DstSlot);
  1169. }
  1170. else if(refinação32 < 242)// +12
  1171. {
  1172. player->Equip[DstSlot].EFV1 = 241;
  1173. p->SendItens(clientid,DstSlot);
  1174. }
  1175. else if(refinação32 < 246)// +13
  1176. {
  1177. player->Equip[DstSlot].EFV1 = 245;
  1178. p->SendItens(clientid,DstSlot);
  1179. }
  1180. else if(refinação32 < 250)// +14
  1181. {
  1182. player->Equip[DstSlot].EFV1 = 249;
  1183. p->SendItens(clientid,DstSlot);
  1184. }
  1185. else if(refinação32 < 254)// +15
  1186. {
  1187. player->Equip[DstSlot].EFV1 = 253;
  1188. p->SendItens(clientid,DstSlot);
  1189. }
  1190. else
  1191. {
  1192. p->SendClientMsg(clientid,"Uso inadequado.");
  1193. p->SendALL(clientid);
  1194. return;
  1195. }
  1196. p->DeleteItem(clientid,SrcSlot);
  1197. return;
  1198. }
  1199. else
  1200. {
  1201. p->SendClientMsg(clientid,"Uso inadequado.");
  1202. p->SendALL(clientid);
  1203. return;
  1204. }
  1205. }
  1206. }
  1207. else if(DstSlot == 6)// Arma
  1208. {
  1209. for(int i=0;i<114;i++)
  1210. if(player->Equip[DstSlot].Index == ExtremeDiamante[i])
  1211. {
  1212. player->Equip[DstSlot].Index += 3;
  1213. }
  1214. else if(player->Equip[DstSlot].Index == ExtremeEsmeralda[i])
  1215. {
  1216. player->Equip[DstSlot].Index += 2;
  1217. }
  1218. else if(player->Equip[DstSlot].Index == ExtremeCoral[i])
  1219. {
  1220. player->Equip[DstSlot].Index += 1;
  1221. }
  1222. else if(player->Equip[DstSlot].Index == ExtremeGarnet[i])
  1223. {
  1224. player->Equip[DstSlot].Index = player->Equip[DstSlot].Index;
  1225. }
  1226. if((refinação11 == 43) || (refinação11 >= 116 && refinação11 <= 125))
  1227. {
  1228. if(refinação12 <= 9)
  1229. {
  1230. p->SendItens(clientid,DstSlot);
  1231. }
  1232. else if(refinação12 < 234)// +10
  1233. {
  1234. player->Equip[DstSlot].EFV1 = 233;
  1235. p->SendItens(clientid,DstSlot);
  1236. }
  1237. else if(refinação12 < 238)// +11
  1238. {
  1239. player->Equip[DstSlot].EFV1 = 237;
  1240. p->SendItens(clientid,DstSlot);
  1241. }
  1242. else if(refinação12 < 242)// +12
  1243. {
  1244. player->Equip[DstSlot].EFV1 = 241;
  1245. p->SendItens(clientid,DstSlot);
  1246. }
  1247. else if(refinação12 < 246)// +13
  1248. {
  1249. player->Equip[DstSlot].EFV1 = 245;
  1250. p->SendItens(clientid,DstSlot);
  1251. }
  1252. else if(refinação12 < 250)// +14
  1253. {
  1254. player->Equip[DstSlot].EFV1 = 249;
  1255. p->SendItens(clientid,DstSlot);
  1256. }
  1257. else if(refinação12 < 254)// +15
  1258. {
  1259. player->Equip[DstSlot].EFV1 = 253;
  1260. p->SendItens(clientid,DstSlot);
  1261. }
  1262. else
  1263. {
  1264. p->SendClientMsg(clientid,"Uso inadequado.");
  1265. p->SendALL(clientid);
  1266. return;
  1267. }
  1268. p->DeleteItem(clientid,SrcSlot);
  1269. return;
  1270. }
  1271. else if((refinação21 == 43) || (refinação21 >= 116 && refinação21 <= 125))
  1272. {
  1273. if(refinação22 <= 9)
  1274. {
  1275. p->SendClientMsg(clientid,"Uso inadequado.");
  1276. p->SendALL(clientid);
  1277. return;
  1278. }
  1279. else if(refinação22 < 234)// +10
  1280. {
  1281. player->Equip[DstSlot].EFV1 = 233;
  1282. p->SendItens(clientid,DstSlot);
  1283. }
  1284. else if(refinação22 < 238)// +11
  1285. {
  1286. player->Equip[DstSlot].EFV1 = 237;
  1287. p->SendItens(clientid,DstSlot);
  1288. }
  1289. else if(refinação22 < 242)// +12
  1290. {
  1291. player->Equip[DstSlot].EFV1 = 241;
  1292. p->SendItens(clientid,DstSlot);
  1293. }
  1294. else if(refinação22 < 246)// +13
  1295. {
  1296. player->Equip[DstSlot].EFV1 = 245;
  1297. p->SendItens(clientid,DstSlot);
  1298. }
  1299. else if(refinação22 < 250)// +14
  1300. {
  1301. player->Equip[DstSlot].EFV1 = 249;
  1302. p->SendItens(clientid,DstSlot);
  1303. }
  1304. else if(refinação22 < 254)// +15
  1305. {
  1306. player->Equip[DstSlot].EFV1 = 254;
  1307. p->SendItens(clientid,DstSlot);
  1308. }
  1309. else
  1310. {
  1311. p->SendClientMsg(clientid,"Uso inadequado.");
  1312. p->SendALL(clientid);
  1313. return;
  1314. }
  1315. p->DeleteItem(clientid,SrcSlot);
  1316. return;
  1317. }
  1318. else if((refinação31 == 43) || (refinação31 >= 116 && refinação31 <= 125))
  1319. {
  1320. if(refinação32 <= 9)
  1321. {
  1322. p->SendClientMsg(clientid,"Uso inadequado.");
  1323. p->SendALL(clientid);
  1324. return;
  1325. }
  1326. else if(refinação32 < 234)// +10
  1327. {
  1328. player->Equip[DstSlot].EFV1 = 233;
  1329. p->SendItens(clientid,DstSlot);
  1330. }
  1331. else if(refinação32 < 238)// +11
  1332. {
  1333. player->Equip[DstSlot].EFV1 = 237;
  1334. p->SendItens(clientid,DstSlot);
  1335. }
  1336. else if(refinação32 < 242)// +12
  1337. {
  1338. player->Equip[DstSlot].EFV1 = 241;
  1339. p->SendItens(clientid,DstSlot);
  1340. }
  1341. else if(refinação32 < 246)// +13
  1342. {
  1343. player->Equip[DstSlot].EFV1 = 245;
  1344. p->SendItens(clientid,DstSlot);
  1345. }
  1346. else if(refinação32 < 250)// +14
  1347. {
  1348. player->Equip[DstSlot].EFV1 = 249;
  1349. p->SendItens(clientid,DstSlot);
  1350. }
  1351. else if(refinação32 < 254)// +15
  1352. {
  1353. player->Equip[DstSlot].EFV1 = 253;
  1354. p->SendItens(clientid,DstSlot);
  1355. }
  1356. else
  1357. {
  1358. p->SendClientMsg(clientid,"Uso inadequado.");
  1359. p->SendALL(clientid);
  1360. return;
  1361. }
  1362. p->DeleteItem(clientid,SrcSlot);
  1363. return;
  1364. }
  1365. else
  1366. {
  1367. p->SendClientMsg(clientid,"Uso inadequado.");
  1368. p->SendALL(clientid);
  1369. return;
  1370. }
  1371. }
  1372. else
  1373. {
  1374. p->SendClientMsg(clientid,"Uso inadequado.");
  1375. p->SendALL(clientid);
  1376. return;
  1377. }
  1378. return;
  1379. }
Add Comment
Please, Sign In to add comment