# HG changeset patch # User Robert McIntyre # Date 1333995694 18000 # Node ID 845b2d88bef9eddf65ecb715bc0314b5f593c66a # Parent 985e910605674352e3b4c232cd32fd02b13dd83d script: item-program completely deposited. Will test tomorrow :) diff -r 985e91060567 -r 845b2d88bef9 clojure/com/aurellem/run/bootstrap_1.clj --- a/clojure/com/aurellem/run/bootstrap_1.clj Mon Apr 09 12:34:29 2012 -0500 +++ b/clojure/com/aurellem/run/bootstrap_1.clj Mon Apr 09 13:21:34 2012 -0500 @@ -130,7 +130,7 @@ 0xE9 ;; jump to (HL) ]]))) -(defn view-desired-item-layout [] +(defn print-desired-item-layout [] (clojure.pprint/pprint (raw-inventory->inventory (pc-item-writer-program)))) @@ -749,20 +749,73 @@ (deposit-held-item 13 191) (deposit-held-item-named :TM02 98) (deposit-held-item-named :TM09 1) + close-menu close-menu))) (defn-memo hacking-11 ([] (hacking-11 (hacking-10))) ([script] (->> script - to-held-items - (toss-held-item 17 1) - (toss-held-item 17 1) - (toss-held-item 17 1) - (toss-held-item 17 1) - (toss-held-item 17 1) + begin-withdraw + (widthdraw-pc-item 3 0xFE) + (widthdraw-pc-item 4 0xFE) + (widthdraw-pc-item 5 1) + (widthdraw-pc-item 5 1) + (widthdraw-pc-item 5 1) + (widthdraw-pc-item 5 0xFB) + (multiple-times + 3 + (partial combine-items 2)) + close-menu))) + +(defn-memo hacking-12 + ([] (hacking-12 (hacking-11))) + ([script] + (->> script + begin-deposit + (deposit-held-item 18 203) + (deposit-held-item-named :guard-spec 87) + (deposit-held-item-named :guard-spec 24) + (deposit-held-item-named :TM05 1) + (multiple-times + 8 + (partial deposit-held-item 14 2)) + (deposit-held-item 14 55) + (deposit-held-item-named :x-accuracy 58) + (deposit-held-item 14 38) + (deposit-held-item-named :TM13 1) + (deposit-held-item 13 1) + (deposit-held-item 13 233) close-menu close-menu))) + + +(defn toss-pc-item [n quantity [moves state :as script]] + (let [total-quantity (second (nth-pc-item state n))] + (->> script + (set-cursor n) + (select-menu-entry 1) + (wait-for-quantity) + (set-quantity total-quantity quantity) + (delayed-difference [] [:a] 100 #(search-string % "Is")) + (scroll-text) + select-menu-entry + (scroll-text)))) + +(defn hacking-13 + ([] (hacking-13 (hacking-12))) + ([script] + (->> script + (set-cursor-relative 1) + (select-menu-entry) + (toss-pc-item 1 1) + (toss-pc-item 0 156) + (toss-pc-item 0 11) + close-menu))) + + + +