Advertisement
Guest User

Untitled

a guest
Aug 16th, 2017
57
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 4.93 KB | None | 0 0
  1. ;==================================
  2. ; Script Name: Mine All Can See
  3. ; Author: Vostran
  4. ; Version: 1.0.3 (stripped and released)
  5. ; Client Tested with: 3.0.0c
  6. ; EUO version tested with: 1.33
  7. ; Shard OSI / FS: Free Shard (Deusovis)
  8. ; Revision Date: 08th Febuary 2004
  9. ; Public Release: 17th January 2004
  10. ; Global Variables Used: none
  11. ; Purpose: Written specifically for a Deusovis, it mines all the ore from a cave floor, stopping when you're full. It's intentionally simple and should remain that way.
  12. ;==================================
  13. initialise:
  14. initevents
  15. config:
  16. ; This can be set a few ways, remember to comment out the way you don't want it set. Must be set atleast one way.
  17. ; set %maxweight #maxweight - 50
  18. ; set %maxweight 300
  19. set %maxweight #maxweight
  20.  
  21. ; if raresonly is 1 then it will ignore the lesser ores and gold coins it finds, soon gems to.
  22. set %raresonly 0
  23. ; if raresonly is 1 then these will determine which ores are not skipped, set to -1 to skip, 1 to mine.
  24. set %rusty -1
  25. set %iron -1
  26. set %copper -1
  27. set %bronze -1
  28. set %silver -1
  29. set %pure -1
  30.  
  31. ; Set this option to halt once you mined the 9x9 box you're standing in, so you can move and press play again to continue.
  32. set %pausePerPass 0
  33.  
  34. ; Will attempt to hide if this is 1.
  35. set %hide 0
  36.  
  37. ; Higher number for busier mines.
  38. set %scanjournalloops 100
  39.  
  40. start:
  41. gosub mineallhere
  42. goto start
  43.  
  44. sub mineallhere
  45. for %mineloopX -4 4
  46. {
  47. for %mineloopY -4 4
  48. {
  49. set %mineX #CHARPOSX
  50. set %mineY #CHARPOSY
  51. set %mineX %mineX + %mineloopX
  52. set %mineY %mineY + %mineloopY
  53. event sysMessage %mineX %mineY
  54. gosub mineXY %mineX %mineY
  55. if #weight > %maxweight
  56. {
  57. gosub hide
  58. halt
  59. }
  60. }
  61. }
  62. if %pausePerPass = 1
  63. {
  64. event sysMessage Pausing because we've mined this area dry.
  65. gosub hide
  66. pause
  67. }
  68. return
  69. sub mineXY
  70. set %success 1
  71. for %mineloop 1 -1
  72. {
  73. gosub hide
  74. finditem NPF_TWF_QPF_WWF
  75. set #lobjectid #findid
  76. event macro 17 0
  77. set #lTargetKind 2
  78. set #lTargetX %1
  79. set #lTargetY %2
  80. target
  81. event macro 22
  82. scanJournal 0
  83. deleteJournal
  84. event sysMessage
  85. wait 20
  86. for %journalloop 0 %scanjournalloops
  87. {
  88. scanjournal %journalloop
  89. if there_is_no_ore_here in #journal
  90. {
  91. set %journalloop %scanjournalloops
  92. set %mineloop -1
  93. set %success 0
  94. }
  95. if that_is_too_far_away in #journal
  96. {
  97. set %journalloop %scanjournalloops
  98. set %mineloop -1
  99. set %success 0
  100. }
  101. if no_line_of_sight in #journal
  102. {
  103. set %journalloop %scanjournalloops
  104. set %mineloop -1
  105. set %success 0
  106. }
  107. if try_mining_in_rock in #journal
  108. {
  109. set %journalloop %scanjournalloops
  110. set %mineloop -1
  111. set %success 0
  112. }
  113. }
  114. if %success = 1
  115. {
  116. wait 130
  117. for %journalloop 0 %scanjournalloops
  118. {
  119. scanjournal %journalloop
  120. if you_loosen_some_rocks_but_fail in #journal
  121. {
  122. set %journalloop %scanjournalloops
  123. set %mineloop 1
  124. }
  125. if you_put_the in #journal
  126. {
  127. set %journalloop %scanjournalloops
  128. set %mineloop 1
  129. if %raresonly = 1
  130. {
  131. if rusty in #journal
  132. {
  133. set %mineloop %rusty
  134. }
  135. if iron in #journal
  136. {
  137. set %mineloop %iron
  138. }
  139. if copper in #journal
  140. {
  141. if chrome notin #journal
  142. {
  143. set %mineloop %copper
  144. }
  145. }
  146. if bronze in #journal
  147. {
  148. set %mineloop %bronze
  149. }
  150. if silver in #journal
  151. {
  152. set %mineloop %silver
  153. }
  154. if pure in #journal
  155. {
  156. set %mineloop %pure
  157. }
  158. if gold_coin_in in #journal
  159. {
  160. set %mineloop -1
  161. }
  162. }
  163. }
  164. if previous_targeting_cancelled in #journal
  165. {
  166. set %journalloop %scanjournalloops
  167. set %mineloop 1
  168. }
  169. }
  170. }
  171. }
  172. return
  173. sub hide
  174. if %hide = 1
  175. {
  176. if H notin #charstatus
  177. {
  178. event macro 13 21
  179. wait 65
  180. gosub hide
  181. }
  182. }
  183. return
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement