MAMEWorld >> MAME Artwork: Official
Previous thread Previous  View all threads Index   Next thread Next   Flat Mode Flat  

Mr. DoAdministrator
MAME Art Editor
Reged: 09/21/03
Posts: 4856
Loc: California
Send PM
Re: Vas Crabb or Mr. Do: Request for Input
12/03/20 08:51 PM Attachment: bosco.zip 4017 KB (3 downloads)


> I've run into the same problem with Champion Baseball as I did with Bosconian: it
> won't read the upper left/lower right joystick positions (or vice-versa as was the
> case with Bosconian). Is there a bit mask hitherto unexplored? I initially thought it
> may have been a driver bug, but I'm not sure now that I've run into it twice. See
> attached.

Fix attached... probably better if I explain how the whole inputraw thing works (well, for joysticks at least):

This is the Input_Port settings for Bosconian joystick:

PORT_START("IN0")
PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_JOYSTICK_UP ) PORT_8WAY
PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_JOYSTICK_RIGHT ) PORT_8WAY
PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_JOYSTICK_DOWN ) PORT_8WAY
PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_JOYSTICK_LEFT ) PORT_8WAY

The default state and inputmask is the sum of all the port_bits that you are grouping together; in this case, u/r/d/l... 1+2+4+8=15, which is f in hex (10=a, 11=b, etc.)

The state in the element for each position is the sum of all the inputs, minus the input you are defining... so RIGHT = 15-2 = 13 = d... UP+LEFT = 15-1-8 = 6

On average, a 4/8-way joystick for many games will have an inputmask of 0xf, but U/D/L/R aren't always in the same order, so you can't always copy/paste from one game to another; only if the inputs are in the same order, with the same port_bits.



RELAX and just have fun. Remember, it's all about the games.








Entire thread
Subject Posted by Posted on
* Vas Crabb or Mr. Do: Request for Input Nightvoice 12/03/20 04:22 PM
. * Re: Vas Crabb or Mr. Do: Request for Input Mr. DoAdministrator  12/03/20 08:51 PM
. * Re: Vas Crabb or Mr. Do: Request for Input MooglyGuy  12/04/20 04:06 AM
. * Re: Vas Crabb or Mr. Do: Request for Input Mr. DoAdministrator  12/04/20 07:39 AM
. * Re: Vas Crabb or Mr. Do: Request for Input Vas Crabb  12/05/20 01:46 PM
. * Re: Vas Crabb or Mr. Do: Request for Input Vas Crabb  12/04/20 11:19 AM
. * Re: Vas Crabb or Mr. Do: Request for Input Nightvoice  12/31/20 08:36 PM
. * Re: Vas Crabb or Mr. Do: Request for Input Mr. DoAdministrator  01/01/21 12:25 AM
. * Re: Vas Crabb or Mr. Do: Request for Input Vas Crabb  01/01/21 03:47 AM
. * What Am I Doing Wrong? Nightvoice  11/24/21 10:40 PM
. * Re: What Am I Doing Wrong? Vas Crabb  11/27/21 06:55 PM
. * Re: What Am I Doing Wrong? Nightvoice  11/27/21 08:07 PM
. * Re: What Am I Doing Wrong? Mr. DoAdministrator  12/05/21 03:34 PM
. * Re: What Am I Doing Wrong? Nightvoice  12/05/21 11:21 PM
. * Re: Escape From The Planet of the Robot Monsters Nightvoice  12/08/21 05:22 AM
. * Re: What Am I Doing Wrong? Vas Crabb  11/27/21 05:18 AM
. * Re: Vas Crabb or Mr. Do: Request for Input Nightvoice  01/01/21 07:31 AM
. * Re: Vas Crabb or Mr. Do: Request for Input Vas Crabb  01/01/21 03:02 PM
. * Re: Vas Crabb or Mr. Do: Request for Input Nightvoice  12/04/20 03:34 PM
. * Re: Vas Crabb or Mr. Do: Request for Input Vas Crabb  12/05/20 04:36 AM
. * Re: Vas Crabb or Mr. Do: Request for Input Nightvoice  12/03/20 10:04 PM
. * Re: Vas Crabb or Mr. Do: Request for Input wemr97dl  03/24/23 07:15 AM
. * Re: Vas Crabb or Mr. Do: Request for Input Nightvoice  03/24/23 09:42 PM
. * Re: Vas Crabb or Mr. Do: Request for Input Nightvoice  12/03/20 04:23 PM

Extra information Permissions
Moderator:  Mr. Do 
0 registered and 12 anonymous users are browsing this forum.
You cannot start new topics
You cannot reply to topics
HTML is enabled
UBBCode is enabled
Thread views: 1098