From 86960297c3131b1724083ea580b0476c10a9ca2c Mon Sep 17 00:00:00 2001 From: cpg Date: Tue, 11 May 2004 19:31:14 +0000 Subject: [PATCH] return correct joystick count for XL and newer machines -- patch from Stefan Haubenthal git-svn-id: svn://svn.cc65.org/cc65/trunk@3021 b7a2c559-68d2-44c3-8de9-860c34a00d81 --- libsrc/atari/atari-stdjoy.s | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/libsrc/atari/atari-stdjoy.s b/libsrc/atari/atari-stdjoy.s index c89044b19..54b8d7228 100644 --- a/libsrc/atari/atari-stdjoy.s +++ b/libsrc/atari/atari-stdjoy.s @@ -81,9 +81,14 @@ UNINSTALL: ; COUNT: - lda #JOY_COUNT - rts + lda #JOY_COUNT + ldx $fcd8 + cpx #$a2 + beq _400800 + lsr a ; XL and newer machines only have 2 ports +_400800: + ldx #0 + rts ; ------------------------------------------------------------------------ ; READ: Read a particular joystick passed in A. -- 2.39.5