Prev: CF50 Up: Map Next: CF67
CF5F: Check Wall Horizontal Reverse
Used by the routine at TestMoveLeft.
Checks whether an object that is moving in the direction of heading three touches a wall in the cell containing a point. If it does, the depth is made positive and the object is pushed back by CheckWallHorizontal_PushBack.
Input
DE The horizontal position of the point
HL The vertical position of the point
IX The address of the object
Output
F The carry flag is set if the object hit a wall
Check the walls, then push the object back if it is touching one.
CheckWallHorizontalReverse CF5F CALL CheckWallsVerticalFirst Call CheckWallsVerticalFirst.
CF62 RET NC Return if the object is not touching a wall.
CF63 NEG Make the depth positive, and jump to CheckWallHorizontal_PushBack.
CF65 JR CheckWallHorizontal_PushBack
View the equivalent code in;
Prev: CF50 Up: Map Next: CF67