![]() |
Routines |
| Prev: CA70 | Up: Map | Next: CA90 |
|
Used by the routines at clip_dZ_to_floor, dX_obj_shorten, dY_obj_shorten, dZ_obj_shorten, clip_dX_test and clip_dY_test.
Moves A one step towards zero -- down if positive, up if negative -- and leaves Z set if nothing is left. Every loop in the collision code uses it to cut a move short one unit at a time and try again.
|
||||||||||
| shorten_delta | CA89 | AND A | already zero | |||||||
| CA8A | RET Z | |||||||||
| CA8B | JP P,shorten_delta_dec | negative: +2 and then -1 | ||||||||
| CA8E | INC A | |||||||||
| CA8F | INC A | |||||||||
| Prev: CA70 | Up: Map | Next: CA90 |