mirror of
https://github.com/holub/mame
synced 2025-05-22 13:48:55 +03:00
Fix Mantis #00106.
KonamiGX: Tweek le2 gun aiming. Reloading off the top and bottom of the screen works again.
This commit is contained in:
parent
3518ae84ac
commit
29e2e3855e
@ -873,16 +873,19 @@ static double adc0834_callback( int input )
|
||||
|
||||
static READ32_HANDLER( le2_gun_H_r )
|
||||
{
|
||||
int p1x = input_port_read(machine, "LIGHT0_X")*287/0xff+22;
|
||||
int p2x = input_port_read(machine, "LIGHT1_X")*287/0xff+22;
|
||||
int p1x = input_port_read(machine, "LIGHT0_X")*290/0xff+20;
|
||||
int p2x = input_port_read(machine, "LIGHT1_X")*290/0xff+20;
|
||||
|
||||
return (p1x<<16)|p2x;
|
||||
}
|
||||
|
||||
static READ32_HANDLER( le2_gun_V_r )
|
||||
{
|
||||
int p1y = input_port_read(machine, "LIGHT0_Y")*223/0xff+1;
|
||||
int p2y = input_port_read(machine, "LIGHT1_Y")*223/0xff+1;
|
||||
int p1y = input_port_read(machine, "LIGHT0_Y")*224/0xff;
|
||||
int p2y = input_port_read(machine, "LIGHT1_Y")*224/0xff;
|
||||
|
||||
// make "off the bottom" reload too
|
||||
if (p1y >= 0xdf) p1y = 0;
|
||||
|
||||
return (p1y<<16)|p2y;
|
||||
}
|
||||
@ -3353,8 +3356,8 @@ static DRIVER_INIT(konamigx)
|
||||
switch (gameDefs[i].special)
|
||||
{
|
||||
case 1: // LE2 guns
|
||||
memory_install_read32_handler(machine, 0, ADDRESS_SPACE_PROGRAM, 0xd44000, 0xd44003, 0, 0, le2_gun_H_r );
|
||||
memory_install_read32_handler(machine, 0, ADDRESS_SPACE_PROGRAM, 0xd44004, 0xd44007, 0, 0, le2_gun_V_r );
|
||||
memory_install_read32_handler(machine, 0, ADDRESS_SPACE_PROGRAM, 0xd44000, 0xd44003, 0, 0, le2_gun_H_r );
|
||||
memory_install_read32_handler(machine, 0, ADDRESS_SPACE_PROGRAM, 0xd44004, 0xd44007, 0, 0, le2_gun_V_r );
|
||||
break;
|
||||
|
||||
case 2: // tkmmpzdm hack
|
||||
|
Loading…
Reference in New Issue
Block a user