mirror of
https://github.com/holub/mame
synced 2025-07-05 01:48:29 +03:00
rmnimbus.c: reduce tagmap lookups (nw)
This commit is contained in:
parent
f749c73b26
commit
24f9770aeb
@ -66,7 +66,12 @@ public:
|
|||||||
m_scsi_ctrl_out(*this, "scsi_ctrl_out"),
|
m_scsi_ctrl_out(*this, "scsi_ctrl_out"),
|
||||||
m_fdc(*this, FDC_TAG),
|
m_fdc(*this, FDC_TAG),
|
||||||
m_z80sio(*this, Z80SIO_TAG),
|
m_z80sio(*this, Z80SIO_TAG),
|
||||||
m_screen(*this, "screen")
|
m_screen(*this, "screen"),
|
||||||
|
m_io_config(*this, "config"),
|
||||||
|
m_io_joystick0(*this, JOYSTICK0_TAG),
|
||||||
|
m_io_mouse_button(*this, MOUSE_BUTTON_TAG),
|
||||||
|
m_io_mousex(*this, MOUSEX_TAG),
|
||||||
|
m_io_mousey(*this, MOUSEY_TAG)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -84,6 +89,11 @@ public:
|
|||||||
required_device<wd2793_t> m_fdc;
|
required_device<wd2793_t> m_fdc;
|
||||||
required_device<z80sio2_device> m_z80sio;
|
required_device<z80sio2_device> m_z80sio;
|
||||||
required_device<screen_device> m_screen;
|
required_device<screen_device> m_screen;
|
||||||
|
required_ioport m_io_config;
|
||||||
|
required_ioport m_io_joystick0;
|
||||||
|
required_ioport m_io_mouse_button;
|
||||||
|
required_ioport m_io_mousex;
|
||||||
|
required_ioport m_io_mousey;
|
||||||
|
|
||||||
bitmap_ind16 m_video_mem;
|
bitmap_ind16 m_video_mem;
|
||||||
|
|
||||||
|
@ -1546,9 +1546,9 @@ void rmnimbus_state::device_timer(emu_timer &timer, device_timer_id id, int para
|
|||||||
int xint;
|
int xint;
|
||||||
int yint;
|
int yint;
|
||||||
|
|
||||||
m_nimbus_mouse.m_reg0a4 = ioport(MOUSE_BUTTON_TAG)->read() | 0xC0;
|
m_nimbus_mouse.m_reg0a4 = m_io_mouse_button->read() | 0xC0;
|
||||||
x = ioport(MOUSEX_TAG)->read();
|
x = m_io_mousex->read();
|
||||||
y = ioport(MOUSEY_TAG)->read();
|
y = m_io_mousey->read();
|
||||||
|
|
||||||
UINT8 mxa;
|
UINT8 mxa;
|
||||||
UINT8 mxb;
|
UINT8 mxb;
|
||||||
@ -1683,14 +1683,14 @@ READ8_MEMBER(rmnimbus_state::nimbus_mouse_js_r)
|
|||||||
UINT8 result;
|
UINT8 result;
|
||||||
//int pc=m_maincpu->_pc();
|
//int pc=m_maincpu->_pc();
|
||||||
|
|
||||||
if (ioport("config")->read() & 0x01)
|
if (m_io_config->read() & 0x01)
|
||||||
{
|
{
|
||||||
result=m_nimbus_mouse.m_reg0a4;
|
result=m_nimbus_mouse.m_reg0a4;
|
||||||
//logerror("mouse_js_r: pc=%05X, result=%02X\n",pc,result);
|
//logerror("mouse_js_r: pc=%05X, result=%02X\n",pc,result);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
result=ioport(JOYSTICK0_TAG)->read_safe(0xff);
|
result = m_io_joystick0->read();
|
||||||
}
|
}
|
||||||
|
|
||||||
return result;
|
return result;
|
||||||
|
Loading…
Reference in New Issue
Block a user