Prev: 66FD Up: Map Next: 6772
6711: CRASH - hit a tree! Bring it close up to the player so we crash into it
Used by the routine at 66FD.
6711 LD H,$7F Get the tree position
6713 LD L,$8D adjusted for where
6715 LD A,($5DDF) the player is travelling
6718 ADD A,L
6719 LD L,A
671A LD B,$03
671C LD (HL),$20 Put a tree here
671E INC HL
671F DJNZ $671C
6721 LD B,$03
6723 LD (HL),$40 Put a big tree here
6725 INC HL
6726 DJNZ $6723
6728 CALL $5F89 Recalculate trees
672B LD HL,$504D Copy the bottom of the tree down so it meets the bike
672E LD B,$08
6730 PUSH HL
6731 PUSH BC
6732 LD B,$07
6734 LD A,($502F)
6737 OR (HL)
6738 LD (HL),A
6739 INC HL
673A DJNZ $6734
673C POP BC
673D POP HL
673E INC H
673F DJNZ $6730
6741 XOR A
6742 LD ($5DE8),A Turn off firing
6745 LD A,$02
6747 LD ($5DEC),A Stop the bike
674A CALL $6781 Play a "hit tree" effect
674D CALL $6530 Clear the screen
6750 CALL $6772 and the playing area
6753 CALL $686B Stop firing
6756 CALL $6918 Restore the display
6759 CALL $66DB and the handlebars
675C LD A,($6987) Get the number of lives
675F DEC A Remove one
6760 LD ($6987),A Set the new value
6763 CP $30 Have we run out of lives?
6765 PUSH AF
6766 CALL $6974 Print new number of lives
6769 POP AF
676A RET NZ More lives left
676B POP HL
676C CALL $6B71 Game over!
676F JP $65B3 Back to start sequence
Prev: 66FD Up: Map Next: 6772