# HG changeset patch # User Robert McIntyre # Date 1333170339 18000 # Node ID 0b3e89103dc2557bfe741baf6bd52d1794d0b09c # Parent 1de6aada1cb78a0c8707bfcc5df9b649c7816f66 going to test bootstrapping program. diff -r 1de6aada1cb7 -r 0b3e89103dc2 clojure/com/aurellem/exp/notes.txt --- a/clojure/com/aurellem/exp/notes.txt Fri Mar 30 23:39:58 2012 -0500 +++ b/clojure/com/aurellem/exp/notes.txt Sat Mar 31 00:05:39 2012 -0500 @@ -2,8 +2,8 @@ start game -name rival "LT" -(0x8B 0xE1 0x93 0xE1 in character codes) +name rival "LU" +(0x8B 0xE1 0x94 0xE1 in character codes) get pikachu, fight rival, deliver oak's parcel, go back to viridian poke mart. @@ -29,7 +29,7 @@ pattern in the item computer. You can do this with what is in your item list because of the previous setup. -[repeat the following 24 times] +[repeat the following 25 times] 0xFF 0x01 [end repeat] @@ -55,18 +55,18 @@ 0x00 0xC3 ;; first part of absolute jump -burn-heal -x 95 -- address of Route 3 memory-function +burn-heal (0x0C) +x 95 (0x5F) -- address of Route 3 memory-function [repeat the following 8 times] 0xFF 0x01 [end repeat] -0x00 ;; this starts at address 0xD58B +0x00 ;; this starts at address 0xD58A 0x21 ;; load target into HL -third rival's name character +third rival's name character (U == 0x94) x D5 -- target item address 0x00 @@ -75,8 +75,11 @@ fifth rival's name character (PK) (TM25) (0xE1 == -31) x any -target-item type -target-item quantity +0xFF +0x01 + +target-item type (at 0xD594) +target-item quantity (at 0xD595) diff -r 1de6aada1cb7 -r 0b3e89103dc2 clojure/com/aurellem/run/bootstrap_0.clj --- a/clojure/com/aurellem/run/bootstrap_0.clj Fri Mar 30 23:39:58 2012 -0500 +++ b/clojure/com/aurellem/run/bootstrap_0.clj Sat Mar 31 00:05:39 2012 -0500 @@ -784,3 +784,57 @@ (do-nothing 1)))) + +(defn test-pc-item-program [] + (-> (read-state "bootstrap-init") + (set-memory pc-item-list-start 50) + (set-memory-range + + (inc pc-item-list-start) + (flatten + [ + (repeat + 25 + [0xFF 0x01]) + [0x00 ;; second part of item manipulation program + 0x2A + + 0x00 + 0x47 + + 0x00 + 0x3A + + 0x00 + 0x22 + + 0x00 + 0X70 + + 0x00 + 0xC3 + + 0x0C + 0x5F] + (repeat + 8 + [0xFF 0x01]) + + [0x00 + 0x21 + + 0x93 + 0xD5 + + 0x00 + 0x18 + + 0xE1 + 0x01 + + 0xFF + 0x01 + + 0x04 ;; target ID + 0x3E ;; target Quantity + ]]))))