![]() |
Routines |
| Prev: DF97 | Up: Map | Next: E00B |
|
Used by the routine at CLIP_PLUS_V.
Called by the +V routine (CLIP_PLUS_V) for each cell its object's leading edge covers. If the object's box, moved by this turn's step, overlaps one of the cell's boxes (HIT_BOXES_V), the step in V (+B) is cut by the overlap, so that the move ends with the object against the box's face; bit 0 of the flags (+7) is set to say it was stopped, and carry is returned.
The entry point CUT_STEP_V adds twice A, the overlap in half units, to the step; MARK_BLOCKED sets the flag. CUT_STEP_MINUS_V, CUT_STEP_PLUS_U and CUT_STEP_MINUS_U are the same for -V, +U and -U.
|
||||||||||||||||
| CUT_STEP_PLUS_V | DFFA | CALL HIT_BOXES_V | Test the cell's boxes; nothing in the way returns with carry clear | |||||||||||||
| DFFD | RET NC | |||||||||||||||
|
This entry point is used by the routine at CUT_STEP_MINUS_V.
|
||||||||||||||||
| CUT_STEP_V | DFFE | ADD A,A | CUT_STEP_V: A is minus the overlap, in half units; twice it added to a positive step ends the move at the box | |||||||||||||
| DFFF | ADD A,(IX+$0B) | |||||||||||||||
| E002 | LD (IX+$0B),A | |||||||||||||||
|
This entry point is used by the routine at CUT_STEP_PLUS_U.
|
||||||||||||||||
| MARK_BLOCKED | E005 | SET 0,(IX+$07) | MARK_BLOCKED: bit 0 of the flags says the object was stopped; return with carry set | |||||||||||||
| E009 | SCF | |||||||||||||||
| E00A | RET | |||||||||||||||
| Prev: DF97 | Up: Map | Next: E00B |