From e241085fb527e38bf4e9f992067ccb5cebc6fea9 Mon Sep 17 00:00:00 2001 From: Michael Pavone Date: Sat, 5 Dec 2015 18:40:34 -0800 Subject: Mouse X and Y are 9-bit 2's complement not 8-bit magnitude + sign bit like I thought. Fixed mouse Y direction. --- menu.s68 | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'menu.s68') diff --git a/menu.s68 b/menu.s68 index c9f8e59..1a30874 100644 --- a/menu.s68 +++ b/menu.s68 @@ -364,6 +364,7 @@ handle_mouse: move.b #1, mouse_shown.w .skip_show_check + neg.w d1 move.l mouse_sprite.w, a2 add.w d1, (a2) add.w d0, mouse_x.w @@ -505,11 +506,11 @@ loop: btst #4, d3 beq xpos - neg.w d0 + or.w #$FF00, d0 xpos btst #5, d3 beq ypos - neg.w d1 + or.w #$FF00, d1 ypos ;set port config back to normal controller mode move.b #$40, (PAD1_CTRL-PAD1_DATA, a2) -- cgit v1.2.3