Search
lxdream.org :: lxdream :: r411:5ae249d63c44
lxdream 0.9.1
released Jun 29
Download Now
changeset411:5ae249d63c44
parent410:5f8413358e7f
child412:d58e4d69de16
authornkeynes
dateSun Sep 30 21:19:43 2007 +0000 (12 years ago)
Fix trigger buttons (sense was inverted)
src/maple/controller.c
1.1 --- a/src/maple/controller.c Sat Sep 29 11:06:40 2007 +0000
1.2 +++ b/src/maple/controller.c Sun Sep 30 21:19:43 2007 +0000
1.3 @@ -1,5 +1,5 @@
1.4 /**
1.5 - * $Id: controller.c,v 1.4 2006-05-20 02:40:51 nkeynes Exp $
1.6 + * $Id: controller.c,v 1.5 2007-09-30 21:19:43 nkeynes Exp $
1.7 *
1.8 * Implements the standard dreamcast controller
1.9 *
1.10 @@ -91,6 +91,10 @@
1.11 case JOY_DOWN:
1.12 dev->condition[1] |= JOY_Y_AXIS;
1.13 break;
1.14 + case BUTTON_LEFT_TRIGGER:
1.15 + case BUTTON_RIGHT_TRIGGER:
1.16 + dev->condition[0] |= value;
1.17 + break;
1.18 default:
1.19 dev->condition[0] &= ~value;
1.20 }
1.21 @@ -104,6 +108,10 @@
1.22 case JOY_DOWN:
1.23 dev->condition[1] = (dev->condition[1] & ~JOY_Y_AXIS)| JOY_Y_AXIS_CENTER;
1.24 break;
1.25 + case BUTTON_LEFT_TRIGGER:
1.26 + case BUTTON_RIGHT_TRIGGER:
1.27 + dev->condition[0] &= ~value;
1.28 + break;
1.29 default:
1.30 dev->condition[0] |= value;
1.31 }
.