Advertisement
Guest User

macro fungo

a guest
Dec 15th, 2017
111
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 7.42 KB | None | 0 0
  1. $${
  2. if(@neth3);
  3. keyup(forward);
  4. unset(@neth3);
  5. }$$
  6. /home
  7. $${
  8. wait(500ms);
  9. gui(GUICHEST);
  10.  
  11. wait(500ms);
  12. slotclick(11,r,false);
  13. wait(1);
  14. slotclick(15,l,false);
  15.  
  16. wait(1500ms);
  17. }$$
  18.  
  19. /sethome fungotemp
  20.  
  21. $${
  22. #snposx1=%XPOS%; #snposx2=%ZPOS%;
  23. log("&d» &6Plantação Automática &c[OFF]");
  24. stop();
  25. else;
  26. set(@neth3);
  27. #delay=8;#nbau=1;
  28. log("&d» &6Plantação Automática &a[ON]");
  29. PROMPT(&return,$$?,"Continuar de onde estava quando desligou? (S ou N)");
  30. ifmatches(%&return%,^[S|s]);
  31. set(return);
  32. log("&d» &6Continuando a partir de onde foi desligado!");
  33. else;
  34. unset(return);
  35. PROMPT(#fxv,$$?,"Quantos andares são? (O máximo são 6 andares!)"); if(%#fxv%=0);unset(@neth3);stop();endif;
  36. #hfl=1;
  37. if(%#fxv%>1);
  38. &tm=;
  39. if(%#fxv%=2);&tm=1 ou 2?;endif;if(%#fxv%=3);&tm=1, 2 ou 3?;endif;if(%#fxv%=4);&tm=1, 2, 3 ou 4?;endif;if(%#fxv%=5);&tm=1, 2, 3, 4 ou 5?;endif;if(%#fxv%=6);&tm=1, 2, 3, 4, 5 ou 6?;endif;
  40. if(%#fxv%>6);
  41. log("&d» &cOps! &6Número de andares maior que o possível &3(6)&6!");
  42. log("&d» &6Plantação Automática &c[OFF]");
  43. unset(@neth3);
  44. stop();
  45. endif;
  46. PROMPT(#flror,$$?,"Começar por qual andar? %&tm%"); if(%#flror%=0);unset(@neth3);stop();endif;
  47. else;
  48. #flror=1;
  49. endif;
  50. if(%#flror%>%#fxv%);
  51. log(&d» &cOps! &6Andar escolhido para começar é maior que o número de andares que você escolheu! Preste mais atenção nas perguntas &3:/);
  52. log("&d» &6Plantação Automática &c[OFF]");
  53. unset(@neth3);
  54. stop();
  55. endif;
  56. log("&d» &6As sethomes devem ser no estilo: &3/home fungof1 /home fungof2&6 ...");
  57. log("&d» &6A sethome dos baús deve ser &3/home fungobaus &6...");
  58. log("&d» &6Se quiser parar só por um tempo, segure a &3tecla P&6 até parar!");
  59. set(first);
  60. endif;
  61.  
  62. do;
  63. for(#hfl,%#flror%,%#fxv%);
  64. wait(1);
  65. if(return);
  66. #hfltemp=%#hfl%;#hfl=8000;
  67. }$$
  68. /home fungotemp
  69. $${
  70. do;until((%XPOS%=%#snposx1%)&&(%ZPOS%=%#snposx2%));wait(1);
  71. unset(return);
  72. else;
  73. }$$
  74. $${if(%#hfl%=1);}$$/home fungof1$${endif;}$$
  75. $${if(%#hfl%=2);}$$/home fungof2$${endif;}$$
  76. $${if(%#hfl%=3);}$$/home fungof3$${endif;}$$
  77. $${if(%#hfl%=4);}$$/home fungof4$${endif;}$$
  78. $${if(%#hfl%=5);}$$/home fungof5$${endif;}$$
  79. $${if(%#hfl%=6);}$$/home fungof6$${endif;}$$
  80. $${
  81. wait(8);
  82. set(first);
  83. endif;
  84.  
  85. keydown(jump);wait(100ms);keyup(jump);wait(1);
  86. &dir=%DIRECTION%;
  87. ifmatches(%&dir%,N);&dir=NORTH;endif;
  88. ifmatches(%&dir%,S);&dir=SOUTH;endif;
  89. ifmatches(%&dir%,E);&dir=EAST;endif;
  90. ifmatches(%&dir%,W);&dir=WEST;endif;
  91.  
  92. gui();
  93. for(#in,1,9);
  94. getslotitem(%#in%,#idk,#stack);
  95. ifmatches(%#idk%,^269$|^270$|^271$|^273$|^274$|^275$|^277$|^278$|^279$|^284$|^285$|^286$|^256$|^257$|^258$);
  96. #slotl=%#in%;
  97. endif;
  98. next;
  99.  
  100. look(%&dir%);
  101. look(,+89);
  102. key(attack);
  103. unset(nextfloor);
  104.  
  105. do;
  106. #stack=0;
  107. keyup(forward);
  108. gui(inventory);
  109. wait(450ms);
  110. getslot(372,#fghot);
  111. getslotitem(35,#id,#stack);
  112. if(%#fghot%<36);
  113. slotclick(%#fghot%,l,true);
  114. endif;
  115. wait(450ms);
  116. gui();
  117.  
  118. if(%#stack%>0);
  119. #nposx1=%XPOS%; #nposx2=%ZPOS%;
  120. }$$
  121. /home
  122. $${
  123. wait(500ms);
  124. gui(GUICHEST);
  125.  
  126. wait(500ms);
  127. slotclick(11,r,false);
  128. wait(1);
  129. slotclick(15,l,false);
  130.  
  131. wait(1500ms);
  132. }$$/sethome fungotemp
  133.  
  134. $${
  135. wait(1)
  136. }$$
  137.  
  138. /home venderfungo
  139.  
  140. $${
  141.  
  142. wait(500ms);
  143. key(attack);
  144. wait(1);
  145. key(attack);
  146. wait(1);
  147.  
  148. }$$
  149.  
  150. $${
  151.  
  152. look(east);
  153. gui(inventory);
  154. wait(1);
  155. FOR(#u,9,44);
  156. GETSLOTITEM(%#u%,#idu,#stacku);
  157. IF(%#idu%=387);
  158. SLOTCLICK(%#u%);
  159. SLOTCLICK(-999);
  160. ENDIF;
  161. NEXT;;
  162. gui();
  163. wait(1);
  164.  
  165. }$$
  166.  
  167. /home fungotemp
  168.  
  169. $${
  170. wait(%#delay%);
  171. keydown(jump);wait(100ms);keyup(jump);wait(1);
  172. else;
  173. gui();
  174. endif;
  175.  
  176. do;
  177. &dir=%DIRECTION%;
  178. ifmatches(%&dir%,N);&dir=NORTH;&z=-1;&x=+0;&z1=+0;&z2=+0;&x1=-1;&x2=+1;endif;
  179. ifmatches(%&dir%,S);&dir=SOUTH;&z=+1;&x=+0;&z1=+0;&z2=+0;&x1=+1;&x2=-1;endif;
  180. ifmatches(%&dir%,E);&dir=EAST;&z=+0;&x=+1;&x1=+0;&x2=+0;&z1=-1;&z2=+1;endif;
  181. ifmatches(%&dir%,W);&dir=WEST;&z=+0;&x=-1;&x1=+0;&x2=+0;&z1=+1;&z2=-1;endif;
  182.  
  183. ifmatches(%GUI%,chat|inventory);
  184. keyup(forward);
  185. log(&d» &6Chat ou inventório detectado. &3Macro pausado!);
  186. do;
  187. ifmatches(%GUI%,CHAT|INVENTORY);
  188. else;
  189. #g=0;
  190. endif;
  191. until(%#g%=0);
  192. #g=1;
  193. log(&d» &6Chat ou inventório fechado. &3Continuando!);
  194. endif;
  195.  
  196. if(KEY_P);
  197. keyup(forward);
  198. wait(200ms);
  199. #nposx1=%XPOS%;#nposx2=%ZPOS%;
  200. }$$
  201. /home
  202. $${
  203. wait(500ms);
  204. gui(GUICHEST);
  205.  
  206. wait(500ms);
  207. slotclick(11,r,false);
  208. wait(1);
  209. slotclick(15,l,false);
  210.  
  211. wait(1500ms);
  212. }$$/sethome fungotemp
  213.  
  214. $${
  215. log(&d» &6Plantação automática &3interrompida&6!);
  216. log(&d» &6Para continuar, segure a &3tecla P &6por 3 segundos!);
  217. do;
  218. if(KEY_P);
  219. wait(3);
  220. if(KEY_P);
  221. wait(200ms);
  222. if(KEY_P);
  223. set(resume);
  224. endif;
  225. endif;
  226. endif;
  227. until(resume);
  228. unset(resume);
  229. }$$
  230. /home fungotemp
  231. $${
  232. log("&d» &6Plantação automática &3retomada&6!");
  233. log("&d» &6Não mexa o mouse, oki? &3:)");
  234. do;until((%XPOS%=%#nposx1%)&&(%ZPOS%=%#nposx2%));
  235. wait(2);
  236. endif;
  237.  
  238. &dir=%DIRECTION%;
  239. ifmatches(%&dir%,N);&dir=NORTH;endif;
  240. ifmatches(%&dir%,S);&dir=SOUTH;endif;
  241. ifmatches(%&dir%,E);&dir=EAST;endif;
  242. ifmatches(%&dir%,W);&dir=WEST;endif;
  243.  
  244. look(%&dir%);
  245. look(,+89);
  246. #nposx1=%XPOS%; #nposx2=%ZPOS%;
  247. do;
  248. keydown(forward);
  249. pick(372);
  250. key(use);
  251. getidrel(%&x%,+0,%&z%,#blockd);
  252. getidrel(%&x%,+1,%&z%,#blocku);
  253. until((%XPOS%!=%#nposx1%)|(%ZPOS%!=%#nposx2%)|(%#blockd%!=88)|(%#blocku%!=115)&&(%#blocku%!=0));
  254. slot(%#slotl%);
  255. if(%HITDATA%>2);key(attack);wait(10ms);endif;
  256. until((%#blockd%!=88)|(%#blocku%!=115)&&(%#blocku%!=0));
  257.  
  258. key(use);
  259. keyup(forward);
  260.  
  261. if(first);
  262. getidrel(%&x1%,+0,%&z1%,#block1);getidrel(%&x2%,+0,%&z2%,#block2);
  263. getidrel(%&x1%,+1,%&z1%,#block3);getidrel(%&x2%,+1,%&z2%,#block4);
  264. if((%#block1%=88)|(%#block3%=88));&sn=-;endif;
  265. if((%#block2%=88)|(%#block4%=88));&sn=+;endif;
  266. &dirc=%DIRECTION%;
  267. ifmatches(%&sn%,[\+]);&sn1=+;&sn2=-;endif;
  268. ifmatches(%&sn%,[\-]);&sn1=-;&sn2=+;endif;
  269. unset(first);
  270. endif;
  271.  
  272. &dir=%DIRECTION%;
  273. ifmatches(%&dirc%,N);ifmatches(%&dir%,N);&sn=%&sn1%;endif;ifmatches(%&dir%,S);&sn=%&sn2%;endif;endif;
  274. ifmatches(%&dirc%,S);ifmatches(%&dir%,N);&sn=%&sn2%;endif;ifmatches(%&dir%,S);&sn=%&sn1%;endif;endif;
  275. ifmatches(%&dirc%,W);ifmatches(%&dir%,W);&sn=%&sn1%;endif;ifmatches(%&dir%,E);&sn=%&sn2%;endif;endif;
  276. ifmatches(%&dirc%,E);ifmatches(%&dir%,W);&sn=%&sn2%;endif;ifmatches(%&dir%,E);&sn=%&sn1%;endif;endif;
  277.  
  278. look(%&sn%90,);
  279. wait(100ms);
  280.  
  281. &dir=%DIRECTION%;
  282. ifmatches(%&dir%,N);&dir=NORTH;&z=-1;&x=+0;&z1=+0;&z2=+0;&x1=-1;&x2=+1;endif;
  283. ifmatches(%&dir%,S);&dir=SOUTH;&z=+1;&x=+0;&z1=+0;&z2=+0;&x1=+1;&x2=-1;endif;
  284. ifmatches(%&dir%,E);&dir=EAST;&z=+0;&x=+1;&x1=+0;&x2=+0;&z1=-1;&z2=+1;endif;
  285. ifmatches(%&dir%,W);&dir=WEST;&z=+0;&x=-1;&x1=+0;&x2=+0;&z1=+1;&z2=-1;endif;
  286.  
  287. getidrel(%&x%,+0,%&z%,#block1);
  288. getidrel(%&x%,+1,%&z%,#block3);
  289.  
  290. if(((%#block3%!=0)&&(%#block3%!=115))|(%#block1%!=88));
  291. set(nextfloor);
  292. endif;
  293.  
  294. if(nextfloor);
  295. else;
  296. #nposx1 = %XPOS%; #nposx2 = %ZPOS%;
  297. do;
  298. keydown(forward);
  299. pick(372);
  300. key(use);
  301. until((%XPOS%!=%#nposx1%)|(%ZPOS%!=%#nposx2%));
  302. keyup(forward);
  303. key(attack);
  304. look(%&sn%90,);
  305. endif;
  306. until(nextfloor);
  307. keyup(FORWARD);
  308. next;
  309. #flror=1;
  310. loop;
  311. endif;
  312. }$$
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement