annotate org/rom.org @ 320:9637a0f52e7b

located item-list related addresses.
author Robert McIntyre <rlm@mit.edu>
date Tue, 03 Apr 2012 23:17:33 -0500
parents 2060219691fa
children 5639312a393f
rev   line source
ocsenave@311 1 #+title: Notes on Deconstructing Pokemon Yellow
ocsenave@311 2 #+author: Dylan Holmes
ocsenave@311 3 #+email: rlm@mit.edu
ocsenave@311 4 #+description:
ocsenave@312 5 #+keywords:
ocsenave@311 6 #+SETUPFILE: ../../aurellem/org/setup.org
ocsenave@311 7 #+INCLUDE: ../../aurellem/org/level-0.org
ocsenave@311 8 #+BABEL: :exports both :noweb yes :cache no :mkdirp yes
ocsenave@311 9
ocsenave@312 10
ocsenave@312 11 # pokedollar: U+20B1
ocsenave@311 12 * Mapping the ROM
ocsenave@311 13
ocsenave@311 14 | ROM address (hex) | Description | Format | Example |
ocsenave@311 15 |-------------------+-----------------+-----------------+-----------------|
ocsenave@311 16 | | <15> | <15> | <15> |
ocsenave@312 17 | 0233C- | Shop inventories. | | |
ocsenave@312 18 | 04495- | Prices of items. | Each price is two bytes of binary-coded decimal. Prices are separated by zeroes. Priceless items[fn::Like the Pok\eacute{}dex and other unsellable items.] are given a price of zero. | The cost of lemonade is 0x03 0x50, which translates to a price of ₱350. |
ocsenave@311 19 | 045B7-0491E | Names of the items in memory. | Variable-length item names (strings of character codes). Names are separated by a single 0x80 character. | MASTER BALL#ULTRA BALL#... |
ocsenave@312 20 | 04D89- | Lists of wild Pok\eacute{}mon to encounter in each region. | Each list contains ten Pokemon (ids) and their levels; twenty bytes in total. First, the level of the first Pokemon. Then the internal id of the first Pokemon. Next, the level of the second Pokemon, and so on. Since Pokemon cannot have level 0, the lists are separated by a pair 0 /X/, where /X/ is an apparently random Pokemon id. | The first list is (3 36 4 36 2 165 3 165 2 36 3 36 5 36 4 165 6 36 7 36 0 25), i.e. level 3 pidgey, level 4 pidgey, level 2 rattata, level 3 rattata, level 2 pidgey, level 3 pidgey, level 5 pidgey, level 4 rattata, level 6 pidgey, level 7 pidgey, level 0 end-of-list. |
ocsenave@311 21 | 05EDB. | Which Pok\eacute{}mon to show during Prof. Oak's introduction. | A single byte, the Pok\eacute{}mon's internal id. | In Pok\eacute{}mon Yellow, it shows Pikachu during the introduction; Pikachu's internal id is 0x54. |
ocsenave@312 22 | 06698- | ? Background music. | | |
ocsenave@312 23 | 0822E-082F? | Pointers to background music, part I. | | |
ocsenave@312 24 | 0CB95- | Pointers to lists of wild pokemon to encounter in each region. These lists begin at 04D89, see above. | Each pointer is a low-byte, high-byte pair. | The first entry is 0x89 0x4D, corresponding to the address 0x4D89, the location of the first list of wild Pok\eacute{}mon (see above). |
ocsenave@312 25 | 1232D- | Which moves are taught by the TMs and HMs | | |
ocsenave@311 26 | 27D99-27DFF | Names of the Pok\eacute{}mon types. | Variable-length type names (strings of character codes). Names are separated by a single 0x80 character. | NORMAL#FIGHTING#... |
ocsenave@312 27 | 27E77- | Trainer title names. | | YOUNGSTER#BUG CATCHER#LASS#... |
ocsenave@312 28 | 34000- | Evolution and learnset data. | | |
ocsenave@312 29 | 38000- | The basic properties and effects of moves. | Fixed-length (6 byte) continguous descriptions (no separating character): move-index, move-effect, power, move-type, accuracy, pp. | The entry for Pound, the first attack in the list, is (1 0 40 0 255 35). See below for more explanation. |
ocsenave@312 30 | 383DE- | Species data for the Pokemon, listed in Pokedex order: Pokedex number; base moves; types; learnable TMs and HMs; base HP, attack, defense, speed, special; sprite data. | | |
ocsenave@311 31 | 39462- | The Pok\eacute{}mon cry data. | Fixed-length (3 byte) descriptions of cries. | |
ocsenave@312 32 | 3B1E5- | Pointers to evolution/learnset data. | | |
ocsenave@311 33 | 40687- | Species data from the Pok\eacute{}dex: species name, height, weight, etc. | Fixed-length sequences of bytes. See below for specifics. | |
ocsenave@312 34 | 410B1- | A conversion table between internal order and Pokedex order. | | |
ocsenave@312 35 | 71500- | Names of places. | | |
ocsenave@312 36 | 7C249-7C2?? | Pointers to background music, pt II. | | |
ocsenave@312 37 | 98000- | Dialogue | | |
ocsenave@312 38 | B8000- | The text of each Pokemon's Pok\eacute{}dex entry. | | |
ocsenave@312 39 | BC000- | Move names. | | |
ocsenave@311 40 | E8000-E876C | Names of the \ldquo{}190\rdquo{} species of Pok\eacute{}mon in memory. | Fixed length (10-letter) Pok\eacute{}mon names. Any extra space is padded with the character 0x80. The names are in \ldquo{}internal order\rdquo{}. | RHYDON####KANGASKHANNIDORAN♂#... |
ocsenave@311 41 | | | | |
ocsenave@311 42 | | | | |
ocsenave@312 43
ocsenave@312 44 * Appendices
ocsenave@312 45 ** Internal Pok\eacute{}mon IDs
ocsenave@312 46 ** Type IDs
ocsenave@312 47 ** Basic effects of moves
ocsenave@312 48 ** Alphabet code