Shroomism

vault.cmd

Sep 19th, 2018
187
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.91 KB | None | 0 0
  1. #################################################
  2. # VAULT script by Shroom of TF
  3. # Auto-enter vault and looks inside
  4. # Waits for you to be done
  5. # Type "DONE" to auto-leave vault
  6. # Pays your rent if needed
  7. # Start inside any city you own a vault
  8. ##############################################
  9. action goto VAULT when The attendant bursts into the chamber
  10. if contains("$roomname", "Carousel Chamber") then goto VAULT.LOOK
  11. gosub automove vault
  12. pause 0.4
  13. pause 0.2
  14. if contains("$roomname", "Carousel Desk") then put out
  15. pause 0.1
  16. if contains("$roomobjs", "Carousel Square") then put go square
  17. pause 0.1
  18. pause 0.1
  19. if contains("$roomname", "Carousel Desk") then put out
  20. pause 0.1
  21. if contains("$roomobjs", "vault") then put go vault
  22. pause 0.1
  23. pause 0.1
  24. put go door
  25. pause 0.1
  26. pause 0.1
  27. pause 0.1
  28. VAULT:
  29. 1.ARCH:
  30. matchre PAY.RENT rent
  31. matchre VAULT.GO escorts you
  32. matchre 2.ARCH blocks|someone|using|Sorry
  33. put go arch
  34. matchwait
  35. 2.ARCH:
  36. matchre PAY.RENT rent
  37. matchre VAULT.GO escorts you
  38. matchre 3.ARCH blocks|someone|using|Sorry
  39. put go second arch
  40. matchwait
  41. 3.ARCH:
  42. matchre PAY.RENT rent
  43. matchre VAULT.GO escorts you
  44. matchre NO.ARCH blocks|someone|using|Sorry
  45. put go third arch
  46. matchwait
  47. NO.ARCH:
  48. echo NO ARCH AVAILABLE! WAITING....
  49. pause 10
  50. goto 1.ARCH
  51.  
  52. PAY.RENT:
  53. echo ======================
  54. echo ** PAYING VAULT RENT
  55. echo ======================
  56. pause 0.2
  57. gosub automove teller
  58. send with 8 gold
  59. pause 0.1
  60. pause 0.1
  61. pause 0.1
  62. gosub automove exchange
  63. put exchan all dok to kro
  64. put exchan all lir to kro
  65. pause 0.1
  66. pause 0.1
  67. if ("$zoneid" = "67") then gosub automove 138
  68. if ("$zoneid" = "116") then gosub automove 288
  69. if ("$zoneid" = "61") then gosub automove 169
  70. if ("$zoneid" = "47") then gosub automove 273
  71. if ("$zoneid" = "42") then gosub automove 28
  72. if ("$zoneid" = "30") then gosub automove 362
  73. if ("$zoneid" = "1") then gosub automove 188
  74. if ("$zoneid" = "99") then gosub automove 141
  75. if ("$zoneid" = "107") then gosub automove 219
  76. if ("$zoneid" = "90") then gosub automove 261
  77. if ("$zoneid" = "127") then gosub automove 532
  78. put pay 5000
  79. pause 0.1
  80. pause 0.1
  81. move out
  82. goto 1.ARCH
  83.  
  84. VAULT.GO:
  85. put pull lever
  86. pause 0.2
  87. pause 0.2
  88. send go door
  89. pause 0.2
  90. pause 0.2
  91. pause 0.1
  92. send open vault
  93. pause 0.1
  94. pause 0.1
  95. echo =================================
  96. echo *** VAULT SCRIPT ACTIVE
  97. echo *** TYPE "DONE" to LEAVE VAULT!
  98. echo =================================
  99. VAULT.LOOK:
  100. send rummage vault
  101. pause 0.2
  102. pause 0.2
  103. pause 0.1
  104. send rumm on shelf
  105. pause 0.1
  106. pause 0.1
  107. send rumm on second shelf
  108. pause 0.1
  109. send rumm on hook
  110. pause 0.2
  111. pause 0.2
  112. echo =================================
  113. echo *** VAULT SCRIPT ACTIVE
  114. echo *** TYPE DONE or done to LEAVE VAULT
  115. echo =================================
  116. put #parse VAULT
  117. matchre VAULT.LEAVE DONE
  118. matchre VAULT.LEAVE done
  119. matchwait 110
  120. goto VAULT.LOOK
  121.  
  122. VAULT.LEAVE:
  123. echo
  124. echo LEAVING VAULT!
  125. echo
  126. pause 0.1
  127. pause 0.1
  128. put close vault
  129. pause 0.4
  130. pause 0.2
  131. put go door
  132. pause 0.4
  133. pause 0.3
  134. put go arch
  135. pause 0.5
  136. pause 0.1
  137. move out
  138. pause 0.3
  139. pause 0.2
  140. put out
  141. pause 0.2
  142. pause 0.1
  143. VAULT.DONE:
  144. echo
  145. echo *** DONE WITH VAULT SCRIPT!
  146. echo
  147. exit
  148.  
  149. AUTOMOVE:
  150. delay 0.0001
  151. var Destination $0
  152. var automovefailCounter 0
  153. if (!$standing) then gosub AUTOMOVE_STAND
  154. if ("$roomid" = "%Destination") then return
  155. AUTOMOVE_GO:
  156. delay 0.0001
  157. matchre AUTOMOVE_FAILED ^(?:AUTOMAPPER )?MOVE(?:MENT)? FAILED
  158. matchre AUTOMOVE_RETURN ^YOU HAVE ARRIVED(?:\!)?
  159. matchre AUTOMOVE_RETURN ^SHOP CLOSED(?:\!)?
  160. matchre AUTOMOVE_FAIL_BAIL ^DESTINATION NOT FOUND
  161. put #goto %Destination
  162. matchwait 10
  163. if ($north) then put n
  164. if ($south) then put s
  165. if ($east) then put e
  166. if ($west) then put w
  167. if ($northeast) then put ne
  168. if ($northwest) then put nw
  169. if ($southwest) then put sw
  170. pause 0.5
  171. pause 0.3
  172. goto AUTOMOVE_GO
  173. AUTOMOVE_STAND:
  174. pause 0.1
  175. matchre AUTOMOVE_STAND ^\.\.\.wait|^Sorry\,
  176. matchre AUTOMOVE_STAND ^Roundtime\:?|^\[Roundtime\:?|^\(Roundtime\:?
  177. matchre AUTOMOVE_STAND ^The weight of all your possessions prevents you from standing\.
  178. matchre AUTOMOVE_STAND ^You are still stunned\.
  179. matchre AUTOMOVE_RETURN ^You stand(?:\s*back)? up\.
  180. matchre AUTOMOVE_RETURN ^You are already standing\.
  181. send stand
  182. matchwait
  183. AUTOMOVE_FAILED:
  184. evalmath automovefailCounter (automovefailCounter + 1)
  185. if (%automovefailCounter > 5) then goto AUTOMOVE_FAIL_BAIL
  186. send #mapper reset
  187. pause 0.5
  188. pause 0.1
  189. goto AUTOMOVE_GO
  190. AUTOMOVE_FAIL_BAIL:
  191. put #echo
  192. put #echo >$Log Crimson *** AUTOMOVE FAILED. ***
  193. put #echo >$Log Destination: %Destination
  194. put #echo Crimson *** AUTOMOVE FAILED. ***
  195. put #echo Crimson Destination: %Destination
  196. put #echo
  197. exit
  198. AUTOMOVE_RETURN:
  199. return
Advertisement
Add Comment
Please, Sign In to add comment