Advertisement
Guest User

Untitled

a guest
Aug 20th, 2019
106
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 4.20 KB | None | 0 0
  1. def stand()
  2. return if dead?
  3. fput 'stand' until standing?
  4. end
  5.  
  6. PRONE = /sleeping|webbed|stunned|kneeling|sitting|^lying|prone/
  7.  
  8. def lounge()
  9. while (percentencumbrance > 10) do
  10. echo "You're too fat to hunt, lighten up!"
  11. break
  12. kill_script ("pheist")
  13. end
  14. if Room.current.id == 27161
  15. start_script "go2", ['27160']
  16. wait_while { running? 'go2' }
  17. fput "stow all"
  18. fput "get booklet from my #{Vars.bookletsack}"
  19. fput "go bandit"
  20. fput "put booklet in my #{Vars.bookletsack}"
  21. fput "gird"
  22. end
  23. end
  24.  
  25. activespells = Array['9903','9904','9907','9908','9912','9913','909','515']
  26.  
  27. def spellcheck(thesespells)
  28. thesespells.each { |nextspell|
  29. waitrt?
  30. waitcastrt?
  31. if nextspell == "909"
  32. fput("incant #{nextspell}") if !Spell[nextspell.to_i].active? && Spell[nextspell.to_i].affordable? && Spell[nextspell.to_i].known?
  33. waitcastrt?
  34. elsif nextspell == "515"
  35. fput("incant #{nextspell}") if !Spell[nextspell.to_i].active? && Spell[nextspell.to_i].affordable? && Spell[nextspell.to_i].known?
  36. else
  37. Spell[nextspell.to_i].cast if !Spell[nextspell.to_i].active? && Spell[nextspell.to_i].affordable? && Spell[nextspell.to_i].known?
  38. end
  39. }
  40. end
  41.  
  42. def symbol()
  43. Spell[9903].cast if !Spell[9903].active? && Spell[9903].affordable? && Spell[9903].known?
  44. Spell[9904].cast if !Spell[9904].active? && Spell[9904].affordable? && Spell[9904].known?
  45. Spell[9907].cast if !Spell[9907].active? && Spell[9907].affordable? && Spell[9907].known?
  46. Spell[9908].cast if !Spell[9908].active? && Spell[9908].affordable? && Spell[9908].known?
  47. Spell[9912].cast if !Spell[9912].active? && Spell[9912].affordable? && Spell[9912].known?
  48. Spell[9913].cast if !Spell[9913].active? && Spell[9913].affordable? && Spell[9913].known?
  49.  
  50. end
  51. start_script("go2", ["27160"])
  52. wait_while {running?("go2")}
  53. pause 0.5
  54. if Room.current.id == 27160
  55. fput "stow all"
  56. fput "look at book"
  57. pause 0.5
  58. echo " ***PAUSE ME NOW IF YOU WANT TO STOP LEAVING IN 10 SECONDS *******"
  59. echo " ***PAUSE ME NOW IF YOU WANT TO STOP LEAVING IN 10 SECONDS *******"
  60. sleep 10
  61. result = dothistimeout("get my booklet", 5, /You remove|Get what\?/)
  62. if result =~ /You remove/
  63. fput "go bandit"
  64. fput "put my booklet in my #{Vars.bookletsack}"
  65. elsif result =~ /Get what\?/
  66. respond 'Out of booklets!'
  67. kill_script ("pheist")
  68. end
  69. fput "gird"
  70.  
  71. else
  72. lounge()
  73. end
  74. loop {
  75. 5.times{
  76. spellcheck(activespells)
  77. waitrt?
  78. waitcastrt?
  79. fput "gird"
  80. if Spell[916].known?
  81. Spell[916].cast if !Spell[916].active? && Spell[916].affordable? && Spell[916].known?
  82. else
  83. nil
  84. end
  85. waitrt?
  86. waitcastrt?
  87. result = dothistimeout("observe", 5, /The maruaders are hot on your trail\, perhaps pace around to make some extra footprints\!|strides in|stride in/)
  88. if result =~ /The maruaders are hot on your trail\, perhaps pace around to make some extra footprints\!/
  89. waitrt?
  90. fput "pace"
  91. waitrt?
  92. fput "steal"
  93. sleep 3.0
  94. waitrt?
  95. if checkright == "runestaff"
  96. nil
  97. else
  98. fput "put ##{GameObj.left_hand.id} in my #{Vars.lootsack}"
  99. end
  100. sleep 3.0
  101. break
  102.  
  103. elsif result =~ /strides in|stride in/
  104. end
  105. sleep 0.1
  106. waitrt?
  107. waitcastrt?
  108. wait_while{ stunned? }
  109. target = GameObj.npcs.find{ |npc| npc.name =~ // }
  110. while GameObj.npcs.size > 0
  111. target = GameObj.npcs.find{ |npc| npc.name =~ // if npc.status !~ /dead|gone/ }
  112. waitrt? if !(target.status =~ /dead|gone/)
  113. waitcastrt? if !(target.status =~ /dead|gone/)
  114. while target.status !~ /dead|gone/
  115. if !(target.status =~ /dead|gone/)
  116. start_script "bigshot", [ "quick" ]
  117. wait_while {running?("bigshot")}
  118. end
  119. end
  120. end
  121. waitrt?
  122. waitcastrt?
  123. fput "stance defensive"
  124. if !Room.current.id == 23733
  125. fput "steal"
  126. sleep 3.0
  127. waitrt?
  128. if checkright == "runestaff"
  129. nil
  130. else
  131. fput "put ##{GameObj.left_hand.id} in my #{Vars.lootsack}"
  132. end
  133.  
  134. else
  135. fput "steal"
  136. sleep 3.0
  137. waitrt?
  138. if checkright == "runestaff"
  139. nil
  140. else
  141. fput "put ##{GameObj.left_hand.id} in my #{Vars.lootsack}"
  142. end
  143. if checkleft
  144. fput "put ##{GameObj.left_hand.id} in my #{Vars.lootsack}"
  145. end
  146. break
  147. end
  148. sleep 1.0
  149. }
  150. sleep 3.0
  151. lounge()
  152. sleep 1.0
  153.  
  154. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement