Prev: 6DEF Up: Map Next: 6E19
6E00: Bounce Off Y Edge
Used by the routines at HandlerAccelerate and SubtractY.
Reverses the direction in Y, sounds the bounce and carries on with the X direction.
BounceY 6E00 LD A,($5E11) Fetch the quadrant of the direction (5E11).
6E03 XOR %00000001 Flip bit 0 to reverse the direction in Y.
6E05 LD ($5E11),A Write the quadrant back to 5E11.
6E08 LD A,($5E10) Fetch the direction (Player_Direction).
6E0B CPL Flip all the bits to reverse the direction within the quadrant.
6E0C LD ($5E10),A Write the direction back to Player_Direction.
6E0F LD A,$05 Set the bounce counter to 05.
6E11 LD ($5E45),A Write the bounce counter to BounceCounter.
6E14 CALL SoundsBounce Make the bounce sound using SoundsBounce.
6E17 JR HandlerAccelerate_MoveX Jump to HandlerAccelerate_MoveX.
Prev: 6DEF Up: Map Next: 6E19