# HG changeset patch # User Robert McIntyre # Date 1332637585 18000 # Node ID 30ced394823a8438140e8147bb849b143898daa3 # Parent 5becef6312b97ca01ead8a850b3724503b82c6ec# Parent 00e4efa7c1040ece15fdd4f07aa5777791b654b5 merge. diff -r 5becef6312b9 -r 30ced394823a clojure/com/aurellem/gb/characters.clj --- a/clojure/com/aurellem/gb/characters.clj Sat Mar 24 20:05:47 2012 -0500 +++ b/clojure/com/aurellem/gb/characters.clj Sat Mar 24 20:06:25 2012 -0500 @@ -17,6 +17,44 @@ :n-times [0x50 0x09 0x05 0xCD 0x11 0x0] }) + + +(def meta-characters + {0x00 "non-meta text follows" + 0x01 "load text from RAM (nn)" + 0x02 "BCD number (nn)C" ;; C is 3 flags and 5 length bits." + 0x03 "store text in RAM (nn)" + 0x04 "draw box (nn)WH" + 0x05 "BEGIN text on textbox line 2" + 0x06 "wait for A or B" + 0x07 "scrolling text" + 0x08 "BEGIN routine" + 0x09 "load RAM (nn) hex-to-dec. (nn)BC. B is bytes to read, C is + digits to display" + 0x0A "wait 30 vblanks iff you pressed A or B" + + 0x0B "sound: got item" + 0x0E "sound: learned skill" + 0x0F "sound: got rarecandy" ;; incidentally, same as 'got item' + 0x10 "sound: caught pokemon!" + 0x11 "sound: gave OAK the parcel" + 0x12 "sound: same as 0x10???" + 0x13 "sound: new data added" + 0x14 "sound: cry-nidorina" + 0x15 "sound: cry-pidgeot" + 0x16 "sound: cry-dewgong" + + 0x4E "new line" + 0x51 "new page" + 0x55 "scroll page" + 0x50 "END command" ;; the pair 0x50 0x50 ?? + 0x57 "END command" + 0x58 "END after you press A or B" + }) + + + + (def end-of-name-sentinel 0x00) (def character-code->character