Prev: 52362 Up: Map Next: 52398
52375: Move Player Forward
Used by the routine at SlowPlayerDown.
Sets the speed and moves the sheriff one step in the direction of his heading, stopping at walls. A step plays PlayFootstepSound and PlayMovementSound, and moves on to the next walking frame.
Input
A The speed
IX The address of the sheriff
Set the speed and check the walls. Keep the flags from before the check for PlayFootstepSound.
MovePlayerForward 52375 LD (IX+5),A Set the speed.
52378 CALL SetSpeedsFromHeading Call SetSpeedsFromHeading.
52381 LD A,(IX+7) Fetch the flags.
52384 PUSH AF Stash the flags on the stack.
52385 CALL TestMove Call TestMove.
52388 POP AF Restore the flags from the stack.
Play the sounds and move the sheriff.
52389 CALL PlayFootstepSound Call PlayFootstepSound.
52392 CALL MoveObject Call MoveObject.
52395 CALL PlayMovementSound Call PlayMovementSound.
Continue on to NextSpriteNumber.
Prev: 52362 Up: Map Next: 52398