summaryrefslogtreecommitdiff
path: root/menu.s68
diff options
context:
space:
mode:
authorMichael Pavone <pavone@retrodev.com>2015-12-05 18:40:34 -0800
committerMichael Pavone <pavone@retrodev.com>2015-12-05 18:40:34 -0800
commite241085fb527e38bf4e9f992067ccb5cebc6fea9 (patch)
tree8ae2aae19e05c398092f8dc7e2f019e14ce60108 /menu.s68
parent8592699fdafa583310eaf3679a46fde920ec8114 (diff)
Mouse X and Y are 9-bit 2's complement not 8-bit magnitude + sign bit like I thought. Fixed mouse Y direction.
Diffstat (limited to 'menu.s68')
-rw-r--r--menu.s685
1 files changed, 3 insertions, 2 deletions
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)