| The Hobbit (v1.0) | Routines |
| Prev: 8B18 | Up: Map | Next: 8B26 |
|
Increases D (x), unless it would go past 255. Returns with Z set at the edge.
|
||||
| 8B1F | INC D | x one higher | ||
| 8B20 | RET NZ | Still within 0-255: done | ||
| 8B21 | DEC D | Wrapped past 255: undo the move | ||
| 8B22 | LD H,A | Save A for a moment... | ||
| 8B23 | XOR A | ...set Z, to tell the caller the edge was reached... | ||
| 8B24 | LD A,H | ...then restore A | ||
| 8B25 | RET | |||
| Prev: 8B18 | Up: Map | Next: 8B26 |