![]() |
Routines |
| Prev: 45020 | Up: Map | Next: 45038 |
|
Is meant to move a light one cell up. However, the instruction that should take one row off the address is missing, so the cell that is tested is the cell that the light is already in. That cell never has the attribute of the frame, and so the light always turns instead.
|
||||||||||
| MoveLightUp | 45025 | LD L,E | Point HL at the cell that the light is in. | |||||||
| 45026 | LD H,D | |||||||||
| 45027 | LD BC,32 | Use a row of 32 characters. | ||||||||
| 45030 | AND A | Clear the carry flag. | ||||||||
|
This entry point is used by the routine at MoveLightDown.
|
||||||||||
| MoveLight_Test | 45031 | LD A,(HL) | Fetch the attribute of the cell. | |||||||
| 45032 | CP 72 | Jump to turn the light sideways if it is not part of the frame. | ||||||||
| 45034 | JR NZ,TurnLightHorizontally | |||||||||
| 45036 | JR MoveLight_Move | Jump to move the light. | ||||||||
| Prev: 45020 | Up: Map | Next: 45038 |