![]() |
Routines |
| Prev: C46D | Up: Map | Next: C489 |
|
Used by the routine at main.
Gives each of the 32 places in special_objs_tbl an object, and puts each one at its starting position. The places are fixed by the table; what changes from game to game is which object is where. The kinds are handed out in rotation, 96 to 103 and round again, so there are four of each, but the rotation starts at a random point: the seed saved at switch-on ($5BA0) plus the refresh register.
Types 96 to 102 are the seven things the wizard's cauldron needs (objects_required lists the order he asks for them); type 103 is the one that gives an extra life when touched (upd_103).
|
||||
| init_special_objects | C47E | LD HL,special_objs_tbl | the first of 32 nine-byte entries | |
| C481 | LD A,($5BA0) | a random starting kind | ||
| C484 | LD E,A | |||
| C485 | LD A,R | |||
| C487 | ADD A,E | |||
| C488 | LD E,A | |||
| Prev: C46D | Up: Map | Next: C489 |