![]() |
Routines |
| Prev: 26109 | Up: Map | Next: 26152 |
|
Used by the routine at HandlerCar.
Continues HandlerCar when the car is moving towards lower X positions. Takes the distance away from the X position, stopping at zero.
|
||||||||||
| ReduceCarX | 26141 | EX DE,HL | Swap DE and HL so that HL is the X position and DE is the distance. | |||||||
| 26142 | AND A | Reset the carry flag. | ||||||||
| 26143 | SBC HL,DE | HL=HL - DE. | ||||||||
| 26145 | JR NC,HandlerCar_StoreX | If the result is not negative then jump to HandlerCar_StoreX. | ||||||||
| 26147 | LD HL,0 | HL=0000 (stop at zero). | ||||||||
| 26150 | JR HandlerCar_StoreX | Jump to HandlerCar_StoreX. | ||||||||
| Prev: 26109 | Up: Map | Next: 26152 |