changeset 300:bc1f62b269b5

found program that works as valid items, but now the program is too long...
author Robert McIntyre <rlm@mit.edu>
date Fri, 30 Mar 2012 23:05:38 -0500
parents eb8d1d7941ec
children 1de6aada1cb7
files clojure/com/aurellem/exp/notes.txt
diffstat 1 files changed, 31 insertions(+), 49 deletions(-) [+]
line wrap: on
line diff
     1.1 --- a/clojure/com/aurellem/exp/notes.txt	Fri Mar 30 22:48:31 2012 -0500
     1.2 +++ b/clojure/com/aurellem/exp/notes.txt	Fri Mar 30 23:05:38 2012 -0500
     1.3 @@ -2,8 +2,8 @@
     1.4  
     1.5  start game
     1.6  
     1.7 -name rival "<space><PK>G<PK>G<PK>" 
     1.8 -(0x7F 0xE1 0x86 0xE1 0x86 0xE1 in character codes)
     1.9 +name rival "L<PK>T<PK>" 
    1.10 +(0x8B 0xE1 0x93 0xE1 in character codes)
    1.11  
    1.12  get pikachu, fight rival, deliver oak's parcel, go back to
    1.13  viridian poke mart.
    1.14 @@ -16,7 +16,7 @@
    1.15  
    1.16  buy a pokeball to repair item-list
    1.17  
    1.18 -buy 1 pokeball, 1 potion, 1 antidote, 1 parlyz heal, and
    1.19 +buy 1 potion, 1 antidote, 1 parlyz heal, 2 pokeballs, and
    1.20  96 burn heals
    1.21  
    1.22  95 burn heals spells out the address that will safely return
    1.23 @@ -34,55 +34,9 @@
    1.24  0x01
    1.25  [end repeat]
    1.26  
    1.27 -0x00
    1.28 -0xFA          -- first part of "Load A from Literal address"
    1.29 -
    1.30 -third rival's name character
    1.31 -xD5           -- target item address
    1.32 -
    1.33 -0x00
    1.34 -0x3C          -- increment A register
    1.35 -
    1.36 -0x00
    1.37 -0xEA          -- first part of "Save A to literal address"
    1.38 -
    1.39 -fifth rival's name character
    1.40 -xD5           -- target item address
    1.41 -
    1.42 -0x00
    1.43 -0xC3          -- first part of "Absolute Jump to literal address"
    1.44 -
    1.45 -burn-heal
    1.46 -x 95          -- address of Route 3 memory-function
    1.47 -
    1.48 -0x00
    1.49 -0x??
    1.50 -
    1.51 -Drop enough from rival's first character/ second character
    1.52 -as an item so that it is [0x7F 0xD5] instead of [0x7F 0xE1].
    1.53 -
    1.54 -shift rival's name's first two characters into
    1.55 -mem-function-address.
    1.56 -
    1.57 -now close the menu and continue item manipulations using the
    1.58 -newly constructed program.  Starting and then canceling the
    1.59 -start menu activates the program.
    1.60 -
    1.61 -**********  END Game Sequence
    1.62 -
    1.63 -
    1.64 -
    1.65 -
    1.66 -[repeat 35 times]
    1.67 -0xFF
    1.68 -0x01
    1.69 -[end repeat]
    1.70 -
    1.71 -
    1.72  ;;; program to swap item ID and quantity at fixed address.
    1.73  ;; here target is equal to rival's thrid and fourth character
    1.74  
    1.75 -
    1.76  0x00
    1.77  0x21  ;; load target into HL
    1.78  
    1.79 @@ -90,6 +44,15 @@
    1.80  xD5     -- target item address
    1.81  
    1.82  0x00
    1.83 +0x18  ;; jump relative
    1.84 +
    1.85 +pokeball ;; pokeball = 0x04, so
    1.86 +x any    ;; jump over the next four bytes
    1.87 +
    1.88 +target-item type
    1.89 +target-item quantity
    1.90 +
    1.91 +0x00
    1.92  0x2A  ;; save (HL)=(target) to A, increment HL
    1.93  
    1.94  0x00
    1.95 @@ -104,12 +67,31 @@
    1.96  0x00
    1.97  0x70  ;; load B into target+1 [(target) -> target+1]
    1.98  
    1.99 +0x00
   1.100 +0xC3  ;; first part of absolute jump
   1.101  
   1.102 +burn-heal
   1.103 +x 95          -- address of Route 3 memory-function
   1.104  
   1.105  
   1.106 +Drop enough from rival's first character/ second character
   1.107 +as an item so that it is [_ 0xD5] instead of [_ 0xE1].
   1.108  
   1.109 +shift rival's name's first two characters into
   1.110 +mem-function-address.
   1.111  
   1.112 +now close the menu and continue item manipulations using the
   1.113 +newly constructed program.  Starting and then canceling the
   1.114 +start menu activates the program.
   1.115  
   1.116 +**********  END Game Sequence
   1.117 +
   1.118 +
   1.119 +
   1.120 +
   1.121 +
   1.122 +
   1.123 +************  Misc Notes.
   1.124  
   1.125  valid start addresses for the initial bootstrap program are
   1.126  the following: