matsamilla

Untitled

Dec 15th, 2018
83
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.71 KB | None | 0 0
  1. // !! Find and equip any axe in backpack ***
  2. // Line up on a row of tree's facing NORTH and activate this macro
  3. // It will chop, and run around tree to next tree north in line
  4. // It WILL get stuck if multiple trees
  5. // DO NOT USE AFK
  6. if not listexists 'AxeList'
  7. createlist 'AxeList'
  8. endif
  9. // !! axe data
  10. @clearlist 'AxeList'
  11. @pushlist 'AxeList' 0xf43 //Hatchet
  12. @pushlist 'AxeList' 0xf45 //Executioner's Axe
  13. @pushlist 'AxeList' 0xf4d //Bardiche
  14. @pushlist 'AxeList' 0xf4b //Double Axe
  15. @pushlist 'AxeList' 0x143e //Halberd
  16. @pushlist 'AxeList' 0x13fb //Large Battle Axe
  17. @pushlist 'AxeList' 0x1443 //Two Handed Axe
  18. @pushlist 'AxeList' 0xf47 //Battle Axe
  19. @pushlist 'AxeList' 0xf49 //Axe
  20. //
  21. // !! Equip Axe
  22. for 0 to 'AxeList'
  23. if @findtype 'AxeList[]' 'any' 'backpack'
  24. unsetalias 'AXE'
  25. setalias 'AXE' 'found'
  26. endif
  27. endfor
  28. //******************************************
  29. //
  30. // !! Main chopping routine
  31. while weight < maxweight
  32. clearjournal
  33. if not @findlayer 'self' 2
  34. equipitem 'AXE' 2
  35. pause 600
  36. endif
  37. //
  38. useobject 'LeftHand'
  39. waitfortarget 1000
  40. if direction == 0
  41. targettileoffset! 0 -1 0
  42. elseif direction == 1
  43. targettileoffset! 1 -1 0
  44. elseif direction == 2
  45. targettileoffset! 1 0 0
  46. elseif direction == 3
  47. targettileoffset! 1 1 0
  48. elseif direction == 4
  49. targettileoffset! 0 1 0
  50. elseif direction == 5
  51. targettileoffset! -1 1 0
  52. elseif direction == 6
  53. targettileoffset! -1 0 0
  54. elseif direction == 7
  55. targettileoffset! -1 -1 0
  56. endif
  57. pause 500
  58. //
  59. //
  60. //****** Wait for it **********************
  61. // !! System hickup insurance loop
  62. for 60
  63. if @injournal 'enough wood here' 'system'
  64. break
  65. elseif @injournal 'You chop' 'system'
  66. break
  67. elseif @injournal "fail to" "system"
  68. break
  69. elseif @injournal "You can't" "system"
  70. break
  71. elseif @injournal "You can" "system"
  72. break
  73. elseif not @findlayer 'self' 2
  74. break
  75. else
  76. pause 100
  77. endif
  78. endfor
  79. //
  80. //******************************************
  81. //
  82. //*** Display proper feedback
  83. if @injournal "You can't" "system"
  84. pause 500
  85. endif
  86. if @injournal 'enough wood here' 'system'
  87. headmsg 'NO MORE WOOD' '2124'
  88. headmsg 'go to next tree' '2124'
  89. msg '[e whistle'
  90. pause 2000
  91. turn "East"
  92. walk "East"
  93. turn "North"
  94. walk "North"
  95. walk "North"
  96. turn "West"
  97. walk "West"
  98. turn "North"
  99. run "North"
  100. run "North"
  101. run "North"
  102. run "North"
  103. run "North"
  104. run "North"
  105. run "North"
  106. run "North"
  107. run "North"
  108. run "North"
  109. pause 800
  110. endif
  111. if @injournal 'some ordinary' 'system'
  112. headmsg '--Ordinary wood--' '1150'
  113. clearjournal
  114. endif
  115. if @injournal 'some oak' 'system'
  116. headmsg '--OAK--' '2010'
  117. clearjournal
  118. endif
  119. if @injournal 'some ash' 'system'
  120. headmsg '--ASH--' '1191'
  121. clearjournal
  122. endif
  123. if @injournal 'some yew' 'system'
  124. headmsg '--YEW--' '1192'
  125. msg '[e ah'
  126. clearjournal
  127. endif
  128. if @injournal 'some heartwood' 'system'
  129. headmsg '>!!!--HEARTWOOD--!!!<' '1193'
  130. msg '[e yea'
  131. clearjournal
  132. endif
  133. if @injournal 'some bloodwood' 'system'
  134. headmsg '>!!!--BLOODWOOD--!!!<' '1194'
  135. msg '[e woohoo'
  136. clearjournal
  137. endif
  138. if @injournal 'some frostwood' 'system'
  139. headmsg '>!!!--FROSTWOOD--!!!<' '1151'
  140. msg '[e woohoo'
  141. clearjournal
  142. endif
  143. //******************************************
  144. //
  145. //
  146. endwhile
  147. headmsg 'Over Weight Fatty !' '89'
  148. headmsg 'go home and unload!' '89'
  149. if @findtype '0x1bdd' 'any' 'backpack' 'any' 'any'
  150. @setalias 'Logs' 'Found'
  151. useobject 'LeftHand'
  152. autotargetobject 'Logs'
  153. pause 1000
  154. endif
Add Comment
Please, Sign In to add comment