| The Hobbit (v1.0) | Routines |
| Prev: AA13 | Up: Map | Next: AA47 |
|
Called by 9611 when the eyes timer reaches 0. If Bilbo is still in room 2 (the forest road) or room 3 (the forest), he has stayed too long: the eyes are shown, the thing drops from above and stings, and Bilbo dies. If he is anywhere else, nothing happens.
Together with AA13 and C6CC, this produces the well-known rule: on entering the forest, wait twice and move on the third turn. The timer is set to 4 on entry; the turn of entry leaves it at 3, the two waits take it to 2 and then 1 (the tick routine is happy each time because Bilbo is still there), and the move takes it to 0 with Bilbo already out of the forest. Wait a third time and the timer expires with Bilbo still there; move sooner and the tick routine sees him gone while the timer is still running.
|
||||
| AA2E | LD A,($C01B) | Is Bilbo in room 2 or room 3? | ||
| AA31 | CP $02 | Is it room 2? | ||
| AA33 | JR Z,$AA38 | If yes, go to AA38 | ||
| AA35 | CP $03 | Is it room 3? | ||
| AA37 | RET NZ | Return if no | ||
| AA38 | LD HL,$B203 | Yes: eyes... | ||
| AA3B | CALL $72D4 | Print the message at HL | ||
|
This entry point is used by the routine at AA13.
|
||||
| AA3E | LD HL,$B211 | ...sting... | ||
| AA41 | CALL $72D4 | Print the message at HL | ||
| AA44 | JP $903C | ...and death | ||
| Prev: AA13 | Up: Map | Next: AA47 |