comparison clojure/com/aurellem/exp/notes.txt @ 293:4a0dbaed7078

preliminary idea for a better pre-bootstrapping program.
author Robert McIntyre <rlm@mit.edu>
date Fri, 30 Mar 2012 18:14:14 -0500
parents dc9a0060e7cb
children d35683bfc15f
comparison
equal deleted inserted replaced
291:c8b0db518de3 293:4a0dbaed7078
71 ********** END Game Sequence 71 ********** END Game Sequence
72 72
73 73
74 74
75 75
76 [repeat 35 times]
77 0xFF
78 0x01
79 [end repeat]
80
81
82 ;;; program to swap item ID and quantity at fixed address.
83 ;; here target is equal to rival's thrid and fourth character
84
85
86 0x00
87 0x21 ;; load target into HL
88
89 third rival's name character
90 xD5 -- target item address
91
92 0x00
93 0x2A ;; save (HL)=(target) to A, increment HL
94
95 0x00
96 0x78 ;; save A to B
97
98 0x00
99 0x3A ;; save (target+1) to A, decrement HL
100
101 0x00
102 0x22 ;; save A to target, increment HL [(target+1) -> target]
103
104 0x00
105 0x78 ;; load B to A
106
107 0x00
108 0x77 ;; load A into target+1 [(target) -> target+1]
109
110
111
76 112
77 113
78 114
79 115
80 116
82 the following: 118 the following:
83 119
84 0xD31D - 0xD41B 120 0xD31D - 0xD41B
85 --OR-- 121 --OR--
86 0xD53A - 0XD59C 122 0xD53A - 0XD59C
87
88
89
90
91