Skip to navigation


Extra tracks: HookJoystick (Part 2 of 3)

Name: HookJoystick (Part 2 of 3) [Show more] Type: Subroutine Category: Extra tracks Summary: Apply enhanced joystick steering to specific track sections Deep dive: Secrets of the extra tracks Code hooks in the extra tracks
Context: See this subroutine in context in the source code References: No direct references to this subroutine in this source file
.joys8 LDY #181 \ Set Y = 181 so by default we scale the steering by \ 1.00 CMP #24 \ If the track section <> 24 (i.e. section 3), jump to BNE joys9 \ joys9 to keep checking LDY #205 \ Set Y = 205 so we scale the steering by 1.28 .joys9 CMP #48 \ If the track section = 48 (i.e. section 6), jump to BEQ joys10 \ joys10 to scale the steering by 1.08 CMP #40 \ If the track section <> 40 (i.e. section 5), jump to BNE joys11 \ joys11 to keep checking .joys10 LDY #188 \ Set Y = 188 so we scale the steering by 1.08 .joys11 JMP joys12 \ Jump to part 3 to scale the steering